@syhr/sy-graph 1.0.9-beta.2 → 1.0.9-beta.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/sy-graph.cjs CHANGED
@@ -1,16 +1,16 @@
1
- "use strict";require('./graph.css');var Ec=Object.defineProperty,Ac=Object.defineProperties;var Cc=Object.getOwnPropertyDescriptors;var fn=Object.getOwnPropertySymbols;var Sa=Object.prototype.hasOwnProperty,Ba=Object.prototype.propertyIsEnumerable;var ar=(e,r)=>(r=Symbol[e])?r:Symbol.for("Symbol."+e),Sc=e=>{throw TypeError(e)},mt=Math.pow,vi=(e,r,t)=>r in e?Ec(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,he=(e,r)=>{for(var t in r||(r={}))Sa.call(r,t)&&vi(e,t,r[t]);if(fn)for(var t of fn(r))Ba.call(r,t)&&vi(e,t,r[t]);return e},_e=(e,r)=>Ac(e,Cc(r));var ka=(e,r)=>{var t={};for(var n in e)Sa.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(e!=null&&fn)for(var n of fn(e))r.indexOf(n)<0&&Ba.call(e,n)&&(t[n]=e[n]);return t};var It=(e,r,t)=>vi(e,typeof r!="symbol"?r+"":r,t);var je=(e,r,t)=>new Promise((n,l)=>{var a=p=>{try{u(t.next(p))}catch(s){l(s)}},o=p=>{try{u(t.throw(p))}catch(s){l(s)}},u=p=>p.done?n(p.value):Promise.resolve(p.value).then(a,o);u((t=t.apply(e,r)).next())}),zt=function(e,r){this[0]=e,this[1]=r},yi=(e,r,t)=>{var n=(o,u,p,s)=>{try{var i=t[o](u),d=(u=i.value)instanceof zt,c=i.done;Promise.resolve(d?u[0]:u).then(f=>d?n(o==="return"?o:"next",u[1]?{done:f.done,value:f.value}:f,p,s):p({value:f,done:c})).catch(f=>n("throw",f,p,s))}catch(f){s(f)}},l=o=>a[o]=u=>new Promise((p,s)=>n(o,u,p,s)),a={};return t=t.apply(e,r),a[ar("asyncIterator")]=()=>a,l("next"),l("throw"),l("return"),a},gi=e=>{var r=e[ar("asyncIterator")],t=!1,n,l={};return r==null?(r=e[ar("iterator")](),n=a=>l[a]=o=>r[a](o)):(r=r.call(e),n=a=>l[a]=o=>{if(t){if(t=!1,a==="throw")throw o;return o}return t=!0,{done:!1,value:new zt(new Promise(u=>{var p=r[a](o);p instanceof Object||Sc("Object expected"),u(p)}),1)}}),l[ar("iterator")]=()=>l,n("next"),"throw"in r?n("throw"):l.throw=a=>{throw a},"return"in r&&n("return"),l},Ta=(e,r,t)=>(r=e[ar("asyncIterator")])?r.call(e):(e=e[ar("iterator")](),r={},t=(n,l)=>(l=e[n])&&(r[n]=a=>new Promise((o,u,p)=>(a=l.call(e,a),p=a.done,Promise.resolve(a.value).then(s=>o({value:s,done:p}),u)))),t("next"),t("return"),r);Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const N=require("vue"),$n=require("lodash-es"),tu=require("@meta2d/utils"),Pe=require("@meta2d/core"),Bc=require("/icon/camera.svg?url"),kc=require("/icon/audio.svg?url"),Tc=require("/icon/sensor.svg?url"),Fc=require("/icon/light_plate.svg"),Ic=require("@meta2d/plugin-mind-core"),Dc=require("@meta2d/plugin-mind-collapse"),Rc=require("@meta2d/form-diagram"),Oc=require("@meta2d/class-diagram"),Pc=require("@meta2d/le5le-charts"),Fa=require("@meta2d/flow-diagram"),xi=require("@meta2d/fta-diagram"),Ia=require("@meta2d/sequence-diagram"),Da=require("@meta2d/activity-diagram");var xe=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function Zo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Nc(e){if(e.__esModule)return e;var r=e.default;if(typeof r=="function"){var t=function n(){return this instanceof n?Reflect.construct(r,arguments,this.constructor):r.apply(this,arguments)};t.prototype=r.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var l=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,l.get?l:{enumerable:!0,get:function(){return e[n]}})}),t}var Ar=TypeError;const Mc={},Lc=Object.freeze(Object.defineProperty({__proto__:null,default:Mc},Symbol.toStringTag,{value:"Module"})),ru=Nc(Lc);var Jo=typeof Map=="function"&&Map.prototype,bi=Object.getOwnPropertyDescriptor&&Jo?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Rn=Jo&&bi&&typeof bi.get=="function"?bi.get:null,Ra=Jo&&Map.prototype.forEach,ea=typeof Set=="function"&&Set.prototype,wi=Object.getOwnPropertyDescriptor&&ea?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,On=ea&&wi&&typeof wi.get=="function"?wi.get:null,Oa=ea&&Set.prototype.forEach,Uc=typeof WeakMap=="function"&&WeakMap.prototype,Pr=Uc?WeakMap.prototype.has:null,qc=typeof WeakSet=="function"&&WeakSet.prototype,Nr=qc?WeakSet.prototype.has:null,$c=typeof WeakRef=="function"&&WeakRef.prototype,Pa=$c?WeakRef.prototype.deref:null,zc=Boolean.prototype.valueOf,jc=Object.prototype.toString,Hc=Function.prototype.toString,Vc=String.prototype.match,ta=String.prototype.slice,Rt=String.prototype.replace,Wc=String.prototype.toUpperCase,Na=String.prototype.toLowerCase,nu=RegExp.prototype.test,Ma=Array.prototype.concat,bt=Array.prototype.join,Kc=Array.prototype.slice,La=Math.floor,Ro=typeof BigInt=="function"?BigInt.prototype.valueOf:null,_i=Object.getOwnPropertySymbols,Oo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,gr=typeof Symbol=="function"&&typeof Symbol.iterator=="object",Mr=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===gr||!0)?Symbol.toStringTag:null,iu=Object.prototype.propertyIsEnumerable,Ua=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function qa(e,r){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||nu.call(/e/,r))return r;var t=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var n=e<0?-La(-e):La(e);if(n!==e){var l=String(n),a=ta.call(r,l.length+1);return Rt.call(l,t,"$&_")+"."+Rt.call(Rt.call(a,/([0-9]{3})/g,"$&_"),/_$/,"")}}return Rt.call(r,t,"$&_")}var Po=ru,$a=Po.custom,za=su($a)?$a:null,ou={__proto__:null,double:'"',single:"'"},Gc={__proto__:null,double:/(["\\])/g,single:/(['\\])/g},zn=function e(r,t,n,l){var a=t||{};if(St(a,"quoteStyle")&&!St(ou,a.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(St(a,"maxStringLength")&&(typeof a.maxStringLength=="number"?a.maxStringLength<0&&a.maxStringLength!==1/0:a.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var o=St(a,"customInspect")?a.customInspect:!0;if(typeof o!="boolean"&&o!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(St(a,"indent")&&a.indent!==null&&a.indent!==" "&&!(parseInt(a.indent,10)===a.indent&&a.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(St(a,"numericSeparator")&&typeof a.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var u=a.numericSeparator;if(typeof r=="undefined")return"undefined";if(r===null)return"null";if(typeof r=="boolean")return r?"true":"false";if(typeof r=="string")return uu(r,a);if(typeof r=="number"){if(r===0)return 1/0/r>0?"0":"-0";var p=String(r);return u?qa(r,p):p}if(typeof r=="bigint"){var s=String(r)+"n";return u?qa(r,s):s}var i=typeof a.depth=="undefined"?5:a.depth;if(typeof n=="undefined"&&(n=0),n>=i&&i>0&&typeof r=="object")return No(r)?"[Array]":"[Object]";var d=pf(a,n);if(typeof l=="undefined")l=[];else if(lu(l,r)>=0)return"[Circular]";function c(C,F,j){if(F&&(l=Kc.call(l),l.push(F)),j){var P={depth:a.depth};return St(a,"quoteStyle")&&(P.quoteStyle=a.quoteStyle),e(C,P,n+1,l)}return e(C,a,n+1,l)}if(typeof r=="function"&&!ja(r)){var f=nf(r),h=hn(r,c);return"[Function"+(f?": "+f:" (anonymous)")+"]"+(h.length>0?" { "+bt.call(h,", ")+" }":"")}if(su(r)){var v=gr?Rt.call(String(r),/^(Symbol\(.*\))_[^)]*$/,"$1"):Oo.call(r);return typeof r=="object"&&!gr?Fr(v):v}if(cf(r)){for(var m="<"+Na.call(String(r.nodeName)),g=r.attributes||[],x=0;x<g.length;x++)m+=" "+g[x].name+"="+au(Qc(g[x].value),"double",a);return m+=">",r.childNodes&&r.childNodes.length&&(m+="..."),m+="</"+Na.call(String(r.nodeName))+">",m}if(No(r)){if(r.length===0)return"[]";var y=hn(r,c);return d&&!hf(y)?"["+Mo(y,d)+"]":"[ "+bt.call(y,", ")+" ]"}if(Xc(r)){var w=hn(r,c);return!("cause"in Error.prototype)&&"cause"in r&&!iu.call(r,"cause")?"{ ["+String(r)+"] "+bt.call(Ma.call("[cause]: "+c(r.cause),w),", ")+" }":w.length===0?"["+String(r)+"]":"{ ["+String(r)+"] "+bt.call(w,", ")+" }"}if(typeof r=="object"&&o){if(za&&typeof r[za]=="function"&&Po)return Po(r,{depth:i-n});if(o!=="symbol"&&typeof r.inspect=="function")return r.inspect()}if(of(r)){var k=[];return Ra&&Ra.call(r,function(C,F){k.push(c(F,r,!0)+" => "+c(C,r))}),Ha("Map",Rn.call(r),k,d)}if(lf(r)){var T=[];return Oa&&Oa.call(r,function(C){T.push(c(C,r))}),Ha("Set",On.call(r),T,d)}if(af(r))return Ei("WeakMap");if(uf(r))return Ei("WeakSet");if(sf(r))return Ei("WeakRef");if(Jc(r))return Fr(c(Number(r)));if(tf(r))return Fr(c(Ro.call(r)));if(ef(r))return Fr(zc.call(r));if(Zc(r))return Fr(c(String(r)));if(typeof window!="undefined"&&r===window)return"{ [object Window] }";if(typeof globalThis!="undefined"&&r===globalThis||typeof xe!="undefined"&&r===xe)return"{ [object globalThis] }";if(!Yc(r)&&!ja(r)){var I=hn(r,c),D=Ua?Ua(r)===Object.prototype:r instanceof Object||r.constructor===Object,X=r instanceof Object?"":"null prototype",V=!D&&Mr&&Object(r)===r&&Mr in r?ta.call(Pt(r),8,-1):X?"Object":"",E=D||typeof r.constructor!="function"?"":r.constructor.name?r.constructor.name+" ":"",A=E+(V||X?"["+bt.call(Ma.call([],V||[],X||[]),": ")+"] ":"");return I.length===0?A+"{}":d?A+"{"+Mo(I,d)+"}":A+"{ "+bt.call(I,", ")+" }"}return String(r)};function au(e,r,t){var n=t.quoteStyle||r,l=ou[n];return l+e+l}function Qc(e){return Rt.call(String(e),/"/g,"&quot;")}function er(e){return!Mr||!(typeof e=="object"&&(Mr in e||typeof e[Mr]!="undefined"))}function No(e){return Pt(e)==="[object Array]"&&er(e)}function Yc(e){return Pt(e)==="[object Date]"&&er(e)}function ja(e){return Pt(e)==="[object RegExp]"&&er(e)}function Xc(e){return Pt(e)==="[object Error]"&&er(e)}function Zc(e){return Pt(e)==="[object String]"&&er(e)}function Jc(e){return Pt(e)==="[object Number]"&&er(e)}function ef(e){return Pt(e)==="[object Boolean]"&&er(e)}function su(e){if(gr)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!Oo)return!1;try{return Oo.call(e),!0}catch(r){}return!1}function tf(e){if(!e||typeof e!="object"||!Ro)return!1;try{return Ro.call(e),!0}catch(r){}return!1}var rf=Object.prototype.hasOwnProperty||function(e){return e in this};function St(e,r){return rf.call(e,r)}function Pt(e){return jc.call(e)}function nf(e){if(e.name)return e.name;var r=Vc.call(Hc.call(e),/^function\s*([\w$]+)/);return r?r[1]:null}function lu(e,r){if(e.indexOf)return e.indexOf(r);for(var t=0,n=e.length;t<n;t++)if(e[t]===r)return t;return-1}function of(e){if(!Rn||!e||typeof e!="object")return!1;try{Rn.call(e);try{On.call(e)}catch(r){return!0}return e instanceof Map}catch(r){}return!1}function af(e){if(!Pr||!e||typeof e!="object")return!1;try{Pr.call(e,Pr);try{Nr.call(e,Nr)}catch(r){return!0}return e instanceof WeakMap}catch(r){}return!1}function sf(e){if(!Pa||!e||typeof e!="object")return!1;try{return Pa.call(e),!0}catch(r){}return!1}function lf(e){if(!On||!e||typeof e!="object")return!1;try{On.call(e);try{Rn.call(e)}catch(r){return!0}return e instanceof Set}catch(r){}return!1}function uf(e){if(!Nr||!e||typeof e!="object")return!1;try{Nr.call(e,Nr);try{Pr.call(e,Pr)}catch(r){return!0}return e instanceof WeakSet}catch(r){}return!1}function cf(e){return!e||typeof e!="object"?!1:typeof HTMLElement!="undefined"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}function uu(e,r){if(e.length>r.maxStringLength){var t=e.length-r.maxStringLength,n="... "+t+" more character"+(t>1?"s":"");return uu(ta.call(e,0,r.maxStringLength),r)+n}var l=Gc[r.quoteStyle||"single"];l.lastIndex=0;var a=Rt.call(Rt.call(e,l,"\\$1"),/[\x00-\x1f]/g,ff);return au(a,"single",r)}function ff(e){var r=e.charCodeAt(0),t={8:"b",9:"t",10:"n",12:"f",13:"r"}[r];return t?"\\"+t:"\\x"+(r<16?"0":"")+Wc.call(r.toString(16))}function Fr(e){return"Object("+e+")"}function Ei(e){return e+" { ? }"}function Ha(e,r,t,n){var l=n?Mo(t,n):bt.call(t,", ");return e+" ("+r+") {"+l+"}"}function hf(e){for(var r=0;r<e.length;r++)if(lu(e[r],`
2
- `)>=0)return!1;return!0}function pf(e,r){var t;if(e.indent===" ")t=" ";else if(typeof e.indent=="number"&&e.indent>0)t=bt.call(Array(e.indent+1)," ");else return null;return{base:t,prev:bt.call(Array(r+1),t)}}function Mo(e,r){if(e.length===0)return"";var t=`
1
+ "use strict";require('./graph.css');var Ec=Object.defineProperty,Ac=Object.defineProperties;var Cc=Object.getOwnPropertyDescriptors;var fn=Object.getOwnPropertySymbols;var Sa=Object.prototype.hasOwnProperty,Ba=Object.prototype.propertyIsEnumerable;var ar=(e,r)=>(r=Symbol[e])?r:Symbol.for("Symbol."+e),Sc=e=>{throw TypeError(e)},mt=Math.pow,vi=(e,r,t)=>r in e?Ec(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,he=(e,r)=>{for(var t in r||(r={}))Sa.call(r,t)&&vi(e,t,r[t]);if(fn)for(var t of fn(r))Ba.call(r,t)&&vi(e,t,r[t]);return e},_e=(e,r)=>Ac(e,Cc(r));var ka=(e,r)=>{var t={};for(var n in e)Sa.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(e!=null&&fn)for(var n of fn(e))r.indexOf(n)<0&&Ba.call(e,n)&&(t[n]=e[n]);return t};var It=(e,r,t)=>vi(e,typeof r!="symbol"?r+"":r,t);var je=(e,r,t)=>new Promise((n,l)=>{var a=p=>{try{u(t.next(p))}catch(s){l(s)}},o=p=>{try{u(t.throw(p))}catch(s){l(s)}},u=p=>p.done?n(p.value):Promise.resolve(p.value).then(a,o);u((t=t.apply(e,r)).next())}),zt=function(e,r){this[0]=e,this[1]=r},yi=(e,r,t)=>{var n=(o,u,p,s)=>{try{var i=t[o](u),d=(u=i.value)instanceof zt,c=i.done;Promise.resolve(d?u[0]:u).then(f=>d?n(o==="return"?o:"next",u[1]?{done:f.done,value:f.value}:f,p,s):p({value:f,done:c})).catch(f=>n("throw",f,p,s))}catch(f){s(f)}},l=o=>a[o]=u=>new Promise((p,s)=>n(o,u,p,s)),a={};return t=t.apply(e,r),a[ar("asyncIterator")]=()=>a,l("next"),l("throw"),l("return"),a},gi=e=>{var r=e[ar("asyncIterator")],t=!1,n,l={};return r==null?(r=e[ar("iterator")](),n=a=>l[a]=o=>r[a](o)):(r=r.call(e),n=a=>l[a]=o=>{if(t){if(t=!1,a==="throw")throw o;return o}return t=!0,{done:!1,value:new zt(new Promise(u=>{var p=r[a](o);p instanceof Object||Sc("Object expected"),u(p)}),1)}}),l[ar("iterator")]=()=>l,n("next"),"throw"in r?n("throw"):l.throw=a=>{throw a},"return"in r&&n("return"),l},Ta=(e,r,t)=>(r=e[ar("asyncIterator")])?r.call(e):(e=e[ar("iterator")](),r={},t=(n,l)=>(l=e[n])&&(r[n]=a=>new Promise((o,u,p)=>(a=l.call(e,a),p=a.done,Promise.resolve(a.value).then(s=>o({value:s,done:p}),u)))),t("next"),t("return"),r);Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const N=require("vue"),$n=require("lodash-es"),tu=require("@meta2d/utils"),Pe=require("@meta2d/core"),Bc=require("@meta2d/plugin-mind-core"),kc=require("@meta2d/plugin-mind-collapse"),Tc=require("@meta2d/form-diagram"),Fc=require("@meta2d/class-diagram"),Ic=require("@meta2d/le5le-charts"),Fa=require("@meta2d/flow-diagram"),xi=require("@meta2d/fta-diagram"),Ia=require("@meta2d/sequence-diagram"),Da=require("@meta2d/activity-diagram");var xe=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function Zo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Dc(e){if(e.__esModule)return e;var r=e.default;if(typeof r=="function"){var t=function n(){return this instanceof n?Reflect.construct(r,arguments,this.constructor):r.apply(this,arguments)};t.prototype=r.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var l=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,l.get?l:{enumerable:!0,get:function(){return e[n]}})}),t}var Ar=TypeError;const Rc={},Oc=Object.freeze(Object.defineProperty({__proto__:null,default:Rc},Symbol.toStringTag,{value:"Module"})),ru=Dc(Oc);var Jo=typeof Map=="function"&&Map.prototype,bi=Object.getOwnPropertyDescriptor&&Jo?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Rn=Jo&&bi&&typeof bi.get=="function"?bi.get:null,Ra=Jo&&Map.prototype.forEach,ea=typeof Set=="function"&&Set.prototype,wi=Object.getOwnPropertyDescriptor&&ea?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,On=ea&&wi&&typeof wi.get=="function"?wi.get:null,Oa=ea&&Set.prototype.forEach,Pc=typeof WeakMap=="function"&&WeakMap.prototype,Pr=Pc?WeakMap.prototype.has:null,Nc=typeof WeakSet=="function"&&WeakSet.prototype,Nr=Nc?WeakSet.prototype.has:null,Mc=typeof WeakRef=="function"&&WeakRef.prototype,Pa=Mc?WeakRef.prototype.deref:null,Lc=Boolean.prototype.valueOf,Uc=Object.prototype.toString,qc=Function.prototype.toString,$c=String.prototype.match,ta=String.prototype.slice,Rt=String.prototype.replace,zc=String.prototype.toUpperCase,Na=String.prototype.toLowerCase,nu=RegExp.prototype.test,Ma=Array.prototype.concat,bt=Array.prototype.join,jc=Array.prototype.slice,La=Math.floor,Ro=typeof BigInt=="function"?BigInt.prototype.valueOf:null,_i=Object.getOwnPropertySymbols,Oo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,gr=typeof Symbol=="function"&&typeof Symbol.iterator=="object",Mr=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===gr||!0)?Symbol.toStringTag:null,iu=Object.prototype.propertyIsEnumerable,Ua=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function qa(e,r){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||nu.call(/e/,r))return r;var t=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof e=="number"){var n=e<0?-La(-e):La(e);if(n!==e){var l=String(n),a=ta.call(r,l.length+1);return Rt.call(l,t,"$&_")+"."+Rt.call(Rt.call(a,/([0-9]{3})/g,"$&_"),/_$/,"")}}return Rt.call(r,t,"$&_")}var Po=ru,$a=Po.custom,za=su($a)?$a:null,ou={__proto__:null,double:'"',single:"'"},Hc={__proto__:null,double:/(["\\])/g,single:/(['\\])/g},zn=function e(r,t,n,l){var a=t||{};if(St(a,"quoteStyle")&&!St(ou,a.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(St(a,"maxStringLength")&&(typeof a.maxStringLength=="number"?a.maxStringLength<0&&a.maxStringLength!==1/0:a.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var o=St(a,"customInspect")?a.customInspect:!0;if(typeof o!="boolean"&&o!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(St(a,"indent")&&a.indent!==null&&a.indent!==" "&&!(parseInt(a.indent,10)===a.indent&&a.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(St(a,"numericSeparator")&&typeof a.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var u=a.numericSeparator;if(typeof r=="undefined")return"undefined";if(r===null)return"null";if(typeof r=="boolean")return r?"true":"false";if(typeof r=="string")return uu(r,a);if(typeof r=="number"){if(r===0)return 1/0/r>0?"0":"-0";var p=String(r);return u?qa(r,p):p}if(typeof r=="bigint"){var s=String(r)+"n";return u?qa(r,s):s}var i=typeof a.depth=="undefined"?5:a.depth;if(typeof n=="undefined"&&(n=0),n>=i&&i>0&&typeof r=="object")return No(r)?"[Array]":"[Object]";var d=uf(a,n);if(typeof l=="undefined")l=[];else if(lu(l,r)>=0)return"[Circular]";function c(C,F,j){if(F&&(l=jc.call(l),l.push(F)),j){var P={depth:a.depth};return St(a,"quoteStyle")&&(P.quoteStyle=a.quoteStyle),e(C,P,n+1,l)}return e(C,a,n+1,l)}if(typeof r=="function"&&!ja(r)){var f=Jc(r),h=hn(r,c);return"[Function"+(f?": "+f:" (anonymous)")+"]"+(h.length>0?" { "+bt.call(h,", ")+" }":"")}if(su(r)){var v=gr?Rt.call(String(r),/^(Symbol\(.*\))_[^)]*$/,"$1"):Oo.call(r);return typeof r=="object"&&!gr?Fr(v):v}if(af(r)){for(var m="<"+Na.call(String(r.nodeName)),g=r.attributes||[],x=0;x<g.length;x++)m+=" "+g[x].name+"="+au(Vc(g[x].value),"double",a);return m+=">",r.childNodes&&r.childNodes.length&&(m+="..."),m+="</"+Na.call(String(r.nodeName))+">",m}if(No(r)){if(r.length===0)return"[]";var y=hn(r,c);return d&&!lf(y)?"["+Mo(y,d)+"]":"[ "+bt.call(y,", ")+" ]"}if(Kc(r)){var w=hn(r,c);return!("cause"in Error.prototype)&&"cause"in r&&!iu.call(r,"cause")?"{ ["+String(r)+"] "+bt.call(Ma.call("[cause]: "+c(r.cause),w),", ")+" }":w.length===0?"["+String(r)+"]":"{ ["+String(r)+"] "+bt.call(w,", ")+" }"}if(typeof r=="object"&&o){if(za&&typeof r[za]=="function"&&Po)return Po(r,{depth:i-n});if(o!=="symbol"&&typeof r.inspect=="function")return r.inspect()}if(ef(r)){var k=[];return Ra&&Ra.call(r,function(C,F){k.push(c(F,r,!0)+" => "+c(C,r))}),Ha("Map",Rn.call(r),k,d)}if(nf(r)){var T=[];return Oa&&Oa.call(r,function(C){T.push(c(C,r))}),Ha("Set",On.call(r),T,d)}if(tf(r))return Ei("WeakMap");if(of(r))return Ei("WeakSet");if(rf(r))return Ei("WeakRef");if(Qc(r))return Fr(c(Number(r)));if(Xc(r))return Fr(c(Ro.call(r)));if(Yc(r))return Fr(Lc.call(r));if(Gc(r))return Fr(c(String(r)));if(typeof window!="undefined"&&r===window)return"{ [object Window] }";if(typeof globalThis!="undefined"&&r===globalThis||typeof xe!="undefined"&&r===xe)return"{ [object globalThis] }";if(!Wc(r)&&!ja(r)){var I=hn(r,c),D=Ua?Ua(r)===Object.prototype:r instanceof Object||r.constructor===Object,X=r instanceof Object?"":"null prototype",V=!D&&Mr&&Object(r)===r&&Mr in r?ta.call(Pt(r),8,-1):X?"Object":"",E=D||typeof r.constructor!="function"?"":r.constructor.name?r.constructor.name+" ":"",A=E+(V||X?"["+bt.call(Ma.call([],V||[],X||[]),": ")+"] ":"");return I.length===0?A+"{}":d?A+"{"+Mo(I,d)+"}":A+"{ "+bt.call(I,", ")+" }"}return String(r)};function au(e,r,t){var n=t.quoteStyle||r,l=ou[n];return l+e+l}function Vc(e){return Rt.call(String(e),/"/g,"&quot;")}function er(e){return!Mr||!(typeof e=="object"&&(Mr in e||typeof e[Mr]!="undefined"))}function No(e){return Pt(e)==="[object Array]"&&er(e)}function Wc(e){return Pt(e)==="[object Date]"&&er(e)}function ja(e){return Pt(e)==="[object RegExp]"&&er(e)}function Kc(e){return Pt(e)==="[object Error]"&&er(e)}function Gc(e){return Pt(e)==="[object String]"&&er(e)}function Qc(e){return Pt(e)==="[object Number]"&&er(e)}function Yc(e){return Pt(e)==="[object Boolean]"&&er(e)}function su(e){if(gr)return e&&typeof e=="object"&&e instanceof Symbol;if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||!Oo)return!1;try{return Oo.call(e),!0}catch(r){}return!1}function Xc(e){if(!e||typeof e!="object"||!Ro)return!1;try{return Ro.call(e),!0}catch(r){}return!1}var Zc=Object.prototype.hasOwnProperty||function(e){return e in this};function St(e,r){return Zc.call(e,r)}function Pt(e){return Uc.call(e)}function Jc(e){if(e.name)return e.name;var r=$c.call(qc.call(e),/^function\s*([\w$]+)/);return r?r[1]:null}function lu(e,r){if(e.indexOf)return e.indexOf(r);for(var t=0,n=e.length;t<n;t++)if(e[t]===r)return t;return-1}function ef(e){if(!Rn||!e||typeof e!="object")return!1;try{Rn.call(e);try{On.call(e)}catch(r){return!0}return e instanceof Map}catch(r){}return!1}function tf(e){if(!Pr||!e||typeof e!="object")return!1;try{Pr.call(e,Pr);try{Nr.call(e,Nr)}catch(r){return!0}return e instanceof WeakMap}catch(r){}return!1}function rf(e){if(!Pa||!e||typeof e!="object")return!1;try{return Pa.call(e),!0}catch(r){}return!1}function nf(e){if(!On||!e||typeof e!="object")return!1;try{On.call(e);try{Rn.call(e)}catch(r){return!0}return e instanceof Set}catch(r){}return!1}function of(e){if(!Nr||!e||typeof e!="object")return!1;try{Nr.call(e,Nr);try{Pr.call(e,Pr)}catch(r){return!0}return e instanceof WeakSet}catch(r){}return!1}function af(e){return!e||typeof e!="object"?!1:typeof HTMLElement!="undefined"&&e instanceof HTMLElement?!0:typeof e.nodeName=="string"&&typeof e.getAttribute=="function"}function uu(e,r){if(e.length>r.maxStringLength){var t=e.length-r.maxStringLength,n="... "+t+" more character"+(t>1?"s":"");return uu(ta.call(e,0,r.maxStringLength),r)+n}var l=Hc[r.quoteStyle||"single"];l.lastIndex=0;var a=Rt.call(Rt.call(e,l,"\\$1"),/[\x00-\x1f]/g,sf);return au(a,"single",r)}function sf(e){var r=e.charCodeAt(0),t={8:"b",9:"t",10:"n",12:"f",13:"r"}[r];return t?"\\"+t:"\\x"+(r<16?"0":"")+zc.call(r.toString(16))}function Fr(e){return"Object("+e+")"}function Ei(e){return e+" { ? }"}function Ha(e,r,t,n){var l=n?Mo(t,n):bt.call(t,", ");return e+" ("+r+") {"+l+"}"}function lf(e){for(var r=0;r<e.length;r++)if(lu(e[r],`
2
+ `)>=0)return!1;return!0}function uf(e,r){var t;if(e.indent===" ")t=" ";else if(typeof e.indent=="number"&&e.indent>0)t=bt.call(Array(e.indent+1)," ");else return null;return{base:t,prev:bt.call(Array(r+1),t)}}function Mo(e,r){if(e.length===0)return"";var t=`
3
3
  `+r.prev+r.base;return t+bt.call(e,","+t)+`
4
- `+r.prev}function hn(e,r){var t=No(e),n=[];if(t){n.length=e.length;for(var l=0;l<e.length;l++)n[l]=St(e,l)?r(e[l],e):""}var a=typeof _i=="function"?_i(e):[],o;if(gr){o={};for(var u=0;u<a.length;u++)o["$"+a[u]]=a[u]}for(var p in e)St(e,p)&&(t&&String(Number(p))===p&&p<e.length||gr&&o["$"+p]instanceof Symbol||(nu.call(/[^\w$]/,p)?n.push(r(p,e)+": "+r(e[p],e)):n.push(p+": "+r(e[p],e))));if(typeof _i=="function")for(var s=0;s<a.length;s++)iu.call(e,a[s])&&n.push("["+r(a[s])+"]: "+r(e[a[s]],e));return n}var df=zn,mf=Ar,jn=function(e,r,t){for(var n=e,l;(l=n.next)!=null;n=l)if(l.key===r)return n.next=l.next,t||(l.next=e.next,e.next=l),l},vf=function(e,r){if(e){var t=jn(e,r);return t&&t.value}},yf=function(e,r,t){var n=jn(e,r);n?n.value=t:e.next={key:r,next:e.next,value:t}},gf=function(e,r){return e?!!jn(e,r):!1},xf=function(e,r){if(e)return jn(e,r,!0)},bf=function(){var r,t={assert:function(n){if(!t.has(n))throw new mf("Side channel does not contain "+df(n))},delete:function(n){var l=r&&r.next,a=xf(r,n);return a&&l&&l===a&&(r=void 0),!!a},get:function(n){return vf(r,n)},has:function(n){return gf(r,n)},set:function(n,l){r||(r={next:void 0}),yf(r,n,l)}};return t},cu=Object,wf=Error,_f=EvalError,Ef=RangeError,Af=ReferenceError,Cf=SyntaxError,Sf=URIError,Bf=Math.abs,kf=Math.floor,Tf=Math.max,Ff=Math.min,If=Math.pow,Df=Math.round,Rf=Number.isNaN||function(r){return r!==r},Of=Rf,Pf=function(r){return Of(r)||r===0?r:r<0?-1:1},Nf=Object.getOwnPropertyDescriptor,Cn=Nf;if(Cn)try{Cn([],"length")}catch(e){Cn=null}var fu=Cn,Sn=Object.defineProperty||!1;if(Sn)try{Sn({},"a",{value:1})}catch(e){Sn=!1}var Mf=Sn,Ai,Va;function Lf(){return Va||(Va=1,Ai=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var r={},t=Symbol("test"),n=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var l=42;r[t]=l;for(var a in r)return!1;if(typeof Object.keys=="function"&&Object.keys(r).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(r).length!==0)return!1;var o=Object.getOwnPropertySymbols(r);if(o.length!==1||o[0]!==t||!Object.prototype.propertyIsEnumerable.call(r,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var u=Object.getOwnPropertyDescriptor(r,t);if(u.value!==l||u.enumerable!==!0)return!1}return!0}),Ai}var Ci,Wa;function Uf(){if(Wa)return Ci;Wa=1;var e=typeof Symbol!="undefined"&&Symbol,r=Lf();return Ci=function(){return typeof e!="function"||typeof Symbol!="function"||typeof e("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:r()},Ci}var Si,Ka;function hu(){return Ka||(Ka=1,Si=typeof Reflect!="undefined"&&Reflect.getPrototypeOf||null),Si}var Bi,Ga;function pu(){if(Ga)return Bi;Ga=1;var e=cu;return Bi=e.getPrototypeOf||null,Bi}var ki,Qa;function qf(){if(Qa)return ki;Qa=1;var e="Function.prototype.bind called on incompatible ",r=Object.prototype.toString,t=Math.max,n="[object Function]",l=function(p,s){for(var i=[],d=0;d<p.length;d+=1)i[d]=p[d];for(var c=0;c<s.length;c+=1)i[c+p.length]=s[c];return i},a=function(p,s){for(var i=[],d=s,c=0;d<p.length;d+=1,c+=1)i[c]=p[d];return i},o=function(u,p){for(var s="",i=0;i<u.length;i+=1)s+=u[i],i+1<u.length&&(s+=p);return s};return ki=function(p){var s=this;if(typeof s!="function"||r.apply(s)!==n)throw new TypeError(e+s);for(var i=a(arguments,1),d,c=function(){if(this instanceof d){var g=s.apply(this,l(i,arguments));return Object(g)===g?g:this}return s.apply(p,l(i,arguments))},f=t(0,s.length-i.length),h=[],v=0;v<f;v++)h[v]="$"+v;if(d=Function("binder","return function ("+o(h,",")+"){ return binder.apply(this,arguments); }")(c),s.prototype){var m=function(){};m.prototype=s.prototype,d.prototype=new m,m.prototype=null}return d},ki}var Ti,Ya;function Hn(){if(Ya)return Ti;Ya=1;var e=qf();return Ti=Function.prototype.bind||e,Ti}var Fi,Xa;function ra(){return Xa||(Xa=1,Fi=Function.prototype.call),Fi}var Ii,Za;function du(){return Za||(Za=1,Ii=Function.prototype.apply),Ii}var $f=typeof Reflect!="undefined"&&Reflect&&Reflect.apply,zf=Hn(),jf=du(),Hf=ra(),Vf=$f,Wf=Vf||zf.call(Hf,jf),Kf=Hn(),Gf=Ar,Qf=ra(),Yf=Wf,mu=function(r){if(r.length<1||typeof r[0]!="function")throw new Gf("a function is required");return Yf(Kf,Qf,r)},Di,Ja;function Xf(){if(Ja)return Di;Ja=1;var e=mu,r=fu,t;try{t=[].__proto__===Array.prototype}catch(o){if(!o||typeof o!="object"||!("code"in o)||o.code!=="ERR_PROTO_ACCESS")throw o}var n=!!t&&r&&r(Object.prototype,"__proto__"),l=Object,a=l.getPrototypeOf;return Di=n&&typeof n.get=="function"?e([n.get]):typeof a=="function"?function(u){return a(u==null?u:l(u))}:!1,Di}var Ri,es;function Zf(){if(es)return Ri;es=1;var e=hu(),r=pu(),t=Xf();return Ri=e?function(l){return e(l)}:r?function(l){if(!l||typeof l!="object"&&typeof l!="function")throw new TypeError("getProto: not an object");return r(l)}:t?function(l){return t(l)}:null,Ri}var Oi,ts;function Jf(){if(ts)return Oi;ts=1;var e=Function.prototype.call,r=Object.prototype.hasOwnProperty,t=Hn();return Oi=t.call(e,r),Oi}var Ee,eh=cu,th=wf,rh=_f,nh=Ef,ih=Af,xr=Cf,dr=Ar,oh=Sf,ah=Bf,sh=kf,lh=Tf,uh=Ff,ch=If,fh=Df,hh=Pf,vu=Function,Pi=function(e){try{return vu('"use strict"; return ('+e+").constructor;")()}catch(r){}},qr=fu,ph=Mf,Ni=function(){throw new dr},dh=qr?function(){try{return arguments.callee,Ni}catch(e){try{return qr(arguments,"callee").get}catch(r){return Ni}}}():Ni,sr=Uf()(),$e=Zf(),mh=pu(),vh=hu(),yu=du(),Vr=ra(),fr={},yh=typeof Uint8Array=="undefined"||!$e?Ee:$e(Uint8Array),Gt={__proto__:null,"%AggregateError%":typeof AggregateError=="undefined"?Ee:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer=="undefined"?Ee:ArrayBuffer,"%ArrayIteratorPrototype%":sr&&$e?$e([][Symbol.iterator]()):Ee,"%AsyncFromSyncIteratorPrototype%":Ee,"%AsyncFunction%":fr,"%AsyncGenerator%":fr,"%AsyncGeneratorFunction%":fr,"%AsyncIteratorPrototype%":fr,"%Atomics%":typeof Atomics=="undefined"?Ee:Atomics,"%BigInt%":typeof BigInt=="undefined"?Ee:BigInt,"%BigInt64Array%":typeof BigInt64Array=="undefined"?Ee:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array=="undefined"?Ee:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView=="undefined"?Ee:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":th,"%eval%":eval,"%EvalError%":rh,"%Float16Array%":typeof Float16Array=="undefined"?Ee:Float16Array,"%Float32Array%":typeof Float32Array=="undefined"?Ee:Float32Array,"%Float64Array%":typeof Float64Array=="undefined"?Ee:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry=="undefined"?Ee:FinalizationRegistry,"%Function%":vu,"%GeneratorFunction%":fr,"%Int8Array%":typeof Int8Array=="undefined"?Ee:Int8Array,"%Int16Array%":typeof Int16Array=="undefined"?Ee:Int16Array,"%Int32Array%":typeof Int32Array=="undefined"?Ee:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":sr&&$e?$e($e([][Symbol.iterator]())):Ee,"%JSON%":typeof JSON=="object"?JSON:Ee,"%Map%":typeof Map=="undefined"?Ee:Map,"%MapIteratorPrototype%":typeof Map=="undefined"||!sr||!$e?Ee:$e(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":eh,"%Object.getOwnPropertyDescriptor%":qr,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise=="undefined"?Ee:Promise,"%Proxy%":typeof Proxy=="undefined"?Ee:Proxy,"%RangeError%":nh,"%ReferenceError%":ih,"%Reflect%":typeof Reflect=="undefined"?Ee:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set=="undefined"?Ee:Set,"%SetIteratorPrototype%":typeof Set=="undefined"||!sr||!$e?Ee:$e(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer=="undefined"?Ee:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":sr&&$e?$e(""[Symbol.iterator]()):Ee,"%Symbol%":sr?Symbol:Ee,"%SyntaxError%":xr,"%ThrowTypeError%":dh,"%TypedArray%":yh,"%TypeError%":dr,"%Uint8Array%":typeof Uint8Array=="undefined"?Ee:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray=="undefined"?Ee:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array=="undefined"?Ee:Uint16Array,"%Uint32Array%":typeof Uint32Array=="undefined"?Ee:Uint32Array,"%URIError%":oh,"%WeakMap%":typeof WeakMap=="undefined"?Ee:WeakMap,"%WeakRef%":typeof WeakRef=="undefined"?Ee:WeakRef,"%WeakSet%":typeof WeakSet=="undefined"?Ee:WeakSet,"%Function.prototype.call%":Vr,"%Function.prototype.apply%":yu,"%Object.defineProperty%":ph,"%Object.getPrototypeOf%":mh,"%Math.abs%":ah,"%Math.floor%":sh,"%Math.max%":lh,"%Math.min%":uh,"%Math.pow%":ch,"%Math.round%":fh,"%Math.sign%":hh,"%Reflect.getPrototypeOf%":vh};if($e)try{null.error}catch(e){var gh=$e($e(e));Gt["%Error.prototype%"]=gh}var xh=function e(r){var t;if(r==="%AsyncFunction%")t=Pi("async function () {}");else if(r==="%GeneratorFunction%")t=Pi("function* () {}");else if(r==="%AsyncGeneratorFunction%")t=Pi("async function* () {}");else if(r==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(t=n.prototype)}else if(r==="%AsyncIteratorPrototype%"){var l=e("%AsyncGenerator%");l&&$e&&(t=$e(l.prototype))}return Gt[r]=t,t},rs={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Wr=Hn(),Pn=Jf(),bh=Wr.call(Vr,Array.prototype.concat),wh=Wr.call(yu,Array.prototype.splice),ns=Wr.call(Vr,String.prototype.replace),Nn=Wr.call(Vr,String.prototype.slice),_h=Wr.call(Vr,RegExp.prototype.exec),Eh=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Ah=/\\(\\)?/g,Ch=function(r){var t=Nn(r,0,1),n=Nn(r,-1);if(t==="%"&&n!=="%")throw new xr("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&t!=="%")throw new xr("invalid intrinsic syntax, expected opening `%`");var l=[];return ns(r,Eh,function(a,o,u,p){l[l.length]=u?ns(p,Ah,"$1"):o||a}),l},Sh=function(r,t){var n=r,l;if(Pn(rs,n)&&(l=rs[n],n="%"+l[0]+"%"),Pn(Gt,n)){var a=Gt[n];if(a===fr&&(a=xh(n)),typeof a=="undefined"&&!t)throw new dr("intrinsic "+r+" exists, but is not available. Please file an issue!");return{alias:l,name:n,value:a}}throw new xr("intrinsic "+r+" does not exist!")},na=function(r,t){if(typeof r!="string"||r.length===0)throw new dr("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof t!="boolean")throw new dr('"allowMissing" argument must be a boolean');if(_h(/^%?[^%]*%?$/,r)===null)throw new xr("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Ch(r),l=n.length>0?n[0]:"",a=Sh("%"+l+"%",t),o=a.name,u=a.value,p=!1,s=a.alias;s&&(l=s[0],wh(n,bh([0,1],s)));for(var i=1,d=!0;i<n.length;i+=1){var c=n[i],f=Nn(c,0,1),h=Nn(c,-1);if((f==='"'||f==="'"||f==="`"||h==='"'||h==="'"||h==="`")&&f!==h)throw new xr("property names with quotes must have matching quotes");if((c==="constructor"||!d)&&(p=!0),l+="."+c,o="%"+l+"%",Pn(Gt,o))u=Gt[o];else if(u!=null){if(!(c in u)){if(!t)throw new dr("base intrinsic for "+r+" exists, but the property is not available.");return}if(qr&&i+1>=n.length){var v=qr(u,c);d=!!v,d&&"get"in v&&!("originalValue"in v.get)?u=v.get:u=u[c]}else d=Pn(u,c),u=u[c];d&&!p&&(Gt[o]=u)}}return u},gu=na,xu=mu,Bh=xu([gu("%String.prototype.indexOf%")]),bu=function(r,t){var n=gu(r,!!t);return typeof n=="function"&&Bh(r,".prototype.")>-1?xu([n]):n},kh=na,Kr=bu,Th=zn,Fh=Ar,is=kh("%Map%",!0),Ih=Kr("Map.prototype.get",!0),Dh=Kr("Map.prototype.set",!0),Rh=Kr("Map.prototype.has",!0),Oh=Kr("Map.prototype.delete",!0),Ph=Kr("Map.prototype.size",!0),wu=!!is&&function(){var r,t={assert:function(n){if(!t.has(n))throw new Fh("Side channel does not contain "+Th(n))},delete:function(n){if(r){var l=Oh(r,n);return Ph(r)===0&&(r=void 0),l}return!1},get:function(n){if(r)return Ih(r,n)},has:function(n){return r?Rh(r,n):!1},set:function(n,l){r||(r=new is),Dh(r,n,l)}};return t},Nh=na,Vn=bu,Mh=zn,pn=wu,Lh=Ar,lr=Nh("%WeakMap%",!0),Uh=Vn("WeakMap.prototype.get",!0),qh=Vn("WeakMap.prototype.set",!0),$h=Vn("WeakMap.prototype.has",!0),zh=Vn("WeakMap.prototype.delete",!0),jh=lr?function(){var r,t,n={assert:function(l){if(!n.has(l))throw new Lh("Side channel does not contain "+Mh(l))},delete:function(l){if(lr&&l&&(typeof l=="object"||typeof l=="function")){if(r)return zh(r,l)}else if(pn&&t)return t.delete(l);return!1},get:function(l){return lr&&l&&(typeof l=="object"||typeof l=="function")&&r?Uh(r,l):t&&t.get(l)},has:function(l){return lr&&l&&(typeof l=="object"||typeof l=="function")&&r?$h(r,l):!!t&&t.has(l)},set:function(l,a){lr&&l&&(typeof l=="object"||typeof l=="function")?(r||(r=new lr),qh(r,l,a)):pn&&(t||(t=pn()),t.set(l,a))}};return n}:pn,Hh=Ar,Vh=zn,Wh=bf,Kh=wu,Gh=jh,Qh=Gh||Kh||Wh,_u=function(){var r,t={assert:function(n){if(!t.has(n))throw new Hh("Side channel does not contain "+Vh(n))},delete:function(n){return!!r&&r.delete(n)},get:function(n){return r&&r.get(n)},has:function(n){return!!r&&r.has(n)},set:function(n,l){r||(r=Qh()),r.set(n,l)}};return t},Yh=String.prototype.replace,Xh=/%20/g,Mi={RFC1738:"RFC1738",RFC3986:"RFC3986"},ia={default:Mi.RFC3986,formatters:{RFC1738:function(e){return Yh.call(e,Xh,"+")},RFC3986:function(e){return String(e)}},RFC1738:Mi.RFC1738,RFC3986:Mi.RFC3986},Zh=ia,Jh=_u,Li=Object.prototype.hasOwnProperty,Ht=Array.isArray,Wn=Jh(),pr=function(r,t){return Wn.set(r,t),r},Vt=function(r){return Wn.has(r)},Dr=function(r){return Wn.get(r)},Lo=function(r,t){Wn.set(r,t)},vt=function(){for(var e=[],r=0;r<256;++r)e[e.length]="%"+((r<16?"0":"")+r.toString(16)).toUpperCase();return e}(),ep=function(r){for(;r.length>1;){var t=r.pop(),n=t.obj[t.prop];if(Ht(n)){for(var l=[],a=0;a<n.length;++a)typeof n[a]!="undefined"&&(l[l.length]=n[a]);t.obj[t.prop]=l}}},Lr=function(r,t){for(var n=t&&t.plainObjects?{__proto__:null}:{},l=0;l<r.length;++l)typeof r[l]!="undefined"&&(n[l]=r[l]);return n},tp=function e(r,t,n){if(!t)return r;if(typeof t!="object"&&typeof t!="function"){if(Ht(r)){var l=r.length;if(n&&typeof n.arrayLimit=="number"&&l>n.arrayLimit)return pr(Lr(r.concat(t),n),l);r[l]=t}else if(r&&typeof r=="object")if(Vt(r)){var a=Dr(r)+1;r[a]=t,Lo(r,a)}else(n&&(n.plainObjects||n.allowPrototypes)||!Li.call(Object.prototype,t))&&(r[t]=!0);else return[r,t];return r}if(!r||typeof r!="object"){if(Vt(t)){for(var o=Object.keys(t),u=n&&n.plainObjects?{__proto__:null,0:r}:{0:r},p=0;p<o.length;p++){var s=parseInt(o[p],10);u[s+1]=t[o[p]]}return pr(u,Dr(t)+1)}var i=[r].concat(t);return n&&typeof n.arrayLimit=="number"&&i.length>n.arrayLimit?pr(Lr(i,n),i.length-1):i}var d=r;return Ht(r)&&!Ht(t)&&(d=Lr(r,n)),Ht(r)&&Ht(t)?(t.forEach(function(c,f){if(Li.call(r,f)){var h=r[f];h&&typeof h=="object"&&c&&typeof c=="object"?r[f]=e(h,c,n):r[r.length]=c}else r[f]=c}),r):Object.keys(t).reduce(function(c,f){var h=t[f];if(Li.call(c,f)?c[f]=e(c[f],h,n):c[f]=h,Vt(t)&&!Vt(c)&&pr(c,Dr(t)),Vt(c)){var v=parseInt(f,10);String(v)===f&&v>=0&&v>Dr(c)&&Lo(c,v)}return c},d)},rp=function(r,t){return Object.keys(t).reduce(function(n,l){return n[l]=t[l],n},r)},np=function(e,r,t){var n=e.replace(/\+/g," ");if(t==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch(l){return n}},Ui=1024,ip=function(r,t,n,l,a){if(r.length===0)return r;var o=r;if(typeof r=="symbol"?o=Symbol.prototype.toString.call(r):typeof r!="string"&&(o=String(r)),n==="iso-8859-1")return escape(o).replace(/%u[0-9a-f]{4}/gi,function(f){return"%26%23"+parseInt(f.slice(2),16)+"%3B"});for(var u="",p=0;p<o.length;p+=Ui){for(var s=o.length>=Ui?o.slice(p,p+Ui):o,i=[],d=0;d<s.length;++d){var c=s.charCodeAt(d);if(c===45||c===46||c===95||c===126||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122||a===Zh.RFC1738&&(c===40||c===41)){i[i.length]=s.charAt(d);continue}if(c<128){i[i.length]=vt[c];continue}if(c<2048){i[i.length]=vt[192|c>>6]+vt[128|c&63];continue}if(c<55296||c>=57344){i[i.length]=vt[224|c>>12]+vt[128|c>>6&63]+vt[128|c&63];continue}d+=1,c=65536+((c&1023)<<10|s.charCodeAt(d)&1023),i[i.length]=vt[240|c>>18]+vt[128|c>>12&63]+vt[128|c>>6&63]+vt[128|c&63]}u+=i.join("")}return u},op=function(r){for(var t=[{obj:{o:r},prop:"o"}],n=[],l=0;l<t.length;++l)for(var a=t[l],o=a.obj[a.prop],u=Object.keys(o),p=0;p<u.length;++p){var s=u[p],i=o[s];typeof i=="object"&&i!==null&&n.indexOf(i)===-1&&(t[t.length]={obj:o,prop:s},n[n.length]=i)}return ep(t),r},ap=function(r){return Object.prototype.toString.call(r)==="[object RegExp]"},sp=function(r){return!r||typeof r!="object"?!1:!!(r.constructor&&r.constructor.isBuffer&&r.constructor.isBuffer(r))},lp=function(r,t,n,l){if(Vt(r)){var a=Dr(r)+1;return r[a]=t,Lo(r,a),r}var o=[].concat(r,t);return o.length>n?pr(Lr(o,{plainObjects:l}),o.length-1):o},up=function(r,t){if(Ht(r)){for(var n=[],l=0;l<r.length;l+=1)n[n.length]=t(r[l]);return n}return t(r)},Eu={arrayToObject:Lr,assign:rp,combine:lp,compact:op,decode:np,encode:ip,isBuffer:sp,isOverflow:Vt,isRegExp:ap,markOverflow:pr,maybeMap:up,merge:tp},Au=_u,Bn=Eu,Ur=ia,cp=Object.prototype.hasOwnProperty,Cu={brackets:function(r){return r+"[]"},comma:"comma",indices:function(r,t){return r+"["+t+"]"},repeat:function(r){return r}},xt=Array.isArray,fp=Array.prototype.push,Su=function(e,r){fp.apply(e,xt(r)?r:[r])},hp=Date.prototype.toISOString,os=Ur.default,Ne={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,commaRoundTrip:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Bn.encode,encodeValuesOnly:!1,filter:void 0,format:os,formatter:Ur.formatters[os],indices:!1,serializeDate:function(r){return hp.call(r)},skipNulls:!1,strictNullHandling:!1},pp=function(r){return typeof r=="string"||typeof r=="number"||typeof r=="boolean"||typeof r=="symbol"||typeof r=="bigint"},qi={},dp=function e(r,t,n,l,a,o,u,p,s,i,d,c,f,h,v,m,g,x){for(var y=r,w=x,k=0,T=!1;(w=w.get(qi))!==void 0&&!T;){var I=w.get(r);if(k+=1,typeof I!="undefined"){if(I===k)throw new RangeError("Cyclic object value");T=!0}typeof w.get(qi)=="undefined"&&(k=0)}if(typeof i=="function"?y=i(t,y):y instanceof Date?y=f(y):n==="comma"&&xt(y)&&(y=Bn.maybeMap(y,function(K){return K instanceof Date?f(K):K})),y===null){if(o)return s&&!m?s(t,Ne.encoder,g,"key",h):t;y=""}if(pp(y)||Bn.isBuffer(y)){if(s){var D=m?t:s(t,Ne.encoder,g,"key",h);return[v(D)+"="+v(s(y,Ne.encoder,g,"value",h))]}return[v(t)+"="+v(String(y))]}var X=[];if(typeof y=="undefined")return X;var V;if(n==="comma"&&xt(y))m&&s&&(y=Bn.maybeMap(y,s)),V=[{value:y.length>0?y.join(",")||null:void 0}];else if(xt(i))V=i;else{var E=Object.keys(y);V=d?E.sort(d):E}var A=p?String(t).replace(/\./g,"%2E"):String(t),C=l&&xt(y)&&y.length===1?A+"[]":A;if(a&&xt(y)&&y.length===0)return C+"[]";for(var F=0;F<V.length;++F){var j=V[F],P=typeof j=="object"&&j&&typeof j.value!="undefined"?j.value:y[j];if(!(u&&P===null)){var J=c&&p?String(j).replace(/\./g,"%2E"):String(j),$=xt(y)?typeof n=="function"?n(C,J):C:C+(c?"."+J:"["+J+"]");x.set(r,k);var U=Au();U.set(qi,x),Su(X,e(P,$,n,l,a,o,u,p,n==="comma"&&m&&xt(y)?null:s,i,d,c,f,h,v,m,g,U))}}return X},mp=function(r){if(!r)return Ne;if(typeof r.allowEmptyArrays!="undefined"&&typeof r.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof r.encodeDotInKeys!="undefined"&&typeof r.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(r.encoder!==null&&typeof r.encoder!="undefined"&&typeof r.encoder!="function")throw new TypeError("Encoder has to be a function.");var t=r.charset||Ne.charset;if(typeof r.charset!="undefined"&&r.charset!=="utf-8"&&r.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=Ur.default;if(typeof r.format!="undefined"){if(!cp.call(Ur.formatters,r.format))throw new TypeError("Unknown format option provided.");n=r.format}var l=Ur.formatters[n],a=Ne.filter;(typeof r.filter=="function"||xt(r.filter))&&(a=r.filter);var o;if(r.arrayFormat in Cu?o=r.arrayFormat:"indices"in r?o=r.indices?"indices":"repeat":o=Ne.arrayFormat,"commaRoundTrip"in r&&typeof r.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var u=typeof r.allowDots=="undefined"?r.encodeDotInKeys===!0?!0:Ne.allowDots:!!r.allowDots;return{addQueryPrefix:typeof r.addQueryPrefix=="boolean"?r.addQueryPrefix:Ne.addQueryPrefix,allowDots:u,allowEmptyArrays:typeof r.allowEmptyArrays=="boolean"?!!r.allowEmptyArrays:Ne.allowEmptyArrays,arrayFormat:o,charset:t,charsetSentinel:typeof r.charsetSentinel=="boolean"?r.charsetSentinel:Ne.charsetSentinel,commaRoundTrip:!!r.commaRoundTrip,delimiter:typeof r.delimiter=="undefined"?Ne.delimiter:r.delimiter,encode:typeof r.encode=="boolean"?r.encode:Ne.encode,encodeDotInKeys:typeof r.encodeDotInKeys=="boolean"?r.encodeDotInKeys:Ne.encodeDotInKeys,encoder:typeof r.encoder=="function"?r.encoder:Ne.encoder,encodeValuesOnly:typeof r.encodeValuesOnly=="boolean"?r.encodeValuesOnly:Ne.encodeValuesOnly,filter:a,format:n,formatter:l,serializeDate:typeof r.serializeDate=="function"?r.serializeDate:Ne.serializeDate,skipNulls:typeof r.skipNulls=="boolean"?r.skipNulls:Ne.skipNulls,sort:typeof r.sort=="function"?r.sort:null,strictNullHandling:typeof r.strictNullHandling=="boolean"?r.strictNullHandling:Ne.strictNullHandling}},vp=function(e,r){var t=e,n=mp(r),l,a;typeof n.filter=="function"?(a=n.filter,t=a("",t)):xt(n.filter)&&(a=n.filter,l=a);var o=[];if(typeof t!="object"||t===null)return"";var u=Cu[n.arrayFormat],p=u==="comma"&&n.commaRoundTrip;l||(l=Object.keys(t)),n.sort&&l.sort(n.sort);for(var s=Au(),i=0;i<l.length;++i){var d=l[i],c=t[d];n.skipNulls&&c===null||Su(o,dp(c,d,u,p,n.allowEmptyArrays,n.strictNullHandling,n.skipNulls,n.encodeDotInKeys,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,s))}var f=o.join(n.delimiter),h=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?h+="utf8=%26%2310003%3B&":h+="utf8=%E2%9C%93&"),f.length>0?h+f:""},_t=Eu,kn=Object.prototype.hasOwnProperty,$i=Array.isArray,De={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:_t.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1,throwOnLimitExceeded:!1},yp=function(e){return e.replace(/&#(\d+);/g,function(r,t){return String.fromCharCode(parseInt(t,10))})},Bu=function(e,r,t){if(e&&typeof e=="string"&&r.comma&&e.indexOf(",")>-1)return e.split(",");if(r.throwOnLimitExceeded&&t>=r.arrayLimit)throw new RangeError("Array limit exceeded. Only "+r.arrayLimit+" element"+(r.arrayLimit===1?"":"s")+" allowed in an array.");return e},gp="utf8=%26%2310003%3B",xp="utf8=%E2%9C%93",bp=function(r,t){var n={__proto__:null},l=t.ignoreQueryPrefix?r.replace(/^\?/,""):r;l=l.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var a=t.parameterLimit===1/0?void 0:t.parameterLimit,o=l.split(t.delimiter,t.throwOnLimitExceeded?a+1:a);if(t.throwOnLimitExceeded&&o.length>a)throw new RangeError("Parameter limit exceeded. Only "+a+" parameter"+(a===1?"":"s")+" allowed.");var u=-1,p,s=t.charset;if(t.charsetSentinel)for(p=0;p<o.length;++p)o[p].indexOf("utf8=")===0&&(o[p]===xp?s="utf-8":o[p]===gp&&(s="iso-8859-1"),u=p,p=o.length);for(p=0;p<o.length;++p)if(p!==u){var i=o[p],d=i.indexOf("]="),c=d===-1?i.indexOf("="):d+1,f,h;if(c===-1?(f=t.decoder(i,De.decoder,s,"key"),h=t.strictNullHandling?null:""):(f=t.decoder(i.slice(0,c),De.decoder,s,"key"),f!==null&&(h=_t.maybeMap(Bu(i.slice(c+1),t,$i(n[f])?n[f].length:0),function(m){return t.decoder(m,De.decoder,s,"value")}))),h&&t.interpretNumericEntities&&s==="iso-8859-1"&&(h=yp(String(h))),i.indexOf("[]=")>-1&&(h=$i(h)?[h]:h),t.comma&&$i(h)&&h.length>t.arrayLimit){if(t.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(t.arrayLimit===1?"":"s")+" allowed in an array.");h=_t.combine([],h,t.arrayLimit,t.plainObjects)}if(f!==null){var v=kn.call(n,f);v&&t.duplicates==="combine"?n[f]=_t.combine(n[f],h,t.arrayLimit,t.plainObjects):(!v||t.duplicates==="last")&&(n[f]=h)}}return n},wp=function(e,r,t,n){var l=0;if(e.length>0&&e[e.length-1]==="[]"){var a=e.slice(0,-1).join("");l=Array.isArray(r)&&r[a]?r[a].length:0}for(var o=n?r:Bu(r,t,l),u=e.length-1;u>=0;--u){var p,s=e[u];if(s==="[]"&&t.parseArrays)_t.isOverflow(o)?p=o:p=t.allowEmptyArrays&&(o===""||t.strictNullHandling&&o===null)?[]:_t.combine([],o,t.arrayLimit,t.plainObjects);else{p=t.plainObjects?{__proto__:null}:{};var i=s.charAt(0)==="["&&s.charAt(s.length-1)==="]"?s.slice(1,-1):s,d=t.decodeDotInKeys?i.replace(/%2E/g,"."):i,c=parseInt(d,10),f=!isNaN(c)&&s!==d&&String(c)===d&&c>=0&&t.parseArrays;if(!t.parseArrays&&d==="")p={0:o};else if(f&&c<t.arrayLimit)p=[],p[c]=o;else{if(f&&t.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(t.arrayLimit===1?"":"s")+" allowed in an array.");f?(p[c]=o,_t.markOverflow(p,c)):d!=="__proto__"&&(p[d]=o)}}o=p}return o},_p=function(r,t){var n=t.allowDots?r.replace(/\.([^.[]+)/g,"[$1]"):r;if(t.depth<=0)return!t.plainObjects&&kn.call(Object.prototype,n)&&!t.allowPrototypes?void 0:[n];var l=/(\[[^[\]]*])/,a=/(\[[^[\]]*])/g,o=l.exec(n),u=o?n.slice(0,o.index):n,p=[];if(u){if(!t.plainObjects&&kn.call(Object.prototype,u)&&!t.allowPrototypes)return;p[p.length]=u}for(var s=0;(o=a.exec(n))!==null&&s<t.depth;){s+=1;var i=o[1].slice(1,-1);if(!t.plainObjects&&kn.call(Object.prototype,i)&&!t.allowPrototypes)return;p[p.length]=o[1]}if(o){if(t.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+t.depth+" and strictDepth is true");p[p.length]="["+n.slice(o.index)+"]"}return p},Ep=function(r,t,n,l){if(r){var a=_p(r,n);if(a)return wp(a,t,n,l)}},Ap=function(r){if(!r)return De;if(typeof r.allowEmptyArrays!="undefined"&&typeof r.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof r.decodeDotInKeys!="undefined"&&typeof r.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(r.decoder!==null&&typeof r.decoder!="undefined"&&typeof r.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof r.charset!="undefined"&&r.charset!=="utf-8"&&r.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");if(typeof r.throwOnLimitExceeded!="undefined"&&typeof r.throwOnLimitExceeded!="boolean")throw new TypeError("`throwOnLimitExceeded` option must be a boolean");var t=typeof r.charset=="undefined"?De.charset:r.charset,n=typeof r.duplicates=="undefined"?De.duplicates:r.duplicates;if(n!=="combine"&&n!=="first"&&n!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var l=typeof r.allowDots=="undefined"?r.decodeDotInKeys===!0?!0:De.allowDots:!!r.allowDots;return{allowDots:l,allowEmptyArrays:typeof r.allowEmptyArrays=="boolean"?!!r.allowEmptyArrays:De.allowEmptyArrays,allowPrototypes:typeof r.allowPrototypes=="boolean"?r.allowPrototypes:De.allowPrototypes,allowSparse:typeof r.allowSparse=="boolean"?r.allowSparse:De.allowSparse,arrayLimit:typeof r.arrayLimit=="number"?r.arrayLimit:De.arrayLimit,charset:t,charsetSentinel:typeof r.charsetSentinel=="boolean"?r.charsetSentinel:De.charsetSentinel,comma:typeof r.comma=="boolean"?r.comma:De.comma,decodeDotInKeys:typeof r.decodeDotInKeys=="boolean"?r.decodeDotInKeys:De.decodeDotInKeys,decoder:typeof r.decoder=="function"?r.decoder:De.decoder,delimiter:typeof r.delimiter=="string"||_t.isRegExp(r.delimiter)?r.delimiter:De.delimiter,depth:typeof r.depth=="number"||r.depth===!1?+r.depth:De.depth,duplicates:n,ignoreQueryPrefix:r.ignoreQueryPrefix===!0,interpretNumericEntities:typeof r.interpretNumericEntities=="boolean"?r.interpretNumericEntities:De.interpretNumericEntities,parameterLimit:typeof r.parameterLimit=="number"?r.parameterLimit:De.parameterLimit,parseArrays:r.parseArrays!==!1,plainObjects:typeof r.plainObjects=="boolean"?r.plainObjects:De.plainObjects,strictDepth:typeof r.strictDepth=="boolean"?!!r.strictDepth:De.strictDepth,strictNullHandling:typeof r.strictNullHandling=="boolean"?r.strictNullHandling:De.strictNullHandling,throwOnLimitExceeded:typeof r.throwOnLimitExceeded=="boolean"?r.throwOnLimitExceeded:!1}},Cp=function(e,r){var t=Ap(r);if(e===""||e===null||typeof e=="undefined")return t.plainObjects?{__proto__:null}:{};for(var n=typeof e=="string"?bp(e,t):e,l=t.plainObjects?{__proto__:null}:{},a=Object.keys(n),o=0;o<a.length;++o){var u=a[o],p=Ep(u,n[u],t,typeof e=="string");l=_t.merge(l,p,t)}return t.allowSparse===!0?l:_t.compact(l)},Sp=vp,Bp=Cp,kp=ia,Tp={formats:kp,parse:Bp,stringify:Sp};const Fp=Zo(Tp);function ku(e,r){return function(){return e.apply(r,arguments)}}const{toString:Ip}=Object.prototype,{getPrototypeOf:oa}=Object,{iterator:Kn,toStringTag:Tu}=Symbol,Gn=(e=>r=>{const t=Ip.call(r);return e[t]||(e[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),pt=e=>(e=e.toLowerCase(),r=>Gn(r)===e),Qn=e=>r=>typeof r===e,{isArray:Cr}=Array,br=Qn("undefined");function Gr(e){return e!==null&&!br(e)&&e.constructor!==null&&!br(e.constructor)&&Ze(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Fu=pt("ArrayBuffer");function Dp(e){let r;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?r=ArrayBuffer.isView(e):r=e&&e.buffer&&Fu(e.buffer),r}const Rp=Qn("string"),Ze=Qn("function"),Iu=Qn("number"),Qr=e=>e!==null&&typeof e=="object",Op=e=>e===!0||e===!1,Tn=e=>{if(Gn(e)!=="object")return!1;const r=oa(e);return(r===null||r===Object.prototype||Object.getPrototypeOf(r)===null)&&!(Tu in e)&&!(Kn in e)},Pp=e=>{if(!Qr(e)||Gr(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(r){return!1}},Np=pt("Date"),Mp=pt("File"),Lp=pt("Blob"),Up=pt("FileList"),qp=e=>Qr(e)&&Ze(e.pipe),$p=e=>{let r;return e&&(typeof FormData=="function"&&e instanceof FormData||Ze(e.append)&&((r=Gn(e))==="formdata"||r==="object"&&Ze(e.toString)&&e.toString()==="[object FormData]"))},zp=pt("URLSearchParams"),[jp,Hp,Vp,Wp]=["ReadableStream","Request","Response","Headers"].map(pt),Kp=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Yr(e,r,{allOwnKeys:t=!1}={}){if(e===null||typeof e=="undefined")return;let n,l;if(typeof e!="object"&&(e=[e]),Cr(e))for(n=0,l=e.length;n<l;n++)r.call(null,e[n],n,e);else{if(Gr(e))return;const a=t?Object.getOwnPropertyNames(e):Object.keys(e),o=a.length;let u;for(n=0;n<o;n++)u=a[n],r.call(null,e[u],u,e)}}function Du(e,r){if(Gr(e))return null;r=r.toLowerCase();const t=Object.keys(e);let n=t.length,l;for(;n-- >0;)if(l=t[n],r===l.toLowerCase())return l;return null}const Wt=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,Ru=e=>!br(e)&&e!==Wt;function Uo(){const{caseless:e,skipUndefined:r}=Ru(this)&&this||{},t={},n=(l,a)=>{if(a==="__proto__"||a==="constructor"||a==="prototype")return;const o=e&&Du(t,a)||a;Tn(t[o])&&Tn(l)?t[o]=Uo(t[o],l):Tn(l)?t[o]=Uo({},l):Cr(l)?t[o]=l.slice():(!r||!br(l))&&(t[o]=l)};for(let l=0,a=arguments.length;l<a;l++)arguments[l]&&Yr(arguments[l],n);return t}const Gp=(e,r,t,{allOwnKeys:n}={})=>(Yr(r,(l,a)=>{t&&Ze(l)?Object.defineProperty(e,a,{value:ku(l,t),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,a,{value:l,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),e),Qp=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Yp=(e,r,t,n)=>{e.prototype=Object.create(r.prototype,n),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:r.prototype}),t&&Object.assign(e.prototype,t)},Xp=(e,r,t,n)=>{let l,a,o;const u={};if(r=r||{},e==null)return r;do{for(l=Object.getOwnPropertyNames(e),a=l.length;a-- >0;)o=l[a],(!n||n(o,e,r))&&!u[o]&&(r[o]=e[o],u[o]=!0);e=t!==!1&&oa(e)}while(e&&(!t||t(e,r))&&e!==Object.prototype);return r},Zp=(e,r,t)=>{e=String(e),(t===void 0||t>e.length)&&(t=e.length),t-=r.length;const n=e.indexOf(r,t);return n!==-1&&n===t},Jp=e=>{if(!e)return null;if(Cr(e))return e;let r=e.length;if(!Iu(r))return null;const t=new Array(r);for(;r-- >0;)t[r]=e[r];return t},ed=(e=>r=>e&&r instanceof e)(typeof Uint8Array!="undefined"&&oa(Uint8Array)),td=(e,r)=>{const n=(e&&e[Kn]).call(e);let l;for(;(l=n.next())&&!l.done;){const a=l.value;r.call(e,a[0],a[1])}},rd=(e,r)=>{let t;const n=[];for(;(t=e.exec(r))!==null;)n.push(t);return n},nd=pt("HTMLFormElement"),id=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,n,l){return n.toUpperCase()+l}),as=(({hasOwnProperty:e})=>(r,t)=>e.call(r,t))(Object.prototype),od=pt("RegExp"),Ou=(e,r)=>{const t=Object.getOwnPropertyDescriptors(e),n={};Yr(t,(l,a)=>{let o;(o=r(l,a,e))!==!1&&(n[a]=o||l)}),Object.defineProperties(e,n)},ad=e=>{Ou(e,(r,t)=>{if(Ze(e)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const n=e[t];if(Ze(n)){if(r.enumerable=!1,"writable"in r){r.writable=!1;return}r.set||(r.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},sd=(e,r)=>{const t={},n=l=>{l.forEach(a=>{t[a]=!0})};return Cr(e)?n(e):n(String(e).split(r)),t},ld=()=>{},ud=(e,r)=>e!=null&&Number.isFinite(e=+e)?e:r;function cd(e){return!!(e&&Ze(e.append)&&e[Tu]==="FormData"&&e[Kn])}const fd=e=>{const r=new Array(10),t=(n,l)=>{if(Qr(n)){if(r.indexOf(n)>=0)return;if(Gr(n))return n;if(!("toJSON"in n)){r[l]=n;const a=Cr(n)?[]:{};return Yr(n,(o,u)=>{const p=t(o,l+1);!br(p)&&(a[u]=p)}),r[l]=void 0,a}}return n};return t(e,0)},hd=pt("AsyncFunction"),pd=e=>e&&(Qr(e)||Ze(e))&&Ze(e.then)&&Ze(e.catch),Pu=((e,r)=>e?setImmediate:r?((t,n)=>(Wt.addEventListener("message",({source:l,data:a})=>{l===Wt&&a===t&&n.length&&n.shift()()},!1),l=>{n.push(l),Wt.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Ze(Wt.postMessage)),dd=typeof queueMicrotask!="undefined"?queueMicrotask.bind(Wt):typeof process!="undefined"&&process.nextTick||Pu,md=e=>e!=null&&Ze(e[Kn]),le={isArray:Cr,isArrayBuffer:Fu,isBuffer:Gr,isFormData:$p,isArrayBufferView:Dp,isString:Rp,isNumber:Iu,isBoolean:Op,isObject:Qr,isPlainObject:Tn,isEmptyObject:Pp,isReadableStream:jp,isRequest:Hp,isResponse:Vp,isHeaders:Wp,isUndefined:br,isDate:Np,isFile:Mp,isBlob:Lp,isRegExp:od,isFunction:Ze,isStream:qp,isURLSearchParams:zp,isTypedArray:ed,isFileList:Up,forEach:Yr,merge:Uo,extend:Gp,trim:Kp,stripBOM:Qp,inherits:Yp,toFlatObject:Xp,kindOf:Gn,kindOfTest:pt,endsWith:Zp,toArray:Jp,forEachEntry:td,matchAll:rd,isHTMLForm:nd,hasOwnProperty:as,hasOwnProp:as,reduceDescriptors:Ou,freezeMethods:ad,toObjectSet:sd,toCamelCase:id,noop:ld,toFiniteNumber:ud,findKey:Du,global:Wt,isContextDefined:Ru,isSpecCompliantForm:cd,toJSONObject:fd,isAsyncFn:hd,isThenable:pd,setImmediate:Pu,asap:dd,isIterable:md};let be=class Nu extends Error{static from(r,t,n,l,a,o){const u=new Nu(r.message,t||r.code,n,l,a);return u.cause=r,u.name=r.name,o&&Object.assign(u,o),u}constructor(r,t,n,l,a){super(r),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),n&&(this.config=n),l&&(this.request=l),a&&(this.response=a,this.status=a.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:le.toJSONObject(this.config),code:this.code,status:this.status}}};be.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";be.ERR_BAD_OPTION="ERR_BAD_OPTION";be.ECONNABORTED="ECONNABORTED";be.ETIMEDOUT="ETIMEDOUT";be.ERR_NETWORK="ERR_NETWORK";be.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";be.ERR_DEPRECATED="ERR_DEPRECATED";be.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";be.ERR_BAD_REQUEST="ERR_BAD_REQUEST";be.ERR_CANCELED="ERR_CANCELED";be.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";be.ERR_INVALID_URL="ERR_INVALID_URL";const vd=null;function qo(e){return le.isPlainObject(e)||le.isArray(e)}function Mu(e){return le.endsWith(e,"[]")?e.slice(0,-2):e}function ss(e,r,t){return e?e.concat(r).map(function(l,a){return l=Mu(l),!t&&a?"["+l+"]":l}).join(t?".":""):r}function yd(e){return le.isArray(e)&&!e.some(qo)}const gd=le.toFlatObject(le,{},null,function(r){return/^is[A-Z]/.test(r)});function Yn(e,r,t){if(!le.isObject(e))throw new TypeError("target must be an object");r=r||new FormData,t=le.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(v,m){return!le.isUndefined(m[v])});const n=t.metaTokens,l=t.visitor||i,a=t.dots,o=t.indexes,p=(t.Blob||typeof Blob!="undefined"&&Blob)&&le.isSpecCompliantForm(r);if(!le.isFunction(l))throw new TypeError("visitor must be a function");function s(h){if(h===null)return"";if(le.isDate(h))return h.toISOString();if(le.isBoolean(h))return h.toString();if(!p&&le.isBlob(h))throw new be("Blob is not supported. Use a Buffer instead.");return le.isArrayBuffer(h)||le.isTypedArray(h)?p&&typeof Blob=="function"?new Blob([h]):Buffer.from(h):h}function i(h,v,m){let g=h;if(h&&!m&&typeof h=="object"){if(le.endsWith(v,"{}"))v=n?v:v.slice(0,-2),h=JSON.stringify(h);else if(le.isArray(h)&&yd(h)||(le.isFileList(h)||le.endsWith(v,"[]"))&&(g=le.toArray(h)))return v=Mu(v),g.forEach(function(y,w){!(le.isUndefined(y)||y===null)&&r.append(o===!0?ss([v],w,a):o===null?v:v+"[]",s(y))}),!1}return qo(h)?!0:(r.append(ss(m,v,a),s(h)),!1)}const d=[],c=Object.assign(gd,{defaultVisitor:i,convertValue:s,isVisitable:qo});function f(h,v){if(!le.isUndefined(h)){if(d.indexOf(h)!==-1)throw Error("Circular reference detected in "+v.join("."));d.push(h),le.forEach(h,function(g,x){(!(le.isUndefined(g)||g===null)&&l.call(r,g,le.isString(x)?x.trim():x,v,c))===!0&&f(g,v?v.concat(x):[x])}),d.pop()}}if(!le.isObject(e))throw new TypeError("data must be an object");return f(e),r}function ls(e){const r={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return r[n]})}function aa(e,r){this._pairs=[],e&&Yn(e,this,r)}const Lu=aa.prototype;Lu.append=function(r,t){this._pairs.push([r,t])};Lu.toString=function(r){const t=r?function(n){return r.call(this,n,ls)}:ls;return this._pairs.map(function(l){return t(l[0])+"="+t(l[1])},"").join("&")};function xd(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Uu(e,r,t){if(!r)return e;const n=t&&t.encode||xd,l=le.isFunction(t)?{serialize:t}:t,a=l&&l.serialize;let o;if(a?o=a(r,l):o=le.isURLSearchParams(r)?r.toString():new aa(r,l).toString(n),o){const u=e.indexOf("#");u!==-1&&(e=e.slice(0,u)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class us{constructor(){this.handlers=[]}use(r,t,n){return this.handlers.push({fulfilled:r,rejected:t,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(r){this.handlers[r]&&(this.handlers[r]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(r){le.forEach(this.handlers,function(n){n!==null&&r(n)})}}const sa={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},bd=typeof URLSearchParams!="undefined"?URLSearchParams:aa,wd=typeof FormData!="undefined"?FormData:null,_d=typeof Blob!="undefined"?Blob:null,Ed={isBrowser:!0,classes:{URLSearchParams:bd,FormData:wd,Blob:_d},protocols:["http","https","file","blob","url","data"]},la=typeof window!="undefined"&&typeof document!="undefined",$o=typeof navigator=="object"&&navigator||void 0,Ad=la&&(!$o||["ReactNative","NativeScript","NS"].indexOf($o.product)<0),Cd=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Sd=la&&window.location.href||"http://localhost",Bd=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:la,hasStandardBrowserEnv:Ad,hasStandardBrowserWebWorkerEnv:Cd,navigator:$o,origin:Sd},Symbol.toStringTag,{value:"Module"})),Ke=he(he({},Bd),Ed);function kd(e,r){return Yn(e,new Ke.classes.URLSearchParams,he({visitor:function(t,n,l,a){return Ke.isNode&&le.isBuffer(t)?(this.append(n,t.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},r))}function Td(e){return le.matchAll(/\w+|\[(\w*)]/g,e).map(r=>r[0]==="[]"?"":r[1]||r[0])}function Fd(e){const r={},t=Object.keys(e);let n;const l=t.length;let a;for(n=0;n<l;n++)a=t[n],r[a]=e[a];return r}function qu(e){function r(t,n,l,a){let o=t[a++];if(o==="__proto__")return!0;const u=Number.isFinite(+o),p=a>=t.length;return o=!o&&le.isArray(l)?l.length:o,p?(le.hasOwnProp(l,o)?l[o]=[l[o],n]:l[o]=n,!u):((!l[o]||!le.isObject(l[o]))&&(l[o]=[]),r(t,n,l[o],a)&&le.isArray(l[o])&&(l[o]=Fd(l[o])),!u)}if(le.isFormData(e)&&le.isFunction(e.entries)){const t={};return le.forEachEntry(e,(n,l)=>{r(Td(n),l,t,0)}),t}return null}function Id(e,r,t){if(le.isString(e))try{return(r||JSON.parse)(e),le.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(t||JSON.stringify)(e)}const Xr={transitional:sa,adapter:["xhr","http","fetch"],transformRequest:[function(r,t){const n=t.getContentType()||"",l=n.indexOf("application/json")>-1,a=le.isObject(r);if(a&&le.isHTMLForm(r)&&(r=new FormData(r)),le.isFormData(r))return l?JSON.stringify(qu(r)):r;if(le.isArrayBuffer(r)||le.isBuffer(r)||le.isStream(r)||le.isFile(r)||le.isBlob(r)||le.isReadableStream(r))return r;if(le.isArrayBufferView(r))return r.buffer;if(le.isURLSearchParams(r))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),r.toString();let u;if(a){if(n.indexOf("application/x-www-form-urlencoded")>-1)return kd(r,this.formSerializer).toString();if((u=le.isFileList(r))||n.indexOf("multipart/form-data")>-1){const p=this.env&&this.env.FormData;return Yn(u?{"files[]":r}:r,p&&new p,this.formSerializer)}}return a||l?(t.setContentType("application/json",!1),Id(r)):r}],transformResponse:[function(r){const t=this.transitional||Xr.transitional,n=t&&t.forcedJSONParsing,l=this.responseType==="json";if(le.isResponse(r)||le.isReadableStream(r))return r;if(r&&le.isString(r)&&(n&&!this.responseType||l)){const o=!(t&&t.silentJSONParsing)&&l;try{return JSON.parse(r,this.parseReviver)}catch(u){if(o)throw u.name==="SyntaxError"?be.from(u,be.ERR_BAD_RESPONSE,this,null,this.response):u}}return r}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Ke.classes.FormData,Blob:Ke.classes.Blob},validateStatus:function(r){return r>=200&&r<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};le.forEach(["delete","get","head","post","put","patch"],e=>{Xr.headers[e]={}});const Dd=le.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"]),Rd=e=>{const r={};let t,n,l;return e&&e.split(`
5
- `).forEach(function(o){l=o.indexOf(":"),t=o.substring(0,l).trim().toLowerCase(),n=o.substring(l+1).trim(),!(!t||r[t]&&Dd[t])&&(t==="set-cookie"?r[t]?r[t].push(n):r[t]=[n]:r[t]=r[t]?r[t]+", "+n:n)}),r},cs=Symbol("internals");function Ir(e){return e&&String(e).trim().toLowerCase()}function Fn(e){return e===!1||e==null?e:le.isArray(e)?e.map(Fn):String(e)}function Od(e){const r=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=t.exec(e);)r[n[1]]=n[2];return r}const Pd=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function zi(e,r,t,n,l){if(le.isFunction(n))return n.call(this,r,t);if(l&&(r=t),!!le.isString(r)){if(le.isString(n))return r.indexOf(n)!==-1;if(le.isRegExp(n))return n.test(r)}}function Nd(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(r,t,n)=>t.toUpperCase()+n)}function Md(e,r){const t=le.toCamelCase(" "+r);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+t,{value:function(l,a,o){return this[n].call(this,r,l,a,o)},configurable:!0})})}let Je=class{constructor(r){r&&this.set(r)}set(r,t,n){const l=this;function a(u,p,s){const i=Ir(p);if(!i)throw new Error("header name must be a non-empty string");const d=le.findKey(l,i);(!d||l[d]===void 0||s===!0||s===void 0&&l[d]!==!1)&&(l[d||p]=Fn(u))}const o=(u,p)=>le.forEach(u,(s,i)=>a(s,i,p));if(le.isPlainObject(r)||r instanceof this.constructor)o(r,t);else if(le.isString(r)&&(r=r.trim())&&!Pd(r))o(Rd(r),t);else if(le.isObject(r)&&le.isIterable(r)){let u={},p,s;for(const i of r){if(!le.isArray(i))throw TypeError("Object iterator must return a key-value pair");u[s=i[0]]=(p=u[s])?le.isArray(p)?[...p,i[1]]:[p,i[1]]:i[1]}o(u,t)}else r!=null&&a(t,r,n);return this}get(r,t){if(r=Ir(r),r){const n=le.findKey(this,r);if(n){const l=this[n];if(!t)return l;if(t===!0)return Od(l);if(le.isFunction(t))return t.call(this,l,n);if(le.isRegExp(t))return t.exec(l);throw new TypeError("parser must be boolean|regexp|function")}}}has(r,t){if(r=Ir(r),r){const n=le.findKey(this,r);return!!(n&&this[n]!==void 0&&(!t||zi(this,this[n],n,t)))}return!1}delete(r,t){const n=this;let l=!1;function a(o){if(o=Ir(o),o){const u=le.findKey(n,o);u&&(!t||zi(n,n[u],u,t))&&(delete n[u],l=!0)}}return le.isArray(r)?r.forEach(a):a(r),l}clear(r){const t=Object.keys(this);let n=t.length,l=!1;for(;n--;){const a=t[n];(!r||zi(this,this[a],a,r,!0))&&(delete this[a],l=!0)}return l}normalize(r){const t=this,n={};return le.forEach(this,(l,a)=>{const o=le.findKey(n,a);if(o){t[o]=Fn(l),delete t[a];return}const u=r?Nd(a):String(a).trim();u!==a&&delete t[a],t[u]=Fn(l),n[u]=!0}),this}concat(...r){return this.constructor.concat(this,...r)}toJSON(r){const t=Object.create(null);return le.forEach(this,(n,l)=>{n!=null&&n!==!1&&(t[l]=r&&le.isArray(n)?n.join(", "):n)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([r,t])=>r+": "+t).join(`
6
- `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(r){return r instanceof this?r:new this(r)}static concat(r,...t){const n=new this(r);return t.forEach(l=>n.set(l)),n}static accessor(r){const n=(this[cs]=this[cs]={accessors:{}}).accessors,l=this.prototype;function a(o){const u=Ir(o);n[u]||(Md(l,o),n[u]=!0)}return le.isArray(r)?r.forEach(a):a(r),this}};Je.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);le.reduceDescriptors(Je.prototype,({value:e},r)=>{let t=r[0].toUpperCase()+r.slice(1);return{get:()=>e,set(n){this[t]=n}}});le.freezeMethods(Je);function ji(e,r){const t=this||Xr,n=r||t,l=Je.from(n.headers);let a=n.data;return le.forEach(e,function(u){a=u.call(t,a,l.normalize(),r?r.status:void 0)}),l.normalize(),a}function $u(e){return!!(e&&e.__CANCEL__)}let Zr=class extends be{constructor(r,t,n){super(r==null?"canceled":r,be.ERR_CANCELED,t,n),this.name="CanceledError",this.__CANCEL__=!0}};function zu(e,r,t){const n=t.config.validateStatus;!t.status||!n||n(t.status)?e(t):r(new be("Request failed with status code "+t.status,[be.ERR_BAD_REQUEST,be.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function Ld(e){const r=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return r&&r[1]||""}function Ud(e,r){e=e||10;const t=new Array(e),n=new Array(e);let l=0,a=0,o;return r=r!==void 0?r:1e3,function(p){const s=Date.now(),i=n[a];o||(o=s),t[l]=p,n[l]=s;let d=a,c=0;for(;d!==l;)c+=t[d++],d=d%e;if(l=(l+1)%e,l===a&&(a=(a+1)%e),s-o<r)return;const f=i&&s-i;return f?Math.round(c*1e3/f):void 0}}function qd(e,r){let t=0,n=1e3/r,l,a;const o=(s,i=Date.now())=>{t=i,l=null,a&&(clearTimeout(a),a=null),e(...s)};return[(...s)=>{const i=Date.now(),d=i-t;d>=n?o(s,i):(l=s,a||(a=setTimeout(()=>{a=null,o(l)},n-d)))},()=>l&&o(l)]}const Mn=(e,r,t=3)=>{let n=0;const l=Ud(50,250);return qd(a=>{const o=a.loaded,u=a.lengthComputable?a.total:void 0,p=o-n,s=l(p),i=o<=u;n=o;const d={loaded:o,total:u,progress:u?o/u:void 0,bytes:p,rate:s||void 0,estimated:s&&u&&i?(u-o)/s:void 0,event:a,lengthComputable:u!=null,[r?"download":"upload"]:!0};e(d)},t)},fs=(e,r)=>{const t=e!=null;return[n=>r[0]({lengthComputable:t,total:e,loaded:n}),r[1]]},hs=e=>(...r)=>le.asap(()=>e(...r)),$d=Ke.hasStandardBrowserEnv?((e,r)=>t=>(t=new URL(t,Ke.origin),e.protocol===t.protocol&&e.host===t.host&&(r||e.port===t.port)))(new URL(Ke.origin),Ke.navigator&&/(msie|trident)/i.test(Ke.navigator.userAgent)):()=>!0,zd=Ke.hasStandardBrowserEnv?{write(e,r,t,n,l,a,o){if(typeof document=="undefined")return;const u=[`${e}=${encodeURIComponent(r)}`];le.isNumber(t)&&u.push(`expires=${new Date(t).toUTCString()}`),le.isString(n)&&u.push(`path=${n}`),le.isString(l)&&u.push(`domain=${l}`),a===!0&&u.push("secure"),le.isString(o)&&u.push(`SameSite=${o}`),document.cookie=u.join("; ")},read(e){if(typeof document=="undefined")return null;const r=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return r?decodeURIComponent(r[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function jd(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Hd(e,r){return r?e.replace(/\/?\/$/,"")+"/"+r.replace(/^\/+/,""):e}function ju(e,r,t){let n=!jd(r);return e&&(n||t==!1)?Hd(e,r):r}const ps=e=>e instanceof Je?he({},e):e;function Yt(e,r){r=r||{};const t={};function n(s,i,d,c){return le.isPlainObject(s)&&le.isPlainObject(i)?le.merge.call({caseless:c},s,i):le.isPlainObject(i)?le.merge({},i):le.isArray(i)?i.slice():i}function l(s,i,d,c){if(le.isUndefined(i)){if(!le.isUndefined(s))return n(void 0,s,d,c)}else return n(s,i,d,c)}function a(s,i){if(!le.isUndefined(i))return n(void 0,i)}function o(s,i){if(le.isUndefined(i)){if(!le.isUndefined(s))return n(void 0,s)}else return n(void 0,i)}function u(s,i,d){if(d in r)return n(s,i);if(d in e)return n(void 0,s)}const p={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:u,headers:(s,i,d)=>l(ps(s),ps(i),d,!0)};return le.forEach(Object.keys(he(he({},e),r)),function(i){if(i==="__proto__"||i==="constructor"||i==="prototype")return;const d=le.hasOwnProp(p,i)?p[i]:l,c=d(e[i],r[i],i);le.isUndefined(c)&&d!==u||(t[i]=c)}),t}const Hu=e=>{const r=Yt({},e);let{data:t,withXSRFToken:n,xsrfHeaderName:l,xsrfCookieName:a,headers:o,auth:u}=r;if(r.headers=o=Je.from(o),r.url=Uu(ju(r.baseURL,r.url,r.allowAbsoluteUrls),e.params,e.paramsSerializer),u&&o.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?unescape(encodeURIComponent(u.password)):""))),le.isFormData(t)){if(Ke.hasStandardBrowserEnv||Ke.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(le.isFunction(t.getHeaders)){const p=t.getHeaders(),s=["content-type","content-length"];Object.entries(p).forEach(([i,d])=>{s.includes(i.toLowerCase())&&o.set(i,d)})}}if(Ke.hasStandardBrowserEnv&&(n&&le.isFunction(n)&&(n=n(r)),n||n!==!1&&$d(r.url))){const p=l&&a&&zd.read(a);p&&o.set(l,p)}return r},Vd=typeof XMLHttpRequest!="undefined",Wd=Vd&&function(e){return new Promise(function(t,n){const l=Hu(e);let a=l.data;const o=Je.from(l.headers).normalize();let{responseType:u,onUploadProgress:p,onDownloadProgress:s}=l,i,d,c,f,h;function v(){f&&f(),h&&h(),l.cancelToken&&l.cancelToken.unsubscribe(i),l.signal&&l.signal.removeEventListener("abort",i)}let m=new XMLHttpRequest;m.open(l.method.toUpperCase(),l.url,!0),m.timeout=l.timeout;function g(){if(!m)return;const y=Je.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),k={data:!u||u==="text"||u==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:y,config:e,request:m};zu(function(I){t(I),v()},function(I){n(I),v()},k),m=null}"onloadend"in m?m.onloadend=g:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.indexOf("file:")===0)||setTimeout(g)},m.onabort=function(){m&&(n(new be("Request aborted",be.ECONNABORTED,e,m)),m=null)},m.onerror=function(w){const k=w&&w.message?w.message:"Network Error",T=new be(k,be.ERR_NETWORK,e,m);T.event=w||null,n(T),m=null},m.ontimeout=function(){let w=l.timeout?"timeout of "+l.timeout+"ms exceeded":"timeout exceeded";const k=l.transitional||sa;l.timeoutErrorMessage&&(w=l.timeoutErrorMessage),n(new be(w,k.clarifyTimeoutError?be.ETIMEDOUT:be.ECONNABORTED,e,m)),m=null},a===void 0&&o.setContentType(null),"setRequestHeader"in m&&le.forEach(o.toJSON(),function(w,k){m.setRequestHeader(k,w)}),le.isUndefined(l.withCredentials)||(m.withCredentials=!!l.withCredentials),u&&u!=="json"&&(m.responseType=l.responseType),s&&([c,h]=Mn(s,!0),m.addEventListener("progress",c)),p&&m.upload&&([d,f]=Mn(p),m.upload.addEventListener("progress",d),m.upload.addEventListener("loadend",f)),(l.cancelToken||l.signal)&&(i=y=>{m&&(n(!y||y.type?new Zr(null,e,m):y),m.abort(),m=null)},l.cancelToken&&l.cancelToken.subscribe(i),l.signal&&(l.signal.aborted?i():l.signal.addEventListener("abort",i)));const x=Ld(l.url);if(x&&Ke.protocols.indexOf(x)===-1){n(new be("Unsupported protocol "+x+":",be.ERR_BAD_REQUEST,e));return}m.send(a||null)})},Kd=(e,r)=>{const{length:t}=e=e?e.filter(Boolean):[];if(r||t){let n=new AbortController,l;const a=function(s){if(!l){l=!0,u();const i=s instanceof Error?s:this.reason;n.abort(i instanceof be?i:new Zr(i instanceof Error?i.message:i))}};let o=r&&setTimeout(()=>{o=null,a(new be(`timeout of ${r}ms exceeded`,be.ETIMEDOUT))},r);const u=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(s=>{s.unsubscribe?s.unsubscribe(a):s.removeEventListener("abort",a)}),e=null)};e.forEach(s=>s.addEventListener("abort",a));const{signal:p}=n;return p.unsubscribe=()=>le.asap(u),p}},Gd=function*(e,r){let t=e.byteLength;if(t<r){yield e;return}let n=0,l;for(;n<t;)l=n+r,yield e.slice(n,l),n=l},Qd=function(e,r){return yi(this,null,function*(){try{for(var t=Ta(Yd(e)),n,l,a;n=!(l=yield new zt(t.next())).done;n=!1){const o=l.value;yield*gi(Gd(o,r))}}catch(l){a=[l]}finally{try{n&&(l=t.return)&&(yield new zt(l.call(t)))}finally{if(a)throw a[0]}}})},Yd=function(e){return yi(this,null,function*(){if(e[Symbol.asyncIterator]){yield*gi(e);return}const r=e.getReader();try{for(;;){const{done:t,value:n}=yield new zt(r.read());if(t)break;yield n}}finally{yield new zt(r.cancel())}})},ds=(e,r,t,n)=>{const l=Qd(e,r);let a=0,o,u=s=>{o||(o=!0,n&&n(s))};return new ReadableStream({pull(s){return je(this,null,function*(){try{const{done:i,value:d}=yield l.next();if(i){u(),s.close();return}let c=d.byteLength;if(t){let f=a+=c;t(f)}s.enqueue(new Uint8Array(d))}catch(i){throw u(i),i}})},cancel(s){return u(s),l.return()}},{highWaterMark:2})},ms=64*1024,{isFunction:dn}=le,Xd=(({Request:e,Response:r})=>({Request:e,Response:r}))(le.global),{ReadableStream:vs,TextEncoder:ys}=le.global,gs=(e,...r)=>{try{return!!e(...r)}catch(t){return!1}},Zd=e=>{e=le.merge.call({skipUndefined:!0},Xd,e);const{fetch:r,Request:t,Response:n}=e,l=r?dn(r):typeof fetch=="function",a=dn(t),o=dn(n);if(!l)return!1;const u=l&&dn(vs),p=l&&(typeof ys=="function"?(h=>v=>h.encode(v))(new ys):h=>je(exports,null,function*(){return new Uint8Array(yield new t(h).arrayBuffer())})),s=a&&u&&gs(()=>{let h=!1;const v=new t(Ke.origin,{body:new vs,method:"POST",get duplex(){return h=!0,"half"}}).headers.has("Content-Type");return h&&!v}),i=o&&u&&gs(()=>le.isReadableStream(new n("").body)),d={stream:i&&(h=>h.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(h=>{!d[h]&&(d[h]=(v,m)=>{let g=v&&v[h];if(g)return g.call(v);throw new be(`Response type '${h}' is not supported`,be.ERR_NOT_SUPPORT,m)})});const c=h=>je(exports,null,function*(){if(h==null)return 0;if(le.isBlob(h))return h.size;if(le.isSpecCompliantForm(h))return(yield new t(Ke.origin,{method:"POST",body:h}).arrayBuffer()).byteLength;if(le.isArrayBufferView(h)||le.isArrayBuffer(h))return h.byteLength;if(le.isURLSearchParams(h)&&(h=h+""),le.isString(h))return(yield p(h)).byteLength}),f=(h,v)=>je(exports,null,function*(){const m=le.toFiniteNumber(h.getContentLength());return m==null?c(v):m});return h=>je(exports,null,function*(){let{url:v,method:m,data:g,signal:x,cancelToken:y,timeout:w,onDownloadProgress:k,onUploadProgress:T,responseType:I,headers:D,withCredentials:X="same-origin",fetchOptions:V}=Hu(h),E=r||fetch;I=I?(I+"").toLowerCase():"text";let A=Kd([x,y&&y.toAbortSignal()],w),C=null;const F=A&&A.unsubscribe&&(()=>{A.unsubscribe()});let j;try{if(T&&s&&m!=="get"&&m!=="head"&&(j=yield f(D,g))!==0){let L=new t(v,{method:"POST",body:g,duplex:"half"}),O;if(le.isFormData(g)&&(O=L.headers.get("content-type"))&&D.setContentType(O),L.body){const[H,W]=fs(j,Mn(hs(T)));g=ds(L.body,ms,H,W)}}le.isString(X)||(X=X?"include":"omit");const P=a&&"credentials"in t.prototype,J=_e(he({},V),{signal:A,method:m.toUpperCase(),headers:D.normalize().toJSON(),body:g,duplex:"half",credentials:P?X:void 0});C=a&&new t(v,J);let $=yield a?E(C,V):E(v,J);const U=i&&(I==="stream"||I==="response");if(i&&(k||U&&F)){const L={};["status","statusText","headers"].forEach(Z=>{L[Z]=$[Z]});const O=le.toFiniteNumber($.headers.get("content-length")),[H,W]=k&&fs(O,Mn(hs(k),!0))||[];$=new n(ds($.body,ms,H,()=>{W&&W(),F&&F()}),L)}I=I||"text";let K=yield d[le.findKey(d,I)||"text"]($,h);return!U&&F&&F(),yield new Promise((L,O)=>{zu(L,O,{data:K,headers:Je.from($.headers),status:$.status,statusText:$.statusText,config:h,request:C})})}catch(P){throw F&&F(),P&&P.name==="TypeError"&&/Load failed|fetch/i.test(P.message)?Object.assign(new be("Network Error",be.ERR_NETWORK,h,C,P&&P.response),{cause:P.cause||P}):be.from(P,P&&P.code,h,C,P&&P.response)}})},Jd=new Map,Vu=e=>{let r=e&&e.env||{};const{fetch:t,Request:n,Response:l}=r,a=[n,l,t];let o=a.length,u=o,p,s,i=Jd;for(;u--;)p=a[u],s=i.get(p),s===void 0&&i.set(p,s=u?new Map:Zd(r)),i=s;return s};Vu();const ua={http:vd,xhr:Wd,fetch:{get:Vu}};le.forEach(ua,(e,r)=>{if(e){try{Object.defineProperty(e,"name",{value:r})}catch(t){}Object.defineProperty(e,"adapterName",{value:r})}});const xs=e=>`- ${e}`,e1=e=>le.isFunction(e)||e===null||e===!1;function t1(e,r){e=le.isArray(e)?e:[e];const{length:t}=e;let n,l;const a={};for(let o=0;o<t;o++){n=e[o];let u;if(l=n,!e1(n)&&(l=ua[(u=String(n)).toLowerCase()],l===void 0))throw new be(`Unknown adapter '${u}'`);if(l&&(le.isFunction(l)||(l=l.get(r))))break;a[u||"#"+o]=l}if(!l){const o=Object.entries(a).map(([p,s])=>`adapter ${p} `+(s===!1?"is not supported by the environment":"is not available in the build"));let u=t?o.length>1?`since :
4
+ `+r.prev}function hn(e,r){var t=No(e),n=[];if(t){n.length=e.length;for(var l=0;l<e.length;l++)n[l]=St(e,l)?r(e[l],e):""}var a=typeof _i=="function"?_i(e):[],o;if(gr){o={};for(var u=0;u<a.length;u++)o["$"+a[u]]=a[u]}for(var p in e)St(e,p)&&(t&&String(Number(p))===p&&p<e.length||gr&&o["$"+p]instanceof Symbol||(nu.call(/[^\w$]/,p)?n.push(r(p,e)+": "+r(e[p],e)):n.push(p+": "+r(e[p],e))));if(typeof _i=="function")for(var s=0;s<a.length;s++)iu.call(e,a[s])&&n.push("["+r(a[s])+"]: "+r(e[a[s]],e));return n}var cf=zn,ff=Ar,jn=function(e,r,t){for(var n=e,l;(l=n.next)!=null;n=l)if(l.key===r)return n.next=l.next,t||(l.next=e.next,e.next=l),l},hf=function(e,r){if(e){var t=jn(e,r);return t&&t.value}},pf=function(e,r,t){var n=jn(e,r);n?n.value=t:e.next={key:r,next:e.next,value:t}},df=function(e,r){return e?!!jn(e,r):!1},mf=function(e,r){if(e)return jn(e,r,!0)},vf=function(){var r,t={assert:function(n){if(!t.has(n))throw new ff("Side channel does not contain "+cf(n))},delete:function(n){var l=r&&r.next,a=mf(r,n);return a&&l&&l===a&&(r=void 0),!!a},get:function(n){return hf(r,n)},has:function(n){return df(r,n)},set:function(n,l){r||(r={next:void 0}),pf(r,n,l)}};return t},cu=Object,yf=Error,gf=EvalError,xf=RangeError,bf=ReferenceError,wf=SyntaxError,_f=URIError,Ef=Math.abs,Af=Math.floor,Cf=Math.max,Sf=Math.min,Bf=Math.pow,kf=Math.round,Tf=Number.isNaN||function(r){return r!==r},Ff=Tf,If=function(r){return Ff(r)||r===0?r:r<0?-1:1},Df=Object.getOwnPropertyDescriptor,Cn=Df;if(Cn)try{Cn([],"length")}catch(e){Cn=null}var fu=Cn,Sn=Object.defineProperty||!1;if(Sn)try{Sn({},"a",{value:1})}catch(e){Sn=!1}var Rf=Sn,Ai,Va;function Of(){return Va||(Va=1,Ai=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var r={},t=Symbol("test"),n=Object(t);if(typeof t=="string"||Object.prototype.toString.call(t)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var l=42;r[t]=l;for(var a in r)return!1;if(typeof Object.keys=="function"&&Object.keys(r).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(r).length!==0)return!1;var o=Object.getOwnPropertySymbols(r);if(o.length!==1||o[0]!==t||!Object.prototype.propertyIsEnumerable.call(r,t))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var u=Object.getOwnPropertyDescriptor(r,t);if(u.value!==l||u.enumerable!==!0)return!1}return!0}),Ai}var Ci,Wa;function Pf(){if(Wa)return Ci;Wa=1;var e=typeof Symbol!="undefined"&&Symbol,r=Of();return Ci=function(){return typeof e!="function"||typeof Symbol!="function"||typeof e("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:r()},Ci}var Si,Ka;function hu(){return Ka||(Ka=1,Si=typeof Reflect!="undefined"&&Reflect.getPrototypeOf||null),Si}var Bi,Ga;function pu(){if(Ga)return Bi;Ga=1;var e=cu;return Bi=e.getPrototypeOf||null,Bi}var ki,Qa;function Nf(){if(Qa)return ki;Qa=1;var e="Function.prototype.bind called on incompatible ",r=Object.prototype.toString,t=Math.max,n="[object Function]",l=function(p,s){for(var i=[],d=0;d<p.length;d+=1)i[d]=p[d];for(var c=0;c<s.length;c+=1)i[c+p.length]=s[c];return i},a=function(p,s){for(var i=[],d=s,c=0;d<p.length;d+=1,c+=1)i[c]=p[d];return i},o=function(u,p){for(var s="",i=0;i<u.length;i+=1)s+=u[i],i+1<u.length&&(s+=p);return s};return ki=function(p){var s=this;if(typeof s!="function"||r.apply(s)!==n)throw new TypeError(e+s);for(var i=a(arguments,1),d,c=function(){if(this instanceof d){var g=s.apply(this,l(i,arguments));return Object(g)===g?g:this}return s.apply(p,l(i,arguments))},f=t(0,s.length-i.length),h=[],v=0;v<f;v++)h[v]="$"+v;if(d=Function("binder","return function ("+o(h,",")+"){ return binder.apply(this,arguments); }")(c),s.prototype){var m=function(){};m.prototype=s.prototype,d.prototype=new m,m.prototype=null}return d},ki}var Ti,Ya;function Hn(){if(Ya)return Ti;Ya=1;var e=Nf();return Ti=Function.prototype.bind||e,Ti}var Fi,Xa;function ra(){return Xa||(Xa=1,Fi=Function.prototype.call),Fi}var Ii,Za;function du(){return Za||(Za=1,Ii=Function.prototype.apply),Ii}var Mf=typeof Reflect!="undefined"&&Reflect&&Reflect.apply,Lf=Hn(),Uf=du(),qf=ra(),$f=Mf,zf=$f||Lf.call(qf,Uf),jf=Hn(),Hf=Ar,Vf=ra(),Wf=zf,mu=function(r){if(r.length<1||typeof r[0]!="function")throw new Hf("a function is required");return Wf(jf,Vf,r)},Di,Ja;function Kf(){if(Ja)return Di;Ja=1;var e=mu,r=fu,t;try{t=[].__proto__===Array.prototype}catch(o){if(!o||typeof o!="object"||!("code"in o)||o.code!=="ERR_PROTO_ACCESS")throw o}var n=!!t&&r&&r(Object.prototype,"__proto__"),l=Object,a=l.getPrototypeOf;return Di=n&&typeof n.get=="function"?e([n.get]):typeof a=="function"?function(u){return a(u==null?u:l(u))}:!1,Di}var Ri,es;function Gf(){if(es)return Ri;es=1;var e=hu(),r=pu(),t=Kf();return Ri=e?function(l){return e(l)}:r?function(l){if(!l||typeof l!="object"&&typeof l!="function")throw new TypeError("getProto: not an object");return r(l)}:t?function(l){return t(l)}:null,Ri}var Oi,ts;function Qf(){if(ts)return Oi;ts=1;var e=Function.prototype.call,r=Object.prototype.hasOwnProperty,t=Hn();return Oi=t.call(e,r),Oi}var Ee,Yf=cu,Xf=yf,Zf=gf,Jf=xf,eh=bf,xr=wf,dr=Ar,th=_f,rh=Ef,nh=Af,ih=Cf,oh=Sf,ah=Bf,sh=kf,lh=If,vu=Function,Pi=function(e){try{return vu('"use strict"; return ('+e+").constructor;")()}catch(r){}},qr=fu,uh=Rf,Ni=function(){throw new dr},ch=qr?function(){try{return arguments.callee,Ni}catch(e){try{return qr(arguments,"callee").get}catch(r){return Ni}}}():Ni,sr=Pf()(),$e=Gf(),fh=pu(),hh=hu(),yu=du(),Vr=ra(),fr={},ph=typeof Uint8Array=="undefined"||!$e?Ee:$e(Uint8Array),Gt={__proto__:null,"%AggregateError%":typeof AggregateError=="undefined"?Ee:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer=="undefined"?Ee:ArrayBuffer,"%ArrayIteratorPrototype%":sr&&$e?$e([][Symbol.iterator]()):Ee,"%AsyncFromSyncIteratorPrototype%":Ee,"%AsyncFunction%":fr,"%AsyncGenerator%":fr,"%AsyncGeneratorFunction%":fr,"%AsyncIteratorPrototype%":fr,"%Atomics%":typeof Atomics=="undefined"?Ee:Atomics,"%BigInt%":typeof BigInt=="undefined"?Ee:BigInt,"%BigInt64Array%":typeof BigInt64Array=="undefined"?Ee:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array=="undefined"?Ee:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView=="undefined"?Ee:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Xf,"%eval%":eval,"%EvalError%":Zf,"%Float16Array%":typeof Float16Array=="undefined"?Ee:Float16Array,"%Float32Array%":typeof Float32Array=="undefined"?Ee:Float32Array,"%Float64Array%":typeof Float64Array=="undefined"?Ee:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry=="undefined"?Ee:FinalizationRegistry,"%Function%":vu,"%GeneratorFunction%":fr,"%Int8Array%":typeof Int8Array=="undefined"?Ee:Int8Array,"%Int16Array%":typeof Int16Array=="undefined"?Ee:Int16Array,"%Int32Array%":typeof Int32Array=="undefined"?Ee:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":sr&&$e?$e($e([][Symbol.iterator]())):Ee,"%JSON%":typeof JSON=="object"?JSON:Ee,"%Map%":typeof Map=="undefined"?Ee:Map,"%MapIteratorPrototype%":typeof Map=="undefined"||!sr||!$e?Ee:$e(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Yf,"%Object.getOwnPropertyDescriptor%":qr,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise=="undefined"?Ee:Promise,"%Proxy%":typeof Proxy=="undefined"?Ee:Proxy,"%RangeError%":Jf,"%ReferenceError%":eh,"%Reflect%":typeof Reflect=="undefined"?Ee:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set=="undefined"?Ee:Set,"%SetIteratorPrototype%":typeof Set=="undefined"||!sr||!$e?Ee:$e(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer=="undefined"?Ee:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":sr&&$e?$e(""[Symbol.iterator]()):Ee,"%Symbol%":sr?Symbol:Ee,"%SyntaxError%":xr,"%ThrowTypeError%":ch,"%TypedArray%":ph,"%TypeError%":dr,"%Uint8Array%":typeof Uint8Array=="undefined"?Ee:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray=="undefined"?Ee:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array=="undefined"?Ee:Uint16Array,"%Uint32Array%":typeof Uint32Array=="undefined"?Ee:Uint32Array,"%URIError%":th,"%WeakMap%":typeof WeakMap=="undefined"?Ee:WeakMap,"%WeakRef%":typeof WeakRef=="undefined"?Ee:WeakRef,"%WeakSet%":typeof WeakSet=="undefined"?Ee:WeakSet,"%Function.prototype.call%":Vr,"%Function.prototype.apply%":yu,"%Object.defineProperty%":uh,"%Object.getPrototypeOf%":fh,"%Math.abs%":rh,"%Math.floor%":nh,"%Math.max%":ih,"%Math.min%":oh,"%Math.pow%":ah,"%Math.round%":sh,"%Math.sign%":lh,"%Reflect.getPrototypeOf%":hh};if($e)try{null.error}catch(e){var dh=$e($e(e));Gt["%Error.prototype%"]=dh}var mh=function e(r){var t;if(r==="%AsyncFunction%")t=Pi("async function () {}");else if(r==="%GeneratorFunction%")t=Pi("function* () {}");else if(r==="%AsyncGeneratorFunction%")t=Pi("async function* () {}");else if(r==="%AsyncGenerator%"){var n=e("%AsyncGeneratorFunction%");n&&(t=n.prototype)}else if(r==="%AsyncIteratorPrototype%"){var l=e("%AsyncGenerator%");l&&$e&&(t=$e(l.prototype))}return Gt[r]=t,t},rs={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Wr=Hn(),Pn=Qf(),vh=Wr.call(Vr,Array.prototype.concat),yh=Wr.call(yu,Array.prototype.splice),ns=Wr.call(Vr,String.prototype.replace),Nn=Wr.call(Vr,String.prototype.slice),gh=Wr.call(Vr,RegExp.prototype.exec),xh=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,bh=/\\(\\)?/g,wh=function(r){var t=Nn(r,0,1),n=Nn(r,-1);if(t==="%"&&n!=="%")throw new xr("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&t!=="%")throw new xr("invalid intrinsic syntax, expected opening `%`");var l=[];return ns(r,xh,function(a,o,u,p){l[l.length]=u?ns(p,bh,"$1"):o||a}),l},_h=function(r,t){var n=r,l;if(Pn(rs,n)&&(l=rs[n],n="%"+l[0]+"%"),Pn(Gt,n)){var a=Gt[n];if(a===fr&&(a=mh(n)),typeof a=="undefined"&&!t)throw new dr("intrinsic "+r+" exists, but is not available. Please file an issue!");return{alias:l,name:n,value:a}}throw new xr("intrinsic "+r+" does not exist!")},na=function(r,t){if(typeof r!="string"||r.length===0)throw new dr("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof t!="boolean")throw new dr('"allowMissing" argument must be a boolean');if(gh(/^%?[^%]*%?$/,r)===null)throw new xr("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=wh(r),l=n.length>0?n[0]:"",a=_h("%"+l+"%",t),o=a.name,u=a.value,p=!1,s=a.alias;s&&(l=s[0],yh(n,vh([0,1],s)));for(var i=1,d=!0;i<n.length;i+=1){var c=n[i],f=Nn(c,0,1),h=Nn(c,-1);if((f==='"'||f==="'"||f==="`"||h==='"'||h==="'"||h==="`")&&f!==h)throw new xr("property names with quotes must have matching quotes");if((c==="constructor"||!d)&&(p=!0),l+="."+c,o="%"+l+"%",Pn(Gt,o))u=Gt[o];else if(u!=null){if(!(c in u)){if(!t)throw new dr("base intrinsic for "+r+" exists, but the property is not available.");return}if(qr&&i+1>=n.length){var v=qr(u,c);d=!!v,d&&"get"in v&&!("originalValue"in v.get)?u=v.get:u=u[c]}else d=Pn(u,c),u=u[c];d&&!p&&(Gt[o]=u)}}return u},gu=na,xu=mu,Eh=xu([gu("%String.prototype.indexOf%")]),bu=function(r,t){var n=gu(r,!!t);return typeof n=="function"&&Eh(r,".prototype.")>-1?xu([n]):n},Ah=na,Kr=bu,Ch=zn,Sh=Ar,is=Ah("%Map%",!0),Bh=Kr("Map.prototype.get",!0),kh=Kr("Map.prototype.set",!0),Th=Kr("Map.prototype.has",!0),Fh=Kr("Map.prototype.delete",!0),Ih=Kr("Map.prototype.size",!0),wu=!!is&&function(){var r,t={assert:function(n){if(!t.has(n))throw new Sh("Side channel does not contain "+Ch(n))},delete:function(n){if(r){var l=Fh(r,n);return Ih(r)===0&&(r=void 0),l}return!1},get:function(n){if(r)return Bh(r,n)},has:function(n){return r?Th(r,n):!1},set:function(n,l){r||(r=new is),kh(r,n,l)}};return t},Dh=na,Vn=bu,Rh=zn,pn=wu,Oh=Ar,lr=Dh("%WeakMap%",!0),Ph=Vn("WeakMap.prototype.get",!0),Nh=Vn("WeakMap.prototype.set",!0),Mh=Vn("WeakMap.prototype.has",!0),Lh=Vn("WeakMap.prototype.delete",!0),Uh=lr?function(){var r,t,n={assert:function(l){if(!n.has(l))throw new Oh("Side channel does not contain "+Rh(l))},delete:function(l){if(lr&&l&&(typeof l=="object"||typeof l=="function")){if(r)return Lh(r,l)}else if(pn&&t)return t.delete(l);return!1},get:function(l){return lr&&l&&(typeof l=="object"||typeof l=="function")&&r?Ph(r,l):t&&t.get(l)},has:function(l){return lr&&l&&(typeof l=="object"||typeof l=="function")&&r?Mh(r,l):!!t&&t.has(l)},set:function(l,a){lr&&l&&(typeof l=="object"||typeof l=="function")?(r||(r=new lr),Nh(r,l,a)):pn&&(t||(t=pn()),t.set(l,a))}};return n}:pn,qh=Ar,$h=zn,zh=vf,jh=wu,Hh=Uh,Vh=Hh||jh||zh,_u=function(){var r,t={assert:function(n){if(!t.has(n))throw new qh("Side channel does not contain "+$h(n))},delete:function(n){return!!r&&r.delete(n)},get:function(n){return r&&r.get(n)},has:function(n){return!!r&&r.has(n)},set:function(n,l){r||(r=Vh()),r.set(n,l)}};return t},Wh=String.prototype.replace,Kh=/%20/g,Mi={RFC1738:"RFC1738",RFC3986:"RFC3986"},ia={default:Mi.RFC3986,formatters:{RFC1738:function(e){return Wh.call(e,Kh,"+")},RFC3986:function(e){return String(e)}},RFC1738:Mi.RFC1738,RFC3986:Mi.RFC3986},Gh=ia,Qh=_u,Li=Object.prototype.hasOwnProperty,Ht=Array.isArray,Wn=Qh(),pr=function(r,t){return Wn.set(r,t),r},Vt=function(r){return Wn.has(r)},Dr=function(r){return Wn.get(r)},Lo=function(r,t){Wn.set(r,t)},vt=function(){for(var e=[],r=0;r<256;++r)e[e.length]="%"+((r<16?"0":"")+r.toString(16)).toUpperCase();return e}(),Yh=function(r){for(;r.length>1;){var t=r.pop(),n=t.obj[t.prop];if(Ht(n)){for(var l=[],a=0;a<n.length;++a)typeof n[a]!="undefined"&&(l[l.length]=n[a]);t.obj[t.prop]=l}}},Lr=function(r,t){for(var n=t&&t.plainObjects?{__proto__:null}:{},l=0;l<r.length;++l)typeof r[l]!="undefined"&&(n[l]=r[l]);return n},Xh=function e(r,t,n){if(!t)return r;if(typeof t!="object"&&typeof t!="function"){if(Ht(r)){var l=r.length;if(n&&typeof n.arrayLimit=="number"&&l>n.arrayLimit)return pr(Lr(r.concat(t),n),l);r[l]=t}else if(r&&typeof r=="object")if(Vt(r)){var a=Dr(r)+1;r[a]=t,Lo(r,a)}else(n&&(n.plainObjects||n.allowPrototypes)||!Li.call(Object.prototype,t))&&(r[t]=!0);else return[r,t];return r}if(!r||typeof r!="object"){if(Vt(t)){for(var o=Object.keys(t),u=n&&n.plainObjects?{__proto__:null,0:r}:{0:r},p=0;p<o.length;p++){var s=parseInt(o[p],10);u[s+1]=t[o[p]]}return pr(u,Dr(t)+1)}var i=[r].concat(t);return n&&typeof n.arrayLimit=="number"&&i.length>n.arrayLimit?pr(Lr(i,n),i.length-1):i}var d=r;return Ht(r)&&!Ht(t)&&(d=Lr(r,n)),Ht(r)&&Ht(t)?(t.forEach(function(c,f){if(Li.call(r,f)){var h=r[f];h&&typeof h=="object"&&c&&typeof c=="object"?r[f]=e(h,c,n):r[r.length]=c}else r[f]=c}),r):Object.keys(t).reduce(function(c,f){var h=t[f];if(Li.call(c,f)?c[f]=e(c[f],h,n):c[f]=h,Vt(t)&&!Vt(c)&&pr(c,Dr(t)),Vt(c)){var v=parseInt(f,10);String(v)===f&&v>=0&&v>Dr(c)&&Lo(c,v)}return c},d)},Zh=function(r,t){return Object.keys(t).reduce(function(n,l){return n[l]=t[l],n},r)},Jh=function(e,r,t){var n=e.replace(/\+/g," ");if(t==="iso-8859-1")return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch(l){return n}},Ui=1024,ep=function(r,t,n,l,a){if(r.length===0)return r;var o=r;if(typeof r=="symbol"?o=Symbol.prototype.toString.call(r):typeof r!="string"&&(o=String(r)),n==="iso-8859-1")return escape(o).replace(/%u[0-9a-f]{4}/gi,function(f){return"%26%23"+parseInt(f.slice(2),16)+"%3B"});for(var u="",p=0;p<o.length;p+=Ui){for(var s=o.length>=Ui?o.slice(p,p+Ui):o,i=[],d=0;d<s.length;++d){var c=s.charCodeAt(d);if(c===45||c===46||c===95||c===126||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122||a===Gh.RFC1738&&(c===40||c===41)){i[i.length]=s.charAt(d);continue}if(c<128){i[i.length]=vt[c];continue}if(c<2048){i[i.length]=vt[192|c>>6]+vt[128|c&63];continue}if(c<55296||c>=57344){i[i.length]=vt[224|c>>12]+vt[128|c>>6&63]+vt[128|c&63];continue}d+=1,c=65536+((c&1023)<<10|s.charCodeAt(d)&1023),i[i.length]=vt[240|c>>18]+vt[128|c>>12&63]+vt[128|c>>6&63]+vt[128|c&63]}u+=i.join("")}return u},tp=function(r){for(var t=[{obj:{o:r},prop:"o"}],n=[],l=0;l<t.length;++l)for(var a=t[l],o=a.obj[a.prop],u=Object.keys(o),p=0;p<u.length;++p){var s=u[p],i=o[s];typeof i=="object"&&i!==null&&n.indexOf(i)===-1&&(t[t.length]={obj:o,prop:s},n[n.length]=i)}return Yh(t),r},rp=function(r){return Object.prototype.toString.call(r)==="[object RegExp]"},np=function(r){return!r||typeof r!="object"?!1:!!(r.constructor&&r.constructor.isBuffer&&r.constructor.isBuffer(r))},ip=function(r,t,n,l){if(Vt(r)){var a=Dr(r)+1;return r[a]=t,Lo(r,a),r}var o=[].concat(r,t);return o.length>n?pr(Lr(o,{plainObjects:l}),o.length-1):o},op=function(r,t){if(Ht(r)){for(var n=[],l=0;l<r.length;l+=1)n[n.length]=t(r[l]);return n}return t(r)},Eu={arrayToObject:Lr,assign:Zh,combine:ip,compact:tp,decode:Jh,encode:ep,isBuffer:np,isOverflow:Vt,isRegExp:rp,markOverflow:pr,maybeMap:op,merge:Xh},Au=_u,Bn=Eu,Ur=ia,ap=Object.prototype.hasOwnProperty,Cu={brackets:function(r){return r+"[]"},comma:"comma",indices:function(r,t){return r+"["+t+"]"},repeat:function(r){return r}},xt=Array.isArray,sp=Array.prototype.push,Su=function(e,r){sp.apply(e,xt(r)?r:[r])},lp=Date.prototype.toISOString,os=Ur.default,Ne={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,commaRoundTrip:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:Bn.encode,encodeValuesOnly:!1,filter:void 0,format:os,formatter:Ur.formatters[os],indices:!1,serializeDate:function(r){return lp.call(r)},skipNulls:!1,strictNullHandling:!1},up=function(r){return typeof r=="string"||typeof r=="number"||typeof r=="boolean"||typeof r=="symbol"||typeof r=="bigint"},qi={},cp=function e(r,t,n,l,a,o,u,p,s,i,d,c,f,h,v,m,g,x){for(var y=r,w=x,k=0,T=!1;(w=w.get(qi))!==void 0&&!T;){var I=w.get(r);if(k+=1,typeof I!="undefined"){if(I===k)throw new RangeError("Cyclic object value");T=!0}typeof w.get(qi)=="undefined"&&(k=0)}if(typeof i=="function"?y=i(t,y):y instanceof Date?y=f(y):n==="comma"&&xt(y)&&(y=Bn.maybeMap(y,function(K){return K instanceof Date?f(K):K})),y===null){if(o)return s&&!m?s(t,Ne.encoder,g,"key",h):t;y=""}if(up(y)||Bn.isBuffer(y)){if(s){var D=m?t:s(t,Ne.encoder,g,"key",h);return[v(D)+"="+v(s(y,Ne.encoder,g,"value",h))]}return[v(t)+"="+v(String(y))]}var X=[];if(typeof y=="undefined")return X;var V;if(n==="comma"&&xt(y))m&&s&&(y=Bn.maybeMap(y,s)),V=[{value:y.length>0?y.join(",")||null:void 0}];else if(xt(i))V=i;else{var E=Object.keys(y);V=d?E.sort(d):E}var A=p?String(t).replace(/\./g,"%2E"):String(t),C=l&&xt(y)&&y.length===1?A+"[]":A;if(a&&xt(y)&&y.length===0)return C+"[]";for(var F=0;F<V.length;++F){var j=V[F],P=typeof j=="object"&&j&&typeof j.value!="undefined"?j.value:y[j];if(!(u&&P===null)){var J=c&&p?String(j).replace(/\./g,"%2E"):String(j),$=xt(y)?typeof n=="function"?n(C,J):C:C+(c?"."+J:"["+J+"]");x.set(r,k);var U=Au();U.set(qi,x),Su(X,e(P,$,n,l,a,o,u,p,n==="comma"&&m&&xt(y)?null:s,i,d,c,f,h,v,m,g,U))}}return X},fp=function(r){if(!r)return Ne;if(typeof r.allowEmptyArrays!="undefined"&&typeof r.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof r.encodeDotInKeys!="undefined"&&typeof r.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(r.encoder!==null&&typeof r.encoder!="undefined"&&typeof r.encoder!="function")throw new TypeError("Encoder has to be a function.");var t=r.charset||Ne.charset;if(typeof r.charset!="undefined"&&r.charset!=="utf-8"&&r.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=Ur.default;if(typeof r.format!="undefined"){if(!ap.call(Ur.formatters,r.format))throw new TypeError("Unknown format option provided.");n=r.format}var l=Ur.formatters[n],a=Ne.filter;(typeof r.filter=="function"||xt(r.filter))&&(a=r.filter);var o;if(r.arrayFormat in Cu?o=r.arrayFormat:"indices"in r?o=r.indices?"indices":"repeat":o=Ne.arrayFormat,"commaRoundTrip"in r&&typeof r.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var u=typeof r.allowDots=="undefined"?r.encodeDotInKeys===!0?!0:Ne.allowDots:!!r.allowDots;return{addQueryPrefix:typeof r.addQueryPrefix=="boolean"?r.addQueryPrefix:Ne.addQueryPrefix,allowDots:u,allowEmptyArrays:typeof r.allowEmptyArrays=="boolean"?!!r.allowEmptyArrays:Ne.allowEmptyArrays,arrayFormat:o,charset:t,charsetSentinel:typeof r.charsetSentinel=="boolean"?r.charsetSentinel:Ne.charsetSentinel,commaRoundTrip:!!r.commaRoundTrip,delimiter:typeof r.delimiter=="undefined"?Ne.delimiter:r.delimiter,encode:typeof r.encode=="boolean"?r.encode:Ne.encode,encodeDotInKeys:typeof r.encodeDotInKeys=="boolean"?r.encodeDotInKeys:Ne.encodeDotInKeys,encoder:typeof r.encoder=="function"?r.encoder:Ne.encoder,encodeValuesOnly:typeof r.encodeValuesOnly=="boolean"?r.encodeValuesOnly:Ne.encodeValuesOnly,filter:a,format:n,formatter:l,serializeDate:typeof r.serializeDate=="function"?r.serializeDate:Ne.serializeDate,skipNulls:typeof r.skipNulls=="boolean"?r.skipNulls:Ne.skipNulls,sort:typeof r.sort=="function"?r.sort:null,strictNullHandling:typeof r.strictNullHandling=="boolean"?r.strictNullHandling:Ne.strictNullHandling}},hp=function(e,r){var t=e,n=fp(r),l,a;typeof n.filter=="function"?(a=n.filter,t=a("",t)):xt(n.filter)&&(a=n.filter,l=a);var o=[];if(typeof t!="object"||t===null)return"";var u=Cu[n.arrayFormat],p=u==="comma"&&n.commaRoundTrip;l||(l=Object.keys(t)),n.sort&&l.sort(n.sort);for(var s=Au(),i=0;i<l.length;++i){var d=l[i],c=t[d];n.skipNulls&&c===null||Su(o,cp(c,d,u,p,n.allowEmptyArrays,n.strictNullHandling,n.skipNulls,n.encodeDotInKeys,n.encode?n.encoder:null,n.filter,n.sort,n.allowDots,n.serializeDate,n.format,n.formatter,n.encodeValuesOnly,n.charset,s))}var f=o.join(n.delimiter),h=n.addQueryPrefix===!0?"?":"";return n.charsetSentinel&&(n.charset==="iso-8859-1"?h+="utf8=%26%2310003%3B&":h+="utf8=%E2%9C%93&"),f.length>0?h+f:""},_t=Eu,kn=Object.prototype.hasOwnProperty,$i=Array.isArray,De={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:_t.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictNullHandling:!1,throwOnLimitExceeded:!1},pp=function(e){return e.replace(/&#(\d+);/g,function(r,t){return String.fromCharCode(parseInt(t,10))})},Bu=function(e,r,t){if(e&&typeof e=="string"&&r.comma&&e.indexOf(",")>-1)return e.split(",");if(r.throwOnLimitExceeded&&t>=r.arrayLimit)throw new RangeError("Array limit exceeded. Only "+r.arrayLimit+" element"+(r.arrayLimit===1?"":"s")+" allowed in an array.");return e},dp="utf8=%26%2310003%3B",mp="utf8=%E2%9C%93",vp=function(r,t){var n={__proto__:null},l=t.ignoreQueryPrefix?r.replace(/^\?/,""):r;l=l.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var a=t.parameterLimit===1/0?void 0:t.parameterLimit,o=l.split(t.delimiter,t.throwOnLimitExceeded?a+1:a);if(t.throwOnLimitExceeded&&o.length>a)throw new RangeError("Parameter limit exceeded. Only "+a+" parameter"+(a===1?"":"s")+" allowed.");var u=-1,p,s=t.charset;if(t.charsetSentinel)for(p=0;p<o.length;++p)o[p].indexOf("utf8=")===0&&(o[p]===mp?s="utf-8":o[p]===dp&&(s="iso-8859-1"),u=p,p=o.length);for(p=0;p<o.length;++p)if(p!==u){var i=o[p],d=i.indexOf("]="),c=d===-1?i.indexOf("="):d+1,f,h;if(c===-1?(f=t.decoder(i,De.decoder,s,"key"),h=t.strictNullHandling?null:""):(f=t.decoder(i.slice(0,c),De.decoder,s,"key"),f!==null&&(h=_t.maybeMap(Bu(i.slice(c+1),t,$i(n[f])?n[f].length:0),function(m){return t.decoder(m,De.decoder,s,"value")}))),h&&t.interpretNumericEntities&&s==="iso-8859-1"&&(h=pp(String(h))),i.indexOf("[]=")>-1&&(h=$i(h)?[h]:h),t.comma&&$i(h)&&h.length>t.arrayLimit){if(t.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(t.arrayLimit===1?"":"s")+" allowed in an array.");h=_t.combine([],h,t.arrayLimit,t.plainObjects)}if(f!==null){var v=kn.call(n,f);v&&t.duplicates==="combine"?n[f]=_t.combine(n[f],h,t.arrayLimit,t.plainObjects):(!v||t.duplicates==="last")&&(n[f]=h)}}return n},yp=function(e,r,t,n){var l=0;if(e.length>0&&e[e.length-1]==="[]"){var a=e.slice(0,-1).join("");l=Array.isArray(r)&&r[a]?r[a].length:0}for(var o=n?r:Bu(r,t,l),u=e.length-1;u>=0;--u){var p,s=e[u];if(s==="[]"&&t.parseArrays)_t.isOverflow(o)?p=o:p=t.allowEmptyArrays&&(o===""||t.strictNullHandling&&o===null)?[]:_t.combine([],o,t.arrayLimit,t.plainObjects);else{p=t.plainObjects?{__proto__:null}:{};var i=s.charAt(0)==="["&&s.charAt(s.length-1)==="]"?s.slice(1,-1):s,d=t.decodeDotInKeys?i.replace(/%2E/g,"."):i,c=parseInt(d,10),f=!isNaN(c)&&s!==d&&String(c)===d&&c>=0&&t.parseArrays;if(!t.parseArrays&&d==="")p={0:o};else if(f&&c<t.arrayLimit)p=[],p[c]=o;else{if(f&&t.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+t.arrayLimit+" element"+(t.arrayLimit===1?"":"s")+" allowed in an array.");f?(p[c]=o,_t.markOverflow(p,c)):d!=="__proto__"&&(p[d]=o)}}o=p}return o},gp=function(r,t){var n=t.allowDots?r.replace(/\.([^.[]+)/g,"[$1]"):r;if(t.depth<=0)return!t.plainObjects&&kn.call(Object.prototype,n)&&!t.allowPrototypes?void 0:[n];var l=/(\[[^[\]]*])/,a=/(\[[^[\]]*])/g,o=l.exec(n),u=o?n.slice(0,o.index):n,p=[];if(u){if(!t.plainObjects&&kn.call(Object.prototype,u)&&!t.allowPrototypes)return;p[p.length]=u}for(var s=0;(o=a.exec(n))!==null&&s<t.depth;){s+=1;var i=o[1].slice(1,-1);if(!t.plainObjects&&kn.call(Object.prototype,i)&&!t.allowPrototypes)return;p[p.length]=o[1]}if(o){if(t.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+t.depth+" and strictDepth is true");p[p.length]="["+n.slice(o.index)+"]"}return p},xp=function(r,t,n,l){if(r){var a=gp(r,n);if(a)return yp(a,t,n,l)}},bp=function(r){if(!r)return De;if(typeof r.allowEmptyArrays!="undefined"&&typeof r.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof r.decodeDotInKeys!="undefined"&&typeof r.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(r.decoder!==null&&typeof r.decoder!="undefined"&&typeof r.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof r.charset!="undefined"&&r.charset!=="utf-8"&&r.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");if(typeof r.throwOnLimitExceeded!="undefined"&&typeof r.throwOnLimitExceeded!="boolean")throw new TypeError("`throwOnLimitExceeded` option must be a boolean");var t=typeof r.charset=="undefined"?De.charset:r.charset,n=typeof r.duplicates=="undefined"?De.duplicates:r.duplicates;if(n!=="combine"&&n!=="first"&&n!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var l=typeof r.allowDots=="undefined"?r.decodeDotInKeys===!0?!0:De.allowDots:!!r.allowDots;return{allowDots:l,allowEmptyArrays:typeof r.allowEmptyArrays=="boolean"?!!r.allowEmptyArrays:De.allowEmptyArrays,allowPrototypes:typeof r.allowPrototypes=="boolean"?r.allowPrototypes:De.allowPrototypes,allowSparse:typeof r.allowSparse=="boolean"?r.allowSparse:De.allowSparse,arrayLimit:typeof r.arrayLimit=="number"?r.arrayLimit:De.arrayLimit,charset:t,charsetSentinel:typeof r.charsetSentinel=="boolean"?r.charsetSentinel:De.charsetSentinel,comma:typeof r.comma=="boolean"?r.comma:De.comma,decodeDotInKeys:typeof r.decodeDotInKeys=="boolean"?r.decodeDotInKeys:De.decodeDotInKeys,decoder:typeof r.decoder=="function"?r.decoder:De.decoder,delimiter:typeof r.delimiter=="string"||_t.isRegExp(r.delimiter)?r.delimiter:De.delimiter,depth:typeof r.depth=="number"||r.depth===!1?+r.depth:De.depth,duplicates:n,ignoreQueryPrefix:r.ignoreQueryPrefix===!0,interpretNumericEntities:typeof r.interpretNumericEntities=="boolean"?r.interpretNumericEntities:De.interpretNumericEntities,parameterLimit:typeof r.parameterLimit=="number"?r.parameterLimit:De.parameterLimit,parseArrays:r.parseArrays!==!1,plainObjects:typeof r.plainObjects=="boolean"?r.plainObjects:De.plainObjects,strictDepth:typeof r.strictDepth=="boolean"?!!r.strictDepth:De.strictDepth,strictNullHandling:typeof r.strictNullHandling=="boolean"?r.strictNullHandling:De.strictNullHandling,throwOnLimitExceeded:typeof r.throwOnLimitExceeded=="boolean"?r.throwOnLimitExceeded:!1}},wp=function(e,r){var t=bp(r);if(e===""||e===null||typeof e=="undefined")return t.plainObjects?{__proto__:null}:{};for(var n=typeof e=="string"?vp(e,t):e,l=t.plainObjects?{__proto__:null}:{},a=Object.keys(n),o=0;o<a.length;++o){var u=a[o],p=xp(u,n[u],t,typeof e=="string");l=_t.merge(l,p,t)}return t.allowSparse===!0?l:_t.compact(l)},_p=hp,Ep=wp,Ap=ia,Cp={formats:Ap,parse:Ep,stringify:_p};const Sp=Zo(Cp);function ku(e,r){return function(){return e.apply(r,arguments)}}const{toString:Bp}=Object.prototype,{getPrototypeOf:oa}=Object,{iterator:Kn,toStringTag:Tu}=Symbol,Gn=(e=>r=>{const t=Bp.call(r);return e[t]||(e[t]=t.slice(8,-1).toLowerCase())})(Object.create(null)),pt=e=>(e=e.toLowerCase(),r=>Gn(r)===e),Qn=e=>r=>typeof r===e,{isArray:Cr}=Array,br=Qn("undefined");function Gr(e){return e!==null&&!br(e)&&e.constructor!==null&&!br(e.constructor)&&Ze(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Fu=pt("ArrayBuffer");function kp(e){let r;return typeof ArrayBuffer!="undefined"&&ArrayBuffer.isView?r=ArrayBuffer.isView(e):r=e&&e.buffer&&Fu(e.buffer),r}const Tp=Qn("string"),Ze=Qn("function"),Iu=Qn("number"),Qr=e=>e!==null&&typeof e=="object",Fp=e=>e===!0||e===!1,Tn=e=>{if(Gn(e)!=="object")return!1;const r=oa(e);return(r===null||r===Object.prototype||Object.getPrototypeOf(r)===null)&&!(Tu in e)&&!(Kn in e)},Ip=e=>{if(!Qr(e)||Gr(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch(r){return!1}},Dp=pt("Date"),Rp=pt("File"),Op=pt("Blob"),Pp=pt("FileList"),Np=e=>Qr(e)&&Ze(e.pipe),Mp=e=>{let r;return e&&(typeof FormData=="function"&&e instanceof FormData||Ze(e.append)&&((r=Gn(e))==="formdata"||r==="object"&&Ze(e.toString)&&e.toString()==="[object FormData]"))},Lp=pt("URLSearchParams"),[Up,qp,$p,zp]=["ReadableStream","Request","Response","Headers"].map(pt),jp=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Yr(e,r,{allOwnKeys:t=!1}={}){if(e===null||typeof e=="undefined")return;let n,l;if(typeof e!="object"&&(e=[e]),Cr(e))for(n=0,l=e.length;n<l;n++)r.call(null,e[n],n,e);else{if(Gr(e))return;const a=t?Object.getOwnPropertyNames(e):Object.keys(e),o=a.length;let u;for(n=0;n<o;n++)u=a[n],r.call(null,e[u],u,e)}}function Du(e,r){if(Gr(e))return null;r=r.toLowerCase();const t=Object.keys(e);let n=t.length,l;for(;n-- >0;)if(l=t[n],r===l.toLowerCase())return l;return null}const Wt=typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:typeof window!="undefined"?window:global,Ru=e=>!br(e)&&e!==Wt;function Uo(){const{caseless:e,skipUndefined:r}=Ru(this)&&this||{},t={},n=(l,a)=>{if(a==="__proto__"||a==="constructor"||a==="prototype")return;const o=e&&Du(t,a)||a;Tn(t[o])&&Tn(l)?t[o]=Uo(t[o],l):Tn(l)?t[o]=Uo({},l):Cr(l)?t[o]=l.slice():(!r||!br(l))&&(t[o]=l)};for(let l=0,a=arguments.length;l<a;l++)arguments[l]&&Yr(arguments[l],n);return t}const Hp=(e,r,t,{allOwnKeys:n}={})=>(Yr(r,(l,a)=>{t&&Ze(l)?Object.defineProperty(e,a,{value:ku(l,t),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,a,{value:l,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),e),Vp=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Wp=(e,r,t,n)=>{e.prototype=Object.create(r.prototype,n),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:r.prototype}),t&&Object.assign(e.prototype,t)},Kp=(e,r,t,n)=>{let l,a,o;const u={};if(r=r||{},e==null)return r;do{for(l=Object.getOwnPropertyNames(e),a=l.length;a-- >0;)o=l[a],(!n||n(o,e,r))&&!u[o]&&(r[o]=e[o],u[o]=!0);e=t!==!1&&oa(e)}while(e&&(!t||t(e,r))&&e!==Object.prototype);return r},Gp=(e,r,t)=>{e=String(e),(t===void 0||t>e.length)&&(t=e.length),t-=r.length;const n=e.indexOf(r,t);return n!==-1&&n===t},Qp=e=>{if(!e)return null;if(Cr(e))return e;let r=e.length;if(!Iu(r))return null;const t=new Array(r);for(;r-- >0;)t[r]=e[r];return t},Yp=(e=>r=>e&&r instanceof e)(typeof Uint8Array!="undefined"&&oa(Uint8Array)),Xp=(e,r)=>{const n=(e&&e[Kn]).call(e);let l;for(;(l=n.next())&&!l.done;){const a=l.value;r.call(e,a[0],a[1])}},Zp=(e,r)=>{let t;const n=[];for(;(t=e.exec(r))!==null;)n.push(t);return n},Jp=pt("HTMLFormElement"),ed=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(t,n,l){return n.toUpperCase()+l}),as=(({hasOwnProperty:e})=>(r,t)=>e.call(r,t))(Object.prototype),td=pt("RegExp"),Ou=(e,r)=>{const t=Object.getOwnPropertyDescriptors(e),n={};Yr(t,(l,a)=>{let o;(o=r(l,a,e))!==!1&&(n[a]=o||l)}),Object.defineProperties(e,n)},rd=e=>{Ou(e,(r,t)=>{if(Ze(e)&&["arguments","caller","callee"].indexOf(t)!==-1)return!1;const n=e[t];if(Ze(n)){if(r.enumerable=!1,"writable"in r){r.writable=!1;return}r.set||(r.set=()=>{throw Error("Can not rewrite read-only method '"+t+"'")})}})},nd=(e,r)=>{const t={},n=l=>{l.forEach(a=>{t[a]=!0})};return Cr(e)?n(e):n(String(e).split(r)),t},id=()=>{},od=(e,r)=>e!=null&&Number.isFinite(e=+e)?e:r;function ad(e){return!!(e&&Ze(e.append)&&e[Tu]==="FormData"&&e[Kn])}const sd=e=>{const r=new Array(10),t=(n,l)=>{if(Qr(n)){if(r.indexOf(n)>=0)return;if(Gr(n))return n;if(!("toJSON"in n)){r[l]=n;const a=Cr(n)?[]:{};return Yr(n,(o,u)=>{const p=t(o,l+1);!br(p)&&(a[u]=p)}),r[l]=void 0,a}}return n};return t(e,0)},ld=pt("AsyncFunction"),ud=e=>e&&(Qr(e)||Ze(e))&&Ze(e.then)&&Ze(e.catch),Pu=((e,r)=>e?setImmediate:r?((t,n)=>(Wt.addEventListener("message",({source:l,data:a})=>{l===Wt&&a===t&&n.length&&n.shift()()},!1),l=>{n.push(l),Wt.postMessage(t,"*")}))(`axios@${Math.random()}`,[]):t=>setTimeout(t))(typeof setImmediate=="function",Ze(Wt.postMessage)),cd=typeof queueMicrotask!="undefined"?queueMicrotask.bind(Wt):typeof process!="undefined"&&process.nextTick||Pu,fd=e=>e!=null&&Ze(e[Kn]),le={isArray:Cr,isArrayBuffer:Fu,isBuffer:Gr,isFormData:Mp,isArrayBufferView:kp,isString:Tp,isNumber:Iu,isBoolean:Fp,isObject:Qr,isPlainObject:Tn,isEmptyObject:Ip,isReadableStream:Up,isRequest:qp,isResponse:$p,isHeaders:zp,isUndefined:br,isDate:Dp,isFile:Rp,isBlob:Op,isRegExp:td,isFunction:Ze,isStream:Np,isURLSearchParams:Lp,isTypedArray:Yp,isFileList:Pp,forEach:Yr,merge:Uo,extend:Hp,trim:jp,stripBOM:Vp,inherits:Wp,toFlatObject:Kp,kindOf:Gn,kindOfTest:pt,endsWith:Gp,toArray:Qp,forEachEntry:Xp,matchAll:Zp,isHTMLForm:Jp,hasOwnProperty:as,hasOwnProp:as,reduceDescriptors:Ou,freezeMethods:rd,toObjectSet:nd,toCamelCase:ed,noop:id,toFiniteNumber:od,findKey:Du,global:Wt,isContextDefined:Ru,isSpecCompliantForm:ad,toJSONObject:sd,isAsyncFn:ld,isThenable:ud,setImmediate:Pu,asap:cd,isIterable:fd};let be=class Nu extends Error{static from(r,t,n,l,a,o){const u=new Nu(r.message,t||r.code,n,l,a);return u.cause=r,u.name=r.name,o&&Object.assign(u,o),u}constructor(r,t,n,l,a){super(r),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),n&&(this.config=n),l&&(this.request=l),a&&(this.response=a,this.status=a.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:le.toJSONObject(this.config),code:this.code,status:this.status}}};be.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";be.ERR_BAD_OPTION="ERR_BAD_OPTION";be.ECONNABORTED="ECONNABORTED";be.ETIMEDOUT="ETIMEDOUT";be.ERR_NETWORK="ERR_NETWORK";be.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";be.ERR_DEPRECATED="ERR_DEPRECATED";be.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";be.ERR_BAD_REQUEST="ERR_BAD_REQUEST";be.ERR_CANCELED="ERR_CANCELED";be.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";be.ERR_INVALID_URL="ERR_INVALID_URL";const hd=null;function qo(e){return le.isPlainObject(e)||le.isArray(e)}function Mu(e){return le.endsWith(e,"[]")?e.slice(0,-2):e}function ss(e,r,t){return e?e.concat(r).map(function(l,a){return l=Mu(l),!t&&a?"["+l+"]":l}).join(t?".":""):r}function pd(e){return le.isArray(e)&&!e.some(qo)}const dd=le.toFlatObject(le,{},null,function(r){return/^is[A-Z]/.test(r)});function Yn(e,r,t){if(!le.isObject(e))throw new TypeError("target must be an object");r=r||new FormData,t=le.toFlatObject(t,{metaTokens:!0,dots:!1,indexes:!1},!1,function(v,m){return!le.isUndefined(m[v])});const n=t.metaTokens,l=t.visitor||i,a=t.dots,o=t.indexes,p=(t.Blob||typeof Blob!="undefined"&&Blob)&&le.isSpecCompliantForm(r);if(!le.isFunction(l))throw new TypeError("visitor must be a function");function s(h){if(h===null)return"";if(le.isDate(h))return h.toISOString();if(le.isBoolean(h))return h.toString();if(!p&&le.isBlob(h))throw new be("Blob is not supported. Use a Buffer instead.");return le.isArrayBuffer(h)||le.isTypedArray(h)?p&&typeof Blob=="function"?new Blob([h]):Buffer.from(h):h}function i(h,v,m){let g=h;if(h&&!m&&typeof h=="object"){if(le.endsWith(v,"{}"))v=n?v:v.slice(0,-2),h=JSON.stringify(h);else if(le.isArray(h)&&pd(h)||(le.isFileList(h)||le.endsWith(v,"[]"))&&(g=le.toArray(h)))return v=Mu(v),g.forEach(function(y,w){!(le.isUndefined(y)||y===null)&&r.append(o===!0?ss([v],w,a):o===null?v:v+"[]",s(y))}),!1}return qo(h)?!0:(r.append(ss(m,v,a),s(h)),!1)}const d=[],c=Object.assign(dd,{defaultVisitor:i,convertValue:s,isVisitable:qo});function f(h,v){if(!le.isUndefined(h)){if(d.indexOf(h)!==-1)throw Error("Circular reference detected in "+v.join("."));d.push(h),le.forEach(h,function(g,x){(!(le.isUndefined(g)||g===null)&&l.call(r,g,le.isString(x)?x.trim():x,v,c))===!0&&f(g,v?v.concat(x):[x])}),d.pop()}}if(!le.isObject(e))throw new TypeError("data must be an object");return f(e),r}function ls(e){const r={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(n){return r[n]})}function aa(e,r){this._pairs=[],e&&Yn(e,this,r)}const Lu=aa.prototype;Lu.append=function(r,t){this._pairs.push([r,t])};Lu.toString=function(r){const t=r?function(n){return r.call(this,n,ls)}:ls;return this._pairs.map(function(l){return t(l[0])+"="+t(l[1])},"").join("&")};function md(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Uu(e,r,t){if(!r)return e;const n=t&&t.encode||md,l=le.isFunction(t)?{serialize:t}:t,a=l&&l.serialize;let o;if(a?o=a(r,l):o=le.isURLSearchParams(r)?r.toString():new aa(r,l).toString(n),o){const u=e.indexOf("#");u!==-1&&(e=e.slice(0,u)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class us{constructor(){this.handlers=[]}use(r,t,n){return this.handlers.push({fulfilled:r,rejected:t,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(r){this.handlers[r]&&(this.handlers[r]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(r){le.forEach(this.handlers,function(n){n!==null&&r(n)})}}const sa={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},vd=typeof URLSearchParams!="undefined"?URLSearchParams:aa,yd=typeof FormData!="undefined"?FormData:null,gd=typeof Blob!="undefined"?Blob:null,xd={isBrowser:!0,classes:{URLSearchParams:vd,FormData:yd,Blob:gd},protocols:["http","https","file","blob","url","data"]},la=typeof window!="undefined"&&typeof document!="undefined",$o=typeof navigator=="object"&&navigator||void 0,bd=la&&(!$o||["ReactNative","NativeScript","NS"].indexOf($o.product)<0),wd=typeof WorkerGlobalScope!="undefined"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",_d=la&&window.location.href||"http://localhost",Ed=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:la,hasStandardBrowserEnv:bd,hasStandardBrowserWebWorkerEnv:wd,navigator:$o,origin:_d},Symbol.toStringTag,{value:"Module"})),Ke=he(he({},Ed),xd);function Ad(e,r){return Yn(e,new Ke.classes.URLSearchParams,he({visitor:function(t,n,l,a){return Ke.isNode&&le.isBuffer(t)?(this.append(n,t.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},r))}function Cd(e){return le.matchAll(/\w+|\[(\w*)]/g,e).map(r=>r[0]==="[]"?"":r[1]||r[0])}function Sd(e){const r={},t=Object.keys(e);let n;const l=t.length;let a;for(n=0;n<l;n++)a=t[n],r[a]=e[a];return r}function qu(e){function r(t,n,l,a){let o=t[a++];if(o==="__proto__")return!0;const u=Number.isFinite(+o),p=a>=t.length;return o=!o&&le.isArray(l)?l.length:o,p?(le.hasOwnProp(l,o)?l[o]=[l[o],n]:l[o]=n,!u):((!l[o]||!le.isObject(l[o]))&&(l[o]=[]),r(t,n,l[o],a)&&le.isArray(l[o])&&(l[o]=Sd(l[o])),!u)}if(le.isFormData(e)&&le.isFunction(e.entries)){const t={};return le.forEachEntry(e,(n,l)=>{r(Cd(n),l,t,0)}),t}return null}function Bd(e,r,t){if(le.isString(e))try{return(r||JSON.parse)(e),le.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(t||JSON.stringify)(e)}const Xr={transitional:sa,adapter:["xhr","http","fetch"],transformRequest:[function(r,t){const n=t.getContentType()||"",l=n.indexOf("application/json")>-1,a=le.isObject(r);if(a&&le.isHTMLForm(r)&&(r=new FormData(r)),le.isFormData(r))return l?JSON.stringify(qu(r)):r;if(le.isArrayBuffer(r)||le.isBuffer(r)||le.isStream(r)||le.isFile(r)||le.isBlob(r)||le.isReadableStream(r))return r;if(le.isArrayBufferView(r))return r.buffer;if(le.isURLSearchParams(r))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),r.toString();let u;if(a){if(n.indexOf("application/x-www-form-urlencoded")>-1)return Ad(r,this.formSerializer).toString();if((u=le.isFileList(r))||n.indexOf("multipart/form-data")>-1){const p=this.env&&this.env.FormData;return Yn(u?{"files[]":r}:r,p&&new p,this.formSerializer)}}return a||l?(t.setContentType("application/json",!1),Bd(r)):r}],transformResponse:[function(r){const t=this.transitional||Xr.transitional,n=t&&t.forcedJSONParsing,l=this.responseType==="json";if(le.isResponse(r)||le.isReadableStream(r))return r;if(r&&le.isString(r)&&(n&&!this.responseType||l)){const o=!(t&&t.silentJSONParsing)&&l;try{return JSON.parse(r,this.parseReviver)}catch(u){if(o)throw u.name==="SyntaxError"?be.from(u,be.ERR_BAD_RESPONSE,this,null,this.response):u}}return r}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Ke.classes.FormData,Blob:Ke.classes.Blob},validateStatus:function(r){return r>=200&&r<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};le.forEach(["delete","get","head","post","put","patch"],e=>{Xr.headers[e]={}});const kd=le.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"]),Td=e=>{const r={};let t,n,l;return e&&e.split(`
5
+ `).forEach(function(o){l=o.indexOf(":"),t=o.substring(0,l).trim().toLowerCase(),n=o.substring(l+1).trim(),!(!t||r[t]&&kd[t])&&(t==="set-cookie"?r[t]?r[t].push(n):r[t]=[n]:r[t]=r[t]?r[t]+", "+n:n)}),r},cs=Symbol("internals");function Ir(e){return e&&String(e).trim().toLowerCase()}function Fn(e){return e===!1||e==null?e:le.isArray(e)?e.map(Fn):String(e)}function Fd(e){const r=Object.create(null),t=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=t.exec(e);)r[n[1]]=n[2];return r}const Id=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function zi(e,r,t,n,l){if(le.isFunction(n))return n.call(this,r,t);if(l&&(r=t),!!le.isString(r)){if(le.isString(n))return r.indexOf(n)!==-1;if(le.isRegExp(n))return n.test(r)}}function Dd(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(r,t,n)=>t.toUpperCase()+n)}function Rd(e,r){const t=le.toCamelCase(" "+r);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+t,{value:function(l,a,o){return this[n].call(this,r,l,a,o)},configurable:!0})})}let Je=class{constructor(r){r&&this.set(r)}set(r,t,n){const l=this;function a(u,p,s){const i=Ir(p);if(!i)throw new Error("header name must be a non-empty string");const d=le.findKey(l,i);(!d||l[d]===void 0||s===!0||s===void 0&&l[d]!==!1)&&(l[d||p]=Fn(u))}const o=(u,p)=>le.forEach(u,(s,i)=>a(s,i,p));if(le.isPlainObject(r)||r instanceof this.constructor)o(r,t);else if(le.isString(r)&&(r=r.trim())&&!Id(r))o(Td(r),t);else if(le.isObject(r)&&le.isIterable(r)){let u={},p,s;for(const i of r){if(!le.isArray(i))throw TypeError("Object iterator must return a key-value pair");u[s=i[0]]=(p=u[s])?le.isArray(p)?[...p,i[1]]:[p,i[1]]:i[1]}o(u,t)}else r!=null&&a(t,r,n);return this}get(r,t){if(r=Ir(r),r){const n=le.findKey(this,r);if(n){const l=this[n];if(!t)return l;if(t===!0)return Fd(l);if(le.isFunction(t))return t.call(this,l,n);if(le.isRegExp(t))return t.exec(l);throw new TypeError("parser must be boolean|regexp|function")}}}has(r,t){if(r=Ir(r),r){const n=le.findKey(this,r);return!!(n&&this[n]!==void 0&&(!t||zi(this,this[n],n,t)))}return!1}delete(r,t){const n=this;let l=!1;function a(o){if(o=Ir(o),o){const u=le.findKey(n,o);u&&(!t||zi(n,n[u],u,t))&&(delete n[u],l=!0)}}return le.isArray(r)?r.forEach(a):a(r),l}clear(r){const t=Object.keys(this);let n=t.length,l=!1;for(;n--;){const a=t[n];(!r||zi(this,this[a],a,r,!0))&&(delete this[a],l=!0)}return l}normalize(r){const t=this,n={};return le.forEach(this,(l,a)=>{const o=le.findKey(n,a);if(o){t[o]=Fn(l),delete t[a];return}const u=r?Dd(a):String(a).trim();u!==a&&delete t[a],t[u]=Fn(l),n[u]=!0}),this}concat(...r){return this.constructor.concat(this,...r)}toJSON(r){const t=Object.create(null);return le.forEach(this,(n,l)=>{n!=null&&n!==!1&&(t[l]=r&&le.isArray(n)?n.join(", "):n)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([r,t])=>r+": "+t).join(`
6
+ `)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(r){return r instanceof this?r:new this(r)}static concat(r,...t){const n=new this(r);return t.forEach(l=>n.set(l)),n}static accessor(r){const n=(this[cs]=this[cs]={accessors:{}}).accessors,l=this.prototype;function a(o){const u=Ir(o);n[u]||(Rd(l,o),n[u]=!0)}return le.isArray(r)?r.forEach(a):a(r),this}};Je.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);le.reduceDescriptors(Je.prototype,({value:e},r)=>{let t=r[0].toUpperCase()+r.slice(1);return{get:()=>e,set(n){this[t]=n}}});le.freezeMethods(Je);function ji(e,r){const t=this||Xr,n=r||t,l=Je.from(n.headers);let a=n.data;return le.forEach(e,function(u){a=u.call(t,a,l.normalize(),r?r.status:void 0)}),l.normalize(),a}function $u(e){return!!(e&&e.__CANCEL__)}let Zr=class extends be{constructor(r,t,n){super(r==null?"canceled":r,be.ERR_CANCELED,t,n),this.name="CanceledError",this.__CANCEL__=!0}};function zu(e,r,t){const n=t.config.validateStatus;!t.status||!n||n(t.status)?e(t):r(new be("Request failed with status code "+t.status,[be.ERR_BAD_REQUEST,be.ERR_BAD_RESPONSE][Math.floor(t.status/100)-4],t.config,t.request,t))}function Od(e){const r=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return r&&r[1]||""}function Pd(e,r){e=e||10;const t=new Array(e),n=new Array(e);let l=0,a=0,o;return r=r!==void 0?r:1e3,function(p){const s=Date.now(),i=n[a];o||(o=s),t[l]=p,n[l]=s;let d=a,c=0;for(;d!==l;)c+=t[d++],d=d%e;if(l=(l+1)%e,l===a&&(a=(a+1)%e),s-o<r)return;const f=i&&s-i;return f?Math.round(c*1e3/f):void 0}}function Nd(e,r){let t=0,n=1e3/r,l,a;const o=(s,i=Date.now())=>{t=i,l=null,a&&(clearTimeout(a),a=null),e(...s)};return[(...s)=>{const i=Date.now(),d=i-t;d>=n?o(s,i):(l=s,a||(a=setTimeout(()=>{a=null,o(l)},n-d)))},()=>l&&o(l)]}const Mn=(e,r,t=3)=>{let n=0;const l=Pd(50,250);return Nd(a=>{const o=a.loaded,u=a.lengthComputable?a.total:void 0,p=o-n,s=l(p),i=o<=u;n=o;const d={loaded:o,total:u,progress:u?o/u:void 0,bytes:p,rate:s||void 0,estimated:s&&u&&i?(u-o)/s:void 0,event:a,lengthComputable:u!=null,[r?"download":"upload"]:!0};e(d)},t)},fs=(e,r)=>{const t=e!=null;return[n=>r[0]({lengthComputable:t,total:e,loaded:n}),r[1]]},hs=e=>(...r)=>le.asap(()=>e(...r)),Md=Ke.hasStandardBrowserEnv?((e,r)=>t=>(t=new URL(t,Ke.origin),e.protocol===t.protocol&&e.host===t.host&&(r||e.port===t.port)))(new URL(Ke.origin),Ke.navigator&&/(msie|trident)/i.test(Ke.navigator.userAgent)):()=>!0,Ld=Ke.hasStandardBrowserEnv?{write(e,r,t,n,l,a,o){if(typeof document=="undefined")return;const u=[`${e}=${encodeURIComponent(r)}`];le.isNumber(t)&&u.push(`expires=${new Date(t).toUTCString()}`),le.isString(n)&&u.push(`path=${n}`),le.isString(l)&&u.push(`domain=${l}`),a===!0&&u.push("secure"),le.isString(o)&&u.push(`SameSite=${o}`),document.cookie=u.join("; ")},read(e){if(typeof document=="undefined")return null;const r=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return r?decodeURIComponent(r[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function Ud(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function qd(e,r){return r?e.replace(/\/?\/$/,"")+"/"+r.replace(/^\/+/,""):e}function ju(e,r,t){let n=!Ud(r);return e&&(n||t==!1)?qd(e,r):r}const ps=e=>e instanceof Je?he({},e):e;function Yt(e,r){r=r||{};const t={};function n(s,i,d,c){return le.isPlainObject(s)&&le.isPlainObject(i)?le.merge.call({caseless:c},s,i):le.isPlainObject(i)?le.merge({},i):le.isArray(i)?i.slice():i}function l(s,i,d,c){if(le.isUndefined(i)){if(!le.isUndefined(s))return n(void 0,s,d,c)}else return n(s,i,d,c)}function a(s,i){if(!le.isUndefined(i))return n(void 0,i)}function o(s,i){if(le.isUndefined(i)){if(!le.isUndefined(s))return n(void 0,s)}else return n(void 0,i)}function u(s,i,d){if(d in r)return n(s,i);if(d in e)return n(void 0,s)}const p={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:u,headers:(s,i,d)=>l(ps(s),ps(i),d,!0)};return le.forEach(Object.keys(he(he({},e),r)),function(i){if(i==="__proto__"||i==="constructor"||i==="prototype")return;const d=le.hasOwnProp(p,i)?p[i]:l,c=d(e[i],r[i],i);le.isUndefined(c)&&d!==u||(t[i]=c)}),t}const Hu=e=>{const r=Yt({},e);let{data:t,withXSRFToken:n,xsrfHeaderName:l,xsrfCookieName:a,headers:o,auth:u}=r;if(r.headers=o=Je.from(o),r.url=Uu(ju(r.baseURL,r.url,r.allowAbsoluteUrls),e.params,e.paramsSerializer),u&&o.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?unescape(encodeURIComponent(u.password)):""))),le.isFormData(t)){if(Ke.hasStandardBrowserEnv||Ke.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(le.isFunction(t.getHeaders)){const p=t.getHeaders(),s=["content-type","content-length"];Object.entries(p).forEach(([i,d])=>{s.includes(i.toLowerCase())&&o.set(i,d)})}}if(Ke.hasStandardBrowserEnv&&(n&&le.isFunction(n)&&(n=n(r)),n||n!==!1&&Md(r.url))){const p=l&&a&&Ld.read(a);p&&o.set(l,p)}return r},$d=typeof XMLHttpRequest!="undefined",zd=$d&&function(e){return new Promise(function(t,n){const l=Hu(e);let a=l.data;const o=Je.from(l.headers).normalize();let{responseType:u,onUploadProgress:p,onDownloadProgress:s}=l,i,d,c,f,h;function v(){f&&f(),h&&h(),l.cancelToken&&l.cancelToken.unsubscribe(i),l.signal&&l.signal.removeEventListener("abort",i)}let m=new XMLHttpRequest;m.open(l.method.toUpperCase(),l.url,!0),m.timeout=l.timeout;function g(){if(!m)return;const y=Je.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders()),k={data:!u||u==="text"||u==="json"?m.responseText:m.response,status:m.status,statusText:m.statusText,headers:y,config:e,request:m};zu(function(I){t(I),v()},function(I){n(I),v()},k),m=null}"onloadend"in m?m.onloadend=g:m.onreadystatechange=function(){!m||m.readyState!==4||m.status===0&&!(m.responseURL&&m.responseURL.indexOf("file:")===0)||setTimeout(g)},m.onabort=function(){m&&(n(new be("Request aborted",be.ECONNABORTED,e,m)),m=null)},m.onerror=function(w){const k=w&&w.message?w.message:"Network Error",T=new be(k,be.ERR_NETWORK,e,m);T.event=w||null,n(T),m=null},m.ontimeout=function(){let w=l.timeout?"timeout of "+l.timeout+"ms exceeded":"timeout exceeded";const k=l.transitional||sa;l.timeoutErrorMessage&&(w=l.timeoutErrorMessage),n(new be(w,k.clarifyTimeoutError?be.ETIMEDOUT:be.ECONNABORTED,e,m)),m=null},a===void 0&&o.setContentType(null),"setRequestHeader"in m&&le.forEach(o.toJSON(),function(w,k){m.setRequestHeader(k,w)}),le.isUndefined(l.withCredentials)||(m.withCredentials=!!l.withCredentials),u&&u!=="json"&&(m.responseType=l.responseType),s&&([c,h]=Mn(s,!0),m.addEventListener("progress",c)),p&&m.upload&&([d,f]=Mn(p),m.upload.addEventListener("progress",d),m.upload.addEventListener("loadend",f)),(l.cancelToken||l.signal)&&(i=y=>{m&&(n(!y||y.type?new Zr(null,e,m):y),m.abort(),m=null)},l.cancelToken&&l.cancelToken.subscribe(i),l.signal&&(l.signal.aborted?i():l.signal.addEventListener("abort",i)));const x=Od(l.url);if(x&&Ke.protocols.indexOf(x)===-1){n(new be("Unsupported protocol "+x+":",be.ERR_BAD_REQUEST,e));return}m.send(a||null)})},jd=(e,r)=>{const{length:t}=e=e?e.filter(Boolean):[];if(r||t){let n=new AbortController,l;const a=function(s){if(!l){l=!0,u();const i=s instanceof Error?s:this.reason;n.abort(i instanceof be?i:new Zr(i instanceof Error?i.message:i))}};let o=r&&setTimeout(()=>{o=null,a(new be(`timeout of ${r}ms exceeded`,be.ETIMEDOUT))},r);const u=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(s=>{s.unsubscribe?s.unsubscribe(a):s.removeEventListener("abort",a)}),e=null)};e.forEach(s=>s.addEventListener("abort",a));const{signal:p}=n;return p.unsubscribe=()=>le.asap(u),p}},Hd=function*(e,r){let t=e.byteLength;if(t<r){yield e;return}let n=0,l;for(;n<t;)l=n+r,yield e.slice(n,l),n=l},Vd=function(e,r){return yi(this,null,function*(){try{for(var t=Ta(Wd(e)),n,l,a;n=!(l=yield new zt(t.next())).done;n=!1){const o=l.value;yield*gi(Hd(o,r))}}catch(l){a=[l]}finally{try{n&&(l=t.return)&&(yield new zt(l.call(t)))}finally{if(a)throw a[0]}}})},Wd=function(e){return yi(this,null,function*(){if(e[Symbol.asyncIterator]){yield*gi(e);return}const r=e.getReader();try{for(;;){const{done:t,value:n}=yield new zt(r.read());if(t)break;yield n}}finally{yield new zt(r.cancel())}})},ds=(e,r,t,n)=>{const l=Vd(e,r);let a=0,o,u=s=>{o||(o=!0,n&&n(s))};return new ReadableStream({pull(s){return je(this,null,function*(){try{const{done:i,value:d}=yield l.next();if(i){u(),s.close();return}let c=d.byteLength;if(t){let f=a+=c;t(f)}s.enqueue(new Uint8Array(d))}catch(i){throw u(i),i}})},cancel(s){return u(s),l.return()}},{highWaterMark:2})},ms=64*1024,{isFunction:dn}=le,Kd=(({Request:e,Response:r})=>({Request:e,Response:r}))(le.global),{ReadableStream:vs,TextEncoder:ys}=le.global,gs=(e,...r)=>{try{return!!e(...r)}catch(t){return!1}},Gd=e=>{e=le.merge.call({skipUndefined:!0},Kd,e);const{fetch:r,Request:t,Response:n}=e,l=r?dn(r):typeof fetch=="function",a=dn(t),o=dn(n);if(!l)return!1;const u=l&&dn(vs),p=l&&(typeof ys=="function"?(h=>v=>h.encode(v))(new ys):h=>je(exports,null,function*(){return new Uint8Array(yield new t(h).arrayBuffer())})),s=a&&u&&gs(()=>{let h=!1;const v=new t(Ke.origin,{body:new vs,method:"POST",get duplex(){return h=!0,"half"}}).headers.has("Content-Type");return h&&!v}),i=o&&u&&gs(()=>le.isReadableStream(new n("").body)),d={stream:i&&(h=>h.body)};l&&["text","arrayBuffer","blob","formData","stream"].forEach(h=>{!d[h]&&(d[h]=(v,m)=>{let g=v&&v[h];if(g)return g.call(v);throw new be(`Response type '${h}' is not supported`,be.ERR_NOT_SUPPORT,m)})});const c=h=>je(exports,null,function*(){if(h==null)return 0;if(le.isBlob(h))return h.size;if(le.isSpecCompliantForm(h))return(yield new t(Ke.origin,{method:"POST",body:h}).arrayBuffer()).byteLength;if(le.isArrayBufferView(h)||le.isArrayBuffer(h))return h.byteLength;if(le.isURLSearchParams(h)&&(h=h+""),le.isString(h))return(yield p(h)).byteLength}),f=(h,v)=>je(exports,null,function*(){const m=le.toFiniteNumber(h.getContentLength());return m==null?c(v):m});return h=>je(exports,null,function*(){let{url:v,method:m,data:g,signal:x,cancelToken:y,timeout:w,onDownloadProgress:k,onUploadProgress:T,responseType:I,headers:D,withCredentials:X="same-origin",fetchOptions:V}=Hu(h),E=r||fetch;I=I?(I+"").toLowerCase():"text";let A=jd([x,y&&y.toAbortSignal()],w),C=null;const F=A&&A.unsubscribe&&(()=>{A.unsubscribe()});let j;try{if(T&&s&&m!=="get"&&m!=="head"&&(j=yield f(D,g))!==0){let L=new t(v,{method:"POST",body:g,duplex:"half"}),O;if(le.isFormData(g)&&(O=L.headers.get("content-type"))&&D.setContentType(O),L.body){const[H,W]=fs(j,Mn(hs(T)));g=ds(L.body,ms,H,W)}}le.isString(X)||(X=X?"include":"omit");const P=a&&"credentials"in t.prototype,J=_e(he({},V),{signal:A,method:m.toUpperCase(),headers:D.normalize().toJSON(),body:g,duplex:"half",credentials:P?X:void 0});C=a&&new t(v,J);let $=yield a?E(C,V):E(v,J);const U=i&&(I==="stream"||I==="response");if(i&&(k||U&&F)){const L={};["status","statusText","headers"].forEach(Z=>{L[Z]=$[Z]});const O=le.toFiniteNumber($.headers.get("content-length")),[H,W]=k&&fs(O,Mn(hs(k),!0))||[];$=new n(ds($.body,ms,H,()=>{W&&W(),F&&F()}),L)}I=I||"text";let K=yield d[le.findKey(d,I)||"text"]($,h);return!U&&F&&F(),yield new Promise((L,O)=>{zu(L,O,{data:K,headers:Je.from($.headers),status:$.status,statusText:$.statusText,config:h,request:C})})}catch(P){throw F&&F(),P&&P.name==="TypeError"&&/Load failed|fetch/i.test(P.message)?Object.assign(new be("Network Error",be.ERR_NETWORK,h,C,P&&P.response),{cause:P.cause||P}):be.from(P,P&&P.code,h,C,P&&P.response)}})},Qd=new Map,Vu=e=>{let r=e&&e.env||{};const{fetch:t,Request:n,Response:l}=r,a=[n,l,t];let o=a.length,u=o,p,s,i=Qd;for(;u--;)p=a[u],s=i.get(p),s===void 0&&i.set(p,s=u?new Map:Gd(r)),i=s;return s};Vu();const ua={http:hd,xhr:zd,fetch:{get:Vu}};le.forEach(ua,(e,r)=>{if(e){try{Object.defineProperty(e,"name",{value:r})}catch(t){}Object.defineProperty(e,"adapterName",{value:r})}});const xs=e=>`- ${e}`,Yd=e=>le.isFunction(e)||e===null||e===!1;function Xd(e,r){e=le.isArray(e)?e:[e];const{length:t}=e;let n,l;const a={};for(let o=0;o<t;o++){n=e[o];let u;if(l=n,!Yd(n)&&(l=ua[(u=String(n)).toLowerCase()],l===void 0))throw new be(`Unknown adapter '${u}'`);if(l&&(le.isFunction(l)||(l=l.get(r))))break;a[u||"#"+o]=l}if(!l){const o=Object.entries(a).map(([p,s])=>`adapter ${p} `+(s===!1?"is not supported by the environment":"is not available in the build"));let u=t?o.length>1?`since :
7
7
  `+o.map(xs).join(`
8
- `):" "+xs(o[0]):"as no adapter specified";throw new be("There is no suitable adapter to dispatch the request "+u,"ERR_NOT_SUPPORT")}return l}const Wu={getAdapter:t1,adapters:ua};function Hi(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Zr(null,e)}function bs(e){return Hi(e),e.headers=Je.from(e.headers),e.data=ji.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Wu.getAdapter(e.adapter||Xr.adapter,e)(e).then(function(n){return Hi(e),n.data=ji.call(e,e.transformResponse,n),n.headers=Je.from(n.headers),n},function(n){return $u(n)||(Hi(e),n&&n.response&&(n.response.data=ji.call(e,e.transformResponse,n.response),n.response.headers=Je.from(n.response.headers))),Promise.reject(n)})}const Ku="1.13.5",Xn={};["object","boolean","number","function","string","symbol"].forEach((e,r)=>{Xn[e]=function(n){return typeof n===e||"a"+(r<1?"n ":" ")+e}});const ws={};Xn.transitional=function(r,t,n){function l(a,o){return"[Axios v"+Ku+"] Transitional option '"+a+"'"+o+(n?". "+n:"")}return(a,o,u)=>{if(r===!1)throw new be(l(o," has been removed"+(t?" in "+t:"")),be.ERR_DEPRECATED);return t&&!ws[o]&&(ws[o]=!0,console.warn(l(o," has been deprecated since v"+t+" and will be removed in the near future"))),r?r(a,o,u):!0}};Xn.spelling=function(r){return(t,n)=>(console.warn(`${n} is likely a misspelling of ${r}`),!0)};function r1(e,r,t){if(typeof e!="object")throw new be("options must be an object",be.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let l=n.length;for(;l-- >0;){const a=n[l],o=r[a];if(o){const u=e[a],p=u===void 0||o(u,a,e);if(p!==!0)throw new be("option "+a+" must be "+p,be.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new be("Unknown option "+a,be.ERR_BAD_OPTION)}}const In={assertOptions:r1,validators:Xn},ot=In.validators;let Qt=class{constructor(r){this.defaults=r||{},this.interceptors={request:new us,response:new us}}request(r,t){return je(this,null,function*(){try{return yield this._request(r,t)}catch(n){if(n instanceof Error){let l={};Error.captureStackTrace?Error.captureStackTrace(l):l=new Error;const a=l.stack?l.stack.replace(/^.+\n/,""):"";try{n.stack?a&&!String(n.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(n.stack+=`
9
- `+a):n.stack=a}catch(o){}}throw n}})}_request(r,t){typeof r=="string"?(t=t||{},t.url=r):t=r||{},t=Yt(this.defaults,t);const{transitional:n,paramsSerializer:l,headers:a}=t;n!==void 0&&In.assertOptions(n,{silentJSONParsing:ot.transitional(ot.boolean),forcedJSONParsing:ot.transitional(ot.boolean),clarifyTimeoutError:ot.transitional(ot.boolean),legacyInterceptorReqResOrdering:ot.transitional(ot.boolean)},!1),l!=null&&(le.isFunction(l)?t.paramsSerializer={serialize:l}:In.assertOptions(l,{encode:ot.function,serialize:ot.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),In.assertOptions(t,{baseUrl:ot.spelling("baseURL"),withXsrfToken:ot.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let o=a&&le.merge(a.common,a[t.method]);a&&le.forEach(["delete","get","head","post","put","patch","common"],h=>{delete a[h]}),t.headers=Je.concat(o,a);const u=[];let p=!0;this.interceptors.request.forEach(function(v){if(typeof v.runWhen=="function"&&v.runWhen(t)===!1)return;p=p&&v.synchronous;const m=t.transitional||sa;m&&m.legacyInterceptorReqResOrdering?u.unshift(v.fulfilled,v.rejected):u.push(v.fulfilled,v.rejected)});const s=[];this.interceptors.response.forEach(function(v){s.push(v.fulfilled,v.rejected)});let i,d=0,c;if(!p){const h=[bs.bind(this),void 0];for(h.unshift(...u),h.push(...s),c=h.length,i=Promise.resolve(t);d<c;)i=i.then(h[d++],h[d++]);return i}c=u.length;let f=t;for(;d<c;){const h=u[d++],v=u[d++];try{f=h(f)}catch(m){v.call(this,m);break}}try{i=bs.call(this,f)}catch(h){return Promise.reject(h)}for(d=0,c=s.length;d<c;)i=i.then(s[d++],s[d++]);return i}getUri(r){r=Yt(this.defaults,r);const t=ju(r.baseURL,r.url,r.allowAbsoluteUrls);return Uu(t,r.params,r.paramsSerializer)}};le.forEach(["delete","get","head","options"],function(r){Qt.prototype[r]=function(t,n){return this.request(Yt(n||{},{method:r,url:t,data:(n||{}).data}))}});le.forEach(["post","put","patch"],function(r){function t(n){return function(a,o,u){return this.request(Yt(u||{},{method:r,headers:n?{"Content-Type":"multipart/form-data"}:{},url:a,data:o}))}}Qt.prototype[r]=t(),Qt.prototype[r+"Form"]=t(!0)});let n1=class Gu{constructor(r){if(typeof r!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(a){t=a});const n=this;this.promise.then(l=>{if(!n._listeners)return;let a=n._listeners.length;for(;a-- >0;)n._listeners[a](l);n._listeners=null}),this.promise.then=l=>{let a;const o=new Promise(u=>{n.subscribe(u),a=u}).then(l);return o.cancel=function(){n.unsubscribe(a)},o},r(function(a,o,u){n.reason||(n.reason=new Zr(a,o,u),t(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(r){if(this.reason){r(this.reason);return}this._listeners?this._listeners.push(r):this._listeners=[r]}unsubscribe(r){if(!this._listeners)return;const t=this._listeners.indexOf(r);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const r=new AbortController,t=n=>{r.abort(n)};return this.subscribe(t),r.signal.unsubscribe=()=>this.unsubscribe(t),r.signal}static source(){let r;return{token:new Gu(function(l){r=l}),cancel:r}}};function i1(e){return function(t){return e.apply(null,t)}}function o1(e){return le.isObject(e)&&e.isAxiosError===!0}const zo={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(zo).forEach(([e,r])=>{zo[r]=e});function Qu(e){const r=new Qt(e),t=ku(Qt.prototype.request,r);return le.extend(t,Qt.prototype,r,{allOwnKeys:!0}),le.extend(t,r,null,{allOwnKeys:!0}),t.create=function(l){return Qu(Yt(e,l))},t}const Re=Qu(Xr);Re.Axios=Qt;Re.CanceledError=Zr;Re.CancelToken=n1;Re.isCancel=$u;Re.VERSION=Ku;Re.toFormData=Yn;Re.AxiosError=be;Re.Cancel=Re.CanceledError;Re.all=function(r){return Promise.all(r)};Re.spread=i1;Re.isAxiosError=o1;Re.mergeConfig=Yt;Re.AxiosHeaders=Je;Re.formToJSON=e=>qu(le.isHTMLForm(e)?new FormData(e):e);Re.getAdapter=Wu.getAdapter;Re.HttpStatusCode=zo;Re.default=Re;const{Axios:xg,AxiosError:bg,CanceledError:wg,isCancel:_g,CancelToken:Eg,VERSION:Ag,all:Cg,Cancel:Sg,isAxiosError:Bg,spread:kg,toFormData:Tg,AxiosHeaders:Fg,HttpStatusCode:Ig,formToJSON:Dg,getAdapter:Rg,mergeConfig:Og}=Re,nt={CUSTOM_MSG:"CUSTOM_MSG",OPEN_CAMERA:"OPEN_CAMERA",CLOSE_CAMERA:"CLOSE_CAMERA",OPEN_AUDIO:"OPEN_AUDIO",CLOSE_AUDIO:"CLOSE_AUDIO",CHANGE_GRAPH:"CHANGE_GRAPH",NOTIFY_DIALOG:"NOTIFY_DIALOG"},a1={OFFLINE:0},Se={NORMAL:"NORMAL",TEXT:"TEXT",AUDIO:"AUDIO",MP4:"MP4",CAMERA:"CAMERA",VIDEO_STREAM:"VIDEO_STREAM",POINT_VALUE:"POINT_VALUE",LIGHT_PLATE:"LIGHT_PLATE",SENSOR:"SENSOR",TABLE:"TABLE",SWITCH:"SWITCH",RADIO:"RADIO",SLIDER:"SLIDER",SELECT:"SELECT",CHECKBOX:"CHECKBOX",TIME:"TIME",BUTTON:"BUTTON",INPUT:"INPUT"},Vi={POINT:5,YX:6,YC:7},mn={Emit:7},s1={STOP:2},l1={1:1,2:2,3:3,4:4,5:5},Zn={WUJIE:"wujie",QIANKUN:"qiankun",MICROAPP:"microapp"},_s={GRAPH:{SOCKET:"GRAPH_SOCKET"}},Es={AC:{ALARM:"ac.channel.alarm",CONDITION:"ac.channel.gk",OPERATION:"ac.channel.op"},AUDIT:{MSG:"audit.msg",ALARM:"audit.alarm"},DATA:{TASK_STATUS:"data.patroldevice.taskstatus",TASK_RESULT:"data.patroldevice.taskresult"},HOST:{STATUS:"status.platform.hoststatus"},NEST:{BATTERY:"status.platform.nestbattery",HUMIDITY:"status.platform.nesthumidity",TEMPERATURE:"status.platform.nesttemperature",AIR_STATE:"status.platform.nestairstate",DOOR_STATE:"status.platform.nestdoorstate",CHARGE_STATE:"status.platform.nestchargestate",RUNNING_STATE:"status.platform.nestrunningstate",BATTERY_STATE:"status.platform.nestbatterystate",BATTERY_ENABLE:"status.platform.nestbatteryenable",BATTERY_VOLTAGE:"status.platform.nestbatteryvoltage",PLATFORM_STATE:"status.platform.nestsysstate"},MEDIA:{NVR_INFO:"status.platform.nvrinfo",NVR_STATUS:"status.platform.nvrstatus",CAMERA_STATUS:"status.platform.camerastatus"},DRONE:{STATUS:"status.platform.dronestatus",ELECTRICITY:"status.platform.droneelectricity",FLIGHT_TIME:"status.platform.flighttime",FLIGHT_HEIGHT:"status.platform.flightheight",FLIGHT_STATUS:"status.platform.flightstatus",FLIGHT_DISTANCE:"status.platform.flightdistance",PTZ_ELEVATION:"status.platform.ptzelevation",PTZ_YAW_ANGLE:"status.platform.ptzyawangle",PTZ_ROLL_ANGLE:"status.platform.ptzrollangle",LOW_BATTERY:"status.platform.lowbattery",COMM_ABNORMAL:"status.platform.commabnormal",DRIVE_EXCEPTION:"status.platform.driveexception",FAULT_ALARM:"status.platform.faultalarm",CONTROL_STATUS:"status.platform.controlstatus",MILEAGE:"status.platform.mileage",CONTROL_MODE:"status.platform.controlmode"},ROBOT:{SPEED:"status.platform.robotspeed",STATUS:"status.platform.robotstatus",BATTERY:"status.platform.robotbattery",MILEAGE:"status.platform.robotmileage",HUMIDITY:"status.platform.robothumidity",WINDSPEED:"status.platform.robotwindspeed",COORDINATE:"status.platform.robotcoordinate",COORDINATES:"status.platform.robotcoordinates",FAULT_ALARM:"status.platform.robotfaultalarm",LOW_BATTERY:"status.platform.robotlowbattery",TEMPERATURE:"status.platform.robottemperature",CONTROL_MODE:"status.platform.robotcontrolmode",COMM_ABNORMAL:"status.platform.robotcommabnormal",RUNNING_STATE:"status.platform.robotrunningstate",CONTROL_STATUS:"status.platform.robotcontrolstatus",DRIVE_EXCEPTION:"status.platform.robotdriveexception",TRANSPORT_STATUS:"status.platform.robottransportstatus",ULTRASONIC_STOPPING:"status.platform.robotultrasonicstopping"},VOICE:{STATUS:"voiceprint.status",DATA:"voice.data",VOICEPRINT:"voiceprint.data",TIME_DOMAIN:"voiceprint.time.domain",FREQ_DOMAIN:"voiceprint.freq.domain"},PATROL:{ALARM:"patrol.alarm",TASK_ITEM:"patrol.task.item",TASK_INDEX:"patrol.task.index",SINGLE_RESULT:"patrol.single.result",CAMERA_ITEM:"patrol.camera.item",PATROLDEVICE_TASKSTATUS:"data.patroldevice.taskstatus",PATROLDEVICE_TASKRESULT:"data.patroldevice.taskresult",MASTER_ALARM:"patrol.master.alarm",MASTER_SILENCE:"patrol.task.master.silence",MASTER_TASK_ITEM:"patrol.task.master.item",MASTER_TASK_INDEX:"patrol.task.master.index"},REPORT:{ALARM:"report.alarm.message",EXCEL:"report.excel.message",PATROL:"report.patrol.message",PICTURE:"report.picture.message"},ACPOINT:{YCVALUE:"status.platform.ycvalue",YXVALUE:"status.platform.yxvalue"},ALARM:{VOICE:"alarm.platform.alarm"},LINKAGE:{TASK:"linkage.record.task",CAMERA:"linkage.record.camera",PRESET:"linkage.record.preset",CONTROL:"linkage.record.control",PATROLPOINT:"linkage.record.patrolpoint"},METRICS:{SERVER:"metrics.metrics.server",CONTAINER:"metrics.metrics.container"},STATION:{SF6:"status.platform.stationsf6",OXYGEN:"status.platform.stationoxygen",HUMIDITY:"status.platform.stationhumidity",PRESSURE:"status.platform.stationpressure",RAINFALL:"status.platform.stationrainfall",WINDSPEED:"status.platform.stationwindspeed",TEMPERATURE:"status.platform.stationtemperature",WINDDIRECTION:"status.platform.stationwinddirection"},INTERFACE:{ANALYSIS:"analyse.pic.result",ALGORITHM:"algorithm.update.result"},PATROL_DEVICE:{BATTERY:"status.platform.battery",MILEAGE:"status.platform.mileage",GEOGRAPHY:"status.platform.coordinate_geography",COORDINATE:"status.platform.coordinate",COORDINATES:"status.platform.coordinates",ELECTRICITY:"status.platform.electricity",PTZYAWANGLE:"status.platform.ptzyawangle",PTZELEVATION:"status.platform.ptzelevation",PTZROLLANGLE:"status.platform.ptzrollangle",VERTICAL_SPEED:"status.platform.verticalspeed",HORIZONTAL_SPEED:"status.platform.horizontalspeed",FAULT_ALARM:"status.platform.faultalarm",LOW_BATTERY:"status.platform.lowbattery",CONTROL_MODE:"status.platform.controlmode",COMM_ABNORMAL:"status.platform.commabnormal",RUNNING_STATE:"status.platform.runningstate",CONTROL_STATUS:"status.platform.controlstatus",DRIVE_EXCEPTION:"status.platform.driveexception",TRANSPORT_STATUS:"status.platform.transportstatus",ULTRASONIC_STOPPING:"status.platform.ultrasonicstopping"}};var Jn={};/*!
8
+ `):" "+xs(o[0]):"as no adapter specified";throw new be("There is no suitable adapter to dispatch the request "+u,"ERR_NOT_SUPPORT")}return l}const Wu={getAdapter:Xd,adapters:ua};function Hi(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Zr(null,e)}function bs(e){return Hi(e),e.headers=Je.from(e.headers),e.data=ji.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Wu.getAdapter(e.adapter||Xr.adapter,e)(e).then(function(n){return Hi(e),n.data=ji.call(e,e.transformResponse,n),n.headers=Je.from(n.headers),n},function(n){return $u(n)||(Hi(e),n&&n.response&&(n.response.data=ji.call(e,e.transformResponse,n.response),n.response.headers=Je.from(n.response.headers))),Promise.reject(n)})}const Ku="1.13.5",Xn={};["object","boolean","number","function","string","symbol"].forEach((e,r)=>{Xn[e]=function(n){return typeof n===e||"a"+(r<1?"n ":" ")+e}});const ws={};Xn.transitional=function(r,t,n){function l(a,o){return"[Axios v"+Ku+"] Transitional option '"+a+"'"+o+(n?". "+n:"")}return(a,o,u)=>{if(r===!1)throw new be(l(o," has been removed"+(t?" in "+t:"")),be.ERR_DEPRECATED);return t&&!ws[o]&&(ws[o]=!0,console.warn(l(o," has been deprecated since v"+t+" and will be removed in the near future"))),r?r(a,o,u):!0}};Xn.spelling=function(r){return(t,n)=>(console.warn(`${n} is likely a misspelling of ${r}`),!0)};function Zd(e,r,t){if(typeof e!="object")throw new be("options must be an object",be.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let l=n.length;for(;l-- >0;){const a=n[l],o=r[a];if(o){const u=e[a],p=u===void 0||o(u,a,e);if(p!==!0)throw new be("option "+a+" must be "+p,be.ERR_BAD_OPTION_VALUE);continue}if(t!==!0)throw new be("Unknown option "+a,be.ERR_BAD_OPTION)}}const In={assertOptions:Zd,validators:Xn},ot=In.validators;let Qt=class{constructor(r){this.defaults=r||{},this.interceptors={request:new us,response:new us}}request(r,t){return je(this,null,function*(){try{return yield this._request(r,t)}catch(n){if(n instanceof Error){let l={};Error.captureStackTrace?Error.captureStackTrace(l):l=new Error;const a=l.stack?l.stack.replace(/^.+\n/,""):"";try{n.stack?a&&!String(n.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(n.stack+=`
9
+ `+a):n.stack=a}catch(o){}}throw n}})}_request(r,t){typeof r=="string"?(t=t||{},t.url=r):t=r||{},t=Yt(this.defaults,t);const{transitional:n,paramsSerializer:l,headers:a}=t;n!==void 0&&In.assertOptions(n,{silentJSONParsing:ot.transitional(ot.boolean),forcedJSONParsing:ot.transitional(ot.boolean),clarifyTimeoutError:ot.transitional(ot.boolean),legacyInterceptorReqResOrdering:ot.transitional(ot.boolean)},!1),l!=null&&(le.isFunction(l)?t.paramsSerializer={serialize:l}:In.assertOptions(l,{encode:ot.function,serialize:ot.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),In.assertOptions(t,{baseUrl:ot.spelling("baseURL"),withXsrfToken:ot.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let o=a&&le.merge(a.common,a[t.method]);a&&le.forEach(["delete","get","head","post","put","patch","common"],h=>{delete a[h]}),t.headers=Je.concat(o,a);const u=[];let p=!0;this.interceptors.request.forEach(function(v){if(typeof v.runWhen=="function"&&v.runWhen(t)===!1)return;p=p&&v.synchronous;const m=t.transitional||sa;m&&m.legacyInterceptorReqResOrdering?u.unshift(v.fulfilled,v.rejected):u.push(v.fulfilled,v.rejected)});const s=[];this.interceptors.response.forEach(function(v){s.push(v.fulfilled,v.rejected)});let i,d=0,c;if(!p){const h=[bs.bind(this),void 0];for(h.unshift(...u),h.push(...s),c=h.length,i=Promise.resolve(t);d<c;)i=i.then(h[d++],h[d++]);return i}c=u.length;let f=t;for(;d<c;){const h=u[d++],v=u[d++];try{f=h(f)}catch(m){v.call(this,m);break}}try{i=bs.call(this,f)}catch(h){return Promise.reject(h)}for(d=0,c=s.length;d<c;)i=i.then(s[d++],s[d++]);return i}getUri(r){r=Yt(this.defaults,r);const t=ju(r.baseURL,r.url,r.allowAbsoluteUrls);return Uu(t,r.params,r.paramsSerializer)}};le.forEach(["delete","get","head","options"],function(r){Qt.prototype[r]=function(t,n){return this.request(Yt(n||{},{method:r,url:t,data:(n||{}).data}))}});le.forEach(["post","put","patch"],function(r){function t(n){return function(a,o,u){return this.request(Yt(u||{},{method:r,headers:n?{"Content-Type":"multipart/form-data"}:{},url:a,data:o}))}}Qt.prototype[r]=t(),Qt.prototype[r+"Form"]=t(!0)});let Jd=class Gu{constructor(r){if(typeof r!="function")throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(a){t=a});const n=this;this.promise.then(l=>{if(!n._listeners)return;let a=n._listeners.length;for(;a-- >0;)n._listeners[a](l);n._listeners=null}),this.promise.then=l=>{let a;const o=new Promise(u=>{n.subscribe(u),a=u}).then(l);return o.cancel=function(){n.unsubscribe(a)},o},r(function(a,o,u){n.reason||(n.reason=new Zr(a,o,u),t(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(r){if(this.reason){r(this.reason);return}this._listeners?this._listeners.push(r):this._listeners=[r]}unsubscribe(r){if(!this._listeners)return;const t=this._listeners.indexOf(r);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){const r=new AbortController,t=n=>{r.abort(n)};return this.subscribe(t),r.signal.unsubscribe=()=>this.unsubscribe(t),r.signal}static source(){let r;return{token:new Gu(function(l){r=l}),cancel:r}}};function e1(e){return function(t){return e.apply(null,t)}}function t1(e){return le.isObject(e)&&e.isAxiosError===!0}const zo={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(zo).forEach(([e,r])=>{zo[r]=e});function Qu(e){const r=new Qt(e),t=ku(Qt.prototype.request,r);return le.extend(t,Qt.prototype,r,{allOwnKeys:!0}),le.extend(t,r,null,{allOwnKeys:!0}),t.create=function(l){return Qu(Yt(e,l))},t}const Re=Qu(Xr);Re.Axios=Qt;Re.CanceledError=Zr;Re.CancelToken=Jd;Re.isCancel=$u;Re.VERSION=Ku;Re.toFormData=Yn;Re.AxiosError=be;Re.Cancel=Re.CanceledError;Re.all=function(r){return Promise.all(r)};Re.spread=e1;Re.isAxiosError=t1;Re.mergeConfig=Yt;Re.AxiosHeaders=Je;Re.formToJSON=e=>qu(le.isHTMLForm(e)?new FormData(e):e);Re.getAdapter=Wu.getAdapter;Re.HttpStatusCode=zo;Re.default=Re;const{Axios:vg,AxiosError:yg,CanceledError:gg,isCancel:xg,CancelToken:bg,VERSION:wg,all:_g,Cancel:Eg,isAxiosError:Ag,spread:Cg,toFormData:Sg,AxiosHeaders:Bg,HttpStatusCode:kg,formToJSON:Tg,getAdapter:Fg,mergeConfig:Ig}=Re,nt={CUSTOM_MSG:"CUSTOM_MSG",OPEN_CAMERA:"OPEN_CAMERA",CLOSE_CAMERA:"CLOSE_CAMERA",OPEN_AUDIO:"OPEN_AUDIO",CLOSE_AUDIO:"CLOSE_AUDIO",CHANGE_GRAPH:"CHANGE_GRAPH",NOTIFY_DIALOG:"NOTIFY_DIALOG",PROPS_PANEL:"PROPS_PANEL"},r1={OFFLINE:0},Se={NORMAL:"NORMAL",TEXT:"TEXT",AUDIO:"AUDIO",MP4:"MP4",CAMERA:"CAMERA",VIDEO_STREAM:"VIDEO_STREAM",POINT_VALUE:"POINT_VALUE",LIGHT_PLATE:"LIGHT_PLATE",SENSOR:"SENSOR",TABLE:"TABLE",SWITCH:"SWITCH",RADIO:"RADIO",SLIDER:"SLIDER",SELECT:"SELECT",CHECKBOX:"CHECKBOX",TIME:"TIME",BUTTON:"BUTTON",INPUT:"INPUT"},Vi={POINT:5,YX:6,YC:7},mn={Emit:7},n1={STOP:2},i1={1:1,2:2,3:3,4:4,5:5},Zn={WUJIE:"wujie",QIANKUN:"qiankun",MICROAPP:"microapp"},_s={GRAPH:{SOCKET:"GRAPH_SOCKET"}},Es={AC:{ALARM:"ac.channel.alarm",CONDITION:"ac.channel.gk",OPERATION:"ac.channel.op"},AUDIT:{MSG:"audit.msg",ALARM:"audit.alarm"},DATA:{TASK_STATUS:"data.patroldevice.taskstatus",TASK_RESULT:"data.patroldevice.taskresult"},HOST:{STATUS:"status.platform.hoststatus"},NEST:{BATTERY:"status.platform.nestbattery",HUMIDITY:"status.platform.nesthumidity",TEMPERATURE:"status.platform.nesttemperature",AIR_STATE:"status.platform.nestairstate",DOOR_STATE:"status.platform.nestdoorstate",CHARGE_STATE:"status.platform.nestchargestate",RUNNING_STATE:"status.platform.nestrunningstate",BATTERY_STATE:"status.platform.nestbatterystate",BATTERY_ENABLE:"status.platform.nestbatteryenable",BATTERY_VOLTAGE:"status.platform.nestbatteryvoltage",PLATFORM_STATE:"status.platform.nestsysstate"},MEDIA:{NVR_INFO:"status.platform.nvrinfo",NVR_STATUS:"status.platform.nvrstatus",CAMERA_STATUS:"status.platform.camerastatus"},DRONE:{STATUS:"status.platform.dronestatus",ELECTRICITY:"status.platform.droneelectricity",FLIGHT_TIME:"status.platform.flighttime",FLIGHT_HEIGHT:"status.platform.flightheight",FLIGHT_STATUS:"status.platform.flightstatus",FLIGHT_DISTANCE:"status.platform.flightdistance",PTZ_ELEVATION:"status.platform.ptzelevation",PTZ_YAW_ANGLE:"status.platform.ptzyawangle",PTZ_ROLL_ANGLE:"status.platform.ptzrollangle",LOW_BATTERY:"status.platform.lowbattery",COMM_ABNORMAL:"status.platform.commabnormal",DRIVE_EXCEPTION:"status.platform.driveexception",FAULT_ALARM:"status.platform.faultalarm",CONTROL_STATUS:"status.platform.controlstatus",MILEAGE:"status.platform.mileage",CONTROL_MODE:"status.platform.controlmode"},ROBOT:{SPEED:"status.platform.robotspeed",STATUS:"status.platform.robotstatus",BATTERY:"status.platform.robotbattery",MILEAGE:"status.platform.robotmileage",HUMIDITY:"status.platform.robothumidity",WINDSPEED:"status.platform.robotwindspeed",COORDINATE:"status.platform.robotcoordinate",COORDINATES:"status.platform.robotcoordinates",FAULT_ALARM:"status.platform.robotfaultalarm",LOW_BATTERY:"status.platform.robotlowbattery",TEMPERATURE:"status.platform.robottemperature",CONTROL_MODE:"status.platform.robotcontrolmode",COMM_ABNORMAL:"status.platform.robotcommabnormal",RUNNING_STATE:"status.platform.robotrunningstate",CONTROL_STATUS:"status.platform.robotcontrolstatus",DRIVE_EXCEPTION:"status.platform.robotdriveexception",TRANSPORT_STATUS:"status.platform.robottransportstatus",ULTRASONIC_STOPPING:"status.platform.robotultrasonicstopping"},VOICE:{STATUS:"voiceprint.status",DATA:"voice.data",VOICEPRINT:"voiceprint.data",TIME_DOMAIN:"voiceprint.time.domain",FREQ_DOMAIN:"voiceprint.freq.domain"},PATROL:{ALARM:"patrol.alarm",TASK_ITEM:"patrol.task.item",TASK_INDEX:"patrol.task.index",SINGLE_RESULT:"patrol.single.result",CAMERA_ITEM:"patrol.camera.item",PATROLDEVICE_TASKSTATUS:"data.patroldevice.taskstatus",PATROLDEVICE_TASKRESULT:"data.patroldevice.taskresult",MASTER_ALARM:"patrol.master.alarm",MASTER_SILENCE:"patrol.task.master.silence",MASTER_TASK_ITEM:"patrol.task.master.item",MASTER_TASK_INDEX:"patrol.task.master.index"},REPORT:{ALARM:"report.alarm.message",EXCEL:"report.excel.message",PATROL:"report.patrol.message",PICTURE:"report.picture.message"},ACPOINT:{YCVALUE:"status.platform.ycvalue",YXVALUE:"status.platform.yxvalue"},ALARM:{VOICE:"alarm.platform.alarm"},LINKAGE:{TASK:"linkage.record.task",CAMERA:"linkage.record.camera",PRESET:"linkage.record.preset",CONTROL:"linkage.record.control",PATROLPOINT:"linkage.record.patrolpoint"},METRICS:{SERVER:"metrics.metrics.server",CONTAINER:"metrics.metrics.container"},STATION:{SF6:"status.platform.stationsf6",OXYGEN:"status.platform.stationoxygen",HUMIDITY:"status.platform.stationhumidity",PRESSURE:"status.platform.stationpressure",RAINFALL:"status.platform.stationrainfall",WINDSPEED:"status.platform.stationwindspeed",TEMPERATURE:"status.platform.stationtemperature",WINDDIRECTION:"status.platform.stationwinddirection"},INTERFACE:{ANALYSIS:"analyse.pic.result",ALGORITHM:"algorithm.update.result"},PATROL_DEVICE:{BATTERY:"status.platform.battery",MILEAGE:"status.platform.mileage",GEOGRAPHY:"status.platform.coordinate_geography",COORDINATE:"status.platform.coordinate",COORDINATES:"status.platform.coordinates",ELECTRICITY:"status.platform.electricity",PTZYAWANGLE:"status.platform.ptzyawangle",PTZELEVATION:"status.platform.ptzelevation",PTZROLLANGLE:"status.platform.ptzrollangle",VERTICAL_SPEED:"status.platform.verticalspeed",HORIZONTAL_SPEED:"status.platform.horizontalspeed",FAULT_ALARM:"status.platform.faultalarm",LOW_BATTERY:"status.platform.lowbattery",CONTROL_MODE:"status.platform.controlmode",COMM_ABNORMAL:"status.platform.commabnormal",RUNNING_STATE:"status.platform.runningstate",CONTROL_STATUS:"status.platform.controlstatus",DRIVE_EXCEPTION:"status.platform.driveexception",TRANSPORT_STATUS:"status.platform.transportstatus",ULTRASONIC_STOPPING:"status.platform.ultrasonicstopping"}};var Jn={};/*!
10
10
  * vite-plugin-qiankun.js v1.0.14
11
11
  * (c) 2021-2022 Teng Mao Qing
12
12
  * Released under the MIT License.
13
- */Object.defineProperty(Jn,"__esModule",{value:!0});var hr=typeof window!="undefined"?window.proxy||window:{},Yu=function(e){hr!=null&&hr.__POWERED_BY_QIANKUN__&&(window.moudleQiankunAppLifeCycles||(window.moudleQiankunAppLifeCycles={}),hr.qiankunName&&(window.moudleQiankunAppLifeCycles[hr.qiankunName]=e))};Jn.default=Yu;var u1=Jn.qiankunWindow=hr;Jn.renderWithQiankun=Yu;const c1="/",f1=u1||window,ca=f1.meta.vite.micro.type||Zn.QIANKUN,Xu=ca===Zn.WUJIE,Zu=ca===Zn.QIANKUN,Ju=ca===Zn.MICROAPP,h1=window.top!==window.self||Xu||Zu||Ju;console.log("🚀 ~ isNested:",h1,Xu,Zu,Ju);const p1=location.protocol==="https:",d1=location.hostname,m1=p1?"wss:":"ws:",v1=location.port,y1=location.origin,As=`${m1}//${location.host}/ws`;window.meta.graph.savePath,window.meta.graph.graphPenPath,window.meta.graph.templatePath,window.meta.graph.graphImgUploadPath;const Ie=Re.create({baseURL:y1,timeout:window.meta.axios.timeout||12e4,withCredentials:!1,paramsSerializer:e=>Fp.stringify(e)});Ie.interceptors.request.use(e=>(e.headers["x-token"]="ewoglCJhbGcilDogpc3",e),e=>Promise.reject(e));Ie.interceptors.response.use(e=>{const{data:r}=e;return Promise.resolve(r)},e=>Promise.reject(e));function g1(e,r={},t={}){return new Promise(n=>{Ie.get(e,he({params:r},t)).then(l=>n({res:l,err:null})).catch(l=>n({res:null,err:l}))})}function x1(e,r={},t={}){return new Promise(n=>{Ie.post(e,r,t).then(l=>n({res:l,err:null})).catch(l=>n({res:null,err:l}))})}function b1(e,r={},t={}){return Ie.get(e,he({params:r},t))}function w1(e,r={},t={}){return Ie.post(e,r,t)}function _1(e,r={}){return Ie.get(`/filehandle/${e}`,{params:r})}function E1(e,r={},t={}){return Ie.post(`/filehandle/${e}`,r,t)}function A1(e,r={}){return Ie.get(`/user/${e}`,{params:r})}function C1(e,r={},t={}){return Ie.post(`/user/${e}`,r,t)}function S1(e,r={}){return Ie.get(`${e}`,r.local?{params:r,baseURL:c1}:{params:r})}function B1(e,r={}){return Ie.get(`/media/${e}/`,{params:r})}function k1(e,r={},t={}){return Ie.post(`/media/${e}/`,r,t)}function T1(e,r={}){return Ie.get(`/${window.meta.app.isFactory?window.meta.factory.singo_prefix||"acproxy/common":"common"}/${e}/`,{params:r})}function F1(e,r={},t={}){return Ie.post(`/${window.meta.app.isFactory?window.meta.factory.singo_prefix||"acproxy/common":"common"}/${e}/`,r,t)}function I1(e,r={}){return Ie.get(`/history/${e}`,{params:r})}function D1(e,r={},t={}){return Ie.post(`/history/${e}`,r,t)}function R1(e,r={}){return Ie.get(`/scada/${e}`,{params:r})}function O1(e,r={},t={}){return Ie.post(`/scada/${e}`,r,t)}function P1(e,r={}){return Ie.get(`/common/factory/${e}`,{params:r})}function N1(e,r={},t={}){return Ie.post(`/common/factory/${e}`,r,t)}function M1(e,r={}){return Ie.get(`/factory/${e}`,{params:r})}function L1(e,r={},t={}){return Ie.post(`/factory/${e}`,r,t)}const jo={getApi:g1,postApi:x1,getFileApi:_1,postFileApi:E1,getBaseApi:b1,postBaseApi:w1,getUserApi:A1,postUserApi:C1,getGraphApi:S1,getMediaApi:B1,postMediaApi:k1,getScadaApi:R1,postScadaApi:O1,getCommonApi:T1,postCommonApi:F1,getHistoryApi:I1,postHistoryApi:D1,getFactoryApi:M1,postFactoryApi:L1,getCommonFactoryApi:P1,postCommonFactoryApi:N1};function U1(e){return{all:e=e||new Map,on:function(r,t){var n=e.get(r);n?n.push(t):e.set(r,[t])},off:function(r,t){var n=e.get(r);n&&(t?n.splice(n.indexOf(t)>>>0,1):e.set(r,[]))},emit:function(r,t){var n=e.get(r);n&&n.slice().map(function(l){l(t)}),(n=e.get("*"))&&n.slice().map(function(l){l(r,t)})}}}const Ho=U1();function Cs(e){return Object.prototype.toString.call(e).slice(8,-1)}function Ss(e){if(typeof e!="string")return!1;const r=/^-?\d+(\.\d+)?$/;return e.trim()!==""&&r.test(e.trim())}var q1={exports:{}};function Rr(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Wi={exports:{}},Bs;function Ae(){return Bs||(Bs=1,function(e,r){(function(t,n){e.exports=n()})(xe,function(){var t=t||function(n,l){var a;if(typeof window!="undefined"&&window.crypto&&(a=window.crypto),typeof self!="undefined"&&self.crypto&&(a=self.crypto),typeof globalThis!="undefined"&&globalThis.crypto&&(a=globalThis.crypto),!a&&typeof window!="undefined"&&window.msCrypto&&(a=window.msCrypto),!a&&typeof xe!="undefined"&&xe.crypto&&(a=xe.crypto),!a&&typeof Rr=="function")try{a=ru}catch(x){}var o=function(){if(a){if(typeof a.getRandomValues=="function")try{return a.getRandomValues(new Uint32Array(1))[0]}catch(x){}if(typeof a.randomBytes=="function")try{return a.randomBytes(4).readInt32LE()}catch(x){}}throw new Error("Native crypto module could not be used to get secure random number.")},u=Object.create||function(){function x(){}return function(y){var w;return x.prototype=y,w=new x,x.prototype=null,w}}(),p={},s=p.lib={},i=s.Base=function(){return{extend:function(x){var y=u(this);return x&&y.mixIn(x),(!y.hasOwnProperty("init")||this.init===y.init)&&(y.init=function(){y.$super.init.apply(this,arguments)}),y.init.prototype=y,y.$super=this,y},create:function(){var x=this.extend();return x.init.apply(x,arguments),x},init:function(){},mixIn:function(x){for(var y in x)x.hasOwnProperty(y)&&(this[y]=x[y]);x.hasOwnProperty("toString")&&(this.toString=x.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),d=s.WordArray=i.extend({init:function(x,y){x=this.words=x||[],y!=l?this.sigBytes=y:this.sigBytes=x.length*4},toString:function(x){return(x||f).stringify(this)},concat:function(x){var y=this.words,w=x.words,k=this.sigBytes,T=x.sigBytes;if(this.clamp(),k%4)for(var I=0;I<T;I++){var D=w[I>>>2]>>>24-I%4*8&255;y[k+I>>>2]|=D<<24-(k+I)%4*8}else for(var X=0;X<T;X+=4)y[k+X>>>2]=w[X>>>2];return this.sigBytes+=T,this},clamp:function(){var x=this.words,y=this.sigBytes;x[y>>>2]&=4294967295<<32-y%4*8,x.length=n.ceil(y/4)},clone:function(){var x=i.clone.call(this);return x.words=this.words.slice(0),x},random:function(x){for(var y=[],w=0;w<x;w+=4)y.push(o());return new d.init(y,x)}}),c=p.enc={},f=c.Hex={stringify:function(x){for(var y=x.words,w=x.sigBytes,k=[],T=0;T<w;T++){var I=y[T>>>2]>>>24-T%4*8&255;k.push((I>>>4).toString(16)),k.push((I&15).toString(16))}return k.join("")},parse:function(x){for(var y=x.length,w=[],k=0;k<y;k+=2)w[k>>>3]|=parseInt(x.substr(k,2),16)<<24-k%8*4;return new d.init(w,y/2)}},h=c.Latin1={stringify:function(x){for(var y=x.words,w=x.sigBytes,k=[],T=0;T<w;T++){var I=y[T>>>2]>>>24-T%4*8&255;k.push(String.fromCharCode(I))}return k.join("")},parse:function(x){for(var y=x.length,w=[],k=0;k<y;k++)w[k>>>2]|=(x.charCodeAt(k)&255)<<24-k%4*8;return new d.init(w,y)}},v=c.Utf8={stringify:function(x){try{return decodeURIComponent(escape(h.stringify(x)))}catch(y){throw new Error("Malformed UTF-8 data")}},parse:function(x){return h.parse(unescape(encodeURIComponent(x)))}},m=s.BufferedBlockAlgorithm=i.extend({reset:function(){this._data=new d.init,this._nDataBytes=0},_append:function(x){typeof x=="string"&&(x=v.parse(x)),this._data.concat(x),this._nDataBytes+=x.sigBytes},_process:function(x){var y,w=this._data,k=w.words,T=w.sigBytes,I=this.blockSize,D=I*4,X=T/D;x?X=n.ceil(X):X=n.max((X|0)-this._minBufferSize,0);var V=X*I,E=n.min(V*4,T);if(V){for(var A=0;A<V;A+=I)this._doProcessBlock(k,A);y=k.splice(0,V),w.sigBytes-=E}return new d.init(y,E)},clone:function(){var x=i.clone.call(this);return x._data=this._data.clone(),x},_minBufferSize:0});s.Hasher=m.extend({cfg:i.extend(),init:function(x){this.cfg=this.cfg.extend(x),this.reset()},reset:function(){m.reset.call(this),this._doReset()},update:function(x){return this._append(x),this._process(),this},finalize:function(x){x&&this._append(x);var y=this._doFinalize();return y},blockSize:16,_createHelper:function(x){return function(y,w){return new x.init(w).finalize(y)}},_createHmacHelper:function(x){return function(y,w){return new g.HMAC.init(x,w).finalize(y)}}});var g=p.algo={};return p}(Math);return t})}(Wi)),Wi.exports}var Ki={exports:{}},ks;function ei(){return ks||(ks=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.Base,u=a.WordArray,p=l.x64={};p.Word=o.extend({init:function(s,i){this.high=s,this.low=i}}),p.WordArray=o.extend({init:function(s,i){s=this.words=s||[],i!=n?this.sigBytes=i:this.sigBytes=s.length*8},toX32:function(){for(var s=this.words,i=s.length,d=[],c=0;c<i;c++){var f=s[c];d.push(f.high),d.push(f.low)}return u.create(d,this.sigBytes)},clone:function(){for(var s=o.clone.call(this),i=s.words=this.words.slice(0),d=i.length,c=0;c<d;c++)i[c]=i[c].clone();return s}})}(),t})}(Ki)),Ki.exports}var Gi={exports:{}},Ts;function $1(){return Ts||(Ts=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){if(typeof ArrayBuffer=="function"){var n=t,l=n.lib,a=l.WordArray,o=a.init,u=a.init=function(p){if(p instanceof ArrayBuffer&&(p=new Uint8Array(p)),(p instanceof Int8Array||typeof Uint8ClampedArray!="undefined"&&p instanceof Uint8ClampedArray||p instanceof Int16Array||p instanceof Uint16Array||p instanceof Int32Array||p instanceof Uint32Array||p instanceof Float32Array||p instanceof Float64Array)&&(p=new Uint8Array(p.buffer,p.byteOffset,p.byteLength)),p instanceof Uint8Array){for(var s=p.byteLength,i=[],d=0;d<s;d++)i[d>>>2]|=p[d]<<24-d%4*8;o.call(this,i,s)}else o.apply(this,arguments)};u.prototype=a}}(),t.lib.WordArray})}(Gi)),Gi.exports}var Qi={exports:{}},Fs;function z1(){return Fs||(Fs=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.enc;o.Utf16=o.Utf16BE={stringify:function(p){for(var s=p.words,i=p.sigBytes,d=[],c=0;c<i;c+=2){var f=s[c>>>2]>>>16-c%4*8&65535;d.push(String.fromCharCode(f))}return d.join("")},parse:function(p){for(var s=p.length,i=[],d=0;d<s;d++)i[d>>>1]|=p.charCodeAt(d)<<16-d%2*16;return a.create(i,s*2)}},o.Utf16LE={stringify:function(p){for(var s=p.words,i=p.sigBytes,d=[],c=0;c<i;c+=2){var f=u(s[c>>>2]>>>16-c%4*8&65535);d.push(String.fromCharCode(f))}return d.join("")},parse:function(p){for(var s=p.length,i=[],d=0;d<s;d++)i[d>>>1]|=u(p.charCodeAt(d)<<16-d%2*16);return a.create(i,s*2)}};function u(p){return p<<8&4278255360|p>>>8&16711935}}(),t.enc.Utf16})}(Qi)),Qi.exports}var Yi={exports:{}},Is;function tr(){return Is||(Is=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.enc;o.Base64={stringify:function(p){var s=p.words,i=p.sigBytes,d=this._map;p.clamp();for(var c=[],f=0;f<i;f+=3)for(var h=s[f>>>2]>>>24-f%4*8&255,v=s[f+1>>>2]>>>24-(f+1)%4*8&255,m=s[f+2>>>2]>>>24-(f+2)%4*8&255,g=h<<16|v<<8|m,x=0;x<4&&f+x*.75<i;x++)c.push(d.charAt(g>>>6*(3-x)&63));var y=d.charAt(64);if(y)for(;c.length%4;)c.push(y);return c.join("")},parse:function(p){var s=p.length,i=this._map,d=this._reverseMap;if(!d){d=this._reverseMap=[];for(var c=0;c<i.length;c++)d[i.charCodeAt(c)]=c}var f=i.charAt(64);if(f){var h=p.indexOf(f);h!==-1&&(s=h)}return u(p,s,d)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function u(p,s,i){for(var d=[],c=0,f=0;f<s;f++)if(f%4){var h=i[p.charCodeAt(f-1)]<<f%4*2,v=i[p.charCodeAt(f)]>>>6-f%4*2,m=h|v;d[c>>>2]|=m<<24-c%4*8,c++}return a.create(d,c)}}(),t.enc.Base64})}(Yi)),Yi.exports}var Xi={exports:{}},Ds;function j1(){return Ds||(Ds=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.enc;o.Base64url={stringify:function(p,s){s===void 0&&(s=!0);var i=p.words,d=p.sigBytes,c=s?this._safe_map:this._map;p.clamp();for(var f=[],h=0;h<d;h+=3)for(var v=i[h>>>2]>>>24-h%4*8&255,m=i[h+1>>>2]>>>24-(h+1)%4*8&255,g=i[h+2>>>2]>>>24-(h+2)%4*8&255,x=v<<16|m<<8|g,y=0;y<4&&h+y*.75<d;y++)f.push(c.charAt(x>>>6*(3-y)&63));var w=c.charAt(64);if(w)for(;f.length%4;)f.push(w);return f.join("")},parse:function(p,s){s===void 0&&(s=!0);var i=p.length,d=s?this._safe_map:this._map,c=this._reverseMap;if(!c){c=this._reverseMap=[];for(var f=0;f<d.length;f++)c[d.charCodeAt(f)]=f}var h=d.charAt(64);if(h){var v=p.indexOf(h);v!==-1&&(i=v)}return u(p,i,c)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function u(p,s,i){for(var d=[],c=0,f=0;f<s;f++)if(f%4){var h=i[p.charCodeAt(f-1)]<<f%4*2,v=i[p.charCodeAt(f)]>>>6-f%4*2,m=h|v;d[c>>>2]|=m<<24-c%4*8,c++}return a.create(d,c)}}(),t.enc.Base64url})}(Xi)),Xi.exports}var Zi={exports:{}},Rs;function rr(){return Rs||(Rs=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.algo,s=[];(function(){for(var v=0;v<64;v++)s[v]=n.abs(n.sin(v+1))*4294967296|0})();var i=p.MD5=u.extend({_doReset:function(){this._hash=new o.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(v,m){for(var g=0;g<16;g++){var x=m+g,y=v[x];v[x]=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360}var w=this._hash.words,k=v[m+0],T=v[m+1],I=v[m+2],D=v[m+3],X=v[m+4],V=v[m+5],E=v[m+6],A=v[m+7],C=v[m+8],F=v[m+9],j=v[m+10],P=v[m+11],J=v[m+12],$=v[m+13],U=v[m+14],K=v[m+15],L=w[0],O=w[1],H=w[2],W=w[3];L=d(L,O,H,W,k,7,s[0]),W=d(W,L,O,H,T,12,s[1]),H=d(H,W,L,O,I,17,s[2]),O=d(O,H,W,L,D,22,s[3]),L=d(L,O,H,W,X,7,s[4]),W=d(W,L,O,H,V,12,s[5]),H=d(H,W,L,O,E,17,s[6]),O=d(O,H,W,L,A,22,s[7]),L=d(L,O,H,W,C,7,s[8]),W=d(W,L,O,H,F,12,s[9]),H=d(H,W,L,O,j,17,s[10]),O=d(O,H,W,L,P,22,s[11]),L=d(L,O,H,W,J,7,s[12]),W=d(W,L,O,H,$,12,s[13]),H=d(H,W,L,O,U,17,s[14]),O=d(O,H,W,L,K,22,s[15]),L=c(L,O,H,W,T,5,s[16]),W=c(W,L,O,H,E,9,s[17]),H=c(H,W,L,O,P,14,s[18]),O=c(O,H,W,L,k,20,s[19]),L=c(L,O,H,W,V,5,s[20]),W=c(W,L,O,H,j,9,s[21]),H=c(H,W,L,O,K,14,s[22]),O=c(O,H,W,L,X,20,s[23]),L=c(L,O,H,W,F,5,s[24]),W=c(W,L,O,H,U,9,s[25]),H=c(H,W,L,O,D,14,s[26]),O=c(O,H,W,L,C,20,s[27]),L=c(L,O,H,W,$,5,s[28]),W=c(W,L,O,H,I,9,s[29]),H=c(H,W,L,O,A,14,s[30]),O=c(O,H,W,L,J,20,s[31]),L=f(L,O,H,W,V,4,s[32]),W=f(W,L,O,H,C,11,s[33]),H=f(H,W,L,O,P,16,s[34]),O=f(O,H,W,L,U,23,s[35]),L=f(L,O,H,W,T,4,s[36]),W=f(W,L,O,H,X,11,s[37]),H=f(H,W,L,O,A,16,s[38]),O=f(O,H,W,L,j,23,s[39]),L=f(L,O,H,W,$,4,s[40]),W=f(W,L,O,H,k,11,s[41]),H=f(H,W,L,O,D,16,s[42]),O=f(O,H,W,L,E,23,s[43]),L=f(L,O,H,W,F,4,s[44]),W=f(W,L,O,H,J,11,s[45]),H=f(H,W,L,O,K,16,s[46]),O=f(O,H,W,L,I,23,s[47]),L=h(L,O,H,W,k,6,s[48]),W=h(W,L,O,H,A,10,s[49]),H=h(H,W,L,O,U,15,s[50]),O=h(O,H,W,L,V,21,s[51]),L=h(L,O,H,W,J,6,s[52]),W=h(W,L,O,H,D,10,s[53]),H=h(H,W,L,O,j,15,s[54]),O=h(O,H,W,L,T,21,s[55]),L=h(L,O,H,W,C,6,s[56]),W=h(W,L,O,H,K,10,s[57]),H=h(H,W,L,O,E,15,s[58]),O=h(O,H,W,L,$,21,s[59]),L=h(L,O,H,W,X,6,s[60]),W=h(W,L,O,H,P,10,s[61]),H=h(H,W,L,O,I,15,s[62]),O=h(O,H,W,L,F,21,s[63]),w[0]=w[0]+L|0,w[1]=w[1]+O|0,w[2]=w[2]+H|0,w[3]=w[3]+W|0},_doFinalize:function(){var v=this._data,m=v.words,g=this._nDataBytes*8,x=v.sigBytes*8;m[x>>>5]|=128<<24-x%32;var y=n.floor(g/4294967296),w=g;m[(x+64>>>9<<4)+15]=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360,m[(x+64>>>9<<4)+14]=(w<<8|w>>>24)&16711935|(w<<24|w>>>8)&4278255360,v.sigBytes=(m.length+1)*4,this._process();for(var k=this._hash,T=k.words,I=0;I<4;I++){var D=T[I];T[I]=(D<<8|D>>>24)&16711935|(D<<24|D>>>8)&4278255360}return k},clone:function(){var v=u.clone.call(this);return v._hash=this._hash.clone(),v}});function d(v,m,g,x,y,w,k){var T=v+(m&g|~m&x)+y+k;return(T<<w|T>>>32-w)+m}function c(v,m,g,x,y,w,k){var T=v+(m&x|g&~x)+y+k;return(T<<w|T>>>32-w)+m}function f(v,m,g,x,y,w,k){var T=v+(m^g^x)+y+k;return(T<<w|T>>>32-w)+m}function h(v,m,g,x,y,w,k){var T=v+(g^(m|~x))+y+k;return(T<<w|T>>>32-w)+m}l.MD5=u._createHelper(i),l.HmacMD5=u._createHmacHelper(i)}(Math),t.MD5})}(Zi)),Zi.exports}var Ji={exports:{}},Os;function e0(){return Os||(Os=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=l.Hasher,u=n.algo,p=[],s=u.SHA1=o.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(i,d){for(var c=this._hash.words,f=c[0],h=c[1],v=c[2],m=c[3],g=c[4],x=0;x<80;x++){if(x<16)p[x]=i[d+x]|0;else{var y=p[x-3]^p[x-8]^p[x-14]^p[x-16];p[x]=y<<1|y>>>31}var w=(f<<5|f>>>27)+g+p[x];x<20?w+=(h&v|~h&m)+1518500249:x<40?w+=(h^v^m)+1859775393:x<60?w+=(h&v|h&m|v&m)-1894007588:w+=(h^v^m)-899497514,g=m,m=v,v=h<<30|h>>>2,h=f,f=w}c[0]=c[0]+f|0,c[1]=c[1]+h|0,c[2]=c[2]+v|0,c[3]=c[3]+m|0,c[4]=c[4]+g|0},_doFinalize:function(){var i=this._data,d=i.words,c=this._nDataBytes*8,f=i.sigBytes*8;return d[f>>>5]|=128<<24-f%32,d[(f+64>>>9<<4)+14]=Math.floor(c/4294967296),d[(f+64>>>9<<4)+15]=c,i.sigBytes=d.length*4,this._process(),this._hash},clone:function(){var i=o.clone.call(this);return i._hash=this._hash.clone(),i}});n.SHA1=o._createHelper(s),n.HmacSHA1=o._createHmacHelper(s)}(),t.SHA1})}(Ji)),Ji.exports}var eo={exports:{}},Ps;function fa(){return Ps||(Ps=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.algo,s=[],i=[];(function(){function f(g){for(var x=n.sqrt(g),y=2;y<=x;y++)if(!(g%y))return!1;return!0}function h(g){return(g-(g|0))*4294967296|0}for(var v=2,m=0;m<64;)f(v)&&(m<8&&(s[m]=h(n.pow(v,1/2))),i[m]=h(n.pow(v,1/3)),m++),v++})();var d=[],c=p.SHA256=u.extend({_doReset:function(){this._hash=new o.init(s.slice(0))},_doProcessBlock:function(f,h){for(var v=this._hash.words,m=v[0],g=v[1],x=v[2],y=v[3],w=v[4],k=v[5],T=v[6],I=v[7],D=0;D<64;D++){if(D<16)d[D]=f[h+D]|0;else{var X=d[D-15],V=(X<<25|X>>>7)^(X<<14|X>>>18)^X>>>3,E=d[D-2],A=(E<<15|E>>>17)^(E<<13|E>>>19)^E>>>10;d[D]=V+d[D-7]+A+d[D-16]}var C=w&k^~w&T,F=m&g^m&x^g&x,j=(m<<30|m>>>2)^(m<<19|m>>>13)^(m<<10|m>>>22),P=(w<<26|w>>>6)^(w<<21|w>>>11)^(w<<7|w>>>25),J=I+P+C+i[D]+d[D],$=j+F;I=T,T=k,k=w,w=y+J|0,y=x,x=g,g=m,m=J+$|0}v[0]=v[0]+m|0,v[1]=v[1]+g|0,v[2]=v[2]+x|0,v[3]=v[3]+y|0,v[4]=v[4]+w|0,v[5]=v[5]+k|0,v[6]=v[6]+T|0,v[7]=v[7]+I|0},_doFinalize:function(){var f=this._data,h=f.words,v=this._nDataBytes*8,m=f.sigBytes*8;return h[m>>>5]|=128<<24-m%32,h[(m+64>>>9<<4)+14]=n.floor(v/4294967296),h[(m+64>>>9<<4)+15]=v,f.sigBytes=h.length*4,this._process(),this._hash},clone:function(){var f=u.clone.call(this);return f._hash=this._hash.clone(),f}});l.SHA256=u._createHelper(c),l.HmacSHA256=u._createHmacHelper(c)}(Math),t.SHA256})}(eo)),eo.exports}var to={exports:{}},Ns;function H1(){return Ns||(Ns=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),fa())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.algo,u=o.SHA256,p=o.SHA224=u.extend({_doReset:function(){this._hash=new a.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var s=u._doFinalize.call(this);return s.sigBytes-=4,s}});n.SHA224=u._createHelper(p),n.HmacSHA224=u._createHmacHelper(p)}(),t.SHA224})}(to)),to.exports}var ro={exports:{}},Ms;function t0(){return Ms||(Ms=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ei())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.Hasher,o=n.x64,u=o.Word,p=o.WordArray,s=n.algo;function i(){return u.create.apply(u,arguments)}var d=[i(1116352408,3609767458),i(1899447441,602891725),i(3049323471,3964484399),i(3921009573,2173295548),i(961987163,4081628472),i(1508970993,3053834265),i(2453635748,2937671579),i(2870763221,3664609560),i(3624381080,2734883394),i(310598401,1164996542),i(607225278,1323610764),i(1426881987,3590304994),i(1925078388,4068182383),i(2162078206,991336113),i(2614888103,633803317),i(3248222580,3479774868),i(3835390401,2666613458),i(4022224774,944711139),i(264347078,2341262773),i(604807628,2007800933),i(770255983,1495990901),i(1249150122,1856431235),i(1555081692,3175218132),i(1996064986,2198950837),i(2554220882,3999719339),i(2821834349,766784016),i(2952996808,2566594879),i(3210313671,3203337956),i(3336571891,1034457026),i(3584528711,2466948901),i(113926993,3758326383),i(338241895,168717936),i(666307205,1188179964),i(773529912,1546045734),i(1294757372,1522805485),i(1396182291,2643833823),i(1695183700,2343527390),i(1986661051,1014477480),i(2177026350,1206759142),i(2456956037,344077627),i(2730485921,1290863460),i(2820302411,3158454273),i(3259730800,3505952657),i(3345764771,106217008),i(3516065817,3606008344),i(3600352804,1432725776),i(4094571909,1467031594),i(275423344,851169720),i(430227734,3100823752),i(506948616,1363258195),i(659060556,3750685593),i(883997877,3785050280),i(958139571,3318307427),i(1322822218,3812723403),i(1537002063,2003034995),i(1747873779,3602036899),i(1955562222,1575990012),i(2024104815,1125592928),i(2227730452,2716904306),i(2361852424,442776044),i(2428436474,593698344),i(2756734187,3733110249),i(3204031479,2999351573),i(3329325298,3815920427),i(3391569614,3928383900),i(3515267271,566280711),i(3940187606,3454069534),i(4118630271,4000239992),i(116418474,1914138554),i(174292421,2731055270),i(289380356,3203993006),i(460393269,320620315),i(685471733,587496836),i(852142971,1086792851),i(1017036298,365543100),i(1126000580,2618297676),i(1288033470,3409855158),i(1501505948,4234509866),i(1607167915,987167468),i(1816402316,1246189591)],c=[];(function(){for(var h=0;h<80;h++)c[h]=i()})();var f=s.SHA512=a.extend({_doReset:function(){this._hash=new p.init([new u.init(1779033703,4089235720),new u.init(3144134277,2227873595),new u.init(1013904242,4271175723),new u.init(2773480762,1595750129),new u.init(1359893119,2917565137),new u.init(2600822924,725511199),new u.init(528734635,4215389547),new u.init(1541459225,327033209)])},_doProcessBlock:function(h,v){for(var m=this._hash.words,g=m[0],x=m[1],y=m[2],w=m[3],k=m[4],T=m[5],I=m[6],D=m[7],X=g.high,V=g.low,E=x.high,A=x.low,C=y.high,F=y.low,j=w.high,P=w.low,J=k.high,$=k.low,U=T.high,K=T.low,L=I.high,O=I.low,H=D.high,W=D.low,Z=X,re=V,oe=E,ae=A,b=C,_=F,R=j,G=P,ee=J,te=$,se=U,z=K,S=L,B=O,Y=H,ie=W,ue=0;ue<80;ue++){var ce,me,ge=c[ue];if(ue<16)me=ge.high=h[v+ue*2]|0,ce=ge.low=h[v+ue*2+1]|0;else{var Ce=c[ue-15],Te=Ce.high,Be=Ce.low,kt=(Te>>>1|Be<<31)^(Te>>>8|Be<<24)^Te>>>7,Lt=(Be>>>1|Te<<31)^(Be>>>8|Te<<24)^(Be>>>7|Te<<25),Ut=c[ue-2],Tt=Ut.high,qt=Ut.low,ri=(Tt>>>19|qt<<13)^(Tt<<3|qt>>>29)^Tt>>>6,or=(qt>>>19|Tt<<13)^(qt<<3|Tt>>>29)^(qt>>>6|Tt<<26),Jr=c[ue-7],en=Jr.high,ni=Jr.low,kr=c[ue-16],ii=kr.high,tn=kr.low;ce=Lt+ni,me=kt+en+(ce>>>0<Lt>>>0?1:0),ce=ce+or,me=me+ri+(ce>>>0<or>>>0?1:0),ce=ce+tn,me=me+ii+(ce>>>0<tn>>>0?1:0),ge.high=me,ge.low=ce}var oi=ee&se^~ee&S,rn=te&z^~te&B,ai=Z&oe^Z&b^oe&b,si=re&ae^re&_^ae&_,li=(Z>>>28|re<<4)^(Z<<30|re>>>2)^(Z<<25|re>>>7),nn=(re>>>28|Z<<4)^(re<<30|Z>>>2)^(re<<25|Z>>>7),ui=(ee>>>14|te<<18)^(ee>>>18|te<<14)^(ee<<23|te>>>9),ci=(te>>>14|ee<<18)^(te>>>18|ee<<14)^(te<<23|ee>>>9),on=d[ue],fi=on.high,an=on.low,Ge=ie+ci,dt=Y+ui+(Ge>>>0<ie>>>0?1:0),Ge=Ge+rn,dt=dt+oi+(Ge>>>0<rn>>>0?1:0),Ge=Ge+an,dt=dt+fi+(Ge>>>0<an>>>0?1:0),Ge=Ge+ce,dt=dt+me+(Ge>>>0<ce>>>0?1:0),sn=nn+si,hi=li+ai+(sn>>>0<nn>>>0?1:0);Y=S,ie=B,S=se,B=z,se=ee,z=te,te=G+Ge|0,ee=R+dt+(te>>>0<G>>>0?1:0)|0,R=b,G=_,b=oe,_=ae,oe=Z,ae=re,re=Ge+sn|0,Z=dt+hi+(re>>>0<Ge>>>0?1:0)|0}V=g.low=V+re,g.high=X+Z+(V>>>0<re>>>0?1:0),A=x.low=A+ae,x.high=E+oe+(A>>>0<ae>>>0?1:0),F=y.low=F+_,y.high=C+b+(F>>>0<_>>>0?1:0),P=w.low=P+G,w.high=j+R+(P>>>0<G>>>0?1:0),$=k.low=$+te,k.high=J+ee+($>>>0<te>>>0?1:0),K=T.low=K+z,T.high=U+se+(K>>>0<z>>>0?1:0),O=I.low=O+B,I.high=L+S+(O>>>0<B>>>0?1:0),W=D.low=W+ie,D.high=H+Y+(W>>>0<ie>>>0?1:0)},_doFinalize:function(){var h=this._data,v=h.words,m=this._nDataBytes*8,g=h.sigBytes*8;v[g>>>5]|=128<<24-g%32,v[(g+128>>>10<<5)+30]=Math.floor(m/4294967296),v[(g+128>>>10<<5)+31]=m,h.sigBytes=v.length*4,this._process();var x=this._hash.toX32();return x},clone:function(){var h=a.clone.call(this);return h._hash=this._hash.clone(),h},blockSize:1024/32});n.SHA512=a._createHelper(f),n.HmacSHA512=a._createHmacHelper(f)}(),t.SHA512})}(ro)),ro.exports}var no={exports:{}},Ls;function V1(){return Ls||(Ls=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ei(),t0())})(xe,function(t){return function(){var n=t,l=n.x64,a=l.Word,o=l.WordArray,u=n.algo,p=u.SHA512,s=u.SHA384=p.extend({_doReset:function(){this._hash=new o.init([new a.init(3418070365,3238371032),new a.init(1654270250,914150663),new a.init(2438529370,812702999),new a.init(355462360,4144912697),new a.init(1731405415,4290775857),new a.init(2394180231,1750603025),new a.init(3675008525,1694076839),new a.init(1203062813,3204075428)])},_doFinalize:function(){var i=p._doFinalize.call(this);return i.sigBytes-=16,i}});n.SHA384=p._createHelper(s),n.HmacSHA384=p._createHmacHelper(s)}(),t.SHA384})}(no)),no.exports}var io={exports:{}},Us;function W1(){return Us||(Us=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ei())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.x64,s=p.Word,i=l.algo,d=[],c=[],f=[];(function(){for(var m=1,g=0,x=0;x<24;x++){d[m+5*g]=(x+1)*(x+2)/2%64;var y=g%5,w=(2*m+3*g)%5;m=y,g=w}for(var m=0;m<5;m++)for(var g=0;g<5;g++)c[m+5*g]=g+(2*m+3*g)%5*5;for(var k=1,T=0;T<24;T++){for(var I=0,D=0,X=0;X<7;X++){if(k&1){var V=(1<<X)-1;V<32?D^=1<<V:I^=1<<V-32}k&128?k=k<<1^113:k<<=1}f[T]=s.create(I,D)}})();var h=[];(function(){for(var m=0;m<25;m++)h[m]=s.create()})();var v=i.SHA3=u.extend({cfg:u.cfg.extend({outputLength:512}),_doReset:function(){for(var m=this._state=[],g=0;g<25;g++)m[g]=new s.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(m,g){for(var x=this._state,y=this.blockSize/2,w=0;w<y;w++){var k=m[g+2*w],T=m[g+2*w+1];k=(k<<8|k>>>24)&16711935|(k<<24|k>>>8)&4278255360,T=(T<<8|T>>>24)&16711935|(T<<24|T>>>8)&4278255360;var I=x[w];I.high^=T,I.low^=k}for(var D=0;D<24;D++){for(var X=0;X<5;X++){for(var V=0,E=0,A=0;A<5;A++){var I=x[X+5*A];V^=I.high,E^=I.low}var C=h[X];C.high=V,C.low=E}for(var X=0;X<5;X++)for(var F=h[(X+4)%5],j=h[(X+1)%5],P=j.high,J=j.low,V=F.high^(P<<1|J>>>31),E=F.low^(J<<1|P>>>31),A=0;A<5;A++){var I=x[X+5*A];I.high^=V,I.low^=E}for(var $=1;$<25;$++){var V,E,I=x[$],U=I.high,K=I.low,L=d[$];L<32?(V=U<<L|K>>>32-L,E=K<<L|U>>>32-L):(V=K<<L-32|U>>>64-L,E=U<<L-32|K>>>64-L);var O=h[c[$]];O.high=V,O.low=E}var H=h[0],W=x[0];H.high=W.high,H.low=W.low;for(var X=0;X<5;X++)for(var A=0;A<5;A++){var $=X+5*A,I=x[$],Z=h[$],re=h[(X+1)%5+5*A],oe=h[(X+2)%5+5*A];I.high=Z.high^~re.high&oe.high,I.low=Z.low^~re.low&oe.low}var I=x[0],ae=f[D];I.high^=ae.high,I.low^=ae.low}},_doFinalize:function(){var m=this._data,g=m.words;this._nDataBytes*8;var x=m.sigBytes*8,y=this.blockSize*32;g[x>>>5]|=1<<24-x%32,g[(n.ceil((x+1)/y)*y>>>5)-1]|=128,m.sigBytes=g.length*4,this._process();for(var w=this._state,k=this.cfg.outputLength/8,T=k/8,I=[],D=0;D<T;D++){var X=w[D],V=X.high,E=X.low;V=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360,E=(E<<8|E>>>24)&16711935|(E<<24|E>>>8)&4278255360,I.push(E),I.push(V)}return new o.init(I,k)},clone:function(){for(var m=u.clone.call(this),g=m._state=this._state.slice(0),x=0;x<25;x++)g[x]=g[x].clone();return m}});l.SHA3=u._createHelper(v),l.HmacSHA3=u._createHmacHelper(v)}(Math),t.SHA3})}(io)),io.exports}var oo={exports:{}},qs;function K1(){return qs||(qs=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){/** @preserve
13
+ */Object.defineProperty(Jn,"__esModule",{value:!0});var hr=typeof window!="undefined"?window.proxy||window:{},Yu=function(e){hr!=null&&hr.__POWERED_BY_QIANKUN__&&(window.moudleQiankunAppLifeCycles||(window.moudleQiankunAppLifeCycles={}),hr.qiankunName&&(window.moudleQiankunAppLifeCycles[hr.qiankunName]=e))};Jn.default=Yu;var o1=Jn.qiankunWindow=hr;Jn.renderWithQiankun=Yu;const a1="/",s1=o1||window,ca=s1.meta.vite.micro.type||Zn.QIANKUN,Xu=ca===Zn.WUJIE,Zu=ca===Zn.QIANKUN,Ju=ca===Zn.MICROAPP,l1=window.top!==window.self||Xu||Zu||Ju;console.log("🚀 ~ isNested:",l1,Xu,Zu,Ju);const u1=location.protocol==="https:",c1=location.hostname,f1=u1?"wss:":"ws:",h1=location.port,p1=location.origin,As=`${f1}//${location.host}/ws`;window.meta.graph.savePath,window.meta.graph.graphPenPath,window.meta.graph.templatePath,window.meta.graph.graphImgUploadPath;const Ie=Re.create({baseURL:p1,timeout:window.meta.axios.timeout||12e4,withCredentials:!1,paramsSerializer:e=>Sp.stringify(e)});Ie.interceptors.request.use(e=>(e.headers["x-token"]="ewoglCJhbGcilDogpc3",e),e=>Promise.reject(e));Ie.interceptors.response.use(e=>{const{data:r}=e;return Promise.resolve(r)},e=>Promise.reject(e));function d1(e,r={},t={}){return new Promise(n=>{Ie.get(e,he({params:r},t)).then(l=>n({res:l,err:null})).catch(l=>n({res:null,err:l}))})}function m1(e,r={},t={}){return new Promise(n=>{Ie.post(e,r,t).then(l=>n({res:l,err:null})).catch(l=>n({res:null,err:l}))})}function v1(e,r={},t={}){return Ie.get(e,he({params:r},t))}function y1(e,r={},t={}){return Ie.post(e,r,t)}function g1(e,r={}){return Ie.get(`/filehandle/${e}`,{params:r})}function x1(e,r={},t={}){return Ie.post(`/filehandle/${e}`,r,t)}function b1(e,r={}){return Ie.get(`/user/${e}`,{params:r})}function w1(e,r={},t={}){return Ie.post(`/user/${e}`,r,t)}function _1(e,r={}){return Ie.get(`${e}`,r.local?{params:r,baseURL:a1}:{params:r})}function E1(e,r={}){return Ie.get(`/media/${e}/`,{params:r})}function A1(e,r={},t={}){return Ie.post(`/media/${e}/`,r,t)}function C1(e,r={}){return Ie.get(`/${window.meta.app.isFactory?window.meta.factory.singo_prefix||"acproxy/common":"common"}/${e}/`,{params:r})}function S1(e,r={},t={}){return Ie.post(`/${window.meta.app.isFactory?window.meta.factory.singo_prefix||"acproxy/common":"common"}/${e}/`,r,t)}function B1(e,r={}){return Ie.get(`/history/${e}`,{params:r})}function k1(e,r={},t={}){return Ie.post(`/history/${e}`,r,t)}function T1(e,r={}){return Ie.get(`/scada/${e}`,{params:r})}function F1(e,r={},t={}){return Ie.post(`/scada/${e}`,r,t)}function I1(e,r={}){return Ie.get(`/common/factory/${e}`,{params:r})}function D1(e,r={},t={}){return Ie.post(`/common/factory/${e}`,r,t)}function R1(e,r={}){return Ie.get(`/factory/${e}`,{params:r})}function O1(e,r={},t={}){return Ie.post(`/factory/${e}`,r,t)}const jo={getApi:d1,postApi:m1,getFileApi:g1,postFileApi:x1,getBaseApi:v1,postBaseApi:y1,getUserApi:b1,postUserApi:w1,getGraphApi:_1,getMediaApi:E1,postMediaApi:A1,getScadaApi:T1,postScadaApi:F1,getCommonApi:C1,postCommonApi:S1,getHistoryApi:B1,postHistoryApi:k1,getFactoryApi:R1,postFactoryApi:O1,getCommonFactoryApi:I1,postCommonFactoryApi:D1};function P1(e){return{all:e=e||new Map,on:function(r,t){var n=e.get(r);n?n.push(t):e.set(r,[t])},off:function(r,t){var n=e.get(r);n&&(t?n.splice(n.indexOf(t)>>>0,1):e.set(r,[]))},emit:function(r,t){var n=e.get(r);n&&n.slice().map(function(l){l(t)}),(n=e.get("*"))&&n.slice().map(function(l){l(r,t)})}}}const Ho=P1();function Cs(e){return Object.prototype.toString.call(e).slice(8,-1)}function Ss(e){if(typeof e!="string")return!1;const r=/^-?\d+(\.\d+)?$/;return e.trim()!==""&&r.test(e.trim())}var N1={exports:{}};function Rr(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Wi={exports:{}},Bs;function Ae(){return Bs||(Bs=1,function(e,r){(function(t,n){e.exports=n()})(xe,function(){var t=t||function(n,l){var a;if(typeof window!="undefined"&&window.crypto&&(a=window.crypto),typeof self!="undefined"&&self.crypto&&(a=self.crypto),typeof globalThis!="undefined"&&globalThis.crypto&&(a=globalThis.crypto),!a&&typeof window!="undefined"&&window.msCrypto&&(a=window.msCrypto),!a&&typeof xe!="undefined"&&xe.crypto&&(a=xe.crypto),!a&&typeof Rr=="function")try{a=ru}catch(x){}var o=function(){if(a){if(typeof a.getRandomValues=="function")try{return a.getRandomValues(new Uint32Array(1))[0]}catch(x){}if(typeof a.randomBytes=="function")try{return a.randomBytes(4).readInt32LE()}catch(x){}}throw new Error("Native crypto module could not be used to get secure random number.")},u=Object.create||function(){function x(){}return function(y){var w;return x.prototype=y,w=new x,x.prototype=null,w}}(),p={},s=p.lib={},i=s.Base=function(){return{extend:function(x){var y=u(this);return x&&y.mixIn(x),(!y.hasOwnProperty("init")||this.init===y.init)&&(y.init=function(){y.$super.init.apply(this,arguments)}),y.init.prototype=y,y.$super=this,y},create:function(){var x=this.extend();return x.init.apply(x,arguments),x},init:function(){},mixIn:function(x){for(var y in x)x.hasOwnProperty(y)&&(this[y]=x[y]);x.hasOwnProperty("toString")&&(this.toString=x.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),d=s.WordArray=i.extend({init:function(x,y){x=this.words=x||[],y!=l?this.sigBytes=y:this.sigBytes=x.length*4},toString:function(x){return(x||f).stringify(this)},concat:function(x){var y=this.words,w=x.words,k=this.sigBytes,T=x.sigBytes;if(this.clamp(),k%4)for(var I=0;I<T;I++){var D=w[I>>>2]>>>24-I%4*8&255;y[k+I>>>2]|=D<<24-(k+I)%4*8}else for(var X=0;X<T;X+=4)y[k+X>>>2]=w[X>>>2];return this.sigBytes+=T,this},clamp:function(){var x=this.words,y=this.sigBytes;x[y>>>2]&=4294967295<<32-y%4*8,x.length=n.ceil(y/4)},clone:function(){var x=i.clone.call(this);return x.words=this.words.slice(0),x},random:function(x){for(var y=[],w=0;w<x;w+=4)y.push(o());return new d.init(y,x)}}),c=p.enc={},f=c.Hex={stringify:function(x){for(var y=x.words,w=x.sigBytes,k=[],T=0;T<w;T++){var I=y[T>>>2]>>>24-T%4*8&255;k.push((I>>>4).toString(16)),k.push((I&15).toString(16))}return k.join("")},parse:function(x){for(var y=x.length,w=[],k=0;k<y;k+=2)w[k>>>3]|=parseInt(x.substr(k,2),16)<<24-k%8*4;return new d.init(w,y/2)}},h=c.Latin1={stringify:function(x){for(var y=x.words,w=x.sigBytes,k=[],T=0;T<w;T++){var I=y[T>>>2]>>>24-T%4*8&255;k.push(String.fromCharCode(I))}return k.join("")},parse:function(x){for(var y=x.length,w=[],k=0;k<y;k++)w[k>>>2]|=(x.charCodeAt(k)&255)<<24-k%4*8;return new d.init(w,y)}},v=c.Utf8={stringify:function(x){try{return decodeURIComponent(escape(h.stringify(x)))}catch(y){throw new Error("Malformed UTF-8 data")}},parse:function(x){return h.parse(unescape(encodeURIComponent(x)))}},m=s.BufferedBlockAlgorithm=i.extend({reset:function(){this._data=new d.init,this._nDataBytes=0},_append:function(x){typeof x=="string"&&(x=v.parse(x)),this._data.concat(x),this._nDataBytes+=x.sigBytes},_process:function(x){var y,w=this._data,k=w.words,T=w.sigBytes,I=this.blockSize,D=I*4,X=T/D;x?X=n.ceil(X):X=n.max((X|0)-this._minBufferSize,0);var V=X*I,E=n.min(V*4,T);if(V){for(var A=0;A<V;A+=I)this._doProcessBlock(k,A);y=k.splice(0,V),w.sigBytes-=E}return new d.init(y,E)},clone:function(){var x=i.clone.call(this);return x._data=this._data.clone(),x},_minBufferSize:0});s.Hasher=m.extend({cfg:i.extend(),init:function(x){this.cfg=this.cfg.extend(x),this.reset()},reset:function(){m.reset.call(this),this._doReset()},update:function(x){return this._append(x),this._process(),this},finalize:function(x){x&&this._append(x);var y=this._doFinalize();return y},blockSize:16,_createHelper:function(x){return function(y,w){return new x.init(w).finalize(y)}},_createHmacHelper:function(x){return function(y,w){return new g.HMAC.init(x,w).finalize(y)}}});var g=p.algo={};return p}(Math);return t})}(Wi)),Wi.exports}var Ki={exports:{}},ks;function ei(){return ks||(ks=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.Base,u=a.WordArray,p=l.x64={};p.Word=o.extend({init:function(s,i){this.high=s,this.low=i}}),p.WordArray=o.extend({init:function(s,i){s=this.words=s||[],i!=n?this.sigBytes=i:this.sigBytes=s.length*8},toX32:function(){for(var s=this.words,i=s.length,d=[],c=0;c<i;c++){var f=s[c];d.push(f.high),d.push(f.low)}return u.create(d,this.sigBytes)},clone:function(){for(var s=o.clone.call(this),i=s.words=this.words.slice(0),d=i.length,c=0;c<d;c++)i[c]=i[c].clone();return s}})}(),t})}(Ki)),Ki.exports}var Gi={exports:{}},Ts;function M1(){return Ts||(Ts=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){if(typeof ArrayBuffer=="function"){var n=t,l=n.lib,a=l.WordArray,o=a.init,u=a.init=function(p){if(p instanceof ArrayBuffer&&(p=new Uint8Array(p)),(p instanceof Int8Array||typeof Uint8ClampedArray!="undefined"&&p instanceof Uint8ClampedArray||p instanceof Int16Array||p instanceof Uint16Array||p instanceof Int32Array||p instanceof Uint32Array||p instanceof Float32Array||p instanceof Float64Array)&&(p=new Uint8Array(p.buffer,p.byteOffset,p.byteLength)),p instanceof Uint8Array){for(var s=p.byteLength,i=[],d=0;d<s;d++)i[d>>>2]|=p[d]<<24-d%4*8;o.call(this,i,s)}else o.apply(this,arguments)};u.prototype=a}}(),t.lib.WordArray})}(Gi)),Gi.exports}var Qi={exports:{}},Fs;function L1(){return Fs||(Fs=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.enc;o.Utf16=o.Utf16BE={stringify:function(p){for(var s=p.words,i=p.sigBytes,d=[],c=0;c<i;c+=2){var f=s[c>>>2]>>>16-c%4*8&65535;d.push(String.fromCharCode(f))}return d.join("")},parse:function(p){for(var s=p.length,i=[],d=0;d<s;d++)i[d>>>1]|=p.charCodeAt(d)<<16-d%2*16;return a.create(i,s*2)}},o.Utf16LE={stringify:function(p){for(var s=p.words,i=p.sigBytes,d=[],c=0;c<i;c+=2){var f=u(s[c>>>2]>>>16-c%4*8&65535);d.push(String.fromCharCode(f))}return d.join("")},parse:function(p){for(var s=p.length,i=[],d=0;d<s;d++)i[d>>>1]|=u(p.charCodeAt(d)<<16-d%2*16);return a.create(i,s*2)}};function u(p){return p<<8&4278255360|p>>>8&16711935}}(),t.enc.Utf16})}(Qi)),Qi.exports}var Yi={exports:{}},Is;function tr(){return Is||(Is=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.enc;o.Base64={stringify:function(p){var s=p.words,i=p.sigBytes,d=this._map;p.clamp();for(var c=[],f=0;f<i;f+=3)for(var h=s[f>>>2]>>>24-f%4*8&255,v=s[f+1>>>2]>>>24-(f+1)%4*8&255,m=s[f+2>>>2]>>>24-(f+2)%4*8&255,g=h<<16|v<<8|m,x=0;x<4&&f+x*.75<i;x++)c.push(d.charAt(g>>>6*(3-x)&63));var y=d.charAt(64);if(y)for(;c.length%4;)c.push(y);return c.join("")},parse:function(p){var s=p.length,i=this._map,d=this._reverseMap;if(!d){d=this._reverseMap=[];for(var c=0;c<i.length;c++)d[i.charCodeAt(c)]=c}var f=i.charAt(64);if(f){var h=p.indexOf(f);h!==-1&&(s=h)}return u(p,s,d)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function u(p,s,i){for(var d=[],c=0,f=0;f<s;f++)if(f%4){var h=i[p.charCodeAt(f-1)]<<f%4*2,v=i[p.charCodeAt(f)]>>>6-f%4*2,m=h|v;d[c>>>2]|=m<<24-c%4*8,c++}return a.create(d,c)}}(),t.enc.Base64})}(Yi)),Yi.exports}var Xi={exports:{}},Ds;function U1(){return Ds||(Ds=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.enc;o.Base64url={stringify:function(p,s){s===void 0&&(s=!0);var i=p.words,d=p.sigBytes,c=s?this._safe_map:this._map;p.clamp();for(var f=[],h=0;h<d;h+=3)for(var v=i[h>>>2]>>>24-h%4*8&255,m=i[h+1>>>2]>>>24-(h+1)%4*8&255,g=i[h+2>>>2]>>>24-(h+2)%4*8&255,x=v<<16|m<<8|g,y=0;y<4&&h+y*.75<d;y++)f.push(c.charAt(x>>>6*(3-y)&63));var w=c.charAt(64);if(w)for(;f.length%4;)f.push(w);return f.join("")},parse:function(p,s){s===void 0&&(s=!0);var i=p.length,d=s?this._safe_map:this._map,c=this._reverseMap;if(!c){c=this._reverseMap=[];for(var f=0;f<d.length;f++)c[d.charCodeAt(f)]=f}var h=d.charAt(64);if(h){var v=p.indexOf(h);v!==-1&&(i=v)}return u(p,i,c)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function u(p,s,i){for(var d=[],c=0,f=0;f<s;f++)if(f%4){var h=i[p.charCodeAt(f-1)]<<f%4*2,v=i[p.charCodeAt(f)]>>>6-f%4*2,m=h|v;d[c>>>2]|=m<<24-c%4*8,c++}return a.create(d,c)}}(),t.enc.Base64url})}(Xi)),Xi.exports}var Zi={exports:{}},Rs;function rr(){return Rs||(Rs=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.algo,s=[];(function(){for(var v=0;v<64;v++)s[v]=n.abs(n.sin(v+1))*4294967296|0})();var i=p.MD5=u.extend({_doReset:function(){this._hash=new o.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(v,m){for(var g=0;g<16;g++){var x=m+g,y=v[x];v[x]=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360}var w=this._hash.words,k=v[m+0],T=v[m+1],I=v[m+2],D=v[m+3],X=v[m+4],V=v[m+5],E=v[m+6],A=v[m+7],C=v[m+8],F=v[m+9],j=v[m+10],P=v[m+11],J=v[m+12],$=v[m+13],U=v[m+14],K=v[m+15],L=w[0],O=w[1],H=w[2],W=w[3];L=d(L,O,H,W,k,7,s[0]),W=d(W,L,O,H,T,12,s[1]),H=d(H,W,L,O,I,17,s[2]),O=d(O,H,W,L,D,22,s[3]),L=d(L,O,H,W,X,7,s[4]),W=d(W,L,O,H,V,12,s[5]),H=d(H,W,L,O,E,17,s[6]),O=d(O,H,W,L,A,22,s[7]),L=d(L,O,H,W,C,7,s[8]),W=d(W,L,O,H,F,12,s[9]),H=d(H,W,L,O,j,17,s[10]),O=d(O,H,W,L,P,22,s[11]),L=d(L,O,H,W,J,7,s[12]),W=d(W,L,O,H,$,12,s[13]),H=d(H,W,L,O,U,17,s[14]),O=d(O,H,W,L,K,22,s[15]),L=c(L,O,H,W,T,5,s[16]),W=c(W,L,O,H,E,9,s[17]),H=c(H,W,L,O,P,14,s[18]),O=c(O,H,W,L,k,20,s[19]),L=c(L,O,H,W,V,5,s[20]),W=c(W,L,O,H,j,9,s[21]),H=c(H,W,L,O,K,14,s[22]),O=c(O,H,W,L,X,20,s[23]),L=c(L,O,H,W,F,5,s[24]),W=c(W,L,O,H,U,9,s[25]),H=c(H,W,L,O,D,14,s[26]),O=c(O,H,W,L,C,20,s[27]),L=c(L,O,H,W,$,5,s[28]),W=c(W,L,O,H,I,9,s[29]),H=c(H,W,L,O,A,14,s[30]),O=c(O,H,W,L,J,20,s[31]),L=f(L,O,H,W,V,4,s[32]),W=f(W,L,O,H,C,11,s[33]),H=f(H,W,L,O,P,16,s[34]),O=f(O,H,W,L,U,23,s[35]),L=f(L,O,H,W,T,4,s[36]),W=f(W,L,O,H,X,11,s[37]),H=f(H,W,L,O,A,16,s[38]),O=f(O,H,W,L,j,23,s[39]),L=f(L,O,H,W,$,4,s[40]),W=f(W,L,O,H,k,11,s[41]),H=f(H,W,L,O,D,16,s[42]),O=f(O,H,W,L,E,23,s[43]),L=f(L,O,H,W,F,4,s[44]),W=f(W,L,O,H,J,11,s[45]),H=f(H,W,L,O,K,16,s[46]),O=f(O,H,W,L,I,23,s[47]),L=h(L,O,H,W,k,6,s[48]),W=h(W,L,O,H,A,10,s[49]),H=h(H,W,L,O,U,15,s[50]),O=h(O,H,W,L,V,21,s[51]),L=h(L,O,H,W,J,6,s[52]),W=h(W,L,O,H,D,10,s[53]),H=h(H,W,L,O,j,15,s[54]),O=h(O,H,W,L,T,21,s[55]),L=h(L,O,H,W,C,6,s[56]),W=h(W,L,O,H,K,10,s[57]),H=h(H,W,L,O,E,15,s[58]),O=h(O,H,W,L,$,21,s[59]),L=h(L,O,H,W,X,6,s[60]),W=h(W,L,O,H,P,10,s[61]),H=h(H,W,L,O,I,15,s[62]),O=h(O,H,W,L,F,21,s[63]),w[0]=w[0]+L|0,w[1]=w[1]+O|0,w[2]=w[2]+H|0,w[3]=w[3]+W|0},_doFinalize:function(){var v=this._data,m=v.words,g=this._nDataBytes*8,x=v.sigBytes*8;m[x>>>5]|=128<<24-x%32;var y=n.floor(g/4294967296),w=g;m[(x+64>>>9<<4)+15]=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360,m[(x+64>>>9<<4)+14]=(w<<8|w>>>24)&16711935|(w<<24|w>>>8)&4278255360,v.sigBytes=(m.length+1)*4,this._process();for(var k=this._hash,T=k.words,I=0;I<4;I++){var D=T[I];T[I]=(D<<8|D>>>24)&16711935|(D<<24|D>>>8)&4278255360}return k},clone:function(){var v=u.clone.call(this);return v._hash=this._hash.clone(),v}});function d(v,m,g,x,y,w,k){var T=v+(m&g|~m&x)+y+k;return(T<<w|T>>>32-w)+m}function c(v,m,g,x,y,w,k){var T=v+(m&x|g&~x)+y+k;return(T<<w|T>>>32-w)+m}function f(v,m,g,x,y,w,k){var T=v+(m^g^x)+y+k;return(T<<w|T>>>32-w)+m}function h(v,m,g,x,y,w,k){var T=v+(g^(m|~x))+y+k;return(T<<w|T>>>32-w)+m}l.MD5=u._createHelper(i),l.HmacMD5=u._createHmacHelper(i)}(Math),t.MD5})}(Zi)),Zi.exports}var Ji={exports:{}},Os;function e0(){return Os||(Os=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=l.Hasher,u=n.algo,p=[],s=u.SHA1=o.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(i,d){for(var c=this._hash.words,f=c[0],h=c[1],v=c[2],m=c[3],g=c[4],x=0;x<80;x++){if(x<16)p[x]=i[d+x]|0;else{var y=p[x-3]^p[x-8]^p[x-14]^p[x-16];p[x]=y<<1|y>>>31}var w=(f<<5|f>>>27)+g+p[x];x<20?w+=(h&v|~h&m)+1518500249:x<40?w+=(h^v^m)+1859775393:x<60?w+=(h&v|h&m|v&m)-1894007588:w+=(h^v^m)-899497514,g=m,m=v,v=h<<30|h>>>2,h=f,f=w}c[0]=c[0]+f|0,c[1]=c[1]+h|0,c[2]=c[2]+v|0,c[3]=c[3]+m|0,c[4]=c[4]+g|0},_doFinalize:function(){var i=this._data,d=i.words,c=this._nDataBytes*8,f=i.sigBytes*8;return d[f>>>5]|=128<<24-f%32,d[(f+64>>>9<<4)+14]=Math.floor(c/4294967296),d[(f+64>>>9<<4)+15]=c,i.sigBytes=d.length*4,this._process(),this._hash},clone:function(){var i=o.clone.call(this);return i._hash=this._hash.clone(),i}});n.SHA1=o._createHelper(s),n.HmacSHA1=o._createHmacHelper(s)}(),t.SHA1})}(Ji)),Ji.exports}var eo={exports:{}},Ps;function fa(){return Ps||(Ps=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.algo,s=[],i=[];(function(){function f(g){for(var x=n.sqrt(g),y=2;y<=x;y++)if(!(g%y))return!1;return!0}function h(g){return(g-(g|0))*4294967296|0}for(var v=2,m=0;m<64;)f(v)&&(m<8&&(s[m]=h(n.pow(v,1/2))),i[m]=h(n.pow(v,1/3)),m++),v++})();var d=[],c=p.SHA256=u.extend({_doReset:function(){this._hash=new o.init(s.slice(0))},_doProcessBlock:function(f,h){for(var v=this._hash.words,m=v[0],g=v[1],x=v[2],y=v[3],w=v[4],k=v[5],T=v[6],I=v[7],D=0;D<64;D++){if(D<16)d[D]=f[h+D]|0;else{var X=d[D-15],V=(X<<25|X>>>7)^(X<<14|X>>>18)^X>>>3,E=d[D-2],A=(E<<15|E>>>17)^(E<<13|E>>>19)^E>>>10;d[D]=V+d[D-7]+A+d[D-16]}var C=w&k^~w&T,F=m&g^m&x^g&x,j=(m<<30|m>>>2)^(m<<19|m>>>13)^(m<<10|m>>>22),P=(w<<26|w>>>6)^(w<<21|w>>>11)^(w<<7|w>>>25),J=I+P+C+i[D]+d[D],$=j+F;I=T,T=k,k=w,w=y+J|0,y=x,x=g,g=m,m=J+$|0}v[0]=v[0]+m|0,v[1]=v[1]+g|0,v[2]=v[2]+x|0,v[3]=v[3]+y|0,v[4]=v[4]+w|0,v[5]=v[5]+k|0,v[6]=v[6]+T|0,v[7]=v[7]+I|0},_doFinalize:function(){var f=this._data,h=f.words,v=this._nDataBytes*8,m=f.sigBytes*8;return h[m>>>5]|=128<<24-m%32,h[(m+64>>>9<<4)+14]=n.floor(v/4294967296),h[(m+64>>>9<<4)+15]=v,f.sigBytes=h.length*4,this._process(),this._hash},clone:function(){var f=u.clone.call(this);return f._hash=this._hash.clone(),f}});l.SHA256=u._createHelper(c),l.HmacSHA256=u._createHmacHelper(c)}(Math),t.SHA256})}(eo)),eo.exports}var to={exports:{}},Ns;function q1(){return Ns||(Ns=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),fa())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=n.algo,u=o.SHA256,p=o.SHA224=u.extend({_doReset:function(){this._hash=new a.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var s=u._doFinalize.call(this);return s.sigBytes-=4,s}});n.SHA224=u._createHelper(p),n.HmacSHA224=u._createHmacHelper(p)}(),t.SHA224})}(to)),to.exports}var ro={exports:{}},Ms;function t0(){return Ms||(Ms=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ei())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.Hasher,o=n.x64,u=o.Word,p=o.WordArray,s=n.algo;function i(){return u.create.apply(u,arguments)}var d=[i(1116352408,3609767458),i(1899447441,602891725),i(3049323471,3964484399),i(3921009573,2173295548),i(961987163,4081628472),i(1508970993,3053834265),i(2453635748,2937671579),i(2870763221,3664609560),i(3624381080,2734883394),i(310598401,1164996542),i(607225278,1323610764),i(1426881987,3590304994),i(1925078388,4068182383),i(2162078206,991336113),i(2614888103,633803317),i(3248222580,3479774868),i(3835390401,2666613458),i(4022224774,944711139),i(264347078,2341262773),i(604807628,2007800933),i(770255983,1495990901),i(1249150122,1856431235),i(1555081692,3175218132),i(1996064986,2198950837),i(2554220882,3999719339),i(2821834349,766784016),i(2952996808,2566594879),i(3210313671,3203337956),i(3336571891,1034457026),i(3584528711,2466948901),i(113926993,3758326383),i(338241895,168717936),i(666307205,1188179964),i(773529912,1546045734),i(1294757372,1522805485),i(1396182291,2643833823),i(1695183700,2343527390),i(1986661051,1014477480),i(2177026350,1206759142),i(2456956037,344077627),i(2730485921,1290863460),i(2820302411,3158454273),i(3259730800,3505952657),i(3345764771,106217008),i(3516065817,3606008344),i(3600352804,1432725776),i(4094571909,1467031594),i(275423344,851169720),i(430227734,3100823752),i(506948616,1363258195),i(659060556,3750685593),i(883997877,3785050280),i(958139571,3318307427),i(1322822218,3812723403),i(1537002063,2003034995),i(1747873779,3602036899),i(1955562222,1575990012),i(2024104815,1125592928),i(2227730452,2716904306),i(2361852424,442776044),i(2428436474,593698344),i(2756734187,3733110249),i(3204031479,2999351573),i(3329325298,3815920427),i(3391569614,3928383900),i(3515267271,566280711),i(3940187606,3454069534),i(4118630271,4000239992),i(116418474,1914138554),i(174292421,2731055270),i(289380356,3203993006),i(460393269,320620315),i(685471733,587496836),i(852142971,1086792851),i(1017036298,365543100),i(1126000580,2618297676),i(1288033470,3409855158),i(1501505948,4234509866),i(1607167915,987167468),i(1816402316,1246189591)],c=[];(function(){for(var h=0;h<80;h++)c[h]=i()})();var f=s.SHA512=a.extend({_doReset:function(){this._hash=new p.init([new u.init(1779033703,4089235720),new u.init(3144134277,2227873595),new u.init(1013904242,4271175723),new u.init(2773480762,1595750129),new u.init(1359893119,2917565137),new u.init(2600822924,725511199),new u.init(528734635,4215389547),new u.init(1541459225,327033209)])},_doProcessBlock:function(h,v){for(var m=this._hash.words,g=m[0],x=m[1],y=m[2],w=m[3],k=m[4],T=m[5],I=m[6],D=m[7],X=g.high,V=g.low,E=x.high,A=x.low,C=y.high,F=y.low,j=w.high,P=w.low,J=k.high,$=k.low,U=T.high,K=T.low,L=I.high,O=I.low,H=D.high,W=D.low,Z=X,re=V,oe=E,ae=A,b=C,_=F,R=j,G=P,ee=J,te=$,se=U,z=K,S=L,B=O,Y=H,ie=W,ue=0;ue<80;ue++){var ce,me,ge=c[ue];if(ue<16)me=ge.high=h[v+ue*2]|0,ce=ge.low=h[v+ue*2+1]|0;else{var Ce=c[ue-15],Te=Ce.high,Be=Ce.low,kt=(Te>>>1|Be<<31)^(Te>>>8|Be<<24)^Te>>>7,Lt=(Be>>>1|Te<<31)^(Be>>>8|Te<<24)^(Be>>>7|Te<<25),Ut=c[ue-2],Tt=Ut.high,qt=Ut.low,ri=(Tt>>>19|qt<<13)^(Tt<<3|qt>>>29)^Tt>>>6,or=(qt>>>19|Tt<<13)^(qt<<3|Tt>>>29)^(qt>>>6|Tt<<26),Jr=c[ue-7],en=Jr.high,ni=Jr.low,kr=c[ue-16],ii=kr.high,tn=kr.low;ce=Lt+ni,me=kt+en+(ce>>>0<Lt>>>0?1:0),ce=ce+or,me=me+ri+(ce>>>0<or>>>0?1:0),ce=ce+tn,me=me+ii+(ce>>>0<tn>>>0?1:0),ge.high=me,ge.low=ce}var oi=ee&se^~ee&S,rn=te&z^~te&B,ai=Z&oe^Z&b^oe&b,si=re&ae^re&_^ae&_,li=(Z>>>28|re<<4)^(Z<<30|re>>>2)^(Z<<25|re>>>7),nn=(re>>>28|Z<<4)^(re<<30|Z>>>2)^(re<<25|Z>>>7),ui=(ee>>>14|te<<18)^(ee>>>18|te<<14)^(ee<<23|te>>>9),ci=(te>>>14|ee<<18)^(te>>>18|ee<<14)^(te<<23|ee>>>9),on=d[ue],fi=on.high,an=on.low,Ge=ie+ci,dt=Y+ui+(Ge>>>0<ie>>>0?1:0),Ge=Ge+rn,dt=dt+oi+(Ge>>>0<rn>>>0?1:0),Ge=Ge+an,dt=dt+fi+(Ge>>>0<an>>>0?1:0),Ge=Ge+ce,dt=dt+me+(Ge>>>0<ce>>>0?1:0),sn=nn+si,hi=li+ai+(sn>>>0<nn>>>0?1:0);Y=S,ie=B,S=se,B=z,se=ee,z=te,te=G+Ge|0,ee=R+dt+(te>>>0<G>>>0?1:0)|0,R=b,G=_,b=oe,_=ae,oe=Z,ae=re,re=Ge+sn|0,Z=dt+hi+(re>>>0<Ge>>>0?1:0)|0}V=g.low=V+re,g.high=X+Z+(V>>>0<re>>>0?1:0),A=x.low=A+ae,x.high=E+oe+(A>>>0<ae>>>0?1:0),F=y.low=F+_,y.high=C+b+(F>>>0<_>>>0?1:0),P=w.low=P+G,w.high=j+R+(P>>>0<G>>>0?1:0),$=k.low=$+te,k.high=J+ee+($>>>0<te>>>0?1:0),K=T.low=K+z,T.high=U+se+(K>>>0<z>>>0?1:0),O=I.low=O+B,I.high=L+S+(O>>>0<B>>>0?1:0),W=D.low=W+ie,D.high=H+Y+(W>>>0<ie>>>0?1:0)},_doFinalize:function(){var h=this._data,v=h.words,m=this._nDataBytes*8,g=h.sigBytes*8;v[g>>>5]|=128<<24-g%32,v[(g+128>>>10<<5)+30]=Math.floor(m/4294967296),v[(g+128>>>10<<5)+31]=m,h.sigBytes=v.length*4,this._process();var x=this._hash.toX32();return x},clone:function(){var h=a.clone.call(this);return h._hash=this._hash.clone(),h},blockSize:1024/32});n.SHA512=a._createHelper(f),n.HmacSHA512=a._createHmacHelper(f)}(),t.SHA512})}(ro)),ro.exports}var no={exports:{}},Ls;function $1(){return Ls||(Ls=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ei(),t0())})(xe,function(t){return function(){var n=t,l=n.x64,a=l.Word,o=l.WordArray,u=n.algo,p=u.SHA512,s=u.SHA384=p.extend({_doReset:function(){this._hash=new o.init([new a.init(3418070365,3238371032),new a.init(1654270250,914150663),new a.init(2438529370,812702999),new a.init(355462360,4144912697),new a.init(1731405415,4290775857),new a.init(2394180231,1750603025),new a.init(3675008525,1694076839),new a.init(1203062813,3204075428)])},_doFinalize:function(){var i=p._doFinalize.call(this);return i.sigBytes-=16,i}});n.SHA384=p._createHelper(s),n.HmacSHA384=p._createHmacHelper(s)}(),t.SHA384})}(no)),no.exports}var io={exports:{}},Us;function z1(){return Us||(Us=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ei())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.x64,s=p.Word,i=l.algo,d=[],c=[],f=[];(function(){for(var m=1,g=0,x=0;x<24;x++){d[m+5*g]=(x+1)*(x+2)/2%64;var y=g%5,w=(2*m+3*g)%5;m=y,g=w}for(var m=0;m<5;m++)for(var g=0;g<5;g++)c[m+5*g]=g+(2*m+3*g)%5*5;for(var k=1,T=0;T<24;T++){for(var I=0,D=0,X=0;X<7;X++){if(k&1){var V=(1<<X)-1;V<32?D^=1<<V:I^=1<<V-32}k&128?k=k<<1^113:k<<=1}f[T]=s.create(I,D)}})();var h=[];(function(){for(var m=0;m<25;m++)h[m]=s.create()})();var v=i.SHA3=u.extend({cfg:u.cfg.extend({outputLength:512}),_doReset:function(){for(var m=this._state=[],g=0;g<25;g++)m[g]=new s.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(m,g){for(var x=this._state,y=this.blockSize/2,w=0;w<y;w++){var k=m[g+2*w],T=m[g+2*w+1];k=(k<<8|k>>>24)&16711935|(k<<24|k>>>8)&4278255360,T=(T<<8|T>>>24)&16711935|(T<<24|T>>>8)&4278255360;var I=x[w];I.high^=T,I.low^=k}for(var D=0;D<24;D++){for(var X=0;X<5;X++){for(var V=0,E=0,A=0;A<5;A++){var I=x[X+5*A];V^=I.high,E^=I.low}var C=h[X];C.high=V,C.low=E}for(var X=0;X<5;X++)for(var F=h[(X+4)%5],j=h[(X+1)%5],P=j.high,J=j.low,V=F.high^(P<<1|J>>>31),E=F.low^(J<<1|P>>>31),A=0;A<5;A++){var I=x[X+5*A];I.high^=V,I.low^=E}for(var $=1;$<25;$++){var V,E,I=x[$],U=I.high,K=I.low,L=d[$];L<32?(V=U<<L|K>>>32-L,E=K<<L|U>>>32-L):(V=K<<L-32|U>>>64-L,E=U<<L-32|K>>>64-L);var O=h[c[$]];O.high=V,O.low=E}var H=h[0],W=x[0];H.high=W.high,H.low=W.low;for(var X=0;X<5;X++)for(var A=0;A<5;A++){var $=X+5*A,I=x[$],Z=h[$],re=h[(X+1)%5+5*A],oe=h[(X+2)%5+5*A];I.high=Z.high^~re.high&oe.high,I.low=Z.low^~re.low&oe.low}var I=x[0],ae=f[D];I.high^=ae.high,I.low^=ae.low}},_doFinalize:function(){var m=this._data,g=m.words;this._nDataBytes*8;var x=m.sigBytes*8,y=this.blockSize*32;g[x>>>5]|=1<<24-x%32,g[(n.ceil((x+1)/y)*y>>>5)-1]|=128,m.sigBytes=g.length*4,this._process();for(var w=this._state,k=this.cfg.outputLength/8,T=k/8,I=[],D=0;D<T;D++){var X=w[D],V=X.high,E=X.low;V=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360,E=(E<<8|E>>>24)&16711935|(E<<24|E>>>8)&4278255360,I.push(E),I.push(V)}return new o.init(I,k)},clone:function(){for(var m=u.clone.call(this),g=m._state=this._state.slice(0),x=0;x<25;x++)g[x]=g[x].clone();return m}});l.SHA3=u._createHelper(v),l.HmacSHA3=u._createHmacHelper(v)}(Math),t.SHA3})}(io)),io.exports}var oo={exports:{}},qs;function j1(){return qs||(qs=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){/** @preserve
14
14
  (c) 2012 by Cédric Mesnil. All rights reserved.
15
15
 
16
16
  Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
@@ -19,29 +19,29 @@
19
19
  - Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
20
20
 
21
21
  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
22
- */return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.algo,s=o.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),i=o.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),d=o.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),c=o.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),f=o.create([0,1518500249,1859775393,2400959708,2840853838]),h=o.create([1352829926,1548603684,1836072691,2053994217,0]),v=p.RIPEMD160=u.extend({_doReset:function(){this._hash=o.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(T,I){for(var D=0;D<16;D++){var X=I+D,V=T[X];T[X]=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360}var E=this._hash.words,A=f.words,C=h.words,F=s.words,j=i.words,P=d.words,J=c.words,$,U,K,L,O,H,W,Z,re,oe;H=$=E[0],W=U=E[1],Z=K=E[2],re=L=E[3],oe=O=E[4];for(var ae,D=0;D<80;D+=1)ae=$+T[I+F[D]]|0,D<16?ae+=m(U,K,L)+A[0]:D<32?ae+=g(U,K,L)+A[1]:D<48?ae+=x(U,K,L)+A[2]:D<64?ae+=y(U,K,L)+A[3]:ae+=w(U,K,L)+A[4],ae=ae|0,ae=k(ae,P[D]),ae=ae+O|0,$=O,O=L,L=k(K,10),K=U,U=ae,ae=H+T[I+j[D]]|0,D<16?ae+=w(W,Z,re)+C[0]:D<32?ae+=y(W,Z,re)+C[1]:D<48?ae+=x(W,Z,re)+C[2]:D<64?ae+=g(W,Z,re)+C[3]:ae+=m(W,Z,re)+C[4],ae=ae|0,ae=k(ae,J[D]),ae=ae+oe|0,H=oe,oe=re,re=k(Z,10),Z=W,W=ae;ae=E[1]+K+re|0,E[1]=E[2]+L+oe|0,E[2]=E[3]+O+H|0,E[3]=E[4]+$+W|0,E[4]=E[0]+U+Z|0,E[0]=ae},_doFinalize:function(){var T=this._data,I=T.words,D=this._nDataBytes*8,X=T.sigBytes*8;I[X>>>5]|=128<<24-X%32,I[(X+64>>>9<<4)+14]=(D<<8|D>>>24)&16711935|(D<<24|D>>>8)&4278255360,T.sigBytes=(I.length+1)*4,this._process();for(var V=this._hash,E=V.words,A=0;A<5;A++){var C=E[A];E[A]=(C<<8|C>>>24)&16711935|(C<<24|C>>>8)&4278255360}return V},clone:function(){var T=u.clone.call(this);return T._hash=this._hash.clone(),T}});function m(T,I,D){return T^I^D}function g(T,I,D){return T&I|~T&D}function x(T,I,D){return(T|~I)^D}function y(T,I,D){return T&D|I&~D}function w(T,I,D){return T^(I|~D)}function k(T,I){return T<<I|T>>>32-I}l.RIPEMD160=u._createHelper(v),l.HmacRIPEMD160=u._createHmacHelper(v)}(),t.RIPEMD160})}(oo)),oo.exports}var ao={exports:{}},$s;function ha(){return $s||($s=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){(function(){var n=t,l=n.lib,a=l.Base,o=n.enc,u=o.Utf8,p=n.algo;p.HMAC=a.extend({init:function(s,i){s=this._hasher=new s.init,typeof i=="string"&&(i=u.parse(i));var d=s.blockSize,c=d*4;i.sigBytes>c&&(i=s.finalize(i)),i.clamp();for(var f=this._oKey=i.clone(),h=this._iKey=i.clone(),v=f.words,m=h.words,g=0;g<d;g++)v[g]^=1549556828,m[g]^=909522486;f.sigBytes=h.sigBytes=c,this.reset()},reset:function(){var s=this._hasher;s.reset(),s.update(this._iKey)},update:function(s){return this._hasher.update(s),this},finalize:function(s){var i=this._hasher,d=i.finalize(s);i.reset();var c=i.finalize(this._oKey.clone().concat(d));return c}})})()})}(ao)),ao.exports}var so={exports:{}},zs;function G1(){return zs||(zs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),fa(),ha())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.Base,o=l.WordArray,u=n.algo,p=u.SHA256,s=u.HMAC,i=u.PBKDF2=a.extend({cfg:a.extend({keySize:128/32,hasher:p,iterations:25e4}),init:function(d){this.cfg=this.cfg.extend(d)},compute:function(d,c){for(var f=this.cfg,h=s.create(f.hasher,d),v=o.create(),m=o.create([1]),g=v.words,x=m.words,y=f.keySize,w=f.iterations;g.length<y;){var k=h.update(c).finalize(m);h.reset();for(var T=k.words,I=T.length,D=k,X=1;X<w;X++){D=h.finalize(D),h.reset();for(var V=D.words,E=0;E<I;E++)T[E]^=V[E]}v.concat(k),x[0]++}return v.sigBytes=y*4,v}});n.PBKDF2=function(d,c,f){return i.create(f).compute(d,c)}}(),t.PBKDF2})}(so)),so.exports}var lo={exports:{}},js;function Nt(){return js||(js=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),e0(),ha())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.Base,o=l.WordArray,u=n.algo,p=u.MD5,s=u.EvpKDF=a.extend({cfg:a.extend({keySize:128/32,hasher:p,iterations:1}),init:function(i){this.cfg=this.cfg.extend(i)},compute:function(i,d){for(var c,f=this.cfg,h=f.hasher.create(),v=o.create(),m=v.words,g=f.keySize,x=f.iterations;m.length<g;){c&&h.update(c),c=h.update(i).finalize(d),h.reset();for(var y=1;y<x;y++)c=h.finalize(c),h.reset();v.concat(c)}return v.sigBytes=g*4,v}});n.EvpKDF=function(i,d,c){return s.create(c).compute(i,d)}}(),t.EvpKDF})}(lo)),lo.exports}var uo={exports:{}},Hs;function ze(){return Hs||(Hs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),Nt())})(xe,function(t){t.lib.Cipher||function(n){var l=t,a=l.lib,o=a.Base,u=a.WordArray,p=a.BufferedBlockAlgorithm,s=l.enc;s.Utf8;var i=s.Base64,d=l.algo,c=d.EvpKDF,f=a.Cipher=p.extend({cfg:o.extend(),createEncryptor:function(V,E){return this.create(this._ENC_XFORM_MODE,V,E)},createDecryptor:function(V,E){return this.create(this._DEC_XFORM_MODE,V,E)},init:function(V,E,A){this.cfg=this.cfg.extend(A),this._xformMode=V,this._key=E,this.reset()},reset:function(){p.reset.call(this),this._doReset()},process:function(V){return this._append(V),this._process()},finalize:function(V){V&&this._append(V);var E=this._doFinalize();return E},keySize:128/32,ivSize:128/32,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function V(E){return typeof E=="string"?X:T}return function(E){return{encrypt:function(A,C,F){return V(C).encrypt(E,A,C,F)},decrypt:function(A,C,F){return V(C).decrypt(E,A,C,F)}}}}()});a.StreamCipher=f.extend({_doFinalize:function(){var V=this._process(!0);return V},blockSize:1});var h=l.mode={},v=a.BlockCipherMode=o.extend({createEncryptor:function(V,E){return this.Encryptor.create(V,E)},createDecryptor:function(V,E){return this.Decryptor.create(V,E)},init:function(V,E){this._cipher=V,this._iv=E}}),m=h.CBC=function(){var V=v.extend();V.Encryptor=V.extend({processBlock:function(A,C){var F=this._cipher,j=F.blockSize;E.call(this,A,C,j),F.encryptBlock(A,C),this._prevBlock=A.slice(C,C+j)}}),V.Decryptor=V.extend({processBlock:function(A,C){var F=this._cipher,j=F.blockSize,P=A.slice(C,C+j);F.decryptBlock(A,C),E.call(this,A,C,j),this._prevBlock=P}});function E(A,C,F){var j,P=this._iv;P?(j=P,this._iv=n):j=this._prevBlock;for(var J=0;J<F;J++)A[C+J]^=j[J]}return V}(),g=l.pad={},x=g.Pkcs7={pad:function(V,E){for(var A=E*4,C=A-V.sigBytes%A,F=C<<24|C<<16|C<<8|C,j=[],P=0;P<C;P+=4)j.push(F);var J=u.create(j,C);V.concat(J)},unpad:function(V){var E=V.words[V.sigBytes-1>>>2]&255;V.sigBytes-=E}};a.BlockCipher=f.extend({cfg:f.cfg.extend({mode:m,padding:x}),reset:function(){var V;f.reset.call(this);var E=this.cfg,A=E.iv,C=E.mode;this._xformMode==this._ENC_XFORM_MODE?V=C.createEncryptor:(V=C.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==V?this._mode.init(this,A&&A.words):(this._mode=V.call(C,this,A&&A.words),this._mode.__creator=V)},_doProcessBlock:function(V,E){this._mode.processBlock(V,E)},_doFinalize:function(){var V,E=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(E.pad(this._data,this.blockSize),V=this._process(!0)):(V=this._process(!0),E.unpad(V)),V},blockSize:128/32});var y=a.CipherParams=o.extend({init:function(V){this.mixIn(V)},toString:function(V){return(V||this.formatter).stringify(this)}}),w=l.format={},k=w.OpenSSL={stringify:function(V){var E,A=V.ciphertext,C=V.salt;return C?E=u.create([1398893684,1701076831]).concat(C).concat(A):E=A,E.toString(i)},parse:function(V){var E,A=i.parse(V),C=A.words;return C[0]==1398893684&&C[1]==1701076831&&(E=u.create(C.slice(2,4)),C.splice(0,4),A.sigBytes-=16),y.create({ciphertext:A,salt:E})}},T=a.SerializableCipher=o.extend({cfg:o.extend({format:k}),encrypt:function(V,E,A,C){C=this.cfg.extend(C);var F=V.createEncryptor(A,C),j=F.finalize(E),P=F.cfg;return y.create({ciphertext:j,key:A,iv:P.iv,algorithm:V,mode:P.mode,padding:P.padding,blockSize:V.blockSize,formatter:C.format})},decrypt:function(V,E,A,C){C=this.cfg.extend(C),E=this._parse(E,C.format);var F=V.createDecryptor(A,C).finalize(E.ciphertext);return F},_parse:function(V,E){return typeof V=="string"?E.parse(V,this):V}}),I=l.kdf={},D=I.OpenSSL={execute:function(V,E,A,C,F){if(C||(C=u.random(64/8)),F)var j=c.create({keySize:E+A,hasher:F}).compute(V,C);else var j=c.create({keySize:E+A}).compute(V,C);var P=u.create(j.words.slice(E),A*4);return j.sigBytes=E*4,y.create({key:j,iv:P,salt:C})}},X=a.PasswordBasedCipher=T.extend({cfg:T.cfg.extend({kdf:D}),encrypt:function(V,E,A,C){C=this.cfg.extend(C);var F=C.kdf.execute(A,V.keySize,V.ivSize,C.salt,C.hasher);C.iv=F.iv;var j=T.encrypt.call(this,V,E,F.key,C);return j.mixIn(F),j},decrypt:function(V,E,A,C){C=this.cfg.extend(C),E=this._parse(E,C.format);var F=C.kdf.execute(A,V.keySize,V.ivSize,E.salt,C.hasher);C.iv=F.iv;var j=T.decrypt.call(this,V,E,F.key,C);return j}})}()})}(uo)),uo.exports}var co={exports:{}},Vs;function Q1(){return Vs||(Vs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.CFB=function(){var n=t.lib.BlockCipherMode.extend();n.Encryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize;l.call(this,a,o,p,u),this._prevBlock=a.slice(o,o+p)}}),n.Decryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize,s=a.slice(o,o+p);l.call(this,a,o,p,u),this._prevBlock=s}});function l(a,o,u,p){var s,i=this._iv;i?(s=i.slice(0),this._iv=void 0):s=this._prevBlock,p.encryptBlock(s,0);for(var d=0;d<u;d++)a[o+d]^=s[d]}return n}(),t.mode.CFB})}(co)),co.exports}var fo={exports:{}},Ws;function Y1(){return Ws||(Ws=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.CTR=function(){var n=t.lib.BlockCipherMode.extend(),l=n.Encryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize,s=this._iv,i=this._counter;s&&(i=this._counter=s.slice(0),this._iv=void 0);var d=i.slice(0);u.encryptBlock(d,0),i[p-1]=i[p-1]+1|0;for(var c=0;c<p;c++)a[o+c]^=d[c]}});return n.Decryptor=l,n}(),t.mode.CTR})}(fo)),fo.exports}var ho={exports:{}},Ks;function X1(){return Ks||(Ks=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){/** @preserve
22
+ */return function(n){var l=t,a=l.lib,o=a.WordArray,u=a.Hasher,p=l.algo,s=o.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),i=o.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),d=o.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),c=o.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),f=o.create([0,1518500249,1859775393,2400959708,2840853838]),h=o.create([1352829926,1548603684,1836072691,2053994217,0]),v=p.RIPEMD160=u.extend({_doReset:function(){this._hash=o.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(T,I){for(var D=0;D<16;D++){var X=I+D,V=T[X];T[X]=(V<<8|V>>>24)&16711935|(V<<24|V>>>8)&4278255360}var E=this._hash.words,A=f.words,C=h.words,F=s.words,j=i.words,P=d.words,J=c.words,$,U,K,L,O,H,W,Z,re,oe;H=$=E[0],W=U=E[1],Z=K=E[2],re=L=E[3],oe=O=E[4];for(var ae,D=0;D<80;D+=1)ae=$+T[I+F[D]]|0,D<16?ae+=m(U,K,L)+A[0]:D<32?ae+=g(U,K,L)+A[1]:D<48?ae+=x(U,K,L)+A[2]:D<64?ae+=y(U,K,L)+A[3]:ae+=w(U,K,L)+A[4],ae=ae|0,ae=k(ae,P[D]),ae=ae+O|0,$=O,O=L,L=k(K,10),K=U,U=ae,ae=H+T[I+j[D]]|0,D<16?ae+=w(W,Z,re)+C[0]:D<32?ae+=y(W,Z,re)+C[1]:D<48?ae+=x(W,Z,re)+C[2]:D<64?ae+=g(W,Z,re)+C[3]:ae+=m(W,Z,re)+C[4],ae=ae|0,ae=k(ae,J[D]),ae=ae+oe|0,H=oe,oe=re,re=k(Z,10),Z=W,W=ae;ae=E[1]+K+re|0,E[1]=E[2]+L+oe|0,E[2]=E[3]+O+H|0,E[3]=E[4]+$+W|0,E[4]=E[0]+U+Z|0,E[0]=ae},_doFinalize:function(){var T=this._data,I=T.words,D=this._nDataBytes*8,X=T.sigBytes*8;I[X>>>5]|=128<<24-X%32,I[(X+64>>>9<<4)+14]=(D<<8|D>>>24)&16711935|(D<<24|D>>>8)&4278255360,T.sigBytes=(I.length+1)*4,this._process();for(var V=this._hash,E=V.words,A=0;A<5;A++){var C=E[A];E[A]=(C<<8|C>>>24)&16711935|(C<<24|C>>>8)&4278255360}return V},clone:function(){var T=u.clone.call(this);return T._hash=this._hash.clone(),T}});function m(T,I,D){return T^I^D}function g(T,I,D){return T&I|~T&D}function x(T,I,D){return(T|~I)^D}function y(T,I,D){return T&D|I&~D}function w(T,I,D){return T^(I|~D)}function k(T,I){return T<<I|T>>>32-I}l.RIPEMD160=u._createHelper(v),l.HmacRIPEMD160=u._createHmacHelper(v)}(),t.RIPEMD160})}(oo)),oo.exports}var ao={exports:{}},$s;function ha(){return $s||($s=1,function(e,r){(function(t,n){e.exports=n(Ae())})(xe,function(t){(function(){var n=t,l=n.lib,a=l.Base,o=n.enc,u=o.Utf8,p=n.algo;p.HMAC=a.extend({init:function(s,i){s=this._hasher=new s.init,typeof i=="string"&&(i=u.parse(i));var d=s.blockSize,c=d*4;i.sigBytes>c&&(i=s.finalize(i)),i.clamp();for(var f=this._oKey=i.clone(),h=this._iKey=i.clone(),v=f.words,m=h.words,g=0;g<d;g++)v[g]^=1549556828,m[g]^=909522486;f.sigBytes=h.sigBytes=c,this.reset()},reset:function(){var s=this._hasher;s.reset(),s.update(this._iKey)},update:function(s){return this._hasher.update(s),this},finalize:function(s){var i=this._hasher,d=i.finalize(s);i.reset();var c=i.finalize(this._oKey.clone().concat(d));return c}})})()})}(ao)),ao.exports}var so={exports:{}},zs;function H1(){return zs||(zs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),fa(),ha())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.Base,o=l.WordArray,u=n.algo,p=u.SHA256,s=u.HMAC,i=u.PBKDF2=a.extend({cfg:a.extend({keySize:128/32,hasher:p,iterations:25e4}),init:function(d){this.cfg=this.cfg.extend(d)},compute:function(d,c){for(var f=this.cfg,h=s.create(f.hasher,d),v=o.create(),m=o.create([1]),g=v.words,x=m.words,y=f.keySize,w=f.iterations;g.length<y;){var k=h.update(c).finalize(m);h.reset();for(var T=k.words,I=T.length,D=k,X=1;X<w;X++){D=h.finalize(D),h.reset();for(var V=D.words,E=0;E<I;E++)T[E]^=V[E]}v.concat(k),x[0]++}return v.sigBytes=y*4,v}});n.PBKDF2=function(d,c,f){return i.create(f).compute(d,c)}}(),t.PBKDF2})}(so)),so.exports}var lo={exports:{}},js;function Nt(){return js||(js=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),e0(),ha())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.Base,o=l.WordArray,u=n.algo,p=u.MD5,s=u.EvpKDF=a.extend({cfg:a.extend({keySize:128/32,hasher:p,iterations:1}),init:function(i){this.cfg=this.cfg.extend(i)},compute:function(i,d){for(var c,f=this.cfg,h=f.hasher.create(),v=o.create(),m=v.words,g=f.keySize,x=f.iterations;m.length<g;){c&&h.update(c),c=h.update(i).finalize(d),h.reset();for(var y=1;y<x;y++)c=h.finalize(c),h.reset();v.concat(c)}return v.sigBytes=g*4,v}});n.EvpKDF=function(i,d,c){return s.create(c).compute(i,d)}}(),t.EvpKDF})}(lo)),lo.exports}var uo={exports:{}},Hs;function ze(){return Hs||(Hs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),Nt())})(xe,function(t){t.lib.Cipher||function(n){var l=t,a=l.lib,o=a.Base,u=a.WordArray,p=a.BufferedBlockAlgorithm,s=l.enc;s.Utf8;var i=s.Base64,d=l.algo,c=d.EvpKDF,f=a.Cipher=p.extend({cfg:o.extend(),createEncryptor:function(V,E){return this.create(this._ENC_XFORM_MODE,V,E)},createDecryptor:function(V,E){return this.create(this._DEC_XFORM_MODE,V,E)},init:function(V,E,A){this.cfg=this.cfg.extend(A),this._xformMode=V,this._key=E,this.reset()},reset:function(){p.reset.call(this),this._doReset()},process:function(V){return this._append(V),this._process()},finalize:function(V){V&&this._append(V);var E=this._doFinalize();return E},keySize:128/32,ivSize:128/32,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function V(E){return typeof E=="string"?X:T}return function(E){return{encrypt:function(A,C,F){return V(C).encrypt(E,A,C,F)},decrypt:function(A,C,F){return V(C).decrypt(E,A,C,F)}}}}()});a.StreamCipher=f.extend({_doFinalize:function(){var V=this._process(!0);return V},blockSize:1});var h=l.mode={},v=a.BlockCipherMode=o.extend({createEncryptor:function(V,E){return this.Encryptor.create(V,E)},createDecryptor:function(V,E){return this.Decryptor.create(V,E)},init:function(V,E){this._cipher=V,this._iv=E}}),m=h.CBC=function(){var V=v.extend();V.Encryptor=V.extend({processBlock:function(A,C){var F=this._cipher,j=F.blockSize;E.call(this,A,C,j),F.encryptBlock(A,C),this._prevBlock=A.slice(C,C+j)}}),V.Decryptor=V.extend({processBlock:function(A,C){var F=this._cipher,j=F.blockSize,P=A.slice(C,C+j);F.decryptBlock(A,C),E.call(this,A,C,j),this._prevBlock=P}});function E(A,C,F){var j,P=this._iv;P?(j=P,this._iv=n):j=this._prevBlock;for(var J=0;J<F;J++)A[C+J]^=j[J]}return V}(),g=l.pad={},x=g.Pkcs7={pad:function(V,E){for(var A=E*4,C=A-V.sigBytes%A,F=C<<24|C<<16|C<<8|C,j=[],P=0;P<C;P+=4)j.push(F);var J=u.create(j,C);V.concat(J)},unpad:function(V){var E=V.words[V.sigBytes-1>>>2]&255;V.sigBytes-=E}};a.BlockCipher=f.extend({cfg:f.cfg.extend({mode:m,padding:x}),reset:function(){var V;f.reset.call(this);var E=this.cfg,A=E.iv,C=E.mode;this._xformMode==this._ENC_XFORM_MODE?V=C.createEncryptor:(V=C.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==V?this._mode.init(this,A&&A.words):(this._mode=V.call(C,this,A&&A.words),this._mode.__creator=V)},_doProcessBlock:function(V,E){this._mode.processBlock(V,E)},_doFinalize:function(){var V,E=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(E.pad(this._data,this.blockSize),V=this._process(!0)):(V=this._process(!0),E.unpad(V)),V},blockSize:128/32});var y=a.CipherParams=o.extend({init:function(V){this.mixIn(V)},toString:function(V){return(V||this.formatter).stringify(this)}}),w=l.format={},k=w.OpenSSL={stringify:function(V){var E,A=V.ciphertext,C=V.salt;return C?E=u.create([1398893684,1701076831]).concat(C).concat(A):E=A,E.toString(i)},parse:function(V){var E,A=i.parse(V),C=A.words;return C[0]==1398893684&&C[1]==1701076831&&(E=u.create(C.slice(2,4)),C.splice(0,4),A.sigBytes-=16),y.create({ciphertext:A,salt:E})}},T=a.SerializableCipher=o.extend({cfg:o.extend({format:k}),encrypt:function(V,E,A,C){C=this.cfg.extend(C);var F=V.createEncryptor(A,C),j=F.finalize(E),P=F.cfg;return y.create({ciphertext:j,key:A,iv:P.iv,algorithm:V,mode:P.mode,padding:P.padding,blockSize:V.blockSize,formatter:C.format})},decrypt:function(V,E,A,C){C=this.cfg.extend(C),E=this._parse(E,C.format);var F=V.createDecryptor(A,C).finalize(E.ciphertext);return F},_parse:function(V,E){return typeof V=="string"?E.parse(V,this):V}}),I=l.kdf={},D=I.OpenSSL={execute:function(V,E,A,C,F){if(C||(C=u.random(64/8)),F)var j=c.create({keySize:E+A,hasher:F}).compute(V,C);else var j=c.create({keySize:E+A}).compute(V,C);var P=u.create(j.words.slice(E),A*4);return j.sigBytes=E*4,y.create({key:j,iv:P,salt:C})}},X=a.PasswordBasedCipher=T.extend({cfg:T.cfg.extend({kdf:D}),encrypt:function(V,E,A,C){C=this.cfg.extend(C);var F=C.kdf.execute(A,V.keySize,V.ivSize,C.salt,C.hasher);C.iv=F.iv;var j=T.encrypt.call(this,V,E,F.key,C);return j.mixIn(F),j},decrypt:function(V,E,A,C){C=this.cfg.extend(C),E=this._parse(E,C.format);var F=C.kdf.execute(A,V.keySize,V.ivSize,E.salt,C.hasher);C.iv=F.iv;var j=T.decrypt.call(this,V,E,F.key,C);return j}})}()})}(uo)),uo.exports}var co={exports:{}},Vs;function V1(){return Vs||(Vs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.CFB=function(){var n=t.lib.BlockCipherMode.extend();n.Encryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize;l.call(this,a,o,p,u),this._prevBlock=a.slice(o,o+p)}}),n.Decryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize,s=a.slice(o,o+p);l.call(this,a,o,p,u),this._prevBlock=s}});function l(a,o,u,p){var s,i=this._iv;i?(s=i.slice(0),this._iv=void 0):s=this._prevBlock,p.encryptBlock(s,0);for(var d=0;d<u;d++)a[o+d]^=s[d]}return n}(),t.mode.CFB})}(co)),co.exports}var fo={exports:{}},Ws;function W1(){return Ws||(Ws=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.CTR=function(){var n=t.lib.BlockCipherMode.extend(),l=n.Encryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize,s=this._iv,i=this._counter;s&&(i=this._counter=s.slice(0),this._iv=void 0);var d=i.slice(0);u.encryptBlock(d,0),i[p-1]=i[p-1]+1|0;for(var c=0;c<p;c++)a[o+c]^=d[c]}});return n.Decryptor=l,n}(),t.mode.CTR})}(fo)),fo.exports}var ho={exports:{}},Ks;function K1(){return Ks||(Ks=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){/** @preserve
23
23
  * Counter block mode compatible with Dr Brian Gladman fileenc.c
24
24
  * derived from CryptoJS.mode.CTR
25
25
  * Jan Hruby jhruby.web@gmail.com
26
- */return t.mode.CTRGladman=function(){var n=t.lib.BlockCipherMode.extend();function l(u){if((u>>24&255)===255){var p=u>>16&255,s=u>>8&255,i=u&255;p===255?(p=0,s===255?(s=0,i===255?i=0:++i):++s):++p,u=0,u+=p<<16,u+=s<<8,u+=i}else u+=1<<24;return u}function a(u){return(u[0]=l(u[0]))===0&&(u[1]=l(u[1])),u}var o=n.Encryptor=n.extend({processBlock:function(u,p){var s=this._cipher,i=s.blockSize,d=this._iv,c=this._counter;d&&(c=this._counter=d.slice(0),this._iv=void 0),a(c);var f=c.slice(0);s.encryptBlock(f,0);for(var h=0;h<i;h++)u[p+h]^=f[h]}});return n.Decryptor=o,n}(),t.mode.CTRGladman})}(ho)),ho.exports}var po={exports:{}},Gs;function Z1(){return Gs||(Gs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.OFB=function(){var n=t.lib.BlockCipherMode.extend(),l=n.Encryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize,s=this._iv,i=this._keystream;s&&(i=this._keystream=s.slice(0),this._iv=void 0),u.encryptBlock(i,0);for(var d=0;d<p;d++)a[o+d]^=i[d]}});return n.Decryptor=l,n}(),t.mode.OFB})}(po)),po.exports}var mo={exports:{}},Qs;function J1(){return Qs||(Qs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.ECB=function(){var n=t.lib.BlockCipherMode.extend();return n.Encryptor=n.extend({processBlock:function(l,a){this._cipher.encryptBlock(l,a)}}),n.Decryptor=n.extend({processBlock:function(l,a){this._cipher.decryptBlock(l,a)}}),n}(),t.mode.ECB})}(mo)),mo.exports}var vo={exports:{}},Ys;function em(){return Ys||(Ys=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.AnsiX923={pad:function(n,l){var a=n.sigBytes,o=l*4,u=o-a%o,p=a+u-1;n.clamp(),n.words[p>>>2]|=u<<24-p%4*8,n.sigBytes+=u},unpad:function(n){var l=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=l}},t.pad.Ansix923})}(vo)),vo.exports}var yo={exports:{}},Xs;function tm(){return Xs||(Xs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.Iso10126={pad:function(n,l){var a=l*4,o=a-n.sigBytes%a;n.concat(t.lib.WordArray.random(o-1)).concat(t.lib.WordArray.create([o<<24],1))},unpad:function(n){var l=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=l}},t.pad.Iso10126})}(yo)),yo.exports}var go={exports:{}},Zs;function rm(){return Zs||(Zs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.Iso97971={pad:function(n,l){n.concat(t.lib.WordArray.create([2147483648],1)),t.pad.ZeroPadding.pad(n,l)},unpad:function(n){t.pad.ZeroPadding.unpad(n),n.sigBytes--}},t.pad.Iso97971})}(go)),go.exports}var xo={exports:{}},Js;function nm(){return Js||(Js=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.ZeroPadding={pad:function(n,l){var a=l*4;n.clamp(),n.sigBytes+=a-(n.sigBytes%a||a)},unpad:function(n){for(var l=n.words,a=n.sigBytes-1,a=n.sigBytes-1;a>=0;a--)if(l[a>>>2]>>>24-a%4*8&255){n.sigBytes=a+1;break}}},t.pad.ZeroPadding})}(xo)),xo.exports}var bo={exports:{}},el;function im(){return el||(el=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.NoPadding={pad:function(){},unpad:function(){}},t.pad.NoPadding})}(bo)),bo.exports}var wo={exports:{}},tl;function om(){return tl||(tl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.CipherParams,u=l.enc,p=u.Hex,s=l.format;s.Hex={stringify:function(i){return i.ciphertext.toString(p)},parse:function(i){var d=p.parse(i);return o.create({ciphertext:d})}}}(),t.format.Hex})}(wo)),wo.exports}var _o={exports:{}},rl;function am(){return rl||(rl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.BlockCipher,o=n.algo,u=[],p=[],s=[],i=[],d=[],c=[],f=[],h=[],v=[],m=[];(function(){for(var y=[],w=0;w<256;w++)w<128?y[w]=w<<1:y[w]=w<<1^283;for(var k=0,T=0,w=0;w<256;w++){var I=T^T<<1^T<<2^T<<3^T<<4;I=I>>>8^I&255^99,u[k]=I,p[I]=k;var D=y[k],X=y[D],V=y[X],E=y[I]*257^I*16843008;s[k]=E<<24|E>>>8,i[k]=E<<16|E>>>16,d[k]=E<<8|E>>>24,c[k]=E;var E=V*16843009^X*65537^D*257^k*16843008;f[I]=E<<24|E>>>8,h[I]=E<<16|E>>>16,v[I]=E<<8|E>>>24,m[I]=E,k?(k=D^y[y[y[V^D]]],T^=y[y[T]]):k=T=1}})();var g=[0,1,2,4,8,16,32,64,128,27,54],x=o.AES=a.extend({_doReset:function(){var y;if(!(this._nRounds&&this._keyPriorReset===this._key)){for(var w=this._keyPriorReset=this._key,k=w.words,T=w.sigBytes/4,I=this._nRounds=T+6,D=(I+1)*4,X=this._keySchedule=[],V=0;V<D;V++)V<T?X[V]=k[V]:(y=X[V-1],V%T?T>6&&V%T==4&&(y=u[y>>>24]<<24|u[y>>>16&255]<<16|u[y>>>8&255]<<8|u[y&255]):(y=y<<8|y>>>24,y=u[y>>>24]<<24|u[y>>>16&255]<<16|u[y>>>8&255]<<8|u[y&255],y^=g[V/T|0]<<24),X[V]=X[V-T]^y);for(var E=this._invKeySchedule=[],A=0;A<D;A++){var V=D-A;if(A%4)var y=X[V];else var y=X[V-4];A<4||V<=4?E[A]=y:E[A]=f[u[y>>>24]]^h[u[y>>>16&255]]^v[u[y>>>8&255]]^m[u[y&255]]}}},encryptBlock:function(y,w){this._doCryptBlock(y,w,this._keySchedule,s,i,d,c,u)},decryptBlock:function(y,w){var k=y[w+1];y[w+1]=y[w+3],y[w+3]=k,this._doCryptBlock(y,w,this._invKeySchedule,f,h,v,m,p);var k=y[w+1];y[w+1]=y[w+3],y[w+3]=k},_doCryptBlock:function(y,w,k,T,I,D,X,V){for(var E=this._nRounds,A=y[w]^k[0],C=y[w+1]^k[1],F=y[w+2]^k[2],j=y[w+3]^k[3],P=4,J=1;J<E;J++){var $=T[A>>>24]^I[C>>>16&255]^D[F>>>8&255]^X[j&255]^k[P++],U=T[C>>>24]^I[F>>>16&255]^D[j>>>8&255]^X[A&255]^k[P++],K=T[F>>>24]^I[j>>>16&255]^D[A>>>8&255]^X[C&255]^k[P++],L=T[j>>>24]^I[A>>>16&255]^D[C>>>8&255]^X[F&255]^k[P++];A=$,C=U,F=K,j=L}var $=(V[A>>>24]<<24|V[C>>>16&255]<<16|V[F>>>8&255]<<8|V[j&255])^k[P++],U=(V[C>>>24]<<24|V[F>>>16&255]<<16|V[j>>>8&255]<<8|V[A&255])^k[P++],K=(V[F>>>24]<<24|V[j>>>16&255]<<16|V[A>>>8&255]<<8|V[C&255])^k[P++],L=(V[j>>>24]<<24|V[A>>>16&255]<<16|V[C>>>8&255]<<8|V[F&255])^k[P++];y[w]=$,y[w+1]=U,y[w+2]=K,y[w+3]=L},keySize:256/32});n.AES=a._createHelper(x)}(),t.AES})}(_o)),_o.exports}var Eo={exports:{}},nl;function sm(){return nl||(nl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=l.BlockCipher,u=n.algo,p=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],s=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],i=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],d=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],c=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],f=u.DES=o.extend({_doReset:function(){for(var g=this._key,x=g.words,y=[],w=0;w<56;w++){var k=p[w]-1;y[w]=x[k>>>5]>>>31-k%32&1}for(var T=this._subKeys=[],I=0;I<16;I++){for(var D=T[I]=[],X=i[I],w=0;w<24;w++)D[w/6|0]|=y[(s[w]-1+X)%28]<<31-w%6,D[4+(w/6|0)]|=y[28+(s[w+24]-1+X)%28]<<31-w%6;D[0]=D[0]<<1|D[0]>>>31;for(var w=1;w<7;w++)D[w]=D[w]>>>(w-1)*4+3;D[7]=D[7]<<5|D[7]>>>27}for(var V=this._invSubKeys=[],w=0;w<16;w++)V[w]=T[15-w]},encryptBlock:function(g,x){this._doCryptBlock(g,x,this._subKeys)},decryptBlock:function(g,x){this._doCryptBlock(g,x,this._invSubKeys)},_doCryptBlock:function(g,x,y){this._lBlock=g[x],this._rBlock=g[x+1],h.call(this,4,252645135),h.call(this,16,65535),v.call(this,2,858993459),v.call(this,8,16711935),h.call(this,1,1431655765);for(var w=0;w<16;w++){for(var k=y[w],T=this._lBlock,I=this._rBlock,D=0,X=0;X<8;X++)D|=d[X][((I^k[X])&c[X])>>>0];this._lBlock=I,this._rBlock=T^D}var V=this._lBlock;this._lBlock=this._rBlock,this._rBlock=V,h.call(this,1,1431655765),v.call(this,8,16711935),v.call(this,2,858993459),h.call(this,16,65535),h.call(this,4,252645135),g[x]=this._lBlock,g[x+1]=this._rBlock},keySize:64/32,ivSize:64/32,blockSize:64/32});function h(g,x){var y=(this._lBlock>>>g^this._rBlock)&x;this._rBlock^=y,this._lBlock^=y<<g}function v(g,x){var y=(this._rBlock>>>g^this._lBlock)&x;this._lBlock^=y,this._rBlock^=y<<g}n.DES=o._createHelper(f);var m=u.TripleDES=o.extend({_doReset:function(){var g=this._key,x=g.words;if(x.length!==2&&x.length!==4&&x.length<6)throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");var y=x.slice(0,2),w=x.length<4?x.slice(0,2):x.slice(2,4),k=x.length<6?x.slice(0,2):x.slice(4,6);this._des1=f.createEncryptor(a.create(y)),this._des2=f.createEncryptor(a.create(w)),this._des3=f.createEncryptor(a.create(k))},encryptBlock:function(g,x){this._des1.encryptBlock(g,x),this._des2.decryptBlock(g,x),this._des3.encryptBlock(g,x)},decryptBlock:function(g,x){this._des3.decryptBlock(g,x),this._des2.encryptBlock(g,x),this._des1.decryptBlock(g,x)},keySize:192/32,ivSize:64/32,blockSize:64/32});n.TripleDES=o._createHelper(m)}(),t.TripleDES})}(Eo)),Eo.exports}var Ao={exports:{}},il;function lm(){return il||(il=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.StreamCipher,o=n.algo,u=o.RC4=a.extend({_doReset:function(){for(var i=this._key,d=i.words,c=i.sigBytes,f=this._S=[],h=0;h<256;h++)f[h]=h;for(var h=0,v=0;h<256;h++){var m=h%c,g=d[m>>>2]>>>24-m%4*8&255;v=(v+f[h]+g)%256;var x=f[h];f[h]=f[v],f[v]=x}this._i=this._j=0},_doProcessBlock:function(i,d){i[d]^=p.call(this)},keySize:256/32,ivSize:0});function p(){for(var i=this._S,d=this._i,c=this._j,f=0,h=0;h<4;h++){d=(d+1)%256,c=(c+i[d])%256;var v=i[d];i[d]=i[c],i[c]=v,f|=i[(i[d]+i[c])%256]<<24-h*8}return this._i=d,this._j=c,f}n.RC4=a._createHelper(u);var s=o.RC4Drop=u.extend({cfg:u.cfg.extend({drop:192}),_doReset:function(){u._doReset.call(this);for(var i=this.cfg.drop;i>0;i--)p.call(this)}});n.RC4Drop=a._createHelper(s)}(),t.RC4})}(Ao)),Ao.exports}var Co={exports:{}},ol;function um(){return ol||(ol=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.StreamCipher,o=n.algo,u=[],p=[],s=[],i=o.Rabbit=a.extend({_doReset:function(){for(var c=this._key.words,f=this.cfg.iv,h=0;h<4;h++)c[h]=(c[h]<<8|c[h]>>>24)&16711935|(c[h]<<24|c[h]>>>8)&4278255360;var v=this._X=[c[0],c[3]<<16|c[2]>>>16,c[1],c[0]<<16|c[3]>>>16,c[2],c[1]<<16|c[0]>>>16,c[3],c[2]<<16|c[1]>>>16],m=this._C=[c[2]<<16|c[2]>>>16,c[0]&4294901760|c[1]&65535,c[3]<<16|c[3]>>>16,c[1]&4294901760|c[2]&65535,c[0]<<16|c[0]>>>16,c[2]&4294901760|c[3]&65535,c[1]<<16|c[1]>>>16,c[3]&4294901760|c[0]&65535];this._b=0;for(var h=0;h<4;h++)d.call(this);for(var h=0;h<8;h++)m[h]^=v[h+4&7];if(f){var g=f.words,x=g[0],y=g[1],w=(x<<8|x>>>24)&16711935|(x<<24|x>>>8)&4278255360,k=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360,T=w>>>16|k&4294901760,I=k<<16|w&65535;m[0]^=w,m[1]^=T,m[2]^=k,m[3]^=I,m[4]^=w,m[5]^=T,m[6]^=k,m[7]^=I;for(var h=0;h<4;h++)d.call(this)}},_doProcessBlock:function(c,f){var h=this._X;d.call(this),u[0]=h[0]^h[5]>>>16^h[3]<<16,u[1]=h[2]^h[7]>>>16^h[5]<<16,u[2]=h[4]^h[1]>>>16^h[7]<<16,u[3]=h[6]^h[3]>>>16^h[1]<<16;for(var v=0;v<4;v++)u[v]=(u[v]<<8|u[v]>>>24)&16711935|(u[v]<<24|u[v]>>>8)&4278255360,c[f+v]^=u[v]},blockSize:128/32,ivSize:64/32});function d(){for(var c=this._X,f=this._C,h=0;h<8;h++)p[h]=f[h];f[0]=f[0]+1295307597+this._b|0,f[1]=f[1]+3545052371+(f[0]>>>0<p[0]>>>0?1:0)|0,f[2]=f[2]+886263092+(f[1]>>>0<p[1]>>>0?1:0)|0,f[3]=f[3]+1295307597+(f[2]>>>0<p[2]>>>0?1:0)|0,f[4]=f[4]+3545052371+(f[3]>>>0<p[3]>>>0?1:0)|0,f[5]=f[5]+886263092+(f[4]>>>0<p[4]>>>0?1:0)|0,f[6]=f[6]+1295307597+(f[5]>>>0<p[5]>>>0?1:0)|0,f[7]=f[7]+3545052371+(f[6]>>>0<p[6]>>>0?1:0)|0,this._b=f[7]>>>0<p[7]>>>0?1:0;for(var h=0;h<8;h++){var v=c[h]+f[h],m=v&65535,g=v>>>16,x=((m*m>>>17)+m*g>>>15)+g*g,y=((v&4294901760)*v|0)+((v&65535)*v|0);s[h]=x^y}c[0]=s[0]+(s[7]<<16|s[7]>>>16)+(s[6]<<16|s[6]>>>16)|0,c[1]=s[1]+(s[0]<<8|s[0]>>>24)+s[7]|0,c[2]=s[2]+(s[1]<<16|s[1]>>>16)+(s[0]<<16|s[0]>>>16)|0,c[3]=s[3]+(s[2]<<8|s[2]>>>24)+s[1]|0,c[4]=s[4]+(s[3]<<16|s[3]>>>16)+(s[2]<<16|s[2]>>>16)|0,c[5]=s[5]+(s[4]<<8|s[4]>>>24)+s[3]|0,c[6]=s[6]+(s[5]<<16|s[5]>>>16)+(s[4]<<16|s[4]>>>16)|0,c[7]=s[7]+(s[6]<<8|s[6]>>>24)+s[5]|0}n.Rabbit=a._createHelper(i)}(),t.Rabbit})}(Co)),Co.exports}var So={exports:{}},al;function cm(){return al||(al=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.StreamCipher,o=n.algo,u=[],p=[],s=[],i=o.RabbitLegacy=a.extend({_doReset:function(){var c=this._key.words,f=this.cfg.iv,h=this._X=[c[0],c[3]<<16|c[2]>>>16,c[1],c[0]<<16|c[3]>>>16,c[2],c[1]<<16|c[0]>>>16,c[3],c[2]<<16|c[1]>>>16],v=this._C=[c[2]<<16|c[2]>>>16,c[0]&4294901760|c[1]&65535,c[3]<<16|c[3]>>>16,c[1]&4294901760|c[2]&65535,c[0]<<16|c[0]>>>16,c[2]&4294901760|c[3]&65535,c[1]<<16|c[1]>>>16,c[3]&4294901760|c[0]&65535];this._b=0;for(var m=0;m<4;m++)d.call(this);for(var m=0;m<8;m++)v[m]^=h[m+4&7];if(f){var g=f.words,x=g[0],y=g[1],w=(x<<8|x>>>24)&16711935|(x<<24|x>>>8)&4278255360,k=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360,T=w>>>16|k&4294901760,I=k<<16|w&65535;v[0]^=w,v[1]^=T,v[2]^=k,v[3]^=I,v[4]^=w,v[5]^=T,v[6]^=k,v[7]^=I;for(var m=0;m<4;m++)d.call(this)}},_doProcessBlock:function(c,f){var h=this._X;d.call(this),u[0]=h[0]^h[5]>>>16^h[3]<<16,u[1]=h[2]^h[7]>>>16^h[5]<<16,u[2]=h[4]^h[1]>>>16^h[7]<<16,u[3]=h[6]^h[3]>>>16^h[1]<<16;for(var v=0;v<4;v++)u[v]=(u[v]<<8|u[v]>>>24)&16711935|(u[v]<<24|u[v]>>>8)&4278255360,c[f+v]^=u[v]},blockSize:128/32,ivSize:64/32});function d(){for(var c=this._X,f=this._C,h=0;h<8;h++)p[h]=f[h];f[0]=f[0]+1295307597+this._b|0,f[1]=f[1]+3545052371+(f[0]>>>0<p[0]>>>0?1:0)|0,f[2]=f[2]+886263092+(f[1]>>>0<p[1]>>>0?1:0)|0,f[3]=f[3]+1295307597+(f[2]>>>0<p[2]>>>0?1:0)|0,f[4]=f[4]+3545052371+(f[3]>>>0<p[3]>>>0?1:0)|0,f[5]=f[5]+886263092+(f[4]>>>0<p[4]>>>0?1:0)|0,f[6]=f[6]+1295307597+(f[5]>>>0<p[5]>>>0?1:0)|0,f[7]=f[7]+3545052371+(f[6]>>>0<p[6]>>>0?1:0)|0,this._b=f[7]>>>0<p[7]>>>0?1:0;for(var h=0;h<8;h++){var v=c[h]+f[h],m=v&65535,g=v>>>16,x=((m*m>>>17)+m*g>>>15)+g*g,y=((v&4294901760)*v|0)+((v&65535)*v|0);s[h]=x^y}c[0]=s[0]+(s[7]<<16|s[7]>>>16)+(s[6]<<16|s[6]>>>16)|0,c[1]=s[1]+(s[0]<<8|s[0]>>>24)+s[7]|0,c[2]=s[2]+(s[1]<<16|s[1]>>>16)+(s[0]<<16|s[0]>>>16)|0,c[3]=s[3]+(s[2]<<8|s[2]>>>24)+s[1]|0,c[4]=s[4]+(s[3]<<16|s[3]>>>16)+(s[2]<<16|s[2]>>>16)|0,c[5]=s[5]+(s[4]<<8|s[4]>>>24)+s[3]|0,c[6]=s[6]+(s[5]<<16|s[5]>>>16)+(s[4]<<16|s[4]>>>16)|0,c[7]=s[7]+(s[6]<<8|s[6]>>>24)+s[5]|0}n.RabbitLegacy=a._createHelper(i)}(),t.RabbitLegacy})}(So)),So.exports}var Bo={exports:{}},sl;function fm(){return sl||(sl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.BlockCipher,o=n.algo;const u=16,p=[608135816,2242054355,320440878,57701188,2752067618,698298832,137296536,3964562569,1160258022,953160567,3193202383,887688300,3232508343,3380367581,1065670069,3041331479,2450970073,2306472731],s=[[3509652390,2564797868,805139163,3491422135,3101798381,1780907670,3128725573,4046225305,614570311,3012652279,134345442,2240740374,1667834072,1901547113,2757295779,4103290238,227898511,1921955416,1904987480,2182433518,2069144605,3260701109,2620446009,720527379,3318853667,677414384,3393288472,3101374703,2390351024,1614419982,1822297739,2954791486,3608508353,3174124327,2024746970,1432378464,3864339955,2857741204,1464375394,1676153920,1439316330,715854006,3033291828,289532110,2706671279,2087905683,3018724369,1668267050,732546397,1947742710,3462151702,2609353502,2950085171,1814351708,2050118529,680887927,999245976,1800124847,3300911131,1713906067,1641548236,4213287313,1216130144,1575780402,4018429277,3917837745,3693486850,3949271944,596196993,3549867205,258830323,2213823033,772490370,2760122372,1774776394,2652871518,566650946,4142492826,1728879713,2882767088,1783734482,3629395816,2517608232,2874225571,1861159788,326777828,3124490320,2130389656,2716951837,967770486,1724537150,2185432712,2364442137,1164943284,2105845187,998989502,3765401048,2244026483,1075463327,1455516326,1322494562,910128902,469688178,1117454909,936433444,3490320968,3675253459,1240580251,122909385,2157517691,634681816,4142456567,3825094682,3061402683,2540495037,79693498,3249098678,1084186820,1583128258,426386531,1761308591,1047286709,322548459,995290223,1845252383,2603652396,3431023940,2942221577,3202600964,3727903485,1712269319,422464435,3234572375,1170764815,3523960633,3117677531,1434042557,442511882,3600875718,1076654713,1738483198,4213154764,2393238008,3677496056,1014306527,4251020053,793779912,2902807211,842905082,4246964064,1395751752,1040244610,2656851899,3396308128,445077038,3742853595,3577915638,679411651,2892444358,2354009459,1767581616,3150600392,3791627101,3102740896,284835224,4246832056,1258075500,768725851,2589189241,3069724005,3532540348,1274779536,3789419226,2764799539,1660621633,3471099624,4011903706,913787905,3497959166,737222580,2514213453,2928710040,3937242737,1804850592,3499020752,2949064160,2386320175,2390070455,2415321851,4061277028,2290661394,2416832540,1336762016,1754252060,3520065937,3014181293,791618072,3188594551,3933548030,2332172193,3852520463,3043980520,413987798,3465142937,3030929376,4245938359,2093235073,3534596313,375366246,2157278981,2479649556,555357303,3870105701,2008414854,3344188149,4221384143,3956125452,2067696032,3594591187,2921233993,2428461,544322398,577241275,1471733935,610547355,4027169054,1432588573,1507829418,2025931657,3646575487,545086370,48609733,2200306550,1653985193,298326376,1316178497,3007786442,2064951626,458293330,2589141269,3591329599,3164325604,727753846,2179363840,146436021,1461446943,4069977195,705550613,3059967265,3887724982,4281599278,3313849956,1404054877,2845806497,146425753,1854211946],[1266315497,3048417604,3681880366,3289982499,290971e4,1235738493,2632868024,2414719590,3970600049,1771706367,1449415276,3266420449,422970021,1963543593,2690192192,3826793022,1062508698,1531092325,1804592342,2583117782,2714934279,4024971509,1294809318,4028980673,1289560198,2221992742,1669523910,35572830,157838143,1052438473,1016535060,1802137761,1753167236,1386275462,3080475397,2857371447,1040679964,2145300060,2390574316,1461121720,2956646967,4031777805,4028374788,33600511,2920084762,1018524850,629373528,3691585981,3515945977,2091462646,2486323059,586499841,988145025,935516892,3367335476,2599673255,2839830854,265290510,3972581182,2759138881,3795373465,1005194799,847297441,406762289,1314163512,1332590856,1866599683,4127851711,750260880,613907577,1450815602,3165620655,3734664991,3650291728,3012275730,3704569646,1427272223,778793252,1343938022,2676280711,2052605720,1946737175,3164576444,3914038668,3967478842,3682934266,1661551462,3294938066,4011595847,840292616,3712170807,616741398,312560963,711312465,1351876610,322626781,1910503582,271666773,2175563734,1594956187,70604529,3617834859,1007753275,1495573769,4069517037,2549218298,2663038764,504708206,2263041392,3941167025,2249088522,1514023603,1998579484,1312622330,694541497,2582060303,2151582166,1382467621,776784248,2618340202,3323268794,2497899128,2784771155,503983604,4076293799,907881277,423175695,432175456,1378068232,4145222326,3954048622,3938656102,3820766613,2793130115,2977904593,26017576,3274890735,3194772133,1700274565,1756076034,4006520079,3677328699,720338349,1533947780,354530856,688349552,3973924725,1637815568,332179504,3949051286,53804574,2852348879,3044236432,1282449977,3583942155,3416972820,4006381244,1617046695,2628476075,3002303598,1686838959,431878346,2686675385,1700445008,1080580658,1009431731,832498133,3223435511,2605976345,2271191193,2516031870,1648197032,4164389018,2548247927,300782431,375919233,238389289,3353747414,2531188641,2019080857,1475708069,455242339,2609103871,448939670,3451063019,1395535956,2413381860,1841049896,1491858159,885456874,4264095073,4001119347,1565136089,3898914787,1108368660,540939232,1173283510,2745871338,3681308437,4207628240,3343053890,4016749493,1699691293,1103962373,3625875870,2256883143,3830138730,1031889488,3479347698,1535977030,4236805024,3251091107,2132092099,1774941330,1199868427,1452454533,157007616,2904115357,342012276,595725824,1480756522,206960106,497939518,591360097,863170706,2375253569,3596610801,1814182875,2094937945,3421402208,1082520231,3463918190,2785509508,435703966,3908032597,1641649973,2842273706,3305899714,1510255612,2148256476,2655287854,3276092548,4258621189,236887753,3681803219,274041037,1734335097,3815195456,3317970021,1899903192,1026095262,4050517792,356393447,2410691914,3873677099,3682840055],[3913112168,2491498743,4132185628,2489919796,1091903735,1979897079,3170134830,3567386728,3557303409,857797738,1136121015,1342202287,507115054,2535736646,337727348,3213592640,1301675037,2528481711,1895095763,1721773893,3216771564,62756741,2142006736,835421444,2531993523,1442658625,3659876326,2882144922,676362277,1392781812,170690266,3921047035,1759253602,3611846912,1745797284,664899054,1329594018,3901205900,3045908486,2062866102,2865634940,3543621612,3464012697,1080764994,553557557,3656615353,3996768171,991055499,499776247,1265440854,648242737,3940784050,980351604,3713745714,1749149687,3396870395,4211799374,3640570775,1161844396,3125318951,1431517754,545492359,4268468663,3499529547,1437099964,2702547544,3433638243,2581715763,2787789398,1060185593,1593081372,2418618748,4260947970,69676912,2159744348,86519011,2512459080,3838209314,1220612927,3339683548,133810670,1090789135,1078426020,1569222167,845107691,3583754449,4072456591,1091646820,628848692,1613405280,3757631651,526609435,236106946,48312990,2942717905,3402727701,1797494240,859738849,992217954,4005476642,2243076622,3870952857,3732016268,765654824,3490871365,2511836413,1685915746,3888969200,1414112111,2273134842,3281911079,4080962846,172450625,2569994100,980381355,4109958455,2819808352,2716589560,2568741196,3681446669,3329971472,1835478071,660984891,3704678404,4045999559,3422617507,3040415634,1762651403,1719377915,3470491036,2693910283,3642056355,3138596744,1364962596,2073328063,1983633131,926494387,3423689081,2150032023,4096667949,1749200295,3328846651,309677260,2016342300,1779581495,3079819751,111262694,1274766160,443224088,298511866,1025883608,3806446537,1145181785,168956806,3641502830,3584813610,1689216846,3666258015,3200248200,1692713982,2646376535,4042768518,1618508792,1610833997,3523052358,4130873264,2001055236,3610705100,2202168115,4028541809,2961195399,1006657119,2006996926,3186142756,1430667929,3210227297,1314452623,4074634658,4101304120,2273951170,1399257539,3367210612,3027628629,1190975929,2062231137,2333990788,2221543033,2438960610,1181637006,548689776,2362791313,3372408396,3104550113,3145860560,296247880,1970579870,3078560182,3769228297,1714227617,3291629107,3898220290,166772364,1251581989,493813264,448347421,195405023,2709975567,677966185,3703036547,1463355134,2715995803,1338867538,1343315457,2802222074,2684532164,233230375,2599980071,2000651841,3277868038,1638401717,4028070440,3237316320,6314154,819756386,300326615,590932579,1405279636,3267499572,3150704214,2428286686,3959192993,3461946742,1862657033,1266418056,963775037,2089974820,2263052895,1917689273,448879540,3550394620,3981727096,150775221,3627908307,1303187396,508620638,2975983352,2726630617,1817252668,1876281319,1457606340,908771278,3720792119,3617206836,2455994898,1729034894,1080033504],[976866871,3556439503,2881648439,1522871579,1555064734,1336096578,3548522304,2579274686,3574697629,3205460757,3593280638,3338716283,3079412587,564236357,2993598910,1781952180,1464380207,3163844217,3332601554,1699332808,1393555694,1183702653,3581086237,1288719814,691649499,2847557200,2895455976,3193889540,2717570544,1781354906,1676643554,2592534050,3230253752,1126444790,2770207658,2633158820,2210423226,2615765581,2414155088,3127139286,673620729,2805611233,1269405062,4015350505,3341807571,4149409754,1057255273,2012875353,2162469141,2276492801,2601117357,993977747,3918593370,2654263191,753973209,36408145,2530585658,25011837,3520020182,2088578344,530523599,2918365339,1524020338,1518925132,3760827505,3759777254,1202760957,3985898139,3906192525,674977740,4174734889,2031300136,2019492241,3983892565,4153806404,3822280332,352677332,2297720250,60907813,90501309,3286998549,1016092578,2535922412,2839152426,457141659,509813237,4120667899,652014361,1966332200,2975202805,55981186,2327461051,676427537,3255491064,2882294119,3433927263,1307055953,942726286,933058658,2468411793,3933900994,4215176142,1361170020,2001714738,2830558078,3274259782,1222529897,1679025792,2729314320,3714953764,1770335741,151462246,3013232138,1682292957,1483529935,471910574,1539241949,458788160,3436315007,1807016891,3718408830,978976581,1043663428,3165965781,1927990952,4200891579,2372276910,3208408903,3533431907,1412390302,2931980059,4132332400,1947078029,3881505623,4168226417,2941484381,1077988104,1320477388,886195818,18198404,3786409e3,2509781533,112762804,3463356488,1866414978,891333506,18488651,661792760,1628790961,3885187036,3141171499,876946877,2693282273,1372485963,791857591,2686433993,3759982718,3167212022,3472953795,2716379847,445679433,3561995674,3504004811,3574258232,54117162,3331405415,2381918588,3769707343,4154350007,1140177722,4074052095,668550556,3214352940,367459370,261225585,2610173221,4209349473,3468074219,3265815641,314222801,3066103646,3808782860,282218597,3406013506,3773591054,379116347,1285071038,846784868,2669647154,3771962079,3550491691,2305946142,453669953,1268987020,3317592352,3279303384,3744833421,2610507566,3859509063,266596637,3847019092,517658769,3462560207,3443424879,370717030,4247526661,2224018117,4143653529,4112773975,2788324899,2477274417,1456262402,2901442914,1517677493,1846949527,2295493580,3734397586,2176403920,1280348187,1908823572,3871786941,846861322,1172426758,3287448474,3383383037,1655181056,3139813346,901632758,1897031941,2986607138,3066810236,3447102507,1393639104,373351379,950779232,625454576,3124240540,4148612726,2007998917,544563296,2244738638,2330496472,2058025392,1291430526,424198748,50039436,29584100,3605783033,2429876329,2791104160,1057563949,3255363231,3075367218,3463963227,1469046755,985887462]];var i={pbox:[],sbox:[]};function d(m,g){let x=g>>24&255,y=g>>16&255,w=g>>8&255,k=g&255,T=m.sbox[0][x]+m.sbox[1][y];return T=T^m.sbox[2][w],T=T+m.sbox[3][k],T}function c(m,g,x){let y=g,w=x,k;for(let T=0;T<u;++T)y=y^m.pbox[T],w=d(m,y)^w,k=y,y=w,w=k;return k=y,y=w,w=k,w=w^m.pbox[u],y=y^m.pbox[u+1],{left:y,right:w}}function f(m,g,x){let y=g,w=x,k;for(let T=u+1;T>1;--T)y=y^m.pbox[T],w=d(m,y)^w,k=y,y=w,w=k;return k=y,y=w,w=k,w=w^m.pbox[1],y=y^m.pbox[0],{left:y,right:w}}function h(m,g,x){for(let I=0;I<4;I++){m.sbox[I]=[];for(let D=0;D<256;D++)m.sbox[I][D]=s[I][D]}let y=0;for(let I=0;I<u+2;I++)m.pbox[I]=p[I]^g[y],y++,y>=x&&(y=0);let w=0,k=0,T=0;for(let I=0;I<u+2;I+=2)T=c(m,w,k),w=T.left,k=T.right,m.pbox[I]=w,m.pbox[I+1]=k;for(let I=0;I<4;I++)for(let D=0;D<256;D+=2)T=c(m,w,k),w=T.left,k=T.right,m.sbox[I][D]=w,m.sbox[I][D+1]=k;return!0}var v=o.Blowfish=a.extend({_doReset:function(){if(this._keyPriorReset!==this._key){var m=this._keyPriorReset=this._key,g=m.words,x=m.sigBytes/4;h(i,g,x)}},encryptBlock:function(m,g){var x=c(i,m[g],m[g+1]);m[g]=x.left,m[g+1]=x.right},decryptBlock:function(m,g){var x=f(i,m[g],m[g+1]);m[g]=x.left,m[g+1]=x.right},blockSize:64/32,keySize:128/32,ivSize:64/32});n.Blowfish=a._createHelper(v)}(),t.Blowfish})}(Bo)),Bo.exports}(function(e,r){(function(t,n,l){e.exports=n(Ae(),ei(),$1(),z1(),tr(),j1(),rr(),e0(),fa(),H1(),t0(),V1(),W1(),K1(),ha(),G1(),Nt(),ze(),Q1(),Y1(),X1(),Z1(),J1(),em(),tm(),rm(),nm(),im(),om(),am(),sm(),lm(),um(),cm(),fm())})(xe,function(t){return t})})(q1);var we={},ti={};ti.byteLength=dm;ti.toByteArray=vm;ti.fromByteArray=xm;var wt=[],at=[],hm=typeof Uint8Array!="undefined"?Uint8Array:Array,ko="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var ur=0,pm=ko.length;ur<pm;++ur)wt[ur]=ko[ur],at[ko.charCodeAt(ur)]=ur;at[45]=62;at[95]=63;function r0(e){var r=e.length;if(r%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var t=e.indexOf("=");t===-1&&(t=r);var n=t===r?0:4-t%4;return[t,n]}function dm(e){var r=r0(e),t=r[0],n=r[1];return(t+n)*3/4-n}function mm(e,r,t){return(r+t)*3/4-t}function vm(e){var r,t=r0(e),n=t[0],l=t[1],a=new hm(mm(e,n,l)),o=0,u=l>0?n-4:n,p;for(p=0;p<u;p+=4)r=at[e.charCodeAt(p)]<<18|at[e.charCodeAt(p+1)]<<12|at[e.charCodeAt(p+2)]<<6|at[e.charCodeAt(p+3)],a[o++]=r>>16&255,a[o++]=r>>8&255,a[o++]=r&255;return l===2&&(r=at[e.charCodeAt(p)]<<2|at[e.charCodeAt(p+1)]>>4,a[o++]=r&255),l===1&&(r=at[e.charCodeAt(p)]<<10|at[e.charCodeAt(p+1)]<<4|at[e.charCodeAt(p+2)]>>2,a[o++]=r>>8&255,a[o++]=r&255),a}function ym(e){return wt[e>>18&63]+wt[e>>12&63]+wt[e>>6&63]+wt[e&63]}function gm(e,r,t){for(var n,l=[],a=r;a<t;a+=3)n=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(e[a+2]&255),l.push(ym(n));return l.join("")}function xm(e){for(var r,t=e.length,n=t%3,l=[],a=16383,o=0,u=t-n;o<u;o+=a)l.push(gm(e,o,o+a>u?u:o+a));return n===1?(r=e[t-1],l.push(wt[r>>2]+wt[r<<4&63]+"==")):n===2&&(r=(e[t-2]<<8)+e[t-1],l.push(wt[r>>10]+wt[r>>4&63]+wt[r<<2&63]+"=")),l.join("")}var pa={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */pa.read=function(e,r,t,n,l){var a,o,u=l*8-n-1,p=(1<<u)-1,s=p>>1,i=-7,d=t?l-1:0,c=t?-1:1,f=e[r+d];for(d+=c,a=f&(1<<-i)-1,f>>=-i,i+=u;i>0;a=a*256+e[r+d],d+=c,i-=8);for(o=a&(1<<-i)-1,a>>=-i,i+=n;i>0;o=o*256+e[r+d],d+=c,i-=8);if(a===0)a=1-s;else{if(a===p)return o?NaN:(f?-1:1)*(1/0);o=o+Math.pow(2,n),a=a-s}return(f?-1:1)*o*Math.pow(2,a-n)};pa.write=function(e,r,t,n,l,a){var o,u,p,s=a*8-l-1,i=(1<<s)-1,d=i>>1,c=l===23?Math.pow(2,-24)-Math.pow(2,-77):0,f=n?0:a-1,h=n?1:-1,v=r<0||r===0&&1/r<0?1:0;for(r=Math.abs(r),isNaN(r)||r===1/0?(u=isNaN(r)?1:0,o=i):(o=Math.floor(Math.log(r)/Math.LN2),r*(p=Math.pow(2,-o))<1&&(o--,p*=2),o+d>=1?r+=c/p:r+=c*Math.pow(2,1-d),r*p>=2&&(o++,p/=2),o+d>=i?(u=0,o=i):o+d>=1?(u=(r*p-1)*Math.pow(2,l),o=o+d):(u=r*Math.pow(2,d-1)*Math.pow(2,l),o=0));l>=8;e[t+f]=u&255,f+=h,u/=256,l-=8);for(o=o<<l|u,s+=l;s>0;e[t+f]=o&255,f+=h,o/=256,s-=8);e[t+f-h]|=v*128};/*!
26
+ */return t.mode.CTRGladman=function(){var n=t.lib.BlockCipherMode.extend();function l(u){if((u>>24&255)===255){var p=u>>16&255,s=u>>8&255,i=u&255;p===255?(p=0,s===255?(s=0,i===255?i=0:++i):++s):++p,u=0,u+=p<<16,u+=s<<8,u+=i}else u+=1<<24;return u}function a(u){return(u[0]=l(u[0]))===0&&(u[1]=l(u[1])),u}var o=n.Encryptor=n.extend({processBlock:function(u,p){var s=this._cipher,i=s.blockSize,d=this._iv,c=this._counter;d&&(c=this._counter=d.slice(0),this._iv=void 0),a(c);var f=c.slice(0);s.encryptBlock(f,0);for(var h=0;h<i;h++)u[p+h]^=f[h]}});return n.Decryptor=o,n}(),t.mode.CTRGladman})}(ho)),ho.exports}var po={exports:{}},Gs;function G1(){return Gs||(Gs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.OFB=function(){var n=t.lib.BlockCipherMode.extend(),l=n.Encryptor=n.extend({processBlock:function(a,o){var u=this._cipher,p=u.blockSize,s=this._iv,i=this._keystream;s&&(i=this._keystream=s.slice(0),this._iv=void 0),u.encryptBlock(i,0);for(var d=0;d<p;d++)a[o+d]^=i[d]}});return n.Decryptor=l,n}(),t.mode.OFB})}(po)),po.exports}var mo={exports:{}},Qs;function Q1(){return Qs||(Qs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.mode.ECB=function(){var n=t.lib.BlockCipherMode.extend();return n.Encryptor=n.extend({processBlock:function(l,a){this._cipher.encryptBlock(l,a)}}),n.Decryptor=n.extend({processBlock:function(l,a){this._cipher.decryptBlock(l,a)}}),n}(),t.mode.ECB})}(mo)),mo.exports}var vo={exports:{}},Ys;function Y1(){return Ys||(Ys=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.AnsiX923={pad:function(n,l){var a=n.sigBytes,o=l*4,u=o-a%o,p=a+u-1;n.clamp(),n.words[p>>>2]|=u<<24-p%4*8,n.sigBytes+=u},unpad:function(n){var l=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=l}},t.pad.Ansix923})}(vo)),vo.exports}var yo={exports:{}},Xs;function X1(){return Xs||(Xs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.Iso10126={pad:function(n,l){var a=l*4,o=a-n.sigBytes%a;n.concat(t.lib.WordArray.random(o-1)).concat(t.lib.WordArray.create([o<<24],1))},unpad:function(n){var l=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=l}},t.pad.Iso10126})}(yo)),yo.exports}var go={exports:{}},Zs;function Z1(){return Zs||(Zs=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.Iso97971={pad:function(n,l){n.concat(t.lib.WordArray.create([2147483648],1)),t.pad.ZeroPadding.pad(n,l)},unpad:function(n){t.pad.ZeroPadding.unpad(n),n.sigBytes--}},t.pad.Iso97971})}(go)),go.exports}var xo={exports:{}},Js;function J1(){return Js||(Js=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.ZeroPadding={pad:function(n,l){var a=l*4;n.clamp(),n.sigBytes+=a-(n.sigBytes%a||a)},unpad:function(n){for(var l=n.words,a=n.sigBytes-1,a=n.sigBytes-1;a>=0;a--)if(l[a>>>2]>>>24-a%4*8&255){n.sigBytes=a+1;break}}},t.pad.ZeroPadding})}(xo)),xo.exports}var bo={exports:{}},el;function em(){return el||(el=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return t.pad.NoPadding={pad:function(){},unpad:function(){}},t.pad.NoPadding})}(bo)),bo.exports}var wo={exports:{}},tl;function tm(){return tl||(tl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),ze())})(xe,function(t){return function(n){var l=t,a=l.lib,o=a.CipherParams,u=l.enc,p=u.Hex,s=l.format;s.Hex={stringify:function(i){return i.ciphertext.toString(p)},parse:function(i){var d=p.parse(i);return o.create({ciphertext:d})}}}(),t.format.Hex})}(wo)),wo.exports}var _o={exports:{}},rl;function rm(){return rl||(rl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.BlockCipher,o=n.algo,u=[],p=[],s=[],i=[],d=[],c=[],f=[],h=[],v=[],m=[];(function(){for(var y=[],w=0;w<256;w++)w<128?y[w]=w<<1:y[w]=w<<1^283;for(var k=0,T=0,w=0;w<256;w++){var I=T^T<<1^T<<2^T<<3^T<<4;I=I>>>8^I&255^99,u[k]=I,p[I]=k;var D=y[k],X=y[D],V=y[X],E=y[I]*257^I*16843008;s[k]=E<<24|E>>>8,i[k]=E<<16|E>>>16,d[k]=E<<8|E>>>24,c[k]=E;var E=V*16843009^X*65537^D*257^k*16843008;f[I]=E<<24|E>>>8,h[I]=E<<16|E>>>16,v[I]=E<<8|E>>>24,m[I]=E,k?(k=D^y[y[y[V^D]]],T^=y[y[T]]):k=T=1}})();var g=[0,1,2,4,8,16,32,64,128,27,54],x=o.AES=a.extend({_doReset:function(){var y;if(!(this._nRounds&&this._keyPriorReset===this._key)){for(var w=this._keyPriorReset=this._key,k=w.words,T=w.sigBytes/4,I=this._nRounds=T+6,D=(I+1)*4,X=this._keySchedule=[],V=0;V<D;V++)V<T?X[V]=k[V]:(y=X[V-1],V%T?T>6&&V%T==4&&(y=u[y>>>24]<<24|u[y>>>16&255]<<16|u[y>>>8&255]<<8|u[y&255]):(y=y<<8|y>>>24,y=u[y>>>24]<<24|u[y>>>16&255]<<16|u[y>>>8&255]<<8|u[y&255],y^=g[V/T|0]<<24),X[V]=X[V-T]^y);for(var E=this._invKeySchedule=[],A=0;A<D;A++){var V=D-A;if(A%4)var y=X[V];else var y=X[V-4];A<4||V<=4?E[A]=y:E[A]=f[u[y>>>24]]^h[u[y>>>16&255]]^v[u[y>>>8&255]]^m[u[y&255]]}}},encryptBlock:function(y,w){this._doCryptBlock(y,w,this._keySchedule,s,i,d,c,u)},decryptBlock:function(y,w){var k=y[w+1];y[w+1]=y[w+3],y[w+3]=k,this._doCryptBlock(y,w,this._invKeySchedule,f,h,v,m,p);var k=y[w+1];y[w+1]=y[w+3],y[w+3]=k},_doCryptBlock:function(y,w,k,T,I,D,X,V){for(var E=this._nRounds,A=y[w]^k[0],C=y[w+1]^k[1],F=y[w+2]^k[2],j=y[w+3]^k[3],P=4,J=1;J<E;J++){var $=T[A>>>24]^I[C>>>16&255]^D[F>>>8&255]^X[j&255]^k[P++],U=T[C>>>24]^I[F>>>16&255]^D[j>>>8&255]^X[A&255]^k[P++],K=T[F>>>24]^I[j>>>16&255]^D[A>>>8&255]^X[C&255]^k[P++],L=T[j>>>24]^I[A>>>16&255]^D[C>>>8&255]^X[F&255]^k[P++];A=$,C=U,F=K,j=L}var $=(V[A>>>24]<<24|V[C>>>16&255]<<16|V[F>>>8&255]<<8|V[j&255])^k[P++],U=(V[C>>>24]<<24|V[F>>>16&255]<<16|V[j>>>8&255]<<8|V[A&255])^k[P++],K=(V[F>>>24]<<24|V[j>>>16&255]<<16|V[A>>>8&255]<<8|V[C&255])^k[P++],L=(V[j>>>24]<<24|V[A>>>16&255]<<16|V[C>>>8&255]<<8|V[F&255])^k[P++];y[w]=$,y[w+1]=U,y[w+2]=K,y[w+3]=L},keySize:256/32});n.AES=a._createHelper(x)}(),t.AES})}(_o)),_o.exports}var Eo={exports:{}},nl;function nm(){return nl||(nl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.WordArray,o=l.BlockCipher,u=n.algo,p=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],s=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],i=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],d=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],c=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],f=u.DES=o.extend({_doReset:function(){for(var g=this._key,x=g.words,y=[],w=0;w<56;w++){var k=p[w]-1;y[w]=x[k>>>5]>>>31-k%32&1}for(var T=this._subKeys=[],I=0;I<16;I++){for(var D=T[I]=[],X=i[I],w=0;w<24;w++)D[w/6|0]|=y[(s[w]-1+X)%28]<<31-w%6,D[4+(w/6|0)]|=y[28+(s[w+24]-1+X)%28]<<31-w%6;D[0]=D[0]<<1|D[0]>>>31;for(var w=1;w<7;w++)D[w]=D[w]>>>(w-1)*4+3;D[7]=D[7]<<5|D[7]>>>27}for(var V=this._invSubKeys=[],w=0;w<16;w++)V[w]=T[15-w]},encryptBlock:function(g,x){this._doCryptBlock(g,x,this._subKeys)},decryptBlock:function(g,x){this._doCryptBlock(g,x,this._invSubKeys)},_doCryptBlock:function(g,x,y){this._lBlock=g[x],this._rBlock=g[x+1],h.call(this,4,252645135),h.call(this,16,65535),v.call(this,2,858993459),v.call(this,8,16711935),h.call(this,1,1431655765);for(var w=0;w<16;w++){for(var k=y[w],T=this._lBlock,I=this._rBlock,D=0,X=0;X<8;X++)D|=d[X][((I^k[X])&c[X])>>>0];this._lBlock=I,this._rBlock=T^D}var V=this._lBlock;this._lBlock=this._rBlock,this._rBlock=V,h.call(this,1,1431655765),v.call(this,8,16711935),v.call(this,2,858993459),h.call(this,16,65535),h.call(this,4,252645135),g[x]=this._lBlock,g[x+1]=this._rBlock},keySize:64/32,ivSize:64/32,blockSize:64/32});function h(g,x){var y=(this._lBlock>>>g^this._rBlock)&x;this._rBlock^=y,this._lBlock^=y<<g}function v(g,x){var y=(this._rBlock>>>g^this._lBlock)&x;this._lBlock^=y,this._rBlock^=y<<g}n.DES=o._createHelper(f);var m=u.TripleDES=o.extend({_doReset:function(){var g=this._key,x=g.words;if(x.length!==2&&x.length!==4&&x.length<6)throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");var y=x.slice(0,2),w=x.length<4?x.slice(0,2):x.slice(2,4),k=x.length<6?x.slice(0,2):x.slice(4,6);this._des1=f.createEncryptor(a.create(y)),this._des2=f.createEncryptor(a.create(w)),this._des3=f.createEncryptor(a.create(k))},encryptBlock:function(g,x){this._des1.encryptBlock(g,x),this._des2.decryptBlock(g,x),this._des3.encryptBlock(g,x)},decryptBlock:function(g,x){this._des3.decryptBlock(g,x),this._des2.encryptBlock(g,x),this._des1.decryptBlock(g,x)},keySize:192/32,ivSize:64/32,blockSize:64/32});n.TripleDES=o._createHelper(m)}(),t.TripleDES})}(Eo)),Eo.exports}var Ao={exports:{}},il;function im(){return il||(il=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.StreamCipher,o=n.algo,u=o.RC4=a.extend({_doReset:function(){for(var i=this._key,d=i.words,c=i.sigBytes,f=this._S=[],h=0;h<256;h++)f[h]=h;for(var h=0,v=0;h<256;h++){var m=h%c,g=d[m>>>2]>>>24-m%4*8&255;v=(v+f[h]+g)%256;var x=f[h];f[h]=f[v],f[v]=x}this._i=this._j=0},_doProcessBlock:function(i,d){i[d]^=p.call(this)},keySize:256/32,ivSize:0});function p(){for(var i=this._S,d=this._i,c=this._j,f=0,h=0;h<4;h++){d=(d+1)%256,c=(c+i[d])%256;var v=i[d];i[d]=i[c],i[c]=v,f|=i[(i[d]+i[c])%256]<<24-h*8}return this._i=d,this._j=c,f}n.RC4=a._createHelper(u);var s=o.RC4Drop=u.extend({cfg:u.cfg.extend({drop:192}),_doReset:function(){u._doReset.call(this);for(var i=this.cfg.drop;i>0;i--)p.call(this)}});n.RC4Drop=a._createHelper(s)}(),t.RC4})}(Ao)),Ao.exports}var Co={exports:{}},ol;function om(){return ol||(ol=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.StreamCipher,o=n.algo,u=[],p=[],s=[],i=o.Rabbit=a.extend({_doReset:function(){for(var c=this._key.words,f=this.cfg.iv,h=0;h<4;h++)c[h]=(c[h]<<8|c[h]>>>24)&16711935|(c[h]<<24|c[h]>>>8)&4278255360;var v=this._X=[c[0],c[3]<<16|c[2]>>>16,c[1],c[0]<<16|c[3]>>>16,c[2],c[1]<<16|c[0]>>>16,c[3],c[2]<<16|c[1]>>>16],m=this._C=[c[2]<<16|c[2]>>>16,c[0]&4294901760|c[1]&65535,c[3]<<16|c[3]>>>16,c[1]&4294901760|c[2]&65535,c[0]<<16|c[0]>>>16,c[2]&4294901760|c[3]&65535,c[1]<<16|c[1]>>>16,c[3]&4294901760|c[0]&65535];this._b=0;for(var h=0;h<4;h++)d.call(this);for(var h=0;h<8;h++)m[h]^=v[h+4&7];if(f){var g=f.words,x=g[0],y=g[1],w=(x<<8|x>>>24)&16711935|(x<<24|x>>>8)&4278255360,k=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360,T=w>>>16|k&4294901760,I=k<<16|w&65535;m[0]^=w,m[1]^=T,m[2]^=k,m[3]^=I,m[4]^=w,m[5]^=T,m[6]^=k,m[7]^=I;for(var h=0;h<4;h++)d.call(this)}},_doProcessBlock:function(c,f){var h=this._X;d.call(this),u[0]=h[0]^h[5]>>>16^h[3]<<16,u[1]=h[2]^h[7]>>>16^h[5]<<16,u[2]=h[4]^h[1]>>>16^h[7]<<16,u[3]=h[6]^h[3]>>>16^h[1]<<16;for(var v=0;v<4;v++)u[v]=(u[v]<<8|u[v]>>>24)&16711935|(u[v]<<24|u[v]>>>8)&4278255360,c[f+v]^=u[v]},blockSize:128/32,ivSize:64/32});function d(){for(var c=this._X,f=this._C,h=0;h<8;h++)p[h]=f[h];f[0]=f[0]+1295307597+this._b|0,f[1]=f[1]+3545052371+(f[0]>>>0<p[0]>>>0?1:0)|0,f[2]=f[2]+886263092+(f[1]>>>0<p[1]>>>0?1:0)|0,f[3]=f[3]+1295307597+(f[2]>>>0<p[2]>>>0?1:0)|0,f[4]=f[4]+3545052371+(f[3]>>>0<p[3]>>>0?1:0)|0,f[5]=f[5]+886263092+(f[4]>>>0<p[4]>>>0?1:0)|0,f[6]=f[6]+1295307597+(f[5]>>>0<p[5]>>>0?1:0)|0,f[7]=f[7]+3545052371+(f[6]>>>0<p[6]>>>0?1:0)|0,this._b=f[7]>>>0<p[7]>>>0?1:0;for(var h=0;h<8;h++){var v=c[h]+f[h],m=v&65535,g=v>>>16,x=((m*m>>>17)+m*g>>>15)+g*g,y=((v&4294901760)*v|0)+((v&65535)*v|0);s[h]=x^y}c[0]=s[0]+(s[7]<<16|s[7]>>>16)+(s[6]<<16|s[6]>>>16)|0,c[1]=s[1]+(s[0]<<8|s[0]>>>24)+s[7]|0,c[2]=s[2]+(s[1]<<16|s[1]>>>16)+(s[0]<<16|s[0]>>>16)|0,c[3]=s[3]+(s[2]<<8|s[2]>>>24)+s[1]|0,c[4]=s[4]+(s[3]<<16|s[3]>>>16)+(s[2]<<16|s[2]>>>16)|0,c[5]=s[5]+(s[4]<<8|s[4]>>>24)+s[3]|0,c[6]=s[6]+(s[5]<<16|s[5]>>>16)+(s[4]<<16|s[4]>>>16)|0,c[7]=s[7]+(s[6]<<8|s[6]>>>24)+s[5]|0}n.Rabbit=a._createHelper(i)}(),t.Rabbit})}(Co)),Co.exports}var So={exports:{}},al;function am(){return al||(al=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.StreamCipher,o=n.algo,u=[],p=[],s=[],i=o.RabbitLegacy=a.extend({_doReset:function(){var c=this._key.words,f=this.cfg.iv,h=this._X=[c[0],c[3]<<16|c[2]>>>16,c[1],c[0]<<16|c[3]>>>16,c[2],c[1]<<16|c[0]>>>16,c[3],c[2]<<16|c[1]>>>16],v=this._C=[c[2]<<16|c[2]>>>16,c[0]&4294901760|c[1]&65535,c[3]<<16|c[3]>>>16,c[1]&4294901760|c[2]&65535,c[0]<<16|c[0]>>>16,c[2]&4294901760|c[3]&65535,c[1]<<16|c[1]>>>16,c[3]&4294901760|c[0]&65535];this._b=0;for(var m=0;m<4;m++)d.call(this);for(var m=0;m<8;m++)v[m]^=h[m+4&7];if(f){var g=f.words,x=g[0],y=g[1],w=(x<<8|x>>>24)&16711935|(x<<24|x>>>8)&4278255360,k=(y<<8|y>>>24)&16711935|(y<<24|y>>>8)&4278255360,T=w>>>16|k&4294901760,I=k<<16|w&65535;v[0]^=w,v[1]^=T,v[2]^=k,v[3]^=I,v[4]^=w,v[5]^=T,v[6]^=k,v[7]^=I;for(var m=0;m<4;m++)d.call(this)}},_doProcessBlock:function(c,f){var h=this._X;d.call(this),u[0]=h[0]^h[5]>>>16^h[3]<<16,u[1]=h[2]^h[7]>>>16^h[5]<<16,u[2]=h[4]^h[1]>>>16^h[7]<<16,u[3]=h[6]^h[3]>>>16^h[1]<<16;for(var v=0;v<4;v++)u[v]=(u[v]<<8|u[v]>>>24)&16711935|(u[v]<<24|u[v]>>>8)&4278255360,c[f+v]^=u[v]},blockSize:128/32,ivSize:64/32});function d(){for(var c=this._X,f=this._C,h=0;h<8;h++)p[h]=f[h];f[0]=f[0]+1295307597+this._b|0,f[1]=f[1]+3545052371+(f[0]>>>0<p[0]>>>0?1:0)|0,f[2]=f[2]+886263092+(f[1]>>>0<p[1]>>>0?1:0)|0,f[3]=f[3]+1295307597+(f[2]>>>0<p[2]>>>0?1:0)|0,f[4]=f[4]+3545052371+(f[3]>>>0<p[3]>>>0?1:0)|0,f[5]=f[5]+886263092+(f[4]>>>0<p[4]>>>0?1:0)|0,f[6]=f[6]+1295307597+(f[5]>>>0<p[5]>>>0?1:0)|0,f[7]=f[7]+3545052371+(f[6]>>>0<p[6]>>>0?1:0)|0,this._b=f[7]>>>0<p[7]>>>0?1:0;for(var h=0;h<8;h++){var v=c[h]+f[h],m=v&65535,g=v>>>16,x=((m*m>>>17)+m*g>>>15)+g*g,y=((v&4294901760)*v|0)+((v&65535)*v|0);s[h]=x^y}c[0]=s[0]+(s[7]<<16|s[7]>>>16)+(s[6]<<16|s[6]>>>16)|0,c[1]=s[1]+(s[0]<<8|s[0]>>>24)+s[7]|0,c[2]=s[2]+(s[1]<<16|s[1]>>>16)+(s[0]<<16|s[0]>>>16)|0,c[3]=s[3]+(s[2]<<8|s[2]>>>24)+s[1]|0,c[4]=s[4]+(s[3]<<16|s[3]>>>16)+(s[2]<<16|s[2]>>>16)|0,c[5]=s[5]+(s[4]<<8|s[4]>>>24)+s[3]|0,c[6]=s[6]+(s[5]<<16|s[5]>>>16)+(s[4]<<16|s[4]>>>16)|0,c[7]=s[7]+(s[6]<<8|s[6]>>>24)+s[5]|0}n.RabbitLegacy=a._createHelper(i)}(),t.RabbitLegacy})}(So)),So.exports}var Bo={exports:{}},sl;function sm(){return sl||(sl=1,function(e,r){(function(t,n,l){e.exports=n(Ae(),tr(),rr(),Nt(),ze())})(xe,function(t){return function(){var n=t,l=n.lib,a=l.BlockCipher,o=n.algo;const u=16,p=[608135816,2242054355,320440878,57701188,2752067618,698298832,137296536,3964562569,1160258022,953160567,3193202383,887688300,3232508343,3380367581,1065670069,3041331479,2450970073,2306472731],s=[[3509652390,2564797868,805139163,3491422135,3101798381,1780907670,3128725573,4046225305,614570311,3012652279,134345442,2240740374,1667834072,1901547113,2757295779,4103290238,227898511,1921955416,1904987480,2182433518,2069144605,3260701109,2620446009,720527379,3318853667,677414384,3393288472,3101374703,2390351024,1614419982,1822297739,2954791486,3608508353,3174124327,2024746970,1432378464,3864339955,2857741204,1464375394,1676153920,1439316330,715854006,3033291828,289532110,2706671279,2087905683,3018724369,1668267050,732546397,1947742710,3462151702,2609353502,2950085171,1814351708,2050118529,680887927,999245976,1800124847,3300911131,1713906067,1641548236,4213287313,1216130144,1575780402,4018429277,3917837745,3693486850,3949271944,596196993,3549867205,258830323,2213823033,772490370,2760122372,1774776394,2652871518,566650946,4142492826,1728879713,2882767088,1783734482,3629395816,2517608232,2874225571,1861159788,326777828,3124490320,2130389656,2716951837,967770486,1724537150,2185432712,2364442137,1164943284,2105845187,998989502,3765401048,2244026483,1075463327,1455516326,1322494562,910128902,469688178,1117454909,936433444,3490320968,3675253459,1240580251,122909385,2157517691,634681816,4142456567,3825094682,3061402683,2540495037,79693498,3249098678,1084186820,1583128258,426386531,1761308591,1047286709,322548459,995290223,1845252383,2603652396,3431023940,2942221577,3202600964,3727903485,1712269319,422464435,3234572375,1170764815,3523960633,3117677531,1434042557,442511882,3600875718,1076654713,1738483198,4213154764,2393238008,3677496056,1014306527,4251020053,793779912,2902807211,842905082,4246964064,1395751752,1040244610,2656851899,3396308128,445077038,3742853595,3577915638,679411651,2892444358,2354009459,1767581616,3150600392,3791627101,3102740896,284835224,4246832056,1258075500,768725851,2589189241,3069724005,3532540348,1274779536,3789419226,2764799539,1660621633,3471099624,4011903706,913787905,3497959166,737222580,2514213453,2928710040,3937242737,1804850592,3499020752,2949064160,2386320175,2390070455,2415321851,4061277028,2290661394,2416832540,1336762016,1754252060,3520065937,3014181293,791618072,3188594551,3933548030,2332172193,3852520463,3043980520,413987798,3465142937,3030929376,4245938359,2093235073,3534596313,375366246,2157278981,2479649556,555357303,3870105701,2008414854,3344188149,4221384143,3956125452,2067696032,3594591187,2921233993,2428461,544322398,577241275,1471733935,610547355,4027169054,1432588573,1507829418,2025931657,3646575487,545086370,48609733,2200306550,1653985193,298326376,1316178497,3007786442,2064951626,458293330,2589141269,3591329599,3164325604,727753846,2179363840,146436021,1461446943,4069977195,705550613,3059967265,3887724982,4281599278,3313849956,1404054877,2845806497,146425753,1854211946],[1266315497,3048417604,3681880366,3289982499,290971e4,1235738493,2632868024,2414719590,3970600049,1771706367,1449415276,3266420449,422970021,1963543593,2690192192,3826793022,1062508698,1531092325,1804592342,2583117782,2714934279,4024971509,1294809318,4028980673,1289560198,2221992742,1669523910,35572830,157838143,1052438473,1016535060,1802137761,1753167236,1386275462,3080475397,2857371447,1040679964,2145300060,2390574316,1461121720,2956646967,4031777805,4028374788,33600511,2920084762,1018524850,629373528,3691585981,3515945977,2091462646,2486323059,586499841,988145025,935516892,3367335476,2599673255,2839830854,265290510,3972581182,2759138881,3795373465,1005194799,847297441,406762289,1314163512,1332590856,1866599683,4127851711,750260880,613907577,1450815602,3165620655,3734664991,3650291728,3012275730,3704569646,1427272223,778793252,1343938022,2676280711,2052605720,1946737175,3164576444,3914038668,3967478842,3682934266,1661551462,3294938066,4011595847,840292616,3712170807,616741398,312560963,711312465,1351876610,322626781,1910503582,271666773,2175563734,1594956187,70604529,3617834859,1007753275,1495573769,4069517037,2549218298,2663038764,504708206,2263041392,3941167025,2249088522,1514023603,1998579484,1312622330,694541497,2582060303,2151582166,1382467621,776784248,2618340202,3323268794,2497899128,2784771155,503983604,4076293799,907881277,423175695,432175456,1378068232,4145222326,3954048622,3938656102,3820766613,2793130115,2977904593,26017576,3274890735,3194772133,1700274565,1756076034,4006520079,3677328699,720338349,1533947780,354530856,688349552,3973924725,1637815568,332179504,3949051286,53804574,2852348879,3044236432,1282449977,3583942155,3416972820,4006381244,1617046695,2628476075,3002303598,1686838959,431878346,2686675385,1700445008,1080580658,1009431731,832498133,3223435511,2605976345,2271191193,2516031870,1648197032,4164389018,2548247927,300782431,375919233,238389289,3353747414,2531188641,2019080857,1475708069,455242339,2609103871,448939670,3451063019,1395535956,2413381860,1841049896,1491858159,885456874,4264095073,4001119347,1565136089,3898914787,1108368660,540939232,1173283510,2745871338,3681308437,4207628240,3343053890,4016749493,1699691293,1103962373,3625875870,2256883143,3830138730,1031889488,3479347698,1535977030,4236805024,3251091107,2132092099,1774941330,1199868427,1452454533,157007616,2904115357,342012276,595725824,1480756522,206960106,497939518,591360097,863170706,2375253569,3596610801,1814182875,2094937945,3421402208,1082520231,3463918190,2785509508,435703966,3908032597,1641649973,2842273706,3305899714,1510255612,2148256476,2655287854,3276092548,4258621189,236887753,3681803219,274041037,1734335097,3815195456,3317970021,1899903192,1026095262,4050517792,356393447,2410691914,3873677099,3682840055],[3913112168,2491498743,4132185628,2489919796,1091903735,1979897079,3170134830,3567386728,3557303409,857797738,1136121015,1342202287,507115054,2535736646,337727348,3213592640,1301675037,2528481711,1895095763,1721773893,3216771564,62756741,2142006736,835421444,2531993523,1442658625,3659876326,2882144922,676362277,1392781812,170690266,3921047035,1759253602,3611846912,1745797284,664899054,1329594018,3901205900,3045908486,2062866102,2865634940,3543621612,3464012697,1080764994,553557557,3656615353,3996768171,991055499,499776247,1265440854,648242737,3940784050,980351604,3713745714,1749149687,3396870395,4211799374,3640570775,1161844396,3125318951,1431517754,545492359,4268468663,3499529547,1437099964,2702547544,3433638243,2581715763,2787789398,1060185593,1593081372,2418618748,4260947970,69676912,2159744348,86519011,2512459080,3838209314,1220612927,3339683548,133810670,1090789135,1078426020,1569222167,845107691,3583754449,4072456591,1091646820,628848692,1613405280,3757631651,526609435,236106946,48312990,2942717905,3402727701,1797494240,859738849,992217954,4005476642,2243076622,3870952857,3732016268,765654824,3490871365,2511836413,1685915746,3888969200,1414112111,2273134842,3281911079,4080962846,172450625,2569994100,980381355,4109958455,2819808352,2716589560,2568741196,3681446669,3329971472,1835478071,660984891,3704678404,4045999559,3422617507,3040415634,1762651403,1719377915,3470491036,2693910283,3642056355,3138596744,1364962596,2073328063,1983633131,926494387,3423689081,2150032023,4096667949,1749200295,3328846651,309677260,2016342300,1779581495,3079819751,111262694,1274766160,443224088,298511866,1025883608,3806446537,1145181785,168956806,3641502830,3584813610,1689216846,3666258015,3200248200,1692713982,2646376535,4042768518,1618508792,1610833997,3523052358,4130873264,2001055236,3610705100,2202168115,4028541809,2961195399,1006657119,2006996926,3186142756,1430667929,3210227297,1314452623,4074634658,4101304120,2273951170,1399257539,3367210612,3027628629,1190975929,2062231137,2333990788,2221543033,2438960610,1181637006,548689776,2362791313,3372408396,3104550113,3145860560,296247880,1970579870,3078560182,3769228297,1714227617,3291629107,3898220290,166772364,1251581989,493813264,448347421,195405023,2709975567,677966185,3703036547,1463355134,2715995803,1338867538,1343315457,2802222074,2684532164,233230375,2599980071,2000651841,3277868038,1638401717,4028070440,3237316320,6314154,819756386,300326615,590932579,1405279636,3267499572,3150704214,2428286686,3959192993,3461946742,1862657033,1266418056,963775037,2089974820,2263052895,1917689273,448879540,3550394620,3981727096,150775221,3627908307,1303187396,508620638,2975983352,2726630617,1817252668,1876281319,1457606340,908771278,3720792119,3617206836,2455994898,1729034894,1080033504],[976866871,3556439503,2881648439,1522871579,1555064734,1336096578,3548522304,2579274686,3574697629,3205460757,3593280638,3338716283,3079412587,564236357,2993598910,1781952180,1464380207,3163844217,3332601554,1699332808,1393555694,1183702653,3581086237,1288719814,691649499,2847557200,2895455976,3193889540,2717570544,1781354906,1676643554,2592534050,3230253752,1126444790,2770207658,2633158820,2210423226,2615765581,2414155088,3127139286,673620729,2805611233,1269405062,4015350505,3341807571,4149409754,1057255273,2012875353,2162469141,2276492801,2601117357,993977747,3918593370,2654263191,753973209,36408145,2530585658,25011837,3520020182,2088578344,530523599,2918365339,1524020338,1518925132,3760827505,3759777254,1202760957,3985898139,3906192525,674977740,4174734889,2031300136,2019492241,3983892565,4153806404,3822280332,352677332,2297720250,60907813,90501309,3286998549,1016092578,2535922412,2839152426,457141659,509813237,4120667899,652014361,1966332200,2975202805,55981186,2327461051,676427537,3255491064,2882294119,3433927263,1307055953,942726286,933058658,2468411793,3933900994,4215176142,1361170020,2001714738,2830558078,3274259782,1222529897,1679025792,2729314320,3714953764,1770335741,151462246,3013232138,1682292957,1483529935,471910574,1539241949,458788160,3436315007,1807016891,3718408830,978976581,1043663428,3165965781,1927990952,4200891579,2372276910,3208408903,3533431907,1412390302,2931980059,4132332400,1947078029,3881505623,4168226417,2941484381,1077988104,1320477388,886195818,18198404,3786409e3,2509781533,112762804,3463356488,1866414978,891333506,18488651,661792760,1628790961,3885187036,3141171499,876946877,2693282273,1372485963,791857591,2686433993,3759982718,3167212022,3472953795,2716379847,445679433,3561995674,3504004811,3574258232,54117162,3331405415,2381918588,3769707343,4154350007,1140177722,4074052095,668550556,3214352940,367459370,261225585,2610173221,4209349473,3468074219,3265815641,314222801,3066103646,3808782860,282218597,3406013506,3773591054,379116347,1285071038,846784868,2669647154,3771962079,3550491691,2305946142,453669953,1268987020,3317592352,3279303384,3744833421,2610507566,3859509063,266596637,3847019092,517658769,3462560207,3443424879,370717030,4247526661,2224018117,4143653529,4112773975,2788324899,2477274417,1456262402,2901442914,1517677493,1846949527,2295493580,3734397586,2176403920,1280348187,1908823572,3871786941,846861322,1172426758,3287448474,3383383037,1655181056,3139813346,901632758,1897031941,2986607138,3066810236,3447102507,1393639104,373351379,950779232,625454576,3124240540,4148612726,2007998917,544563296,2244738638,2330496472,2058025392,1291430526,424198748,50039436,29584100,3605783033,2429876329,2791104160,1057563949,3255363231,3075367218,3463963227,1469046755,985887462]];var i={pbox:[],sbox:[]};function d(m,g){let x=g>>24&255,y=g>>16&255,w=g>>8&255,k=g&255,T=m.sbox[0][x]+m.sbox[1][y];return T=T^m.sbox[2][w],T=T+m.sbox[3][k],T}function c(m,g,x){let y=g,w=x,k;for(let T=0;T<u;++T)y=y^m.pbox[T],w=d(m,y)^w,k=y,y=w,w=k;return k=y,y=w,w=k,w=w^m.pbox[u],y=y^m.pbox[u+1],{left:y,right:w}}function f(m,g,x){let y=g,w=x,k;for(let T=u+1;T>1;--T)y=y^m.pbox[T],w=d(m,y)^w,k=y,y=w,w=k;return k=y,y=w,w=k,w=w^m.pbox[1],y=y^m.pbox[0],{left:y,right:w}}function h(m,g,x){for(let I=0;I<4;I++){m.sbox[I]=[];for(let D=0;D<256;D++)m.sbox[I][D]=s[I][D]}let y=0;for(let I=0;I<u+2;I++)m.pbox[I]=p[I]^g[y],y++,y>=x&&(y=0);let w=0,k=0,T=0;for(let I=0;I<u+2;I+=2)T=c(m,w,k),w=T.left,k=T.right,m.pbox[I]=w,m.pbox[I+1]=k;for(let I=0;I<4;I++)for(let D=0;D<256;D+=2)T=c(m,w,k),w=T.left,k=T.right,m.sbox[I][D]=w,m.sbox[I][D+1]=k;return!0}var v=o.Blowfish=a.extend({_doReset:function(){if(this._keyPriorReset!==this._key){var m=this._keyPriorReset=this._key,g=m.words,x=m.sigBytes/4;h(i,g,x)}},encryptBlock:function(m,g){var x=c(i,m[g],m[g+1]);m[g]=x.left,m[g+1]=x.right},decryptBlock:function(m,g){var x=f(i,m[g],m[g+1]);m[g]=x.left,m[g+1]=x.right},blockSize:64/32,keySize:128/32,ivSize:64/32});n.Blowfish=a._createHelper(v)}(),t.Blowfish})}(Bo)),Bo.exports}(function(e,r){(function(t,n,l){e.exports=n(Ae(),ei(),M1(),L1(),tr(),U1(),rr(),e0(),fa(),q1(),t0(),$1(),z1(),j1(),ha(),H1(),Nt(),ze(),V1(),W1(),K1(),G1(),Q1(),Y1(),X1(),Z1(),J1(),em(),tm(),rm(),nm(),im(),om(),am(),sm())})(xe,function(t){return t})})(N1);var we={},ti={};ti.byteLength=cm;ti.toByteArray=hm;ti.fromByteArray=mm;var wt=[],at=[],lm=typeof Uint8Array!="undefined"?Uint8Array:Array,ko="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var ur=0,um=ko.length;ur<um;++ur)wt[ur]=ko[ur],at[ko.charCodeAt(ur)]=ur;at[45]=62;at[95]=63;function r0(e){var r=e.length;if(r%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var t=e.indexOf("=");t===-1&&(t=r);var n=t===r?0:4-t%4;return[t,n]}function cm(e){var r=r0(e),t=r[0],n=r[1];return(t+n)*3/4-n}function fm(e,r,t){return(r+t)*3/4-t}function hm(e){var r,t=r0(e),n=t[0],l=t[1],a=new lm(fm(e,n,l)),o=0,u=l>0?n-4:n,p;for(p=0;p<u;p+=4)r=at[e.charCodeAt(p)]<<18|at[e.charCodeAt(p+1)]<<12|at[e.charCodeAt(p+2)]<<6|at[e.charCodeAt(p+3)],a[o++]=r>>16&255,a[o++]=r>>8&255,a[o++]=r&255;return l===2&&(r=at[e.charCodeAt(p)]<<2|at[e.charCodeAt(p+1)]>>4,a[o++]=r&255),l===1&&(r=at[e.charCodeAt(p)]<<10|at[e.charCodeAt(p+1)]<<4|at[e.charCodeAt(p+2)]>>2,a[o++]=r>>8&255,a[o++]=r&255),a}function pm(e){return wt[e>>18&63]+wt[e>>12&63]+wt[e>>6&63]+wt[e&63]}function dm(e,r,t){for(var n,l=[],a=r;a<t;a+=3)n=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(e[a+2]&255),l.push(pm(n));return l.join("")}function mm(e){for(var r,t=e.length,n=t%3,l=[],a=16383,o=0,u=t-n;o<u;o+=a)l.push(dm(e,o,o+a>u?u:o+a));return n===1?(r=e[t-1],l.push(wt[r>>2]+wt[r<<4&63]+"==")):n===2&&(r=(e[t-2]<<8)+e[t-1],l.push(wt[r>>10]+wt[r>>4&63]+wt[r<<2&63]+"=")),l.join("")}var pa={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */pa.read=function(e,r,t,n,l){var a,o,u=l*8-n-1,p=(1<<u)-1,s=p>>1,i=-7,d=t?l-1:0,c=t?-1:1,f=e[r+d];for(d+=c,a=f&(1<<-i)-1,f>>=-i,i+=u;i>0;a=a*256+e[r+d],d+=c,i-=8);for(o=a&(1<<-i)-1,a>>=-i,i+=n;i>0;o=o*256+e[r+d],d+=c,i-=8);if(a===0)a=1-s;else{if(a===p)return o?NaN:(f?-1:1)*(1/0);o=o+Math.pow(2,n),a=a-s}return(f?-1:1)*o*Math.pow(2,a-n)};pa.write=function(e,r,t,n,l,a){var o,u,p,s=a*8-l-1,i=(1<<s)-1,d=i>>1,c=l===23?Math.pow(2,-24)-Math.pow(2,-77):0,f=n?0:a-1,h=n?1:-1,v=r<0||r===0&&1/r<0?1:0;for(r=Math.abs(r),isNaN(r)||r===1/0?(u=isNaN(r)?1:0,o=i):(o=Math.floor(Math.log(r)/Math.LN2),r*(p=Math.pow(2,-o))<1&&(o--,p*=2),o+d>=1?r+=c/p:r+=c*Math.pow(2,1-d),r*p>=2&&(o++,p/=2),o+d>=i?(u=0,o=i):o+d>=1?(u=(r*p-1)*Math.pow(2,l),o=o+d):(u=r*Math.pow(2,d-1)*Math.pow(2,l),o=0));l>=8;e[t+f]=u&255,f+=h,u/=256,l-=8);for(o=o<<l|u,s+=l;s>0;e[t+f]=o&255,f+=h,o/=256,s-=8);e[t+f-h]|=v*128};/*!
27
27
  * The buffer module from node.js, for the browser.
28
28
  *
29
29
  * @author Feross Aboukhadijeh <https://feross.org>
30
30
  * @license MIT
31
- */(function(e){var r=ti,t=pa,n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=u,e.SlowBuffer=x,e.INSPECT_MAX_BYTES=50;var l=2147483647;e.kMaxLength=l,u.TYPED_ARRAY_SUPPORT=a(),!u.TYPED_ARRAY_SUPPORT&&typeof console!="undefined"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function a(){try{var z=new Uint8Array(1),S={foo:function(){return 42}};return Object.setPrototypeOf(S,Uint8Array.prototype),Object.setPrototypeOf(z,S),z.foo()===42}catch(B){return!1}}Object.defineProperty(u.prototype,"parent",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.buffer}}),Object.defineProperty(u.prototype,"offset",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.byteOffset}});function o(z){if(z>l)throw new RangeError('The value "'+z+'" is invalid for option "size"');var S=new Uint8Array(z);return Object.setPrototypeOf(S,u.prototype),S}function u(z,S,B){if(typeof z=="number"){if(typeof S=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return d(z)}return p(z,S,B)}u.poolSize=8192;function p(z,S,B){if(typeof z=="string")return c(z,S);if(ArrayBuffer.isView(z))return h(z);if(z==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z);if(ee(z,ArrayBuffer)||z&&ee(z.buffer,ArrayBuffer)||typeof SharedArrayBuffer!="undefined"&&(ee(z,SharedArrayBuffer)||z&&ee(z.buffer,SharedArrayBuffer)))return v(z,S,B);if(typeof z=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var Y=z.valueOf&&z.valueOf();if(Y!=null&&Y!==z)return u.from(Y,S,B);var ie=m(z);if(ie)return ie;if(typeof Symbol!="undefined"&&Symbol.toPrimitive!=null&&typeof z[Symbol.toPrimitive]=="function")return u.from(z[Symbol.toPrimitive]("string"),S,B);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z)}u.from=function(z,S,B){return p(z,S,B)},Object.setPrototypeOf(u.prototype,Uint8Array.prototype),Object.setPrototypeOf(u,Uint8Array);function s(z){if(typeof z!="number")throw new TypeError('"size" argument must be of type number');if(z<0)throw new RangeError('The value "'+z+'" is invalid for option "size"')}function i(z,S,B){return s(z),z<=0?o(z):S!==void 0?typeof B=="string"?o(z).fill(S,B):o(z).fill(S):o(z)}u.alloc=function(z,S,B){return i(z,S,B)};function d(z){return s(z),o(z<0?0:g(z)|0)}u.allocUnsafe=function(z){return d(z)},u.allocUnsafeSlow=function(z){return d(z)};function c(z,S){if((typeof S!="string"||S==="")&&(S="utf8"),!u.isEncoding(S))throw new TypeError("Unknown encoding: "+S);var B=y(z,S)|0,Y=o(B),ie=Y.write(z,S);return ie!==B&&(Y=Y.slice(0,ie)),Y}function f(z){for(var S=z.length<0?0:g(z.length)|0,B=o(S),Y=0;Y<S;Y+=1)B[Y]=z[Y]&255;return B}function h(z){if(ee(z,Uint8Array)){var S=new Uint8Array(z);return v(S.buffer,S.byteOffset,S.byteLength)}return f(z)}function v(z,S,B){if(S<0||z.byteLength<S)throw new RangeError('"offset" is outside of buffer bounds');if(z.byteLength<S+(B||0))throw new RangeError('"length" is outside of buffer bounds');var Y;return S===void 0&&B===void 0?Y=new Uint8Array(z):B===void 0?Y=new Uint8Array(z,S):Y=new Uint8Array(z,S,B),Object.setPrototypeOf(Y,u.prototype),Y}function m(z){if(u.isBuffer(z)){var S=g(z.length)|0,B=o(S);return B.length===0||z.copy(B,0,0,S),B}if(z.length!==void 0)return typeof z.length!="number"||te(z.length)?o(0):f(z);if(z.type==="Buffer"&&Array.isArray(z.data))return f(z.data)}function g(z){if(z>=l)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+l.toString(16)+" bytes");return z|0}function x(z){return+z!=z&&(z=0),u.alloc(+z)}u.isBuffer=function(S){return S!=null&&S._isBuffer===!0&&S!==u.prototype},u.compare=function(S,B){if(ee(S,Uint8Array)&&(S=u.from(S,S.offset,S.byteLength)),ee(B,Uint8Array)&&(B=u.from(B,B.offset,B.byteLength)),!u.isBuffer(S)||!u.isBuffer(B))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(S===B)return 0;for(var Y=S.length,ie=B.length,ue=0,ce=Math.min(Y,ie);ue<ce;++ue)if(S[ue]!==B[ue]){Y=S[ue],ie=B[ue];break}return Y<ie?-1:ie<Y?1:0},u.isEncoding=function(S){switch(String(S).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}},u.concat=function(S,B){if(!Array.isArray(S))throw new TypeError('"list" argument must be an Array of Buffers');if(S.length===0)return u.alloc(0);var Y;if(B===void 0)for(B=0,Y=0;Y<S.length;++Y)B+=S[Y].length;var ie=u.allocUnsafe(B),ue=0;for(Y=0;Y<S.length;++Y){var ce=S[Y];if(ee(ce,Uint8Array))ue+ce.length>ie.length?u.from(ce).copy(ie,ue):Uint8Array.prototype.set.call(ie,ce,ue);else if(u.isBuffer(ce))ce.copy(ie,ue);else throw new TypeError('"list" argument must be an Array of Buffers');ue+=ce.length}return ie};function y(z,S){if(u.isBuffer(z))return z.length;if(ArrayBuffer.isView(z)||ee(z,ArrayBuffer))return z.byteLength;if(typeof z!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof z);var B=z.length,Y=arguments.length>2&&arguments[2]===!0;if(!Y&&B===0)return 0;for(var ie=!1;;)switch(S){case"ascii":case"latin1":case"binary":return B;case"utf8":case"utf-8":return ae(z).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return B*2;case"hex":return B>>>1;case"base64":return R(z).length;default:if(ie)return Y?-1:ae(z).length;S=(""+S).toLowerCase(),ie=!0}}u.byteLength=y;function w(z,S,B){var Y=!1;if((S===void 0||S<0)&&(S=0),S>this.length||((B===void 0||B>this.length)&&(B=this.length),B<=0)||(B>>>=0,S>>>=0,B<=S))return"";for(z||(z="utf8");;)switch(z){case"hex":return U(this,S,B);case"utf8":case"utf-8":return F(this,S,B);case"ascii":return J(this,S,B);case"latin1":case"binary":return $(this,S,B);case"base64":return C(this,S,B);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return K(this,S,B);default:if(Y)throw new TypeError("Unknown encoding: "+z);z=(z+"").toLowerCase(),Y=!0}}u.prototype._isBuffer=!0;function k(z,S,B){var Y=z[S];z[S]=z[B],z[B]=Y}u.prototype.swap16=function(){var S=this.length;if(S%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var B=0;B<S;B+=2)k(this,B,B+1);return this},u.prototype.swap32=function(){var S=this.length;if(S%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var B=0;B<S;B+=4)k(this,B,B+3),k(this,B+1,B+2);return this},u.prototype.swap64=function(){var S=this.length;if(S%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var B=0;B<S;B+=8)k(this,B,B+7),k(this,B+1,B+6),k(this,B+2,B+5),k(this,B+3,B+4);return this},u.prototype.toString=function(){var S=this.length;return S===0?"":arguments.length===0?F(this,0,S):w.apply(this,arguments)},u.prototype.toLocaleString=u.prototype.toString,u.prototype.equals=function(S){if(!u.isBuffer(S))throw new TypeError("Argument must be a Buffer");return this===S?!0:u.compare(this,S)===0},u.prototype.inspect=function(){var S="",B=e.INSPECT_MAX_BYTES;return S=this.toString("hex",0,B).replace(/(.{2})/g,"$1 ").trim(),this.length>B&&(S+=" ... "),"<Buffer "+S+">"},n&&(u.prototype[n]=u.prototype.inspect),u.prototype.compare=function(S,B,Y,ie,ue){if(ee(S,Uint8Array)&&(S=u.from(S,S.offset,S.byteLength)),!u.isBuffer(S))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof S);if(B===void 0&&(B=0),Y===void 0&&(Y=S?S.length:0),ie===void 0&&(ie=0),ue===void 0&&(ue=this.length),B<0||Y>S.length||ie<0||ue>this.length)throw new RangeError("out of range index");if(ie>=ue&&B>=Y)return 0;if(ie>=ue)return-1;if(B>=Y)return 1;if(B>>>=0,Y>>>=0,ie>>>=0,ue>>>=0,this===S)return 0;for(var ce=ue-ie,me=Y-B,ge=Math.min(ce,me),Ce=this.slice(ie,ue),Te=S.slice(B,Y),Be=0;Be<ge;++Be)if(Ce[Be]!==Te[Be]){ce=Ce[Be],me=Te[Be];break}return ce<me?-1:me<ce?1:0};function T(z,S,B,Y,ie){if(z.length===0)return-1;if(typeof B=="string"?(Y=B,B=0):B>2147483647?B=2147483647:B<-2147483648&&(B=-2147483648),B=+B,te(B)&&(B=ie?0:z.length-1),B<0&&(B=z.length+B),B>=z.length){if(ie)return-1;B=z.length-1}else if(B<0)if(ie)B=0;else return-1;if(typeof S=="string"&&(S=u.from(S,Y)),u.isBuffer(S))return S.length===0?-1:I(z,S,B,Y,ie);if(typeof S=="number")return S=S&255,typeof Uint8Array.prototype.indexOf=="function"?ie?Uint8Array.prototype.indexOf.call(z,S,B):Uint8Array.prototype.lastIndexOf.call(z,S,B):I(z,[S],B,Y,ie);throw new TypeError("val must be string, number or Buffer")}function I(z,S,B,Y,ie){var ue=1,ce=z.length,me=S.length;if(Y!==void 0&&(Y=String(Y).toLowerCase(),Y==="ucs2"||Y==="ucs-2"||Y==="utf16le"||Y==="utf-16le")){if(z.length<2||S.length<2)return-1;ue=2,ce/=2,me/=2,B/=2}function ge(Lt,Ut){return ue===1?Lt[Ut]:Lt.readUInt16BE(Ut*ue)}var Ce;if(ie){var Te=-1;for(Ce=B;Ce<ce;Ce++)if(ge(z,Ce)===ge(S,Te===-1?0:Ce-Te)){if(Te===-1&&(Te=Ce),Ce-Te+1===me)return Te*ue}else Te!==-1&&(Ce-=Ce-Te),Te=-1}else for(B+me>ce&&(B=ce-me),Ce=B;Ce>=0;Ce--){for(var Be=!0,kt=0;kt<me;kt++)if(ge(z,Ce+kt)!==ge(S,kt)){Be=!1;break}if(Be)return Ce}return-1}u.prototype.includes=function(S,B,Y){return this.indexOf(S,B,Y)!==-1},u.prototype.indexOf=function(S,B,Y){return T(this,S,B,Y,!0)},u.prototype.lastIndexOf=function(S,B,Y){return T(this,S,B,Y,!1)};function D(z,S,B,Y){B=Number(B)||0;var ie=z.length-B;Y?(Y=Number(Y),Y>ie&&(Y=ie)):Y=ie;var ue=S.length;Y>ue/2&&(Y=ue/2);for(var ce=0;ce<Y;++ce){var me=parseInt(S.substr(ce*2,2),16);if(te(me))return ce;z[B+ce]=me}return ce}function X(z,S,B,Y){return G(ae(S,z.length-B),z,B,Y)}function V(z,S,B,Y){return G(b(S),z,B,Y)}function E(z,S,B,Y){return G(R(S),z,B,Y)}function A(z,S,B,Y){return G(_(S,z.length-B),z,B,Y)}u.prototype.write=function(S,B,Y,ie){if(B===void 0)ie="utf8",Y=this.length,B=0;else if(Y===void 0&&typeof B=="string")ie=B,Y=this.length,B=0;else if(isFinite(B))B=B>>>0,isFinite(Y)?(Y=Y>>>0,ie===void 0&&(ie="utf8")):(ie=Y,Y=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var ue=this.length-B;if((Y===void 0||Y>ue)&&(Y=ue),S.length>0&&(Y<0||B<0)||B>this.length)throw new RangeError("Attempt to write outside buffer bounds");ie||(ie="utf8");for(var ce=!1;;)switch(ie){case"hex":return D(this,S,B,Y);case"utf8":case"utf-8":return X(this,S,B,Y);case"ascii":case"latin1":case"binary":return V(this,S,B,Y);case"base64":return E(this,S,B,Y);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,S,B,Y);default:if(ce)throw new TypeError("Unknown encoding: "+ie);ie=(""+ie).toLowerCase(),ce=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function C(z,S,B){return S===0&&B===z.length?r.fromByteArray(z):r.fromByteArray(z.slice(S,B))}function F(z,S,B){B=Math.min(z.length,B);for(var Y=[],ie=S;ie<B;){var ue=z[ie],ce=null,me=ue>239?4:ue>223?3:ue>191?2:1;if(ie+me<=B){var ge,Ce,Te,Be;switch(me){case 1:ue<128&&(ce=ue);break;case 2:ge=z[ie+1],(ge&192)===128&&(Be=(ue&31)<<6|ge&63,Be>127&&(ce=Be));break;case 3:ge=z[ie+1],Ce=z[ie+2],(ge&192)===128&&(Ce&192)===128&&(Be=(ue&15)<<12|(ge&63)<<6|Ce&63,Be>2047&&(Be<55296||Be>57343)&&(ce=Be));break;case 4:ge=z[ie+1],Ce=z[ie+2],Te=z[ie+3],(ge&192)===128&&(Ce&192)===128&&(Te&192)===128&&(Be=(ue&15)<<18|(ge&63)<<12|(Ce&63)<<6|Te&63,Be>65535&&Be<1114112&&(ce=Be))}}ce===null?(ce=65533,me=1):ce>65535&&(ce-=65536,Y.push(ce>>>10&1023|55296),ce=56320|ce&1023),Y.push(ce),ie+=me}return P(Y)}var j=4096;function P(z){var S=z.length;if(S<=j)return String.fromCharCode.apply(String,z);for(var B="",Y=0;Y<S;)B+=String.fromCharCode.apply(String,z.slice(Y,Y+=j));return B}function J(z,S,B){var Y="";B=Math.min(z.length,B);for(var ie=S;ie<B;++ie)Y+=String.fromCharCode(z[ie]&127);return Y}function $(z,S,B){var Y="";B=Math.min(z.length,B);for(var ie=S;ie<B;++ie)Y+=String.fromCharCode(z[ie]);return Y}function U(z,S,B){var Y=z.length;(!S||S<0)&&(S=0),(!B||B<0||B>Y)&&(B=Y);for(var ie="",ue=S;ue<B;++ue)ie+=se[z[ue]];return ie}function K(z,S,B){for(var Y=z.slice(S,B),ie="",ue=0;ue<Y.length-1;ue+=2)ie+=String.fromCharCode(Y[ue]+Y[ue+1]*256);return ie}u.prototype.slice=function(S,B){var Y=this.length;S=~~S,B=B===void 0?Y:~~B,S<0?(S+=Y,S<0&&(S=0)):S>Y&&(S=Y),B<0?(B+=Y,B<0&&(B=0)):B>Y&&(B=Y),B<S&&(B=S);var ie=this.subarray(S,B);return Object.setPrototypeOf(ie,u.prototype),ie};function L(z,S,B){if(z%1!==0||z<0)throw new RangeError("offset is not uint");if(z+S>B)throw new RangeError("Trying to access beyond buffer length")}u.prototype.readUintLE=u.prototype.readUIntLE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=this[S],ue=1,ce=0;++ce<B&&(ue*=256);)ie+=this[S+ce]*ue;return ie},u.prototype.readUintBE=u.prototype.readUIntBE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=this[S+--B],ue=1;B>0&&(ue*=256);)ie+=this[S+--B]*ue;return ie},u.prototype.readUint8=u.prototype.readUInt8=function(S,B){return S=S>>>0,B||L(S,1,this.length),this[S]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(S,B){return S=S>>>0,B||L(S,2,this.length),this[S]|this[S+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(S,B){return S=S>>>0,B||L(S,2,this.length),this[S]<<8|this[S+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(S,B){return S=S>>>0,B||L(S,4,this.length),(this[S]|this[S+1]<<8|this[S+2]<<16)+this[S+3]*16777216},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(S,B){return S=S>>>0,B||L(S,4,this.length),this[S]*16777216+(this[S+1]<<16|this[S+2]<<8|this[S+3])},u.prototype.readIntLE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=this[S],ue=1,ce=0;++ce<B&&(ue*=256);)ie+=this[S+ce]*ue;return ue*=128,ie>=ue&&(ie-=Math.pow(2,8*B)),ie},u.prototype.readIntBE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=B,ue=1,ce=this[S+--ie];ie>0&&(ue*=256);)ce+=this[S+--ie]*ue;return ue*=128,ce>=ue&&(ce-=Math.pow(2,8*B)),ce},u.prototype.readInt8=function(S,B){return S=S>>>0,B||L(S,1,this.length),this[S]&128?(255-this[S]+1)*-1:this[S]},u.prototype.readInt16LE=function(S,B){S=S>>>0,B||L(S,2,this.length);var Y=this[S]|this[S+1]<<8;return Y&32768?Y|4294901760:Y},u.prototype.readInt16BE=function(S,B){S=S>>>0,B||L(S,2,this.length);var Y=this[S+1]|this[S]<<8;return Y&32768?Y|4294901760:Y},u.prototype.readInt32LE=function(S,B){return S=S>>>0,B||L(S,4,this.length),this[S]|this[S+1]<<8|this[S+2]<<16|this[S+3]<<24},u.prototype.readInt32BE=function(S,B){return S=S>>>0,B||L(S,4,this.length),this[S]<<24|this[S+1]<<16|this[S+2]<<8|this[S+3]},u.prototype.readFloatLE=function(S,B){return S=S>>>0,B||L(S,4,this.length),t.read(this,S,!0,23,4)},u.prototype.readFloatBE=function(S,B){return S=S>>>0,B||L(S,4,this.length),t.read(this,S,!1,23,4)},u.prototype.readDoubleLE=function(S,B){return S=S>>>0,B||L(S,8,this.length),t.read(this,S,!0,52,8)},u.prototype.readDoubleBE=function(S,B){return S=S>>>0,B||L(S,8,this.length),t.read(this,S,!1,52,8)};function O(z,S,B,Y,ie,ue){if(!u.isBuffer(z))throw new TypeError('"buffer" argument must be a Buffer instance');if(S>ie||S<ue)throw new RangeError('"value" argument is out of bounds');if(B+Y>z.length)throw new RangeError("Index out of range")}u.prototype.writeUintLE=u.prototype.writeUIntLE=function(S,B,Y,ie){if(S=+S,B=B>>>0,Y=Y>>>0,!ie){var ue=Math.pow(2,8*Y)-1;O(this,S,B,Y,ue,0)}var ce=1,me=0;for(this[B]=S&255;++me<Y&&(ce*=256);)this[B+me]=S/ce&255;return B+Y},u.prototype.writeUintBE=u.prototype.writeUIntBE=function(S,B,Y,ie){if(S=+S,B=B>>>0,Y=Y>>>0,!ie){var ue=Math.pow(2,8*Y)-1;O(this,S,B,Y,ue,0)}var ce=Y-1,me=1;for(this[B+ce]=S&255;--ce>=0&&(me*=256);)this[B+ce]=S/me&255;return B+Y},u.prototype.writeUint8=u.prototype.writeUInt8=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,1,255,0),this[B]=S&255,B+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,65535,0),this[B]=S&255,this[B+1]=S>>>8,B+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,65535,0),this[B]=S>>>8,this[B+1]=S&255,B+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,4294967295,0),this[B+3]=S>>>24,this[B+2]=S>>>16,this[B+1]=S>>>8,this[B]=S&255,B+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,4294967295,0),this[B]=S>>>24,this[B+1]=S>>>16,this[B+2]=S>>>8,this[B+3]=S&255,B+4},u.prototype.writeIntLE=function(S,B,Y,ie){if(S=+S,B=B>>>0,!ie){var ue=Math.pow(2,8*Y-1);O(this,S,B,Y,ue-1,-ue)}var ce=0,me=1,ge=0;for(this[B]=S&255;++ce<Y&&(me*=256);)S<0&&ge===0&&this[B+ce-1]!==0&&(ge=1),this[B+ce]=(S/me>>0)-ge&255;return B+Y},u.prototype.writeIntBE=function(S,B,Y,ie){if(S=+S,B=B>>>0,!ie){var ue=Math.pow(2,8*Y-1);O(this,S,B,Y,ue-1,-ue)}var ce=Y-1,me=1,ge=0;for(this[B+ce]=S&255;--ce>=0&&(me*=256);)S<0&&ge===0&&this[B+ce+1]!==0&&(ge=1),this[B+ce]=(S/me>>0)-ge&255;return B+Y},u.prototype.writeInt8=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,1,127,-128),S<0&&(S=255+S+1),this[B]=S&255,B+1},u.prototype.writeInt16LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,32767,-32768),this[B]=S&255,this[B+1]=S>>>8,B+2},u.prototype.writeInt16BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,32767,-32768),this[B]=S>>>8,this[B+1]=S&255,B+2},u.prototype.writeInt32LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,2147483647,-2147483648),this[B]=S&255,this[B+1]=S>>>8,this[B+2]=S>>>16,this[B+3]=S>>>24,B+4},u.prototype.writeInt32BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,2147483647,-2147483648),S<0&&(S=4294967295+S+1),this[B]=S>>>24,this[B+1]=S>>>16,this[B+2]=S>>>8,this[B+3]=S&255,B+4};function H(z,S,B,Y,ie,ue){if(B+Y>z.length)throw new RangeError("Index out of range");if(B<0)throw new RangeError("Index out of range")}function W(z,S,B,Y,ie){return S=+S,B=B>>>0,ie||H(z,S,B,4),t.write(z,S,B,Y,23,4),B+4}u.prototype.writeFloatLE=function(S,B,Y){return W(this,S,B,!0,Y)},u.prototype.writeFloatBE=function(S,B,Y){return W(this,S,B,!1,Y)};function Z(z,S,B,Y,ie){return S=+S,B=B>>>0,ie||H(z,S,B,8),t.write(z,S,B,Y,52,8),B+8}u.prototype.writeDoubleLE=function(S,B,Y){return Z(this,S,B,!0,Y)},u.prototype.writeDoubleBE=function(S,B,Y){return Z(this,S,B,!1,Y)},u.prototype.copy=function(S,B,Y,ie){if(!u.isBuffer(S))throw new TypeError("argument should be a Buffer");if(Y||(Y=0),!ie&&ie!==0&&(ie=this.length),B>=S.length&&(B=S.length),B||(B=0),ie>0&&ie<Y&&(ie=Y),ie===Y||S.length===0||this.length===0)return 0;if(B<0)throw new RangeError("targetStart out of bounds");if(Y<0||Y>=this.length)throw new RangeError("Index out of range");if(ie<0)throw new RangeError("sourceEnd out of bounds");ie>this.length&&(ie=this.length),S.length-B<ie-Y&&(ie=S.length-B+Y);var ue=ie-Y;return this===S&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(B,Y,ie):Uint8Array.prototype.set.call(S,this.subarray(Y,ie),B),ue},u.prototype.fill=function(S,B,Y,ie){if(typeof S=="string"){if(typeof B=="string"?(ie=B,B=0,Y=this.length):typeof Y=="string"&&(ie=Y,Y=this.length),ie!==void 0&&typeof ie!="string")throw new TypeError("encoding must be a string");if(typeof ie=="string"&&!u.isEncoding(ie))throw new TypeError("Unknown encoding: "+ie);if(S.length===1){var ue=S.charCodeAt(0);(ie==="utf8"&&ue<128||ie==="latin1")&&(S=ue)}}else typeof S=="number"?S=S&255:typeof S=="boolean"&&(S=Number(S));if(B<0||this.length<B||this.length<Y)throw new RangeError("Out of range index");if(Y<=B)return this;B=B>>>0,Y=Y===void 0?this.length:Y>>>0,S||(S=0);var ce;if(typeof S=="number")for(ce=B;ce<Y;++ce)this[ce]=S;else{var me=u.isBuffer(S)?S:u.from(S,ie),ge=me.length;if(ge===0)throw new TypeError('The value "'+S+'" is invalid for argument "value"');for(ce=0;ce<Y-B;++ce)this[ce+B]=me[ce%ge]}return this};var re=/[^+/0-9A-Za-z-_]/g;function oe(z){if(z=z.split("=")[0],z=z.trim().replace(re,""),z.length<2)return"";for(;z.length%4!==0;)z=z+"=";return z}function ae(z,S){S=S||1/0;for(var B,Y=z.length,ie=null,ue=[],ce=0;ce<Y;++ce){if(B=z.charCodeAt(ce),B>55295&&B<57344){if(!ie){if(B>56319){(S-=3)>-1&&ue.push(239,191,189);continue}else if(ce+1===Y){(S-=3)>-1&&ue.push(239,191,189);continue}ie=B;continue}if(B<56320){(S-=3)>-1&&ue.push(239,191,189),ie=B;continue}B=(ie-55296<<10|B-56320)+65536}else ie&&(S-=3)>-1&&ue.push(239,191,189);if(ie=null,B<128){if((S-=1)<0)break;ue.push(B)}else if(B<2048){if((S-=2)<0)break;ue.push(B>>6|192,B&63|128)}else if(B<65536){if((S-=3)<0)break;ue.push(B>>12|224,B>>6&63|128,B&63|128)}else if(B<1114112){if((S-=4)<0)break;ue.push(B>>18|240,B>>12&63|128,B>>6&63|128,B&63|128)}else throw new Error("Invalid code point")}return ue}function b(z){for(var S=[],B=0;B<z.length;++B)S.push(z.charCodeAt(B)&255);return S}function _(z,S){for(var B,Y,ie,ue=[],ce=0;ce<z.length&&!((S-=2)<0);++ce)B=z.charCodeAt(ce),Y=B>>8,ie=B%256,ue.push(ie),ue.push(Y);return ue}function R(z){return r.toByteArray(oe(z))}function G(z,S,B,Y){for(var ie=0;ie<Y&&!(ie+B>=S.length||ie>=z.length);++ie)S[ie+B]=z[ie];return ie}function ee(z,S){return z instanceof S||z!=null&&z.constructor!=null&&z.constructor.name!=null&&z.constructor.name===S.name}function te(z){return z!==z}var se=function(){for(var z="0123456789abcdef",S=new Array(256),B=0;B<16;++B)for(var Y=B*16,ie=0;ie<16;++ie)S[Y+ie]=z[B]+z[ie];return S}()})(we);var bm=we.Buffer,wm=function(e){if(e instanceof Uint8Array){if(e.byteOffset===0&&e.byteLength===e.buffer.byteLength)return e.buffer;if(typeof e.buffer.slice=="function")return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)}if(bm.isBuffer(e)){for(var r=new Uint8Array(e.length),t=e.length,n=0;n<t;n++)r[n]=e[n];return r.buffer}else throw new Error("Argument must be a Buffer")};const $r=Zo(wm);var n0={exports:{}};(function(e,r){(function(){var t,n=0xdeadbeefcafe,l=(n&16777215)==15715070;function a(M,q,Q){M!=null&&(typeof M=="number"?this.fromNumber(M,q,Q):q==null&&typeof M!="string"?this.fromString(M,256):this.fromString(M,q))}function o(){return new a(null)}function u(M,q,Q,ne,fe,pe){for(;--pe>=0;){var de=q*this[M++]+Q[ne]+fe;fe=Math.floor(de/67108864),Q[ne++]=de&67108863}return fe}function p(M,q,Q,ne,fe,pe){for(var de=q&32767,ve=q>>15;--pe>=0;){var Fe=this[M]&32767,Ue=this[M++]>>15,it=ve*Fe+Ue*de;Fe=de*Fe+((it&32767)<<15)+Q[ne]+(fe&1073741823),fe=(Fe>>>30)+(it>>>15)+ve*Ue+(fe>>>30),Q[ne++]=Fe&1073741823}return fe}function s(M,q,Q,ne,fe,pe){for(var de=q&16383,ve=q>>14;--pe>=0;){var Fe=this[M]&16383,Ue=this[M++]>>14,it=ve*Fe+Ue*de;Fe=de*Fe+((it&16383)<<14)+Q[ne]+fe,fe=(Fe>>28)+(it>>14)+ve*Ue,Q[ne++]=Fe&268435455}return fe}var i=typeof navigator!="undefined";i&&l&&navigator.appName=="Microsoft Internet Explorer"?(a.prototype.am=p,t=30):i&&l&&navigator.appName!="Netscape"?(a.prototype.am=u,t=26):(a.prototype.am=s,t=28),a.prototype.DB=t,a.prototype.DM=(1<<t)-1,a.prototype.DV=1<<t;var d=52;a.prototype.FV=Math.pow(2,d),a.prototype.F1=d-t,a.prototype.F2=2*t-d;var c="0123456789abcdefghijklmnopqrstuvwxyz",f=new Array,h,v;for(h=48,v=0;v<=9;++v)f[h++]=v;for(h=97,v=10;v<36;++v)f[h++]=v;for(h=65,v=10;v<36;++v)f[h++]=v;function m(M){return c.charAt(M)}function g(M,q){var Q=f[M.charCodeAt(q)];return Q==null?-1:Q}function x(M){for(var q=this.t-1;q>=0;--q)M[q]=this[q];M.t=this.t,M.s=this.s}function y(M){this.t=1,this.s=M<0?-1:0,M>0?this[0]=M:M<-1?this[0]=M+this.DV:this.t=0}function w(M){var q=o();return q.fromInt(M),q}function k(M,q){var Q;if(q==16)Q=4;else if(q==8)Q=3;else if(q==256)Q=8;else if(q==2)Q=1;else if(q==32)Q=5;else if(q==4)Q=2;else{this.fromRadix(M,q);return}this.t=0,this.s=0;for(var ne=M.length,fe=!1,pe=0;--ne>=0;){var de=Q==8?M[ne]&255:g(M,ne);if(de<0){M.charAt(ne)=="-"&&(fe=!0);continue}fe=!1,pe==0?this[this.t++]=de:pe+Q>this.DB?(this[this.t-1]|=(de&(1<<this.DB-pe)-1)<<pe,this[this.t++]=de>>this.DB-pe):this[this.t-1]|=de<<pe,pe+=Q,pe>=this.DB&&(pe-=this.DB)}Q==8&&M[0]&128&&(this.s=-1,pe>0&&(this[this.t-1]|=(1<<this.DB-pe)-1<<pe)),this.clamp(),fe&&a.ZERO.subTo(this,this)}function T(){for(var M=this.s&this.DM;this.t>0&&this[this.t-1]==M;)--this.t}function I(M){if(this.s<0)return"-"+this.negate().toString(M);var q;if(M==16)q=4;else if(M==8)q=3;else if(M==2)q=1;else if(M==32)q=5;else if(M==4)q=2;else return this.toRadix(M);var Q=(1<<q)-1,ne,fe=!1,pe="",de=this.t,ve=this.DB-de*this.DB%q;if(de-- >0)for(ve<this.DB&&(ne=this[de]>>ve)>0&&(fe=!0,pe=m(ne));de>=0;)ve<q?(ne=(this[de]&(1<<ve)-1)<<q-ve,ne|=this[--de]>>(ve+=this.DB-q)):(ne=this[de]>>(ve-=q)&Q,ve<=0&&(ve+=this.DB,--de)),ne>0&&(fe=!0),fe&&(pe+=m(ne));return fe?pe:"0"}function D(){var M=o();return a.ZERO.subTo(this,M),M}function X(){return this.s<0?this.negate():this}function V(M){var q=this.s-M.s;if(q!=0)return q;var Q=this.t;if(q=Q-M.t,q!=0)return this.s<0?-q:q;for(;--Q>=0;)if((q=this[Q]-M[Q])!=0)return q;return 0}function E(M){var q=1,Q;return(Q=M>>>16)!=0&&(M=Q,q+=16),(Q=M>>8)!=0&&(M=Q,q+=8),(Q=M>>4)!=0&&(M=Q,q+=4),(Q=M>>2)!=0&&(M=Q,q+=2),(Q=M>>1)!=0&&(M=Q,q+=1),q}function A(){return this.t<=0?0:this.DB*(this.t-1)+E(this[this.t-1]^this.s&this.DM)}function C(M,q){var Q;for(Q=this.t-1;Q>=0;--Q)q[Q+M]=this[Q];for(Q=M-1;Q>=0;--Q)q[Q]=0;q.t=this.t+M,q.s=this.s}function F(M,q){for(var Q=M;Q<this.t;++Q)q[Q-M]=this[Q];q.t=Math.max(this.t-M,0),q.s=this.s}function j(M,q){var Q=M%this.DB,ne=this.DB-Q,fe=(1<<ne)-1,pe=Math.floor(M/this.DB),de=this.s<<Q&this.DM,ve;for(ve=this.t-1;ve>=0;--ve)q[ve+pe+1]=this[ve]>>ne|de,de=(this[ve]&fe)<<Q;for(ve=pe-1;ve>=0;--ve)q[ve]=0;q[pe]=de,q.t=this.t+pe+1,q.s=this.s,q.clamp()}function P(M,q){q.s=this.s;var Q=Math.floor(M/this.DB);if(Q>=this.t){q.t=0;return}var ne=M%this.DB,fe=this.DB-ne,pe=(1<<ne)-1;q[0]=this[Q]>>ne;for(var de=Q+1;de<this.t;++de)q[de-Q-1]|=(this[de]&pe)<<fe,q[de-Q]=this[de]>>ne;ne>0&&(q[this.t-Q-1]|=(this.s&pe)<<fe),q.t=this.t-Q,q.clamp()}function J(M,q){for(var Q=0,ne=0,fe=Math.min(M.t,this.t);Q<fe;)ne+=this[Q]-M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;if(M.t<this.t){for(ne-=M.s;Q<this.t;)ne+=this[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne+=this.s}else{for(ne+=this.s;Q<M.t;)ne-=M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne-=M.s}q.s=ne<0?-1:0,ne<-1?q[Q++]=this.DV+ne:ne>0&&(q[Q++]=ne),q.t=Q,q.clamp()}function $(M,q){var Q=this.abs(),ne=M.abs(),fe=Q.t;for(q.t=fe+ne.t;--fe>=0;)q[fe]=0;for(fe=0;fe<ne.t;++fe)q[fe+Q.t]=Q.am(0,ne[fe],q,fe,0,Q.t);q.s=0,q.clamp(),this.s!=M.s&&a.ZERO.subTo(q,q)}function U(M){for(var q=this.abs(),Q=M.t=2*q.t;--Q>=0;)M[Q]=0;for(Q=0;Q<q.t-1;++Q){var ne=q.am(Q,q[Q],M,2*Q,0,1);(M[Q+q.t]+=q.am(Q+1,2*q[Q],M,2*Q+1,ne,q.t-Q-1))>=q.DV&&(M[Q+q.t]-=q.DV,M[Q+q.t+1]=1)}M.t>0&&(M[M.t-1]+=q.am(Q,q[Q],M,2*Q,0,1)),M.s=0,M.clamp()}function K(M,q,Q){var ne=M.abs();if(!(ne.t<=0)){var fe=this.abs();if(fe.t<ne.t){q!=null&&q.fromInt(0),Q!=null&&this.copyTo(Q);return}Q==null&&(Q=o());var pe=o(),de=this.s,ve=M.s,Fe=this.DB-E(ne[ne.t-1]);Fe>0?(ne.lShiftTo(Fe,pe),fe.lShiftTo(Fe,Q)):(ne.copyTo(pe),fe.copyTo(Q));var Ue=pe.t,it=pe[Ue-1];if(it!=0){var tt=it*(1<<this.F1)+(Ue>1?pe[Ue-2]>>this.F2:0),Et=this.FV/tt,un=(1<<this.F1)/tt,ut=1<<this.F2,ct=Q.t,cn=ct-Ue,Ft=q==null?o():q;for(pe.dlShiftTo(cn,Ft),Q.compareTo(Ft)>=0&&(Q[Q.t++]=1,Q.subTo(Ft,Q)),a.ONE.dlShiftTo(Ue,Ft),Ft.subTo(pe,pe);pe.t<Ue;)pe[pe.t++]=0;for(;--cn>=0;){var mi=Q[--ct]==it?this.DM:Math.floor(Q[ct]*Et+(Q[ct-1]+ut)*un);if((Q[ct]+=pe.am(0,mi,Q,cn,0,Ue))<mi)for(pe.dlShiftTo(cn,Ft),Q.subTo(Ft,Q);Q[ct]<--mi;)Q.subTo(Ft,Q)}q!=null&&(Q.drShiftTo(Ue,q),de!=ve&&a.ZERO.subTo(q,q)),Q.t=Ue,Q.clamp(),Fe>0&&Q.rShiftTo(Fe,Q),de<0&&a.ZERO.subTo(Q,Q)}}}function L(M){var q=o();return this.abs().divRemTo(M,null,q),this.s<0&&q.compareTo(a.ZERO)>0&&M.subTo(q,q),q}function O(M){this.m=M}function H(M){return M.s<0||M.compareTo(this.m)>=0?M.mod(this.m):M}function W(M){return M}function Z(M){M.divRemTo(this.m,null,M)}function re(M,q,Q){M.multiplyTo(q,Q),this.reduce(Q)}function oe(M,q){M.squareTo(q),this.reduce(q)}O.prototype.convert=H,O.prototype.revert=W,O.prototype.reduce=Z,O.prototype.mulTo=re,O.prototype.sqrTo=oe;function ae(){if(this.t<1)return 0;var M=this[0];if(!(M&1))return 0;var q=M&3;return q=q*(2-(M&15)*q)&15,q=q*(2-(M&255)*q)&255,q=q*(2-((M&65535)*q&65535))&65535,q=q*(2-M*q%this.DV)%this.DV,q>0?this.DV-q:-q}function b(M){this.m=M,this.mp=M.invDigit(),this.mpl=this.mp&32767,this.mph=this.mp>>15,this.um=(1<<M.DB-15)-1,this.mt2=2*M.t}function _(M){var q=o();return M.abs().dlShiftTo(this.m.t,q),q.divRemTo(this.m,null,q),M.s<0&&q.compareTo(a.ZERO)>0&&this.m.subTo(q,q),q}function R(M){var q=o();return M.copyTo(q),this.reduce(q),q}function G(M){for(;M.t<=this.mt2;)M[M.t++]=0;for(var q=0;q<this.m.t;++q){var Q=M[q]&32767,ne=Q*this.mpl+((Q*this.mph+(M[q]>>15)*this.mpl&this.um)<<15)&M.DM;for(Q=q+this.m.t,M[Q]+=this.m.am(0,ne,M,q,0,this.m.t);M[Q]>=M.DV;)M[Q]-=M.DV,M[++Q]++}M.clamp(),M.drShiftTo(this.m.t,M),M.compareTo(this.m)>=0&&M.subTo(this.m,M)}function ee(M,q){M.squareTo(q),this.reduce(q)}function te(M,q,Q){M.multiplyTo(q,Q),this.reduce(Q)}b.prototype.convert=_,b.prototype.revert=R,b.prototype.reduce=G,b.prototype.mulTo=te,b.prototype.sqrTo=ee;function se(){return(this.t>0?this[0]&1:this.s)==0}function z(M,q){if(M>4294967295||M<1)return a.ONE;var Q=o(),ne=o(),fe=q.convert(this),pe=E(M)-1;for(fe.copyTo(Q);--pe>=0;)if(q.sqrTo(Q,ne),(M&1<<pe)>0)q.mulTo(ne,fe,Q);else{var de=Q;Q=ne,ne=de}return q.revert(Q)}function S(M,q){var Q;return M<256||q.isEven()?Q=new O(q):Q=new b(q),this.exp(M,Q)}a.prototype.copyTo=x,a.prototype.fromInt=y,a.prototype.fromString=k,a.prototype.clamp=T,a.prototype.dlShiftTo=C,a.prototype.drShiftTo=F,a.prototype.lShiftTo=j,a.prototype.rShiftTo=P,a.prototype.subTo=J,a.prototype.multiplyTo=$,a.prototype.squareTo=U,a.prototype.divRemTo=K,a.prototype.invDigit=ae,a.prototype.isEven=se,a.prototype.exp=z,a.prototype.toString=I,a.prototype.negate=D,a.prototype.abs=X,a.prototype.compareTo=V,a.prototype.bitLength=A,a.prototype.mod=L,a.prototype.modPowInt=S,a.ZERO=w(0),a.ONE=w(1);function B(){var M=o();return this.copyTo(M),M}function Y(){if(this.s<0){if(this.t==1)return this[0]-this.DV;if(this.t==0)return-1}else{if(this.t==1)return this[0];if(this.t==0)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]}function ie(){return this.t==0?this.s:this[0]<<24>>24}function ue(){return this.t==0?this.s:this[0]<<16>>16}function ce(M){return Math.floor(Math.LN2*this.DB/Math.log(M))}function me(){return this.s<0?-1:this.t<=0||this.t==1&&this[0]<=0?0:1}function ge(M){if(M==null&&(M=10),this.signum()==0||M<2||M>36)return"0";var q=this.chunkSize(M),Q=Math.pow(M,q),ne=w(Q),fe=o(),pe=o(),de="";for(this.divRemTo(ne,fe,pe);fe.signum()>0;)de=(Q+pe.intValue()).toString(M).substr(1)+de,fe.divRemTo(ne,fe,pe);return pe.intValue().toString(M)+de}function Ce(M,q){this.fromInt(0),q==null&&(q=10);for(var Q=this.chunkSize(q),ne=Math.pow(q,Q),fe=!1,pe=0,de=0,ve=0;ve<M.length;++ve){var Fe=g(M,ve);if(Fe<0){M.charAt(ve)=="-"&&this.signum()==0&&(fe=!0);continue}de=q*de+Fe,++pe>=Q&&(this.dMultiply(ne),this.dAddOffset(de,0),pe=0,de=0)}pe>0&&(this.dMultiply(Math.pow(q,pe)),this.dAddOffset(de,0)),fe&&a.ZERO.subTo(this,this)}function Te(M,q,Q){if(typeof q=="number")if(M<2)this.fromInt(1);else for(this.fromNumber(M,Q),this.testBit(M-1)||this.bitwiseTo(a.ONE.shiftLeft(M-1),or,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(q);)this.dAddOffset(2,0),this.bitLength()>M&&this.subTo(a.ONE.shiftLeft(M-1),this);else{var ne=new Array,fe=M&7;ne.length=(M>>3)+1,q.nextBytes(ne),fe>0?ne[0]&=(1<<fe)-1:ne[0]=0,this.fromString(ne,256)}}function Be(){var M=this.t,q=new Array;q[0]=this.s;var Q=this.DB-M*this.DB%8,ne,fe=0;if(M-- >0)for(Q<this.DB&&(ne=this[M]>>Q)!=(this.s&this.DM)>>Q&&(q[fe++]=ne|this.s<<this.DB-Q);M>=0;)Q<8?(ne=(this[M]&(1<<Q)-1)<<8-Q,ne|=this[--M]>>(Q+=this.DB-8)):(ne=this[M]>>(Q-=8)&255,Q<=0&&(Q+=this.DB,--M)),ne&128&&(ne|=-256),fe==0&&(this.s&128)!=(ne&128)&&++fe,(fe>0||ne!=this.s)&&(q[fe++]=ne);return q}function kt(M){return this.compareTo(M)==0}function Lt(M){return this.compareTo(M)<0?this:M}function Ut(M){return this.compareTo(M)>0?this:M}function Tt(M,q,Q){var ne,fe,pe=Math.min(M.t,this.t);for(ne=0;ne<pe;++ne)Q[ne]=q(this[ne],M[ne]);if(M.t<this.t){for(fe=M.s&this.DM,ne=pe;ne<this.t;++ne)Q[ne]=q(this[ne],fe);Q.t=this.t}else{for(fe=this.s&this.DM,ne=pe;ne<M.t;++ne)Q[ne]=q(fe,M[ne]);Q.t=M.t}Q.s=q(this.s,M.s),Q.clamp()}function qt(M,q){return M&q}function ri(M){var q=o();return this.bitwiseTo(M,qt,q),q}function or(M,q){return M|q}function Jr(M){var q=o();return this.bitwiseTo(M,or,q),q}function en(M,q){return M^q}function ni(M){var q=o();return this.bitwiseTo(M,en,q),q}function kr(M,q){return M&~q}function ii(M){var q=o();return this.bitwiseTo(M,kr,q),q}function tn(){for(var M=o(),q=0;q<this.t;++q)M[q]=this.DM&~this[q];return M.t=this.t,M.s=~this.s,M}function oi(M){var q=o();return M<0?this.rShiftTo(-M,q):this.lShiftTo(M,q),q}function rn(M){var q=o();return M<0?this.lShiftTo(-M,q):this.rShiftTo(M,q),q}function ai(M){if(M==0)return-1;var q=0;return M&65535||(M>>=16,q+=16),M&255||(M>>=8,q+=8),M&15||(M>>=4,q+=4),M&3||(M>>=2,q+=2),M&1||++q,q}function si(){for(var M=0;M<this.t;++M)if(this[M]!=0)return M*this.DB+ai(this[M]);return this.s<0?this.t*this.DB:-1}function li(M){for(var q=0;M!=0;)M&=M-1,++q;return q}function nn(){for(var M=0,q=this.s&this.DM,Q=0;Q<this.t;++Q)M+=li(this[Q]^q);return M}function ui(M){var q=Math.floor(M/this.DB);return q>=this.t?this.s!=0:(this[q]&1<<M%this.DB)!=0}function ci(M,q){var Q=a.ONE.shiftLeft(M);return this.bitwiseTo(Q,q,Q),Q}function on(M){return this.changeBit(M,or)}function fi(M){return this.changeBit(M,kr)}function an(M){return this.changeBit(M,en)}function Ge(M,q){for(var Q=0,ne=0,fe=Math.min(M.t,this.t);Q<fe;)ne+=this[Q]+M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;if(M.t<this.t){for(ne+=M.s;Q<this.t;)ne+=this[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne+=this.s}else{for(ne+=this.s;Q<M.t;)ne+=M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne+=M.s}q.s=ne<0?-1:0,ne>0?q[Q++]=ne:ne<-1&&(q[Q++]=this.DV+ne),q.t=Q,q.clamp()}function dt(M){var q=o();return this.addTo(M,q),q}function sn(M){var q=o();return this.subTo(M,q),q}function hi(M){var q=o();return this.multiplyTo(M,q),q}function G0(){var M=o();return this.squareTo(M),M}function Q0(M){var q=o();return this.divRemTo(M,q,null),q}function Y0(M){var q=o();return this.divRemTo(M,null,q),q}function X0(M){var q=o(),Q=o();return this.divRemTo(M,q,Q),new Array(q,Q)}function Z0(M){this[this.t]=this.am(0,M-1,this,0,0,this.t),++this.t,this.clamp()}function J0(M,q){if(M!=0){for(;this.t<=q;)this[this.t++]=0;for(this[q]+=M;this[q]>=this.DV;)this[q]-=this.DV,++q>=this.t&&(this[this.t++]=0),++this[q]}}function Tr(){}function wa(M){return M}function ec(M,q,Q){M.multiplyTo(q,Q)}function tc(M,q){M.squareTo(q)}Tr.prototype.convert=wa,Tr.prototype.revert=wa,Tr.prototype.mulTo=ec,Tr.prototype.sqrTo=tc;function rc(M){return this.exp(M,new Tr)}function nc(M,q,Q){var ne=Math.min(this.t+M.t,q);for(Q.s=0,Q.t=ne;ne>0;)Q[--ne]=0;var fe;for(fe=Q.t-this.t;ne<fe;++ne)Q[ne+this.t]=this.am(0,M[ne],Q,ne,0,this.t);for(fe=Math.min(M.t,q);ne<fe;++ne)this.am(0,M[ne],Q,ne,0,q-ne);Q.clamp()}function ic(M,q,Q){--q;var ne=Q.t=this.t+M.t-q;for(Q.s=0;--ne>=0;)Q[ne]=0;for(ne=Math.max(q-this.t,0);ne<M.t;++ne)Q[this.t+ne-q]=this.am(q-ne,M[ne],Q,0,0,this.t+ne-q);Q.clamp(),Q.drShiftTo(1,Q)}function __$t__(M){this.r2=o(),this.q3=o(),a.ONE.dlShiftTo(2*M.t,this.r2),this.mu=this.r2.divide(M),this.m=M}function oc(M){if(M.s<0||M.t>2*this.m.t)return M.mod(this.m);if(M.compareTo(this.m)<0)return M;var q=o();return M.copyTo(q),this.reduce(q),q}function ac(M){return M}function sc(M){for(M.drShiftTo(this.m.t-1,this.r2),M.t>this.m.t+1&&(M.t=this.m.t+1,M.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);M.compareTo(this.r2)<0;)M.dAddOffset(1,this.m.t+1);for(M.subTo(this.r2,M);M.compareTo(this.m)>=0;)M.subTo(this.m,M)}function lc(M,q){M.squareTo(q),this.reduce(q)}function uc(M,q,Q){M.multiplyTo(q,Q),this.reduce(Q)}__$t__.prototype.convert=oc,__$t__.prototype.revert=ac,__$t__.prototype.reduce=sc,__$t__.prototype.mulTo=uc,__$t__.prototype.sqrTo=lc;function cc(M,q){var Q=M.bitLength(),ne,fe=w(1),pe;if(Q<=0)return fe;Q<18?ne=1:Q<48?ne=3:Q<144?ne=4:Q<768?ne=5:ne=6,Q<8?pe=new O(q):q.isEven()?pe=new __$t__(q):pe=new b(q);var de=new Array,ve=3,Fe=ne-1,Ue=(1<<ne)-1;if(de[1]=pe.convert(this),ne>1){var it=o();for(pe.sqrTo(de[1],it);ve<=Ue;)de[ve]=o(),pe.mulTo(it,de[ve-2],de[ve]),ve+=2}var tt=M.t-1,Et,un=!0,ut=o(),ct;for(Q=E(M[tt])-1;tt>=0;){for(Q>=Fe?Et=M[tt]>>Q-Fe&Ue:(Et=(M[tt]&(1<<Q+1)-1)<<Fe-Q,tt>0&&(Et|=M[tt-1]>>this.DB+Q-Fe)),ve=ne;!(Et&1);)Et>>=1,--ve;if((Q-=ve)<0&&(Q+=this.DB,--tt),un)de[Et].copyTo(fe),un=!1;else{for(;ve>1;)pe.sqrTo(fe,ut),pe.sqrTo(ut,fe),ve-=2;ve>0?pe.sqrTo(fe,ut):(ct=fe,fe=ut,ut=ct),pe.mulTo(ut,de[Et],fe)}for(;tt>=0&&!(M[tt]&1<<Q);)pe.sqrTo(fe,ut),ct=fe,fe=ut,ut=ct,--Q<0&&(Q=this.DB-1,--tt)}return pe.revert(fe)}function fc(M){var q=this.s<0?this.negate():this.clone(),Q=M.s<0?M.negate():M.clone();if(q.compareTo(Q)<0){var ne=q;q=Q,Q=ne}var fe=q.getLowestSetBit(),pe=Q.getLowestSetBit();if(pe<0)return q;for(fe<pe&&(pe=fe),pe>0&&(q.rShiftTo(pe,q),Q.rShiftTo(pe,Q));q.signum()>0;)(fe=q.getLowestSetBit())>0&&q.rShiftTo(fe,q),(fe=Q.getLowestSetBit())>0&&Q.rShiftTo(fe,Q),q.compareTo(Q)>=0?(q.subTo(Q,q),q.rShiftTo(1,q)):(Q.subTo(q,Q),Q.rShiftTo(1,Q));return pe>0&&Q.lShiftTo(pe,Q),Q}function hc(M){if(M<=0)return 0;var q=this.DV%M,Q=this.s<0?M-1:0;if(this.t>0)if(q==0)Q=this[0]%M;else for(var ne=this.t-1;ne>=0;--ne)Q=(q*Q+this[ne])%M;return Q}function pc(M){var q=M.isEven();if(this.isEven()&&q||M.signum()==0)return a.ZERO;for(var Q=M.clone(),ne=this.clone(),fe=w(1),pe=w(0),de=w(0),ve=w(1);Q.signum()!=0;){for(;Q.isEven();)Q.rShiftTo(1,Q),q?((!fe.isEven()||!pe.isEven())&&(fe.addTo(this,fe),pe.subTo(M,pe)),fe.rShiftTo(1,fe)):pe.isEven()||pe.subTo(M,pe),pe.rShiftTo(1,pe);for(;ne.isEven();)ne.rShiftTo(1,ne),q?((!de.isEven()||!ve.isEven())&&(de.addTo(this,de),ve.subTo(M,ve)),de.rShiftTo(1,de)):ve.isEven()||ve.subTo(M,ve),ve.rShiftTo(1,ve);Q.compareTo(ne)>=0?(Q.subTo(ne,Q),q&&fe.subTo(de,fe),pe.subTo(ve,pe)):(ne.subTo(Q,ne),q&&de.subTo(fe,de),ve.subTo(pe,ve))}if(ne.compareTo(a.ONE)!=0)return a.ZERO;if(ve.compareTo(M)>=0)return ve.subtract(M);if(ve.signum()<0)ve.addTo(M,ve);else return ve;return ve.signum()<0?ve.add(M):ve}var Qe=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],dc=(1<<26)/Qe[Qe.length-1];function mc(M){var q,Q=this.abs();if(Q.t==1&&Q[0]<=Qe[Qe.length-1]){for(q=0;q<Qe.length;++q)if(Q[0]==Qe[q])return!0;return!1}if(Q.isEven())return!1;for(q=1;q<Qe.length;){for(var ne=Qe[q],fe=q+1;fe<Qe.length&&ne<dc;)ne*=Qe[fe++];for(ne=Q.modInt(ne);q<fe;)if(ne%Qe[q++]==0)return!1}return Q.millerRabin(M)}function vc(M){var q=this.subtract(a.ONE),Q=q.getLowestSetBit();if(Q<=0)return!1;var ne=q.shiftRight(Q);M=M+1>>1,M>Qe.length&&(M=Qe.length);for(var fe=o(),pe=0;pe<M;++pe){fe.fromInt(Qe[Math.floor(Math.random()*Qe.length)]);var de=fe.modPow(ne,this);if(de.compareTo(a.ONE)!=0&&de.compareTo(q)!=0){for(var ve=1;ve++<Q&&de.compareTo(q)!=0;)if(de=de.modPowInt(2,this),de.compareTo(a.ONE)==0)return!1;if(de.compareTo(q)!=0)return!1}}return!0}a.prototype.chunkSize=ce,a.prototype.toRadix=ge,a.prototype.fromRadix=Ce,a.prototype.fromNumber=Te,a.prototype.bitwiseTo=Tt,a.prototype.changeBit=ci,a.prototype.addTo=Ge,a.prototype.dMultiply=Z0,a.prototype.dAddOffset=J0,a.prototype.multiplyLowerTo=nc,a.prototype.multiplyUpperTo=ic,a.prototype.modInt=hc,a.prototype.millerRabin=vc,a.prototype.clone=B,a.prototype.intValue=Y,a.prototype.byteValue=ie,a.prototype.shortValue=ue,a.prototype.signum=me,a.prototype.toByteArray=Be,a.prototype.equals=kt,a.prototype.min=Lt,a.prototype.max=Ut,a.prototype.and=ri,a.prototype.or=Jr,a.prototype.xor=ni,a.prototype.andNot=ii,a.prototype.not=tn,a.prototype.shiftLeft=oi,a.prototype.shiftRight=rn,a.prototype.getLowestSetBit=si,a.prototype.bitCount=nn,a.prototype.testBit=ui,a.prototype.setBit=on,a.prototype.clearBit=fi,a.prototype.flipBit=an,a.prototype.add=dt,a.prototype.subtract=sn,a.prototype.multiply=hi,a.prototype.divide=Q0,a.prototype.remainder=Y0,a.prototype.divideAndRemainder=X0,a.prototype.modPow=cc,a.prototype.modInverse=pc,a.prototype.pow=rc,a.prototype.gcd=fc,a.prototype.isProbablePrime=mc,a.prototype.square=G0,a.prototype.Barrett=__$t__;var ln,et,Le;function yc(M){et[Le++]^=M&255,et[Le++]^=M>>8&255,et[Le++]^=M>>16&255,et[Le++]^=M>>24&255,Le>=di&&(Le-=di)}function _a(){yc(new Date().getTime())}if(et==null){et=new Array,Le=0;var lt;if(typeof window!="undefined"&&window.crypto){if(window.crypto.getRandomValues){var Ea=new Uint8Array(32);for(window.crypto.getRandomValues(Ea),lt=0;lt<32;++lt)et[Le++]=Ea[lt]}else if(navigator.appName=="Netscape"&&navigator.appVersion<"5"){var Aa=window.crypto.random(32);for(lt=0;lt<Aa.length;++lt)et[Le++]=Aa.charCodeAt(lt)&255}}for(;Le<di;)lt=Math.floor(65536*Math.random()),et[Le++]=lt>>>8,et[Le++]=lt&255;Le=0,_a()}function gc(){if(ln==null){for(_a(),ln=_c(),ln.init(et),Le=0;Le<et.length;++Le)et[Le]=0;Le=0}return ln.next()}function xc(M){var q;for(q=0;q<M.length;++q)M[q]=gc()}function Ca(){}Ca.prototype.nextBytes=xc;function pi(){this.i=0,this.j=0,this.S=new Array}function bc(M){var q,Q,ne;for(q=0;q<256;++q)this.S[q]=q;for(Q=0,q=0;q<256;++q)Q=Q+this.S[q]+M[q%M.length]&255,ne=this.S[q],this.S[q]=this.S[Q],this.S[Q]=ne;this.i=0,this.j=0}function wc(){var M;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,M=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=M,this.S[M+this.S[this.i]&255]}pi.prototype.init=bc,pi.prototype.next=wc;function _c(){return new pi}var di=256;e.exports={default:a,BigInteger:a,SecureRandom:Ca}}).call(xe)})(n0);var ke=n0.exports,_m=ke.BigInteger.prototype.Barrett;function Ye(e,r){this.x=r,this.q=e}function Xe(e,r,t,n){this.curve=e,this.x=r,this.y=t,this.z=n==null?ke.BigInteger.ONE:n,this.zinv=null}function gt(e,r,t){this.q=e,this.a=this.fromBigInteger(r),this.b=this.fromBigInteger(t),this.infinity=new Xe(this,null,null),this.reducer=new _m(this.q)}Ye.prototype.equals=function(e){return e==this||this.q.equals(e.q)&&this.x.equals(e.x)},Ye.prototype.toBigInteger=function(){return this.x},Ye.prototype.negate=function(){return new Ye(this.q,this.x.negate().mod(this.q))},Ye.prototype.add=function(e){return new Ye(this.q,this.x.add(e.toBigInteger()).mod(this.q))},Ye.prototype.subtract=function(e){return new Ye(this.q,this.x.subtract(e.toBigInteger()).mod(this.q))},Ye.prototype.multiply=function(e){return new Ye(this.q,this.x.multiply(e.toBigInteger()).mod(this.q))},Ye.prototype.square=function(){return new Ye(this.q,this.x.square().mod(this.q))},Ye.prototype.divide=function(e){return new Ye(this.q,this.x.multiply(e.toBigInteger().modInverse(this.q)).mod(this.q))},Xe.prototype.getX=function(){this.zinv==null&&(this.zinv=this.z.modInverse(this.curve.q));var e=this.x.toBigInteger().multiply(this.zinv);return this.curve.reduce(e),this.curve.fromBigInteger(e)},Xe.prototype.getY=function(){this.zinv==null&&(this.zinv=this.z.modInverse(this.curve.q));var e=this.y.toBigInteger().multiply(this.zinv);return this.curve.reduce(e),this.curve.fromBigInteger(e)},Xe.prototype.equals=function(e){return e==this||(this.isInfinity()?e.isInfinity():e.isInfinity()?this.isInfinity():!!e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q).equals(ke.BigInteger.ZERO)&&e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q).equals(ke.BigInteger.ZERO))},Xe.prototype.isInfinity=function(){return this.x==null&&this.y==null||this.z.equals(ke.BigInteger.ZERO)&&!this.y.toBigInteger().equals(ke.BigInteger.ZERO)},Xe.prototype.negate=function(){return new Xe(this.curve,this.x,this.y.negate(),this.z)},Xe.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var r=e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q),t=e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q);if(ke.BigInteger.ZERO.equals(t))return ke.BigInteger.ZERO.equals(r)?this.twice():this.curve.getInfinity();var n=new ke.BigInteger("3"),l=this.x.toBigInteger(),a=this.y.toBigInteger(),o=(e.x.toBigInteger(),e.y.toBigInteger(),t.square()),u=o.multiply(t),p=l.multiply(o),s=r.square().multiply(this.z),i=s.subtract(p.shiftLeft(1)).multiply(e.z).subtract(u).multiply(t).mod(this.curve.q),d=p.multiply(n).multiply(r).subtract(a.multiply(u)).subtract(s.multiply(r)).multiply(e.z).add(r.multiply(u)).mod(this.curve.q),c=u.multiply(this.z).multiply(e.z).mod(this.curve.q);return new Xe(this.curve,this.curve.fromBigInteger(i),this.curve.fromBigInteger(d),c)},Xe.prototype.twice=function(){if(this.isInfinity())return this;if(this.y.toBigInteger().signum()==0)return this.curve.getInfinity();var e=new ke.BigInteger("3"),r=this.x.toBigInteger(),t=this.y.toBigInteger(),n=t.multiply(this.z),l=n.multiply(t).mod(this.curve.q),a=this.curve.a.toBigInteger(),o=r.square().multiply(e);ke.BigInteger.ZERO.equals(a)||(o=o.add(this.z.square().multiply(a)));var u=(o=o.mod(this.curve.q)).square().subtract(r.shiftLeft(3).multiply(l)).shiftLeft(1).multiply(n).mod(this.curve.q),p=o.multiply(e).multiply(r).subtract(l.shiftLeft(1)).shiftLeft(2).multiply(l).subtract(o.square().multiply(o)).mod(this.curve.q),s=n.square().multiply(n).shiftLeft(3).mod(this.curve.q);return new Xe(this.curve,this.curve.fromBigInteger(u),this.curve.fromBigInteger(p),s)},Xe.prototype.multiply=function(e){if(this.isInfinity())return this;if(e.signum()==0)return this.curve.getInfinity();var r,t=e,n=t.multiply(new ke.BigInteger("3")),l=this.negate(),a=this;for(r=n.bitLength()-2;r>0;--r){a=a.twice();var o=n.testBit(r);o!=t.testBit(r)&&(a=a.add(o?this:l))}return a},Xe.prototype.multiplyTwo=function(e,r,t){var n;n=e.bitLength()>t.bitLength()?e.bitLength()-1:t.bitLength()-1;for(var l=this.curve.getInfinity(),a=this.add(r);n>=0;)l=l.twice(),e.testBit(n)?l=t.testBit(n)?l.add(a):l.add(this):t.testBit(n)&&(l=l.add(r)),--n;return l},gt.prototype.getQ=function(){return this.q},gt.prototype.getA=function(){return this.a},gt.prototype.getB=function(){return this.b},gt.prototype.equals=function(e){return e==this||this.q.equals(e.q)&&this.a.equals(e.a)&&this.b.equals(e.b)},gt.prototype.getInfinity=function(){return this.infinity},gt.prototype.fromBigInteger=function(e){return new Ye(this.q,e)},gt.prototype.reduce=function(e){this.reducer.reduce(e)},gt.prototype.decodePointHex=function(e){switch(parseInt(e.substr(0,2),16)){case 0:return this.infinity;case 2:case 3:return null;case 4:case 6:case 7:var r=(e.length-2)/2,t=e.substr(2,r),n=e.substr(r+2,r);return new Xe(this,this.fromBigInteger(new ke.BigInteger(t,16)),this.fromBigInteger(new ke.BigInteger(n,16)));default:return null}},gt.prototype.encodePointHex=function(e){if(e.isInfinity())return"00";var r=e.getX().toBigInteger().toString(16),t=e.getY().toBigInteger().toString(16),n=this.getQ().toString(16).length;for(n%2!=0&&n++;r.length<n;)r="0"+r;for(;t.length<n;)t="0"+t;return"04"+r+t};var qe=function(e,r){return e<<(r%=32)|e>>>32-r},yt=function(e,r){var t=r-e.length;return(t>0?"0".repeat(t):"")+e},Em=function(e){return e<16?2043430169:2055708042},Am=function(e,r,t,n){return n<16?e^r^t:e&r|e&t|r&t},Cm=function(e,r,t,n){return n<16?e^r^t:e&r|~e&t},Sm=function(e,r,t){for(var n,l,a,o,u,p=function(x){var y,w=new Array(132);x.forEach(function(I,D){w[D]=I});for(var k=16;k<68;k++)w[k]=(y=w[k-16]^w[k-9]^qe(w[k-3],15))^qe(y,15)^qe(y,23)^qe(w[k-13],7)^w[k-6];for(var T=0;T<64;T++)w[T+68]=w[T]^w[T+4];return w}(r),s=e[0],i=e[1],d=e[2],c=e[3],f=e[4],h=e[5],v=e[6],m=e[7],g=0;g<64;g++)l=(n=qe(qe(s,12)+f+qe(Em(g),g),7))^qe(s,12),a=Am(s,i,d,g)+c+l+p[g+68],o=Cm(f,h,v,g)+m+n+p[g],c=d,d=qe(i,9),i=s,s=a,m=v,v=qe(h,19),h=f,f=(u=o)^qe(u,9)^qe(u,17);return[s^e[0],i^e[1],d^e[2],c^e[3],f^e[4],h^e[5],v^e[6],m^e[7]]},Vo=function(e,r,t){if(typeof e=="string"?e=we.Buffer.from(e,r||"utf8"):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');var n,l,a,o,u,p;n=e,l=we.Buffer.alloc(1,128),o=we.Buffer.alloc(a=(a=n.length%64)>=56?64-a%56-1:56-a-1,0),u=we.Buffer.alloc(8),p=8*n.length,u.writeUInt32BE(Math.floor(p/Math.pow(2,32)),0),u.writeUInt32BE(p%Math.pow(2,32),4);for(var s=(e=we.Buffer.concat([n,l,o,u],n.length+1+a+8)).length/64,i=new Array(s),d=0;d<s;d++){i[d]=new Array(16);for(var c=0;c<16;c++)i[d][c]=e.readUInt32BE(64*d+4*c)}var f=new Array(s);f[0]=[1937774191,1226093241,388252375,3666478592,2842636476,372324522,3817729613,2969243214];for(var h=0;h<s;h++)f[h+1]=Sm(f[h],i[h]);var v=we.Buffer.alloc(32);return f[s].forEach(function(m,g){return v.writeInt32BE(m,4*g)}),t?v.toString(t):$r(v)},ll=new ke.SecureRandom,da=function(){var e=new gt(new ke.BigInteger("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFF",16),new ke.BigInteger("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFC",16),new ke.BigInteger("28E9FA9E9D9F5E344D5A9E4BCF6509A7F39789F515AB8F92DDBCBD414D940E93",16)),r=e.decodePointHex("0432C4AE2C1F1981195F9904466A39C9948FE30BBFF2660BE1715A4589334C74C7BC3736A2F4F6779C59BDCEE36B692153D0A9877CC62A474002DF32E52139F0A0");return{curve:e,G:r,n:new ke.BigInteger("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFF7203DF6B21C6052B53BBF40939D54123",16)}}(),ul=da.curve,cl=da.G,vn=da.n;function fl(e,r){for(var t=[],n=Math.ceil(r/32),l=r%32,a=1;a<=n;a++){var o=we.Buffer.allocUnsafe(4);o.writeUInt32BE(a);var u=Vo(we.Buffer.concat([e,o]));t.push(a===n&&l?we.Buffer.from(u).slice(0,l):we.Buffer.from(u))}return we.Buffer.concat(t,r)}var Bm={__proto__:null,constants:{C1C2C3:0,C1C3C2:1,PC:"04"},generateKeyPair:function(){var e=new ke.BigInteger(vn.bitLength(),ll).mod(vn.subtract(new ke.BigInteger("2"))).add(ke.BigInteger.ONE),r=yt(e.toString(16),64),t=cl.multiply(e);return{privateKey:r,publicKey:"04"+yt(t.getX().toBigInteger().toString(16),64)+yt(t.getY().toBigInteger().toString(16),64)}},encrypt:function(e,r,t){var n=t||{},l=n.mode,a=l===void 0?1:l,o=n.outputEncoding,u=n.pc;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding||"utf8"):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');var p=new ke.BigInteger(vn.bitLength(),ll).mod(vn.subtract(ke.BigInteger.ONE)).add(ke.BigInteger.ONE),s=cl.multiply(p),i=yt(s.getX().toBigInteger().toString(16),64)+yt(s.getY().toBigInteger().toString(16),64),d=ul.decodePointHex(r).multiply(p),c=yt(d.getX().toBigInteger().toString(16),64),f=yt(d.getY().toBigInteger().toString(16),64),h=fl(we.Buffer.from(c+f,"hex"),e.length),v=yt(new ke.BigInteger(e.toString("hex"),16).xor(new ke.BigInteger(h.toString("hex"),16)).toString(16),2*e.length),m=Vo(c+e.toString("hex")+f,"hex","hex"),g=we.Buffer.from((u?"04":"")+(a===0?i+v+m:i+m+v),"hex");return o?g.toString(o):$r(g)},decrypt:function(e,r,t){var n=t||{},l=n.mode,a=l===void 0?1:l,o=n.outputEncoding,u=n.pc;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');var p=(e=u?e.slice(1):e).slice(0,32).toString("hex"),s=e.slice(32,64).toString("hex"),i=ul.decodePointHex("04"+p+s).multiply(new ke.BigInteger(r,16)),d=yt(i.getX().toBigInteger().toString(16),64),c=yt(i.getY().toBigInteger().toString(16),64),f=e.slice(64,96),h=e.slice(96);a===0&&(f=e.slice(e.length-32),h=e.slice(64,e.length-32));var v=fl(we.Buffer.from(d+c,"hex"),h.length),m=new ke.BigInteger(h.toString("hex"),16).xor(new ke.BigInteger(v.toString("hex"),16)).toString(16),g=Vo(d+m+c,"hex","hex")===f.toString("hex")?we.Buffer.from(m,"hex"):we.Buffer.alloc(0);return o?g.toString(o):$r(g)}},yn=[[214,144,233,254,204,225,61,183,22,182,20,194,40,251,44,5],[43,103,154,118,42,190,4,195,170,68,19,38,73,134,6,153],[156,66,80,244,145,239,152,122,51,84,11,67,237,207,172,98],[228,179,28,169,201,8,232,149,128,223,148,250,117,143,63,166],[71,7,167,252,243,115,23,186,131,89,60,25,230,133,79,168],[104,107,129,178,113,100,218,139,248,235,15,75,112,86,157,53],[30,36,14,94,99,88,209,162,37,34,124,59,1,33,120,135],[212,0,70,87,159,211,39,82,76,54,2,231,160,196,200,158],[234,191,138,210,64,199,56,181,163,247,242,206,249,97,21,161],[224,174,93,164,155,52,26,85,173,147,50,48,245,140,177,227],[29,246,226,46,130,102,202,96,192,41,35,171,13,83,78,111],[213,219,55,69,222,253,142,47,3,255,106,114,109,108,91,81],[141,27,175,146,187,221,188,127,17,217,92,65,31,16,90,216],[10,193,49,136,165,205,123,189,45,116,208,18,184,229,180,176],[137,105,151,74,12,150,119,126,101,185,241,9,197,110,198,132],[24,240,125,236,58,220,77,32,121,238,95,62,215,203,57,72]],gn=[2746333894,1453994832,1736282519,2993693404],km=[462357,472066609,943670861,1415275113,1886879365,2358483617,2830087869,3301692121,3773296373,4228057617,404694573,876298825,1347903077,1819507329,2291111581,2762715833,3234320085,3705924337,4177462797,337322537,808926789,1280531041,1752135293,2223739545,2695343797,3166948049,3638552301,4110090761,269950501,741554753,1213159005,1684763257],xn=/^[0-9a-f]{32}$/i,i0=function(e){return yn[(4026531840&e)>>>28][(251658240&e)>>>24]<<24|yn[(15728640&e)>>>20][(983040&e)>>>16]<<16|yn[(61440&e)>>>12][(3840&e)>>>8]<<8|yn[(240&e)>>>4][(15&e)>>>0]<<0},o0=function(e){return(r=i0(e))^qe(r,2)^qe(r,10)^qe(r,18)^qe(r,24);var r},a0=function(e){var r,t=new Array(36);t[0]=e[0]^gn[0],t[1]=e[1]^gn[1],t[2]=e[2]^gn[2],t[3]=e[3]^gn[3];for(var n=new Array(32),l=0;l<32;l++)t[l+4]=t[l]^(r=i0(t[l+1]^t[l+2]^t[l+3]^km[l]))^qe(r,13)^qe(r,23),n[l]=t[l+4];return n},hl=function(e,r){for(var t=a0(r),n=0;n<32;n++)e[n+4]=e[n]^o0(e[n+1]^e[n+2]^e[n+3]^t[n]);return[e[35],e[34],e[33],e[32]]},pl=function(e,r){for(var t=a0(r).reverse(),n=0;n<32;n++)e[n+4]=e[n]^o0(e[n+1]^e[n+2]^e[n+3]^t[n]);return[e[35],e[34],e[33],e[32]]},bn=function(e){return[e.readInt32BE(0),e.readInt32BE(4),e.readInt32BE(8),e.readInt32BE(12)]},wn=function(e){for(var r=we.Buffer.alloc(16),t=0;t<4;t++)r.writeInt32BE(e[t],4*t);return r},wr={__proto__:null,constants:{ECB:1,CBC:2},encrypt:function(e,r,t){var n=t||{},l=n.mode,a=n.iv,o=n.outputEncoding;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding||"utf8"):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');if(!xn.test(r))throw new TypeError("Invalid value of cipher `key`");if(r=we.Buffer.from(r,"hex"),l===2&&!xn.test(a))throw new TypeError("Invalid value of `iv` option");return function(u,p,s,i){s&&(s=bn(s)),p=bn(p);for(var d=[],c=(u=function(k){var T=16-k.length%16,I=we.Buffer.alloc(T,T);return we.Buffer.concat([k,I],k.length+T)}(u)).length/16,f=0;f<c;f++)if(s){var h=16*f,v=[s[0]^u.readInt32BE(h),s[1]^u.readInt32BE(h+4),s[2]^u.readInt32BE(h+8),s[3]^u.readInt32BE(h+12)],m=hl(v,p);d.push(wn(m)),s=m.slice(0)}else{var g=16*f,x=[u.readInt32BE(g),u.readInt32BE(g+4),u.readInt32BE(g+8),u.readInt32BE(g+12)],y=hl(x,p);d.push(wn(y))}var w=we.Buffer.concat(d,u.length);return i?w.toString(i):$r(w)}(e,r,a=l===2?we.Buffer.from(a,"hex"):null,o)},decrypt:function(e,r,t){var n=t||{},l=n.mode,a=n.iv,o=n.outputEncoding;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');if(!xn.test(r))throw new TypeError("Invalid value of cipher `key`");if(r=we.Buffer.from(r,"hex"),l===2&&!xn.test(a))throw new TypeError("Invalid value of `iv` option");return function(u,p,s,i){s&&(s=bn(s)),p=bn(p);var d=[],c=u.length/16;if(s)for(var f=c-1;f>=0;f--){var h,v=16*f;h=f>0?[u.readInt32BE(v-16),u.readInt32BE(v-16+4),u.readInt32BE(v-16+8),u.readInt32BE(v-16+12)]:s;var m=[u.readInt32BE(v),u.readInt32BE(v+4),u.readInt32BE(v+8),u.readInt32BE(v+12)],g=pl(m,p);d.unshift(wn([g[0]^h[0],g[1]^h[1],g[2]^h[2],g[3]^h[3]]))}else for(var x=0;x<c;x++){var y=16*x,w=[u.readInt32BE(y),u.readInt32BE(y+4),u.readInt32BE(y+8),u.readInt32BE(y+12)],k=pl(w,p);d.push(wn(k))}var T=we.Buffer.concat(d,u.length-d[d.length-1][15]);return i?T.toString(i):$r(T)}(e,r,a=l===2?we.Buffer.from(a,"hex"):null,o)}};(function(){if(typeof Object.id=="undefined"){var e=0;Object.id=function(r){return typeof r.__uniqueid=="undefined"&&Object.defineProperty(r,"__uniqueid",{value:++e,enumerable:!1,writable:!1}),r.__uniqueid}}})();function Tm(){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r=[-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,62,-1,-1,-1,63,52,53,54,55,56,57,58,59,60,61,-1,-1,-1,-1,-1,-1,-1,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1,-1,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,-1,-1,-1,-1,-1];this.encode=function(t){var n,l,a,o,u,p;for(a=t.length,l=0,n="";l<a;){if(o=t.charCodeAt(l++)&255,l==a){n+=e.charAt(o>>2),n+=e.charAt((o&3)<<4),n+="==";break}if(u=t.charCodeAt(l++),l==a){n+=e.charAt(o>>2),n+=e.charAt((o&3)<<4|(u&240)>>4),n+=e.charAt((u&15)<<2),n+="=";break}p=t.charCodeAt(l++),n+=e.charAt(o>>2),n+=e.charAt((o&3)<<4|(u&240)>>4),n+=e.charAt((u&15)<<2|(p&192)>>6),n+=e.charAt(p&63)}return n},this.decode=function(t){var n,l,a,o,u,p,s;for(p=t.length,u=0,s="";u<p;){do n=r[t.charCodeAt(u++)&255];while(u<p&&n==-1);if(n==-1)break;do l=r[t.charCodeAt(u++)&255];while(u<p&&l==-1);if(l==-1)break;s+=String.fromCharCode(n<<2|(l&48)>>4);do{if(a=t.charCodeAt(u++)&255,a==61)return s;a=r[a]}while(u<p&&a==-1);if(a==-1)break;s+=String.fromCharCode((l&15)<<4|(a&60)>>2);do{if(o=t.charCodeAt(u++)&255,o==61)return s;o=r[o]}while(u<p&&o==-1);if(o==-1)break;s+=String.fromCharCode((a&3)<<6|o)}return s},this.utf16to8=function(t){var n,l,a,o;for(n="",a=t.length,l=0;l<a;l++)o=t.charCodeAt(l),o>=1&&o<=127?n+=t.charAt(l):o>2047?(n+=String.fromCharCode(224|o>>12&15),n+=String.fromCharCode(128|o>>6&63),n+=String.fromCharCode(128|o>>0&63)):(n+=String.fromCharCode(192|o>>6&31),n+=String.fromCharCode(128|o>>0&63));return n},this.utf8to16=function(t){var n,l,a,o,u,p;for(n="",a=t.length,l=0;l<a;)switch(o=t.charCodeAt(l++),o>>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:n+=t.charAt(l-1);break;case 12:case 13:u=t.charCodeAt(l++),n+=String.fromCharCode((o&31)<<6|u&63);break;case 14:u=t.charCodeAt(l++),p=t.charCodeAt(l++),n+=String.fromCharCode((o&15)<<12|(u&63)<<6|(p&63)<<0);break}return n},this.charToHex=function(t){var n,l,a;for(n="",l=0;l<t.length;)a=t.charCodeAt(l++).toString(16),n+="\\0x"+a,n+=l>0&&l%8==0?`\r
32
- `:", ";return n}}function Fm(){var e=0,r=new Object;this.add=function(t,n){this.containsKey(t)||e++,r[t]=n},this.getValue=function(t){return this.containsKey(t)?r[t]:null},this.remove=function(t){this.containsKey(t)&&delete r[t]&&e--},this.containsKey=function(t){return t in r},this.containsValue=function(t){for(var n in r)if(r[n]==t)return!0;return!1},this.getValues=function(){var t=[];for(var n in r)t.push(r[n]);return t},this.getKeys=function(){var t=[];for(var n in r)t.push(n);return t},this.getSize=function(){return e},this.clear=function(){e=0,r=new Object}}function Im(e){if(this.connect=!1,this.ready_func_=null,this.callbacks_=new Fm,this.module_="JS_IActiveXCtrl","WebSocket"in window)this.ws=new WebSocket("ws://127.0.0.1:7321");else throw"WebSocket not supported";this.ws.onerror=function(){throw"Unable to establish connection to WebSocket"},this.loadModule=function(){this.connect=!0;var r=JSON.stringify({MsgId:"LoadModule",Module:this.module_});this.ws.onmessage=this._callback.bind(this),this.ws.send(r)},this.loadModuleCallBack=function(r){if(!r)throw r.Response;this.ready_func_&&this.ready_func_()}.bind(this),this.callbacks_.add("LoadModule",this.loadModuleCallBack),this.exec=function(r,t,n){var l=Object.id(n).toString();this.callbacks_.add(l,n);var a={MsgId:l,Method:r+"|"+e};t&&(a.Param=JSON.stringify(t));var o=JSON.stringify(a);this.connect&&this.ws.send(o)},this.ready=function(r){this.ready_func_=r},this._callback=function(r){var t=JSON.parse(r.data),n=t.MsgId;if(this.callbacks_.containsKey(n)){var l=this.callbacks_.getValue(n);l(t.Result,t.Response),this.callbacks_.remove(n)}},this.ws.onopen=this.loadModule.bind(this),this.Arm_GetDongleInfo=function({Index:r,DongleInfoNum:t},n){this.exec("Arm_GetDongleInfo",[parseInt(r),parseInt(t)],n)},this.Arm_Enum=function(r){this.exec("Arm_Enum",null,r)},this.Arm_Open=function({Index:r},t){this.exec("Arm_Open",[parseInt(r)],t)},this.Arm_Close=function({Handle:r},t){this.exec("Arm_Close",[parseInt(r)],t)},this.Arm_VerifyPIN=function({Handle:r,UserPin:t,UserType:n},l){this.exec("Arm_VerifyPIN",[parseInt(r),n,t],l)},this.Arm_ResetState=function({Handle:r},t){this.exec("Arm_ResetState",[parseInt(r)],t)},this.Arm_GenRandom=function({Handle:r,RandomLen:t},n){this.exec("Arm_GenRandom",[parseInt(r),parseInt(t)],n)},this.Arm_LEDControl=function({Handle:r,LedFlag:t},n){this.exec("Arm_LEDControl",[parseInt(r),t],n)},this.Arm_SwitchProtocol=function({Handle:r,ProtocolFlag:t},n){this.exec("Arm_SwitchProtocol",[parseInt(r),t],n)},this.Arm_CreateFile=function({Handle:r,FileID:t,FileType:n,AttrBuffer:l},a){this.exec("Arm_CreateFile",[parseInt(r),n,parseInt(t),l],a)},this.Arm_WriteFile=function({Handle:r,FileID:t,FileType:n,FileOffset:l,DataInput:a},o){this.exec("Arm_WriteFile",[parseInt(r),n,parseInt(t),parseInt(l),a],o)},this.Arm_ReadFile0001=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0001"),parseInt(0),parseInt("64")],t)},this.Arm_ReadFile0002=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0002"),parseInt(0),parseInt("130")],t)},this.Arm_ReadFile0003=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0003"),parseInt(0),parseInt("130")],t)},this.Arm_ReadFile0004=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0004"),parseInt(0),parseInt("2048")],t)},this.Arm_ReadFile0005=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0005"),parseInt(0),parseInt("2048")],t)},this.Arm_DownloadExeFile=function({Handle:r,Count:t,ExeFileInfo:n},l){this.exec("Arm_DownloadExeFile",[parseInt(r),parseInt(t),n],l)},this.Arm_RunExeFile=function({Handle:r,FileID:t,InData:n,DataLen:l},a){this.exec("Arm_RunExeFile",[parseInt(r),parseInt(t),n,n.length,parseInt(l)],a)},this.Arm_ReadRunExeFileData=function(r){this.exec("Arm_ReadRunExeFileData",null,r)},this.Arm_DeleteFile=function({Handle:r,FileID:t,FileType:n},l){this.exec("Arm_DeleteFile",[parseInt(r),n,parseInt(t)],l)},this.Arm_WriteData=function({Handle:r,Offset:t,DataInput:n},l){this.exec("Arm_WriteData",[parseInt(r),parseInt(t),n],l)},this.Arm_ReadData=function({Handle:r,Offset:t,ReadLength:n},l){this.exec("Arm_ReadData",[parseInt(r),parseInt(t),n],l)},this.Arm_WriteShareMemory=function({Handle:r,DataInput:t},n){this.exec("Arm_WriteShareMemory",[parseInt(r),t],n)},this.Arm_ReadShareMemory=function({Handle:r},t){this.exec("Arm_ReadShareMemory",[parseInt(r)],t)},this.Arm_GenUniqueKey=function({Handle:r,Seed:t},n){this.exec("Arm_GenUniqueKey",[parseInt(r),t.length,t],n)},this.Arm_ChangePIN=function({Handle:r,NewPIN:t,OldPIN:n,TryCount:l,PinFlag:a},o){this.exec("Arm_ChangePIN",[parseInt(r),a,n,t,parseInt(l)],o)},this.Arm_ResetUserPIN=function({Handle:r,AdminPIN:t},n){this.exec("Arm_ResetUserPIN",[parseInt(r),t],n)},this.Arm_SetUserID=function({Handle:r,UserID:t},n){this.exec("Arm_SetUserID",[parseInt(r),parseInt(t)],n)},this.Arm_GetDeadline=function({Handle:r},t){this.exec("Arm_GetDeadline",[parseInt(r)],t)},this.Arm_SetDeadline=function({Handle:r,SetDeadTime:t},n){this.exec("Arm_SetDeadline",[parseInt(r),parseInt(t)],n)},this.Arm_GetUTCTime=function({Handle:r},t){this.exec("Arm_GetUTCTime",[parseInt(r)],t)},this.Arm_RFS=function({Handle:r},t){this.exec("Arm_RFS",[parseInt(r)],t)},this.Arm_RsaGenPubPriKey=function({Handle:r,RsaFileId:t},n){this.exec("Arm_RsaGenPubPriKey",[parseInt(r),parseInt(t)],n)},this.Arm_EccGenPubPriKey=function({Handle:r,EccFileId:t},n){this.exec("Arm_EccGenPubPriKey",[parseInt(r),parseInt(t)],n)},this.Arm_Sm2GenPubPriKey=function({Handle:r,Sm2FileId:t},n){this.exec("Arm_Sm2GenPubPriKey",[parseInt(r),parseInt(t)],n)},this.Arm_ReadRsaPri=function(r){this.exec("Arm_ReadRsaPri",null,r)},this.Arm_ReadRsaPub=function(r){this.exec("Arm_ReadRsaPub",null,r)},this.Arm_ReadEccPri=function(r){this.exec("Arm_ReadEccPri",null,r)},this.Arm_ReadEccPub=function(r){this.exec("Arm_ReadEccPub",null,r)},this.Arm_ReadSm2Pri=function(r){this.exec("Arm_ReadSm2Pri",null,r)},this.Arm_ReadSm2Pub=function(r){this.exec("Arm_ReadSm2Pub",null,r)},this.Arm_RsaPri=function({Handle:r,RsaPri_Flag:t,RsaPriInData:n,RsaPriFileID:l,RsaPriFileSize:a},o){this.exec("Arm_RsaPri",[parseInt(r),parseInt(l),parseInt(a),t,n],o)},this.Arm_RsaPub=function({Handle:r,RsaPubKey:t,RsaPub_Flag:n,RsaPubInData:l,RsaPubFileSize:a},o){this.exec("Arm_RsaPub",[parseInt(r),parseInt(a),n,t,t.length,l],o)},this.Arm_EccSign=function({Handle:r,HashData:t,EccFileId:n},l){this.exec("Arm_EccSign",[parseInt(r),parseInt(n),t],l)},this.Arm_EccVerify=function({Handle:r,HashData:t,EccPubKey:n,EccSignData:l},a){this.exec("Arm_EccVerify",[parseInt(r),n,n.length,t,l],a)},this.Arm_Sm2Sign=function({Handle:r,HashData:t,Sm2FileId:n},l){this.exec("Arm_Sm2Sign",[parseInt(r),parseInt(n),t],l)},this.Arm_Sm2Verify=function({Handle:r,HashData:t,Sm2PubKey:n,Sm2SignData:l},a){this.exec("Arm_Sm2Verify",[parseInt(r),n,n.length,t,l],a)},this.Arm_TDES=function({Handle:r,Tdes_Flag:t,TdesFileID:n,TdesInData:l},a){this.exec("Arm_TDES",[parseInt(r),parseInt(n),t,l],a)},this.Arm_SM4=function({Handle:r,Sm4_Flag:t,Sm4FileID:n,Sm4InData:l},a){this.exec("Arm_SM4",[parseInt(r),parseInt(n),t,l],a)},this.Arm_HASH=function({Handle:r,Hash_Flag:t,HashInData:n},l){this.exec("Arm_HASH",[parseInt(r),t,n],l)},this.Arm_Seed=function({Handle:r,SeedData:t,SeedLength:n},l){this.exec("Arm_Seed",[parseInt(r),n,t],l)},this.Arm_LimitSeedCount=function({Handle:r,SeedCount:t},n){this.exec("Arm_LimitSeedCount",[parseInt(r),parseInt(t)],n)},this.Arm_GenMotherKey=function({Handle:r,SeedLen:t,SeedForPID:n,SonCount:l,StartUserID:a,AdminTryCount:o,UserPin:u,UserTryCount:p,UpdateRSAPriKey:s},i){this.exec("Arm_GenMotherKey",[parseInt(r),parseInt(t),n,u,parseInt(p),parseInt(o),s,parseInt(a),parseInt(l)],i)},this.Arm_RequestInit=function({Handle:r},t){this.exec("Arm_RequestInit",[parseInt(r)],t)},this.Arm_GetInitDataFromMother=function({Handle:r},t){this.exec("Arm_GetInitDataFromMother",[parseInt(r),Request],t)},this.Arm_InitSon=function({Handle:r,InitData:t},n){this.exec("Arm_InitSon",[parseInt(r),t],n)},this.Arm_SetUpdatePriKey=function({Handle:r,UpdatePriKey:t},n){this.exec("Arm_SetUpdatePriKey",[parseInt(r),t],n)},this.Arm_MakeUpdatePacket=function({Handle:r,HID:t,Func:n,FileID:l,FileType:a,Offset:o,DataLen:u,DataBuffer:p,UpRSAPubKey:s},i){this.exec("Arm_MakeUpdatePacket",[parseInt(r),t,n,a,parseInt(l),parseInt(o),p,s,parseInt(u)],i)},this.Arm_MakeUpdatePacketFromMother=function({Handle:r,HID:t,Func:n,FileID:l,FileType:a,Offset:o,DataLen:u,DataBuffer:p},s){this.exec("Arm_MakeUpdatePacketFromMother",[parseInt(r),t,n,a,parseInt(l),parseInt(o),p,parseInt(u)],s)},this.Arm_Update=function({Handle:r,UpdateData:t},n){this.exec("Arm_Update",[parseInt(r),t],n)},this.Arm_Set_DATA_FILE_ATTR=function({Size:r,ReadPriv:t,WritePriv:n},l){this.exec("Arm_Set_DATA_FILE_ATTR",[parseInt(r),parseInt(t),parseInt(n)],l)},this.Arm_Set_PRIKEY_FILE_ATTR=function({Count:r,Size:t,Type:n,Priv:l,IsReset:a,IsDecOnRAM:o},u){this.exec("Arm_Set_PRIKEY_FILE_ATTR",[n,parseInt(t),parseInt(r),parseInt(l),parseInt(o),parseInt(a)],u)},this.Arm_Set_KEY_FILE_ATTR=function({Size:r,PrivEnc:t},n){this.exec("Arm_Set_KEY_FILE_ATTR",[parseInt(r),parseInt(t)],n)},this.Arm_Set_EXE_FILE_ATTR=function({FileLen:r,PrivExe:t},n){this.exec("Arm_Set_EXE_FILE_ATTR",[parseInt(r),parseInt(t)],n)},this.Arm_Set_DATA_LIC=function({ReadPriv:r,WritePriv:t},n){this.exec("Arm_Set_DATA_LIC",[parseInt(r),parseInt(t)],n)},this.Arm_Set_PRIKEY_LIC=function({Count:r,Priv:t,IsReset:n,IsDecOnRAM:l},a){this.exec("Arm_Set_PRIKEY_LIC",[parseInt(r),parseInt(t),parseInt(l),parseInt(n)],a)},this.Arm_Set_KEY_LIC=function({PrivEnc:r},t){this.exec("Arm_Set_KEY_LIC",[parseInt(r)],t)},this.Arm_Set_EXE_LIC=function({PrivExe:r},t){this.exec("Arm_Set_EXE_LIC",[parseInt(r)],t)},this.Arm_Set_EXE_FILE_INFO=function({FileID:r,FileData:t,FileSize:n,InBuffer:l,CallLimit:a},o){this.exec("Arm_Set_EXE_FILE_INFO",[l,parseInt(n),parseInt(r),parseInt(a),t,t.length],o)},this.Arm_Clear_EXE_FILE_INFO=function({InBuffer:r},t){this.exec("Arm_Clear_EXE_FILE_INFO",[r],t)}}const Dm={HID:0},_n={PRODUCT_ID:0,USER_ID:1,HARDWARE_ID:2},dl={USER:0};class s0{constructor(){It(this,"Base64",new Tm);It(this,"AtlCtrl",null);It(this,"ArmCount",0);It(this,"ArmIndex",0);It(this,"ArmHandle",0);It(this,"ArmRandom","");try{this.AtlCtrl=new Im("{39E9B272-82A7-4177-A19D-6723C1BDB0CC}")}catch(r){console.error(r),this.AtlCtrl=null}}armEnum(){if(this.AtlCtrl)return new Promise((r,t)=>{this.AtlCtrl.Arm_Enum((n,l)=>{n?(this.ArmCount=+l,r(l)):t(l)})})}armOpen(r=0){if(this.AtlCtrl)return this.ArmIndex=r,new Promise((t,n)=>{this.AtlCtrl.Arm_Open({Index:r},(l,a)=>{l?(this.ArmHandle=+a,t(a)):(this.ArmHandle=a,n(a))})})}armClose(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_Close({Handle:r},(l,a)=>{l?t(a):n(a)})})}armChangePIN(r,t,n=255,l=dl.USER,a=this.ArmHandle){if(this.AtlCtrl)return new Promise((o,u)=>{this.AtlCtrl.Arm_ChangePIN({Handle:a,NewPIN:r,OldPIN:t,TryCount:n,PinFlag:l},(p,s)=>{p&&s==0?(this.ArmPin=r,o(s)):u(s)})})}armGenRandom(r=16,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_GenRandom({Handle:t,RandomLen:r},(a,o)=>{a?(this.ArmRandom=o,n(o)):l(o)})})}armGetDeadline(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_GetDeadline({Handle:r},(l,a)=>{l?(this.ArmDeadline=a,t(a)):n(a)})})}armGenUniqueKey(r="MTIzNDU2Nzg5MA==",t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_GenUniqueKey({Handle:t,Seed:r},(a,o)=>{a?(this.ArmUKey=o,n(o)):l(o)})})}armGetDongleInfo(r=0,t=_n.HARDWARE_ID){if(this.AtlCtrl)return this.ArmIndex=r,new Promise((n,l)=>{this.AtlCtrl.Arm_GetDongleInfo({Index:r,DongleInfoNum:t},(a,o)=>{if(a){switch(t){case _n.USER_ID:this.ArmUid=o;break;case _n.PRODUCT_ID:this.ArmPid=o;break;case _n.HARDWARE_ID:this.ArmHid=o;break}n(o)}else l(o)})})}armLEDControl(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_LEDControl({Handle:t,LedFlag:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armRFS(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_RFS({Handle:r},(l,a)=>{l&&a==0?t(a):n(a)})})}armReadFile(r="0001",t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl[`Arm_ReadFile${r}`]({Handle:t},(a,o)=>{if(a&&o.length>0)try{o=this.Base64.decode(o),n(o)}catch(u){console.error(u),n(o)}else l(o)})})}armResetState(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_ResetState({Handle:r},(l,a)=>{l&&a==0?t(a):n(a)})})}armResetUserPIN(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_ResetUserPIN({Handle:t,AdminPIN:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armSetUserID(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_SetUserID({Handle:t,UserID:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armSetDeadline(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_SetDeadline({Handle:t,SetDeadTime:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armSwitchProtocol(r=Dm.HID,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_SwitchProtocol({Handle:t,ProtocolFlag:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armVerifyPIN(r,t=dl.USER,n=this.ArmHandle){if(this.AtlCtrl)return new Promise((l,a)=>{this.AtlCtrl.Arm_VerifyPIN({Handle:n,UserPin:r,UserType:t},(o,u)=>{o&&u==0?(this.ArmPin=r,l(u)):a(u)})})}armReadData(r=0,t=128,n=this.ArmHandle){if(this.AtlCtrl)return new Promise((l,a)=>{this.AtlCtrl.Arm_ReadData({Handle:n,Offset:r,ReadLength:t},(o,u)=>{o?(this.ArmData=u,l(u)):a(u)})})}armWriteData(r,t=0,n=this.ArmHandle){if(this.AtlCtrl)return new Promise((l,a)=>{this.AtlCtrl.Arm_WriteData({Handle:n,Offset:t,DataInput:r},(o,u)=>{o&&u==0?l(u):a(u)})})}armReadShareMemory(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_ReadShareMemory({Handle:r},(l,a)=>{l?(this.ArmData=a,t(a)):n(a)})})}armWriteShareMemory(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_WriteShareMemory({Handle:t,DataInput:r},(a,o)=>{a&&o==0?n(o):l(o)})})}}const l0=Symbol(),Dn="el",Rm="is-",jt=(e,r,t,n,l)=>{let a=`${e}-${r}`;return t&&(a+=`-${t}`),n&&(a+=`__${n}`),l&&(a+=`--${l}`),a},u0=Symbol("namespaceContextKey"),Om=e=>{const r=e||(N.getCurrentInstance()?N.inject(u0,N.ref(Dn)):N.ref(Dn));return N.computed(()=>N.unref(r)||Dn)},Sr=(e,r)=>{const t=Om(r);return{namespace:t,b:(v="")=>jt(t.value,e,v,"",""),e:v=>v?jt(t.value,e,"",v,""):"",m:v=>v?jt(t.value,e,"","",v):"",be:(v,m)=>v&&m?jt(t.value,e,v,m,""):"",em:(v,m)=>v&&m?jt(t.value,e,"",v,m):"",bm:(v,m)=>v&&m?jt(t.value,e,v,"",m):"",bem:(v,m,g)=>v&&m&&g?jt(t.value,e,v,m,g):"",is:(v,...m)=>{const g=m.length>=1?m[0]:!0;return v&&g?`${Rm}${v}`:""},cssVar:v=>{const m={};for(const g in v)v[g]&&(m[`--${t.value}-${g}`]=v[g]);return m},cssVarName:v=>`--${t.value}-${v}`,cssVarBlock:v=>{const m={};for(const g in v)v[g]&&(m[`--${t.value}-${e}-${g}`]=v[g]);return m},cssVarBlockName:v=>`--${t.value}-${e}-${v}`}};/**
31
+ */(function(e){var r=ti,t=pa,n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=u,e.SlowBuffer=x,e.INSPECT_MAX_BYTES=50;var l=2147483647;e.kMaxLength=l,u.TYPED_ARRAY_SUPPORT=a(),!u.TYPED_ARRAY_SUPPORT&&typeof console!="undefined"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function a(){try{var z=new Uint8Array(1),S={foo:function(){return 42}};return Object.setPrototypeOf(S,Uint8Array.prototype),Object.setPrototypeOf(z,S),z.foo()===42}catch(B){return!1}}Object.defineProperty(u.prototype,"parent",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.buffer}}),Object.defineProperty(u.prototype,"offset",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.byteOffset}});function o(z){if(z>l)throw new RangeError('The value "'+z+'" is invalid for option "size"');var S=new Uint8Array(z);return Object.setPrototypeOf(S,u.prototype),S}function u(z,S,B){if(typeof z=="number"){if(typeof S=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return d(z)}return p(z,S,B)}u.poolSize=8192;function p(z,S,B){if(typeof z=="string")return c(z,S);if(ArrayBuffer.isView(z))return h(z);if(z==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z);if(ee(z,ArrayBuffer)||z&&ee(z.buffer,ArrayBuffer)||typeof SharedArrayBuffer!="undefined"&&(ee(z,SharedArrayBuffer)||z&&ee(z.buffer,SharedArrayBuffer)))return v(z,S,B);if(typeof z=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var Y=z.valueOf&&z.valueOf();if(Y!=null&&Y!==z)return u.from(Y,S,B);var ie=m(z);if(ie)return ie;if(typeof Symbol!="undefined"&&Symbol.toPrimitive!=null&&typeof z[Symbol.toPrimitive]=="function")return u.from(z[Symbol.toPrimitive]("string"),S,B);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof z)}u.from=function(z,S,B){return p(z,S,B)},Object.setPrototypeOf(u.prototype,Uint8Array.prototype),Object.setPrototypeOf(u,Uint8Array);function s(z){if(typeof z!="number")throw new TypeError('"size" argument must be of type number');if(z<0)throw new RangeError('The value "'+z+'" is invalid for option "size"')}function i(z,S,B){return s(z),z<=0?o(z):S!==void 0?typeof B=="string"?o(z).fill(S,B):o(z).fill(S):o(z)}u.alloc=function(z,S,B){return i(z,S,B)};function d(z){return s(z),o(z<0?0:g(z)|0)}u.allocUnsafe=function(z){return d(z)},u.allocUnsafeSlow=function(z){return d(z)};function c(z,S){if((typeof S!="string"||S==="")&&(S="utf8"),!u.isEncoding(S))throw new TypeError("Unknown encoding: "+S);var B=y(z,S)|0,Y=o(B),ie=Y.write(z,S);return ie!==B&&(Y=Y.slice(0,ie)),Y}function f(z){for(var S=z.length<0?0:g(z.length)|0,B=o(S),Y=0;Y<S;Y+=1)B[Y]=z[Y]&255;return B}function h(z){if(ee(z,Uint8Array)){var S=new Uint8Array(z);return v(S.buffer,S.byteOffset,S.byteLength)}return f(z)}function v(z,S,B){if(S<0||z.byteLength<S)throw new RangeError('"offset" is outside of buffer bounds');if(z.byteLength<S+(B||0))throw new RangeError('"length" is outside of buffer bounds');var Y;return S===void 0&&B===void 0?Y=new Uint8Array(z):B===void 0?Y=new Uint8Array(z,S):Y=new Uint8Array(z,S,B),Object.setPrototypeOf(Y,u.prototype),Y}function m(z){if(u.isBuffer(z)){var S=g(z.length)|0,B=o(S);return B.length===0||z.copy(B,0,0,S),B}if(z.length!==void 0)return typeof z.length!="number"||te(z.length)?o(0):f(z);if(z.type==="Buffer"&&Array.isArray(z.data))return f(z.data)}function g(z){if(z>=l)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+l.toString(16)+" bytes");return z|0}function x(z){return+z!=z&&(z=0),u.alloc(+z)}u.isBuffer=function(S){return S!=null&&S._isBuffer===!0&&S!==u.prototype},u.compare=function(S,B){if(ee(S,Uint8Array)&&(S=u.from(S,S.offset,S.byteLength)),ee(B,Uint8Array)&&(B=u.from(B,B.offset,B.byteLength)),!u.isBuffer(S)||!u.isBuffer(B))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(S===B)return 0;for(var Y=S.length,ie=B.length,ue=0,ce=Math.min(Y,ie);ue<ce;++ue)if(S[ue]!==B[ue]){Y=S[ue],ie=B[ue];break}return Y<ie?-1:ie<Y?1:0},u.isEncoding=function(S){switch(String(S).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}},u.concat=function(S,B){if(!Array.isArray(S))throw new TypeError('"list" argument must be an Array of Buffers');if(S.length===0)return u.alloc(0);var Y;if(B===void 0)for(B=0,Y=0;Y<S.length;++Y)B+=S[Y].length;var ie=u.allocUnsafe(B),ue=0;for(Y=0;Y<S.length;++Y){var ce=S[Y];if(ee(ce,Uint8Array))ue+ce.length>ie.length?u.from(ce).copy(ie,ue):Uint8Array.prototype.set.call(ie,ce,ue);else if(u.isBuffer(ce))ce.copy(ie,ue);else throw new TypeError('"list" argument must be an Array of Buffers');ue+=ce.length}return ie};function y(z,S){if(u.isBuffer(z))return z.length;if(ArrayBuffer.isView(z)||ee(z,ArrayBuffer))return z.byteLength;if(typeof z!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof z);var B=z.length,Y=arguments.length>2&&arguments[2]===!0;if(!Y&&B===0)return 0;for(var ie=!1;;)switch(S){case"ascii":case"latin1":case"binary":return B;case"utf8":case"utf-8":return ae(z).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return B*2;case"hex":return B>>>1;case"base64":return R(z).length;default:if(ie)return Y?-1:ae(z).length;S=(""+S).toLowerCase(),ie=!0}}u.byteLength=y;function w(z,S,B){var Y=!1;if((S===void 0||S<0)&&(S=0),S>this.length||((B===void 0||B>this.length)&&(B=this.length),B<=0)||(B>>>=0,S>>>=0,B<=S))return"";for(z||(z="utf8");;)switch(z){case"hex":return U(this,S,B);case"utf8":case"utf-8":return F(this,S,B);case"ascii":return J(this,S,B);case"latin1":case"binary":return $(this,S,B);case"base64":return C(this,S,B);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return K(this,S,B);default:if(Y)throw new TypeError("Unknown encoding: "+z);z=(z+"").toLowerCase(),Y=!0}}u.prototype._isBuffer=!0;function k(z,S,B){var Y=z[S];z[S]=z[B],z[B]=Y}u.prototype.swap16=function(){var S=this.length;if(S%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var B=0;B<S;B+=2)k(this,B,B+1);return this},u.prototype.swap32=function(){var S=this.length;if(S%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var B=0;B<S;B+=4)k(this,B,B+3),k(this,B+1,B+2);return this},u.prototype.swap64=function(){var S=this.length;if(S%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var B=0;B<S;B+=8)k(this,B,B+7),k(this,B+1,B+6),k(this,B+2,B+5),k(this,B+3,B+4);return this},u.prototype.toString=function(){var S=this.length;return S===0?"":arguments.length===0?F(this,0,S):w.apply(this,arguments)},u.prototype.toLocaleString=u.prototype.toString,u.prototype.equals=function(S){if(!u.isBuffer(S))throw new TypeError("Argument must be a Buffer");return this===S?!0:u.compare(this,S)===0},u.prototype.inspect=function(){var S="",B=e.INSPECT_MAX_BYTES;return S=this.toString("hex",0,B).replace(/(.{2})/g,"$1 ").trim(),this.length>B&&(S+=" ... "),"<Buffer "+S+">"},n&&(u.prototype[n]=u.prototype.inspect),u.prototype.compare=function(S,B,Y,ie,ue){if(ee(S,Uint8Array)&&(S=u.from(S,S.offset,S.byteLength)),!u.isBuffer(S))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof S);if(B===void 0&&(B=0),Y===void 0&&(Y=S?S.length:0),ie===void 0&&(ie=0),ue===void 0&&(ue=this.length),B<0||Y>S.length||ie<0||ue>this.length)throw new RangeError("out of range index");if(ie>=ue&&B>=Y)return 0;if(ie>=ue)return-1;if(B>=Y)return 1;if(B>>>=0,Y>>>=0,ie>>>=0,ue>>>=0,this===S)return 0;for(var ce=ue-ie,me=Y-B,ge=Math.min(ce,me),Ce=this.slice(ie,ue),Te=S.slice(B,Y),Be=0;Be<ge;++Be)if(Ce[Be]!==Te[Be]){ce=Ce[Be],me=Te[Be];break}return ce<me?-1:me<ce?1:0};function T(z,S,B,Y,ie){if(z.length===0)return-1;if(typeof B=="string"?(Y=B,B=0):B>2147483647?B=2147483647:B<-2147483648&&(B=-2147483648),B=+B,te(B)&&(B=ie?0:z.length-1),B<0&&(B=z.length+B),B>=z.length){if(ie)return-1;B=z.length-1}else if(B<0)if(ie)B=0;else return-1;if(typeof S=="string"&&(S=u.from(S,Y)),u.isBuffer(S))return S.length===0?-1:I(z,S,B,Y,ie);if(typeof S=="number")return S=S&255,typeof Uint8Array.prototype.indexOf=="function"?ie?Uint8Array.prototype.indexOf.call(z,S,B):Uint8Array.prototype.lastIndexOf.call(z,S,B):I(z,[S],B,Y,ie);throw new TypeError("val must be string, number or Buffer")}function I(z,S,B,Y,ie){var ue=1,ce=z.length,me=S.length;if(Y!==void 0&&(Y=String(Y).toLowerCase(),Y==="ucs2"||Y==="ucs-2"||Y==="utf16le"||Y==="utf-16le")){if(z.length<2||S.length<2)return-1;ue=2,ce/=2,me/=2,B/=2}function ge(Lt,Ut){return ue===1?Lt[Ut]:Lt.readUInt16BE(Ut*ue)}var Ce;if(ie){var Te=-1;for(Ce=B;Ce<ce;Ce++)if(ge(z,Ce)===ge(S,Te===-1?0:Ce-Te)){if(Te===-1&&(Te=Ce),Ce-Te+1===me)return Te*ue}else Te!==-1&&(Ce-=Ce-Te),Te=-1}else for(B+me>ce&&(B=ce-me),Ce=B;Ce>=0;Ce--){for(var Be=!0,kt=0;kt<me;kt++)if(ge(z,Ce+kt)!==ge(S,kt)){Be=!1;break}if(Be)return Ce}return-1}u.prototype.includes=function(S,B,Y){return this.indexOf(S,B,Y)!==-1},u.prototype.indexOf=function(S,B,Y){return T(this,S,B,Y,!0)},u.prototype.lastIndexOf=function(S,B,Y){return T(this,S,B,Y,!1)};function D(z,S,B,Y){B=Number(B)||0;var ie=z.length-B;Y?(Y=Number(Y),Y>ie&&(Y=ie)):Y=ie;var ue=S.length;Y>ue/2&&(Y=ue/2);for(var ce=0;ce<Y;++ce){var me=parseInt(S.substr(ce*2,2),16);if(te(me))return ce;z[B+ce]=me}return ce}function X(z,S,B,Y){return G(ae(S,z.length-B),z,B,Y)}function V(z,S,B,Y){return G(b(S),z,B,Y)}function E(z,S,B,Y){return G(R(S),z,B,Y)}function A(z,S,B,Y){return G(_(S,z.length-B),z,B,Y)}u.prototype.write=function(S,B,Y,ie){if(B===void 0)ie="utf8",Y=this.length,B=0;else if(Y===void 0&&typeof B=="string")ie=B,Y=this.length,B=0;else if(isFinite(B))B=B>>>0,isFinite(Y)?(Y=Y>>>0,ie===void 0&&(ie="utf8")):(ie=Y,Y=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var ue=this.length-B;if((Y===void 0||Y>ue)&&(Y=ue),S.length>0&&(Y<0||B<0)||B>this.length)throw new RangeError("Attempt to write outside buffer bounds");ie||(ie="utf8");for(var ce=!1;;)switch(ie){case"hex":return D(this,S,B,Y);case"utf8":case"utf-8":return X(this,S,B,Y);case"ascii":case"latin1":case"binary":return V(this,S,B,Y);case"base64":return E(this,S,B,Y);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,S,B,Y);default:if(ce)throw new TypeError("Unknown encoding: "+ie);ie=(""+ie).toLowerCase(),ce=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function C(z,S,B){return S===0&&B===z.length?r.fromByteArray(z):r.fromByteArray(z.slice(S,B))}function F(z,S,B){B=Math.min(z.length,B);for(var Y=[],ie=S;ie<B;){var ue=z[ie],ce=null,me=ue>239?4:ue>223?3:ue>191?2:1;if(ie+me<=B){var ge,Ce,Te,Be;switch(me){case 1:ue<128&&(ce=ue);break;case 2:ge=z[ie+1],(ge&192)===128&&(Be=(ue&31)<<6|ge&63,Be>127&&(ce=Be));break;case 3:ge=z[ie+1],Ce=z[ie+2],(ge&192)===128&&(Ce&192)===128&&(Be=(ue&15)<<12|(ge&63)<<6|Ce&63,Be>2047&&(Be<55296||Be>57343)&&(ce=Be));break;case 4:ge=z[ie+1],Ce=z[ie+2],Te=z[ie+3],(ge&192)===128&&(Ce&192)===128&&(Te&192)===128&&(Be=(ue&15)<<18|(ge&63)<<12|(Ce&63)<<6|Te&63,Be>65535&&Be<1114112&&(ce=Be))}}ce===null?(ce=65533,me=1):ce>65535&&(ce-=65536,Y.push(ce>>>10&1023|55296),ce=56320|ce&1023),Y.push(ce),ie+=me}return P(Y)}var j=4096;function P(z){var S=z.length;if(S<=j)return String.fromCharCode.apply(String,z);for(var B="",Y=0;Y<S;)B+=String.fromCharCode.apply(String,z.slice(Y,Y+=j));return B}function J(z,S,B){var Y="";B=Math.min(z.length,B);for(var ie=S;ie<B;++ie)Y+=String.fromCharCode(z[ie]&127);return Y}function $(z,S,B){var Y="";B=Math.min(z.length,B);for(var ie=S;ie<B;++ie)Y+=String.fromCharCode(z[ie]);return Y}function U(z,S,B){var Y=z.length;(!S||S<0)&&(S=0),(!B||B<0||B>Y)&&(B=Y);for(var ie="",ue=S;ue<B;++ue)ie+=se[z[ue]];return ie}function K(z,S,B){for(var Y=z.slice(S,B),ie="",ue=0;ue<Y.length-1;ue+=2)ie+=String.fromCharCode(Y[ue]+Y[ue+1]*256);return ie}u.prototype.slice=function(S,B){var Y=this.length;S=~~S,B=B===void 0?Y:~~B,S<0?(S+=Y,S<0&&(S=0)):S>Y&&(S=Y),B<0?(B+=Y,B<0&&(B=0)):B>Y&&(B=Y),B<S&&(B=S);var ie=this.subarray(S,B);return Object.setPrototypeOf(ie,u.prototype),ie};function L(z,S,B){if(z%1!==0||z<0)throw new RangeError("offset is not uint");if(z+S>B)throw new RangeError("Trying to access beyond buffer length")}u.prototype.readUintLE=u.prototype.readUIntLE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=this[S],ue=1,ce=0;++ce<B&&(ue*=256);)ie+=this[S+ce]*ue;return ie},u.prototype.readUintBE=u.prototype.readUIntBE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=this[S+--B],ue=1;B>0&&(ue*=256);)ie+=this[S+--B]*ue;return ie},u.prototype.readUint8=u.prototype.readUInt8=function(S,B){return S=S>>>0,B||L(S,1,this.length),this[S]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(S,B){return S=S>>>0,B||L(S,2,this.length),this[S]|this[S+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(S,B){return S=S>>>0,B||L(S,2,this.length),this[S]<<8|this[S+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(S,B){return S=S>>>0,B||L(S,4,this.length),(this[S]|this[S+1]<<8|this[S+2]<<16)+this[S+3]*16777216},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(S,B){return S=S>>>0,B||L(S,4,this.length),this[S]*16777216+(this[S+1]<<16|this[S+2]<<8|this[S+3])},u.prototype.readIntLE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=this[S],ue=1,ce=0;++ce<B&&(ue*=256);)ie+=this[S+ce]*ue;return ue*=128,ie>=ue&&(ie-=Math.pow(2,8*B)),ie},u.prototype.readIntBE=function(S,B,Y){S=S>>>0,B=B>>>0,Y||L(S,B,this.length);for(var ie=B,ue=1,ce=this[S+--ie];ie>0&&(ue*=256);)ce+=this[S+--ie]*ue;return ue*=128,ce>=ue&&(ce-=Math.pow(2,8*B)),ce},u.prototype.readInt8=function(S,B){return S=S>>>0,B||L(S,1,this.length),this[S]&128?(255-this[S]+1)*-1:this[S]},u.prototype.readInt16LE=function(S,B){S=S>>>0,B||L(S,2,this.length);var Y=this[S]|this[S+1]<<8;return Y&32768?Y|4294901760:Y},u.prototype.readInt16BE=function(S,B){S=S>>>0,B||L(S,2,this.length);var Y=this[S+1]|this[S]<<8;return Y&32768?Y|4294901760:Y},u.prototype.readInt32LE=function(S,B){return S=S>>>0,B||L(S,4,this.length),this[S]|this[S+1]<<8|this[S+2]<<16|this[S+3]<<24},u.prototype.readInt32BE=function(S,B){return S=S>>>0,B||L(S,4,this.length),this[S]<<24|this[S+1]<<16|this[S+2]<<8|this[S+3]},u.prototype.readFloatLE=function(S,B){return S=S>>>0,B||L(S,4,this.length),t.read(this,S,!0,23,4)},u.prototype.readFloatBE=function(S,B){return S=S>>>0,B||L(S,4,this.length),t.read(this,S,!1,23,4)},u.prototype.readDoubleLE=function(S,B){return S=S>>>0,B||L(S,8,this.length),t.read(this,S,!0,52,8)},u.prototype.readDoubleBE=function(S,B){return S=S>>>0,B||L(S,8,this.length),t.read(this,S,!1,52,8)};function O(z,S,B,Y,ie,ue){if(!u.isBuffer(z))throw new TypeError('"buffer" argument must be a Buffer instance');if(S>ie||S<ue)throw new RangeError('"value" argument is out of bounds');if(B+Y>z.length)throw new RangeError("Index out of range")}u.prototype.writeUintLE=u.prototype.writeUIntLE=function(S,B,Y,ie){if(S=+S,B=B>>>0,Y=Y>>>0,!ie){var ue=Math.pow(2,8*Y)-1;O(this,S,B,Y,ue,0)}var ce=1,me=0;for(this[B]=S&255;++me<Y&&(ce*=256);)this[B+me]=S/ce&255;return B+Y},u.prototype.writeUintBE=u.prototype.writeUIntBE=function(S,B,Y,ie){if(S=+S,B=B>>>0,Y=Y>>>0,!ie){var ue=Math.pow(2,8*Y)-1;O(this,S,B,Y,ue,0)}var ce=Y-1,me=1;for(this[B+ce]=S&255;--ce>=0&&(me*=256);)this[B+ce]=S/me&255;return B+Y},u.prototype.writeUint8=u.prototype.writeUInt8=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,1,255,0),this[B]=S&255,B+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,65535,0),this[B]=S&255,this[B+1]=S>>>8,B+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,65535,0),this[B]=S>>>8,this[B+1]=S&255,B+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,4294967295,0),this[B+3]=S>>>24,this[B+2]=S>>>16,this[B+1]=S>>>8,this[B]=S&255,B+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,4294967295,0),this[B]=S>>>24,this[B+1]=S>>>16,this[B+2]=S>>>8,this[B+3]=S&255,B+4},u.prototype.writeIntLE=function(S,B,Y,ie){if(S=+S,B=B>>>0,!ie){var ue=Math.pow(2,8*Y-1);O(this,S,B,Y,ue-1,-ue)}var ce=0,me=1,ge=0;for(this[B]=S&255;++ce<Y&&(me*=256);)S<0&&ge===0&&this[B+ce-1]!==0&&(ge=1),this[B+ce]=(S/me>>0)-ge&255;return B+Y},u.prototype.writeIntBE=function(S,B,Y,ie){if(S=+S,B=B>>>0,!ie){var ue=Math.pow(2,8*Y-1);O(this,S,B,Y,ue-1,-ue)}var ce=Y-1,me=1,ge=0;for(this[B+ce]=S&255;--ce>=0&&(me*=256);)S<0&&ge===0&&this[B+ce+1]!==0&&(ge=1),this[B+ce]=(S/me>>0)-ge&255;return B+Y},u.prototype.writeInt8=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,1,127,-128),S<0&&(S=255+S+1),this[B]=S&255,B+1},u.prototype.writeInt16LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,32767,-32768),this[B]=S&255,this[B+1]=S>>>8,B+2},u.prototype.writeInt16BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,2,32767,-32768),this[B]=S>>>8,this[B+1]=S&255,B+2},u.prototype.writeInt32LE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,2147483647,-2147483648),this[B]=S&255,this[B+1]=S>>>8,this[B+2]=S>>>16,this[B+3]=S>>>24,B+4},u.prototype.writeInt32BE=function(S,B,Y){return S=+S,B=B>>>0,Y||O(this,S,B,4,2147483647,-2147483648),S<0&&(S=4294967295+S+1),this[B]=S>>>24,this[B+1]=S>>>16,this[B+2]=S>>>8,this[B+3]=S&255,B+4};function H(z,S,B,Y,ie,ue){if(B+Y>z.length)throw new RangeError("Index out of range");if(B<0)throw new RangeError("Index out of range")}function W(z,S,B,Y,ie){return S=+S,B=B>>>0,ie||H(z,S,B,4),t.write(z,S,B,Y,23,4),B+4}u.prototype.writeFloatLE=function(S,B,Y){return W(this,S,B,!0,Y)},u.prototype.writeFloatBE=function(S,B,Y){return W(this,S,B,!1,Y)};function Z(z,S,B,Y,ie){return S=+S,B=B>>>0,ie||H(z,S,B,8),t.write(z,S,B,Y,52,8),B+8}u.prototype.writeDoubleLE=function(S,B,Y){return Z(this,S,B,!0,Y)},u.prototype.writeDoubleBE=function(S,B,Y){return Z(this,S,B,!1,Y)},u.prototype.copy=function(S,B,Y,ie){if(!u.isBuffer(S))throw new TypeError("argument should be a Buffer");if(Y||(Y=0),!ie&&ie!==0&&(ie=this.length),B>=S.length&&(B=S.length),B||(B=0),ie>0&&ie<Y&&(ie=Y),ie===Y||S.length===0||this.length===0)return 0;if(B<0)throw new RangeError("targetStart out of bounds");if(Y<0||Y>=this.length)throw new RangeError("Index out of range");if(ie<0)throw new RangeError("sourceEnd out of bounds");ie>this.length&&(ie=this.length),S.length-B<ie-Y&&(ie=S.length-B+Y);var ue=ie-Y;return this===S&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(B,Y,ie):Uint8Array.prototype.set.call(S,this.subarray(Y,ie),B),ue},u.prototype.fill=function(S,B,Y,ie){if(typeof S=="string"){if(typeof B=="string"?(ie=B,B=0,Y=this.length):typeof Y=="string"&&(ie=Y,Y=this.length),ie!==void 0&&typeof ie!="string")throw new TypeError("encoding must be a string");if(typeof ie=="string"&&!u.isEncoding(ie))throw new TypeError("Unknown encoding: "+ie);if(S.length===1){var ue=S.charCodeAt(0);(ie==="utf8"&&ue<128||ie==="latin1")&&(S=ue)}}else typeof S=="number"?S=S&255:typeof S=="boolean"&&(S=Number(S));if(B<0||this.length<B||this.length<Y)throw new RangeError("Out of range index");if(Y<=B)return this;B=B>>>0,Y=Y===void 0?this.length:Y>>>0,S||(S=0);var ce;if(typeof S=="number")for(ce=B;ce<Y;++ce)this[ce]=S;else{var me=u.isBuffer(S)?S:u.from(S,ie),ge=me.length;if(ge===0)throw new TypeError('The value "'+S+'" is invalid for argument "value"');for(ce=0;ce<Y-B;++ce)this[ce+B]=me[ce%ge]}return this};var re=/[^+/0-9A-Za-z-_]/g;function oe(z){if(z=z.split("=")[0],z=z.trim().replace(re,""),z.length<2)return"";for(;z.length%4!==0;)z=z+"=";return z}function ae(z,S){S=S||1/0;for(var B,Y=z.length,ie=null,ue=[],ce=0;ce<Y;++ce){if(B=z.charCodeAt(ce),B>55295&&B<57344){if(!ie){if(B>56319){(S-=3)>-1&&ue.push(239,191,189);continue}else if(ce+1===Y){(S-=3)>-1&&ue.push(239,191,189);continue}ie=B;continue}if(B<56320){(S-=3)>-1&&ue.push(239,191,189),ie=B;continue}B=(ie-55296<<10|B-56320)+65536}else ie&&(S-=3)>-1&&ue.push(239,191,189);if(ie=null,B<128){if((S-=1)<0)break;ue.push(B)}else if(B<2048){if((S-=2)<0)break;ue.push(B>>6|192,B&63|128)}else if(B<65536){if((S-=3)<0)break;ue.push(B>>12|224,B>>6&63|128,B&63|128)}else if(B<1114112){if((S-=4)<0)break;ue.push(B>>18|240,B>>12&63|128,B>>6&63|128,B&63|128)}else throw new Error("Invalid code point")}return ue}function b(z){for(var S=[],B=0;B<z.length;++B)S.push(z.charCodeAt(B)&255);return S}function _(z,S){for(var B,Y,ie,ue=[],ce=0;ce<z.length&&!((S-=2)<0);++ce)B=z.charCodeAt(ce),Y=B>>8,ie=B%256,ue.push(ie),ue.push(Y);return ue}function R(z){return r.toByteArray(oe(z))}function G(z,S,B,Y){for(var ie=0;ie<Y&&!(ie+B>=S.length||ie>=z.length);++ie)S[ie+B]=z[ie];return ie}function ee(z,S){return z instanceof S||z!=null&&z.constructor!=null&&z.constructor.name!=null&&z.constructor.name===S.name}function te(z){return z!==z}var se=function(){for(var z="0123456789abcdef",S=new Array(256),B=0;B<16;++B)for(var Y=B*16,ie=0;ie<16;++ie)S[Y+ie]=z[B]+z[ie];return S}()})(we);var vm=we.Buffer,ym=function(e){if(e instanceof Uint8Array){if(e.byteOffset===0&&e.byteLength===e.buffer.byteLength)return e.buffer;if(typeof e.buffer.slice=="function")return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)}if(vm.isBuffer(e)){for(var r=new Uint8Array(e.length),t=e.length,n=0;n<t;n++)r[n]=e[n];return r.buffer}else throw new Error("Argument must be a Buffer")};const $r=Zo(ym);var n0={exports:{}};(function(e,r){(function(){var t,n=0xdeadbeefcafe,l=(n&16777215)==15715070;function a(M,q,Q){M!=null&&(typeof M=="number"?this.fromNumber(M,q,Q):q==null&&typeof M!="string"?this.fromString(M,256):this.fromString(M,q))}function o(){return new a(null)}function u(M,q,Q,ne,fe,pe){for(;--pe>=0;){var de=q*this[M++]+Q[ne]+fe;fe=Math.floor(de/67108864),Q[ne++]=de&67108863}return fe}function p(M,q,Q,ne,fe,pe){for(var de=q&32767,ve=q>>15;--pe>=0;){var Fe=this[M]&32767,Ue=this[M++]>>15,it=ve*Fe+Ue*de;Fe=de*Fe+((it&32767)<<15)+Q[ne]+(fe&1073741823),fe=(Fe>>>30)+(it>>>15)+ve*Ue+(fe>>>30),Q[ne++]=Fe&1073741823}return fe}function s(M,q,Q,ne,fe,pe){for(var de=q&16383,ve=q>>14;--pe>=0;){var Fe=this[M]&16383,Ue=this[M++]>>14,it=ve*Fe+Ue*de;Fe=de*Fe+((it&16383)<<14)+Q[ne]+fe,fe=(Fe>>28)+(it>>14)+ve*Ue,Q[ne++]=Fe&268435455}return fe}var i=typeof navigator!="undefined";i&&l&&navigator.appName=="Microsoft Internet Explorer"?(a.prototype.am=p,t=30):i&&l&&navigator.appName!="Netscape"?(a.prototype.am=u,t=26):(a.prototype.am=s,t=28),a.prototype.DB=t,a.prototype.DM=(1<<t)-1,a.prototype.DV=1<<t;var d=52;a.prototype.FV=Math.pow(2,d),a.prototype.F1=d-t,a.prototype.F2=2*t-d;var c="0123456789abcdefghijklmnopqrstuvwxyz",f=new Array,h,v;for(h=48,v=0;v<=9;++v)f[h++]=v;for(h=97,v=10;v<36;++v)f[h++]=v;for(h=65,v=10;v<36;++v)f[h++]=v;function m(M){return c.charAt(M)}function g(M,q){var Q=f[M.charCodeAt(q)];return Q==null?-1:Q}function x(M){for(var q=this.t-1;q>=0;--q)M[q]=this[q];M.t=this.t,M.s=this.s}function y(M){this.t=1,this.s=M<0?-1:0,M>0?this[0]=M:M<-1?this[0]=M+this.DV:this.t=0}function w(M){var q=o();return q.fromInt(M),q}function k(M,q){var Q;if(q==16)Q=4;else if(q==8)Q=3;else if(q==256)Q=8;else if(q==2)Q=1;else if(q==32)Q=5;else if(q==4)Q=2;else{this.fromRadix(M,q);return}this.t=0,this.s=0;for(var ne=M.length,fe=!1,pe=0;--ne>=0;){var de=Q==8?M[ne]&255:g(M,ne);if(de<0){M.charAt(ne)=="-"&&(fe=!0);continue}fe=!1,pe==0?this[this.t++]=de:pe+Q>this.DB?(this[this.t-1]|=(de&(1<<this.DB-pe)-1)<<pe,this[this.t++]=de>>this.DB-pe):this[this.t-1]|=de<<pe,pe+=Q,pe>=this.DB&&(pe-=this.DB)}Q==8&&M[0]&128&&(this.s=-1,pe>0&&(this[this.t-1]|=(1<<this.DB-pe)-1<<pe)),this.clamp(),fe&&a.ZERO.subTo(this,this)}function T(){for(var M=this.s&this.DM;this.t>0&&this[this.t-1]==M;)--this.t}function I(M){if(this.s<0)return"-"+this.negate().toString(M);var q;if(M==16)q=4;else if(M==8)q=3;else if(M==2)q=1;else if(M==32)q=5;else if(M==4)q=2;else return this.toRadix(M);var Q=(1<<q)-1,ne,fe=!1,pe="",de=this.t,ve=this.DB-de*this.DB%q;if(de-- >0)for(ve<this.DB&&(ne=this[de]>>ve)>0&&(fe=!0,pe=m(ne));de>=0;)ve<q?(ne=(this[de]&(1<<ve)-1)<<q-ve,ne|=this[--de]>>(ve+=this.DB-q)):(ne=this[de]>>(ve-=q)&Q,ve<=0&&(ve+=this.DB,--de)),ne>0&&(fe=!0),fe&&(pe+=m(ne));return fe?pe:"0"}function D(){var M=o();return a.ZERO.subTo(this,M),M}function X(){return this.s<0?this.negate():this}function V(M){var q=this.s-M.s;if(q!=0)return q;var Q=this.t;if(q=Q-M.t,q!=0)return this.s<0?-q:q;for(;--Q>=0;)if((q=this[Q]-M[Q])!=0)return q;return 0}function E(M){var q=1,Q;return(Q=M>>>16)!=0&&(M=Q,q+=16),(Q=M>>8)!=0&&(M=Q,q+=8),(Q=M>>4)!=0&&(M=Q,q+=4),(Q=M>>2)!=0&&(M=Q,q+=2),(Q=M>>1)!=0&&(M=Q,q+=1),q}function A(){return this.t<=0?0:this.DB*(this.t-1)+E(this[this.t-1]^this.s&this.DM)}function C(M,q){var Q;for(Q=this.t-1;Q>=0;--Q)q[Q+M]=this[Q];for(Q=M-1;Q>=0;--Q)q[Q]=0;q.t=this.t+M,q.s=this.s}function F(M,q){for(var Q=M;Q<this.t;++Q)q[Q-M]=this[Q];q.t=Math.max(this.t-M,0),q.s=this.s}function j(M,q){var Q=M%this.DB,ne=this.DB-Q,fe=(1<<ne)-1,pe=Math.floor(M/this.DB),de=this.s<<Q&this.DM,ve;for(ve=this.t-1;ve>=0;--ve)q[ve+pe+1]=this[ve]>>ne|de,de=(this[ve]&fe)<<Q;for(ve=pe-1;ve>=0;--ve)q[ve]=0;q[pe]=de,q.t=this.t+pe+1,q.s=this.s,q.clamp()}function P(M,q){q.s=this.s;var Q=Math.floor(M/this.DB);if(Q>=this.t){q.t=0;return}var ne=M%this.DB,fe=this.DB-ne,pe=(1<<ne)-1;q[0]=this[Q]>>ne;for(var de=Q+1;de<this.t;++de)q[de-Q-1]|=(this[de]&pe)<<fe,q[de-Q]=this[de]>>ne;ne>0&&(q[this.t-Q-1]|=(this.s&pe)<<fe),q.t=this.t-Q,q.clamp()}function J(M,q){for(var Q=0,ne=0,fe=Math.min(M.t,this.t);Q<fe;)ne+=this[Q]-M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;if(M.t<this.t){for(ne-=M.s;Q<this.t;)ne+=this[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne+=this.s}else{for(ne+=this.s;Q<M.t;)ne-=M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne-=M.s}q.s=ne<0?-1:0,ne<-1?q[Q++]=this.DV+ne:ne>0&&(q[Q++]=ne),q.t=Q,q.clamp()}function $(M,q){var Q=this.abs(),ne=M.abs(),fe=Q.t;for(q.t=fe+ne.t;--fe>=0;)q[fe]=0;for(fe=0;fe<ne.t;++fe)q[fe+Q.t]=Q.am(0,ne[fe],q,fe,0,Q.t);q.s=0,q.clamp(),this.s!=M.s&&a.ZERO.subTo(q,q)}function U(M){for(var q=this.abs(),Q=M.t=2*q.t;--Q>=0;)M[Q]=0;for(Q=0;Q<q.t-1;++Q){var ne=q.am(Q,q[Q],M,2*Q,0,1);(M[Q+q.t]+=q.am(Q+1,2*q[Q],M,2*Q+1,ne,q.t-Q-1))>=q.DV&&(M[Q+q.t]-=q.DV,M[Q+q.t+1]=1)}M.t>0&&(M[M.t-1]+=q.am(Q,q[Q],M,2*Q,0,1)),M.s=0,M.clamp()}function K(M,q,Q){var ne=M.abs();if(!(ne.t<=0)){var fe=this.abs();if(fe.t<ne.t){q!=null&&q.fromInt(0),Q!=null&&this.copyTo(Q);return}Q==null&&(Q=o());var pe=o(),de=this.s,ve=M.s,Fe=this.DB-E(ne[ne.t-1]);Fe>0?(ne.lShiftTo(Fe,pe),fe.lShiftTo(Fe,Q)):(ne.copyTo(pe),fe.copyTo(Q));var Ue=pe.t,it=pe[Ue-1];if(it!=0){var tt=it*(1<<this.F1)+(Ue>1?pe[Ue-2]>>this.F2:0),Et=this.FV/tt,un=(1<<this.F1)/tt,ut=1<<this.F2,ct=Q.t,cn=ct-Ue,Ft=q==null?o():q;for(pe.dlShiftTo(cn,Ft),Q.compareTo(Ft)>=0&&(Q[Q.t++]=1,Q.subTo(Ft,Q)),a.ONE.dlShiftTo(Ue,Ft),Ft.subTo(pe,pe);pe.t<Ue;)pe[pe.t++]=0;for(;--cn>=0;){var mi=Q[--ct]==it?this.DM:Math.floor(Q[ct]*Et+(Q[ct-1]+ut)*un);if((Q[ct]+=pe.am(0,mi,Q,cn,0,Ue))<mi)for(pe.dlShiftTo(cn,Ft),Q.subTo(Ft,Q);Q[ct]<--mi;)Q.subTo(Ft,Q)}q!=null&&(Q.drShiftTo(Ue,q),de!=ve&&a.ZERO.subTo(q,q)),Q.t=Ue,Q.clamp(),Fe>0&&Q.rShiftTo(Fe,Q),de<0&&a.ZERO.subTo(Q,Q)}}}function L(M){var q=o();return this.abs().divRemTo(M,null,q),this.s<0&&q.compareTo(a.ZERO)>0&&M.subTo(q,q),q}function O(M){this.m=M}function H(M){return M.s<0||M.compareTo(this.m)>=0?M.mod(this.m):M}function W(M){return M}function Z(M){M.divRemTo(this.m,null,M)}function re(M,q,Q){M.multiplyTo(q,Q),this.reduce(Q)}function oe(M,q){M.squareTo(q),this.reduce(q)}O.prototype.convert=H,O.prototype.revert=W,O.prototype.reduce=Z,O.prototype.mulTo=re,O.prototype.sqrTo=oe;function ae(){if(this.t<1)return 0;var M=this[0];if(!(M&1))return 0;var q=M&3;return q=q*(2-(M&15)*q)&15,q=q*(2-(M&255)*q)&255,q=q*(2-((M&65535)*q&65535))&65535,q=q*(2-M*q%this.DV)%this.DV,q>0?this.DV-q:-q}function b(M){this.m=M,this.mp=M.invDigit(),this.mpl=this.mp&32767,this.mph=this.mp>>15,this.um=(1<<M.DB-15)-1,this.mt2=2*M.t}function _(M){var q=o();return M.abs().dlShiftTo(this.m.t,q),q.divRemTo(this.m,null,q),M.s<0&&q.compareTo(a.ZERO)>0&&this.m.subTo(q,q),q}function R(M){var q=o();return M.copyTo(q),this.reduce(q),q}function G(M){for(;M.t<=this.mt2;)M[M.t++]=0;for(var q=0;q<this.m.t;++q){var Q=M[q]&32767,ne=Q*this.mpl+((Q*this.mph+(M[q]>>15)*this.mpl&this.um)<<15)&M.DM;for(Q=q+this.m.t,M[Q]+=this.m.am(0,ne,M,q,0,this.m.t);M[Q]>=M.DV;)M[Q]-=M.DV,M[++Q]++}M.clamp(),M.drShiftTo(this.m.t,M),M.compareTo(this.m)>=0&&M.subTo(this.m,M)}function ee(M,q){M.squareTo(q),this.reduce(q)}function te(M,q,Q){M.multiplyTo(q,Q),this.reduce(Q)}b.prototype.convert=_,b.prototype.revert=R,b.prototype.reduce=G,b.prototype.mulTo=te,b.prototype.sqrTo=ee;function se(){return(this.t>0?this[0]&1:this.s)==0}function z(M,q){if(M>4294967295||M<1)return a.ONE;var Q=o(),ne=o(),fe=q.convert(this),pe=E(M)-1;for(fe.copyTo(Q);--pe>=0;)if(q.sqrTo(Q,ne),(M&1<<pe)>0)q.mulTo(ne,fe,Q);else{var de=Q;Q=ne,ne=de}return q.revert(Q)}function S(M,q){var Q;return M<256||q.isEven()?Q=new O(q):Q=new b(q),this.exp(M,Q)}a.prototype.copyTo=x,a.prototype.fromInt=y,a.prototype.fromString=k,a.prototype.clamp=T,a.prototype.dlShiftTo=C,a.prototype.drShiftTo=F,a.prototype.lShiftTo=j,a.prototype.rShiftTo=P,a.prototype.subTo=J,a.prototype.multiplyTo=$,a.prototype.squareTo=U,a.prototype.divRemTo=K,a.prototype.invDigit=ae,a.prototype.isEven=se,a.prototype.exp=z,a.prototype.toString=I,a.prototype.negate=D,a.prototype.abs=X,a.prototype.compareTo=V,a.prototype.bitLength=A,a.prototype.mod=L,a.prototype.modPowInt=S,a.ZERO=w(0),a.ONE=w(1);function B(){var M=o();return this.copyTo(M),M}function Y(){if(this.s<0){if(this.t==1)return this[0]-this.DV;if(this.t==0)return-1}else{if(this.t==1)return this[0];if(this.t==0)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]}function ie(){return this.t==0?this.s:this[0]<<24>>24}function ue(){return this.t==0?this.s:this[0]<<16>>16}function ce(M){return Math.floor(Math.LN2*this.DB/Math.log(M))}function me(){return this.s<0?-1:this.t<=0||this.t==1&&this[0]<=0?0:1}function ge(M){if(M==null&&(M=10),this.signum()==0||M<2||M>36)return"0";var q=this.chunkSize(M),Q=Math.pow(M,q),ne=w(Q),fe=o(),pe=o(),de="";for(this.divRemTo(ne,fe,pe);fe.signum()>0;)de=(Q+pe.intValue()).toString(M).substr(1)+de,fe.divRemTo(ne,fe,pe);return pe.intValue().toString(M)+de}function Ce(M,q){this.fromInt(0),q==null&&(q=10);for(var Q=this.chunkSize(q),ne=Math.pow(q,Q),fe=!1,pe=0,de=0,ve=0;ve<M.length;++ve){var Fe=g(M,ve);if(Fe<0){M.charAt(ve)=="-"&&this.signum()==0&&(fe=!0);continue}de=q*de+Fe,++pe>=Q&&(this.dMultiply(ne),this.dAddOffset(de,0),pe=0,de=0)}pe>0&&(this.dMultiply(Math.pow(q,pe)),this.dAddOffset(de,0)),fe&&a.ZERO.subTo(this,this)}function Te(M,q,Q){if(typeof q=="number")if(M<2)this.fromInt(1);else for(this.fromNumber(M,Q),this.testBit(M-1)||this.bitwiseTo(a.ONE.shiftLeft(M-1),or,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(q);)this.dAddOffset(2,0),this.bitLength()>M&&this.subTo(a.ONE.shiftLeft(M-1),this);else{var ne=new Array,fe=M&7;ne.length=(M>>3)+1,q.nextBytes(ne),fe>0?ne[0]&=(1<<fe)-1:ne[0]=0,this.fromString(ne,256)}}function Be(){var M=this.t,q=new Array;q[0]=this.s;var Q=this.DB-M*this.DB%8,ne,fe=0;if(M-- >0)for(Q<this.DB&&(ne=this[M]>>Q)!=(this.s&this.DM)>>Q&&(q[fe++]=ne|this.s<<this.DB-Q);M>=0;)Q<8?(ne=(this[M]&(1<<Q)-1)<<8-Q,ne|=this[--M]>>(Q+=this.DB-8)):(ne=this[M]>>(Q-=8)&255,Q<=0&&(Q+=this.DB,--M)),ne&128&&(ne|=-256),fe==0&&(this.s&128)!=(ne&128)&&++fe,(fe>0||ne!=this.s)&&(q[fe++]=ne);return q}function kt(M){return this.compareTo(M)==0}function Lt(M){return this.compareTo(M)<0?this:M}function Ut(M){return this.compareTo(M)>0?this:M}function Tt(M,q,Q){var ne,fe,pe=Math.min(M.t,this.t);for(ne=0;ne<pe;++ne)Q[ne]=q(this[ne],M[ne]);if(M.t<this.t){for(fe=M.s&this.DM,ne=pe;ne<this.t;++ne)Q[ne]=q(this[ne],fe);Q.t=this.t}else{for(fe=this.s&this.DM,ne=pe;ne<M.t;++ne)Q[ne]=q(fe,M[ne]);Q.t=M.t}Q.s=q(this.s,M.s),Q.clamp()}function qt(M,q){return M&q}function ri(M){var q=o();return this.bitwiseTo(M,qt,q),q}function or(M,q){return M|q}function Jr(M){var q=o();return this.bitwiseTo(M,or,q),q}function en(M,q){return M^q}function ni(M){var q=o();return this.bitwiseTo(M,en,q),q}function kr(M,q){return M&~q}function ii(M){var q=o();return this.bitwiseTo(M,kr,q),q}function tn(){for(var M=o(),q=0;q<this.t;++q)M[q]=this.DM&~this[q];return M.t=this.t,M.s=~this.s,M}function oi(M){var q=o();return M<0?this.rShiftTo(-M,q):this.lShiftTo(M,q),q}function rn(M){var q=o();return M<0?this.lShiftTo(-M,q):this.rShiftTo(M,q),q}function ai(M){if(M==0)return-1;var q=0;return M&65535||(M>>=16,q+=16),M&255||(M>>=8,q+=8),M&15||(M>>=4,q+=4),M&3||(M>>=2,q+=2),M&1||++q,q}function si(){for(var M=0;M<this.t;++M)if(this[M]!=0)return M*this.DB+ai(this[M]);return this.s<0?this.t*this.DB:-1}function li(M){for(var q=0;M!=0;)M&=M-1,++q;return q}function nn(){for(var M=0,q=this.s&this.DM,Q=0;Q<this.t;++Q)M+=li(this[Q]^q);return M}function ui(M){var q=Math.floor(M/this.DB);return q>=this.t?this.s!=0:(this[q]&1<<M%this.DB)!=0}function ci(M,q){var Q=a.ONE.shiftLeft(M);return this.bitwiseTo(Q,q,Q),Q}function on(M){return this.changeBit(M,or)}function fi(M){return this.changeBit(M,kr)}function an(M){return this.changeBit(M,en)}function Ge(M,q){for(var Q=0,ne=0,fe=Math.min(M.t,this.t);Q<fe;)ne+=this[Q]+M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;if(M.t<this.t){for(ne+=M.s;Q<this.t;)ne+=this[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne+=this.s}else{for(ne+=this.s;Q<M.t;)ne+=M[Q],q[Q++]=ne&this.DM,ne>>=this.DB;ne+=M.s}q.s=ne<0?-1:0,ne>0?q[Q++]=ne:ne<-1&&(q[Q++]=this.DV+ne),q.t=Q,q.clamp()}function dt(M){var q=o();return this.addTo(M,q),q}function sn(M){var q=o();return this.subTo(M,q),q}function hi(M){var q=o();return this.multiplyTo(M,q),q}function G0(){var M=o();return this.squareTo(M),M}function Q0(M){var q=o();return this.divRemTo(M,q,null),q}function Y0(M){var q=o();return this.divRemTo(M,null,q),q}function X0(M){var q=o(),Q=o();return this.divRemTo(M,q,Q),new Array(q,Q)}function Z0(M){this[this.t]=this.am(0,M-1,this,0,0,this.t),++this.t,this.clamp()}function J0(M,q){if(M!=0){for(;this.t<=q;)this[this.t++]=0;for(this[q]+=M;this[q]>=this.DV;)this[q]-=this.DV,++q>=this.t&&(this[this.t++]=0),++this[q]}}function Tr(){}function wa(M){return M}function ec(M,q,Q){M.multiplyTo(q,Q)}function tc(M,q){M.squareTo(q)}Tr.prototype.convert=wa,Tr.prototype.revert=wa,Tr.prototype.mulTo=ec,Tr.prototype.sqrTo=tc;function rc(M){return this.exp(M,new Tr)}function nc(M,q,Q){var ne=Math.min(this.t+M.t,q);for(Q.s=0,Q.t=ne;ne>0;)Q[--ne]=0;var fe;for(fe=Q.t-this.t;ne<fe;++ne)Q[ne+this.t]=this.am(0,M[ne],Q,ne,0,this.t);for(fe=Math.min(M.t,q);ne<fe;++ne)this.am(0,M[ne],Q,ne,0,q-ne);Q.clamp()}function ic(M,q,Q){--q;var ne=Q.t=this.t+M.t-q;for(Q.s=0;--ne>=0;)Q[ne]=0;for(ne=Math.max(q-this.t,0);ne<M.t;++ne)Q[this.t+ne-q]=this.am(q-ne,M[ne],Q,0,0,this.t+ne-q);Q.clamp(),Q.drShiftTo(1,Q)}function __$t__(M){this.r2=o(),this.q3=o(),a.ONE.dlShiftTo(2*M.t,this.r2),this.mu=this.r2.divide(M),this.m=M}function oc(M){if(M.s<0||M.t>2*this.m.t)return M.mod(this.m);if(M.compareTo(this.m)<0)return M;var q=o();return M.copyTo(q),this.reduce(q),q}function ac(M){return M}function sc(M){for(M.drShiftTo(this.m.t-1,this.r2),M.t>this.m.t+1&&(M.t=this.m.t+1,M.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);M.compareTo(this.r2)<0;)M.dAddOffset(1,this.m.t+1);for(M.subTo(this.r2,M);M.compareTo(this.m)>=0;)M.subTo(this.m,M)}function lc(M,q){M.squareTo(q),this.reduce(q)}function uc(M,q,Q){M.multiplyTo(q,Q),this.reduce(Q)}__$t__.prototype.convert=oc,__$t__.prototype.revert=ac,__$t__.prototype.reduce=sc,__$t__.prototype.mulTo=uc,__$t__.prototype.sqrTo=lc;function cc(M,q){var Q=M.bitLength(),ne,fe=w(1),pe;if(Q<=0)return fe;Q<18?ne=1:Q<48?ne=3:Q<144?ne=4:Q<768?ne=5:ne=6,Q<8?pe=new O(q):q.isEven()?pe=new __$t__(q):pe=new b(q);var de=new Array,ve=3,Fe=ne-1,Ue=(1<<ne)-1;if(de[1]=pe.convert(this),ne>1){var it=o();for(pe.sqrTo(de[1],it);ve<=Ue;)de[ve]=o(),pe.mulTo(it,de[ve-2],de[ve]),ve+=2}var tt=M.t-1,Et,un=!0,ut=o(),ct;for(Q=E(M[tt])-1;tt>=0;){for(Q>=Fe?Et=M[tt]>>Q-Fe&Ue:(Et=(M[tt]&(1<<Q+1)-1)<<Fe-Q,tt>0&&(Et|=M[tt-1]>>this.DB+Q-Fe)),ve=ne;!(Et&1);)Et>>=1,--ve;if((Q-=ve)<0&&(Q+=this.DB,--tt),un)de[Et].copyTo(fe),un=!1;else{for(;ve>1;)pe.sqrTo(fe,ut),pe.sqrTo(ut,fe),ve-=2;ve>0?pe.sqrTo(fe,ut):(ct=fe,fe=ut,ut=ct),pe.mulTo(ut,de[Et],fe)}for(;tt>=0&&!(M[tt]&1<<Q);)pe.sqrTo(fe,ut),ct=fe,fe=ut,ut=ct,--Q<0&&(Q=this.DB-1,--tt)}return pe.revert(fe)}function fc(M){var q=this.s<0?this.negate():this.clone(),Q=M.s<0?M.negate():M.clone();if(q.compareTo(Q)<0){var ne=q;q=Q,Q=ne}var fe=q.getLowestSetBit(),pe=Q.getLowestSetBit();if(pe<0)return q;for(fe<pe&&(pe=fe),pe>0&&(q.rShiftTo(pe,q),Q.rShiftTo(pe,Q));q.signum()>0;)(fe=q.getLowestSetBit())>0&&q.rShiftTo(fe,q),(fe=Q.getLowestSetBit())>0&&Q.rShiftTo(fe,Q),q.compareTo(Q)>=0?(q.subTo(Q,q),q.rShiftTo(1,q)):(Q.subTo(q,Q),Q.rShiftTo(1,Q));return pe>0&&Q.lShiftTo(pe,Q),Q}function hc(M){if(M<=0)return 0;var q=this.DV%M,Q=this.s<0?M-1:0;if(this.t>0)if(q==0)Q=this[0]%M;else for(var ne=this.t-1;ne>=0;--ne)Q=(q*Q+this[ne])%M;return Q}function pc(M){var q=M.isEven();if(this.isEven()&&q||M.signum()==0)return a.ZERO;for(var Q=M.clone(),ne=this.clone(),fe=w(1),pe=w(0),de=w(0),ve=w(1);Q.signum()!=0;){for(;Q.isEven();)Q.rShiftTo(1,Q),q?((!fe.isEven()||!pe.isEven())&&(fe.addTo(this,fe),pe.subTo(M,pe)),fe.rShiftTo(1,fe)):pe.isEven()||pe.subTo(M,pe),pe.rShiftTo(1,pe);for(;ne.isEven();)ne.rShiftTo(1,ne),q?((!de.isEven()||!ve.isEven())&&(de.addTo(this,de),ve.subTo(M,ve)),de.rShiftTo(1,de)):ve.isEven()||ve.subTo(M,ve),ve.rShiftTo(1,ve);Q.compareTo(ne)>=0?(Q.subTo(ne,Q),q&&fe.subTo(de,fe),pe.subTo(ve,pe)):(ne.subTo(Q,ne),q&&de.subTo(fe,de),ve.subTo(pe,ve))}if(ne.compareTo(a.ONE)!=0)return a.ZERO;if(ve.compareTo(M)>=0)return ve.subtract(M);if(ve.signum()<0)ve.addTo(M,ve);else return ve;return ve.signum()<0?ve.add(M):ve}var Qe=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],dc=(1<<26)/Qe[Qe.length-1];function mc(M){var q,Q=this.abs();if(Q.t==1&&Q[0]<=Qe[Qe.length-1]){for(q=0;q<Qe.length;++q)if(Q[0]==Qe[q])return!0;return!1}if(Q.isEven())return!1;for(q=1;q<Qe.length;){for(var ne=Qe[q],fe=q+1;fe<Qe.length&&ne<dc;)ne*=Qe[fe++];for(ne=Q.modInt(ne);q<fe;)if(ne%Qe[q++]==0)return!1}return Q.millerRabin(M)}function vc(M){var q=this.subtract(a.ONE),Q=q.getLowestSetBit();if(Q<=0)return!1;var ne=q.shiftRight(Q);M=M+1>>1,M>Qe.length&&(M=Qe.length);for(var fe=o(),pe=0;pe<M;++pe){fe.fromInt(Qe[Math.floor(Math.random()*Qe.length)]);var de=fe.modPow(ne,this);if(de.compareTo(a.ONE)!=0&&de.compareTo(q)!=0){for(var ve=1;ve++<Q&&de.compareTo(q)!=0;)if(de=de.modPowInt(2,this),de.compareTo(a.ONE)==0)return!1;if(de.compareTo(q)!=0)return!1}}return!0}a.prototype.chunkSize=ce,a.prototype.toRadix=ge,a.prototype.fromRadix=Ce,a.prototype.fromNumber=Te,a.prototype.bitwiseTo=Tt,a.prototype.changeBit=ci,a.prototype.addTo=Ge,a.prototype.dMultiply=Z0,a.prototype.dAddOffset=J0,a.prototype.multiplyLowerTo=nc,a.prototype.multiplyUpperTo=ic,a.prototype.modInt=hc,a.prototype.millerRabin=vc,a.prototype.clone=B,a.prototype.intValue=Y,a.prototype.byteValue=ie,a.prototype.shortValue=ue,a.prototype.signum=me,a.prototype.toByteArray=Be,a.prototype.equals=kt,a.prototype.min=Lt,a.prototype.max=Ut,a.prototype.and=ri,a.prototype.or=Jr,a.prototype.xor=ni,a.prototype.andNot=ii,a.prototype.not=tn,a.prototype.shiftLeft=oi,a.prototype.shiftRight=rn,a.prototype.getLowestSetBit=si,a.prototype.bitCount=nn,a.prototype.testBit=ui,a.prototype.setBit=on,a.prototype.clearBit=fi,a.prototype.flipBit=an,a.prototype.add=dt,a.prototype.subtract=sn,a.prototype.multiply=hi,a.prototype.divide=Q0,a.prototype.remainder=Y0,a.prototype.divideAndRemainder=X0,a.prototype.modPow=cc,a.prototype.modInverse=pc,a.prototype.pow=rc,a.prototype.gcd=fc,a.prototype.isProbablePrime=mc,a.prototype.square=G0,a.prototype.Barrett=__$t__;var ln,et,Le;function yc(M){et[Le++]^=M&255,et[Le++]^=M>>8&255,et[Le++]^=M>>16&255,et[Le++]^=M>>24&255,Le>=di&&(Le-=di)}function _a(){yc(new Date().getTime())}if(et==null){et=new Array,Le=0;var lt;if(typeof window!="undefined"&&window.crypto){if(window.crypto.getRandomValues){var Ea=new Uint8Array(32);for(window.crypto.getRandomValues(Ea),lt=0;lt<32;++lt)et[Le++]=Ea[lt]}else if(navigator.appName=="Netscape"&&navigator.appVersion<"5"){var Aa=window.crypto.random(32);for(lt=0;lt<Aa.length;++lt)et[Le++]=Aa.charCodeAt(lt)&255}}for(;Le<di;)lt=Math.floor(65536*Math.random()),et[Le++]=lt>>>8,et[Le++]=lt&255;Le=0,_a()}function gc(){if(ln==null){for(_a(),ln=_c(),ln.init(et),Le=0;Le<et.length;++Le)et[Le]=0;Le=0}return ln.next()}function xc(M){var q;for(q=0;q<M.length;++q)M[q]=gc()}function Ca(){}Ca.prototype.nextBytes=xc;function pi(){this.i=0,this.j=0,this.S=new Array}function bc(M){var q,Q,ne;for(q=0;q<256;++q)this.S[q]=q;for(Q=0,q=0;q<256;++q)Q=Q+this.S[q]+M[q%M.length]&255,ne=this.S[q],this.S[q]=this.S[Q],this.S[Q]=ne;this.i=0,this.j=0}function wc(){var M;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,M=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=M,this.S[M+this.S[this.i]&255]}pi.prototype.init=bc,pi.prototype.next=wc;function _c(){return new pi}var di=256;e.exports={default:a,BigInteger:a,SecureRandom:Ca}}).call(xe)})(n0);var ke=n0.exports,gm=ke.BigInteger.prototype.Barrett;function Ye(e,r){this.x=r,this.q=e}function Xe(e,r,t,n){this.curve=e,this.x=r,this.y=t,this.z=n==null?ke.BigInteger.ONE:n,this.zinv=null}function gt(e,r,t){this.q=e,this.a=this.fromBigInteger(r),this.b=this.fromBigInteger(t),this.infinity=new Xe(this,null,null),this.reducer=new gm(this.q)}Ye.prototype.equals=function(e){return e==this||this.q.equals(e.q)&&this.x.equals(e.x)},Ye.prototype.toBigInteger=function(){return this.x},Ye.prototype.negate=function(){return new Ye(this.q,this.x.negate().mod(this.q))},Ye.prototype.add=function(e){return new Ye(this.q,this.x.add(e.toBigInteger()).mod(this.q))},Ye.prototype.subtract=function(e){return new Ye(this.q,this.x.subtract(e.toBigInteger()).mod(this.q))},Ye.prototype.multiply=function(e){return new Ye(this.q,this.x.multiply(e.toBigInteger()).mod(this.q))},Ye.prototype.square=function(){return new Ye(this.q,this.x.square().mod(this.q))},Ye.prototype.divide=function(e){return new Ye(this.q,this.x.multiply(e.toBigInteger().modInverse(this.q)).mod(this.q))},Xe.prototype.getX=function(){this.zinv==null&&(this.zinv=this.z.modInverse(this.curve.q));var e=this.x.toBigInteger().multiply(this.zinv);return this.curve.reduce(e),this.curve.fromBigInteger(e)},Xe.prototype.getY=function(){this.zinv==null&&(this.zinv=this.z.modInverse(this.curve.q));var e=this.y.toBigInteger().multiply(this.zinv);return this.curve.reduce(e),this.curve.fromBigInteger(e)},Xe.prototype.equals=function(e){return e==this||(this.isInfinity()?e.isInfinity():e.isInfinity()?this.isInfinity():!!e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q).equals(ke.BigInteger.ZERO)&&e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q).equals(ke.BigInteger.ZERO))},Xe.prototype.isInfinity=function(){return this.x==null&&this.y==null||this.z.equals(ke.BigInteger.ZERO)&&!this.y.toBigInteger().equals(ke.BigInteger.ZERO)},Xe.prototype.negate=function(){return new Xe(this.curve,this.x,this.y.negate(),this.z)},Xe.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var r=e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q),t=e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q);if(ke.BigInteger.ZERO.equals(t))return ke.BigInteger.ZERO.equals(r)?this.twice():this.curve.getInfinity();var n=new ke.BigInteger("3"),l=this.x.toBigInteger(),a=this.y.toBigInteger(),o=(e.x.toBigInteger(),e.y.toBigInteger(),t.square()),u=o.multiply(t),p=l.multiply(o),s=r.square().multiply(this.z),i=s.subtract(p.shiftLeft(1)).multiply(e.z).subtract(u).multiply(t).mod(this.curve.q),d=p.multiply(n).multiply(r).subtract(a.multiply(u)).subtract(s.multiply(r)).multiply(e.z).add(r.multiply(u)).mod(this.curve.q),c=u.multiply(this.z).multiply(e.z).mod(this.curve.q);return new Xe(this.curve,this.curve.fromBigInteger(i),this.curve.fromBigInteger(d),c)},Xe.prototype.twice=function(){if(this.isInfinity())return this;if(this.y.toBigInteger().signum()==0)return this.curve.getInfinity();var e=new ke.BigInteger("3"),r=this.x.toBigInteger(),t=this.y.toBigInteger(),n=t.multiply(this.z),l=n.multiply(t).mod(this.curve.q),a=this.curve.a.toBigInteger(),o=r.square().multiply(e);ke.BigInteger.ZERO.equals(a)||(o=o.add(this.z.square().multiply(a)));var u=(o=o.mod(this.curve.q)).square().subtract(r.shiftLeft(3).multiply(l)).shiftLeft(1).multiply(n).mod(this.curve.q),p=o.multiply(e).multiply(r).subtract(l.shiftLeft(1)).shiftLeft(2).multiply(l).subtract(o.square().multiply(o)).mod(this.curve.q),s=n.square().multiply(n).shiftLeft(3).mod(this.curve.q);return new Xe(this.curve,this.curve.fromBigInteger(u),this.curve.fromBigInteger(p),s)},Xe.prototype.multiply=function(e){if(this.isInfinity())return this;if(e.signum()==0)return this.curve.getInfinity();var r,t=e,n=t.multiply(new ke.BigInteger("3")),l=this.negate(),a=this;for(r=n.bitLength()-2;r>0;--r){a=a.twice();var o=n.testBit(r);o!=t.testBit(r)&&(a=a.add(o?this:l))}return a},Xe.prototype.multiplyTwo=function(e,r,t){var n;n=e.bitLength()>t.bitLength()?e.bitLength()-1:t.bitLength()-1;for(var l=this.curve.getInfinity(),a=this.add(r);n>=0;)l=l.twice(),e.testBit(n)?l=t.testBit(n)?l.add(a):l.add(this):t.testBit(n)&&(l=l.add(r)),--n;return l},gt.prototype.getQ=function(){return this.q},gt.prototype.getA=function(){return this.a},gt.prototype.getB=function(){return this.b},gt.prototype.equals=function(e){return e==this||this.q.equals(e.q)&&this.a.equals(e.a)&&this.b.equals(e.b)},gt.prototype.getInfinity=function(){return this.infinity},gt.prototype.fromBigInteger=function(e){return new Ye(this.q,e)},gt.prototype.reduce=function(e){this.reducer.reduce(e)},gt.prototype.decodePointHex=function(e){switch(parseInt(e.substr(0,2),16)){case 0:return this.infinity;case 2:case 3:return null;case 4:case 6:case 7:var r=(e.length-2)/2,t=e.substr(2,r),n=e.substr(r+2,r);return new Xe(this,this.fromBigInteger(new ke.BigInteger(t,16)),this.fromBigInteger(new ke.BigInteger(n,16)));default:return null}},gt.prototype.encodePointHex=function(e){if(e.isInfinity())return"00";var r=e.getX().toBigInteger().toString(16),t=e.getY().toBigInteger().toString(16),n=this.getQ().toString(16).length;for(n%2!=0&&n++;r.length<n;)r="0"+r;for(;t.length<n;)t="0"+t;return"04"+r+t};var qe=function(e,r){return e<<(r%=32)|e>>>32-r},yt=function(e,r){var t=r-e.length;return(t>0?"0".repeat(t):"")+e},xm=function(e){return e<16?2043430169:2055708042},bm=function(e,r,t,n){return n<16?e^r^t:e&r|e&t|r&t},wm=function(e,r,t,n){return n<16?e^r^t:e&r|~e&t},_m=function(e,r,t){for(var n,l,a,o,u,p=function(x){var y,w=new Array(132);x.forEach(function(I,D){w[D]=I});for(var k=16;k<68;k++)w[k]=(y=w[k-16]^w[k-9]^qe(w[k-3],15))^qe(y,15)^qe(y,23)^qe(w[k-13],7)^w[k-6];for(var T=0;T<64;T++)w[T+68]=w[T]^w[T+4];return w}(r),s=e[0],i=e[1],d=e[2],c=e[3],f=e[4],h=e[5],v=e[6],m=e[7],g=0;g<64;g++)l=(n=qe(qe(s,12)+f+qe(xm(g),g),7))^qe(s,12),a=bm(s,i,d,g)+c+l+p[g+68],o=wm(f,h,v,g)+m+n+p[g],c=d,d=qe(i,9),i=s,s=a,m=v,v=qe(h,19),h=f,f=(u=o)^qe(u,9)^qe(u,17);return[s^e[0],i^e[1],d^e[2],c^e[3],f^e[4],h^e[5],v^e[6],m^e[7]]},Vo=function(e,r,t){if(typeof e=="string"?e=we.Buffer.from(e,r||"utf8"):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');var n,l,a,o,u,p;n=e,l=we.Buffer.alloc(1,128),o=we.Buffer.alloc(a=(a=n.length%64)>=56?64-a%56-1:56-a-1,0),u=we.Buffer.alloc(8),p=8*n.length,u.writeUInt32BE(Math.floor(p/Math.pow(2,32)),0),u.writeUInt32BE(p%Math.pow(2,32),4);for(var s=(e=we.Buffer.concat([n,l,o,u],n.length+1+a+8)).length/64,i=new Array(s),d=0;d<s;d++){i[d]=new Array(16);for(var c=0;c<16;c++)i[d][c]=e.readUInt32BE(64*d+4*c)}var f=new Array(s);f[0]=[1937774191,1226093241,388252375,3666478592,2842636476,372324522,3817729613,2969243214];for(var h=0;h<s;h++)f[h+1]=_m(f[h],i[h]);var v=we.Buffer.alloc(32);return f[s].forEach(function(m,g){return v.writeInt32BE(m,4*g)}),t?v.toString(t):$r(v)},ll=new ke.SecureRandom,da=function(){var e=new gt(new ke.BigInteger("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFF",16),new ke.BigInteger("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000FFFFFFFFFFFFFFFC",16),new ke.BigInteger("28E9FA9E9D9F5E344D5A9E4BCF6509A7F39789F515AB8F92DDBCBD414D940E93",16)),r=e.decodePointHex("0432C4AE2C1F1981195F9904466A39C9948FE30BBFF2660BE1715A4589334C74C7BC3736A2F4F6779C59BDCEE36B692153D0A9877CC62A474002DF32E52139F0A0");return{curve:e,G:r,n:new ke.BigInteger("FFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFF7203DF6B21C6052B53BBF40939D54123",16)}}(),ul=da.curve,cl=da.G,vn=da.n;function fl(e,r){for(var t=[],n=Math.ceil(r/32),l=r%32,a=1;a<=n;a++){var o=we.Buffer.allocUnsafe(4);o.writeUInt32BE(a);var u=Vo(we.Buffer.concat([e,o]));t.push(a===n&&l?we.Buffer.from(u).slice(0,l):we.Buffer.from(u))}return we.Buffer.concat(t,r)}var Em={__proto__:null,constants:{C1C2C3:0,C1C3C2:1,PC:"04"},generateKeyPair:function(){var e=new ke.BigInteger(vn.bitLength(),ll).mod(vn.subtract(new ke.BigInteger("2"))).add(ke.BigInteger.ONE),r=yt(e.toString(16),64),t=cl.multiply(e);return{privateKey:r,publicKey:"04"+yt(t.getX().toBigInteger().toString(16),64)+yt(t.getY().toBigInteger().toString(16),64)}},encrypt:function(e,r,t){var n=t||{},l=n.mode,a=l===void 0?1:l,o=n.outputEncoding,u=n.pc;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding||"utf8"):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');var p=new ke.BigInteger(vn.bitLength(),ll).mod(vn.subtract(ke.BigInteger.ONE)).add(ke.BigInteger.ONE),s=cl.multiply(p),i=yt(s.getX().toBigInteger().toString(16),64)+yt(s.getY().toBigInteger().toString(16),64),d=ul.decodePointHex(r).multiply(p),c=yt(d.getX().toBigInteger().toString(16),64),f=yt(d.getY().toBigInteger().toString(16),64),h=fl(we.Buffer.from(c+f,"hex"),e.length),v=yt(new ke.BigInteger(e.toString("hex"),16).xor(new ke.BigInteger(h.toString("hex"),16)).toString(16),2*e.length),m=Vo(c+e.toString("hex")+f,"hex","hex"),g=we.Buffer.from((u?"04":"")+(a===0?i+v+m:i+m+v),"hex");return o?g.toString(o):$r(g)},decrypt:function(e,r,t){var n=t||{},l=n.mode,a=l===void 0?1:l,o=n.outputEncoding,u=n.pc;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');var p=(e=u?e.slice(1):e).slice(0,32).toString("hex"),s=e.slice(32,64).toString("hex"),i=ul.decodePointHex("04"+p+s).multiply(new ke.BigInteger(r,16)),d=yt(i.getX().toBigInteger().toString(16),64),c=yt(i.getY().toBigInteger().toString(16),64),f=e.slice(64,96),h=e.slice(96);a===0&&(f=e.slice(e.length-32),h=e.slice(64,e.length-32));var v=fl(we.Buffer.from(d+c,"hex"),h.length),m=new ke.BigInteger(h.toString("hex"),16).xor(new ke.BigInteger(v.toString("hex"),16)).toString(16),g=Vo(d+m+c,"hex","hex")===f.toString("hex")?we.Buffer.from(m,"hex"):we.Buffer.alloc(0);return o?g.toString(o):$r(g)}},yn=[[214,144,233,254,204,225,61,183,22,182,20,194,40,251,44,5],[43,103,154,118,42,190,4,195,170,68,19,38,73,134,6,153],[156,66,80,244,145,239,152,122,51,84,11,67,237,207,172,98],[228,179,28,169,201,8,232,149,128,223,148,250,117,143,63,166],[71,7,167,252,243,115,23,186,131,89,60,25,230,133,79,168],[104,107,129,178,113,100,218,139,248,235,15,75,112,86,157,53],[30,36,14,94,99,88,209,162,37,34,124,59,1,33,120,135],[212,0,70,87,159,211,39,82,76,54,2,231,160,196,200,158],[234,191,138,210,64,199,56,181,163,247,242,206,249,97,21,161],[224,174,93,164,155,52,26,85,173,147,50,48,245,140,177,227],[29,246,226,46,130,102,202,96,192,41,35,171,13,83,78,111],[213,219,55,69,222,253,142,47,3,255,106,114,109,108,91,81],[141,27,175,146,187,221,188,127,17,217,92,65,31,16,90,216],[10,193,49,136,165,205,123,189,45,116,208,18,184,229,180,176],[137,105,151,74,12,150,119,126,101,185,241,9,197,110,198,132],[24,240,125,236,58,220,77,32,121,238,95,62,215,203,57,72]],gn=[2746333894,1453994832,1736282519,2993693404],Am=[462357,472066609,943670861,1415275113,1886879365,2358483617,2830087869,3301692121,3773296373,4228057617,404694573,876298825,1347903077,1819507329,2291111581,2762715833,3234320085,3705924337,4177462797,337322537,808926789,1280531041,1752135293,2223739545,2695343797,3166948049,3638552301,4110090761,269950501,741554753,1213159005,1684763257],xn=/^[0-9a-f]{32}$/i,i0=function(e){return yn[(4026531840&e)>>>28][(251658240&e)>>>24]<<24|yn[(15728640&e)>>>20][(983040&e)>>>16]<<16|yn[(61440&e)>>>12][(3840&e)>>>8]<<8|yn[(240&e)>>>4][(15&e)>>>0]<<0},o0=function(e){return(r=i0(e))^qe(r,2)^qe(r,10)^qe(r,18)^qe(r,24);var r},a0=function(e){var r,t=new Array(36);t[0]=e[0]^gn[0],t[1]=e[1]^gn[1],t[2]=e[2]^gn[2],t[3]=e[3]^gn[3];for(var n=new Array(32),l=0;l<32;l++)t[l+4]=t[l]^(r=i0(t[l+1]^t[l+2]^t[l+3]^Am[l]))^qe(r,13)^qe(r,23),n[l]=t[l+4];return n},hl=function(e,r){for(var t=a0(r),n=0;n<32;n++)e[n+4]=e[n]^o0(e[n+1]^e[n+2]^e[n+3]^t[n]);return[e[35],e[34],e[33],e[32]]},pl=function(e,r){for(var t=a0(r).reverse(),n=0;n<32;n++)e[n+4]=e[n]^o0(e[n+1]^e[n+2]^e[n+3]^t[n]);return[e[35],e[34],e[33],e[32]]},bn=function(e){return[e.readInt32BE(0),e.readInt32BE(4),e.readInt32BE(8),e.readInt32BE(12)]},wn=function(e){for(var r=we.Buffer.alloc(16),t=0;t<4;t++)r.writeInt32BE(e[t],4*t);return r},wr={__proto__:null,constants:{ECB:1,CBC:2},encrypt:function(e,r,t){var n=t||{},l=n.mode,a=n.iv,o=n.outputEncoding;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding||"utf8"):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');if(!xn.test(r))throw new TypeError("Invalid value of cipher `key`");if(r=we.Buffer.from(r,"hex"),l===2&&!xn.test(a))throw new TypeError("Invalid value of `iv` option");return function(u,p,s,i){s&&(s=bn(s)),p=bn(p);for(var d=[],c=(u=function(k){var T=16-k.length%16,I=we.Buffer.alloc(T,T);return we.Buffer.concat([k,I],k.length+T)}(u)).length/16,f=0;f<c;f++)if(s){var h=16*f,v=[s[0]^u.readInt32BE(h),s[1]^u.readInt32BE(h+4),s[2]^u.readInt32BE(h+8),s[3]^u.readInt32BE(h+12)],m=hl(v,p);d.push(wn(m)),s=m.slice(0)}else{var g=16*f,x=[u.readInt32BE(g),u.readInt32BE(g+4),u.readInt32BE(g+8),u.readInt32BE(g+12)],y=hl(x,p);d.push(wn(y))}var w=we.Buffer.concat(d,u.length);return i?w.toString(i):$r(w)}(e,r,a=l===2?we.Buffer.from(a,"hex"):null,o)},decrypt:function(e,r,t){var n=t||{},l=n.mode,a=n.iv,o=n.outputEncoding;if(typeof e=="string"?e=we.Buffer.from(e,n.inputEncoding):e instanceof ArrayBuffer&&(e=we.Buffer.from(e)),!we.Buffer.isBuffer(e))throw new TypeError('Expected "string" | "Buffer" | "ArrayBuffer" but received "'+Object.prototype.toString.call(e)+'"');if(!xn.test(r))throw new TypeError("Invalid value of cipher `key`");if(r=we.Buffer.from(r,"hex"),l===2&&!xn.test(a))throw new TypeError("Invalid value of `iv` option");return function(u,p,s,i){s&&(s=bn(s)),p=bn(p);var d=[],c=u.length/16;if(s)for(var f=c-1;f>=0;f--){var h,v=16*f;h=f>0?[u.readInt32BE(v-16),u.readInt32BE(v-16+4),u.readInt32BE(v-16+8),u.readInt32BE(v-16+12)]:s;var m=[u.readInt32BE(v),u.readInt32BE(v+4),u.readInt32BE(v+8),u.readInt32BE(v+12)],g=pl(m,p);d.unshift(wn([g[0]^h[0],g[1]^h[1],g[2]^h[2],g[3]^h[3]]))}else for(var x=0;x<c;x++){var y=16*x,w=[u.readInt32BE(y),u.readInt32BE(y+4),u.readInt32BE(y+8),u.readInt32BE(y+12)],k=pl(w,p);d.push(wn(k))}var T=we.Buffer.concat(d,u.length-d[d.length-1][15]);return i?T.toString(i):$r(T)}(e,r,a=l===2?we.Buffer.from(a,"hex"):null,o)}};(function(){if(typeof Object.id=="undefined"){var e=0;Object.id=function(r){return typeof r.__uniqueid=="undefined"&&Object.defineProperty(r,"__uniqueid",{value:++e,enumerable:!1,writable:!1}),r.__uniqueid}}})();function Cm(){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r=[-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,62,-1,-1,-1,63,52,53,54,55,56,57,58,59,60,61,-1,-1,-1,-1,-1,-1,-1,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1,-1,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,-1,-1,-1,-1,-1];this.encode=function(t){var n,l,a,o,u,p;for(a=t.length,l=0,n="";l<a;){if(o=t.charCodeAt(l++)&255,l==a){n+=e.charAt(o>>2),n+=e.charAt((o&3)<<4),n+="==";break}if(u=t.charCodeAt(l++),l==a){n+=e.charAt(o>>2),n+=e.charAt((o&3)<<4|(u&240)>>4),n+=e.charAt((u&15)<<2),n+="=";break}p=t.charCodeAt(l++),n+=e.charAt(o>>2),n+=e.charAt((o&3)<<4|(u&240)>>4),n+=e.charAt((u&15)<<2|(p&192)>>6),n+=e.charAt(p&63)}return n},this.decode=function(t){var n,l,a,o,u,p,s;for(p=t.length,u=0,s="";u<p;){do n=r[t.charCodeAt(u++)&255];while(u<p&&n==-1);if(n==-1)break;do l=r[t.charCodeAt(u++)&255];while(u<p&&l==-1);if(l==-1)break;s+=String.fromCharCode(n<<2|(l&48)>>4);do{if(a=t.charCodeAt(u++)&255,a==61)return s;a=r[a]}while(u<p&&a==-1);if(a==-1)break;s+=String.fromCharCode((l&15)<<4|(a&60)>>2);do{if(o=t.charCodeAt(u++)&255,o==61)return s;o=r[o]}while(u<p&&o==-1);if(o==-1)break;s+=String.fromCharCode((a&3)<<6|o)}return s},this.utf16to8=function(t){var n,l,a,o;for(n="",a=t.length,l=0;l<a;l++)o=t.charCodeAt(l),o>=1&&o<=127?n+=t.charAt(l):o>2047?(n+=String.fromCharCode(224|o>>12&15),n+=String.fromCharCode(128|o>>6&63),n+=String.fromCharCode(128|o>>0&63)):(n+=String.fromCharCode(192|o>>6&31),n+=String.fromCharCode(128|o>>0&63));return n},this.utf8to16=function(t){var n,l,a,o,u,p;for(n="",a=t.length,l=0;l<a;)switch(o=t.charCodeAt(l++),o>>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:n+=t.charAt(l-1);break;case 12:case 13:u=t.charCodeAt(l++),n+=String.fromCharCode((o&31)<<6|u&63);break;case 14:u=t.charCodeAt(l++),p=t.charCodeAt(l++),n+=String.fromCharCode((o&15)<<12|(u&63)<<6|(p&63)<<0);break}return n},this.charToHex=function(t){var n,l,a;for(n="",l=0;l<t.length;)a=t.charCodeAt(l++).toString(16),n+="\\0x"+a,n+=l>0&&l%8==0?`\r
32
+ `:", ";return n}}function Sm(){var e=0,r=new Object;this.add=function(t,n){this.containsKey(t)||e++,r[t]=n},this.getValue=function(t){return this.containsKey(t)?r[t]:null},this.remove=function(t){this.containsKey(t)&&delete r[t]&&e--},this.containsKey=function(t){return t in r},this.containsValue=function(t){for(var n in r)if(r[n]==t)return!0;return!1},this.getValues=function(){var t=[];for(var n in r)t.push(r[n]);return t},this.getKeys=function(){var t=[];for(var n in r)t.push(n);return t},this.getSize=function(){return e},this.clear=function(){e=0,r=new Object}}function Bm(e){if(this.connect=!1,this.ready_func_=null,this.callbacks_=new Sm,this.module_="JS_IActiveXCtrl","WebSocket"in window)this.ws=new WebSocket("ws://127.0.0.1:7321");else throw"WebSocket not supported";this.ws.onerror=function(){throw"Unable to establish connection to WebSocket"},this.loadModule=function(){this.connect=!0;var r=JSON.stringify({MsgId:"LoadModule",Module:this.module_});this.ws.onmessage=this._callback.bind(this),this.ws.send(r)},this.loadModuleCallBack=function(r){if(!r)throw r.Response;this.ready_func_&&this.ready_func_()}.bind(this),this.callbacks_.add("LoadModule",this.loadModuleCallBack),this.exec=function(r,t,n){var l=Object.id(n).toString();this.callbacks_.add(l,n);var a={MsgId:l,Method:r+"|"+e};t&&(a.Param=JSON.stringify(t));var o=JSON.stringify(a);this.connect&&this.ws.send(o)},this.ready=function(r){this.ready_func_=r},this._callback=function(r){var t=JSON.parse(r.data),n=t.MsgId;if(this.callbacks_.containsKey(n)){var l=this.callbacks_.getValue(n);l(t.Result,t.Response),this.callbacks_.remove(n)}},this.ws.onopen=this.loadModule.bind(this),this.Arm_GetDongleInfo=function({Index:r,DongleInfoNum:t},n){this.exec("Arm_GetDongleInfo",[parseInt(r),parseInt(t)],n)},this.Arm_Enum=function(r){this.exec("Arm_Enum",null,r)},this.Arm_Open=function({Index:r},t){this.exec("Arm_Open",[parseInt(r)],t)},this.Arm_Close=function({Handle:r},t){this.exec("Arm_Close",[parseInt(r)],t)},this.Arm_VerifyPIN=function({Handle:r,UserPin:t,UserType:n},l){this.exec("Arm_VerifyPIN",[parseInt(r),n,t],l)},this.Arm_ResetState=function({Handle:r},t){this.exec("Arm_ResetState",[parseInt(r)],t)},this.Arm_GenRandom=function({Handle:r,RandomLen:t},n){this.exec("Arm_GenRandom",[parseInt(r),parseInt(t)],n)},this.Arm_LEDControl=function({Handle:r,LedFlag:t},n){this.exec("Arm_LEDControl",[parseInt(r),t],n)},this.Arm_SwitchProtocol=function({Handle:r,ProtocolFlag:t},n){this.exec("Arm_SwitchProtocol",[parseInt(r),t],n)},this.Arm_CreateFile=function({Handle:r,FileID:t,FileType:n,AttrBuffer:l},a){this.exec("Arm_CreateFile",[parseInt(r),n,parseInt(t),l],a)},this.Arm_WriteFile=function({Handle:r,FileID:t,FileType:n,FileOffset:l,DataInput:a},o){this.exec("Arm_WriteFile",[parseInt(r),n,parseInt(t),parseInt(l),a],o)},this.Arm_ReadFile0001=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0001"),parseInt(0),parseInt("64")],t)},this.Arm_ReadFile0002=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0002"),parseInt(0),parseInt("130")],t)},this.Arm_ReadFile0003=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0003"),parseInt(0),parseInt("130")],t)},this.Arm_ReadFile0004=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0004"),parseInt(0),parseInt("2048")],t)},this.Arm_ReadFile0005=function({Handle:r},t){this.exec("Arm_ReadFile",[parseInt(r),parseInt("0005"),parseInt(0),parseInt("2048")],t)},this.Arm_DownloadExeFile=function({Handle:r,Count:t,ExeFileInfo:n},l){this.exec("Arm_DownloadExeFile",[parseInt(r),parseInt(t),n],l)},this.Arm_RunExeFile=function({Handle:r,FileID:t,InData:n,DataLen:l},a){this.exec("Arm_RunExeFile",[parseInt(r),parseInt(t),n,n.length,parseInt(l)],a)},this.Arm_ReadRunExeFileData=function(r){this.exec("Arm_ReadRunExeFileData",null,r)},this.Arm_DeleteFile=function({Handle:r,FileID:t,FileType:n},l){this.exec("Arm_DeleteFile",[parseInt(r),n,parseInt(t)],l)},this.Arm_WriteData=function({Handle:r,Offset:t,DataInput:n},l){this.exec("Arm_WriteData",[parseInt(r),parseInt(t),n],l)},this.Arm_ReadData=function({Handle:r,Offset:t,ReadLength:n},l){this.exec("Arm_ReadData",[parseInt(r),parseInt(t),n],l)},this.Arm_WriteShareMemory=function({Handle:r,DataInput:t},n){this.exec("Arm_WriteShareMemory",[parseInt(r),t],n)},this.Arm_ReadShareMemory=function({Handle:r},t){this.exec("Arm_ReadShareMemory",[parseInt(r)],t)},this.Arm_GenUniqueKey=function({Handle:r,Seed:t},n){this.exec("Arm_GenUniqueKey",[parseInt(r),t.length,t],n)},this.Arm_ChangePIN=function({Handle:r,NewPIN:t,OldPIN:n,TryCount:l,PinFlag:a},o){this.exec("Arm_ChangePIN",[parseInt(r),a,n,t,parseInt(l)],o)},this.Arm_ResetUserPIN=function({Handle:r,AdminPIN:t},n){this.exec("Arm_ResetUserPIN",[parseInt(r),t],n)},this.Arm_SetUserID=function({Handle:r,UserID:t},n){this.exec("Arm_SetUserID",[parseInt(r),parseInt(t)],n)},this.Arm_GetDeadline=function({Handle:r},t){this.exec("Arm_GetDeadline",[parseInt(r)],t)},this.Arm_SetDeadline=function({Handle:r,SetDeadTime:t},n){this.exec("Arm_SetDeadline",[parseInt(r),parseInt(t)],n)},this.Arm_GetUTCTime=function({Handle:r},t){this.exec("Arm_GetUTCTime",[parseInt(r)],t)},this.Arm_RFS=function({Handle:r},t){this.exec("Arm_RFS",[parseInt(r)],t)},this.Arm_RsaGenPubPriKey=function({Handle:r,RsaFileId:t},n){this.exec("Arm_RsaGenPubPriKey",[parseInt(r),parseInt(t)],n)},this.Arm_EccGenPubPriKey=function({Handle:r,EccFileId:t},n){this.exec("Arm_EccGenPubPriKey",[parseInt(r),parseInt(t)],n)},this.Arm_Sm2GenPubPriKey=function({Handle:r,Sm2FileId:t},n){this.exec("Arm_Sm2GenPubPriKey",[parseInt(r),parseInt(t)],n)},this.Arm_ReadRsaPri=function(r){this.exec("Arm_ReadRsaPri",null,r)},this.Arm_ReadRsaPub=function(r){this.exec("Arm_ReadRsaPub",null,r)},this.Arm_ReadEccPri=function(r){this.exec("Arm_ReadEccPri",null,r)},this.Arm_ReadEccPub=function(r){this.exec("Arm_ReadEccPub",null,r)},this.Arm_ReadSm2Pri=function(r){this.exec("Arm_ReadSm2Pri",null,r)},this.Arm_ReadSm2Pub=function(r){this.exec("Arm_ReadSm2Pub",null,r)},this.Arm_RsaPri=function({Handle:r,RsaPri_Flag:t,RsaPriInData:n,RsaPriFileID:l,RsaPriFileSize:a},o){this.exec("Arm_RsaPri",[parseInt(r),parseInt(l),parseInt(a),t,n],o)},this.Arm_RsaPub=function({Handle:r,RsaPubKey:t,RsaPub_Flag:n,RsaPubInData:l,RsaPubFileSize:a},o){this.exec("Arm_RsaPub",[parseInt(r),parseInt(a),n,t,t.length,l],o)},this.Arm_EccSign=function({Handle:r,HashData:t,EccFileId:n},l){this.exec("Arm_EccSign",[parseInt(r),parseInt(n),t],l)},this.Arm_EccVerify=function({Handle:r,HashData:t,EccPubKey:n,EccSignData:l},a){this.exec("Arm_EccVerify",[parseInt(r),n,n.length,t,l],a)},this.Arm_Sm2Sign=function({Handle:r,HashData:t,Sm2FileId:n},l){this.exec("Arm_Sm2Sign",[parseInt(r),parseInt(n),t],l)},this.Arm_Sm2Verify=function({Handle:r,HashData:t,Sm2PubKey:n,Sm2SignData:l},a){this.exec("Arm_Sm2Verify",[parseInt(r),n,n.length,t,l],a)},this.Arm_TDES=function({Handle:r,Tdes_Flag:t,TdesFileID:n,TdesInData:l},a){this.exec("Arm_TDES",[parseInt(r),parseInt(n),t,l],a)},this.Arm_SM4=function({Handle:r,Sm4_Flag:t,Sm4FileID:n,Sm4InData:l},a){this.exec("Arm_SM4",[parseInt(r),parseInt(n),t,l],a)},this.Arm_HASH=function({Handle:r,Hash_Flag:t,HashInData:n},l){this.exec("Arm_HASH",[parseInt(r),t,n],l)},this.Arm_Seed=function({Handle:r,SeedData:t,SeedLength:n},l){this.exec("Arm_Seed",[parseInt(r),n,t],l)},this.Arm_LimitSeedCount=function({Handle:r,SeedCount:t},n){this.exec("Arm_LimitSeedCount",[parseInt(r),parseInt(t)],n)},this.Arm_GenMotherKey=function({Handle:r,SeedLen:t,SeedForPID:n,SonCount:l,StartUserID:a,AdminTryCount:o,UserPin:u,UserTryCount:p,UpdateRSAPriKey:s},i){this.exec("Arm_GenMotherKey",[parseInt(r),parseInt(t),n,u,parseInt(p),parseInt(o),s,parseInt(a),parseInt(l)],i)},this.Arm_RequestInit=function({Handle:r},t){this.exec("Arm_RequestInit",[parseInt(r)],t)},this.Arm_GetInitDataFromMother=function({Handle:r},t){this.exec("Arm_GetInitDataFromMother",[parseInt(r),Request],t)},this.Arm_InitSon=function({Handle:r,InitData:t},n){this.exec("Arm_InitSon",[parseInt(r),t],n)},this.Arm_SetUpdatePriKey=function({Handle:r,UpdatePriKey:t},n){this.exec("Arm_SetUpdatePriKey",[parseInt(r),t],n)},this.Arm_MakeUpdatePacket=function({Handle:r,HID:t,Func:n,FileID:l,FileType:a,Offset:o,DataLen:u,DataBuffer:p,UpRSAPubKey:s},i){this.exec("Arm_MakeUpdatePacket",[parseInt(r),t,n,a,parseInt(l),parseInt(o),p,s,parseInt(u)],i)},this.Arm_MakeUpdatePacketFromMother=function({Handle:r,HID:t,Func:n,FileID:l,FileType:a,Offset:o,DataLen:u,DataBuffer:p},s){this.exec("Arm_MakeUpdatePacketFromMother",[parseInt(r),t,n,a,parseInt(l),parseInt(o),p,parseInt(u)],s)},this.Arm_Update=function({Handle:r,UpdateData:t},n){this.exec("Arm_Update",[parseInt(r),t],n)},this.Arm_Set_DATA_FILE_ATTR=function({Size:r,ReadPriv:t,WritePriv:n},l){this.exec("Arm_Set_DATA_FILE_ATTR",[parseInt(r),parseInt(t),parseInt(n)],l)},this.Arm_Set_PRIKEY_FILE_ATTR=function({Count:r,Size:t,Type:n,Priv:l,IsReset:a,IsDecOnRAM:o},u){this.exec("Arm_Set_PRIKEY_FILE_ATTR",[n,parseInt(t),parseInt(r),parseInt(l),parseInt(o),parseInt(a)],u)},this.Arm_Set_KEY_FILE_ATTR=function({Size:r,PrivEnc:t},n){this.exec("Arm_Set_KEY_FILE_ATTR",[parseInt(r),parseInt(t)],n)},this.Arm_Set_EXE_FILE_ATTR=function({FileLen:r,PrivExe:t},n){this.exec("Arm_Set_EXE_FILE_ATTR",[parseInt(r),parseInt(t)],n)},this.Arm_Set_DATA_LIC=function({ReadPriv:r,WritePriv:t},n){this.exec("Arm_Set_DATA_LIC",[parseInt(r),parseInt(t)],n)},this.Arm_Set_PRIKEY_LIC=function({Count:r,Priv:t,IsReset:n,IsDecOnRAM:l},a){this.exec("Arm_Set_PRIKEY_LIC",[parseInt(r),parseInt(t),parseInt(l),parseInt(n)],a)},this.Arm_Set_KEY_LIC=function({PrivEnc:r},t){this.exec("Arm_Set_KEY_LIC",[parseInt(r)],t)},this.Arm_Set_EXE_LIC=function({PrivExe:r},t){this.exec("Arm_Set_EXE_LIC",[parseInt(r)],t)},this.Arm_Set_EXE_FILE_INFO=function({FileID:r,FileData:t,FileSize:n,InBuffer:l,CallLimit:a},o){this.exec("Arm_Set_EXE_FILE_INFO",[l,parseInt(n),parseInt(r),parseInt(a),t,t.length],o)},this.Arm_Clear_EXE_FILE_INFO=function({InBuffer:r},t){this.exec("Arm_Clear_EXE_FILE_INFO",[r],t)}}const km={HID:0},_n={PRODUCT_ID:0,USER_ID:1,HARDWARE_ID:2},dl={USER:0};class s0{constructor(){It(this,"Base64",new Cm);It(this,"AtlCtrl",null);It(this,"ArmCount",0);It(this,"ArmIndex",0);It(this,"ArmHandle",0);It(this,"ArmRandom","");try{this.AtlCtrl=new Bm("{39E9B272-82A7-4177-A19D-6723C1BDB0CC}")}catch(r){console.error(r),this.AtlCtrl=null}}armEnum(){if(this.AtlCtrl)return new Promise((r,t)=>{this.AtlCtrl.Arm_Enum((n,l)=>{n?(this.ArmCount=+l,r(l)):t(l)})})}armOpen(r=0){if(this.AtlCtrl)return this.ArmIndex=r,new Promise((t,n)=>{this.AtlCtrl.Arm_Open({Index:r},(l,a)=>{l?(this.ArmHandle=+a,t(a)):(this.ArmHandle=a,n(a))})})}armClose(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_Close({Handle:r},(l,a)=>{l?t(a):n(a)})})}armChangePIN(r,t,n=255,l=dl.USER,a=this.ArmHandle){if(this.AtlCtrl)return new Promise((o,u)=>{this.AtlCtrl.Arm_ChangePIN({Handle:a,NewPIN:r,OldPIN:t,TryCount:n,PinFlag:l},(p,s)=>{p&&s==0?(this.ArmPin=r,o(s)):u(s)})})}armGenRandom(r=16,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_GenRandom({Handle:t,RandomLen:r},(a,o)=>{a?(this.ArmRandom=o,n(o)):l(o)})})}armGetDeadline(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_GetDeadline({Handle:r},(l,a)=>{l?(this.ArmDeadline=a,t(a)):n(a)})})}armGenUniqueKey(r="MTIzNDU2Nzg5MA==",t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_GenUniqueKey({Handle:t,Seed:r},(a,o)=>{a?(this.ArmUKey=o,n(o)):l(o)})})}armGetDongleInfo(r=0,t=_n.HARDWARE_ID){if(this.AtlCtrl)return this.ArmIndex=r,new Promise((n,l)=>{this.AtlCtrl.Arm_GetDongleInfo({Index:r,DongleInfoNum:t},(a,o)=>{if(a){switch(t){case _n.USER_ID:this.ArmUid=o;break;case _n.PRODUCT_ID:this.ArmPid=o;break;case _n.HARDWARE_ID:this.ArmHid=o;break}n(o)}else l(o)})})}armLEDControl(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_LEDControl({Handle:t,LedFlag:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armRFS(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_RFS({Handle:r},(l,a)=>{l&&a==0?t(a):n(a)})})}armReadFile(r="0001",t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl[`Arm_ReadFile${r}`]({Handle:t},(a,o)=>{if(a&&o.length>0)try{o=this.Base64.decode(o),n(o)}catch(u){console.error(u),n(o)}else l(o)})})}armResetState(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_ResetState({Handle:r},(l,a)=>{l&&a==0?t(a):n(a)})})}armResetUserPIN(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_ResetUserPIN({Handle:t,AdminPIN:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armSetUserID(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_SetUserID({Handle:t,UserID:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armSetDeadline(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_SetDeadline({Handle:t,SetDeadTime:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armSwitchProtocol(r=km.HID,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_SwitchProtocol({Handle:t,ProtocolFlag:r},(a,o)=>{a&&o==0?n(o):l(o)})})}armVerifyPIN(r,t=dl.USER,n=this.ArmHandle){if(this.AtlCtrl)return new Promise((l,a)=>{this.AtlCtrl.Arm_VerifyPIN({Handle:n,UserPin:r,UserType:t},(o,u)=>{o&&u==0?(this.ArmPin=r,l(u)):a(u)})})}armReadData(r=0,t=128,n=this.ArmHandle){if(this.AtlCtrl)return new Promise((l,a)=>{this.AtlCtrl.Arm_ReadData({Handle:n,Offset:r,ReadLength:t},(o,u)=>{o?(this.ArmData=u,l(u)):a(u)})})}armWriteData(r,t=0,n=this.ArmHandle){if(this.AtlCtrl)return new Promise((l,a)=>{this.AtlCtrl.Arm_WriteData({Handle:n,Offset:t,DataInput:r},(o,u)=>{o&&u==0?l(u):a(u)})})}armReadShareMemory(r=this.ArmHandle){if(this.AtlCtrl)return new Promise((t,n)=>{this.AtlCtrl.Arm_ReadShareMemory({Handle:r},(l,a)=>{l?(this.ArmData=a,t(a)):n(a)})})}armWriteShareMemory(r,t=this.ArmHandle){if(this.AtlCtrl)return new Promise((n,l)=>{this.AtlCtrl.Arm_WriteShareMemory({Handle:t,DataInput:r},(a,o)=>{a&&o==0?n(o):l(o)})})}}const l0=Symbol(),Dn="el",Tm="is-",jt=(e,r,t,n,l)=>{let a=`${e}-${r}`;return t&&(a+=`-${t}`),n&&(a+=`__${n}`),l&&(a+=`--${l}`),a},u0=Symbol("namespaceContextKey"),Fm=e=>{const r=e||(N.getCurrentInstance()?N.inject(u0,N.ref(Dn)):N.ref(Dn));return N.computed(()=>N.unref(r)||Dn)},Sr=(e,r)=>{const t=Fm(r);return{namespace:t,b:(v="")=>jt(t.value,e,v,"",""),e:v=>v?jt(t.value,e,"",v,""):"",m:v=>v?jt(t.value,e,"","",v):"",be:(v,m)=>v&&m?jt(t.value,e,v,m,""):"",em:(v,m)=>v&&m?jt(t.value,e,"",v,m):"",bm:(v,m)=>v&&m?jt(t.value,e,v,"",m):"",bem:(v,m,g)=>v&&m&&g?jt(t.value,e,v,m,g):"",is:(v,...m)=>{const g=m.length>=1?m[0]:!0;return v&&g?`${Tm}${v}`:""},cssVar:v=>{const m={};for(const g in v)v[g]&&(m[`--${t.value}-${g}`]=v[g]);return m},cssVarName:v=>`--${t.value}-${v}`,cssVarBlock:v=>{const m={};for(const g in v)v[g]&&(m[`--${t.value}-${e}-${g}`]=v[g]);return m},cssVarBlockName:v=>`--${t.value}-${e}-${v}`}};/**
33
33
  * @vue/shared v3.5.29
34
34
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
35
35
  * @license MIT
36
- **/process.env.NODE_ENV!=="production"&&Object.freeze({});process.env.NODE_ENV!=="production"&&Object.freeze([]);const Pm=()=>{},Nm=Object.prototype.hasOwnProperty,Wo=(e,r)=>Nm.call(e,r),Mm=Array.isArray,zr=e=>typeof e=="function",Bt=e=>typeof e=="string",c0=e=>e!==null&&typeof e=="object",Lm=e=>e===void 0,To=e=>typeof e=="boolean",Xt=e=>typeof e=="number",Ko=e=>typeof Element=="undefined"?!1:e instanceof Element,Um=e=>Bt(e)?!Number.isNaN(Number(e)):!1;var ml;const Mt=typeof window!="undefined",qm=e=>typeof e=="string",$m=()=>{};Mt&&((ml=window==null?void 0:window.navigator)!=null&&ml.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function ma(e){return typeof e=="function"?e():N.unref(e)}function zm(e){return e}function va(e){return N.getCurrentScope()?(N.onScopeDispose(e),!0):!1}function jm(e,r=!0){N.getCurrentInstance()?N.onMounted(e):r?e():N.nextTick(e)}function f0(e,r,t={}){const{immediate:n=!0}=t,l=N.ref(!1);let a=null;function o(){a&&(clearTimeout(a),a=null)}function u(){l.value=!1,o()}function p(...s){o(),l.value=!0,a=setTimeout(()=>{l.value=!1,a=null,e(...s)},ma(r))}return n&&(l.value=!0,Mt&&p()),va(u),{isPending:N.readonly(l),start:p,stop:u}}function h0(e){var r;const t=ma(e);return(r=t==null?void 0:t.$el)!=null?r:t}const p0=Mt?window:void 0;function d0(...e){let r,t,n,l;if(qm(e[0])||Array.isArray(e[0])?([t,n,l]=e,r=p0):[r,t,n,l]=e,!r)return $m;Array.isArray(t)||(t=[t]),Array.isArray(n)||(n=[n]);const a=[],o=()=>{a.forEach(i=>i()),a.length=0},u=(i,d,c,f)=>(i.addEventListener(d,c,f),()=>i.removeEventListener(d,c,f)),p=N.watch(()=>[h0(r),ma(l)],([i,d])=>{o(),i&&a.push(...t.flatMap(c=>n.map(f=>u(i,c,f,d))))},{immediate:!0,flush:"post"}),s=()=>{p(),o()};return va(s),s}function Hm(e,r=!1){const t=N.ref(),n=()=>t.value=!!e();return n(),jm(n,r),t}const vl=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},yl="__vueuse_ssr_handlers__";vl[yl]=vl[yl]||{};var gl=Object.getOwnPropertySymbols,Vm=Object.prototype.hasOwnProperty,Wm=Object.prototype.propertyIsEnumerable,Km=(e,r)=>{var t={};for(var n in e)Vm.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(e!=null&&gl)for(var n of gl(e))r.indexOf(n)<0&&Wm.call(e,n)&&(t[n]=e[n]);return t};function Gm(e,r,t={}){const n=t,{window:l=p0}=n,a=Km(n,["window"]);let o;const u=Hm(()=>l&&"ResizeObserver"in l),p=()=>{o&&(o.disconnect(),o=void 0)},s=N.watch(()=>h0(e),d=>{p(),u.value&&l&&d&&(o=new ResizeObserver(r),o.observe(d,a))},{immediate:!0,flush:"post"}),i=()=>{p(),s()};return va(i),{isSupported:u,stop:i}}var xl;(function(e){e.UP="UP",e.RIGHT="RIGHT",e.DOWN="DOWN",e.LEFT="LEFT",e.NONE="NONE"})(xl||(xl={}));var Qm=Object.defineProperty,bl=Object.getOwnPropertySymbols,Ym=Object.prototype.hasOwnProperty,Xm=Object.prototype.propertyIsEnumerable,wl=(e,r,t)=>r in e?Qm(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,Zm=(e,r)=>{for(var t in r||(r={}))Ym.call(r,t)&&wl(e,t,r[t]);if(bl)for(var t of bl(r))Xm.call(r,t)&&wl(e,t,r[t]);return e};const Jm={easeInSine:[.12,0,.39,0],easeOutSine:[.61,1,.88,1],easeInOutSine:[.37,0,.63,1],easeInQuad:[.11,0,.5,0],easeOutQuad:[.5,1,.89,1],easeInOutQuad:[.45,0,.55,1],easeInCubic:[.32,0,.67,0],easeOutCubic:[.33,1,.68,1],easeInOutCubic:[.65,0,.35,1],easeInQuart:[.5,0,.75,0],easeOutQuart:[.25,1,.5,1],easeInOutQuart:[.76,0,.24,1],easeInQuint:[.64,0,.78,0],easeOutQuint:[.22,1,.36,1],easeInOutQuint:[.83,0,.17,1],easeInExpo:[.7,0,.84,0],easeOutExpo:[.16,1,.3,1],easeInOutExpo:[.87,0,.13,1],easeInCirc:[.55,0,1,.45],easeOutCirc:[0,.55,.45,1],easeInOutCirc:[.85,0,.15,1],easeInBack:[.36,0,.66,-.56],easeOutBack:[.34,1.56,.64,1],easeInOutBack:[.68,-.6,.32,1.6]};Zm({linear:zm},Jm);class ev extends Error{constructor(r){super(r),this.name="ElementPlusError"}}function nr(e,r){if(typeof process!="undefined"&&process.env.NODE_ENV!=="production"){const t=Bt(e)?new ev(`[${e}] ${r}`):e;console.warn(t)}}const _l={current:0},El=N.ref(0),m0=2e3,Al=Symbol("elZIndexContextKey"),v0=Symbol("zIndexContextKey"),tv=e=>{const r=N.getCurrentInstance()?N.inject(Al,_l):_l,t=e||(N.getCurrentInstance()?N.inject(v0,void 0):void 0),n=N.computed(()=>{const o=N.unref(t);return Xt(o)?o:m0}),l=N.computed(()=>n.value+El.value),a=()=>(r.current++,El.value=r.current,l.value);return!Mt&&!N.inject(Al)&&nr("ZIndexInjection",`Looks like you are using server rendering, you must provide a z-index provider to ensure the hydration process to be succeed
37
- usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`),{initialZIndex:n,currentZIndex:l,nextZIndex:a}};var rv={name:"en",el:{breadcrumb:{label:"Breadcrumb"},colorpicker:{confirm:"OK",clear:"Clear",defaultLabel:"color picker",description:"current color is {color}. press enter to select a new color.",alphaLabel:"pick alpha value",alphaDescription:"alpha {alpha}, current color is {color}",hueLabel:"pick hue value",hueDescription:"hue {hue}, current color is {color}",svLabel:"pick saturation and brightness value",svDescription:"saturation {saturation}, brightness {brightness}, current color is {color}",predefineDescription:"select {value} as the color"},datepicker:{now:"Now",today:"Today",cancel:"Cancel",clear:"Clear",confirm:"OK",dateTablePrompt:"Use the arrow keys and enter to select the day of the month",monthTablePrompt:"Use the arrow keys and enter to select the month",yearTablePrompt:"Use the arrow keys and enter to select the year",selectedDate:"Selected date",selectDate:"Select date",selectTime:"Select time",startDate:"Start Date",startTime:"Start Time",endDate:"End Date",endTime:"End Time",prevYear:"Previous Year",nextYear:"Next Year",prevMonth:"Previous Month",nextMonth:"Next Month",year:"",month1:"January",month2:"February",month3:"March",month4:"April",month5:"May",month6:"June",month7:"July",month8:"August",month9:"September",month10:"October",month11:"November",month12:"December",weeks:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},weeksFull:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"},months:{jan:"Jan",feb:"Feb",mar:"Mar",apr:"Apr",may:"May",jun:"Jun",jul:"Jul",aug:"Aug",sep:"Sep",oct:"Oct",nov:"Nov",dec:"Dec"}},inputNumber:{decrease:"decrease number",increase:"increase number"},select:{loading:"Loading",noMatch:"No matching data",noData:"No data",placeholder:"Select"},mention:{loading:"Loading"},dropdown:{toggleDropdown:"Toggle Dropdown"},cascader:{noMatch:"No matching data",loading:"Loading",placeholder:"Select",noData:"No data"},pagination:{goto:"Go to",pagesize:"/page",total:"Total {total}",pageClassifier:"",page:"Page",prev:"Go to previous page",next:"Go to next page",currentPage:"page {pager}",prevPages:"Previous {pager} pages",nextPages:"Next {pager} pages",deprecationWarning:"Deprecated usages detected, please refer to the el-pagination documentation for more details"},dialog:{close:"Close this dialog"},drawer:{close:"Close this dialog"},messagebox:{title:"Message",confirm:"OK",cancel:"Cancel",error:"Illegal input",close:"Close this dialog"},upload:{deleteTip:"press delete to remove",delete:"Delete",preview:"Preview",continue:"Continue"},slider:{defaultLabel:"slider between {min} and {max}",defaultRangeStartLabel:"pick start value",defaultRangeEndLabel:"pick end value"},table:{emptyText:"No Data",confirmFilter:"Confirm",resetFilter:"Reset",clearFilter:"All",sumText:"Sum",selectAllLabel:"Select all rows",selectRowLabel:"Select this row",expandRowLabel:"Expand this row",collapseRowLabel:"Collapse this row",sortLabel:"Sort by {column}",filterLabel:"Filter by {column}"},tag:{close:"Close this tag"},tour:{next:"Next",previous:"Previous",finish:"Finish",close:"Close this dialog"},tree:{emptyText:"No Data"},transfer:{noMatch:"No matching data",noData:"No data",titles:["List 1","List 2"],filterPlaceholder:"Enter keyword",noCheckedFormat:"{total} items",hasCheckedFormat:"{checked}/{total} checked"},image:{error:"FAILED"},pageHeader:{title:"Back"},popconfirm:{confirmButtonText:"Yes",cancelButtonText:"No"},carousel:{leftArrow:"Carousel arrow left",rightArrow:"Carousel arrow right",indicator:"Carousel switch to index {index}"}}};const nv=e=>(r,t)=>iv(r,t,N.unref(e)),iv=(e,r,t)=>$n.get(t,e,e).replace(/\{(\w+)\}/g,(n,l)=>{var a;return`${(a=r==null?void 0:r[l])!=null?a:`{${l}}`}`}),ov=e=>{const r=N.computed(()=>N.unref(e).name),t=N.isRef(e)?e:N.ref(e);return{lang:r,locale:t,t:nv(e)}},y0=Symbol("localeContextKey"),av=e=>{const r=e||N.inject(y0,N.ref());return ov(N.computed(()=>r.value||rv))},g0="__epPropKey",Me=e=>e,sv=e=>c0(e)&&!!e[g0],x0=(e,r)=>{if(!c0(e)||sv(e))return e;const{values:t,required:n,default:l,type:a,validator:o}=e,p={type:a,required:!!n,validator:t||o?s=>{let i=!1,d=[];if(t&&(d=Array.from(t),Wo(e,"default")&&d.push(l),i||(i=d.includes(s))),o&&(i||(i=o(s))),!i&&d.length>0){const c=[...new Set(d)].map(f=>JSON.stringify(f)).join(", ");N.warn(`Invalid prop: validation failed${r?` for prop "${r}"`:""}. Expected one of [${c}], got value ${JSON.stringify(s)}.`)}return i}:void 0,[g0]:!0};return Wo(e,"default")&&(p.default=l),p},ir=e=>$n.fromPairs(Object.entries(e).map(([r,t])=>[r,x0(t,r)])),lv=["","default","small","large"],b0=x0({type:String,values:lv,required:!1}),w0=Symbol("size"),uv=()=>{const e=N.inject(w0,{});return N.computed(()=>N.unref(e.size)||"")},cv=Symbol("emptyValuesContextKey"),fv=ir({emptyValues:Array,valueOnClear:{type:Me([String,Number,Boolean,Function]),default:void 0,validator:e=>(e=zr(e)?e():e,Mm(e)?e.every(r=>!r):!e)}}),Cl=e=>Object.keys(e),Ln=N.ref();function ya(e,r=void 0){const t=N.getCurrentInstance()?N.inject(l0,Ln):Ln;return e?N.computed(()=>{var n,l;return(l=(n=t.value)==null?void 0:n[e])!=null?l:r}):t}function _0(e,r){const t=ya(),n=Sr(e,N.computed(()=>{var u;return((u=t.value)==null?void 0:u.namespace)||Dn})),l=av(N.computed(()=>{var u;return(u=t.value)==null?void 0:u.locale})),a=tv(N.computed(()=>{var u;return((u=t.value)==null?void 0:u.zIndex)||m0})),o=N.computed(()=>{var u;return N.unref(r)||((u=t.value)==null?void 0:u.size)||""});return E0(N.computed(()=>N.unref(t)||{})),{ns:n,locale:l,zIndex:a,size:o}}const E0=(e,r,t=!1)=>{var n;const l=!!N.getCurrentInstance(),a=l?ya():void 0,o=(n=void 0)!=null?n:l?N.provide:void 0;if(!o){nr("provideGlobalConfig","provideGlobalConfig() can only be used inside setup().");return}const u=N.computed(()=>{const p=N.unref(e);return a!=null&&a.value?hv(a.value,p):p});return o(l0,u),o(y0,N.computed(()=>u.value.locale)),o(u0,N.computed(()=>u.value.namespace)),o(v0,N.computed(()=>u.value.zIndex)),o(w0,{size:N.computed(()=>u.value.size||"")}),o(cv,N.computed(()=>({emptyValues:u.value.emptyValues,valueOnClear:u.value.valueOnClear}))),(t||!Ln.value)&&(Ln.value=u.value),u},hv=(e,r)=>{const t=[...new Set([...Cl(e),...Cl(r)])],n={};for(const l of t)n[l]=r[l]!==void 0?r[l]:e[l];return n};var Br=(e,r)=>{const t=e.__vccOpts||e;for(const[n,l]of r)t[n]=l;return t};const pv="utils/dom/style";function Go(e,r="px"){if(!e&&e!==0)return"";if(Xt(e)||Um(e))return`${e}${r}`;if(Bt(e))return e;nr(pv,"binding value must be a string or number")}const ga=(e,r)=>{if(e.install=t=>{for(const n of[e,...Object.values(r!=null?r:{})])t.component(n.name,n)},r)for(const[t,n]of Object.entries(r))e[t]=n;return e},A0=(e,r)=>(e.install=t=>{e._context=t._context,t.config.globalProperties[r]=e},e),dv=e=>(e.install=Pm,e),mv=ir({size:{type:Me([Number,String])},color:{type:String}}),vv=N.defineComponent({name:"ElIcon",inheritAttrs:!1}),yv=N.defineComponent(_e(he({},vv),{props:mv,setup(e){const r=e,t=Sr("icon"),n=N.computed(()=>{const{size:l,color:a}=r,o=Go(l);return!o&&!a?{}:{fontSize:o,"--color":a}});return(l,a)=>(N.openBlock(),N.createElementBlock("i",N.mergeProps({class:N.unref(t).b(),style:N.unref(n)},l.$attrs),[N.renderSlot(l.$slots,"default")],16))}}));var gv=Br(yv,[["__file","icon.vue"]]);const _r=ga(gv);/*! Element Plus Icons Vue v2.3.2 */var xv=N.defineComponent({name:"CircleCloseFilled",__name:"circle-close-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 393.664L407.936 353.6a38.4 38.4 0 1 0-54.336 54.336L457.664 512 353.6 616.064a38.4 38.4 0 1 0 54.336 54.336L512 566.336 616.064 670.4a38.4 38.4 0 1 0 54.336-54.336L566.336 512 670.4 407.936a38.4 38.4 0 1 0-54.336-54.336z"})]))}}),bv=xv,wv=N.defineComponent({name:"Close",__name:"close",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z"})]))}}),C0=wv,_v=N.defineComponent({name:"InfoFilled",__name:"info-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896.064A448 448 0 0 1 512 64m67.2 275.072c33.28 0 60.288-23.104 60.288-57.344s-27.072-57.344-60.288-57.344c-33.28 0-60.16 23.104-60.16 57.344s26.88 57.344 60.16 57.344M590.912 699.2c0-6.848 2.368-24.64 1.024-34.752l-52.608 60.544c-10.88 11.456-24.512 19.392-30.912 17.28a12.99 12.99 0 0 1-8.256-14.72l87.68-276.992c7.168-35.136-12.544-67.2-54.336-71.296-44.096 0-108.992 44.736-148.48 101.504 0 6.784-1.28 23.68.064 33.792l52.544-60.608c10.88-11.328 23.552-19.328 29.952-17.152a12.8 12.8 0 0 1 7.808 16.128L388.48 728.576c-10.048 32.256 8.96 63.872 55.04 71.04 67.84 0 107.904-43.648 147.456-100.416z"})]))}}),Sl=_v,Ev=N.defineComponent({name:"Loading",__name:"loading",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248m452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248M828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0"})]))}}),S0=Ev,Av=N.defineComponent({name:"SuccessFilled",__name:"success-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m-55.808 536.384-99.52-99.584a38.4 38.4 0 1 0-54.336 54.336l126.72 126.72a38.27 38.27 0 0 0 54.336 0l262.4-262.464a38.4 38.4 0 1 0-54.272-54.336z"})]))}}),Cv=Av,Sv=N.defineComponent({name:"WarningFilled",__name:"warning-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 192a58.43 58.43 0 0 0-58.24 63.744l23.36 256.384a35.072 35.072 0 0 0 69.76 0l23.296-256.384A58.43 58.43 0 0 0 512 256m0 512a51.2 51.2 0 1 0 0-102.4 51.2 51.2 0 0 0 0 102.4"})]))}}),Bv=Sv;const jr=Me([String,Object,Function]),kv={Close:C0},Un={primary:Sl,success:Cv,warning:Bv,error:bv,info:Sl},Tv=()=>Mt&&/android/i.test(window.navigator.userAgent),Fv=e=>e,xa=Symbol("formContextKey"),B0=Symbol("formItemContextKey"),Iv=()=>{const e=N.inject(xa,void 0),r=N.inject(B0,void 0);return{form:e,formItem:r}},k0=e=>{const r=N.getCurrentInstance();return N.computed(()=>{var t,n;return(n=(t=r==null?void 0:r.proxy)==null?void 0:t.$props)==null?void 0:n[e]})},Dv=(e,r={})=>{const t=N.ref(void 0),n=r.prop?t:k0("size"),l=r.global?t:uv(),a=r.form?{size:void 0}:N.inject(xa,void 0),o=r.formItem?{size:void 0}:N.inject(B0,void 0);return N.computed(()=>n.value||N.unref(e)||(o==null?void 0:o.size)||(a==null?void 0:a.size)||l.value||"")},T0=e=>{const r=k0("disabled"),t=N.inject(xa,void 0);return N.computed(()=>{var n,l,a;return(a=(l=(n=r.value)!=null?n:N.unref(e))!=null?l:t==null?void 0:t.disabled)!=null?a:!1})},mr={tab:"Tab",enter:"Enter",space:"Space",left:"ArrowLeft",up:"ArrowUp",right:"ArrowRight",down:"ArrowDown",esc:"Escape",delete:"Delete",backspace:"Backspace",numpadEnter:"NumpadEnter",pageUp:"PageUp",pageDown:"PageDown",home:"Home",end:"End"},F0=e=>{if(e.code&&e.code!=="Unidentified")return e.code;const r=Rv(e);if(r){if(Object.values(mr).includes(r))return r;switch(r){case" ":return mr.space;default:return""}}return""},Rv=e=>{let r=e.key&&e.key!=="Unidentified"?e.key:"";if(!r&&e.type==="keyup"&&Tv()){const t=e.target;r=t.value.charAt(t.selectionStart-1)}return r},Ov=ir({value:{type:[String,Number],default:""},max:{type:Number,default:99},isDot:Boolean,hidden:Boolean,type:{type:String,values:["primary","success","warning","info","danger"],default:"danger"},showZero:{type:Boolean,default:!0},color:String,badgeStyle:{type:Me([String,Object,Array])},offset:{type:Me(Array),default:[0,0]},badgeClass:{type:String}}),Pv=N.defineComponent({name:"ElBadge"}),Nv=N.defineComponent(_e(he({},Pv),{props:Ov,setup(e,{expose:r}){const t=e,n=Sr("badge"),l=N.computed(()=>t.isDot?"":Xt(t.value)&&Xt(t.max)?t.max<t.value?`${t.max}+`:`${t.value}`:`${t.value}`),a=N.computed(()=>{var o;return[{backgroundColor:t.color,marginRight:Go(-t.offset[0]),marginTop:Go(t.offset[1])},(o=t.badgeStyle)!=null?o:{}]});return r({content:l}),(o,u)=>(N.openBlock(),N.createElementBlock("div",{class:N.normalizeClass(N.unref(n).b())},[N.renderSlot(o.$slots,"default"),N.createVNode(N.Transition,{name:`${N.unref(n).namespace.value}-zoom-in-center`,persisted:""},{default:N.withCtx(()=>[N.withDirectives(N.createElementVNode("sup",{class:N.normalizeClass([N.unref(n).e("content"),N.unref(n).em("content",o.type),N.unref(n).is("fixed",!!o.$slots.default),N.unref(n).is("dot",o.isDot),N.unref(n).is("hide-zero",!o.showZero&&o.value===0),o.badgeClass]),style:N.normalizeStyle(N.unref(a))},[N.renderSlot(o.$slots,"content",{value:N.unref(l)},()=>[N.createTextVNode(N.toDisplayString(N.unref(l)),1)])],6),[[N.vShow,!o.hidden&&(N.unref(l)||o.isDot||o.$slots.content)]])]),_:3},8,["name"])],2))}}));var Mv=Br(Nv,[["__file","badge.vue"]]);const Lv=ga(Mv),I0=Symbol("buttonGroupContextKey"),Uv=({from:e,replacement:r,scope:t,version:n,ref:l,type:a="API"},o)=>{N.watch(()=>N.unref(o),u=>{u&&nr(t,`[${a}] ${e} is about to be deprecated in version ${n}, please use ${r} instead.
36
+ **/process.env.NODE_ENV!=="production"&&Object.freeze({});process.env.NODE_ENV!=="production"&&Object.freeze([]);const Im=()=>{},Dm=Object.prototype.hasOwnProperty,Wo=(e,r)=>Dm.call(e,r),Rm=Array.isArray,zr=e=>typeof e=="function",Bt=e=>typeof e=="string",c0=e=>e!==null&&typeof e=="object",Om=e=>e===void 0,To=e=>typeof e=="boolean",Xt=e=>typeof e=="number",Ko=e=>typeof Element=="undefined"?!1:e instanceof Element,Pm=e=>Bt(e)?!Number.isNaN(Number(e)):!1;var ml;const Mt=typeof window!="undefined",Nm=e=>typeof e=="string",Mm=()=>{};Mt&&((ml=window==null?void 0:window.navigator)!=null&&ml.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function ma(e){return typeof e=="function"?e():N.unref(e)}function Lm(e){return e}function va(e){return N.getCurrentScope()?(N.onScopeDispose(e),!0):!1}function Um(e,r=!0){N.getCurrentInstance()?N.onMounted(e):r?e():N.nextTick(e)}function f0(e,r,t={}){const{immediate:n=!0}=t,l=N.ref(!1);let a=null;function o(){a&&(clearTimeout(a),a=null)}function u(){l.value=!1,o()}function p(...s){o(),l.value=!0,a=setTimeout(()=>{l.value=!1,a=null,e(...s)},ma(r))}return n&&(l.value=!0,Mt&&p()),va(u),{isPending:N.readonly(l),start:p,stop:u}}function h0(e){var r;const t=ma(e);return(r=t==null?void 0:t.$el)!=null?r:t}const p0=Mt?window:void 0;function d0(...e){let r,t,n,l;if(Nm(e[0])||Array.isArray(e[0])?([t,n,l]=e,r=p0):[r,t,n,l]=e,!r)return Mm;Array.isArray(t)||(t=[t]),Array.isArray(n)||(n=[n]);const a=[],o=()=>{a.forEach(i=>i()),a.length=0},u=(i,d,c,f)=>(i.addEventListener(d,c,f),()=>i.removeEventListener(d,c,f)),p=N.watch(()=>[h0(r),ma(l)],([i,d])=>{o(),i&&a.push(...t.flatMap(c=>n.map(f=>u(i,c,f,d))))},{immediate:!0,flush:"post"}),s=()=>{p(),o()};return va(s),s}function qm(e,r=!1){const t=N.ref(),n=()=>t.value=!!e();return n(),Um(n,r),t}const vl=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},yl="__vueuse_ssr_handlers__";vl[yl]=vl[yl]||{};var gl=Object.getOwnPropertySymbols,$m=Object.prototype.hasOwnProperty,zm=Object.prototype.propertyIsEnumerable,jm=(e,r)=>{var t={};for(var n in e)$m.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(e!=null&&gl)for(var n of gl(e))r.indexOf(n)<0&&zm.call(e,n)&&(t[n]=e[n]);return t};function Hm(e,r,t={}){const n=t,{window:l=p0}=n,a=jm(n,["window"]);let o;const u=qm(()=>l&&"ResizeObserver"in l),p=()=>{o&&(o.disconnect(),o=void 0)},s=N.watch(()=>h0(e),d=>{p(),u.value&&l&&d&&(o=new ResizeObserver(r),o.observe(d,a))},{immediate:!0,flush:"post"}),i=()=>{p(),s()};return va(i),{isSupported:u,stop:i}}var xl;(function(e){e.UP="UP",e.RIGHT="RIGHT",e.DOWN="DOWN",e.LEFT="LEFT",e.NONE="NONE"})(xl||(xl={}));var Vm=Object.defineProperty,bl=Object.getOwnPropertySymbols,Wm=Object.prototype.hasOwnProperty,Km=Object.prototype.propertyIsEnumerable,wl=(e,r,t)=>r in e?Vm(e,r,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[r]=t,Gm=(e,r)=>{for(var t in r||(r={}))Wm.call(r,t)&&wl(e,t,r[t]);if(bl)for(var t of bl(r))Km.call(r,t)&&wl(e,t,r[t]);return e};const Qm={easeInSine:[.12,0,.39,0],easeOutSine:[.61,1,.88,1],easeInOutSine:[.37,0,.63,1],easeInQuad:[.11,0,.5,0],easeOutQuad:[.5,1,.89,1],easeInOutQuad:[.45,0,.55,1],easeInCubic:[.32,0,.67,0],easeOutCubic:[.33,1,.68,1],easeInOutCubic:[.65,0,.35,1],easeInQuart:[.5,0,.75,0],easeOutQuart:[.25,1,.5,1],easeInOutQuart:[.76,0,.24,1],easeInQuint:[.64,0,.78,0],easeOutQuint:[.22,1,.36,1],easeInOutQuint:[.83,0,.17,1],easeInExpo:[.7,0,.84,0],easeOutExpo:[.16,1,.3,1],easeInOutExpo:[.87,0,.13,1],easeInCirc:[.55,0,1,.45],easeOutCirc:[0,.55,.45,1],easeInOutCirc:[.85,0,.15,1],easeInBack:[.36,0,.66,-.56],easeOutBack:[.34,1.56,.64,1],easeInOutBack:[.68,-.6,.32,1.6]};Gm({linear:Lm},Qm);class Ym extends Error{constructor(r){super(r),this.name="ElementPlusError"}}function nr(e,r){if(typeof process!="undefined"&&process.env.NODE_ENV!=="production"){const t=Bt(e)?new Ym(`[${e}] ${r}`):e;console.warn(t)}}const _l={current:0},El=N.ref(0),m0=2e3,Al=Symbol("elZIndexContextKey"),v0=Symbol("zIndexContextKey"),Xm=e=>{const r=N.getCurrentInstance()?N.inject(Al,_l):_l,t=e||(N.getCurrentInstance()?N.inject(v0,void 0):void 0),n=N.computed(()=>{const o=N.unref(t);return Xt(o)?o:m0}),l=N.computed(()=>n.value+El.value),a=()=>(r.current++,El.value=r.current,l.value);return!Mt&&!N.inject(Al)&&nr("ZIndexInjection",`Looks like you are using server rendering, you must provide a z-index provider to ensure the hydration process to be succeed
37
+ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`),{initialZIndex:n,currentZIndex:l,nextZIndex:a}};var Zm={name:"en",el:{breadcrumb:{label:"Breadcrumb"},colorpicker:{confirm:"OK",clear:"Clear",defaultLabel:"color picker",description:"current color is {color}. press enter to select a new color.",alphaLabel:"pick alpha value",alphaDescription:"alpha {alpha}, current color is {color}",hueLabel:"pick hue value",hueDescription:"hue {hue}, current color is {color}",svLabel:"pick saturation and brightness value",svDescription:"saturation {saturation}, brightness {brightness}, current color is {color}",predefineDescription:"select {value} as the color"},datepicker:{now:"Now",today:"Today",cancel:"Cancel",clear:"Clear",confirm:"OK",dateTablePrompt:"Use the arrow keys and enter to select the day of the month",monthTablePrompt:"Use the arrow keys and enter to select the month",yearTablePrompt:"Use the arrow keys and enter to select the year",selectedDate:"Selected date",selectDate:"Select date",selectTime:"Select time",startDate:"Start Date",startTime:"Start Time",endDate:"End Date",endTime:"End Time",prevYear:"Previous Year",nextYear:"Next Year",prevMonth:"Previous Month",nextMonth:"Next Month",year:"",month1:"January",month2:"February",month3:"March",month4:"April",month5:"May",month6:"June",month7:"July",month8:"August",month9:"September",month10:"October",month11:"November",month12:"December",weeks:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},weeksFull:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"},months:{jan:"Jan",feb:"Feb",mar:"Mar",apr:"Apr",may:"May",jun:"Jun",jul:"Jul",aug:"Aug",sep:"Sep",oct:"Oct",nov:"Nov",dec:"Dec"}},inputNumber:{decrease:"decrease number",increase:"increase number"},select:{loading:"Loading",noMatch:"No matching data",noData:"No data",placeholder:"Select"},mention:{loading:"Loading"},dropdown:{toggleDropdown:"Toggle Dropdown"},cascader:{noMatch:"No matching data",loading:"Loading",placeholder:"Select",noData:"No data"},pagination:{goto:"Go to",pagesize:"/page",total:"Total {total}",pageClassifier:"",page:"Page",prev:"Go to previous page",next:"Go to next page",currentPage:"page {pager}",prevPages:"Previous {pager} pages",nextPages:"Next {pager} pages",deprecationWarning:"Deprecated usages detected, please refer to the el-pagination documentation for more details"},dialog:{close:"Close this dialog"},drawer:{close:"Close this dialog"},messagebox:{title:"Message",confirm:"OK",cancel:"Cancel",error:"Illegal input",close:"Close this dialog"},upload:{deleteTip:"press delete to remove",delete:"Delete",preview:"Preview",continue:"Continue"},slider:{defaultLabel:"slider between {min} and {max}",defaultRangeStartLabel:"pick start value",defaultRangeEndLabel:"pick end value"},table:{emptyText:"No Data",confirmFilter:"Confirm",resetFilter:"Reset",clearFilter:"All",sumText:"Sum",selectAllLabel:"Select all rows",selectRowLabel:"Select this row",expandRowLabel:"Expand this row",collapseRowLabel:"Collapse this row",sortLabel:"Sort by {column}",filterLabel:"Filter by {column}"},tag:{close:"Close this tag"},tour:{next:"Next",previous:"Previous",finish:"Finish",close:"Close this dialog"},tree:{emptyText:"No Data"},transfer:{noMatch:"No matching data",noData:"No data",titles:["List 1","List 2"],filterPlaceholder:"Enter keyword",noCheckedFormat:"{total} items",hasCheckedFormat:"{checked}/{total} checked"},image:{error:"FAILED"},pageHeader:{title:"Back"},popconfirm:{confirmButtonText:"Yes",cancelButtonText:"No"},carousel:{leftArrow:"Carousel arrow left",rightArrow:"Carousel arrow right",indicator:"Carousel switch to index {index}"}}};const Jm=e=>(r,t)=>ev(r,t,N.unref(e)),ev=(e,r,t)=>$n.get(t,e,e).replace(/\{(\w+)\}/g,(n,l)=>{var a;return`${(a=r==null?void 0:r[l])!=null?a:`{${l}}`}`}),tv=e=>{const r=N.computed(()=>N.unref(e).name),t=N.isRef(e)?e:N.ref(e);return{lang:r,locale:t,t:Jm(e)}},y0=Symbol("localeContextKey"),rv=e=>{const r=e||N.inject(y0,N.ref());return tv(N.computed(()=>r.value||Zm))},g0="__epPropKey",Me=e=>e,nv=e=>c0(e)&&!!e[g0],x0=(e,r)=>{if(!c0(e)||nv(e))return e;const{values:t,required:n,default:l,type:a,validator:o}=e,p={type:a,required:!!n,validator:t||o?s=>{let i=!1,d=[];if(t&&(d=Array.from(t),Wo(e,"default")&&d.push(l),i||(i=d.includes(s))),o&&(i||(i=o(s))),!i&&d.length>0){const c=[...new Set(d)].map(f=>JSON.stringify(f)).join(", ");N.warn(`Invalid prop: validation failed${r?` for prop "${r}"`:""}. Expected one of [${c}], got value ${JSON.stringify(s)}.`)}return i}:void 0,[g0]:!0};return Wo(e,"default")&&(p.default=l),p},ir=e=>$n.fromPairs(Object.entries(e).map(([r,t])=>[r,x0(t,r)])),iv=["","default","small","large"],b0=x0({type:String,values:iv,required:!1}),w0=Symbol("size"),ov=()=>{const e=N.inject(w0,{});return N.computed(()=>N.unref(e.size)||"")},av=Symbol("emptyValuesContextKey"),sv=ir({emptyValues:Array,valueOnClear:{type:Me([String,Number,Boolean,Function]),default:void 0,validator:e=>(e=zr(e)?e():e,Rm(e)?e.every(r=>!r):!e)}}),Cl=e=>Object.keys(e),Ln=N.ref();function ya(e,r=void 0){const t=N.getCurrentInstance()?N.inject(l0,Ln):Ln;return e?N.computed(()=>{var n,l;return(l=(n=t.value)==null?void 0:n[e])!=null?l:r}):t}function _0(e,r){const t=ya(),n=Sr(e,N.computed(()=>{var u;return((u=t.value)==null?void 0:u.namespace)||Dn})),l=rv(N.computed(()=>{var u;return(u=t.value)==null?void 0:u.locale})),a=Xm(N.computed(()=>{var u;return((u=t.value)==null?void 0:u.zIndex)||m0})),o=N.computed(()=>{var u;return N.unref(r)||((u=t.value)==null?void 0:u.size)||""});return E0(N.computed(()=>N.unref(t)||{})),{ns:n,locale:l,zIndex:a,size:o}}const E0=(e,r,t=!1)=>{var n;const l=!!N.getCurrentInstance(),a=l?ya():void 0,o=(n=void 0)!=null?n:l?N.provide:void 0;if(!o){nr("provideGlobalConfig","provideGlobalConfig() can only be used inside setup().");return}const u=N.computed(()=>{const p=N.unref(e);return a!=null&&a.value?lv(a.value,p):p});return o(l0,u),o(y0,N.computed(()=>u.value.locale)),o(u0,N.computed(()=>u.value.namespace)),o(v0,N.computed(()=>u.value.zIndex)),o(w0,{size:N.computed(()=>u.value.size||"")}),o(av,N.computed(()=>({emptyValues:u.value.emptyValues,valueOnClear:u.value.valueOnClear}))),(t||!Ln.value)&&(Ln.value=u.value),u},lv=(e,r)=>{const t=[...new Set([...Cl(e),...Cl(r)])],n={};for(const l of t)n[l]=r[l]!==void 0?r[l]:e[l];return n};var Br=(e,r)=>{const t=e.__vccOpts||e;for(const[n,l]of r)t[n]=l;return t};const uv="utils/dom/style";function Go(e,r="px"){if(!e&&e!==0)return"";if(Xt(e)||Pm(e))return`${e}${r}`;if(Bt(e))return e;nr(uv,"binding value must be a string or number")}const ga=(e,r)=>{if(e.install=t=>{for(const n of[e,...Object.values(r!=null?r:{})])t.component(n.name,n)},r)for(const[t,n]of Object.entries(r))e[t]=n;return e},A0=(e,r)=>(e.install=t=>{e._context=t._context,t.config.globalProperties[r]=e},e),cv=e=>(e.install=Im,e),fv=ir({size:{type:Me([Number,String])},color:{type:String}}),hv=N.defineComponent({name:"ElIcon",inheritAttrs:!1}),pv=N.defineComponent(_e(he({},hv),{props:fv,setup(e){const r=e,t=Sr("icon"),n=N.computed(()=>{const{size:l,color:a}=r,o=Go(l);return!o&&!a?{}:{fontSize:o,"--color":a}});return(l,a)=>(N.openBlock(),N.createElementBlock("i",N.mergeProps({class:N.unref(t).b(),style:N.unref(n)},l.$attrs),[N.renderSlot(l.$slots,"default")],16))}}));var dv=Br(pv,[["__file","icon.vue"]]);const _r=ga(dv);/*! Element Plus Icons Vue v2.3.2 */var mv=N.defineComponent({name:"CircleCloseFilled",__name:"circle-close-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 393.664L407.936 353.6a38.4 38.4 0 1 0-54.336 54.336L457.664 512 353.6 616.064a38.4 38.4 0 1 0 54.336 54.336L512 566.336 616.064 670.4a38.4 38.4 0 1 0 54.336-54.336L566.336 512 670.4 407.936a38.4 38.4 0 1 0-54.336-54.336z"})]))}}),vv=mv,yv=N.defineComponent({name:"Close",__name:"close",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z"})]))}}),C0=yv,gv=N.defineComponent({name:"InfoFilled",__name:"info-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896.064A448 448 0 0 1 512 64m67.2 275.072c33.28 0 60.288-23.104 60.288-57.344s-27.072-57.344-60.288-57.344c-33.28 0-60.16 23.104-60.16 57.344s26.88 57.344 60.16 57.344M590.912 699.2c0-6.848 2.368-24.64 1.024-34.752l-52.608 60.544c-10.88 11.456-24.512 19.392-30.912 17.28a12.99 12.99 0 0 1-8.256-14.72l87.68-276.992c7.168-35.136-12.544-67.2-54.336-71.296-44.096 0-108.992 44.736-148.48 101.504 0 6.784-1.28 23.68.064 33.792l52.544-60.608c10.88-11.328 23.552-19.328 29.952-17.152a12.8 12.8 0 0 1 7.808 16.128L388.48 728.576c-10.048 32.256 8.96 63.872 55.04 71.04 67.84 0 107.904-43.648 147.456-100.416z"})]))}}),Sl=gv,xv=N.defineComponent({name:"Loading",__name:"loading",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248m452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248M828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0"})]))}}),S0=xv,bv=N.defineComponent({name:"SuccessFilled",__name:"success-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m-55.808 536.384-99.52-99.584a38.4 38.4 0 1 0-54.336 54.336l126.72 126.72a38.27 38.27 0 0 0 54.336 0l262.4-262.464a38.4 38.4 0 1 0-54.272-54.336z"})]))}}),wv=bv,_v=N.defineComponent({name:"WarningFilled",__name:"warning-filled",setup(e){return(r,t)=>(N.openBlock(),N.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[N.createElementVNode("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 192a58.43 58.43 0 0 0-58.24 63.744l23.36 256.384a35.072 35.072 0 0 0 69.76 0l23.296-256.384A58.43 58.43 0 0 0 512 256m0 512a51.2 51.2 0 1 0 0-102.4 51.2 51.2 0 0 0 0 102.4"})]))}}),Ev=_v;const jr=Me([String,Object,Function]),Av={Close:C0},Un={primary:Sl,success:wv,warning:Ev,error:vv,info:Sl},Cv=()=>Mt&&/android/i.test(window.navigator.userAgent),Sv=e=>e,xa=Symbol("formContextKey"),B0=Symbol("formItemContextKey"),Bv=()=>{const e=N.inject(xa,void 0),r=N.inject(B0,void 0);return{form:e,formItem:r}},k0=e=>{const r=N.getCurrentInstance();return N.computed(()=>{var t,n;return(n=(t=r==null?void 0:r.proxy)==null?void 0:t.$props)==null?void 0:n[e]})},kv=(e,r={})=>{const t=N.ref(void 0),n=r.prop?t:k0("size"),l=r.global?t:ov(),a=r.form?{size:void 0}:N.inject(xa,void 0),o=r.formItem?{size:void 0}:N.inject(B0,void 0);return N.computed(()=>n.value||N.unref(e)||(o==null?void 0:o.size)||(a==null?void 0:a.size)||l.value||"")},T0=e=>{const r=k0("disabled"),t=N.inject(xa,void 0);return N.computed(()=>{var n,l,a;return(a=(l=(n=r.value)!=null?n:N.unref(e))!=null?l:t==null?void 0:t.disabled)!=null?a:!1})},mr={tab:"Tab",enter:"Enter",space:"Space",left:"ArrowLeft",up:"ArrowUp",right:"ArrowRight",down:"ArrowDown",esc:"Escape",delete:"Delete",backspace:"Backspace",numpadEnter:"NumpadEnter",pageUp:"PageUp",pageDown:"PageDown",home:"Home",end:"End"},F0=e=>{if(e.code&&e.code!=="Unidentified")return e.code;const r=Tv(e);if(r){if(Object.values(mr).includes(r))return r;switch(r){case" ":return mr.space;default:return""}}return""},Tv=e=>{let r=e.key&&e.key!=="Unidentified"?e.key:"";if(!r&&e.type==="keyup"&&Cv()){const t=e.target;r=t.value.charAt(t.selectionStart-1)}return r},Fv=ir({value:{type:[String,Number],default:""},max:{type:Number,default:99},isDot:Boolean,hidden:Boolean,type:{type:String,values:["primary","success","warning","info","danger"],default:"danger"},showZero:{type:Boolean,default:!0},color:String,badgeStyle:{type:Me([String,Object,Array])},offset:{type:Me(Array),default:[0,0]},badgeClass:{type:String}}),Iv=N.defineComponent({name:"ElBadge"}),Dv=N.defineComponent(_e(he({},Iv),{props:Fv,setup(e,{expose:r}){const t=e,n=Sr("badge"),l=N.computed(()=>t.isDot?"":Xt(t.value)&&Xt(t.max)?t.max<t.value?`${t.max}+`:`${t.value}`:`${t.value}`),a=N.computed(()=>{var o;return[{backgroundColor:t.color,marginRight:Go(-t.offset[0]),marginTop:Go(t.offset[1])},(o=t.badgeStyle)!=null?o:{}]});return r({content:l}),(o,u)=>(N.openBlock(),N.createElementBlock("div",{class:N.normalizeClass(N.unref(n).b())},[N.renderSlot(o.$slots,"default"),N.createVNode(N.Transition,{name:`${N.unref(n).namespace.value}-zoom-in-center`,persisted:""},{default:N.withCtx(()=>[N.withDirectives(N.createElementVNode("sup",{class:N.normalizeClass([N.unref(n).e("content"),N.unref(n).em("content",o.type),N.unref(n).is("fixed",!!o.$slots.default),N.unref(n).is("dot",o.isDot),N.unref(n).is("hide-zero",!o.showZero&&o.value===0),o.badgeClass]),style:N.normalizeStyle(N.unref(a))},[N.renderSlot(o.$slots,"content",{value:N.unref(l)},()=>[N.createTextVNode(N.toDisplayString(N.unref(l)),1)])],6),[[N.vShow,!o.hidden&&(N.unref(l)||o.isDot||o.$slots.content)]])]),_:3},8,["name"])],2))}}));var Rv=Br(Dv,[["__file","badge.vue"]]);const Ov=ga(Rv),I0=Symbol("buttonGroupContextKey"),Pv=({from:e,replacement:r,scope:t,version:n,ref:l,type:a="API"},o)=>{N.watch(()=>N.unref(o),u=>{u&&nr(t,`[${a}] ${e} is about to be deprecated in version ${n}, please use ${r} instead.
38
38
  For more detail, please visit: ${l}
39
- `)},{immediate:!0})},qv=(e,r)=>{Uv({from:"type.text",replacement:"link",version:"3.0.0",scope:"props",ref:"https://element-plus.org/en-US/component/button.html#button-attributes"},N.computed(()=>e.type==="text"));const t=N.inject(I0,void 0),n=ya("button"),{form:l}=Iv(),a=Dv(N.computed(()=>t==null?void 0:t.size)),o=T0(),u=N.ref(),p=N.useSlots(),s=N.computed(()=>{var g;return e.type||(t==null?void 0:t.type)||((g=n.value)==null?void 0:g.type)||""}),i=N.computed(()=>{var g,x,y;return(y=(x=e.autoInsertSpace)!=null?x:(g=n.value)==null?void 0:g.autoInsertSpace)!=null?y:!1}),d=N.computed(()=>{var g,x,y;return(y=(x=e.plain)!=null?x:(g=n.value)==null?void 0:g.plain)!=null?y:!1}),c=N.computed(()=>{var g,x,y;return(y=(x=e.round)!=null?x:(g=n.value)==null?void 0:g.round)!=null?y:!1}),f=N.computed(()=>{var g,x,y;return(y=(x=e.text)!=null?x:(g=n.value)==null?void 0:g.text)!=null?y:!1}),h=N.computed(()=>e.tag==="button"?{ariaDisabled:o.value||e.loading,disabled:o.value||e.loading,autofocus:e.autofocus,type:e.nativeType}:{}),v=N.computed(()=>{var g;const x=(g=p.default)==null?void 0:g.call(p);if(i.value&&(x==null?void 0:x.length)===1){const y=x[0];if((y==null?void 0:y.type)===N.Text){const w=y.children;return new RegExp("^\\p{Unified_Ideograph}{2}$","u").test(w.trim())}}return!1});return{_disabled:o,_size:a,_type:s,_ref:u,_props:h,_plain:d,_round:c,_text:f,shouldAddSpace:v,handleClick:g=>{if(o.value||e.loading){g.stopPropagation();return}e.nativeType==="reset"&&(l==null||l.resetFields()),r("click",g)}}},$v=["default","primary","success","warning","info","danger","text",""],zv=["button","submit","reset"],Qo=ir({size:b0,disabled:{type:Boolean,default:void 0},type:{type:String,values:$v,default:""},icon:{type:jr},nativeType:{type:String,values:zv,default:"button"},loading:Boolean,loadingIcon:{type:jr,default:()=>S0},plain:{type:Boolean,default:void 0},text:{type:Boolean,default:void 0},link:Boolean,bg:Boolean,autofocus:Boolean,round:{type:Boolean,default:void 0},circle:Boolean,color:String,dark:Boolean,autoInsertSpace:{type:Boolean,default:void 0},tag:{type:Me([String,Object]),default:"button"}}),jv={click:e=>e instanceof MouseEvent};function He(e,r){Hv(e)&&(e="100%");var t=Vv(e);return e=r===360?e:Math.min(r,Math.max(0,parseFloat(e))),t&&(e=parseInt(String(e*r),10)/100),Math.abs(e-r)<1e-6?1:(r===360?e=(e<0?e%r+r:e%r)/parseFloat(String(r)):e=e%r/parseFloat(String(r)),e)}function En(e){return Math.min(1,Math.max(0,e))}function Hv(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function Vv(e){return typeof e=="string"&&e.indexOf("%")!==-1}function D0(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function An(e){return e<=1?"".concat(Number(e)*100,"%"):e}function Kt(e){return e.length===1?"0"+e:String(e)}function Wv(e,r,t){return{r:He(e,255)*255,g:He(r,255)*255,b:He(t,255)*255}}function Bl(e,r,t){e=He(e,255),r=He(r,255),t=He(t,255);var n=Math.max(e,r,t),l=Math.min(e,r,t),a=0,o=0,u=(n+l)/2;if(n===l)o=0,a=0;else{var p=n-l;switch(o=u>.5?p/(2-n-l):p/(n+l),n){case e:a=(r-t)/p+(r<t?6:0);break;case r:a=(t-e)/p+2;break;case t:a=(e-r)/p+4;break}a/=6}return{h:a,s:o,l:u}}function Fo(e,r,t){return t<0&&(t+=1),t>1&&(t-=1),t<1/6?e+(r-e)*(6*t):t<1/2?r:t<2/3?e+(r-e)*(2/3-t)*6:e}function Kv(e,r,t){var n,l,a;if(e=He(e,360),r=He(r,100),t=He(t,100),r===0)l=t,a=t,n=t;else{var o=t<.5?t*(1+r):t+r-t*r,u=2*t-o;n=Fo(u,o,e+1/3),l=Fo(u,o,e),a=Fo(u,o,e-1/3)}return{r:n*255,g:l*255,b:a*255}}function kl(e,r,t){e=He(e,255),r=He(r,255),t=He(t,255);var n=Math.max(e,r,t),l=Math.min(e,r,t),a=0,o=n,u=n-l,p=n===0?0:u/n;if(n===l)a=0;else{switch(n){case e:a=(r-t)/u+(r<t?6:0);break;case r:a=(t-e)/u+2;break;case t:a=(e-r)/u+4;break}a/=6}return{h:a,s:p,v:o}}function Gv(e,r,t){e=He(e,360)*6,r=He(r,100),t=He(t,100);var n=Math.floor(e),l=e-n,a=t*(1-r),o=t*(1-l*r),u=t*(1-(1-l)*r),p=n%6,s=[t,o,a,a,u,t][p],i=[u,t,t,o,a,a][p],d=[a,a,u,t,t,o][p];return{r:s*255,g:i*255,b:d*255}}function Tl(e,r,t,n){var l=[Kt(Math.round(e).toString(16)),Kt(Math.round(r).toString(16)),Kt(Math.round(t).toString(16))];return n&&l[0].startsWith(l[0].charAt(1))&&l[1].startsWith(l[1].charAt(1))&&l[2].startsWith(l[2].charAt(1))?l[0].charAt(0)+l[1].charAt(0)+l[2].charAt(0):l.join("")}function Qv(e,r,t,n,l){var a=[Kt(Math.round(e).toString(16)),Kt(Math.round(r).toString(16)),Kt(Math.round(t).toString(16)),Kt(Yv(n))];return l&&a[0].startsWith(a[0].charAt(1))&&a[1].startsWith(a[1].charAt(1))&&a[2].startsWith(a[2].charAt(1))&&a[3].startsWith(a[3].charAt(1))?a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0)+a[3].charAt(0):a.join("")}function Yv(e){return Math.round(parseFloat(e)*255).toString(16)}function Fl(e){return rt(e)/255}function rt(e){return parseInt(e,16)}function Xv(e){return{r:e>>16,g:(e&65280)>>8,b:e&255}}var Yo={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function Zv(e){var r={r:0,g:0,b:0},t=1,n=null,l=null,a=null,o=!1,u=!1;return typeof e=="string"&&(e=ty(e)),typeof e=="object"&&(At(e.r)&&At(e.g)&&At(e.b)?(r=Wv(e.r,e.g,e.b),o=!0,u=String(e.r).substr(-1)==="%"?"prgb":"rgb"):At(e.h)&&At(e.s)&&At(e.v)?(n=An(e.s),l=An(e.v),r=Gv(e.h,n,l),o=!0,u="hsv"):At(e.h)&&At(e.s)&&At(e.l)&&(n=An(e.s),a=An(e.l),r=Kv(e.h,n,a),o=!0,u="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(t=e.a)),t=D0(t),{ok:o,format:e.format||u,r:Math.min(255,Math.max(r.r,0)),g:Math.min(255,Math.max(r.g,0)),b:Math.min(255,Math.max(r.b,0)),a:t}}var Jv="[-\\+]?\\d+%?",ey="[-\\+]?\\d*\\.\\d+%?",Ot="(?:".concat(ey,")|(?:").concat(Jv,")"),Io="[\\s|\\(]+(".concat(Ot,")[,|\\s]+(").concat(Ot,")[,|\\s]+(").concat(Ot,")\\s*\\)?"),Do="[\\s|\\(]+(".concat(Ot,")[,|\\s]+(").concat(Ot,")[,|\\s]+(").concat(Ot,")[,|\\s]+(").concat(Ot,")\\s*\\)?"),ft={CSS_UNIT:new RegExp(Ot),rgb:new RegExp("rgb"+Io),rgba:new RegExp("rgba"+Do),hsl:new RegExp("hsl"+Io),hsla:new RegExp("hsla"+Do),hsv:new RegExp("hsv"+Io),hsva:new RegExp("hsva"+Do),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function ty(e){if(e=e.trim().toLowerCase(),e.length===0)return!1;var r=!1;if(Yo[e])e=Yo[e],r=!0;else if(e==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var t=ft.rgb.exec(e);return t?{r:t[1],g:t[2],b:t[3]}:(t=ft.rgba.exec(e),t?{r:t[1],g:t[2],b:t[3],a:t[4]}:(t=ft.hsl.exec(e),t?{h:t[1],s:t[2],l:t[3]}:(t=ft.hsla.exec(e),t?{h:t[1],s:t[2],l:t[3],a:t[4]}:(t=ft.hsv.exec(e),t?{h:t[1],s:t[2],v:t[3]}:(t=ft.hsva.exec(e),t?{h:t[1],s:t[2],v:t[3],a:t[4]}:(t=ft.hex8.exec(e),t?{r:rt(t[1]),g:rt(t[2]),b:rt(t[3]),a:Fl(t[4]),format:r?"name":"hex8"}:(t=ft.hex6.exec(e),t?{r:rt(t[1]),g:rt(t[2]),b:rt(t[3]),format:r?"name":"hex"}:(t=ft.hex4.exec(e),t?{r:rt(t[1]+t[1]),g:rt(t[2]+t[2]),b:rt(t[3]+t[3]),a:Fl(t[4]+t[4]),format:r?"name":"hex8"}:(t=ft.hex3.exec(e),t?{r:rt(t[1]+t[1]),g:rt(t[2]+t[2]),b:rt(t[3]+t[3]),format:r?"name":"hex"}:!1)))))))))}function At(e){return!!ft.CSS_UNIT.exec(String(e))}var ry=function(){function e(r,t){r===void 0&&(r=""),t===void 0&&(t={});var n;if(r instanceof e)return r;typeof r=="number"&&(r=Xv(r)),this.originalInput=r;var l=Zv(r);this.originalInput=r,this.r=l.r,this.g=l.g,this.b=l.b,this.a=l.a,this.roundA=Math.round(100*this.a)/100,this.format=(n=t.format)!==null&&n!==void 0?n:l.format,this.gradientType=t.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=l.ok}return e.prototype.isDark=function(){return this.getBrightness()<128},e.prototype.isLight=function(){return!this.isDark()},e.prototype.getBrightness=function(){var r=this.toRgb();return(r.r*299+r.g*587+r.b*114)/1e3},e.prototype.getLuminance=function(){var r=this.toRgb(),t,n,l,a=r.r/255,o=r.g/255,u=r.b/255;return a<=.03928?t=a/12.92:t=Math.pow((a+.055)/1.055,2.4),o<=.03928?n=o/12.92:n=Math.pow((o+.055)/1.055,2.4),u<=.03928?l=u/12.92:l=Math.pow((u+.055)/1.055,2.4),.2126*t+.7152*n+.0722*l},e.prototype.getAlpha=function(){return this.a},e.prototype.setAlpha=function(r){return this.a=D0(r),this.roundA=Math.round(100*this.a)/100,this},e.prototype.isMonochrome=function(){var r=this.toHsl().s;return r===0},e.prototype.toHsv=function(){var r=kl(this.r,this.g,this.b);return{h:r.h*360,s:r.s,v:r.v,a:this.a}},e.prototype.toHsvString=function(){var r=kl(this.r,this.g,this.b),t=Math.round(r.h*360),n=Math.round(r.s*100),l=Math.round(r.v*100);return this.a===1?"hsv(".concat(t,", ").concat(n,"%, ").concat(l,"%)"):"hsva(".concat(t,", ").concat(n,"%, ").concat(l,"%, ").concat(this.roundA,")")},e.prototype.toHsl=function(){var r=Bl(this.r,this.g,this.b);return{h:r.h*360,s:r.s,l:r.l,a:this.a}},e.prototype.toHslString=function(){var r=Bl(this.r,this.g,this.b),t=Math.round(r.h*360),n=Math.round(r.s*100),l=Math.round(r.l*100);return this.a===1?"hsl(".concat(t,", ").concat(n,"%, ").concat(l,"%)"):"hsla(".concat(t,", ").concat(n,"%, ").concat(l,"%, ").concat(this.roundA,")")},e.prototype.toHex=function(r){return r===void 0&&(r=!1),Tl(this.r,this.g,this.b,r)},e.prototype.toHexString=function(r){return r===void 0&&(r=!1),"#"+this.toHex(r)},e.prototype.toHex8=function(r){return r===void 0&&(r=!1),Qv(this.r,this.g,this.b,this.a,r)},e.prototype.toHex8String=function(r){return r===void 0&&(r=!1),"#"+this.toHex8(r)},e.prototype.toHexShortString=function(r){return r===void 0&&(r=!1),this.a===1?this.toHexString(r):this.toHex8String(r)},e.prototype.toRgb=function(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}},e.prototype.toRgbString=function(){var r=Math.round(this.r),t=Math.round(this.g),n=Math.round(this.b);return this.a===1?"rgb(".concat(r,", ").concat(t,", ").concat(n,")"):"rgba(".concat(r,", ").concat(t,", ").concat(n,", ").concat(this.roundA,")")},e.prototype.toPercentageRgb=function(){var r=function(t){return"".concat(Math.round(He(t,255)*100),"%")};return{r:r(this.r),g:r(this.g),b:r(this.b),a:this.a}},e.prototype.toPercentageRgbString=function(){var r=function(t){return Math.round(He(t,255)*100)};return this.a===1?"rgb(".concat(r(this.r),"%, ").concat(r(this.g),"%, ").concat(r(this.b),"%)"):"rgba(".concat(r(this.r),"%, ").concat(r(this.g),"%, ").concat(r(this.b),"%, ").concat(this.roundA,")")},e.prototype.toName=function(){if(this.a===0)return"transparent";if(this.a<1)return!1;for(var r="#"+Tl(this.r,this.g,this.b,!1),t=0,n=Object.entries(Yo);t<n.length;t++){var l=n[t],a=l[0],o=l[1];if(r===o)return a}return!1},e.prototype.toString=function(r){var t=!!r;r=r!=null?r:this.format;var n=!1,l=this.a<1&&this.a>=0,a=!t&&l&&(r.startsWith("hex")||r==="name");return a?r==="name"&&this.a===0?this.toName():this.toRgbString():(r==="rgb"&&(n=this.toRgbString()),r==="prgb"&&(n=this.toPercentageRgbString()),(r==="hex"||r==="hex6")&&(n=this.toHexString()),r==="hex3"&&(n=this.toHexString(!0)),r==="hex4"&&(n=this.toHex8String(!0)),r==="hex8"&&(n=this.toHex8String()),r==="name"&&(n=this.toName()),r==="hsl"&&(n=this.toHslString()),r==="hsv"&&(n=this.toHsvString()),n||this.toHexString())},e.prototype.toNumber=function(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)},e.prototype.clone=function(){return new e(this.toString())},e.prototype.lighten=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.l+=r/100,t.l=En(t.l),new e(t)},e.prototype.brighten=function(r){r===void 0&&(r=10);var t=this.toRgb();return t.r=Math.max(0,Math.min(255,t.r-Math.round(255*-(r/100)))),t.g=Math.max(0,Math.min(255,t.g-Math.round(255*-(r/100)))),t.b=Math.max(0,Math.min(255,t.b-Math.round(255*-(r/100)))),new e(t)},e.prototype.darken=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.l-=r/100,t.l=En(t.l),new e(t)},e.prototype.tint=function(r){return r===void 0&&(r=10),this.mix("white",r)},e.prototype.shade=function(r){return r===void 0&&(r=10),this.mix("black",r)},e.prototype.desaturate=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.s-=r/100,t.s=En(t.s),new e(t)},e.prototype.saturate=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.s+=r/100,t.s=En(t.s),new e(t)},e.prototype.greyscale=function(){return this.desaturate(100)},e.prototype.spin=function(r){var t=this.toHsl(),n=(t.h+r)%360;return t.h=n<0?360+n:n,new e(t)},e.prototype.mix=function(r,t){t===void 0&&(t=50);var n=this.toRgb(),l=new e(r).toRgb(),a=t/100,o={r:(l.r-n.r)*a+n.r,g:(l.g-n.g)*a+n.g,b:(l.b-n.b)*a+n.b,a:(l.a-n.a)*a+n.a};return new e(o)},e.prototype.analogous=function(r,t){r===void 0&&(r=6),t===void 0&&(t=30);var n=this.toHsl(),l=360/t,a=[this];for(n.h=(n.h-(l*r>>1)+720)%360;--r;)n.h=(n.h+l)%360,a.push(new e(n));return a},e.prototype.complement=function(){var r=this.toHsl();return r.h=(r.h+180)%360,new e(r)},e.prototype.monochromatic=function(r){r===void 0&&(r=6);for(var t=this.toHsv(),n=t.h,l=t.s,a=t.v,o=[],u=1/r;r--;)o.push(new e({h:n,s:l,v:a})),a=(a+u)%1;return o},e.prototype.splitcomplement=function(){var r=this.toHsl(),t=r.h;return[this,new e({h:(t+72)%360,s:r.s,l:r.l}),new e({h:(t+216)%360,s:r.s,l:r.l})]},e.prototype.onBackground=function(r){var t=this.toRgb(),n=new e(r).toRgb(),l=t.a+n.a*(1-t.a);return new e({r:(t.r*t.a+n.r*n.a*(1-t.a))/l,g:(t.g*t.a+n.g*n.a*(1-t.a))/l,b:(t.b*t.a+n.b*n.a*(1-t.a))/l,a:l})},e.prototype.triad=function(){return this.polyad(3)},e.prototype.tetrad=function(){return this.polyad(4)},e.prototype.polyad=function(r){for(var t=this.toHsl(),n=t.h,l=[this],a=360/r,o=1;o<r;o++)l.push(new e({h:(n+o*a)%360,s:t.s,l:t.l}));return l},e.prototype.equals=function(r){return this.toRgbString()===new e(r).toRgbString()},e}();function Dt(e,r=20){return e.mix("#141414",r).toString()}function ny(e){const r=T0(),t=Sr("button");return N.computed(()=>{let n={},l=e.color;if(l){const a=l.match(/var\((.*?)\)/);a&&(l=window.getComputedStyle(window.document.documentElement).getPropertyValue(a[1]));const o=new ry(l),u=e.dark?o.tint(20).toString():Dt(o,20);if(e.plain)n=t.cssVarBlock({"bg-color":e.dark?Dt(o,90):o.tint(90).toString(),"text-color":l,"border-color":e.dark?Dt(o,50):o.tint(50).toString(),"hover-text-color":`var(${t.cssVarName("color-white")})`,"hover-bg-color":l,"hover-border-color":l,"active-bg-color":u,"active-text-color":`var(${t.cssVarName("color-white")})`,"active-border-color":u}),r.value&&(n[t.cssVarBlockName("disabled-bg-color")]=e.dark?Dt(o,90):o.tint(90).toString(),n[t.cssVarBlockName("disabled-text-color")]=e.dark?Dt(o,50):o.tint(50).toString(),n[t.cssVarBlockName("disabled-border-color")]=e.dark?Dt(o,80):o.tint(80).toString());else{const p=e.dark?Dt(o,30):o.tint(30).toString(),s=o.isDark()?`var(${t.cssVarName("color-white")})`:`var(${t.cssVarName("color-black")})`;if(n=t.cssVarBlock({"bg-color":l,"text-color":s,"border-color":l,"hover-bg-color":p,"hover-text-color":s,"hover-border-color":p,"active-bg-color":u,"active-border-color":u}),r.value){const i=e.dark?Dt(o,50):o.tint(50).toString();n[t.cssVarBlockName("disabled-bg-color")]=i,n[t.cssVarBlockName("disabled-text-color")]=e.dark?"rgba(255, 255, 255, 0.5)":`var(${t.cssVarName("color-white")})`,n[t.cssVarBlockName("disabled-border-color")]=i}}}return n})}const iy=N.defineComponent({name:"ElButton"}),oy=N.defineComponent(_e(he({},iy),{props:Qo,emits:jv,setup(e,{expose:r,emit:t}){const n=e,l=ny(n),a=Sr("button"),{_ref:o,_size:u,_type:p,_disabled:s,_props:i,_plain:d,_round:c,_text:f,shouldAddSpace:h,handleClick:v}=qv(n,t),m=N.computed(()=>[a.b(),a.m(p.value),a.m(u.value),a.is("disabled",s.value),a.is("loading",n.loading),a.is("plain",d.value),a.is("round",c.value),a.is("circle",n.circle),a.is("text",f.value),a.is("link",n.link),a.is("has-bg",n.bg)]);return r({ref:o,size:u,type:p,disabled:s,shouldAddSpace:h}),(g,x)=>(N.openBlock(),N.createBlock(N.resolveDynamicComponent(g.tag),N.mergeProps({ref_key:"_ref",ref:o},N.unref(i),{class:N.unref(m),style:N.unref(l),onClick:N.unref(v)}),{default:N.withCtx(()=>[g.loading?(N.openBlock(),N.createElementBlock(N.Fragment,{key:0},[g.$slots.loading?N.renderSlot(g.$slots,"loading",{key:0}):(N.openBlock(),N.createBlock(N.unref(_r),{key:1,class:N.normalizeClass(N.unref(a).is("loading"))},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(g.loadingIcon)))]),_:1},8,["class"]))],64)):g.icon||g.$slots.icon?(N.openBlock(),N.createBlock(N.unref(_r),{key:1},{default:N.withCtx(()=>[g.icon?(N.openBlock(),N.createBlock(N.resolveDynamicComponent(g.icon),{key:0})):N.renderSlot(g.$slots,"icon",{key:1})]),_:3})):N.createCommentVNode("v-if",!0),g.$slots.default?(N.openBlock(),N.createElementBlock("span",{key:2,class:N.normalizeClass({[N.unref(a).em("text","expand")]:N.unref(h)})},[N.renderSlot(g.$slots,"default")],2)):N.createCommentVNode("v-if",!0)]),_:3},16,["class","style","onClick"]))}}));var ay=Br(oy,[["__file","button.vue"]]);const sy={size:Qo.size,type:Qo.type,direction:{type:Me(String),values:["horizontal","vertical"],default:"horizontal"}},ly=N.defineComponent({name:"ElButtonGroup"}),uy=N.defineComponent(_e(he({},ly),{props:sy,setup(e){const r=e;N.provide(I0,N.reactive({size:N.toRef(r,"size"),type:N.toRef(r,"type")}));const t=Sr("button");return(n,l)=>(N.openBlock(),N.createElementBlock("div",{class:N.normalizeClass([N.unref(t).b("group"),N.unref(t).bm("group",r.direction)])},[N.renderSlot(n.$slots,"default")],2))}}));var R0=Br(uy,[["__file","button-group.vue"]]);const cy=ga(ay,{ButtonGroup:R0});dv(R0);var O0={exports:{}};(function(e,r){(function(t,n){e.exports=n()})(xe,function(){var t=1e3,n=6e4,l=36e5,a="millisecond",o="second",u="minute",p="hour",s="day",i="week",d="month",c="quarter",f="year",h="date",v="Invalid Date",m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,g=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,x={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(F){var j=["th","st","nd","rd"],P=F%100;return"["+F+(j[(P-20)%10]||j[P]||j[0])+"]"}},y=function(F,j,P){var J=String(F);return!J||J.length>=j?F:""+Array(j+1-J.length).join(P)+F},w={s:y,z:function(F){var j=-F.utcOffset(),P=Math.abs(j),J=Math.floor(P/60),$=P%60;return(j<=0?"+":"-")+y(J,2,"0")+":"+y($,2,"0")},m:function F(j,P){if(j.date()<P.date())return-F(P,j);var J=12*(P.year()-j.year())+(P.month()-j.month()),$=j.clone().add(J,d),U=P-$<0,K=j.clone().add(J+(U?-1:1),d);return+(-(J+(P-$)/(U?$-K:K-$))||0)},a:function(F){return F<0?Math.ceil(F)||0:Math.floor(F)},p:function(F){return{M:d,y:f,w:i,d:s,D:h,h:p,m:u,s:o,ms:a,Q:c}[F]||String(F||"").toLowerCase().replace(/s$/,"")},u:function(F){return F===void 0}},k="en",T={};T[k]=x;var I="$isDayjsObject",D=function(F){return F instanceof A||!(!F||!F[I])},X=function F(j,P,J){var $;if(!j)return k;if(typeof j=="string"){var U=j.toLowerCase();T[U]&&($=U),P&&(T[U]=P,$=U);var K=j.split("-");if(!$&&K.length>1)return F(K[0])}else{var L=j.name;T[L]=j,$=L}return!J&&$&&(k=$),$||!J&&k},V=function(F,j){if(D(F))return F.clone();var P=typeof j=="object"?j:{};return P.date=F,P.args=arguments,new A(P)},E=w;E.l=X,E.i=D,E.w=function(F,j){return V(F,{locale:j.$L,utc:j.$u,x:j.$x,$offset:j.$offset})};var A=function(){function F(P){this.$L=X(P.locale,null,!0),this.parse(P),this.$x=this.$x||P.x||{},this[I]=!0}var j=F.prototype;return j.parse=function(P){this.$d=function(J){var $=J.date,U=J.utc;if($===null)return new Date(NaN);if(E.u($))return new Date;if($ instanceof Date)return new Date($);if(typeof $=="string"&&!/Z$/i.test($)){var K=$.match(m);if(K){var L=K[2]-1||0,O=(K[7]||"0").substring(0,3);return U?new Date(Date.UTC(K[1],L,K[3]||1,K[4]||0,K[5]||0,K[6]||0,O)):new Date(K[1],L,K[3]||1,K[4]||0,K[5]||0,K[6]||0,O)}}return new Date($)}(P),this.init()},j.init=function(){var P=this.$d;this.$y=P.getFullYear(),this.$M=P.getMonth(),this.$D=P.getDate(),this.$W=P.getDay(),this.$H=P.getHours(),this.$m=P.getMinutes(),this.$s=P.getSeconds(),this.$ms=P.getMilliseconds()},j.$utils=function(){return E},j.isValid=function(){return this.$d.toString()!==v},j.isSame=function(P,J){var $=V(P);return this.startOf(J)<=$&&$<=this.endOf(J)},j.isAfter=function(P,J){return V(P)<this.startOf(J)},j.isBefore=function(P,J){return this.endOf(J)<V(P)},j.$g=function(P,J,$){return E.u(P)?this[J]:this.set($,P)},j.unix=function(){return Math.floor(this.valueOf()/1e3)},j.valueOf=function(){return this.$d.getTime()},j.startOf=function(P,J){var $=this,U=!!E.u(J)||J,K=E.p(P),L=function(b,_){var R=E.w($.$u?Date.UTC($.$y,_,b):new Date($.$y,_,b),$);return U?R:R.endOf(s)},O=function(b,_){return E.w($.toDate()[b].apply($.toDate("s"),(U?[0,0,0,0]:[23,59,59,999]).slice(_)),$)},H=this.$W,W=this.$M,Z=this.$D,re="set"+(this.$u?"UTC":"");switch(K){case f:return U?L(1,0):L(31,11);case d:return U?L(1,W):L(0,W+1);case i:var oe=this.$locale().weekStart||0,ae=(H<oe?H+7:H)-oe;return L(U?Z-ae:Z+(6-ae),W);case s:case h:return O(re+"Hours",0);case p:return O(re+"Minutes",1);case u:return O(re+"Seconds",2);case o:return O(re+"Milliseconds",3);default:return this.clone()}},j.endOf=function(P){return this.startOf(P,!1)},j.$set=function(P,J){var $,U=E.p(P),K="set"+(this.$u?"UTC":""),L=($={},$[s]=K+"Date",$[h]=K+"Date",$[d]=K+"Month",$[f]=K+"FullYear",$[p]=K+"Hours",$[u]=K+"Minutes",$[o]=K+"Seconds",$[a]=K+"Milliseconds",$)[U],O=U===s?this.$D+(J-this.$W):J;if(U===d||U===f){var H=this.clone().set(h,1);H.$d[L](O),H.init(),this.$d=H.set(h,Math.min(this.$D,H.daysInMonth())).$d}else L&&this.$d[L](O);return this.init(),this},j.set=function(P,J){return this.clone().$set(P,J)},j.get=function(P){return this[E.p(P)]()},j.add=function(P,J){var $,U=this;P=Number(P);var K=E.p(J),L=function(W){var Z=V(U);return E.w(Z.date(Z.date()+Math.round(W*P)),U)};if(K===d)return this.set(d,this.$M+P);if(K===f)return this.set(f,this.$y+P);if(K===s)return L(1);if(K===i)return L(7);var O=($={},$[u]=n,$[p]=l,$[o]=t,$)[K]||1,H=this.$d.getTime()+P*O;return E.w(H,this)},j.subtract=function(P,J){return this.add(-1*P,J)},j.format=function(P){var J=this,$=this.$locale();if(!this.isValid())return $.invalidDate||v;var U=P||"YYYY-MM-DDTHH:mm:ssZ",K=E.z(this),L=this.$H,O=this.$m,H=this.$M,W=$.weekdays,Z=$.months,re=$.meridiem,oe=function(_,R,G,ee){return _&&(_[R]||_(J,U))||G[R].slice(0,ee)},ae=function(_){return E.s(L%12||12,_,"0")},b=re||function(_,R,G){var ee=_<12?"AM":"PM";return G?ee.toLowerCase():ee};return U.replace(g,function(_,R){return R||function(G){switch(G){case"YY":return String(J.$y).slice(-2);case"YYYY":return E.s(J.$y,4,"0");case"M":return H+1;case"MM":return E.s(H+1,2,"0");case"MMM":return oe($.monthsShort,H,Z,3);case"MMMM":return oe(Z,H);case"D":return J.$D;case"DD":return E.s(J.$D,2,"0");case"d":return String(J.$W);case"dd":return oe($.weekdaysMin,J.$W,W,2);case"ddd":return oe($.weekdaysShort,J.$W,W,3);case"dddd":return W[J.$W];case"H":return String(L);case"HH":return E.s(L,2,"0");case"h":return ae(1);case"hh":return ae(2);case"a":return b(L,O,!0);case"A":return b(L,O,!1);case"m":return String(O);case"mm":return E.s(O,2,"0");case"s":return String(J.$s);case"ss":return E.s(J.$s,2,"0");case"SSS":return E.s(J.$ms,3,"0");case"Z":return K}return null}(_)||K.replace(":","")})},j.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},j.diff=function(P,J,$){var U,K=this,L=E.p(J),O=V(P),H=(O.utcOffset()-this.utcOffset())*n,W=this-O,Z=function(){return E.m(K,O)};switch(L){case f:U=Z()/12;break;case d:U=Z();break;case c:U=Z()/3;break;case i:U=(W-H)/6048e5;break;case s:U=(W-H)/864e5;break;case p:U=W/l;break;case u:U=W/n;break;case o:U=W/t;break;default:U=W}return $?U:E.a(U)},j.daysInMonth=function(){return this.endOf(d).$D},j.$locale=function(){return T[this.$L]},j.locale=function(P,J){if(!P)return this.$L;var $=this.clone(),U=X(P,J,!0);return U&&($.$L=U),$},j.clone=function(){return E.w(this.$d,this)},j.toDate=function(){return new Date(this.valueOf())},j.toJSON=function(){return this.isValid()?this.toISOString():null},j.toISOString=function(){return this.$d.toISOString()},j.toString=function(){return this.$d.toUTCString()},F}(),C=A.prototype;return V.prototype=C,[["$ms",a],["$s",o],["$m",u],["$H",p],["$W",s],["$M",d],["$y",f],["$D",h]].forEach(function(F){C[F[1]]=function(j){return this.$g(j,F[0],F[1])}}),V.extend=function(F,j){return F.$i||(F(j,A,V),F.$i=!0),V},V.locale=X,V.isDayjs=D,V.unix=function(F){return V(1e3*F)},V.en=T[k],V.Ls=T,V.p={},V})})(O0);var fy=O0.exports;const hy=Zo(fy),py=ir(he({a11y:{type:Boolean,default:!0},locale:{type:Me(Object)},size:b0,button:{type:Me(Object)},card:{type:Me(Object)},dialog:{type:Me(Object)},link:{type:Me(Object)},experimentalFeatures:{type:Me(Object)},keyboardNavigation:{type:Boolean,default:!0},message:{type:Me(Object)},zIndex:Number,namespace:{type:String,default:"el"}},fv)),We={placement:"top"};N.defineComponent({name:"ElConfigProvider",props:py,setup(e,{slots:r}){const t=E0(e);return N.watch(()=>e.message,n=>{var l,a;Object.assign(We,(a=(l=t==null?void 0:t.value)==null?void 0:l.message)!=null?a:{},n!=null?n:{})},{immediate:!0,deep:!0}),()=>N.renderSlot(r,"default",{config:t==null?void 0:t.value})}});const P0=["primary","success","info","warning","error"],N0=["top","top-left","top-right","bottom","bottom-left","bottom-right"],vr="top",Ve=Fv({customClass:"",dangerouslyUseHTMLString:!1,duration:3e3,icon:void 0,id:"",message:"",onClose:void 0,showClose:!1,type:"info",plain:!1,offset:16,placement:void 0,zIndex:0,grouping:!1,repeatNum:1,appendTo:Mt?document.body:void 0}),dy=ir({customClass:{type:String,default:Ve.customClass},dangerouslyUseHTMLString:{type:Boolean,default:Ve.dangerouslyUseHTMLString},duration:{type:Number,default:Ve.duration},icon:{type:jr,default:Ve.icon},id:{type:String,default:Ve.id},message:{type:Me([String,Object,Function]),default:Ve.message},onClose:{type:Me(Function),default:Ve.onClose},showClose:{type:Boolean,default:Ve.showClose},type:{type:String,values:P0,default:Ve.type},plain:{type:Boolean,default:Ve.plain},offset:{type:Number,default:Ve.offset},placement:{type:String,values:N0,default:Ve.placement},zIndex:{type:Number,default:Ve.zIndex},grouping:{type:Boolean,default:Ve.grouping},repeatNum:{type:Number,default:Ve.repeatNum}}),my={destroy:()=>!0},ht=N.shallowReactive({}),vy=e=>(ht[e]||(ht[e]=N.shallowReactive([])),ht[e]),yy=(e,r)=>{const t=ht[r]||[],n=t.findIndex(o=>o.id===e),l=t[n];let a;return n>0&&(a=t[n-1]),{current:l,prev:a}},gy=(e,r)=>{const{prev:t}=yy(e,r);return t?t.vm.exposed.bottom.value:0},xy=(e,r,t)=>(ht[t]||[]).findIndex(a=>a.id===e)>0?16:r,by=N.defineComponent({name:"ElMessage"}),wy=N.defineComponent(_e(he({},by),{props:dy,emits:my,setup(e,{expose:r,emit:t}){const n=e,{Close:l}=kv,a=N.ref(!1),{ns:o,zIndex:u}=_0("message"),{currentZIndex:p,nextZIndex:s}=u,i=N.ref(),d=N.ref(!1),c=N.ref(0);let f;const h=N.computed(()=>n.type?n.type==="error"?"danger":n.type:"info"),v=N.computed(()=>{const A=n.type;return{[o.bm("icon",A)]:A&&Un[A]}}),m=N.computed(()=>n.icon||Un[n.type]||""),g=N.computed(()=>n.placement||vr),x=N.computed(()=>gy(n.id,g.value)),y=N.computed(()=>xy(n.id,n.offset,g.value)+x.value),w=N.computed(()=>c.value+y.value),k=N.computed(()=>g.value.includes("left")?o.is("left"):g.value.includes("right")?o.is("right"):o.is("center")),T=N.computed(()=>g.value.startsWith("top")?"top":"bottom"),I=N.computed(()=>({[T.value]:`${y.value}px`,zIndex:p.value}));function D(){n.duration!==0&&({stop:f}=f0(()=>{V()},n.duration))}function X(){f==null||f()}function V(){d.value=!1,N.nextTick(()=>{var A;a.value||((A=n.onClose)==null||A.call(n),t("destroy"))})}function E(A){F0(A)===mr.esc&&V()}return N.onMounted(()=>{D(),s(),d.value=!0}),N.watch(()=>n.repeatNum,()=>{X(),D()}),d0(document,"keydown",E),Gm(i,()=>{c.value=i.value.getBoundingClientRect().height}),r({visible:d,bottom:w,close:V}),(A,C)=>(N.openBlock(),N.createBlock(N.Transition,{name:N.unref(o).b("fade"),onBeforeEnter:F=>a.value=!0,onBeforeLeave:A.onClose,onAfterLeave:F=>A.$emit("destroy"),persisted:""},{default:N.withCtx(()=>[N.withDirectives(N.createElementVNode("div",{id:A.id,ref_key:"messageRef",ref:i,class:N.normalizeClass([N.unref(o).b(),{[N.unref(o).m(A.type)]:A.type},N.unref(o).is("closable",A.showClose),N.unref(o).is("plain",A.plain),N.unref(o).is("bottom",N.unref(T)==="bottom"),N.unref(k),A.customClass]),style:N.normalizeStyle(N.unref(I)),role:"alert",onMouseenter:X,onMouseleave:D},[A.repeatNum>1?(N.openBlock(),N.createBlock(N.unref(Lv),{key:0,value:A.repeatNum,type:N.unref(h),class:N.normalizeClass(N.unref(o).e("badge"))},null,8,["value","type","class"])):N.createCommentVNode("v-if",!0),N.unref(m)?(N.openBlock(),N.createBlock(N.unref(_r),{key:1,class:N.normalizeClass([N.unref(o).e("icon"),N.unref(v)])},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(N.unref(m))))]),_:1},8,["class"])):N.createCommentVNode("v-if",!0),N.renderSlot(A.$slots,"default",{},()=>[A.dangerouslyUseHTMLString?(N.openBlock(),N.createElementBlock(N.Fragment,{key:1},[N.createCommentVNode(" Caution here, message could've been compromised, never use user's input as message "),N.createElementVNode("p",{class:N.normalizeClass(N.unref(o).e("content")),innerHTML:A.message},null,10,["innerHTML"])],2112)):(N.openBlock(),N.createElementBlock("p",{key:0,class:N.normalizeClass(N.unref(o).e("content"))},N.toDisplayString(A.message),3))]),A.showClose?(N.openBlock(),N.createBlock(N.unref(_r),{key:2,class:N.normalizeClass(N.unref(o).e("closeBtn")),onClick:N.withModifiers(V,["stop"])},{default:N.withCtx(()=>[N.createVNode(N.unref(l))]),_:1},8,["class","onClick"])):N.createCommentVNode("v-if",!0)],46,["id"]),[[N.vShow,d.value]])]),_:3},8,["name","onBeforeEnter","onBeforeLeave","onAfterLeave"]))}}));var _y=Br(wy,[["__file","message.vue"]]);let Ey=1;const Ay=e=>{if(!e.appendTo)e.appendTo=document.body;else if(Bt(e.appendTo)){let t=document.querySelector(e.appendTo);Ko(t)||(nr("ElMessage","the appendTo option is not an HTMLElement. Falling back to document.body."),t=document.body),e.appendTo=t}},Cy=e=>{!e.placement&&Bt(We.placement)&&We.placement&&(e.placement=We.placement),e.placement||(e.placement=vr),N0.includes(e.placement)||(nr("ElMessage",`Invalid placement: ${e.placement}. Falling back to '${vr}'.`),e.placement=vr)},M0=e=>{const r=!e||Bt(e)||N.isVNode(e)||zr(e)?{message:e}:e,t=he(he({},Ve),r);return Ay(t),Cy(t),To(We.grouping)&&!t.grouping&&(t.grouping=We.grouping),Xt(We.duration)&&t.duration===3e3&&(t.duration=We.duration),Xt(We.offset)&&t.offset===16&&(t.offset=We.offset),To(We.showClose)&&!t.showClose&&(t.showClose=We.showClose),To(We.plain)&&!t.plain&&(t.plain=We.plain),t},Sy=e=>{const r=e.props.placement||vr,t=ht[r],n=t.indexOf(e);if(n===-1)return;t.splice(n,1);const{handler:l}=e;l.close()},By=(n,t)=>{var l=n,{appendTo:e}=l,r=ka(l,["appendTo"]);const a=`message_${Ey++}`,o=r.onClose,u=document.createElement("div"),p=_e(he({},r),{id:a,onClose:()=>{o==null||o(),Sy(c)},onDestroy:()=>{N.render(null,u)}}),s=N.createVNode(_y,p,zr(p.message)||N.isVNode(p.message)?{default:zr(p.message)?p.message:()=>p.message}:null);s.appContext=t||Zt._context,N.render(s,u),e.appendChild(u.firstElementChild);const i=s.component,c={id:a,vnode:s,vm:i,handler:{close:()=>{i.exposed.close()}},props:s.component.props};return c},Zt=(e={},r)=>{if(!Mt)return{close:()=>{}};const t=M0(e),n=vy(t.placement||vr);if(t.grouping&&n.length){const a=n.find(({vnode:o})=>{var u;return((u=o.props)==null?void 0:u.message)===t.message});if(a)return a.props.repeatNum+=1,a.props.type=t.type,a.handler}if(Xt(We.max)&&n.length>=We.max)return{close:()=>{}};const l=By(t,r);return n.push(l),l.handler};P0.forEach(e=>{Zt[e]=(r={},t)=>{const n=M0(r);return Zt(_e(he({},n),{type:e}),t)}});function ky(e){for(const r in ht)if(Wo(ht,r)){const t=[...ht[r]];for(const n of t)(!e||e===n.props.type)&&n.handler.close()}}function Ty(e){if(!ht[e])return;[...ht[e]].forEach(t=>t.handler.close())}Zt.closeAll=ky;Zt.closeAllByPlacement=Ty;Zt._context=null;const st=A0(Zt,"$message"),L0=["primary","success","info","warning","error"],Fy=ir({customClass:{type:String,default:""},dangerouslyUseHTMLString:Boolean,duration:{type:Number,default:4500},icon:{type:jr},id:{type:String,default:""},message:{type:Me([String,Object,Function]),default:""},offset:{type:Number,default:0},onClick:{type:Me(Function),default:()=>{}},onClose:{type:Me(Function),required:!0},position:{type:String,values:["top-right","top-left","bottom-right","bottom-left"],default:"top-right"},showClose:{type:Boolean,default:!0},title:{type:String,default:""},type:{type:String,values:[...L0,""],default:""},zIndex:Number,closeIcon:{type:jr,default:C0}}),Iy={destroy:()=>!0},Dy=N.defineComponent({name:"ElNotification"}),Ry=N.defineComponent(_e(he({},Dy),{props:Fy,emits:Iy,setup(e,{expose:r}){const t=e,{ns:n,zIndex:l}=_0("notification"),{nextZIndex:a,currentZIndex:o}=l,u=N.ref(!1);let p;const s=N.computed(()=>{const x=t.type;return x&&Un[t.type]?n.m(x):""}),i=N.computed(()=>t.type&&Un[t.type]||t.icon),d=N.computed(()=>t.position.endsWith("right")?"right":"left"),c=N.computed(()=>t.position.startsWith("top")?"top":"bottom"),f=N.computed(()=>{var x;return{[c.value]:`${t.offset}px`,zIndex:(x=t.zIndex)!=null?x:o.value}});function h(){t.duration>0&&({stop:p}=f0(()=>{u.value&&m()},t.duration))}function v(){p==null||p()}function m(){u.value=!1}function g(x){switch(F0(x)){case mr.delete:case mr.backspace:v();break;case mr.esc:u.value&&m();break;default:h();break}}return N.onMounted(()=>{h(),a(),u.value=!0}),d0(document,"keydown",g),r({visible:u,close:m}),(x,y)=>(N.openBlock(),N.createBlock(N.Transition,{name:N.unref(n).b("fade"),onBeforeLeave:x.onClose,onAfterLeave:w=>x.$emit("destroy"),persisted:""},{default:N.withCtx(()=>[N.withDirectives(N.createElementVNode("div",{id:x.id,class:N.normalizeClass([N.unref(n).b(),x.customClass,N.unref(d)]),style:N.normalizeStyle(N.unref(f)),role:"alert",onMouseenter:v,onMouseleave:h,onClick:x.onClick},[N.unref(i)?(N.openBlock(),N.createBlock(N.unref(_r),{key:0,class:N.normalizeClass([N.unref(n).e("icon"),N.unref(s)])},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(N.unref(i))))]),_:1},8,["class"])):N.createCommentVNode("v-if",!0),N.createElementVNode("div",{class:N.normalizeClass(N.unref(n).e("group"))},[N.createElementVNode("h2",{class:N.normalizeClass(N.unref(n).e("title")),textContent:N.toDisplayString(x.title)},null,10,["textContent"]),N.withDirectives(N.createElementVNode("div",{class:N.normalizeClass(N.unref(n).e("content")),style:N.normalizeStyle(x.title?void 0:{margin:0})},[N.renderSlot(x.$slots,"default",{},()=>[x.dangerouslyUseHTMLString?(N.openBlock(),N.createElementBlock(N.Fragment,{key:1},[N.createCommentVNode(" Caution here, message could've been compromised, never use user's input as message "),N.createElementVNode("p",{innerHTML:x.message},null,8,["innerHTML"])],2112)):(N.openBlock(),N.createElementBlock("p",{key:0},N.toDisplayString(x.message),1))])],6),[[N.vShow,x.message]]),x.showClose?(N.openBlock(),N.createBlock(N.unref(_r),{key:0,class:N.normalizeClass(N.unref(n).e("closeBtn")),onClick:N.withModifiers(m,["stop"])},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(x.closeIcon)))]),_:1},8,["class","onClick"])):N.createCommentVNode("v-if",!0)],2)],46,["id","onClick"]),[[N.vShow,u.value]])]),_:3},8,["name","onBeforeLeave","onAfterLeave"]))}}));var Oy=Br(Ry,[["__file","notification.vue"]]);const Er={"top-left":[],"top-right":[],"bottom-left":[],"bottom-right":[]},qn=16;let Py=1;const Jt=function(e={},r){if(!Mt)return{close:()=>{}};(Bt(e)||N.isVNode(e))&&(e={message:e});const t=e.position||"top-right";let n=e.offset||0;Er[t].forEach(({vm:i})=>{var d;n+=(((d=i.el)==null?void 0:d.offsetHeight)||0)+qn}),n+=qn;const l=`notification_${Py++}`,a=e.onClose,o=_e(he({},e),{offset:n,id:l,onClose:()=>{Ny(l,t,a)}});let u=document.body;Ko(e.appendTo)?u=e.appendTo:Bt(e.appendTo)&&(u=document.querySelector(e.appendTo)),Ko(u)||(nr("ElNotification","the appendTo option is not an HTMLElement. Falling back to document.body."),u=document.body);const p=document.createElement("div"),s=N.createVNode(Oy,o,zr(o.message)?o.message:N.isVNode(o.message)?()=>o.message:null);return s.appContext=Lm(r)?Jt._context:r,s.props.onDestroy=()=>{N.render(null,p)},N.render(s,p),Er[t].push({vm:s}),u.appendChild(p.firstElementChild),{close:()=>{s.component.exposed.visible.value=!1}}};L0.forEach(e=>{Jt[e]=(r={},t)=>((Bt(r)||N.isVNode(r))&&(r={message:r}),Jt(_e(he({},r),{type:e}),t))});function Ny(e,r,t){const n=Er[r],l=n.findIndex(({vm:s})=>{var i;return((i=s.component)==null?void 0:i.props.id)===e});if(l===-1)return;const{vm:a}=n[l];if(!a)return;t==null||t(a);const o=a.el.offsetHeight,u=r.split("-")[0];n.splice(l,1);const p=n.length;if(!(p<1))for(let s=l;s<p;s++){const{el:i,component:d}=n[s].vm,c=Number.parseInt(i.style[u],10)-o-qn;d.props.offset=c}}function My(){for(const e of Object.values(Er))e.forEach(({vm:r})=>{r.component.exposed.visible.value=!1})}function Ly(e="top-right"){var r,t,n,l;let a=((n=(t=(r=Er[e][0])==null?void 0:r.vm.component)==null?void 0:t.props)==null?void 0:n.offset)||0;for(const{vm:o}of Er[e])o.component.props.offset=a,a+=(((l=o.el)==null?void 0:l.offsetHeight)||0)+qn}Jt.closeAll=My;Jt.updateOffsets=Ly;Jt._context=null;const Uy=A0(Jt,"$notify"),U0="0123456789abcdeffedcba9876543210",q0="4b0de988570c3a0f",qy=window.ENCRYPT;let yr=qy&&new s0;function $0(e=16,r="0123456789abcdefghijklmnopqrstuvwxyz"){let t="",n=r.length;for(;e>0;)t+=r[Math.floor(Math.random()*n)],e--;return t}function z0(){return je(this,null,function*(){return yr||(yr=new s0),new Promise((e,r)=>{yr.armEnum().then(t=>{e(+t)}).catch(t=>{st({type:"warning",ElMessage:"未找到U盘锁,请检查U盘锁!"}),r(t)})})})}$n.throttle(()=>je(exports,null,function*(){const e=yield z0(),r={};if(typeof e!="number"||e<=0)st({type:"warning",ElMessage:"未找到U盘锁,请检查U盘锁!"}),r.resetToken();else{const t=yield zy();if(!r.token)return;t.length?t.includes(r.ukeyHid)||(st({type:"error",ElMessage:"U盘锁不匹配,请检查U盘锁!"}),r.resetToken()):(st({type:"warning",ElMessage:"未找到U盘锁,请检查U盘锁!"}),r.resetToken())}}),5e3,{trailing:!1});function $y(e=0){return je(this,null,function*(){return yr?new Promise((r,t)=>{yr.armGetDongleInfo(e).then(n=>{n?r(n):(st({type:"warning",ElMessage:"U盘锁信息为空,请检查U盘锁!"}),t(n))}).catch(n=>{t(n)})}):st({type:"warning",ElMessage:"未找到U盘锁程序,请检查后台程序!"})})}function zy(){return je(this,null,function*(){if(!yr)return st({type:"warning",ElMessage:"未找到U盘锁程序,请检查后台程序!"});const e=yield z0();let r=[];for(let t=0;t<e;t++){const n=yield $y(t);r.push(n)}return r})}$0(16);$0(16);const j0=window.meta.app.inspect?wr.constants.CBC:wr.constants.ECB;Bm.generateKeyPair();function Il(e,r,t={}){const n=H0(q0),l=t.mode||j0;t=l===wr.constants.ECB?he({mode:l,inputEncoding:"utf8",outputEncoding:"hex"},t):he({iv:U0,mode:l,inputEncoding:"utf8",outputEncoding:"hex"},t);let a="";try{a=wr.encrypt(e,n,t)}catch(o){console.log("err: ",o)}return a}function Dl(e,r,t={}){const n=H0(q0),l=t.mode||j0;return t=l===wr.constants.ECB?he({mode:l,inputEncoding:"hex",outputEncoding:"utf8"},t):he({iv:U0,mode:l,inputEncoding:"hex",outputEncoding:"utf8"},t),wr.decrypt(e,n,t)}function H0(e){return[...e].map(r=>r.charCodeAt().toString(16)).join("")}const Rl={getLocal:e=>{try{let r=window.localStorage.getItem(e);return r=r!==null?Dl(r):r,JSON.parse(r)}catch(r){console.error(r)}},setLocal:(e,r)=>{try{let t=JSON.stringify(r);t=t!==null?Il(t):t,window.localStorage.setItem(e,t)}catch(t){console.error(t)}},eachLocal:e=>{if(!e||Cs(e)!=="Function")return console.error("传递参数非函数类型!");for(let r=0,t=window.localStorage.length;r<t;r++){const n=window.localStorage.key(r);e((void 0).getLocal(n),n)}},clearLocal:()=>{window.localStorage.clear()},removeLocal:e=>{window.localStorage.removeItem(e)},getSession:e=>{try{let r=window.sessionStorage.getItem(e);return r=r!==null?Dl(r):r,JSON.parse(r)}catch(r){console.error(r)}},setSession:(e,r)=>{try{let t=JSON.stringify(r);t=t!==null?Il(t):t,window.sessionStorage.setItem(e,t)}catch(t){console.error(t)}},eachSession:e=>{if(!e||Cs(e)!=="Function")return console.error("传递参数非函数类型!");for(let r=0,t=window.sessionStorage.length;r<t;r++){const n=window.sessionStorage.key(r);e((void 0).getSession(n),n)}},clearSession:()=>{window.sessionStorage.clear()},removeSession:e=>{window.sessionStorage.removeItem(e)}},Ol=e=>{const{quality:r,value:t,function_id:n}=e;return(r>>7&1)===1||r===0&&n===2&&t===1},Pl="USER_TOKEN",Nl="STATION_ID",jy=[{key:0,value:"离线"},{key:1,value:"在线"}],Hy=[{key:0,value:"反向"},{key:1,value:"正向"},{key:2,value:"停止"}],Vy=[{key:1,value:1},{key:2,value:2},{key:3,value:3},{key:4,value:4},{key:5,value:5}],Ct=window.meta.graph.penFormMap?window.meta.graph.penFormMap:{NORMAL:[{name:"颜色",key:"color",type:"color",dataIds:{}}],TEXT:[{name:"显示内容",key:"text",type:"text",dataIds:{}}],AUDIO:[{name:"颜色",key:"color",type:"color",dataIds:{}}],MP4:[{name:"颜色",key:"color",type:"color",dataIds:{}}],CAMERA:[{name:"颜色",key:"color",type:"color",dataIds:{}}],VIDEO_STREAM:[{name:"颜色",key:"color",type:"color",dataIds:{}}],POINT_VALUE:[{name:"在线状态",key:"online_state",type:"select",dataIds:{},options:[{label:"在线",value:1},{label:"离线",value:0}]},{name:"测点值",key:"point_value",type:"text",dataIds:{}}],LIGHT_PLATE:[{name:"光字牌",key:"light_plate",type:"select",dataIds:{},options:[{label:"离线",value:-1},{label:"正常",value:0},{label:"预警",value:1},{label:"一般",value:2},{label:"严重",value:3},{label:"危急",value:4}]}]},V0=window.meta.graph.lightPlateColorMap?window.meta.graph.lightPlateColorMap:{0:"#00d200",1:"#e2ac06",2:"#fa800a",3:"#f04155",4:"#ff0000"},W0=window.meta.graph.lightPlateTextMap?window.meta.graph.lightPlateTextMap:{0:"#fff",1:"#fff",2:"#fff",3:"#fff",4:"#fff"},Oe={form:[{name:"带电状态",key:"charged_state",type:"select",dataIds:{},options:jy.map(e=>({label:e.value,value:e.key}))},{name:"潮流方向",key:"electric_direction",type:"select",dataIds:{},options:Hy.map(e=>({label:e.value,value:e.key}))},{name:"电荷大小",key:"electric_size",type:"select",dataIds:{},options:Vy.map(e=>({label:e.value,value:e.key}))}],anchors:[{x:0,y:.5,id:"0"},{x:.5,y:0,id:"1"},{x:1,y:.5,id:"2"},{x:.5,y:1,id:"3"}],dataType:window.dataType,dataProp:window.dataProp,visibleLevel:window.visibleLevel},ye=_e(he({penType:Se.NORMAL},Oe),{form:[...Ct[Se.NORMAL],...Oe.form]});Se.POINT_VALUE,Oe.anchors,window.visibleLevel,[...Ct[Se.POINT_VALUE],...Oe.form],Oe.form,window.dataType,window.dataProp,window.visibleLevel,Oe.form,window.dataType,window.dataProp,window.visibleLevel,W0[0],Se.LIGHT_PLATE,V0[0],Oe.anchors,window.visibleLevel,[...Ct[Se.LIGHT_PLATE],...Oe.form],Se.SENSOR,Oe.anchors,window.visibleLevel,[...Ct[Se.LIGHT_PLATE],...Oe.form],_e(he({width:100,height:30,name:"text",text:"文本",disableAnchor:!0,penType:Se.TEXT},Oe),{form:[...Ct[Se.TEXT],...Oe.form]}),he({width:100,height:100,name:"square"},ye),_e(he({type:1,name:"line",width:100,height:5,lineWidth:2,lineName:"line",penName:"line",background:"#FFF000",color:"#FFF000"},ye),{lineAnimateType:1,anchors:[{x:0,y:.5,id:"0"},{x:1,y:.5,id:"1"}]}),he({width:200,height:50,borderRadius:0,name:"rectangle"},ye),he({width:100,height:100,name:"circle"},ye),he({width:100,height:100,name:"triangle"},ye),he({width:100,height:100,name:"diamond"},ye),he({width:100,height:100,name:"pentagon"},ye),he({width:100,height:100,name:"hexagon"},ye),he({width:100,height:100,name:"pentagram"},ye),he({width:120,height:60,name:"leftArrow"},ye),he({width:120,height:60,name:"rightArrow"},ye),he({width:150,height:60,name:"twowayArrow"},ye),he({width:100,height:100,name:"cloud"},ye),he({textTop:-.1,width:100,height:100,name:"message"},ye),he({width:80,height:100,name:"file"},ye),_e(he({name:"svg",width:100,height:100,image:kc,audioId:"",penType:Se.AUDIO},Oe),{form:[...Ct[Se.AUDIO],...Oe.form],events:[{name:"enter",action:mn.Emit,value:nt.OPEN_AUDIO,where:{type:""},params:JSON.stringify({action:nt.OPEN_AUDIO,data:""})},{name:"leave",action:mn.Emit,value:nt.CLOSE_AUDIO,where:{type:""},params:JSON.stringify({action:nt.CLOSE_AUDIO,data:""})}]}),_e(he({name:"svg",width:100,height:100,image:Bc,cameraId:"",events:[{name:"enter",action:mn.Emit,value:nt.OPEN_CAMERA,where:{type:""},params:JSON.stringify({action:nt.OPEN_CAMERA,data:""})},{name:"leave",action:mn.Emit,value:nt.CLOSE_CAMERA,where:{type:""},params:JSON.stringify({action:nt.CLOSE_CAMERA,data:""})}],penType:Se.CAMERA},Oe),{form:[...Ct[Se.CAMERA],...Oe.form]}),_e(he({name:"video",width:100,height:100,video:"https://video.699pic.com/videos/17/69/11/a_aa3jeKZ0D63g1556176911_10s.mp4",autoPlay:!0,penType:Se.MP4},Oe),{form:[...Ct[Se.MP4],...Oe.form]}),_e(he({name:"video",width:100,height:100,video:"https://video.699pic.com/videos/17/69/11/a_aa3jeKZ0D63g1556176911_10s.mp4",autoPlay:!0,penType:Se.VIDEO_STREAM},Oe),{form:[...Ct[Se.VIDEO_STREAM],...Oe.form]}),_e(he({width:60,height:100,name:"cube",z:.25},ye),{props:{custom:[{key:"z",label:"Z",type:"number",min:0,placeholder:"<= 1 即宽度的比例"},{key:"backgroundFront",label:"前背景色",type:"color"},{key:"backgroundUp",label:"顶背景色",type:"color"},{key:"backgroundRight",label:"右背景色",type:"color"}]}}),he({width:70,height:100,name:"people"},ye),_e(he({name:"table",width:80,height:30,disableAnchor:!0,colWidth:90,rowHeight:32,bordered:!0,vLine:!0,hLine:!0,stripe:!1,color:"#333",textColor:"#444"},ye),{penType:Se.TABLE,data:[["设备 ID","设备名称","数据协议","级别"],["1","200","MQTT",{text:"一级告警",background:"#650b09",textColor:"#FF5D3CFF"}],["2","湿度传感器","MQTT",{text:"二级告警",background:"#4d2a02",textColor:"#E6A82EFF"}],["3","物联网设备","MQTT",{text:"一级告警",background:"#650b09",textColor:"#FF5D3CFF"}],["4","物联网设备/智能家居/智慧城市","MQTT",{text:"三级告警",textColor:"#58CC84FF",background:"#042617;"}]],styles:[{row:0,textColor:"#000"}]}),_e(he({name:"rectangle",penName:"按钮",width:80,height:30,borderRadius:.2,text:"按钮",background:"#1890ff",color:"#1890ff",textColor:"#fff",activeBackground:"#40a9ff",activeColor:"#40a9ff",activeTextColor:"#fff",hoverBackground:"#40a9ff",hoverColor:"#40a9ff",hoverTextColor:"#fff"},ye),{penType:Se.BUTTON}),_e(he({name:"switch",penName:"开关",height:30,width:60,checked:!1,offColor:"#BFBFBF",onColor:"#1890ff",disableOffColor:"#E5E5E5",disableOnColor:"#A3D3FF",locked:0},ye),{penType:Se.SWITCH}),_e(he({name:"radio",penName:"单选框",width:150,height:100,direction:"vertical",checked:"",options:[{text:"选项一"},{text:"选项二"},{text:"选项三",isForbidden:!0}]},ye),{penType:Se.RADIO}),_e(he({name:"checkbox",penName:"多选框",width:30,height:30,checked:!0,value:"选项一"},ye),{penType:Se.CHECKBOX}),_e(he({name:"slider",penName:"进度条",width:300,height:30,value:10,textWidth:50,barHeight:4,min:0,max:100,color:"#1890ff",background:"#D4D6D9",textColor:"#222",unit:"%"},ye),{penType:Se.SLIDER}),_e(he({name:"rectangle",penName:"输入框",height:50,width:200,input:!0,borderRadius:.05,ellipsis:!0,text:"输入数据",textAlign:"left",color:"#D9D9D9FF",textColor:"#000000FF",hoverTextColor:"#000000FF",activeTextColor:"#000000FF",textLeft:10},ye),{penType:Se.INPUT}),_e(he({name:"rectangle",penName:"选择器",height:50,width:200,borderRadius:.05,ellipsis:!0,text:"选项1",textAlign:"left",color:"#D9D9D9FF",textColor:"#000000FF",hoverTextColor:"#000000FF",activeTextColor:"#000000FF",textLeft:10,dropdownList:[{text:"选项1"},{text:"选项2"},{text:"选项3"}]},ye),{penType:Se.SELECT}),_e(he({name:"time",penName:"时间",width:300,height:40,text:`${hy().format("YYYY-MM-DD HH:mm:ss")}`,lineWidth:0,interval:67,fillZero:!0},ye),{penType:Se.TIME,form:[{key:"timeFormat",name:"显示格式",type:"text"},{key:"fillZero",name:"是否补0",type:"switch"},...ye.form],timeFormat:"`${year}-${month}-${day} ${hours}:${minutes}:${seconds} 星期${week}`"}),he({text:"开始/结束",width:120,height:40,borderRadius:.5,name:"rectangle"},ye),he({text:"流程",width:120,height:40,name:"rectangle"},ye),he({text:"判定",width:120,height:60,name:"diamond"},ye),he({text:"数据",width:120,height:50,name:"flowData",offsetX:.14},ye),he({text:"准备",width:120,height:50,name:"hexagon"},ye),he({text:"子流程",width:120,height:50,name:"flowSubprocess"},ye),he({text:"数据库",width:80,height:120,name:"flowDb"},ye),he({text:"文档",width:120,height:100,name:"flowDocument"},ye),he({text:"内部存储",width:120,height:80,name:"flowInternalStorage"},ye),he({text:"外部存储",width:120,height:80,name:"flowExternStorage"},ye),he({text:"队列",width:100,height:100,name:"flowQueue"},ye),he({text:"手动输入",width:120,height:80,name:"flowManually"},ye),he({text:"展示",width:120,height:80,name:"flowDisplay"},ye),he({text:"并行模式",width:120,height:50,name:"flowParallel"},ye),he({text:"注释",width:100,height:100,name:"flowComment"},ye),he({text:"",width:30,height:30,name:"circle",background:"#555",lineWidth:0},ye),he({width:30,height:30,name:"activityFinal"},ye),he({text:"活动",width:120,height:50,borderRadius:.25,name:"rectangle"},ye),he({text:"决策/合并",width:120,height:50,name:"diamond"},ye),he({text:"垂直泳道",width:200,height:500,name:"swimlaneV",textBaseline:"top",textTop:20,lineTop:.08},ye),he({text:"水平泳道",width:500,height:200,name:"swimlaneH",textWidth:.01,textLeft:.04,textAlign:"left",lineLeft:.08},ye),he({text:"垂直分岔/汇合",width:10,height:150,name:"forkV",fillStyle:"#555",strokeStyle:"transparent"},ye),he({text:"水平分岔/汇合",width:150,height:10,name:"forkH",fillStyle:"#555",strokeStyle:"transparent"},ye),he({name:"andGate",width:100,height:150},ye),he({name:"basicEvent",width:100,height:150},ye),he({name:"unexpandedEvent",width:100,height:150},ye),he({name:"priorityAndGate",width:100,height:150},ye),he({name:"forbiddenGate",width:100,height:150},ye),he({name:"event",width:100,height:150},ye),he({name:"switchEvent",width:100,height:150},ye),he({name:"conditionalEvent",width:150,height:100},ye),he({name:"transferSymbol",width:100,height:150},ye),he({name:"orGate",width:100,height:150},ye),he({name:"xorGate",width:100,height:150},ye),he({name:"votingGate",width:100,height:150},ye),he({text:"主题",width:200,height:50,name:"mindNode",borderRadius:.5},ye),he({text:"子主题",width:160,height:40,name:"mindLine"},ye);const Wy=(e,r={isDev:!1,devServerUrl:"",devServerPort:8443})=>e.replace(/(https?:\/\/)(\b(?:\d{1,3}\.){3}\d{1,3}\b)(:(\d+))?/,`$1${r.isDev?r.devServerUrl:d1}:${r.isDev?r.devServerPort:v1}`);class Ky{constructor(r){It(this,"editor");this.editor=r}initPlugin(r,t,n={}){r.installPenPlugins({name:t},[{plugin:Ic.mindBoxPlugin,options:n},{plugin:Dc.collapseChildPlugin,options:n}])}}var Ml;(function(e){e[e.Node=0]="Node",e[e.Line=1]="Line"})(Ml||(Ml={}));var Ll;(function(e){e[e.None=0]="None",e[e.DisableEdit=1]="DisableEdit",e[e.DisableMove=2]="DisableMove",e[e.DisableScale=3]="DisableScale",e[e.DisableMoveScale=4]="DisableMoveScale",e[e.Disable=10]="Disable"})(Ll||(Ll={}));var Ul;(function(e){e[e.Default=0]="Default",e[e.In=1]="In",e[e.Out=2]="Out"})(Ul||(Ul={}));var ql;(function(e){e[e.None=0]="None",e[e.Linear=1]="Linear",e[e.Radial=2]="Radial"})(ql||(ql={}));var $l;(function(e){e[e.CanvasTemplate=1]="CanvasTemplate",e[e.CanvasImageBottom=2]="CanvasImageBottom",e[e.CanvasMain=3]="CanvasMain",e[e.CanvasImage=4]="CanvasImage"})($l||($l={}));var zl;(function(e){e[e.Normal=0]="Normal",e[e.Beads=1]="Beads",e[e.Dot=2]="Dot",e[e.Arrow=3]="Arrow",e[e.WaterDrop=4]="WaterDrop",e[e.Custom=5]="Custom"})(zl||(zl={}));var jl;(function(e){e[e.Image=0]="Image",e[e.Icon=1]="Icon",e[e.Pen=2]="Pen",e[e.Element=3]="Element"})(jl||(jl={}));var Hl;(function(e){e[e.None=0]="None",e[e.LineAnchor=1]="LineAnchor",e[e.NodeAnchor=2]="NodeAnchor",e[e.Line=3]="Line",e[e.Node=4]="Node",e[e.Resize=5]="Resize",e[e.Rotate=6]="Rotate",e[e.LineAnchorPrev=7]="LineAnchorPrev",e[e.LineAnchorNext=8]="LineAnchorNext"})(Hl||(Hl={}));var Vl;(function(e){e[e.None=0]="None",e[e.Translate=1]="Translate",e[e.Select=2]="Select",e[e.Resize=3]="Resize",e[e.AddAnchor=4]="AddAnchor"})(Vl||(Vl={}));var Wl;(function(e){e[e.None=0]="None",e[e.Down=1]="Down",e[e.Translate=2]="Translate"})(Wl||(Wl={}));var Kl;(function(e){e[e.None=-1]="None",e[e.Up=0]="Up",e[e.Right=1]="Right",e[e.Bottom=2]="Bottom",e[e.Left=3]="Left"})(Kl||(Kl={}));var Gl;(function(e){e[e.Mirror=0]="Mirror",e[e.Bilateral=1]="Bilateral",e[e.Free=2]="Free"})(Gl||(Gl={}));var Ql;(function(e){e[e.Default=0]="Default",e[e.In=1]="In",e[e.Out=2]="Out",e[e.DisableConnected=3]="DisableConnected",e[e.DisableConnectTo=4]="DisableConnectTo",e[e.Disable=10]="Disable"})(Ql||(Ql={}));var Yl;(function(e){e[e.Default=0]="Default",e[e.Line=1]="Line"})(Yl||(Yl={}));var Xo;(function(e){e[e.None=-1]="None",e[e.Document=0]="Document",e[e.Canvas=1]="Canvas"})(Xo||(Xo={}));Xo.Document;var Xl;(function(e){e[e.Add=0]="Add",e[e.Update=1]="Update",e[e.Delete=2]="Delete",e[e.Replace=3]="Replace"})(Xl||(Xl={}));function Zl(e){const r=parseInt,t=Math.round;let n=e.length,l={};if(n>9){const[a,o,u,p]=e=e.split(",");if(n=e.length,n<3||n>4)return null;l.r=r(a[3]=="a"?a.slice(5):a.slice(4)),l.g=r(o),l.b=r(u),l.a=p?parseFloat(p):-1}else{if(n==8||n==6||n<4)return null;n<6&&(e="#"+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]+(n>4?e[4]+e[4]:"")),e=r(e.slice(1),16),n==9||n==5?(l.r=e>>24&255,l.g=e>>16&255,l.b=e>>8&255,l.a=t((e&255)/.255)/1e3):(l.r=e>>16,l.g=e>>8&255,l.b=e&255,l.a=-1)}return l}function Gy(e,r,t,n){let l,a,o,u,p,s,i,d=Math.round,c=typeof t=="string";return typeof e!="number"||e<-1||e>1||typeof r!="string"||r[0]!="r"&&r[0]!="#"||t&&!c||(i=r.length>9,i=c?t.length>9?!0:t=="c"?!i:!1:i,p=Zl(r),u=e<0,s=t&&t!="c"?Zl(t):u?{r:0,g:0,b:0,a:-1}:{r:255,g:255,b:255,a:-1},e=u?e*-1:e,u=1-e,!p||!s)?null:(n?(l=d(u*p.r+e*s.r),a=d(u*p.g+e*s.g),o=d(u*p.b+e*s.b)):(l=d(mt(u*mt(p.r,2)+e*mt(s.r,2),.5)),a=d(mt(u*mt(p.g,2)+e*mt(s.g,2),.5)),o=d(mt(u*mt(p.b,2)+e*mt(s.b,2),.5))),c=p.a,s=s.a,p=c>=0||s>=0,c=p?c<0?s:s<0?c:c*u+s*e:0,i?"rgb"+(p?"a(":"(")+l+","+a+","+o+(p?","+d(c*1e3)/1e3:"")+")":"#"+(4294967296+l*16777216+a*65536+o*256+(p?d(c*255):0)).toString(16).slice(1,p?void 0:-2))}globalThis.pSBC=Gy;var Jl;(function(e){e[e.None=0]="None",e[e.LocalStorage=1]="LocalStorage",e[e.Cookie=2]="Cookie"})(Jl||(Jl={}));location.host.indexOf("le5le.com");const cr={};var eu;(function(e){e[e.Link=0]="Link",e[e.SetProps=1]="SetProps",e[e.StartAnimate=2]="StartAnimate",e[e.PauseAnimate=3]="PauseAnimate",e[e.StopAnimate=4]="StopAnimate",e[e.JS=5]="JS",e[e.GlobalFn=6]="GlobalFn",e[e.Emit=7]="Emit",e[e.StartVideo=8]="StartVideo",e[e.PauseVideo=9]="PauseVideo",e[e.StopVideo=10]="StopVideo",e[e.SendPropData=11]="SendPropData",e[e.SendVarData=12]="SendVarData",e[e.Navigator=13]="Navigator",e[e.Dialog=14]="Dialog",e[e.SendData=15]="SendData",e[e.PostMessage=16]="PostMessage",e[e.PostMessageToParent=17]="PostMessageToParent",e[e.Message=18]="Message"})(eu||(eu={}));var Qy={exports:{}};(function(e,r){(function(t){e.exports=t()})(function(){return function(){return function t(n,l,a){function o(s,i){if(!l[s]){if(!n[s]){var d=typeof Rr=="function"&&Rr;if(!i&&d)return d(s,!0);if(u)return u(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var f=l[s]={exports:{}};n[s][0].call(f.exports,function(h){return o(n[s][1][h]||h)},f,f.exports,t,n,l,a)}return l[s].exports}for(var u=typeof Rr=="function"&&Rr,p=0;p<a.length;p++)o(a[p]);return o}}()({1:[function(t,n,l){(function(a,o){(function(){const u=t("events").EventEmitter,p=t("./store"),s=t("./topic-alias-recv"),i=t("./topic-alias-send"),d=t("mqtt-packet"),c=t("./default-message-id-provider"),f=t("readable-stream").Writable,h=t("inherits"),v=t("reinterval"),m=t("rfdc/default"),g=t("./validations"),x=t("xtend"),y=t("debug")("mqttjs:client"),w=a?a.nextTick:function(C){setTimeout(C,0)},k=o.setImmediate||function(C){w(C)},T={keepalive:60,reschedulePings:!0,protocolId:"MQTT",protocolVersion:4,reconnectPeriod:1e3,connectTimeout:3e4,clean:!0,resubscribe:!0},I={0:"",1:"Unacceptable protocol version",2:"Identifier rejected",3:"Server unavailable",4:"Bad username or password",5:"Not authorized",16:"No matching subscribers",17:"No subscription existed",128:"Unspecified error",129:"Malformed Packet",130:"Protocol Error",131:"Implementation specific error",132:"Unsupported Protocol Version",133:"Client Identifier not valid",134:"Bad User Name or Password",135:"Not authorized",136:"Server unavailable",137:"Server busy",138:"Banned",139:"Server shutting down",140:"Bad authentication method",141:"Keep Alive timeout",142:"Session taken over",143:"Topic Filter invalid",144:"Topic Name invalid",145:"Packet identifier in use",146:"Packet Identifier not found",147:"Receive Maximum exceeded",148:"Topic Alias invalid",149:"Packet too large",150:"Message rate too high",151:"Quota exceeded",152:"Administrative action",153:"Payload format invalid",154:"Retain not supported",155:"QoS not supported",156:"Use another server",157:"Server moved",158:"Shared Subscriptions not supported",159:"Connection rate exceeded",160:"Maximum connect time",161:"Subscription Identifiers not supported",162:"Wildcard Subscriptions not supported"};function D(C,F){let j;F.properties&&(j=F.properties.topicAlias);let P=F.topic.toString();if(P.length===0){if(j===void 0)return new Error("Unregistered Topic Alias");if((P=C.topicAliasSend.getTopicByAlias(j))===void 0)return new Error("Unregistered Topic Alias");F.topic=P}j&&delete F.properties.topicAlias}function X(C,F,j){y("sendPacket :: packet: %O",F),y("sendPacket :: emitting `packetsend`"),C.emit("packetsend",F),y("sendPacket :: writing to stream");const P=d.writeToStream(F,C.stream,C.options);y("sendPacket :: writeToStream result %s",P),!P&&j&&j!==E?(y("sendPacket :: handle events on `drain` once through callback."),C.stream.once("drain",j)):j&&(y("sendPacket :: invoking cb"),j())}function V(C,F,j,P){y("storeAndSend :: store packet with cmd %s to outgoingStore",F.cmd);let J,$=F;if($.cmd==="publish"&&($=m(F),J=D(C,$)))return j&&j(J);C.outgoingStore.put($,function(U){if(U)return j&&j(U);P(),X(C,F,j)})}function E(C){y("nop ::",C)}function A(C,F){let j;const P=this;if(!(this instanceof A))return new A(C,F);for(j in this.options=F||{},T)this.options[j]===void 0?this.options[j]=T[j]:this.options[j]=F[j];y("MqttClient :: options.protocol",F.protocol),y("MqttClient :: options.protocolVersion",F.protocolVersion),y("MqttClient :: options.username",F.username),y("MqttClient :: options.keepalive",F.keepalive),y("MqttClient :: options.reconnectPeriod",F.reconnectPeriod),y("MqttClient :: options.rejectUnauthorized",F.rejectUnauthorized),y("MqttClient :: options.topicAliasMaximum",F.topicAliasMaximum),this.options.clientId=typeof F.clientId=="string"?F.clientId:"mqttjs_"+Math.random().toString(16).substr(2,8),y("MqttClient :: clientId",this.options.clientId),this.options.customHandleAcks=F.protocolVersion===5&&F.customHandleAcks?F.customHandleAcks:function(){arguments[3](0)},this.streamBuilder=C,this.messageIdProvider=this.options.messageIdProvider===void 0?new c:this.options.messageIdProvider,this.outgoingStore=F.outgoingStore||new p,this.incomingStore=F.incomingStore||new p,this.queueQoSZero=F.queueQoSZero===void 0||F.queueQoSZero,this._resubscribeTopics={},this.messageIdToTopic={},this.pingTimer=null,this.connected=!1,this.disconnecting=!1,this.queue=[],this.connackTimer=null,this.reconnectTimer=null,this._storeProcessing=!1,this._packetIdsDuringStoreProcessing={},this._storeProcessingQueue=[],this.outgoing={},this._firstConnection=!0,F.topicAliasMaximum>0&&(F.topicAliasMaximum>65535?y("MqttClient :: options.topicAliasMaximum is out of range"):this.topicAliasRecv=new s(F.topicAliasMaximum)),this.on("connect",function(){const J=this.queue;y("connect :: sending queued packets"),function $(){const U=J.shift();y("deliver :: entry %o",U);let K=null;if(!U)return void P._resubscribe();K=U.packet,y("deliver :: call _sendPacket for %o",K);let L=!0;K.messageId&&K.messageId!==0&&(P.messageIdProvider.register(K.messageId)||(L=!1)),L?P._sendPacket(K,function(O){U.cb&&U.cb(O),$()}):(y("messageId: %d has already used. The message is skipped and removed.",K.messageId),$())}()}),this.on("close",function(){y("close :: connected set to `false`"),this.connected=!1,y("close :: clearing connackTimer"),clearTimeout(this.connackTimer),y("close :: clearing ping timer"),P.pingTimer!==null&&(P.pingTimer.clear(),P.pingTimer=null),this.topicAliasRecv&&this.topicAliasRecv.clear(),y("close :: calling _setupReconnect"),this._setupReconnect()}),u.call(this),y("MqttClient :: setting up stream"),this._setupStream()}h(A,u),A.prototype._setupStream=function(){const C=this,F=new f,j=d.parser(this.options);let P=null;const J=[];function $(){if(J.length)w(U);else{const L=P;P=null,L()}}function U(){y("work :: getting next packet in queue");const L=J.shift();if(L)y("work :: packet pulled from queue"),C._handlePacket(L,$);else{y("work :: no packets in queue");const O=P;P=null,y("work :: done flag is %s",!!O),O&&O()}}y("_setupStream :: calling method to clear reconnect"),this._clearReconnect(),y("_setupStream :: using streamBuilder provided to client to create stream"),this.stream=this.streamBuilder(this),j.on("packet",function(L){y("parser :: on packet push to packets array."),J.push(L)}),F._write=function(L,O,H){P=H,y("writable stream :: parsing buffer"),j.parse(L),U()},y("_setupStream :: pipe stream to writable stream"),this.stream.pipe(F),this.stream.on("error",function(L){y("streamErrorHandler :: error",L.message),L.code?(y("streamErrorHandler :: emitting error"),C.emit("error",L)):E(L)}),this.stream.on("close",function(){var L;y("(%s)stream :: on close",C.options.clientId),(L=C.outgoing)&&(y("flushVolatile :: deleting volatile messages from the queue and setting their callbacks as error function"),Object.keys(L).forEach(function(O){L[O].volatile&&typeof L[O].cb=="function"&&(L[O].cb(new Error("Connection closed")),delete L[O])})),y("stream: emit close to MqttClient"),C.emit("close")}),y("_setupStream: sending packet `connect`");const K=Object.create(this.options);if(K.cmd="connect",this.topicAliasRecv&&(K.properties||(K.properties={}),this.topicAliasRecv&&(K.properties.topicAliasMaximum=this.topicAliasRecv.max)),X(this,K),j.on("error",this.emit.bind(this,"error")),this.options.properties){if(!this.options.properties.authenticationMethod&&this.options.properties.authenticationData)return C.end(()=>this.emit("error",new Error("Packet has no Authentication Method"))),this;this.options.properties.authenticationMethod&&this.options.authPacket&&typeof this.options.authPacket=="object"&&X(this,x({cmd:"auth",reasonCode:0},this.options.authPacket))}this.stream.setMaxListeners(1e3),clearTimeout(this.connackTimer),this.connackTimer=setTimeout(function(){y("!!connectTimeout hit!! Calling _cleanUp with force `true`"),C._cleanUp(!0)},this.options.connectTimeout)},A.prototype._handlePacket=function(C,F){const j=this.options;if(j.protocolVersion===5&&j.properties&&j.properties.maximumPacketSize&&j.properties.maximumPacketSize<C.length)return this.emit("error",new Error("exceeding packets size "+C.cmd)),this.end({reasonCode:149,properties:{reasonString:"Maximum packet size was exceeded"}}),this;switch(y("_handlePacket :: emitting packetreceive"),this.emit("packetreceive",C),C.cmd){case"publish":this._handlePublish(C,F);break;case"puback":case"pubrec":case"pubcomp":case"suback":case"unsuback":this._handleAck(C),F();break;case"pubrel":this._handlePubrel(C,F);break;case"connack":this._handleConnack(C),F();break;case"auth":this._handleAuth(C),F();break;case"pingresp":this._handlePingresp(C),F();break;case"disconnect":this._handleDisconnect(C),F()}},A.prototype._checkDisconnecting=function(C){return this.disconnecting&&(C&&C!==E?C(new Error("client disconnecting")):this.emit("error",new Error("client disconnecting"))),this.disconnecting},A.prototype.publish=function(C,F,j,P){y("publish :: message `%s` to topic `%s`",F,C);const J=this.options;if(typeof j=="function"&&(P=j,j=null),j=x({qos:0,retain:!1,dup:!1},j),this._checkDisconnecting(P))return this;const $=this,U=function(){let K=0;if((j.qos===1||j.qos===2)&&(K=$._nextId())===null)return y("No messageId left"),!1;const L={cmd:"publish",topic:C,payload:F,qos:j.qos,retain:j.retain,messageId:K,dup:j.dup};switch(J.protocolVersion===5&&(L.properties=j.properties),y("publish :: qos",j.qos),j.qos){case 1:case 2:$.outgoing[L.messageId]={volatile:!1,cb:P||E},y("MqttClient:publish: packet cmd: %s",L.cmd),$._sendPacket(L,void 0,j.cbStorePut);break;default:y("MqttClient:publish: packet cmd: %s",L.cmd),$._sendPacket(L,P,j.cbStorePut)}return!0};return(this._storeProcessing||this._storeProcessingQueue.length>0||!U())&&this._storeProcessingQueue.push({invoke:U,cbStorePut:j.cbStorePut,callback:P}),this},A.prototype.subscribe=function(){const C=this,F=new Array(arguments.length);for(let W=0;W<arguments.length;W++)F[W]=arguments[W];const j=[];let P=F.shift();const J=P.resubscribe;let $=F.pop()||E,U=F.pop();const K=this.options.protocolVersion;delete P.resubscribe,typeof P=="string"&&(P=[P]),typeof $!="function"&&(U=$,$=E);const L=g.validateTopics(P);if(L!==null)return k($,new Error("Invalid topic "+L)),this;if(this._checkDisconnecting($))return y("subscribe: discconecting true"),this;const O={qos:0};if(K===5&&(O.nl=!1,O.rap=!1,O.rh=0),U=x(O,U),Array.isArray(P)?P.forEach(function(W){if(y("subscribe: array topic %s",W),!Object.prototype.hasOwnProperty.call(C._resubscribeTopics,W)||C._resubscribeTopics[W].qos<U.qos||J){const Z={topic:W,qos:U.qos};K===5&&(Z.nl=U.nl,Z.rap=U.rap,Z.rh=U.rh,Z.properties=U.properties),y("subscribe: pushing topic `%s` and qos `%s` to subs list",Z.topic,Z.qos),j.push(Z)}}):Object.keys(P).forEach(function(W){if(y("subscribe: object topic %s",W),!Object.prototype.hasOwnProperty.call(C._resubscribeTopics,W)||C._resubscribeTopics[W].qos<P[W].qos||J){const Z={topic:W,qos:P[W].qos};K===5&&(Z.nl=P[W].nl,Z.rap=P[W].rap,Z.rh=P[W].rh,Z.properties=U.properties),y("subscribe: pushing `%s` to subs list",Z),j.push(Z)}}),!j.length)return $(null,[]),this;const H=function(){const W=C._nextId();if(W===null)return y("No messageId left"),!1;const Z={cmd:"subscribe",subscriptions:j,qos:1,retain:!1,dup:!1,messageId:W};if(U.properties&&(Z.properties=U.properties),C.options.resubscribe){y("subscribe :: resubscribe true");const re=[];j.forEach(function(oe){if(C.options.reconnectPeriod>0){const ae={qos:oe.qos};K===5&&(ae.nl=oe.nl||!1,ae.rap=oe.rap||!1,ae.rh=oe.rh||0,ae.properties=oe.properties),C._resubscribeTopics[oe.topic]=ae,re.push(oe.topic)}}),C.messageIdToTopic[Z.messageId]=re}return C.outgoing[Z.messageId]={volatile:!0,cb:function(re,oe){if(!re){const ae=oe.granted;for(let b=0;b<ae.length;b+=1)j[b].qos=ae[b]}$(re,j)}},y("subscribe :: call _sendPacket"),C._sendPacket(Z),!0};return(this._storeProcessing||this._storeProcessingQueue.length>0||!H())&&this._storeProcessingQueue.push({invoke:H,callback:$}),this},A.prototype.unsubscribe=function(){const C=this,F=new Array(arguments.length);for(let K=0;K<arguments.length;K++)F[K]=arguments[K];let j=F.shift(),P=F.pop()||E,J=F.pop();typeof j=="string"&&(j=[j]),typeof P!="function"&&(J=P,P=E);const $=g.validateTopics(j);if($!==null)return k(P,new Error("Invalid topic "+$)),this;if(C._checkDisconnecting(P))return this;const U=function(){const K=C._nextId();if(K===null)return y("No messageId left"),!1;const L={cmd:"unsubscribe",qos:1,messageId:K};return typeof j=="string"?L.unsubscriptions=[j]:Array.isArray(j)&&(L.unsubscriptions=j),C.options.resubscribe&&L.unsubscriptions.forEach(function(O){delete C._resubscribeTopics[O]}),typeof J=="object"&&J.properties&&(L.properties=J.properties),C.outgoing[L.messageId]={volatile:!0,cb:P},y("unsubscribe: call _sendPacket"),C._sendPacket(L),!0};return(this._storeProcessing||this._storeProcessingQueue.length>0||!U())&&this._storeProcessingQueue.push({invoke:U,callback:P}),this},A.prototype.end=function(C,F,j){const P=this;function J(){y("end :: (%s) :: finish :: calling _cleanUp with force %s",P.options.clientId,C),P._cleanUp(C,()=>{y("end :: finish :: calling process.nextTick on closeStores"),w(function(){y("end :: closeStores: closing incoming and outgoing stores"),P.disconnected=!0,P.incomingStore.close(function($){P.outgoingStore.close(function(U){if(y("end :: closeStores: emitting end"),P.emit("end"),j){const K=$||U;y("end :: closeStores: invoking callback with args"),j(K)}})}),P._deferredReconnect&&P._deferredReconnect()}.bind(P))},F)}return y("end :: (%s)",this.options.clientId),C!=null&&typeof C=="boolean"||(j=F||E,F=C,C=!1,typeof F!="object"&&(j=F,F=null,typeof j!="function"&&(j=E))),typeof F!="object"&&(j=F,F=null),y("end :: cb? %s",!!j),j=j||E,this.disconnecting?(j(),this):(this._clearReconnect(),this.disconnecting=!0,!C&&Object.keys(this.outgoing).length>0?(y("end :: (%s) :: calling finish in 10ms once outgoing is empty",P.options.clientId),this.once("outgoingEmpty",setTimeout.bind(null,J,10))):(y("end :: (%s) :: immediately calling finish",P.options.clientId),J()),this)},A.prototype.removeOutgoingMessage=function(C){const F=this.outgoing[C]?this.outgoing[C].cb:null;return delete this.outgoing[C],this.outgoingStore.del({messageId:C},function(){F(new Error("Message removed"))}),this},A.prototype.reconnect=function(C){y("client reconnect");const F=this,j=function(){C?(F.options.incomingStore=C.incomingStore,F.options.outgoingStore=C.outgoingStore):(F.options.incomingStore=null,F.options.outgoingStore=null),F.incomingStore=F.options.incomingStore||new p,F.outgoingStore=F.options.outgoingStore||new p,F.disconnecting=!1,F.disconnected=!1,F._deferredReconnect=null,F._reconnect()};return this.disconnecting&&!this.disconnected?this._deferredReconnect=j:j(),this},A.prototype._reconnect=function(){y("_reconnect: emitting reconnect to client"),this.emit("reconnect"),this.connected?(this.end(()=>{this._setupStream()}),y("client already connected. disconnecting first.")):(y("_reconnect: calling _setupStream"),this._setupStream())},A.prototype._setupReconnect=function(){const C=this;!C.disconnecting&&!C.reconnectTimer&&C.options.reconnectPeriod>0?(this.reconnecting||(y("_setupReconnect :: emit `offline` state"),this.emit("offline"),y("_setupReconnect :: set `reconnecting` to `true`"),this.reconnecting=!0),y("_setupReconnect :: setting reconnectTimer for %d ms",C.options.reconnectPeriod),C.reconnectTimer=setInterval(function(){y("reconnectTimer :: reconnect triggered!"),C._reconnect()},C.options.reconnectPeriod)):y("_setupReconnect :: doing nothing...")},A.prototype._clearReconnect=function(){y("_clearReconnect : clearing reconnect timer"),this.reconnectTimer&&(clearInterval(this.reconnectTimer),this.reconnectTimer=null)},A.prototype._cleanUp=function(C,F){const j=arguments[2];if(F&&(y("_cleanUp :: done callback provided for on stream close"),this.stream.on("close",F)),y("_cleanUp :: forced? %s",C),C)this.options.reconnectPeriod===0&&this.options.clean&&(P=this.outgoing)&&(y("flush: queue exists? %b",!!P),Object.keys(P).forEach(function(J){typeof P[J].cb=="function"&&(P[J].cb(new Error("Connection closed")),delete P[J])})),y("_cleanUp :: (%s) :: destroying stream",this.options.clientId),this.stream.destroy();else{const J=x({cmd:"disconnect"},j);y("_cleanUp :: (%s) :: call _sendPacket with disconnect packet",this.options.clientId),this._sendPacket(J,k.bind(null,this.stream.end.bind(this.stream)))}var P;this.disconnecting||(y("_cleanUp :: client not disconnecting. Clearing and resetting reconnect."),this._clearReconnect(),this._setupReconnect()),this.pingTimer!==null&&(y("_cleanUp :: clearing pingTimer"),this.pingTimer.clear(),this.pingTimer=null),F&&!this.connected&&(y("_cleanUp :: (%s) :: removing stream `done` callback `close` listener",this.options.clientId),this.stream.removeListener("close",F),F())},A.prototype._sendPacket=function(C,F,j){y("_sendPacket :: (%s) :: start",this.options.clientId),j=j||E,F=F||E;const P=function(J,$){if(J.options.protocolVersion===5&&$.cmd==="publish"){let U;$.properties&&(U=$.properties.topicAlias);const K=$.topic.toString();if(J.topicAliasSend)if(U){if(K.length!==0&&(y("applyTopicAlias :: register topic: %s - alias: %d",K,U),!J.topicAliasSend.put(K,U)))return y("applyTopicAlias :: error out of range. topic: %s - alias: %d",K,U),new Error("Sending Topic Alias out of range")}else K.length!==0&&(J.options.autoAssignTopicAlias?(U=J.topicAliasSend.getAliasByTopic(K))?($.topic="",$.properties=_e(he({},$.properties),{topicAlias:U}),y("applyTopicAlias :: auto assign(use) topic: %s - alias: %d",K,U)):(U=J.topicAliasSend.getLruAlias(),J.topicAliasSend.put(K,U),$.properties=_e(he({},$.properties),{topicAlias:U}),y("applyTopicAlias :: auto assign topic: %s - alias: %d",K,U)):J.options.autoUseTopicAlias&&(U=J.topicAliasSend.getAliasByTopic(K))&&($.topic="",$.properties=_e(he({},$.properties),{topicAlias:U}),y("applyTopicAlias :: auto use topic: %s - alias: %d",K,U)));else if(U)return y("applyTopicAlias :: error out of range. topic: %s - alias: %d",K,U),new Error("Sending Topic Alias out of range")}}(this,C);if(P)F(P);else{if(!this.connected)return C.cmd==="auth"?(this._shiftPingInterval(),void X(this,C,F)):(y("_sendPacket :: client not connected. Storing packet offline."),void this._storePacket(C,F,j));switch(this._shiftPingInterval(),C.cmd){case"publish":break;case"pubrel":return void V(this,C,F,j);default:return void X(this,C,F)}switch(C.qos){case 2:case 1:V(this,C,F,j);break;case 0:default:X(this,C,F)}y("_sendPacket :: (%s) :: end",this.options.clientId)}},A.prototype._storePacket=function(C,F,j){y("_storePacket :: packet: %o",C),y("_storePacket :: cb? %s",!!F),j=j||E;let P=C;if(P.cmd==="publish"){const J=D(this,P=m(C));if(J)return F&&F(J)}(P.qos||0)===0&&this.queueQoSZero||P.cmd!=="publish"?this.queue.push({packet:P,cb:F}):P.qos>0?(F=this.outgoing[P.messageId]?this.outgoing[P.messageId].cb:null,this.outgoingStore.put(P,function(J){if(J)return F&&F(J);j()})):F&&F(new Error("No connection to broker"))},A.prototype._setupPingTimer=function(){y("_setupPingTimer :: keepalive %d (seconds)",this.options.keepalive);const C=this;!this.pingTimer&&this.options.keepalive&&(this.pingResp=!0,this.pingTimer=v(function(){C._checkPing()},1e3*this.options.keepalive))},A.prototype._shiftPingInterval=function(){this.pingTimer&&this.options.keepalive&&this.options.reschedulePings&&this.pingTimer.reschedule(1e3*this.options.keepalive)},A.prototype._checkPing=function(){y("_checkPing :: checking ping..."),this.pingResp?(y("_checkPing :: ping response received. Clearing flag and sending `pingreq`"),this.pingResp=!1,this._sendPacket({cmd:"pingreq"})):(y("_checkPing :: calling _cleanUp with force true"),this._cleanUp(!0))},A.prototype._handlePingresp=function(){this.pingResp=!0},A.prototype._handleConnack=function(C){y("_handleConnack");const F=this.options,j=F.protocolVersion===5?C.reasonCode:C.returnCode;if(clearTimeout(this.connackTimer),delete this.topicAliasSend,C.properties){if(C.properties.topicAliasMaximum){if(C.properties.topicAliasMaximum>65535)return void this.emit("error",new Error("topicAliasMaximum from broker is out of range"));C.properties.topicAliasMaximum>0&&(this.topicAliasSend=new i(C.properties.topicAliasMaximum))}C.properties.serverKeepAlive&&F.keepalive&&(F.keepalive=C.properties.serverKeepAlive,this._shiftPingInterval()),C.properties.maximumPacketSize&&(F.properties||(F.properties={}),F.properties.maximumPacketSize=C.properties.maximumPacketSize)}if(j===0)this.reconnecting=!1,this._onConnect(C);else if(j>0){const P=new Error("Connection refused: "+I[j]);P.code=j,this.emit("error",P)}},A.prototype._handleAuth=function(C){const F=this.options.protocolVersion,j=F===5?C.reasonCode:C.returnCode;if(F!==5){const J=new Error("Protocol error: Auth packets are only supported in MQTT 5. Your version:"+F);return J.code=j,void this.emit("error",J)}const P=this;this.handleAuth(C,function(J,$){if(J)P.emit("error",J);else if(j===24)P.reconnecting=!1,P._sendPacket($);else{const U=new Error("Connection refused: "+I[j]);J.code=j,P.emit("error",U)}})},A.prototype.handleAuth=function(C,F){F()},A.prototype._handlePublish=function(C,F){y("_handlePublish: packet %o",C),F=F!==void 0?F:E;let j=C.topic.toString();const P=C.payload,J=C.qos,$=C.messageId,U=this,K=this.options,L=[0,16,128,131,135,144,145,151,153];if(this.options.protocolVersion===5){let O;if(C.properties&&(O=C.properties.topicAlias),O!==void 0)if(j.length===0){if(!(O>0&&O<=65535))return y("_handlePublish :: topic alias out of range. alias: %d",O),void this.emit("error",new Error("Received Topic Alias is out of range"));{const H=this.topicAliasRecv.getTopicByAlias(O);if(!H)return y("_handlePublish :: unregistered topic alias. alias: %d",O),void this.emit("error",new Error("Received unregistered Topic Alias"));y("_handlePublish :: topic complemented by alias. topic: %s - alias: %d",j=H,O)}}else{if(!this.topicAliasRecv.put(j,O))return y("_handlePublish :: topic alias out of range. alias: %d",O),void this.emit("error",new Error("Received Topic Alias is out of range"));y("_handlePublish :: registered topic: %s - alias: %d",j,O)}}switch(y("_handlePublish: qos %d",J),J){case 2:K.customHandleAcks(j,P,C,function(O,H){return O instanceof Error||(H=O,O=null),O?U.emit("error",O):L.indexOf(H)===-1?U.emit("error",new Error("Wrong reason code for pubrec")):void(H?U._sendPacket({cmd:"pubrec",messageId:$,reasonCode:H},F):U.incomingStore.put(C,function(){U._sendPacket({cmd:"pubrec",messageId:$},F)}))});break;case 1:K.customHandleAcks(j,P,C,function(O,H){return O instanceof Error||(H=O,O=null),O?U.emit("error",O):L.indexOf(H)===-1?U.emit("error",new Error("Wrong reason code for puback")):(H||U.emit("message",j,P,C),void U.handleMessage(C,function(W){if(W)return F&&F(W);U._sendPacket({cmd:"puback",messageId:$,reasonCode:H},F)}))});break;case 0:this.emit("message",j,P,C),this.handleMessage(C,F);break;default:y("_handlePublish: unknown QoS. Doing nothing.")}},A.prototype.handleMessage=function(C,F){F()},A.prototype._handleAck=function(C){const F=C.messageId,j=C.cmd;let P=null;const J=this.outgoing[F]?this.outgoing[F].cb:null,$=this;let U;if(J){switch(y("_handleAck :: packet type",j),j){case"pubcomp":case"puback":{const K=C.reasonCode;K&&K>0&&K!==16&&((U=new Error("Publish error: "+I[K])).code=K,J(U,C)),delete this.outgoing[F],this.outgoingStore.del(C,J),this.messageIdProvider.deallocate(F),this._invokeStoreProcessingQueue();break}case"pubrec":{P={cmd:"pubrel",qos:2,messageId:F};const K=C.reasonCode;K&&K>0&&K!==16?((U=new Error("Publish error: "+I[K])).code=K,J(U,C)):this._sendPacket(P);break}case"suback":delete this.outgoing[F],this.messageIdProvider.deallocate(F);for(let K=0;K<C.granted.length;K++)if(128&C.granted[K]){const L=this.messageIdToTopic[F];L&&L.forEach(function(O){delete $._resubscribeTopics[O]})}this._invokeStoreProcessingQueue(),J(null,C);break;case"unsuback":delete this.outgoing[F],this.messageIdProvider.deallocate(F),this._invokeStoreProcessingQueue(),J(null);break;default:$.emit("error",new Error("unrecognized packet type"))}this.disconnecting&&Object.keys(this.outgoing).length===0&&this.emit("outgoingEmpty")}else y("_handleAck :: Server sent an ack in error. Ignoring.")},A.prototype._handlePubrel=function(C,F){y("handling pubrel packet"),F=F!==void 0?F:E;const j=this,P={cmd:"pubcomp",messageId:C.messageId};j.incomingStore.get(C,function(J,$){J?j._sendPacket(P,F):(j.emit("message",$.topic,$.payload,$),j.handleMessage($,function(U){if(U)return F(U);j.incomingStore.del($,E),j._sendPacket(P,F)}))})},A.prototype._handleDisconnect=function(C){this.emit("disconnect",C)},A.prototype._nextId=function(){return this.messageIdProvider.allocate()},A.prototype.getLastMessageId=function(){return this.messageIdProvider.getLastAllocated()},A.prototype._resubscribe=function(){y("_resubscribe");const C=Object.keys(this._resubscribeTopics);if(!this._firstConnection&&(this.options.clean||this.options.protocolVersion===5&&!this.connackPacket.sessionPresent)&&C.length>0)if(this.options.resubscribe)if(this.options.protocolVersion===5){y("_resubscribe: protocolVersion 5");for(let F=0;F<C.length;F++){const j={};j[C[F]]=this._resubscribeTopics[C[F]],j.resubscribe=!0,this.subscribe(j,{properties:j[C[F]].properties})}}else this._resubscribeTopics.resubscribe=!0,this.subscribe(this._resubscribeTopics);else this._resubscribeTopics={};this._firstConnection=!1},A.prototype._onConnect=function(C){if(this.disconnected)return void this.emit("connect",C);const F=this;this.connackPacket=C,this.messageIdProvider.clear(),this._setupPingTimer(),this.connected=!0,function j(){let P=F.outgoingStore.createStream();function J(){F._storeProcessing=!1,F._packetIdsDuringStoreProcessing={}}function $(){P.destroy(),P=null,F._flushStoreProcessingQueue(),J()}F.once("close",$),P.on("error",function(U){J(),F._flushStoreProcessingQueue(),F.removeListener("close",$),F.emit("error",U)}),P.on("end",function(){let U=!0;for(const K in F._packetIdsDuringStoreProcessing)if(!F._packetIdsDuringStoreProcessing[K]){U=!1;break}U?(J(),F.removeListener("close",$),F._invokeAllStoreProcessingQueue(),F.emit("connect",C)):j()}),function U(){if(!P)return;F._storeProcessing=!0;const K=P.read(1);let L;K?F._packetIdsDuringStoreProcessing[K.messageId]?U():F.disconnecting||F.reconnectTimer?P.destroy&&P.destroy():(L=F.outgoing[K.messageId]?F.outgoing[K.messageId].cb:null,F.outgoing[K.messageId]={volatile:!1,cb:function(O,H){L&&L(O,H),U()}},F._packetIdsDuringStoreProcessing[K.messageId]=!0,F.messageIdProvider.register(K.messageId)?F._sendPacket(K):y("messageId: %d has already used.",K.messageId)):P.once("readable",U)}()}()},A.prototype._invokeStoreProcessingQueue=function(){if(this._storeProcessingQueue.length>0){const C=this._storeProcessingQueue[0];if(C&&C.invoke())return this._storeProcessingQueue.shift(),!0}return!1},A.prototype._invokeAllStoreProcessingQueue=function(){for(;this._invokeStoreProcessingQueue(););},A.prototype._flushStoreProcessingQueue=function(){for(const C of this._storeProcessingQueue)C.cbStorePut&&C.cbStorePut(new Error("Connection closed")),C.callback&&C.callback(new Error("Connection closed"));this._storeProcessingQueue.splice(0)},n.exports=A}).call(this)}).call(this,t("_process"),typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./default-message-id-provider":7,"./store":8,"./topic-alias-recv":9,"./topic-alias-send":10,"./validations":11,_process:50,debug:18,events:22,inherits:24,"mqtt-packet":40,"readable-stream":69,reinterval:70,"rfdc/default":71,xtend:81}],2:[function(t,n,l){const{Buffer:a}=t("buffer"),o=t("readable-stream").Transform,u=t("duplexify");let p,s,i,d=!1;n.exports=function(c,f){if(f.hostname=f.hostname||f.host,!f.hostname)throw new Error("Could not determine host. Specify host manually.");const h=f.protocolId==="MQIsdp"&&f.protocolVersion===3?"mqttv3.1":"mqtt";(function(m){m.hostname||(m.hostname="localhost"),m.path||(m.path="/"),m.wsOptions||(m.wsOptions={})})(f);const v=function(m,g){const x=m.protocol==="alis"?"wss":"ws";let y=x+"://"+m.hostname+m.path;return m.port&&m.port!==80&&m.port!==443&&(y=x+"://"+m.hostname+":"+m.port+m.path),typeof m.transformWsUrl=="function"&&(y=m.transformWsUrl(y,m,g)),y}(f,c);return(p=f.my).connectSocket({url:v,protocols:h}),s=function(){const m=new o;return m._write=function(g,x,y){p.sendSocketMessage({data:g.buffer,success:function(){y()},fail:function(){y(new Error)}})},m._flush=function(g){p.closeSocket({success:function(){g()}})},m}(),i=u.obj(),d||(d=!0,p.onSocketOpen(function(){i.setReadable(s),i.setWritable(s),i.emit("connect")}),p.onSocketMessage(function(m){if(typeof m.data=="string"){const g=a.from(m.data,"base64");s.push(g)}else{const g=new FileReader;g.addEventListener("load",function(){let x=g.result;x=x instanceof ArrayBuffer?a.from(x):a.from(x,"utf8"),s.push(x)}),g.readAsArrayBuffer(m.data)}}),p.onSocketClose(function(){i.end(),i.destroy()}),p.onSocketError(function(m){i.destroy(m)})),i}},{buffer:17,duplexify:20,"readable-stream":69}],3:[function(t,n,l){const a=t("net"),o=t("debug")("mqttjs:tcp");n.exports=function(u,p){p.port=p.port||1883,p.hostname=p.hostname||p.host||"localhost";const s=p.port,i=p.hostname;return o("port %d and host %s",s,i),a.createConnection(s,i)}},{debug:18,net:16}],4:[function(t,n,l){const a=t("tls"),o=t("net"),u=t("debug")("mqttjs:tls");n.exports=function(p,s){s.port=s.port||8883,s.host=s.hostname||s.host||"localhost",o.isIP(s.host)===0&&(s.servername=s.host),s.rejectUnauthorized=s.rejectUnauthorized!==!1,delete s.path,u("port %d host %s rejectUnauthorized %b",s.port,s.host,s.rejectUnauthorized);const i=a.connect(s);function d(c){s.rejectUnauthorized&&p.emit("error",c),i.end()}return i.on("secureConnect",function(){s.rejectUnauthorized&&!i.authorized?i.emit("error",new Error("TLS not authorized")):i.removeListener("error",d)}),i.on("error",d),i}},{debug:18,net:16,tls:16}],5:[function(t,n,l){(function(a){(function(){const{Buffer:o}=t("buffer"),u=t("ws"),p=t("debug")("mqttjs:ws"),s=t("duplexify"),i=t("readable-stream").Transform,d=["rejectUnauthorized","ca","cert","key","pfx","passphrase"],c=a!==void 0&&a.title==="browser"||typeof __webpack_require__=="function";function f(v,m){let g=v.protocol+"://"+v.hostname+":"+v.port+v.path;return typeof v.transformWsUrl=="function"&&(g=v.transformWsUrl(g,v,m)),g}function h(v){const m=v;return v.hostname||(m.hostname="localhost"),v.port||(v.protocol==="wss"?m.port=443:m.port=80),v.path||(m.path="/"),v.wsOptions||(m.wsOptions={}),c||v.protocol!=="wss"||d.forEach(function(g){Object.prototype.hasOwnProperty.call(v,g)&&!Object.prototype.hasOwnProperty.call(v.wsOptions,g)&&(m.wsOptions[g]=v[g])}),m}n.exports=c?function(v,m){let g;p("browserStreamBuilder");const x=function(C){const F=h(C);if(F.hostname||(F.hostname=F.host),!F.hostname){if(typeof document=="undefined")throw new Error("Could not determine host. Specify host manually.");const j=new URL(document.URL);F.hostname=j.hostname,F.port||(F.port=j.port)}return F.objectMode===void 0&&(F.objectMode=!(F.binary===!0||F.binary===void 0)),F}(m).browserBufferSize||524288,y=m.browserBufferTimeout||1e3,w=!m.objectMode,k=function(C,F){const j=F.protocolId==="MQIsdp"&&F.protocolVersion===3?"mqttv3.1":"mqtt",P=f(F,C),J=new WebSocket(P,[j]);return J.binaryType="arraybuffer",J}(v,m),T=function(C,F,j){const P=new i({objectModeMode:C.objectMode});return P._write=F,P._flush=j,P}(m,function C(F,j,P){k.bufferedAmount>x&&setTimeout(C,y,F,j,P),w&&typeof F=="string"&&(F=o.from(F,"utf8"));try{k.send(F)}catch(J){return P(J)}P()},function(C){k.close(),C()});m.objectMode||(T._writev=A),T.on("close",()=>{k.close()});const I=k.addEventListener!==void 0;function D(){g.setReadable(T),g.setWritable(T),g.emit("connect")}function X(){g.end(),g.destroy()}function V(C){g.destroy(C)}function E(C){let F=C.data;F=F instanceof ArrayBuffer?o.from(F):o.from(F,"utf8"),T.push(F)}function A(C,F){const j=new Array(C.length);for(let P=0;P<C.length;P++)typeof C[P].chunk=="string"?j[P]=o.from(C[P],"utf8"):j[P]=C[P].chunk;this._write(o.concat(j),"binary",F)}return k.readyState===k.OPEN?g=T:(g=g=s(void 0,void 0,m),m.objectMode||(g._writev=A),I?k.addEventListener("open",D):k.onopen=D),g.socket=k,I?(k.addEventListener("close",X),k.addEventListener("error",V),k.addEventListener("message",E)):(k.onclose=X,k.onerror=V,k.onmessage=E),g}:function(v,m){p("streamBuilder");const g=h(m),x=f(g,v),y=function(k,T,I){p("createWebSocket"),p("protocol: "+I.protocolId+" "+I.protocolVersion);const D=I.protocolId==="MQIsdp"&&I.protocolVersion===3?"mqttv3.1":"mqtt";return p("creating new Websocket for url: "+T+" and protocol: "+D),new u(T,[D],I.wsOptions)}(0,x,g),w=u.createWebSocketStream(y,g.wsOptions);return w.url=x,y.on("close",()=>{w.destroy()}),w}}).call(this)}).call(this,t("_process"))},{_process:50,buffer:17,debug:18,duplexify:20,"readable-stream":69,ws:80}],6:[function(t,n,l){const{Buffer:a}=t("buffer"),o=t("readable-stream").Transform,u=t("duplexify");let p,s,i;n.exports=function(d,c){if(c.hostname=c.hostname||c.host,!c.hostname)throw new Error("Could not determine host. Specify host manually.");const f=c.protocolId==="MQIsdp"&&c.protocolVersion===3?"mqttv3.1":"mqtt";(function(m){m.hostname||(m.hostname="localhost"),m.path||(m.path="/"),m.wsOptions||(m.wsOptions={})})(c);const h=function(m,g){const x=m.protocol==="wxs"?"wss":"ws";let y=x+"://"+m.hostname+m.path;return m.port&&m.port!==80&&m.port!==443&&(y=x+"://"+m.hostname+":"+m.port+m.path),typeof m.transformWsUrl=="function"&&(y=m.transformWsUrl(y,m,g)),y}(c,d);p=wx.connectSocket({url:h,protocols:[f]}),s=function(){const m=new o;return m._write=function(g,x,y){p.send({data:g.buffer,success:function(){y()},fail:function(w){y(new Error(w))}})},m._flush=function(g){p.close({success:function(){g()}})},m}(),(i=u.obj())._destroy=function(m,g){p.close({success:function(){g&&g(m)}})};const v=i.destroy;return i.destroy=function(){i.destroy=v;const m=this;setTimeout(function(){p.close({fail:function(){m._destroy(new Error)}})},0)}.bind(i),p.onOpen(function(){i.setReadable(s),i.setWritable(s),i.emit("connect")}),p.onMessage(function(m){let g=m.data;g=g instanceof ArrayBuffer?a.from(g):a.from(g,"utf8"),s.push(g)}),p.onClose(function(){i.end(),i.destroy()}),p.onError(function(m){i.destroy(new Error(m.errMsg))}),i}},{buffer:17,duplexify:20,"readable-stream":69}],7:[function(t,n,l){function a(){if(!(this instanceof a))return new a;this.nextId=Math.max(1,Math.floor(65535*Math.random()))}a.prototype.allocate=function(){const o=this.nextId++;return this.nextId===65536&&(this.nextId=1),o},a.prototype.getLastAllocated=function(){return this.nextId===1?65535:this.nextId-1},a.prototype.register=function(o){return!0},a.prototype.deallocate=function(o){},a.prototype.clear=function(){},n.exports=a},{}],8:[function(t,n,l){const a=t("xtend"),o=t("readable-stream").Readable,u={objectMode:!0},p={clean:!0};function s(i){if(!(this instanceof s))return new s(i);this.options=i||{},this.options=a(p,i),this._inflights=new Map}s.prototype.put=function(i,d){return this._inflights.set(i.messageId,i),d&&d(),this},s.prototype.createStream=function(){const i=new o(u),d=[];let c=!1,f=0;return this._inflights.forEach(function(h,v){d.push(h)}),i._read=function(){!c&&f<d.length?this.push(d[f++]):this.push(null)},i.destroy=function(){if(c)return;const h=this;c=!0,setTimeout(function(){h.emit("close")},0)},i},s.prototype.del=function(i,d){return(i=this._inflights.get(i.messageId))?(this._inflights.delete(i.messageId),d(null,i)):d&&d(new Error("missing packet")),this},s.prototype.get=function(i,d){return(i=this._inflights.get(i.messageId))?d(null,i):d&&d(new Error("missing packet")),this},s.prototype.close=function(i){this.options.clean&&(this._inflights=null),i&&i()},n.exports=s},{"readable-stream":69,xtend:81}],9:[function(t,n,l){function a(o){if(!(this instanceof a))return new a(o);this.aliasToTopic={},this.max=o}a.prototype.put=function(o,u){return!(u===0||u>this.max)&&(this.aliasToTopic[u]=o,this.length=Object.keys(this.aliasToTopic).length,!0)},a.prototype.getTopicByAlias=function(o){return this.aliasToTopic[o]},a.prototype.clear=function(){this.aliasToTopic={}},n.exports=a},{}],10:[function(t,n,l){const a=t("lru-cache"),o=t("number-allocator").NumberAllocator;function u(p){if(!(this instanceof u))return new u(p);p>0&&(this.aliasToTopic=new a({max:p}),this.topicToAlias={},this.numberAllocator=new o(1,p),this.max=p,this.length=0)}u.prototype.put=function(p,s){if(s===0||s>this.max)return!1;const i=this.aliasToTopic.get(s);return i&&delete this.topicToAlias[i],this.aliasToTopic.set(s,p),this.topicToAlias[p]=s,this.numberAllocator.use(s),this.length=this.aliasToTopic.length,!0},u.prototype.getTopicByAlias=function(p){return this.aliasToTopic.get(p)},u.prototype.getAliasByTopic=function(p){const s=this.topicToAlias[p];return s!==void 0&&this.aliasToTopic.get(s),s},u.prototype.clear=function(){this.aliasToTopic.reset(),this.topicToAlias={},this.numberAllocator.clear(),this.length=0},u.prototype.getLruAlias=function(){return this.numberAllocator.firstVacant()||this.aliasToTopic.keys()[this.aliasToTopic.length-1]},n.exports=u},{"lru-cache":37,"number-allocator":46}],11:[function(t,n,l){function a(o){const u=o.split("/");for(let p=0;p<u.length;p++)if(u[p]!=="+"){if(u[p]==="#")return p===u.length-1;if(u[p].indexOf("+")!==-1||u[p].indexOf("#")!==-1)return!1}return!0}n.exports={validateTopics:function(o){if(o.length===0)return"empty_topic_list";for(let u=0;u<o.length;u++)if(!a(o[u]))return o[u];return null}}},{}],12:[function(t,n,l){(function(a){(function(){const o=t("../client"),u=t("../store"),p=t("url"),s=t("xtend"),i=t("debug")("mqttjs"),d={};function c(f,h){if(i("connecting to an MQTT broker..."),typeof f!="object"||h||(h=f,f=null),h=h||{},f){const m=p.parse(f,!0);if(m.port!=null&&(m.port=Number(m.port)),(h=s(m,h)).protocol===null)throw new Error("Missing protocol");h.protocol=h.protocol.replace(/:$/,"")}if(function(m){let g;m.auth&&((g=m.auth.match(/^(.+):(.+)$/))?(m.username=g[1],m.password=g[2]):m.username=m.auth)}(h),h.query&&typeof h.query.clientId=="string"&&(h.clientId=h.query.clientId),h.cert&&h.key){if(!h.protocol)throw new Error("Missing secure protocol key");if(["mqtts","wss","wxs","alis"].indexOf(h.protocol)===-1)switch(h.protocol){case"mqtt":h.protocol="mqtts";break;case"ws":h.protocol="wss";break;case"wx":h.protocol="wxs";break;case"ali":h.protocol="alis";break;default:throw new Error('Unknown protocol for secure connection: "'+h.protocol+'"!')}}if(!d[h.protocol]){const m=["mqtts","wss"].indexOf(h.protocol)!==-1;h.protocol=["mqtt","mqtts","ws","wss","wx","wxs","ali","alis"].filter(function(g,x){return(!m||x%2!=0)&&typeof d[g]=="function"})[0]}if(h.clean===!1&&!h.clientId)throw new Error("Missing clientId for unclean clients");h.protocol&&(h.defaultProtocol=h.protocol);const v=new o(function(m){return h.servers&&(m._reconnectCount&&m._reconnectCount!==h.servers.length||(m._reconnectCount=0),h.host=h.servers[m._reconnectCount].host,h.port=h.servers[m._reconnectCount].port,h.protocol=h.servers[m._reconnectCount].protocol?h.servers[m._reconnectCount].protocol:h.defaultProtocol,h.hostname=h.host,m._reconnectCount++),i("calling streambuilder for",h.protocol),d[h.protocol](m,h)},h);return v.on("error",function(){}),v}a!==void 0&&a.title!=="browser"||typeof __webpack_require__!="function"?(d.mqtt=t("./tcp"),d.tcp=t("./tcp"),d.ssl=t("./tls"),d.tls=t("./tls"),d.mqtts=t("./tls")):(d.wx=t("./wx"),d.wxs=t("./wx"),d.ali=t("./ali"),d.alis=t("./ali")),d.ws=t("./ws"),d.wss=t("./ws"),n.exports=c,n.exports.connect=c,n.exports.MqttClient=o,n.exports.Store=u}).call(this)}).call(this,t("_process"))},{"../client":1,"../store":8,"./ali":2,"./tcp":3,"./tls":4,"./ws":5,"./wx":6,_process:50,debug:18,url:76,xtend:81}],13:[function(t,n,l){l.byteLength=function(f){var h=d(f),v=h[0],m=h[1];return 3*(v+m)/4-m},l.toByteArray=function(f){var h,v,m=d(f),g=m[0],x=m[1],y=new u(function(T,I,D){return 3*(I+D)/4-D}(0,g,x)),w=0,k=x>0?g-4:g;for(v=0;v<k;v+=4)h=o[f.charCodeAt(v)]<<18|o[f.charCodeAt(v+1)]<<12|o[f.charCodeAt(v+2)]<<6|o[f.charCodeAt(v+3)],y[w++]=h>>16&255,y[w++]=h>>8&255,y[w++]=255&h;return x===2&&(h=o[f.charCodeAt(v)]<<2|o[f.charCodeAt(v+1)]>>4,y[w++]=255&h),x===1&&(h=o[f.charCodeAt(v)]<<10|o[f.charCodeAt(v+1)]<<4|o[f.charCodeAt(v+2)]>>2,y[w++]=h>>8&255,y[w++]=255&h),y},l.fromByteArray=function(f){for(var h,v=f.length,m=v%3,g=[],x=0,y=v-m;x<y;x+=16383)g.push(c(f,x,x+16383>y?y:x+16383));return m===1?(h=f[v-1],g.push(a[h>>2]+a[h<<4&63]+"==")):m===2&&(h=(f[v-2]<<8)+f[v-1],g.push(a[h>>10]+a[h>>4&63]+a[h<<2&63]+"=")),g.join("")};for(var a=[],o=[],u=typeof Uint8Array!="undefined"?Uint8Array:Array,p="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,i=p.length;s<i;++s)a[s]=p[s],o[p.charCodeAt(s)]=s;function d(f){var h=f.length;if(h%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var v=f.indexOf("=");return v===-1&&(v=h),[v,v===h?0:4-v%4]}function c(f,h,v){for(var m,g,x=[],y=h;y<v;y+=3)m=(f[y]<<16&16711680)+(f[y+1]<<8&65280)+(255&f[y+2]),x.push(a[(g=m)>>18&63]+a[g>>12&63]+a[g>>6&63]+a[63&g]);return x.join("")}o[45]=62,o[95]=63},{}],14:[function(t,n,l){const{Buffer:a}=t("buffer"),o=Symbol.for("BufferList");function u(p){if(!(this instanceof u))return new u(p);u._init.call(this,p)}u._init=function(p){Object.defineProperty(this,o,{value:!0}),this._bufs=[],this.length=0,p&&this.append(p)},u.prototype._new=function(p){return new u(p)},u.prototype._offset=function(p){if(p===0)return[0,0];let s=0;for(let i=0;i<this._bufs.length;i++){const d=s+this._bufs[i].length;if(p<d||i===this._bufs.length-1)return[i,p-s];s=d}},u.prototype._reverseOffset=function(p){const s=p[0];let i=p[1];for(let d=0;d<s;d++)i+=this._bufs[d].length;return i},u.prototype.get=function(p){if(p>this.length||p<0)return;const s=this._offset(p);return this._bufs[s[0]][s[1]]},u.prototype.slice=function(p,s){return typeof p=="number"&&p<0&&(p+=this.length),typeof s=="number"&&s<0&&(s+=this.length),this.copy(null,0,p,s)},u.prototype.copy=function(p,s,i,d){if((typeof i!="number"||i<0)&&(i=0),(typeof d!="number"||d>this.length)&&(d=this.length),i>=this.length||d<=0)return p||a.alloc(0);const c=!!p,f=this._offset(i),h=d-i;let v=h,m=c&&s||0,g=f[1];if(i===0&&d===this.length){if(!c)return this._bufs.length===1?this._bufs[0]:a.concat(this._bufs,this.length);for(let x=0;x<this._bufs.length;x++)this._bufs[x].copy(p,m),m+=this._bufs[x].length;return p}if(v<=this._bufs[f[0]].length-g)return c?this._bufs[f[0]].copy(p,s,g,g+v):this._bufs[f[0]].slice(g,g+v);c||(p=a.allocUnsafe(h));for(let x=f[0];x<this._bufs.length;x++){const y=this._bufs[x].length-g;if(!(v>y)){this._bufs[x].copy(p,m,g,g+v),m+=y;break}this._bufs[x].copy(p,m,g),m+=y,v-=y,g&&(g=0)}return p.length>m?p.slice(0,m):p},u.prototype.shallowSlice=function(p,s){if(p=p||0,s=typeof s!="number"?this.length:s,p<0&&(p+=this.length),s<0&&(s+=this.length),p===s)return this._new();const i=this._offset(p),d=this._offset(s),c=this._bufs.slice(i[0],d[0]+1);return d[1]===0?c.pop():c[c.length-1]=c[c.length-1].slice(0,d[1]),i[1]!==0&&(c[0]=c[0].slice(i[1])),this._new(c)},u.prototype.toString=function(p,s,i){return this.slice(s,i).toString(p)},u.prototype.consume=function(p){if(p=Math.trunc(p),Number.isNaN(p)||p<=0)return this;for(;this._bufs.length;){if(!(p>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(p),this.length-=p;break}p-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},u.prototype.duplicate=function(){const p=this._new();for(let s=0;s<this._bufs.length;s++)p.append(this._bufs[s]);return p},u.prototype.append=function(p){if(p==null)return this;if(p.buffer)this._appendBuffer(a.from(p.buffer,p.byteOffset,p.byteLength));else if(Array.isArray(p))for(let s=0;s<p.length;s++)this.append(p[s]);else if(this._isBufferList(p))for(let s=0;s<p._bufs.length;s++)this.append(p._bufs[s]);else typeof p=="number"&&(p=p.toString()),this._appendBuffer(a.from(p));return this},u.prototype._appendBuffer=function(p){this._bufs.push(p),this.length+=p.length},u.prototype.indexOf=function(p,s,i){if(i===void 0&&typeof s=="string"&&(i=s,s=void 0),typeof p=="function"||Array.isArray(p))throw new TypeError('The "value" argument must be one of type string, Buffer, BufferList, or Uint8Array.');if(typeof p=="number"?p=a.from([p]):typeof p=="string"?p=a.from(p,i):this._isBufferList(p)?p=p.slice():Array.isArray(p.buffer)?p=a.from(p.buffer,p.byteOffset,p.byteLength):a.isBuffer(p)||(p=a.from(p)),s=Number(s||0),isNaN(s)&&(s=0),s<0&&(s=this.length+s),s<0&&(s=0),p.length===0)return s>this.length?this.length:s;const d=this._offset(s);let c=d[0],f=d[1];for(;c<this._bufs.length;c++){const h=this._bufs[c];for(;f<h.length;)if(h.length-f>=p.length){const v=h.indexOf(p,f);if(v!==-1)return this._reverseOffset([c,v]);f=h.length-p.length+1}else{const v=this._reverseOffset([c,f]);if(this._match(v,p))return v;f++}f=0}return-1},u.prototype._match=function(p,s){if(this.length-p<s.length)return!1;for(let i=0;i<s.length;i++)if(this.get(p+i)!==s[i])return!1;return!0},function(){const p={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1,readIntBE:null,readIntLE:null,readUIntBE:null,readUIntLE:null};for(const s in p)(function(i){u.prototype[i]=p[i]===null?function(d,c){return this.slice(d,d+c)[i](0,c)}:function(d=0){return this.slice(d,d+p[i])[i](0)}})(s)}(),u.prototype._isBufferList=function(p){return p instanceof u||u.isBufferList(p)},u.isBufferList=function(p){return p!=null&&p[o]},n.exports=u},{buffer:17}],15:[function(t,n,l){const a=t("readable-stream").Duplex,o=t("inherits"),u=t("./BufferList");function p(s){if(!(this instanceof p))return new p(s);if(typeof s=="function"){this._callback=s;const i=function(d){this._callback&&(this._callback(d),this._callback=null)}.bind(this);this.on("pipe",function(d){d.on("error",i)}),this.on("unpipe",function(d){d.removeListener("error",i)}),s=null}u._init.call(this,s),a.call(this)}o(p,a),Object.assign(p.prototype,u.prototype),p.prototype._new=function(s){return new p(s)},p.prototype._write=function(s,i,d){this._appendBuffer(s),typeof d=="function"&&d()},p.prototype._read=function(s){if(!this.length)return this.push(null);s=Math.min(s,this.length),this.push(this.slice(0,s)),this.consume(s)},p.prototype.end=function(s){a.prototype.end.call(this,s),this._callback&&(this._callback(null,this.slice()),this._callback=null)},p.prototype._destroy=function(s,i){this._bufs.length=0,this.length=0,i(s)},p.prototype._isBufferList=function(s){return s instanceof p||s instanceof u||p.isBufferList(s)},p.isBufferList=u.isBufferList,n.exports=p,n.exports.BufferListStream=p,n.exports.BufferList=u},{"./BufferList":14,inherits:24,"readable-stream":69}],16:[function(t,n,l){},{}],17:[function(t,n,l){(function(a){(function(){var o=t("base64-js"),u=t("ieee754");l.Buffer=i,l.SlowBuffer=function(b){return+b!=b&&(b=0),i.alloc(+b)},l.INSPECT_MAX_BYTES=50;var p=2147483647;function s(b){if(b>p)throw new RangeError('The value "'+b+'" is invalid for option "size"');var _=new Uint8Array(b);return _.__proto__=i.prototype,_}function i(b,_,R){if(typeof b=="number"){if(typeof _=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return f(b)}return d(b,_,R)}function d(b,_,R){if(typeof b=="string")return function(te,se){if(typeof se=="string"&&se!==""||(se="utf8"),!i.isEncoding(se))throw new TypeError("Unknown encoding: "+se);var z=0|m(te,se),S=s(z),B=S.write(te,se);return B!==z&&(S=S.slice(0,B)),S}(b,_);if(ArrayBuffer.isView(b))return h(b);if(b==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof b);if(oe(b,ArrayBuffer)||b&&oe(b.buffer,ArrayBuffer))return function(te,se,z){if(se<0||te.byteLength<se)throw new RangeError('"offset" is outside of buffer bounds');if(te.byteLength<se+(z||0))throw new RangeError('"length" is outside of buffer bounds');var S;return S=se===void 0&&z===void 0?new Uint8Array(te):z===void 0?new Uint8Array(te,se):new Uint8Array(te,se,z),S.__proto__=i.prototype,S}(b,_,R);if(typeof b=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var G=b.valueOf&&b.valueOf();if(G!=null&&G!==b)return i.from(G,_,R);var ee=function(te){if(i.isBuffer(te)){var se=0|v(te.length),z=s(se);return z.length===0||te.copy(z,0,0,se),z}if(te.length!==void 0)return typeof te.length!="number"||ae(te.length)?s(0):h(te);if(te.type==="Buffer"&&Array.isArray(te.data))return h(te.data)}(b);if(ee)return ee;if(typeof Symbol!="undefined"&&Symbol.toPrimitive!=null&&typeof b[Symbol.toPrimitive]=="function")return i.from(b[Symbol.toPrimitive]("string"),_,R);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof b)}function c(b){if(typeof b!="number")throw new TypeError('"size" argument must be of type number');if(b<0)throw new RangeError('The value "'+b+'" is invalid for option "size"')}function f(b){return c(b),s(b<0?0:0|v(b))}function h(b){for(var _=b.length<0?0:0|v(b.length),R=s(_),G=0;G<_;G+=1)R[G]=255&b[G];return R}function v(b){if(b>=p)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+p.toString(16)+" bytes");return 0|b}function m(b,_){if(i.isBuffer(b))return b.length;if(ArrayBuffer.isView(b)||oe(b,ArrayBuffer))return b.byteLength;if(typeof b!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof b);var R=b.length,G=arguments.length>2&&arguments[2]===!0;if(!G&&R===0)return 0;for(var ee=!1;;)switch(_){case"ascii":case"latin1":case"binary":return R;case"utf8":case"utf-8":return W(b).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*R;case"hex":return R>>>1;case"base64":return Z(b).length;default:if(ee)return G?-1:W(b).length;_=(""+_).toLowerCase(),ee=!0}}function g(b,_,R){var G=b[_];b[_]=b[R],b[R]=G}function x(b,_,R,G,ee){if(b.length===0)return-1;if(typeof R=="string"?(G=R,R=0):R>2147483647?R=2147483647:R<-2147483648&&(R=-2147483648),ae(R=+R)&&(R=ee?0:b.length-1),R<0&&(R=b.length+R),R>=b.length){if(ee)return-1;R=b.length-1}else if(R<0){if(!ee)return-1;R=0}if(typeof _=="string"&&(_=i.from(_,G)),i.isBuffer(_))return _.length===0?-1:y(b,_,R,G,ee);if(typeof _=="number")return _&=255,typeof Uint8Array.prototype.indexOf=="function"?ee?Uint8Array.prototype.indexOf.call(b,_,R):Uint8Array.prototype.lastIndexOf.call(b,_,R):y(b,[_],R,G,ee);throw new TypeError("val must be string, number or Buffer")}function y(b,_,R,G,ee){var te,se=1,z=b.length,S=_.length;if(G!==void 0&&((G=String(G).toLowerCase())==="ucs2"||G==="ucs-2"||G==="utf16le"||G==="utf-16le")){if(b.length<2||_.length<2)return-1;se=2,z/=2,S/=2,R/=2}function B(ce,me){return se===1?ce[me]:ce.readUInt16BE(me*se)}if(ee){var Y=-1;for(te=R;te<z;te++)if(B(b,te)===B(_,Y===-1?0:te-Y)){if(Y===-1&&(Y=te),te-Y+1===S)return Y*se}else Y!==-1&&(te-=te-Y),Y=-1}else for(R+S>z&&(R=z-S),te=R;te>=0;te--){for(var ie=!0,ue=0;ue<S;ue++)if(B(b,te+ue)!==B(_,ue)){ie=!1;break}if(ie)return te}return-1}function w(b,_,R,G){R=Number(R)||0;var ee=b.length-R;G?(G=Number(G))>ee&&(G=ee):G=ee;var te=_.length;G>te/2&&(G=te/2);for(var se=0;se<G;++se){var z=parseInt(_.substr(2*se,2),16);if(ae(z))return se;b[R+se]=z}return se}function k(b,_,R,G){return re(W(_,b.length-R),b,R,G)}function T(b,_,R,G){return re(function(ee){for(var te=[],se=0;se<ee.length;++se)te.push(255&ee.charCodeAt(se));return te}(_),b,R,G)}function I(b,_,R,G){return T(b,_,R,G)}function D(b,_,R,G){return re(Z(_),b,R,G)}function X(b,_,R,G){return re(function(ee,te){for(var se,z,S,B=[],Y=0;Y<ee.length&&!((te-=2)<0);++Y)se=ee.charCodeAt(Y),z=se>>8,S=se%256,B.push(S),B.push(z);return B}(_,b.length-R),b,R,G)}function V(b,_,R){return _===0&&R===b.length?o.fromByteArray(b):o.fromByteArray(b.slice(_,R))}function E(b,_,R){R=Math.min(b.length,R);for(var G=[],ee=_;ee<R;){var te,se,z,S,B=b[ee],Y=null,ie=B>239?4:B>223?3:B>191?2:1;if(ee+ie<=R)switch(ie){case 1:B<128&&(Y=B);break;case 2:(192&(te=b[ee+1]))==128&&(S=(31&B)<<6|63&te)>127&&(Y=S);break;case 3:te=b[ee+1],se=b[ee+2],(192&te)==128&&(192&se)==128&&(S=(15&B)<<12|(63&te)<<6|63&se)>2047&&(S<55296||S>57343)&&(Y=S);break;case 4:te=b[ee+1],se=b[ee+2],z=b[ee+3],(192&te)==128&&(192&se)==128&&(192&z)==128&&(S=(15&B)<<18|(63&te)<<12|(63&se)<<6|63&z)>65535&&S<1114112&&(Y=S)}Y===null?(Y=65533,ie=1):Y>65535&&(Y-=65536,G.push(Y>>>10&1023|55296),Y=56320|1023&Y),G.push(Y),ee+=ie}return function(ue){var ce=ue.length;if(ce<=A)return String.fromCharCode.apply(String,ue);for(var me="",ge=0;ge<ce;)me+=String.fromCharCode.apply(String,ue.slice(ge,ge+=A));return me}(G)}l.kMaxLength=p,i.TYPED_ARRAY_SUPPORT=function(){try{var b=new Uint8Array(1);return b.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},b.foo()===42}catch(_){return!1}}(),i.TYPED_ARRAY_SUPPORT||typeof console=="undefined"||typeof console.error!="function"||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(i.prototype,"parent",{enumerable:!0,get:function(){if(i.isBuffer(this))return this.buffer}}),Object.defineProperty(i.prototype,"offset",{enumerable:!0,get:function(){if(i.isBuffer(this))return this.byteOffset}}),typeof Symbol!="undefined"&&Symbol.species!=null&&i[Symbol.species]===i&&Object.defineProperty(i,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),i.poolSize=8192,i.from=function(b,_,R){return d(b,_,R)},i.prototype.__proto__=Uint8Array.prototype,i.__proto__=Uint8Array,i.alloc=function(b,_,R){return function(G,ee,te){return c(G),G<=0?s(G):ee!==void 0?typeof te=="string"?s(G).fill(ee,te):s(G).fill(ee):s(G)}(b,_,R)},i.allocUnsafe=function(b){return f(b)},i.allocUnsafeSlow=function(b){return f(b)},i.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==i.prototype},i.compare=function(b,_){if(oe(b,Uint8Array)&&(b=i.from(b,b.offset,b.byteLength)),oe(_,Uint8Array)&&(_=i.from(_,_.offset,_.byteLength)),!i.isBuffer(b)||!i.isBuffer(_))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(b===_)return 0;for(var R=b.length,G=_.length,ee=0,te=Math.min(R,G);ee<te;++ee)if(b[ee]!==_[ee]){R=b[ee],G=_[ee];break}return R<G?-1:G<R?1:0},i.isEncoding=function(b){switch(String(b).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}},i.concat=function(b,_){if(!Array.isArray(b))throw new TypeError('"list" argument must be an Array of Buffers');if(b.length===0)return i.alloc(0);var R;if(_===void 0)for(_=0,R=0;R<b.length;++R)_+=b[R].length;var G=i.allocUnsafe(_),ee=0;for(R=0;R<b.length;++R){var te=b[R];if(oe(te,Uint8Array)&&(te=i.from(te)),!i.isBuffer(te))throw new TypeError('"list" argument must be an Array of Buffers');te.copy(G,ee),ee+=te.length}return G},i.byteLength=m,i.prototype._isBuffer=!0,i.prototype.swap16=function(){var b=this.length;if(b%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var _=0;_<b;_+=2)g(this,_,_+1);return this},i.prototype.swap32=function(){var b=this.length;if(b%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var _=0;_<b;_+=4)g(this,_,_+3),g(this,_+1,_+2);return this},i.prototype.swap64=function(){var b=this.length;if(b%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var _=0;_<b;_+=8)g(this,_,_+7),g(this,_+1,_+6),g(this,_+2,_+5),g(this,_+3,_+4);return this},i.prototype.toString=function(){var b=this.length;return b===0?"":arguments.length===0?E(this,0,b):function(_,R,G){var ee=!1;if((R===void 0||R<0)&&(R=0),R>this.length||((G===void 0||G>this.length)&&(G=this.length),G<=0)||(G>>>=0)<=(R>>>=0))return"";for(_||(_="utf8");;)switch(_){case"hex":return j(this,R,G);case"utf8":case"utf-8":return E(this,R,G);case"ascii":return C(this,R,G);case"latin1":case"binary":return F(this,R,G);case"base64":return V(this,R,G);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,R,G);default:if(ee)throw new TypeError("Unknown encoding: "+_);_=(_+"").toLowerCase(),ee=!0}}.apply(this,arguments)},i.prototype.toLocaleString=i.prototype.toString,i.prototype.equals=function(b){if(!i.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b||i.compare(this,b)===0},i.prototype.inspect=function(){var b="",_=l.INSPECT_MAX_BYTES;return b=this.toString("hex",0,_).replace(/(.{2})/g,"$1 ").trim(),this.length>_&&(b+=" ... "),"<Buffer "+b+">"},i.prototype.compare=function(b,_,R,G,ee){if(oe(b,Uint8Array)&&(b=i.from(b,b.offset,b.byteLength)),!i.isBuffer(b))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof b);if(_===void 0&&(_=0),R===void 0&&(R=b?b.length:0),G===void 0&&(G=0),ee===void 0&&(ee=this.length),_<0||R>b.length||G<0||ee>this.length)throw new RangeError("out of range index");if(G>=ee&&_>=R)return 0;if(G>=ee)return-1;if(_>=R)return 1;if(_>>>=0,R>>>=0,G>>>=0,ee>>>=0,this===b)return 0;for(var te=ee-G,se=R-_,z=Math.min(te,se),S=this.slice(G,ee),B=b.slice(_,R),Y=0;Y<z;++Y)if(S[Y]!==B[Y]){te=S[Y],se=B[Y];break}return te<se?-1:se<te?1:0},i.prototype.includes=function(b,_,R){return this.indexOf(b,_,R)!==-1},i.prototype.indexOf=function(b,_,R){return x(this,b,_,R,!0)},i.prototype.lastIndexOf=function(b,_,R){return x(this,b,_,R,!1)},i.prototype.write=function(b,_,R,G){if(_===void 0)G="utf8",R=this.length,_=0;else if(R===void 0&&typeof _=="string")G=_,R=this.length,_=0;else{if(!isFinite(_))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");_>>>=0,isFinite(R)?(R>>>=0,G===void 0&&(G="utf8")):(G=R,R=void 0)}var ee=this.length-_;if((R===void 0||R>ee)&&(R=ee),b.length>0&&(R<0||_<0)||_>this.length)throw new RangeError("Attempt to write outside buffer bounds");G||(G="utf8");for(var te=!1;;)switch(G){case"hex":return w(this,b,_,R);case"utf8":case"utf-8":return k(this,b,_,R);case"ascii":return T(this,b,_,R);case"latin1":case"binary":return I(this,b,_,R);case"base64":return D(this,b,_,R);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return X(this,b,_,R);default:if(te)throw new TypeError("Unknown encoding: "+G);G=(""+G).toLowerCase(),te=!0}},i.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var A=4096;function C(b,_,R){var G="";R=Math.min(b.length,R);for(var ee=_;ee<R;++ee)G+=String.fromCharCode(127&b[ee]);return G}function F(b,_,R){var G="";R=Math.min(b.length,R);for(var ee=_;ee<R;++ee)G+=String.fromCharCode(b[ee]);return G}function j(b,_,R){var G=b.length;(!_||_<0)&&(_=0),(!R||R<0||R>G)&&(R=G);for(var ee="",te=_;te<R;++te)ee+=H(b[te]);return ee}function P(b,_,R){for(var G=b.slice(_,R),ee="",te=0;te<G.length;te+=2)ee+=String.fromCharCode(G[te]+256*G[te+1]);return ee}function J(b,_,R){if(b%1!=0||b<0)throw new RangeError("offset is not uint");if(b+_>R)throw new RangeError("Trying to access beyond buffer length")}function $(b,_,R,G,ee,te){if(!i.isBuffer(b))throw new TypeError('"buffer" argument must be a Buffer instance');if(_>ee||_<te)throw new RangeError('"value" argument is out of bounds');if(R+G>b.length)throw new RangeError("Index out of range")}function U(b,_,R,G,ee,te){if(R+G>b.length)throw new RangeError("Index out of range");if(R<0)throw new RangeError("Index out of range")}function K(b,_,R,G,ee){return _=+_,R>>>=0,ee||U(b,0,R,4),u.write(b,_,R,G,23,4),R+4}function L(b,_,R,G,ee){return _=+_,R>>>=0,ee||U(b,0,R,8),u.write(b,_,R,G,52,8),R+8}i.prototype.slice=function(b,_){var R=this.length;b=~~b,_=_===void 0?R:~~_,b<0?(b+=R)<0&&(b=0):b>R&&(b=R),_<0?(_+=R)<0&&(_=0):_>R&&(_=R),_<b&&(_=b);var G=this.subarray(b,_);return G.__proto__=i.prototype,G},i.prototype.readUIntLE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=this[b],ee=1,te=0;++te<_&&(ee*=256);)G+=this[b+te]*ee;return G},i.prototype.readUIntBE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=this[b+--_],ee=1;_>0&&(ee*=256);)G+=this[b+--_]*ee;return G},i.prototype.readUInt8=function(b,_){return b>>>=0,_||J(b,1,this.length),this[b]},i.prototype.readUInt16LE=function(b,_){return b>>>=0,_||J(b,2,this.length),this[b]|this[b+1]<<8},i.prototype.readUInt16BE=function(b,_){return b>>>=0,_||J(b,2,this.length),this[b]<<8|this[b+1]},i.prototype.readUInt32LE=function(b,_){return b>>>=0,_||J(b,4,this.length),(this[b]|this[b+1]<<8|this[b+2]<<16)+16777216*this[b+3]},i.prototype.readUInt32BE=function(b,_){return b>>>=0,_||J(b,4,this.length),16777216*this[b]+(this[b+1]<<16|this[b+2]<<8|this[b+3])},i.prototype.readIntLE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=this[b],ee=1,te=0;++te<_&&(ee*=256);)G+=this[b+te]*ee;return G>=(ee*=128)&&(G-=Math.pow(2,8*_)),G},i.prototype.readIntBE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=_,ee=1,te=this[b+--G];G>0&&(ee*=256);)te+=this[b+--G]*ee;return te>=(ee*=128)&&(te-=Math.pow(2,8*_)),te},i.prototype.readInt8=function(b,_){return b>>>=0,_||J(b,1,this.length),128&this[b]?-1*(255-this[b]+1):this[b]},i.prototype.readInt16LE=function(b,_){b>>>=0,_||J(b,2,this.length);var R=this[b]|this[b+1]<<8;return 32768&R?4294901760|R:R},i.prototype.readInt16BE=function(b,_){b>>>=0,_||J(b,2,this.length);var R=this[b+1]|this[b]<<8;return 32768&R?4294901760|R:R},i.prototype.readInt32LE=function(b,_){return b>>>=0,_||J(b,4,this.length),this[b]|this[b+1]<<8|this[b+2]<<16|this[b+3]<<24},i.prototype.readInt32BE=function(b,_){return b>>>=0,_||J(b,4,this.length),this[b]<<24|this[b+1]<<16|this[b+2]<<8|this[b+3]},i.prototype.readFloatLE=function(b,_){return b>>>=0,_||J(b,4,this.length),u.read(this,b,!0,23,4)},i.prototype.readFloatBE=function(b,_){return b>>>=0,_||J(b,4,this.length),u.read(this,b,!1,23,4)},i.prototype.readDoubleLE=function(b,_){return b>>>=0,_||J(b,8,this.length),u.read(this,b,!0,52,8)},i.prototype.readDoubleBE=function(b,_){return b>>>=0,_||J(b,8,this.length),u.read(this,b,!1,52,8)},i.prototype.writeUIntLE=function(b,_,R,G){b=+b,_>>>=0,R>>>=0,G||$(this,b,_,R,Math.pow(2,8*R)-1,0);var ee=1,te=0;for(this[_]=255&b;++te<R&&(ee*=256);)this[_+te]=b/ee&255;return _+R},i.prototype.writeUIntBE=function(b,_,R,G){b=+b,_>>>=0,R>>>=0,G||$(this,b,_,R,Math.pow(2,8*R)-1,0);var ee=R-1,te=1;for(this[_+ee]=255&b;--ee>=0&&(te*=256);)this[_+ee]=b/te&255;return _+R},i.prototype.writeUInt8=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,1,255,0),this[_]=255&b,_+1},i.prototype.writeUInt16LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,65535,0),this[_]=255&b,this[_+1]=b>>>8,_+2},i.prototype.writeUInt16BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,65535,0),this[_]=b>>>8,this[_+1]=255&b,_+2},i.prototype.writeUInt32LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,4294967295,0),this[_+3]=b>>>24,this[_+2]=b>>>16,this[_+1]=b>>>8,this[_]=255&b,_+4},i.prototype.writeUInt32BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,4294967295,0),this[_]=b>>>24,this[_+1]=b>>>16,this[_+2]=b>>>8,this[_+3]=255&b,_+4},i.prototype.writeIntLE=function(b,_,R,G){if(b=+b,_>>>=0,!G){var ee=Math.pow(2,8*R-1);$(this,b,_,R,ee-1,-ee)}var te=0,se=1,z=0;for(this[_]=255&b;++te<R&&(se*=256);)b<0&&z===0&&this[_+te-1]!==0&&(z=1),this[_+te]=(b/se>>0)-z&255;return _+R},i.prototype.writeIntBE=function(b,_,R,G){if(b=+b,_>>>=0,!G){var ee=Math.pow(2,8*R-1);$(this,b,_,R,ee-1,-ee)}var te=R-1,se=1,z=0;for(this[_+te]=255&b;--te>=0&&(se*=256);)b<0&&z===0&&this[_+te+1]!==0&&(z=1),this[_+te]=(b/se>>0)-z&255;return _+R},i.prototype.writeInt8=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,1,127,-128),b<0&&(b=255+b+1),this[_]=255&b,_+1},i.prototype.writeInt16LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,32767,-32768),this[_]=255&b,this[_+1]=b>>>8,_+2},i.prototype.writeInt16BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,32767,-32768),this[_]=b>>>8,this[_+1]=255&b,_+2},i.prototype.writeInt32LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,2147483647,-2147483648),this[_]=255&b,this[_+1]=b>>>8,this[_+2]=b>>>16,this[_+3]=b>>>24,_+4},i.prototype.writeInt32BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,2147483647,-2147483648),b<0&&(b=4294967295+b+1),this[_]=b>>>24,this[_+1]=b>>>16,this[_+2]=b>>>8,this[_+3]=255&b,_+4},i.prototype.writeFloatLE=function(b,_,R){return K(this,b,_,!0,R)},i.prototype.writeFloatBE=function(b,_,R){return K(this,b,_,!1,R)},i.prototype.writeDoubleLE=function(b,_,R){return L(this,b,_,!0,R)},i.prototype.writeDoubleBE=function(b,_,R){return L(this,b,_,!1,R)},i.prototype.copy=function(b,_,R,G){if(!i.isBuffer(b))throw new TypeError("argument should be a Buffer");if(R||(R=0),G||G===0||(G=this.length),_>=b.length&&(_=b.length),_||(_=0),G>0&&G<R&&(G=R),G===R||b.length===0||this.length===0)return 0;if(_<0)throw new RangeError("targetStart out of bounds");if(R<0||R>=this.length)throw new RangeError("Index out of range");if(G<0)throw new RangeError("sourceEnd out of bounds");G>this.length&&(G=this.length),b.length-_<G-R&&(G=b.length-_+R);var ee=G-R;if(this===b&&typeof Uint8Array.prototype.copyWithin=="function")this.copyWithin(_,R,G);else if(this===b&&R<_&&_<G)for(var te=ee-1;te>=0;--te)b[te+_]=this[te+R];else Uint8Array.prototype.set.call(b,this.subarray(R,G),_);return ee},i.prototype.fill=function(b,_,R,G){if(typeof b=="string"){if(typeof _=="string"?(G=_,_=0,R=this.length):typeof R=="string"&&(G=R,R=this.length),G!==void 0&&typeof G!="string")throw new TypeError("encoding must be a string");if(typeof G=="string"&&!i.isEncoding(G))throw new TypeError("Unknown encoding: "+G);if(b.length===1){var ee=b.charCodeAt(0);(G==="utf8"&&ee<128||G==="latin1")&&(b=ee)}}else typeof b=="number"&&(b&=255);if(_<0||this.length<_||this.length<R)throw new RangeError("Out of range index");if(R<=_)return this;var te;if(_>>>=0,R=R===void 0?this.length:R>>>0,b||(b=0),typeof b=="number")for(te=_;te<R;++te)this[te]=b;else{var se=i.isBuffer(b)?b:i.from(b,G),z=se.length;if(z===0)throw new TypeError('The value "'+b+'" is invalid for argument "value"');for(te=0;te<R-_;++te)this[te+_]=se[te%z]}return this};var O=/[^+/0-9A-Za-z-_]/g;function H(b){return b<16?"0"+b.toString(16):b.toString(16)}function W(b,_){var R;_=_||1/0;for(var G=b.length,ee=null,te=[],se=0;se<G;++se){if((R=b.charCodeAt(se))>55295&&R<57344){if(!ee){if(R>56319){(_-=3)>-1&&te.push(239,191,189);continue}if(se+1===G){(_-=3)>-1&&te.push(239,191,189);continue}ee=R;continue}if(R<56320){(_-=3)>-1&&te.push(239,191,189),ee=R;continue}R=65536+(ee-55296<<10|R-56320)}else ee&&(_-=3)>-1&&te.push(239,191,189);if(ee=null,R<128){if((_-=1)<0)break;te.push(R)}else if(R<2048){if((_-=2)<0)break;te.push(R>>6|192,63&R|128)}else if(R<65536){if((_-=3)<0)break;te.push(R>>12|224,R>>6&63|128,63&R|128)}else{if(!(R<1114112))throw new Error("Invalid code point");if((_-=4)<0)break;te.push(R>>18|240,R>>12&63|128,R>>6&63|128,63&R|128)}}return te}function Z(b){return o.toByteArray(function(_){if((_=(_=_.split("=")[0]).trim().replace(O,"")).length<2)return"";for(;_.length%4!=0;)_+="=";return _}(b))}function re(b,_,R,G){for(var ee=0;ee<G&&!(ee+R>=_.length||ee>=b.length);++ee)_[ee+R]=b[ee];return ee}function oe(b,_){return b instanceof _||b!=null&&b.constructor!=null&&b.constructor.name!=null&&b.constructor.name===_.name}function ae(b){return b!=b}}).call(this)}).call(this,t("buffer").Buffer)},{"base64-js":13,buffer:17,ieee754:23}],18:[function(t,n,l){(function(a){(function(){l.formatArgs=function(u){if(u[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+u[0]+(this.useColors?"%c ":" ")+"+"+n.exports.humanize(this.diff),!this.useColors)return;const p="color: "+this.color;u.splice(1,0,p,"color: inherit");let s=0,i=0;u[0].replace(/%[a-zA-Z%]/g,d=>{d!=="%%"&&d==="%c"&&(i=++s)}),u.splice(i,0,p)},l.save=function(u){try{u?l.storage.setItem("debug",u):l.storage.removeItem("debug")}catch(p){}},l.load=function(){let u;try{u=l.storage.getItem("debug")}catch(p){}return!u&&a!==void 0&&"env"in a&&(u=a.env.DEBUG),u},l.useColors=function(){return typeof window!="undefined"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document!="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},l.storage=function(){try{return localStorage}catch(u){}}(),l.destroy=(()=>{let u=!1;return()=>{u||(u=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),l.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],l.log=console.debug||console.log||(()=>{}),n.exports=t("./common")(l);const{formatters:o}=n.exports;o.j=function(u){try{return JSON.stringify(u)}catch(p){return"[UnexpectedJSONParseError]: "+p.message}}}).call(this)}).call(this,t("_process"))},{"./common":19,_process:50}],19:[function(t,n,l){n.exports=function(a){function o(s){let i,d,c,f=null;function h(...v){if(!h.enabled)return;const m=h,g=Number(new Date),x=g-(i||g);m.diff=x,m.prev=i,m.curr=g,i=g,v[0]=o.coerce(v[0]),typeof v[0]!="string"&&v.unshift("%O");let y=0;v[0]=v[0].replace(/%([a-zA-Z%])/g,(w,k)=>{if(w==="%%")return"%";y++;const T=o.formatters[k];if(typeof T=="function"){const I=v[y];w=T.call(m,I),v.splice(y,1),y--}return w}),o.formatArgs.call(m,v),(m.log||o.log).apply(m,v)}return h.namespace=s,h.useColors=o.useColors(),h.color=o.selectColor(s),h.extend=u,h.destroy=o.destroy,Object.defineProperty(h,"enabled",{enumerable:!0,configurable:!1,get:()=>f!==null?f:(d!==o.namespaces&&(d=o.namespaces,c=o.enabled(s)),c),set:v=>{f=v}}),typeof o.init=="function"&&o.init(h),h}function u(s,i){const d=o(this.namespace+(i===void 0?":":i)+s);return d.log=this.log,d}function p(s){return s.toString().substring(2,s.toString().length-2).replace(/\.\*\?$/,"*")}return o.debug=o,o.default=o,o.coerce=function(s){return s instanceof Error?s.stack||s.message:s},o.disable=function(){const s=[...o.names.map(p),...o.skips.map(p).map(i=>"-"+i)].join(",");return o.enable(""),s},o.enable=function(s){let i;o.save(s),o.namespaces=s,o.names=[],o.skips=[];const d=(typeof s=="string"?s:"").split(/[\s,]+/),c=d.length;for(i=0;i<c;i++)d[i]&&((s=d[i].replace(/\*/g,".*?"))[0]==="-"?o.skips.push(new RegExp("^"+s.substr(1)+"$")):o.names.push(new RegExp("^"+s+"$")))},o.enabled=function(s){if(s[s.length-1]==="*")return!0;let i,d;for(i=0,d=o.skips.length;i<d;i++)if(o.skips[i].test(s))return!1;for(i=0,d=o.names.length;i<d;i++)if(o.names[i].test(s))return!0;return!1},o.humanize=t("ms"),o.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(a).forEach(s=>{o[s]=a[s]}),o.names=[],o.skips=[],o.formatters={},o.selectColor=function(s){let i=0;for(let d=0;d<s.length;d++)i=(i<<5)-i+s.charCodeAt(d),i|=0;return o.colors[Math.abs(i)%o.colors.length]},o.enable(o.load()),o}},{ms:45}],20:[function(t,n,l){(function(a,o){(function(){var u=t("readable-stream"),p=t("end-of-stream"),s=t("inherits"),i=t("stream-shift"),d=o.from&&o.from!==Uint8Array.from?o.from([0]):new o([0]),c=function(m,g){m._corked?m.once("uncork",g):g()},f=function(m,g){return function(x){x?function(y,w){y._autoDestroy&&y.destroy(w)}(m,x.message==="premature close"?null:x):g&&!m._ended&&m.end()}},h=function(){},v=function(m,g,x){if(!(this instanceof v))return new v(m,g,x);u.Duplex.call(this,x),this._writable=null,this._readable=null,this._readable2=null,this._autoDestroy=!x||x.autoDestroy!==!1,this._forwardDestroy=!x||x.destroy!==!1,this._forwardEnd=!x||x.end!==!1,this._corked=1,this._ondrain=null,this._drained=!1,this._forwarding=!1,this._unwrite=null,this._unread=null,this._ended=!1,this.destroyed=!1,m&&this.setWritable(m),g&&this.setReadable(g)};s(v,u.Duplex),v.obj=function(m,g,x){return x||(x={}),x.objectMode=!0,x.highWaterMark=16,new v(m,g,x)},v.prototype.cork=function(){++this._corked==1&&this.emit("cork")},v.prototype.uncork=function(){this._corked&&--this._corked==0&&this.emit("uncork")},v.prototype.setWritable=function(m){if(this._unwrite&&this._unwrite(),this.destroyed)m&&m.destroy&&m.destroy();else if(m!==null&&m!==!1){var g=this,x=p(m,{writable:!0,readable:!1},f(this,this._forwardEnd)),y=function(){var w=g._ondrain;g._ondrain=null,w&&w()};this._unwrite&&a.nextTick(y),this._writable=m,this._writable.on("drain",y),this._unwrite=function(){g._writable.removeListener("drain",y),x()},this.uncork()}else this.end()},v.prototype.setReadable=function(m){if(this._unread&&this._unread(),this.destroyed)m&&m.destroy&&m.destroy();else{if(m===null||m===!1)return this.push(null),void this.resume();var g,x=this,y=p(m,{writable:!1,readable:!0},f(this)),w=function(){x._forward()},k=function(){x.push(null)};this._drained=!0,this._readable=m,this._readable2=m._readableState?m:(g=m,new u.Readable({objectMode:!0,highWaterMark:16}).wrap(g)),this._readable2.on("readable",w),this._readable2.on("end",k),this._unread=function(){x._readable2.removeListener("readable",w),x._readable2.removeListener("end",k),y()},this._forward()}},v.prototype._read=function(){this._drained=!0,this._forward()},v.prototype._forward=function(){if(!this._forwarding&&this._readable2&&this._drained){var m;for(this._forwarding=!0;this._drained&&(m=i(this._readable2))!==null;)this.destroyed||(this._drained=this.push(m));this._forwarding=!1}},v.prototype.destroy=function(m,g){if(g||(g=h),this.destroyed)return g(null);this.destroyed=!0;var x=this;a.nextTick(function(){x._destroy(m),g(null)})},v.prototype._destroy=function(m){if(m){var g=this._ondrain;this._ondrain=null,g?g(m):this.emit("error",m)}this._forwardDestroy&&(this._readable&&this._readable.destroy&&this._readable.destroy(),this._writable&&this._writable.destroy&&this._writable.destroy()),this.emit("close")},v.prototype._write=function(m,g,x){if(!this.destroyed)return this._corked?c(this,this._write.bind(this,m,g,x)):m===d?this._finish(x):this._writable?void(this._writable.write(m)===!1?this._ondrain=x:this.destroyed||x()):x()},v.prototype._finish=function(m){var g=this;this.emit("preend"),c(this,function(){var x,y;x=g._forwardEnd&&g._writable,y=function(){g._writableState.prefinished===!1&&(g._writableState.prefinished=!0),g.emit("prefinish"),c(g,m)},x?x._writableState&&x._writableState.finished?y():x._writableState?x.end(y):(x.end(),y()):y()})},v.prototype.end=function(m,g,x){return typeof m=="function"?this.end(null,null,m):typeof g=="function"?this.end(m,null,g):(this._ended=!0,m&&this.write(m),this._writableState.ending||this._writableState.destroyed||this.write(d),u.Writable.prototype.end.call(this,x))},n.exports=v}).call(this)}).call(this,t("_process"),t("buffer").Buffer)},{_process:50,buffer:17,"end-of-stream":21,inherits:24,"readable-stream":69,"stream-shift":74}],21:[function(t,n,l){(function(a){(function(){var o=t("once"),u=function(){},p=function(s,i,d){if(typeof i=="function")return p(s,null,i);i||(i={}),d=o(d||u);var c=s._writableState,f=s._readableState,h=i.readable||i.readable!==!1&&s.readable,v=i.writable||i.writable!==!1&&s.writable,m=!1,g=function(){s.writable||x()},x=function(){v=!1,h||d.call(s)},y=function(){h=!1,v||d.call(s)},w=function(X){d.call(s,X?new Error("exited with error code: "+X):null)},k=function(X){d.call(s,X)},T=function(){a.nextTick(I)},I=function(){if(!m)return(!h||f&&f.ended&&!f.destroyed)&&(!v||c&&c.ended&&!c.destroyed)?void 0:d.call(s,new Error("premature close"))},D=function(){s.req.on("finish",x)};return function(X){return X.setHeader&&typeof X.abort=="function"}(s)?(s.on("complete",x),s.on("abort",T),s.req?D():s.on("request",D)):v&&!c&&(s.on("end",g),s.on("close",g)),function(X){return X.stdio&&Array.isArray(X.stdio)&&X.stdio.length===3}(s)&&s.on("exit",w),s.on("end",y),s.on("finish",x),i.error!==!1&&s.on("error",k),s.on("close",T),function(){m=!0,s.removeListener("complete",x),s.removeListener("abort",T),s.removeListener("request",D),s.req&&s.req.removeListener("finish",x),s.removeListener("end",g),s.removeListener("close",g),s.removeListener("finish",x),s.removeListener("exit",w),s.removeListener("end",y),s.removeListener("error",k),s.removeListener("close",T)}};n.exports=p}).call(this)}).call(this,t("_process"))},{_process:50,once:48}],22:[function(t,n,l){var a=Object.create||function(y){var w=function(){};return w.prototype=y,new w},o=Object.keys||function(y){var w=[];for(var k in y)Object.prototype.hasOwnProperty.call(y,k)&&w.push(k);return k},u=Function.prototype.bind||function(y){var w=this;return function(){return w.apply(y,arguments)}};function p(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=a(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0}n.exports=p,p.EventEmitter=p,p.prototype._events=void 0,p.prototype._maxListeners=void 0;var s,i=10;try{var d={};Object.defineProperty&&Object.defineProperty(d,"x",{value:0}),s=d.x===0}catch(y){s=!1}function c(y){return y._maxListeners===void 0?p.defaultMaxListeners:y._maxListeners}function f(y,w,k,T){var I,D,X;if(typeof k!="function")throw new TypeError('"listener" argument must be a function');if((D=y._events)?(D.newListener&&(y.emit("newListener",w,k.listener?k.listener:k),D=y._events),X=D[w]):(D=y._events=a(null),y._eventsCount=0),X){if(typeof X=="function"?X=D[w]=T?[k,X]:[X,k]:T?X.unshift(k):X.push(k),!X.warned&&(I=c(y))&&I>0&&X.length>I){X.warned=!0;var V=new Error("Possible EventEmitter memory leak detected. "+X.length+' "'+String(w)+'" listeners added. Use emitter.setMaxListeners() to increase limit.');V.name="MaxListenersExceededWarning",V.emitter=y,V.type=w,V.count=X.length,typeof console=="object"&&console.warn&&console.warn("%s: %s",V.name,V.message)}}else X=D[w]=k,++y._eventsCount;return y}function h(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var y=new Array(arguments.length),w=0;w<y.length;++w)y[w]=arguments[w];this.listener.apply(this.target,y)}}function v(y,w,k){var T={fired:!1,wrapFn:void 0,target:y,type:w,listener:k},I=u.call(h,T);return I.listener=k,T.wrapFn=I,I}function m(y,w,k){var T=y._events;if(!T)return[];var I=T[w];return I?typeof I=="function"?k?[I.listener||I]:[I]:k?function(D){for(var X=new Array(D.length),V=0;V<X.length;++V)X[V]=D[V].listener||D[V];return X}(I):x(I,I.length):[]}function g(y){var w=this._events;if(w){var k=w[y];if(typeof k=="function")return 1;if(k)return k.length}return 0}function x(y,w){for(var k=new Array(w),T=0;T<w;++T)k[T]=y[T];return k}s?Object.defineProperty(p,"defaultMaxListeners",{enumerable:!0,get:function(){return i},set:function(y){if(typeof y!="number"||y<0||y!=y)throw new TypeError('"defaultMaxListeners" must be a positive number');i=y}}):p.defaultMaxListeners=i,p.prototype.setMaxListeners=function(y){if(typeof y!="number"||y<0||isNaN(y))throw new TypeError('"n" argument must be a positive number');return this._maxListeners=y,this},p.prototype.getMaxListeners=function(){return c(this)},p.prototype.emit=function(y){var w,k,T,I,D,X,V=y==="error";if(X=this._events)V=V&&X.error==null;else if(!V)return!1;if(V){if(arguments.length>1&&(w=arguments[1]),w instanceof Error)throw w;var E=new Error('Unhandled "error" event. ('+w+")");throw E.context=w,E}if(!(k=X[y]))return!1;var A=typeof k=="function";switch(T=arguments.length){case 1:(function(C,F,j){if(F)C.call(j);else for(var P=C.length,J=x(C,P),$=0;$<P;++$)J[$].call(j)})(k,A,this);break;case 2:(function(C,F,j,P){if(F)C.call(j,P);else for(var J=C.length,$=x(C,J),U=0;U<J;++U)$[U].call(j,P)})(k,A,this,arguments[1]);break;case 3:(function(C,F,j,P,J){if(F)C.call(j,P,J);else for(var $=C.length,U=x(C,$),K=0;K<$;++K)U[K].call(j,P,J)})(k,A,this,arguments[1],arguments[2]);break;case 4:(function(C,F,j,P,J,$){if(F)C.call(j,P,J,$);else for(var U=C.length,K=x(C,U),L=0;L<U;++L)K[L].call(j,P,J,$)})(k,A,this,arguments[1],arguments[2],arguments[3]);break;default:for(I=new Array(T-1),D=1;D<T;D++)I[D-1]=arguments[D];(function(C,F,j,P){if(F)C.apply(j,P);else for(var J=C.length,$=x(C,J),U=0;U<J;++U)$[U].apply(j,P)})(k,A,this,I)}return!0},p.prototype.addListener=function(y,w){return f(this,y,w,!1)},p.prototype.on=p.prototype.addListener,p.prototype.prependListener=function(y,w){return f(this,y,w,!0)},p.prototype.once=function(y,w){if(typeof w!="function")throw new TypeError('"listener" argument must be a function');return this.on(y,v(this,y,w)),this},p.prototype.prependOnceListener=function(y,w){if(typeof w!="function")throw new TypeError('"listener" argument must be a function');return this.prependListener(y,v(this,y,w)),this},p.prototype.removeListener=function(y,w){var k,T,I,D,X;if(typeof w!="function")throw new TypeError('"listener" argument must be a function');if(!(T=this._events))return this;if(!(k=T[y]))return this;if(k===w||k.listener===w)--this._eventsCount==0?this._events=a(null):(delete T[y],T.removeListener&&this.emit("removeListener",y,k.listener||w));else if(typeof k!="function"){for(I=-1,D=k.length-1;D>=0;D--)if(k[D]===w||k[D].listener===w){X=k[D].listener,I=D;break}if(I<0)return this;I===0?k.shift():function(V,E){for(var A=E,C=A+1,F=V.length;C<F;A+=1,C+=1)V[A]=V[C];V.pop()}(k,I),k.length===1&&(T[y]=k[0]),T.removeListener&&this.emit("removeListener",y,X||w)}return this},p.prototype.removeAllListeners=function(y){var w,k,T;if(!(k=this._events))return this;if(!k.removeListener)return arguments.length===0?(this._events=a(null),this._eventsCount=0):k[y]&&(--this._eventsCount==0?this._events=a(null):delete k[y]),this;if(arguments.length===0){var I,D=o(k);for(T=0;T<D.length;++T)(I=D[T])!=="removeListener"&&this.removeAllListeners(I);return this.removeAllListeners("removeListener"),this._events=a(null),this._eventsCount=0,this}if(typeof(w=k[y])=="function")this.removeListener(y,w);else if(w)for(T=w.length-1;T>=0;T--)this.removeListener(y,w[T]);return this},p.prototype.listeners=function(y){return m(this,y,!0)},p.prototype.rawListeners=function(y){return m(this,y,!1)},p.listenerCount=function(y,w){return typeof y.listenerCount=="function"?y.listenerCount(w):g.call(y,w)},p.prototype.listenerCount=g,p.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]}},{}],23:[function(t,n,l){l.read=function(a,o,u,p,s){var i,d,c=8*s-p-1,f=(1<<c)-1,h=f>>1,v=-7,m=u?s-1:0,g=u?-1:1,x=a[o+m];for(m+=g,i=x&(1<<-v)-1,x>>=-v,v+=c;v>0;i=256*i+a[o+m],m+=g,v-=8);for(d=i&(1<<-v)-1,i>>=-v,v+=p;v>0;d=256*d+a[o+m],m+=g,v-=8);if(i===0)i=1-h;else{if(i===f)return d?NaN:1/0*(x?-1:1);d+=Math.pow(2,p),i-=h}return(x?-1:1)*d*Math.pow(2,i-p)},l.write=function(a,o,u,p,s,i){var d,c,f,h=8*i-s-1,v=(1<<h)-1,m=v>>1,g=s===23?Math.pow(2,-24)-Math.pow(2,-77):0,x=p?0:i-1,y=p?1:-1,w=o<0||o===0&&1/o<0?1:0;for(o=Math.abs(o),isNaN(o)||o===1/0?(c=isNaN(o)?1:0,d=v):(d=Math.floor(Math.log(o)/Math.LN2),o*(f=Math.pow(2,-d))<1&&(d--,f*=2),(o+=d+m>=1?g/f:g*Math.pow(2,1-m))*f>=2&&(d++,f/=2),d+m>=v?(c=0,d=v):d+m>=1?(c=(o*f-1)*Math.pow(2,s),d+=m):(c=o*Math.pow(2,m-1)*Math.pow(2,s),d=0));s>=8;a[u+x]=255&c,x+=y,c/=256,s-=8);for(d=d<<s|c,h+=s;h>0;a[u+x]=255&d,x+=y,d/=256,h-=8);a[u+x-y]|=128*w}},{}],24:[function(t,n,l){typeof Object.create=="function"?n.exports=function(a,o){o&&(a.super_=o,a.prototype=Object.create(o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}))}:n.exports=function(a,o){if(o){a.super_=o;var u=function(){};u.prototype=o.prototype,a.prototype=new u,a.prototype.constructor=a}}},{}],25:[function(t,n,l){Object.defineProperty(l,"__esModule",{value:!0});var a=function(){function o(u,p){this.color=!0,this.key=void 0,this.value=void 0,this.parent=void 0,this.brother=void 0,this.leftChild=void 0,this.rightChild=void 0,this.key=u,this.value=p}return o.prototype.rotateLeft=function(){var u=this.parent,p=this.brother,s=this.leftChild,i=this.rightChild;if(!i)throw new Error("unknown error");var d=i.leftChild,c=i.rightChild;return u&&(u.leftChild===this?u.leftChild=i:u.rightChild===this&&(u.rightChild=i)),i.parent=u,i.brother=p,i.leftChild=this,i.rightChild=c,p&&(p.brother=i),this.parent=i,this.brother=c,this.leftChild=s,this.rightChild=d,c&&(c.parent=i,c.brother=this),s&&(s.parent=this,s.brother=d),d&&(d.parent=this,d.brother=s),i},o.prototype.rotateRight=function(){var u=this.parent,p=this.brother,s=this.leftChild;if(!s)throw new Error("unknown error");var i=this.rightChild,d=s.leftChild,c=s.rightChild;return u&&(u.leftChild===this?u.leftChild=s:u.rightChild===this&&(u.rightChild=s)),s.parent=u,s.brother=p,s.leftChild=d,s.rightChild=this,p&&(p.brother=s),d&&(d.parent=s,d.brother=this),this.parent=s,this.brother=d,this.leftChild=c,this.rightChild=i,c&&(c.parent=this,c.brother=i),i&&(i.parent=this,i.brother=c),s},o.prototype.remove=function(){if(this.leftChild||this.rightChild)throw new Error("can only remove leaf node");this.parent&&(this===this.parent.leftChild?this.parent.leftChild=void 0:this===this.parent.rightChild&&(this.parent.rightChild=void 0)),this.brother&&(this.brother.brother=void 0),this.key=void 0,this.value=void 0,this.parent=void 0,this.brother=void 0},o.TreeNodeColorType={red:!0,black:!1},o}();Object.freeze(a),l.default=a},{}],26:[function(t,n,l){var a=this&&this.__generator||function(u,p){var s,i,d,c,f={label:0,sent:function(){if(1&d[0])throw d[1];return d[1]},trys:[],ops:[]};return c={next:h(0),throw:h(1),return:h(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function h(v){return function(m){return function(g){if(s)throw new TypeError("Generator is already executing.");for(;f;)try{if(s=1,i&&(d=2&g[0]?i.return:g[0]?i.throw||((d=i.return)&&d.call(i),0):i.next)&&!(d=d.call(i,g[1])).done)return d;switch(i=0,d&&(g=[2&g[0],d.value]),g[0]){case 0:case 1:d=g;break;case 4:return f.label++,{value:g[1],done:!1};case 5:f.label++,i=g[1],g=[0];continue;case 7:g=f.ops.pop(),f.trys.pop();continue;default:if(!(d=(d=f.trys).length>0&&d[d.length-1])&&(g[0]===6||g[0]===2)){f=0;continue}if(g[0]===3&&(!d||g[1]>d[0]&&g[1]<d[3])){f.label=g[1];break}if(g[0]===6&&f.label<d[1]){f.label=d[1],d=g;break}if(d&&f.label<d[2]){f.label=d[2],f.ops.push(g);break}d[2]&&f.ops.pop(),f.trys.pop();continue}g=p.call(u,f)}catch(x){g=[6,x],i=0}finally{s=d=0}if(5&g[0])throw g[1];return{value:g[0]?g[1]:void 0,done:!0}}([v,m])}}};function o(u){var p=this;u===void 0&&(u=[]);var s=[],i=0,d=0,c=0,f=0,h=0,v=0;this.size=function(){return v},this.empty=function(){return v===0},this.clear=function(){i=c=d=f=h=v=0,g.call(this,o.bucketSize),v=0},this.front=function(){return s[i][d]},this.back=function(){return s[c][f]},this.forEach=function(x){if(!this.empty()){var y=0;if(i!==c){for(k=d;k<o.bucketSize;++k)x(s[i][k],y++);for(k=i+1;k<c;++k)for(var w=0;w<o.bucketSize;++w)x(s[k][w],y++);for(k=0;k<=f;++k)x(s[c][k],y++)}else for(var k=d;k<=f;++k)x(s[i][k],y++)}};var m=function(x){var y=i*o.bucketSize+d,w=y+x,k=c*o.bucketSize+f;if(w<y||w>k)throw new Error("pos should more than 0 and less than queue's size");return{curNodeBucketIndex:Math.floor(w/o.bucketSize),curNodePointerIndex:w%o.bucketSize}};this.getElementByPos=function(x){var y=m(x),w=y.curNodeBucketIndex,k=y.curNodePointerIndex;return s[w][k]},this.eraseElementByPos=function(x){var y=this;if(x<0||x>v)throw new Error("pos should more than 0 and less than queue's size");if(x===0)this.popFront();else if(x===this.size())this.popBack();else{for(var w=[],k=x+1;k<v;++k)w.push(this.getElementByPos(k));this.cut(x),this.popBack(),w.forEach(function(T){return y.pushBack(T)})}},this.eraseElementByValue=function(x){if(!this.empty()){var y=[];this.forEach(function(T){T!==x&&y.push(T)});for(var w=y.length,k=0;k<w;++k)this.setElementByPos(k,y[k]);this.cut(w-1)}};var g=function(x){for(var y=[],w=x*o.sigma,k=Math.max(Math.ceil(w/o.bucketSize),2),T=0;T<k;++T)y.push(new Array(o.bucketSize));var I=Math.ceil(x/o.bucketSize),D=Math.floor(k/2)-Math.floor(I/2),X=D,V=0;if(this.size())for(T=0;T<I;++T){for(var E=0;E<o.bucketSize;++E)if(y[D+T][E]=this.front(),this.popFront(),this.empty()){X=D+T,V=E;break}if(this.empty())break}s=y,i=D,d=0,c=X,f=V,h=k,v=x};this.pushBack=function(x){this.empty()||(c===h-1&&f===o.bucketSize-1&&g.call(this,this.size()),f<o.bucketSize-1?++f:c<h-1&&(++c,f=0)),++v,s[c][f]=x},this.popBack=function(){this.empty()||(this.size()!==1&&(f>0?--f:i<c&&(--c,f=o.bucketSize-1)),v>0&&--v)},this.setElementByPos=function(x,y){var w=m(x),k=w.curNodeBucketIndex,T=w.curNodePointerIndex;s[k][T]=y},this.insert=function(x,y,w){var k=this;if(w===void 0&&(w=1),x===0)for(;w--;)this.pushFront(y);else if(x===this.size())for(;w--;)this.pushBack(y);else{for(var T=[],I=x;I<v;++I)T.push(this.getElementByPos(I));for(this.cut(x-1),I=0;I<w;++I)this.pushBack(y);T.forEach(function(D){return k.pushBack(D)})}},this.find=function(x){if(i===c){for(var y=d;y<=f;++y)if(s[i][y]===x)return!0;return!1}for(y=d;y<o.bucketSize;++y)if(s[i][y]===x)return!0;for(y=i+1;y<c;++y)for(var w=0;w<o.bucketSize;++w)if(s[y][w]===x)return!0;for(y=0;y<=f;++y)if(s[c][y]===x)return!0;return!1},this.reverse=function(){for(var x=0,y=v-1;x<y;){var w=this.getElementByPos(x);this.setElementByPos(x,this.getElementByPos(y)),this.setElementByPos(y,w),++x,--y}},this.unique=function(){if(!this.empty()){var x=[],y=this.front();this.forEach(function(k,T){T!==0&&k===y||(x.push(k),y=k)});for(var w=0;w<v;++w)this.setElementByPos(w,x[w]);this.cut(x.length-1)}},this.sort=function(x){var y=[];this.forEach(function(k){y.push(k)}),y.sort(x);for(var w=0;w<v;++w)this.setElementByPos(w,y[w])},this.pushFront=function(x){this.empty()||(i===0&&d===0&&g.call(this,this.size()),d>0?--d:i>0&&(--i,d=o.bucketSize-1)),++v,s[i][d]=x},this.popFront=function(){this.empty()||(this.size()!==1&&(d<o.bucketSize-1?++d:i<c&&(++i,d=0)),v>0&&--v)},this.shrinkToFit=function(){var x=this,y=[];this.forEach(function(I){y.push(I)});var w=y.length;s=[];for(var k=Math.ceil(w/o.bucketSize),T=0;T<k;++T)s.push(new Array(o.bucketSize));this.clear(),y.forEach(function(I){return x.pushBack(I)})},this.cut=function(x){if(x<0)this.clear();else{var y=m(x),w=y.curNodeBucketIndex,k=y.curNodePointerIndex;c=w,f=k,v=x+1}},this[Symbol.iterator]=function(){return function(){var x,y;return a(this,function(w){switch(w.label){case 0:if(v===0)return[2];if(i!==c)return[3,5];y=d,w.label=1;case 1:return y<=f?[4,s[i][y]]:[3,4];case 2:w.sent(),w.label=3;case 3:return++y,[3,1];case 4:return[2];case 5:y=d,w.label=6;case 6:return y<o.bucketSize?[4,s[i][y]]:[3,9];case 7:w.sent(),w.label=8;case 8:return++y,[3,6];case 9:y=i+1,w.label=10;case 10:if(!(y<c))return[3,15];x=0,w.label=11;case 11:return x<o.bucketSize?[4,s[y][x]]:[3,14];case 12:w.sent(),w.label=13;case 13:return++x,[3,11];case 14:return++y,[3,10];case 15:y=0,w.label=16;case 16:return y<=f?[4,s[c][y]]:[3,19];case 17:w.sent(),w.label=18;case 18:return++y,[3,16];case 19:return[2]}})}()},function(){var x=o.bucketSize;u.size?x=u.size():u.length&&(x=u.length);var y=x*o.sigma;h=Math.ceil(y/o.bucketSize),h=Math.max(h,3);for(var w=0;w<h;++w)s.push(new Array(o.bucketSize));var k=Math.ceil(x/o.bucketSize);i=Math.floor(h/2)-Math.floor(k/2),c=i,u.forEach(function(T){return p.pushBack(T)})}(),Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),o.sigma=3,o.bucketSize=5e3,Object.freeze(o),l.default=o},{}],27:[function(t,n,l){var a=this&&this.__generator||function(i,d){var c,f,h,v,m={label:0,sent:function(){if(1&h[0])throw h[1];return h[1]},trys:[],ops:[]};return v={next:g(0),throw:g(1),return:g(2)},typeof Symbol=="function"&&(v[Symbol.iterator]=function(){return this}),v;function g(x){return function(y){return function(w){if(c)throw new TypeError("Generator is already executing.");for(;m;)try{if(c=1,f&&(h=2&w[0]?f.return:w[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,w[1])).done)return h;switch(f=0,h&&(w=[2&w[0],h.value]),w[0]){case 0:case 1:h=w;break;case 4:return m.label++,{value:w[1],done:!1};case 5:m.label++,f=w[1],w=[0];continue;case 7:w=m.ops.pop(),m.trys.pop();continue;default:if(!(h=(h=m.trys).length>0&&h[h.length-1])&&(w[0]===6||w[0]===2)){m=0;continue}if(w[0]===3&&(!h||w[1]>h[0]&&w[1]<h[3])){m.label=w[1];break}if(w[0]===6&&m.label<h[1]){m.label=h[1],h=w;break}if(h&&m.label<h[2]){m.label=h[2],m.ops.push(w);break}h[2]&&m.ops.pop(),m.trys.pop();continue}w=d.call(i,m)}catch(k){w=[6,k],f=0}finally{c=h=0}if(5&w[0])throw w[1];return{value:w[0]?w[1]:void 0,done:!0}}([x,y])}}},o=this&&this.__values||function(i){var d=typeof Symbol=="function"&&Symbol.iterator,c=d&&i[d],f=0;if(c)return c.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(d?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../LinkList/LinkList"),p=t("../Map/Map");function s(i,d,c){var f=this;if(i===void 0&&(i=[]),d===void 0&&(d=s.initSize),c=c||function(g){var x,y,w=0,k="";if(typeof g=="number")w=((w=Math.floor(g))<<5)-w,w&=w;else{k=typeof g!="string"?JSON.stringify(g):g;try{for(var T=o(k),I=T.next();!I.done;I=T.next())w=(w<<5)-w+I.value.charCodeAt(0),w&=w}catch(D){x={error:D}}finally{try{I&&!I.done&&(y=T.return)&&y.call(T)}finally{if(x)throw x.error}}}return w^=w>>>16},(d&d-1)!=0)throw new Error("initBucketNum must be 2 to the power of n");var h=0,v=[],m=Math.max(s.initSize,Math.min(s.maxSize,d));this.size=function(){return h},this.empty=function(){return h===0},this.clear=function(){h=0,m=d,v=[]},this.forEach=function(g){var x=0;v.forEach(function(y){y.forEach(function(w){g(w,x++)})})},this.setElement=function(g,x){var y,w;if(g==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");if(x!=null){var k=c(g)&m-1;if(v[k]){var T=v[k].size();if(v[k]instanceof u.default){try{for(var I=o(v[k]),D=I.next();!D.done;D=I.next()){var X=D.value;if(X.key===g)return void(X.value=x)}}catch(E){y={error:E}}finally{try{D&&!D.done&&(w=I.return)&&w.call(I)}finally{if(y)throw y.error}}v[k].pushBack({key:g,value:x}),v[k].size()>=s.treeifyThreshold&&(v[k]=new p.default(v[k]))}else v[k].setElement(g,x);var V=v[k].size();h+=V-T}else++h,v[k]=new u.default([{key:g,value:x}]);h>m*s.sigma&&function(E){if(!(E>=s.maxSize)){m=2*E;var A=[];v.forEach(function(C,F){if(!C.empty()){if(C instanceof u.default&&C.size()===1){var j=C.front(),P=j.key,J=j.value;A[c(P)&m-1]=new u.default([{key:P,value:J}])}else if(C instanceof p.default){var $=new u.default,U=new u.default;C.forEach(function(O){c(O.key)&E?U.pushBack(O):$.pushBack(O)}),$.size()>s.untreeifyThreshold?A[F]=new p.default($):$.size()&&(A[F]=$),U.size()>s.untreeifyThreshold?A[F+E]=new p.default(U):U.size()&&(A[F+E]=U)}else{var K=new u.default,L=new u.default;C.forEach(function(O){c(O.key)&E?L.pushBack(O):K.pushBack(O)}),K.size()&&(A[F]=K),L.size()&&(A[F+E]=L)}v[F].clear()}}),v=A}}.call(this,m)}else this.eraseElementByKey(g)},this.getElementByKey=function(g){var x,y,w=c(g)&m-1;if(v[w]){if(v[w]instanceof p.default)return v[w].getElementByKey(g);try{for(var k=o(v[w]),T=k.next();!T.done;T=k.next()){var I=T.value;if(I.key===g)return I.value}}catch(D){x={error:D}}finally{try{T&&!T.done&&(y=k.return)&&y.call(k)}finally{if(x)throw x.error}}}},this.eraseElementByKey=function(g){var x,y,w=c(g)&m-1;if(v[w]){var k=v[w].size();if(v[w]instanceof p.default)v[w].eraseElementByKey(g),v[w].size()<=s.untreeifyThreshold&&(v[w]=new u.default(v[w]));else{var T=-1;try{for(var I=o(v[w]),D=I.next();!D.done;D=I.next())if(++T,D.value.key===g){v[w].eraseElementByPos(T);break}}catch(V){x={error:V}}finally{try{D&&!D.done&&(y=I.return)&&y.call(I)}finally{if(x)throw x.error}}}var X=v[w].size();h+=X-k}},this.find=function(g){var x,y,w=c(g)&m-1;if(!v[w])return!1;if(v[w]instanceof p.default)return v[w].find(g);try{for(var k=o(v[w]),T=k.next();!T.done;T=k.next())if(T.value.key===g)return!0}catch(I){x={error:I}}finally{try{T&&!T.done&&(y=k.return)&&y.call(k)}finally{if(x)throw x.error}}return!1},this[Symbol.iterator]=function(){return function(){var g,x,y,w,k,T;return a(this,function(I){switch(I.label){case 0:g=0,I.label=1;case 1:if(!(g<m))return[3,10];for(;g<m&&!v[g];)++g;if(g>=m)return[3,10];I.label=2;case 2:I.trys.push([2,7,8,9]),k=void 0,x=o(v[g]),y=x.next(),I.label=3;case 3:return y.done?[3,6]:[4,y.value];case 4:I.sent(),I.label=5;case 5:return y=x.next(),[3,3];case 6:return[3,9];case 7:return w=I.sent(),k={error:w},[3,9];case 8:try{y&&!y.done&&(T=x.return)&&T.call(x)}finally{if(k)throw k.error}return[7];case 9:return++g,[3,1];case 10:return[2]}})}()},i.forEach(function(g){var x=g.key,y=g.value;return f.setElement(x,y)}),Object.freeze(this)}s.initSize=16,s.maxSize=1<<30,s.sigma=.75,s.treeifyThreshold=8,s.untreeifyThreshold=6,s.minTreeifySize=64,Object.freeze(s),l.default=s},{"../LinkList/LinkList":29,"../Map/Map":30}],28:[function(t,n,l){var a=this&&this.__generator||function(i,d){var c,f,h,v,m={label:0,sent:function(){if(1&h[0])throw h[1];return h[1]},trys:[],ops:[]};return v={next:g(0),throw:g(1),return:g(2)},typeof Symbol=="function"&&(v[Symbol.iterator]=function(){return this}),v;function g(x){return function(y){return function(w){if(c)throw new TypeError("Generator is already executing.");for(;m;)try{if(c=1,f&&(h=2&w[0]?f.return:w[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,w[1])).done)return h;switch(f=0,h&&(w=[2&w[0],h.value]),w[0]){case 0:case 1:h=w;break;case 4:return m.label++,{value:w[1],done:!1};case 5:m.label++,f=w[1],w=[0];continue;case 7:w=m.ops.pop(),m.trys.pop();continue;default:if(!(h=(h=m.trys).length>0&&h[h.length-1])&&(w[0]===6||w[0]===2)){m=0;continue}if(w[0]===3&&(!h||w[1]>h[0]&&w[1]<h[3])){m.label=w[1];break}if(w[0]===6&&m.label<h[1]){m.label=h[1],h=w;break}if(h&&m.label<h[2]){m.label=h[2],m.ops.push(w);break}h[2]&&m.ops.pop(),m.trys.pop();continue}w=d.call(i,m)}catch(k){w=[6,k],f=0}finally{c=h=0}if(5&w[0])throw w[1];return{value:w[0]?w[1]:void 0,done:!0}}([x,y])}}},o=this&&this.__values||function(i){var d=typeof Symbol=="function"&&Symbol.iterator,c=d&&i[d],f=0;if(c)return c.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(d?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../Set/Set"),p=t("../LinkList/LinkList");function s(i,d,c){var f=this;if(i===void 0&&(i=[]),d===void 0&&(d=s.initSize),c=c||function(g){var x=0,y="";if(typeof g=="number")x=((x=Math.floor(g))<<5)-x,x&=x;else{y=typeof g!="string"?JSON.stringify(g):g;for(var w=0;w<y.length;w++)x=(x<<5)-x+y.charCodeAt(w),x&=x}return x^=x>>>16},(d&d-1)!=0)throw new Error("initBucketNum must be 2 to the power of n");var h=0,v=[],m=Math.max(s.initSize,Math.min(s.maxSize,d));this.size=function(){return h},this.empty=function(){return h===0},this.clear=function(){h=0,m=d,v=[]},this.forEach=function(g){var x=0;v.forEach(function(y){y.forEach(function(w){g(w,x++)})})},this.insert=function(g){if(g==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");var x=c(g)&m-1;if(v[x]){var y=v[x].size();if(v[x]instanceof p.default){if(v[x].find(g))return;v[x].pushBack(g),v[x].size()>=s.treeifyThreshold&&(v[x]=new u.default(v[x]))}else v[x].insert(g);var w=v[x].size();h+=w-y}else v[x]=new p.default([g]),++h;h>m*s.sigma&&function(k){if(!(k>=s.maxSize)){m=2*k;var T=[];v.forEach(function(I,D){if(!I.empty()){if(I instanceof p.default&&I.size()===1){var X=I.front();if(X===void 0)throw new Error("unknown error");T[c(X)&m-1]=new p.default([X])}else if(I instanceof u.default){var V=new p.default,E=new p.default;I.forEach(function(F){c(F)&k?E.pushBack(F):V.pushBack(F)}),V.size()>s.untreeifyThreshold?T[D]=new u.default(V):V.size()&&(T[D]=V),E.size()>s.untreeifyThreshold?T[D+k]=new u.default(E):E.size()&&(T[D+k]=E)}else{var A=new p.default,C=new p.default;I.forEach(function(F){c(F)&k?C.pushBack(F):A.pushBack(F)}),A.size()&&(T[D]=A),C.size()&&(T[D+k]=C)}v[D].clear()}}),v=T}}.call(this,m)},this.eraseElementByValue=function(g){var x=c(g)&m-1;if(v[x]){var y=v[x].size();v[x].eraseElementByValue(g),v[x]instanceof u.default&&v[x].size()<=s.untreeifyThreshold&&(v[x]=new p.default(v[x]));var w=v[x].size();h+=w-y}},this.find=function(g){var x=c(g)&m-1;return!!v[x]&&v[x].find(g)},this[Symbol.iterator]=function(){return function(){var g,x,y,w,k,T;return a(this,function(I){switch(I.label){case 0:g=0,I.label=1;case 1:if(!(g<m))return[3,10];for(;g<m&&!v[g];)++g;if(g>=m)return[3,10];I.label=2;case 2:I.trys.push([2,7,8,9]),k=void 0,x=o(v[g]),y=x.next(),I.label=3;case 3:return y.done?[3,6]:[4,y.value];case 4:I.sent(),I.label=5;case 5:return y=x.next(),[3,3];case 6:return[3,9];case 7:return w=I.sent(),k={error:w},[3,9];case 8:try{y&&!y.done&&(T=x.return)&&T.call(x)}finally{if(k)throw k.error}return[7];case 9:return++g,[3,1];case 10:return[2]}})}()},i.forEach(function(g){return f.insert(g)}),Object.freeze(this)}s.initSize=16,s.maxSize=1<<30,s.sigma=.75,s.treeifyThreshold=8,s.untreeifyThreshold=6,s.minTreeifySize=64,Object.freeze(s),l.default=s},{"../LinkList/LinkList":29,"../Set/Set":33}],29:[function(t,n,l){var a=this&&this.__generator||function(p,s){var i,d,c,f,h={label:0,sent:function(){if(1&c[0])throw c[1];return c[1]},trys:[],ops:[]};return f={next:v(0),throw:v(1),return:v(2)},typeof Symbol=="function"&&(f[Symbol.iterator]=function(){return this}),f;function v(m){return function(g){return function(x){if(i)throw new TypeError("Generator is already executing.");for(;h;)try{if(i=1,d&&(c=2&x[0]?d.return:x[0]?d.throw||((c=d.return)&&c.call(d),0):d.next)&&!(c=c.call(d,x[1])).done)return c;switch(d=0,c&&(x=[2&x[0],c.value]),x[0]){case 0:case 1:c=x;break;case 4:return h.label++,{value:x[1],done:!1};case 5:h.label++,d=x[1],x=[0];continue;case 7:x=h.ops.pop(),h.trys.pop();continue;default:if(!(c=(c=h.trys).length>0&&c[c.length-1])&&(x[0]===6||x[0]===2)){h=0;continue}if(x[0]===3&&(!c||x[1]>c[0]&&x[1]<c[3])){h.label=x[1];break}if(x[0]===6&&h.label<c[1]){h.label=c[1],c=x;break}if(c&&h.label<c[2]){h.label=c[2],h.ops.push(x);break}c[2]&&h.ops.pop(),h.trys.pop();continue}x=s.call(p,h)}catch(y){x=[6,y],d=0}finally{i=c=0}if(5&x[0])throw x[1];return{value:x[0]?x[1]:void 0,done:!0}}([m,g])}}};Object.defineProperty(l,"__esModule",{value:!0});var o=function(){return function(p){this.value=void 0,this.pre=void 0,this.next=void 0,this.value=p}}();function u(p){var s=this;p===void 0&&(p=[]);var i=0,d=void 0,c=void 0;this.size=function(){return i},this.empty=function(){return i===0},this.clear=function(){d=c=void 0,i=0},this.front=function(){return d==null?void 0:d.value},this.back=function(){return c==null?void 0:c.value},this.forEach=function(f){for(var h=d,v=0;h;){if(h.value===void 0)throw new Error("unknown error");f(h.value,v++),h=h.next}},this.getElementByPos=function(f){if(f<0||f>=i)throw new Error("pos must more then 0 and less then the list length");for(var h=d;f--&&h;)h=h.next;if(!h||h.value===void 0)throw new Error("unknown error");return h.value},this.eraseElementByPos=function(f){if(f<0||f>=i)throw new Error("erase pos must more then 0 and less then the list length");if(f===0)this.popFront();else if(f===i-1)this.popBack();else{for(var h=d;f--;){if(!(h!=null&&h.next))throw new Error("unknown error");h=h.next}if(!h||!h.pre||!h.next)throw new Error("unknown error");var v=h.pre,m=h.next;m.pre=v,v.next=m,i>0&&--i}},this.eraseElementByValue=function(f){for(;d&&d.value===f;)this.popFront();for(;c&&c.value===f;)this.popBack();if(d)for(var h=d;h;){if(h.value===f){var v=h.pre,m=h.next;m&&(m.pre=v),v&&(v.next=m),i>0&&--i}h=h.next}},this.pushBack=function(f){if(f==null)throw new Error("you can't push null or undefined here");++i;var h=new o(f);c?(c.next=h,h.pre=c,c=h):d=c=h},this.popBack=function(){c&&(i>0&&--i,c&&(d===c?d=c=void 0:(c=c.pre)&&(c.next=void 0)))},this.setElementByPos=function(f,h){if(h==null)throw new Error("you can't set null or undefined here");if(f<0||f>=i)throw new Error("pos must more then 0 and less then the list length");for(var v=d;f--;){if(!v)throw new Error("unknown error");v=v.next}v&&(v.value=h)},this.insert=function(f,h,v){if(v===void 0&&(v=1),h==null)throw new Error("you can't insert null or undefined here");if(f<0||f>i)throw new Error("insert pos must more then 0 and less then or equal to the list length");if(v<0)throw new Error("insert size must more than 0");if(f===0)for(;v--;)this.pushFront(h);else if(f===i)for(;v--;)this.pushBack(h);else{for(var m=d,g=1;g<f;++g){if(!(m!=null&&m.next))throw new Error("unknown error");m=m==null?void 0:m.next}if(!m)throw new Error("unknown error");var x=m.next;for(i+=v;v--;)m.next=new o(h),m.next.pre=m,m=m.next;m.next=x,x&&(x.pre=m)}},this.find=function(f){for(var h=d;h;){if(h.value===f)return!0;h=h.next}return!1},this.reverse=function(){for(var f=d,h=c,v=0;f&&h&&2*v<i;){var m=f.value;f.value=h.value,h.value=m,f=f.next,h=h.pre,++v}},this.unique=function(){for(var f=d;f;){for(var h=f;h&&h.next&&h.value===h.next.value;)h=h.next,i>0&&--i;f.next=h.next,f.next&&(f.next.pre=f),f=f.next}},this.sort=function(f){var h=[];this.forEach(function(m){h.push(m)}),h.sort(f);var v=d;h.forEach(function(m){v&&(v.value=m,v=v.next)})},this.pushFront=function(f){if(f==null)throw new Error("you can't push null or undefined here");++i;var h=new o(f);d?(h.next=d,d.pre=h,d=h):d=c=h},this.popFront=function(){d&&(i>0&&--i,d&&(d===c?d=c=void 0:(d=d.next)&&(d.pre=void 0)))},this.merge=function(f){var h=this,v=d;f.forEach(function(m){for(;v&&v.value!==void 0&&v.value<=m;)v=v.next;if(v===void 0)h.pushBack(m),v=c;else if(v===d)h.pushFront(m),v=d;else{++i;var g=v.pre;g&&(g.next=new o(m),g.next.pre=g,g.next.next=v,v&&(v.pre=g.next))}})},this[Symbol.iterator]=function(){return function(){var f;return a(this,function(h){switch(h.label){case 0:f=d,h.label=1;case 1:if(f===void 0)return[3,3];if(!f.value)throw new Error("unknown error");return[4,f.value];case 2:return h.sent(),f=f.next,[3,1];case 3:return[2]}})}()},p.forEach(function(f){return s.pushBack(f)}),Object.freeze(this)}Object.freeze(u),l.default=u},{}],30:[function(t,n,l){var a=this&&this.__generator||function(s,i){var d,c,f,h,v={label:0,sent:function(){if(1&f[0])throw f[1];return f[1]},trys:[],ops:[]};return h={next:m(0),throw:m(1),return:m(2)},typeof Symbol=="function"&&(h[Symbol.iterator]=function(){return this}),h;function m(g){return function(x){return function(y){if(d)throw new TypeError("Generator is already executing.");for(;v;)try{if(d=1,c&&(f=2&y[0]?c.return:y[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,y[1])).done)return f;switch(c=0,f&&(y=[2&y[0],f.value]),y[0]){case 0:case 1:f=y;break;case 4:return v.label++,{value:y[1],done:!1};case 5:v.label++,c=y[1],y=[0];continue;case 7:y=v.ops.pop(),v.trys.pop();continue;default:if(!(f=(f=v.trys).length>0&&f[f.length-1])&&(y[0]===6||y[0]===2)){v=0;continue}if(y[0]===3&&(!f||y[1]>f[0]&&y[1]<f[3])){v.label=y[1];break}if(y[0]===6&&v.label<f[1]){v.label=f[1],f=y;break}if(f&&v.label<f[2]){v.label=f[2],v.ops.push(y);break}f[2]&&v.ops.pop(),v.trys.pop();continue}y=i.call(s,v)}catch(w){y=[6,w],c=0}finally{d=f=0}if(5&y[0])throw y[1];return{value:y[0]?y[1]:void 0,done:!0}}([g,x])}}},o=this&&this.__values||function(s){var i=typeof Symbol=="function"&&Symbol.iterator,d=i&&s[i],c=0;if(d)return d.call(s);if(s&&typeof s.length=="number")return{next:function(){return s&&c>=s.length&&(s=void 0),{value:s&&s[c++],done:!s}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../Base/TreeNode");function p(s,i){var d=this;s===void 0&&(s=[]),i=i||function(E,A){return E<A?-1:E>A?1:0};var c=0,f=new u.default;f.color=u.default.TreeNodeColorType.black,this.size=function(){return c},this.empty=function(){return c===0},this.clear=function(){c=0,f.key=f.value=void 0,f.leftChild=f.rightChild=f.brother=void 0};var h=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.leftChild?h(E.leftChild):E},v=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.rightChild?v(E.rightChild):E};this.front=function(){if(!this.empty()){var E=h(f);if(E.key===void 0||E.value===void 0)throw new Error("unknown error");return{key:E.key,value:E.value}}},this.back=function(){if(!this.empty()){var E=v(f);if(E.key===void 0||E.value===void 0)throw new Error("unknown error");return{key:E.key,value:E.value}}},this.forEach=function(E){var A,C,F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next())E(P.value,F++)}catch(J){A={error:J}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}},this.getElementByPos=function(E){var A,C;if(E<0||E>=this.size())throw new Error("pos must more than 0 and less than set's size");var F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next()){var J=P.value;if(F===E)return J;++F}}catch($){A={error:$}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}throw new Error("unknown Error")};var m=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0){var C=i(E.key,A);return C===0?{key:E.key,value:E.value}:C<0?m(E.rightChild,A):m(E.leftChild,A)||{key:E.key,value:E.value}}};this.lowerBound=function(E){return m(f,E)};var g=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0)return i(E.key,A)<=0?g(E.rightChild,A):g(E.leftChild,A)||{key:E.key,value:E.value}};this.upperBound=function(E){return g(f,E)};var x=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0){var C=i(E.key,A);return C===0?{key:E.key,value:E.value}:C>0?x(E.leftChild,A):x(E.rightChild,A)||{key:E.key,value:E.value}}};this.reverseLowerBound=function(E){return x(f,E)};var y=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0)return i(E.key,A)>=0?y(E.leftChild,A):y(E.rightChild,A)||{key:E.key,value:E.value}};this.reverseUpperBound=function(E){return y(f,E)};var w=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(E.color!==u.default.TreeNodeColorType.red){var C=E.brother;if(!C)throw new Error("unknown error");if(E===A.leftChild)if(C.color===u.default.TreeNodeColorType.red){C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red;var F=A.rotateLeft();f===A&&(f=F),w(E)}else C.color===u.default.TreeNodeColorType.black&&(C.rightChild&&C.rightChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=A.rotateLeft(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||!C.leftChild||C.leftChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,w(A)):(C.color=u.default.TreeNodeColorType.red,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=C.rotateRight(),f===C&&(f=F),w(E)));else E===A.rightChild&&(C.color===u.default.TreeNodeColorType.red?(C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red,F=A.rotateRight(),f===A&&(f=F),w(E)):C.color===u.default.TreeNodeColorType.black&&(C.leftChild&&C.leftChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=A.rotateRight(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||!C.rightChild||C.rightChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,w(A)):(C.color=u.default.TreeNodeColorType.red,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=C.rotateLeft(),f===C&&(f=F),w(E))))}else E.color=u.default.TreeNodeColorType.black},k=function(E){for(var A=E;A.leftChild||A.rightChild;){if(A.rightChild){A=h(A.rightChild);var C=E.key;E.key=A.key,A.key=C;var F=E.value;E.value=A.value,A.value=F,E=A}A.leftChild&&(A=v(A.leftChild),C=E.key,E.key=A.key,A.key=C,F=E.value,E.value=A.value,A.value=F,E=A)}w(A),A&&A.remove(),--c,f.color=u.default.TreeNodeColorType.black},T=function(E,A){return!(!E||E.key===void 0)&&(!!T(E.leftChild,A)||!!A(E)||T(E.rightChild,A))};this.eraseElementByPos=function(E){if(E<0||E>=c)throw new Error("pos must more than 0 and less than set's size");var A=0;T(f,function(C){return E===A?(k(C),!0):(++A,!1)})},this.eraseElementByKey=function(E){if(!this.empty()){var A=X(f,E);A!==void 0&&A.key!==void 0&&i(A.key,E)===0&&k(A)}};var I=function(E,A){if(!E||E.key===void 0)throw new Error("unknown error");var C=i(A,E.key);return C<0?E.leftChild?I(E.leftChild,A):(E.leftChild=new u.default,E.leftChild.parent=E,E.leftChild.brother=E.rightChild,E.rightChild&&(E.rightChild.brother=E.leftChild),E.leftChild):C>0?E.rightChild?I(E.rightChild,A):(E.rightChild=new u.default,E.rightChild.parent=E,E.rightChild.brother=E.leftChild,E.leftChild&&(E.leftChild.brother=E.rightChild),E.rightChild):E},D=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(A.color!==u.default.TreeNodeColorType.black&&A.color===u.default.TreeNodeColorType.red){var C=A.brother,F=A.parent;if(!F)throw new Error("unknown error");if(C&&C.color===u.default.TreeNodeColorType.red)C.color=A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,D(F);else if(!C||C.color===u.default.TreeNodeColorType.black)if(A===F.leftChild)if(E===A.leftChild){A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red;var j=F.rotateRight();F===f&&(f=j)}else E===A.rightChild&&(j=A.rotateLeft(),F===f&&(f=j),D(A));else A===F.rightChild&&(E===A.leftChild?(j=A.rotateRight(),F===f&&(f=j),D(A)):E===A.rightChild&&(A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,j=F.rotateLeft(),F===f&&(f=j)))}};this.setElement=function(E,A){if(E==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");if(A!=null){if(this.empty())return++c,f.key=E,f.value=A,void(f.color=u.default.TreeNodeColorType.black);var C=I(f,E);C.key===void 0||i(C.key,E)!==0?(++c,C.key=E,C.value=A,D(C),f.color=u.default.TreeNodeColorType.black):C.value=A}else this.eraseElementByKey(E)};var X=function(E,A){if(E&&E.key!==void 0){var C=i(A,E.key);return C<0?X(E.leftChild,A):C>0?X(E.rightChild,A):E}};this.find=function(E){return!!X(f,E)},this.getElementByKey=function(E){var A=X(f,E);if((A==null?void 0:A.key)===void 0||(A==null?void 0:A.value)===void 0)throw new Error("unknown error");return A.value},this.union=function(E){var A=this;E.forEach(function(C){var F=C.key,j=C.value;return A.setElement(F,j)})},this.getHeight=function(){if(this.empty())return 0;var E=function(A){return A?Math.max(E(A.leftChild),E(A.rightChild))+1:1};return E(f)};var V=function(E){return a(this,function(A){switch(A.label){case 0:return E&&E.key!==void 0&&E.value!==void 0?[5,o(V(E.leftChild))]:[2];case 1:return A.sent(),[4,{key:E.key,value:E.value}];case 2:return A.sent(),[5,o(V(E.rightChild))];case 3:return A.sent(),[2]}})};this[Symbol.iterator]=function(){return V(f)},s.forEach(function(E){var A=E.key,C=E.value;return d.setElement(A,C)}),Object.freeze(this)}Object.freeze(p),l.default=p},{"../Base/TreeNode":25}],31:[function(t,n,l){function a(o,u){o===void 0&&(o=[]),u=u||function(c,f){return c>f?-1:c<f?1:0};var p=[];o.forEach(function(c){return p.push(c)});var s=p.length,i=function(c,f){if(c<0||c>=s)throw new Error("unknown error");if(f<0||f>=s)throw new Error("unknown error");var h=p[c];p[c]=p[f],p[f]=h},d=function(c){if(c<0||c>=s)throw new Error("unknown error");var f=2*c+1,h=2*c+2;f<s&&u(p[c],p[f])>0&&i(c,f),h<s&&u(p[c],p[h])>0&&i(c,h)};(function(){for(var c=Math.floor((s-1)/2);c>=0;--c)for(var f=c,h=2*f+1;h<s;){var v=h+1,m=h;if(v<s&&u(p[h],p[v])>0&&(m=v),u(p[f],p[m])<=0)break;i(f,m),h=2*(f=m)+1}})(),this.size=function(){return s},this.empty=function(){return s===0},this.clear=function(){s=0,p.length=0},this.push=function(c){if(p.push(c),++s!==1)for(var f=s-1;f>0;){var h=Math.floor((f-1)/2);if(u(p[h],c)<=0)break;d(h),f=h}},this.pop=function(){if(!this.empty())if(this.size()!==1){var c=p[s-1];--s;for(var f=0;f<this.size();){var h=2*f+1,v=2*f+2;if(h>=this.size())break;var m=h;if(v<this.size()&&u(p[h],p[v])>0&&(m=v),u(p[m],c)>=0)break;p[f]=p[m],f=m}p[f]=c}else--s},this.top=function(){return p[0]},Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),Object.freeze(a),l.default=a},{}],32:[function(t,n,l){Object.defineProperty(l,"__esModule",{value:!0});var a=t("../LinkList/LinkList");function o(u){u===void 0&&(u=[]);var p=new a.default(u);this.size=function(){return p.size()},this.empty=function(){return p.empty()},this.clear=function(){p.clear()},this.push=function(s){p.pushBack(s)},this.pop=function(){p.popFront()},this.front=function(){return p.front()},Object.freeze(this)}Object.freeze(o),l.default=o},{"../LinkList/LinkList":29}],33:[function(t,n,l){var a=this&&this.__generator||function(s,i){var d,c,f,h,v={label:0,sent:function(){if(1&f[0])throw f[1];return f[1]},trys:[],ops:[]};return h={next:m(0),throw:m(1),return:m(2)},typeof Symbol=="function"&&(h[Symbol.iterator]=function(){return this}),h;function m(g){return function(x){return function(y){if(d)throw new TypeError("Generator is already executing.");for(;v;)try{if(d=1,c&&(f=2&y[0]?c.return:y[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,y[1])).done)return f;switch(c=0,f&&(y=[2&y[0],f.value]),y[0]){case 0:case 1:f=y;break;case 4:return v.label++,{value:y[1],done:!1};case 5:v.label++,c=y[1],y=[0];continue;case 7:y=v.ops.pop(),v.trys.pop();continue;default:if(!(f=(f=v.trys).length>0&&f[f.length-1])&&(y[0]===6||y[0]===2)){v=0;continue}if(y[0]===3&&(!f||y[1]>f[0]&&y[1]<f[3])){v.label=y[1];break}if(y[0]===6&&v.label<f[1]){v.label=f[1],f=y;break}if(f&&v.label<f[2]){v.label=f[2],v.ops.push(y);break}f[2]&&v.ops.pop(),v.trys.pop();continue}y=i.call(s,v)}catch(w){y=[6,w],c=0}finally{d=f=0}if(5&y[0])throw y[1];return{value:y[0]?y[1]:void 0,done:!0}}([g,x])}}},o=this&&this.__values||function(s){var i=typeof Symbol=="function"&&Symbol.iterator,d=i&&s[i],c=0;if(d)return d.call(s);if(s&&typeof s.length=="number")return{next:function(){return s&&c>=s.length&&(s=void 0),{value:s&&s[c++],done:!s}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../Base/TreeNode");function p(s,i){var d=this;s===void 0&&(s=[]),i=i||function(E,A){return E<A?-1:E>A?1:0};var c=0,f=new u.default;f.color=u.default.TreeNodeColorType.black,this.size=function(){return c},this.empty=function(){return c===0},this.clear=function(){c=0,f.key=void 0,f.leftChild=f.rightChild=f.brother=f.parent=void 0,f.color=u.default.TreeNodeColorType.black};var h=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.leftChild?h(E.leftChild):E},v=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.rightChild?v(E.rightChild):E};this.front=function(){if(!this.empty())return h(f).key},this.back=function(){if(!this.empty())return v(f).key},this.forEach=function(E){var A,C,F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next())E(P.value,F++)}catch(J){A={error:J}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}},this.getElementByPos=function(E){var A,C;if(E<0||E>=this.size())throw new Error("pos must more than 0 and less than set's size");var F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next()){var J=P.value;if(F===E)return J;++F}}catch($){A={error:$}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}throw new Error("unknown error")};var m=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(E.color!==u.default.TreeNodeColorType.red){var C=E.brother;if(!C)throw new Error("unknown error");if(E===A.leftChild)if(C.color===u.default.TreeNodeColorType.red){C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red;var F=A.rotateLeft();f===A&&(f=F),m(E)}else C.color===u.default.TreeNodeColorType.black&&(C.rightChild&&C.rightChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=A.rotateLeft(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||!C.leftChild||C.leftChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,m(A)):(C.color=u.default.TreeNodeColorType.red,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=C.rotateRight(),f===C&&(f=F),m(E)));else E===A.rightChild&&(C.color===u.default.TreeNodeColorType.red?(C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red,F=A.rotateRight(),f===A&&(f=F),m(E)):C.color===u.default.TreeNodeColorType.black&&(C.leftChild&&C.leftChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=A.rotateRight(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||!C.rightChild||C.rightChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,m(A)):(C.color=u.default.TreeNodeColorType.red,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=C.rotateLeft(),f===C&&(f=F),m(E))))}else E.color=u.default.TreeNodeColorType.black},g=function(E){for(var A=E;A.leftChild||A.rightChild;){if(A.rightChild){A=h(A.rightChild);var C=E.key;E.key=A.key,A.key=C,E=A}A.leftChild&&(A=v(A.leftChild),C=E.key,E.key=A.key,A.key=C,E=A)}m(A),A&&A.remove(),--c,f.color=u.default.TreeNodeColorType.black},x=function(E,A){return!(!E||E.key===void 0)&&(!!x(E.leftChild,A)||!!A(E)||x(E.rightChild,A))};this.eraseElementByPos=function(E){if(E<0||E>=c)throw new Error("pos must more than 0 and less than set's size");var A=0;x(f,function(C){return E===A?(g(C),!0):(++A,!1)})},this.eraseElementByValue=function(E){if(!this.empty()){var A=k(f,E);A!==void 0&&A.key!==void 0&&i(A.key,E)===0&&g(A)}};var y=function(E,A){if(!E||E.key===void 0)throw new Error("unknown error");var C=i(A,E.key);return C<0?E.leftChild?y(E.leftChild,A):(E.leftChild=new u.default,E.leftChild.parent=E,E.leftChild.brother=E.rightChild,E.rightChild&&(E.rightChild.brother=E.leftChild),E.leftChild):C>0?E.rightChild?y(E.rightChild,A):(E.rightChild=new u.default,E.rightChild.parent=E,E.rightChild.brother=E.leftChild,E.leftChild&&(E.leftChild.brother=E.rightChild),E.rightChild):E},w=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(A.color!==u.default.TreeNodeColorType.black&&A.color===u.default.TreeNodeColorType.red){var C=A.brother,F=A.parent;if(!F)throw new Error("unknown error");if(C&&C.color===u.default.TreeNodeColorType.red)C.color=A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,w(F);else if(!C||C.color===u.default.TreeNodeColorType.black)if(A===F.leftChild)if(E===A.leftChild){A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red;var j=F.rotateRight();F===f&&(f=j)}else E===A.rightChild&&(j=A.rotateLeft(),F===f&&(f=j),w(A));else A===F.rightChild&&(E===A.leftChild?(j=A.rotateRight(),F===f&&(f=j),w(A)):E===A.rightChild&&(A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,j=F.rotateLeft(),F===f&&(f=j)))}};this.insert=function(E){if(E==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");if(this.empty())return++c,f.key=E,void(f.color=u.default.TreeNodeColorType.black);var A=y(f,E);A.key!==void 0&&i(A.key,E)===0||(++c,A.key=E,w(A),f.color=u.default.TreeNodeColorType.black)};var k=function(E,A){if(E&&E.key!==void 0){var C=i(A,E.key);return C<0?k(E.leftChild,A):C>0?k(E.rightChild,A):E}};this.find=function(E){var A=k(f,E);return A!==void 0&&A.key!==void 0&&i(A.key,E)===0};var T=function(E,A){if(E&&E.key!==void 0){var C=i(E.key,A);if(C===0)return E.key;if(C<0)return T(E.rightChild,A);var F=T(E.leftChild,A);return F!==void 0?F:E.key}};this.lowerBound=function(E){return T(f,E)};var I=function(E,A){if(E&&E.key!==void 0){if(i(E.key,A)<=0)return I(E.rightChild,A);var C=I(E.leftChild,A);return C!==void 0?C:E.key}};this.upperBound=function(E){return I(f,E)};var D=function(E,A){if(E&&E.key!==void 0){var C=i(E.key,A);if(C===0)return E.key;if(C>0)return D(E.leftChild,A);var F=D(E.rightChild,A);return F!==void 0?F:E.key}};this.reverseLowerBound=function(E){return D(f,E)};var X=function(E,A){if(E&&E.key!==void 0){if(i(E.key,A)>=0)return X(E.leftChild,A);var C=X(E.rightChild,A);return C!==void 0?C:E.key}};this.reverseUpperBound=function(E){return X(f,E)},this.union=function(E){var A=this;E.forEach(function(C){return A.insert(C)})},this.getHeight=function(){if(this.empty())return 0;var E=function(A){return A?Math.max(E(A.leftChild),E(A.rightChild))+1:1};return E(f)};var V=function(E){return a(this,function(A){switch(A.label){case 0:return E&&E.key!==void 0?[5,o(V(E.leftChild))]:[2];case 1:return A.sent(),[4,E.key];case 2:return A.sent(),[5,o(V(E.rightChild))];case 3:return A.sent(),[2]}})};this[Symbol.iterator]=function(){return V(f)},s.forEach(function(E){return d.insert(E)}),Object.freeze(this)}Object.freeze(p),l.default=p},{"../Base/TreeNode":25}],34:[function(t,n,l){function a(o){var u=this;o===void 0&&(o=[]);var p=0,s=[];this.size=function(){return p},this.empty=function(){return p===0},this.clear=function(){p=0,s.length=0},this.push=function(i){s.push(i),++p},this.pop=function(){s.pop(),p>0&&--p},this.top=function(){return s[p-1]},o.forEach(function(i){return u.push(i)}),Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),Object.freeze(a),l.default=a},{}],35:[function(t,n,l){var a=this&&this.__generator||function(i,d){var c,f,h,v,m={label:0,sent:function(){if(1&h[0])throw h[1];return h[1]},trys:[],ops:[]};return v={next:g(0),throw:g(1),return:g(2)},typeof Symbol=="function"&&(v[Symbol.iterator]=function(){return this}),v;function g(x){return function(y){return function(w){if(c)throw new TypeError("Generator is already executing.");for(;m;)try{if(c=1,f&&(h=2&w[0]?f.return:w[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,w[1])).done)return h;switch(f=0,h&&(w=[2&w[0],h.value]),w[0]){case 0:case 1:h=w;break;case 4:return m.label++,{value:w[1],done:!1};case 5:m.label++,f=w[1],w=[0];continue;case 7:w=m.ops.pop(),m.trys.pop();continue;default:if(!(h=(h=m.trys).length>0&&h[h.length-1])&&(w[0]===6||w[0]===2)){m=0;continue}if(w[0]===3&&(!h||w[1]>h[0]&&w[1]<h[3])){m.label=w[1];break}if(w[0]===6&&m.label<h[1]){m.label=h[1],h=w;break}if(h&&m.label<h[2]){m.label=h[2],m.ops.push(w);break}h[2]&&m.ops.pop(),m.trys.pop();continue}w=d.call(i,m)}catch(k){w=[6,k],f=0}finally{c=h=0}if(5&w[0])throw w[1];return{value:w[0]?w[1]:void 0,done:!0}}([x,y])}}},o=this&&this.__read||function(i,d){var c=typeof Symbol=="function"&&i[Symbol.iterator];if(!c)return i;var f,h,v=c.call(i),m=[];try{for(;(d===void 0||d-- >0)&&!(f=v.next()).done;)m.push(f.value)}catch(g){h={error:g}}finally{try{f&&!f.done&&(c=v.return)&&c.call(v)}finally{if(h)throw h.error}}return m},u=this&&this.__spreadArray||function(i,d,c){if(c||arguments.length===2)for(var f,h=0,v=d.length;h<v;h++)!f&&h in d||(f||(f=Array.prototype.slice.call(d,0,h)),f[h]=d[h]);return i.concat(f||Array.prototype.slice.call(d))},p=this&&this.__values||function(i){var d=typeof Symbol=="function"&&Symbol.iterator,c=d&&i[d],f=0;if(c)return c.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(d?"Object is not iterable.":"Symbol.iterator is not defined.")};function s(i){var d=this;i===void 0&&(i=[]);var c=0,f=[];this.size=function(){return c},this.empty=function(){return c===0},this.clear=function(){c=0,f.length=0},this.front=function(){if(!this.empty())return f[0]},this.back=function(){if(!this.empty())return f[c-1]},this.forEach=function(h){f.forEach(h)},this.getElementByPos=function(h){if(h<0||h>=c)throw new Error("pos must more than 0 and less than vector's size");return f[h]},this.eraseElementByPos=function(h){if(h<0||h>=c)throw new Error("pos must more than 0 and less than vector's size");for(var v=h;v<c-1;++v)f[v]=f[v+1];this.popBack()},this.eraseElementByValue=function(h){var v=[];this.forEach(function(g){g!==h&&v.push(g)}),v.forEach(function(g,x){f[x]=g});for(var m=v.length;c>m;)this.popBack()},this.pushBack=function(h){f.push(h),++c},this.popBack=function(){f.pop(),c>0&&--c},this.setElementByPos=function(h,v){if(h<0||h>=c)throw new Error("pos must more than 0 and less than vector's size");f[h]=v},this.insert=function(h,v,m){if(m===void 0&&(m=1),h<0||h>c)throw new Error("pos must more than 0 and less than or equal to vector's size");f.splice.apply(f,u([h,0],o(new Array(m).fill(v)),!1)),c+=m},this.find=function(h){return f.includes(h)},this.reverse=function(){f.reverse()},this.unique=function(){var h,v=[];this.forEach(function(g,x){x!==0&&g===h||(v.push(g),h=g)}),v.forEach(function(g,x){f[x]=g});for(var m=v.length;c>m;)this.popBack()},this.sort=function(h){f.sort(h)},this[Symbol.iterator]=function(){return function(){return a(this,function(h){switch(h.label){case 0:return[5,p(f)];case 1:return[2,h.sent()]}})}()},i.forEach(function(h){return d.pushBack(h)}),Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),Object.freeze(s),l.default=s},{}],36:[function(t,n,l){Object.defineProperty(l,"__esModule",{value:!0}),l.HashMap=l.HashSet=l.Map=l.Set=l.PriorityQueue=l.Deque=l.LinkList=l.Queue=l.Stack=l.Vector=void 0;var a=t("./Vector/Vector");l.Vector=a.default;var o=t("./Stack/Stack");l.Stack=o.default;var u=t("./Queue/Queue");l.Queue=u.default;var p=t("./LinkList/LinkList");l.LinkList=p.default;var s=t("./Deque/Deque");l.Deque=s.default;var i=t("./PriorityQueue/PriorityQueue");l.PriorityQueue=i.default;var d=t("./Set/Set");l.Set=d.default;var c=t("./Map/Map");l.Map=c.default;var f=t("./HashSet/HashSet");l.HashSet=f.default;var h=t("./HashMap/HashMap");l.HashMap=h.default},{"./Deque/Deque":26,"./HashMap/HashMap":27,"./HashSet/HashSet":28,"./LinkList/LinkList":29,"./Map/Map":30,"./PriorityQueue/PriorityQueue":31,"./Queue/Queue":32,"./Set/Set":33,"./Stack/Stack":34,"./Vector/Vector":35}],37:[function(t,n,l){const a=t("yallist"),o=Symbol("max"),u=Symbol("length"),p=Symbol("lengthCalculator"),s=Symbol("allowStale"),i=Symbol("maxAge"),d=Symbol("dispose"),c=Symbol("noDisposeOnSet"),f=Symbol("lruList"),h=Symbol("cache"),v=Symbol("updateAgeOnGet"),m=()=>1,g=(I,D,X)=>{const V=I[h].get(D);if(V){const E=V.value;if(x(I,E)){if(w(I,V),!I[s])return}else X&&(I[v]&&(V.value.now=Date.now()),I[f].unshiftNode(V));return E.value}},x=(I,D)=>{if(!D||!D.maxAge&&!I[i])return!1;const X=Date.now()-D.now;return D.maxAge?X>D.maxAge:I[i]&&X>I[i]},y=I=>{if(I[u]>I[o])for(let D=I[f].tail;I[u]>I[o]&&D!==null;){const X=D.prev;w(I,D),D=X}},w=(I,D)=>{if(D){const X=D.value;I[d]&&I[d](X.key,X.value),I[u]-=X.length,I[h].delete(X.key),I[f].removeNode(D)}};class k{constructor(D,X,V,E,A){this.key=D,this.value=X,this.length=V,this.now=E,this.maxAge=A||0}}const T=(I,D,X,V)=>{let E=X.value;x(I,E)&&(w(I,X),I[s]||(E=void 0)),E&&D.call(V,E.value,E.key,I)};n.exports=class{constructor(I){if(typeof I=="number"&&(I={max:I}),I||(I={}),I.max&&(typeof I.max!="number"||I.max<0))throw new TypeError("max must be a non-negative number");this[o]=I.max||1/0;const D=I.length||m;if(this[p]=typeof D!="function"?m:D,this[s]=I.stale||!1,I.maxAge&&typeof I.maxAge!="number")throw new TypeError("maxAge must be a number");this[i]=I.maxAge||0,this[d]=I.dispose,this[c]=I.noDisposeOnSet||!1,this[v]=I.updateAgeOnGet||!1,this.reset()}set max(I){if(typeof I!="number"||I<0)throw new TypeError("max must be a non-negative number");this[o]=I||1/0,y(this)}get max(){return this[o]}set allowStale(I){this[s]=!!I}get allowStale(){return this[s]}set maxAge(I){if(typeof I!="number")throw new TypeError("maxAge must be a non-negative number");this[i]=I,y(this)}get maxAge(){return this[i]}set lengthCalculator(I){typeof I!="function"&&(I=m),I!==this[p]&&(this[p]=I,this[u]=0,this[f].forEach(D=>{D.length=this[p](D.value,D.key),this[u]+=D.length})),y(this)}get lengthCalculator(){return this[p]}get length(){return this[u]}get itemCount(){return this[f].length}rforEach(I,D){D=D||this;for(let X=this[f].tail;X!==null;){const V=X.prev;T(this,I,X,D),X=V}}forEach(I,D){D=D||this;for(let X=this[f].head;X!==null;){const V=X.next;T(this,I,X,D),X=V}}keys(){return this[f].toArray().map(I=>I.key)}values(){return this[f].toArray().map(I=>I.value)}reset(){this[d]&&this[f]&&this[f].length&&this[f].forEach(I=>this[d](I.key,I.value)),this[h]=new Map,this[f]=new a,this[u]=0}dump(){return this[f].map(I=>!x(this,I)&&{k:I.key,v:I.value,e:I.now+(I.maxAge||0)}).toArray().filter(I=>I)}dumpLru(){return this[f]}set(I,D,X){if((X=X||this[i])&&typeof X!="number")throw new TypeError("maxAge must be a number");const V=X?Date.now():0,E=this[p](D,I);if(this[h].has(I)){if(E>this[o])return w(this,this[h].get(I)),!1;const C=this[h].get(I).value;return this[d]&&(this[c]||this[d](I,C.value)),C.now=V,C.maxAge=X,C.value=D,this[u]+=E-C.length,C.length=E,this.get(I),y(this),!0}const A=new k(I,D,E,V,X);return A.length>this[o]?(this[d]&&this[d](I,D),!1):(this[u]+=A.length,this[f].unshift(A),this[h].set(I,this[f].head),y(this),!0)}has(I){if(!this[h].has(I))return!1;const D=this[h].get(I).value;return!x(this,D)}get(I){return g(this,I,!0)}peek(I){return g(this,I,!1)}pop(){const I=this[f].tail;return I?(w(this,I),I.value):null}del(I){w(this,this[h].get(I))}load(I){this.reset();const D=Date.now();for(let X=I.length-1;X>=0;X--){const V=I[X],E=V.e||0;if(E===0)this.set(V.k,V.v);else{const A=E-D;A>0&&this.set(V.k,V.v,A)}}}prune(){this[h].forEach((I,D)=>g(this,D,!1))}}},{yallist:83}],38:[function(t,n,l){(function(a){(function(){const o=n.exports;o.types={0:"reserved",1:"connect",2:"connack",3:"publish",4:"puback",5:"pubrec",6:"pubrel",7:"pubcomp",8:"subscribe",9:"suback",10:"unsubscribe",11:"unsuback",12:"pingreq",13:"pingresp",14:"disconnect",15:"auth"},o.codes={};for(const p in o.types){const s=o.types[p];o.codes[s]=p}o.CMD_SHIFT=4,o.CMD_MASK=240,o.DUP_MASK=8,o.QOS_MASK=3,o.QOS_SHIFT=1,o.RETAIN_MASK=1,o.VARBYTEINT_MASK=127,o.VARBYTEINT_FIN_MASK=128,o.VARBYTEINT_MAX=268435455,o.SESSIONPRESENT_MASK=1,o.SESSIONPRESENT_HEADER=a.from([o.SESSIONPRESENT_MASK]),o.CONNACK_HEADER=a.from([o.codes.connack<<o.CMD_SHIFT]),o.USERNAME_MASK=128,o.PASSWORD_MASK=64,o.WILL_RETAIN_MASK=32,o.WILL_QOS_MASK=24,o.WILL_QOS_SHIFT=3,o.WILL_FLAG_MASK=4,o.CLEAN_SESSION_MASK=2,o.CONNECT_HEADER=a.from([o.codes.connect<<o.CMD_SHIFT]),o.properties={sessionExpiryInterval:17,willDelayInterval:24,receiveMaximum:33,maximumPacketSize:39,topicAliasMaximum:34,requestResponseInformation:25,requestProblemInformation:23,userProperties:38,authenticationMethod:21,authenticationData:22,payloadFormatIndicator:1,messageExpiryInterval:2,contentType:3,responseTopic:8,correlationData:9,maximumQoS:36,retainAvailable:37,assignedClientIdentifier:18,reasonString:31,wildcardSubscriptionAvailable:40,subscriptionIdentifiersAvailable:41,sharedSubscriptionAvailable:42,serverKeepAlive:19,responseInformation:26,serverReference:28,topicAlias:35,subscriptionIdentifier:11},o.propertiesCodes={};for(const p in o.properties){const s=o.properties[p];o.propertiesCodes[s]=p}function u(p){return[0,1,2].map(s=>[0,1].map(i=>[0,1].map(d=>{const c=a.alloc(1);return c.writeUInt8(o.codes[p]<<o.CMD_SHIFT|(i?o.DUP_MASK:0)|s<<o.QOS_SHIFT|d,0,!0),c})))}o.propertiesTypes={sessionExpiryInterval:"int32",willDelayInterval:"int32",receiveMaximum:"int16",maximumPacketSize:"int32",topicAliasMaximum:"int16",requestResponseInformation:"byte",requestProblemInformation:"byte",userProperties:"pair",authenticationMethod:"string",authenticationData:"binary",payloadFormatIndicator:"byte",messageExpiryInterval:"int32",contentType:"string",responseTopic:"string",correlationData:"binary",maximumQoS:"int8",retainAvailable:"byte",assignedClientIdentifier:"string",reasonString:"string",wildcardSubscriptionAvailable:"byte",subscriptionIdentifiersAvailable:"byte",sharedSubscriptionAvailable:"byte",serverKeepAlive:"int16",responseInformation:"string",serverReference:"string",topicAlias:"int16",subscriptionIdentifier:"var"},o.PUBLISH_HEADER=u("publish"),o.SUBSCRIBE_HEADER=u("subscribe"),o.SUBSCRIBE_OPTIONS_QOS_MASK=3,o.SUBSCRIBE_OPTIONS_NL_MASK=1,o.SUBSCRIBE_OPTIONS_NL_SHIFT=2,o.SUBSCRIBE_OPTIONS_RAP_MASK=1,o.SUBSCRIBE_OPTIONS_RAP_SHIFT=3,o.SUBSCRIBE_OPTIONS_RH_MASK=3,o.SUBSCRIBE_OPTIONS_RH_SHIFT=4,o.SUBSCRIBE_OPTIONS_RH=[0,16,32],o.SUBSCRIBE_OPTIONS_NL=4,o.SUBSCRIBE_OPTIONS_RAP=8,o.SUBSCRIBE_OPTIONS_QOS=[0,1,2],o.UNSUBSCRIBE_HEADER=u("unsubscribe"),o.ACKS={unsuback:u("unsuback"),puback:u("puback"),pubcomp:u("pubcomp"),pubrel:u("pubrel"),pubrec:u("pubrec")},o.SUBACK_HEADER=a.from([o.codes.suback<<o.CMD_SHIFT]),o.VERSION3=a.from([3]),o.VERSION4=a.from([4]),o.VERSION5=a.from([5]),o.VERSION131=a.from([131]),o.VERSION132=a.from([132]),o.QOS=[0,1,2].map(p=>a.from([p])),o.EMPTY={pingreq:a.from([o.codes.pingreq<<4,0]),pingresp:a.from([o.codes.pingresp<<4,0]),disconnect:a.from([o.codes.disconnect<<4,0])}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:17}],39:[function(t,n,l){(function(a){(function(){const o=t("./writeToStream"),u=t("events");class p extends u{constructor(){super(),this._array=new Array(20),this._i=0}write(i){return this._array[this._i++]=i,!0}concat(){let i=0;const d=new Array(this._array.length),c=this._array;let f,h=0;for(f=0;f<c.length&&c[f]!==void 0;f++)typeof c[f]!="string"?d[f]=c[f].length:d[f]=a.byteLength(c[f]),i+=d[f];const v=a.allocUnsafe(i);for(f=0;f<c.length&&c[f]!==void 0;f++)typeof c[f]!="string"?(c[f].copy(v,h),h+=d[f]):(v.write(c[f],h),h+=d[f]);return v}}n.exports=function(s,i){const d=new p;return o(s,d,i),d.concat()}}).call(this)}).call(this,t("buffer").Buffer)},{"./writeToStream":44,buffer:17,events:22}],40:[function(t,n,l){l.parser=t("./parser").parser,l.generate=t("./generate"),l.writeToStream=t("./writeToStream")},{"./generate":39,"./parser":43,"./writeToStream":44}],41:[function(t,n,l){(function(a){(function(){const u={},p=a.isBuffer(a.from([1,2]).subarray(0,1));function s(i){const d=a.allocUnsafe(2);return d.writeUInt8(i>>8,0),d.writeUInt8(255&i,1),d}n.exports={cache:u,generateCache:function(){for(let i=0;i<65536;i++)u[i]=s(i)},generateNumber:s,genBufVariableByteInt:function(i){let d=0,c=0;const f=a.allocUnsafe(4);do d=i%128|0,(i=i/128|0)>0&&(d|=128),f.writeUInt8(d,c++);while(i>0&&c<4);return i>0&&(c=0),p?f.subarray(0,c):f.slice(0,c)},generate4ByteBuffer:function(i){const d=a.allocUnsafe(4);return d.writeUInt32BE(i,0),d}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:17}],42:[function(t,n,l){n.exports=class{constructor(){this.cmd=null,this.retain=!1,this.qos=0,this.dup=!1,this.length=-1,this.topic=null,this.payload=null}}},{}],43:[function(t,n,l){const a=t("bl"),o=t("events"),u=t("./packet"),p=t("./constants"),s=t("debug")("mqtt-packet:parser");class i extends o{constructor(){super(),this.parser=this.constructor.parser}static parser(c){return this instanceof i?(this.settings=c||{},this._states=["_parseHeader","_parseLength","_parsePayload","_newPacket"],this._resetState(),this):new i().parser(c)}_resetState(){s("_resetState: resetting packet, error, _list, and _stateCounter"),this.packet=new u,this.error=null,this._list=a(),this._stateCounter=0}parse(c){for(this.error&&this._resetState(),this._list.append(c),s("parse: current state: %s",this._states[this._stateCounter]);(this.packet.length!==-1||this._list.length>0)&&this[this._states[this._stateCounter]]()&&!this.error;)this._stateCounter++,s("parse: state complete. _stateCounter is now: %d",this._stateCounter),s("parse: packet.length: %d, buffer list length: %d",this.packet.length,this._list.length),this._stateCounter>=this._states.length&&(this._stateCounter=0);return s("parse: exited while loop. packet: %d, buffer list length: %d",this.packet.length,this._list.length),this._list.length}_parseHeader(){const c=this._list.readUInt8(0);return this.packet.cmd=p.types[c>>p.CMD_SHIFT],this.packet.retain=(c&p.RETAIN_MASK)!=0,this.packet.qos=c>>p.QOS_SHIFT&p.QOS_MASK,this.packet.dup=(c&p.DUP_MASK)!=0,s("_parseHeader: packet: %o",this.packet),this._list.consume(1),!0}_parseLength(){const c=this._parseVarByteNum(!0);return c&&(this.packet.length=c.value,this._list.consume(c.bytes)),s("_parseLength %d",c.value),!!c}_parsePayload(){s("_parsePayload: payload %O",this._list);let c=!1;if(this.packet.length===0||this._list.length>=this.packet.length){switch(this._pos=0,this.packet.cmd){case"connect":this._parseConnect();break;case"connack":this._parseConnack();break;case"publish":this._parsePublish();break;case"puback":case"pubrec":case"pubrel":case"pubcomp":this._parseConfirmation();break;case"subscribe":this._parseSubscribe();break;case"suback":this._parseSuback();break;case"unsubscribe":this._parseUnsubscribe();break;case"unsuback":this._parseUnsuback();break;case"pingreq":case"pingresp":break;case"disconnect":this._parseDisconnect();break;case"auth":this._parseAuth();break;default:this._emitError(new Error("Not supported"))}c=!0}return s("_parsePayload complete result: %s",c),c}_parseConnect(){let c,f,h,v;s("_parseConnect");const m={},g=this.packet,x=this._parseString();if(x===null)return this._emitError(new Error("Cannot parse protocolId"));if(x!=="MQTT"&&x!=="MQIsdp")return this._emitError(new Error("Invalid protocolId"));if(g.protocolId=x,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(g.protocolVersion=this._list.readUInt8(this._pos),g.protocolVersion>=128&&(g.bridgeMode=!0,g.protocolVersion=g.protocolVersion-128),g.protocolVersion!==3&&g.protocolVersion!==4&&g.protocolVersion!==5)return this._emitError(new Error("Invalid protocol version"));if(this._pos++,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(m.username=this._list.readUInt8(this._pos)&p.USERNAME_MASK,m.password=this._list.readUInt8(this._pos)&p.PASSWORD_MASK,m.will=this._list.readUInt8(this._pos)&p.WILL_FLAG_MASK,m.will&&(g.will={},g.will.retain=(this._list.readUInt8(this._pos)&p.WILL_RETAIN_MASK)!=0,g.will.qos=(this._list.readUInt8(this._pos)&p.WILL_QOS_MASK)>>p.WILL_QOS_SHIFT),g.clean=(this._list.readUInt8(this._pos)&p.CLEAN_SESSION_MASK)!=0,this._pos++,g.keepalive=this._parseNum(),g.keepalive===-1)return this._emitError(new Error("Packet too short"));if(g.protocolVersion===5){const w=this._parseProperties();Object.getOwnPropertyNames(w).length&&(g.properties=w)}const y=this._parseString();if(y===null)return this._emitError(new Error("Packet too short"));if(g.clientId=y,s("_parseConnect: packet.clientId: %s",g.clientId),m.will){if(g.protocolVersion===5){const w=this._parseProperties();Object.getOwnPropertyNames(w).length&&(g.will.properties=w)}if((c=this._parseString())===null)return this._emitError(new Error("Cannot parse will topic"));if(g.will.topic=c,s("_parseConnect: packet.will.topic: %s",g.will.topic),(f=this._parseBuffer())===null)return this._emitError(new Error("Cannot parse will payload"));g.will.payload=f,s("_parseConnect: packet.will.paylaod: %s",g.will.payload)}if(m.username){if((v=this._parseString())===null)return this._emitError(new Error("Cannot parse username"));g.username=v,s("_parseConnect: packet.username: %s",g.username)}if(m.password){if((h=this._parseBuffer())===null)return this._emitError(new Error("Cannot parse password"));g.password=h}return this.settings=g,s("_parseConnect: complete"),g}_parseConnack(){s("_parseConnack");const c=this.packet;if(this._list.length<1)return null;if(c.sessionPresent=!!(this._list.readUInt8(this._pos++)&p.SESSIONPRESENT_MASK),this.settings.protocolVersion===5)this._list.length>=2?c.reasonCode=this._list.readUInt8(this._pos++):c.reasonCode=0;else{if(this._list.length<2)return null;c.returnCode=this._list.readUInt8(this._pos++)}if(c.returnCode===-1||c.reasonCode===-1)return this._emitError(new Error("Cannot parse return code"));if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}s("_parseConnack: complete")}_parsePublish(){s("_parsePublish");const c=this.packet;if(c.topic=this._parseString(),c.topic===null)return this._emitError(new Error("Cannot parse topic"));if(!(c.qos>0)||this._parseMessageId()){if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}c.payload=this._list.slice(this._pos,c.length),s("_parsePublish: payload from buffer list: %o",c.payload)}}_parseSubscribe(){s("_parseSubscribe");const c=this.packet;let f,h,v,m,g,x,y;if(c.qos!==1)return this._emitError(new Error("Wrong subscribe header"));if(c.subscriptions=[],this._parseMessageId()){if(this.settings.protocolVersion===5){const w=this._parseProperties();Object.getOwnPropertyNames(w).length&&(c.properties=w)}for(;this._pos<c.length;){if((f=this._parseString())===null)return this._emitError(new Error("Cannot parse topic"));if(this._pos>=c.length)return this._emitError(new Error("Malformed Subscribe Payload"));v=(h=this._parseByte())&p.SUBSCRIBE_OPTIONS_QOS_MASK,x=(h>>p.SUBSCRIBE_OPTIONS_NL_SHIFT&p.SUBSCRIBE_OPTIONS_NL_MASK)!=0,g=(h>>p.SUBSCRIBE_OPTIONS_RAP_SHIFT&p.SUBSCRIBE_OPTIONS_RAP_MASK)!=0,m=h>>p.SUBSCRIBE_OPTIONS_RH_SHIFT&p.SUBSCRIBE_OPTIONS_RH_MASK,y={topic:f,qos:v},this.settings.protocolVersion===5?(y.nl=x,y.rap=g,y.rh=m):this.settings.bridgeMode&&(y.rh=0,y.rap=!0,y.nl=!0),s("_parseSubscribe: push subscription `%s` to subscription",y),c.subscriptions.push(y)}}}_parseSuback(){s("_parseSuback");const c=this.packet;if(this.packet.granted=[],this._parseMessageId()){if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}for(;this._pos<this.packet.length;)this.packet.granted.push(this._list.readUInt8(this._pos++))}}_parseUnsubscribe(){s("_parseUnsubscribe");const c=this.packet;if(c.unsubscriptions=[],this._parseMessageId()){if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}for(;this._pos<c.length;){const f=this._parseString();if(f===null)return this._emitError(new Error("Cannot parse topic"));s("_parseUnsubscribe: push topic `%s` to unsubscriptions",f),c.unsubscriptions.push(f)}}}_parseUnsuback(){s("_parseUnsuback");const c=this.packet;if(!this._parseMessageId())return this._emitError(new Error("Cannot parse messageId"));if(this.settings.protocolVersion===5){const f=this._parseProperties();for(Object.getOwnPropertyNames(f).length&&(c.properties=f),c.granted=[];this._pos<this.packet.length;)this.packet.granted.push(this._list.readUInt8(this._pos++))}}_parseConfirmation(){s("_parseConfirmation: packet.cmd: `%s`",this.packet.cmd);const c=this.packet;if(this._parseMessageId(),this.settings.protocolVersion===5&&(c.length>2?(c.reasonCode=this._parseByte(),s("_parseConfirmation: packet.reasonCode `%d`",c.reasonCode)):c.reasonCode=0,c.length>3)){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}return!0}_parseDisconnect(){const c=this.packet;if(s("_parseDisconnect"),this.settings.protocolVersion===5){this._list.length>0?c.reasonCode=this._parseByte():c.reasonCode=0;const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}return s("_parseDisconnect result: true"),!0}_parseAuth(){s("_parseAuth");const c=this.packet;if(this.settings.protocolVersion!==5)return this._emitError(new Error("Not supported auth packet for this version MQTT"));c.reasonCode=this._parseByte();const f=this._parseProperties();return Object.getOwnPropertyNames(f).length&&(c.properties=f),s("_parseAuth: result: true"),!0}_parseMessageId(){const c=this.packet;return c.messageId=this._parseNum(),c.messageId===null?(this._emitError(new Error("Cannot parse messageId")),!1):(s("_parseMessageId: packet.messageId %d",c.messageId),!0)}_parseString(c){const f=this._parseNum(),h=f+this._pos;if(f===-1||h>this._list.length||h>this.packet.length)return null;const v=this._list.toString("utf8",this._pos,h);return this._pos+=f,s("_parseString: result: %s",v),v}_parseStringPair(){return s("_parseStringPair"),{name:this._parseString(),value:this._parseString()}}_parseBuffer(){const c=this._parseNum(),f=c+this._pos;if(c===-1||f>this._list.length||f>this.packet.length)return null;const h=this._list.slice(this._pos,f);return this._pos+=c,s("_parseBuffer: result: %o",h),h}_parseNum(){if(this._list.length-this._pos<2)return-1;const c=this._list.readUInt16BE(this._pos);return this._pos+=2,s("_parseNum: result: %s",c),c}_parse4ByteNum(){if(this._list.length-this._pos<4)return-1;const c=this._list.readUInt32BE(this._pos);return this._pos+=4,s("_parse4ByteNum: result: %s",c),c}_parseVarByteNum(c){s("_parseVarByteNum");let f,h=0,v=1,m=0,g=!1;const x=this._pos?this._pos:0;for(;h<4&&x+h<this._list.length;){if(m+=v*((f=this._list.readUInt8(x+h++))&p.VARBYTEINT_MASK),v*=128,(f&p.VARBYTEINT_FIN_MASK)==0){g=!0;break}if(this._list.length<=h)break}return!g&&h===4&&this._list.length>=h&&this._emitError(new Error("Invalid variable byte integer")),x&&(this._pos+=h),s("_parseVarByteNum: result: %o",g=!!g&&(c?{bytes:h,value:m}:m)),g}_parseByte(){let c;return this._pos<this._list.length&&(c=this._list.readUInt8(this._pos),this._pos++),s("_parseByte: result: %o",c),c}_parseByType(c){switch(s("_parseByType: type: %s",c),c){case"byte":return this._parseByte()!==0;case"int8":return this._parseByte();case"int16":return this._parseNum();case"int32":return this._parse4ByteNum();case"var":return this._parseVarByteNum();case"string":return this._parseString();case"pair":return this._parseStringPair();case"binary":return this._parseBuffer()}}_parseProperties(){s("_parseProperties");const c=this._parseVarByteNum(),f=this._pos+c,h={};for(;this._pos<f;){const v=this._parseByte();if(!v)return this._emitError(new Error("Cannot parse property code type")),!1;const m=p.propertiesCodes[v];if(!m)return this._emitError(new Error("Unknown property")),!1;if(m!=="userProperties")h[m]?Array.isArray(h[m])?h[m].push(this._parseByType(p.propertiesTypes[m])):(h[m]=[h[m]],h[m].push(this._parseByType(p.propertiesTypes[m]))):h[m]=this._parseByType(p.propertiesTypes[m]);else{h[m]||(h[m]=Object.create(null));const g=this._parseByType(p.propertiesTypes[m]);if(h[m][g.name])if(Array.isArray(h[m][g.name]))h[m][g.name].push(g.value);else{const x=h[m][g.name];h[m][g.name]=[x],h[m][g.name].push(g.value)}else h[m][g.name]=g.value}}return h}_newPacket(){return s("_newPacket"),this.packet&&(this._list.consume(this.packet.length),s("_newPacket: parser emit packet: packet.cmd: %s, packet.payload: %s, packet.length: %d",this.packet.cmd,this.packet.payload,this.packet.length),this.emit("packet",this.packet)),s("_newPacket: new packet"),this.packet=new u,this._pos=0,!0}_emitError(c){s("_emitError"),this.error=c,this.emit("error",c)}}n.exports=i},{"./constants":38,"./packet":42,bl:15,debug:18,events:22}],44:[function(t,n,l){(function(a){(function(){const o=t("./constants"),u=a.allocUnsafe(0),p=a.from([0]),s=t("./numbers"),i=t("process-nextick-args").nextTick,d=t("debug")("mqtt-packet:writeToStream"),c=s.cache,f=s.generateNumber,h=s.generateCache,v=s.genBufVariableByteInt,m=s.generate4ByteBuffer;let g=X,x=!0;function y($,U,K){switch(d("generate called"),U.cork&&(U.cork(),i(w,U)),x&&(x=!1,h()),d("generate: packet.cmd: %s",$.cmd),$.cmd){case"connect":return function(L,O,H){const W=L||{},Z=W.protocolId||"MQTT";let re=W.protocolVersion||4;const oe=W.will;let ae=W.clean;const b=W.keepalive||0,_=W.clientId||"",R=W.username,G=W.password,ee=W.properties;ae===void 0&&(ae=!0);let te=0;if(typeof Z!="string"&&!a.isBuffer(Z))return O.emit("error",new Error("Invalid protocolId")),!1;if(te+=Z.length+2,re!==3&&re!==4&&re!==5)return O.emit("error",new Error("Invalid protocol version")),!1;if(te+=1,(typeof _=="string"||a.isBuffer(_))&&(_||re>=4)&&(_||ae))te+=a.byteLength(_)+2;else{if(re<4)return O.emit("error",new Error("clientId must be supplied before 3.1.1")),!1;if(1*ae==0)return O.emit("error",new Error("clientId must be given if cleanSession set to 0")),!1}if(typeof b!="number"||b<0||b>65535||b%1!=0)return O.emit("error",new Error("Invalid keepalive")),!1;if(te+=2,te+=1,re===5){var se=A(O,ee);if(!se)return!1;te+=se.length}if(oe){if(typeof oe!="object")return O.emit("error",new Error("Invalid will")),!1;if(!oe.topic||typeof oe.topic!="string")return O.emit("error",new Error("Invalid will topic")),!1;if(te+=a.byteLength(oe.topic)+2,te+=2,oe.payload){if(!(oe.payload.length>=0))return O.emit("error",new Error("Invalid will payload")),!1;typeof oe.payload=="string"?te+=a.byteLength(oe.payload):te+=oe.payload.length}var z={};if(re===5){if(!(z=A(O,oe.properties)))return!1;te+=z.length}}let S=!1;if(R!=null){if(!J(R))return O.emit("error",new Error("Invalid username")),!1;S=!0,te+=a.byteLength(R)+2}if(G!=null){if(!S)return O.emit("error",new Error("Username is required to use password")),!1;if(!J(G))return O.emit("error",new Error("Invalid password")),!1;te+=P(G)+2}O.write(o.CONNECT_HEADER),T(O,te),E(O,Z),W.bridgeMode&&(re+=128),O.write(re===131?o.VERSION131:re===132?o.VERSION132:re===4?o.VERSION4:re===5?o.VERSION5:o.VERSION3);let B=0;return B|=R!=null?o.USERNAME_MASK:0,B|=G!=null?o.PASSWORD_MASK:0,B|=oe&&oe.retain?o.WILL_RETAIN_MASK:0,B|=oe&&oe.qos?oe.qos<<o.WILL_QOS_SHIFT:0,B|=oe?o.WILL_FLAG_MASK:0,B|=ae?o.CLEAN_SESSION_MASK:0,O.write(a.from([B])),g(O,b),re===5&&se.write(),E(O,_),oe&&(re===5&&z.write(),I(O,oe.topic),E(O,oe.payload)),R!=null&&E(O,R),G!=null&&E(O,G),!0}($,U);case"connack":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=W===5?Z.reasonCode:Z.returnCode,oe=Z.properties;let ae=2;if(typeof re!="number")return O.emit("error",new Error("Invalid return code")),!1;let b=null;if(W===5){if(!(b=A(O,oe)))return!1;ae+=b.length}return O.write(o.CONNACK_HEADER),T(O,ae),O.write(Z.sessionPresent?o.SESSIONPRESENT_HEADER:p),O.write(a.from([re])),b!=null&&b.write(),!0}($,U,K);case"publish":return function(L,O,H){d("publish: packet: %o",L);const W=H?H.protocolVersion:4,Z=L||{},re=Z.qos||0,oe=Z.retain?o.RETAIN_MASK:0,ae=Z.topic,b=Z.payload||u,_=Z.messageId,R=Z.properties;let G=0;if(typeof ae=="string")G+=a.byteLength(ae)+2;else{if(!a.isBuffer(ae))return O.emit("error",new Error("Invalid topic")),!1;G+=ae.length+2}if(a.isBuffer(b)?G+=b.length:G+=a.byteLength(b),re&&typeof _!="number")return O.emit("error",new Error("Invalid messageId")),!1;re&&(G+=2);let ee=null;if(W===5){if(!(ee=A(O,R)))return!1;G+=ee.length}return O.write(o.PUBLISH_HEADER[re][Z.dup?1:0][oe?1:0]),T(O,G),g(O,P(ae)),O.write(ae),re>0&&g(O,_),ee!=null&&ee.write(),d("publish: payload: %o",b),O.write(b)}($,U,K);case"puback":case"pubrec":case"pubrel":case"pubcomp":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.cmd||"puback",oe=Z.messageId,ae=Z.dup&&re==="pubrel"?o.DUP_MASK:0;let b=0;const _=Z.reasonCode,R=Z.properties;let G=W===5?3:2;if(re==="pubrel"&&(b=1),typeof oe!="number")return O.emit("error",new Error("Invalid messageId")),!1;let ee=null;if(W===5&&typeof R=="object"){if(!(ee=C(O,R,H,G)))return!1;G+=ee.length}return O.write(o.ACKS[re][b][ae][0]),T(O,G),g(O,oe),W===5&&O.write(a.from([_])),ee!==null&&ee.write(),!0}($,U,K);case"subscribe":return function(L,O,H){d("subscribe: packet: ");const W=H?H.protocolVersion:4,Z=L||{},re=Z.dup?o.DUP_MASK:0,oe=Z.messageId,ae=Z.subscriptions,b=Z.properties;let _=0;if(typeof oe!="number")return O.emit("error",new Error("Invalid messageId")),!1;_+=2;let R=null;if(W===5){if(!(R=A(O,b)))return!1;_+=R.length}if(typeof ae!="object"||!ae.length)return O.emit("error",new Error("Invalid subscriptions")),!1;for(let ee=0;ee<ae.length;ee+=1){const te=ae[ee].topic,se=ae[ee].qos;if(typeof te!="string")return O.emit("error",new Error("Invalid subscriptions - invalid topic")),!1;if(typeof se!="number")return O.emit("error",new Error("Invalid subscriptions - invalid qos")),!1;if(W===5){if(typeof(ae[ee].nl||!1)!="boolean")return O.emit("error",new Error("Invalid subscriptions - invalid No Local")),!1;if(typeof(ae[ee].rap||!1)!="boolean")return O.emit("error",new Error("Invalid subscriptions - invalid Retain as Published")),!1;const B=ae[ee].rh||0;if(typeof B!="number"||B>2)return O.emit("error",new Error("Invalid subscriptions - invalid Retain Handling")),!1}_+=a.byteLength(te)+2+1}d("subscribe: writing to stream: %o",o.SUBSCRIBE_HEADER),O.write(o.SUBSCRIBE_HEADER[1][re?1:0][0]),T(O,_),g(O,oe),R!==null&&R.write();let G=!0;for(const ee of ae){const te=ee.topic,se=ee.qos,z=+ee.nl,S=+ee.rap,B=ee.rh;let Y;I(O,te),Y=o.SUBSCRIBE_OPTIONS_QOS[se],W===5&&(Y|=z?o.SUBSCRIBE_OPTIONS_NL:0,Y|=S?o.SUBSCRIBE_OPTIONS_RAP:0,Y|=B?o.SUBSCRIBE_OPTIONS_RH[B]:0),G=O.write(a.from([Y]))}return G}($,U,K);case"suback":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.messageId,oe=Z.granted,ae=Z.properties;let b=0;if(typeof re!="number")return O.emit("error",new Error("Invalid messageId")),!1;if(b+=2,typeof oe!="object"||!oe.length)return O.emit("error",new Error("Invalid qos vector")),!1;for(let R=0;R<oe.length;R+=1){if(typeof oe[R]!="number")return O.emit("error",new Error("Invalid qos vector")),!1;b+=1}let _=null;if(W===5){if(!(_=C(O,ae,H,b)))return!1;b+=_.length}return O.write(o.SUBACK_HEADER),T(O,b),g(O,re),_!==null&&_.write(),O.write(a.from(oe))}($,U,K);case"unsubscribe":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.messageId,oe=Z.dup?o.DUP_MASK:0,ae=Z.unsubscriptions,b=Z.properties;let _=0;if(typeof re!="number")return O.emit("error",new Error("Invalid messageId")),!1;if(_+=2,typeof ae!="object"||!ae.length)return O.emit("error",new Error("Invalid unsubscriptions")),!1;for(let ee=0;ee<ae.length;ee+=1){if(typeof ae[ee]!="string")return O.emit("error",new Error("Invalid unsubscriptions")),!1;_+=a.byteLength(ae[ee])+2}let R=null;if(W===5){if(!(R=A(O,b)))return!1;_+=R.length}O.write(o.UNSUBSCRIBE_HEADER[1][oe?1:0][0]),T(O,_),g(O,re),R!==null&&R.write();let G=!0;for(let ee=0;ee<ae.length;ee++)G=I(O,ae[ee]);return G}($,U,K);case"unsuback":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.messageId,oe=Z.dup?o.DUP_MASK:0,ae=Z.granted,b=Z.properties,_=Z.cmd;let R=2;if(typeof re!="number")return O.emit("error",new Error("Invalid messageId")),!1;if(W===5){if(typeof ae!="object"||!ae.length)return O.emit("error",new Error("Invalid qos vector")),!1;for(let ee=0;ee<ae.length;ee+=1){if(typeof ae[ee]!="number")return O.emit("error",new Error("Invalid qos vector")),!1;R+=1}}let G=null;if(W===5){if(!(G=C(O,b,H,R)))return!1;R+=G.length}return O.write(o.ACKS[_][0][oe][0]),T(O,R),g(O,re),G!==null&&G.write(),W===5&&O.write(a.from(ae)),!0}($,U,K);case"pingreq":case"pingresp":return function(L,O,H){return O.write(o.EMPTY[L.cmd])}($,U);case"disconnect":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.reasonCode,oe=Z.properties;let ae=W===5?1:0,b=null;if(W===5){if(!(b=C(O,oe,H,ae)))return!1;ae+=b.length}return O.write(a.from([o.codes.disconnect<<4])),T(O,ae),W===5&&O.write(a.from([re])),b!==null&&b.write(),!0}($,U,K);case"auth":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.reasonCode,oe=Z.properties;let ae=W===5?1:0;W!==5&&O.emit("error",new Error("Invalid mqtt version for auth packet"));const b=C(O,oe,H,ae);return b?(ae+=b.length,O.write(a.from([o.codes.auth<<4])),T(O,ae),O.write(a.from([re])),b!==null&&b.write(),!0):!1}($,U,K);default:return U.emit("error",new Error("Unknown command")),!1}}function w($){$.uncork()}Object.defineProperty(y,"cacheNumbers",{get:()=>g===X,set($){$?(c&&Object.keys(c).length!==0||(x=!0),g=X):(x=!1,g=V)}});const k={};function T($,U){if(U>o.VARBYTEINT_MAX)return $.emit("error",new Error(`Invalid variable byte integer: ${U}`)),!1;let K=k[U];return K||(K=v(U),U<16384&&(k[U]=K)),d("writeVarByteInt: writing to stream: %o",K),$.write(K)}function I($,U){const K=a.byteLength(U);return g($,K),d("writeString: %s",U),$.write(U,"utf8")}function D($,U,K){I($,U),I($,K)}function X($,U){return d("writeNumberCached: number: %d",U),d("writeNumberCached: %o",c[U]),$.write(c[U])}function V($,U){const K=f(U);return d("writeNumberGenerated: %o",K),$.write(K)}function E($,U){typeof U=="string"?I($,U):U?(g($,U.length),$.write(U)):g($,0)}function A($,U){if(typeof U!="object"||U.length!=null)return{length:1,write(){j($,{},0)}};let K=0;function L(O,H){let W=0;switch(o.propertiesTypes[O]){case"byte":if(typeof H!="boolean")return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=2;break;case"int8":if(typeof H!="number"||H<0||H>255)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=2;break;case"binary":if(H&&H===null)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=1+a.byteLength(H)+2;break;case"int16":if(typeof H!="number"||H<0||H>65535)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=3;break;case"int32":if(typeof H!="number"||H<0||H>4294967295)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=5;break;case"var":if(typeof H!="number"||H<0||H>268435455)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=1+a.byteLength(v(H));break;case"string":if(typeof H!="string")return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=3+a.byteLength(H.toString());break;case"pair":if(typeof H!="object")return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=Object.getOwnPropertyNames(H).reduce((Z,re)=>{const oe=H[re];return Array.isArray(oe)?Z+=oe.reduce((ae,b)=>ae+=3+a.byteLength(re.toString())+2+a.byteLength(b.toString()),0):Z+=3+a.byteLength(re.toString())+2+a.byteLength(H[re].toString()),Z},0);break;default:return $.emit("error",new Error(`Invalid property ${O}: ${H}`)),!1}return W}if(U)for(const O in U){let H=0,W=0;const Z=U[O];if(Array.isArray(Z))for(let re=0;re<Z.length;re++){if(!(W=L(O,Z[re])))return!1;H+=W}else{if(!(W=L(O,Z)))return!1;H=W}if(!H)return!1;K+=H}return{length:a.byteLength(v(K))+K,write(){j($,U,K)}}}function C($,U,K,L){const O=["reasonString","userProperties"],H=K&&K.properties&&K.properties.maximumPacketSize?K.properties.maximumPacketSize:0;let W=A($,U);if(H)for(;L+W.length>H;){const Z=O.shift();if(!Z||!U[Z])return!1;delete U[Z],W=A($,U)}return W}function F($,U,K){switch(o.propertiesTypes[U]){case"byte":$.write(a.from([o.properties[U]])),$.write(a.from([+K]));break;case"int8":$.write(a.from([o.properties[U]])),$.write(a.from([K]));break;case"binary":$.write(a.from([o.properties[U]])),E($,K);break;case"int16":$.write(a.from([o.properties[U]])),g($,K);break;case"int32":$.write(a.from([o.properties[U]])),function(L,O){const H=m(O);d("write4ByteNumber: %o",H),L.write(H)}($,K);break;case"var":$.write(a.from([o.properties[U]])),T($,K);break;case"string":$.write(a.from([o.properties[U]])),I($,K);break;case"pair":Object.getOwnPropertyNames(K).forEach(L=>{const O=K[L];Array.isArray(O)?O.forEach(H=>{$.write(a.from([o.properties[U]])),D($,L.toString(),H.toString())}):($.write(a.from([o.properties[U]])),D($,L.toString(),O.toString()))});break;default:return $.emit("error",new Error(`Invalid property ${U} value: ${K}`)),!1}}function j($,U,K){T($,K);for(const L in U)if(Object.prototype.hasOwnProperty.call(U,L)&&U[L]!==null){const O=U[L];if(Array.isArray(O))for(let H=0;H<O.length;H++)F($,L,O[H]);else F($,L,O)}}function P($){return $?$ instanceof a?$.length:a.byteLength($):0}function J($){return typeof $=="string"||$ instanceof a}n.exports=y}).call(this)}).call(this,t("buffer").Buffer)},{"./constants":38,"./numbers":41,buffer:17,debug:18,"process-nextick-args":49}],45:[function(t,n,l){var a=1e3,o=60*a,u=60*o,p=24*u,s=7*p,i=365.25*p;function d(c,f,h,v){var m=f>=1.5*h;return Math.round(c/h)+" "+v+(m?"s":"")}n.exports=function(c,f){f=f||{};var h=typeof c;if(h==="string"&&c.length>0)return function(v){if(!((v=String(v)).length>100)){var m=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(v);if(m){var g=parseFloat(m[1]);switch((m[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return g*i;case"weeks":case"week":case"w":return g*s;case"days":case"day":case"d":return g*p;case"hours":case"hour":case"hrs":case"hr":case"h":return g*u;case"minutes":case"minute":case"mins":case"min":case"m":return g*o;case"seconds":case"second":case"secs":case"sec":case"s":return g*a;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return g;default:return}}}}(c);if(h==="number"&&isFinite(c))return f.long?function(v){var m=Math.abs(v);return m>=p?d(v,m,p,"day"):m>=u?d(v,m,u,"hour"):m>=o?d(v,m,o,"minute"):m>=a?d(v,m,a,"second"):v+" ms"}(c):function(v){var m=Math.abs(v);return m>=p?Math.round(v/p)+"d":m>=u?Math.round(v/u)+"h":m>=o?Math.round(v/o)+"m":m>=a?Math.round(v/a)+"s":v+"ms"}(c);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(c))}},{}],46:[function(t,n,l){const a=t("./lib/number-allocator.js");n.exports.NumberAllocator=a},{"./lib/number-allocator.js":47}],47:[function(t,n,l){const a=t("js-sdsl").Set,o=t("debug")("number-allocator:trace"),u=t("debug")("number-allocator:error");function p(i,d){this.low=i,this.high=d}function s(i,d){if(!(this instanceof s))return new s(i,d);this.min=i,this.max=d,this.ss=new a([],(c,f)=>c.compare(f)),o("Create"),this.clear()}p.prototype.equals=function(i){return this.low===i.low&&this.high===i.high},p.prototype.compare=function(i){return this.low<i.low&&this.high<i.low?-1:i.low<this.low&&i.high<this.low?1:0},s.prototype.firstVacant=function(){return this.ss.size()===0?null:this.ss.front().low},s.prototype.alloc=function(){if(this.ss.size()===0)return o("alloc():empty"),null;const i=this.ss.front(),d=i.low;return d+1<=i.high?++i.low:this.ss.eraseElementByPos(0),o("alloc():"+d),d},s.prototype.use=function(i){const d=new p(i,i),c=this.ss.lowerBound(d);if(c){if(c.equals(d))return this.ss.eraseElementByValue(c),o("use():"+i),!0;if(c.low>i)return!1;if(c.low===i)return++c.low,o("use():"+i),!0;if(c.high===i)return--c.high,o("use():"+i),!0;const f=c.low;return c.low=i+1,this.ss.insert(new p(f,i-1)),o("use():"+i),!0}return o("use():failed"),!1},s.prototype.free=function(i){if(i<this.min||i>this.max)return void u("free():"+i+" is out of range");const d=new p(i,i),c=this.ss.lowerBound(d);if(c){if(c.low<=i&&i<=c.high)return void u("free():"+i+" has already been vacant");if(c===this.ss.front())i+1===c.low?--c.low:this.ss.insert(d);else{const f=this.ss.reverseLowerBound(d);f.high+1===i?i+1===c.low?(this.ss.eraseElementByValue(f),c.low=f.low):f.high=i:i+1===c.low?c.low=i:this.ss.insert(d)}}else{if(c===this.ss.front())return void this.ss.insert(d);const f=this.ss.reverseLowerBound(d);f.high+1===i?f.high=i:this.ss.insert(d)}o("free():"+i)},s.prototype.clear=function(){o("clear()"),this.ss.clear(),this.ss.insert(new p(this.min,this.max))},s.prototype.intervalCount=function(){return this.ss.size()},s.prototype.dump=function(){console.log("length:"+this.ss.size());for(const i of this.ss)console.log(i)},n.exports=s},{debug:18,"js-sdsl":36}],48:[function(t,n,l){var a=t("wrappy");function o(p){var s=function(){return s.called?s.value:(s.called=!0,s.value=p.apply(this,arguments))};return s.called=!1,s}function u(p){var s=function(){if(s.called)throw new Error(s.onceError);return s.called=!0,s.value=p.apply(this,arguments)},i=p.name||"Function wrapped with `once`";return s.onceError=i+" shouldn't be called more than once",s.called=!1,s}n.exports=a(o),n.exports.strict=a(u),o.proto=o(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return o(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return u(this)},configurable:!0})})},{wrappy:79}],49:[function(t,n,l){(function(a){(function(){a===void 0||!a.version||a.version.indexOf("v0.")===0||a.version.indexOf("v1.")===0&&a.version.indexOf("v1.8.")!==0?n.exports={nextTick:function(o,u,p,s){if(typeof o!="function")throw new TypeError('"callback" argument must be a function');var i,d,c=arguments.length;switch(c){case 0:case 1:return a.nextTick(o);case 2:return a.nextTick(function(){o.call(null,u)});case 3:return a.nextTick(function(){o.call(null,u,p)});case 4:return a.nextTick(function(){o.call(null,u,p,s)});default:for(i=new Array(c-1),d=0;d<i.length;)i[d++]=arguments[d];return a.nextTick(function(){o.apply(null,i)})}}}:n.exports=a}).call(this)}).call(this,t("_process"))},{_process:50}],50:[function(t,n,l){var a,o,u=n.exports={};function p(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function i(y){if(a===setTimeout)return setTimeout(y,0);if((a===p||!a)&&setTimeout)return a=setTimeout,setTimeout(y,0);try{return a(y,0)}catch(w){try{return a.call(null,y,0)}catch(k){return a.call(this,y,0)}}}(function(){try{a=typeof setTimeout=="function"?setTimeout:p}catch(y){a=p}try{o=typeof clearTimeout=="function"?clearTimeout:s}catch(y){o=s}})();var d,c=[],f=!1,h=-1;function v(){f&&d&&(f=!1,d.length?c=d.concat(c):h=-1,c.length&&m())}function m(){if(!f){var y=i(v);f=!0;for(var w=c.length;w;){for(d=c,c=[];++h<w;)d&&d[h].run();h=-1,w=c.length}d=null,f=!1,function(k){if(o===clearTimeout)return clearTimeout(k);if((o===s||!o)&&clearTimeout)return o=clearTimeout,clearTimeout(k);try{o(k)}catch(T){try{return o.call(null,k)}catch(I){return o.call(this,k)}}}(y)}}function g(y,w){this.fun=y,this.array=w}function x(){}u.nextTick=function(y){var w=new Array(arguments.length-1);if(arguments.length>1)for(var k=1;k<arguments.length;k++)w[k-1]=arguments[k];c.push(new g(y,w)),c.length!==1||f||i(m)},g.prototype.run=function(){this.fun.apply(null,this.array)},u.title="browser",u.browser=!0,u.env={},u.argv=[],u.version="",u.versions={},u.on=x,u.addListener=x,u.once=x,u.off=x,u.removeListener=x,u.removeAllListeners=x,u.emit=x,u.prependListener=x,u.prependOnceListener=x,u.listeners=function(y){return[]},u.binding=function(y){throw new Error("process.binding is not supported")},u.cwd=function(){return"/"},u.chdir=function(y){throw new Error("process.chdir is not supported")},u.umask=function(){return 0}},{}],51:[function(t,n,l){(function(a){(function(){(function(o){var u=typeof l=="object"&&l&&!l.nodeType&&l,p=typeof n=="object"&&n&&!n.nodeType&&n,s=typeof a=="object"&&a;s.global!==s&&s.window!==s&&s.self!==s||(o=s);var i,d,c=2147483647,f=36,h=1,v=26,m=38,g=700,x=72,y=128,w="-",k=/^xn--/,T=/[^\x20-\x7E]/,I=/[\x2E\u3002\uFF0E\uFF61]/g,D={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},X=f-h,V=Math.floor,E=String.fromCharCode;function A(L){throw new RangeError(D[L])}function C(L,O){for(var H=L.length,W=[];H--;)W[H]=O(L[H]);return W}function F(L,O){var H=L.split("@"),W="";return H.length>1&&(W=H[0]+"@",L=H[1]),W+C((L=L.replace(I,".")).split("."),O).join(".")}function j(L){for(var O,H,W=[],Z=0,re=L.length;Z<re;)(O=L.charCodeAt(Z++))>=55296&&O<=56319&&Z<re?(64512&(H=L.charCodeAt(Z++)))==56320?W.push(((1023&O)<<10)+(1023&H)+65536):(W.push(O),Z--):W.push(O);return W}function P(L){return C(L,function(O){var H="";return O>65535&&(H+=E((O-=65536)>>>10&1023|55296),O=56320|1023&O),H+=E(O)}).join("")}function J(L,O){return L+22+75*(L<26)-((O!=0)<<5)}function $(L,O,H){var W=0;for(L=H?V(L/g):L>>1,L+=V(L/O);L>X*v>>1;W+=f)L=V(L/X);return V(W+(X+1)*L/(L+m))}function U(L){var O,H,W,Z,re,oe,ae,b,_,R,G,ee=[],te=L.length,se=0,z=y,S=x;for((H=L.lastIndexOf(w))<0&&(H=0),W=0;W<H;++W)L.charCodeAt(W)>=128&&A("not-basic"),ee.push(L.charCodeAt(W));for(Z=H>0?H+1:0;Z<te;){for(re=se,oe=1,ae=f;Z>=te&&A("invalid-input"),((b=(G=L.charCodeAt(Z++))-48<10?G-22:G-65<26?G-65:G-97<26?G-97:f)>=f||b>V((c-se)/oe))&&A("overflow"),se+=b*oe,!(b<(_=ae<=S?h:ae>=S+v?v:ae-S));ae+=f)oe>V(c/(R=f-_))&&A("overflow"),oe*=R;S=$(se-re,O=ee.length+1,re==0),V(se/O)>c-z&&A("overflow"),z+=V(se/O),se%=O,ee.splice(se++,0,z)}return P(ee)}function K(L){var O,H,W,Z,re,oe,ae,b,_,R,G,ee,te,se,z,S=[];for(ee=(L=j(L)).length,O=y,H=0,re=x,oe=0;oe<ee;++oe)(G=L[oe])<128&&S.push(E(G));for(W=Z=S.length,Z&&S.push(w);W<ee;){for(ae=c,oe=0;oe<ee;++oe)(G=L[oe])>=O&&G<ae&&(ae=G);for(ae-O>V((c-H)/(te=W+1))&&A("overflow"),H+=(ae-O)*te,O=ae,oe=0;oe<ee;++oe)if((G=L[oe])<O&&++H>c&&A("overflow"),G==O){for(b=H,_=f;!(b<(R=_<=re?h:_>=re+v?v:_-re));_+=f)z=b-R,se=f-R,S.push(E(J(R+z%se,0))),b=V(z/se);S.push(E(J(b,0))),re=$(H,te,W==Z),H=0,++W}++H,++O}return S.join("")}if(i={version:"1.4.1",ucs2:{decode:j,encode:P},decode:U,encode:K,toASCII:function(L){return F(L,function(O){return T.test(O)?"xn--"+K(O):O})},toUnicode:function(L){return F(L,function(O){return k.test(O)?U(O.slice(4).toLowerCase()):O})}},u&&p)if(n.exports==u)p.exports=i;else for(d in i)i.hasOwnProperty(d)&&(u[d]=i[d]);else o.punycode=i})(this)}).call(this)}).call(this,typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],52:[function(t,n,l){function a(u,p){return Object.prototype.hasOwnProperty.call(u,p)}n.exports=function(u,p,s,i){p=p||"&",s=s||"=";var d={};if(typeof u!="string"||u.length===0)return d;var c=/\+/g;u=u.split(p);var f=1e3;i&&typeof i.maxKeys=="number"&&(f=i.maxKeys);var h=u.length;f>0&&h>f&&(h=f);for(var v=0;v<h;++v){var m,g,x,y,w=u[v].replace(c,"%20"),k=w.indexOf(s);k>=0?(m=w.substr(0,k),g=w.substr(k+1)):(m=w,g=""),x=decodeURIComponent(m),y=decodeURIComponent(g),a(d,x)?o(d[x])?d[x].push(y):d[x]=[d[x],y]:d[x]=y}return d};var o=Array.isArray||function(u){return Object.prototype.toString.call(u)==="[object Array]"}},{}],53:[function(t,n,l){var a=function(s){switch(typeof s){case"string":return s;case"boolean":return s?"true":"false";case"number":return isFinite(s)?s:"";default:return""}};n.exports=function(s,i,d,c){return i=i||"&",d=d||"=",s===null&&(s=void 0),typeof s=="object"?u(p(s),function(f){var h=encodeURIComponent(a(f))+d;return o(s[f])?u(s[f],function(v){return h+encodeURIComponent(a(v))}).join(i):h+encodeURIComponent(a(s[f]))}).join(i):c?encodeURIComponent(a(c))+d+encodeURIComponent(a(s)):""};var o=Array.isArray||function(s){return Object.prototype.toString.call(s)==="[object Array]"};function u(s,i){if(s.map)return s.map(i);for(var d=[],c=0;c<s.length;c++)d.push(i(s[c],c));return d}var p=Object.keys||function(s){var i=[];for(var d in s)Object.prototype.hasOwnProperty.call(s,d)&&i.push(d);return i}},{}],54:[function(t,n,l){l.decode=l.parse=t("./decode"),l.encode=l.stringify=t("./encode")},{"./decode":52,"./encode":53}],55:[function(t,n,l){var a={};function o(p,s,i){i||(i=Error);var d=function(c){var f,h;function v(m,g,x){return c.call(this,function(y,w,k){return typeof s=="string"?s:s(y,w,k)}(m,g,x))||this}return h=c,(f=v).prototype=Object.create(h.prototype),f.prototype.constructor=f,f.__proto__=h,v}(i);d.prototype.name=i.name,d.prototype.code=p,a[p]=d}function u(p,s){if(Array.isArray(p)){var i=p.length;return p=p.map(function(d){return String(d)}),i>2?"one of ".concat(s," ").concat(p.slice(0,i-1).join(", "),", or ")+p[i-1]:i===2?"one of ".concat(s," ").concat(p[0]," or ").concat(p[1]):"of ".concat(s," ").concat(p[0])}return"of ".concat(s," ").concat(String(p))}o("ERR_INVALID_OPT_VALUE",function(p,s){return'The value "'+s+'" is invalid for option "'+p+'"'},TypeError),o("ERR_INVALID_ARG_TYPE",function(p,s,i){var d,c,f;if(typeof s=="string"&&(c="not ",s.substr(0,c.length)===c)?(d="must not be",s=s.replace(/^not /,"")):d="must be",function(v,m,g){return(g===void 0||g>v.length)&&(g=v.length),v.substring(g-m.length,g)===m}(p," argument"))f="The ".concat(p," ").concat(d," ").concat(u(s,"type"));else{var h=function(v,m,g){return typeof g!="number"&&(g=0),!(g+m.length>v.length)&&v.indexOf(m,g)!==-1}(p,".")?"property":"argument";f='The "'.concat(p,'" ').concat(h," ").concat(d," ").concat(u(s,"type"))}return f+=". Received type ".concat(typeof i)},TypeError),o("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),o("ERR_METHOD_NOT_IMPLEMENTED",function(p){return"The "+p+" method is not implemented"}),o("ERR_STREAM_PREMATURE_CLOSE","Premature close"),o("ERR_STREAM_DESTROYED",function(p){return"Cannot call "+p+" after a stream was destroyed"}),o("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),o("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),o("ERR_STREAM_WRITE_AFTER_END","write after end"),o("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),o("ERR_UNKNOWN_ENCODING",function(p){return"Unknown encoding: "+p},TypeError),o("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),n.exports.codes=a},{}],56:[function(t,n,l){(function(a){(function(){var o=Object.keys||function(v){var m=[];for(var g in v)m.push(g);return m};n.exports=c;var u=t("./_stream_readable"),p=t("./_stream_writable");t("inherits")(c,u);for(var s=o(p.prototype),i=0;i<s.length;i++){var d=s[i];c.prototype[d]||(c.prototype[d]=p.prototype[d])}function c(v){if(!(this instanceof c))return new c(v);u.call(this,v),p.call(this,v),this.allowHalfOpen=!0,v&&(v.readable===!1&&(this.readable=!1),v.writable===!1&&(this.writable=!1),v.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",f)))}function f(){this._writableState.ended||a.nextTick(h,this)}function h(v){v.end()}Object.defineProperty(c.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(c.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(c.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(c.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState!==void 0&&this._writableState!==void 0&&this._readableState.destroyed&&this._writableState.destroyed},set:function(v){this._readableState!==void 0&&this._writableState!==void 0&&(this._readableState.destroyed=v,this._writableState.destroyed=v)}})}).call(this)}).call(this,t("_process"))},{"./_stream_readable":58,"./_stream_writable":60,_process:50,inherits:24}],57:[function(t,n,l){n.exports=o;var a=t("./_stream_transform");function o(u){if(!(this instanceof o))return new o(u);a.call(this,u)}t("inherits")(o,a),o.prototype._transform=function(u,p,s){s(null,u)}},{"./_stream_transform":59,inherits:24}],58:[function(t,n,l){(function(a,o){(function(){var u;n.exports=A,A.ReadableState=E,t("events").EventEmitter;var p=function(b,_){return b.listeners(_).length},s=t("./internal/streams/stream"),i=t("buffer").Buffer,d=o.Uint8Array||function(){},c,f=t("util");c=f&&f.debuglog?f.debuglog("stream"):function(){};var h,v,m,g=t("./internal/streams/buffer_list"),x=t("./internal/streams/destroy"),y=t("./internal/streams/state").getHighWaterMark,w=t("../errors").codes,k=w.ERR_INVALID_ARG_TYPE,T=w.ERR_STREAM_PUSH_AFTER_EOF,I=w.ERR_METHOD_NOT_IMPLEMENTED,D=w.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;t("inherits")(A,s);var X=x.errorOrDestroy,V=["error","close","destroy","pause","resume"];function E(b,_,R){u=u||t("./_stream_duplex"),b=b||{},typeof R!="boolean"&&(R=_ instanceof u),this.objectMode=!!b.objectMode,R&&(this.objectMode=this.objectMode||!!b.readableObjectMode),this.highWaterMark=y(this,b,"readableHighWaterMark",R),this.buffer=new g,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=b.emitClose!==!1,this.autoDestroy=!!b.autoDestroy,this.destroyed=!1,this.defaultEncoding=b.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,b.encoding&&(h||(h=t("string_decoder/").StringDecoder),this.decoder=new h(b.encoding),this.encoding=b.encoding)}function A(b){if(u=u||t("./_stream_duplex"),!(this instanceof A))return new A(b);var _=this instanceof u;this._readableState=new E(b,this,_),this.readable=!0,b&&(typeof b.read=="function"&&(this._read=b.read),typeof b.destroy=="function"&&(this._destroy=b.destroy)),s.call(this)}function C(b,_,R,G,ee){c("readableAddChunk",_);var te,se=b._readableState;if(_===null)se.reading=!1,function(z,S){if(c("onEofChunk"),!S.ended){if(S.decoder){var B=S.decoder.end();B&&B.length&&(S.buffer.push(B),S.length+=S.objectMode?1:B.length)}S.ended=!0,S.sync?J(z):(S.needReadable=!1,S.emittedReadable||(S.emittedReadable=!0,$(z)))}}(b,se);else if(ee||(te=function(z,S){var B;Y=S,i.isBuffer(Y)||Y instanceof d||typeof S=="string"||S===void 0||z.objectMode||(B=new k("chunk",["string","Buffer","Uint8Array"],S));var Y;return B}(se,_)),te)X(b,te);else if(se.objectMode||_&&_.length>0)if(typeof _=="string"||se.objectMode||Object.getPrototypeOf(_)===i.prototype||(_=function(z){return i.from(z)}(_)),G)se.endEmitted?X(b,new D):F(b,se,_,!0);else if(se.ended)X(b,new T);else{if(se.destroyed)return!1;se.reading=!1,se.decoder&&!R?(_=se.decoder.write(_),se.objectMode||_.length!==0?F(b,se,_,!1):U(b,se)):F(b,se,_,!1)}else G||(se.reading=!1,U(b,se));return!se.ended&&(se.length<se.highWaterMark||se.length===0)}function F(b,_,R,G){_.flowing&&_.length===0&&!_.sync?(_.awaitDrain=0,b.emit("data",R)):(_.length+=_.objectMode?1:R.length,G?_.buffer.unshift(R):_.buffer.push(R),_.needReadable&&J(b)),U(b,_)}Object.defineProperty(A.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState!==void 0&&this._readableState.destroyed},set:function(b){this._readableState&&(this._readableState.destroyed=b)}}),A.prototype.destroy=x.destroy,A.prototype._undestroy=x.undestroy,A.prototype._destroy=function(b,_){_(b)},A.prototype.push=function(b,_){var R,G=this._readableState;return G.objectMode?R=!0:typeof b=="string"&&((_=_||G.defaultEncoding)!==G.encoding&&(b=i.from(b,_),_=""),R=!0),C(this,b,_,!1,R)},A.prototype.unshift=function(b){return C(this,b,null,!0,!1)},A.prototype.isPaused=function(){return this._readableState.flowing===!1},A.prototype.setEncoding=function(b){h||(h=t("string_decoder/").StringDecoder);var _=new h(b);this._readableState.decoder=_,this._readableState.encoding=this._readableState.decoder.encoding;for(var R=this._readableState.buffer.head,G="";R!==null;)G+=_.write(R.data),R=R.next;return this._readableState.buffer.clear(),G!==""&&this._readableState.buffer.push(G),this._readableState.length=G.length,this};var j=1073741824;function P(b,_){return b<=0||_.length===0&&_.ended?0:_.objectMode?1:b!=b?_.flowing&&_.length?_.buffer.head.data.length:_.length:(b>_.highWaterMark&&(_.highWaterMark=function(R){return R>=j?R=j:(R--,R|=R>>>1,R|=R>>>2,R|=R>>>4,R|=R>>>8,R|=R>>>16,R++),R}(b)),b<=_.length?b:_.ended?_.length:(_.needReadable=!0,0))}function J(b){var _=b._readableState;c("emitReadable",_.needReadable,_.emittedReadable),_.needReadable=!1,_.emittedReadable||(c("emitReadable",_.flowing),_.emittedReadable=!0,a.nextTick($,b))}function $(b){var _=b._readableState;c("emitReadable_",_.destroyed,_.length,_.ended),_.destroyed||!_.length&&!_.ended||(b.emit("readable"),_.emittedReadable=!1),_.needReadable=!_.flowing&&!_.ended&&_.length<=_.highWaterMark,W(b)}function U(b,_){_.readingMore||(_.readingMore=!0,a.nextTick(K,b,_))}function K(b,_){for(;!_.reading&&!_.ended&&(_.length<_.highWaterMark||_.flowing&&_.length===0);){var R=_.length;if(c("maybeReadMore read 0"),b.read(0),R===_.length)break}_.readingMore=!1}function L(b){var _=b._readableState;_.readableListening=b.listenerCount("readable")>0,_.resumeScheduled&&!_.paused?_.flowing=!0:b.listenerCount("data")>0&&b.resume()}function O(b){c("readable nexttick read 0"),b.read(0)}function H(b,_){c("resume",_.reading),_.reading||b.read(0),_.resumeScheduled=!1,b.emit("resume"),W(b),_.flowing&&!_.reading&&b.read(0)}function W(b){var _=b._readableState;for(c("flow",_.flowing);_.flowing&&b.read()!==null;);}function Z(b,_){return _.length===0?null:(_.objectMode?R=_.buffer.shift():!b||b>=_.length?(R=_.decoder?_.buffer.join(""):_.buffer.length===1?_.buffer.first():_.buffer.concat(_.length),_.buffer.clear()):R=_.buffer.consume(b,_.decoder),R);var R}function re(b){var _=b._readableState;c("endReadable",_.endEmitted),_.endEmitted||(_.ended=!0,a.nextTick(oe,_,b))}function oe(b,_){if(c("endReadableNT",b.endEmitted,b.length),!b.endEmitted&&b.length===0&&(b.endEmitted=!0,_.readable=!1,_.emit("end"),b.autoDestroy)){var R=_._writableState;(!R||R.autoDestroy&&R.finished)&&_.destroy()}}function ae(b,_){for(var R=0,G=b.length;R<G;R++)if(b[R]===_)return R;return-1}A.prototype.read=function(b){c("read",b),b=parseInt(b,10);var _=this._readableState,R=b;if(b!==0&&(_.emittedReadable=!1),b===0&&_.needReadable&&((_.highWaterMark!==0?_.length>=_.highWaterMark:_.length>0)||_.ended))return c("read: emitReadable",_.length,_.ended),_.length===0&&_.ended?re(this):J(this),null;if((b=P(b,_))===0&&_.ended)return _.length===0&&re(this),null;var G,ee=_.needReadable;return c("need readable",ee),(_.length===0||_.length-b<_.highWaterMark)&&c("length less than watermark",ee=!0),_.ended||_.reading?c("reading or ended",ee=!1):ee&&(c("do read"),_.reading=!0,_.sync=!0,_.length===0&&(_.needReadable=!0),this._read(_.highWaterMark),_.sync=!1,_.reading||(b=P(R,_))),(G=b>0?Z(b,_):null)===null?(_.needReadable=_.length<=_.highWaterMark,b=0):(_.length-=b,_.awaitDrain=0),_.length===0&&(_.ended||(_.needReadable=!0),R!==b&&_.ended&&re(this)),G!==null&&this.emit("data",G),G},A.prototype._read=function(b){X(this,new I("_read()"))},A.prototype.pipe=function(b,_){var R=this,G=this._readableState;switch(G.pipesCount){case 0:G.pipes=b;break;case 1:G.pipes=[G.pipes,b];break;default:G.pipes.push(b)}G.pipesCount+=1,c("pipe count=%d opts=%j",G.pipesCount,_);var ee=(!_||_.end!==!1)&&b!==a.stdout&&b!==a.stderr?se:ce;function te(me,ge){c("onunpipe"),me===R&&ge&&ge.hasUnpiped===!1&&(ge.hasUnpiped=!0,c("cleanup"),b.removeListener("close",ie),b.removeListener("finish",ue),b.removeListener("drain",z),b.removeListener("error",Y),b.removeListener("unpipe",te),R.removeListener("end",se),R.removeListener("end",ce),R.removeListener("data",B),S=!0,!G.awaitDrain||b._writableState&&!b._writableState.needDrain||z())}function se(){c("onend"),b.end()}G.endEmitted?a.nextTick(ee):R.once("end",ee),b.on("unpipe",te);var z=function(me){return function(){var ge=me._readableState;c("pipeOnDrain",ge.awaitDrain),ge.awaitDrain&&ge.awaitDrain--,ge.awaitDrain===0&&p(me,"data")&&(ge.flowing=!0,W(me))}}(R);b.on("drain",z);var S=!1;function B(me){c("ondata");var ge=b.write(me);c("dest.write",ge),ge===!1&&((G.pipesCount===1&&G.pipes===b||G.pipesCount>1&&ae(G.pipes,b)!==-1)&&!S&&(c("false write response, pause",G.awaitDrain),G.awaitDrain++),R.pause())}function Y(me){c("onerror",me),ce(),b.removeListener("error",Y),p(b,"error")===0&&X(b,me)}function ie(){b.removeListener("finish",ue),ce()}function ue(){c("onfinish"),b.removeListener("close",ie),ce()}function ce(){c("unpipe"),R.unpipe(b)}return R.on("data",B),function(me,ge,Ce){if(typeof me.prependListener=="function")return me.prependListener(ge,Ce);me._events&&me._events[ge]?Array.isArray(me._events[ge])?me._events[ge].unshift(Ce):me._events[ge]=[Ce,me._events[ge]]:me.on(ge,Ce)}(b,"error",Y),b.once("close",ie),b.once("finish",ue),b.emit("pipe",R),G.flowing||(c("pipe resume"),R.resume()),b},A.prototype.unpipe=function(b){var _=this._readableState,R={hasUnpiped:!1};if(_.pipesCount===0)return this;if(_.pipesCount===1)return b&&b!==_.pipes?this:(b||(b=_.pipes),_.pipes=null,_.pipesCount=0,_.flowing=!1,b&&b.emit("unpipe",this,R),this);if(!b){var G=_.pipes,ee=_.pipesCount;_.pipes=null,_.pipesCount=0,_.flowing=!1;for(var te=0;te<ee;te++)G[te].emit("unpipe",this,{hasUnpiped:!1});return this}var se=ae(_.pipes,b);return se===-1?this:(_.pipes.splice(se,1),_.pipesCount-=1,_.pipesCount===1&&(_.pipes=_.pipes[0]),b.emit("unpipe",this,R),this)},A.prototype.on=function(b,_){var R=s.prototype.on.call(this,b,_),G=this._readableState;return b==="data"?(G.readableListening=this.listenerCount("readable")>0,G.flowing!==!1&&this.resume()):b==="readable"&&(G.endEmitted||G.readableListening||(G.readableListening=G.needReadable=!0,G.flowing=!1,G.emittedReadable=!1,c("on readable",G.length,G.reading),G.length?J(this):G.reading||a.nextTick(O,this))),R},A.prototype.addListener=A.prototype.on,A.prototype.removeListener=function(b,_){var R=s.prototype.removeListener.call(this,b,_);return b==="readable"&&a.nextTick(L,this),R},A.prototype.removeAllListeners=function(b){var _=s.prototype.removeAllListeners.apply(this,arguments);return b!=="readable"&&b!==void 0||a.nextTick(L,this),_},A.prototype.resume=function(){var b=this._readableState;return b.flowing||(c("resume"),b.flowing=!b.readableListening,function(_,R){R.resumeScheduled||(R.resumeScheduled=!0,a.nextTick(H,_,R))}(this,b)),b.paused=!1,this},A.prototype.pause=function(){return c("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(c("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},A.prototype.wrap=function(b){var _=this,R=this._readableState,G=!1;for(var ee in b.on("end",function(){if(c("wrapped end"),R.decoder&&!R.ended){var se=R.decoder.end();se&&se.length&&_.push(se)}_.push(null)}),b.on("data",function(se){c("wrapped data"),R.decoder&&(se=R.decoder.write(se)),(!R.objectMode||se!=null)&&(R.objectMode||se&&se.length)&&(_.push(se)||(G=!0,b.pause()))}),b)this[ee]===void 0&&typeof b[ee]=="function"&&(this[ee]=function(se){return function(){return b[se].apply(b,arguments)}}(ee));for(var te=0;te<V.length;te++)b.on(V[te],this.emit.bind(this,V[te]));return this._read=function(se){c("wrapped _read",se),G&&(G=!1,b.resume())},this},typeof Symbol=="function"&&(A.prototype[Symbol.asyncIterator]=function(){return v===void 0&&(v=t("./internal/streams/async_iterator")),v(this)}),Object.defineProperty(A.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(A.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(A.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(b){this._readableState&&(this._readableState.flowing=b)}}),A._fromList=Z,Object.defineProperty(A.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),typeof Symbol=="function"&&(A.from=function(b,_){return m===void 0&&(m=t("./internal/streams/from")),m(A,b,_)})}).call(this)}).call(this,t("_process"),typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"../errors":55,"./_stream_duplex":56,"./internal/streams/async_iterator":61,"./internal/streams/buffer_list":62,"./internal/streams/destroy":63,"./internal/streams/from":65,"./internal/streams/state":67,"./internal/streams/stream":68,_process:50,buffer:17,events:22,inherits:24,"string_decoder/":75,util:16}],59:[function(t,n,l){n.exports=d;var a=t("../errors").codes,o=a.ERR_METHOD_NOT_IMPLEMENTED,u=a.ERR_MULTIPLE_CALLBACK,p=a.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=a.ERR_TRANSFORM_WITH_LENGTH_0,i=t("./_stream_duplex");function d(h){if(!(this instanceof d))return new d(h);i.call(this,h),this._transformState={afterTransform:function(v,m){var g=this._transformState;g.transforming=!1;var x=g.writecb;if(x===null)return this.emit("error",new u);g.writechunk=null,g.writecb=null,m!=null&&this.push(m),x(v);var y=this._readableState;y.reading=!1,(y.needReadable||y.length<y.highWaterMark)&&this._read(y.highWaterMark)}.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,h&&(typeof h.transform=="function"&&(this._transform=h.transform),typeof h.flush=="function"&&(this._flush=h.flush)),this.on("prefinish",c)}function c(){var h=this;typeof this._flush!="function"||this._readableState.destroyed?f(this,null,null):this._flush(function(v,m){f(h,v,m)})}function f(h,v,m){if(v)return h.emit("error",v);if(m!=null&&h.push(m),h._writableState.length)throw new s;if(h._transformState.transforming)throw new p;return h.push(null)}t("inherits")(d,i),d.prototype.push=function(h,v){return this._transformState.needTransform=!1,i.prototype.push.call(this,h,v)},d.prototype._transform=function(h,v,m){m(new o("_transform()"))},d.prototype._write=function(h,v,m){var g=this._transformState;if(g.writecb=m,g.writechunk=h,g.writeencoding=v,!g.transforming){var x=this._readableState;(g.needTransform||x.needReadable||x.length<x.highWaterMark)&&this._read(x.highWaterMark)}},d.prototype._read=function(h){var v=this._transformState;v.writechunk===null||v.transforming?v.needTransform=!0:(v.transforming=!0,this._transform(v.writechunk,v.writeencoding,v.afterTransform))},d.prototype._destroy=function(h,v){i.prototype._destroy.call(this,h,function(m){v(m)})}},{"../errors":55,"./_stream_duplex":56,inherits:24}],60:[function(t,n,l){(function(a,o){(function(){function u(U){var K=this;this.next=null,this.entry=null,this.finish=function(){(function(L,O,H){var W=L.entry;for(L.entry=null;W;){var Z=W.callback;O.pendingcb--,Z(H),W=W.next}O.corkedRequestsFree.next=L})(K,U)}}var p;n.exports=A,A.WritableState=E;var s={deprecate:t("util-deprecate")},i=t("./internal/streams/stream"),d=t("buffer").Buffer,c=o.Uint8Array||function(){},f,h=t("./internal/streams/destroy"),v=t("./internal/streams/state").getHighWaterMark,m=t("../errors").codes,g=m.ERR_INVALID_ARG_TYPE,x=m.ERR_METHOD_NOT_IMPLEMENTED,y=m.ERR_MULTIPLE_CALLBACK,w=m.ERR_STREAM_CANNOT_PIPE,k=m.ERR_STREAM_DESTROYED,T=m.ERR_STREAM_NULL_VALUES,I=m.ERR_STREAM_WRITE_AFTER_END,D=m.ERR_UNKNOWN_ENCODING,X=h.errorOrDestroy;function V(){}function E(U,K,L){p=p||t("./_stream_duplex"),U=U||{},typeof L!="boolean"&&(L=K instanceof p),this.objectMode=!!U.objectMode,L&&(this.objectMode=this.objectMode||!!U.writableObjectMode),this.highWaterMark=v(this,U,"writableHighWaterMark",L),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var O=U.decodeStrings===!1;this.decodeStrings=!O,this.defaultEncoding=U.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(H){(function(W,Z){var re=W._writableState,oe=re.sync,ae=re.writecb;if(typeof ae!="function")throw new y;if(function(_){_.writing=!1,_.writecb=null,_.length-=_.writelen,_.writelen=0}(re),Z)(function(_,R,G,ee,te){--R.pendingcb,G?(a.nextTick(te,ee),a.nextTick($,_,R),_._writableState.errorEmitted=!0,X(_,ee)):(te(ee),_._writableState.errorEmitted=!0,X(_,ee),$(_,R))})(W,re,oe,Z,ae);else{var b=P(re)||W.destroyed;b||re.corked||re.bufferProcessing||!re.bufferedRequest||j(W,re),oe?a.nextTick(F,W,re,b,ae):F(W,re,b,ae)}})(K,H)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=U.emitClose!==!1,this.autoDestroy=!!U.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new u(this)}function A(U){var K=this instanceof(p=p||t("./_stream_duplex"));if(!K&&!f.call(A,this))return new A(U);this._writableState=new E(U,this,K),this.writable=!0,U&&(typeof U.write=="function"&&(this._write=U.write),typeof U.writev=="function"&&(this._writev=U.writev),typeof U.destroy=="function"&&(this._destroy=U.destroy),typeof U.final=="function"&&(this._final=U.final)),i.call(this)}function C(U,K,L,O,H,W,Z){K.writelen=O,K.writecb=Z,K.writing=!0,K.sync=!0,K.destroyed?K.onwrite(new k("write")):L?U._writev(H,K.onwrite):U._write(H,W,K.onwrite),K.sync=!1}function F(U,K,L,O){L||function(H,W){W.length===0&&W.needDrain&&(W.needDrain=!1,H.emit("drain"))}(U,K),K.pendingcb--,O(),$(U,K)}function j(U,K){K.bufferProcessing=!0;var L=K.bufferedRequest;if(U._writev&&L&&L.next){var O=K.bufferedRequestCount,H=new Array(O),W=K.corkedRequestsFree;W.entry=L;for(var Z=0,re=!0;L;)H[Z]=L,L.isBuf||(re=!1),L=L.next,Z+=1;H.allBuffers=re,C(U,K,!0,K.length,H,"",W.finish),K.pendingcb++,K.lastBufferedRequest=null,W.next?(K.corkedRequestsFree=W.next,W.next=null):K.corkedRequestsFree=new u(K),K.bufferedRequestCount=0}else{for(;L;){var oe=L.chunk,ae=L.encoding,b=L.callback;if(C(U,K,!1,K.objectMode?1:oe.length,oe,ae,b),L=L.next,K.bufferedRequestCount--,K.writing)break}L===null&&(K.lastBufferedRequest=null)}K.bufferedRequest=L,K.bufferProcessing=!1}function P(U){return U.ending&&U.length===0&&U.bufferedRequest===null&&!U.finished&&!U.writing}function J(U,K){U._final(function(L){K.pendingcb--,L&&X(U,L),K.prefinished=!0,U.emit("prefinish"),$(U,K)})}function $(U,K){var L=P(K);if(L&&(function(H,W){W.prefinished||W.finalCalled||(typeof H._final!="function"||W.destroyed?(W.prefinished=!0,H.emit("prefinish")):(W.pendingcb++,W.finalCalled=!0,a.nextTick(J,H,W)))}(U,K),K.pendingcb===0&&(K.finished=!0,U.emit("finish"),K.autoDestroy))){var O=U._readableState;(!O||O.autoDestroy&&O.endEmitted)&&U.destroy()}return L}t("inherits")(A,i),E.prototype.getBuffer=function(){for(var U=this.bufferedRequest,K=[];U;)K.push(U),U=U.next;return K},function(){try{Object.defineProperty(E.prototype,"buffer",{get:s.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(U){}}(),typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(f=Function.prototype[Symbol.hasInstance],Object.defineProperty(A,Symbol.hasInstance,{value:function(U){return!!f.call(this,U)||this===A&&U&&U._writableState instanceof E}})):f=function(U){return U instanceof this},A.prototype.pipe=function(){X(this,new w)},A.prototype.write=function(U,K,L){var O,H=this._writableState,W=!1,Z=!H.objectMode&&(O=U,d.isBuffer(O)||O instanceof c);return Z&&!d.isBuffer(U)&&(U=function(re){return d.from(re)}(U)),typeof K=="function"&&(L=K,K=null),Z?K="buffer":K||(K=H.defaultEncoding),typeof L!="function"&&(L=V),H.ending?function(re,oe){var ae=new I;X(re,ae),a.nextTick(oe,ae)}(this,L):(Z||function(re,oe,ae,b){var _;return ae===null?_=new T:typeof ae=="string"||oe.objectMode||(_=new g("chunk",["string","Buffer"],ae)),!_||(X(re,_),a.nextTick(b,_),!1)}(this,H,U,L))&&(H.pendingcb++,W=function(re,oe,ae,b,_,R){if(!ae){var G=function(z,S,B){return z.objectMode||z.decodeStrings===!1||typeof S!="string"||(S=d.from(S,B)),S}(oe,b,_);b!==G&&(ae=!0,_="buffer",b=G)}var ee=oe.objectMode?1:b.length;oe.length+=ee;var te=oe.length<oe.highWaterMark;if(te||(oe.needDrain=!0),oe.writing||oe.corked){var se=oe.lastBufferedRequest;oe.lastBufferedRequest={chunk:b,encoding:_,isBuf:ae,callback:R,next:null},se?se.next=oe.lastBufferedRequest:oe.bufferedRequest=oe.lastBufferedRequest,oe.bufferedRequestCount+=1}else C(re,oe,!1,ee,b,_,R);return te}(this,H,Z,U,K,L)),W},A.prototype.cork=function(){this._writableState.corked++},A.prototype.uncork=function(){var U=this._writableState;U.corked&&(U.corked--,U.writing||U.corked||U.bufferProcessing||!U.bufferedRequest||j(this,U))},A.prototype.setDefaultEncoding=function(U){if(typeof U=="string"&&(U=U.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((U+"").toLowerCase())>-1))throw new D(U);return this._writableState.defaultEncoding=U,this},Object.defineProperty(A.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(A.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),A.prototype._write=function(U,K,L){L(new x("_write()"))},A.prototype._writev=null,A.prototype.end=function(U,K,L){var O=this._writableState;return typeof U=="function"?(L=U,U=null,K=null):typeof K=="function"&&(L=K,K=null),U!=null&&this.write(U,K),O.corked&&(O.corked=1,this.uncork()),O.ending||function(H,W,Z){W.ending=!0,$(H,W),Z&&(W.finished?a.nextTick(Z):H.once("finish",Z)),W.ended=!0,H.writable=!1}(this,O,L),this},Object.defineProperty(A.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(A.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState!==void 0&&this._writableState.destroyed},set:function(U){this._writableState&&(this._writableState.destroyed=U)}}),A.prototype.destroy=h.destroy,A.prototype._undestroy=h.undestroy,A.prototype._destroy=function(U,K){K(U)}}).call(this)}).call(this,t("_process"),typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"../errors":55,"./_stream_duplex":56,"./internal/streams/destroy":63,"./internal/streams/state":67,"./internal/streams/stream":68,_process:50,buffer:17,inherits:24,"util-deprecate":78}],61:[function(t,n,l){(function(a){(function(){var o;function u(w,k,T){return k in w?Object.defineProperty(w,k,{value:T,enumerable:!0,configurable:!0,writable:!0}):w[k]=T,w}var p=t("./end-of-stream"),s=Symbol("lastResolve"),i=Symbol("lastReject"),d=Symbol("error"),c=Symbol("ended"),f=Symbol("lastPromise"),h=Symbol("handlePromise"),v=Symbol("stream");function m(w,k){return{value:w,done:k}}function g(w){var k=w[s];if(k!==null){var T=w[v].read();T!==null&&(w[f]=null,w[s]=null,w[i]=null,k(m(T,!1)))}}var x=Object.getPrototypeOf(function(){}),y=Object.setPrototypeOf((u(o={get stream(){return this[v]},next:function(){var w=this,k=this[d];if(k!==null)return Promise.reject(k);if(this[c])return Promise.resolve(m(void 0,!0));if(this[v].destroyed)return new Promise(function(X,V){a.nextTick(function(){w[d]?V(w[d]):X(m(void 0,!0))})});var T,I=this[f];if(I)T=new Promise(function(X,V){return function(E,A){X.then(function(){V[c]?E(m(void 0,!0)):V[h](E,A)},A)}}(I,this));else{var D=this[v].read();if(D!==null)return Promise.resolve(m(D,!1));T=new Promise(this[h])}return this[f]=T,T}},Symbol.asyncIterator,function(){return this}),u(o,"return",function(){var w=this;return new Promise(function(k,T){w[v].destroy(null,function(I){I?T(I):k(m(void 0,!0))})})}),o),x);n.exports=function(w){var k,T=Object.create(y,(u(k={},v,{value:w,writable:!0}),u(k,s,{value:null,writable:!0}),u(k,i,{value:null,writable:!0}),u(k,d,{value:null,writable:!0}),u(k,c,{value:w._readableState.endEmitted,writable:!0}),u(k,h,{value:function(I,D){var X=T[v].read();X?(T[f]=null,T[s]=null,T[i]=null,I(m(X,!1))):(T[s]=I,T[i]=D)},writable:!0}),k));return T[f]=null,p(w,function(I){if(I&&I.code!=="ERR_STREAM_PREMATURE_CLOSE"){var D=T[i];return D!==null&&(T[f]=null,T[s]=null,T[i]=null,D(I)),void(T[d]=I)}var X=T[s];X!==null&&(T[f]=null,T[s]=null,T[i]=null,X(m(void 0,!0))),T[c]=!0}),w.on("readable",function(I){a.nextTick(g,I)}.bind(null,T)),T}}).call(this)}).call(this,t("_process"))},{"./end-of-stream":64,_process:50}],62:[function(t,n,l){function a(d,c){var f=Object.keys(d);if(Object.getOwnPropertySymbols){var h=Object.getOwnPropertySymbols(d);c&&(h=h.filter(function(v){return Object.getOwnPropertyDescriptor(d,v).enumerable})),f.push.apply(f,h)}return f}function o(d,c,f){return c in d?Object.defineProperty(d,c,{value:f,enumerable:!0,configurable:!0,writable:!0}):d[c]=f,d}function u(d,c){for(var f=0;f<c.length;f++){var h=c[f];h.enumerable=h.enumerable||!1,h.configurable=!0,"value"in h&&(h.writable=!0),Object.defineProperty(d,h.key,h)}}var p=t("buffer").Buffer,s=t("util").inspect,i=s&&s.custom||"inspect";n.exports=function(){function d(){(function(h,v){if(!(h instanceof v))throw new TypeError("Cannot call a class as a function")})(this,d),this.head=null,this.tail=null,this.length=0}var c,f;return c=d,(f=[{key:"push",value:function(h){var v={data:h,next:null};this.length>0?this.tail.next=v:this.head=v,this.tail=v,++this.length}},{key:"unshift",value:function(h){var v={data:h,next:this.head};this.length===0&&(this.tail=v),this.head=v,++this.length}},{key:"shift",value:function(){if(this.length!==0){var h=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,h}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(h){if(this.length===0)return"";for(var v=this.head,m=""+v.data;v=v.next;)m+=h+v.data;return m}},{key:"concat",value:function(h){if(this.length===0)return p.alloc(0);for(var v,m,g,x=p.allocUnsafe(h>>>0),y=this.head,w=0;y;)v=y.data,m=x,g=w,p.prototype.copy.call(v,m,g),w+=y.data.length,y=y.next;return x}},{key:"consume",value:function(h,v){var m;return h<this.head.data.length?(m=this.head.data.slice(0,h),this.head.data=this.head.data.slice(h)):m=h===this.head.data.length?this.shift():v?this._getString(h):this._getBuffer(h),m}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(h){var v=this.head,m=1,g=v.data;for(h-=g.length;v=v.next;){var x=v.data,y=h>x.length?x.length:h;if(y===x.length?g+=x:g+=x.slice(0,h),(h-=y)===0){y===x.length?(++m,v.next?this.head=v.next:this.head=this.tail=null):(this.head=v,v.data=x.slice(y));break}++m}return this.length-=m,g}},{key:"_getBuffer",value:function(h){var v=p.allocUnsafe(h),m=this.head,g=1;for(m.data.copy(v),h-=m.data.length;m=m.next;){var x=m.data,y=h>x.length?x.length:h;if(x.copy(v,v.length-h,0,y),(h-=y)===0){y===x.length?(++g,m.next?this.head=m.next:this.head=this.tail=null):(this.head=m,m.data=x.slice(y));break}++g}return this.length-=g,v}},{key:i,value:function(h,v){return s(this,function(m){for(var g=1;g<arguments.length;g++){var x=arguments[g]!=null?arguments[g]:{};g%2?a(Object(x),!0).forEach(function(y){o(m,y,x[y])}):Object.getOwnPropertyDescriptors?Object.defineProperties(m,Object.getOwnPropertyDescriptors(x)):a(Object(x)).forEach(function(y){Object.defineProperty(m,y,Object.getOwnPropertyDescriptor(x,y))})}return m}({},v,{depth:0,customInspect:!1}))}}])&&u(c.prototype,f),d}()},{buffer:17,util:16}],63:[function(t,n,l){(function(a){(function(){function o(s,i){p(s,i),u(s)}function u(s){s._writableState&&!s._writableState.emitClose||s._readableState&&!s._readableState.emitClose||s.emit("close")}function p(s,i){s.emit("error",i)}n.exports={destroy:function(s,i){var d=this,c=this._readableState&&this._readableState.destroyed,f=this._writableState&&this._writableState.destroyed;return c||f?(i?i(s):s&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,a.nextTick(p,this,s)):a.nextTick(p,this,s)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(s||null,function(h){!i&&h?d._writableState?d._writableState.errorEmitted?a.nextTick(u,d):(d._writableState.errorEmitted=!0,a.nextTick(o,d,h)):a.nextTick(o,d,h):i?(a.nextTick(u,d),i(h)):a.nextTick(u,d)}),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(s,i){var d=s._readableState,c=s._writableState;d&&d.autoDestroy||c&&c.autoDestroy?s.destroy(i):s.emit("error",i)}}}).call(this)}).call(this,t("_process"))},{_process:50}],64:[function(t,n,l){var a=t("../../../errors").codes.ERR_STREAM_PREMATURE_CLOSE;function o(){}n.exports=function u(p,s,i){if(typeof s=="function")return u(p,null,s);s||(s={}),i=function(k){var T=!1;return function(){if(!T){T=!0;for(var I=arguments.length,D=new Array(I),X=0;X<I;X++)D[X]=arguments[X];k.apply(this,D)}}}(i||o);var d=s.readable||s.readable!==!1&&p.readable,c=s.writable||s.writable!==!1&&p.writable,f=function(){p.writable||v()},h=p._writableState&&p._writableState.finished,v=function(){c=!1,h=!0,d||i.call(p)},m=p._readableState&&p._readableState.endEmitted,g=function(){d=!1,m=!0,c||i.call(p)},x=function(k){i.call(p,k)},y=function(){var k;return d&&!m?(p._readableState&&p._readableState.ended||(k=new a),i.call(p,k)):c&&!h?(p._writableState&&p._writableState.ended||(k=new a),i.call(p,k)):void 0},w=function(){p.req.on("finish",v)};return function(k){return k.setHeader&&typeof k.abort=="function"}(p)?(p.on("complete",v),p.on("abort",y),p.req?w():p.on("request",w)):c&&!p._writableState&&(p.on("end",f),p.on("close",f)),p.on("end",g),p.on("finish",v),s.error!==!1&&p.on("error",x),p.on("close",y),function(){p.removeListener("complete",v),p.removeListener("abort",y),p.removeListener("request",w),p.req&&p.req.removeListener("finish",v),p.removeListener("end",f),p.removeListener("close",f),p.removeListener("finish",v),p.removeListener("end",g),p.removeListener("error",x),p.removeListener("close",y)}}},{"../../../errors":55}],65:[function(t,n,l){n.exports=function(){throw new Error("Readable.from is not available in the browser")}},{}],66:[function(t,n,l){var a,o=t("../../../errors").codes,u=o.ERR_MISSING_ARGS,p=o.ERR_STREAM_DESTROYED;function s(c){if(c)throw c}function i(c){c()}function d(c,f){return c.pipe(f)}n.exports=function(){for(var c=arguments.length,f=new Array(c),h=0;h<c;h++)f[h]=arguments[h];var v,m=function(x){return x.length?typeof x[x.length-1]!="function"?s:x.pop():s}(f);if(Array.isArray(f[0])&&(f=f[0]),f.length<2)throw new u("streams");var g=f.map(function(x,y){var w=y<f.length-1;return function(k,T,I,D){D=function(E){var A=!1;return function(){A||(A=!0,E.apply(void 0,arguments))}}(D);var X=!1;k.on("close",function(){X=!0}),a===void 0&&(a=t("./end-of-stream")),a(k,{readable:T,writable:I},function(E){if(E)return D(E);X=!0,D()});var V=!1;return function(E){if(!X&&!V)return V=!0,function(A){return A.setHeader&&typeof A.abort=="function"}(k)?k.abort():typeof k.destroy=="function"?k.destroy():void D(E||new p("pipe"))}}(x,w,y>0,function(k){v||(v=k),k&&g.forEach(i),w||(g.forEach(i),m(v))})});return f.reduce(d)}},{"../../../errors":55,"./end-of-stream":64}],67:[function(t,n,l){var a=t("../../../errors").codes.ERR_INVALID_OPT_VALUE;n.exports={getHighWaterMark:function(o,u,p,s){var i=function(d,c,f){return d.highWaterMark!=null?d.highWaterMark:c?d[f]:null}(u,s,p);if(i!=null){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new a(s?p:"highWaterMark",i);return Math.floor(i)}return o.objectMode?16:16384}}},{"../../../errors":55}],68:[function(t,n,l){n.exports=t("events").EventEmitter},{events:22}],69:[function(t,n,l){(l=n.exports=t("./lib/_stream_readable.js")).Stream=l,l.Readable=l,l.Writable=t("./lib/_stream_writable.js"),l.Duplex=t("./lib/_stream_duplex.js"),l.Transform=t("./lib/_stream_transform.js"),l.PassThrough=t("./lib/_stream_passthrough.js"),l.finished=t("./lib/internal/streams/end-of-stream.js"),l.pipeline=t("./lib/internal/streams/pipeline.js")},{"./lib/_stream_duplex.js":56,"./lib/_stream_passthrough.js":57,"./lib/_stream_readable.js":58,"./lib/_stream_transform.js":59,"./lib/_stream_writable.js":60,"./lib/internal/streams/end-of-stream.js":64,"./lib/internal/streams/pipeline.js":66}],70:[function(t,n,l){n.exports=function(){if(typeof arguments[0]!="function")throw new Error("callback needed");if(typeof arguments[1]!="number")throw new Error("interval needed");var a;if(arguments.length>0){a=new Array(arguments.length-2);for(var o=0;o<a.length;o++)a[o]=arguments[o+2]}return new function(u,p,s){var i=this;this._callback=u,this._args=s,this._interval=setInterval(u,p,this._args),this.reschedule=function(d){d||(d=i._interval),i._interval&&clearInterval(i._interval),i._interval=setInterval(i._callback,d,i._args)},this.clear=function(){i._interval&&(clearInterval(i._interval),i._interval=void 0)},this.destroy=function(){i._interval&&clearInterval(i._interval),i._callback=void 0,i._interval=void 0,i._args=void 0}}(arguments[0],arguments[1],a)}},{}],71:[function(t,n,l){n.exports=t("./index.js")()},{"./index.js":72}],72:[function(t,n,l){(function(a){(function(){function o(u){return u instanceof a?a.from(u):new u.constructor(u.buffer.slice(),u.byteOffset,u.length)}n.exports=function(u){return(u=u||{}).circles?function(s){var i=[],d=[];return s.proto?function f(h){if(typeof h!="object"||h===null)return h;if(h instanceof Date)return new Date(h);if(Array.isArray(h))return c(h,f);if(h instanceof Map)return new Map(c(Array.from(h),f));if(h instanceof Set)return new Set(c(Array.from(h),f));var v={};for(var m in i.push(h),d.push(v),h){var g=h[m];if(typeof g!="object"||g===null)v[m]=g;else if(g instanceof Date)v[m]=new Date(g);else if(g instanceof Map)v[m]=new Map(c(Array.from(g),f));else if(g instanceof Set)v[m]=new Set(c(Array.from(g),f));else if(ArrayBuffer.isView(g))v[m]=o(g);else{var x=i.indexOf(g);v[m]=x!==-1?d[x]:f(g)}}return i.pop(),d.pop(),v}:function f(h){if(typeof h!="object"||h===null)return h;if(h instanceof Date)return new Date(h);if(Array.isArray(h))return c(h,f);if(h instanceof Map)return new Map(c(Array.from(h),f));if(h instanceof Set)return new Set(c(Array.from(h),f));var v={};for(var m in i.push(h),d.push(v),h)if(Object.hasOwnProperty.call(h,m)!==!1){var g=h[m];if(typeof g!="object"||g===null)v[m]=g;else if(g instanceof Date)v[m]=new Date(g);else if(g instanceof Map)v[m]=new Map(c(Array.from(g),f));else if(g instanceof Set)v[m]=new Set(c(Array.from(g),f));else if(ArrayBuffer.isView(g))v[m]=o(g);else{var x=i.indexOf(g);v[m]=x!==-1?d[x]:f(g)}}return i.pop(),d.pop(),v};function c(f,h){for(var v=Object.keys(f),m=new Array(v.length),g=0;g<v.length;g++){var x=v[g],y=f[x];if(typeof y!="object"||y===null)m[x]=y;else if(y instanceof Date)m[x]=new Date(y);else if(ArrayBuffer.isView(y))m[x]=o(y);else{var w=i.indexOf(y);m[x]=w!==-1?d[w]:h(y)}}return m}}(u):u.proto?function s(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return p(i,s);if(i instanceof Map)return new Map(p(Array.from(i),s));if(i instanceof Set)return new Set(p(Array.from(i),s));var d={};for(var c in i){var f=i[c];typeof f!="object"||f===null?d[c]=f:f instanceof Date?d[c]=new Date(f):f instanceof Map?d[c]=new Map(p(Array.from(f),s)):f instanceof Set?d[c]=new Set(p(Array.from(f),s)):ArrayBuffer.isView(f)?d[c]=o(f):d[c]=s(f)}return d}:function s(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return p(i,s);if(i instanceof Map)return new Map(p(Array.from(i),s));if(i instanceof Set)return new Set(p(Array.from(i),s));var d={};for(var c in i)if(Object.hasOwnProperty.call(i,c)!==!1){var f=i[c];typeof f!="object"||f===null?d[c]=f:f instanceof Date?d[c]=new Date(f):f instanceof Map?d[c]=new Map(p(Array.from(f),s)):f instanceof Set?d[c]=new Set(p(Array.from(f),s)):ArrayBuffer.isView(f)?d[c]=o(f):d[c]=s(f)}return d};function p(s,i){for(var d=Object.keys(s),c=new Array(d.length),f=0;f<d.length;f++){var h=d[f],v=s[h];typeof v!="object"||v===null?c[h]=v:v instanceof Date?c[h]=new Date(v):ArrayBuffer.isView(v)?c[h]=o(v):c[h]=i(v)}return c}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:17}],73:[function(t,n,l){var a=t("buffer"),o=a.Buffer;function u(s,i){for(var d in s)i[d]=s[d]}function p(s,i,d){return o(s,i,d)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?n.exports=a:(u(a,l),l.Buffer=p),p.prototype=Object.create(o.prototype),u(o,p),p.from=function(s,i,d){if(typeof s=="number")throw new TypeError("Argument must not be a number");return o(s,i,d)},p.alloc=function(s,i,d){if(typeof s!="number")throw new TypeError("Argument must be a number");var c=o(s);return i!==void 0?typeof d=="string"?c.fill(i,d):c.fill(i):c.fill(0),c},p.allocUnsafe=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return o(s)},p.allocUnsafeSlow=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return a.SlowBuffer(s)}},{buffer:17}],74:[function(t,n,l){n.exports=function(a){var o=a._readableState;return o?o.objectMode||typeof a._duplexState=="number"?a.read():a.read((u=o,u.buffer.length?u.buffer.head?u.buffer.head.data.length:u.buffer[0].length:u.length)):null;var u}},{}],75:[function(t,n,l){var a=t("safe-buffer").Buffer,o=a.isEncoding||function(m){switch((m=""+m)&&m.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function u(m){var g;switch(this.encoding=function(x){var y=function(w){if(!w)return"utf8";for(var k;;)switch(w){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return w;default:if(k)return;w=(""+w).toLowerCase(),k=!0}}(x);if(typeof y!="string"&&(a.isEncoding===o||!o(x)))throw new Error("Unknown encoding: "+x);return y||x}(m),this.encoding){case"utf16le":this.text=i,this.end=d,g=4;break;case"utf8":this.fillLast=s,g=4;break;case"base64":this.text=c,this.end=f,g=3;break;default:return this.write=h,void(this.end=v)}this.lastNeed=0,this.lastTotal=0,this.lastChar=a.allocUnsafe(g)}function p(m){return m<=127?0:m>>5==6?2:m>>4==14?3:m>>3==30?4:m>>6==2?-1:-2}function s(m){var g=this.lastTotal-this.lastNeed,x=function(y,w,k){if((192&w[0])!=128)return y.lastNeed=0,"�";if(y.lastNeed>1&&w.length>1){if((192&w[1])!=128)return y.lastNeed=1,"�";if(y.lastNeed>2&&w.length>2&&(192&w[2])!=128)return y.lastNeed=2,"�"}}(this,m);return x!==void 0?x:this.lastNeed<=m.length?(m.copy(this.lastChar,g,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(m.copy(this.lastChar,g,0,m.length),void(this.lastNeed-=m.length))}function i(m,g){if((m.length-g)%2==0){var x=m.toString("utf16le",g);if(x){var y=x.charCodeAt(x.length-1);if(y>=55296&&y<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=m[m.length-2],this.lastChar[1]=m[m.length-1],x.slice(0,-1)}return x}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=m[m.length-1],m.toString("utf16le",g,m.length-1)}function d(m){var g=m&&m.length?this.write(m):"";if(this.lastNeed){var x=this.lastTotal-this.lastNeed;return g+this.lastChar.toString("utf16le",0,x)}return g}function c(m,g){var x=(m.length-g)%3;return x===0?m.toString("base64",g):(this.lastNeed=3-x,this.lastTotal=3,x===1?this.lastChar[0]=m[m.length-1]:(this.lastChar[0]=m[m.length-2],this.lastChar[1]=m[m.length-1]),m.toString("base64",g,m.length-x))}function f(m){var g=m&&m.length?this.write(m):"";return this.lastNeed?g+this.lastChar.toString("base64",0,3-this.lastNeed):g}function h(m){return m.toString(this.encoding)}function v(m){return m&&m.length?this.write(m):""}l.StringDecoder=u,u.prototype.write=function(m){if(m.length===0)return"";var g,x;if(this.lastNeed){if((g=this.fillLast(m))===void 0)return"";x=this.lastNeed,this.lastNeed=0}else x=0;return x<m.length?g?g+this.text(m,x):this.text(m,x):g||""},u.prototype.end=function(m){var g=m&&m.length?this.write(m):"";return this.lastNeed?g+"�":g},u.prototype.text=function(m,g){var x=function(w,k,T){var I=k.length-1;if(I<T)return 0;var D=p(k[I]);return D>=0?(D>0&&(w.lastNeed=D-1),D):--I<T||D===-2?0:(D=p(k[I]))>=0?(D>0&&(w.lastNeed=D-2),D):--I<T||D===-2?0:(D=p(k[I]))>=0?(D>0&&(D===2?D=0:w.lastNeed=D-3),D):0}(this,m,g);if(!this.lastNeed)return m.toString("utf8",g);this.lastTotal=x;var y=m.length-(x-this.lastNeed);return m.copy(this.lastChar,0,y),m.toString("utf8",g,y)},u.prototype.fillLast=function(m){if(this.lastNeed<=m.length)return m.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);m.copy(this.lastChar,this.lastTotal-this.lastNeed,0,m.length),this.lastNeed-=m.length}},{"safe-buffer":73}],76:[function(t,n,l){var a=t("punycode"),o=t("./util");function u(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}l.parse=k,l.resolve=function(T,I){return k(T,!1,!0).resolve(I)},l.resolveObject=function(T,I){return T?k(T,!1,!0).resolveObject(I):I},l.format=function(T){return o.isString(T)&&(T=k(T)),T instanceof u?T.format():u.prototype.format.call(T)},l.Url=u;var p=/^([a-z0-9.+-]+:)/i,s=/:[0-9]*$/,i=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,d=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r",`
40
- `," "]),c=["'"].concat(d),f=["%","/","?",";","#"].concat(c),h=["/","?","#"],v=/^[+a-z0-9A-Z_-]{0,63}$/,m=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,g={javascript:!0,"javascript:":!0},x={javascript:!0,"javascript:":!0},y={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},w=t("querystring");function k(T,I,D){if(T&&o.isObject(T)&&T instanceof u)return T;var X=new u;return X.parse(T,I,D),X}u.prototype.parse=function(T,I,D){if(!o.isString(T))throw new TypeError("Parameter 'url' must be a string, not "+typeof T);var X=T.indexOf("?"),V=X!==-1&&X<T.indexOf("#")?"?":"#",E=T.split(V);E[0]=E[0].replace(/\\/g,"/");var A=T=E.join(V);if(A=A.trim(),!D&&T.split("#").length===1){var C=i.exec(A);if(C)return this.path=A,this.href=A,this.pathname=C[1],C[2]?(this.search=C[2],this.query=I?w.parse(this.search.substr(1)):this.search.substr(1)):I&&(this.search="",this.query={}),this}var F=p.exec(A);if(F){var j=(F=F[0]).toLowerCase();this.protocol=j,A=A.substr(F.length)}if(D||F||A.match(/^\/\/[^@\/]+@[^@\/]+/)){var P=A.substr(0,2)==="//";!P||F&&x[F]||(A=A.substr(2),this.slashes=!0)}if(!x[F]&&(P||F&&!y[F])){for(var J,$,U=-1,K=0;K<h.length;K++)(L=A.indexOf(h[K]))!==-1&&(U===-1||L<U)&&(U=L);for(($=U===-1?A.lastIndexOf("@"):A.lastIndexOf("@",U))!==-1&&(J=A.slice(0,$),A=A.slice($+1),this.auth=decodeURIComponent(J)),U=-1,K=0;K<f.length;K++){var L;(L=A.indexOf(f[K]))!==-1&&(U===-1||L<U)&&(U=L)}U===-1&&(U=A.length),this.host=A.slice(0,U),A=A.slice(U),this.parseHost(),this.hostname=this.hostname||"";var O=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!O)for(var H=this.hostname.split(/\./),W=(K=0,H.length);K<W;K++){var Z=H[K];if(Z&&!Z.match(v)){for(var re="",oe=0,ae=Z.length;oe<ae;oe++)Z.charCodeAt(oe)>127?re+="x":re+=Z[oe];if(!re.match(v)){var b=H.slice(0,K),_=H.slice(K+1),R=Z.match(m);R&&(b.push(R[1]),_.unshift(R[2])),_.length&&(A="/"+_.join(".")+A),this.hostname=b.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),O||(this.hostname=a.toASCII(this.hostname));var G=this.port?":"+this.port:"",ee=this.hostname||"";this.host=ee+G,this.href+=this.host,O&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),A[0]!=="/"&&(A="/"+A))}if(!g[j])for(K=0,W=c.length;K<W;K++){var te=c[K];if(A.indexOf(te)!==-1){var se=encodeURIComponent(te);se===te&&(se=escape(te)),A=A.split(te).join(se)}}var z=A.indexOf("#");z!==-1&&(this.hash=A.substr(z),A=A.slice(0,z));var S=A.indexOf("?");if(S!==-1?(this.search=A.substr(S),this.query=A.substr(S+1),I&&(this.query=w.parse(this.query)),A=A.slice(0,S)):I&&(this.search="",this.query={}),A&&(this.pathname=A),y[j]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){G=this.pathname||"";var B=this.search||"";this.path=G+B}return this.href=this.format(),this},u.prototype.format=function(){var T=this.auth||"";T&&(T=(T=encodeURIComponent(T)).replace(/%3A/i,":"),T+="@");var I=this.protocol||"",D=this.pathname||"",X=this.hash||"",V=!1,E="";this.host?V=T+this.host:this.hostname&&(V=T+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(V+=":"+this.port)),this.query&&o.isObject(this.query)&&Object.keys(this.query).length&&(E=w.stringify(this.query));var A=this.search||E&&"?"+E||"";return I&&I.substr(-1)!==":"&&(I+=":"),this.slashes||(!I||y[I])&&V!==!1?(V="//"+(V||""),D&&D.charAt(0)!=="/"&&(D="/"+D)):V||(V=""),X&&X.charAt(0)!=="#"&&(X="#"+X),A&&A.charAt(0)!=="?"&&(A="?"+A),I+V+(D=D.replace(/[?#]/g,function(C){return encodeURIComponent(C)}))+(A=A.replace("#","%23"))+X},u.prototype.resolve=function(T){return this.resolveObject(k(T,!1,!0)).format()},u.prototype.resolveObject=function(T){if(o.isString(T)){var I=new u;I.parse(T,!1,!0),T=I}for(var D=new u,X=Object.keys(this),V=0;V<X.length;V++){var E=X[V];D[E]=this[E]}if(D.hash=T.hash,T.href==="")return D.href=D.format(),D;if(T.slashes&&!T.protocol){for(var A=Object.keys(T),C=0;C<A.length;C++){var F=A[C];F!=="protocol"&&(D[F]=T[F])}return y[D.protocol]&&D.hostname&&!D.pathname&&(D.path=D.pathname="/"),D.href=D.format(),D}if(T.protocol&&T.protocol!==D.protocol){if(!y[T.protocol]){for(var j=Object.keys(T),P=0;P<j.length;P++){var J=j[P];D[J]=T[J]}return D.href=D.format(),D}if(D.protocol=T.protocol,T.host||x[T.protocol])D.pathname=T.pathname;else{for(var $=(T.pathname||"").split("/");$.length&&!(T.host=$.shift()););T.host||(T.host=""),T.hostname||(T.hostname=""),$[0]!==""&&$.unshift(""),$.length<2&&$.unshift(""),D.pathname=$.join("/")}if(D.search=T.search,D.query=T.query,D.host=T.host||"",D.auth=T.auth,D.hostname=T.hostname||T.host,D.port=T.port,D.pathname||D.search){var U=D.pathname||"",K=D.search||"";D.path=U+K}return D.slashes=D.slashes||T.slashes,D.href=D.format(),D}var L=D.pathname&&D.pathname.charAt(0)==="/",O=T.host||T.pathname&&T.pathname.charAt(0)==="/",H=O||L||D.host&&T.pathname,W=H,Z=D.pathname&&D.pathname.split("/")||[],re=($=T.pathname&&T.pathname.split("/")||[],D.protocol&&!y[D.protocol]);if(re&&(D.hostname="",D.port=null,D.host&&(Z[0]===""?Z[0]=D.host:Z.unshift(D.host)),D.host="",T.protocol&&(T.hostname=null,T.port=null,T.host&&($[0]===""?$[0]=T.host:$.unshift(T.host)),T.host=null),H=H&&($[0]===""||Z[0]==="")),O)D.host=T.host||T.host===""?T.host:D.host,D.hostname=T.hostname||T.hostname===""?T.hostname:D.hostname,D.search=T.search,D.query=T.query,Z=$;else if($.length)Z||(Z=[]),Z.pop(),Z=Z.concat($),D.search=T.search,D.query=T.query;else if(!o.isNullOrUndefined(T.search))return re&&(D.hostname=D.host=Z.shift(),(R=!!(D.host&&D.host.indexOf("@")>0)&&D.host.split("@"))&&(D.auth=R.shift(),D.host=D.hostname=R.shift())),D.search=T.search,D.query=T.query,o.isNull(D.pathname)&&o.isNull(D.search)||(D.path=(D.pathname?D.pathname:"")+(D.search?D.search:"")),D.href=D.format(),D;if(!Z.length)return D.pathname=null,D.search?D.path="/"+D.search:D.path=null,D.href=D.format(),D;for(var oe=Z.slice(-1)[0],ae=(D.host||T.host||Z.length>1)&&(oe==="."||oe==="..")||oe==="",b=0,_=Z.length;_>=0;_--)(oe=Z[_])==="."?Z.splice(_,1):oe===".."?(Z.splice(_,1),b++):b&&(Z.splice(_,1),b--);if(!H&&!W)for(;b--;b)Z.unshift("..");!H||Z[0]===""||Z[0]&&Z[0].charAt(0)==="/"||Z.unshift(""),ae&&Z.join("/").substr(-1)!=="/"&&Z.push("");var R,G=Z[0]===""||Z[0]&&Z[0].charAt(0)==="/";return re&&(D.hostname=D.host=G?"":Z.length?Z.shift():"",(R=!!(D.host&&D.host.indexOf("@")>0)&&D.host.split("@"))&&(D.auth=R.shift(),D.host=D.hostname=R.shift())),(H=H||D.host&&Z.length)&&!G&&Z.unshift(""),Z.length?D.pathname=Z.join("/"):(D.pathname=null,D.path=null),o.isNull(D.pathname)&&o.isNull(D.search)||(D.path=(D.pathname?D.pathname:"")+(D.search?D.search:"")),D.auth=T.auth||D.auth,D.slashes=D.slashes||T.slashes,D.href=D.format(),D},u.prototype.parseHost=function(){var T=this.host,I=s.exec(T);I&&((I=I[0])!==":"&&(this.port=I.substr(1)),T=T.substr(0,T.length-I.length)),T&&(this.hostname=T)}},{"./util":77,punycode:51,querystring:54}],77:[function(t,n,l){n.exports={isString:function(a){return typeof a=="string"},isObject:function(a){return typeof a=="object"&&a!==null},isNull:function(a){return a===null},isNullOrUndefined:function(a){return a==null}}},{}],78:[function(t,n,l){(function(a){(function(){function o(u){try{if(!a.localStorage)return!1}catch(s){return!1}var p=a.localStorage[u];return p!=null&&String(p).toLowerCase()==="true"}n.exports=function(u,p){if(o("noDeprecation"))return u;var s=!1;return function(){if(!s){if(o("throwDeprecation"))throw new Error(p);o("traceDeprecation")?console.trace(p):console.warn(p),s=!0}return u.apply(this,arguments)}}}).call(this)}).call(this,typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],79:[function(t,n,l){n.exports=function a(o,u){if(o&&u)return a(o)(u);if(typeof o!="function")throw new TypeError("need wrapper function");return Object.keys(o).forEach(function(s){p[s]=o[s]}),p;function p(){for(var s=new Array(arguments.length),i=0;i<s.length;i++)s[i]=arguments[i];var d=o.apply(this,s),c=s[s.length-1];return typeof d=="function"&&d!==c&&Object.keys(c).forEach(function(f){d[f]=c[f]}),d}}},{}],80:[function(t,n,l){n.exports=function(){throw new Error("ws does not work in the browser. Browser clients must use the native WebSocket object")}},{}],81:[function(t,n,l){n.exports=function(){for(var o={},u=0;u<arguments.length;u++){var p=arguments[u];for(var s in p)a.call(p,s)&&(o[s]=p[s])}return o};var a=Object.prototype.hasOwnProperty},{}],82:[function(t,n,l){n.exports=function(a){a.prototype[Symbol.iterator]=function*(){for(let o=this.head;o;o=o.next)yield o.value}}},{}],83:[function(t,n,l){function a(i){var d=this;if(d instanceof a||(d=new a),d.tail=null,d.head=null,d.length=0,i&&typeof i.forEach=="function")i.forEach(function(h){d.push(h)});else if(arguments.length>0)for(var c=0,f=arguments.length;c<f;c++)d.push(arguments[c]);return d}function o(i,d,c){var f=d===i.head?new s(c,null,d,i):new s(c,d,d.next,i);return f.next===null&&(i.tail=f),f.prev===null&&(i.head=f),i.length++,f}function u(i,d){i.tail=new s(d,i.tail,null,i),i.head||(i.head=i.tail),i.length++}function p(i,d){i.head=new s(d,null,i.head,i),i.tail||(i.tail=i.head),i.length++}function s(i,d,c,f){if(!(this instanceof s))return new s(i,d,c,f);this.list=f,this.value=i,d?(d.next=this,this.prev=d):this.prev=null,c?(c.prev=this,this.next=c):this.next=null}n.exports=a,a.Node=s,a.create=a,a.prototype.removeNode=function(i){if(i.list!==this)throw new Error("removing node which does not belong to this list");var d=i.next,c=i.prev;return d&&(d.prev=c),c&&(c.next=d),i===this.head&&(this.head=d),i===this.tail&&(this.tail=c),i.list.length--,i.next=null,i.prev=null,i.list=null,d},a.prototype.unshiftNode=function(i){if(i!==this.head){i.list&&i.list.removeNode(i);var d=this.head;i.list=this,i.next=d,d&&(d.prev=i),this.head=i,this.tail||(this.tail=i),this.length++}},a.prototype.pushNode=function(i){if(i!==this.tail){i.list&&i.list.removeNode(i);var d=this.tail;i.list=this,i.prev=d,d&&(d.next=i),this.tail=i,this.head||(this.head=i),this.length++}},a.prototype.push=function(){for(var i=0,d=arguments.length;i<d;i++)u(this,arguments[i]);return this.length},a.prototype.unshift=function(){for(var i=0,d=arguments.length;i<d;i++)p(this,arguments[i]);return this.length},a.prototype.pop=function(){if(this.tail){var i=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,i}},a.prototype.shift=function(){if(this.head){var i=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,i}},a.prototype.forEach=function(i,d){d=d||this;for(var c=this.head,f=0;c!==null;f++)i.call(d,c.value,f,this),c=c.next},a.prototype.forEachReverse=function(i,d){d=d||this;for(var c=this.tail,f=this.length-1;c!==null;f--)i.call(d,c.value,f,this),c=c.prev},a.prototype.get=function(i){for(var d=0,c=this.head;c!==null&&d<i;d++)c=c.next;if(d===i&&c!==null)return c.value},a.prototype.getReverse=function(i){for(var d=0,c=this.tail;c!==null&&d<i;d++)c=c.prev;if(d===i&&c!==null)return c.value},a.prototype.map=function(i,d){d=d||this;for(var c=new a,f=this.head;f!==null;)c.push(i.call(d,f.value,this)),f=f.next;return c},a.prototype.mapReverse=function(i,d){d=d||this;for(var c=new a,f=this.tail;f!==null;)c.push(i.call(d,f.value,this)),f=f.prev;return c},a.prototype.reduce=function(i,d){var c,f=this.head;if(arguments.length>1)c=d;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");f=this.head.next,c=this.head.value}for(var h=0;f!==null;h++)c=i(c,f.value,h),f=f.next;return c},a.prototype.reduceReverse=function(i,d){var c,f=this.tail;if(arguments.length>1)c=d;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");f=this.tail.prev,c=this.tail.value}for(var h=this.length-1;f!==null;h--)c=i(c,f.value,h),f=f.prev;return c},a.prototype.toArray=function(){for(var i=new Array(this.length),d=0,c=this.head;c!==null;d++)i[d]=c.value,c=c.next;return i},a.prototype.toArrayReverse=function(){for(var i=new Array(this.length),d=0,c=this.tail;c!==null;d++)i[d]=c.value,c=c.prev;return i},a.prototype.slice=function(i,d){(d=d||this.length)<0&&(d+=this.length),(i=i||0)<0&&(i+=this.length);var c=new a;if(d<i||d<0)return c;i<0&&(i=0),d>this.length&&(d=this.length);for(var f=0,h=this.head;h!==null&&f<i;f++)h=h.next;for(;h!==null&&f<d;f++,h=h.next)c.push(h.value);return c},a.prototype.sliceReverse=function(i,d){(d=d||this.length)<0&&(d+=this.length),(i=i||0)<0&&(i+=this.length);var c=new a;if(d<i||d<0)return c;i<0&&(i=0),d>this.length&&(d=this.length);for(var f=this.length,h=this.tail;h!==null&&f>d;f--)h=h.prev;for(;h!==null&&f>i;f--,h=h.prev)c.push(h.value);return c},a.prototype.splice=function(i,d,...c){i>this.length&&(i=this.length-1),i<0&&(i=this.length+i);for(var f=0,h=this.head;h!==null&&f<i;f++)h=h.next;var v=[];for(f=0;h&&f<d;f++)v.push(h.value),h=this.removeNode(h);for(h===null&&(h=this.tail),h!==this.head&&h!==this.tail&&(h=h.prev),f=0;f<c.length;f++)h=o(this,h,c[f]);return v},a.prototype.reverse=function(){for(var i=this.head,d=this.tail,c=i;c!==null;c=c.prev){var f=c.prev;c.prev=c.next,c.next=f}return this.head=d,this.tail=i,this};try{t("./iterator.js")(a)}catch(i){}},{"./iterator.js":82}]},{},[12])(12)})})(Qy);function Yy(e,r){var o,u;let t=r.payload.topicName,n=r.payload.message,l=r.payload.notifyTime,a=`<div style="padding:0px 12px 0px 0px;width:300px;">
39
+ `)},{immediate:!0})},Nv=(e,r)=>{Pv({from:"type.text",replacement:"link",version:"3.0.0",scope:"props",ref:"https://element-plus.org/en-US/component/button.html#button-attributes"},N.computed(()=>e.type==="text"));const t=N.inject(I0,void 0),n=ya("button"),{form:l}=Bv(),a=kv(N.computed(()=>t==null?void 0:t.size)),o=T0(),u=N.ref(),p=N.useSlots(),s=N.computed(()=>{var g;return e.type||(t==null?void 0:t.type)||((g=n.value)==null?void 0:g.type)||""}),i=N.computed(()=>{var g,x,y;return(y=(x=e.autoInsertSpace)!=null?x:(g=n.value)==null?void 0:g.autoInsertSpace)!=null?y:!1}),d=N.computed(()=>{var g,x,y;return(y=(x=e.plain)!=null?x:(g=n.value)==null?void 0:g.plain)!=null?y:!1}),c=N.computed(()=>{var g,x,y;return(y=(x=e.round)!=null?x:(g=n.value)==null?void 0:g.round)!=null?y:!1}),f=N.computed(()=>{var g,x,y;return(y=(x=e.text)!=null?x:(g=n.value)==null?void 0:g.text)!=null?y:!1}),h=N.computed(()=>e.tag==="button"?{ariaDisabled:o.value||e.loading,disabled:o.value||e.loading,autofocus:e.autofocus,type:e.nativeType}:{}),v=N.computed(()=>{var g;const x=(g=p.default)==null?void 0:g.call(p);if(i.value&&(x==null?void 0:x.length)===1){const y=x[0];if((y==null?void 0:y.type)===N.Text){const w=y.children;return new RegExp("^\\p{Unified_Ideograph}{2}$","u").test(w.trim())}}return!1});return{_disabled:o,_size:a,_type:s,_ref:u,_props:h,_plain:d,_round:c,_text:f,shouldAddSpace:v,handleClick:g=>{if(o.value||e.loading){g.stopPropagation();return}e.nativeType==="reset"&&(l==null||l.resetFields()),r("click",g)}}},Mv=["default","primary","success","warning","info","danger","text",""],Lv=["button","submit","reset"],Qo=ir({size:b0,disabled:{type:Boolean,default:void 0},type:{type:String,values:Mv,default:""},icon:{type:jr},nativeType:{type:String,values:Lv,default:"button"},loading:Boolean,loadingIcon:{type:jr,default:()=>S0},plain:{type:Boolean,default:void 0},text:{type:Boolean,default:void 0},link:Boolean,bg:Boolean,autofocus:Boolean,round:{type:Boolean,default:void 0},circle:Boolean,color:String,dark:Boolean,autoInsertSpace:{type:Boolean,default:void 0},tag:{type:Me([String,Object]),default:"button"}}),Uv={click:e=>e instanceof MouseEvent};function He(e,r){qv(e)&&(e="100%");var t=$v(e);return e=r===360?e:Math.min(r,Math.max(0,parseFloat(e))),t&&(e=parseInt(String(e*r),10)/100),Math.abs(e-r)<1e-6?1:(r===360?e=(e<0?e%r+r:e%r)/parseFloat(String(r)):e=e%r/parseFloat(String(r)),e)}function En(e){return Math.min(1,Math.max(0,e))}function qv(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function $v(e){return typeof e=="string"&&e.indexOf("%")!==-1}function D0(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function An(e){return e<=1?"".concat(Number(e)*100,"%"):e}function Kt(e){return e.length===1?"0"+e:String(e)}function zv(e,r,t){return{r:He(e,255)*255,g:He(r,255)*255,b:He(t,255)*255}}function Bl(e,r,t){e=He(e,255),r=He(r,255),t=He(t,255);var n=Math.max(e,r,t),l=Math.min(e,r,t),a=0,o=0,u=(n+l)/2;if(n===l)o=0,a=0;else{var p=n-l;switch(o=u>.5?p/(2-n-l):p/(n+l),n){case e:a=(r-t)/p+(r<t?6:0);break;case r:a=(t-e)/p+2;break;case t:a=(e-r)/p+4;break}a/=6}return{h:a,s:o,l:u}}function Fo(e,r,t){return t<0&&(t+=1),t>1&&(t-=1),t<1/6?e+(r-e)*(6*t):t<1/2?r:t<2/3?e+(r-e)*(2/3-t)*6:e}function jv(e,r,t){var n,l,a;if(e=He(e,360),r=He(r,100),t=He(t,100),r===0)l=t,a=t,n=t;else{var o=t<.5?t*(1+r):t+r-t*r,u=2*t-o;n=Fo(u,o,e+1/3),l=Fo(u,o,e),a=Fo(u,o,e-1/3)}return{r:n*255,g:l*255,b:a*255}}function kl(e,r,t){e=He(e,255),r=He(r,255),t=He(t,255);var n=Math.max(e,r,t),l=Math.min(e,r,t),a=0,o=n,u=n-l,p=n===0?0:u/n;if(n===l)a=0;else{switch(n){case e:a=(r-t)/u+(r<t?6:0);break;case r:a=(t-e)/u+2;break;case t:a=(e-r)/u+4;break}a/=6}return{h:a,s:p,v:o}}function Hv(e,r,t){e=He(e,360)*6,r=He(r,100),t=He(t,100);var n=Math.floor(e),l=e-n,a=t*(1-r),o=t*(1-l*r),u=t*(1-(1-l)*r),p=n%6,s=[t,o,a,a,u,t][p],i=[u,t,t,o,a,a][p],d=[a,a,u,t,t,o][p];return{r:s*255,g:i*255,b:d*255}}function Tl(e,r,t,n){var l=[Kt(Math.round(e).toString(16)),Kt(Math.round(r).toString(16)),Kt(Math.round(t).toString(16))];return n&&l[0].startsWith(l[0].charAt(1))&&l[1].startsWith(l[1].charAt(1))&&l[2].startsWith(l[2].charAt(1))?l[0].charAt(0)+l[1].charAt(0)+l[2].charAt(0):l.join("")}function Vv(e,r,t,n,l){var a=[Kt(Math.round(e).toString(16)),Kt(Math.round(r).toString(16)),Kt(Math.round(t).toString(16)),Kt(Wv(n))];return l&&a[0].startsWith(a[0].charAt(1))&&a[1].startsWith(a[1].charAt(1))&&a[2].startsWith(a[2].charAt(1))&&a[3].startsWith(a[3].charAt(1))?a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0)+a[3].charAt(0):a.join("")}function Wv(e){return Math.round(parseFloat(e)*255).toString(16)}function Fl(e){return rt(e)/255}function rt(e){return parseInt(e,16)}function Kv(e){return{r:e>>16,g:(e&65280)>>8,b:e&255}}var Yo={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function Gv(e){var r={r:0,g:0,b:0},t=1,n=null,l=null,a=null,o=!1,u=!1;return typeof e=="string"&&(e=Xv(e)),typeof e=="object"&&(At(e.r)&&At(e.g)&&At(e.b)?(r=zv(e.r,e.g,e.b),o=!0,u=String(e.r).substr(-1)==="%"?"prgb":"rgb"):At(e.h)&&At(e.s)&&At(e.v)?(n=An(e.s),l=An(e.v),r=Hv(e.h,n,l),o=!0,u="hsv"):At(e.h)&&At(e.s)&&At(e.l)&&(n=An(e.s),a=An(e.l),r=jv(e.h,n,a),o=!0,u="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(t=e.a)),t=D0(t),{ok:o,format:e.format||u,r:Math.min(255,Math.max(r.r,0)),g:Math.min(255,Math.max(r.g,0)),b:Math.min(255,Math.max(r.b,0)),a:t}}var Qv="[-\\+]?\\d+%?",Yv="[-\\+]?\\d*\\.\\d+%?",Ot="(?:".concat(Yv,")|(?:").concat(Qv,")"),Io="[\\s|\\(]+(".concat(Ot,")[,|\\s]+(").concat(Ot,")[,|\\s]+(").concat(Ot,")\\s*\\)?"),Do="[\\s|\\(]+(".concat(Ot,")[,|\\s]+(").concat(Ot,")[,|\\s]+(").concat(Ot,")[,|\\s]+(").concat(Ot,")\\s*\\)?"),ft={CSS_UNIT:new RegExp(Ot),rgb:new RegExp("rgb"+Io),rgba:new RegExp("rgba"+Do),hsl:new RegExp("hsl"+Io),hsla:new RegExp("hsla"+Do),hsv:new RegExp("hsv"+Io),hsva:new RegExp("hsva"+Do),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function Xv(e){if(e=e.trim().toLowerCase(),e.length===0)return!1;var r=!1;if(Yo[e])e=Yo[e],r=!0;else if(e==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var t=ft.rgb.exec(e);return t?{r:t[1],g:t[2],b:t[3]}:(t=ft.rgba.exec(e),t?{r:t[1],g:t[2],b:t[3],a:t[4]}:(t=ft.hsl.exec(e),t?{h:t[1],s:t[2],l:t[3]}:(t=ft.hsla.exec(e),t?{h:t[1],s:t[2],l:t[3],a:t[4]}:(t=ft.hsv.exec(e),t?{h:t[1],s:t[2],v:t[3]}:(t=ft.hsva.exec(e),t?{h:t[1],s:t[2],v:t[3],a:t[4]}:(t=ft.hex8.exec(e),t?{r:rt(t[1]),g:rt(t[2]),b:rt(t[3]),a:Fl(t[4]),format:r?"name":"hex8"}:(t=ft.hex6.exec(e),t?{r:rt(t[1]),g:rt(t[2]),b:rt(t[3]),format:r?"name":"hex"}:(t=ft.hex4.exec(e),t?{r:rt(t[1]+t[1]),g:rt(t[2]+t[2]),b:rt(t[3]+t[3]),a:Fl(t[4]+t[4]),format:r?"name":"hex8"}:(t=ft.hex3.exec(e),t?{r:rt(t[1]+t[1]),g:rt(t[2]+t[2]),b:rt(t[3]+t[3]),format:r?"name":"hex"}:!1)))))))))}function At(e){return!!ft.CSS_UNIT.exec(String(e))}var Zv=function(){function e(r,t){r===void 0&&(r=""),t===void 0&&(t={});var n;if(r instanceof e)return r;typeof r=="number"&&(r=Kv(r)),this.originalInput=r;var l=Gv(r);this.originalInput=r,this.r=l.r,this.g=l.g,this.b=l.b,this.a=l.a,this.roundA=Math.round(100*this.a)/100,this.format=(n=t.format)!==null&&n!==void 0?n:l.format,this.gradientType=t.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=l.ok}return e.prototype.isDark=function(){return this.getBrightness()<128},e.prototype.isLight=function(){return!this.isDark()},e.prototype.getBrightness=function(){var r=this.toRgb();return(r.r*299+r.g*587+r.b*114)/1e3},e.prototype.getLuminance=function(){var r=this.toRgb(),t,n,l,a=r.r/255,o=r.g/255,u=r.b/255;return a<=.03928?t=a/12.92:t=Math.pow((a+.055)/1.055,2.4),o<=.03928?n=o/12.92:n=Math.pow((o+.055)/1.055,2.4),u<=.03928?l=u/12.92:l=Math.pow((u+.055)/1.055,2.4),.2126*t+.7152*n+.0722*l},e.prototype.getAlpha=function(){return this.a},e.prototype.setAlpha=function(r){return this.a=D0(r),this.roundA=Math.round(100*this.a)/100,this},e.prototype.isMonochrome=function(){var r=this.toHsl().s;return r===0},e.prototype.toHsv=function(){var r=kl(this.r,this.g,this.b);return{h:r.h*360,s:r.s,v:r.v,a:this.a}},e.prototype.toHsvString=function(){var r=kl(this.r,this.g,this.b),t=Math.round(r.h*360),n=Math.round(r.s*100),l=Math.round(r.v*100);return this.a===1?"hsv(".concat(t,", ").concat(n,"%, ").concat(l,"%)"):"hsva(".concat(t,", ").concat(n,"%, ").concat(l,"%, ").concat(this.roundA,")")},e.prototype.toHsl=function(){var r=Bl(this.r,this.g,this.b);return{h:r.h*360,s:r.s,l:r.l,a:this.a}},e.prototype.toHslString=function(){var r=Bl(this.r,this.g,this.b),t=Math.round(r.h*360),n=Math.round(r.s*100),l=Math.round(r.l*100);return this.a===1?"hsl(".concat(t,", ").concat(n,"%, ").concat(l,"%)"):"hsla(".concat(t,", ").concat(n,"%, ").concat(l,"%, ").concat(this.roundA,")")},e.prototype.toHex=function(r){return r===void 0&&(r=!1),Tl(this.r,this.g,this.b,r)},e.prototype.toHexString=function(r){return r===void 0&&(r=!1),"#"+this.toHex(r)},e.prototype.toHex8=function(r){return r===void 0&&(r=!1),Vv(this.r,this.g,this.b,this.a,r)},e.prototype.toHex8String=function(r){return r===void 0&&(r=!1),"#"+this.toHex8(r)},e.prototype.toHexShortString=function(r){return r===void 0&&(r=!1),this.a===1?this.toHexString(r):this.toHex8String(r)},e.prototype.toRgb=function(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}},e.prototype.toRgbString=function(){var r=Math.round(this.r),t=Math.round(this.g),n=Math.round(this.b);return this.a===1?"rgb(".concat(r,", ").concat(t,", ").concat(n,")"):"rgba(".concat(r,", ").concat(t,", ").concat(n,", ").concat(this.roundA,")")},e.prototype.toPercentageRgb=function(){var r=function(t){return"".concat(Math.round(He(t,255)*100),"%")};return{r:r(this.r),g:r(this.g),b:r(this.b),a:this.a}},e.prototype.toPercentageRgbString=function(){var r=function(t){return Math.round(He(t,255)*100)};return this.a===1?"rgb(".concat(r(this.r),"%, ").concat(r(this.g),"%, ").concat(r(this.b),"%)"):"rgba(".concat(r(this.r),"%, ").concat(r(this.g),"%, ").concat(r(this.b),"%, ").concat(this.roundA,")")},e.prototype.toName=function(){if(this.a===0)return"transparent";if(this.a<1)return!1;for(var r="#"+Tl(this.r,this.g,this.b,!1),t=0,n=Object.entries(Yo);t<n.length;t++){var l=n[t],a=l[0],o=l[1];if(r===o)return a}return!1},e.prototype.toString=function(r){var t=!!r;r=r!=null?r:this.format;var n=!1,l=this.a<1&&this.a>=0,a=!t&&l&&(r.startsWith("hex")||r==="name");return a?r==="name"&&this.a===0?this.toName():this.toRgbString():(r==="rgb"&&(n=this.toRgbString()),r==="prgb"&&(n=this.toPercentageRgbString()),(r==="hex"||r==="hex6")&&(n=this.toHexString()),r==="hex3"&&(n=this.toHexString(!0)),r==="hex4"&&(n=this.toHex8String(!0)),r==="hex8"&&(n=this.toHex8String()),r==="name"&&(n=this.toName()),r==="hsl"&&(n=this.toHslString()),r==="hsv"&&(n=this.toHsvString()),n||this.toHexString())},e.prototype.toNumber=function(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)},e.prototype.clone=function(){return new e(this.toString())},e.prototype.lighten=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.l+=r/100,t.l=En(t.l),new e(t)},e.prototype.brighten=function(r){r===void 0&&(r=10);var t=this.toRgb();return t.r=Math.max(0,Math.min(255,t.r-Math.round(255*-(r/100)))),t.g=Math.max(0,Math.min(255,t.g-Math.round(255*-(r/100)))),t.b=Math.max(0,Math.min(255,t.b-Math.round(255*-(r/100)))),new e(t)},e.prototype.darken=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.l-=r/100,t.l=En(t.l),new e(t)},e.prototype.tint=function(r){return r===void 0&&(r=10),this.mix("white",r)},e.prototype.shade=function(r){return r===void 0&&(r=10),this.mix("black",r)},e.prototype.desaturate=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.s-=r/100,t.s=En(t.s),new e(t)},e.prototype.saturate=function(r){r===void 0&&(r=10);var t=this.toHsl();return t.s+=r/100,t.s=En(t.s),new e(t)},e.prototype.greyscale=function(){return this.desaturate(100)},e.prototype.spin=function(r){var t=this.toHsl(),n=(t.h+r)%360;return t.h=n<0?360+n:n,new e(t)},e.prototype.mix=function(r,t){t===void 0&&(t=50);var n=this.toRgb(),l=new e(r).toRgb(),a=t/100,o={r:(l.r-n.r)*a+n.r,g:(l.g-n.g)*a+n.g,b:(l.b-n.b)*a+n.b,a:(l.a-n.a)*a+n.a};return new e(o)},e.prototype.analogous=function(r,t){r===void 0&&(r=6),t===void 0&&(t=30);var n=this.toHsl(),l=360/t,a=[this];for(n.h=(n.h-(l*r>>1)+720)%360;--r;)n.h=(n.h+l)%360,a.push(new e(n));return a},e.prototype.complement=function(){var r=this.toHsl();return r.h=(r.h+180)%360,new e(r)},e.prototype.monochromatic=function(r){r===void 0&&(r=6);for(var t=this.toHsv(),n=t.h,l=t.s,a=t.v,o=[],u=1/r;r--;)o.push(new e({h:n,s:l,v:a})),a=(a+u)%1;return o},e.prototype.splitcomplement=function(){var r=this.toHsl(),t=r.h;return[this,new e({h:(t+72)%360,s:r.s,l:r.l}),new e({h:(t+216)%360,s:r.s,l:r.l})]},e.prototype.onBackground=function(r){var t=this.toRgb(),n=new e(r).toRgb(),l=t.a+n.a*(1-t.a);return new e({r:(t.r*t.a+n.r*n.a*(1-t.a))/l,g:(t.g*t.a+n.g*n.a*(1-t.a))/l,b:(t.b*t.a+n.b*n.a*(1-t.a))/l,a:l})},e.prototype.triad=function(){return this.polyad(3)},e.prototype.tetrad=function(){return this.polyad(4)},e.prototype.polyad=function(r){for(var t=this.toHsl(),n=t.h,l=[this],a=360/r,o=1;o<r;o++)l.push(new e({h:(n+o*a)%360,s:t.s,l:t.l}));return l},e.prototype.equals=function(r){return this.toRgbString()===new e(r).toRgbString()},e}();function Dt(e,r=20){return e.mix("#141414",r).toString()}function Jv(e){const r=T0(),t=Sr("button");return N.computed(()=>{let n={},l=e.color;if(l){const a=l.match(/var\((.*?)\)/);a&&(l=window.getComputedStyle(window.document.documentElement).getPropertyValue(a[1]));const o=new Zv(l),u=e.dark?o.tint(20).toString():Dt(o,20);if(e.plain)n=t.cssVarBlock({"bg-color":e.dark?Dt(o,90):o.tint(90).toString(),"text-color":l,"border-color":e.dark?Dt(o,50):o.tint(50).toString(),"hover-text-color":`var(${t.cssVarName("color-white")})`,"hover-bg-color":l,"hover-border-color":l,"active-bg-color":u,"active-text-color":`var(${t.cssVarName("color-white")})`,"active-border-color":u}),r.value&&(n[t.cssVarBlockName("disabled-bg-color")]=e.dark?Dt(o,90):o.tint(90).toString(),n[t.cssVarBlockName("disabled-text-color")]=e.dark?Dt(o,50):o.tint(50).toString(),n[t.cssVarBlockName("disabled-border-color")]=e.dark?Dt(o,80):o.tint(80).toString());else{const p=e.dark?Dt(o,30):o.tint(30).toString(),s=o.isDark()?`var(${t.cssVarName("color-white")})`:`var(${t.cssVarName("color-black")})`;if(n=t.cssVarBlock({"bg-color":l,"text-color":s,"border-color":l,"hover-bg-color":p,"hover-text-color":s,"hover-border-color":p,"active-bg-color":u,"active-border-color":u}),r.value){const i=e.dark?Dt(o,50):o.tint(50).toString();n[t.cssVarBlockName("disabled-bg-color")]=i,n[t.cssVarBlockName("disabled-text-color")]=e.dark?"rgba(255, 255, 255, 0.5)":`var(${t.cssVarName("color-white")})`,n[t.cssVarBlockName("disabled-border-color")]=i}}}return n})}const ey=N.defineComponent({name:"ElButton"}),ty=N.defineComponent(_e(he({},ey),{props:Qo,emits:Uv,setup(e,{expose:r,emit:t}){const n=e,l=Jv(n),a=Sr("button"),{_ref:o,_size:u,_type:p,_disabled:s,_props:i,_plain:d,_round:c,_text:f,shouldAddSpace:h,handleClick:v}=Nv(n,t),m=N.computed(()=>[a.b(),a.m(p.value),a.m(u.value),a.is("disabled",s.value),a.is("loading",n.loading),a.is("plain",d.value),a.is("round",c.value),a.is("circle",n.circle),a.is("text",f.value),a.is("link",n.link),a.is("has-bg",n.bg)]);return r({ref:o,size:u,type:p,disabled:s,shouldAddSpace:h}),(g,x)=>(N.openBlock(),N.createBlock(N.resolveDynamicComponent(g.tag),N.mergeProps({ref_key:"_ref",ref:o},N.unref(i),{class:N.unref(m),style:N.unref(l),onClick:N.unref(v)}),{default:N.withCtx(()=>[g.loading?(N.openBlock(),N.createElementBlock(N.Fragment,{key:0},[g.$slots.loading?N.renderSlot(g.$slots,"loading",{key:0}):(N.openBlock(),N.createBlock(N.unref(_r),{key:1,class:N.normalizeClass(N.unref(a).is("loading"))},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(g.loadingIcon)))]),_:1},8,["class"]))],64)):g.icon||g.$slots.icon?(N.openBlock(),N.createBlock(N.unref(_r),{key:1},{default:N.withCtx(()=>[g.icon?(N.openBlock(),N.createBlock(N.resolveDynamicComponent(g.icon),{key:0})):N.renderSlot(g.$slots,"icon",{key:1})]),_:3})):N.createCommentVNode("v-if",!0),g.$slots.default?(N.openBlock(),N.createElementBlock("span",{key:2,class:N.normalizeClass({[N.unref(a).em("text","expand")]:N.unref(h)})},[N.renderSlot(g.$slots,"default")],2)):N.createCommentVNode("v-if",!0)]),_:3},16,["class","style","onClick"]))}}));var ry=Br(ty,[["__file","button.vue"]]);const ny={size:Qo.size,type:Qo.type,direction:{type:Me(String),values:["horizontal","vertical"],default:"horizontal"}},iy=N.defineComponent({name:"ElButtonGroup"}),oy=N.defineComponent(_e(he({},iy),{props:ny,setup(e){const r=e;N.provide(I0,N.reactive({size:N.toRef(r,"size"),type:N.toRef(r,"type")}));const t=Sr("button");return(n,l)=>(N.openBlock(),N.createElementBlock("div",{class:N.normalizeClass([N.unref(t).b("group"),N.unref(t).bm("group",r.direction)])},[N.renderSlot(n.$slots,"default")],2))}}));var R0=Br(oy,[["__file","button-group.vue"]]);const ay=ga(ry,{ButtonGroup:R0});cv(R0);var O0={exports:{}};(function(e,r){(function(t,n){e.exports=n()})(xe,function(){var t=1e3,n=6e4,l=36e5,a="millisecond",o="second",u="minute",p="hour",s="day",i="week",d="month",c="quarter",f="year",h="date",v="Invalid Date",m=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,g=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,x={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(F){var j=["th","st","nd","rd"],P=F%100;return"["+F+(j[(P-20)%10]||j[P]||j[0])+"]"}},y=function(F,j,P){var J=String(F);return!J||J.length>=j?F:""+Array(j+1-J.length).join(P)+F},w={s:y,z:function(F){var j=-F.utcOffset(),P=Math.abs(j),J=Math.floor(P/60),$=P%60;return(j<=0?"+":"-")+y(J,2,"0")+":"+y($,2,"0")},m:function F(j,P){if(j.date()<P.date())return-F(P,j);var J=12*(P.year()-j.year())+(P.month()-j.month()),$=j.clone().add(J,d),U=P-$<0,K=j.clone().add(J+(U?-1:1),d);return+(-(J+(P-$)/(U?$-K:K-$))||0)},a:function(F){return F<0?Math.ceil(F)||0:Math.floor(F)},p:function(F){return{M:d,y:f,w:i,d:s,D:h,h:p,m:u,s:o,ms:a,Q:c}[F]||String(F||"").toLowerCase().replace(/s$/,"")},u:function(F){return F===void 0}},k="en",T={};T[k]=x;var I="$isDayjsObject",D=function(F){return F instanceof A||!(!F||!F[I])},X=function F(j,P,J){var $;if(!j)return k;if(typeof j=="string"){var U=j.toLowerCase();T[U]&&($=U),P&&(T[U]=P,$=U);var K=j.split("-");if(!$&&K.length>1)return F(K[0])}else{var L=j.name;T[L]=j,$=L}return!J&&$&&(k=$),$||!J&&k},V=function(F,j){if(D(F))return F.clone();var P=typeof j=="object"?j:{};return P.date=F,P.args=arguments,new A(P)},E=w;E.l=X,E.i=D,E.w=function(F,j){return V(F,{locale:j.$L,utc:j.$u,x:j.$x,$offset:j.$offset})};var A=function(){function F(P){this.$L=X(P.locale,null,!0),this.parse(P),this.$x=this.$x||P.x||{},this[I]=!0}var j=F.prototype;return j.parse=function(P){this.$d=function(J){var $=J.date,U=J.utc;if($===null)return new Date(NaN);if(E.u($))return new Date;if($ instanceof Date)return new Date($);if(typeof $=="string"&&!/Z$/i.test($)){var K=$.match(m);if(K){var L=K[2]-1||0,O=(K[7]||"0").substring(0,3);return U?new Date(Date.UTC(K[1],L,K[3]||1,K[4]||0,K[5]||0,K[6]||0,O)):new Date(K[1],L,K[3]||1,K[4]||0,K[5]||0,K[6]||0,O)}}return new Date($)}(P),this.init()},j.init=function(){var P=this.$d;this.$y=P.getFullYear(),this.$M=P.getMonth(),this.$D=P.getDate(),this.$W=P.getDay(),this.$H=P.getHours(),this.$m=P.getMinutes(),this.$s=P.getSeconds(),this.$ms=P.getMilliseconds()},j.$utils=function(){return E},j.isValid=function(){return this.$d.toString()!==v},j.isSame=function(P,J){var $=V(P);return this.startOf(J)<=$&&$<=this.endOf(J)},j.isAfter=function(P,J){return V(P)<this.startOf(J)},j.isBefore=function(P,J){return this.endOf(J)<V(P)},j.$g=function(P,J,$){return E.u(P)?this[J]:this.set($,P)},j.unix=function(){return Math.floor(this.valueOf()/1e3)},j.valueOf=function(){return this.$d.getTime()},j.startOf=function(P,J){var $=this,U=!!E.u(J)||J,K=E.p(P),L=function(b,_){var R=E.w($.$u?Date.UTC($.$y,_,b):new Date($.$y,_,b),$);return U?R:R.endOf(s)},O=function(b,_){return E.w($.toDate()[b].apply($.toDate("s"),(U?[0,0,0,0]:[23,59,59,999]).slice(_)),$)},H=this.$W,W=this.$M,Z=this.$D,re="set"+(this.$u?"UTC":"");switch(K){case f:return U?L(1,0):L(31,11);case d:return U?L(1,W):L(0,W+1);case i:var oe=this.$locale().weekStart||0,ae=(H<oe?H+7:H)-oe;return L(U?Z-ae:Z+(6-ae),W);case s:case h:return O(re+"Hours",0);case p:return O(re+"Minutes",1);case u:return O(re+"Seconds",2);case o:return O(re+"Milliseconds",3);default:return this.clone()}},j.endOf=function(P){return this.startOf(P,!1)},j.$set=function(P,J){var $,U=E.p(P),K="set"+(this.$u?"UTC":""),L=($={},$[s]=K+"Date",$[h]=K+"Date",$[d]=K+"Month",$[f]=K+"FullYear",$[p]=K+"Hours",$[u]=K+"Minutes",$[o]=K+"Seconds",$[a]=K+"Milliseconds",$)[U],O=U===s?this.$D+(J-this.$W):J;if(U===d||U===f){var H=this.clone().set(h,1);H.$d[L](O),H.init(),this.$d=H.set(h,Math.min(this.$D,H.daysInMonth())).$d}else L&&this.$d[L](O);return this.init(),this},j.set=function(P,J){return this.clone().$set(P,J)},j.get=function(P){return this[E.p(P)]()},j.add=function(P,J){var $,U=this;P=Number(P);var K=E.p(J),L=function(W){var Z=V(U);return E.w(Z.date(Z.date()+Math.round(W*P)),U)};if(K===d)return this.set(d,this.$M+P);if(K===f)return this.set(f,this.$y+P);if(K===s)return L(1);if(K===i)return L(7);var O=($={},$[u]=n,$[p]=l,$[o]=t,$)[K]||1,H=this.$d.getTime()+P*O;return E.w(H,this)},j.subtract=function(P,J){return this.add(-1*P,J)},j.format=function(P){var J=this,$=this.$locale();if(!this.isValid())return $.invalidDate||v;var U=P||"YYYY-MM-DDTHH:mm:ssZ",K=E.z(this),L=this.$H,O=this.$m,H=this.$M,W=$.weekdays,Z=$.months,re=$.meridiem,oe=function(_,R,G,ee){return _&&(_[R]||_(J,U))||G[R].slice(0,ee)},ae=function(_){return E.s(L%12||12,_,"0")},b=re||function(_,R,G){var ee=_<12?"AM":"PM";return G?ee.toLowerCase():ee};return U.replace(g,function(_,R){return R||function(G){switch(G){case"YY":return String(J.$y).slice(-2);case"YYYY":return E.s(J.$y,4,"0");case"M":return H+1;case"MM":return E.s(H+1,2,"0");case"MMM":return oe($.monthsShort,H,Z,3);case"MMMM":return oe(Z,H);case"D":return J.$D;case"DD":return E.s(J.$D,2,"0");case"d":return String(J.$W);case"dd":return oe($.weekdaysMin,J.$W,W,2);case"ddd":return oe($.weekdaysShort,J.$W,W,3);case"dddd":return W[J.$W];case"H":return String(L);case"HH":return E.s(L,2,"0");case"h":return ae(1);case"hh":return ae(2);case"a":return b(L,O,!0);case"A":return b(L,O,!1);case"m":return String(O);case"mm":return E.s(O,2,"0");case"s":return String(J.$s);case"ss":return E.s(J.$s,2,"0");case"SSS":return E.s(J.$ms,3,"0");case"Z":return K}return null}(_)||K.replace(":","")})},j.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},j.diff=function(P,J,$){var U,K=this,L=E.p(J),O=V(P),H=(O.utcOffset()-this.utcOffset())*n,W=this-O,Z=function(){return E.m(K,O)};switch(L){case f:U=Z()/12;break;case d:U=Z();break;case c:U=Z()/3;break;case i:U=(W-H)/6048e5;break;case s:U=(W-H)/864e5;break;case p:U=W/l;break;case u:U=W/n;break;case o:U=W/t;break;default:U=W}return $?U:E.a(U)},j.daysInMonth=function(){return this.endOf(d).$D},j.$locale=function(){return T[this.$L]},j.locale=function(P,J){if(!P)return this.$L;var $=this.clone(),U=X(P,J,!0);return U&&($.$L=U),$},j.clone=function(){return E.w(this.$d,this)},j.toDate=function(){return new Date(this.valueOf())},j.toJSON=function(){return this.isValid()?this.toISOString():null},j.toISOString=function(){return this.$d.toISOString()},j.toString=function(){return this.$d.toUTCString()},F}(),C=A.prototype;return V.prototype=C,[["$ms",a],["$s",o],["$m",u],["$H",p],["$W",s],["$M",d],["$y",f],["$D",h]].forEach(function(F){C[F[1]]=function(j){return this.$g(j,F[0],F[1])}}),V.extend=function(F,j){return F.$i||(F(j,A,V),F.$i=!0),V},V.locale=X,V.isDayjs=D,V.unix=function(F){return V(1e3*F)},V.en=T[k],V.Ls=T,V.p={},V})})(O0);var sy=O0.exports;const ly=Zo(sy),uy=ir(he({a11y:{type:Boolean,default:!0},locale:{type:Me(Object)},size:b0,button:{type:Me(Object)},card:{type:Me(Object)},dialog:{type:Me(Object)},link:{type:Me(Object)},experimentalFeatures:{type:Me(Object)},keyboardNavigation:{type:Boolean,default:!0},message:{type:Me(Object)},zIndex:Number,namespace:{type:String,default:"el"}},sv)),We={placement:"top"};N.defineComponent({name:"ElConfigProvider",props:uy,setup(e,{slots:r}){const t=E0(e);return N.watch(()=>e.message,n=>{var l,a;Object.assign(We,(a=(l=t==null?void 0:t.value)==null?void 0:l.message)!=null?a:{},n!=null?n:{})},{immediate:!0,deep:!0}),()=>N.renderSlot(r,"default",{config:t==null?void 0:t.value})}});const P0=["primary","success","info","warning","error"],N0=["top","top-left","top-right","bottom","bottom-left","bottom-right"],vr="top",Ve=Sv({customClass:"",dangerouslyUseHTMLString:!1,duration:3e3,icon:void 0,id:"",message:"",onClose:void 0,showClose:!1,type:"info",plain:!1,offset:16,placement:void 0,zIndex:0,grouping:!1,repeatNum:1,appendTo:Mt?document.body:void 0}),cy=ir({customClass:{type:String,default:Ve.customClass},dangerouslyUseHTMLString:{type:Boolean,default:Ve.dangerouslyUseHTMLString},duration:{type:Number,default:Ve.duration},icon:{type:jr,default:Ve.icon},id:{type:String,default:Ve.id},message:{type:Me([String,Object,Function]),default:Ve.message},onClose:{type:Me(Function),default:Ve.onClose},showClose:{type:Boolean,default:Ve.showClose},type:{type:String,values:P0,default:Ve.type},plain:{type:Boolean,default:Ve.plain},offset:{type:Number,default:Ve.offset},placement:{type:String,values:N0,default:Ve.placement},zIndex:{type:Number,default:Ve.zIndex},grouping:{type:Boolean,default:Ve.grouping},repeatNum:{type:Number,default:Ve.repeatNum}}),fy={destroy:()=>!0},ht=N.shallowReactive({}),hy=e=>(ht[e]||(ht[e]=N.shallowReactive([])),ht[e]),py=(e,r)=>{const t=ht[r]||[],n=t.findIndex(o=>o.id===e),l=t[n];let a;return n>0&&(a=t[n-1]),{current:l,prev:a}},dy=(e,r)=>{const{prev:t}=py(e,r);return t?t.vm.exposed.bottom.value:0},my=(e,r,t)=>(ht[t]||[]).findIndex(a=>a.id===e)>0?16:r,vy=N.defineComponent({name:"ElMessage"}),yy=N.defineComponent(_e(he({},vy),{props:cy,emits:fy,setup(e,{expose:r,emit:t}){const n=e,{Close:l}=Av,a=N.ref(!1),{ns:o,zIndex:u}=_0("message"),{currentZIndex:p,nextZIndex:s}=u,i=N.ref(),d=N.ref(!1),c=N.ref(0);let f;const h=N.computed(()=>n.type?n.type==="error"?"danger":n.type:"info"),v=N.computed(()=>{const A=n.type;return{[o.bm("icon",A)]:A&&Un[A]}}),m=N.computed(()=>n.icon||Un[n.type]||""),g=N.computed(()=>n.placement||vr),x=N.computed(()=>dy(n.id,g.value)),y=N.computed(()=>my(n.id,n.offset,g.value)+x.value),w=N.computed(()=>c.value+y.value),k=N.computed(()=>g.value.includes("left")?o.is("left"):g.value.includes("right")?o.is("right"):o.is("center")),T=N.computed(()=>g.value.startsWith("top")?"top":"bottom"),I=N.computed(()=>({[T.value]:`${y.value}px`,zIndex:p.value}));function D(){n.duration!==0&&({stop:f}=f0(()=>{V()},n.duration))}function X(){f==null||f()}function V(){d.value=!1,N.nextTick(()=>{var A;a.value||((A=n.onClose)==null||A.call(n),t("destroy"))})}function E(A){F0(A)===mr.esc&&V()}return N.onMounted(()=>{D(),s(),d.value=!0}),N.watch(()=>n.repeatNum,()=>{X(),D()}),d0(document,"keydown",E),Hm(i,()=>{c.value=i.value.getBoundingClientRect().height}),r({visible:d,bottom:w,close:V}),(A,C)=>(N.openBlock(),N.createBlock(N.Transition,{name:N.unref(o).b("fade"),onBeforeEnter:F=>a.value=!0,onBeforeLeave:A.onClose,onAfterLeave:F=>A.$emit("destroy"),persisted:""},{default:N.withCtx(()=>[N.withDirectives(N.createElementVNode("div",{id:A.id,ref_key:"messageRef",ref:i,class:N.normalizeClass([N.unref(o).b(),{[N.unref(o).m(A.type)]:A.type},N.unref(o).is("closable",A.showClose),N.unref(o).is("plain",A.plain),N.unref(o).is("bottom",N.unref(T)==="bottom"),N.unref(k),A.customClass]),style:N.normalizeStyle(N.unref(I)),role:"alert",onMouseenter:X,onMouseleave:D},[A.repeatNum>1?(N.openBlock(),N.createBlock(N.unref(Ov),{key:0,value:A.repeatNum,type:N.unref(h),class:N.normalizeClass(N.unref(o).e("badge"))},null,8,["value","type","class"])):N.createCommentVNode("v-if",!0),N.unref(m)?(N.openBlock(),N.createBlock(N.unref(_r),{key:1,class:N.normalizeClass([N.unref(o).e("icon"),N.unref(v)])},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(N.unref(m))))]),_:1},8,["class"])):N.createCommentVNode("v-if",!0),N.renderSlot(A.$slots,"default",{},()=>[A.dangerouslyUseHTMLString?(N.openBlock(),N.createElementBlock(N.Fragment,{key:1},[N.createCommentVNode(" Caution here, message could've been compromised, never use user's input as message "),N.createElementVNode("p",{class:N.normalizeClass(N.unref(o).e("content")),innerHTML:A.message},null,10,["innerHTML"])],2112)):(N.openBlock(),N.createElementBlock("p",{key:0,class:N.normalizeClass(N.unref(o).e("content"))},N.toDisplayString(A.message),3))]),A.showClose?(N.openBlock(),N.createBlock(N.unref(_r),{key:2,class:N.normalizeClass(N.unref(o).e("closeBtn")),onClick:N.withModifiers(V,["stop"])},{default:N.withCtx(()=>[N.createVNode(N.unref(l))]),_:1},8,["class","onClick"])):N.createCommentVNode("v-if",!0)],46,["id"]),[[N.vShow,d.value]])]),_:3},8,["name","onBeforeEnter","onBeforeLeave","onAfterLeave"]))}}));var gy=Br(yy,[["__file","message.vue"]]);let xy=1;const by=e=>{if(!e.appendTo)e.appendTo=document.body;else if(Bt(e.appendTo)){let t=document.querySelector(e.appendTo);Ko(t)||(nr("ElMessage","the appendTo option is not an HTMLElement. Falling back to document.body."),t=document.body),e.appendTo=t}},wy=e=>{!e.placement&&Bt(We.placement)&&We.placement&&(e.placement=We.placement),e.placement||(e.placement=vr),N0.includes(e.placement)||(nr("ElMessage",`Invalid placement: ${e.placement}. Falling back to '${vr}'.`),e.placement=vr)},M0=e=>{const r=!e||Bt(e)||N.isVNode(e)||zr(e)?{message:e}:e,t=he(he({},Ve),r);return by(t),wy(t),To(We.grouping)&&!t.grouping&&(t.grouping=We.grouping),Xt(We.duration)&&t.duration===3e3&&(t.duration=We.duration),Xt(We.offset)&&t.offset===16&&(t.offset=We.offset),To(We.showClose)&&!t.showClose&&(t.showClose=We.showClose),To(We.plain)&&!t.plain&&(t.plain=We.plain),t},_y=e=>{const r=e.props.placement||vr,t=ht[r],n=t.indexOf(e);if(n===-1)return;t.splice(n,1);const{handler:l}=e;l.close()},Ey=(n,t)=>{var l=n,{appendTo:e}=l,r=ka(l,["appendTo"]);const a=`message_${xy++}`,o=r.onClose,u=document.createElement("div"),p=_e(he({},r),{id:a,onClose:()=>{o==null||o(),_y(c)},onDestroy:()=>{N.render(null,u)}}),s=N.createVNode(gy,p,zr(p.message)||N.isVNode(p.message)?{default:zr(p.message)?p.message:()=>p.message}:null);s.appContext=t||Zt._context,N.render(s,u),e.appendChild(u.firstElementChild);const i=s.component,c={id:a,vnode:s,vm:i,handler:{close:()=>{i.exposed.close()}},props:s.component.props};return c},Zt=(e={},r)=>{if(!Mt)return{close:()=>{}};const t=M0(e),n=hy(t.placement||vr);if(t.grouping&&n.length){const a=n.find(({vnode:o})=>{var u;return((u=o.props)==null?void 0:u.message)===t.message});if(a)return a.props.repeatNum+=1,a.props.type=t.type,a.handler}if(Xt(We.max)&&n.length>=We.max)return{close:()=>{}};const l=Ey(t,r);return n.push(l),l.handler};P0.forEach(e=>{Zt[e]=(r={},t)=>{const n=M0(r);return Zt(_e(he({},n),{type:e}),t)}});function Ay(e){for(const r in ht)if(Wo(ht,r)){const t=[...ht[r]];for(const n of t)(!e||e===n.props.type)&&n.handler.close()}}function Cy(e){if(!ht[e])return;[...ht[e]].forEach(t=>t.handler.close())}Zt.closeAll=Ay;Zt.closeAllByPlacement=Cy;Zt._context=null;const st=A0(Zt,"$message"),L0=["primary","success","info","warning","error"],Sy=ir({customClass:{type:String,default:""},dangerouslyUseHTMLString:Boolean,duration:{type:Number,default:4500},icon:{type:jr},id:{type:String,default:""},message:{type:Me([String,Object,Function]),default:""},offset:{type:Number,default:0},onClick:{type:Me(Function),default:()=>{}},onClose:{type:Me(Function),required:!0},position:{type:String,values:["top-right","top-left","bottom-right","bottom-left"],default:"top-right"},showClose:{type:Boolean,default:!0},title:{type:String,default:""},type:{type:String,values:[...L0,""],default:""},zIndex:Number,closeIcon:{type:jr,default:C0}}),By={destroy:()=>!0},ky=N.defineComponent({name:"ElNotification"}),Ty=N.defineComponent(_e(he({},ky),{props:Sy,emits:By,setup(e,{expose:r}){const t=e,{ns:n,zIndex:l}=_0("notification"),{nextZIndex:a,currentZIndex:o}=l,u=N.ref(!1);let p;const s=N.computed(()=>{const x=t.type;return x&&Un[t.type]?n.m(x):""}),i=N.computed(()=>t.type&&Un[t.type]||t.icon),d=N.computed(()=>t.position.endsWith("right")?"right":"left"),c=N.computed(()=>t.position.startsWith("top")?"top":"bottom"),f=N.computed(()=>{var x;return{[c.value]:`${t.offset}px`,zIndex:(x=t.zIndex)!=null?x:o.value}});function h(){t.duration>0&&({stop:p}=f0(()=>{u.value&&m()},t.duration))}function v(){p==null||p()}function m(){u.value=!1}function g(x){switch(F0(x)){case mr.delete:case mr.backspace:v();break;case mr.esc:u.value&&m();break;default:h();break}}return N.onMounted(()=>{h(),a(),u.value=!0}),d0(document,"keydown",g),r({visible:u,close:m}),(x,y)=>(N.openBlock(),N.createBlock(N.Transition,{name:N.unref(n).b("fade"),onBeforeLeave:x.onClose,onAfterLeave:w=>x.$emit("destroy"),persisted:""},{default:N.withCtx(()=>[N.withDirectives(N.createElementVNode("div",{id:x.id,class:N.normalizeClass([N.unref(n).b(),x.customClass,N.unref(d)]),style:N.normalizeStyle(N.unref(f)),role:"alert",onMouseenter:v,onMouseleave:h,onClick:x.onClick},[N.unref(i)?(N.openBlock(),N.createBlock(N.unref(_r),{key:0,class:N.normalizeClass([N.unref(n).e("icon"),N.unref(s)])},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(N.unref(i))))]),_:1},8,["class"])):N.createCommentVNode("v-if",!0),N.createElementVNode("div",{class:N.normalizeClass(N.unref(n).e("group"))},[N.createElementVNode("h2",{class:N.normalizeClass(N.unref(n).e("title")),textContent:N.toDisplayString(x.title)},null,10,["textContent"]),N.withDirectives(N.createElementVNode("div",{class:N.normalizeClass(N.unref(n).e("content")),style:N.normalizeStyle(x.title?void 0:{margin:0})},[N.renderSlot(x.$slots,"default",{},()=>[x.dangerouslyUseHTMLString?(N.openBlock(),N.createElementBlock(N.Fragment,{key:1},[N.createCommentVNode(" Caution here, message could've been compromised, never use user's input as message "),N.createElementVNode("p",{innerHTML:x.message},null,8,["innerHTML"])],2112)):(N.openBlock(),N.createElementBlock("p",{key:0},N.toDisplayString(x.message),1))])],6),[[N.vShow,x.message]]),x.showClose?(N.openBlock(),N.createBlock(N.unref(_r),{key:0,class:N.normalizeClass(N.unref(n).e("closeBtn")),onClick:N.withModifiers(m,["stop"])},{default:N.withCtx(()=>[(N.openBlock(),N.createBlock(N.resolveDynamicComponent(x.closeIcon)))]),_:1},8,["class","onClick"])):N.createCommentVNode("v-if",!0)],2)],46,["id","onClick"]),[[N.vShow,u.value]])]),_:3},8,["name","onBeforeLeave","onAfterLeave"]))}}));var Fy=Br(Ty,[["__file","notification.vue"]]);const Er={"top-left":[],"top-right":[],"bottom-left":[],"bottom-right":[]},qn=16;let Iy=1;const Jt=function(e={},r){if(!Mt)return{close:()=>{}};(Bt(e)||N.isVNode(e))&&(e={message:e});const t=e.position||"top-right";let n=e.offset||0;Er[t].forEach(({vm:i})=>{var d;n+=(((d=i.el)==null?void 0:d.offsetHeight)||0)+qn}),n+=qn;const l=`notification_${Iy++}`,a=e.onClose,o=_e(he({},e),{offset:n,id:l,onClose:()=>{Dy(l,t,a)}});let u=document.body;Ko(e.appendTo)?u=e.appendTo:Bt(e.appendTo)&&(u=document.querySelector(e.appendTo)),Ko(u)||(nr("ElNotification","the appendTo option is not an HTMLElement. Falling back to document.body."),u=document.body);const p=document.createElement("div"),s=N.createVNode(Fy,o,zr(o.message)?o.message:N.isVNode(o.message)?()=>o.message:null);return s.appContext=Om(r)?Jt._context:r,s.props.onDestroy=()=>{N.render(null,p)},N.render(s,p),Er[t].push({vm:s}),u.appendChild(p.firstElementChild),{close:()=>{s.component.exposed.visible.value=!1}}};L0.forEach(e=>{Jt[e]=(r={},t)=>((Bt(r)||N.isVNode(r))&&(r={message:r}),Jt(_e(he({},r),{type:e}),t))});function Dy(e,r,t){const n=Er[r],l=n.findIndex(({vm:s})=>{var i;return((i=s.component)==null?void 0:i.props.id)===e});if(l===-1)return;const{vm:a}=n[l];if(!a)return;t==null||t(a);const o=a.el.offsetHeight,u=r.split("-")[0];n.splice(l,1);const p=n.length;if(!(p<1))for(let s=l;s<p;s++){const{el:i,component:d}=n[s].vm,c=Number.parseInt(i.style[u],10)-o-qn;d.props.offset=c}}function Ry(){for(const e of Object.values(Er))e.forEach(({vm:r})=>{r.component.exposed.visible.value=!1})}function Oy(e="top-right"){var r,t,n,l;let a=((n=(t=(r=Er[e][0])==null?void 0:r.vm.component)==null?void 0:t.props)==null?void 0:n.offset)||0;for(const{vm:o}of Er[e])o.component.props.offset=a,a+=(((l=o.el)==null?void 0:l.offsetHeight)||0)+qn}Jt.closeAll=Ry;Jt.updateOffsets=Oy;Jt._context=null;const Py=A0(Jt,"$notify"),U0="0123456789abcdeffedcba9876543210",q0="4b0de988570c3a0f",Ny=window.ENCRYPT;let yr=Ny&&new s0;function $0(e=16,r="0123456789abcdefghijklmnopqrstuvwxyz"){let t="",n=r.length;for(;e>0;)t+=r[Math.floor(Math.random()*n)],e--;return t}function z0(){return je(this,null,function*(){return yr||(yr=new s0),new Promise((e,r)=>{yr.armEnum().then(t=>{e(+t)}).catch(t=>{st({type:"warning",ElMessage:"未找到U盘锁,请检查U盘锁!"}),r(t)})})})}$n.throttle(()=>je(exports,null,function*(){const e=yield z0(),r={};if(typeof e!="number"||e<=0)st({type:"warning",ElMessage:"未找到U盘锁,请检查U盘锁!"}),r.resetToken();else{const t=yield Ly();if(!r.token)return;t.length?t.includes(r.ukeyHid)||(st({type:"error",ElMessage:"U盘锁不匹配,请检查U盘锁!"}),r.resetToken()):(st({type:"warning",ElMessage:"未找到U盘锁,请检查U盘锁!"}),r.resetToken())}}),5e3,{trailing:!1});function My(e=0){return je(this,null,function*(){return yr?new Promise((r,t)=>{yr.armGetDongleInfo(e).then(n=>{n?r(n):(st({type:"warning",ElMessage:"U盘锁信息为空,请检查U盘锁!"}),t(n))}).catch(n=>{t(n)})}):st({type:"warning",ElMessage:"未找到U盘锁程序,请检查后台程序!"})})}function Ly(){return je(this,null,function*(){if(!yr)return st({type:"warning",ElMessage:"未找到U盘锁程序,请检查后台程序!"});const e=yield z0();let r=[];for(let t=0;t<e;t++){const n=yield My(t);r.push(n)}return r})}$0(16);$0(16);const j0=window.meta.app.inspect?wr.constants.CBC:wr.constants.ECB;Em.generateKeyPair();function Il(e,r,t={}){const n=H0(q0),l=t.mode||j0;t=l===wr.constants.ECB?he({mode:l,inputEncoding:"utf8",outputEncoding:"hex"},t):he({iv:U0,mode:l,inputEncoding:"utf8",outputEncoding:"hex"},t);let a="";try{a=wr.encrypt(e,n,t)}catch(o){console.log("err: ",o)}return a}function Dl(e,r,t={}){const n=H0(q0),l=t.mode||j0;return t=l===wr.constants.ECB?he({mode:l,inputEncoding:"hex",outputEncoding:"utf8"},t):he({iv:U0,mode:l,inputEncoding:"hex",outputEncoding:"utf8"},t),wr.decrypt(e,n,t)}function H0(e){return[...e].map(r=>r.charCodeAt().toString(16)).join("")}const Rl={getLocal:e=>{try{let r=window.localStorage.getItem(e);return r=r!==null?Dl(r):r,JSON.parse(r)}catch(r){console.error(r)}},setLocal:(e,r)=>{try{let t=JSON.stringify(r);t=t!==null?Il(t):t,window.localStorage.setItem(e,t)}catch(t){console.error(t)}},eachLocal:e=>{if(!e||Cs(e)!=="Function")return console.error("传递参数非函数类型!");for(let r=0,t=window.localStorage.length;r<t;r++){const n=window.localStorage.key(r);e((void 0).getLocal(n),n)}},clearLocal:()=>{window.localStorage.clear()},removeLocal:e=>{window.localStorage.removeItem(e)},getSession:e=>{try{let r=window.sessionStorage.getItem(e);return r=r!==null?Dl(r):r,JSON.parse(r)}catch(r){console.error(r)}},setSession:(e,r)=>{try{let t=JSON.stringify(r);t=t!==null?Il(t):t,window.sessionStorage.setItem(e,t)}catch(t){console.error(t)}},eachSession:e=>{if(!e||Cs(e)!=="Function")return console.error("传递参数非函数类型!");for(let r=0,t=window.sessionStorage.length;r<t;r++){const n=window.sessionStorage.key(r);e((void 0).getSession(n),n)}},clearSession:()=>{window.sessionStorage.clear()},removeSession:e=>{window.sessionStorage.removeItem(e)}},Ol=e=>{const{quality:r,value:t,function_id:n}=e;return(r>>7&1)===1||r===0&&n===2&&t===1},Pl="USER_TOKEN",Nl="STATION_ID",Uy=[{key:0,value:"离线"},{key:1,value:"在线"}],qy=[{key:0,value:"反向"},{key:1,value:"正向"},{key:2,value:"停止"}],$y=[{key:1,value:1},{key:2,value:2},{key:3,value:3},{key:4,value:4},{key:5,value:5}],zy="data:image/svg+xml,%3c?xml%20version='1.0'%20standalone='no'?%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20t='1753954524851'%20class='icon'%20viewBox='0%200%201024%201024'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20p-id='1506'%20width='256'%20height='256'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3cpath%20d='M888.65792%20280.15616a46.80704%2046.80704%200%200%200-46.80704-46.80704H233.34912a46.80704%2046.80704%200%200%200-46.80704%2046.80704v93.61408h702.11584V280.15616zM186.54208%20420.5824v374.46144a46.80704%2046.80704%200%200%200%2046.80704%2046.80704h608.49664a46.80704%2046.80704%200%200%200%2046.80704-46.80704V420.5824H186.54208z%20m442.9056%2084.98688l30.92992%2011.47904c-15.62624%2024.23808-35.39968%2050.38592-50.70848%2067.6096l-25.51296-10.84416c15.31392-17.85856%2034.7648-46.56128%2045.29152-68.24448z%20m-184.64768-1.59744c17.54112%2020.09088%2038.26688%2047.5136%2047.5136%2065.37728l-25.51296%2015.62624c-8.61184-17.85856-28.70272-46.23872-45.92128-67.28704l23.92064-13.71648z%20m199.95136%20267.2384h-45.28128c-32.20992%200-39.86432-8.92928-39.86432-39.86432v-102.36416h-46.23872c-5.73952%2069.8368-21.6832%20121.18528-101.0944%20149.56544-3.5072-7.97184-11.47904-19.456-18.49344-25.51296%2072.07424-22.9632%2083.87072-66.01728%2088.65792-124.05248H399.19616v-28.70272h122.7776V483.88096h30.92992v116.39808h122.46016v28.70272h-85.7856v102.04672c0%2010.5216%201.90976%2012.11904%2013.71136%2012.11904h38.90176c8.92928%200%2010.84416-4.1472%2011.8016-28.38016%206.69696%204.78208%2019.12832%209.56928%2027.42272%2011.47904-3.49696%2035.39968-11.4688%2044.96384-36.66432%2044.96384z'%20fill='%23005CFF'%20p-id='1507'%3e%3c/path%3e%3c/svg%3e",Ct=window.meta.graph.penFormMap?window.meta.graph.penFormMap:{NORMAL:[{name:"颜色",key:"color",type:"color",dataIds:{}}],TEXT:[{name:"显示内容",key:"text",type:"text",dataIds:{}}],AUDIO:[{name:"颜色",key:"color",type:"color",dataIds:{}}],MP4:[{name:"颜色",key:"color",type:"color",dataIds:{}}],CAMERA:[{name:"颜色",key:"color",type:"color",dataIds:{}}],VIDEO_STREAM:[{name:"颜色",key:"color",type:"color",dataIds:{}}],POINT_VALUE:[{name:"在线状态",key:"online_state",type:"select",dataIds:{},options:[{label:"在线",value:1},{label:"离线",value:0}]},{name:"测点值",key:"point_value",type:"text",dataIds:{}}],LIGHT_PLATE:[{name:"光字牌",key:"light_plate",type:"select",dataIds:{},options:[{label:"离线",value:-1},{label:"正常",value:0},{label:"预警",value:1},{label:"一般",value:2},{label:"严重",value:3},{label:"危急",value:4}]}]},V0=window.meta.graph.lightPlateColorMap?window.meta.graph.lightPlateColorMap:{0:"#00d200",1:"#e2ac06",2:"#fa800a",3:"#f04155",4:"#ff0000"},W0=window.meta.graph.lightPlateTextMap?window.meta.graph.lightPlateTextMap:{0:"#fff",1:"#fff",2:"#fff",3:"#fff",4:"#fff"},Oe={form:[{name:"带电状态",key:"charged_state",type:"select",dataIds:{},options:Uy.map(e=>({label:e.value,value:e.key}))},{name:"潮流方向",key:"electric_direction",type:"select",dataIds:{},options:qy.map(e=>({label:e.value,value:e.key}))},{name:"电荷大小",key:"electric_size",type:"select",dataIds:{},options:$y.map(e=>({label:e.value,value:e.key}))}],anchors:[{x:0,y:.5,id:"0"},{x:.5,y:0,id:"1"},{x:1,y:.5,id:"2"},{x:.5,y:1,id:"3"}],dataType:window.dataType,dataProp:window.dataProp,visibleLevel:window.visibleLevel},ye=_e(he({penType:Se.NORMAL},Oe),{form:[...Ct[Se.NORMAL],...Oe.form]});Se.POINT_VALUE,Oe.anchors,window.visibleLevel,[...Ct[Se.POINT_VALUE],...Oe.form],Oe.form,window.dataType,window.dataProp,window.visibleLevel,Oe.form,window.dataType,window.dataProp,window.visibleLevel,W0[0],Se.LIGHT_PLATE,V0[0],Oe.anchors,window.visibleLevel,[...Ct[Se.LIGHT_PLATE],...Oe.form],Se.SENSOR,Oe.anchors,window.visibleLevel,[...Ct[Se.LIGHT_PLATE],...Oe.form],_e(he({width:100,height:30,name:"text",text:"文本",disableAnchor:!0,penType:Se.TEXT},Oe),{form:[...Ct[Se.TEXT],...Oe.form]}),he({width:100,height:100,name:"square"},ye),_e(he({type:1,name:"line",width:100,height:5,lineWidth:2,lineName:"line",penName:"line",background:"#FFF000",color:"#FFF000"},ye),{lineAnimateType:1,anchors:[{x:0,y:.5,id:"0"},{x:1,y:.5,id:"1"}]}),he({width:200,height:50,borderRadius:0,name:"rectangle"},ye),he({width:100,height:100,name:"circle"},ye),he({width:100,height:100,name:"triangle"},ye),he({width:100,height:100,name:"diamond"},ye),he({width:100,height:100,name:"pentagon"},ye),he({width:100,height:100,name:"hexagon"},ye),he({width:100,height:100,name:"pentagram"},ye),he({width:120,height:60,name:"leftArrow"},ye),he({width:120,height:60,name:"rightArrow"},ye),he({width:150,height:60,name:"twowayArrow"},ye),he({width:100,height:100,name:"cloud"},ye),he({textTop:-.1,width:100,height:100,name:"message"},ye),he({width:80,height:100,name:"file"},ye),_e(he({name:"svg",width:100,height:100,image:"/icon/audio.svg",audioId:"",penType:Se.AUDIO},Oe),{form:[...Ct[Se.AUDIO],...Oe.form],events:[{name:"enter",action:mn.Emit,value:nt.OPEN_AUDIO,where:{type:""},params:JSON.stringify({action:nt.OPEN_AUDIO,data:""})},{name:"leave",action:mn.Emit,value:nt.CLOSE_AUDIO,where:{type:""},params:JSON.stringify({action:nt.CLOSE_AUDIO,data:""})}]}),_e(he({name:"svg",width:100,height:100,image:"/icon/camera.svg",cameraId:"",events:[{name:"enter",action:mn.Emit,value:nt.OPEN_CAMERA,where:{type:""},params:JSON.stringify({action:nt.OPEN_CAMERA,data:""})},{name:"leave",action:mn.Emit,value:nt.CLOSE_CAMERA,where:{type:""},params:JSON.stringify({action:nt.CLOSE_CAMERA,data:""})}],penType:Se.CAMERA},Oe),{form:[...Ct[Se.CAMERA],...Oe.form]}),_e(he({name:"video",width:100,height:100,video:"https://video.699pic.com/videos/17/69/11/a_aa3jeKZ0D63g1556176911_10s.mp4",autoPlay:!0,penType:Se.MP4},Oe),{form:[...Ct[Se.MP4],...Oe.form]}),_e(he({name:"video",width:100,height:100,video:"https://video.699pic.com/videos/17/69/11/a_aa3jeKZ0D63g1556176911_10s.mp4",autoPlay:!0,penType:Se.VIDEO_STREAM},Oe),{form:[...Ct[Se.VIDEO_STREAM],...Oe.form]}),_e(he({width:60,height:100,name:"cube",z:.25},ye),{props:{custom:[{key:"z",label:"Z",type:"number",min:0,placeholder:"<= 1 即宽度的比例"},{key:"backgroundFront",label:"前背景色",type:"color"},{key:"backgroundUp",label:"顶背景色",type:"color"},{key:"backgroundRight",label:"右背景色",type:"color"}]}}),he({width:70,height:100,name:"people"},ye),_e(he({name:"table",width:80,height:30,disableAnchor:!0,colWidth:90,rowHeight:32,bordered:!0,vLine:!0,hLine:!0,stripe:!1,color:"#333",textColor:"#444"},ye),{penType:Se.TABLE,data:[["设备 ID","设备名称","数据协议","级别"],["1","200","MQTT",{text:"一级告警",background:"#650b09",textColor:"#FF5D3CFF"}],["2","湿度传感器","MQTT",{text:"二级告警",background:"#4d2a02",textColor:"#E6A82EFF"}],["3","物联网设备","MQTT",{text:"一级告警",background:"#650b09",textColor:"#FF5D3CFF"}],["4","物联网设备/智能家居/智慧城市","MQTT",{text:"三级告警",textColor:"#58CC84FF",background:"#042617;"}]],styles:[{row:0,textColor:"#000"}]}),_e(he({name:"rectangle",penName:"按钮",width:80,height:30,borderRadius:.2,text:"按钮",background:"#1890ff",color:"#1890ff",textColor:"#fff",activeBackground:"#40a9ff",activeColor:"#40a9ff",activeTextColor:"#fff",hoverBackground:"#40a9ff",hoverColor:"#40a9ff",hoverTextColor:"#fff"},ye),{penType:Se.BUTTON}),_e(he({name:"switch",penName:"开关",height:30,width:60,checked:!1,offColor:"#BFBFBF",onColor:"#1890ff",disableOffColor:"#E5E5E5",disableOnColor:"#A3D3FF",locked:0},ye),{penType:Se.SWITCH}),_e(he({name:"radio",penName:"单选框",width:150,height:100,direction:"vertical",checked:"",options:[{text:"选项一"},{text:"选项二"},{text:"选项三",isForbidden:!0}]},ye),{penType:Se.RADIO}),_e(he({name:"checkbox",penName:"多选框",width:30,height:30,checked:!0,value:"选项一"},ye),{penType:Se.CHECKBOX}),_e(he({name:"slider",penName:"进度条",width:300,height:30,value:10,textWidth:50,barHeight:4,min:0,max:100,color:"#1890ff",background:"#D4D6D9",textColor:"#222",unit:"%"},ye),{penType:Se.SLIDER}),_e(he({name:"rectangle",penName:"输入框",height:50,width:200,input:!0,borderRadius:.05,ellipsis:!0,text:"输入数据",textAlign:"left",color:"#D9D9D9FF",textColor:"#000000FF",hoverTextColor:"#000000FF",activeTextColor:"#000000FF",textLeft:10},ye),{penType:Se.INPUT}),_e(he({name:"rectangle",penName:"选择器",height:50,width:200,borderRadius:.05,ellipsis:!0,text:"选项1",textAlign:"left",color:"#D9D9D9FF",textColor:"#000000FF",hoverTextColor:"#000000FF",activeTextColor:"#000000FF",textLeft:10,dropdownList:[{text:"选项1"},{text:"选项2"},{text:"选项3"}]},ye),{penType:Se.SELECT}),_e(he({name:"time",penName:"时间",width:300,height:40,text:`${ly().format("YYYY-MM-DD HH:mm:ss")}`,lineWidth:0,interval:67,fillZero:!0},ye),{penType:Se.TIME,form:[{key:"timeFormat",name:"显示格式",type:"text"},{key:"fillZero",name:"是否补0",type:"switch"},...ye.form],timeFormat:"`${year}-${month}-${day} ${hours}:${minutes}:${seconds} 星期${week}`"}),he({text:"开始/结束",width:120,height:40,borderRadius:.5,name:"rectangle"},ye),he({text:"流程",width:120,height:40,name:"rectangle"},ye),he({text:"判定",width:120,height:60,name:"diamond"},ye),he({text:"数据",width:120,height:50,name:"flowData",offsetX:.14},ye),he({text:"准备",width:120,height:50,name:"hexagon"},ye),he({text:"子流程",width:120,height:50,name:"flowSubprocess"},ye),he({text:"数据库",width:80,height:120,name:"flowDb"},ye),he({text:"文档",width:120,height:100,name:"flowDocument"},ye),he({text:"内部存储",width:120,height:80,name:"flowInternalStorage"},ye),he({text:"外部存储",width:120,height:80,name:"flowExternStorage"},ye),he({text:"队列",width:100,height:100,name:"flowQueue"},ye),he({text:"手动输入",width:120,height:80,name:"flowManually"},ye),he({text:"展示",width:120,height:80,name:"flowDisplay"},ye),he({text:"并行模式",width:120,height:50,name:"flowParallel"},ye),he({text:"注释",width:100,height:100,name:"flowComment"},ye),he({text:"",width:30,height:30,name:"circle",background:"#555",lineWidth:0},ye),he({width:30,height:30,name:"activityFinal"},ye),he({text:"活动",width:120,height:50,borderRadius:.25,name:"rectangle"},ye),he({text:"决策/合并",width:120,height:50,name:"diamond"},ye),he({text:"垂直泳道",width:200,height:500,name:"swimlaneV",textBaseline:"top",textTop:20,lineTop:.08},ye),he({text:"水平泳道",width:500,height:200,name:"swimlaneH",textWidth:.01,textLeft:.04,textAlign:"left",lineLeft:.08},ye),he({text:"垂直分岔/汇合",width:10,height:150,name:"forkV",fillStyle:"#555",strokeStyle:"transparent"},ye),he({text:"水平分岔/汇合",width:150,height:10,name:"forkH",fillStyle:"#555",strokeStyle:"transparent"},ye),he({name:"andGate",width:100,height:150},ye),he({name:"basicEvent",width:100,height:150},ye),he({name:"unexpandedEvent",width:100,height:150},ye),he({name:"priorityAndGate",width:100,height:150},ye),he({name:"forbiddenGate",width:100,height:150},ye),he({name:"event",width:100,height:150},ye),he({name:"switchEvent",width:100,height:150},ye),he({name:"conditionalEvent",width:150,height:100},ye),he({name:"transferSymbol",width:100,height:150},ye),he({name:"orGate",width:100,height:150},ye),he({name:"xorGate",width:100,height:150},ye),he({name:"votingGate",width:100,height:150},ye),he({text:"主题",width:200,height:50,name:"mindNode",borderRadius:.5},ye),he({text:"子主题",width:160,height:40,name:"mindLine"},ye);const jy=(e,r={isDev:!1,devServerUrl:"",devServerPort:8443})=>e.replace(/(https?:\/\/)(\b(?:\d{1,3}\.){3}\d{1,3}\b)(:(\d+))?/,`$1${r.isDev?r.devServerUrl:c1}:${r.isDev?r.devServerPort:h1}`);class Hy{constructor(r){It(this,"editor");this.editor=r}initPlugin(r,t,n={}){r.installPenPlugins({name:t},[{plugin:Bc.mindBoxPlugin,options:n},{plugin:kc.collapseChildPlugin,options:n}])}}var Ml;(function(e){e[e.Node=0]="Node",e[e.Line=1]="Line"})(Ml||(Ml={}));var Ll;(function(e){e[e.None=0]="None",e[e.DisableEdit=1]="DisableEdit",e[e.DisableMove=2]="DisableMove",e[e.DisableScale=3]="DisableScale",e[e.DisableMoveScale=4]="DisableMoveScale",e[e.Disable=10]="Disable"})(Ll||(Ll={}));var Ul;(function(e){e[e.Default=0]="Default",e[e.In=1]="In",e[e.Out=2]="Out"})(Ul||(Ul={}));var ql;(function(e){e[e.None=0]="None",e[e.Linear=1]="Linear",e[e.Radial=2]="Radial"})(ql||(ql={}));var $l;(function(e){e[e.CanvasTemplate=1]="CanvasTemplate",e[e.CanvasImageBottom=2]="CanvasImageBottom",e[e.CanvasMain=3]="CanvasMain",e[e.CanvasImage=4]="CanvasImage"})($l||($l={}));var zl;(function(e){e[e.Normal=0]="Normal",e[e.Beads=1]="Beads",e[e.Dot=2]="Dot",e[e.Arrow=3]="Arrow",e[e.WaterDrop=4]="WaterDrop",e[e.Custom=5]="Custom"})(zl||(zl={}));var jl;(function(e){e[e.Image=0]="Image",e[e.Icon=1]="Icon",e[e.Pen=2]="Pen",e[e.Element=3]="Element"})(jl||(jl={}));var Hl;(function(e){e[e.None=0]="None",e[e.LineAnchor=1]="LineAnchor",e[e.NodeAnchor=2]="NodeAnchor",e[e.Line=3]="Line",e[e.Node=4]="Node",e[e.Resize=5]="Resize",e[e.Rotate=6]="Rotate",e[e.LineAnchorPrev=7]="LineAnchorPrev",e[e.LineAnchorNext=8]="LineAnchorNext"})(Hl||(Hl={}));var Vl;(function(e){e[e.None=0]="None",e[e.Translate=1]="Translate",e[e.Select=2]="Select",e[e.Resize=3]="Resize",e[e.AddAnchor=4]="AddAnchor"})(Vl||(Vl={}));var Wl;(function(e){e[e.None=0]="None",e[e.Down=1]="Down",e[e.Translate=2]="Translate"})(Wl||(Wl={}));var Kl;(function(e){e[e.None=-1]="None",e[e.Up=0]="Up",e[e.Right=1]="Right",e[e.Bottom=2]="Bottom",e[e.Left=3]="Left"})(Kl||(Kl={}));var Gl;(function(e){e[e.Mirror=0]="Mirror",e[e.Bilateral=1]="Bilateral",e[e.Free=2]="Free"})(Gl||(Gl={}));var Ql;(function(e){e[e.Default=0]="Default",e[e.In=1]="In",e[e.Out=2]="Out",e[e.DisableConnected=3]="DisableConnected",e[e.DisableConnectTo=4]="DisableConnectTo",e[e.Disable=10]="Disable"})(Ql||(Ql={}));var Yl;(function(e){e[e.Default=0]="Default",e[e.Line=1]="Line"})(Yl||(Yl={}));var Xo;(function(e){e[e.None=-1]="None",e[e.Document=0]="Document",e[e.Canvas=1]="Canvas"})(Xo||(Xo={}));Xo.Document;var Xl;(function(e){e[e.Add=0]="Add",e[e.Update=1]="Update",e[e.Delete=2]="Delete",e[e.Replace=3]="Replace"})(Xl||(Xl={}));function Zl(e){const r=parseInt,t=Math.round;let n=e.length,l={};if(n>9){const[a,o,u,p]=e=e.split(",");if(n=e.length,n<3||n>4)return null;l.r=r(a[3]=="a"?a.slice(5):a.slice(4)),l.g=r(o),l.b=r(u),l.a=p?parseFloat(p):-1}else{if(n==8||n==6||n<4)return null;n<6&&(e="#"+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]+(n>4?e[4]+e[4]:"")),e=r(e.slice(1),16),n==9||n==5?(l.r=e>>24&255,l.g=e>>16&255,l.b=e>>8&255,l.a=t((e&255)/.255)/1e3):(l.r=e>>16,l.g=e>>8&255,l.b=e&255,l.a=-1)}return l}function Vy(e,r,t,n){let l,a,o,u,p,s,i,d=Math.round,c=typeof t=="string";return typeof e!="number"||e<-1||e>1||typeof r!="string"||r[0]!="r"&&r[0]!="#"||t&&!c||(i=r.length>9,i=c?t.length>9?!0:t=="c"?!i:!1:i,p=Zl(r),u=e<0,s=t&&t!="c"?Zl(t):u?{r:0,g:0,b:0,a:-1}:{r:255,g:255,b:255,a:-1},e=u?e*-1:e,u=1-e,!p||!s)?null:(n?(l=d(u*p.r+e*s.r),a=d(u*p.g+e*s.g),o=d(u*p.b+e*s.b)):(l=d(mt(u*mt(p.r,2)+e*mt(s.r,2),.5)),a=d(mt(u*mt(p.g,2)+e*mt(s.g,2),.5)),o=d(mt(u*mt(p.b,2)+e*mt(s.b,2),.5))),c=p.a,s=s.a,p=c>=0||s>=0,c=p?c<0?s:s<0?c:c*u+s*e:0,i?"rgb"+(p?"a(":"(")+l+","+a+","+o+(p?","+d(c*1e3)/1e3:"")+")":"#"+(4294967296+l*16777216+a*65536+o*256+(p?d(c*255):0)).toString(16).slice(1,p?void 0:-2))}globalThis.pSBC=Vy;var Jl;(function(e){e[e.None=0]="None",e[e.LocalStorage=1]="LocalStorage",e[e.Cookie=2]="Cookie"})(Jl||(Jl={}));location.host.indexOf("le5le.com");const cr={};var eu;(function(e){e[e.Link=0]="Link",e[e.SetProps=1]="SetProps",e[e.StartAnimate=2]="StartAnimate",e[e.PauseAnimate=3]="PauseAnimate",e[e.StopAnimate=4]="StopAnimate",e[e.JS=5]="JS",e[e.GlobalFn=6]="GlobalFn",e[e.Emit=7]="Emit",e[e.StartVideo=8]="StartVideo",e[e.PauseVideo=9]="PauseVideo",e[e.StopVideo=10]="StopVideo",e[e.SendPropData=11]="SendPropData",e[e.SendVarData=12]="SendVarData",e[e.Navigator=13]="Navigator",e[e.Dialog=14]="Dialog",e[e.SendData=15]="SendData",e[e.PostMessage=16]="PostMessage",e[e.PostMessageToParent=17]="PostMessageToParent",e[e.Message=18]="Message"})(eu||(eu={}));var Wy={exports:{}};(function(e,r){(function(t){e.exports=t()})(function(){return function(){return function t(n,l,a){function o(s,i){if(!l[s]){if(!n[s]){var d=typeof Rr=="function"&&Rr;if(!i&&d)return d(s,!0);if(u)return u(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var f=l[s]={exports:{}};n[s][0].call(f.exports,function(h){return o(n[s][1][h]||h)},f,f.exports,t,n,l,a)}return l[s].exports}for(var u=typeof Rr=="function"&&Rr,p=0;p<a.length;p++)o(a[p]);return o}}()({1:[function(t,n,l){(function(a,o){(function(){const u=t("events").EventEmitter,p=t("./store"),s=t("./topic-alias-recv"),i=t("./topic-alias-send"),d=t("mqtt-packet"),c=t("./default-message-id-provider"),f=t("readable-stream").Writable,h=t("inherits"),v=t("reinterval"),m=t("rfdc/default"),g=t("./validations"),x=t("xtend"),y=t("debug")("mqttjs:client"),w=a?a.nextTick:function(C){setTimeout(C,0)},k=o.setImmediate||function(C){w(C)},T={keepalive:60,reschedulePings:!0,protocolId:"MQTT",protocolVersion:4,reconnectPeriod:1e3,connectTimeout:3e4,clean:!0,resubscribe:!0},I={0:"",1:"Unacceptable protocol version",2:"Identifier rejected",3:"Server unavailable",4:"Bad username or password",5:"Not authorized",16:"No matching subscribers",17:"No subscription existed",128:"Unspecified error",129:"Malformed Packet",130:"Protocol Error",131:"Implementation specific error",132:"Unsupported Protocol Version",133:"Client Identifier not valid",134:"Bad User Name or Password",135:"Not authorized",136:"Server unavailable",137:"Server busy",138:"Banned",139:"Server shutting down",140:"Bad authentication method",141:"Keep Alive timeout",142:"Session taken over",143:"Topic Filter invalid",144:"Topic Name invalid",145:"Packet identifier in use",146:"Packet Identifier not found",147:"Receive Maximum exceeded",148:"Topic Alias invalid",149:"Packet too large",150:"Message rate too high",151:"Quota exceeded",152:"Administrative action",153:"Payload format invalid",154:"Retain not supported",155:"QoS not supported",156:"Use another server",157:"Server moved",158:"Shared Subscriptions not supported",159:"Connection rate exceeded",160:"Maximum connect time",161:"Subscription Identifiers not supported",162:"Wildcard Subscriptions not supported"};function D(C,F){let j;F.properties&&(j=F.properties.topicAlias);let P=F.topic.toString();if(P.length===0){if(j===void 0)return new Error("Unregistered Topic Alias");if((P=C.topicAliasSend.getTopicByAlias(j))===void 0)return new Error("Unregistered Topic Alias");F.topic=P}j&&delete F.properties.topicAlias}function X(C,F,j){y("sendPacket :: packet: %O",F),y("sendPacket :: emitting `packetsend`"),C.emit("packetsend",F),y("sendPacket :: writing to stream");const P=d.writeToStream(F,C.stream,C.options);y("sendPacket :: writeToStream result %s",P),!P&&j&&j!==E?(y("sendPacket :: handle events on `drain` once through callback."),C.stream.once("drain",j)):j&&(y("sendPacket :: invoking cb"),j())}function V(C,F,j,P){y("storeAndSend :: store packet with cmd %s to outgoingStore",F.cmd);let J,$=F;if($.cmd==="publish"&&($=m(F),J=D(C,$)))return j&&j(J);C.outgoingStore.put($,function(U){if(U)return j&&j(U);P(),X(C,F,j)})}function E(C){y("nop ::",C)}function A(C,F){let j;const P=this;if(!(this instanceof A))return new A(C,F);for(j in this.options=F||{},T)this.options[j]===void 0?this.options[j]=T[j]:this.options[j]=F[j];y("MqttClient :: options.protocol",F.protocol),y("MqttClient :: options.protocolVersion",F.protocolVersion),y("MqttClient :: options.username",F.username),y("MqttClient :: options.keepalive",F.keepalive),y("MqttClient :: options.reconnectPeriod",F.reconnectPeriod),y("MqttClient :: options.rejectUnauthorized",F.rejectUnauthorized),y("MqttClient :: options.topicAliasMaximum",F.topicAliasMaximum),this.options.clientId=typeof F.clientId=="string"?F.clientId:"mqttjs_"+Math.random().toString(16).substr(2,8),y("MqttClient :: clientId",this.options.clientId),this.options.customHandleAcks=F.protocolVersion===5&&F.customHandleAcks?F.customHandleAcks:function(){arguments[3](0)},this.streamBuilder=C,this.messageIdProvider=this.options.messageIdProvider===void 0?new c:this.options.messageIdProvider,this.outgoingStore=F.outgoingStore||new p,this.incomingStore=F.incomingStore||new p,this.queueQoSZero=F.queueQoSZero===void 0||F.queueQoSZero,this._resubscribeTopics={},this.messageIdToTopic={},this.pingTimer=null,this.connected=!1,this.disconnecting=!1,this.queue=[],this.connackTimer=null,this.reconnectTimer=null,this._storeProcessing=!1,this._packetIdsDuringStoreProcessing={},this._storeProcessingQueue=[],this.outgoing={},this._firstConnection=!0,F.topicAliasMaximum>0&&(F.topicAliasMaximum>65535?y("MqttClient :: options.topicAliasMaximum is out of range"):this.topicAliasRecv=new s(F.topicAliasMaximum)),this.on("connect",function(){const J=this.queue;y("connect :: sending queued packets"),function $(){const U=J.shift();y("deliver :: entry %o",U);let K=null;if(!U)return void P._resubscribe();K=U.packet,y("deliver :: call _sendPacket for %o",K);let L=!0;K.messageId&&K.messageId!==0&&(P.messageIdProvider.register(K.messageId)||(L=!1)),L?P._sendPacket(K,function(O){U.cb&&U.cb(O),$()}):(y("messageId: %d has already used. The message is skipped and removed.",K.messageId),$())}()}),this.on("close",function(){y("close :: connected set to `false`"),this.connected=!1,y("close :: clearing connackTimer"),clearTimeout(this.connackTimer),y("close :: clearing ping timer"),P.pingTimer!==null&&(P.pingTimer.clear(),P.pingTimer=null),this.topicAliasRecv&&this.topicAliasRecv.clear(),y("close :: calling _setupReconnect"),this._setupReconnect()}),u.call(this),y("MqttClient :: setting up stream"),this._setupStream()}h(A,u),A.prototype._setupStream=function(){const C=this,F=new f,j=d.parser(this.options);let P=null;const J=[];function $(){if(J.length)w(U);else{const L=P;P=null,L()}}function U(){y("work :: getting next packet in queue");const L=J.shift();if(L)y("work :: packet pulled from queue"),C._handlePacket(L,$);else{y("work :: no packets in queue");const O=P;P=null,y("work :: done flag is %s",!!O),O&&O()}}y("_setupStream :: calling method to clear reconnect"),this._clearReconnect(),y("_setupStream :: using streamBuilder provided to client to create stream"),this.stream=this.streamBuilder(this),j.on("packet",function(L){y("parser :: on packet push to packets array."),J.push(L)}),F._write=function(L,O,H){P=H,y("writable stream :: parsing buffer"),j.parse(L),U()},y("_setupStream :: pipe stream to writable stream"),this.stream.pipe(F),this.stream.on("error",function(L){y("streamErrorHandler :: error",L.message),L.code?(y("streamErrorHandler :: emitting error"),C.emit("error",L)):E(L)}),this.stream.on("close",function(){var L;y("(%s)stream :: on close",C.options.clientId),(L=C.outgoing)&&(y("flushVolatile :: deleting volatile messages from the queue and setting their callbacks as error function"),Object.keys(L).forEach(function(O){L[O].volatile&&typeof L[O].cb=="function"&&(L[O].cb(new Error("Connection closed")),delete L[O])})),y("stream: emit close to MqttClient"),C.emit("close")}),y("_setupStream: sending packet `connect`");const K=Object.create(this.options);if(K.cmd="connect",this.topicAliasRecv&&(K.properties||(K.properties={}),this.topicAliasRecv&&(K.properties.topicAliasMaximum=this.topicAliasRecv.max)),X(this,K),j.on("error",this.emit.bind(this,"error")),this.options.properties){if(!this.options.properties.authenticationMethod&&this.options.properties.authenticationData)return C.end(()=>this.emit("error",new Error("Packet has no Authentication Method"))),this;this.options.properties.authenticationMethod&&this.options.authPacket&&typeof this.options.authPacket=="object"&&X(this,x({cmd:"auth",reasonCode:0},this.options.authPacket))}this.stream.setMaxListeners(1e3),clearTimeout(this.connackTimer),this.connackTimer=setTimeout(function(){y("!!connectTimeout hit!! Calling _cleanUp with force `true`"),C._cleanUp(!0)},this.options.connectTimeout)},A.prototype._handlePacket=function(C,F){const j=this.options;if(j.protocolVersion===5&&j.properties&&j.properties.maximumPacketSize&&j.properties.maximumPacketSize<C.length)return this.emit("error",new Error("exceeding packets size "+C.cmd)),this.end({reasonCode:149,properties:{reasonString:"Maximum packet size was exceeded"}}),this;switch(y("_handlePacket :: emitting packetreceive"),this.emit("packetreceive",C),C.cmd){case"publish":this._handlePublish(C,F);break;case"puback":case"pubrec":case"pubcomp":case"suback":case"unsuback":this._handleAck(C),F();break;case"pubrel":this._handlePubrel(C,F);break;case"connack":this._handleConnack(C),F();break;case"auth":this._handleAuth(C),F();break;case"pingresp":this._handlePingresp(C),F();break;case"disconnect":this._handleDisconnect(C),F()}},A.prototype._checkDisconnecting=function(C){return this.disconnecting&&(C&&C!==E?C(new Error("client disconnecting")):this.emit("error",new Error("client disconnecting"))),this.disconnecting},A.prototype.publish=function(C,F,j,P){y("publish :: message `%s` to topic `%s`",F,C);const J=this.options;if(typeof j=="function"&&(P=j,j=null),j=x({qos:0,retain:!1,dup:!1},j),this._checkDisconnecting(P))return this;const $=this,U=function(){let K=0;if((j.qos===1||j.qos===2)&&(K=$._nextId())===null)return y("No messageId left"),!1;const L={cmd:"publish",topic:C,payload:F,qos:j.qos,retain:j.retain,messageId:K,dup:j.dup};switch(J.protocolVersion===5&&(L.properties=j.properties),y("publish :: qos",j.qos),j.qos){case 1:case 2:$.outgoing[L.messageId]={volatile:!1,cb:P||E},y("MqttClient:publish: packet cmd: %s",L.cmd),$._sendPacket(L,void 0,j.cbStorePut);break;default:y("MqttClient:publish: packet cmd: %s",L.cmd),$._sendPacket(L,P,j.cbStorePut)}return!0};return(this._storeProcessing||this._storeProcessingQueue.length>0||!U())&&this._storeProcessingQueue.push({invoke:U,cbStorePut:j.cbStorePut,callback:P}),this},A.prototype.subscribe=function(){const C=this,F=new Array(arguments.length);for(let W=0;W<arguments.length;W++)F[W]=arguments[W];const j=[];let P=F.shift();const J=P.resubscribe;let $=F.pop()||E,U=F.pop();const K=this.options.protocolVersion;delete P.resubscribe,typeof P=="string"&&(P=[P]),typeof $!="function"&&(U=$,$=E);const L=g.validateTopics(P);if(L!==null)return k($,new Error("Invalid topic "+L)),this;if(this._checkDisconnecting($))return y("subscribe: discconecting true"),this;const O={qos:0};if(K===5&&(O.nl=!1,O.rap=!1,O.rh=0),U=x(O,U),Array.isArray(P)?P.forEach(function(W){if(y("subscribe: array topic %s",W),!Object.prototype.hasOwnProperty.call(C._resubscribeTopics,W)||C._resubscribeTopics[W].qos<U.qos||J){const Z={topic:W,qos:U.qos};K===5&&(Z.nl=U.nl,Z.rap=U.rap,Z.rh=U.rh,Z.properties=U.properties),y("subscribe: pushing topic `%s` and qos `%s` to subs list",Z.topic,Z.qos),j.push(Z)}}):Object.keys(P).forEach(function(W){if(y("subscribe: object topic %s",W),!Object.prototype.hasOwnProperty.call(C._resubscribeTopics,W)||C._resubscribeTopics[W].qos<P[W].qos||J){const Z={topic:W,qos:P[W].qos};K===5&&(Z.nl=P[W].nl,Z.rap=P[W].rap,Z.rh=P[W].rh,Z.properties=U.properties),y("subscribe: pushing `%s` to subs list",Z),j.push(Z)}}),!j.length)return $(null,[]),this;const H=function(){const W=C._nextId();if(W===null)return y("No messageId left"),!1;const Z={cmd:"subscribe",subscriptions:j,qos:1,retain:!1,dup:!1,messageId:W};if(U.properties&&(Z.properties=U.properties),C.options.resubscribe){y("subscribe :: resubscribe true");const re=[];j.forEach(function(oe){if(C.options.reconnectPeriod>0){const ae={qos:oe.qos};K===5&&(ae.nl=oe.nl||!1,ae.rap=oe.rap||!1,ae.rh=oe.rh||0,ae.properties=oe.properties),C._resubscribeTopics[oe.topic]=ae,re.push(oe.topic)}}),C.messageIdToTopic[Z.messageId]=re}return C.outgoing[Z.messageId]={volatile:!0,cb:function(re,oe){if(!re){const ae=oe.granted;for(let b=0;b<ae.length;b+=1)j[b].qos=ae[b]}$(re,j)}},y("subscribe :: call _sendPacket"),C._sendPacket(Z),!0};return(this._storeProcessing||this._storeProcessingQueue.length>0||!H())&&this._storeProcessingQueue.push({invoke:H,callback:$}),this},A.prototype.unsubscribe=function(){const C=this,F=new Array(arguments.length);for(let K=0;K<arguments.length;K++)F[K]=arguments[K];let j=F.shift(),P=F.pop()||E,J=F.pop();typeof j=="string"&&(j=[j]),typeof P!="function"&&(J=P,P=E);const $=g.validateTopics(j);if($!==null)return k(P,new Error("Invalid topic "+$)),this;if(C._checkDisconnecting(P))return this;const U=function(){const K=C._nextId();if(K===null)return y("No messageId left"),!1;const L={cmd:"unsubscribe",qos:1,messageId:K};return typeof j=="string"?L.unsubscriptions=[j]:Array.isArray(j)&&(L.unsubscriptions=j),C.options.resubscribe&&L.unsubscriptions.forEach(function(O){delete C._resubscribeTopics[O]}),typeof J=="object"&&J.properties&&(L.properties=J.properties),C.outgoing[L.messageId]={volatile:!0,cb:P},y("unsubscribe: call _sendPacket"),C._sendPacket(L),!0};return(this._storeProcessing||this._storeProcessingQueue.length>0||!U())&&this._storeProcessingQueue.push({invoke:U,callback:P}),this},A.prototype.end=function(C,F,j){const P=this;function J(){y("end :: (%s) :: finish :: calling _cleanUp with force %s",P.options.clientId,C),P._cleanUp(C,()=>{y("end :: finish :: calling process.nextTick on closeStores"),w(function(){y("end :: closeStores: closing incoming and outgoing stores"),P.disconnected=!0,P.incomingStore.close(function($){P.outgoingStore.close(function(U){if(y("end :: closeStores: emitting end"),P.emit("end"),j){const K=$||U;y("end :: closeStores: invoking callback with args"),j(K)}})}),P._deferredReconnect&&P._deferredReconnect()}.bind(P))},F)}return y("end :: (%s)",this.options.clientId),C!=null&&typeof C=="boolean"||(j=F||E,F=C,C=!1,typeof F!="object"&&(j=F,F=null,typeof j!="function"&&(j=E))),typeof F!="object"&&(j=F,F=null),y("end :: cb? %s",!!j),j=j||E,this.disconnecting?(j(),this):(this._clearReconnect(),this.disconnecting=!0,!C&&Object.keys(this.outgoing).length>0?(y("end :: (%s) :: calling finish in 10ms once outgoing is empty",P.options.clientId),this.once("outgoingEmpty",setTimeout.bind(null,J,10))):(y("end :: (%s) :: immediately calling finish",P.options.clientId),J()),this)},A.prototype.removeOutgoingMessage=function(C){const F=this.outgoing[C]?this.outgoing[C].cb:null;return delete this.outgoing[C],this.outgoingStore.del({messageId:C},function(){F(new Error("Message removed"))}),this},A.prototype.reconnect=function(C){y("client reconnect");const F=this,j=function(){C?(F.options.incomingStore=C.incomingStore,F.options.outgoingStore=C.outgoingStore):(F.options.incomingStore=null,F.options.outgoingStore=null),F.incomingStore=F.options.incomingStore||new p,F.outgoingStore=F.options.outgoingStore||new p,F.disconnecting=!1,F.disconnected=!1,F._deferredReconnect=null,F._reconnect()};return this.disconnecting&&!this.disconnected?this._deferredReconnect=j:j(),this},A.prototype._reconnect=function(){y("_reconnect: emitting reconnect to client"),this.emit("reconnect"),this.connected?(this.end(()=>{this._setupStream()}),y("client already connected. disconnecting first.")):(y("_reconnect: calling _setupStream"),this._setupStream())},A.prototype._setupReconnect=function(){const C=this;!C.disconnecting&&!C.reconnectTimer&&C.options.reconnectPeriod>0?(this.reconnecting||(y("_setupReconnect :: emit `offline` state"),this.emit("offline"),y("_setupReconnect :: set `reconnecting` to `true`"),this.reconnecting=!0),y("_setupReconnect :: setting reconnectTimer for %d ms",C.options.reconnectPeriod),C.reconnectTimer=setInterval(function(){y("reconnectTimer :: reconnect triggered!"),C._reconnect()},C.options.reconnectPeriod)):y("_setupReconnect :: doing nothing...")},A.prototype._clearReconnect=function(){y("_clearReconnect : clearing reconnect timer"),this.reconnectTimer&&(clearInterval(this.reconnectTimer),this.reconnectTimer=null)},A.prototype._cleanUp=function(C,F){const j=arguments[2];if(F&&(y("_cleanUp :: done callback provided for on stream close"),this.stream.on("close",F)),y("_cleanUp :: forced? %s",C),C)this.options.reconnectPeriod===0&&this.options.clean&&(P=this.outgoing)&&(y("flush: queue exists? %b",!!P),Object.keys(P).forEach(function(J){typeof P[J].cb=="function"&&(P[J].cb(new Error("Connection closed")),delete P[J])})),y("_cleanUp :: (%s) :: destroying stream",this.options.clientId),this.stream.destroy();else{const J=x({cmd:"disconnect"},j);y("_cleanUp :: (%s) :: call _sendPacket with disconnect packet",this.options.clientId),this._sendPacket(J,k.bind(null,this.stream.end.bind(this.stream)))}var P;this.disconnecting||(y("_cleanUp :: client not disconnecting. Clearing and resetting reconnect."),this._clearReconnect(),this._setupReconnect()),this.pingTimer!==null&&(y("_cleanUp :: clearing pingTimer"),this.pingTimer.clear(),this.pingTimer=null),F&&!this.connected&&(y("_cleanUp :: (%s) :: removing stream `done` callback `close` listener",this.options.clientId),this.stream.removeListener("close",F),F())},A.prototype._sendPacket=function(C,F,j){y("_sendPacket :: (%s) :: start",this.options.clientId),j=j||E,F=F||E;const P=function(J,$){if(J.options.protocolVersion===5&&$.cmd==="publish"){let U;$.properties&&(U=$.properties.topicAlias);const K=$.topic.toString();if(J.topicAliasSend)if(U){if(K.length!==0&&(y("applyTopicAlias :: register topic: %s - alias: %d",K,U),!J.topicAliasSend.put(K,U)))return y("applyTopicAlias :: error out of range. topic: %s - alias: %d",K,U),new Error("Sending Topic Alias out of range")}else K.length!==0&&(J.options.autoAssignTopicAlias?(U=J.topicAliasSend.getAliasByTopic(K))?($.topic="",$.properties=_e(he({},$.properties),{topicAlias:U}),y("applyTopicAlias :: auto assign(use) topic: %s - alias: %d",K,U)):(U=J.topicAliasSend.getLruAlias(),J.topicAliasSend.put(K,U),$.properties=_e(he({},$.properties),{topicAlias:U}),y("applyTopicAlias :: auto assign topic: %s - alias: %d",K,U)):J.options.autoUseTopicAlias&&(U=J.topicAliasSend.getAliasByTopic(K))&&($.topic="",$.properties=_e(he({},$.properties),{topicAlias:U}),y("applyTopicAlias :: auto use topic: %s - alias: %d",K,U)));else if(U)return y("applyTopicAlias :: error out of range. topic: %s - alias: %d",K,U),new Error("Sending Topic Alias out of range")}}(this,C);if(P)F(P);else{if(!this.connected)return C.cmd==="auth"?(this._shiftPingInterval(),void X(this,C,F)):(y("_sendPacket :: client not connected. Storing packet offline."),void this._storePacket(C,F,j));switch(this._shiftPingInterval(),C.cmd){case"publish":break;case"pubrel":return void V(this,C,F,j);default:return void X(this,C,F)}switch(C.qos){case 2:case 1:V(this,C,F,j);break;case 0:default:X(this,C,F)}y("_sendPacket :: (%s) :: end",this.options.clientId)}},A.prototype._storePacket=function(C,F,j){y("_storePacket :: packet: %o",C),y("_storePacket :: cb? %s",!!F),j=j||E;let P=C;if(P.cmd==="publish"){const J=D(this,P=m(C));if(J)return F&&F(J)}(P.qos||0)===0&&this.queueQoSZero||P.cmd!=="publish"?this.queue.push({packet:P,cb:F}):P.qos>0?(F=this.outgoing[P.messageId]?this.outgoing[P.messageId].cb:null,this.outgoingStore.put(P,function(J){if(J)return F&&F(J);j()})):F&&F(new Error("No connection to broker"))},A.prototype._setupPingTimer=function(){y("_setupPingTimer :: keepalive %d (seconds)",this.options.keepalive);const C=this;!this.pingTimer&&this.options.keepalive&&(this.pingResp=!0,this.pingTimer=v(function(){C._checkPing()},1e3*this.options.keepalive))},A.prototype._shiftPingInterval=function(){this.pingTimer&&this.options.keepalive&&this.options.reschedulePings&&this.pingTimer.reschedule(1e3*this.options.keepalive)},A.prototype._checkPing=function(){y("_checkPing :: checking ping..."),this.pingResp?(y("_checkPing :: ping response received. Clearing flag and sending `pingreq`"),this.pingResp=!1,this._sendPacket({cmd:"pingreq"})):(y("_checkPing :: calling _cleanUp with force true"),this._cleanUp(!0))},A.prototype._handlePingresp=function(){this.pingResp=!0},A.prototype._handleConnack=function(C){y("_handleConnack");const F=this.options,j=F.protocolVersion===5?C.reasonCode:C.returnCode;if(clearTimeout(this.connackTimer),delete this.topicAliasSend,C.properties){if(C.properties.topicAliasMaximum){if(C.properties.topicAliasMaximum>65535)return void this.emit("error",new Error("topicAliasMaximum from broker is out of range"));C.properties.topicAliasMaximum>0&&(this.topicAliasSend=new i(C.properties.topicAliasMaximum))}C.properties.serverKeepAlive&&F.keepalive&&(F.keepalive=C.properties.serverKeepAlive,this._shiftPingInterval()),C.properties.maximumPacketSize&&(F.properties||(F.properties={}),F.properties.maximumPacketSize=C.properties.maximumPacketSize)}if(j===0)this.reconnecting=!1,this._onConnect(C);else if(j>0){const P=new Error("Connection refused: "+I[j]);P.code=j,this.emit("error",P)}},A.prototype._handleAuth=function(C){const F=this.options.protocolVersion,j=F===5?C.reasonCode:C.returnCode;if(F!==5){const J=new Error("Protocol error: Auth packets are only supported in MQTT 5. Your version:"+F);return J.code=j,void this.emit("error",J)}const P=this;this.handleAuth(C,function(J,$){if(J)P.emit("error",J);else if(j===24)P.reconnecting=!1,P._sendPacket($);else{const U=new Error("Connection refused: "+I[j]);J.code=j,P.emit("error",U)}})},A.prototype.handleAuth=function(C,F){F()},A.prototype._handlePublish=function(C,F){y("_handlePublish: packet %o",C),F=F!==void 0?F:E;let j=C.topic.toString();const P=C.payload,J=C.qos,$=C.messageId,U=this,K=this.options,L=[0,16,128,131,135,144,145,151,153];if(this.options.protocolVersion===5){let O;if(C.properties&&(O=C.properties.topicAlias),O!==void 0)if(j.length===0){if(!(O>0&&O<=65535))return y("_handlePublish :: topic alias out of range. alias: %d",O),void this.emit("error",new Error("Received Topic Alias is out of range"));{const H=this.topicAliasRecv.getTopicByAlias(O);if(!H)return y("_handlePublish :: unregistered topic alias. alias: %d",O),void this.emit("error",new Error("Received unregistered Topic Alias"));y("_handlePublish :: topic complemented by alias. topic: %s - alias: %d",j=H,O)}}else{if(!this.topicAliasRecv.put(j,O))return y("_handlePublish :: topic alias out of range. alias: %d",O),void this.emit("error",new Error("Received Topic Alias is out of range"));y("_handlePublish :: registered topic: %s - alias: %d",j,O)}}switch(y("_handlePublish: qos %d",J),J){case 2:K.customHandleAcks(j,P,C,function(O,H){return O instanceof Error||(H=O,O=null),O?U.emit("error",O):L.indexOf(H)===-1?U.emit("error",new Error("Wrong reason code for pubrec")):void(H?U._sendPacket({cmd:"pubrec",messageId:$,reasonCode:H},F):U.incomingStore.put(C,function(){U._sendPacket({cmd:"pubrec",messageId:$},F)}))});break;case 1:K.customHandleAcks(j,P,C,function(O,H){return O instanceof Error||(H=O,O=null),O?U.emit("error",O):L.indexOf(H)===-1?U.emit("error",new Error("Wrong reason code for puback")):(H||U.emit("message",j,P,C),void U.handleMessage(C,function(W){if(W)return F&&F(W);U._sendPacket({cmd:"puback",messageId:$,reasonCode:H},F)}))});break;case 0:this.emit("message",j,P,C),this.handleMessage(C,F);break;default:y("_handlePublish: unknown QoS. Doing nothing.")}},A.prototype.handleMessage=function(C,F){F()},A.prototype._handleAck=function(C){const F=C.messageId,j=C.cmd;let P=null;const J=this.outgoing[F]?this.outgoing[F].cb:null,$=this;let U;if(J){switch(y("_handleAck :: packet type",j),j){case"pubcomp":case"puback":{const K=C.reasonCode;K&&K>0&&K!==16&&((U=new Error("Publish error: "+I[K])).code=K,J(U,C)),delete this.outgoing[F],this.outgoingStore.del(C,J),this.messageIdProvider.deallocate(F),this._invokeStoreProcessingQueue();break}case"pubrec":{P={cmd:"pubrel",qos:2,messageId:F};const K=C.reasonCode;K&&K>0&&K!==16?((U=new Error("Publish error: "+I[K])).code=K,J(U,C)):this._sendPacket(P);break}case"suback":delete this.outgoing[F],this.messageIdProvider.deallocate(F);for(let K=0;K<C.granted.length;K++)if(128&C.granted[K]){const L=this.messageIdToTopic[F];L&&L.forEach(function(O){delete $._resubscribeTopics[O]})}this._invokeStoreProcessingQueue(),J(null,C);break;case"unsuback":delete this.outgoing[F],this.messageIdProvider.deallocate(F),this._invokeStoreProcessingQueue(),J(null);break;default:$.emit("error",new Error("unrecognized packet type"))}this.disconnecting&&Object.keys(this.outgoing).length===0&&this.emit("outgoingEmpty")}else y("_handleAck :: Server sent an ack in error. Ignoring.")},A.prototype._handlePubrel=function(C,F){y("handling pubrel packet"),F=F!==void 0?F:E;const j=this,P={cmd:"pubcomp",messageId:C.messageId};j.incomingStore.get(C,function(J,$){J?j._sendPacket(P,F):(j.emit("message",$.topic,$.payload,$),j.handleMessage($,function(U){if(U)return F(U);j.incomingStore.del($,E),j._sendPacket(P,F)}))})},A.prototype._handleDisconnect=function(C){this.emit("disconnect",C)},A.prototype._nextId=function(){return this.messageIdProvider.allocate()},A.prototype.getLastMessageId=function(){return this.messageIdProvider.getLastAllocated()},A.prototype._resubscribe=function(){y("_resubscribe");const C=Object.keys(this._resubscribeTopics);if(!this._firstConnection&&(this.options.clean||this.options.protocolVersion===5&&!this.connackPacket.sessionPresent)&&C.length>0)if(this.options.resubscribe)if(this.options.protocolVersion===5){y("_resubscribe: protocolVersion 5");for(let F=0;F<C.length;F++){const j={};j[C[F]]=this._resubscribeTopics[C[F]],j.resubscribe=!0,this.subscribe(j,{properties:j[C[F]].properties})}}else this._resubscribeTopics.resubscribe=!0,this.subscribe(this._resubscribeTopics);else this._resubscribeTopics={};this._firstConnection=!1},A.prototype._onConnect=function(C){if(this.disconnected)return void this.emit("connect",C);const F=this;this.connackPacket=C,this.messageIdProvider.clear(),this._setupPingTimer(),this.connected=!0,function j(){let P=F.outgoingStore.createStream();function J(){F._storeProcessing=!1,F._packetIdsDuringStoreProcessing={}}function $(){P.destroy(),P=null,F._flushStoreProcessingQueue(),J()}F.once("close",$),P.on("error",function(U){J(),F._flushStoreProcessingQueue(),F.removeListener("close",$),F.emit("error",U)}),P.on("end",function(){let U=!0;for(const K in F._packetIdsDuringStoreProcessing)if(!F._packetIdsDuringStoreProcessing[K]){U=!1;break}U?(J(),F.removeListener("close",$),F._invokeAllStoreProcessingQueue(),F.emit("connect",C)):j()}),function U(){if(!P)return;F._storeProcessing=!0;const K=P.read(1);let L;K?F._packetIdsDuringStoreProcessing[K.messageId]?U():F.disconnecting||F.reconnectTimer?P.destroy&&P.destroy():(L=F.outgoing[K.messageId]?F.outgoing[K.messageId].cb:null,F.outgoing[K.messageId]={volatile:!1,cb:function(O,H){L&&L(O,H),U()}},F._packetIdsDuringStoreProcessing[K.messageId]=!0,F.messageIdProvider.register(K.messageId)?F._sendPacket(K):y("messageId: %d has already used.",K.messageId)):P.once("readable",U)}()}()},A.prototype._invokeStoreProcessingQueue=function(){if(this._storeProcessingQueue.length>0){const C=this._storeProcessingQueue[0];if(C&&C.invoke())return this._storeProcessingQueue.shift(),!0}return!1},A.prototype._invokeAllStoreProcessingQueue=function(){for(;this._invokeStoreProcessingQueue(););},A.prototype._flushStoreProcessingQueue=function(){for(const C of this._storeProcessingQueue)C.cbStorePut&&C.cbStorePut(new Error("Connection closed")),C.callback&&C.callback(new Error("Connection closed"));this._storeProcessingQueue.splice(0)},n.exports=A}).call(this)}).call(this,t("_process"),typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"./default-message-id-provider":7,"./store":8,"./topic-alias-recv":9,"./topic-alias-send":10,"./validations":11,_process:50,debug:18,events:22,inherits:24,"mqtt-packet":40,"readable-stream":69,reinterval:70,"rfdc/default":71,xtend:81}],2:[function(t,n,l){const{Buffer:a}=t("buffer"),o=t("readable-stream").Transform,u=t("duplexify");let p,s,i,d=!1;n.exports=function(c,f){if(f.hostname=f.hostname||f.host,!f.hostname)throw new Error("Could not determine host. Specify host manually.");const h=f.protocolId==="MQIsdp"&&f.protocolVersion===3?"mqttv3.1":"mqtt";(function(m){m.hostname||(m.hostname="localhost"),m.path||(m.path="/"),m.wsOptions||(m.wsOptions={})})(f);const v=function(m,g){const x=m.protocol==="alis"?"wss":"ws";let y=x+"://"+m.hostname+m.path;return m.port&&m.port!==80&&m.port!==443&&(y=x+"://"+m.hostname+":"+m.port+m.path),typeof m.transformWsUrl=="function"&&(y=m.transformWsUrl(y,m,g)),y}(f,c);return(p=f.my).connectSocket({url:v,protocols:h}),s=function(){const m=new o;return m._write=function(g,x,y){p.sendSocketMessage({data:g.buffer,success:function(){y()},fail:function(){y(new Error)}})},m._flush=function(g){p.closeSocket({success:function(){g()}})},m}(),i=u.obj(),d||(d=!0,p.onSocketOpen(function(){i.setReadable(s),i.setWritable(s),i.emit("connect")}),p.onSocketMessage(function(m){if(typeof m.data=="string"){const g=a.from(m.data,"base64");s.push(g)}else{const g=new FileReader;g.addEventListener("load",function(){let x=g.result;x=x instanceof ArrayBuffer?a.from(x):a.from(x,"utf8"),s.push(x)}),g.readAsArrayBuffer(m.data)}}),p.onSocketClose(function(){i.end(),i.destroy()}),p.onSocketError(function(m){i.destroy(m)})),i}},{buffer:17,duplexify:20,"readable-stream":69}],3:[function(t,n,l){const a=t("net"),o=t("debug")("mqttjs:tcp");n.exports=function(u,p){p.port=p.port||1883,p.hostname=p.hostname||p.host||"localhost";const s=p.port,i=p.hostname;return o("port %d and host %s",s,i),a.createConnection(s,i)}},{debug:18,net:16}],4:[function(t,n,l){const a=t("tls"),o=t("net"),u=t("debug")("mqttjs:tls");n.exports=function(p,s){s.port=s.port||8883,s.host=s.hostname||s.host||"localhost",o.isIP(s.host)===0&&(s.servername=s.host),s.rejectUnauthorized=s.rejectUnauthorized!==!1,delete s.path,u("port %d host %s rejectUnauthorized %b",s.port,s.host,s.rejectUnauthorized);const i=a.connect(s);function d(c){s.rejectUnauthorized&&p.emit("error",c),i.end()}return i.on("secureConnect",function(){s.rejectUnauthorized&&!i.authorized?i.emit("error",new Error("TLS not authorized")):i.removeListener("error",d)}),i.on("error",d),i}},{debug:18,net:16,tls:16}],5:[function(t,n,l){(function(a){(function(){const{Buffer:o}=t("buffer"),u=t("ws"),p=t("debug")("mqttjs:ws"),s=t("duplexify"),i=t("readable-stream").Transform,d=["rejectUnauthorized","ca","cert","key","pfx","passphrase"],c=a!==void 0&&a.title==="browser"||typeof __webpack_require__=="function";function f(v,m){let g=v.protocol+"://"+v.hostname+":"+v.port+v.path;return typeof v.transformWsUrl=="function"&&(g=v.transformWsUrl(g,v,m)),g}function h(v){const m=v;return v.hostname||(m.hostname="localhost"),v.port||(v.protocol==="wss"?m.port=443:m.port=80),v.path||(m.path="/"),v.wsOptions||(m.wsOptions={}),c||v.protocol!=="wss"||d.forEach(function(g){Object.prototype.hasOwnProperty.call(v,g)&&!Object.prototype.hasOwnProperty.call(v.wsOptions,g)&&(m.wsOptions[g]=v[g])}),m}n.exports=c?function(v,m){let g;p("browserStreamBuilder");const x=function(C){const F=h(C);if(F.hostname||(F.hostname=F.host),!F.hostname){if(typeof document=="undefined")throw new Error("Could not determine host. Specify host manually.");const j=new URL(document.URL);F.hostname=j.hostname,F.port||(F.port=j.port)}return F.objectMode===void 0&&(F.objectMode=!(F.binary===!0||F.binary===void 0)),F}(m).browserBufferSize||524288,y=m.browserBufferTimeout||1e3,w=!m.objectMode,k=function(C,F){const j=F.protocolId==="MQIsdp"&&F.protocolVersion===3?"mqttv3.1":"mqtt",P=f(F,C),J=new WebSocket(P,[j]);return J.binaryType="arraybuffer",J}(v,m),T=function(C,F,j){const P=new i({objectModeMode:C.objectMode});return P._write=F,P._flush=j,P}(m,function C(F,j,P){k.bufferedAmount>x&&setTimeout(C,y,F,j,P),w&&typeof F=="string"&&(F=o.from(F,"utf8"));try{k.send(F)}catch(J){return P(J)}P()},function(C){k.close(),C()});m.objectMode||(T._writev=A),T.on("close",()=>{k.close()});const I=k.addEventListener!==void 0;function D(){g.setReadable(T),g.setWritable(T),g.emit("connect")}function X(){g.end(),g.destroy()}function V(C){g.destroy(C)}function E(C){let F=C.data;F=F instanceof ArrayBuffer?o.from(F):o.from(F,"utf8"),T.push(F)}function A(C,F){const j=new Array(C.length);for(let P=0;P<C.length;P++)typeof C[P].chunk=="string"?j[P]=o.from(C[P],"utf8"):j[P]=C[P].chunk;this._write(o.concat(j),"binary",F)}return k.readyState===k.OPEN?g=T:(g=g=s(void 0,void 0,m),m.objectMode||(g._writev=A),I?k.addEventListener("open",D):k.onopen=D),g.socket=k,I?(k.addEventListener("close",X),k.addEventListener("error",V),k.addEventListener("message",E)):(k.onclose=X,k.onerror=V,k.onmessage=E),g}:function(v,m){p("streamBuilder");const g=h(m),x=f(g,v),y=function(k,T,I){p("createWebSocket"),p("protocol: "+I.protocolId+" "+I.protocolVersion);const D=I.protocolId==="MQIsdp"&&I.protocolVersion===3?"mqttv3.1":"mqtt";return p("creating new Websocket for url: "+T+" and protocol: "+D),new u(T,[D],I.wsOptions)}(0,x,g),w=u.createWebSocketStream(y,g.wsOptions);return w.url=x,y.on("close",()=>{w.destroy()}),w}}).call(this)}).call(this,t("_process"))},{_process:50,buffer:17,debug:18,duplexify:20,"readable-stream":69,ws:80}],6:[function(t,n,l){const{Buffer:a}=t("buffer"),o=t("readable-stream").Transform,u=t("duplexify");let p,s,i;n.exports=function(d,c){if(c.hostname=c.hostname||c.host,!c.hostname)throw new Error("Could not determine host. Specify host manually.");const f=c.protocolId==="MQIsdp"&&c.protocolVersion===3?"mqttv3.1":"mqtt";(function(m){m.hostname||(m.hostname="localhost"),m.path||(m.path="/"),m.wsOptions||(m.wsOptions={})})(c);const h=function(m,g){const x=m.protocol==="wxs"?"wss":"ws";let y=x+"://"+m.hostname+m.path;return m.port&&m.port!==80&&m.port!==443&&(y=x+"://"+m.hostname+":"+m.port+m.path),typeof m.transformWsUrl=="function"&&(y=m.transformWsUrl(y,m,g)),y}(c,d);p=wx.connectSocket({url:h,protocols:[f]}),s=function(){const m=new o;return m._write=function(g,x,y){p.send({data:g.buffer,success:function(){y()},fail:function(w){y(new Error(w))}})},m._flush=function(g){p.close({success:function(){g()}})},m}(),(i=u.obj())._destroy=function(m,g){p.close({success:function(){g&&g(m)}})};const v=i.destroy;return i.destroy=function(){i.destroy=v;const m=this;setTimeout(function(){p.close({fail:function(){m._destroy(new Error)}})},0)}.bind(i),p.onOpen(function(){i.setReadable(s),i.setWritable(s),i.emit("connect")}),p.onMessage(function(m){let g=m.data;g=g instanceof ArrayBuffer?a.from(g):a.from(g,"utf8"),s.push(g)}),p.onClose(function(){i.end(),i.destroy()}),p.onError(function(m){i.destroy(new Error(m.errMsg))}),i}},{buffer:17,duplexify:20,"readable-stream":69}],7:[function(t,n,l){function a(){if(!(this instanceof a))return new a;this.nextId=Math.max(1,Math.floor(65535*Math.random()))}a.prototype.allocate=function(){const o=this.nextId++;return this.nextId===65536&&(this.nextId=1),o},a.prototype.getLastAllocated=function(){return this.nextId===1?65535:this.nextId-1},a.prototype.register=function(o){return!0},a.prototype.deallocate=function(o){},a.prototype.clear=function(){},n.exports=a},{}],8:[function(t,n,l){const a=t("xtend"),o=t("readable-stream").Readable,u={objectMode:!0},p={clean:!0};function s(i){if(!(this instanceof s))return new s(i);this.options=i||{},this.options=a(p,i),this._inflights=new Map}s.prototype.put=function(i,d){return this._inflights.set(i.messageId,i),d&&d(),this},s.prototype.createStream=function(){const i=new o(u),d=[];let c=!1,f=0;return this._inflights.forEach(function(h,v){d.push(h)}),i._read=function(){!c&&f<d.length?this.push(d[f++]):this.push(null)},i.destroy=function(){if(c)return;const h=this;c=!0,setTimeout(function(){h.emit("close")},0)},i},s.prototype.del=function(i,d){return(i=this._inflights.get(i.messageId))?(this._inflights.delete(i.messageId),d(null,i)):d&&d(new Error("missing packet")),this},s.prototype.get=function(i,d){return(i=this._inflights.get(i.messageId))?d(null,i):d&&d(new Error("missing packet")),this},s.prototype.close=function(i){this.options.clean&&(this._inflights=null),i&&i()},n.exports=s},{"readable-stream":69,xtend:81}],9:[function(t,n,l){function a(o){if(!(this instanceof a))return new a(o);this.aliasToTopic={},this.max=o}a.prototype.put=function(o,u){return!(u===0||u>this.max)&&(this.aliasToTopic[u]=o,this.length=Object.keys(this.aliasToTopic).length,!0)},a.prototype.getTopicByAlias=function(o){return this.aliasToTopic[o]},a.prototype.clear=function(){this.aliasToTopic={}},n.exports=a},{}],10:[function(t,n,l){const a=t("lru-cache"),o=t("number-allocator").NumberAllocator;function u(p){if(!(this instanceof u))return new u(p);p>0&&(this.aliasToTopic=new a({max:p}),this.topicToAlias={},this.numberAllocator=new o(1,p),this.max=p,this.length=0)}u.prototype.put=function(p,s){if(s===0||s>this.max)return!1;const i=this.aliasToTopic.get(s);return i&&delete this.topicToAlias[i],this.aliasToTopic.set(s,p),this.topicToAlias[p]=s,this.numberAllocator.use(s),this.length=this.aliasToTopic.length,!0},u.prototype.getTopicByAlias=function(p){return this.aliasToTopic.get(p)},u.prototype.getAliasByTopic=function(p){const s=this.topicToAlias[p];return s!==void 0&&this.aliasToTopic.get(s),s},u.prototype.clear=function(){this.aliasToTopic.reset(),this.topicToAlias={},this.numberAllocator.clear(),this.length=0},u.prototype.getLruAlias=function(){return this.numberAllocator.firstVacant()||this.aliasToTopic.keys()[this.aliasToTopic.length-1]},n.exports=u},{"lru-cache":37,"number-allocator":46}],11:[function(t,n,l){function a(o){const u=o.split("/");for(let p=0;p<u.length;p++)if(u[p]!=="+"){if(u[p]==="#")return p===u.length-1;if(u[p].indexOf("+")!==-1||u[p].indexOf("#")!==-1)return!1}return!0}n.exports={validateTopics:function(o){if(o.length===0)return"empty_topic_list";for(let u=0;u<o.length;u++)if(!a(o[u]))return o[u];return null}}},{}],12:[function(t,n,l){(function(a){(function(){const o=t("../client"),u=t("../store"),p=t("url"),s=t("xtend"),i=t("debug")("mqttjs"),d={};function c(f,h){if(i("connecting to an MQTT broker..."),typeof f!="object"||h||(h=f,f=null),h=h||{},f){const m=p.parse(f,!0);if(m.port!=null&&(m.port=Number(m.port)),(h=s(m,h)).protocol===null)throw new Error("Missing protocol");h.protocol=h.protocol.replace(/:$/,"")}if(function(m){let g;m.auth&&((g=m.auth.match(/^(.+):(.+)$/))?(m.username=g[1],m.password=g[2]):m.username=m.auth)}(h),h.query&&typeof h.query.clientId=="string"&&(h.clientId=h.query.clientId),h.cert&&h.key){if(!h.protocol)throw new Error("Missing secure protocol key");if(["mqtts","wss","wxs","alis"].indexOf(h.protocol)===-1)switch(h.protocol){case"mqtt":h.protocol="mqtts";break;case"ws":h.protocol="wss";break;case"wx":h.protocol="wxs";break;case"ali":h.protocol="alis";break;default:throw new Error('Unknown protocol for secure connection: "'+h.protocol+'"!')}}if(!d[h.protocol]){const m=["mqtts","wss"].indexOf(h.protocol)!==-1;h.protocol=["mqtt","mqtts","ws","wss","wx","wxs","ali","alis"].filter(function(g,x){return(!m||x%2!=0)&&typeof d[g]=="function"})[0]}if(h.clean===!1&&!h.clientId)throw new Error("Missing clientId for unclean clients");h.protocol&&(h.defaultProtocol=h.protocol);const v=new o(function(m){return h.servers&&(m._reconnectCount&&m._reconnectCount!==h.servers.length||(m._reconnectCount=0),h.host=h.servers[m._reconnectCount].host,h.port=h.servers[m._reconnectCount].port,h.protocol=h.servers[m._reconnectCount].protocol?h.servers[m._reconnectCount].protocol:h.defaultProtocol,h.hostname=h.host,m._reconnectCount++),i("calling streambuilder for",h.protocol),d[h.protocol](m,h)},h);return v.on("error",function(){}),v}a!==void 0&&a.title!=="browser"||typeof __webpack_require__!="function"?(d.mqtt=t("./tcp"),d.tcp=t("./tcp"),d.ssl=t("./tls"),d.tls=t("./tls"),d.mqtts=t("./tls")):(d.wx=t("./wx"),d.wxs=t("./wx"),d.ali=t("./ali"),d.alis=t("./ali")),d.ws=t("./ws"),d.wss=t("./ws"),n.exports=c,n.exports.connect=c,n.exports.MqttClient=o,n.exports.Store=u}).call(this)}).call(this,t("_process"))},{"../client":1,"../store":8,"./ali":2,"./tcp":3,"./tls":4,"./ws":5,"./wx":6,_process:50,debug:18,url:76,xtend:81}],13:[function(t,n,l){l.byteLength=function(f){var h=d(f),v=h[0],m=h[1];return 3*(v+m)/4-m},l.toByteArray=function(f){var h,v,m=d(f),g=m[0],x=m[1],y=new u(function(T,I,D){return 3*(I+D)/4-D}(0,g,x)),w=0,k=x>0?g-4:g;for(v=0;v<k;v+=4)h=o[f.charCodeAt(v)]<<18|o[f.charCodeAt(v+1)]<<12|o[f.charCodeAt(v+2)]<<6|o[f.charCodeAt(v+3)],y[w++]=h>>16&255,y[w++]=h>>8&255,y[w++]=255&h;return x===2&&(h=o[f.charCodeAt(v)]<<2|o[f.charCodeAt(v+1)]>>4,y[w++]=255&h),x===1&&(h=o[f.charCodeAt(v)]<<10|o[f.charCodeAt(v+1)]<<4|o[f.charCodeAt(v+2)]>>2,y[w++]=h>>8&255,y[w++]=255&h),y},l.fromByteArray=function(f){for(var h,v=f.length,m=v%3,g=[],x=0,y=v-m;x<y;x+=16383)g.push(c(f,x,x+16383>y?y:x+16383));return m===1?(h=f[v-1],g.push(a[h>>2]+a[h<<4&63]+"==")):m===2&&(h=(f[v-2]<<8)+f[v-1],g.push(a[h>>10]+a[h>>4&63]+a[h<<2&63]+"=")),g.join("")};for(var a=[],o=[],u=typeof Uint8Array!="undefined"?Uint8Array:Array,p="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,i=p.length;s<i;++s)a[s]=p[s],o[p.charCodeAt(s)]=s;function d(f){var h=f.length;if(h%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var v=f.indexOf("=");return v===-1&&(v=h),[v,v===h?0:4-v%4]}function c(f,h,v){for(var m,g,x=[],y=h;y<v;y+=3)m=(f[y]<<16&16711680)+(f[y+1]<<8&65280)+(255&f[y+2]),x.push(a[(g=m)>>18&63]+a[g>>12&63]+a[g>>6&63]+a[63&g]);return x.join("")}o[45]=62,o[95]=63},{}],14:[function(t,n,l){const{Buffer:a}=t("buffer"),o=Symbol.for("BufferList");function u(p){if(!(this instanceof u))return new u(p);u._init.call(this,p)}u._init=function(p){Object.defineProperty(this,o,{value:!0}),this._bufs=[],this.length=0,p&&this.append(p)},u.prototype._new=function(p){return new u(p)},u.prototype._offset=function(p){if(p===0)return[0,0];let s=0;for(let i=0;i<this._bufs.length;i++){const d=s+this._bufs[i].length;if(p<d||i===this._bufs.length-1)return[i,p-s];s=d}},u.prototype._reverseOffset=function(p){const s=p[0];let i=p[1];for(let d=0;d<s;d++)i+=this._bufs[d].length;return i},u.prototype.get=function(p){if(p>this.length||p<0)return;const s=this._offset(p);return this._bufs[s[0]][s[1]]},u.prototype.slice=function(p,s){return typeof p=="number"&&p<0&&(p+=this.length),typeof s=="number"&&s<0&&(s+=this.length),this.copy(null,0,p,s)},u.prototype.copy=function(p,s,i,d){if((typeof i!="number"||i<0)&&(i=0),(typeof d!="number"||d>this.length)&&(d=this.length),i>=this.length||d<=0)return p||a.alloc(0);const c=!!p,f=this._offset(i),h=d-i;let v=h,m=c&&s||0,g=f[1];if(i===0&&d===this.length){if(!c)return this._bufs.length===1?this._bufs[0]:a.concat(this._bufs,this.length);for(let x=0;x<this._bufs.length;x++)this._bufs[x].copy(p,m),m+=this._bufs[x].length;return p}if(v<=this._bufs[f[0]].length-g)return c?this._bufs[f[0]].copy(p,s,g,g+v):this._bufs[f[0]].slice(g,g+v);c||(p=a.allocUnsafe(h));for(let x=f[0];x<this._bufs.length;x++){const y=this._bufs[x].length-g;if(!(v>y)){this._bufs[x].copy(p,m,g,g+v),m+=y;break}this._bufs[x].copy(p,m,g),m+=y,v-=y,g&&(g=0)}return p.length>m?p.slice(0,m):p},u.prototype.shallowSlice=function(p,s){if(p=p||0,s=typeof s!="number"?this.length:s,p<0&&(p+=this.length),s<0&&(s+=this.length),p===s)return this._new();const i=this._offset(p),d=this._offset(s),c=this._bufs.slice(i[0],d[0]+1);return d[1]===0?c.pop():c[c.length-1]=c[c.length-1].slice(0,d[1]),i[1]!==0&&(c[0]=c[0].slice(i[1])),this._new(c)},u.prototype.toString=function(p,s,i){return this.slice(s,i).toString(p)},u.prototype.consume=function(p){if(p=Math.trunc(p),Number.isNaN(p)||p<=0)return this;for(;this._bufs.length;){if(!(p>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(p),this.length-=p;break}p-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},u.prototype.duplicate=function(){const p=this._new();for(let s=0;s<this._bufs.length;s++)p.append(this._bufs[s]);return p},u.prototype.append=function(p){if(p==null)return this;if(p.buffer)this._appendBuffer(a.from(p.buffer,p.byteOffset,p.byteLength));else if(Array.isArray(p))for(let s=0;s<p.length;s++)this.append(p[s]);else if(this._isBufferList(p))for(let s=0;s<p._bufs.length;s++)this.append(p._bufs[s]);else typeof p=="number"&&(p=p.toString()),this._appendBuffer(a.from(p));return this},u.prototype._appendBuffer=function(p){this._bufs.push(p),this.length+=p.length},u.prototype.indexOf=function(p,s,i){if(i===void 0&&typeof s=="string"&&(i=s,s=void 0),typeof p=="function"||Array.isArray(p))throw new TypeError('The "value" argument must be one of type string, Buffer, BufferList, or Uint8Array.');if(typeof p=="number"?p=a.from([p]):typeof p=="string"?p=a.from(p,i):this._isBufferList(p)?p=p.slice():Array.isArray(p.buffer)?p=a.from(p.buffer,p.byteOffset,p.byteLength):a.isBuffer(p)||(p=a.from(p)),s=Number(s||0),isNaN(s)&&(s=0),s<0&&(s=this.length+s),s<0&&(s=0),p.length===0)return s>this.length?this.length:s;const d=this._offset(s);let c=d[0],f=d[1];for(;c<this._bufs.length;c++){const h=this._bufs[c];for(;f<h.length;)if(h.length-f>=p.length){const v=h.indexOf(p,f);if(v!==-1)return this._reverseOffset([c,v]);f=h.length-p.length+1}else{const v=this._reverseOffset([c,f]);if(this._match(v,p))return v;f++}f=0}return-1},u.prototype._match=function(p,s){if(this.length-p<s.length)return!1;for(let i=0;i<s.length;i++)if(this.get(p+i)!==s[i])return!1;return!0},function(){const p={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1,readIntBE:null,readIntLE:null,readUIntBE:null,readUIntLE:null};for(const s in p)(function(i){u.prototype[i]=p[i]===null?function(d,c){return this.slice(d,d+c)[i](0,c)}:function(d=0){return this.slice(d,d+p[i])[i](0)}})(s)}(),u.prototype._isBufferList=function(p){return p instanceof u||u.isBufferList(p)},u.isBufferList=function(p){return p!=null&&p[o]},n.exports=u},{buffer:17}],15:[function(t,n,l){const a=t("readable-stream").Duplex,o=t("inherits"),u=t("./BufferList");function p(s){if(!(this instanceof p))return new p(s);if(typeof s=="function"){this._callback=s;const i=function(d){this._callback&&(this._callback(d),this._callback=null)}.bind(this);this.on("pipe",function(d){d.on("error",i)}),this.on("unpipe",function(d){d.removeListener("error",i)}),s=null}u._init.call(this,s),a.call(this)}o(p,a),Object.assign(p.prototype,u.prototype),p.prototype._new=function(s){return new p(s)},p.prototype._write=function(s,i,d){this._appendBuffer(s),typeof d=="function"&&d()},p.prototype._read=function(s){if(!this.length)return this.push(null);s=Math.min(s,this.length),this.push(this.slice(0,s)),this.consume(s)},p.prototype.end=function(s){a.prototype.end.call(this,s),this._callback&&(this._callback(null,this.slice()),this._callback=null)},p.prototype._destroy=function(s,i){this._bufs.length=0,this.length=0,i(s)},p.prototype._isBufferList=function(s){return s instanceof p||s instanceof u||p.isBufferList(s)},p.isBufferList=u.isBufferList,n.exports=p,n.exports.BufferListStream=p,n.exports.BufferList=u},{"./BufferList":14,inherits:24,"readable-stream":69}],16:[function(t,n,l){},{}],17:[function(t,n,l){(function(a){(function(){var o=t("base64-js"),u=t("ieee754");l.Buffer=i,l.SlowBuffer=function(b){return+b!=b&&(b=0),i.alloc(+b)},l.INSPECT_MAX_BYTES=50;var p=2147483647;function s(b){if(b>p)throw new RangeError('The value "'+b+'" is invalid for option "size"');var _=new Uint8Array(b);return _.__proto__=i.prototype,_}function i(b,_,R){if(typeof b=="number"){if(typeof _=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return f(b)}return d(b,_,R)}function d(b,_,R){if(typeof b=="string")return function(te,se){if(typeof se=="string"&&se!==""||(se="utf8"),!i.isEncoding(se))throw new TypeError("Unknown encoding: "+se);var z=0|m(te,se),S=s(z),B=S.write(te,se);return B!==z&&(S=S.slice(0,B)),S}(b,_);if(ArrayBuffer.isView(b))return h(b);if(b==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof b);if(oe(b,ArrayBuffer)||b&&oe(b.buffer,ArrayBuffer))return function(te,se,z){if(se<0||te.byteLength<se)throw new RangeError('"offset" is outside of buffer bounds');if(te.byteLength<se+(z||0))throw new RangeError('"length" is outside of buffer bounds');var S;return S=se===void 0&&z===void 0?new Uint8Array(te):z===void 0?new Uint8Array(te,se):new Uint8Array(te,se,z),S.__proto__=i.prototype,S}(b,_,R);if(typeof b=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var G=b.valueOf&&b.valueOf();if(G!=null&&G!==b)return i.from(G,_,R);var ee=function(te){if(i.isBuffer(te)){var se=0|v(te.length),z=s(se);return z.length===0||te.copy(z,0,0,se),z}if(te.length!==void 0)return typeof te.length!="number"||ae(te.length)?s(0):h(te);if(te.type==="Buffer"&&Array.isArray(te.data))return h(te.data)}(b);if(ee)return ee;if(typeof Symbol!="undefined"&&Symbol.toPrimitive!=null&&typeof b[Symbol.toPrimitive]=="function")return i.from(b[Symbol.toPrimitive]("string"),_,R);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof b)}function c(b){if(typeof b!="number")throw new TypeError('"size" argument must be of type number');if(b<0)throw new RangeError('The value "'+b+'" is invalid for option "size"')}function f(b){return c(b),s(b<0?0:0|v(b))}function h(b){for(var _=b.length<0?0:0|v(b.length),R=s(_),G=0;G<_;G+=1)R[G]=255&b[G];return R}function v(b){if(b>=p)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+p.toString(16)+" bytes");return 0|b}function m(b,_){if(i.isBuffer(b))return b.length;if(ArrayBuffer.isView(b)||oe(b,ArrayBuffer))return b.byteLength;if(typeof b!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof b);var R=b.length,G=arguments.length>2&&arguments[2]===!0;if(!G&&R===0)return 0;for(var ee=!1;;)switch(_){case"ascii":case"latin1":case"binary":return R;case"utf8":case"utf-8":return W(b).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*R;case"hex":return R>>>1;case"base64":return Z(b).length;default:if(ee)return G?-1:W(b).length;_=(""+_).toLowerCase(),ee=!0}}function g(b,_,R){var G=b[_];b[_]=b[R],b[R]=G}function x(b,_,R,G,ee){if(b.length===0)return-1;if(typeof R=="string"?(G=R,R=0):R>2147483647?R=2147483647:R<-2147483648&&(R=-2147483648),ae(R=+R)&&(R=ee?0:b.length-1),R<0&&(R=b.length+R),R>=b.length){if(ee)return-1;R=b.length-1}else if(R<0){if(!ee)return-1;R=0}if(typeof _=="string"&&(_=i.from(_,G)),i.isBuffer(_))return _.length===0?-1:y(b,_,R,G,ee);if(typeof _=="number")return _&=255,typeof Uint8Array.prototype.indexOf=="function"?ee?Uint8Array.prototype.indexOf.call(b,_,R):Uint8Array.prototype.lastIndexOf.call(b,_,R):y(b,[_],R,G,ee);throw new TypeError("val must be string, number or Buffer")}function y(b,_,R,G,ee){var te,se=1,z=b.length,S=_.length;if(G!==void 0&&((G=String(G).toLowerCase())==="ucs2"||G==="ucs-2"||G==="utf16le"||G==="utf-16le")){if(b.length<2||_.length<2)return-1;se=2,z/=2,S/=2,R/=2}function B(ce,me){return se===1?ce[me]:ce.readUInt16BE(me*se)}if(ee){var Y=-1;for(te=R;te<z;te++)if(B(b,te)===B(_,Y===-1?0:te-Y)){if(Y===-1&&(Y=te),te-Y+1===S)return Y*se}else Y!==-1&&(te-=te-Y),Y=-1}else for(R+S>z&&(R=z-S),te=R;te>=0;te--){for(var ie=!0,ue=0;ue<S;ue++)if(B(b,te+ue)!==B(_,ue)){ie=!1;break}if(ie)return te}return-1}function w(b,_,R,G){R=Number(R)||0;var ee=b.length-R;G?(G=Number(G))>ee&&(G=ee):G=ee;var te=_.length;G>te/2&&(G=te/2);for(var se=0;se<G;++se){var z=parseInt(_.substr(2*se,2),16);if(ae(z))return se;b[R+se]=z}return se}function k(b,_,R,G){return re(W(_,b.length-R),b,R,G)}function T(b,_,R,G){return re(function(ee){for(var te=[],se=0;se<ee.length;++se)te.push(255&ee.charCodeAt(se));return te}(_),b,R,G)}function I(b,_,R,G){return T(b,_,R,G)}function D(b,_,R,G){return re(Z(_),b,R,G)}function X(b,_,R,G){return re(function(ee,te){for(var se,z,S,B=[],Y=0;Y<ee.length&&!((te-=2)<0);++Y)se=ee.charCodeAt(Y),z=se>>8,S=se%256,B.push(S),B.push(z);return B}(_,b.length-R),b,R,G)}function V(b,_,R){return _===0&&R===b.length?o.fromByteArray(b):o.fromByteArray(b.slice(_,R))}function E(b,_,R){R=Math.min(b.length,R);for(var G=[],ee=_;ee<R;){var te,se,z,S,B=b[ee],Y=null,ie=B>239?4:B>223?3:B>191?2:1;if(ee+ie<=R)switch(ie){case 1:B<128&&(Y=B);break;case 2:(192&(te=b[ee+1]))==128&&(S=(31&B)<<6|63&te)>127&&(Y=S);break;case 3:te=b[ee+1],se=b[ee+2],(192&te)==128&&(192&se)==128&&(S=(15&B)<<12|(63&te)<<6|63&se)>2047&&(S<55296||S>57343)&&(Y=S);break;case 4:te=b[ee+1],se=b[ee+2],z=b[ee+3],(192&te)==128&&(192&se)==128&&(192&z)==128&&(S=(15&B)<<18|(63&te)<<12|(63&se)<<6|63&z)>65535&&S<1114112&&(Y=S)}Y===null?(Y=65533,ie=1):Y>65535&&(Y-=65536,G.push(Y>>>10&1023|55296),Y=56320|1023&Y),G.push(Y),ee+=ie}return function(ue){var ce=ue.length;if(ce<=A)return String.fromCharCode.apply(String,ue);for(var me="",ge=0;ge<ce;)me+=String.fromCharCode.apply(String,ue.slice(ge,ge+=A));return me}(G)}l.kMaxLength=p,i.TYPED_ARRAY_SUPPORT=function(){try{var b=new Uint8Array(1);return b.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},b.foo()===42}catch(_){return!1}}(),i.TYPED_ARRAY_SUPPORT||typeof console=="undefined"||typeof console.error!="function"||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(i.prototype,"parent",{enumerable:!0,get:function(){if(i.isBuffer(this))return this.buffer}}),Object.defineProperty(i.prototype,"offset",{enumerable:!0,get:function(){if(i.isBuffer(this))return this.byteOffset}}),typeof Symbol!="undefined"&&Symbol.species!=null&&i[Symbol.species]===i&&Object.defineProperty(i,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),i.poolSize=8192,i.from=function(b,_,R){return d(b,_,R)},i.prototype.__proto__=Uint8Array.prototype,i.__proto__=Uint8Array,i.alloc=function(b,_,R){return function(G,ee,te){return c(G),G<=0?s(G):ee!==void 0?typeof te=="string"?s(G).fill(ee,te):s(G).fill(ee):s(G)}(b,_,R)},i.allocUnsafe=function(b){return f(b)},i.allocUnsafeSlow=function(b){return f(b)},i.isBuffer=function(b){return b!=null&&b._isBuffer===!0&&b!==i.prototype},i.compare=function(b,_){if(oe(b,Uint8Array)&&(b=i.from(b,b.offset,b.byteLength)),oe(_,Uint8Array)&&(_=i.from(_,_.offset,_.byteLength)),!i.isBuffer(b)||!i.isBuffer(_))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(b===_)return 0;for(var R=b.length,G=_.length,ee=0,te=Math.min(R,G);ee<te;++ee)if(b[ee]!==_[ee]){R=b[ee],G=_[ee];break}return R<G?-1:G<R?1:0},i.isEncoding=function(b){switch(String(b).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}},i.concat=function(b,_){if(!Array.isArray(b))throw new TypeError('"list" argument must be an Array of Buffers');if(b.length===0)return i.alloc(0);var R;if(_===void 0)for(_=0,R=0;R<b.length;++R)_+=b[R].length;var G=i.allocUnsafe(_),ee=0;for(R=0;R<b.length;++R){var te=b[R];if(oe(te,Uint8Array)&&(te=i.from(te)),!i.isBuffer(te))throw new TypeError('"list" argument must be an Array of Buffers');te.copy(G,ee),ee+=te.length}return G},i.byteLength=m,i.prototype._isBuffer=!0,i.prototype.swap16=function(){var b=this.length;if(b%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var _=0;_<b;_+=2)g(this,_,_+1);return this},i.prototype.swap32=function(){var b=this.length;if(b%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var _=0;_<b;_+=4)g(this,_,_+3),g(this,_+1,_+2);return this},i.prototype.swap64=function(){var b=this.length;if(b%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var _=0;_<b;_+=8)g(this,_,_+7),g(this,_+1,_+6),g(this,_+2,_+5),g(this,_+3,_+4);return this},i.prototype.toString=function(){var b=this.length;return b===0?"":arguments.length===0?E(this,0,b):function(_,R,G){var ee=!1;if((R===void 0||R<0)&&(R=0),R>this.length||((G===void 0||G>this.length)&&(G=this.length),G<=0)||(G>>>=0)<=(R>>>=0))return"";for(_||(_="utf8");;)switch(_){case"hex":return j(this,R,G);case"utf8":case"utf-8":return E(this,R,G);case"ascii":return C(this,R,G);case"latin1":case"binary":return F(this,R,G);case"base64":return V(this,R,G);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,R,G);default:if(ee)throw new TypeError("Unknown encoding: "+_);_=(_+"").toLowerCase(),ee=!0}}.apply(this,arguments)},i.prototype.toLocaleString=i.prototype.toString,i.prototype.equals=function(b){if(!i.isBuffer(b))throw new TypeError("Argument must be a Buffer");return this===b||i.compare(this,b)===0},i.prototype.inspect=function(){var b="",_=l.INSPECT_MAX_BYTES;return b=this.toString("hex",0,_).replace(/(.{2})/g,"$1 ").trim(),this.length>_&&(b+=" ... "),"<Buffer "+b+">"},i.prototype.compare=function(b,_,R,G,ee){if(oe(b,Uint8Array)&&(b=i.from(b,b.offset,b.byteLength)),!i.isBuffer(b))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof b);if(_===void 0&&(_=0),R===void 0&&(R=b?b.length:0),G===void 0&&(G=0),ee===void 0&&(ee=this.length),_<0||R>b.length||G<0||ee>this.length)throw new RangeError("out of range index");if(G>=ee&&_>=R)return 0;if(G>=ee)return-1;if(_>=R)return 1;if(_>>>=0,R>>>=0,G>>>=0,ee>>>=0,this===b)return 0;for(var te=ee-G,se=R-_,z=Math.min(te,se),S=this.slice(G,ee),B=b.slice(_,R),Y=0;Y<z;++Y)if(S[Y]!==B[Y]){te=S[Y],se=B[Y];break}return te<se?-1:se<te?1:0},i.prototype.includes=function(b,_,R){return this.indexOf(b,_,R)!==-1},i.prototype.indexOf=function(b,_,R){return x(this,b,_,R,!0)},i.prototype.lastIndexOf=function(b,_,R){return x(this,b,_,R,!1)},i.prototype.write=function(b,_,R,G){if(_===void 0)G="utf8",R=this.length,_=0;else if(R===void 0&&typeof _=="string")G=_,R=this.length,_=0;else{if(!isFinite(_))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");_>>>=0,isFinite(R)?(R>>>=0,G===void 0&&(G="utf8")):(G=R,R=void 0)}var ee=this.length-_;if((R===void 0||R>ee)&&(R=ee),b.length>0&&(R<0||_<0)||_>this.length)throw new RangeError("Attempt to write outside buffer bounds");G||(G="utf8");for(var te=!1;;)switch(G){case"hex":return w(this,b,_,R);case"utf8":case"utf-8":return k(this,b,_,R);case"ascii":return T(this,b,_,R);case"latin1":case"binary":return I(this,b,_,R);case"base64":return D(this,b,_,R);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return X(this,b,_,R);default:if(te)throw new TypeError("Unknown encoding: "+G);G=(""+G).toLowerCase(),te=!0}},i.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var A=4096;function C(b,_,R){var G="";R=Math.min(b.length,R);for(var ee=_;ee<R;++ee)G+=String.fromCharCode(127&b[ee]);return G}function F(b,_,R){var G="";R=Math.min(b.length,R);for(var ee=_;ee<R;++ee)G+=String.fromCharCode(b[ee]);return G}function j(b,_,R){var G=b.length;(!_||_<0)&&(_=0),(!R||R<0||R>G)&&(R=G);for(var ee="",te=_;te<R;++te)ee+=H(b[te]);return ee}function P(b,_,R){for(var G=b.slice(_,R),ee="",te=0;te<G.length;te+=2)ee+=String.fromCharCode(G[te]+256*G[te+1]);return ee}function J(b,_,R){if(b%1!=0||b<0)throw new RangeError("offset is not uint");if(b+_>R)throw new RangeError("Trying to access beyond buffer length")}function $(b,_,R,G,ee,te){if(!i.isBuffer(b))throw new TypeError('"buffer" argument must be a Buffer instance');if(_>ee||_<te)throw new RangeError('"value" argument is out of bounds');if(R+G>b.length)throw new RangeError("Index out of range")}function U(b,_,R,G,ee,te){if(R+G>b.length)throw new RangeError("Index out of range");if(R<0)throw new RangeError("Index out of range")}function K(b,_,R,G,ee){return _=+_,R>>>=0,ee||U(b,0,R,4),u.write(b,_,R,G,23,4),R+4}function L(b,_,R,G,ee){return _=+_,R>>>=0,ee||U(b,0,R,8),u.write(b,_,R,G,52,8),R+8}i.prototype.slice=function(b,_){var R=this.length;b=~~b,_=_===void 0?R:~~_,b<0?(b+=R)<0&&(b=0):b>R&&(b=R),_<0?(_+=R)<0&&(_=0):_>R&&(_=R),_<b&&(_=b);var G=this.subarray(b,_);return G.__proto__=i.prototype,G},i.prototype.readUIntLE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=this[b],ee=1,te=0;++te<_&&(ee*=256);)G+=this[b+te]*ee;return G},i.prototype.readUIntBE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=this[b+--_],ee=1;_>0&&(ee*=256);)G+=this[b+--_]*ee;return G},i.prototype.readUInt8=function(b,_){return b>>>=0,_||J(b,1,this.length),this[b]},i.prototype.readUInt16LE=function(b,_){return b>>>=0,_||J(b,2,this.length),this[b]|this[b+1]<<8},i.prototype.readUInt16BE=function(b,_){return b>>>=0,_||J(b,2,this.length),this[b]<<8|this[b+1]},i.prototype.readUInt32LE=function(b,_){return b>>>=0,_||J(b,4,this.length),(this[b]|this[b+1]<<8|this[b+2]<<16)+16777216*this[b+3]},i.prototype.readUInt32BE=function(b,_){return b>>>=0,_||J(b,4,this.length),16777216*this[b]+(this[b+1]<<16|this[b+2]<<8|this[b+3])},i.prototype.readIntLE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=this[b],ee=1,te=0;++te<_&&(ee*=256);)G+=this[b+te]*ee;return G>=(ee*=128)&&(G-=Math.pow(2,8*_)),G},i.prototype.readIntBE=function(b,_,R){b>>>=0,_>>>=0,R||J(b,_,this.length);for(var G=_,ee=1,te=this[b+--G];G>0&&(ee*=256);)te+=this[b+--G]*ee;return te>=(ee*=128)&&(te-=Math.pow(2,8*_)),te},i.prototype.readInt8=function(b,_){return b>>>=0,_||J(b,1,this.length),128&this[b]?-1*(255-this[b]+1):this[b]},i.prototype.readInt16LE=function(b,_){b>>>=0,_||J(b,2,this.length);var R=this[b]|this[b+1]<<8;return 32768&R?4294901760|R:R},i.prototype.readInt16BE=function(b,_){b>>>=0,_||J(b,2,this.length);var R=this[b+1]|this[b]<<8;return 32768&R?4294901760|R:R},i.prototype.readInt32LE=function(b,_){return b>>>=0,_||J(b,4,this.length),this[b]|this[b+1]<<8|this[b+2]<<16|this[b+3]<<24},i.prototype.readInt32BE=function(b,_){return b>>>=0,_||J(b,4,this.length),this[b]<<24|this[b+1]<<16|this[b+2]<<8|this[b+3]},i.prototype.readFloatLE=function(b,_){return b>>>=0,_||J(b,4,this.length),u.read(this,b,!0,23,4)},i.prototype.readFloatBE=function(b,_){return b>>>=0,_||J(b,4,this.length),u.read(this,b,!1,23,4)},i.prototype.readDoubleLE=function(b,_){return b>>>=0,_||J(b,8,this.length),u.read(this,b,!0,52,8)},i.prototype.readDoubleBE=function(b,_){return b>>>=0,_||J(b,8,this.length),u.read(this,b,!1,52,8)},i.prototype.writeUIntLE=function(b,_,R,G){b=+b,_>>>=0,R>>>=0,G||$(this,b,_,R,Math.pow(2,8*R)-1,0);var ee=1,te=0;for(this[_]=255&b;++te<R&&(ee*=256);)this[_+te]=b/ee&255;return _+R},i.prototype.writeUIntBE=function(b,_,R,G){b=+b,_>>>=0,R>>>=0,G||$(this,b,_,R,Math.pow(2,8*R)-1,0);var ee=R-1,te=1;for(this[_+ee]=255&b;--ee>=0&&(te*=256);)this[_+ee]=b/te&255;return _+R},i.prototype.writeUInt8=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,1,255,0),this[_]=255&b,_+1},i.prototype.writeUInt16LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,65535,0),this[_]=255&b,this[_+1]=b>>>8,_+2},i.prototype.writeUInt16BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,65535,0),this[_]=b>>>8,this[_+1]=255&b,_+2},i.prototype.writeUInt32LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,4294967295,0),this[_+3]=b>>>24,this[_+2]=b>>>16,this[_+1]=b>>>8,this[_]=255&b,_+4},i.prototype.writeUInt32BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,4294967295,0),this[_]=b>>>24,this[_+1]=b>>>16,this[_+2]=b>>>8,this[_+3]=255&b,_+4},i.prototype.writeIntLE=function(b,_,R,G){if(b=+b,_>>>=0,!G){var ee=Math.pow(2,8*R-1);$(this,b,_,R,ee-1,-ee)}var te=0,se=1,z=0;for(this[_]=255&b;++te<R&&(se*=256);)b<0&&z===0&&this[_+te-1]!==0&&(z=1),this[_+te]=(b/se>>0)-z&255;return _+R},i.prototype.writeIntBE=function(b,_,R,G){if(b=+b,_>>>=0,!G){var ee=Math.pow(2,8*R-1);$(this,b,_,R,ee-1,-ee)}var te=R-1,se=1,z=0;for(this[_+te]=255&b;--te>=0&&(se*=256);)b<0&&z===0&&this[_+te+1]!==0&&(z=1),this[_+te]=(b/se>>0)-z&255;return _+R},i.prototype.writeInt8=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,1,127,-128),b<0&&(b=255+b+1),this[_]=255&b,_+1},i.prototype.writeInt16LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,32767,-32768),this[_]=255&b,this[_+1]=b>>>8,_+2},i.prototype.writeInt16BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,2,32767,-32768),this[_]=b>>>8,this[_+1]=255&b,_+2},i.prototype.writeInt32LE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,2147483647,-2147483648),this[_]=255&b,this[_+1]=b>>>8,this[_+2]=b>>>16,this[_+3]=b>>>24,_+4},i.prototype.writeInt32BE=function(b,_,R){return b=+b,_>>>=0,R||$(this,b,_,4,2147483647,-2147483648),b<0&&(b=4294967295+b+1),this[_]=b>>>24,this[_+1]=b>>>16,this[_+2]=b>>>8,this[_+3]=255&b,_+4},i.prototype.writeFloatLE=function(b,_,R){return K(this,b,_,!0,R)},i.prototype.writeFloatBE=function(b,_,R){return K(this,b,_,!1,R)},i.prototype.writeDoubleLE=function(b,_,R){return L(this,b,_,!0,R)},i.prototype.writeDoubleBE=function(b,_,R){return L(this,b,_,!1,R)},i.prototype.copy=function(b,_,R,G){if(!i.isBuffer(b))throw new TypeError("argument should be a Buffer");if(R||(R=0),G||G===0||(G=this.length),_>=b.length&&(_=b.length),_||(_=0),G>0&&G<R&&(G=R),G===R||b.length===0||this.length===0)return 0;if(_<0)throw new RangeError("targetStart out of bounds");if(R<0||R>=this.length)throw new RangeError("Index out of range");if(G<0)throw new RangeError("sourceEnd out of bounds");G>this.length&&(G=this.length),b.length-_<G-R&&(G=b.length-_+R);var ee=G-R;if(this===b&&typeof Uint8Array.prototype.copyWithin=="function")this.copyWithin(_,R,G);else if(this===b&&R<_&&_<G)for(var te=ee-1;te>=0;--te)b[te+_]=this[te+R];else Uint8Array.prototype.set.call(b,this.subarray(R,G),_);return ee},i.prototype.fill=function(b,_,R,G){if(typeof b=="string"){if(typeof _=="string"?(G=_,_=0,R=this.length):typeof R=="string"&&(G=R,R=this.length),G!==void 0&&typeof G!="string")throw new TypeError("encoding must be a string");if(typeof G=="string"&&!i.isEncoding(G))throw new TypeError("Unknown encoding: "+G);if(b.length===1){var ee=b.charCodeAt(0);(G==="utf8"&&ee<128||G==="latin1")&&(b=ee)}}else typeof b=="number"&&(b&=255);if(_<0||this.length<_||this.length<R)throw new RangeError("Out of range index");if(R<=_)return this;var te;if(_>>>=0,R=R===void 0?this.length:R>>>0,b||(b=0),typeof b=="number")for(te=_;te<R;++te)this[te]=b;else{var se=i.isBuffer(b)?b:i.from(b,G),z=se.length;if(z===0)throw new TypeError('The value "'+b+'" is invalid for argument "value"');for(te=0;te<R-_;++te)this[te+_]=se[te%z]}return this};var O=/[^+/0-9A-Za-z-_]/g;function H(b){return b<16?"0"+b.toString(16):b.toString(16)}function W(b,_){var R;_=_||1/0;for(var G=b.length,ee=null,te=[],se=0;se<G;++se){if((R=b.charCodeAt(se))>55295&&R<57344){if(!ee){if(R>56319){(_-=3)>-1&&te.push(239,191,189);continue}if(se+1===G){(_-=3)>-1&&te.push(239,191,189);continue}ee=R;continue}if(R<56320){(_-=3)>-1&&te.push(239,191,189),ee=R;continue}R=65536+(ee-55296<<10|R-56320)}else ee&&(_-=3)>-1&&te.push(239,191,189);if(ee=null,R<128){if((_-=1)<0)break;te.push(R)}else if(R<2048){if((_-=2)<0)break;te.push(R>>6|192,63&R|128)}else if(R<65536){if((_-=3)<0)break;te.push(R>>12|224,R>>6&63|128,63&R|128)}else{if(!(R<1114112))throw new Error("Invalid code point");if((_-=4)<0)break;te.push(R>>18|240,R>>12&63|128,R>>6&63|128,63&R|128)}}return te}function Z(b){return o.toByteArray(function(_){if((_=(_=_.split("=")[0]).trim().replace(O,"")).length<2)return"";for(;_.length%4!=0;)_+="=";return _}(b))}function re(b,_,R,G){for(var ee=0;ee<G&&!(ee+R>=_.length||ee>=b.length);++ee)_[ee+R]=b[ee];return ee}function oe(b,_){return b instanceof _||b!=null&&b.constructor!=null&&b.constructor.name!=null&&b.constructor.name===_.name}function ae(b){return b!=b}}).call(this)}).call(this,t("buffer").Buffer)},{"base64-js":13,buffer:17,ieee754:23}],18:[function(t,n,l){(function(a){(function(){l.formatArgs=function(u){if(u[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+u[0]+(this.useColors?"%c ":" ")+"+"+n.exports.humanize(this.diff),!this.useColors)return;const p="color: "+this.color;u.splice(1,0,p,"color: inherit");let s=0,i=0;u[0].replace(/%[a-zA-Z%]/g,d=>{d!=="%%"&&d==="%c"&&(i=++s)}),u.splice(i,0,p)},l.save=function(u){try{u?l.storage.setItem("debug",u):l.storage.removeItem("debug")}catch(p){}},l.load=function(){let u;try{u=l.storage.getItem("debug")}catch(p){}return!u&&a!==void 0&&"env"in a&&(u=a.env.DEBUG),u},l.useColors=function(){return typeof window!="undefined"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document!="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},l.storage=function(){try{return localStorage}catch(u){}}(),l.destroy=(()=>{let u=!1;return()=>{u||(u=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),l.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],l.log=console.debug||console.log||(()=>{}),n.exports=t("./common")(l);const{formatters:o}=n.exports;o.j=function(u){try{return JSON.stringify(u)}catch(p){return"[UnexpectedJSONParseError]: "+p.message}}}).call(this)}).call(this,t("_process"))},{"./common":19,_process:50}],19:[function(t,n,l){n.exports=function(a){function o(s){let i,d,c,f=null;function h(...v){if(!h.enabled)return;const m=h,g=Number(new Date),x=g-(i||g);m.diff=x,m.prev=i,m.curr=g,i=g,v[0]=o.coerce(v[0]),typeof v[0]!="string"&&v.unshift("%O");let y=0;v[0]=v[0].replace(/%([a-zA-Z%])/g,(w,k)=>{if(w==="%%")return"%";y++;const T=o.formatters[k];if(typeof T=="function"){const I=v[y];w=T.call(m,I),v.splice(y,1),y--}return w}),o.formatArgs.call(m,v),(m.log||o.log).apply(m,v)}return h.namespace=s,h.useColors=o.useColors(),h.color=o.selectColor(s),h.extend=u,h.destroy=o.destroy,Object.defineProperty(h,"enabled",{enumerable:!0,configurable:!1,get:()=>f!==null?f:(d!==o.namespaces&&(d=o.namespaces,c=o.enabled(s)),c),set:v=>{f=v}}),typeof o.init=="function"&&o.init(h),h}function u(s,i){const d=o(this.namespace+(i===void 0?":":i)+s);return d.log=this.log,d}function p(s){return s.toString().substring(2,s.toString().length-2).replace(/\.\*\?$/,"*")}return o.debug=o,o.default=o,o.coerce=function(s){return s instanceof Error?s.stack||s.message:s},o.disable=function(){const s=[...o.names.map(p),...o.skips.map(p).map(i=>"-"+i)].join(",");return o.enable(""),s},o.enable=function(s){let i;o.save(s),o.namespaces=s,o.names=[],o.skips=[];const d=(typeof s=="string"?s:"").split(/[\s,]+/),c=d.length;for(i=0;i<c;i++)d[i]&&((s=d[i].replace(/\*/g,".*?"))[0]==="-"?o.skips.push(new RegExp("^"+s.substr(1)+"$")):o.names.push(new RegExp("^"+s+"$")))},o.enabled=function(s){if(s[s.length-1]==="*")return!0;let i,d;for(i=0,d=o.skips.length;i<d;i++)if(o.skips[i].test(s))return!1;for(i=0,d=o.names.length;i<d;i++)if(o.names[i].test(s))return!0;return!1},o.humanize=t("ms"),o.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(a).forEach(s=>{o[s]=a[s]}),o.names=[],o.skips=[],o.formatters={},o.selectColor=function(s){let i=0;for(let d=0;d<s.length;d++)i=(i<<5)-i+s.charCodeAt(d),i|=0;return o.colors[Math.abs(i)%o.colors.length]},o.enable(o.load()),o}},{ms:45}],20:[function(t,n,l){(function(a,o){(function(){var u=t("readable-stream"),p=t("end-of-stream"),s=t("inherits"),i=t("stream-shift"),d=o.from&&o.from!==Uint8Array.from?o.from([0]):new o([0]),c=function(m,g){m._corked?m.once("uncork",g):g()},f=function(m,g){return function(x){x?function(y,w){y._autoDestroy&&y.destroy(w)}(m,x.message==="premature close"?null:x):g&&!m._ended&&m.end()}},h=function(){},v=function(m,g,x){if(!(this instanceof v))return new v(m,g,x);u.Duplex.call(this,x),this._writable=null,this._readable=null,this._readable2=null,this._autoDestroy=!x||x.autoDestroy!==!1,this._forwardDestroy=!x||x.destroy!==!1,this._forwardEnd=!x||x.end!==!1,this._corked=1,this._ondrain=null,this._drained=!1,this._forwarding=!1,this._unwrite=null,this._unread=null,this._ended=!1,this.destroyed=!1,m&&this.setWritable(m),g&&this.setReadable(g)};s(v,u.Duplex),v.obj=function(m,g,x){return x||(x={}),x.objectMode=!0,x.highWaterMark=16,new v(m,g,x)},v.prototype.cork=function(){++this._corked==1&&this.emit("cork")},v.prototype.uncork=function(){this._corked&&--this._corked==0&&this.emit("uncork")},v.prototype.setWritable=function(m){if(this._unwrite&&this._unwrite(),this.destroyed)m&&m.destroy&&m.destroy();else if(m!==null&&m!==!1){var g=this,x=p(m,{writable:!0,readable:!1},f(this,this._forwardEnd)),y=function(){var w=g._ondrain;g._ondrain=null,w&&w()};this._unwrite&&a.nextTick(y),this._writable=m,this._writable.on("drain",y),this._unwrite=function(){g._writable.removeListener("drain",y),x()},this.uncork()}else this.end()},v.prototype.setReadable=function(m){if(this._unread&&this._unread(),this.destroyed)m&&m.destroy&&m.destroy();else{if(m===null||m===!1)return this.push(null),void this.resume();var g,x=this,y=p(m,{writable:!1,readable:!0},f(this)),w=function(){x._forward()},k=function(){x.push(null)};this._drained=!0,this._readable=m,this._readable2=m._readableState?m:(g=m,new u.Readable({objectMode:!0,highWaterMark:16}).wrap(g)),this._readable2.on("readable",w),this._readable2.on("end",k),this._unread=function(){x._readable2.removeListener("readable",w),x._readable2.removeListener("end",k),y()},this._forward()}},v.prototype._read=function(){this._drained=!0,this._forward()},v.prototype._forward=function(){if(!this._forwarding&&this._readable2&&this._drained){var m;for(this._forwarding=!0;this._drained&&(m=i(this._readable2))!==null;)this.destroyed||(this._drained=this.push(m));this._forwarding=!1}},v.prototype.destroy=function(m,g){if(g||(g=h),this.destroyed)return g(null);this.destroyed=!0;var x=this;a.nextTick(function(){x._destroy(m),g(null)})},v.prototype._destroy=function(m){if(m){var g=this._ondrain;this._ondrain=null,g?g(m):this.emit("error",m)}this._forwardDestroy&&(this._readable&&this._readable.destroy&&this._readable.destroy(),this._writable&&this._writable.destroy&&this._writable.destroy()),this.emit("close")},v.prototype._write=function(m,g,x){if(!this.destroyed)return this._corked?c(this,this._write.bind(this,m,g,x)):m===d?this._finish(x):this._writable?void(this._writable.write(m)===!1?this._ondrain=x:this.destroyed||x()):x()},v.prototype._finish=function(m){var g=this;this.emit("preend"),c(this,function(){var x,y;x=g._forwardEnd&&g._writable,y=function(){g._writableState.prefinished===!1&&(g._writableState.prefinished=!0),g.emit("prefinish"),c(g,m)},x?x._writableState&&x._writableState.finished?y():x._writableState?x.end(y):(x.end(),y()):y()})},v.prototype.end=function(m,g,x){return typeof m=="function"?this.end(null,null,m):typeof g=="function"?this.end(m,null,g):(this._ended=!0,m&&this.write(m),this._writableState.ending||this._writableState.destroyed||this.write(d),u.Writable.prototype.end.call(this,x))},n.exports=v}).call(this)}).call(this,t("_process"),t("buffer").Buffer)},{_process:50,buffer:17,"end-of-stream":21,inherits:24,"readable-stream":69,"stream-shift":74}],21:[function(t,n,l){(function(a){(function(){var o=t("once"),u=function(){},p=function(s,i,d){if(typeof i=="function")return p(s,null,i);i||(i={}),d=o(d||u);var c=s._writableState,f=s._readableState,h=i.readable||i.readable!==!1&&s.readable,v=i.writable||i.writable!==!1&&s.writable,m=!1,g=function(){s.writable||x()},x=function(){v=!1,h||d.call(s)},y=function(){h=!1,v||d.call(s)},w=function(X){d.call(s,X?new Error("exited with error code: "+X):null)},k=function(X){d.call(s,X)},T=function(){a.nextTick(I)},I=function(){if(!m)return(!h||f&&f.ended&&!f.destroyed)&&(!v||c&&c.ended&&!c.destroyed)?void 0:d.call(s,new Error("premature close"))},D=function(){s.req.on("finish",x)};return function(X){return X.setHeader&&typeof X.abort=="function"}(s)?(s.on("complete",x),s.on("abort",T),s.req?D():s.on("request",D)):v&&!c&&(s.on("end",g),s.on("close",g)),function(X){return X.stdio&&Array.isArray(X.stdio)&&X.stdio.length===3}(s)&&s.on("exit",w),s.on("end",y),s.on("finish",x),i.error!==!1&&s.on("error",k),s.on("close",T),function(){m=!0,s.removeListener("complete",x),s.removeListener("abort",T),s.removeListener("request",D),s.req&&s.req.removeListener("finish",x),s.removeListener("end",g),s.removeListener("close",g),s.removeListener("finish",x),s.removeListener("exit",w),s.removeListener("end",y),s.removeListener("error",k),s.removeListener("close",T)}};n.exports=p}).call(this)}).call(this,t("_process"))},{_process:50,once:48}],22:[function(t,n,l){var a=Object.create||function(y){var w=function(){};return w.prototype=y,new w},o=Object.keys||function(y){var w=[];for(var k in y)Object.prototype.hasOwnProperty.call(y,k)&&w.push(k);return k},u=Function.prototype.bind||function(y){var w=this;return function(){return w.apply(y,arguments)}};function p(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=a(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0}n.exports=p,p.EventEmitter=p,p.prototype._events=void 0,p.prototype._maxListeners=void 0;var s,i=10;try{var d={};Object.defineProperty&&Object.defineProperty(d,"x",{value:0}),s=d.x===0}catch(y){s=!1}function c(y){return y._maxListeners===void 0?p.defaultMaxListeners:y._maxListeners}function f(y,w,k,T){var I,D,X;if(typeof k!="function")throw new TypeError('"listener" argument must be a function');if((D=y._events)?(D.newListener&&(y.emit("newListener",w,k.listener?k.listener:k),D=y._events),X=D[w]):(D=y._events=a(null),y._eventsCount=0),X){if(typeof X=="function"?X=D[w]=T?[k,X]:[X,k]:T?X.unshift(k):X.push(k),!X.warned&&(I=c(y))&&I>0&&X.length>I){X.warned=!0;var V=new Error("Possible EventEmitter memory leak detected. "+X.length+' "'+String(w)+'" listeners added. Use emitter.setMaxListeners() to increase limit.');V.name="MaxListenersExceededWarning",V.emitter=y,V.type=w,V.count=X.length,typeof console=="object"&&console.warn&&console.warn("%s: %s",V.name,V.message)}}else X=D[w]=k,++y._eventsCount;return y}function h(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var y=new Array(arguments.length),w=0;w<y.length;++w)y[w]=arguments[w];this.listener.apply(this.target,y)}}function v(y,w,k){var T={fired:!1,wrapFn:void 0,target:y,type:w,listener:k},I=u.call(h,T);return I.listener=k,T.wrapFn=I,I}function m(y,w,k){var T=y._events;if(!T)return[];var I=T[w];return I?typeof I=="function"?k?[I.listener||I]:[I]:k?function(D){for(var X=new Array(D.length),V=0;V<X.length;++V)X[V]=D[V].listener||D[V];return X}(I):x(I,I.length):[]}function g(y){var w=this._events;if(w){var k=w[y];if(typeof k=="function")return 1;if(k)return k.length}return 0}function x(y,w){for(var k=new Array(w),T=0;T<w;++T)k[T]=y[T];return k}s?Object.defineProperty(p,"defaultMaxListeners",{enumerable:!0,get:function(){return i},set:function(y){if(typeof y!="number"||y<0||y!=y)throw new TypeError('"defaultMaxListeners" must be a positive number');i=y}}):p.defaultMaxListeners=i,p.prototype.setMaxListeners=function(y){if(typeof y!="number"||y<0||isNaN(y))throw new TypeError('"n" argument must be a positive number');return this._maxListeners=y,this},p.prototype.getMaxListeners=function(){return c(this)},p.prototype.emit=function(y){var w,k,T,I,D,X,V=y==="error";if(X=this._events)V=V&&X.error==null;else if(!V)return!1;if(V){if(arguments.length>1&&(w=arguments[1]),w instanceof Error)throw w;var E=new Error('Unhandled "error" event. ('+w+")");throw E.context=w,E}if(!(k=X[y]))return!1;var A=typeof k=="function";switch(T=arguments.length){case 1:(function(C,F,j){if(F)C.call(j);else for(var P=C.length,J=x(C,P),$=0;$<P;++$)J[$].call(j)})(k,A,this);break;case 2:(function(C,F,j,P){if(F)C.call(j,P);else for(var J=C.length,$=x(C,J),U=0;U<J;++U)$[U].call(j,P)})(k,A,this,arguments[1]);break;case 3:(function(C,F,j,P,J){if(F)C.call(j,P,J);else for(var $=C.length,U=x(C,$),K=0;K<$;++K)U[K].call(j,P,J)})(k,A,this,arguments[1],arguments[2]);break;case 4:(function(C,F,j,P,J,$){if(F)C.call(j,P,J,$);else for(var U=C.length,K=x(C,U),L=0;L<U;++L)K[L].call(j,P,J,$)})(k,A,this,arguments[1],arguments[2],arguments[3]);break;default:for(I=new Array(T-1),D=1;D<T;D++)I[D-1]=arguments[D];(function(C,F,j,P){if(F)C.apply(j,P);else for(var J=C.length,$=x(C,J),U=0;U<J;++U)$[U].apply(j,P)})(k,A,this,I)}return!0},p.prototype.addListener=function(y,w){return f(this,y,w,!1)},p.prototype.on=p.prototype.addListener,p.prototype.prependListener=function(y,w){return f(this,y,w,!0)},p.prototype.once=function(y,w){if(typeof w!="function")throw new TypeError('"listener" argument must be a function');return this.on(y,v(this,y,w)),this},p.prototype.prependOnceListener=function(y,w){if(typeof w!="function")throw new TypeError('"listener" argument must be a function');return this.prependListener(y,v(this,y,w)),this},p.prototype.removeListener=function(y,w){var k,T,I,D,X;if(typeof w!="function")throw new TypeError('"listener" argument must be a function');if(!(T=this._events))return this;if(!(k=T[y]))return this;if(k===w||k.listener===w)--this._eventsCount==0?this._events=a(null):(delete T[y],T.removeListener&&this.emit("removeListener",y,k.listener||w));else if(typeof k!="function"){for(I=-1,D=k.length-1;D>=0;D--)if(k[D]===w||k[D].listener===w){X=k[D].listener,I=D;break}if(I<0)return this;I===0?k.shift():function(V,E){for(var A=E,C=A+1,F=V.length;C<F;A+=1,C+=1)V[A]=V[C];V.pop()}(k,I),k.length===1&&(T[y]=k[0]),T.removeListener&&this.emit("removeListener",y,X||w)}return this},p.prototype.removeAllListeners=function(y){var w,k,T;if(!(k=this._events))return this;if(!k.removeListener)return arguments.length===0?(this._events=a(null),this._eventsCount=0):k[y]&&(--this._eventsCount==0?this._events=a(null):delete k[y]),this;if(arguments.length===0){var I,D=o(k);for(T=0;T<D.length;++T)(I=D[T])!=="removeListener"&&this.removeAllListeners(I);return this.removeAllListeners("removeListener"),this._events=a(null),this._eventsCount=0,this}if(typeof(w=k[y])=="function")this.removeListener(y,w);else if(w)for(T=w.length-1;T>=0;T--)this.removeListener(y,w[T]);return this},p.prototype.listeners=function(y){return m(this,y,!0)},p.prototype.rawListeners=function(y){return m(this,y,!1)},p.listenerCount=function(y,w){return typeof y.listenerCount=="function"?y.listenerCount(w):g.call(y,w)},p.prototype.listenerCount=g,p.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]}},{}],23:[function(t,n,l){l.read=function(a,o,u,p,s){var i,d,c=8*s-p-1,f=(1<<c)-1,h=f>>1,v=-7,m=u?s-1:0,g=u?-1:1,x=a[o+m];for(m+=g,i=x&(1<<-v)-1,x>>=-v,v+=c;v>0;i=256*i+a[o+m],m+=g,v-=8);for(d=i&(1<<-v)-1,i>>=-v,v+=p;v>0;d=256*d+a[o+m],m+=g,v-=8);if(i===0)i=1-h;else{if(i===f)return d?NaN:1/0*(x?-1:1);d+=Math.pow(2,p),i-=h}return(x?-1:1)*d*Math.pow(2,i-p)},l.write=function(a,o,u,p,s,i){var d,c,f,h=8*i-s-1,v=(1<<h)-1,m=v>>1,g=s===23?Math.pow(2,-24)-Math.pow(2,-77):0,x=p?0:i-1,y=p?1:-1,w=o<0||o===0&&1/o<0?1:0;for(o=Math.abs(o),isNaN(o)||o===1/0?(c=isNaN(o)?1:0,d=v):(d=Math.floor(Math.log(o)/Math.LN2),o*(f=Math.pow(2,-d))<1&&(d--,f*=2),(o+=d+m>=1?g/f:g*Math.pow(2,1-m))*f>=2&&(d++,f/=2),d+m>=v?(c=0,d=v):d+m>=1?(c=(o*f-1)*Math.pow(2,s),d+=m):(c=o*Math.pow(2,m-1)*Math.pow(2,s),d=0));s>=8;a[u+x]=255&c,x+=y,c/=256,s-=8);for(d=d<<s|c,h+=s;h>0;a[u+x]=255&d,x+=y,d/=256,h-=8);a[u+x-y]|=128*w}},{}],24:[function(t,n,l){typeof Object.create=="function"?n.exports=function(a,o){o&&(a.super_=o,a.prototype=Object.create(o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}))}:n.exports=function(a,o){if(o){a.super_=o;var u=function(){};u.prototype=o.prototype,a.prototype=new u,a.prototype.constructor=a}}},{}],25:[function(t,n,l){Object.defineProperty(l,"__esModule",{value:!0});var a=function(){function o(u,p){this.color=!0,this.key=void 0,this.value=void 0,this.parent=void 0,this.brother=void 0,this.leftChild=void 0,this.rightChild=void 0,this.key=u,this.value=p}return o.prototype.rotateLeft=function(){var u=this.parent,p=this.brother,s=this.leftChild,i=this.rightChild;if(!i)throw new Error("unknown error");var d=i.leftChild,c=i.rightChild;return u&&(u.leftChild===this?u.leftChild=i:u.rightChild===this&&(u.rightChild=i)),i.parent=u,i.brother=p,i.leftChild=this,i.rightChild=c,p&&(p.brother=i),this.parent=i,this.brother=c,this.leftChild=s,this.rightChild=d,c&&(c.parent=i,c.brother=this),s&&(s.parent=this,s.brother=d),d&&(d.parent=this,d.brother=s),i},o.prototype.rotateRight=function(){var u=this.parent,p=this.brother,s=this.leftChild;if(!s)throw new Error("unknown error");var i=this.rightChild,d=s.leftChild,c=s.rightChild;return u&&(u.leftChild===this?u.leftChild=s:u.rightChild===this&&(u.rightChild=s)),s.parent=u,s.brother=p,s.leftChild=d,s.rightChild=this,p&&(p.brother=s),d&&(d.parent=s,d.brother=this),this.parent=s,this.brother=d,this.leftChild=c,this.rightChild=i,c&&(c.parent=this,c.brother=i),i&&(i.parent=this,i.brother=c),s},o.prototype.remove=function(){if(this.leftChild||this.rightChild)throw new Error("can only remove leaf node");this.parent&&(this===this.parent.leftChild?this.parent.leftChild=void 0:this===this.parent.rightChild&&(this.parent.rightChild=void 0)),this.brother&&(this.brother.brother=void 0),this.key=void 0,this.value=void 0,this.parent=void 0,this.brother=void 0},o.TreeNodeColorType={red:!0,black:!1},o}();Object.freeze(a),l.default=a},{}],26:[function(t,n,l){var a=this&&this.__generator||function(u,p){var s,i,d,c,f={label:0,sent:function(){if(1&d[0])throw d[1];return d[1]},trys:[],ops:[]};return c={next:h(0),throw:h(1),return:h(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function h(v){return function(m){return function(g){if(s)throw new TypeError("Generator is already executing.");for(;f;)try{if(s=1,i&&(d=2&g[0]?i.return:g[0]?i.throw||((d=i.return)&&d.call(i),0):i.next)&&!(d=d.call(i,g[1])).done)return d;switch(i=0,d&&(g=[2&g[0],d.value]),g[0]){case 0:case 1:d=g;break;case 4:return f.label++,{value:g[1],done:!1};case 5:f.label++,i=g[1],g=[0];continue;case 7:g=f.ops.pop(),f.trys.pop();continue;default:if(!(d=(d=f.trys).length>0&&d[d.length-1])&&(g[0]===6||g[0]===2)){f=0;continue}if(g[0]===3&&(!d||g[1]>d[0]&&g[1]<d[3])){f.label=g[1];break}if(g[0]===6&&f.label<d[1]){f.label=d[1],d=g;break}if(d&&f.label<d[2]){f.label=d[2],f.ops.push(g);break}d[2]&&f.ops.pop(),f.trys.pop();continue}g=p.call(u,f)}catch(x){g=[6,x],i=0}finally{s=d=0}if(5&g[0])throw g[1];return{value:g[0]?g[1]:void 0,done:!0}}([v,m])}}};function o(u){var p=this;u===void 0&&(u=[]);var s=[],i=0,d=0,c=0,f=0,h=0,v=0;this.size=function(){return v},this.empty=function(){return v===0},this.clear=function(){i=c=d=f=h=v=0,g.call(this,o.bucketSize),v=0},this.front=function(){return s[i][d]},this.back=function(){return s[c][f]},this.forEach=function(x){if(!this.empty()){var y=0;if(i!==c){for(k=d;k<o.bucketSize;++k)x(s[i][k],y++);for(k=i+1;k<c;++k)for(var w=0;w<o.bucketSize;++w)x(s[k][w],y++);for(k=0;k<=f;++k)x(s[c][k],y++)}else for(var k=d;k<=f;++k)x(s[i][k],y++)}};var m=function(x){var y=i*o.bucketSize+d,w=y+x,k=c*o.bucketSize+f;if(w<y||w>k)throw new Error("pos should more than 0 and less than queue's size");return{curNodeBucketIndex:Math.floor(w/o.bucketSize),curNodePointerIndex:w%o.bucketSize}};this.getElementByPos=function(x){var y=m(x),w=y.curNodeBucketIndex,k=y.curNodePointerIndex;return s[w][k]},this.eraseElementByPos=function(x){var y=this;if(x<0||x>v)throw new Error("pos should more than 0 and less than queue's size");if(x===0)this.popFront();else if(x===this.size())this.popBack();else{for(var w=[],k=x+1;k<v;++k)w.push(this.getElementByPos(k));this.cut(x),this.popBack(),w.forEach(function(T){return y.pushBack(T)})}},this.eraseElementByValue=function(x){if(!this.empty()){var y=[];this.forEach(function(T){T!==x&&y.push(T)});for(var w=y.length,k=0;k<w;++k)this.setElementByPos(k,y[k]);this.cut(w-1)}};var g=function(x){for(var y=[],w=x*o.sigma,k=Math.max(Math.ceil(w/o.bucketSize),2),T=0;T<k;++T)y.push(new Array(o.bucketSize));var I=Math.ceil(x/o.bucketSize),D=Math.floor(k/2)-Math.floor(I/2),X=D,V=0;if(this.size())for(T=0;T<I;++T){for(var E=0;E<o.bucketSize;++E)if(y[D+T][E]=this.front(),this.popFront(),this.empty()){X=D+T,V=E;break}if(this.empty())break}s=y,i=D,d=0,c=X,f=V,h=k,v=x};this.pushBack=function(x){this.empty()||(c===h-1&&f===o.bucketSize-1&&g.call(this,this.size()),f<o.bucketSize-1?++f:c<h-1&&(++c,f=0)),++v,s[c][f]=x},this.popBack=function(){this.empty()||(this.size()!==1&&(f>0?--f:i<c&&(--c,f=o.bucketSize-1)),v>0&&--v)},this.setElementByPos=function(x,y){var w=m(x),k=w.curNodeBucketIndex,T=w.curNodePointerIndex;s[k][T]=y},this.insert=function(x,y,w){var k=this;if(w===void 0&&(w=1),x===0)for(;w--;)this.pushFront(y);else if(x===this.size())for(;w--;)this.pushBack(y);else{for(var T=[],I=x;I<v;++I)T.push(this.getElementByPos(I));for(this.cut(x-1),I=0;I<w;++I)this.pushBack(y);T.forEach(function(D){return k.pushBack(D)})}},this.find=function(x){if(i===c){for(var y=d;y<=f;++y)if(s[i][y]===x)return!0;return!1}for(y=d;y<o.bucketSize;++y)if(s[i][y]===x)return!0;for(y=i+1;y<c;++y)for(var w=0;w<o.bucketSize;++w)if(s[y][w]===x)return!0;for(y=0;y<=f;++y)if(s[c][y]===x)return!0;return!1},this.reverse=function(){for(var x=0,y=v-1;x<y;){var w=this.getElementByPos(x);this.setElementByPos(x,this.getElementByPos(y)),this.setElementByPos(y,w),++x,--y}},this.unique=function(){if(!this.empty()){var x=[],y=this.front();this.forEach(function(k,T){T!==0&&k===y||(x.push(k),y=k)});for(var w=0;w<v;++w)this.setElementByPos(w,x[w]);this.cut(x.length-1)}},this.sort=function(x){var y=[];this.forEach(function(k){y.push(k)}),y.sort(x);for(var w=0;w<v;++w)this.setElementByPos(w,y[w])},this.pushFront=function(x){this.empty()||(i===0&&d===0&&g.call(this,this.size()),d>0?--d:i>0&&(--i,d=o.bucketSize-1)),++v,s[i][d]=x},this.popFront=function(){this.empty()||(this.size()!==1&&(d<o.bucketSize-1?++d:i<c&&(++i,d=0)),v>0&&--v)},this.shrinkToFit=function(){var x=this,y=[];this.forEach(function(I){y.push(I)});var w=y.length;s=[];for(var k=Math.ceil(w/o.bucketSize),T=0;T<k;++T)s.push(new Array(o.bucketSize));this.clear(),y.forEach(function(I){return x.pushBack(I)})},this.cut=function(x){if(x<0)this.clear();else{var y=m(x),w=y.curNodeBucketIndex,k=y.curNodePointerIndex;c=w,f=k,v=x+1}},this[Symbol.iterator]=function(){return function(){var x,y;return a(this,function(w){switch(w.label){case 0:if(v===0)return[2];if(i!==c)return[3,5];y=d,w.label=1;case 1:return y<=f?[4,s[i][y]]:[3,4];case 2:w.sent(),w.label=3;case 3:return++y,[3,1];case 4:return[2];case 5:y=d,w.label=6;case 6:return y<o.bucketSize?[4,s[i][y]]:[3,9];case 7:w.sent(),w.label=8;case 8:return++y,[3,6];case 9:y=i+1,w.label=10;case 10:if(!(y<c))return[3,15];x=0,w.label=11;case 11:return x<o.bucketSize?[4,s[y][x]]:[3,14];case 12:w.sent(),w.label=13;case 13:return++x,[3,11];case 14:return++y,[3,10];case 15:y=0,w.label=16;case 16:return y<=f?[4,s[c][y]]:[3,19];case 17:w.sent(),w.label=18;case 18:return++y,[3,16];case 19:return[2]}})}()},function(){var x=o.bucketSize;u.size?x=u.size():u.length&&(x=u.length);var y=x*o.sigma;h=Math.ceil(y/o.bucketSize),h=Math.max(h,3);for(var w=0;w<h;++w)s.push(new Array(o.bucketSize));var k=Math.ceil(x/o.bucketSize);i=Math.floor(h/2)-Math.floor(k/2),c=i,u.forEach(function(T){return p.pushBack(T)})}(),Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),o.sigma=3,o.bucketSize=5e3,Object.freeze(o),l.default=o},{}],27:[function(t,n,l){var a=this&&this.__generator||function(i,d){var c,f,h,v,m={label:0,sent:function(){if(1&h[0])throw h[1];return h[1]},trys:[],ops:[]};return v={next:g(0),throw:g(1),return:g(2)},typeof Symbol=="function"&&(v[Symbol.iterator]=function(){return this}),v;function g(x){return function(y){return function(w){if(c)throw new TypeError("Generator is already executing.");for(;m;)try{if(c=1,f&&(h=2&w[0]?f.return:w[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,w[1])).done)return h;switch(f=0,h&&(w=[2&w[0],h.value]),w[0]){case 0:case 1:h=w;break;case 4:return m.label++,{value:w[1],done:!1};case 5:m.label++,f=w[1],w=[0];continue;case 7:w=m.ops.pop(),m.trys.pop();continue;default:if(!(h=(h=m.trys).length>0&&h[h.length-1])&&(w[0]===6||w[0]===2)){m=0;continue}if(w[0]===3&&(!h||w[1]>h[0]&&w[1]<h[3])){m.label=w[1];break}if(w[0]===6&&m.label<h[1]){m.label=h[1],h=w;break}if(h&&m.label<h[2]){m.label=h[2],m.ops.push(w);break}h[2]&&m.ops.pop(),m.trys.pop();continue}w=d.call(i,m)}catch(k){w=[6,k],f=0}finally{c=h=0}if(5&w[0])throw w[1];return{value:w[0]?w[1]:void 0,done:!0}}([x,y])}}},o=this&&this.__values||function(i){var d=typeof Symbol=="function"&&Symbol.iterator,c=d&&i[d],f=0;if(c)return c.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(d?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../LinkList/LinkList"),p=t("../Map/Map");function s(i,d,c){var f=this;if(i===void 0&&(i=[]),d===void 0&&(d=s.initSize),c=c||function(g){var x,y,w=0,k="";if(typeof g=="number")w=((w=Math.floor(g))<<5)-w,w&=w;else{k=typeof g!="string"?JSON.stringify(g):g;try{for(var T=o(k),I=T.next();!I.done;I=T.next())w=(w<<5)-w+I.value.charCodeAt(0),w&=w}catch(D){x={error:D}}finally{try{I&&!I.done&&(y=T.return)&&y.call(T)}finally{if(x)throw x.error}}}return w^=w>>>16},(d&d-1)!=0)throw new Error("initBucketNum must be 2 to the power of n");var h=0,v=[],m=Math.max(s.initSize,Math.min(s.maxSize,d));this.size=function(){return h},this.empty=function(){return h===0},this.clear=function(){h=0,m=d,v=[]},this.forEach=function(g){var x=0;v.forEach(function(y){y.forEach(function(w){g(w,x++)})})},this.setElement=function(g,x){var y,w;if(g==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");if(x!=null){var k=c(g)&m-1;if(v[k]){var T=v[k].size();if(v[k]instanceof u.default){try{for(var I=o(v[k]),D=I.next();!D.done;D=I.next()){var X=D.value;if(X.key===g)return void(X.value=x)}}catch(E){y={error:E}}finally{try{D&&!D.done&&(w=I.return)&&w.call(I)}finally{if(y)throw y.error}}v[k].pushBack({key:g,value:x}),v[k].size()>=s.treeifyThreshold&&(v[k]=new p.default(v[k]))}else v[k].setElement(g,x);var V=v[k].size();h+=V-T}else++h,v[k]=new u.default([{key:g,value:x}]);h>m*s.sigma&&function(E){if(!(E>=s.maxSize)){m=2*E;var A=[];v.forEach(function(C,F){if(!C.empty()){if(C instanceof u.default&&C.size()===1){var j=C.front(),P=j.key,J=j.value;A[c(P)&m-1]=new u.default([{key:P,value:J}])}else if(C instanceof p.default){var $=new u.default,U=new u.default;C.forEach(function(O){c(O.key)&E?U.pushBack(O):$.pushBack(O)}),$.size()>s.untreeifyThreshold?A[F]=new p.default($):$.size()&&(A[F]=$),U.size()>s.untreeifyThreshold?A[F+E]=new p.default(U):U.size()&&(A[F+E]=U)}else{var K=new u.default,L=new u.default;C.forEach(function(O){c(O.key)&E?L.pushBack(O):K.pushBack(O)}),K.size()&&(A[F]=K),L.size()&&(A[F+E]=L)}v[F].clear()}}),v=A}}.call(this,m)}else this.eraseElementByKey(g)},this.getElementByKey=function(g){var x,y,w=c(g)&m-1;if(v[w]){if(v[w]instanceof p.default)return v[w].getElementByKey(g);try{for(var k=o(v[w]),T=k.next();!T.done;T=k.next()){var I=T.value;if(I.key===g)return I.value}}catch(D){x={error:D}}finally{try{T&&!T.done&&(y=k.return)&&y.call(k)}finally{if(x)throw x.error}}}},this.eraseElementByKey=function(g){var x,y,w=c(g)&m-1;if(v[w]){var k=v[w].size();if(v[w]instanceof p.default)v[w].eraseElementByKey(g),v[w].size()<=s.untreeifyThreshold&&(v[w]=new u.default(v[w]));else{var T=-1;try{for(var I=o(v[w]),D=I.next();!D.done;D=I.next())if(++T,D.value.key===g){v[w].eraseElementByPos(T);break}}catch(V){x={error:V}}finally{try{D&&!D.done&&(y=I.return)&&y.call(I)}finally{if(x)throw x.error}}}var X=v[w].size();h+=X-k}},this.find=function(g){var x,y,w=c(g)&m-1;if(!v[w])return!1;if(v[w]instanceof p.default)return v[w].find(g);try{for(var k=o(v[w]),T=k.next();!T.done;T=k.next())if(T.value.key===g)return!0}catch(I){x={error:I}}finally{try{T&&!T.done&&(y=k.return)&&y.call(k)}finally{if(x)throw x.error}}return!1},this[Symbol.iterator]=function(){return function(){var g,x,y,w,k,T;return a(this,function(I){switch(I.label){case 0:g=0,I.label=1;case 1:if(!(g<m))return[3,10];for(;g<m&&!v[g];)++g;if(g>=m)return[3,10];I.label=2;case 2:I.trys.push([2,7,8,9]),k=void 0,x=o(v[g]),y=x.next(),I.label=3;case 3:return y.done?[3,6]:[4,y.value];case 4:I.sent(),I.label=5;case 5:return y=x.next(),[3,3];case 6:return[3,9];case 7:return w=I.sent(),k={error:w},[3,9];case 8:try{y&&!y.done&&(T=x.return)&&T.call(x)}finally{if(k)throw k.error}return[7];case 9:return++g,[3,1];case 10:return[2]}})}()},i.forEach(function(g){var x=g.key,y=g.value;return f.setElement(x,y)}),Object.freeze(this)}s.initSize=16,s.maxSize=1<<30,s.sigma=.75,s.treeifyThreshold=8,s.untreeifyThreshold=6,s.minTreeifySize=64,Object.freeze(s),l.default=s},{"../LinkList/LinkList":29,"../Map/Map":30}],28:[function(t,n,l){var a=this&&this.__generator||function(i,d){var c,f,h,v,m={label:0,sent:function(){if(1&h[0])throw h[1];return h[1]},trys:[],ops:[]};return v={next:g(0),throw:g(1),return:g(2)},typeof Symbol=="function"&&(v[Symbol.iterator]=function(){return this}),v;function g(x){return function(y){return function(w){if(c)throw new TypeError("Generator is already executing.");for(;m;)try{if(c=1,f&&(h=2&w[0]?f.return:w[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,w[1])).done)return h;switch(f=0,h&&(w=[2&w[0],h.value]),w[0]){case 0:case 1:h=w;break;case 4:return m.label++,{value:w[1],done:!1};case 5:m.label++,f=w[1],w=[0];continue;case 7:w=m.ops.pop(),m.trys.pop();continue;default:if(!(h=(h=m.trys).length>0&&h[h.length-1])&&(w[0]===6||w[0]===2)){m=0;continue}if(w[0]===3&&(!h||w[1]>h[0]&&w[1]<h[3])){m.label=w[1];break}if(w[0]===6&&m.label<h[1]){m.label=h[1],h=w;break}if(h&&m.label<h[2]){m.label=h[2],m.ops.push(w);break}h[2]&&m.ops.pop(),m.trys.pop();continue}w=d.call(i,m)}catch(k){w=[6,k],f=0}finally{c=h=0}if(5&w[0])throw w[1];return{value:w[0]?w[1]:void 0,done:!0}}([x,y])}}},o=this&&this.__values||function(i){var d=typeof Symbol=="function"&&Symbol.iterator,c=d&&i[d],f=0;if(c)return c.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(d?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../Set/Set"),p=t("../LinkList/LinkList");function s(i,d,c){var f=this;if(i===void 0&&(i=[]),d===void 0&&(d=s.initSize),c=c||function(g){var x=0,y="";if(typeof g=="number")x=((x=Math.floor(g))<<5)-x,x&=x;else{y=typeof g!="string"?JSON.stringify(g):g;for(var w=0;w<y.length;w++)x=(x<<5)-x+y.charCodeAt(w),x&=x}return x^=x>>>16},(d&d-1)!=0)throw new Error("initBucketNum must be 2 to the power of n");var h=0,v=[],m=Math.max(s.initSize,Math.min(s.maxSize,d));this.size=function(){return h},this.empty=function(){return h===0},this.clear=function(){h=0,m=d,v=[]},this.forEach=function(g){var x=0;v.forEach(function(y){y.forEach(function(w){g(w,x++)})})},this.insert=function(g){if(g==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");var x=c(g)&m-1;if(v[x]){var y=v[x].size();if(v[x]instanceof p.default){if(v[x].find(g))return;v[x].pushBack(g),v[x].size()>=s.treeifyThreshold&&(v[x]=new u.default(v[x]))}else v[x].insert(g);var w=v[x].size();h+=w-y}else v[x]=new p.default([g]),++h;h>m*s.sigma&&function(k){if(!(k>=s.maxSize)){m=2*k;var T=[];v.forEach(function(I,D){if(!I.empty()){if(I instanceof p.default&&I.size()===1){var X=I.front();if(X===void 0)throw new Error("unknown error");T[c(X)&m-1]=new p.default([X])}else if(I instanceof u.default){var V=new p.default,E=new p.default;I.forEach(function(F){c(F)&k?E.pushBack(F):V.pushBack(F)}),V.size()>s.untreeifyThreshold?T[D]=new u.default(V):V.size()&&(T[D]=V),E.size()>s.untreeifyThreshold?T[D+k]=new u.default(E):E.size()&&(T[D+k]=E)}else{var A=new p.default,C=new p.default;I.forEach(function(F){c(F)&k?C.pushBack(F):A.pushBack(F)}),A.size()&&(T[D]=A),C.size()&&(T[D+k]=C)}v[D].clear()}}),v=T}}.call(this,m)},this.eraseElementByValue=function(g){var x=c(g)&m-1;if(v[x]){var y=v[x].size();v[x].eraseElementByValue(g),v[x]instanceof u.default&&v[x].size()<=s.untreeifyThreshold&&(v[x]=new p.default(v[x]));var w=v[x].size();h+=w-y}},this.find=function(g){var x=c(g)&m-1;return!!v[x]&&v[x].find(g)},this[Symbol.iterator]=function(){return function(){var g,x,y,w,k,T;return a(this,function(I){switch(I.label){case 0:g=0,I.label=1;case 1:if(!(g<m))return[3,10];for(;g<m&&!v[g];)++g;if(g>=m)return[3,10];I.label=2;case 2:I.trys.push([2,7,8,9]),k=void 0,x=o(v[g]),y=x.next(),I.label=3;case 3:return y.done?[3,6]:[4,y.value];case 4:I.sent(),I.label=5;case 5:return y=x.next(),[3,3];case 6:return[3,9];case 7:return w=I.sent(),k={error:w},[3,9];case 8:try{y&&!y.done&&(T=x.return)&&T.call(x)}finally{if(k)throw k.error}return[7];case 9:return++g,[3,1];case 10:return[2]}})}()},i.forEach(function(g){return f.insert(g)}),Object.freeze(this)}s.initSize=16,s.maxSize=1<<30,s.sigma=.75,s.treeifyThreshold=8,s.untreeifyThreshold=6,s.minTreeifySize=64,Object.freeze(s),l.default=s},{"../LinkList/LinkList":29,"../Set/Set":33}],29:[function(t,n,l){var a=this&&this.__generator||function(p,s){var i,d,c,f,h={label:0,sent:function(){if(1&c[0])throw c[1];return c[1]},trys:[],ops:[]};return f={next:v(0),throw:v(1),return:v(2)},typeof Symbol=="function"&&(f[Symbol.iterator]=function(){return this}),f;function v(m){return function(g){return function(x){if(i)throw new TypeError("Generator is already executing.");for(;h;)try{if(i=1,d&&(c=2&x[0]?d.return:x[0]?d.throw||((c=d.return)&&c.call(d),0):d.next)&&!(c=c.call(d,x[1])).done)return c;switch(d=0,c&&(x=[2&x[0],c.value]),x[0]){case 0:case 1:c=x;break;case 4:return h.label++,{value:x[1],done:!1};case 5:h.label++,d=x[1],x=[0];continue;case 7:x=h.ops.pop(),h.trys.pop();continue;default:if(!(c=(c=h.trys).length>0&&c[c.length-1])&&(x[0]===6||x[0]===2)){h=0;continue}if(x[0]===3&&(!c||x[1]>c[0]&&x[1]<c[3])){h.label=x[1];break}if(x[0]===6&&h.label<c[1]){h.label=c[1],c=x;break}if(c&&h.label<c[2]){h.label=c[2],h.ops.push(x);break}c[2]&&h.ops.pop(),h.trys.pop();continue}x=s.call(p,h)}catch(y){x=[6,y],d=0}finally{i=c=0}if(5&x[0])throw x[1];return{value:x[0]?x[1]:void 0,done:!0}}([m,g])}}};Object.defineProperty(l,"__esModule",{value:!0});var o=function(){return function(p){this.value=void 0,this.pre=void 0,this.next=void 0,this.value=p}}();function u(p){var s=this;p===void 0&&(p=[]);var i=0,d=void 0,c=void 0;this.size=function(){return i},this.empty=function(){return i===0},this.clear=function(){d=c=void 0,i=0},this.front=function(){return d==null?void 0:d.value},this.back=function(){return c==null?void 0:c.value},this.forEach=function(f){for(var h=d,v=0;h;){if(h.value===void 0)throw new Error("unknown error");f(h.value,v++),h=h.next}},this.getElementByPos=function(f){if(f<0||f>=i)throw new Error("pos must more then 0 and less then the list length");for(var h=d;f--&&h;)h=h.next;if(!h||h.value===void 0)throw new Error("unknown error");return h.value},this.eraseElementByPos=function(f){if(f<0||f>=i)throw new Error("erase pos must more then 0 and less then the list length");if(f===0)this.popFront();else if(f===i-1)this.popBack();else{for(var h=d;f--;){if(!(h!=null&&h.next))throw new Error("unknown error");h=h.next}if(!h||!h.pre||!h.next)throw new Error("unknown error");var v=h.pre,m=h.next;m.pre=v,v.next=m,i>0&&--i}},this.eraseElementByValue=function(f){for(;d&&d.value===f;)this.popFront();for(;c&&c.value===f;)this.popBack();if(d)for(var h=d;h;){if(h.value===f){var v=h.pre,m=h.next;m&&(m.pre=v),v&&(v.next=m),i>0&&--i}h=h.next}},this.pushBack=function(f){if(f==null)throw new Error("you can't push null or undefined here");++i;var h=new o(f);c?(c.next=h,h.pre=c,c=h):d=c=h},this.popBack=function(){c&&(i>0&&--i,c&&(d===c?d=c=void 0:(c=c.pre)&&(c.next=void 0)))},this.setElementByPos=function(f,h){if(h==null)throw new Error("you can't set null or undefined here");if(f<0||f>=i)throw new Error("pos must more then 0 and less then the list length");for(var v=d;f--;){if(!v)throw new Error("unknown error");v=v.next}v&&(v.value=h)},this.insert=function(f,h,v){if(v===void 0&&(v=1),h==null)throw new Error("you can't insert null or undefined here");if(f<0||f>i)throw new Error("insert pos must more then 0 and less then or equal to the list length");if(v<0)throw new Error("insert size must more than 0");if(f===0)for(;v--;)this.pushFront(h);else if(f===i)for(;v--;)this.pushBack(h);else{for(var m=d,g=1;g<f;++g){if(!(m!=null&&m.next))throw new Error("unknown error");m=m==null?void 0:m.next}if(!m)throw new Error("unknown error");var x=m.next;for(i+=v;v--;)m.next=new o(h),m.next.pre=m,m=m.next;m.next=x,x&&(x.pre=m)}},this.find=function(f){for(var h=d;h;){if(h.value===f)return!0;h=h.next}return!1},this.reverse=function(){for(var f=d,h=c,v=0;f&&h&&2*v<i;){var m=f.value;f.value=h.value,h.value=m,f=f.next,h=h.pre,++v}},this.unique=function(){for(var f=d;f;){for(var h=f;h&&h.next&&h.value===h.next.value;)h=h.next,i>0&&--i;f.next=h.next,f.next&&(f.next.pre=f),f=f.next}},this.sort=function(f){var h=[];this.forEach(function(m){h.push(m)}),h.sort(f);var v=d;h.forEach(function(m){v&&(v.value=m,v=v.next)})},this.pushFront=function(f){if(f==null)throw new Error("you can't push null or undefined here");++i;var h=new o(f);d?(h.next=d,d.pre=h,d=h):d=c=h},this.popFront=function(){d&&(i>0&&--i,d&&(d===c?d=c=void 0:(d=d.next)&&(d.pre=void 0)))},this.merge=function(f){var h=this,v=d;f.forEach(function(m){for(;v&&v.value!==void 0&&v.value<=m;)v=v.next;if(v===void 0)h.pushBack(m),v=c;else if(v===d)h.pushFront(m),v=d;else{++i;var g=v.pre;g&&(g.next=new o(m),g.next.pre=g,g.next.next=v,v&&(v.pre=g.next))}})},this[Symbol.iterator]=function(){return function(){var f;return a(this,function(h){switch(h.label){case 0:f=d,h.label=1;case 1:if(f===void 0)return[3,3];if(!f.value)throw new Error("unknown error");return[4,f.value];case 2:return h.sent(),f=f.next,[3,1];case 3:return[2]}})}()},p.forEach(function(f){return s.pushBack(f)}),Object.freeze(this)}Object.freeze(u),l.default=u},{}],30:[function(t,n,l){var a=this&&this.__generator||function(s,i){var d,c,f,h,v={label:0,sent:function(){if(1&f[0])throw f[1];return f[1]},trys:[],ops:[]};return h={next:m(0),throw:m(1),return:m(2)},typeof Symbol=="function"&&(h[Symbol.iterator]=function(){return this}),h;function m(g){return function(x){return function(y){if(d)throw new TypeError("Generator is already executing.");for(;v;)try{if(d=1,c&&(f=2&y[0]?c.return:y[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,y[1])).done)return f;switch(c=0,f&&(y=[2&y[0],f.value]),y[0]){case 0:case 1:f=y;break;case 4:return v.label++,{value:y[1],done:!1};case 5:v.label++,c=y[1],y=[0];continue;case 7:y=v.ops.pop(),v.trys.pop();continue;default:if(!(f=(f=v.trys).length>0&&f[f.length-1])&&(y[0]===6||y[0]===2)){v=0;continue}if(y[0]===3&&(!f||y[1]>f[0]&&y[1]<f[3])){v.label=y[1];break}if(y[0]===6&&v.label<f[1]){v.label=f[1],f=y;break}if(f&&v.label<f[2]){v.label=f[2],v.ops.push(y);break}f[2]&&v.ops.pop(),v.trys.pop();continue}y=i.call(s,v)}catch(w){y=[6,w],c=0}finally{d=f=0}if(5&y[0])throw y[1];return{value:y[0]?y[1]:void 0,done:!0}}([g,x])}}},o=this&&this.__values||function(s){var i=typeof Symbol=="function"&&Symbol.iterator,d=i&&s[i],c=0;if(d)return d.call(s);if(s&&typeof s.length=="number")return{next:function(){return s&&c>=s.length&&(s=void 0),{value:s&&s[c++],done:!s}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../Base/TreeNode");function p(s,i){var d=this;s===void 0&&(s=[]),i=i||function(E,A){return E<A?-1:E>A?1:0};var c=0,f=new u.default;f.color=u.default.TreeNodeColorType.black,this.size=function(){return c},this.empty=function(){return c===0},this.clear=function(){c=0,f.key=f.value=void 0,f.leftChild=f.rightChild=f.brother=void 0};var h=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.leftChild?h(E.leftChild):E},v=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.rightChild?v(E.rightChild):E};this.front=function(){if(!this.empty()){var E=h(f);if(E.key===void 0||E.value===void 0)throw new Error("unknown error");return{key:E.key,value:E.value}}},this.back=function(){if(!this.empty()){var E=v(f);if(E.key===void 0||E.value===void 0)throw new Error("unknown error");return{key:E.key,value:E.value}}},this.forEach=function(E){var A,C,F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next())E(P.value,F++)}catch(J){A={error:J}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}},this.getElementByPos=function(E){var A,C;if(E<0||E>=this.size())throw new Error("pos must more than 0 and less than set's size");var F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next()){var J=P.value;if(F===E)return J;++F}}catch($){A={error:$}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}throw new Error("unknown Error")};var m=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0){var C=i(E.key,A);return C===0?{key:E.key,value:E.value}:C<0?m(E.rightChild,A):m(E.leftChild,A)||{key:E.key,value:E.value}}};this.lowerBound=function(E){return m(f,E)};var g=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0)return i(E.key,A)<=0?g(E.rightChild,A):g(E.leftChild,A)||{key:E.key,value:E.value}};this.upperBound=function(E){return g(f,E)};var x=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0){var C=i(E.key,A);return C===0?{key:E.key,value:E.value}:C>0?x(E.leftChild,A):x(E.rightChild,A)||{key:E.key,value:E.value}}};this.reverseLowerBound=function(E){return x(f,E)};var y=function(E,A){if(E&&E.key!==void 0&&E.value!==void 0)return i(E.key,A)>=0?y(E.leftChild,A):y(E.rightChild,A)||{key:E.key,value:E.value}};this.reverseUpperBound=function(E){return y(f,E)};var w=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(E.color!==u.default.TreeNodeColorType.red){var C=E.brother;if(!C)throw new Error("unknown error");if(E===A.leftChild)if(C.color===u.default.TreeNodeColorType.red){C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red;var F=A.rotateLeft();f===A&&(f=F),w(E)}else C.color===u.default.TreeNodeColorType.black&&(C.rightChild&&C.rightChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=A.rotateLeft(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||!C.leftChild||C.leftChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,w(A)):(C.color=u.default.TreeNodeColorType.red,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=C.rotateRight(),f===C&&(f=F),w(E)));else E===A.rightChild&&(C.color===u.default.TreeNodeColorType.red?(C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red,F=A.rotateRight(),f===A&&(f=F),w(E)):C.color===u.default.TreeNodeColorType.black&&(C.leftChild&&C.leftChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=A.rotateRight(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||!C.rightChild||C.rightChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,w(A)):(C.color=u.default.TreeNodeColorType.red,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=C.rotateLeft(),f===C&&(f=F),w(E))))}else E.color=u.default.TreeNodeColorType.black},k=function(E){for(var A=E;A.leftChild||A.rightChild;){if(A.rightChild){A=h(A.rightChild);var C=E.key;E.key=A.key,A.key=C;var F=E.value;E.value=A.value,A.value=F,E=A}A.leftChild&&(A=v(A.leftChild),C=E.key,E.key=A.key,A.key=C,F=E.value,E.value=A.value,A.value=F,E=A)}w(A),A&&A.remove(),--c,f.color=u.default.TreeNodeColorType.black},T=function(E,A){return!(!E||E.key===void 0)&&(!!T(E.leftChild,A)||!!A(E)||T(E.rightChild,A))};this.eraseElementByPos=function(E){if(E<0||E>=c)throw new Error("pos must more than 0 and less than set's size");var A=0;T(f,function(C){return E===A?(k(C),!0):(++A,!1)})},this.eraseElementByKey=function(E){if(!this.empty()){var A=X(f,E);A!==void 0&&A.key!==void 0&&i(A.key,E)===0&&k(A)}};var I=function(E,A){if(!E||E.key===void 0)throw new Error("unknown error");var C=i(A,E.key);return C<0?E.leftChild?I(E.leftChild,A):(E.leftChild=new u.default,E.leftChild.parent=E,E.leftChild.brother=E.rightChild,E.rightChild&&(E.rightChild.brother=E.leftChild),E.leftChild):C>0?E.rightChild?I(E.rightChild,A):(E.rightChild=new u.default,E.rightChild.parent=E,E.rightChild.brother=E.leftChild,E.leftChild&&(E.leftChild.brother=E.rightChild),E.rightChild):E},D=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(A.color!==u.default.TreeNodeColorType.black&&A.color===u.default.TreeNodeColorType.red){var C=A.brother,F=A.parent;if(!F)throw new Error("unknown error");if(C&&C.color===u.default.TreeNodeColorType.red)C.color=A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,D(F);else if(!C||C.color===u.default.TreeNodeColorType.black)if(A===F.leftChild)if(E===A.leftChild){A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red;var j=F.rotateRight();F===f&&(f=j)}else E===A.rightChild&&(j=A.rotateLeft(),F===f&&(f=j),D(A));else A===F.rightChild&&(E===A.leftChild?(j=A.rotateRight(),F===f&&(f=j),D(A)):E===A.rightChild&&(A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,j=F.rotateLeft(),F===f&&(f=j)))}};this.setElement=function(E,A){if(E==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");if(A!=null){if(this.empty())return++c,f.key=E,f.value=A,void(f.color=u.default.TreeNodeColorType.black);var C=I(f,E);C.key===void 0||i(C.key,E)!==0?(++c,C.key=E,C.value=A,D(C),f.color=u.default.TreeNodeColorType.black):C.value=A}else this.eraseElementByKey(E)};var X=function(E,A){if(E&&E.key!==void 0){var C=i(A,E.key);return C<0?X(E.leftChild,A):C>0?X(E.rightChild,A):E}};this.find=function(E){return!!X(f,E)},this.getElementByKey=function(E){var A=X(f,E);if((A==null?void 0:A.key)===void 0||(A==null?void 0:A.value)===void 0)throw new Error("unknown error");return A.value},this.union=function(E){var A=this;E.forEach(function(C){var F=C.key,j=C.value;return A.setElement(F,j)})},this.getHeight=function(){if(this.empty())return 0;var E=function(A){return A?Math.max(E(A.leftChild),E(A.rightChild))+1:1};return E(f)};var V=function(E){return a(this,function(A){switch(A.label){case 0:return E&&E.key!==void 0&&E.value!==void 0?[5,o(V(E.leftChild))]:[2];case 1:return A.sent(),[4,{key:E.key,value:E.value}];case 2:return A.sent(),[5,o(V(E.rightChild))];case 3:return A.sent(),[2]}})};this[Symbol.iterator]=function(){return V(f)},s.forEach(function(E){var A=E.key,C=E.value;return d.setElement(A,C)}),Object.freeze(this)}Object.freeze(p),l.default=p},{"../Base/TreeNode":25}],31:[function(t,n,l){function a(o,u){o===void 0&&(o=[]),u=u||function(c,f){return c>f?-1:c<f?1:0};var p=[];o.forEach(function(c){return p.push(c)});var s=p.length,i=function(c,f){if(c<0||c>=s)throw new Error("unknown error");if(f<0||f>=s)throw new Error("unknown error");var h=p[c];p[c]=p[f],p[f]=h},d=function(c){if(c<0||c>=s)throw new Error("unknown error");var f=2*c+1,h=2*c+2;f<s&&u(p[c],p[f])>0&&i(c,f),h<s&&u(p[c],p[h])>0&&i(c,h)};(function(){for(var c=Math.floor((s-1)/2);c>=0;--c)for(var f=c,h=2*f+1;h<s;){var v=h+1,m=h;if(v<s&&u(p[h],p[v])>0&&(m=v),u(p[f],p[m])<=0)break;i(f,m),h=2*(f=m)+1}})(),this.size=function(){return s},this.empty=function(){return s===0},this.clear=function(){s=0,p.length=0},this.push=function(c){if(p.push(c),++s!==1)for(var f=s-1;f>0;){var h=Math.floor((f-1)/2);if(u(p[h],c)<=0)break;d(h),f=h}},this.pop=function(){if(!this.empty())if(this.size()!==1){var c=p[s-1];--s;for(var f=0;f<this.size();){var h=2*f+1,v=2*f+2;if(h>=this.size())break;var m=h;if(v<this.size()&&u(p[h],p[v])>0&&(m=v),u(p[m],c)>=0)break;p[f]=p[m],f=m}p[f]=c}else--s},this.top=function(){return p[0]},Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),Object.freeze(a),l.default=a},{}],32:[function(t,n,l){Object.defineProperty(l,"__esModule",{value:!0});var a=t("../LinkList/LinkList");function o(u){u===void 0&&(u=[]);var p=new a.default(u);this.size=function(){return p.size()},this.empty=function(){return p.empty()},this.clear=function(){p.clear()},this.push=function(s){p.pushBack(s)},this.pop=function(){p.popFront()},this.front=function(){return p.front()},Object.freeze(this)}Object.freeze(o),l.default=o},{"../LinkList/LinkList":29}],33:[function(t,n,l){var a=this&&this.__generator||function(s,i){var d,c,f,h,v={label:0,sent:function(){if(1&f[0])throw f[1];return f[1]},trys:[],ops:[]};return h={next:m(0),throw:m(1),return:m(2)},typeof Symbol=="function"&&(h[Symbol.iterator]=function(){return this}),h;function m(g){return function(x){return function(y){if(d)throw new TypeError("Generator is already executing.");for(;v;)try{if(d=1,c&&(f=2&y[0]?c.return:y[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,y[1])).done)return f;switch(c=0,f&&(y=[2&y[0],f.value]),y[0]){case 0:case 1:f=y;break;case 4:return v.label++,{value:y[1],done:!1};case 5:v.label++,c=y[1],y=[0];continue;case 7:y=v.ops.pop(),v.trys.pop();continue;default:if(!(f=(f=v.trys).length>0&&f[f.length-1])&&(y[0]===6||y[0]===2)){v=0;continue}if(y[0]===3&&(!f||y[1]>f[0]&&y[1]<f[3])){v.label=y[1];break}if(y[0]===6&&v.label<f[1]){v.label=f[1],f=y;break}if(f&&v.label<f[2]){v.label=f[2],v.ops.push(y);break}f[2]&&v.ops.pop(),v.trys.pop();continue}y=i.call(s,v)}catch(w){y=[6,w],c=0}finally{d=f=0}if(5&y[0])throw y[1];return{value:y[0]?y[1]:void 0,done:!0}}([g,x])}}},o=this&&this.__values||function(s){var i=typeof Symbol=="function"&&Symbol.iterator,d=i&&s[i],c=0;if(d)return d.call(s);if(s&&typeof s.length=="number")return{next:function(){return s&&c>=s.length&&(s=void 0),{value:s&&s[c++],done:!s}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(l,"__esModule",{value:!0});var u=t("../Base/TreeNode");function p(s,i){var d=this;s===void 0&&(s=[]),i=i||function(E,A){return E<A?-1:E>A?1:0};var c=0,f=new u.default;f.color=u.default.TreeNodeColorType.black,this.size=function(){return c},this.empty=function(){return c===0},this.clear=function(){c=0,f.key=void 0,f.leftChild=f.rightChild=f.brother=f.parent=void 0,f.color=u.default.TreeNodeColorType.black};var h=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.leftChild?h(E.leftChild):E},v=function(E){if(!E||E.key===void 0)throw new Error("unknown error");return E.rightChild?v(E.rightChild):E};this.front=function(){if(!this.empty())return h(f).key},this.back=function(){if(!this.empty())return v(f).key},this.forEach=function(E){var A,C,F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next())E(P.value,F++)}catch(J){A={error:J}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}},this.getElementByPos=function(E){var A,C;if(E<0||E>=this.size())throw new Error("pos must more than 0 and less than set's size");var F=0;try{for(var j=o(this),P=j.next();!P.done;P=j.next()){var J=P.value;if(F===E)return J;++F}}catch($){A={error:$}}finally{try{P&&!P.done&&(C=j.return)&&C.call(j)}finally{if(A)throw A.error}}throw new Error("unknown error")};var m=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(E.color!==u.default.TreeNodeColorType.red){var C=E.brother;if(!C)throw new Error("unknown error");if(E===A.leftChild)if(C.color===u.default.TreeNodeColorType.red){C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red;var F=A.rotateLeft();f===A&&(f=F),m(E)}else C.color===u.default.TreeNodeColorType.black&&(C.rightChild&&C.rightChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=A.rotateLeft(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||!C.leftChild||C.leftChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,m(A)):(C.color=u.default.TreeNodeColorType.red,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=C.rotateRight(),f===C&&(f=F),m(E)));else E===A.rightChild&&(C.color===u.default.TreeNodeColorType.red?(C.color=u.default.TreeNodeColorType.black,A.color=u.default.TreeNodeColorType.red,F=A.rotateRight(),f===A&&(f=F),m(E)):C.color===u.default.TreeNodeColorType.black&&(C.leftChild&&C.leftChild.color===u.default.TreeNodeColorType.red?(C.color=A.color,A.color=u.default.TreeNodeColorType.black,C.leftChild&&(C.leftChild.color=u.default.TreeNodeColorType.black),F=A.rotateRight(),f===A&&(f=F),E.color=u.default.TreeNodeColorType.black):C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||!C.rightChild||C.rightChild.color!==u.default.TreeNodeColorType.red?C.leftChild&&C.leftChild.color!==u.default.TreeNodeColorType.black||C.rightChild&&C.rightChild.color!==u.default.TreeNodeColorType.black||(C.color=u.default.TreeNodeColorType.red,m(A)):(C.color=u.default.TreeNodeColorType.red,C.rightChild&&(C.rightChild.color=u.default.TreeNodeColorType.black),F=C.rotateLeft(),f===C&&(f=F),m(E))))}else E.color=u.default.TreeNodeColorType.black},g=function(E){for(var A=E;A.leftChild||A.rightChild;){if(A.rightChild){A=h(A.rightChild);var C=E.key;E.key=A.key,A.key=C,E=A}A.leftChild&&(A=v(A.leftChild),C=E.key,E.key=A.key,A.key=C,E=A)}m(A),A&&A.remove(),--c,f.color=u.default.TreeNodeColorType.black},x=function(E,A){return!(!E||E.key===void 0)&&(!!x(E.leftChild,A)||!!A(E)||x(E.rightChild,A))};this.eraseElementByPos=function(E){if(E<0||E>=c)throw new Error("pos must more than 0 and less than set's size");var A=0;x(f,function(C){return E===A?(g(C),!0):(++A,!1)})},this.eraseElementByValue=function(E){if(!this.empty()){var A=k(f,E);A!==void 0&&A.key!==void 0&&i(A.key,E)===0&&g(A)}};var y=function(E,A){if(!E||E.key===void 0)throw new Error("unknown error");var C=i(A,E.key);return C<0?E.leftChild?y(E.leftChild,A):(E.leftChild=new u.default,E.leftChild.parent=E,E.leftChild.brother=E.rightChild,E.rightChild&&(E.rightChild.brother=E.leftChild),E.leftChild):C>0?E.rightChild?y(E.rightChild,A):(E.rightChild=new u.default,E.rightChild.parent=E,E.rightChild.brother=E.leftChild,E.leftChild&&(E.leftChild.brother=E.rightChild),E.rightChild):E},w=function(E){var A=E.parent;if(!A){if(E===f)return;throw new Error("unknown error")}if(A.color!==u.default.TreeNodeColorType.black&&A.color===u.default.TreeNodeColorType.red){var C=A.brother,F=A.parent;if(!F)throw new Error("unknown error");if(C&&C.color===u.default.TreeNodeColorType.red)C.color=A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,w(F);else if(!C||C.color===u.default.TreeNodeColorType.black)if(A===F.leftChild)if(E===A.leftChild){A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red;var j=F.rotateRight();F===f&&(f=j)}else E===A.rightChild&&(j=A.rotateLeft(),F===f&&(f=j),w(A));else A===F.rightChild&&(E===A.leftChild?(j=A.rotateRight(),F===f&&(f=j),w(A)):E===A.rightChild&&(A.color=u.default.TreeNodeColorType.black,F.color=u.default.TreeNodeColorType.red,j=F.rotateLeft(),F===f&&(f=j)))}};this.insert=function(E){if(E==null)throw new Error("to avoid some unnecessary errors, we don't suggest you insert null or undefined here");if(this.empty())return++c,f.key=E,void(f.color=u.default.TreeNodeColorType.black);var A=y(f,E);A.key!==void 0&&i(A.key,E)===0||(++c,A.key=E,w(A),f.color=u.default.TreeNodeColorType.black)};var k=function(E,A){if(E&&E.key!==void 0){var C=i(A,E.key);return C<0?k(E.leftChild,A):C>0?k(E.rightChild,A):E}};this.find=function(E){var A=k(f,E);return A!==void 0&&A.key!==void 0&&i(A.key,E)===0};var T=function(E,A){if(E&&E.key!==void 0){var C=i(E.key,A);if(C===0)return E.key;if(C<0)return T(E.rightChild,A);var F=T(E.leftChild,A);return F!==void 0?F:E.key}};this.lowerBound=function(E){return T(f,E)};var I=function(E,A){if(E&&E.key!==void 0){if(i(E.key,A)<=0)return I(E.rightChild,A);var C=I(E.leftChild,A);return C!==void 0?C:E.key}};this.upperBound=function(E){return I(f,E)};var D=function(E,A){if(E&&E.key!==void 0){var C=i(E.key,A);if(C===0)return E.key;if(C>0)return D(E.leftChild,A);var F=D(E.rightChild,A);return F!==void 0?F:E.key}};this.reverseLowerBound=function(E){return D(f,E)};var X=function(E,A){if(E&&E.key!==void 0){if(i(E.key,A)>=0)return X(E.leftChild,A);var C=X(E.rightChild,A);return C!==void 0?C:E.key}};this.reverseUpperBound=function(E){return X(f,E)},this.union=function(E){var A=this;E.forEach(function(C){return A.insert(C)})},this.getHeight=function(){if(this.empty())return 0;var E=function(A){return A?Math.max(E(A.leftChild),E(A.rightChild))+1:1};return E(f)};var V=function(E){return a(this,function(A){switch(A.label){case 0:return E&&E.key!==void 0?[5,o(V(E.leftChild))]:[2];case 1:return A.sent(),[4,E.key];case 2:return A.sent(),[5,o(V(E.rightChild))];case 3:return A.sent(),[2]}})};this[Symbol.iterator]=function(){return V(f)},s.forEach(function(E){return d.insert(E)}),Object.freeze(this)}Object.freeze(p),l.default=p},{"../Base/TreeNode":25}],34:[function(t,n,l){function a(o){var u=this;o===void 0&&(o=[]);var p=0,s=[];this.size=function(){return p},this.empty=function(){return p===0},this.clear=function(){p=0,s.length=0},this.push=function(i){s.push(i),++p},this.pop=function(){s.pop(),p>0&&--p},this.top=function(){return s[p-1]},o.forEach(function(i){return u.push(i)}),Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),Object.freeze(a),l.default=a},{}],35:[function(t,n,l){var a=this&&this.__generator||function(i,d){var c,f,h,v,m={label:0,sent:function(){if(1&h[0])throw h[1];return h[1]},trys:[],ops:[]};return v={next:g(0),throw:g(1),return:g(2)},typeof Symbol=="function"&&(v[Symbol.iterator]=function(){return this}),v;function g(x){return function(y){return function(w){if(c)throw new TypeError("Generator is already executing.");for(;m;)try{if(c=1,f&&(h=2&w[0]?f.return:w[0]?f.throw||((h=f.return)&&h.call(f),0):f.next)&&!(h=h.call(f,w[1])).done)return h;switch(f=0,h&&(w=[2&w[0],h.value]),w[0]){case 0:case 1:h=w;break;case 4:return m.label++,{value:w[1],done:!1};case 5:m.label++,f=w[1],w=[0];continue;case 7:w=m.ops.pop(),m.trys.pop();continue;default:if(!(h=(h=m.trys).length>0&&h[h.length-1])&&(w[0]===6||w[0]===2)){m=0;continue}if(w[0]===3&&(!h||w[1]>h[0]&&w[1]<h[3])){m.label=w[1];break}if(w[0]===6&&m.label<h[1]){m.label=h[1],h=w;break}if(h&&m.label<h[2]){m.label=h[2],m.ops.push(w);break}h[2]&&m.ops.pop(),m.trys.pop();continue}w=d.call(i,m)}catch(k){w=[6,k],f=0}finally{c=h=0}if(5&w[0])throw w[1];return{value:w[0]?w[1]:void 0,done:!0}}([x,y])}}},o=this&&this.__read||function(i,d){var c=typeof Symbol=="function"&&i[Symbol.iterator];if(!c)return i;var f,h,v=c.call(i),m=[];try{for(;(d===void 0||d-- >0)&&!(f=v.next()).done;)m.push(f.value)}catch(g){h={error:g}}finally{try{f&&!f.done&&(c=v.return)&&c.call(v)}finally{if(h)throw h.error}}return m},u=this&&this.__spreadArray||function(i,d,c){if(c||arguments.length===2)for(var f,h=0,v=d.length;h<v;h++)!f&&h in d||(f||(f=Array.prototype.slice.call(d,0,h)),f[h]=d[h]);return i.concat(f||Array.prototype.slice.call(d))},p=this&&this.__values||function(i){var d=typeof Symbol=="function"&&Symbol.iterator,c=d&&i[d],f=0;if(c)return c.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&f>=i.length&&(i=void 0),{value:i&&i[f++],done:!i}}};throw new TypeError(d?"Object is not iterable.":"Symbol.iterator is not defined.")};function s(i){var d=this;i===void 0&&(i=[]);var c=0,f=[];this.size=function(){return c},this.empty=function(){return c===0},this.clear=function(){c=0,f.length=0},this.front=function(){if(!this.empty())return f[0]},this.back=function(){if(!this.empty())return f[c-1]},this.forEach=function(h){f.forEach(h)},this.getElementByPos=function(h){if(h<0||h>=c)throw new Error("pos must more than 0 and less than vector's size");return f[h]},this.eraseElementByPos=function(h){if(h<0||h>=c)throw new Error("pos must more than 0 and less than vector's size");for(var v=h;v<c-1;++v)f[v]=f[v+1];this.popBack()},this.eraseElementByValue=function(h){var v=[];this.forEach(function(g){g!==h&&v.push(g)}),v.forEach(function(g,x){f[x]=g});for(var m=v.length;c>m;)this.popBack()},this.pushBack=function(h){f.push(h),++c},this.popBack=function(){f.pop(),c>0&&--c},this.setElementByPos=function(h,v){if(h<0||h>=c)throw new Error("pos must more than 0 and less than vector's size");f[h]=v},this.insert=function(h,v,m){if(m===void 0&&(m=1),h<0||h>c)throw new Error("pos must more than 0 and less than or equal to vector's size");f.splice.apply(f,u([h,0],o(new Array(m).fill(v)),!1)),c+=m},this.find=function(h){return f.includes(h)},this.reverse=function(){f.reverse()},this.unique=function(){var h,v=[];this.forEach(function(g,x){x!==0&&g===h||(v.push(g),h=g)}),v.forEach(function(g,x){f[x]=g});for(var m=v.length;c>m;)this.popBack()},this.sort=function(h){f.sort(h)},this[Symbol.iterator]=function(){return function(){return a(this,function(h){switch(h.label){case 0:return[5,p(f)];case 1:return[2,h.sent()]}})}()},i.forEach(function(h){return d.pushBack(h)}),Object.freeze(this)}Object.defineProperty(l,"__esModule",{value:!0}),Object.freeze(s),l.default=s},{}],36:[function(t,n,l){Object.defineProperty(l,"__esModule",{value:!0}),l.HashMap=l.HashSet=l.Map=l.Set=l.PriorityQueue=l.Deque=l.LinkList=l.Queue=l.Stack=l.Vector=void 0;var a=t("./Vector/Vector");l.Vector=a.default;var o=t("./Stack/Stack");l.Stack=o.default;var u=t("./Queue/Queue");l.Queue=u.default;var p=t("./LinkList/LinkList");l.LinkList=p.default;var s=t("./Deque/Deque");l.Deque=s.default;var i=t("./PriorityQueue/PriorityQueue");l.PriorityQueue=i.default;var d=t("./Set/Set");l.Set=d.default;var c=t("./Map/Map");l.Map=c.default;var f=t("./HashSet/HashSet");l.HashSet=f.default;var h=t("./HashMap/HashMap");l.HashMap=h.default},{"./Deque/Deque":26,"./HashMap/HashMap":27,"./HashSet/HashSet":28,"./LinkList/LinkList":29,"./Map/Map":30,"./PriorityQueue/PriorityQueue":31,"./Queue/Queue":32,"./Set/Set":33,"./Stack/Stack":34,"./Vector/Vector":35}],37:[function(t,n,l){const a=t("yallist"),o=Symbol("max"),u=Symbol("length"),p=Symbol("lengthCalculator"),s=Symbol("allowStale"),i=Symbol("maxAge"),d=Symbol("dispose"),c=Symbol("noDisposeOnSet"),f=Symbol("lruList"),h=Symbol("cache"),v=Symbol("updateAgeOnGet"),m=()=>1,g=(I,D,X)=>{const V=I[h].get(D);if(V){const E=V.value;if(x(I,E)){if(w(I,V),!I[s])return}else X&&(I[v]&&(V.value.now=Date.now()),I[f].unshiftNode(V));return E.value}},x=(I,D)=>{if(!D||!D.maxAge&&!I[i])return!1;const X=Date.now()-D.now;return D.maxAge?X>D.maxAge:I[i]&&X>I[i]},y=I=>{if(I[u]>I[o])for(let D=I[f].tail;I[u]>I[o]&&D!==null;){const X=D.prev;w(I,D),D=X}},w=(I,D)=>{if(D){const X=D.value;I[d]&&I[d](X.key,X.value),I[u]-=X.length,I[h].delete(X.key),I[f].removeNode(D)}};class k{constructor(D,X,V,E,A){this.key=D,this.value=X,this.length=V,this.now=E,this.maxAge=A||0}}const T=(I,D,X,V)=>{let E=X.value;x(I,E)&&(w(I,X),I[s]||(E=void 0)),E&&D.call(V,E.value,E.key,I)};n.exports=class{constructor(I){if(typeof I=="number"&&(I={max:I}),I||(I={}),I.max&&(typeof I.max!="number"||I.max<0))throw new TypeError("max must be a non-negative number");this[o]=I.max||1/0;const D=I.length||m;if(this[p]=typeof D!="function"?m:D,this[s]=I.stale||!1,I.maxAge&&typeof I.maxAge!="number")throw new TypeError("maxAge must be a number");this[i]=I.maxAge||0,this[d]=I.dispose,this[c]=I.noDisposeOnSet||!1,this[v]=I.updateAgeOnGet||!1,this.reset()}set max(I){if(typeof I!="number"||I<0)throw new TypeError("max must be a non-negative number");this[o]=I||1/0,y(this)}get max(){return this[o]}set allowStale(I){this[s]=!!I}get allowStale(){return this[s]}set maxAge(I){if(typeof I!="number")throw new TypeError("maxAge must be a non-negative number");this[i]=I,y(this)}get maxAge(){return this[i]}set lengthCalculator(I){typeof I!="function"&&(I=m),I!==this[p]&&(this[p]=I,this[u]=0,this[f].forEach(D=>{D.length=this[p](D.value,D.key),this[u]+=D.length})),y(this)}get lengthCalculator(){return this[p]}get length(){return this[u]}get itemCount(){return this[f].length}rforEach(I,D){D=D||this;for(let X=this[f].tail;X!==null;){const V=X.prev;T(this,I,X,D),X=V}}forEach(I,D){D=D||this;for(let X=this[f].head;X!==null;){const V=X.next;T(this,I,X,D),X=V}}keys(){return this[f].toArray().map(I=>I.key)}values(){return this[f].toArray().map(I=>I.value)}reset(){this[d]&&this[f]&&this[f].length&&this[f].forEach(I=>this[d](I.key,I.value)),this[h]=new Map,this[f]=new a,this[u]=0}dump(){return this[f].map(I=>!x(this,I)&&{k:I.key,v:I.value,e:I.now+(I.maxAge||0)}).toArray().filter(I=>I)}dumpLru(){return this[f]}set(I,D,X){if((X=X||this[i])&&typeof X!="number")throw new TypeError("maxAge must be a number");const V=X?Date.now():0,E=this[p](D,I);if(this[h].has(I)){if(E>this[o])return w(this,this[h].get(I)),!1;const C=this[h].get(I).value;return this[d]&&(this[c]||this[d](I,C.value)),C.now=V,C.maxAge=X,C.value=D,this[u]+=E-C.length,C.length=E,this.get(I),y(this),!0}const A=new k(I,D,E,V,X);return A.length>this[o]?(this[d]&&this[d](I,D),!1):(this[u]+=A.length,this[f].unshift(A),this[h].set(I,this[f].head),y(this),!0)}has(I){if(!this[h].has(I))return!1;const D=this[h].get(I).value;return!x(this,D)}get(I){return g(this,I,!0)}peek(I){return g(this,I,!1)}pop(){const I=this[f].tail;return I?(w(this,I),I.value):null}del(I){w(this,this[h].get(I))}load(I){this.reset();const D=Date.now();for(let X=I.length-1;X>=0;X--){const V=I[X],E=V.e||0;if(E===0)this.set(V.k,V.v);else{const A=E-D;A>0&&this.set(V.k,V.v,A)}}}prune(){this[h].forEach((I,D)=>g(this,D,!1))}}},{yallist:83}],38:[function(t,n,l){(function(a){(function(){const o=n.exports;o.types={0:"reserved",1:"connect",2:"connack",3:"publish",4:"puback",5:"pubrec",6:"pubrel",7:"pubcomp",8:"subscribe",9:"suback",10:"unsubscribe",11:"unsuback",12:"pingreq",13:"pingresp",14:"disconnect",15:"auth"},o.codes={};for(const p in o.types){const s=o.types[p];o.codes[s]=p}o.CMD_SHIFT=4,o.CMD_MASK=240,o.DUP_MASK=8,o.QOS_MASK=3,o.QOS_SHIFT=1,o.RETAIN_MASK=1,o.VARBYTEINT_MASK=127,o.VARBYTEINT_FIN_MASK=128,o.VARBYTEINT_MAX=268435455,o.SESSIONPRESENT_MASK=1,o.SESSIONPRESENT_HEADER=a.from([o.SESSIONPRESENT_MASK]),o.CONNACK_HEADER=a.from([o.codes.connack<<o.CMD_SHIFT]),o.USERNAME_MASK=128,o.PASSWORD_MASK=64,o.WILL_RETAIN_MASK=32,o.WILL_QOS_MASK=24,o.WILL_QOS_SHIFT=3,o.WILL_FLAG_MASK=4,o.CLEAN_SESSION_MASK=2,o.CONNECT_HEADER=a.from([o.codes.connect<<o.CMD_SHIFT]),o.properties={sessionExpiryInterval:17,willDelayInterval:24,receiveMaximum:33,maximumPacketSize:39,topicAliasMaximum:34,requestResponseInformation:25,requestProblemInformation:23,userProperties:38,authenticationMethod:21,authenticationData:22,payloadFormatIndicator:1,messageExpiryInterval:2,contentType:3,responseTopic:8,correlationData:9,maximumQoS:36,retainAvailable:37,assignedClientIdentifier:18,reasonString:31,wildcardSubscriptionAvailable:40,subscriptionIdentifiersAvailable:41,sharedSubscriptionAvailable:42,serverKeepAlive:19,responseInformation:26,serverReference:28,topicAlias:35,subscriptionIdentifier:11},o.propertiesCodes={};for(const p in o.properties){const s=o.properties[p];o.propertiesCodes[s]=p}function u(p){return[0,1,2].map(s=>[0,1].map(i=>[0,1].map(d=>{const c=a.alloc(1);return c.writeUInt8(o.codes[p]<<o.CMD_SHIFT|(i?o.DUP_MASK:0)|s<<o.QOS_SHIFT|d,0,!0),c})))}o.propertiesTypes={sessionExpiryInterval:"int32",willDelayInterval:"int32",receiveMaximum:"int16",maximumPacketSize:"int32",topicAliasMaximum:"int16",requestResponseInformation:"byte",requestProblemInformation:"byte",userProperties:"pair",authenticationMethod:"string",authenticationData:"binary",payloadFormatIndicator:"byte",messageExpiryInterval:"int32",contentType:"string",responseTopic:"string",correlationData:"binary",maximumQoS:"int8",retainAvailable:"byte",assignedClientIdentifier:"string",reasonString:"string",wildcardSubscriptionAvailable:"byte",subscriptionIdentifiersAvailable:"byte",sharedSubscriptionAvailable:"byte",serverKeepAlive:"int16",responseInformation:"string",serverReference:"string",topicAlias:"int16",subscriptionIdentifier:"var"},o.PUBLISH_HEADER=u("publish"),o.SUBSCRIBE_HEADER=u("subscribe"),o.SUBSCRIBE_OPTIONS_QOS_MASK=3,o.SUBSCRIBE_OPTIONS_NL_MASK=1,o.SUBSCRIBE_OPTIONS_NL_SHIFT=2,o.SUBSCRIBE_OPTIONS_RAP_MASK=1,o.SUBSCRIBE_OPTIONS_RAP_SHIFT=3,o.SUBSCRIBE_OPTIONS_RH_MASK=3,o.SUBSCRIBE_OPTIONS_RH_SHIFT=4,o.SUBSCRIBE_OPTIONS_RH=[0,16,32],o.SUBSCRIBE_OPTIONS_NL=4,o.SUBSCRIBE_OPTIONS_RAP=8,o.SUBSCRIBE_OPTIONS_QOS=[0,1,2],o.UNSUBSCRIBE_HEADER=u("unsubscribe"),o.ACKS={unsuback:u("unsuback"),puback:u("puback"),pubcomp:u("pubcomp"),pubrel:u("pubrel"),pubrec:u("pubrec")},o.SUBACK_HEADER=a.from([o.codes.suback<<o.CMD_SHIFT]),o.VERSION3=a.from([3]),o.VERSION4=a.from([4]),o.VERSION5=a.from([5]),o.VERSION131=a.from([131]),o.VERSION132=a.from([132]),o.QOS=[0,1,2].map(p=>a.from([p])),o.EMPTY={pingreq:a.from([o.codes.pingreq<<4,0]),pingresp:a.from([o.codes.pingresp<<4,0]),disconnect:a.from([o.codes.disconnect<<4,0])}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:17}],39:[function(t,n,l){(function(a){(function(){const o=t("./writeToStream"),u=t("events");class p extends u{constructor(){super(),this._array=new Array(20),this._i=0}write(i){return this._array[this._i++]=i,!0}concat(){let i=0;const d=new Array(this._array.length),c=this._array;let f,h=0;for(f=0;f<c.length&&c[f]!==void 0;f++)typeof c[f]!="string"?d[f]=c[f].length:d[f]=a.byteLength(c[f]),i+=d[f];const v=a.allocUnsafe(i);for(f=0;f<c.length&&c[f]!==void 0;f++)typeof c[f]!="string"?(c[f].copy(v,h),h+=d[f]):(v.write(c[f],h),h+=d[f]);return v}}n.exports=function(s,i){const d=new p;return o(s,d,i),d.concat()}}).call(this)}).call(this,t("buffer").Buffer)},{"./writeToStream":44,buffer:17,events:22}],40:[function(t,n,l){l.parser=t("./parser").parser,l.generate=t("./generate"),l.writeToStream=t("./writeToStream")},{"./generate":39,"./parser":43,"./writeToStream":44}],41:[function(t,n,l){(function(a){(function(){const u={},p=a.isBuffer(a.from([1,2]).subarray(0,1));function s(i){const d=a.allocUnsafe(2);return d.writeUInt8(i>>8,0),d.writeUInt8(255&i,1),d}n.exports={cache:u,generateCache:function(){for(let i=0;i<65536;i++)u[i]=s(i)},generateNumber:s,genBufVariableByteInt:function(i){let d=0,c=0;const f=a.allocUnsafe(4);do d=i%128|0,(i=i/128|0)>0&&(d|=128),f.writeUInt8(d,c++);while(i>0&&c<4);return i>0&&(c=0),p?f.subarray(0,c):f.slice(0,c)},generate4ByteBuffer:function(i){const d=a.allocUnsafe(4);return d.writeUInt32BE(i,0),d}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:17}],42:[function(t,n,l){n.exports=class{constructor(){this.cmd=null,this.retain=!1,this.qos=0,this.dup=!1,this.length=-1,this.topic=null,this.payload=null}}},{}],43:[function(t,n,l){const a=t("bl"),o=t("events"),u=t("./packet"),p=t("./constants"),s=t("debug")("mqtt-packet:parser");class i extends o{constructor(){super(),this.parser=this.constructor.parser}static parser(c){return this instanceof i?(this.settings=c||{},this._states=["_parseHeader","_parseLength","_parsePayload","_newPacket"],this._resetState(),this):new i().parser(c)}_resetState(){s("_resetState: resetting packet, error, _list, and _stateCounter"),this.packet=new u,this.error=null,this._list=a(),this._stateCounter=0}parse(c){for(this.error&&this._resetState(),this._list.append(c),s("parse: current state: %s",this._states[this._stateCounter]);(this.packet.length!==-1||this._list.length>0)&&this[this._states[this._stateCounter]]()&&!this.error;)this._stateCounter++,s("parse: state complete. _stateCounter is now: %d",this._stateCounter),s("parse: packet.length: %d, buffer list length: %d",this.packet.length,this._list.length),this._stateCounter>=this._states.length&&(this._stateCounter=0);return s("parse: exited while loop. packet: %d, buffer list length: %d",this.packet.length,this._list.length),this._list.length}_parseHeader(){const c=this._list.readUInt8(0);return this.packet.cmd=p.types[c>>p.CMD_SHIFT],this.packet.retain=(c&p.RETAIN_MASK)!=0,this.packet.qos=c>>p.QOS_SHIFT&p.QOS_MASK,this.packet.dup=(c&p.DUP_MASK)!=0,s("_parseHeader: packet: %o",this.packet),this._list.consume(1),!0}_parseLength(){const c=this._parseVarByteNum(!0);return c&&(this.packet.length=c.value,this._list.consume(c.bytes)),s("_parseLength %d",c.value),!!c}_parsePayload(){s("_parsePayload: payload %O",this._list);let c=!1;if(this.packet.length===0||this._list.length>=this.packet.length){switch(this._pos=0,this.packet.cmd){case"connect":this._parseConnect();break;case"connack":this._parseConnack();break;case"publish":this._parsePublish();break;case"puback":case"pubrec":case"pubrel":case"pubcomp":this._parseConfirmation();break;case"subscribe":this._parseSubscribe();break;case"suback":this._parseSuback();break;case"unsubscribe":this._parseUnsubscribe();break;case"unsuback":this._parseUnsuback();break;case"pingreq":case"pingresp":break;case"disconnect":this._parseDisconnect();break;case"auth":this._parseAuth();break;default:this._emitError(new Error("Not supported"))}c=!0}return s("_parsePayload complete result: %s",c),c}_parseConnect(){let c,f,h,v;s("_parseConnect");const m={},g=this.packet,x=this._parseString();if(x===null)return this._emitError(new Error("Cannot parse protocolId"));if(x!=="MQTT"&&x!=="MQIsdp")return this._emitError(new Error("Invalid protocolId"));if(g.protocolId=x,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(g.protocolVersion=this._list.readUInt8(this._pos),g.protocolVersion>=128&&(g.bridgeMode=!0,g.protocolVersion=g.protocolVersion-128),g.protocolVersion!==3&&g.protocolVersion!==4&&g.protocolVersion!==5)return this._emitError(new Error("Invalid protocol version"));if(this._pos++,this._pos>=this._list.length)return this._emitError(new Error("Packet too short"));if(m.username=this._list.readUInt8(this._pos)&p.USERNAME_MASK,m.password=this._list.readUInt8(this._pos)&p.PASSWORD_MASK,m.will=this._list.readUInt8(this._pos)&p.WILL_FLAG_MASK,m.will&&(g.will={},g.will.retain=(this._list.readUInt8(this._pos)&p.WILL_RETAIN_MASK)!=0,g.will.qos=(this._list.readUInt8(this._pos)&p.WILL_QOS_MASK)>>p.WILL_QOS_SHIFT),g.clean=(this._list.readUInt8(this._pos)&p.CLEAN_SESSION_MASK)!=0,this._pos++,g.keepalive=this._parseNum(),g.keepalive===-1)return this._emitError(new Error("Packet too short"));if(g.protocolVersion===5){const w=this._parseProperties();Object.getOwnPropertyNames(w).length&&(g.properties=w)}const y=this._parseString();if(y===null)return this._emitError(new Error("Packet too short"));if(g.clientId=y,s("_parseConnect: packet.clientId: %s",g.clientId),m.will){if(g.protocolVersion===5){const w=this._parseProperties();Object.getOwnPropertyNames(w).length&&(g.will.properties=w)}if((c=this._parseString())===null)return this._emitError(new Error("Cannot parse will topic"));if(g.will.topic=c,s("_parseConnect: packet.will.topic: %s",g.will.topic),(f=this._parseBuffer())===null)return this._emitError(new Error("Cannot parse will payload"));g.will.payload=f,s("_parseConnect: packet.will.paylaod: %s",g.will.payload)}if(m.username){if((v=this._parseString())===null)return this._emitError(new Error("Cannot parse username"));g.username=v,s("_parseConnect: packet.username: %s",g.username)}if(m.password){if((h=this._parseBuffer())===null)return this._emitError(new Error("Cannot parse password"));g.password=h}return this.settings=g,s("_parseConnect: complete"),g}_parseConnack(){s("_parseConnack");const c=this.packet;if(this._list.length<1)return null;if(c.sessionPresent=!!(this._list.readUInt8(this._pos++)&p.SESSIONPRESENT_MASK),this.settings.protocolVersion===5)this._list.length>=2?c.reasonCode=this._list.readUInt8(this._pos++):c.reasonCode=0;else{if(this._list.length<2)return null;c.returnCode=this._list.readUInt8(this._pos++)}if(c.returnCode===-1||c.reasonCode===-1)return this._emitError(new Error("Cannot parse return code"));if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}s("_parseConnack: complete")}_parsePublish(){s("_parsePublish");const c=this.packet;if(c.topic=this._parseString(),c.topic===null)return this._emitError(new Error("Cannot parse topic"));if(!(c.qos>0)||this._parseMessageId()){if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}c.payload=this._list.slice(this._pos,c.length),s("_parsePublish: payload from buffer list: %o",c.payload)}}_parseSubscribe(){s("_parseSubscribe");const c=this.packet;let f,h,v,m,g,x,y;if(c.qos!==1)return this._emitError(new Error("Wrong subscribe header"));if(c.subscriptions=[],this._parseMessageId()){if(this.settings.protocolVersion===5){const w=this._parseProperties();Object.getOwnPropertyNames(w).length&&(c.properties=w)}for(;this._pos<c.length;){if((f=this._parseString())===null)return this._emitError(new Error("Cannot parse topic"));if(this._pos>=c.length)return this._emitError(new Error("Malformed Subscribe Payload"));v=(h=this._parseByte())&p.SUBSCRIBE_OPTIONS_QOS_MASK,x=(h>>p.SUBSCRIBE_OPTIONS_NL_SHIFT&p.SUBSCRIBE_OPTIONS_NL_MASK)!=0,g=(h>>p.SUBSCRIBE_OPTIONS_RAP_SHIFT&p.SUBSCRIBE_OPTIONS_RAP_MASK)!=0,m=h>>p.SUBSCRIBE_OPTIONS_RH_SHIFT&p.SUBSCRIBE_OPTIONS_RH_MASK,y={topic:f,qos:v},this.settings.protocolVersion===5?(y.nl=x,y.rap=g,y.rh=m):this.settings.bridgeMode&&(y.rh=0,y.rap=!0,y.nl=!0),s("_parseSubscribe: push subscription `%s` to subscription",y),c.subscriptions.push(y)}}}_parseSuback(){s("_parseSuback");const c=this.packet;if(this.packet.granted=[],this._parseMessageId()){if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}for(;this._pos<this.packet.length;)this.packet.granted.push(this._list.readUInt8(this._pos++))}}_parseUnsubscribe(){s("_parseUnsubscribe");const c=this.packet;if(c.unsubscriptions=[],this._parseMessageId()){if(this.settings.protocolVersion===5){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}for(;this._pos<c.length;){const f=this._parseString();if(f===null)return this._emitError(new Error("Cannot parse topic"));s("_parseUnsubscribe: push topic `%s` to unsubscriptions",f),c.unsubscriptions.push(f)}}}_parseUnsuback(){s("_parseUnsuback");const c=this.packet;if(!this._parseMessageId())return this._emitError(new Error("Cannot parse messageId"));if(this.settings.protocolVersion===5){const f=this._parseProperties();for(Object.getOwnPropertyNames(f).length&&(c.properties=f),c.granted=[];this._pos<this.packet.length;)this.packet.granted.push(this._list.readUInt8(this._pos++))}}_parseConfirmation(){s("_parseConfirmation: packet.cmd: `%s`",this.packet.cmd);const c=this.packet;if(this._parseMessageId(),this.settings.protocolVersion===5&&(c.length>2?(c.reasonCode=this._parseByte(),s("_parseConfirmation: packet.reasonCode `%d`",c.reasonCode)):c.reasonCode=0,c.length>3)){const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}return!0}_parseDisconnect(){const c=this.packet;if(s("_parseDisconnect"),this.settings.protocolVersion===5){this._list.length>0?c.reasonCode=this._parseByte():c.reasonCode=0;const f=this._parseProperties();Object.getOwnPropertyNames(f).length&&(c.properties=f)}return s("_parseDisconnect result: true"),!0}_parseAuth(){s("_parseAuth");const c=this.packet;if(this.settings.protocolVersion!==5)return this._emitError(new Error("Not supported auth packet for this version MQTT"));c.reasonCode=this._parseByte();const f=this._parseProperties();return Object.getOwnPropertyNames(f).length&&(c.properties=f),s("_parseAuth: result: true"),!0}_parseMessageId(){const c=this.packet;return c.messageId=this._parseNum(),c.messageId===null?(this._emitError(new Error("Cannot parse messageId")),!1):(s("_parseMessageId: packet.messageId %d",c.messageId),!0)}_parseString(c){const f=this._parseNum(),h=f+this._pos;if(f===-1||h>this._list.length||h>this.packet.length)return null;const v=this._list.toString("utf8",this._pos,h);return this._pos+=f,s("_parseString: result: %s",v),v}_parseStringPair(){return s("_parseStringPair"),{name:this._parseString(),value:this._parseString()}}_parseBuffer(){const c=this._parseNum(),f=c+this._pos;if(c===-1||f>this._list.length||f>this.packet.length)return null;const h=this._list.slice(this._pos,f);return this._pos+=c,s("_parseBuffer: result: %o",h),h}_parseNum(){if(this._list.length-this._pos<2)return-1;const c=this._list.readUInt16BE(this._pos);return this._pos+=2,s("_parseNum: result: %s",c),c}_parse4ByteNum(){if(this._list.length-this._pos<4)return-1;const c=this._list.readUInt32BE(this._pos);return this._pos+=4,s("_parse4ByteNum: result: %s",c),c}_parseVarByteNum(c){s("_parseVarByteNum");let f,h=0,v=1,m=0,g=!1;const x=this._pos?this._pos:0;for(;h<4&&x+h<this._list.length;){if(m+=v*((f=this._list.readUInt8(x+h++))&p.VARBYTEINT_MASK),v*=128,(f&p.VARBYTEINT_FIN_MASK)==0){g=!0;break}if(this._list.length<=h)break}return!g&&h===4&&this._list.length>=h&&this._emitError(new Error("Invalid variable byte integer")),x&&(this._pos+=h),s("_parseVarByteNum: result: %o",g=!!g&&(c?{bytes:h,value:m}:m)),g}_parseByte(){let c;return this._pos<this._list.length&&(c=this._list.readUInt8(this._pos),this._pos++),s("_parseByte: result: %o",c),c}_parseByType(c){switch(s("_parseByType: type: %s",c),c){case"byte":return this._parseByte()!==0;case"int8":return this._parseByte();case"int16":return this._parseNum();case"int32":return this._parse4ByteNum();case"var":return this._parseVarByteNum();case"string":return this._parseString();case"pair":return this._parseStringPair();case"binary":return this._parseBuffer()}}_parseProperties(){s("_parseProperties");const c=this._parseVarByteNum(),f=this._pos+c,h={};for(;this._pos<f;){const v=this._parseByte();if(!v)return this._emitError(new Error("Cannot parse property code type")),!1;const m=p.propertiesCodes[v];if(!m)return this._emitError(new Error("Unknown property")),!1;if(m!=="userProperties")h[m]?Array.isArray(h[m])?h[m].push(this._parseByType(p.propertiesTypes[m])):(h[m]=[h[m]],h[m].push(this._parseByType(p.propertiesTypes[m]))):h[m]=this._parseByType(p.propertiesTypes[m]);else{h[m]||(h[m]=Object.create(null));const g=this._parseByType(p.propertiesTypes[m]);if(h[m][g.name])if(Array.isArray(h[m][g.name]))h[m][g.name].push(g.value);else{const x=h[m][g.name];h[m][g.name]=[x],h[m][g.name].push(g.value)}else h[m][g.name]=g.value}}return h}_newPacket(){return s("_newPacket"),this.packet&&(this._list.consume(this.packet.length),s("_newPacket: parser emit packet: packet.cmd: %s, packet.payload: %s, packet.length: %d",this.packet.cmd,this.packet.payload,this.packet.length),this.emit("packet",this.packet)),s("_newPacket: new packet"),this.packet=new u,this._pos=0,!0}_emitError(c){s("_emitError"),this.error=c,this.emit("error",c)}}n.exports=i},{"./constants":38,"./packet":42,bl:15,debug:18,events:22}],44:[function(t,n,l){(function(a){(function(){const o=t("./constants"),u=a.allocUnsafe(0),p=a.from([0]),s=t("./numbers"),i=t("process-nextick-args").nextTick,d=t("debug")("mqtt-packet:writeToStream"),c=s.cache,f=s.generateNumber,h=s.generateCache,v=s.genBufVariableByteInt,m=s.generate4ByteBuffer;let g=X,x=!0;function y($,U,K){switch(d("generate called"),U.cork&&(U.cork(),i(w,U)),x&&(x=!1,h()),d("generate: packet.cmd: %s",$.cmd),$.cmd){case"connect":return function(L,O,H){const W=L||{},Z=W.protocolId||"MQTT";let re=W.protocolVersion||4;const oe=W.will;let ae=W.clean;const b=W.keepalive||0,_=W.clientId||"",R=W.username,G=W.password,ee=W.properties;ae===void 0&&(ae=!0);let te=0;if(typeof Z!="string"&&!a.isBuffer(Z))return O.emit("error",new Error("Invalid protocolId")),!1;if(te+=Z.length+2,re!==3&&re!==4&&re!==5)return O.emit("error",new Error("Invalid protocol version")),!1;if(te+=1,(typeof _=="string"||a.isBuffer(_))&&(_||re>=4)&&(_||ae))te+=a.byteLength(_)+2;else{if(re<4)return O.emit("error",new Error("clientId must be supplied before 3.1.1")),!1;if(1*ae==0)return O.emit("error",new Error("clientId must be given if cleanSession set to 0")),!1}if(typeof b!="number"||b<0||b>65535||b%1!=0)return O.emit("error",new Error("Invalid keepalive")),!1;if(te+=2,te+=1,re===5){var se=A(O,ee);if(!se)return!1;te+=se.length}if(oe){if(typeof oe!="object")return O.emit("error",new Error("Invalid will")),!1;if(!oe.topic||typeof oe.topic!="string")return O.emit("error",new Error("Invalid will topic")),!1;if(te+=a.byteLength(oe.topic)+2,te+=2,oe.payload){if(!(oe.payload.length>=0))return O.emit("error",new Error("Invalid will payload")),!1;typeof oe.payload=="string"?te+=a.byteLength(oe.payload):te+=oe.payload.length}var z={};if(re===5){if(!(z=A(O,oe.properties)))return!1;te+=z.length}}let S=!1;if(R!=null){if(!J(R))return O.emit("error",new Error("Invalid username")),!1;S=!0,te+=a.byteLength(R)+2}if(G!=null){if(!S)return O.emit("error",new Error("Username is required to use password")),!1;if(!J(G))return O.emit("error",new Error("Invalid password")),!1;te+=P(G)+2}O.write(o.CONNECT_HEADER),T(O,te),E(O,Z),W.bridgeMode&&(re+=128),O.write(re===131?o.VERSION131:re===132?o.VERSION132:re===4?o.VERSION4:re===5?o.VERSION5:o.VERSION3);let B=0;return B|=R!=null?o.USERNAME_MASK:0,B|=G!=null?o.PASSWORD_MASK:0,B|=oe&&oe.retain?o.WILL_RETAIN_MASK:0,B|=oe&&oe.qos?oe.qos<<o.WILL_QOS_SHIFT:0,B|=oe?o.WILL_FLAG_MASK:0,B|=ae?o.CLEAN_SESSION_MASK:0,O.write(a.from([B])),g(O,b),re===5&&se.write(),E(O,_),oe&&(re===5&&z.write(),I(O,oe.topic),E(O,oe.payload)),R!=null&&E(O,R),G!=null&&E(O,G),!0}($,U);case"connack":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=W===5?Z.reasonCode:Z.returnCode,oe=Z.properties;let ae=2;if(typeof re!="number")return O.emit("error",new Error("Invalid return code")),!1;let b=null;if(W===5){if(!(b=A(O,oe)))return!1;ae+=b.length}return O.write(o.CONNACK_HEADER),T(O,ae),O.write(Z.sessionPresent?o.SESSIONPRESENT_HEADER:p),O.write(a.from([re])),b!=null&&b.write(),!0}($,U,K);case"publish":return function(L,O,H){d("publish: packet: %o",L);const W=H?H.protocolVersion:4,Z=L||{},re=Z.qos||0,oe=Z.retain?o.RETAIN_MASK:0,ae=Z.topic,b=Z.payload||u,_=Z.messageId,R=Z.properties;let G=0;if(typeof ae=="string")G+=a.byteLength(ae)+2;else{if(!a.isBuffer(ae))return O.emit("error",new Error("Invalid topic")),!1;G+=ae.length+2}if(a.isBuffer(b)?G+=b.length:G+=a.byteLength(b),re&&typeof _!="number")return O.emit("error",new Error("Invalid messageId")),!1;re&&(G+=2);let ee=null;if(W===5){if(!(ee=A(O,R)))return!1;G+=ee.length}return O.write(o.PUBLISH_HEADER[re][Z.dup?1:0][oe?1:0]),T(O,G),g(O,P(ae)),O.write(ae),re>0&&g(O,_),ee!=null&&ee.write(),d("publish: payload: %o",b),O.write(b)}($,U,K);case"puback":case"pubrec":case"pubrel":case"pubcomp":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.cmd||"puback",oe=Z.messageId,ae=Z.dup&&re==="pubrel"?o.DUP_MASK:0;let b=0;const _=Z.reasonCode,R=Z.properties;let G=W===5?3:2;if(re==="pubrel"&&(b=1),typeof oe!="number")return O.emit("error",new Error("Invalid messageId")),!1;let ee=null;if(W===5&&typeof R=="object"){if(!(ee=C(O,R,H,G)))return!1;G+=ee.length}return O.write(o.ACKS[re][b][ae][0]),T(O,G),g(O,oe),W===5&&O.write(a.from([_])),ee!==null&&ee.write(),!0}($,U,K);case"subscribe":return function(L,O,H){d("subscribe: packet: ");const W=H?H.protocolVersion:4,Z=L||{},re=Z.dup?o.DUP_MASK:0,oe=Z.messageId,ae=Z.subscriptions,b=Z.properties;let _=0;if(typeof oe!="number")return O.emit("error",new Error("Invalid messageId")),!1;_+=2;let R=null;if(W===5){if(!(R=A(O,b)))return!1;_+=R.length}if(typeof ae!="object"||!ae.length)return O.emit("error",new Error("Invalid subscriptions")),!1;for(let ee=0;ee<ae.length;ee+=1){const te=ae[ee].topic,se=ae[ee].qos;if(typeof te!="string")return O.emit("error",new Error("Invalid subscriptions - invalid topic")),!1;if(typeof se!="number")return O.emit("error",new Error("Invalid subscriptions - invalid qos")),!1;if(W===5){if(typeof(ae[ee].nl||!1)!="boolean")return O.emit("error",new Error("Invalid subscriptions - invalid No Local")),!1;if(typeof(ae[ee].rap||!1)!="boolean")return O.emit("error",new Error("Invalid subscriptions - invalid Retain as Published")),!1;const B=ae[ee].rh||0;if(typeof B!="number"||B>2)return O.emit("error",new Error("Invalid subscriptions - invalid Retain Handling")),!1}_+=a.byteLength(te)+2+1}d("subscribe: writing to stream: %o",o.SUBSCRIBE_HEADER),O.write(o.SUBSCRIBE_HEADER[1][re?1:0][0]),T(O,_),g(O,oe),R!==null&&R.write();let G=!0;for(const ee of ae){const te=ee.topic,se=ee.qos,z=+ee.nl,S=+ee.rap,B=ee.rh;let Y;I(O,te),Y=o.SUBSCRIBE_OPTIONS_QOS[se],W===5&&(Y|=z?o.SUBSCRIBE_OPTIONS_NL:0,Y|=S?o.SUBSCRIBE_OPTIONS_RAP:0,Y|=B?o.SUBSCRIBE_OPTIONS_RH[B]:0),G=O.write(a.from([Y]))}return G}($,U,K);case"suback":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.messageId,oe=Z.granted,ae=Z.properties;let b=0;if(typeof re!="number")return O.emit("error",new Error("Invalid messageId")),!1;if(b+=2,typeof oe!="object"||!oe.length)return O.emit("error",new Error("Invalid qos vector")),!1;for(let R=0;R<oe.length;R+=1){if(typeof oe[R]!="number")return O.emit("error",new Error("Invalid qos vector")),!1;b+=1}let _=null;if(W===5){if(!(_=C(O,ae,H,b)))return!1;b+=_.length}return O.write(o.SUBACK_HEADER),T(O,b),g(O,re),_!==null&&_.write(),O.write(a.from(oe))}($,U,K);case"unsubscribe":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.messageId,oe=Z.dup?o.DUP_MASK:0,ae=Z.unsubscriptions,b=Z.properties;let _=0;if(typeof re!="number")return O.emit("error",new Error("Invalid messageId")),!1;if(_+=2,typeof ae!="object"||!ae.length)return O.emit("error",new Error("Invalid unsubscriptions")),!1;for(let ee=0;ee<ae.length;ee+=1){if(typeof ae[ee]!="string")return O.emit("error",new Error("Invalid unsubscriptions")),!1;_+=a.byteLength(ae[ee])+2}let R=null;if(W===5){if(!(R=A(O,b)))return!1;_+=R.length}O.write(o.UNSUBSCRIBE_HEADER[1][oe?1:0][0]),T(O,_),g(O,re),R!==null&&R.write();let G=!0;for(let ee=0;ee<ae.length;ee++)G=I(O,ae[ee]);return G}($,U,K);case"unsuback":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.messageId,oe=Z.dup?o.DUP_MASK:0,ae=Z.granted,b=Z.properties,_=Z.cmd;let R=2;if(typeof re!="number")return O.emit("error",new Error("Invalid messageId")),!1;if(W===5){if(typeof ae!="object"||!ae.length)return O.emit("error",new Error("Invalid qos vector")),!1;for(let ee=0;ee<ae.length;ee+=1){if(typeof ae[ee]!="number")return O.emit("error",new Error("Invalid qos vector")),!1;R+=1}}let G=null;if(W===5){if(!(G=C(O,b,H,R)))return!1;R+=G.length}return O.write(o.ACKS[_][0][oe][0]),T(O,R),g(O,re),G!==null&&G.write(),W===5&&O.write(a.from(ae)),!0}($,U,K);case"pingreq":case"pingresp":return function(L,O,H){return O.write(o.EMPTY[L.cmd])}($,U);case"disconnect":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.reasonCode,oe=Z.properties;let ae=W===5?1:0,b=null;if(W===5){if(!(b=C(O,oe,H,ae)))return!1;ae+=b.length}return O.write(a.from([o.codes.disconnect<<4])),T(O,ae),W===5&&O.write(a.from([re])),b!==null&&b.write(),!0}($,U,K);case"auth":return function(L,O,H){const W=H?H.protocolVersion:4,Z=L||{},re=Z.reasonCode,oe=Z.properties;let ae=W===5?1:0;W!==5&&O.emit("error",new Error("Invalid mqtt version for auth packet"));const b=C(O,oe,H,ae);return b?(ae+=b.length,O.write(a.from([o.codes.auth<<4])),T(O,ae),O.write(a.from([re])),b!==null&&b.write(),!0):!1}($,U,K);default:return U.emit("error",new Error("Unknown command")),!1}}function w($){$.uncork()}Object.defineProperty(y,"cacheNumbers",{get:()=>g===X,set($){$?(c&&Object.keys(c).length!==0||(x=!0),g=X):(x=!1,g=V)}});const k={};function T($,U){if(U>o.VARBYTEINT_MAX)return $.emit("error",new Error(`Invalid variable byte integer: ${U}`)),!1;let K=k[U];return K||(K=v(U),U<16384&&(k[U]=K)),d("writeVarByteInt: writing to stream: %o",K),$.write(K)}function I($,U){const K=a.byteLength(U);return g($,K),d("writeString: %s",U),$.write(U,"utf8")}function D($,U,K){I($,U),I($,K)}function X($,U){return d("writeNumberCached: number: %d",U),d("writeNumberCached: %o",c[U]),$.write(c[U])}function V($,U){const K=f(U);return d("writeNumberGenerated: %o",K),$.write(K)}function E($,U){typeof U=="string"?I($,U):U?(g($,U.length),$.write(U)):g($,0)}function A($,U){if(typeof U!="object"||U.length!=null)return{length:1,write(){j($,{},0)}};let K=0;function L(O,H){let W=0;switch(o.propertiesTypes[O]){case"byte":if(typeof H!="boolean")return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=2;break;case"int8":if(typeof H!="number"||H<0||H>255)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=2;break;case"binary":if(H&&H===null)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=1+a.byteLength(H)+2;break;case"int16":if(typeof H!="number"||H<0||H>65535)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=3;break;case"int32":if(typeof H!="number"||H<0||H>4294967295)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=5;break;case"var":if(typeof H!="number"||H<0||H>268435455)return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=1+a.byteLength(v(H));break;case"string":if(typeof H!="string")return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=3+a.byteLength(H.toString());break;case"pair":if(typeof H!="object")return $.emit("error",new Error(`Invalid ${O}: ${H}`)),!1;W+=Object.getOwnPropertyNames(H).reduce((Z,re)=>{const oe=H[re];return Array.isArray(oe)?Z+=oe.reduce((ae,b)=>ae+=3+a.byteLength(re.toString())+2+a.byteLength(b.toString()),0):Z+=3+a.byteLength(re.toString())+2+a.byteLength(H[re].toString()),Z},0);break;default:return $.emit("error",new Error(`Invalid property ${O}: ${H}`)),!1}return W}if(U)for(const O in U){let H=0,W=0;const Z=U[O];if(Array.isArray(Z))for(let re=0;re<Z.length;re++){if(!(W=L(O,Z[re])))return!1;H+=W}else{if(!(W=L(O,Z)))return!1;H=W}if(!H)return!1;K+=H}return{length:a.byteLength(v(K))+K,write(){j($,U,K)}}}function C($,U,K,L){const O=["reasonString","userProperties"],H=K&&K.properties&&K.properties.maximumPacketSize?K.properties.maximumPacketSize:0;let W=A($,U);if(H)for(;L+W.length>H;){const Z=O.shift();if(!Z||!U[Z])return!1;delete U[Z],W=A($,U)}return W}function F($,U,K){switch(o.propertiesTypes[U]){case"byte":$.write(a.from([o.properties[U]])),$.write(a.from([+K]));break;case"int8":$.write(a.from([o.properties[U]])),$.write(a.from([K]));break;case"binary":$.write(a.from([o.properties[U]])),E($,K);break;case"int16":$.write(a.from([o.properties[U]])),g($,K);break;case"int32":$.write(a.from([o.properties[U]])),function(L,O){const H=m(O);d("write4ByteNumber: %o",H),L.write(H)}($,K);break;case"var":$.write(a.from([o.properties[U]])),T($,K);break;case"string":$.write(a.from([o.properties[U]])),I($,K);break;case"pair":Object.getOwnPropertyNames(K).forEach(L=>{const O=K[L];Array.isArray(O)?O.forEach(H=>{$.write(a.from([o.properties[U]])),D($,L.toString(),H.toString())}):($.write(a.from([o.properties[U]])),D($,L.toString(),O.toString()))});break;default:return $.emit("error",new Error(`Invalid property ${U} value: ${K}`)),!1}}function j($,U,K){T($,K);for(const L in U)if(Object.prototype.hasOwnProperty.call(U,L)&&U[L]!==null){const O=U[L];if(Array.isArray(O))for(let H=0;H<O.length;H++)F($,L,O[H]);else F($,L,O)}}function P($){return $?$ instanceof a?$.length:a.byteLength($):0}function J($){return typeof $=="string"||$ instanceof a}n.exports=y}).call(this)}).call(this,t("buffer").Buffer)},{"./constants":38,"./numbers":41,buffer:17,debug:18,"process-nextick-args":49}],45:[function(t,n,l){var a=1e3,o=60*a,u=60*o,p=24*u,s=7*p,i=365.25*p;function d(c,f,h,v){var m=f>=1.5*h;return Math.round(c/h)+" "+v+(m?"s":"")}n.exports=function(c,f){f=f||{};var h=typeof c;if(h==="string"&&c.length>0)return function(v){if(!((v=String(v)).length>100)){var m=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(v);if(m){var g=parseFloat(m[1]);switch((m[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return g*i;case"weeks":case"week":case"w":return g*s;case"days":case"day":case"d":return g*p;case"hours":case"hour":case"hrs":case"hr":case"h":return g*u;case"minutes":case"minute":case"mins":case"min":case"m":return g*o;case"seconds":case"second":case"secs":case"sec":case"s":return g*a;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return g;default:return}}}}(c);if(h==="number"&&isFinite(c))return f.long?function(v){var m=Math.abs(v);return m>=p?d(v,m,p,"day"):m>=u?d(v,m,u,"hour"):m>=o?d(v,m,o,"minute"):m>=a?d(v,m,a,"second"):v+" ms"}(c):function(v){var m=Math.abs(v);return m>=p?Math.round(v/p)+"d":m>=u?Math.round(v/u)+"h":m>=o?Math.round(v/o)+"m":m>=a?Math.round(v/a)+"s":v+"ms"}(c);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(c))}},{}],46:[function(t,n,l){const a=t("./lib/number-allocator.js");n.exports.NumberAllocator=a},{"./lib/number-allocator.js":47}],47:[function(t,n,l){const a=t("js-sdsl").Set,o=t("debug")("number-allocator:trace"),u=t("debug")("number-allocator:error");function p(i,d){this.low=i,this.high=d}function s(i,d){if(!(this instanceof s))return new s(i,d);this.min=i,this.max=d,this.ss=new a([],(c,f)=>c.compare(f)),o("Create"),this.clear()}p.prototype.equals=function(i){return this.low===i.low&&this.high===i.high},p.prototype.compare=function(i){return this.low<i.low&&this.high<i.low?-1:i.low<this.low&&i.high<this.low?1:0},s.prototype.firstVacant=function(){return this.ss.size()===0?null:this.ss.front().low},s.prototype.alloc=function(){if(this.ss.size()===0)return o("alloc():empty"),null;const i=this.ss.front(),d=i.low;return d+1<=i.high?++i.low:this.ss.eraseElementByPos(0),o("alloc():"+d),d},s.prototype.use=function(i){const d=new p(i,i),c=this.ss.lowerBound(d);if(c){if(c.equals(d))return this.ss.eraseElementByValue(c),o("use():"+i),!0;if(c.low>i)return!1;if(c.low===i)return++c.low,o("use():"+i),!0;if(c.high===i)return--c.high,o("use():"+i),!0;const f=c.low;return c.low=i+1,this.ss.insert(new p(f,i-1)),o("use():"+i),!0}return o("use():failed"),!1},s.prototype.free=function(i){if(i<this.min||i>this.max)return void u("free():"+i+" is out of range");const d=new p(i,i),c=this.ss.lowerBound(d);if(c){if(c.low<=i&&i<=c.high)return void u("free():"+i+" has already been vacant");if(c===this.ss.front())i+1===c.low?--c.low:this.ss.insert(d);else{const f=this.ss.reverseLowerBound(d);f.high+1===i?i+1===c.low?(this.ss.eraseElementByValue(f),c.low=f.low):f.high=i:i+1===c.low?c.low=i:this.ss.insert(d)}}else{if(c===this.ss.front())return void this.ss.insert(d);const f=this.ss.reverseLowerBound(d);f.high+1===i?f.high=i:this.ss.insert(d)}o("free():"+i)},s.prototype.clear=function(){o("clear()"),this.ss.clear(),this.ss.insert(new p(this.min,this.max))},s.prototype.intervalCount=function(){return this.ss.size()},s.prototype.dump=function(){console.log("length:"+this.ss.size());for(const i of this.ss)console.log(i)},n.exports=s},{debug:18,"js-sdsl":36}],48:[function(t,n,l){var a=t("wrappy");function o(p){var s=function(){return s.called?s.value:(s.called=!0,s.value=p.apply(this,arguments))};return s.called=!1,s}function u(p){var s=function(){if(s.called)throw new Error(s.onceError);return s.called=!0,s.value=p.apply(this,arguments)},i=p.name||"Function wrapped with `once`";return s.onceError=i+" shouldn't be called more than once",s.called=!1,s}n.exports=a(o),n.exports.strict=a(u),o.proto=o(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return o(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return u(this)},configurable:!0})})},{wrappy:79}],49:[function(t,n,l){(function(a){(function(){a===void 0||!a.version||a.version.indexOf("v0.")===0||a.version.indexOf("v1.")===0&&a.version.indexOf("v1.8.")!==0?n.exports={nextTick:function(o,u,p,s){if(typeof o!="function")throw new TypeError('"callback" argument must be a function');var i,d,c=arguments.length;switch(c){case 0:case 1:return a.nextTick(o);case 2:return a.nextTick(function(){o.call(null,u)});case 3:return a.nextTick(function(){o.call(null,u,p)});case 4:return a.nextTick(function(){o.call(null,u,p,s)});default:for(i=new Array(c-1),d=0;d<i.length;)i[d++]=arguments[d];return a.nextTick(function(){o.apply(null,i)})}}}:n.exports=a}).call(this)}).call(this,t("_process"))},{_process:50}],50:[function(t,n,l){var a,o,u=n.exports={};function p(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function i(y){if(a===setTimeout)return setTimeout(y,0);if((a===p||!a)&&setTimeout)return a=setTimeout,setTimeout(y,0);try{return a(y,0)}catch(w){try{return a.call(null,y,0)}catch(k){return a.call(this,y,0)}}}(function(){try{a=typeof setTimeout=="function"?setTimeout:p}catch(y){a=p}try{o=typeof clearTimeout=="function"?clearTimeout:s}catch(y){o=s}})();var d,c=[],f=!1,h=-1;function v(){f&&d&&(f=!1,d.length?c=d.concat(c):h=-1,c.length&&m())}function m(){if(!f){var y=i(v);f=!0;for(var w=c.length;w;){for(d=c,c=[];++h<w;)d&&d[h].run();h=-1,w=c.length}d=null,f=!1,function(k){if(o===clearTimeout)return clearTimeout(k);if((o===s||!o)&&clearTimeout)return o=clearTimeout,clearTimeout(k);try{o(k)}catch(T){try{return o.call(null,k)}catch(I){return o.call(this,k)}}}(y)}}function g(y,w){this.fun=y,this.array=w}function x(){}u.nextTick=function(y){var w=new Array(arguments.length-1);if(arguments.length>1)for(var k=1;k<arguments.length;k++)w[k-1]=arguments[k];c.push(new g(y,w)),c.length!==1||f||i(m)},g.prototype.run=function(){this.fun.apply(null,this.array)},u.title="browser",u.browser=!0,u.env={},u.argv=[],u.version="",u.versions={},u.on=x,u.addListener=x,u.once=x,u.off=x,u.removeListener=x,u.removeAllListeners=x,u.emit=x,u.prependListener=x,u.prependOnceListener=x,u.listeners=function(y){return[]},u.binding=function(y){throw new Error("process.binding is not supported")},u.cwd=function(){return"/"},u.chdir=function(y){throw new Error("process.chdir is not supported")},u.umask=function(){return 0}},{}],51:[function(t,n,l){(function(a){(function(){(function(o){var u=typeof l=="object"&&l&&!l.nodeType&&l,p=typeof n=="object"&&n&&!n.nodeType&&n,s=typeof a=="object"&&a;s.global!==s&&s.window!==s&&s.self!==s||(o=s);var i,d,c=2147483647,f=36,h=1,v=26,m=38,g=700,x=72,y=128,w="-",k=/^xn--/,T=/[^\x20-\x7E]/,I=/[\x2E\u3002\uFF0E\uFF61]/g,D={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},X=f-h,V=Math.floor,E=String.fromCharCode;function A(L){throw new RangeError(D[L])}function C(L,O){for(var H=L.length,W=[];H--;)W[H]=O(L[H]);return W}function F(L,O){var H=L.split("@"),W="";return H.length>1&&(W=H[0]+"@",L=H[1]),W+C((L=L.replace(I,".")).split("."),O).join(".")}function j(L){for(var O,H,W=[],Z=0,re=L.length;Z<re;)(O=L.charCodeAt(Z++))>=55296&&O<=56319&&Z<re?(64512&(H=L.charCodeAt(Z++)))==56320?W.push(((1023&O)<<10)+(1023&H)+65536):(W.push(O),Z--):W.push(O);return W}function P(L){return C(L,function(O){var H="";return O>65535&&(H+=E((O-=65536)>>>10&1023|55296),O=56320|1023&O),H+=E(O)}).join("")}function J(L,O){return L+22+75*(L<26)-((O!=0)<<5)}function $(L,O,H){var W=0;for(L=H?V(L/g):L>>1,L+=V(L/O);L>X*v>>1;W+=f)L=V(L/X);return V(W+(X+1)*L/(L+m))}function U(L){var O,H,W,Z,re,oe,ae,b,_,R,G,ee=[],te=L.length,se=0,z=y,S=x;for((H=L.lastIndexOf(w))<0&&(H=0),W=0;W<H;++W)L.charCodeAt(W)>=128&&A("not-basic"),ee.push(L.charCodeAt(W));for(Z=H>0?H+1:0;Z<te;){for(re=se,oe=1,ae=f;Z>=te&&A("invalid-input"),((b=(G=L.charCodeAt(Z++))-48<10?G-22:G-65<26?G-65:G-97<26?G-97:f)>=f||b>V((c-se)/oe))&&A("overflow"),se+=b*oe,!(b<(_=ae<=S?h:ae>=S+v?v:ae-S));ae+=f)oe>V(c/(R=f-_))&&A("overflow"),oe*=R;S=$(se-re,O=ee.length+1,re==0),V(se/O)>c-z&&A("overflow"),z+=V(se/O),se%=O,ee.splice(se++,0,z)}return P(ee)}function K(L){var O,H,W,Z,re,oe,ae,b,_,R,G,ee,te,se,z,S=[];for(ee=(L=j(L)).length,O=y,H=0,re=x,oe=0;oe<ee;++oe)(G=L[oe])<128&&S.push(E(G));for(W=Z=S.length,Z&&S.push(w);W<ee;){for(ae=c,oe=0;oe<ee;++oe)(G=L[oe])>=O&&G<ae&&(ae=G);for(ae-O>V((c-H)/(te=W+1))&&A("overflow"),H+=(ae-O)*te,O=ae,oe=0;oe<ee;++oe)if((G=L[oe])<O&&++H>c&&A("overflow"),G==O){for(b=H,_=f;!(b<(R=_<=re?h:_>=re+v?v:_-re));_+=f)z=b-R,se=f-R,S.push(E(J(R+z%se,0))),b=V(z/se);S.push(E(J(b,0))),re=$(H,te,W==Z),H=0,++W}++H,++O}return S.join("")}if(i={version:"1.4.1",ucs2:{decode:j,encode:P},decode:U,encode:K,toASCII:function(L){return F(L,function(O){return T.test(O)?"xn--"+K(O):O})},toUnicode:function(L){return F(L,function(O){return k.test(O)?U(O.slice(4).toLowerCase()):O})}},u&&p)if(n.exports==u)p.exports=i;else for(d in i)i.hasOwnProperty(d)&&(u[d]=i[d]);else o.punycode=i})(this)}).call(this)}).call(this,typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],52:[function(t,n,l){function a(u,p){return Object.prototype.hasOwnProperty.call(u,p)}n.exports=function(u,p,s,i){p=p||"&",s=s||"=";var d={};if(typeof u!="string"||u.length===0)return d;var c=/\+/g;u=u.split(p);var f=1e3;i&&typeof i.maxKeys=="number"&&(f=i.maxKeys);var h=u.length;f>0&&h>f&&(h=f);for(var v=0;v<h;++v){var m,g,x,y,w=u[v].replace(c,"%20"),k=w.indexOf(s);k>=0?(m=w.substr(0,k),g=w.substr(k+1)):(m=w,g=""),x=decodeURIComponent(m),y=decodeURIComponent(g),a(d,x)?o(d[x])?d[x].push(y):d[x]=[d[x],y]:d[x]=y}return d};var o=Array.isArray||function(u){return Object.prototype.toString.call(u)==="[object Array]"}},{}],53:[function(t,n,l){var a=function(s){switch(typeof s){case"string":return s;case"boolean":return s?"true":"false";case"number":return isFinite(s)?s:"";default:return""}};n.exports=function(s,i,d,c){return i=i||"&",d=d||"=",s===null&&(s=void 0),typeof s=="object"?u(p(s),function(f){var h=encodeURIComponent(a(f))+d;return o(s[f])?u(s[f],function(v){return h+encodeURIComponent(a(v))}).join(i):h+encodeURIComponent(a(s[f]))}).join(i):c?encodeURIComponent(a(c))+d+encodeURIComponent(a(s)):""};var o=Array.isArray||function(s){return Object.prototype.toString.call(s)==="[object Array]"};function u(s,i){if(s.map)return s.map(i);for(var d=[],c=0;c<s.length;c++)d.push(i(s[c],c));return d}var p=Object.keys||function(s){var i=[];for(var d in s)Object.prototype.hasOwnProperty.call(s,d)&&i.push(d);return i}},{}],54:[function(t,n,l){l.decode=l.parse=t("./decode"),l.encode=l.stringify=t("./encode")},{"./decode":52,"./encode":53}],55:[function(t,n,l){var a={};function o(p,s,i){i||(i=Error);var d=function(c){var f,h;function v(m,g,x){return c.call(this,function(y,w,k){return typeof s=="string"?s:s(y,w,k)}(m,g,x))||this}return h=c,(f=v).prototype=Object.create(h.prototype),f.prototype.constructor=f,f.__proto__=h,v}(i);d.prototype.name=i.name,d.prototype.code=p,a[p]=d}function u(p,s){if(Array.isArray(p)){var i=p.length;return p=p.map(function(d){return String(d)}),i>2?"one of ".concat(s," ").concat(p.slice(0,i-1).join(", "),", or ")+p[i-1]:i===2?"one of ".concat(s," ").concat(p[0]," or ").concat(p[1]):"of ".concat(s," ").concat(p[0])}return"of ".concat(s," ").concat(String(p))}o("ERR_INVALID_OPT_VALUE",function(p,s){return'The value "'+s+'" is invalid for option "'+p+'"'},TypeError),o("ERR_INVALID_ARG_TYPE",function(p,s,i){var d,c,f;if(typeof s=="string"&&(c="not ",s.substr(0,c.length)===c)?(d="must not be",s=s.replace(/^not /,"")):d="must be",function(v,m,g){return(g===void 0||g>v.length)&&(g=v.length),v.substring(g-m.length,g)===m}(p," argument"))f="The ".concat(p," ").concat(d," ").concat(u(s,"type"));else{var h=function(v,m,g){return typeof g!="number"&&(g=0),!(g+m.length>v.length)&&v.indexOf(m,g)!==-1}(p,".")?"property":"argument";f='The "'.concat(p,'" ').concat(h," ").concat(d," ").concat(u(s,"type"))}return f+=". Received type ".concat(typeof i)},TypeError),o("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),o("ERR_METHOD_NOT_IMPLEMENTED",function(p){return"The "+p+" method is not implemented"}),o("ERR_STREAM_PREMATURE_CLOSE","Premature close"),o("ERR_STREAM_DESTROYED",function(p){return"Cannot call "+p+" after a stream was destroyed"}),o("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),o("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),o("ERR_STREAM_WRITE_AFTER_END","write after end"),o("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),o("ERR_UNKNOWN_ENCODING",function(p){return"Unknown encoding: "+p},TypeError),o("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),n.exports.codes=a},{}],56:[function(t,n,l){(function(a){(function(){var o=Object.keys||function(v){var m=[];for(var g in v)m.push(g);return m};n.exports=c;var u=t("./_stream_readable"),p=t("./_stream_writable");t("inherits")(c,u);for(var s=o(p.prototype),i=0;i<s.length;i++){var d=s[i];c.prototype[d]||(c.prototype[d]=p.prototype[d])}function c(v){if(!(this instanceof c))return new c(v);u.call(this,v),p.call(this,v),this.allowHalfOpen=!0,v&&(v.readable===!1&&(this.readable=!1),v.writable===!1&&(this.writable=!1),v.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",f)))}function f(){this._writableState.ended||a.nextTick(h,this)}function h(v){v.end()}Object.defineProperty(c.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(c.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(c.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(c.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState!==void 0&&this._writableState!==void 0&&this._readableState.destroyed&&this._writableState.destroyed},set:function(v){this._readableState!==void 0&&this._writableState!==void 0&&(this._readableState.destroyed=v,this._writableState.destroyed=v)}})}).call(this)}).call(this,t("_process"))},{"./_stream_readable":58,"./_stream_writable":60,_process:50,inherits:24}],57:[function(t,n,l){n.exports=o;var a=t("./_stream_transform");function o(u){if(!(this instanceof o))return new o(u);a.call(this,u)}t("inherits")(o,a),o.prototype._transform=function(u,p,s){s(null,u)}},{"./_stream_transform":59,inherits:24}],58:[function(t,n,l){(function(a,o){(function(){var u;n.exports=A,A.ReadableState=E,t("events").EventEmitter;var p=function(b,_){return b.listeners(_).length},s=t("./internal/streams/stream"),i=t("buffer").Buffer,d=o.Uint8Array||function(){},c,f=t("util");c=f&&f.debuglog?f.debuglog("stream"):function(){};var h,v,m,g=t("./internal/streams/buffer_list"),x=t("./internal/streams/destroy"),y=t("./internal/streams/state").getHighWaterMark,w=t("../errors").codes,k=w.ERR_INVALID_ARG_TYPE,T=w.ERR_STREAM_PUSH_AFTER_EOF,I=w.ERR_METHOD_NOT_IMPLEMENTED,D=w.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;t("inherits")(A,s);var X=x.errorOrDestroy,V=["error","close","destroy","pause","resume"];function E(b,_,R){u=u||t("./_stream_duplex"),b=b||{},typeof R!="boolean"&&(R=_ instanceof u),this.objectMode=!!b.objectMode,R&&(this.objectMode=this.objectMode||!!b.readableObjectMode),this.highWaterMark=y(this,b,"readableHighWaterMark",R),this.buffer=new g,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=b.emitClose!==!1,this.autoDestroy=!!b.autoDestroy,this.destroyed=!1,this.defaultEncoding=b.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,b.encoding&&(h||(h=t("string_decoder/").StringDecoder),this.decoder=new h(b.encoding),this.encoding=b.encoding)}function A(b){if(u=u||t("./_stream_duplex"),!(this instanceof A))return new A(b);var _=this instanceof u;this._readableState=new E(b,this,_),this.readable=!0,b&&(typeof b.read=="function"&&(this._read=b.read),typeof b.destroy=="function"&&(this._destroy=b.destroy)),s.call(this)}function C(b,_,R,G,ee){c("readableAddChunk",_);var te,se=b._readableState;if(_===null)se.reading=!1,function(z,S){if(c("onEofChunk"),!S.ended){if(S.decoder){var B=S.decoder.end();B&&B.length&&(S.buffer.push(B),S.length+=S.objectMode?1:B.length)}S.ended=!0,S.sync?J(z):(S.needReadable=!1,S.emittedReadable||(S.emittedReadable=!0,$(z)))}}(b,se);else if(ee||(te=function(z,S){var B;Y=S,i.isBuffer(Y)||Y instanceof d||typeof S=="string"||S===void 0||z.objectMode||(B=new k("chunk",["string","Buffer","Uint8Array"],S));var Y;return B}(se,_)),te)X(b,te);else if(se.objectMode||_&&_.length>0)if(typeof _=="string"||se.objectMode||Object.getPrototypeOf(_)===i.prototype||(_=function(z){return i.from(z)}(_)),G)se.endEmitted?X(b,new D):F(b,se,_,!0);else if(se.ended)X(b,new T);else{if(se.destroyed)return!1;se.reading=!1,se.decoder&&!R?(_=se.decoder.write(_),se.objectMode||_.length!==0?F(b,se,_,!1):U(b,se)):F(b,se,_,!1)}else G||(se.reading=!1,U(b,se));return!se.ended&&(se.length<se.highWaterMark||se.length===0)}function F(b,_,R,G){_.flowing&&_.length===0&&!_.sync?(_.awaitDrain=0,b.emit("data",R)):(_.length+=_.objectMode?1:R.length,G?_.buffer.unshift(R):_.buffer.push(R),_.needReadable&&J(b)),U(b,_)}Object.defineProperty(A.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState!==void 0&&this._readableState.destroyed},set:function(b){this._readableState&&(this._readableState.destroyed=b)}}),A.prototype.destroy=x.destroy,A.prototype._undestroy=x.undestroy,A.prototype._destroy=function(b,_){_(b)},A.prototype.push=function(b,_){var R,G=this._readableState;return G.objectMode?R=!0:typeof b=="string"&&((_=_||G.defaultEncoding)!==G.encoding&&(b=i.from(b,_),_=""),R=!0),C(this,b,_,!1,R)},A.prototype.unshift=function(b){return C(this,b,null,!0,!1)},A.prototype.isPaused=function(){return this._readableState.flowing===!1},A.prototype.setEncoding=function(b){h||(h=t("string_decoder/").StringDecoder);var _=new h(b);this._readableState.decoder=_,this._readableState.encoding=this._readableState.decoder.encoding;for(var R=this._readableState.buffer.head,G="";R!==null;)G+=_.write(R.data),R=R.next;return this._readableState.buffer.clear(),G!==""&&this._readableState.buffer.push(G),this._readableState.length=G.length,this};var j=1073741824;function P(b,_){return b<=0||_.length===0&&_.ended?0:_.objectMode?1:b!=b?_.flowing&&_.length?_.buffer.head.data.length:_.length:(b>_.highWaterMark&&(_.highWaterMark=function(R){return R>=j?R=j:(R--,R|=R>>>1,R|=R>>>2,R|=R>>>4,R|=R>>>8,R|=R>>>16,R++),R}(b)),b<=_.length?b:_.ended?_.length:(_.needReadable=!0,0))}function J(b){var _=b._readableState;c("emitReadable",_.needReadable,_.emittedReadable),_.needReadable=!1,_.emittedReadable||(c("emitReadable",_.flowing),_.emittedReadable=!0,a.nextTick($,b))}function $(b){var _=b._readableState;c("emitReadable_",_.destroyed,_.length,_.ended),_.destroyed||!_.length&&!_.ended||(b.emit("readable"),_.emittedReadable=!1),_.needReadable=!_.flowing&&!_.ended&&_.length<=_.highWaterMark,W(b)}function U(b,_){_.readingMore||(_.readingMore=!0,a.nextTick(K,b,_))}function K(b,_){for(;!_.reading&&!_.ended&&(_.length<_.highWaterMark||_.flowing&&_.length===0);){var R=_.length;if(c("maybeReadMore read 0"),b.read(0),R===_.length)break}_.readingMore=!1}function L(b){var _=b._readableState;_.readableListening=b.listenerCount("readable")>0,_.resumeScheduled&&!_.paused?_.flowing=!0:b.listenerCount("data")>0&&b.resume()}function O(b){c("readable nexttick read 0"),b.read(0)}function H(b,_){c("resume",_.reading),_.reading||b.read(0),_.resumeScheduled=!1,b.emit("resume"),W(b),_.flowing&&!_.reading&&b.read(0)}function W(b){var _=b._readableState;for(c("flow",_.flowing);_.flowing&&b.read()!==null;);}function Z(b,_){return _.length===0?null:(_.objectMode?R=_.buffer.shift():!b||b>=_.length?(R=_.decoder?_.buffer.join(""):_.buffer.length===1?_.buffer.first():_.buffer.concat(_.length),_.buffer.clear()):R=_.buffer.consume(b,_.decoder),R);var R}function re(b){var _=b._readableState;c("endReadable",_.endEmitted),_.endEmitted||(_.ended=!0,a.nextTick(oe,_,b))}function oe(b,_){if(c("endReadableNT",b.endEmitted,b.length),!b.endEmitted&&b.length===0&&(b.endEmitted=!0,_.readable=!1,_.emit("end"),b.autoDestroy)){var R=_._writableState;(!R||R.autoDestroy&&R.finished)&&_.destroy()}}function ae(b,_){for(var R=0,G=b.length;R<G;R++)if(b[R]===_)return R;return-1}A.prototype.read=function(b){c("read",b),b=parseInt(b,10);var _=this._readableState,R=b;if(b!==0&&(_.emittedReadable=!1),b===0&&_.needReadable&&((_.highWaterMark!==0?_.length>=_.highWaterMark:_.length>0)||_.ended))return c("read: emitReadable",_.length,_.ended),_.length===0&&_.ended?re(this):J(this),null;if((b=P(b,_))===0&&_.ended)return _.length===0&&re(this),null;var G,ee=_.needReadable;return c("need readable",ee),(_.length===0||_.length-b<_.highWaterMark)&&c("length less than watermark",ee=!0),_.ended||_.reading?c("reading or ended",ee=!1):ee&&(c("do read"),_.reading=!0,_.sync=!0,_.length===0&&(_.needReadable=!0),this._read(_.highWaterMark),_.sync=!1,_.reading||(b=P(R,_))),(G=b>0?Z(b,_):null)===null?(_.needReadable=_.length<=_.highWaterMark,b=0):(_.length-=b,_.awaitDrain=0),_.length===0&&(_.ended||(_.needReadable=!0),R!==b&&_.ended&&re(this)),G!==null&&this.emit("data",G),G},A.prototype._read=function(b){X(this,new I("_read()"))},A.prototype.pipe=function(b,_){var R=this,G=this._readableState;switch(G.pipesCount){case 0:G.pipes=b;break;case 1:G.pipes=[G.pipes,b];break;default:G.pipes.push(b)}G.pipesCount+=1,c("pipe count=%d opts=%j",G.pipesCount,_);var ee=(!_||_.end!==!1)&&b!==a.stdout&&b!==a.stderr?se:ce;function te(me,ge){c("onunpipe"),me===R&&ge&&ge.hasUnpiped===!1&&(ge.hasUnpiped=!0,c("cleanup"),b.removeListener("close",ie),b.removeListener("finish",ue),b.removeListener("drain",z),b.removeListener("error",Y),b.removeListener("unpipe",te),R.removeListener("end",se),R.removeListener("end",ce),R.removeListener("data",B),S=!0,!G.awaitDrain||b._writableState&&!b._writableState.needDrain||z())}function se(){c("onend"),b.end()}G.endEmitted?a.nextTick(ee):R.once("end",ee),b.on("unpipe",te);var z=function(me){return function(){var ge=me._readableState;c("pipeOnDrain",ge.awaitDrain),ge.awaitDrain&&ge.awaitDrain--,ge.awaitDrain===0&&p(me,"data")&&(ge.flowing=!0,W(me))}}(R);b.on("drain",z);var S=!1;function B(me){c("ondata");var ge=b.write(me);c("dest.write",ge),ge===!1&&((G.pipesCount===1&&G.pipes===b||G.pipesCount>1&&ae(G.pipes,b)!==-1)&&!S&&(c("false write response, pause",G.awaitDrain),G.awaitDrain++),R.pause())}function Y(me){c("onerror",me),ce(),b.removeListener("error",Y),p(b,"error")===0&&X(b,me)}function ie(){b.removeListener("finish",ue),ce()}function ue(){c("onfinish"),b.removeListener("close",ie),ce()}function ce(){c("unpipe"),R.unpipe(b)}return R.on("data",B),function(me,ge,Ce){if(typeof me.prependListener=="function")return me.prependListener(ge,Ce);me._events&&me._events[ge]?Array.isArray(me._events[ge])?me._events[ge].unshift(Ce):me._events[ge]=[Ce,me._events[ge]]:me.on(ge,Ce)}(b,"error",Y),b.once("close",ie),b.once("finish",ue),b.emit("pipe",R),G.flowing||(c("pipe resume"),R.resume()),b},A.prototype.unpipe=function(b){var _=this._readableState,R={hasUnpiped:!1};if(_.pipesCount===0)return this;if(_.pipesCount===1)return b&&b!==_.pipes?this:(b||(b=_.pipes),_.pipes=null,_.pipesCount=0,_.flowing=!1,b&&b.emit("unpipe",this,R),this);if(!b){var G=_.pipes,ee=_.pipesCount;_.pipes=null,_.pipesCount=0,_.flowing=!1;for(var te=0;te<ee;te++)G[te].emit("unpipe",this,{hasUnpiped:!1});return this}var se=ae(_.pipes,b);return se===-1?this:(_.pipes.splice(se,1),_.pipesCount-=1,_.pipesCount===1&&(_.pipes=_.pipes[0]),b.emit("unpipe",this,R),this)},A.prototype.on=function(b,_){var R=s.prototype.on.call(this,b,_),G=this._readableState;return b==="data"?(G.readableListening=this.listenerCount("readable")>0,G.flowing!==!1&&this.resume()):b==="readable"&&(G.endEmitted||G.readableListening||(G.readableListening=G.needReadable=!0,G.flowing=!1,G.emittedReadable=!1,c("on readable",G.length,G.reading),G.length?J(this):G.reading||a.nextTick(O,this))),R},A.prototype.addListener=A.prototype.on,A.prototype.removeListener=function(b,_){var R=s.prototype.removeListener.call(this,b,_);return b==="readable"&&a.nextTick(L,this),R},A.prototype.removeAllListeners=function(b){var _=s.prototype.removeAllListeners.apply(this,arguments);return b!=="readable"&&b!==void 0||a.nextTick(L,this),_},A.prototype.resume=function(){var b=this._readableState;return b.flowing||(c("resume"),b.flowing=!b.readableListening,function(_,R){R.resumeScheduled||(R.resumeScheduled=!0,a.nextTick(H,_,R))}(this,b)),b.paused=!1,this},A.prototype.pause=function(){return c("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(c("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},A.prototype.wrap=function(b){var _=this,R=this._readableState,G=!1;for(var ee in b.on("end",function(){if(c("wrapped end"),R.decoder&&!R.ended){var se=R.decoder.end();se&&se.length&&_.push(se)}_.push(null)}),b.on("data",function(se){c("wrapped data"),R.decoder&&(se=R.decoder.write(se)),(!R.objectMode||se!=null)&&(R.objectMode||se&&se.length)&&(_.push(se)||(G=!0,b.pause()))}),b)this[ee]===void 0&&typeof b[ee]=="function"&&(this[ee]=function(se){return function(){return b[se].apply(b,arguments)}}(ee));for(var te=0;te<V.length;te++)b.on(V[te],this.emit.bind(this,V[te]));return this._read=function(se){c("wrapped _read",se),G&&(G=!1,b.resume())},this},typeof Symbol=="function"&&(A.prototype[Symbol.asyncIterator]=function(){return v===void 0&&(v=t("./internal/streams/async_iterator")),v(this)}),Object.defineProperty(A.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(A.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(A.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(b){this._readableState&&(this._readableState.flowing=b)}}),A._fromList=Z,Object.defineProperty(A.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),typeof Symbol=="function"&&(A.from=function(b,_){return m===void 0&&(m=t("./internal/streams/from")),m(A,b,_)})}).call(this)}).call(this,t("_process"),typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"../errors":55,"./_stream_duplex":56,"./internal/streams/async_iterator":61,"./internal/streams/buffer_list":62,"./internal/streams/destroy":63,"./internal/streams/from":65,"./internal/streams/state":67,"./internal/streams/stream":68,_process:50,buffer:17,events:22,inherits:24,"string_decoder/":75,util:16}],59:[function(t,n,l){n.exports=d;var a=t("../errors").codes,o=a.ERR_METHOD_NOT_IMPLEMENTED,u=a.ERR_MULTIPLE_CALLBACK,p=a.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=a.ERR_TRANSFORM_WITH_LENGTH_0,i=t("./_stream_duplex");function d(h){if(!(this instanceof d))return new d(h);i.call(this,h),this._transformState={afterTransform:function(v,m){var g=this._transformState;g.transforming=!1;var x=g.writecb;if(x===null)return this.emit("error",new u);g.writechunk=null,g.writecb=null,m!=null&&this.push(m),x(v);var y=this._readableState;y.reading=!1,(y.needReadable||y.length<y.highWaterMark)&&this._read(y.highWaterMark)}.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,h&&(typeof h.transform=="function"&&(this._transform=h.transform),typeof h.flush=="function"&&(this._flush=h.flush)),this.on("prefinish",c)}function c(){var h=this;typeof this._flush!="function"||this._readableState.destroyed?f(this,null,null):this._flush(function(v,m){f(h,v,m)})}function f(h,v,m){if(v)return h.emit("error",v);if(m!=null&&h.push(m),h._writableState.length)throw new s;if(h._transformState.transforming)throw new p;return h.push(null)}t("inherits")(d,i),d.prototype.push=function(h,v){return this._transformState.needTransform=!1,i.prototype.push.call(this,h,v)},d.prototype._transform=function(h,v,m){m(new o("_transform()"))},d.prototype._write=function(h,v,m){var g=this._transformState;if(g.writecb=m,g.writechunk=h,g.writeencoding=v,!g.transforming){var x=this._readableState;(g.needTransform||x.needReadable||x.length<x.highWaterMark)&&this._read(x.highWaterMark)}},d.prototype._read=function(h){var v=this._transformState;v.writechunk===null||v.transforming?v.needTransform=!0:(v.transforming=!0,this._transform(v.writechunk,v.writeencoding,v.afterTransform))},d.prototype._destroy=function(h,v){i.prototype._destroy.call(this,h,function(m){v(m)})}},{"../errors":55,"./_stream_duplex":56,inherits:24}],60:[function(t,n,l){(function(a,o){(function(){function u(U){var K=this;this.next=null,this.entry=null,this.finish=function(){(function(L,O,H){var W=L.entry;for(L.entry=null;W;){var Z=W.callback;O.pendingcb--,Z(H),W=W.next}O.corkedRequestsFree.next=L})(K,U)}}var p;n.exports=A,A.WritableState=E;var s={deprecate:t("util-deprecate")},i=t("./internal/streams/stream"),d=t("buffer").Buffer,c=o.Uint8Array||function(){},f,h=t("./internal/streams/destroy"),v=t("./internal/streams/state").getHighWaterMark,m=t("../errors").codes,g=m.ERR_INVALID_ARG_TYPE,x=m.ERR_METHOD_NOT_IMPLEMENTED,y=m.ERR_MULTIPLE_CALLBACK,w=m.ERR_STREAM_CANNOT_PIPE,k=m.ERR_STREAM_DESTROYED,T=m.ERR_STREAM_NULL_VALUES,I=m.ERR_STREAM_WRITE_AFTER_END,D=m.ERR_UNKNOWN_ENCODING,X=h.errorOrDestroy;function V(){}function E(U,K,L){p=p||t("./_stream_duplex"),U=U||{},typeof L!="boolean"&&(L=K instanceof p),this.objectMode=!!U.objectMode,L&&(this.objectMode=this.objectMode||!!U.writableObjectMode),this.highWaterMark=v(this,U,"writableHighWaterMark",L),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var O=U.decodeStrings===!1;this.decodeStrings=!O,this.defaultEncoding=U.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(H){(function(W,Z){var re=W._writableState,oe=re.sync,ae=re.writecb;if(typeof ae!="function")throw new y;if(function(_){_.writing=!1,_.writecb=null,_.length-=_.writelen,_.writelen=0}(re),Z)(function(_,R,G,ee,te){--R.pendingcb,G?(a.nextTick(te,ee),a.nextTick($,_,R),_._writableState.errorEmitted=!0,X(_,ee)):(te(ee),_._writableState.errorEmitted=!0,X(_,ee),$(_,R))})(W,re,oe,Z,ae);else{var b=P(re)||W.destroyed;b||re.corked||re.bufferProcessing||!re.bufferedRequest||j(W,re),oe?a.nextTick(F,W,re,b,ae):F(W,re,b,ae)}})(K,H)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=U.emitClose!==!1,this.autoDestroy=!!U.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new u(this)}function A(U){var K=this instanceof(p=p||t("./_stream_duplex"));if(!K&&!f.call(A,this))return new A(U);this._writableState=new E(U,this,K),this.writable=!0,U&&(typeof U.write=="function"&&(this._write=U.write),typeof U.writev=="function"&&(this._writev=U.writev),typeof U.destroy=="function"&&(this._destroy=U.destroy),typeof U.final=="function"&&(this._final=U.final)),i.call(this)}function C(U,K,L,O,H,W,Z){K.writelen=O,K.writecb=Z,K.writing=!0,K.sync=!0,K.destroyed?K.onwrite(new k("write")):L?U._writev(H,K.onwrite):U._write(H,W,K.onwrite),K.sync=!1}function F(U,K,L,O){L||function(H,W){W.length===0&&W.needDrain&&(W.needDrain=!1,H.emit("drain"))}(U,K),K.pendingcb--,O(),$(U,K)}function j(U,K){K.bufferProcessing=!0;var L=K.bufferedRequest;if(U._writev&&L&&L.next){var O=K.bufferedRequestCount,H=new Array(O),W=K.corkedRequestsFree;W.entry=L;for(var Z=0,re=!0;L;)H[Z]=L,L.isBuf||(re=!1),L=L.next,Z+=1;H.allBuffers=re,C(U,K,!0,K.length,H,"",W.finish),K.pendingcb++,K.lastBufferedRequest=null,W.next?(K.corkedRequestsFree=W.next,W.next=null):K.corkedRequestsFree=new u(K),K.bufferedRequestCount=0}else{for(;L;){var oe=L.chunk,ae=L.encoding,b=L.callback;if(C(U,K,!1,K.objectMode?1:oe.length,oe,ae,b),L=L.next,K.bufferedRequestCount--,K.writing)break}L===null&&(K.lastBufferedRequest=null)}K.bufferedRequest=L,K.bufferProcessing=!1}function P(U){return U.ending&&U.length===0&&U.bufferedRequest===null&&!U.finished&&!U.writing}function J(U,K){U._final(function(L){K.pendingcb--,L&&X(U,L),K.prefinished=!0,U.emit("prefinish"),$(U,K)})}function $(U,K){var L=P(K);if(L&&(function(H,W){W.prefinished||W.finalCalled||(typeof H._final!="function"||W.destroyed?(W.prefinished=!0,H.emit("prefinish")):(W.pendingcb++,W.finalCalled=!0,a.nextTick(J,H,W)))}(U,K),K.pendingcb===0&&(K.finished=!0,U.emit("finish"),K.autoDestroy))){var O=U._readableState;(!O||O.autoDestroy&&O.endEmitted)&&U.destroy()}return L}t("inherits")(A,i),E.prototype.getBuffer=function(){for(var U=this.bufferedRequest,K=[];U;)K.push(U),U=U.next;return K},function(){try{Object.defineProperty(E.prototype,"buffer",{get:s.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(U){}}(),typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(f=Function.prototype[Symbol.hasInstance],Object.defineProperty(A,Symbol.hasInstance,{value:function(U){return!!f.call(this,U)||this===A&&U&&U._writableState instanceof E}})):f=function(U){return U instanceof this},A.prototype.pipe=function(){X(this,new w)},A.prototype.write=function(U,K,L){var O,H=this._writableState,W=!1,Z=!H.objectMode&&(O=U,d.isBuffer(O)||O instanceof c);return Z&&!d.isBuffer(U)&&(U=function(re){return d.from(re)}(U)),typeof K=="function"&&(L=K,K=null),Z?K="buffer":K||(K=H.defaultEncoding),typeof L!="function"&&(L=V),H.ending?function(re,oe){var ae=new I;X(re,ae),a.nextTick(oe,ae)}(this,L):(Z||function(re,oe,ae,b){var _;return ae===null?_=new T:typeof ae=="string"||oe.objectMode||(_=new g("chunk",["string","Buffer"],ae)),!_||(X(re,_),a.nextTick(b,_),!1)}(this,H,U,L))&&(H.pendingcb++,W=function(re,oe,ae,b,_,R){if(!ae){var G=function(z,S,B){return z.objectMode||z.decodeStrings===!1||typeof S!="string"||(S=d.from(S,B)),S}(oe,b,_);b!==G&&(ae=!0,_="buffer",b=G)}var ee=oe.objectMode?1:b.length;oe.length+=ee;var te=oe.length<oe.highWaterMark;if(te||(oe.needDrain=!0),oe.writing||oe.corked){var se=oe.lastBufferedRequest;oe.lastBufferedRequest={chunk:b,encoding:_,isBuf:ae,callback:R,next:null},se?se.next=oe.lastBufferedRequest:oe.bufferedRequest=oe.lastBufferedRequest,oe.bufferedRequestCount+=1}else C(re,oe,!1,ee,b,_,R);return te}(this,H,Z,U,K,L)),W},A.prototype.cork=function(){this._writableState.corked++},A.prototype.uncork=function(){var U=this._writableState;U.corked&&(U.corked--,U.writing||U.corked||U.bufferProcessing||!U.bufferedRequest||j(this,U))},A.prototype.setDefaultEncoding=function(U){if(typeof U=="string"&&(U=U.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((U+"").toLowerCase())>-1))throw new D(U);return this._writableState.defaultEncoding=U,this},Object.defineProperty(A.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(A.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),A.prototype._write=function(U,K,L){L(new x("_write()"))},A.prototype._writev=null,A.prototype.end=function(U,K,L){var O=this._writableState;return typeof U=="function"?(L=U,U=null,K=null):typeof K=="function"&&(L=K,K=null),U!=null&&this.write(U,K),O.corked&&(O.corked=1,this.uncork()),O.ending||function(H,W,Z){W.ending=!0,$(H,W),Z&&(W.finished?a.nextTick(Z):H.once("finish",Z)),W.ended=!0,H.writable=!1}(this,O,L),this},Object.defineProperty(A.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(A.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState!==void 0&&this._writableState.destroyed},set:function(U){this._writableState&&(this._writableState.destroyed=U)}}),A.prototype.destroy=h.destroy,A.prototype._undestroy=h.undestroy,A.prototype._destroy=function(U,K){K(U)}}).call(this)}).call(this,t("_process"),typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{"../errors":55,"./_stream_duplex":56,"./internal/streams/destroy":63,"./internal/streams/state":67,"./internal/streams/stream":68,_process:50,buffer:17,inherits:24,"util-deprecate":78}],61:[function(t,n,l){(function(a){(function(){var o;function u(w,k,T){return k in w?Object.defineProperty(w,k,{value:T,enumerable:!0,configurable:!0,writable:!0}):w[k]=T,w}var p=t("./end-of-stream"),s=Symbol("lastResolve"),i=Symbol("lastReject"),d=Symbol("error"),c=Symbol("ended"),f=Symbol("lastPromise"),h=Symbol("handlePromise"),v=Symbol("stream");function m(w,k){return{value:w,done:k}}function g(w){var k=w[s];if(k!==null){var T=w[v].read();T!==null&&(w[f]=null,w[s]=null,w[i]=null,k(m(T,!1)))}}var x=Object.getPrototypeOf(function(){}),y=Object.setPrototypeOf((u(o={get stream(){return this[v]},next:function(){var w=this,k=this[d];if(k!==null)return Promise.reject(k);if(this[c])return Promise.resolve(m(void 0,!0));if(this[v].destroyed)return new Promise(function(X,V){a.nextTick(function(){w[d]?V(w[d]):X(m(void 0,!0))})});var T,I=this[f];if(I)T=new Promise(function(X,V){return function(E,A){X.then(function(){V[c]?E(m(void 0,!0)):V[h](E,A)},A)}}(I,this));else{var D=this[v].read();if(D!==null)return Promise.resolve(m(D,!1));T=new Promise(this[h])}return this[f]=T,T}},Symbol.asyncIterator,function(){return this}),u(o,"return",function(){var w=this;return new Promise(function(k,T){w[v].destroy(null,function(I){I?T(I):k(m(void 0,!0))})})}),o),x);n.exports=function(w){var k,T=Object.create(y,(u(k={},v,{value:w,writable:!0}),u(k,s,{value:null,writable:!0}),u(k,i,{value:null,writable:!0}),u(k,d,{value:null,writable:!0}),u(k,c,{value:w._readableState.endEmitted,writable:!0}),u(k,h,{value:function(I,D){var X=T[v].read();X?(T[f]=null,T[s]=null,T[i]=null,I(m(X,!1))):(T[s]=I,T[i]=D)},writable:!0}),k));return T[f]=null,p(w,function(I){if(I&&I.code!=="ERR_STREAM_PREMATURE_CLOSE"){var D=T[i];return D!==null&&(T[f]=null,T[s]=null,T[i]=null,D(I)),void(T[d]=I)}var X=T[s];X!==null&&(T[f]=null,T[s]=null,T[i]=null,X(m(void 0,!0))),T[c]=!0}),w.on("readable",function(I){a.nextTick(g,I)}.bind(null,T)),T}}).call(this)}).call(this,t("_process"))},{"./end-of-stream":64,_process:50}],62:[function(t,n,l){function a(d,c){var f=Object.keys(d);if(Object.getOwnPropertySymbols){var h=Object.getOwnPropertySymbols(d);c&&(h=h.filter(function(v){return Object.getOwnPropertyDescriptor(d,v).enumerable})),f.push.apply(f,h)}return f}function o(d,c,f){return c in d?Object.defineProperty(d,c,{value:f,enumerable:!0,configurable:!0,writable:!0}):d[c]=f,d}function u(d,c){for(var f=0;f<c.length;f++){var h=c[f];h.enumerable=h.enumerable||!1,h.configurable=!0,"value"in h&&(h.writable=!0),Object.defineProperty(d,h.key,h)}}var p=t("buffer").Buffer,s=t("util").inspect,i=s&&s.custom||"inspect";n.exports=function(){function d(){(function(h,v){if(!(h instanceof v))throw new TypeError("Cannot call a class as a function")})(this,d),this.head=null,this.tail=null,this.length=0}var c,f;return c=d,(f=[{key:"push",value:function(h){var v={data:h,next:null};this.length>0?this.tail.next=v:this.head=v,this.tail=v,++this.length}},{key:"unshift",value:function(h){var v={data:h,next:this.head};this.length===0&&(this.tail=v),this.head=v,++this.length}},{key:"shift",value:function(){if(this.length!==0){var h=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,h}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(h){if(this.length===0)return"";for(var v=this.head,m=""+v.data;v=v.next;)m+=h+v.data;return m}},{key:"concat",value:function(h){if(this.length===0)return p.alloc(0);for(var v,m,g,x=p.allocUnsafe(h>>>0),y=this.head,w=0;y;)v=y.data,m=x,g=w,p.prototype.copy.call(v,m,g),w+=y.data.length,y=y.next;return x}},{key:"consume",value:function(h,v){var m;return h<this.head.data.length?(m=this.head.data.slice(0,h),this.head.data=this.head.data.slice(h)):m=h===this.head.data.length?this.shift():v?this._getString(h):this._getBuffer(h),m}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(h){var v=this.head,m=1,g=v.data;for(h-=g.length;v=v.next;){var x=v.data,y=h>x.length?x.length:h;if(y===x.length?g+=x:g+=x.slice(0,h),(h-=y)===0){y===x.length?(++m,v.next?this.head=v.next:this.head=this.tail=null):(this.head=v,v.data=x.slice(y));break}++m}return this.length-=m,g}},{key:"_getBuffer",value:function(h){var v=p.allocUnsafe(h),m=this.head,g=1;for(m.data.copy(v),h-=m.data.length;m=m.next;){var x=m.data,y=h>x.length?x.length:h;if(x.copy(v,v.length-h,0,y),(h-=y)===0){y===x.length?(++g,m.next?this.head=m.next:this.head=this.tail=null):(this.head=m,m.data=x.slice(y));break}++g}return this.length-=g,v}},{key:i,value:function(h,v){return s(this,function(m){for(var g=1;g<arguments.length;g++){var x=arguments[g]!=null?arguments[g]:{};g%2?a(Object(x),!0).forEach(function(y){o(m,y,x[y])}):Object.getOwnPropertyDescriptors?Object.defineProperties(m,Object.getOwnPropertyDescriptors(x)):a(Object(x)).forEach(function(y){Object.defineProperty(m,y,Object.getOwnPropertyDescriptor(x,y))})}return m}({},v,{depth:0,customInspect:!1}))}}])&&u(c.prototype,f),d}()},{buffer:17,util:16}],63:[function(t,n,l){(function(a){(function(){function o(s,i){p(s,i),u(s)}function u(s){s._writableState&&!s._writableState.emitClose||s._readableState&&!s._readableState.emitClose||s.emit("close")}function p(s,i){s.emit("error",i)}n.exports={destroy:function(s,i){var d=this,c=this._readableState&&this._readableState.destroyed,f=this._writableState&&this._writableState.destroyed;return c||f?(i?i(s):s&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,a.nextTick(p,this,s)):a.nextTick(p,this,s)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(s||null,function(h){!i&&h?d._writableState?d._writableState.errorEmitted?a.nextTick(u,d):(d._writableState.errorEmitted=!0,a.nextTick(o,d,h)):a.nextTick(o,d,h):i?(a.nextTick(u,d),i(h)):a.nextTick(u,d)}),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(s,i){var d=s._readableState,c=s._writableState;d&&d.autoDestroy||c&&c.autoDestroy?s.destroy(i):s.emit("error",i)}}}).call(this)}).call(this,t("_process"))},{_process:50}],64:[function(t,n,l){var a=t("../../../errors").codes.ERR_STREAM_PREMATURE_CLOSE;function o(){}n.exports=function u(p,s,i){if(typeof s=="function")return u(p,null,s);s||(s={}),i=function(k){var T=!1;return function(){if(!T){T=!0;for(var I=arguments.length,D=new Array(I),X=0;X<I;X++)D[X]=arguments[X];k.apply(this,D)}}}(i||o);var d=s.readable||s.readable!==!1&&p.readable,c=s.writable||s.writable!==!1&&p.writable,f=function(){p.writable||v()},h=p._writableState&&p._writableState.finished,v=function(){c=!1,h=!0,d||i.call(p)},m=p._readableState&&p._readableState.endEmitted,g=function(){d=!1,m=!0,c||i.call(p)},x=function(k){i.call(p,k)},y=function(){var k;return d&&!m?(p._readableState&&p._readableState.ended||(k=new a),i.call(p,k)):c&&!h?(p._writableState&&p._writableState.ended||(k=new a),i.call(p,k)):void 0},w=function(){p.req.on("finish",v)};return function(k){return k.setHeader&&typeof k.abort=="function"}(p)?(p.on("complete",v),p.on("abort",y),p.req?w():p.on("request",w)):c&&!p._writableState&&(p.on("end",f),p.on("close",f)),p.on("end",g),p.on("finish",v),s.error!==!1&&p.on("error",x),p.on("close",y),function(){p.removeListener("complete",v),p.removeListener("abort",y),p.removeListener("request",w),p.req&&p.req.removeListener("finish",v),p.removeListener("end",f),p.removeListener("close",f),p.removeListener("finish",v),p.removeListener("end",g),p.removeListener("error",x),p.removeListener("close",y)}}},{"../../../errors":55}],65:[function(t,n,l){n.exports=function(){throw new Error("Readable.from is not available in the browser")}},{}],66:[function(t,n,l){var a,o=t("../../../errors").codes,u=o.ERR_MISSING_ARGS,p=o.ERR_STREAM_DESTROYED;function s(c){if(c)throw c}function i(c){c()}function d(c,f){return c.pipe(f)}n.exports=function(){for(var c=arguments.length,f=new Array(c),h=0;h<c;h++)f[h]=arguments[h];var v,m=function(x){return x.length?typeof x[x.length-1]!="function"?s:x.pop():s}(f);if(Array.isArray(f[0])&&(f=f[0]),f.length<2)throw new u("streams");var g=f.map(function(x,y){var w=y<f.length-1;return function(k,T,I,D){D=function(E){var A=!1;return function(){A||(A=!0,E.apply(void 0,arguments))}}(D);var X=!1;k.on("close",function(){X=!0}),a===void 0&&(a=t("./end-of-stream")),a(k,{readable:T,writable:I},function(E){if(E)return D(E);X=!0,D()});var V=!1;return function(E){if(!X&&!V)return V=!0,function(A){return A.setHeader&&typeof A.abort=="function"}(k)?k.abort():typeof k.destroy=="function"?k.destroy():void D(E||new p("pipe"))}}(x,w,y>0,function(k){v||(v=k),k&&g.forEach(i),w||(g.forEach(i),m(v))})});return f.reduce(d)}},{"../../../errors":55,"./end-of-stream":64}],67:[function(t,n,l){var a=t("../../../errors").codes.ERR_INVALID_OPT_VALUE;n.exports={getHighWaterMark:function(o,u,p,s){var i=function(d,c,f){return d.highWaterMark!=null?d.highWaterMark:c?d[f]:null}(u,s,p);if(i!=null){if(!isFinite(i)||Math.floor(i)!==i||i<0)throw new a(s?p:"highWaterMark",i);return Math.floor(i)}return o.objectMode?16:16384}}},{"../../../errors":55}],68:[function(t,n,l){n.exports=t("events").EventEmitter},{events:22}],69:[function(t,n,l){(l=n.exports=t("./lib/_stream_readable.js")).Stream=l,l.Readable=l,l.Writable=t("./lib/_stream_writable.js"),l.Duplex=t("./lib/_stream_duplex.js"),l.Transform=t("./lib/_stream_transform.js"),l.PassThrough=t("./lib/_stream_passthrough.js"),l.finished=t("./lib/internal/streams/end-of-stream.js"),l.pipeline=t("./lib/internal/streams/pipeline.js")},{"./lib/_stream_duplex.js":56,"./lib/_stream_passthrough.js":57,"./lib/_stream_readable.js":58,"./lib/_stream_transform.js":59,"./lib/_stream_writable.js":60,"./lib/internal/streams/end-of-stream.js":64,"./lib/internal/streams/pipeline.js":66}],70:[function(t,n,l){n.exports=function(){if(typeof arguments[0]!="function")throw new Error("callback needed");if(typeof arguments[1]!="number")throw new Error("interval needed");var a;if(arguments.length>0){a=new Array(arguments.length-2);for(var o=0;o<a.length;o++)a[o]=arguments[o+2]}return new function(u,p,s){var i=this;this._callback=u,this._args=s,this._interval=setInterval(u,p,this._args),this.reschedule=function(d){d||(d=i._interval),i._interval&&clearInterval(i._interval),i._interval=setInterval(i._callback,d,i._args)},this.clear=function(){i._interval&&(clearInterval(i._interval),i._interval=void 0)},this.destroy=function(){i._interval&&clearInterval(i._interval),i._callback=void 0,i._interval=void 0,i._args=void 0}}(arguments[0],arguments[1],a)}},{}],71:[function(t,n,l){n.exports=t("./index.js")()},{"./index.js":72}],72:[function(t,n,l){(function(a){(function(){function o(u){return u instanceof a?a.from(u):new u.constructor(u.buffer.slice(),u.byteOffset,u.length)}n.exports=function(u){return(u=u||{}).circles?function(s){var i=[],d=[];return s.proto?function f(h){if(typeof h!="object"||h===null)return h;if(h instanceof Date)return new Date(h);if(Array.isArray(h))return c(h,f);if(h instanceof Map)return new Map(c(Array.from(h),f));if(h instanceof Set)return new Set(c(Array.from(h),f));var v={};for(var m in i.push(h),d.push(v),h){var g=h[m];if(typeof g!="object"||g===null)v[m]=g;else if(g instanceof Date)v[m]=new Date(g);else if(g instanceof Map)v[m]=new Map(c(Array.from(g),f));else if(g instanceof Set)v[m]=new Set(c(Array.from(g),f));else if(ArrayBuffer.isView(g))v[m]=o(g);else{var x=i.indexOf(g);v[m]=x!==-1?d[x]:f(g)}}return i.pop(),d.pop(),v}:function f(h){if(typeof h!="object"||h===null)return h;if(h instanceof Date)return new Date(h);if(Array.isArray(h))return c(h,f);if(h instanceof Map)return new Map(c(Array.from(h),f));if(h instanceof Set)return new Set(c(Array.from(h),f));var v={};for(var m in i.push(h),d.push(v),h)if(Object.hasOwnProperty.call(h,m)!==!1){var g=h[m];if(typeof g!="object"||g===null)v[m]=g;else if(g instanceof Date)v[m]=new Date(g);else if(g instanceof Map)v[m]=new Map(c(Array.from(g),f));else if(g instanceof Set)v[m]=new Set(c(Array.from(g),f));else if(ArrayBuffer.isView(g))v[m]=o(g);else{var x=i.indexOf(g);v[m]=x!==-1?d[x]:f(g)}}return i.pop(),d.pop(),v};function c(f,h){for(var v=Object.keys(f),m=new Array(v.length),g=0;g<v.length;g++){var x=v[g],y=f[x];if(typeof y!="object"||y===null)m[x]=y;else if(y instanceof Date)m[x]=new Date(y);else if(ArrayBuffer.isView(y))m[x]=o(y);else{var w=i.indexOf(y);m[x]=w!==-1?d[w]:h(y)}}return m}}(u):u.proto?function s(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return p(i,s);if(i instanceof Map)return new Map(p(Array.from(i),s));if(i instanceof Set)return new Set(p(Array.from(i),s));var d={};for(var c in i){var f=i[c];typeof f!="object"||f===null?d[c]=f:f instanceof Date?d[c]=new Date(f):f instanceof Map?d[c]=new Map(p(Array.from(f),s)):f instanceof Set?d[c]=new Set(p(Array.from(f),s)):ArrayBuffer.isView(f)?d[c]=o(f):d[c]=s(f)}return d}:function s(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return p(i,s);if(i instanceof Map)return new Map(p(Array.from(i),s));if(i instanceof Set)return new Set(p(Array.from(i),s));var d={};for(var c in i)if(Object.hasOwnProperty.call(i,c)!==!1){var f=i[c];typeof f!="object"||f===null?d[c]=f:f instanceof Date?d[c]=new Date(f):f instanceof Map?d[c]=new Map(p(Array.from(f),s)):f instanceof Set?d[c]=new Set(p(Array.from(f),s)):ArrayBuffer.isView(f)?d[c]=o(f):d[c]=s(f)}return d};function p(s,i){for(var d=Object.keys(s),c=new Array(d.length),f=0;f<d.length;f++){var h=d[f],v=s[h];typeof v!="object"||v===null?c[h]=v:v instanceof Date?c[h]=new Date(v):ArrayBuffer.isView(v)?c[h]=o(v):c[h]=i(v)}return c}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:17}],73:[function(t,n,l){var a=t("buffer"),o=a.Buffer;function u(s,i){for(var d in s)i[d]=s[d]}function p(s,i,d){return o(s,i,d)}o.from&&o.alloc&&o.allocUnsafe&&o.allocUnsafeSlow?n.exports=a:(u(a,l),l.Buffer=p),p.prototype=Object.create(o.prototype),u(o,p),p.from=function(s,i,d){if(typeof s=="number")throw new TypeError("Argument must not be a number");return o(s,i,d)},p.alloc=function(s,i,d){if(typeof s!="number")throw new TypeError("Argument must be a number");var c=o(s);return i!==void 0?typeof d=="string"?c.fill(i,d):c.fill(i):c.fill(0),c},p.allocUnsafe=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return o(s)},p.allocUnsafeSlow=function(s){if(typeof s!="number")throw new TypeError("Argument must be a number");return a.SlowBuffer(s)}},{buffer:17}],74:[function(t,n,l){n.exports=function(a){var o=a._readableState;return o?o.objectMode||typeof a._duplexState=="number"?a.read():a.read((u=o,u.buffer.length?u.buffer.head?u.buffer.head.data.length:u.buffer[0].length:u.length)):null;var u}},{}],75:[function(t,n,l){var a=t("safe-buffer").Buffer,o=a.isEncoding||function(m){switch((m=""+m)&&m.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function u(m){var g;switch(this.encoding=function(x){var y=function(w){if(!w)return"utf8";for(var k;;)switch(w){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return w;default:if(k)return;w=(""+w).toLowerCase(),k=!0}}(x);if(typeof y!="string"&&(a.isEncoding===o||!o(x)))throw new Error("Unknown encoding: "+x);return y||x}(m),this.encoding){case"utf16le":this.text=i,this.end=d,g=4;break;case"utf8":this.fillLast=s,g=4;break;case"base64":this.text=c,this.end=f,g=3;break;default:return this.write=h,void(this.end=v)}this.lastNeed=0,this.lastTotal=0,this.lastChar=a.allocUnsafe(g)}function p(m){return m<=127?0:m>>5==6?2:m>>4==14?3:m>>3==30?4:m>>6==2?-1:-2}function s(m){var g=this.lastTotal-this.lastNeed,x=function(y,w,k){if((192&w[0])!=128)return y.lastNeed=0,"�";if(y.lastNeed>1&&w.length>1){if((192&w[1])!=128)return y.lastNeed=1,"�";if(y.lastNeed>2&&w.length>2&&(192&w[2])!=128)return y.lastNeed=2,"�"}}(this,m);return x!==void 0?x:this.lastNeed<=m.length?(m.copy(this.lastChar,g,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(m.copy(this.lastChar,g,0,m.length),void(this.lastNeed-=m.length))}function i(m,g){if((m.length-g)%2==0){var x=m.toString("utf16le",g);if(x){var y=x.charCodeAt(x.length-1);if(y>=55296&&y<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=m[m.length-2],this.lastChar[1]=m[m.length-1],x.slice(0,-1)}return x}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=m[m.length-1],m.toString("utf16le",g,m.length-1)}function d(m){var g=m&&m.length?this.write(m):"";if(this.lastNeed){var x=this.lastTotal-this.lastNeed;return g+this.lastChar.toString("utf16le",0,x)}return g}function c(m,g){var x=(m.length-g)%3;return x===0?m.toString("base64",g):(this.lastNeed=3-x,this.lastTotal=3,x===1?this.lastChar[0]=m[m.length-1]:(this.lastChar[0]=m[m.length-2],this.lastChar[1]=m[m.length-1]),m.toString("base64",g,m.length-x))}function f(m){var g=m&&m.length?this.write(m):"";return this.lastNeed?g+this.lastChar.toString("base64",0,3-this.lastNeed):g}function h(m){return m.toString(this.encoding)}function v(m){return m&&m.length?this.write(m):""}l.StringDecoder=u,u.prototype.write=function(m){if(m.length===0)return"";var g,x;if(this.lastNeed){if((g=this.fillLast(m))===void 0)return"";x=this.lastNeed,this.lastNeed=0}else x=0;return x<m.length?g?g+this.text(m,x):this.text(m,x):g||""},u.prototype.end=function(m){var g=m&&m.length?this.write(m):"";return this.lastNeed?g+"�":g},u.prototype.text=function(m,g){var x=function(w,k,T){var I=k.length-1;if(I<T)return 0;var D=p(k[I]);return D>=0?(D>0&&(w.lastNeed=D-1),D):--I<T||D===-2?0:(D=p(k[I]))>=0?(D>0&&(w.lastNeed=D-2),D):--I<T||D===-2?0:(D=p(k[I]))>=0?(D>0&&(D===2?D=0:w.lastNeed=D-3),D):0}(this,m,g);if(!this.lastNeed)return m.toString("utf8",g);this.lastTotal=x;var y=m.length-(x-this.lastNeed);return m.copy(this.lastChar,0,y),m.toString("utf8",g,y)},u.prototype.fillLast=function(m){if(this.lastNeed<=m.length)return m.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);m.copy(this.lastChar,this.lastTotal-this.lastNeed,0,m.length),this.lastNeed-=m.length}},{"safe-buffer":73}],76:[function(t,n,l){var a=t("punycode"),o=t("./util");function u(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}l.parse=k,l.resolve=function(T,I){return k(T,!1,!0).resolve(I)},l.resolveObject=function(T,I){return T?k(T,!1,!0).resolveObject(I):I},l.format=function(T){return o.isString(T)&&(T=k(T)),T instanceof u?T.format():u.prototype.format.call(T)},l.Url=u;var p=/^([a-z0-9.+-]+:)/i,s=/:[0-9]*$/,i=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,d=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r",`
40
+ `," "]),c=["'"].concat(d),f=["%","/","?",";","#"].concat(c),h=["/","?","#"],v=/^[+a-z0-9A-Z_-]{0,63}$/,m=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,g={javascript:!0,"javascript:":!0},x={javascript:!0,"javascript:":!0},y={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},w=t("querystring");function k(T,I,D){if(T&&o.isObject(T)&&T instanceof u)return T;var X=new u;return X.parse(T,I,D),X}u.prototype.parse=function(T,I,D){if(!o.isString(T))throw new TypeError("Parameter 'url' must be a string, not "+typeof T);var X=T.indexOf("?"),V=X!==-1&&X<T.indexOf("#")?"?":"#",E=T.split(V);E[0]=E[0].replace(/\\/g,"/");var A=T=E.join(V);if(A=A.trim(),!D&&T.split("#").length===1){var C=i.exec(A);if(C)return this.path=A,this.href=A,this.pathname=C[1],C[2]?(this.search=C[2],this.query=I?w.parse(this.search.substr(1)):this.search.substr(1)):I&&(this.search="",this.query={}),this}var F=p.exec(A);if(F){var j=(F=F[0]).toLowerCase();this.protocol=j,A=A.substr(F.length)}if(D||F||A.match(/^\/\/[^@\/]+@[^@\/]+/)){var P=A.substr(0,2)==="//";!P||F&&x[F]||(A=A.substr(2),this.slashes=!0)}if(!x[F]&&(P||F&&!y[F])){for(var J,$,U=-1,K=0;K<h.length;K++)(L=A.indexOf(h[K]))!==-1&&(U===-1||L<U)&&(U=L);for(($=U===-1?A.lastIndexOf("@"):A.lastIndexOf("@",U))!==-1&&(J=A.slice(0,$),A=A.slice($+1),this.auth=decodeURIComponent(J)),U=-1,K=0;K<f.length;K++){var L;(L=A.indexOf(f[K]))!==-1&&(U===-1||L<U)&&(U=L)}U===-1&&(U=A.length),this.host=A.slice(0,U),A=A.slice(U),this.parseHost(),this.hostname=this.hostname||"";var O=this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!O)for(var H=this.hostname.split(/\./),W=(K=0,H.length);K<W;K++){var Z=H[K];if(Z&&!Z.match(v)){for(var re="",oe=0,ae=Z.length;oe<ae;oe++)Z.charCodeAt(oe)>127?re+="x":re+=Z[oe];if(!re.match(v)){var b=H.slice(0,K),_=H.slice(K+1),R=Z.match(m);R&&(b.push(R[1]),_.unshift(R[2])),_.length&&(A="/"+_.join(".")+A),this.hostname=b.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),O||(this.hostname=a.toASCII(this.hostname));var G=this.port?":"+this.port:"",ee=this.hostname||"";this.host=ee+G,this.href+=this.host,O&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),A[0]!=="/"&&(A="/"+A))}if(!g[j])for(K=0,W=c.length;K<W;K++){var te=c[K];if(A.indexOf(te)!==-1){var se=encodeURIComponent(te);se===te&&(se=escape(te)),A=A.split(te).join(se)}}var z=A.indexOf("#");z!==-1&&(this.hash=A.substr(z),A=A.slice(0,z));var S=A.indexOf("?");if(S!==-1?(this.search=A.substr(S),this.query=A.substr(S+1),I&&(this.query=w.parse(this.query)),A=A.slice(0,S)):I&&(this.search="",this.query={}),A&&(this.pathname=A),y[j]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){G=this.pathname||"";var B=this.search||"";this.path=G+B}return this.href=this.format(),this},u.prototype.format=function(){var T=this.auth||"";T&&(T=(T=encodeURIComponent(T)).replace(/%3A/i,":"),T+="@");var I=this.protocol||"",D=this.pathname||"",X=this.hash||"",V=!1,E="";this.host?V=T+this.host:this.hostname&&(V=T+(this.hostname.indexOf(":")===-1?this.hostname:"["+this.hostname+"]"),this.port&&(V+=":"+this.port)),this.query&&o.isObject(this.query)&&Object.keys(this.query).length&&(E=w.stringify(this.query));var A=this.search||E&&"?"+E||"";return I&&I.substr(-1)!==":"&&(I+=":"),this.slashes||(!I||y[I])&&V!==!1?(V="//"+(V||""),D&&D.charAt(0)!=="/"&&(D="/"+D)):V||(V=""),X&&X.charAt(0)!=="#"&&(X="#"+X),A&&A.charAt(0)!=="?"&&(A="?"+A),I+V+(D=D.replace(/[?#]/g,function(C){return encodeURIComponent(C)}))+(A=A.replace("#","%23"))+X},u.prototype.resolve=function(T){return this.resolveObject(k(T,!1,!0)).format()},u.prototype.resolveObject=function(T){if(o.isString(T)){var I=new u;I.parse(T,!1,!0),T=I}for(var D=new u,X=Object.keys(this),V=0;V<X.length;V++){var E=X[V];D[E]=this[E]}if(D.hash=T.hash,T.href==="")return D.href=D.format(),D;if(T.slashes&&!T.protocol){for(var A=Object.keys(T),C=0;C<A.length;C++){var F=A[C];F!=="protocol"&&(D[F]=T[F])}return y[D.protocol]&&D.hostname&&!D.pathname&&(D.path=D.pathname="/"),D.href=D.format(),D}if(T.protocol&&T.protocol!==D.protocol){if(!y[T.protocol]){for(var j=Object.keys(T),P=0;P<j.length;P++){var J=j[P];D[J]=T[J]}return D.href=D.format(),D}if(D.protocol=T.protocol,T.host||x[T.protocol])D.pathname=T.pathname;else{for(var $=(T.pathname||"").split("/");$.length&&!(T.host=$.shift()););T.host||(T.host=""),T.hostname||(T.hostname=""),$[0]!==""&&$.unshift(""),$.length<2&&$.unshift(""),D.pathname=$.join("/")}if(D.search=T.search,D.query=T.query,D.host=T.host||"",D.auth=T.auth,D.hostname=T.hostname||T.host,D.port=T.port,D.pathname||D.search){var U=D.pathname||"",K=D.search||"";D.path=U+K}return D.slashes=D.slashes||T.slashes,D.href=D.format(),D}var L=D.pathname&&D.pathname.charAt(0)==="/",O=T.host||T.pathname&&T.pathname.charAt(0)==="/",H=O||L||D.host&&T.pathname,W=H,Z=D.pathname&&D.pathname.split("/")||[],re=($=T.pathname&&T.pathname.split("/")||[],D.protocol&&!y[D.protocol]);if(re&&(D.hostname="",D.port=null,D.host&&(Z[0]===""?Z[0]=D.host:Z.unshift(D.host)),D.host="",T.protocol&&(T.hostname=null,T.port=null,T.host&&($[0]===""?$[0]=T.host:$.unshift(T.host)),T.host=null),H=H&&($[0]===""||Z[0]==="")),O)D.host=T.host||T.host===""?T.host:D.host,D.hostname=T.hostname||T.hostname===""?T.hostname:D.hostname,D.search=T.search,D.query=T.query,Z=$;else if($.length)Z||(Z=[]),Z.pop(),Z=Z.concat($),D.search=T.search,D.query=T.query;else if(!o.isNullOrUndefined(T.search))return re&&(D.hostname=D.host=Z.shift(),(R=!!(D.host&&D.host.indexOf("@")>0)&&D.host.split("@"))&&(D.auth=R.shift(),D.host=D.hostname=R.shift())),D.search=T.search,D.query=T.query,o.isNull(D.pathname)&&o.isNull(D.search)||(D.path=(D.pathname?D.pathname:"")+(D.search?D.search:"")),D.href=D.format(),D;if(!Z.length)return D.pathname=null,D.search?D.path="/"+D.search:D.path=null,D.href=D.format(),D;for(var oe=Z.slice(-1)[0],ae=(D.host||T.host||Z.length>1)&&(oe==="."||oe==="..")||oe==="",b=0,_=Z.length;_>=0;_--)(oe=Z[_])==="."?Z.splice(_,1):oe===".."?(Z.splice(_,1),b++):b&&(Z.splice(_,1),b--);if(!H&&!W)for(;b--;b)Z.unshift("..");!H||Z[0]===""||Z[0]&&Z[0].charAt(0)==="/"||Z.unshift(""),ae&&Z.join("/").substr(-1)!=="/"&&Z.push("");var R,G=Z[0]===""||Z[0]&&Z[0].charAt(0)==="/";return re&&(D.hostname=D.host=G?"":Z.length?Z.shift():"",(R=!!(D.host&&D.host.indexOf("@")>0)&&D.host.split("@"))&&(D.auth=R.shift(),D.host=D.hostname=R.shift())),(H=H||D.host&&Z.length)&&!G&&Z.unshift(""),Z.length?D.pathname=Z.join("/"):(D.pathname=null,D.path=null),o.isNull(D.pathname)&&o.isNull(D.search)||(D.path=(D.pathname?D.pathname:"")+(D.search?D.search:"")),D.auth=T.auth||D.auth,D.slashes=D.slashes||T.slashes,D.href=D.format(),D},u.prototype.parseHost=function(){var T=this.host,I=s.exec(T);I&&((I=I[0])!==":"&&(this.port=I.substr(1)),T=T.substr(0,T.length-I.length)),T&&(this.hostname=T)}},{"./util":77,punycode:51,querystring:54}],77:[function(t,n,l){n.exports={isString:function(a){return typeof a=="string"},isObject:function(a){return typeof a=="object"&&a!==null},isNull:function(a){return a===null},isNullOrUndefined:function(a){return a==null}}},{}],78:[function(t,n,l){(function(a){(function(){function o(u){try{if(!a.localStorage)return!1}catch(s){return!1}var p=a.localStorage[u];return p!=null&&String(p).toLowerCase()==="true"}n.exports=function(u,p){if(o("noDeprecation"))return u;var s=!1;return function(){if(!s){if(o("throwDeprecation"))throw new Error(p);o("traceDeprecation")?console.trace(p):console.warn(p),s=!0}return u.apply(this,arguments)}}}).call(this)}).call(this,typeof xe!="undefined"?xe:typeof self!="undefined"?self:typeof window!="undefined"?window:{})},{}],79:[function(t,n,l){n.exports=function a(o,u){if(o&&u)return a(o)(u);if(typeof o!="function")throw new TypeError("need wrapper function");return Object.keys(o).forEach(function(s){p[s]=o[s]}),p;function p(){for(var s=new Array(arguments.length),i=0;i<s.length;i++)s[i]=arguments[i];var d=o.apply(this,s),c=s[s.length-1];return typeof d=="function"&&d!==c&&Object.keys(c).forEach(function(f){d[f]=c[f]}),d}}},{}],80:[function(t,n,l){n.exports=function(){throw new Error("ws does not work in the browser. Browser clients must use the native WebSocket object")}},{}],81:[function(t,n,l){n.exports=function(){for(var o={},u=0;u<arguments.length;u++){var p=arguments[u];for(var s in p)a.call(p,s)&&(o[s]=p[s])}return o};var a=Object.prototype.hasOwnProperty},{}],82:[function(t,n,l){n.exports=function(a){a.prototype[Symbol.iterator]=function*(){for(let o=this.head;o;o=o.next)yield o.value}}},{}],83:[function(t,n,l){function a(i){var d=this;if(d instanceof a||(d=new a),d.tail=null,d.head=null,d.length=0,i&&typeof i.forEach=="function")i.forEach(function(h){d.push(h)});else if(arguments.length>0)for(var c=0,f=arguments.length;c<f;c++)d.push(arguments[c]);return d}function o(i,d,c){var f=d===i.head?new s(c,null,d,i):new s(c,d,d.next,i);return f.next===null&&(i.tail=f),f.prev===null&&(i.head=f),i.length++,f}function u(i,d){i.tail=new s(d,i.tail,null,i),i.head||(i.head=i.tail),i.length++}function p(i,d){i.head=new s(d,null,i.head,i),i.tail||(i.tail=i.head),i.length++}function s(i,d,c,f){if(!(this instanceof s))return new s(i,d,c,f);this.list=f,this.value=i,d?(d.next=this,this.prev=d):this.prev=null,c?(c.prev=this,this.next=c):this.next=null}n.exports=a,a.Node=s,a.create=a,a.prototype.removeNode=function(i){if(i.list!==this)throw new Error("removing node which does not belong to this list");var d=i.next,c=i.prev;return d&&(d.prev=c),c&&(c.next=d),i===this.head&&(this.head=d),i===this.tail&&(this.tail=c),i.list.length--,i.next=null,i.prev=null,i.list=null,d},a.prototype.unshiftNode=function(i){if(i!==this.head){i.list&&i.list.removeNode(i);var d=this.head;i.list=this,i.next=d,d&&(d.prev=i),this.head=i,this.tail||(this.tail=i),this.length++}},a.prototype.pushNode=function(i){if(i!==this.tail){i.list&&i.list.removeNode(i);var d=this.tail;i.list=this,i.prev=d,d&&(d.next=i),this.tail=i,this.head||(this.head=i),this.length++}},a.prototype.push=function(){for(var i=0,d=arguments.length;i<d;i++)u(this,arguments[i]);return this.length},a.prototype.unshift=function(){for(var i=0,d=arguments.length;i<d;i++)p(this,arguments[i]);return this.length},a.prototype.pop=function(){if(this.tail){var i=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,i}},a.prototype.shift=function(){if(this.head){var i=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,i}},a.prototype.forEach=function(i,d){d=d||this;for(var c=this.head,f=0;c!==null;f++)i.call(d,c.value,f,this),c=c.next},a.prototype.forEachReverse=function(i,d){d=d||this;for(var c=this.tail,f=this.length-1;c!==null;f--)i.call(d,c.value,f,this),c=c.prev},a.prototype.get=function(i){for(var d=0,c=this.head;c!==null&&d<i;d++)c=c.next;if(d===i&&c!==null)return c.value},a.prototype.getReverse=function(i){for(var d=0,c=this.tail;c!==null&&d<i;d++)c=c.prev;if(d===i&&c!==null)return c.value},a.prototype.map=function(i,d){d=d||this;for(var c=new a,f=this.head;f!==null;)c.push(i.call(d,f.value,this)),f=f.next;return c},a.prototype.mapReverse=function(i,d){d=d||this;for(var c=new a,f=this.tail;f!==null;)c.push(i.call(d,f.value,this)),f=f.prev;return c},a.prototype.reduce=function(i,d){var c,f=this.head;if(arguments.length>1)c=d;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");f=this.head.next,c=this.head.value}for(var h=0;f!==null;h++)c=i(c,f.value,h),f=f.next;return c},a.prototype.reduceReverse=function(i,d){var c,f=this.tail;if(arguments.length>1)c=d;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");f=this.tail.prev,c=this.tail.value}for(var h=this.length-1;f!==null;h--)c=i(c,f.value,h),f=f.prev;return c},a.prototype.toArray=function(){for(var i=new Array(this.length),d=0,c=this.head;c!==null;d++)i[d]=c.value,c=c.next;return i},a.prototype.toArrayReverse=function(){for(var i=new Array(this.length),d=0,c=this.tail;c!==null;d++)i[d]=c.value,c=c.prev;return i},a.prototype.slice=function(i,d){(d=d||this.length)<0&&(d+=this.length),(i=i||0)<0&&(i+=this.length);var c=new a;if(d<i||d<0)return c;i<0&&(i=0),d>this.length&&(d=this.length);for(var f=0,h=this.head;h!==null&&f<i;f++)h=h.next;for(;h!==null&&f<d;f++,h=h.next)c.push(h.value);return c},a.prototype.sliceReverse=function(i,d){(d=d||this.length)<0&&(d+=this.length),(i=i||0)<0&&(i+=this.length);var c=new a;if(d<i||d<0)return c;i<0&&(i=0),d>this.length&&(d=this.length);for(var f=this.length,h=this.tail;h!==null&&f>d;f--)h=h.prev;for(;h!==null&&f>i;f--,h=h.prev)c.push(h.value);return c},a.prototype.splice=function(i,d,...c){i>this.length&&(i=this.length-1),i<0&&(i=this.length+i);for(var f=0,h=this.head;h!==null&&f<i;f++)h=h.next;var v=[];for(f=0;h&&f<d;f++)v.push(h.value),h=this.removeNode(h);for(h===null&&(h=this.tail),h!==this.head&&h!==this.tail&&(h=h.prev),f=0;f<c.length;f++)h=o(this,h,c[f]);return v},a.prototype.reverse=function(){for(var i=this.head,d=this.tail,c=i;c!==null;c=c.prev){var f=c.prev;c.prev=c.next,c.next=f}return this.head=d,this.tail=i,this};try{t("./iterator.js")(a)}catch(i){}},{"./iterator.js":82}]},{},[12])(12)})})(Wy);function Ky(e,r){var o,u;let t=r.payload.topicName,n=r.payload.message,l=r.payload.notifyTime,a=`<div style="padding:0px 12px 0px 0px;width:300px;">
41
41
  <div style="display:flex;height: 20px;justify-content: space-between">
42
42
  <div style="color: #000000d9;
43
43
  font-size: 14px;
44
- font-weight: 700;">${t}</div><div style="color: #00000073;">${Xy(l)}</div>
44
+ font-weight: 700;">${t}</div><div style="color: #00000073;">${Gy(l)}</div>
45
45
  </div>
46
46
  <span>${n}</span>
47
- </div>`;e.message({content:a,duration:0,closeBtn:!0,placement:"right",height:75}),(o=r.payload.detail)!=null&&o.alarmConfigId&&Zy(e,(u=r.payload.detail)==null?void 0:u.alarmConfigId)}globalThis.doWarning=Yy;function Xy(e){const r=new Date(e),t=r.getFullYear(),n=(r.getMonth()+1+"").padStart(2,"0"),l=(r.getDate()+"").padStart(2,"0"),a=(r.getHours()+"").padStart(2,"0"),o=(r.getMinutes()+"").padStart(2,"0"),u=(r.getSeconds()+"").padStart(2,"0");return t+"-"+n+"-"+l+" "+a+":"+o+":"+u}function Zy(e,r){return je(this,null,function*(){const t=yield fetch(`/api/alarm/config/${r}`,{headers:{"X-Access-Token":localStorage.getItem("X-Access-Token")||new URLSearchParams(location.search).get("X-Access-Token")||"","Content-Type":"application/json"},method:"GET"});if(t.ok){let n=yield t.json();n.result.media&&K0(e,n.result.media,n.result.playTimes)}})}function K0(e,r,t){if(e.store.globalAudio||(e.store.globalAudio=document.createElement("audio")),e.store.globalAudio.src=r,e.store.globalAudio.play(),t===-1)e.store.globalAudio.loop=!0;else{e.store.globalAudio.loop=!1;let n=0;e.store.globalAudio.onended=()=>{n++,n<t&&e.store.globalAudio.play()}}}globalThis.createAudio=K0;const Jy="original_meta2d";function eg(){return localStorage.removeItem(Jy)}let Or={};const tg=e=>{const r=document.querySelectorAll("video");let t=null;if(r.forEach(l=>{l.getAttribute("src")===e.video&&(t=l)}),!t)return;t.setAttribute("muted","muted"),t.setAttribute("autoplay","autoplay"),t.setAttribute("loop","loop"),t.setAttribute("crossorigin",""),t.setAttribute("controls",""),t.style.display="none",t.parentElement.style.border="2px solid #ffc878";const n=new JessibucaPro({container:t.parentElement,background:"",hasControl:!1,controlAutoHide:!0,checkFirstIFrame:!0,debug:!1,decoder:"./wasm/decoder-pro.js",forceNoOffscreen:!0,hotKey:!1,hasAudio:!1,hasVideo:!0,hiddenAutoPause:!1,isFlv:!0,isResize:!1,isNotMute:!0,loadingIcon:!0,loadingText:"加载中...",networkDelayTimeoutReplay:!1,playbackForwardMaxRateDecodeIFrame:8,showBandwidth:!1,showPerformance:!1,syncAudioAndVideo:!0,supportDblclickFullscreen:!1,timeout:10,useMSE:!0,useWCS:!1,useSIMD:!0,useVideoRender:!0,useCanvasRender:!1,videoBuffer:.2,videoBufferDelay:1});return e.autoPlay&&e.streamUrl&&n.play(e.streamUrl),Or[e.id]=n,n},rg=()=>{Object.keys(Or).forEach(e=>{Or[e].destroy(),Or[e]=null}),Or={}},ba=(e,r)=>{const t=e.__vccOpts||e;for(const[n,l]of r)t[n]=l;return t},ng={class:"sy-empty"},ig={key:1,class:"sy-empty-picture"},og={class:"sy-empty-description"},ag=Object.assign({name:"SyEmpty"},{__name:"index",props:{image:{type:String,default:"empty"},imageSize:{type:Number,default:80},description:{type:String,default:"暂无数据"},onlyText:{type:Boolean,default:!1}},setup(e){N.useCssVars(l=>({dbdd1bf2:n.value.width,d36455f4:n.value.height}));const r=e,t=N.computed(()=>({"font-size":r.imageSize?`${r.imageSize}px`:"80px"})),n=N.computed(()=>r.imageSize?{width:r.imageSize*1.2+"px",height:r.imageSize+"px"}:{width:"187px",height:"144px"});return(l,a)=>{const o=N.resolveComponent("SyIcon"),u=N.resolveComponent("el-icon");return N.openBlock(),N.createElementBlock("div",ng,[e.image!=="empty"?(N.openBlock(),N.createElementBlock("span",{key:0,class:"sy-empty-image",style:N.normalizeStyle(t.value)},[e.image!=="loading"?(N.openBlock(),N.createBlock(o,{key:0,name:e.image,gradient:""},null,8,["name"])):(N.openBlock(),N.createBlock(u,{key:1,class:"is-loading",style:{color:"#1671d4"}},{default:N.withCtx(()=>[N.createVNode(N.unref(S0))]),_:1}))],4)):e.onlyText?N.createCommentVNode("",!0):(N.openBlock(),N.createElementBlock("span",ig)),N.createElementVNode("div",og,[N.createElementVNode("p",null,N.toDisplayString(e.description),1)])])}}}),sg=ba(ag,[["__scopeId","data-v-c5e7d407"]]),lg=Object.assign({name:"Meta2dEditor"},{__name:"index",props:{url:{type:String,default:""},data:{type:Object,default:()=>{}},local:{type:Boolean,default:!1},preview:{type:Boolean,default:!1},devConfig:{type:Object,default:()=>({isDev:!1,devServerUrl:"",devServerPort:8443})}},emits:["loaded","load-error"],setup(e,{expose:r,emit:t}){const n=t,l=e,a=N.ref(null),o=N.shallowRef(),u=N.computed(()=>!!(l.data||l.url));N.watch(()=>[l.data,l.url],()=>{u.value&&s()});let p=N.ref(!0);function s(){return je(this,null,function*(){try{if(p.value=!0,yield N.nextTick(),!a.value){console.error("未找到meta2d元素!");return}let g=null;if(l.data?g=l.data:l.url&&(g=yield v()),!g||!g.data){p.value=!1,console.log("图纸数据为空"),n("load-error");return}const x=g.options||{background:"#eee",disableAnchor:!1};if(o.value&&(o.value.destroy(!0),o.value=null),!a.value){console.error("Meta2D 容器元素不可用");return}o.value=new Pe.Meta2d(a.value,he({},x)),x.visibleLevel&&o.value.scale(x.visibleLevel),i(),d(),yield c(g.data),o.value.render(),f(),setTimeout(()=>{window.meta2dTools&&window.registerToolsNew()},1e3),n("loaded",o.value)}catch(g){console.error("初始化编辑器失败:",g)}})}function i(){if(!o.value)return;new Ky({}).initPlugin(o.value,"mindNode",{})}function d(){Pe.register(Oc.classPens()),Pe.register(Fa.flowPens()),Pe.registerAnchors(Fa.flowAnchors()),Pe.register(Ia.sequencePens()),Pe.registerCanvasDraw(Ia.sequencePensbyCtx()),Pe.register(Da.activityDiagram()),Pe.registerCanvasDraw(Da.activityDiagramByCtx()),Pe.registerCanvasDraw(Rc.formPens()),Pe.registerCanvasDraw(Pc.chartsPens()),Pe.register(xi.ftaPens()),Pe.registerAnchors(xi.ftaAnchors()),Pe.registerCanvasDraw(xi.ftaPensbyCtx())}function c(g){if(o.value){if(typeof g.locked=="undefined"&&(g.locked=0),g.bkImage&&o.value.setBackgroundImage(g.bkImage),g.pens&&g.pens.length>0){const x=[];g.pens.forEach(k=>{k.name==="video"&&k.streamUrl?x.push(k):k.name==="image"&&k.image&&(k.image=Wy(k.image,l.devConfig))}),x.length>0&&setTimeout(()=>{x.forEach(k=>{tg(k)})},500);const y=window.meta.graph.penCountThreshold||2e3;g.pens.length>y&&g.scale&&g.pens.forEach(k=>{const T=k.visibleLevel;T!==void 0?(k.visible=g.scale>=T,k.visible||(k.disabled=!0,k.locked=Pe.LockState.Disable)):(k.visible=!0,k.disabled=!1,k.locked=Pe.LockState.None)})}o.value.open(g)}}function f(){o.value&&o.value.on("scale",h)}const h=$n.debounce(g=>{var x,y,w,k;try{if(!o.value)return;Ho.emit("graph-scale",g);let T=o.value.store.data.pens;const I=window.meta.graph.penCountThreshold||2e3,D=T.length>I;for(let X=0;X<T.length;X++){const V=T[X];if([Se.VIDEO_STREAM,Se.MP4].includes(V.penType)){if(((y=(x=cr[V.id])==null?void 0:x.children)==null?void 0:y.length)===3){let E=cr[V.id].children[0],A=cr[V.id].children[2];E.style.width=A.currentTime/A.duration*V.calculative.worldRect.width+"px"}else if(((k=(w=cr[V.id])==null?void 0:w.children)==null?void 0:k.length)===2){let E=cr[V.id].children[0],A=cr[V.id].children[1];E.style.width=A.currentTime/A.duration*V.calculative.worldRect.width+"px"}}if(D){const E=V.visibleLevel!==void 0?g>=V.visibleLevel:!0;o.value._setValue({id:V.id,visible:E,disabled:!E,locked:E?Pe.LockState.None:Pe.LockState.Disable})}}o.value.render()}catch(T){console.error("处理缩放失败:",T)}},500);function v(){return je(this,null,function*(){if(!l.url)return st.error("图纸路径为空!"),null;try{return(yield jo.getGraphApi(l.url,{local:l.local}))||null}catch(g){return null}})}const m=()=>{o.value&&o.value.resize()};return N.onMounted(()=>{u.value&&s(),window.document.addEventListener("resize",m)}),N.onUnmounted(()=>{rg(),eg(),o.value&&(l.preview?(tu.clearLineCross(),o.value.destroy(!0)):o.value.off("scale",h)),window.document.removeEventListener("resize",m)}),r({stage:o}),(g,x)=>(N.openBlock(),N.createElementBlock("div",{ref_key:"meta2dRef",ref:a,class:"meta2d-editor"},[N.unref(p)?N.createCommentVNode("",!0):(N.openBlock(),N.createBlock(sg,{key:0,class:"meta2d-empty",description:"图纸不存在"}))],512))}}),ug=ba(lg,[["__scopeId","data-v-d97cf5a2"]]),cg={class:"preview-container"},fg={key:0,class:"back-btn"},hg=Object.assign({name:"Meta2dPreview"},{__name:"index",props:{url:{type:String,default:""},gid:{type:String,default:""},data:{type:Object,default:null},local:{type:Boolean,default:!1},isInitData:{type:Boolean,default:!0},config:{type:Object,default:()=>({socketUrl:As,stationIdKey:Nl,enableToken:!0,userTokenKey:Pl,messageDelay:200,debounceDelay:100,enableAutoFit:!0,enableWebSocket:!0,graphSocket:_s.GRAPH.SOCKET})},showMap:{type:Boolean,default:!1},isFactory:{type:Boolean,default:!1},apiInstance:{type:Object,default:()=>jo},mittInstance:{type:Object,default:()=>Ho},customCallbacks:{type:Object,default:()=>({})},errorHandler:{type:Object,default:()=>({callback:null,showMessage:!0})},devConfig:{type:Object,default:()=>({isDev:!1,devServerUrl:"",devServerPort:8443})}},emits:["error","loaded","custom-msg","socket-msg"],setup(e,{expose:r,emit:t}){const n=t,l=e;let a=N.ref(!1),o=N.ref(""),u=N.ref(!1);const p=N.ref(null),s=N.ref(""),i=N.ref(!1),d=N.computed(()=>{var P;return(P=p.value)==null?void 0:P.stage}),c=N.computed(()=>{var P;return(P=d.value)==null?void 0:P.store}),f=N.computed(()=>he({socketUrl:As,stationIdKey:Nl,enableToken:!0,userTokenKey:Pl,messageDelay:200,debounceDelay:100,enableAutoFit:!0,fitPadding:10,enableWebSocket:!0,graphSocket:_s.GRAPH.SOCKET},l.config)),h=()=>l.apiInstance||jo,v=()=>l.mittInstance||Ho,m=(P,J="")=>{const $={error:P,message:J,timestamp:new Date().toISOString()};n("error",$),l.errorHandler.callback?l.errorHandler.callback($):l.errorHandler.showMessage&&st&&st.error(`${J}: ${P.message||P}`)},g=()=>{o.value&&(s.value=o.value,i.value=u.value)},x=P=>{var J,$,U,K,L,O;try{if(!P)return;if((J=P==null?void 0:P.includes)!=null&&J.call(P,"token 必传"))return st.warning(P);const H=typeof P=="string"?JSON.parse(P):P;if((H==null?void 0:H.data)==="服务错误"||(U=($=H==null?void 0:H.data)==null?void 0:$.includes)!=null&&U.call($,"token is expired"))return st.warning(H.data);switch(n("socket-msg",H),H.action){case Es.ACPOINT.YCVALUE:case Es.ACPOINT.YXVALUE:if((K=H==null?void 0:H.data)!=null&&K.point_id){const W=d.value.find(H.data.point_id);W&&C(W,H.data)}break;default:if(((L=H.data)==null?void 0:L.length)>0){const W=setTimeout(()=>{clearTimeout(W),d.value&&H.data.forEach(Z=>{const re=d.value.find(Z.dataId||Z.point_id);C(re,Z)})},f.value.messageDelay);l.customCallbacks.onWebSocketMessage&&l.customCallbacks.onWebSocketMessage(H),(O=window.customSocketFn)==null||O.call(window,P)}break}return!0}catch(H){return m(H,"WebSocket消息处理"),!0}},y=P=>je(this,null,function*(){try{if(P.msgName)switch(P.msgName){case nt.CHANGE_GRAPH:case nt.NOTIFY_DIALOG:w(P);break}else w(P);n("custom-msg",P),l.customCallbacks.onCustomMessage&&l.customCallbacks.onCustomMessage(P)}catch(J){m(J,"自定义消息处理")}}),w=P=>{var J;if(P.params){const $=JSON.parse(P.params);switch($.action){case nt.CHANGE_GRAPH:($==null?void 0:$.data)!=="图纸id"?(o.value=s.value,u.value=i.value,a.value=$.isBack,(J=$==null?void 0:$.data)!=null&&J.startsWith("/")?(s.value=$==null?void 0:$.data,i.value=!0):(i.value=!1,T($.data))):console.warn("切换图纸信息为空");break;case nt.NOTIFY_DIALOG:$.msg!=="通知内容"?Uy(he({message:$.msg},$)):console.warn("通知内容为空");break}}},k=P=>{var J,$,U;try{n("loaded",P);const K=D(),L=f.value,O=Rl.getSession(L.stationIdKey),H=Rl.getSession(L.userTokenKey);L.enableWebSocket&&O&&H&&(($=(J=P.store)==null?void 0:J.data)!=null&&$.websocket?((U=P.store.data.websocket)!=null&&U.includes("station_id")||(P.store.data.websocket=`${P.store.data.websocket}?station_id=${O}`),L.enableToken?P.store.data.websocketProtocols=H:P.store.data.websocketProtocols=void 0,P.closeSocket(),P.connectSocket()):(P.store.data.websocket=`${L.socketUrl}?station_id=${O}`,L.enableToken?P.store.data.websocketProtocols=H:P.store.data.websocketProtocols=void 0,P.connectWebsocket())),(l.showMap||K.showMap==="true")&&P.showMap(),P.setRule({rule:!1}),P.setOptions({disableRuleLine:!0}),P.setGrid({grid:!1}),P.lock(Pe.LockState.DisableEdit),E().forEach(Z=>{var re;(re=Z==null?void 0:Z.events)!=null&&re.length?X({id:Z.id,locked:1},!1):X({id:Z.id,locked:10},!1)}),P.render(),L.enableAutoFit&&P.fitView(!0,L.fitPadding),Object.values(nt).forEach(Z=>{P.on(Z,re=>y(_e(he({},re),{msgName:Z})))}),P&&(P.socketFn=x),l.customCallbacks.onStageLoaded&&l.customCallbacks.onStageLoaded(P),l.isInitData&&I(P)}catch(K){m(K,"图纸加载完成处理")}},T=P=>je(this,null,function*(){var J;try{if(l.url){s.value=l.url,i.value=l.local;return}const $=D();if(P=P||l.gid||$.id,$.local==="true"&&(i.value=!0),P){const U=h();if(U&&U.getCommonApi){const K=yield U.getCommonApi(l.isFactory?"graph":"floorplan",{guid:P});if((J=K.data)!=null&&J.length)s.value=K.data[0].path,l.customCallbacks.onGraphLoaded&&l.customCallbacks.onGraphLoaded(s.value);else{const L="未找到图纸!";m(new Error(L),"获取图纸数据")}}else m(new Error("API实例不可用"),"初始化图纸数据!")}else s.value=l.url,i.value=l.local}catch($){m($,"获取图纸数据失败")}}),I=P=>je(this,null,function*(){var J,$,U;if(P){let K=[],L=[],O=[];const H=P.store.data.pens;for(let W=0;W<H.length;W++){const Z=H[W];Z.bindDataId&&(J=Z.form)!=null&&J.length&&Z.form.forEach(re=>{if(re.dataIds.dataId)switch(re.dataIds.dataType){case Vi.YC:K.push(_e(he({},re),{nodeName:re.dataIds.name,penId:Z.id,penName:Z.penName}));break;case Vi.YX:L.push(_e(he({},re),{nodeName:re.dataIds.name,penId:Z.id,penName:Z.penName}));break;case Vi.POINT:O.push(_e(he({},re),{nodeName:re.dataIds.name,penId:Z.id,penName:Z.penName}));break}})}if(K.length){const W=h();if(W&&W.postCommonApi){const Z=yield W.postCommonApi("queryrealtimepoint",{point_id:K.map(re=>{var oe;return(oe=re==null?void 0:re.dataIds)==null?void 0:oe.dataId}).join(",")});($=Z==null?void 0:Z.data)!=null&&$.length&&Z.data.forEach(re=>{const oe=P.find(re.guid);C(oe,_e(he({},re),{value:Ss(re.value)?Number(re.value):re.value,value_disp:re.value_disp,alarm_value:re.alarm_value,point_id:re.guid}))})}}if(L.length){const W=h();if(W&&W.postCommonApi){const Z=yield W.postCommonApi("queryrealtimepoint",{point_id:L.map(re=>{var oe;return(oe=re==null?void 0:re.dataIds)==null?void 0:oe.dataId}).join(",")});(U=Z==null?void 0:Z.data)!=null&&U.length&&Z.data.forEach(re=>{const oe=P.find(re.guid);C(oe,_e(he({},re),{value:Ss(re.value)?Number(re.value):re.value,value_disp:re.value_disp,alarm_value:re.alarm_value,point_id:re.guid}))})}}}}),D=()=>{var U;const P={},J=((U=window.location.href.split("?"))==null?void 0:U[1])||"",$=new URLSearchParams(J);for(const[K,L]of $.entries())P[K]=L;return P},X=(P,J=!0)=>{if(d.value)return d.value.setValue(P,{render:J})},V=()=>d.value,E=()=>{var P,J;return((J=(P=c.value)==null?void 0:P.data)==null?void 0:J.pens)||[]},A=()=>Se,C=(()=>{let P=null;const J=new Map,$=new Map,U=L=>{var H;if(!((H=L.children)!=null&&H.length))return[];const O=L.id||"";if(!O)return[];if(!$.has(O)&&c.value){const W=Pe.getAllChildren(L,c.value);$.set(O,W)}return $.get(O)||[]},K=()=>{if(J.size===0||!d.value||!c.value)return;const L=[],O=[],H=c.value.animates;J.forEach(({pen:W,dataItem:Z,formKey:re})=>{switch(re){case"showChild":X({id:W.id,showChild:Z.value},!1);break;case"text":X({id:W.id,text:Z.value_disp||Z.value},!1);break;case"light_plate":{const oe=Z.value===-1||Ol(Z)?"#999999":W0[Z.value!==void 0?Z.value:Z.alarm_value],ae=Z.value===-1||Ol(Z)?"#cccccc":V0[Z.value!==void 0?Z.value:Z.alarm_value];X({id:W.id,textColor:oe,background:ae},!1)}break;case"point_value":W.penType===Se.POINT_VALUE&&U(W).forEach(ae=>{ae.name==="text"&&X({id:ae.id,text:Z.value},!1)});break;case"online_state":{let oe=Z.value?void 0:"contrast(0%)";X({id:W.id,filter:oe},!1),U(W).forEach(b=>{X({id:b.id,filter:oe},!1)})}break;case"charged_state":{const oe=Z.value===a1.OFFLINE?"contrast(0%)":void 0;oe!==W.filter&&(X({id:W.id,filter:oe},!1),U(W).forEach(b=>{X({id:b.id,filter:oe},!1)}))}break;case"electric_direction":Z.value===s1.STOP?H!=null&&H.has(W)&&O.push(W):!!Z.value!==W.animateReverse&&(X({id:W.id,animateReverse:!!Z.value},!1),H!=null&&H.has(W)||L.push(W));break;case"electric_size":{const oe=l1[Z.value];oe!==void 0&&oe!==W.lineWidth&&X({id:W.id,lineWidth:oe},!1)}break;default:X({id:W.id,[re]:Z.value},!1);break}}),O.length>0&&d.value.stopAnimate(O),L.length>0&&d.value.startAnimate(L),J.clear(),d.value.render()};return(L,O)=>{L!=null&&L.length&&(L.forEach(H=>{const W=H.form;W!=null&&W.length&&W.forEach(Z=>{if(!(Array.isArray(Z.dataIds)?Z.dataIds:[Z.dataIds]).some(b=>(b==null?void 0:b.dataId)&&((b==null?void 0:b.dataId)===O.dataId||(b==null?void 0:b.dataId)===O.point_id)))return;const ae=`${H.id}-${Z.key}`;J.set(ae,{pen:H,dataItem:O,formKey:Z.key})})}),P&&clearTimeout(P),P=setTimeout(()=>{K(),P=null},f.value.debounceDelay))}})(),F=P=>{if(d.value){for(let J=0;J<P.length;J++){const $=P[J],U=d.value.find($.dataId);C(U,$)}d.value.render(),l.customCallbacks.onBatchUpdate&&l.customCallbacks.onBatchUpdate(P)}},j=(P,J=!1)=>{if(!d.value)return;const $=E();for(let U=0;U<$.length;U++){const K=$[U];let L=!1;J?L=P===K.dataProp:L=P===5?!0:K.dataProp<=P,X({id:K.id,visible:L},!1)}d.value.fitView(),d.value.render(),l.customCallbacks.onLevelChange&&l.customCallbacks.onLevelChange(P,J)};return N.watch(()=>[l.url,l.isFactory,l.local,l.data,l.gid],()=>{T()}),N.watch(()=>l.showMap,P=>{d.value&&(P?d.value.showMap():d.value.hideMap())}),N.onMounted(()=>{const P=v();P&&P.on&&P.on(f.value.graphSocket,x),T()}),N.onUnmounted(()=>{const P=v();P&&P.off&&P.off(f.value.graphSocket,x)}),r({setValue:X,getStage:V,getAllPens:E,getCustomPenType:A,batchUpdatePen:F,handleLineCross:tu.handleLineCross,changeVisibleByLevel:j}),(P,J)=>(N.openBlock(),N.createElementBlock("div",cg,[N.createVNode(ug,{ref_key:"graphRef",ref:p,url:s.value,local:i.value,data:l.data,"dev-config":l.devConfig,preview:"",onLoaded:k},null,8,["url","local","data","dev-config"]),N.unref(a)?(N.openBlock(),N.createElementBlock("div",fg,[N.createVNode(N.unref(cy),{type:"primary",onClick:g},{default:N.withCtx(()=>[...J[0]||(J[0]=[N.createTextVNode("返回",-1)])]),_:1})])):N.createCommentVNode("",!0)]))}}),Hr=ba(hg,[["__scopeId","data-v-2a1fecdf"]]);Hr.name||(Hr.name="SyGraph");const pg=e=>{e.component(Hr.name||"SyGraph",Hr)},dg={install:pg};exports.SyGraph=Hr;exports.default=dg;
47
+ </div>`;e.message({content:a,duration:0,closeBtn:!0,placement:"right",height:75}),(o=r.payload.detail)!=null&&o.alarmConfigId&&Qy(e,(u=r.payload.detail)==null?void 0:u.alarmConfigId)}globalThis.doWarning=Ky;function Gy(e){const r=new Date(e),t=r.getFullYear(),n=(r.getMonth()+1+"").padStart(2,"0"),l=(r.getDate()+"").padStart(2,"0"),a=(r.getHours()+"").padStart(2,"0"),o=(r.getMinutes()+"").padStart(2,"0"),u=(r.getSeconds()+"").padStart(2,"0");return t+"-"+n+"-"+l+" "+a+":"+o+":"+u}function Qy(e,r){return je(this,null,function*(){const t=yield fetch(`/api/alarm/config/${r}`,{headers:{"X-Access-Token":localStorage.getItem("X-Access-Token")||new URLSearchParams(location.search).get("X-Access-Token")||"","Content-Type":"application/json"},method:"GET"});if(t.ok){let n=yield t.json();n.result.media&&K0(e,n.result.media,n.result.playTimes)}})}function K0(e,r,t){if(e.store.globalAudio||(e.store.globalAudio=document.createElement("audio")),e.store.globalAudio.src=r,e.store.globalAudio.play(),t===-1)e.store.globalAudio.loop=!0;else{e.store.globalAudio.loop=!1;let n=0;e.store.globalAudio.onended=()=>{n++,n<t&&e.store.globalAudio.play()}}}globalThis.createAudio=K0;const Yy="original_meta2d";function Xy(){return localStorage.removeItem(Yy)}let Or={};const Zy=e=>{const r=document.querySelectorAll("video");let t=null;if(r.forEach(l=>{l.getAttribute("src")===e.video&&(t=l)}),!t)return;t.setAttribute("muted","muted"),t.setAttribute("autoplay","autoplay"),t.setAttribute("loop","loop"),t.setAttribute("crossorigin",""),t.setAttribute("controls",""),t.style.display="none",t.parentElement.style.border="2px solid #ffc878";const n=new JessibucaPro({container:t.parentElement,background:"",hasControl:!1,controlAutoHide:!0,checkFirstIFrame:!0,debug:!1,decoder:"./wasm/decoder-pro.js",forceNoOffscreen:!0,hotKey:!1,hasAudio:!1,hasVideo:!0,hiddenAutoPause:!1,isFlv:!0,isResize:!1,isNotMute:!0,loadingIcon:!0,loadingText:"加载中...",networkDelayTimeoutReplay:!1,playbackForwardMaxRateDecodeIFrame:8,showBandwidth:!1,showPerformance:!1,syncAudioAndVideo:!0,supportDblclickFullscreen:!1,timeout:10,useMSE:!0,useWCS:!1,useSIMD:!0,useVideoRender:!0,useCanvasRender:!1,videoBuffer:.2,videoBufferDelay:1});return e.autoPlay&&e.streamUrl&&n.play(e.streamUrl),Or[e.id]=n,n},Jy=()=>{Object.keys(Or).forEach(e=>{Or[e].destroy(),Or[e]=null}),Or={}},ba=(e,r)=>{const t=e.__vccOpts||e;for(const[n,l]of r)t[n]=l;return t},eg={class:"sy-empty"},tg={key:1,class:"sy-empty-picture"},rg={class:"sy-empty-description"},ng=Object.assign({name:"SyEmpty"},{__name:"index",props:{image:{type:String,default:"empty"},imageSize:{type:Number,default:80},description:{type:String,default:"暂无数据"},onlyText:{type:Boolean,default:!1}},setup(e){N.useCssVars(l=>({dbdd1bf2:n.value.width,d36455f4:n.value.height}));const r=e,t=N.computed(()=>({"font-size":r.imageSize?`${r.imageSize}px`:"80px"})),n=N.computed(()=>r.imageSize?{width:r.imageSize*1.2+"px",height:r.imageSize+"px"}:{width:"187px",height:"144px"});return(l,a)=>{const o=N.resolveComponent("SyIcon"),u=N.resolveComponent("el-icon");return N.openBlock(),N.createElementBlock("div",eg,[e.image!=="empty"?(N.openBlock(),N.createElementBlock("span",{key:0,class:"sy-empty-image",style:N.normalizeStyle(t.value)},[e.image!=="loading"?(N.openBlock(),N.createBlock(o,{key:0,name:e.image,gradient:""},null,8,["name"])):(N.openBlock(),N.createBlock(u,{key:1,class:"is-loading",style:{color:"#1671d4"}},{default:N.withCtx(()=>[N.createVNode(N.unref(S0))]),_:1}))],4)):e.onlyText?N.createCommentVNode("",!0):(N.openBlock(),N.createElementBlock("span",tg)),N.createElementVNode("div",rg,[N.createElementVNode("p",null,N.toDisplayString(e.description),1)])])}}}),ig=ba(ng,[["__scopeId","data-v-c5e7d407"]]),og=Object.assign({name:"Meta2dEditor"},{__name:"index",props:{url:{type:String,default:""},data:{type:Object,default:()=>{}},local:{type:Boolean,default:!1},preview:{type:Boolean,default:!1},devConfig:{type:Object,default:()=>({isDev:!1,devServerUrl:"",devServerPort:8443})}},emits:["loaded","load-error"],setup(e,{expose:r,emit:t}){const n=t,l=e,a=N.ref(null),o=N.shallowRef(),u=N.computed(()=>!!(l.data||l.url));N.watch(()=>[l.data,l.url],()=>{u.value&&s()});let p=N.ref(!0);function s(){return je(this,null,function*(){try{if(p.value=!0,yield N.nextTick(),!a.value){console.error("未找到meta2d元素!");return}let g=null;if(l.data?g=l.data:l.url&&(g=yield v()),!g||!g.data){p.value=!1,console.log("图纸数据为空"),n("load-error");return}const x=g.options||{background:"#eee",disableAnchor:!1};if(o.value&&(o.value.destroy(!0),o.value=null),!a.value){console.error("Meta2D 容器元素不可用");return}o.value=new Pe.Meta2d(a.value,he({},x)),x.visibleLevel&&o.value.scale(x.visibleLevel),i(),d(),yield c(g.data),o.value.render(),f(),setTimeout(()=>{window.meta2dTools&&window.registerToolsNew()},1e3),n("loaded",o.value)}catch(g){console.error("初始化编辑器失败:",g)}})}function i(){if(!o.value)return;new Hy({}).initPlugin(o.value,"mindNode",{})}function d(){Pe.register(Fc.classPens()),Pe.register(Fa.flowPens()),Pe.registerAnchors(Fa.flowAnchors()),Pe.register(Ia.sequencePens()),Pe.registerCanvasDraw(Ia.sequencePensbyCtx()),Pe.register(Da.activityDiagram()),Pe.registerCanvasDraw(Da.activityDiagramByCtx()),Pe.registerCanvasDraw(Tc.formPens()),Pe.registerCanvasDraw(Ic.chartsPens()),Pe.register(xi.ftaPens()),Pe.registerAnchors(xi.ftaAnchors()),Pe.registerCanvasDraw(xi.ftaPensbyCtx())}function c(g){if(o.value){if(typeof g.locked=="undefined"&&(g.locked=0),g.bkImage&&o.value.setBackgroundImage(g.bkImage),g.pens&&g.pens.length>0){const x=[];g.pens.forEach(k=>{k.name==="video"&&k.streamUrl?x.push(k):k.name==="image"&&k.image&&(k.image=jy(k.image,l.devConfig))}),x.length>0&&setTimeout(()=>{x.forEach(k=>{Zy(k)})},500);const y=window.meta.graph.penCountThreshold||2e3;g.pens.length>y&&g.scale&&g.pens.forEach(k=>{const T=k.visibleLevel;T!==void 0?(k.visible=g.scale>=T,k.visible||(k.disabled=!0,k.locked=Pe.LockState.Disable)):(k.visible=!0,k.disabled=!1,k.locked=Pe.LockState.None)})}o.value.open(g)}}function f(){o.value&&o.value.on("scale",h)}const h=$n.debounce(g=>{var x,y,w,k;try{if(!o.value)return;Ho.emit("graph-scale",g);let T=o.value.store.data.pens;const I=window.meta.graph.penCountThreshold||2e3,D=T.length>I;for(let X=0;X<T.length;X++){const V=T[X];if([Se.VIDEO_STREAM,Se.MP4].includes(V.penType)){if(((y=(x=cr[V.id])==null?void 0:x.children)==null?void 0:y.length)===3){let E=cr[V.id].children[0],A=cr[V.id].children[2];E.style.width=A.currentTime/A.duration*V.calculative.worldRect.width+"px"}else if(((k=(w=cr[V.id])==null?void 0:w.children)==null?void 0:k.length)===2){let E=cr[V.id].children[0],A=cr[V.id].children[1];E.style.width=A.currentTime/A.duration*V.calculative.worldRect.width+"px"}}if(D){const E=V.visibleLevel!==void 0?g>=V.visibleLevel:!0;o.value._setValue({id:V.id,visible:E,disabled:!E,locked:E?Pe.LockState.None:Pe.LockState.Disable})}}o.value.render()}catch(T){console.error("处理缩放失败:",T)}},500);function v(){return je(this,null,function*(){if(!l.url)return st.error("图纸路径为空!"),null;try{return(yield jo.getGraphApi(l.url,{local:l.local}))||null}catch(g){return null}})}const m=()=>{o.value&&o.value.resize()};return N.onMounted(()=>{u.value&&s(),window.document.addEventListener("resize",m)}),N.onUnmounted(()=>{Jy(),Xy(),o.value&&(l.preview?(tu.clearLineCross(),o.value.destroy(!0)):o.value.off("scale",h)),window.document.removeEventListener("resize",m)}),r({stage:o}),(g,x)=>(N.openBlock(),N.createElementBlock("div",{ref_key:"meta2dRef",ref:a,class:"meta2d-editor"},[N.unref(p)?N.createCommentVNode("",!0):(N.openBlock(),N.createBlock(ig,{key:0,class:"meta2d-empty",description:"图纸不存在"}))],512))}}),ag=ba(og,[["__scopeId","data-v-d97cf5a2"]]),sg={class:"preview-container"},lg={key:0,class:"back-btn"},ug=Object.assign({name:"Meta2dPreview"},{__name:"index",props:{url:{type:String,default:""},gid:{type:String,default:""},data:{type:Object,default:null},local:{type:Boolean,default:!1},isInitData:{type:Boolean,default:!0},config:{type:Object,default:()=>({socketUrl:As,stationIdKey:Nl,enableToken:!0,userTokenKey:Pl,messageDelay:200,debounceDelay:100,enableAutoFit:!0,enableWebSocket:!0,graphSocket:_s.GRAPH.SOCKET})},showMap:{type:Boolean,default:!1},isFactory:{type:Boolean,default:!1},apiInstance:{type:Object,default:()=>jo},mittInstance:{type:Object,default:()=>Ho},customCallbacks:{type:Object,default:()=>({})},errorHandler:{type:Object,default:()=>({callback:null,showMessage:!0})},devConfig:{type:Object,default:()=>({isDev:!1,devServerUrl:"",devServerPort:8443})}},emits:["error","loaded","custom-msg","socket-msg"],setup(e,{expose:r,emit:t}){const n=t,l=e;let a=N.ref(!1),o=N.ref(""),u=N.ref(!1);const p=N.ref(null),s=N.ref(""),i=N.ref(!1),d=N.computed(()=>{var P;return(P=p.value)==null?void 0:P.stage}),c=N.computed(()=>{var P;return(P=d.value)==null?void 0:P.store}),f=N.computed(()=>he({socketUrl:As,stationIdKey:Nl,enableToken:!0,userTokenKey:Pl,messageDelay:200,debounceDelay:100,enableAutoFit:!0,fitPadding:10,enableWebSocket:!0,graphSocket:_s.GRAPH.SOCKET},l.config)),h=()=>l.apiInstance||jo,v=()=>l.mittInstance||Ho,m=(P,J="")=>{const $={error:P,message:J,timestamp:new Date().toISOString()};n("error",$),l.errorHandler.callback?l.errorHandler.callback($):l.errorHandler.showMessage&&st&&st.error(`${J}: ${P.message||P}`)},g=()=>{o.value&&(s.value=o.value,i.value=u.value)},x=P=>{var J,$,U,K,L,O;try{if(!P)return;if((J=P==null?void 0:P.includes)!=null&&J.call(P,"token 必传"))return st.warning(P);const H=typeof P=="string"?JSON.parse(P):P;if((H==null?void 0:H.data)==="服务错误"||(U=($=H==null?void 0:H.data)==null?void 0:$.includes)!=null&&U.call($,"token is expired"))return st.warning(H.data);switch(n("socket-msg",H),H.action){case Es.ACPOINT.YCVALUE:case Es.ACPOINT.YXVALUE:if((K=H==null?void 0:H.data)!=null&&K.point_id){const W=d.value.find(H.data.point_id);W&&C(W,H.data)}break;default:if(((L=H.data)==null?void 0:L.length)>0){const W=setTimeout(()=>{clearTimeout(W),d.value&&H.data.forEach(Z=>{const re=d.value.find(Z.dataId||Z.point_id);C(re,Z)})},f.value.messageDelay);l.customCallbacks.onWebSocketMessage&&l.customCallbacks.onWebSocketMessage(H),(O=window.customSocketFn)==null||O.call(window,P)}break}return!0}catch(H){return m(H,"WebSocket消息处理"),!0}},y=P=>je(this,null,function*(){console.log("🚀 ~ onCustomMsg ~ msg:",P);try{if(P.msgName)switch(P.msgName){case nt.CHANGE_GRAPH:case nt.NOTIFY_DIALOG:w(P);break}else w(P);n("custom-msg",P),l.customCallbacks.onCustomMessage&&l.customCallbacks.onCustomMessage(P)}catch(J){m(J,"自定义消息处理")}}),w=P=>{var J;if(P.params){const $=JSON.parse(P.params);switch($.action){case nt.CHANGE_GRAPH:($==null?void 0:$.data)!=="图纸id"?(o.value=s.value,u.value=i.value,a.value=$.isBack,(J=$==null?void 0:$.data)!=null&&J.startsWith("/")?(s.value=$==null?void 0:$.data,i.value=!0):(i.value=!1,T($.data))):console.warn("切换图纸信息为空");break;case nt.NOTIFY_DIALOG:$.msg!=="通知内容"?Py(he({message:$.msg},$)):console.warn("通知内容为空");break}}},k=P=>{var J,$,U;try{n("loaded",P);const K=D(),L=f.value,O=Rl.getSession(L.stationIdKey),H=Rl.getSession(L.userTokenKey);L.enableWebSocket&&O&&H&&(($=(J=P.store)==null?void 0:J.data)!=null&&$.websocket?((U=P.store.data.websocket)!=null&&U.includes("station_id")||(P.store.data.websocket=`${P.store.data.websocket}?station_id=${O}`),L.enableToken?P.store.data.websocketProtocols=H:P.store.data.websocketProtocols=void 0,P.closeSocket(),P.connectSocket()):(P.store.data.websocket=`${L.socketUrl}?station_id=${O}`,L.enableToken?P.store.data.websocketProtocols=H:P.store.data.websocketProtocols=void 0,P.connectWebsocket())),(l.showMap||K.showMap==="true")&&P.showMap(),P.setRule({rule:!1}),P.setOptions({disableRuleLine:!0}),P.setGrid({grid:!1}),P.lock(Pe.LockState.DisableEdit),E().forEach(Z=>{var re;(re=Z==null?void 0:Z.events)!=null&&re.length?X({id:Z.id,locked:1},!1):X({id:Z.id,locked:10},!1)}),P.render(),L.enableAutoFit&&P.fitView(!0,L.fitPadding),Object.values(nt).forEach(Z=>{P.on(Z,re=>y(_e(he({},re),{msgName:Z})))}),P&&(P.socketFn=x),l.customCallbacks.onStageLoaded&&l.customCallbacks.onStageLoaded(P),l.isInitData&&I(P)}catch(K){m(K,"图纸加载完成处理")}},T=P=>je(this,null,function*(){var J;try{if(l.url){s.value=l.url,i.value=l.local;return}const $=D();if(P=P||l.gid||$.id,$.local==="true"&&(i.value=!0),P){const U=h();if(U&&U.getCommonApi){const K=yield U.getCommonApi(l.isFactory?"graph":"floorplan",{guid:P});if((J=K.data)!=null&&J.length)s.value=K.data[0].path,l.customCallbacks.onGraphLoaded&&l.customCallbacks.onGraphLoaded(s.value);else{const L="未找到图纸!";m(new Error(L),"获取图纸数据")}}else m(new Error("API实例不可用"),"初始化图纸数据!")}else s.value=l.url,i.value=l.local}catch($){m($,"获取图纸数据失败")}}),I=P=>je(this,null,function*(){var J,$,U;if(P){let K=[],L=[],O=[];const H=P.store.data.pens;for(let W=0;W<H.length;W++){const Z=H[W];Z.bindDataId&&(J=Z.form)!=null&&J.length&&Z.form.forEach(re=>{if(re.dataIds.dataId)switch(re.dataIds.dataType){case Vi.YC:K.push(_e(he({},re),{nodeName:re.dataIds.name,penId:Z.id,penName:Z.penName}));break;case Vi.YX:L.push(_e(he({},re),{nodeName:re.dataIds.name,penId:Z.id,penName:Z.penName}));break;case Vi.POINT:O.push(_e(he({},re),{nodeName:re.dataIds.name,penId:Z.id,penName:Z.penName}));break}})}if(K.length){const W=h();if(W&&W.postCommonApi){const Z=yield W.postCommonApi("queryrealtimepoint",{point_id:K.map(re=>{var oe;return(oe=re==null?void 0:re.dataIds)==null?void 0:oe.dataId}).join(",")});($=Z==null?void 0:Z.data)!=null&&$.length&&Z.data.forEach(re=>{const oe=P.find(re.guid);C(oe,_e(he({},re),{value:Ss(re.value)?Number(re.value):re.value,value_disp:re.value_disp,alarm_value:re.alarm_value,point_id:re.guid}))})}}if(L.length){const W=h();if(W&&W.postCommonApi){const Z=yield W.postCommonApi("queryrealtimepoint",{point_id:L.map(re=>{var oe;return(oe=re==null?void 0:re.dataIds)==null?void 0:oe.dataId}).join(",")});(U=Z==null?void 0:Z.data)!=null&&U.length&&Z.data.forEach(re=>{const oe=P.find(re.guid);C(oe,_e(he({},re),{value:Ss(re.value)?Number(re.value):re.value,value_disp:re.value_disp,alarm_value:re.alarm_value,point_id:re.guid}))})}}}}),D=()=>{var U;const P={},J=((U=window.location.href.split("?"))==null?void 0:U[1])||"",$=new URLSearchParams(J);for(const[K,L]of $.entries())P[K]=L;return P},X=(P,J=!0)=>{if(d.value)return d.value.setValue(P,{render:J})},V=()=>d.value,E=()=>{var P,J;return((J=(P=c.value)==null?void 0:P.data)==null?void 0:J.pens)||[]},A=()=>Se,C=(()=>{let P=null;const J=new Map,$=new Map,U=L=>{var H;if(!((H=L.children)!=null&&H.length))return[];const O=L.id||"";if(!O)return[];if(!$.has(O)&&c.value){const W=Pe.getAllChildren(L,c.value);$.set(O,W)}return $.get(O)||[]},K=()=>{if(J.size===0||!d.value||!c.value)return;const L=[],O=[],H=c.value.animates;J.forEach(({pen:W,dataItem:Z,formKey:re})=>{switch(re){case"showChild":X({id:W.id,showChild:Z.value},!1);break;case"text":X({id:W.id,text:Z.value_disp||Z.value},!1);break;case"light_plate":{const oe=Z.value===-1||Ol(Z)?"#999999":W0[Z.value!==void 0?Z.value:Z.alarm_value],ae=Z.value===-1||Ol(Z)?"#cccccc":V0[Z.value!==void 0?Z.value:Z.alarm_value];X({id:W.id,textColor:oe,background:ae},!1)}break;case"point_value":W.penType===Se.POINT_VALUE&&U(W).forEach(ae=>{ae.name==="text"&&X({id:ae.id,text:Z.value},!1)});break;case"online_state":{let oe=Z.value?void 0:"contrast(0%)";X({id:W.id,filter:oe},!1),U(W).forEach(b=>{X({id:b.id,filter:oe},!1)})}break;case"charged_state":{const oe=Z.value===r1.OFFLINE?"contrast(0%)":void 0;oe!==W.filter&&(X({id:W.id,filter:oe},!1),U(W).forEach(b=>{X({id:b.id,filter:oe},!1)}))}break;case"electric_direction":Z.value===n1.STOP?H!=null&&H.has(W)&&O.push(W):!!Z.value!==W.animateReverse&&(X({id:W.id,animateReverse:!!Z.value},!1),H!=null&&H.has(W)||L.push(W));break;case"electric_size":{const oe=i1[Z.value];oe!==void 0&&oe!==W.lineWidth&&X({id:W.id,lineWidth:oe},!1)}break;default:X({id:W.id,[re]:Z.value},!1);break}}),O.length>0&&d.value.stopAnimate(O),L.length>0&&d.value.startAnimate(L),J.clear(),d.value.render()};return(L,O)=>{L!=null&&L.length&&(L.forEach(H=>{const W=H.form;W!=null&&W.length&&W.forEach(Z=>{if(!(Array.isArray(Z.dataIds)?Z.dataIds:[Z.dataIds]).some(b=>(b==null?void 0:b.dataId)&&((b==null?void 0:b.dataId)===O.dataId||(b==null?void 0:b.dataId)===O.point_id)))return;const ae=`${H.id}-${Z.key}`;J.set(ae,{pen:H,dataItem:O,formKey:Z.key})})}),P&&clearTimeout(P),P=setTimeout(()=>{K(),P=null},f.value.debounceDelay))}})(),F=P=>{if(d.value){for(let J=0;J<P.length;J++){const $=P[J],U=d.value.find($.dataId);C(U,$)}d.value.render(),l.customCallbacks.onBatchUpdate&&l.customCallbacks.onBatchUpdate(P)}},j=(P,J=!1)=>{if(!d.value)return;const $=E();for(let U=0;U<$.length;U++){const K=$[U];let L=!1;J?L=P===K.dataProp:L=P===5?!0:K.dataProp<=P,X({id:K.id,visible:L},!1)}d.value.fitView(),d.value.render(),l.customCallbacks.onLevelChange&&l.customCallbacks.onLevelChange(P,J)};return N.watch(()=>[l.url,l.isFactory,l.local,l.data,l.gid],()=>{T()}),N.watch(()=>l.showMap,P=>{d.value&&(P?d.value.showMap():d.value.hideMap())}),N.onMounted(()=>{const P=v();P&&P.on&&P.on(f.value.graphSocket,x),T()}),N.onUnmounted(()=>{const P=v();P&&P.off&&P.off(f.value.graphSocket,x)}),r({setValue:X,getStage:V,getAllPens:E,getCustomPenType:A,batchUpdatePen:F,handleLineCross:tu.handleLineCross,changeVisibleByLevel:j}),(P,J)=>(N.openBlock(),N.createElementBlock("div",sg,[N.createVNode(ag,{ref_key:"graphRef",ref:p,url:s.value,local:i.value,data:l.data,"dev-config":l.devConfig,preview:"",onLoaded:k},null,8,["url","local","data","dev-config"]),N.unref(a)?(N.openBlock(),N.createElementBlock("div",lg,[N.createVNode(N.unref(ay),{type:"primary",onClick:g},{default:N.withCtx(()=>[...J[0]||(J[0]=[N.createTextVNode("返回",-1)])]),_:1})])):N.createCommentVNode("",!0)]))}}),Hr=ba(ug,[["__scopeId","data-v-c4b2c873"]]);Hr.name||(Hr.name="SyGraph");const cg=e=>{e.component(Hr.name||"SyGraph",Hr)},fg={install:cg};exports.SyGraph=Hr;exports.default=fg;