(function(global,factory){true?module.exports=factory():undefined})(this,function(){"use strict";functionobjectOrFunction(x){vartype=typeofx;returnx!==null&&(type==="object"||type==="function")}functionisFunction(x){returntypeofx==="function"}var_isArray=void0;if(Array.isArray){_isArray=Array.isArray}else{_isArray=function(x){returnObject.prototype.toString.call(x)==="[object Array]"}}varisArray=_isArray;varlen=0;varvertxNext=void0;varcustomSchedulerFn=void0;varasap=functionasap(callback,arg){queue[len]=callback;queue[len+1]=arg;len+=2;if(len===2){if(customSchedulerFn){customSchedulerFn(flush)}else{scheduleFlush()}}};functionsetScheduler(scheduleFn){customSchedulerFn=scheduleFn}functionsetAsap(asapFn){asap=asapFn}varbrowserWindow=typeofwindow!=="undefined"?window:undefined;varbrowserGlobal=browserWindow||{};varBrowserMutationObserver=browserGlobal.MutationObserver||browserGlobal.WebKitMutationObserver;varisNode=typeofself==="undefined"&&typeofprocess!=="undefined"&&{}.toString.call(process)==="[object process]";varisWorker=typeofUint8ClampedArray!=="undefined"&&typeofimportScripts!=="undefined"&&typeofMessageChannel!=="undefined";functionuseNextTick(){returnfunction(){returnprocess.nextTick(flush)}}functionuseVertxTimer(){if(typeofvertxNext!=="undefined"){returnfunction(){vertxNext(flush)}}returnuseSetTimeout()}functionuseMutationObserver(){variterations=0;varobserver=newBrowserMutationObserver(flush);varnode=document.createTextNode("");observer.observe(node,{characterData:true});returnfunction(){node.data=iterations=++iterations%2}}functionuseMessageChannel(){varchannel=newMessageChannel;channel.port1.onmessage=flush;returnfunction(){returnchannel.port2.postMessage(0)}}functionuseSetTimeout(){varglobalSetTimeout=setTimeout;returnfunction(){returnglobalSetTimeout(flush,1)}}varqueue=newArray(1e3);functionflush(){for(vari=0;i<len;i+=2){varcallback=queue[i];vararg=queue[i+1];callback(arg);queue[i]=undefined;queue[i+1]=undefined}len=0}functionattemptVertx(){try{varr=require;varvertx=__webpack_require__(!functionwebpackMissingModule(){vare=newError("Cannot find module 'vertx'");e.code="MODULE_NOT_FOUND";throwe}());vertxNext=vertx.runOnLoop||vertx.runOnContext;returnuseVertxTimer()}catch(e){returnuseSetTimeout()}}varscheduleFlush=void0;if(isNode){scheduleFlush=useNextTick()}elseif(BrowserMutationObserver){scheduleFlush=useMutationObserver()}elseif(isWorker){scheduleFlush=useMessageChannel()}elseif(browserWindow===undefined&&"function"==="function"){scheduleFlush=attemptVertx()}else{scheduleFlush=useSetTimeout()}functionthen(onFulfillment,onRejection){varparent=this;varchild=newthis.constructor(noop);if(child[PROMISE_ID]===undefined){makePromise(child)}var_state=parent._state;if(_state){varcallback=arguments[_state-1];asap(function(){returninvokeCallback(_state,child,callback,parent._result)})}else{subscribe(parent,child,onFulfillment,onRejection)}returnchild}functionresolve$1(object){varConstructor=this;if(object&&typeofobject==="object"&&object.constructor===Constructor){returnobject}varpromise=newConstructor(noop);resolve(promise,object);returnpromise}varPROMISE_ID=Math.random().toString(36).substring(16);functionnoop(){}varPENDING=void0;varFULFILLED=1;varREJECTED=2;varGET_THEN_ERROR=newErrorObject;functionselfFulfillment(){returnnewTypeError("You cannot resolve a promise with itself")}functioncannotReturnOwn(){returnnewTypeError("A promises callback cannot return that same promise.")}functiongetThen(promise){try{returnpromise.then}catch(error){GET_THEN_ERROR.error=error;returnGET_THEN_ERROR}}functiontryThen(then$$1,value,fulfillmentHandler,rejectionHandler){try{then$$1.call(value,fulfillmentHandler,rejectionHandler)}catch(e){returne}}functionhandleForeignThenable(promise,thenable,then$$1){asap(function(promise){varsealed=false;varerror=tryThen(then$$1,thenable,function(value){if(sealed){return}sealed=true;if(thenable!==value){resolve(promise,value)}else{fulfill(promise,value)}},function(reason){if(sealed){return}se