metaapi.cloud-sdk
Version:
SDK for MetaApi, a professional cloud forex API which includes MetaTrader REST API and MetaTrader websocket API. Supports both MetaTrader 5 (MT5) and MetaTrader 4 (MT4). CopyFactory copy trading API included. (https://metaapi.cloud)
2 lines • 1.86 MB
JavaScript
/*! For license information please see index.mjs.LICENSE.txt */
import{createRequire as __WEBPACK_EXTERNAL_createRequire}from"module";var __webpack_modules__={56310:(module,__unused_webpack_exports,__webpack_require__)=>{class Logger{log(){}isLevelEnabled(){return!1}addContext(){}removeContext(){}clearContext(){}}["Trace","Debug","Info","Warn","Error","Fatal","Mark"].forEach((level=>{Logger.prototype[level.toLowerCase()]=()=>{},Logger.prototype[`is${level}Enabled`]=()=>!1}));const log4js=(()=>{try{return __webpack_require__(34296)}catch(e){return null}})(),loggerFn=log4js?log4js.getLogger:()=>new Logger;module.exports={getLogger:loggerFn}},92722:module=>{function noop(){}module.exports=function after(count,callback,err_cb){var bail=!1;return err_cb=err_cb||noop,proxy.count=count,0===count?callback():proxy;function proxy(err,result){if(proxy.count<=0)throw new Error("after called too many times");--proxy.count,err?(bail=!0,callback(err),callback=err_cb):0!==proxy.count||bail||callback(null,result)}}},64666:module=>{"Set"in global?"function"==typeof Set.prototype.forEach&&function doesForEachActuallyWork(){var ret=!1;return new Set([!0]).forEach((function(el){ret=el})),!0===ret}()?module.exports=function uniqSetWithForEach(arr){var ret=[];return new Set(arr).forEach((function(el){ret.push(el)})),ret}:module.exports=function uniqSet(arr){var seen=new Set;return arr.filter((function(el){if(!seen.has(el))return seen.add(el),!0}))}:module.exports=function uniqNoSet(arr){for(var ret=[],i=0;i<arr.length;i++)-1===ret.indexOf(arr[i])&&ret.push(arr[i]);return ret}},87453:(module,__unused_webpack_exports,__webpack_require__)=>{var ArraySpeciesCreate=__webpack_require__(16750),Call=__webpack_require__(78583),CreateDataPropertyOrThrow=__webpack_require__(3489),Get=__webpack_require__(60760),HasProperty=__webpack_require__(69358),IsCallable=__webpack_require__(97036),ToUint32=__webpack_require__(47961),ToObject=__webpack_require__(28263),ToString=__webpack_require__(55697),callBound=__webpack_require__(17379),isString=__webpack_require__(29981),boxedString=Object("a"),splitString="a"!==boxedString[0]||!(0 in boxedString),strSplit=callBound("String.prototype.split");module.exports=function map(callbackfn){var T,O=ToObject(this),self=splitString&&isString(O)?strSplit(O,""):O,len=ToUint32(self.length);if(!IsCallable(callbackfn))throw new TypeError("Array.prototype.map callback must be a function");arguments.length>1&&(T=arguments[1]);for(var A=ArraySpeciesCreate(O,len),k=0;k<len;){var Pk=ToString(k);if(HasProperty(O,Pk)){var kValue=Get(O,Pk),mappedValue=Call(callbackfn,T,[kValue,k,O]);CreateDataPropertyOrThrow(A,Pk,mappedValue)}k+=1}return A}},14770:(module,__unused_webpack_exports,__webpack_require__)=>{var define=__webpack_require__(4289),RequireObjectCoercible=__webpack_require__(11781),callBind=__webpack_require__(55559),callBound=__webpack_require__(17379),implementation=__webpack_require__(87453),getPolyfill=__webpack_require__(47373),polyfill=callBind.apply(getPolyfill()),shim=__webpack_require__(12717),$slice=callBound("Array.prototype.slice"),boundMapShim=function map(array,callbackfn){return RequireObjectCoercible(array),polyfill(array,$slice(arguments,1))};define(boundMapShim,{getPolyfill,implementation,shim}),module.exports=boundMapShim},47373:(module,__unused_webpack_exports,__webpack_require__)=>{var arrayMethodBoxesProperly=__webpack_require__(72868),implementation=__webpack_require__(87453);module.exports=function getPolyfill(){var method=Array.prototype.map;return arrayMethodBoxesProperly(method)?method:implementation}},12717:(module,__unused_webpack_exports,__webpack_require__)=>{var define=__webpack_require__(4289),getPolyfill=__webpack_require__(47373);module.exports=function shimArrayPrototypeMap(){var polyfill=getPolyfill();return define(Array.prototype,{map:polyfill},{map:function(){return Array.prototype.map!==polyfill}}),polyfill}},59118:(module,__unused_webpack_exports,__webpack_require__)=>{module.exports={parallel:__webpack_require__(19162),serial:__webpack_require__(31357),serialOrdered:__webpack_require__(69087)}},37651:module=>{function clean(key){"function"==typeof this.jobs[key]&&this.jobs[key]()}module.exports=function abort(state){Object.keys(state.jobs).forEach(clean.bind(state)),state.jobs={}}},55912:(module,__unused_webpack_exports,__webpack_require__)=>{var defer=__webpack_require__(9265);module.exports=function async(callback){var isAsync=!1;return defer((function(){isAsync=!0})),function async_callback(err,result){isAsync?callback(err,result):defer((function nextTick_callback(){callback(err,result)}))}}},9265:module=>{module.exports=function defer(fn){var nextTick="function"==typeof setImmediate?setImmediate:"object"==typeof process&&"function"==typeof process.nextTick?process.nextTick:null;nextTick?nextTick(fn):setTimeout(fn,0)}},97594:(module,__unused_webpack_exports,__webpack_require__)=>{var async=__webpack_require__(55912),abort=__webpack_require__(37651);module.exports=function iterate(list,iterator,state,callback){var key=state.keyedList?state.keyedList[state.index]:state.index;state.jobs[key]=function runJob(iterator,key,item,callback){var aborter;aborter=2==iterator.length?iterator(item,async(callback)):iterator(item,key,async(callback));return aborter}(iterator,key,list[key],(function(error,output){key in state.jobs&&(delete state.jobs[key],error?abort(state):state.results[key]=output,callback(error,state.results))}))}},94528:module=>{module.exports=function state(list,sortMethod){var isNamedList=!Array.isArray(list),initState={index:0,keyedList:isNamedList||sortMethod?Object.keys(list):null,jobs:{},results:isNamedList?{}:[],size:isNamedList?Object.keys(list).length:list.length};sortMethod&&initState.keyedList.sort(isNamedList?sortMethod:function(a,b){return sortMethod(list[a],list[b])});return initState}},25353:(module,__unused_webpack_exports,__webpack_require__)=>{var abort=__webpack_require__(37651),async=__webpack_require__(55912);module.exports=function terminator(callback){if(!Object.keys(this.jobs).length)return;this.index=this.size,abort(this),async(callback)(null,this.results)}},19162:(module,__unused_webpack_exports,__webpack_require__)=>{var iterate=__webpack_require__(97594),initState=__webpack_require__(94528),terminator=__webpack_require__(25353);module.exports=function parallel(list,iterator,callback){var state=initState(list);for(;state.index<(state.keyedList||list).length;)iterate(list,iterator,state,(function(error,result){error?callback(error,result):0!==Object.keys(state.jobs).length||callback(null,state.results)})),state.index++;return terminator.bind(state,callback)}},31357:(module,__unused_webpack_exports,__webpack_require__)=>{var serialOrdered=__webpack_require__(69087);module.exports=function serial(list,iterator,callback){return serialOrdered(list,iterator,null,callback)}},69087:(module,__unused_webpack_exports,__webpack_require__)=>{var iterate=__webpack_require__(97594),initState=__webpack_require__(94528),terminator=__webpack_require__(25353);function ascending(a,b){return a<b?-1:a>b?1:0}module.exports=function serialOrdered(list,iterator,sortMethod,callback){var state=initState(list,sortMethod);return iterate(list,iterator,state,(function iteratorHandler(error,result){error?callback(error,result):(state.index++,state.index<(state.keyedList||list).length?iterate(list,iterator,state,iteratorHandler):callback(null,state.results))})),terminator.bind(state,callback)},module.exports.ascending=ascending,module.exports.descending=function descending(a,b){return-1*ascending(a,b)}},3736:module=>{module.exports=r=>{const n=process.versions.node.split(".").map((x=>parseInt(x,10)));return r=r.split(".").map((x=>parseInt(x,10))),n[0]>r[0]||n[0]===r[0]&&(n[1]>r[1]||n[1]===r[1]&&n[2]>=r[2])}},43010:module=>{function Backoff(opts){opts=opts||{},this.ms=opts.min||100,this.max=opts.max||1e4,this.factor=opts.factor||2,this.jitter=opts.jitter>0&&opts.jitter<=1?opts.jitter:0,this.attempts=0}module.exports=Backoff,Backoff.prototype.duration=function(){var ms=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var rand=Math.random(),deviation=Math.floor(rand*this.jitter*ms);ms=1&Math.floor(10*rand)?ms+deviation:ms-deviation}return 0|Math.min(ms,this.max)},Backoff.prototype.reset=function(){this.attempts=0},Backoff.prototype.setMin=function(min){this.ms=min},Backoff.prototype.setMax=function(max){this.max=max},Backoff.prototype.setJitter=function(jitter){this.jitter=jitter}},17153:(module,__unused_webpack_exports,__webpack_require__)=>{__webpack_require__(74820),module.exports.AVLTree=__webpack_require__(63004)},63004:(module,__unused_webpack_exports,__webpack_require__)=>{var BinarySearchTree=__webpack_require__(74820),customUtils=__webpack_require__(74066),util=__webpack_require__(73837);__webpack_require__(13469);function AVLTree(options){this.tree=new _AVLTree(options)}function _AVLTree(options){options=options||{},this.left=null,this.right=null,this.parent=void 0!==options.parent?options.parent:null,options.hasOwnProperty("key")&&(this.key=options.key),this.data=options.hasOwnProperty("value")?[options.value]:[],this.unique=options.unique||!1,this.compareKeys=options.compareKeys||customUtils.defaultCompareKeysFunction,this.checkValueEquality=options.checkValueEquality||customUtils.defaultCheckValueEquality}util.inherits(_AVLTree,BinarySearchTree),AVLTree._AVLTree=_AVLTree,_AVLTree.prototype.checkHeightCorrect=function(){var leftH,rightH;if(this.hasOwnProperty("key")){if(this.left&&void 0===this.left.height)throw new Error("Undefined height for node "+this.left.key);if(this.right&&void 0===this.right.height)throw new Error("Undefined height for node "+this.right.key);if(void 0===this.height)throw new Error("Undefined height for node "+this.key);if(leftH=this.left?this.left.height:0,rightH=this.right?this.right.height:0,this.height!==1+Math.max(leftH,rightH))throw new Error("Height constraint failed for node "+this.key);this.left&&this.left.checkHeightCorrect(),this.right&&this.right.checkHeightCorrect()}},_AVLTree.prototype.balanceFactor=function(){return(this.left?this.left.height:0)-(this.right?this.right.height:0)},_AVLTree.prototype.checkBalanceFactors=function(){if(Math.abs(this.balanceFactor())>1)throw new Error("Tree is unbalanced at node "+this.key);this.left&&this.left.checkBalanceFactors(),this.right&&this.right.checkBalanceFactors()},_AVLTree.prototype.checkIsAVLT=function(){_AVLTree.super_.prototype.checkIsBST.call(this),this.checkHeightCorrect(),this.checkBalanceFactors()},AVLTree.prototype.checkIsAVLT=function(){this.tree.checkIsAVLT()},_AVLTree.prototype.rightRotation=function(){var b,ah,bh,ch,q=this,p=this.left;return p?(b=p.right,q.parent?(p.parent=q.parent,q.parent.left===q?q.parent.left=p:q.parent.right=p):p.parent=null,p.right=q,q.parent=p,q.left=b,b&&(b.parent=q),ah=p.left?p.left.height:0,bh=b?b.height:0,ch=q.right?q.right.height:0,q.height=Math.max(bh,ch)+1,p.height=Math.max(ah,q.height)+1,p):this},_AVLTree.prototype.leftRotation=function(){var b,ah,bh,ch,p=this,q=this.right;return q?(b=q.left,p.parent?(q.parent=p.parent,p.parent.left===p?p.parent.left=q:p.parent.right=q):q.parent=null,q.left=p,p.parent=q,p.right=b,b&&(b.parent=p),ah=p.left?p.left.height:0,bh=b?b.height:0,ch=q.right?q.right.height:0,p.height=Math.max(ah,bh)+1,q.height=Math.max(ch,p.height)+1,q):this},_AVLTree.prototype.rightTooSmall=function(){return this.balanceFactor()<=1?this:(this.left.balanceFactor()<0&&this.left.leftRotation(),this.rightRotation())},_AVLTree.prototype.leftTooSmall=function(){return this.balanceFactor()>=-1?this:(this.right.balanceFactor()>0&&this.right.rightRotation(),this.leftRotation())},_AVLTree.prototype.rebalanceAlongPath=function(path){var rotated,i,newRoot=this;if(!this.hasOwnProperty("key"))return delete this.height,this;for(i=path.length-1;i>=0;i-=1)path[i].height=1+Math.max(path[i].left?path[i].left.height:0,path[i].right?path[i].right.height:0),path[i].balanceFactor()>1&&(rotated=path[i].rightTooSmall(),0===i&&(newRoot=rotated)),path[i].balanceFactor()<-1&&(rotated=path[i].leftTooSmall(),0===i&&(newRoot=rotated));return newRoot},_AVLTree.prototype.insert=function(key,value){var insertPath=[],currentNode=this;if(!this.hasOwnProperty("key"))return this.key=key,this.data.push(value),this.height=1,this;for(;;){if(0===currentNode.compareKeys(currentNode.key,key)){if(currentNode.unique){var err=new Error("Can't insert key "+key+", it violates the unique constraint");throw err.key=key,err.errorType="uniqueViolated",err}return currentNode.data.push(value),this}if(insertPath.push(currentNode),currentNode.compareKeys(key,currentNode.key)<0){if(!currentNode.left){insertPath.push(currentNode.createLeftChild({key,value}));break}currentNode=currentNode.left}else{if(!currentNode.right){insertPath.push(currentNode.createRightChild({key,value}));break}currentNode=currentNode.right}}return this.rebalanceAlongPath(insertPath)},AVLTree.prototype.insert=function(key,value){var newTree=this.tree.insert(key,value);newTree&&(this.tree=newTree)},_AVLTree.prototype.delete=function(key,value){var replaceWith,newData=[],currentNode=this,deletePath=[];if(!this.hasOwnProperty("key"))return this;for(;0!==currentNode.compareKeys(key,currentNode.key);)if(deletePath.push(currentNode),currentNode.compareKeys(key,currentNode.key)<0){if(!currentNode.left)return this;currentNode=currentNode.left}else{if(!currentNode.right)return this;currentNode=currentNode.right}if(currentNode.data.length>1&&void 0!==value)return currentNode.data.forEach((function(d){currentNode.checkValueEquality(d,value)||newData.push(d)})),currentNode.data=newData,this;if(!currentNode.left&&!currentNode.right)return currentNode===this?(delete currentNode.key,currentNode.data=[],delete currentNode.height,this):(currentNode.parent.left===currentNode?currentNode.parent.left=null:currentNode.parent.right=null,this.rebalanceAlongPath(deletePath));if(!currentNode.left||!currentNode.right)return replaceWith=currentNode.left?currentNode.left:currentNode.right,currentNode===this?(replaceWith.parent=null,replaceWith):(currentNode.parent.left===currentNode?(currentNode.parent.left=replaceWith,replaceWith.parent=currentNode.parent):(currentNode.parent.right=replaceWith,replaceWith.parent=currentNode.parent),this.rebalanceAlongPath(deletePath));if(deletePath.push(currentNode),!(replaceWith=currentNode.left).right)return currentNode.key=replaceWith.key,currentNode.data=replaceWith.data,currentNode.left=replaceWith.left,replaceWith.left&&(replaceWith.left.parent=currentNode),this.rebalanceAlongPath(deletePath);for(;replaceWith.right;)deletePath.push(replaceWith),replaceWith=replaceWith.right;return currentNode.key=replaceWith.key,currentNode.data=replaceWith.data,replaceWith.parent.right=replaceWith.left,replaceWith.left&&(replaceWith.left.parent=replaceWith.parent),this.rebalanceAlongPath(deletePath)},AVLTree.prototype.delete=function(key,value){var newTree=this.tree.delete(key,value);newTree&&(this.tree=newTree)},["getNumberOfKeys","search","betweenBounds","prettyPrint","executeOnEveryNode"].forEach((function(fn){AVLTree.prototype[fn]=function(){return this.tree[fn].apply(this.tree,arguments)}})),module.exports=AVLTree},74820:(module,__unused_webpack_exports,__webpack_require__)=>{var customUtils=__webpack_require__(74066);function BinarySearchTree(options){options=options||{},this.left=null,this.right=null,this.parent=void 0!==options.parent?options.parent:null,options.hasOwnProperty("key")&&(this.key=options.key),this.data=options.hasOwnProperty("value")?[options.value]:[],this.unique=options.unique||!1,this.compareKeys=options.compareKeys||customUtils.defaultCompareKeysFunction,this.checkValueEquality=options.checkValueEquality||customUtils.defaultCheckValueEquality}function append(array,toAppend){var i;for(i=0;i<toAppend.length;i+=1)array.push(toAppend[i])}BinarySearchTree.prototype.getMaxKeyDescendant=function(){return this.right?this.right.getMaxKeyDescendant():this},BinarySearchTree.prototype.getMaxKey=function(){return this.getMaxKeyDescendant().key},BinarySearchTree.prototype.getMinKeyDescendant=function(){return this.left?this.left.getMinKeyDescendant():this},BinarySearchTree.prototype.getMinKey=function(){return this.getMinKeyDescendant().key},BinarySearchTree.prototype.checkAllNodesFullfillCondition=function(test){this.hasOwnProperty("key")&&(test(this.key,this.data),this.left&&this.left.checkAllNodesFullfillCondition(test),this.right&&this.right.checkAllNodesFullfillCondition(test))},BinarySearchTree.prototype.checkNodeOrdering=function(){var self=this;this.hasOwnProperty("key")&&(this.left&&(this.left.checkAllNodesFullfillCondition((function(k){if(self.compareKeys(k,self.key)>=0)throw new Error("Tree with root "+self.key+" is not a binary search tree")})),this.left.checkNodeOrdering()),this.right&&(this.right.checkAllNodesFullfillCondition((function(k){if(self.compareKeys(k,self.key)<=0)throw new Error("Tree with root "+self.key+" is not a binary search tree")})),this.right.checkNodeOrdering()))},BinarySearchTree.prototype.checkInternalPointers=function(){if(this.left){if(this.left.parent!==this)throw new Error("Parent pointer broken for key "+this.key);this.left.checkInternalPointers()}if(this.right){if(this.right.parent!==this)throw new Error("Parent pointer broken for key "+this.key);this.right.checkInternalPointers()}},BinarySearchTree.prototype.checkIsBST=function(){if(this.checkNodeOrdering(),this.checkInternalPointers(),this.parent)throw new Error("The root shouldn't have a parent")},BinarySearchTree.prototype.getNumberOfKeys=function(){var res;return this.hasOwnProperty("key")?(res=1,this.left&&(res+=this.left.getNumberOfKeys()),this.right&&(res+=this.right.getNumberOfKeys()),res):0},BinarySearchTree.prototype.createSimilar=function(options){return(options=options||{}).unique=this.unique,options.compareKeys=this.compareKeys,options.checkValueEquality=this.checkValueEquality,new this.constructor(options)},BinarySearchTree.prototype.createLeftChild=function(options){var leftChild=this.createSimilar(options);return leftChild.parent=this,this.left=leftChild,leftChild},BinarySearchTree.prototype.createRightChild=function(options){var rightChild=this.createSimilar(options);return rightChild.parent=this,this.right=rightChild,rightChild},BinarySearchTree.prototype.insert=function(key,value){if(!this.hasOwnProperty("key"))return this.key=key,void this.data.push(value);if(0!==this.compareKeys(this.key,key))this.compareKeys(key,this.key)<0?this.left?this.left.insert(key,value):this.createLeftChild({key,value}):this.right?this.right.insert(key,value):this.createRightChild({key,value});else{if(this.unique){var err=new Error("Can't insert key "+key+", it violates the unique constraint");throw err.key=key,err.errorType="uniqueViolated",err}this.data.push(value)}},BinarySearchTree.prototype.search=function(key){return this.hasOwnProperty("key")?0===this.compareKeys(this.key,key)?this.data:this.compareKeys(key,this.key)<0?this.left?this.left.search(key):[]:this.right?this.right.search(key):[]:[]},BinarySearchTree.prototype.getLowerBoundMatcher=function(query){var self=this;return query.hasOwnProperty("$gt")||query.hasOwnProperty("$gte")?query.hasOwnProperty("$gt")&&query.hasOwnProperty("$gte")?0===self.compareKeys(query.$gte,query.$gt)?function(key){return self.compareKeys(key,query.$gt)>0}:self.compareKeys(query.$gte,query.$gt)>0?function(key){return self.compareKeys(key,query.$gte)>=0}:function(key){return self.compareKeys(key,query.$gt)>0}:query.hasOwnProperty("$gt")?function(key){return self.compareKeys(key,query.$gt)>0}:function(key){return self.compareKeys(key,query.$gte)>=0}:function(){return!0}},BinarySearchTree.prototype.getUpperBoundMatcher=function(query){var self=this;return query.hasOwnProperty("$lt")||query.hasOwnProperty("$lte")?query.hasOwnProperty("$lt")&&query.hasOwnProperty("$lte")?0===self.compareKeys(query.$lte,query.$lt)?function(key){return self.compareKeys(key,query.$lt)<0}:self.compareKeys(query.$lte,query.$lt)<0?function(key){return self.compareKeys(key,query.$lte)<=0}:function(key){return self.compareKeys(key,query.$lt)<0}:query.hasOwnProperty("$lt")?function(key){return self.compareKeys(key,query.$lt)<0}:function(key){return self.compareKeys(key,query.$lte)<=0}:function(){return!0}},BinarySearchTree.prototype.betweenBounds=function(query,lbm,ubm){var res=[];return this.hasOwnProperty("key")?(lbm=lbm||this.getLowerBoundMatcher(query),ubm=ubm||this.getUpperBoundMatcher(query),lbm(this.key)&&this.left&&append(res,this.left.betweenBounds(query,lbm,ubm)),lbm(this.key)&&ubm(this.key)&&append(res,this.data),ubm(this.key)&&this.right&&append(res,this.right.betweenBounds(query,lbm,ubm)),res):[]},BinarySearchTree.prototype.deleteIfLeaf=function(){return!this.left&&!this.right&&(this.parent?(this.parent.left===this?this.parent.left=null:this.parent.right=null,!0):(delete this.key,this.data=[],!0))},BinarySearchTree.prototype.deleteIfOnlyOneChild=function(){var child;return this.left&&!this.right&&(child=this.left),!this.left&&this.right&&(child=this.right),!!child&&(this.parent?(this.parent.left===this?(this.parent.left=child,child.parent=this.parent):(this.parent.right=child,child.parent=this.parent),!0):(this.key=child.key,this.data=child.data,this.left=null,child.left&&(this.left=child.left,child.left.parent=this),this.right=null,child.right&&(this.right=child.right,child.right.parent=this),!0))},BinarySearchTree.prototype.delete=function(key,value){var replaceWith,newData=[],self=this;if(this.hasOwnProperty("key"))if(this.compareKeys(key,this.key)<0)this.left&&this.left.delete(key,value);else if(this.compareKeys(key,this.key)>0)this.right&&this.right.delete(key,value);else if(0!==!this.compareKeys(key,this.key))return this.data.length>1&&void 0!==value?(this.data.forEach((function(d){self.checkValueEquality(d,value)||newData.push(d)})),void(self.data=newData)):void(this.deleteIfLeaf()||this.deleteIfOnlyOneChild()||(Math.random()>=.5?(replaceWith=this.left.getMaxKeyDescendant(),this.key=replaceWith.key,this.data=replaceWith.data,this===replaceWith.parent?(this.left=replaceWith.left,replaceWith.left&&(replaceWith.left.parent=replaceWith.parent)):(replaceWith.parent.right=replaceWith.left,replaceWith.left&&(replaceWith.left.parent=replaceWith.parent))):(replaceWith=this.right.getMinKeyDescendant(),this.key=replaceWith.key,this.data=replaceWith.data,this===replaceWith.parent?(this.right=replaceWith.right,replaceWith.right&&(replaceWith.right.parent=replaceWith.parent)):(replaceWith.parent.left=replaceWith.right,replaceWith.right&&(replaceWith.right.parent=replaceWith.parent)))))},BinarySearchTree.prototype.executeOnEveryNode=function(fn){this.left&&this.left.executeOnEveryNode(fn),fn(this),this.right&&this.right.executeOnEveryNode(fn)},BinarySearchTree.prototype.prettyPrint=function(printData,spacing){spacing=spacing||"",console.log(spacing+"* "+this.key),printData&&console.log(spacing+"* "+this.data),(this.left||this.right)&&(this.left?this.left.prettyPrint(printData,spacing+" "):console.log(spacing+" *"),this.right?this.right.prettyPrint(printData,spacing+" "):console.log(spacing+" *"))},module.exports=BinarySearchTree},74066:module=>{module.exports.getRandomArray=function getRandomArray(n){var res,next;return 0===n?[]:1===n?[0]:(res=getRandomArray(n-1),next=Math.floor(Math.random()*n),res.splice(next,0,n-1),res)},module.exports.defaultCompareKeysFunction=function defaultCompareKeysFunction(a,b){if(a<b)return-1;if(a>b)return 1;if(a===b)return 0;var err=new Error("Couldn't compare elements");throw err.a=a,err.b=b,err},module.exports.defaultCheckValueEquality=function defaultCheckValueEquality(a,b){return a===b}},39376:module=>{module.exports={mask:(source,mask,output,offset,length)=>{for(var i=0;i<length;i++)output[offset+i]=source[i]^mask[3&i]},unmask:(buffer,mask)=>{const length=buffer.length;for(var i=0;i<length;i++)buffer[i]^=mask[3&i]}}},41891:(module,__unused_webpack_exports,__webpack_require__)=>{try{module.exports=__webpack_require__(19516)(__dirname)}catch(e){module.exports=__webpack_require__(39376)}},25730:(module,__unused_webpack_exports,__webpack_require__)=>{var bind=__webpack_require__(58612),$apply=__webpack_require__(1768),$call=__webpack_require__(68928),$reflectApply=__webpack_require__(59770);module.exports=$reflectApply||bind.call($call,$apply)},93192:(module,__unused_webpack_exports,__webpack_require__)=>{var bind=__webpack_require__(58612),$apply=__webpack_require__(1768),actualApply=__webpack_require__(25730);module.exports=function applyBind(){return actualApply(bind,$apply,arguments)}},1768:module=>{module.exports=Function.prototype.apply},68928:module=>{module.exports=Function.prototype.call},40319:(module,__unused_webpack_exports,__webpack_require__)=>{var bind=__webpack_require__(58612),$TypeError=__webpack_require__(14453),$call=__webpack_require__(68928),$actualApply=__webpack_require__(25730);module.exports=function callBindBasic(args){if(args.length<1||"function"!=typeof args[0])throw new $TypeError("a function is required");return $actualApply(bind,$call,args)}},59770:module=>{module.exports="undefined"!=typeof Reflect&&Reflect&&Reflect.apply},55559:(module,__unused_webpack_exports,__webpack_require__)=>{var setFunctionLength=__webpack_require__(67771),$defineProperty=__webpack_require__(24429),callBindBasic=__webpack_require__(40319),applyBind=__webpack_require__(93192);module.exports=function callBind(originalFunction){var func=callBindBasic(arguments),adjustedLength=originalFunction.length-(arguments.length-1);return setFunctionLength(func,1+(adjustedLength>0?adjustedLength:0),!0)},$defineProperty?$defineProperty(module.exports,"apply",{value:applyBind}):module.exports.apply=applyBind},17379:(module,__unused_webpack_exports,__webpack_require__)=>{var GetIntrinsic=__webpack_require__(40210),callBindBasic=__webpack_require__(40319),$indexOf=callBindBasic([GetIntrinsic("%String.prototype.indexOf%")]);module.exports=function callBoundIntrinsic(name,allowMissing){var intrinsic=GetIntrinsic(name,!!allowMissing);return"function"==typeof intrinsic&&$indexOf(name,".prototype.")>-1?callBindBasic([intrinsic]):intrinsic}},9779:(module,__unused_webpack_exports,__webpack_require__)=>{var util=__webpack_require__(73837),Stream=__webpack_require__(12781).Stream,DelayedStream=__webpack_require__(63463);function CombinedStream(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2097152,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}module.exports=CombinedStream,util.inherits(CombinedStream,Stream),CombinedStream.create=function(options){var combinedStream=new this;for(var option in options=options||{})combinedStream[option]=options[option];return combinedStream},CombinedStream.isStreamLike=function(stream){return"function"!=typeof stream&&"string"!=typeof stream&&"boolean"!=typeof stream&&"number"!=typeof stream&&!Buffer.isBuffer(stream)},CombinedStream.prototype.append=function(stream){if(CombinedStream.isStreamLike(stream)){if(!(stream instanceof DelayedStream)){var newStream=DelayedStream.create(stream,{maxDataSize:1/0,pauseStream:this.pauseStreams});stream.on("data",this._checkDataSize.bind(this)),stream=newStream}this._handleErrors(stream),this.pauseStreams&&stream.pause()}return this._streams.push(stream),this},CombinedStream.prototype.pipe=function(dest,options){return Stream.prototype.pipe.call(this,dest,options),this.resume(),dest},CombinedStream.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop)this._pendingNext=!0;else{this._insideLoop=!0;try{do{this._pendingNext=!1,this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=!1}}},CombinedStream.prototype._realGetNext=function(){var stream=this._streams.shift();void 0!==stream?"function"==typeof stream?stream(function(stream){CombinedStream.isStreamLike(stream)&&(stream.on("data",this._checkDataSize.bind(this)),this._handleErrors(stream)),this._pipeNext(stream)}.bind(this)):this._pipeNext(stream):this.end()},CombinedStream.prototype._pipeNext=function(stream){if(this._currentStream=stream,CombinedStream.isStreamLike(stream))return stream.on("end",this._getNext.bind(this)),void stream.pipe(this,{end:!1});var value=stream;this.write(value),this._getNext()},CombinedStream.prototype._handleErrors=function(stream){var self=this;stream.on("error",(function(err){self._emitError(err)}))},CombinedStream.prototype.write=function(data){this.emit("data",data)},CombinedStream.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&"function"==typeof this._currentStream.pause&&this._currentStream.pause(),this.emit("pause"))},CombinedStream.prototype.resume=function(){this._released||(this._released=!0,this.writable=!0,this._getNext()),this.pauseStreams&&this._currentStream&&"function"==typeof this._currentStream.resume&&this._currentStream.resume(),this.emit("resume")},CombinedStream.prototype.end=function(){this._reset(),this.emit("end")},CombinedStream.prototype.destroy=function(){this._reset(),this.emit("close")},CombinedStream.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null},CombinedStream.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var message="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(message))}},CombinedStream.prototype._updateDataSize=function(){this.dataSize=0;var self=this;this._streams.forEach((function(stream){stream.dataSize&&(self.dataSize+=stream.dataSize)})),this._currentStream&&this._currentStream.dataSize&&(this.dataSize+=this._currentStream.dataSize)},CombinedStream.prototype._emitError=function(err){this._reset(),this.emit("error",err)}},86077:module=>{var slice=[].slice;module.exports=function(obj,fn){if("string"==typeof fn&&(fn=obj[fn]),"function"!=typeof fn)throw new Error("bind() requires a function");var args=slice.call(arguments,2);return function(){return fn.apply(obj,args.concat(slice.call(arguments)))}}},98767:module=>{function Emitter(obj){if(obj)return function mixin(obj){for(var key in Emitter.prototype)obj[key]=Emitter.prototype[key];return obj}(obj)}module.exports=Emitter,Emitter.prototype.on=Emitter.prototype.addEventListener=function(event,fn){return this._callbacks=this._callbacks||{},(this._callbacks["$"+event]=this._callbacks["$"+event]||[]).push(fn),this},Emitter.prototype.once=function(event,fn){function on(){this.off(event,on),fn.apply(this,arguments)}return on.fn=fn,this.on(event,on),this},Emitter.prototype.off=Emitter.prototype.removeListener=Emitter.prototype.removeAllListeners=Emitter.prototype.removeEventListener=function(event,fn){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var cb,callbacks=this._callbacks["$"+event];if(!callbacks)return this;if(1==arguments.length)return delete this._callbacks["$"+event],this;for(var i=0;i<callbacks.length;i++)if((cb=callbacks[i])===fn||cb.fn===fn){callbacks.splice(i,1);break}return 0===callbacks.length&&delete this._callbacks["$"+event],this},Emitter.prototype.emit=function(event){this._callbacks=this._callbacks||{};for(var args=new Array(arguments.length-1),callbacks=this._callbacks["$"+event],i=1;i<arguments.length;i++)args[i-1]=arguments[i];if(callbacks){i=0;for(var len=(callbacks=callbacks.slice(0)).length;i<len;++i)callbacks[i].apply(this,args)}return this},Emitter.prototype.listeners=function(event){return this._callbacks=this._callbacks||{},this._callbacks["$"+event]||[]},Emitter.prototype.hasListeners=function(event){return!!this.listeners(event).length}},53861:module=>{module.exports=function(a,b){var fn=function(){};fn.prototype=b.prototype,a.prototype=new fn,a.prototype.constructor=a}},40452:function(module,exports,__webpack_require__){var CryptoJS;module.exports=(CryptoJS=__webpack_require__(78249),__webpack_require__(98269),__webpack_require__(68214),__webpack_require__(90888),__webpack_require__(75109),function(){var C=CryptoJS,BlockCipher=C.lib.BlockCipher,C_algo=C.algo,SBOX=[],INV_SBOX=[],SUB_MIX_0=[],SUB_MIX_1=[],SUB_MIX_2=[],SUB_MIX_3=[],INV_SUB_MIX_0=[],INV_SUB_MIX_1=[],INV_SUB_MIX_2=[],INV_SUB_MIX_3=[];!function(){for(var d=[],i=0;i<256;i++)d[i]=i<128?i<<1:i<<1^283;var x=0,xi=0;for(i=0;i<256;i++){var sx=xi^xi<<1^xi<<2^xi<<3^xi<<4;sx=sx>>>8^255&sx^99,SBOX[x]=sx,INV_SBOX[sx]=x;var x2=d[x],x4=d[x2],x8=d[x4],t=257*d[sx]^16843008*sx;SUB_MIX_0[x]=t<<24|t>>>8,SUB_MIX_1[x]=t<<16|t>>>16,SUB_MIX_2[x]=t<<8|t>>>24,SUB_MIX_3[x]=t,t=16843009*x8^65537*x4^257*x2^16843008*x,INV_SUB_MIX_0[sx]=t<<24|t>>>8,INV_SUB_MIX_1[sx]=t<<16|t>>>16,INV_SUB_MIX_2[sx]=t<<8|t>>>24,INV_SUB_MIX_3[sx]=t,x?(x=x2^d[d[d[x8^x2]]],xi^=d[d[xi]]):x=xi=1}}();var RCON=[0,1,2,4,8,16,32,64,128,27,54],AES=C_algo.AES=BlockCipher.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var key=this._keyPriorReset=this._key,keyWords=key.words,keySize=key.sigBytes/4,ksRows=4*((this._nRounds=keySize+6)+1),keySchedule=this._keySchedule=[],ksRow=0;ksRow<ksRows;ksRow++)ksRow<keySize?keySchedule[ksRow]=keyWords[ksRow]:(t=keySchedule[ksRow-1],ksRow%keySize?keySize>6&&ksRow%keySize==4&&(t=SBOX[t>>>24]<<24|SBOX[t>>>16&255]<<16|SBOX[t>>>8&255]<<8|SBOX[255&t]):(t=SBOX[(t=t<<8|t>>>24)>>>24]<<24|SBOX[t>>>16&255]<<16|SBOX[t>>>8&255]<<8|SBOX[255&t],t^=RCON[ksRow/keySize|0]<<24),keySchedule[ksRow]=keySchedule[ksRow-keySize]^t);for(var invKeySchedule=this._invKeySchedule=[],invKsRow=0;invKsRow<ksRows;invKsRow++){if(ksRow=ksRows-invKsRow,invKsRow%4)var t=keySchedule[ksRow];else t=keySchedule[ksRow-4];invKeySchedule[invKsRow]=invKsRow<4||ksRow<=4?t:INV_SUB_MIX_0[SBOX[t>>>24]]^INV_SUB_MIX_1[SBOX[t>>>16&255]]^INV_SUB_MIX_2[SBOX[t>>>8&255]]^INV_SUB_MIX_3[SBOX[255&t]]}}},encryptBlock:function(M,offset){this._doCryptBlock(M,offset,this._keySchedule,SUB_MIX_0,SUB_MIX_1,SUB_MIX_2,SUB_MIX_3,SBOX)},decryptBlock:function(M,offset){var t=M[offset+1];M[offset+1]=M[offset+3],M[offset+3]=t,this._doCryptBlock(M,offset,this._invKeySchedule,INV_SUB_MIX_0,INV_SUB_MIX_1,INV_SUB_MIX_2,INV_SUB_MIX_3,INV_SBOX),t=M[offset+1],M[offset+1]=M[offset+3],M[offset+3]=t},_doCryptBlock:function(M,offset,keySchedule,SUB_MIX_0,SUB_MIX_1,SUB_MIX_2,SUB_MIX_3,SBOX){for(var nRounds=this._nRounds,s0=M[offset]^keySchedule[0],s1=M[offset+1]^keySchedule[1],s2=M[offset+2]^keySchedule[2],s3=M[offset+3]^keySchedule[3],ksRow=4,round=1;round<nRounds;round++){var t0=SUB_MIX_0[s0>>>24]^SUB_MIX_1[s1>>>16&255]^SUB_MIX_2[s2>>>8&255]^SUB_MIX_3[255&s3]^keySchedule[ksRow++],t1=SUB_MIX_0[s1>>>24]^SUB_MIX_1[s2>>>16&255]^SUB_MIX_2[s3>>>8&255]^SUB_MIX_3[255&s0]^keySchedule[ksRow++],t2=SUB_MIX_0[s2>>>24]^SUB_MIX_1[s3>>>16&255]^SUB_MIX_2[s0>>>8&255]^SUB_MIX_3[255&s1]^keySchedule[ksRow++],t3=SUB_MIX_0[s3>>>24]^SUB_MIX_1[s0>>>16&255]^SUB_MIX_2[s1>>>8&255]^SUB_MIX_3[255&s2]^keySchedule[ksRow++];s0=t0,s1=t1,s2=t2,s3=t3}t0=(SBOX[s0>>>24]<<24|SBOX[s1>>>16&255]<<16|SBOX[s2>>>8&255]<<8|SBOX[255&s3])^keySchedule[ksRow++],t1=(SBOX[s1>>>24]<<24|SBOX[s2>>>16&255]<<16|SBOX[s3>>>8&255]<<8|SBOX[255&s0])^keySchedule[ksRow++],t2=(SBOX[s2>>>24]<<24|SBOX[s3>>>16&255]<<16|SBOX[s0>>>8&255]<<8|SBOX[255&s1])^keySchedule[ksRow++],t3=(SBOX[s3>>>24]<<24|SBOX[s0>>>16&255]<<16|SBOX[s1>>>8&255]<<8|SBOX[255&s2])^keySchedule[ksRow++],M[offset]=t0,M[offset+1]=t1,M[offset+2]=t2,M[offset+3]=t3},keySize:8});C.AES=BlockCipher._createHelper(AES)}(),CryptoJS.AES)},75109:function(module,exports,__webpack_require__){var CryptoJS;module.exports=(CryptoJS=__webpack_require__(78249),__webpack_require__(90888),void(CryptoJS.lib.Cipher||function(undefined){var C=CryptoJS,C_lib=C.lib,Base=C_lib.Base,WordArray=C_lib.WordArray,BufferedBlockAlgorithm=C_lib.BufferedBlockAlgorithm,C_enc=C.enc,Base64=(C_enc.Utf8,C_enc.Base64),EvpKDF=C.algo.EvpKDF,Cipher=C_lib.Cipher=BufferedBlockAlgorithm.extend({cfg:Base.extend(),createEncryptor:function(key,cfg){return this.create(this._ENC_XFORM_MODE,key,cfg)},createDecryptor:function(key,cfg){return this.create(this._DEC_XFORM_MODE,key,cfg)},init:function(xformMode,key,cfg){this.cfg=this.cfg.extend(cfg),this._xformMode=xformMode,this._key=key,this.reset()},reset:function(){BufferedBlockAlgorithm.reset.call(this),this._doReset()},process:function(dataUpdate){return this._append(dataUpdate),this._process()},finalize:function(dataUpdate){return dataUpdate&&this._append(dataUpdate),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function selectCipherStrategy(key){return"string"==typeof key?PasswordBasedCipher:SerializableCipher}return function(cipher){return{encrypt:function(message,key,cfg){return selectCipherStrategy(key).encrypt(cipher,message,key,cfg)},decrypt:function(ciphertext,key,cfg){return selectCipherStrategy(key).decrypt(cipher,ciphertext,key,cfg)}}}}()}),C_mode=(C_lib.StreamCipher=Cipher.extend({_doFinalize:function(){return this._process(!0)},blockSize:1}),C.mode={}),BlockCipherMode=C_lib.BlockCipherMode=Base.extend({createEncryptor:function(cipher,iv){return this.Encryptor.create(cipher,iv)},createDecryptor:function(cipher,iv){return this.Decryptor.create(cipher,iv)},init:function(cipher,iv){this._cipher=cipher,this._iv=iv}}),CBC=C_mode.CBC=function(){var CBC=BlockCipherMode.extend();function xorBlock(words,offset,blockSize){var block,iv=this._iv;iv?(block=iv,this._iv=undefined):block=this._prevBlock;for(var i=0;i<blockSize;i++)words[offset+i]^=block[i]}return CBC.Encryptor=CBC.extend({processBlock:function(words,offset){var cipher=this._cipher,blockSize=cipher.blockSize;xorBlock.call(this,words,offset,blockSize),cipher.encryptBlock(words,offset),this._prevBlock=words.slice(offset,offset+blockSize)}}),CBC.Decryptor=CBC.extend({processBlock:function(words,offset){var cipher=this._cipher,blockSize=cipher.blockSize,thisBlock=words.slice(offset,offset+blockSize);cipher.decryptBlock(words,offset),xorBlock.call(this,words,offset,blockSize),this._prevBlock=thisBlock}}),CBC}(),Pkcs7=(C.pad={}).Pkcs7={pad:function(data,blockSize){for(var blockSizeBytes=4*blockSize,nPaddingBytes=blockSizeBytes-data.sigBytes%blockSizeBytes,paddingWord=nPaddingBytes<<24|nPaddingBytes<<16|nPaddingBytes<<8|nPaddingBytes,paddingWords=[],i=0;i<nPaddingBytes;i+=4)paddingWords.push(paddingWord);var padding=WordArray.create(paddingWords,nPaddingBytes);data.concat(padding)},unpad:function(data){var nPaddingBytes=255&data.words[data.sigBytes-1>>>2];data.sigBytes-=nPaddingBytes}},CipherParams=(C_lib.BlockCipher=Cipher.extend({cfg:Cipher.cfg.extend({mode:CBC,padding:Pkcs7}),reset:function(){var modeCreator;Cipher.reset.call(this);var cfg=this.cfg,iv=cfg.iv,mode=cfg.mode;this._xformMode==this._ENC_XFORM_MODE?modeCreator=mode.createEncryptor:(modeCreator=mode.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==modeCreator?this._mode.init(this,iv&&iv.words):(this._mode=modeCreator.call(mode,this,iv&&iv.words),this._mode.__creator=modeCreator)},_doProcessBlock:function(words,offset){this._mode.processBlock(words,offset)},_doFinalize:function(){var finalProcessedBlocks,padding=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(padding.pad(this._data,this.blockSize),finalProcessedBlocks=this._process(!0)):(finalProcessedBlocks=this._process(!0),padding.unpad(finalProcessedBlocks)),finalProcessedBlocks},blockSize:4}),C_lib.CipherParams=Base.extend({init:function(cipherParams){this.mixIn(cipherParams)},toString:function(formatter){return(formatter||this.formatter).stringify(this)}})),OpenSSLFormatter=(C.format={}).OpenSSL={stringify:function(cipherParams){var ciphertext=cipherParams.ciphertext,salt=cipherParams.salt;return(salt?WordArray.create([1398893684,1701076831]).concat(salt).concat(ciphertext):ciphertext).toString(Base64)},parse:function(openSSLStr){var salt,ciphertext=Base64.parse(openSSLStr),ciphertextWords=ciphertext.words;return 1398893684==ciphertextWords[0]&&1701076831==ciphertextWords[1]&&(salt=WordArray.create(ciphertextWords.slice(2,4)),ciphertextWords.splice(0,4),ciphertext.sigBytes-=16),CipherParams.create({ciphertext,salt})}},SerializableCipher=C_lib.SerializableCipher=Base.extend({cfg:Base.extend({format:OpenSSLFormatter}),encrypt:function(cipher,message,key,cfg){cfg=this.cfg.extend(cfg);var encryptor=cipher.createEncryptor(key,cfg),ciphertext=encryptor.finalize(message),cipherCfg=encryptor.cfg;return CipherParams.create({ciphertext,key,iv:cipherCfg.iv,algorithm:cipher,mode:cipherCfg.mode,padding:cipherCfg.padding,blockSize:cipher.blockSize,formatter:cfg.format})},decrypt:function(cipher,ciphertext,key,cfg){return cfg=this.cfg.extend(cfg),ciphertext=this._parse(ciphertext,cfg.format),cipher.createDecryptor(key,cfg).finalize(ciphertext.ciphertext)},_parse:function(ciphertext,format){return"string"==typeof ciphertext?format.parse(ciphertext,this):ciphertext}}),OpenSSLKdf=(C.kdf={}).OpenSSL={execute:function(password,keySize,ivSize,salt){salt||(salt=WordArray.random(8));var key=EvpKDF.create({keySize:keySize+ivSize}).compute(password,salt),iv=WordArray.create(key.words.slice(keySize),4*ivSize);return key.sigBytes=4*keySize,CipherParams.create({key,iv,salt})}},PasswordBasedCipher=C_lib.PasswordBasedCipher=SerializableCipher.extend({cfg:SerializableCipher.cfg.extend({kdf:OpenSSLKdf}),encrypt:function(cipher,message,password,cfg){var derivedParams=(cfg=this.cfg.extend(cfg)).kdf.execute(password,cipher.keySize,cipher.ivSize);cfg.iv=derivedParams.iv;var ciphertext=SerializableCipher.encrypt.call(this,cipher,message,derivedParams.key,cfg);return ciphertext.mixIn(derivedParams),ciphertext},decrypt:function(cipher,ciphertext,password,cfg){cfg=this.cfg.extend(cfg),ciphertext=this._parse(ciphertext,cfg.format);var derivedParams=cfg.kdf.execute(password,cipher.keySize,cipher.ivSize,ciphertext.salt);return cfg.iv=derivedParams.iv,SerializableCipher.decrypt.call(this,cipher,ciphertext,derivedParams.key,cfg)}})}()))},78249:function(module,exports,__webpack_require__){var CryptoJS;module.exports=(CryptoJS=CryptoJS||function(Math,undefined){var crypto;if("undefined"!=typeof window&&window.crypto&&(crypto=window.crypto),"undefined"!=typeof self&&self.crypto&&(crypto=self.crypto),"undefined"!=typeof globalThis&&globalThis.crypto&&(crypto=globalThis.crypto),!crypto&&"undefined"!=typeof window&&window.msCrypto&&(crypto=window.msCrypto),!crypto&&"undefined"!=typeof global&&global.crypto&&(crypto=global.crypto),!crypto)try{crypto=__webpack_require__(6113)}catch(err){}var cryptoSecureRandomInt=function(){if(crypto){if("function"==typeof crypto.getRandomValues)try{return crypto.getRandomValues(new Uint32Array(1))[0]}catch(err){}if("function"==typeof crypto.randomBytes)try{return crypto.randomBytes(4).readInt32LE()}catch(err){}}throw new Error("Native crypto module could not be used to get secure random number.")},create=Object.create||function(){function F(){}return function(obj){var subtype;return F.prototype=obj,subtype=new F,F.prototype=null,subtype}}(),C={},C_lib=C.lib={},Base=C_lib.Base={extend:function(overrides){var subtype=create(this);return overrides&&subtype.mixIn(overrides),subtype.hasOwnProperty("init")&&this.init!==subtype.init||(subtype.init=function(){subtype.$super.init.apply(this,arguments)}),subtype.init.prototype=subtype,subtype.$super=this,subtype},create:function(){var instance=this.extend();return instance.init.apply(instance,arguments),instance},init:function(){},mixIn:function(properties){for(var propertyName in properties)properties.hasOwnProperty(propertyName)&&(this[propertyName]=properties[propertyName]);properties.hasOwnProperty("toString")&&(this.toString=properties.toString)},clone:function(){return this.init.prototype.extend(this)}},WordArray=C_lib.WordArray=Base.extend({init:function(words,sigBytes){words=this.words=words||[],this.sigBytes=sigBytes!=undefined?sigBytes:4*words.length},toString:function(encoder){return(encoder||Hex).stringify(this)},concat:function(wordArray){var thisWords=this.words,thatWords=wordArray.words,thisSigBytes=this.sigBytes,thatSigBytes=wordArray.sigBytes;if(this.clamp(),thisSigBytes%4)for(var i=0;i<thatSigBytes;i++){var thatByte=thatWords[i>>>2]>>>24-i%4*8&255;thisWords[thisSigBytes+i>>>2]|=thatByte<<24-(thisSigBytes+i)%4*8}else for(var j=0;j<thatSigBytes;j+=4)thisWords[thisSigBytes+j>>>2]=thatWords[j>>>2];return this.sigBytes+=thatSigBytes,this},clamp:function(){var words=this.words,sigBytes=this.sigBytes;words[sigBytes>>>2]&=4294967295<<32-sigBytes%4*8,words.length=Math.ceil(sigBytes/4)},clone:function(){var clone=Base.clone.call(this);return clone.words=this.words.slice(0),clone},random:function(nBytes){for(var words=[],i=0;i<nBytes;i+=4)words.push(cryptoSecureRandomInt());return new WordArray.init(words,nBytes)}}),C_enc=C.enc={},Hex=C_enc.Hex={stringify:function(wordArray){for(var words=wordArray.words,sigBytes=wordArray.sigBytes,hexChars=[],i=0;i<sigBytes;i++){var bite=words[i>>>2]>>>24-i%4*8&255;hexChars.push((bite>>>4).toString(16)),hexChars.push((15&bite).toString(16))}return hexChars.join("")},parse:function(hexStr){for(var hexStrLength=hexStr.length,words=[],i=0;i<hexStrLength;i+=2)words[i>>>3]|=parseInt(hexStr.substr(i,2),16)<<24-i%8*4;return new WordArray.init(words,hexStrLength/2)}},Latin1=C_enc.Latin1={stringify:function(wordArray){for(var words=wordArray.words,sigBytes=wordArray.sigBytes,latin1Chars=[],i=0;i<sigBytes;i++){var bite=words[i>>>2]>>>24-i%4*8&255;latin1Chars.push(String.fromCharCode(bite))}return latin1Chars.join("")},parse:function(latin1Str){for(var latin1StrLength=latin1Str.length,words=[],i=0;i<latin1StrLength;i++)words[i>>>2]|=(255&latin1Str.charCodeAt(i))<<24-i%4*8;return new WordArray.init(words,latin1StrLength)}},Utf8=C_enc.Utf8={stringify:function(wordArray){try{return decodeURIComponent(escape(Latin1.stringify(wordArray)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(utf8Str){return Latin1.parse(unescape(encodeURIComponent(utf8Str)))}},BufferedBlockAlgorithm=C_lib.BufferedBlockAlgorithm=Base.extend({reset:function(){this._data=new WordArray.init,this._nDataBytes=0},_append:function(data){"string"==typeof data&&(data=Utf8.parse(data)),this._data.concat(data),this._nDataBytes+=data.sigBytes},_process:function(doFlush){var processedWords,data=this._data,dataWords=data.words,dataSigBytes=data.sigBytes,blockSize=this.blockSize,nBlocksReady=dataSigBytes/(4*blockSize),nWordsReady=(nBlocksReady=doFlush?Math.ceil(nBlocksReady):Math.max((0|nBlocksReady)-this._minBufferSize,0))*blockSize,nBytesReady=Math.min(4*nWordsReady,dataSigBytes);if(nWordsReady){for(var offset=0;offset<nWordsReady;offset+=blockSize)this._doProcessBlock(dataWords,offset);processedWords=dataWords.splice(0,nWordsReady),data.sigBytes-=nBytesReady}return new WordArray.init(processedWords,nBytesReady)},clone:function(){var clone=Base.clone.call(this);return clone._data=this._data.clone(),clone},_minBufferSize:0}),C_algo=(C_lib.Hasher=BufferedBlockAlgorithm.extend({cfg:Base.extend(),init:function(cfg){this.cfg=this.cfg.extend(cfg),this.reset()},reset:function(){BufferedBlockAlgorithm.reset.call(this),this._doReset()},update:function(messageUpdate){return this._append(messageUpdate),this._process(),this},finalize:function(messageUpdate){return messageUpdate&&this._append(messageUpdate),this._doFinalize()},blockSize:16,_createHelper:function(hasher){return function(message,cfg){return new hasher.init(cfg).finalize(message)}},_createHmacHelper:function(hasher){return function(message,key){return new C_algo.HMAC.init(hasher,key).finalize(message)}}}),C.algo={});return C}(Math),CryptoJS)},98269:function(module,exports,__webpack_require__){var CryptoJS;module.exports=(CryptoJS=__webpack_require__(78249),function(){var C=CryptoJS,WordArray=C.lib.WordArray;function parseLoop(base64Str,base64StrLength,reverseMap){for(var words=[],nBytes=0,i=0;i<base64StrLength;i++)if(i%4){var bitsCombined=reverseMap[base64Str.charCodeAt(i-1)]<<i%4*2|reverseMap[base64Str.charCodeAt(i)]>>>6-i%4*2;words[nBytes>>>2]|=bitsCombined<<24-nBytes%4*8,nBytes++}return WordArray.create(words,nBytes)}C.enc.Base64={stringify:function(wordArray){var words=wordArray.words,sigBytes=wordArray.sigBytes,map=this._map;wordArray.clamp();for(var base64Chars=[],i=0;i<sigBytes;i+=3)for(var triplet=(words[i>>>2]>>>24-i%4*8&255)<<16|(words[i+1>>>2]>>>24-(i+1)%4*8&255)<<8|words[i+2>>>2]>>>24-(i+2)%4*8&255,j=0;j<4&&i+.75*j<sigBytes;j++)base64Chars.push(map.charAt(triplet>>>6*(3-j)&63));var paddingChar=map.charAt(64);if(paddingChar)for(;base64Chars.length%4;)base64Chars.push(paddingChar);return base64Chars.join("")},parse:function(base64Str){var base64StrLength=base64Str.length,map=this._map,reverseMap=this._reverseMap;if(!reverseMap){reverseMap=this._reverseMap=[];for(var j=0;j<map.length;j++)reverseMap[map.charCodeAt(j)]=j}var paddingChar=map.charAt(64);if(paddingChar){var paddingIndex=base64Str.indexOf(paddingChar);-1!==paddingIndex&&(base64StrLength=paddingIndex)}return parseLoop(base64Str,base64StrLength,reverseMap)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),CryptoJS.enc.Base64)},43786:function(module,exports,__webpack_require__){var CryptoJS;module.exports=(CryptoJS=__webpack_require__(78249),function(){var C=CryptoJS,WordArray=C.lib.WordArray;function parseLoop(base64Str,base64StrLength,reverseMap){for(var words=[],nBytes=0,i=0;i<base64StrLength;i++)if(i%4){var bitsCombined=reverseMap[base64Str.charCodeAt(i-1)]<<i%4*2|reverseMap[base64Str.charCodeAt(i)]>>>6-i%4*2;words[nBytes>>>2]|=bitsCombined<<24-nBytes%4*8,nBytes++}return WordArray.create(words,nBytes)}C.enc.Base64url={stringify:function(wordArray,urlSafe=!0){var words=wordArray.words,sigBytes=wordArray.sigBytes,map=urlSafe?this._safe_map:this._map;wordArray.clamp();for(var base64Chars=[],i=0;i<sigBytes;i+=3)for(var triplet=(words[i>>>2]>>>24-i%4*8&255)<<16|(words[i+1>>>2]>>>24-(i+1)%4*8&255)<<8|words[i+2>>>2]>>>24-(i+2)%4*8&255,j=0;j<4&&i+.75*j<sigBytes;j++)base64Chars.push(map.charAt(triplet>>>6*(3-j)&63));var paddingChar=map.charAt(64);if(paddingChar)for(;ba