test-triam-sdk-contract
Version:
triam-sdk is a library for working with the Triam Horizon server.
17 lines • 542 kB
JavaScript
!function(e){"use strict";function t(e){this.withCredentials=!1,this.responseType="",this.readyState=0,this.status=0,this.statusText="",this.responseText="",this.onprogress=y,this.onreadystatechange=y,this._contentType="",this._xhr=e,this._sendTimeout=0,this._abort=y}function r(e){this._xhr=new t(e)}function n(){this._listeners=Object.create(null)}function o(e){c(function(){throw e},0)}function i(e){this.type=e,this.target=void 0}function a(e,t){i.call(this,e),this.data=t.data,this.lastEventId=t.lastEventId}function s(e,t){n.call(this),this.onopen=void 0,this.onmessage=void 0,this.onerror=void 0,this.url=void 0,this.readyState=void 0,this.withCredentials=void 0,this._close=void 0,u(this,e,t)}function u(e,t,n){t=String(t);var s=void 0!=n&&Boolean(n.withCredentials),u=P(1e3),p=P(45e3),d="",y=u,S=!1,x=void 0!=n&&void 0!=n.headers?JSON.parse(JSON.stringify(n.headers)):void 0,j=void 0!=n&&void 0!=n.Transport?n.Transport:void 0!=h?h:l,R=new r(new j),I=0,B=v,M="",N="",U="",L="",D=_,q=0,F=0,z=function(t,r,n){if(B===g)if(200===t&&void 0!=n&&E.test(n)){B=m,S=!0,y=u,e.readyState=m;var a=new i("open");e.dispatchEvent(a),T(e,e.onopen,a)}else{var s="";200!==t?(r&&(r=r.replace(/\s+/g," ")),s="EventSource's response has a status "+t+" "+r+" that is not 200. Aborting the connection."):s="EventSource's response has a Content-Type specifying an unsupported type: "+(void 0==n?"-":n.replace(/\s+/g," "))+". Aborting the connection.",o(new Error(s)),K();var a=new i("error");e.dispatchEvent(a),T(e,e.onerror,a)}},H=function(t){if(B===m){for(var r=-1,n=0;n<t.length;n+=1){var o=t.charCodeAt(n);(o==="\n".charCodeAt(0)||o==="\r".charCodeAt(0))&&(r=n)}var i=(-1!==r?L:"")+t.slice(0,r+1);L=(-1===r?L:"")+t.slice(r+1),""!==i&&(S=!0);for(var s=0;s<i.length;s+=1){var o=i.charCodeAt(s);if(D===w&&o==="\n".charCodeAt(0))D=_;else if(D===w&&(D=_),o==="\r".charCodeAt(0)||o==="\n".charCodeAt(0)){if(D!==_){D===k&&(F=s+1);var l=i.slice(q,F-1),h=i.slice(F+(s>F&&i.charCodeAt(F)===" ".charCodeAt(0)?1:0),s);"data"===l?(M+="\n",M+=h):"id"===l?N=h:"event"===l?U=h:"retry"===l?(u=C(h,u),y=u):"heartbeatTimeout"===l&&(p=C(h,p),0!==I&&(f(I),I=c(function(){X()},p)))}if(D===_){if(""!==M){d=N,""===U&&(U="message");var v=new a(U,{data:M.slice(1),lastEventId:N});if(e.dispatchEvent(v),"message"===U&&T(e,e.onmessage,v),B===b)return}M="",U=""}D=o==="\r".charCodeAt(0)?w:_}else D===_&&(q=s,D=k),D===k?o===":".charCodeAt(0)&&(F=s+1,D=A):D===A&&(D=O)}}},V=function(){if(B===m||B===g){B=v,0!==I&&(f(I),I=0),I=c(function(){X()},y),y=P(Math.min(16*u,2*y)),e.readyState=g;var t=new i("error");e.dispatchEvent(t),T(e,e.onerror,t)}},K=function(){B=b,R.cancel(),0!==I&&(f(I),I=0),e.readyState=b},X=function(){if(I=0,B!==v)return void(S?(S=!1,I=c(function(){X()},p)):(o(new Error("No activity within "+p+" milliseconds. Reconnecting.")),R.cancel()));S=!1,I=c(function(){X()},p),B=g,M="",U="",N=d,L="",q=0,F=0,D=_;var e=t;"data:"!==t.slice(0,5)&&"blob:"!==t.slice(0,5)&&(e=t+(-1===t.indexOf("?",0)?"?":"&")+"lastEventId="+encodeURIComponent(d));var r={};if(r.Accept="text/event-stream",void 0!=x)for(var n in x)Object.prototype.hasOwnProperty.call(x,n)&&(r[n]=x[n]);try{R.open(z,H,V,e,s,r)}catch(i){throw K(),i}};e.url=t,e.readyState=g,e.withCredentials=s,e._close=K,X()}var c=e.setTimeout,f=e.clearTimeout,l=e.XMLHttpRequest,h=e.XDomainRequest,p=e.EventSource,d=e.document;null==Object.create&&(Object.create=function(e){function t(){}return t.prototype=e,new t});var y=function(){};t.prototype.open=function(e,t){this._abort(!0);var r=this,n=this._xhr,o=1,i=0;this._abort=function(e){0!==r._sendTimeout&&(f(r._sendTimeout),r._sendTimeout=0),(1===o||2===o||3===o)&&(o=4,n.onload=y,n.onerror=y,n.onabort=y,n.onprogress=y,n.onreadystatechange=y,n.abort(),0!==i&&(f(i),i=0),e||(r.readyState=4,r.onreadystatechange())),o=0};var a=function(){if(1===o){var e=0,t="",i=void 0;if("contentType"in n)e=200,t="OK",i=n.contentType;else try{e=n.status,t=n.statusText,i=n.getResponseHeader("Content-Type")}catch(a){e=0,t="",i=void 0}0!==e&&(o=2,r.readyState=2,r.status=e,r.statusText=t,r._contentType=i,r.onreadystatechange())}},s=function(){if(a(),2===o||3===o){o=3;var e="";try{e=n.responseText}catch(t){}r.readyState=3,r.responseText=e,r.onprogress()}},u=function(){s(),(1===o||2===o||3===o)&&(o=4,0!==i&&(f(i),i=0),r.readyState=4,r.onreadystatechange())},h=function(){void 0!=n&&(4===n.readyState?u():3===n.readyState?s():2===n.readyState&&a())},p=function(){i=c(function(){p()},500),3===n.readyState&&s()};n.onload=u,n.onerror=u,n.onabort=u,"sendAsBinary"in l.prototype||"mozAnon"in l.prototype||(n.onprogress=s),n.onreadystatechange=h,"contentType"in n&&(t+=(-1===t.indexOf("?",0)?"?":"&")+"padding=true"),n.open(e,t,!0),"readyState"in n&&(i=c(function(){p()},0))},t.prototype.abort=function(){this._abort(!1)},t.prototype.getResponseHeader=function(){return this._contentType},t.prototype.setRequestHeader=function(e,t){var r=this._xhr;"setRequestHeader"in r&&r.setRequestHeader(e,t)},t.prototype.send=function(){if(!("ontimeout"in l.prototype)&&void 0!=d&&void 0!=d.readyState&&"complete"!==d.readyState){var e=this;return void(e._sendTimeout=c(function(){e._sendTimeout=0,e.send()},4))}var t=this._xhr;t.withCredentials=this.withCredentials,t.responseType=this.responseType;try{t.send(void 0)}catch(r){throw r}},r.prototype.open=function(e,t,r,n,o,i){var a=this._xhr;a.open("GET",n);var s=0;a.onprogress=function(){var e=a.responseText,r=e.slice(s);s+=r.length,t(r)},a.onreadystatechange=function(){if(2===a.readyState){var t=a.status,n=a.statusText,o=a.getResponseHeader("Content-Type");e(t,n,o)}else 4===a.readyState&&r()},a.withCredentials=o,a.responseType="text";for(var u in i)Object.prototype.hasOwnProperty.call(i,u)&&a.setRequestHeader(u,i[u]);a.send()},r.prototype.cancel=function(){var e=this._xhr;e.abort()},n.prototype.dispatchEvent=function(e){e.target=this;var t=this._listeners[e.type];if(void 0!=t)for(var r=t.length,n=0;r>n;n+=1){var i=t[n];try{"function"==typeof i.handleEvent?i.handleEvent(e):i.call(this,e)}catch(a){o(a)}}},n.prototype.addEventListener=function(e,t){e=String(e);var r=this._listeners,n=r[e];void 0==n&&(n=[],r[e]=n);for(var o=!1,i=0;i<n.length;i+=1)n[i]===t&&(o=!0);o||n.push(t)},n.prototype.removeEventListener=function(e,t){e=String(e);var r=this._listeners,n=r[e];if(void 0!=n){for(var o=[],i=0;i<n.length;i+=1)n[i]!==t&&o.push(n[i]);0===o.length?delete r[e]:r[e]=o}},a.prototype=Object.create(i.prototype);var v=-1,g=0,m=1,b=2,w=-1,_=0,k=1,A=2,O=3,E=/^text\/event\-stream;?(\s*charset\=utf\-8)?$/i,S=1e3,x=18e6,C=function(e,t){var r=parseInt(e,10);return r!==r&&(r=t),P(r)},P=function(e){return Math.min(Math.max(e,S),x)},T=function(e,t,r){try{"function"==typeof t&&t.call(e,r)}catch(n){o(n)}};s.prototype=Object.create(n.prototype),s.prototype.CONNECTING=g,s.prototype.OPEN=m,s.prototype.CLOSED=b,s.prototype.close=function(){this._close()},s.CONNECTING=g,s.OPEN=m,s.CLOSED=b,s.prototype.withCredentials=void 0,e.EventSourcePolyfill=s,e.NativeEventSource=p,void 0==l||void 0!=p&&"withCredentials"in p.prototype||(e.EventSource=s)}("undefined"!=typeof window?window:this);var StellarSdk=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={exports:{},id:n,loaded:!1};return e[n].call(o.exports,o,o.exports,t),o.loaded=!0,o.exports}var r={};return t.m=e,t.c=r,t.p="",t(0)}([function(e,t,r){"use strict";e.exports=r(1),e.exports.axios=r(129),e.exports.StellarBase=r(203)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(2);Object.keys(n).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return n[e]}})});var o=r(3);Object.defineProperty(t,"Config",{enumerable:!0,get:function(){return o.Config}});var i=r(113);Object.defineProperty(t,"Server",{enumerable:!0,get:function(){return i.Server}});var a=r(443);Object.defineProperty(t,"FederationServer",{enumerable:!0,get:function(){return a.FederationServer}}),Object.defineProperty(t,"FEDERATION_RESPONSE_MAX_SIZE",{enumerable:!0,get:function(){return a.FEDERATION_RESPONSE_MAX_SIZE}});var s=r(452);Object.defineProperty(t,"StellarTomlResolver",{enumerable:!0,get:function(){return s.StellarTomlResolver}}),Object.defineProperty(t,"STELLAR_TOML_MAX_SIZE",{enumerable:!0,get:function(){return s.STELLAR_TOML_MAX_SIZE}});var u=r(456);Object.defineProperty(t,"CoreConnection",{enumerable:!0,get:function(){return u.CoreConnection}});var c=r(203);Object.keys(c).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return c[e]}})}),r(457).polyfill(),t.default=e.exports},function(e,t){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function i(e){function t(){var t=Reflect.construct(e,Array.from(arguments));return Object.setPrototypeOf(t,Object.getPrototypeOf(this)),t}return t.prototype=Object.create(e.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e,t}Object.defineProperty(t,"__esModule",{value:!0});{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=t.NetworkError=function(e){function t(e,o){r(this,t);var i=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return i.constructor=t,i.response=o,i}return o(t,e),a(t,[{key:"getResponse",value:function(){return this.response}}]),t}(i(Error));t.NotFoundError=function(e){function t(e,o){r(this,t);var i=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,o));return i.constructor=t,i}return o(t,e),t}(s),t.BadRequestError=function(e){function t(e,o){r(this,t);var i=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,o));return i.constructor=t,i}return o(t,e),t}(s),t.BadResponseError=function(e){function t(e,o){r(this,t);var i=n(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,o));return i.constructor=t,i}return o(t,e),t}(s)}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Config=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(4),s=n(a),u={allowHttp:!1,timeout:0},c=s.default(u),f=function(){function e(){o(this,e)}return i(e,null,[{key:"setAllowHttp",value:function(e){c.allowHttp=e}},{key:"setTimeout",value:function(e){c.timeout=e}},{key:"isAllowHttp",value:function(){return s.default(c.allowHttp)}},{key:"getTimeout",value:function(){return s.default(c.timeout)}},{key:"setDefault",value:function(){c=s.default(u)}}]),e}();t.Config=f},function(e,t,r){function n(e){return o(e,i)}var o=r(5),i=4;e.exports=n},function(e,t,r){function n(e,t,r,P,T,j){var R,M=t&E,N=t&S,L=t&x;if(r&&(R=T?r(e,P,T,j):r(e)),void 0!==R)return R;if(!k(e))return e;var D=b(e);if(D){if(R=v(e),!M)return f(e,R)}else{var q=y(e),F=q==I||q==B;if(w(e))return c(e,M);if(q==U||q==C||F&&!T){if(R=N||F?{}:m(e),!M)return N?h(e,u(R,e)):l(e,s(R,e))}else{if(!et[q])return T?e:{};R=g(e,q,M)}}j||(j=new o);var z=j.get(e);if(z)return z;j.set(e,R),A(e)?e.forEach(function(o){R.add(n(o,t,r,o,e,j))}):_(e)&&e.forEach(function(o,i){R.set(i,n(o,t,r,i,e,j))});var H=L?N?d:p:N?keysIn:O,V=D?void 0:H(e);return i(V||e,function(o,i){V&&(i=o,o=e[i]),a(R,i,n(o,t,r,i,e,j))}),R}var o=r(6),i=r(50),a=r(51),s=r(54),u=r(77),c=r(81),f=r(82),l=r(83),h=r(87),p=r(91),d=r(93),y=r(94),v=r(99),g=r(100),m=r(107),b=r(62),w=r(63),_=r(109),k=r(30),A=r(111),O=r(56),E=1,S=2,x=4,C="[object Arguments]",P="[object Array]",T="[object Boolean]",j="[object Date]",R="[object Error]",I="[object Function]",B="[object GeneratorFunction]",M="[object Map]",N="[object Number]",U="[object Object]",L="[object RegExp]",D="[object Set]",q="[object String]",F="[object Symbol]",z="[object WeakMap]",H="[object ArrayBuffer]",V="[object DataView]",K="[object Float32Array]",X="[object Float64Array]",Q="[object Int8Array]",Y="[object Int16Array]",$="[object Int32Array]",W="[object Uint8Array]",Z="[object Uint8ClampedArray]",G="[object Uint16Array]",J="[object Uint32Array]",et={};et[C]=et[P]=et[H]=et[V]=et[T]=et[j]=et[K]=et[X]=et[Q]=et[Y]=et[$]=et[M]=et[N]=et[U]=et[L]=et[D]=et[q]=et[F]=et[W]=et[Z]=et[G]=et[J]=!0,et[R]=et[I]=et[z]=!1,e.exports=n},function(e,t,r){function n(e){var t=this.__data__=new o(e);this.size=t.size}var o=r(7),i=r(15),a=r(16),s=r(17),u=r(18),c=r(19);n.prototype.clear=i,n.prototype["delete"]=a,n.prototype.get=s,n.prototype.has=u,n.prototype.set=c,e.exports=n},function(e,t,r){function n(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}var o=r(8),i=r(9),a=r(12),s=r(13),u=r(14);n.prototype.clear=o,n.prototype["delete"]=i,n.prototype.get=a,n.prototype.has=s,n.prototype.set=u,e.exports=n},function(e){function t(){this.__data__=[],this.size=0}e.exports=t},function(e,t,r){function n(e){var t=this.__data__,r=o(t,e);if(0>r)return!1;var n=t.length-1;return r==n?t.pop():a.call(t,r,1),--this.size,!0}var o=r(10),i=Array.prototype,a=i.splice;e.exports=n},function(e,t,r){function n(e,t){for(var r=e.length;r--;)if(o(e[r][0],t))return r;return-1}var o=r(11);e.exports=n},function(e){function t(e,t){return e===t||e!==e&&t!==t}e.exports=t},function(e,t,r){function n(e){var t=this.__data__,r=o(t,e);return 0>r?void 0:t[r][1]}var o=r(10);e.exports=n},function(e,t,r){function n(e){return o(this.__data__,e)>-1}var o=r(10);e.exports=n},function(e,t,r){function n(e,t){var r=this.__data__,n=o(r,e);return 0>n?(++this.size,r.push([e,t])):r[n][1]=t,this}var o=r(10);e.exports=n},function(e,t,r){function n(){this.__data__=new o,this.size=0}var o=r(7);e.exports=n},function(e){function t(e){var t=this.__data__,r=t["delete"](e);return this.size=t.size,r}e.exports=t},function(e){function t(e){return this.__data__.get(e)}e.exports=t},function(e){function t(e){return this.__data__.has(e)}e.exports=t},function(e,t,r){function n(e,t){var r=this.__data__;if(r instanceof o){var n=r.__data__;if(!i||n.length<s-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new a(n)}return r.set(e,t),this.size=r.size,this}var o=r(7),i=r(20),a=r(35),s=200;e.exports=n},function(e,t,r){var n=r(21),o=r(26),i=n(o,"Map");e.exports=i},function(e,t,r){function n(e,t){var r=i(e,t);return o(r)?r:void 0}var o=r(22),i=r(34);e.exports=n},function(e,t,r){function n(e){if(!a(e)||i(e))return!1;var t=o(e)?d:c;return t.test(s(e))}var o=r(23),i=r(31),a=r(30),s=r(33),u=/[\\^$.*+?()[\]{}|]/g,c=/^\[object .+?Constructor\]$/,f=Function.prototype,l=Object.prototype,h=f.toString,p=l.hasOwnProperty,d=RegExp("^"+h.call(p).replace(u,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=n},function(e,t,r){function n(e){if(!i(e))return!1;var t=o(e);return t==s||t==u||t==a||t==c}var o=r(24),i=r(30),a="[object AsyncFunction]",s="[object Function]",u="[object GeneratorFunction]",c="[object Proxy]";e.exports=n},function(e,t,r){function n(e){return null==e?void 0===e?u:s:c&&c in Object(e)?i(e):a(e)}var o=r(25),i=r(28),a=r(29),s="[object Null]",u="[object Undefined]",c=o?o.toStringTag:void 0;e.exports=n},function(e,t,r){var n=r(26),o=n.Symbol;e.exports=o},function(e,t,r){var n=r(27),o="object"==typeof self&&self&&self.Object===Object&&self,i=n||o||Function("return this")();e.exports=i},function(e,t){(function(t){var r="object"==typeof t&&t&&t.Object===Object&&t;e.exports=r}).call(t,function(){return this}())},function(e,t,r){function n(e){var t=a.call(e,u),r=e[u];try{e[u]=void 0;var n=!0}catch(o){}var i=s.call(e);return n&&(t?e[u]=r:delete e[u]),i}var o=r(25),i=Object.prototype,a=i.hasOwnProperty,s=i.toString,u=o?o.toStringTag:void 0;e.exports=n},function(e){function t(e){return n.call(e)}var r=Object.prototype,n=r.toString;e.exports=t},function(e){function t(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}e.exports=t},function(e,t,r){function n(e){return!!i&&i in e}var o=r(32),i=function(){var e=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();e.exports=n},function(e,t,r){var n=r(26),o=n["__core-js_shared__"];e.exports=o},function(e){function t(e){if(null!=e){try{return n.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var r=Function.prototype,n=r.toString;e.exports=t},function(e){function t(e,t){return null==e?void 0:e[t]}e.exports=t},function(e,t,r){function n(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}var o=r(36),i=r(44),a=r(47),s=r(48),u=r(49);n.prototype.clear=o,n.prototype["delete"]=i,n.prototype.get=a,n.prototype.has=s,n.prototype.set=u,e.exports=n},function(e,t,r){function n(){this.size=0,this.__data__={hash:new o,map:new(a||i),string:new o}}var o=r(37),i=r(7),a=r(20);e.exports=n},function(e,t,r){function n(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}var o=r(38),i=r(40),a=r(41),s=r(42),u=r(43);n.prototype.clear=o,n.prototype["delete"]=i,n.prototype.get=a,n.prototype.has=s,n.prototype.set=u,e.exports=n},function(e,t,r){function n(){this.__data__=o?o(null):{},this.size=0}var o=r(39);e.exports=n},function(e,t,r){var n=r(21),o=n(Object,"create");e.exports=o},function(e){function t(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}e.exports=t},function(e,t,r){function n(e){var t=this.__data__;if(o){var r=t[e];return r===i?void 0:r}return s.call(t,e)?t[e]:void 0}var o=r(39),i="__lodash_hash_undefined__",a=Object.prototype,s=a.hasOwnProperty;e.exports=n},function(e,t,r){function n(e){var t=this.__data__;return o?void 0!==t[e]:a.call(t,e)}var o=r(39),i=Object.prototype,a=i.hasOwnProperty;e.exports=n},function(e,t,r){function n(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=o&&void 0===t?i:t,this}var o=r(39),i="__lodash_hash_undefined__";e.exports=n},function(e,t,r){function n(e){var t=o(this,e)["delete"](e);return this.size-=t?1:0,t}var o=r(45);e.exports=n},function(e,t,r){function n(e,t){var r=e.__data__;return o(t)?r["string"==typeof t?"string":"hash"]:r.map}var o=r(46);e.exports=n},function(e){function t(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}e.exports=t},function(e,t,r){function n(e){return o(this,e).get(e)}var o=r(45);e.exports=n},function(e,t,r){function n(e){return o(this,e).has(e)}var o=r(45);e.exports=n},function(e,t,r){function n(e,t){var r=o(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var o=r(45);e.exports=n},function(e){function t(e,t){for(var r=-1,n=null==e?0:e.length;++r<n&&t(e[r],r,e)!==!1;);return e}e.exports=t},function(e,t,r){function n(e,t,r){var n=e[t];s.call(e,t)&&i(n,r)&&(void 0!==r||t in e)||o(e,t,r)}var o=r(52),i=r(11),a=Object.prototype,s=a.hasOwnProperty;e.exports=n},function(e,t,r){function n(e,t,r){"__proto__"==t&&o?o(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var o=r(53);e.exports=n},function(e,t,r){var n=r(21),o=function(){try{var e=n(Object,"defineProperty");return e({},"",{}),e}catch(t){}}();e.exports=o},function(e,t,r){function n(e,t){return e&&o(t,i(t),e)}var o=r(55),i=r(56);e.exports=n},function(e,t,r){function n(e,t,r,n){var a=!r;r||(r={});for(var s=-1,u=t.length;++s<u;){var c=t[s],f=n?n(r[c],e[c],c,r,e):void 0;void 0===f&&(f=e[c]),a?i(r,c,f):o(r,c,f)}return r}var o=r(51),i=r(52);e.exports=n},function(e,t,r){function n(e){return a(e)?o(e):i(e)}var o=r(57),i=r(72),a=r(76);e.exports=n},function(e,t,r){function n(e,t){var r=a(e),n=!r&&i(e),f=!r&&!n&&s(e),h=!r&&!n&&!f&&c(e),p=r||n||f||h,d=p?o(e.length,String):[],y=d.length;for(var v in e)!t&&!l.call(e,v)||p&&("length"==v||f&&("offset"==v||"parent"==v)||h&&("buffer"==v||"byteLength"==v||"byteOffset"==v)||u(v,y))||d.push(v);return d}var o=r(58),i=r(59),a=r(62),s=r(63),u=r(66),c=r(67),f=Object.prototype,l=f.hasOwnProperty;e.exports=n},function(e){function t(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}e.exports=t},function(e,t,r){var n=r(60),o=r(61),i=Object.prototype,a=i.hasOwnProperty,s=i.propertyIsEnumerable,u=n(function(){return arguments}())?n:function(e){return o(e)&&a.call(e,"callee")&&!s.call(e,"callee")};e.exports=u},function(e,t,r){function n(e){return i(e)&&o(e)==a}var o=r(24),i=r(61),a="[object Arguments]";e.exports=n},function(e){function t(e){return null!=e&&"object"==typeof e}e.exports=t},function(e){var t=Array.isArray;e.exports=t},function(e,t,r){(function(e){var n=r(26),o=r(65),i="object"==typeof t&&t&&!t.nodeType&&t,a=i&&"object"==typeof e&&e&&!e.nodeType&&e,s=a&&a.exports===i,u=s?n.Buffer:void 0,c=u?u.isBuffer:void 0,f=c||o;e.exports=f}).call(t,r(64)(e))},function(e){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children=[],e.webpackPolyfill=1),e}},function(e){function t(){return!1}e.exports=t},function(e){function t(e,t){var o=typeof e;return t=null==t?r:t,!!t&&("number"==o||"symbol"!=o&&n.test(e))&&e>-1&&e%1==0&&t>e}var r=9007199254740991,n=/^(?:0|[1-9]\d*)$/;e.exports=t},function(e,t,r){var n=r(68),o=r(70),i=r(71),a=i&&i.isTypedArray,s=a?o(a):n;e.exports=s},function(e,t,r){function n(e){return a(e)&&i(e.length)&&!!j[o(e)]}var o=r(24),i=r(69),a=r(61),s="[object Arguments]",u="[object Array]",c="[object Boolean]",f="[object Date]",l="[object Error]",h="[object Function]",p="[object Map]",d="[object Number]",y="[object Object]",v="[object RegExp]",g="[object Set]",m="[object String]",b="[object WeakMap]",w="[object ArrayBuffer]",_="[object DataView]",k="[object Float32Array]",A="[object Float64Array]",O="[object Int8Array]",E="[object Int16Array]",S="[object Int32Array]",x="[object Uint8Array]",C="[object Uint8ClampedArray]",P="[object Uint16Array]",T="[object Uint32Array]",j={};j[k]=j[A]=j[O]=j[E]=j[S]=j[x]=j[C]=j[P]=j[T]=!0,j[s]=j[u]=j[w]=j[c]=j[_]=j[f]=j[l]=j[h]=j[p]=j[d]=j[y]=j[v]=j[g]=j[m]=j[b]=!1,e.exports=n},function(e){function t(e){return"number"==typeof e&&e>-1&&e%1==0&&r>=e}var r=9007199254740991;e.exports=t},function(e){function t(e){return function(t){return e(t)}}e.exports=t},function(e,t,r){(function(e){var n=r(27),o="object"==typeof t&&t&&!t.nodeType&&t,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,a=i&&i.exports===o,s=a&&n.process,u=function(){try{var e=i&&i.require&&i.require("util").types;return e?e:s&&s.binding&&s.binding("util")}catch(t){}}();e.exports=u}).call(t,r(64)(e))},function(e,t,r){function n(e){if(!o(e))return i(e);var t=[];for(var r in Object(e))s.call(e,r)&&"constructor"!=r&&t.push(r);return t}var o=r(73),i=r(74),a=Object.prototype,s=a.hasOwnProperty;e.exports=n},function(e){function t(e){var t=e&&e.constructor,n="function"==typeof t&&t.prototype||r;return e===n}var r=Object.prototype;e.exports=t},function(e,t,r){var n=r(75),o=n(Object.keys,Object);e.exports=o},function(e){function t(e,t){return function(r){return e(t(r))}}e.exports=t},function(e,t,r){function n(e){return null!=e&&i(e.length)&&!o(e)}var o=r(23),i=r(69);e.exports=n},function(e,t,r){function n(e,t){return e&&o(t,i(t),e)}var o=r(55),i=r(78);e.exports=n},function(e,t,r){function n(e){return a(e)?o(e,!0):i(e)}var o=r(57),i=r(79),a=r(76);e.exports=n},function(e,t,r){function n(e){if(!o(e))return a(e);var t=i(e),r=[];for(var n in e)("constructor"!=n||!t&&u.call(e,n))&&r.push(n);return r}var o=r(30),i=r(73),a=r(80),s=Object.prototype,u=s.hasOwnProperty;e.exports=n},function(e){function t(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t}e.exports=t},function(e,t,r){(function(e){function n(e,t){if(t)return e.slice();var r=e.length,n=c?c(r):new e.constructor(r);return e.copy(n),n}var o=r(26),i="object"==typeof t&&t&&!t.nodeType&&t,a=i&&"object"==typeof e&&e&&!e.nodeType&&e,s=a&&a.exports===i,u=s?o.Buffer:void 0,c=u?u.allocUnsafe:void 0;e.exports=n}).call(t,r(64)(e))},function(e){function t(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}e.exports=t},function(e,t,r){function n(e,t){return o(e,i(e),t)}var o=r(55),i=r(84);e.exports=n},function(e,t,r){var n=r(85),o=r(86),i=Object.prototype,a=i.propertyIsEnumerable,s=Object.getOwnPropertySymbols,u=s?function(e){return null==e?[]:(e=Object(e),n(s(e),function(t){return a.call(e,t)}))}:o;e.exports=u},function(e){function t(e,t){for(var r=-1,n=null==e?0:e.length,o=0,i=[];++r<n;){var a=e[r];t(a,r,e)&&(i[o++]=a)}return i}e.exports=t},function(e){function t(){return[]}e.exports=t},function(e,t,r){function n(e,t){return o(e,i(e),t)}var o=r(55),i=r(88);e.exports=n},function(e,t,r){var n=r(89),o=r(90),i=r(84),a=r(86),s=Object.getOwnPropertySymbols,u=s?function(e){for(var t=[];e;)n(t,i(e)),e=o(e);return t}:a;e.exports=u},function(e){function t(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}e.exports=t},function(e,t,r){var n=r(75),o=n(Object.getPrototypeOf,Object);e.exports=o},function(e,t,r){function n(e){return o(e,a,i)}var o=r(92),i=r(84),a=r(56);e.exports=n},function(e,t,r){function n(e,t,r){var n=t(e);return i(e)?n:o(n,r(e))}var o=r(89),i=r(62);e.exports=n},function(e,t,r){function n(e){return o(e,a,i)}var o=r(92),i=r(88),a=r(78);e.exports=n},function(e,t,r){var n=r(95),o=r(20),i=r(96),a=r(97),s=r(98),u=r(24),c=r(33),f="[object Map]",l="[object Object]",h="[object Promise]",p="[object Set]",d="[object WeakMap]",y="[object DataView]",v=c(n),g=c(o),m=c(i),b=c(a),w=c(s),_=u;(n&&_(new n(new ArrayBuffer(1)))!=y||o&&_(new o)!=f||i&&_(i.resolve())!=h||a&&_(new a)!=p||s&&_(new s)!=d)&&(_=function(e){var t=u(e),r=t==l?e.constructor:void 0,n=r?c(r):"";if(n)switch(n){case v:return y;case g:return f;case m:return h;case b:return p;case w:return d}return t}),e.exports=_},function(e,t,r){var n=r(21),o=r(26),i=n(o,"DataView");e.exports=i},function(e,t,r){var n=r(21),o=r(26),i=n(o,"Promise");e.exports=i},function(e,t,r){var n=r(21),o=r(26),i=n(o,"Set");e.exports=i},function(e,t,r){var n=r(21),o=r(26),i=n(o,"WeakMap");e.exports=i},function(e){function t(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&n.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var r=Object.prototype,n=r.hasOwnProperty;e.exports=t},function(e,t,r){function n(e,t,r){var n=e.constructor;switch(t){case g:return o(e);case c:case f:return new n(+e);case m:return i(e,r);case b:case w:case _:case k:case A:case O:case E:case S:case x:return u(e,r);case l:return new n;case h:case y:return new n(e);case p:return a(e);case d:return new n;case v:return s(e)}}var o=r(101),i=r(103),a=r(104),s=r(105),u=r(106),c="[object Boolean]",f="[object Date]",l="[object Map]",h="[object Number]",p="[object RegExp]",d="[object Set]",y="[object String]",v="[object Symbol]",g="[object ArrayBuffer]",m="[object DataView]",b="[object Float32Array]",w="[object Float64Array]",_="[object Int8Array]",k="[object Int16Array]",A="[object Int32Array]",O="[object Uint8Array]",E="[object Uint8ClampedArray]",S="[object Uint16Array]",x="[object Uint32Array]";e.exports=n},function(e,t,r){function n(e){var t=new e.constructor(e.byteLength);return new o(t).set(new o(e)),t}var o=r(102);e.exports=n},function(e,t,r){var n=r(26),o=n.Uint8Array;e.exports=o},function(e,t,r){function n(e,t){var r=t?o(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var o=r(101);e.exports=n},function(e){function t(e){var t=new e.constructor(e.source,r.exec(e));return t.lastIndex=e.lastIndex,t}var r=/\w*$/;e.exports=t},function(e,t,r){function n(e){return a?Object(a.call(e)):{}}var o=r(25),i=o?o.prototype:void 0,a=i?i.valueOf:void 0;e.exports=n},function(e,t,r){function n(e,t){var r=t?o(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var o=r(101);e.exports=n},function(e,t,r){function n(e){return"function"!=typeof e.constructor||a(e)?{}:o(i(e))}var o=r(108),i=r(90),a=r(73);e.exports=n},function(e,t,r){var n=r(30),o=Object.create,i=function(){function e(){}return function(t){if(!n(t))return{};if(o)return o(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();e.exports=i},function(e,t,r){var n=r(110),o=r(70),i=r(71),a=i&&i.isMap,s=a?o(a):n;e.exports=s},function(e,t,r){function n(e){return i(e)&&o(e)==a}var o=r(94),i=r(61),a="[object Map]";e.exports=n},function(e,t,r){var n=r(112),o=r(70),i=r(71),a=i&&i.isSet,s=a?o(a):n;e.exports=s},function(e,t,r){function n(e){return i(e)&&o(e)==a}var o=r(94),i=r(61),a="[object Set]";e.exports=n},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Server=t.SUBMIT_TRANSACTION_TIMEOUT=void 0;{var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(2),s=r(114),u=r(202),c=r(3),f=r(431),l=r(432),h=r(433),p=r(434),d=r(435),y=r(436),v=r(437),g=r(438),m=r(439),b=r(440),w=r(441),_=r(442),k=(r(203),r(240)),A=(n(k),r(129)),O=r(124),E=(r(124).URITemplate,t.SUBMIT_TRANSACTION_TIMEOUT=6e4);t.Server=function(){function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};o(this,e),this.serverURL=O(t);var n=c.Config.isAllowHttp();if("undefined"!=typeof r.allowHttp&&(n=r.allowHttp),"https"!=this.serverURL.protocol()&&!n)throw new Error("Cannot connect to insecure horizon server")}return i(e,[{key:"submitTransaction",value:function(e){var t=encodeURIComponent(e.toEnvelope().toXDR().toString("base64"));return A.post(O(this.serverURL).segment("transactions").toString(),"tx="+t,{timeout:E}).then(function(e){return e.data}).catch(function(e){return e instanceof Error?Promise.reject(e):Promise.reject(new a.BadResponseError("Transaction submission failed. Server responded: "+e.status+" "+e.statusText,e.data))})}},{key:"accounts",value:function(){return new s.AccountCallBuilder(O(this.serverURL))}},{key:"contractstate",value:function(){return new ContractStateCallBuilder(O(this.serverURL))}},{key:"ledgers",value:function(){return new f.LedgerCallBuilder(O(this.serverURL))}},{key:"transactions",value:function(){return new l.TransactionCallBuilder(O(this.serverURL))}},{key:"offers",value:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;t>n;n++)r[n-1]=arguments[n];return new(Function.prototype.bind.apply(p.OfferCallBuilder,[null].concat([O(this.serverURL),e],r)))}},{key:"orderbook",value:function(e,t){return new d.OrderbookCallBuilder(O(this.serverURL),e,t)}},{key:"trades",value:function(){return new y.TradesCallBuilder(O(this.serverURL))}},{key:"operations",value:function(){return new h.OperationCallBuilder(O(this.serverURL))}},{key:"paths",value:function(e,t,r,n){return new v.PathCallBuilder(O(this.serverURL),e,t,r,n)}},{key:"payments",value:function(){return new g.PaymentCallBuilder(O(this.serverURL))}},{key:"effects",value:function(){return new m.EffectCallBuilder(O(this.serverURL))}},{key:"friendbot",value:function(e){return new b.FriendbotBuilder(O(this.serverURL),e)}},{key:"assets",value:function(){return new w.AssetsCallBuilder(O(this.serverURL))}},{key:"loadAccount",value:function(e){return this.accounts().accountId(e).call().then(function(e){return new u.AccountResponse(e)})}},{key:"tradeAggregation",value:function(e,t,r,n,o,i){return new _.TradeAggregationCallBuilder(O(this.serverURL),e,t,r,n,o,i)
}}]),e}()}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.AccountCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.AccountCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("accounts"),r}return i(t,e),a(t,[{key:"accountId",value:function(e){return this.filter.push(["accounts",e]),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.CallBuilder=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(2),s=r(116),u=n(s),c=r(124),f=r(128),l=r(129),h="undefined"==typeof window?r(155):window.EventSource,p=function(){function e(t){o(this,e),this.url=t,this.filter=[],this.originalSegments=this.url.segment()||[]}return i(e,[{key:"checkFilter",value:function(){if(this.filter.length>=2)throw new a.BadRequestError("Too many filters specified",this.filter);if(1===this.filter.length){var e=this.originalSegments.concat(this.filter[0]);this.url.segment(e)}}},{key:"call",value:function(){var e=this;return this.checkFilter(),this._sendNormalRequest(this.url).then(function(t){return e._parseResponse(t)})}},{key:"stream",value:function(e){var t=this;this.checkFilter();var r=void 0,n=void 0,o=function(){n=setTimeout(function(){r.close(),r=i()},e.reconnectTimeout||15e3)},i=function(){try{r=new h(t.url.toString())}catch(i){return e.onerror&&(e.onerror(i),e.onerror("EventSource not supported")),!1}return o(),r.onmessage=function(r){var i=r.data?t._parseRecord(JSON.parse(r.data)):r;i.paging_token&&t.url.setQuery("cursor",i.paging_token),clearTimeout(n),o(),e.onmessage(i)},r.onerror=function(t){e.onerror&&e.onerror(t)},r};return i(),function(){clearTimeout(n),r.close()}}},{key:"_requestFnForLink",value:function(e){var t=this;return function(r){var n=void 0;if(e.templated){var o=f(e.href);n=c(o.expand(r||{}))}else n=c(e.href);return t._sendNormalRequest(n).then(function(e){return t._parseResponse(e)})}}},{key:"_parseRecord",value:function(e){var t=this;return e._links?(u.default(e._links,function(r,n){"undefined"!=typeof e[n]&&(e[n+"_attr"]=e[n]),e[n]=t._requestFnForLink(r)}),e):e}},{key:"_sendNormalRequest",value:function(e){return""===e.authority()&&(e=e.authority(this.url.authority())),""===e.protocol()&&(e=e.protocol(this.url.protocol())),e.setQuery("c",Math.random()),l.get(e.toString()).then(function(e){return e.data}).catch(this._handleNetworkError)}},{key:"_parseResponse",value:function(e){return e._embedded&&e._embedded.records?this._toCollectionPage(e):this._parseRecord(e)}},{key:"_toCollectionPage",value:function(e){for(var t=this,r=0;r<e._embedded.records.length;r++)e._embedded.records[r]=this._parseRecord(e._embedded.records[r]);return{records:e._embedded.records,next:function(){return t._sendNormalRequest(c(e._links.next.href)).then(function(e){return t._toCollectionPage(e)})},prev:function(){return t._sendNormalRequest(c(e._links.prev.href)).then(function(e){return t._toCollectionPage(e)})}}}},{key:"_handleNetworkError",value:function(e){if(!e.response||!e.response.status)return Promise.reject(new Error(e));switch(e.response.status){case 404:return Promise.reject(new a.NotFoundError(e.response.statusText,e.response.data));default:return Promise.reject(new a.NetworkError(e.response.statusText,e.response.data))}}},{key:"cursor",value:function(e){return this.url.setQuery("cursor",e),this}},{key:"limit",value:function(e){return this.url.setQuery("limit",e),this}},{key:"order",value:function(e){return this.url.setQuery("order",e),this}}]),e}();t.CallBuilder=p},function(e,t,r){function n(e,t){var r=s(e)?o:i;return r(e,a(t))}var o=r(50),i=r(117),a=r(122),s=r(62);e.exports=n},function(e,t,r){var n=r(118),o=r(121),i=o(n);e.exports=i},function(e,t,r){function n(e,t){return e&&o(e,t,i)}var o=r(119),i=r(56);e.exports=n},function(e,t,r){var n=r(120),o=n();e.exports=o},function(e){function t(e){return function(t,r,n){for(var o=-1,i=Object(t),a=n(t),s=a.length;s--;){var u=a[e?s:++o];if(r(i[u],u,i)===!1)break}return t}}e.exports=t},function(e,t,r){function n(e,t){return function(r,n){if(null==r)return r;if(!o(r))return e(r,n);for(var i=r.length,a=t?i:-1,s=Object(r);(t?a--:++a<i)&&n(s[a],a,s)!==!1;);return r}}var o=r(76);e.exports=n},function(e,t,r){function n(e){return"function"==typeof e?e:o}var o=r(123);e.exports=n},function(e){function t(e){return e}e.exports=t},function(e,t,r){var n,o,i;!function(a,s){"use strict";"object"==typeof e&&e.exports?e.exports=s(r(125),r(126),r(127)):(o=[r(125),r(126),r(127)],n=s,i="function"==typeof n?n.apply(t,o):n,!(void 0!==i&&(e.exports=i)))}(this,function(e,t,r,n){"use strict";function o(e,t){var r=arguments.length>=1,n=arguments.length>=2;if(!(this instanceof o))return r?n?new o(e,t):new o(e):new o;if(void 0===e){if(r)throw new TypeError("undefined is not a valid argument for URI");e="undefined"!=typeof location?location.href+"":""}if(null===e&&r)throw new TypeError("null is not a valid argument for URI");return this.href(e),void 0!==t?this.absoluteTo(t):this}function i(e){return/^[0-9]+$/.test(e)}function a(e){return e.replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}function s(e){return void 0===e?"Undefined":String(Object.prototype.toString.call(e)).slice(8,-1)}function u(e){return"Array"===s(e)}function c(e,t){var r,n,o={};if("RegExp"===s(t))o=null;else if(u(t))for(r=0,n=t.length;n>r;r++)o[t[r]]=!0;else o[t]=!0;for(r=0,n=e.length;n>r;r++){var i=o&&void 0!==o[e[r]]||!o&&t.test(e[r]);i&&(e.splice(r,1),n--,r--)}return e}function f(e,t){var r,n;if(u(t)){for(r=0,n=t.length;n>r;r++)if(!f(e,t[r]))return!1;return!0}var o=s(t);for(r=0,n=e.length;n>r;r++)if("RegExp"===o){if("string"==typeof e[r]&&e[r].match(t))return!0}else if(e[r]===t)return!0;return!1}function l(e,t){if(!u(e)||!u(t))return!1;if(e.length!==t.length)return!1;e.sort(),t.sort();for(var r=0,n=e.length;n>r;r++)if(e[r]!==t[r])return!1;return!0}function h(e){var t=/^\/+|\/+$/g;return e.replace(t,"")}function p(e){return escape(e)}function d(e){return encodeURIComponent(e).replace(/[!'()*]/g,p).replace(/\*/g,"%2A")}function y(e){return function(t,r){return void 0===t?this._parts[e]||"":(this._parts[e]=t||null,this.build(!r),this)}}function v(e,t){return function(r,n){return void 0===r?this._parts[e]||"":(null!==r&&(r+="",r.charAt(0)===t&&(r=r.substring(1))),this._parts[e]=r,this.build(!n),this)}}var g=n&&n.URI;o.version="1.19.1";var m=o.prototype,b=Object.prototype.hasOwnProperty;o._parts=function(){return{protocol:null,username:null,password:null,hostname:null,urn:null,port:null,path:null,query:null,fragment:null,preventInvalidHostname:o.preventInvalidHostname,duplicateQueryParameters:o.duplicateQueryParameters,escapeQuerySpace:o.escapeQuerySpace}},o.preventInvalidHostname=!1,o.duplicateQueryParameters=!1,o.escapeQuerySpace=!0,o.protocol_expression=/^[a-z][a-z0-9.+-]*$/i,o.idn_expression=/[^a-z0-9\._-]/i,o.punycode_expression=/(xn--)/i,o.ip4_expression=/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/,o.ip6_expression=/^\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?\s*$/,o.find_uri_expression=/\b((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}\/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?\xab\xbb\u201c\u201d\u2018\u2019]))/gi,o.findUri={start:/\b(?:([a-z][a-z0-9.+-]*:\/\/)|www\.)/gi,end:/[\s\r\n]|$/,trim:/[`!()\[\]{};:'".,<>?\xab\xbb\u201c\u201d\u201e\u2018\u2019]+$/,parens:/(\([^\)]*\)|\[[^\]]*\]|\{[^}]*\}|<[^>]*>)/g},o.defaultPorts={http:"80",https:"443",ftp:"21",gopher:"70",ws:"80",wss:"443"},o.hostProtocols=["http","https"],o.invalid_hostname_characters=/[^a-zA-Z0-9\.\-:_]/,o.domAttributes={a:"href",blockquote:"cite",link:"href",base:"href",script:"src",form:"action",img:"src",area:"href",iframe:"src",embed:"src",source:"src",track:"src",input:"src",audio:"src",video:"src"},o.getDomAttribute=function(e){if(!e||!e.nodeName)return void 0;var t=e.nodeName.toLowerCase();return"input"===t&&"image"!==e.type?void 0:o.domAttributes[t]},o.encode=d,o.decode=decodeURIComponent,o.iso8859=function(){o.encode=escape,o.decode=unescape},o.unicode=function(){o.encode=d,o.decode=decodeURIComponent},o.characters={pathname:{encode:{expression:/%(24|26|2B|2C|3B|3D|3A|40)/gi,map:{"%24":"$","%26":"&","%2B":"+","%2C":",","%3B":";","%3D":"=","%3A":":","%40":"@"}},decode:{expression:/[\/\?#]/g,map:{"/":"%2F","?":"%3F","#":"%23"}}},reserved:{encode:{expression:/%(21|23|24|26|27|28|29|2A|2B|2C|2F|3A|3B|3D|3F|40|5B|5D)/gi,map:{"%3A":":","%2F":"/","%3F":"?","%23":"#","%5B":"[","%5D":"]","%40":"@","%21":"!","%24":"$","%26":"&","%27":"'","%28":"(","%29":")","%2A":"*","%2B":"+","%2C":",","%3B":";","%3D":"="}}},urnpath:{encode:{expression:/%(21|24|27|28|29|2A|2B|2C|3B|3D|40)/gi,map:{"%21":"!","%24":"$","%27":"'","%28":"(","%29":")","%2A":"*","%2B":"+","%2C":",","%3B":";","%3D":"=","%40":"@"}},decode:{expression:/[\/\?#:]/g,map:{"/":"%2F","?":"%3F","#":"%23",":":"%3A"}}}},o.encodeQuery=function(e,t){var r=o.encode(e+"");return void 0===t&&(t=o.escapeQuerySpace),t?r.replace(/%20/g,"+"):r},o.decodeQuery=function(e,t){e+="",void 0===t&&(t=o.escapeQuerySpace);try{return o.decode(t?e.replace(/\+/g,"%20"):e)}catch(r){return e}};var w,_={encode:"encode",decode:"decode"},k=function(e,t){return function(r){try{return o[t](r+"").replace(o.characters[e][t].expression,function(r){return o.characters[e][t].map[r]})}catch(n){return r}}};for(w in _)o[w+"PathSegment"]=k("pathname",_[w]),o[w+"UrnPathSegment"]=k("urnpath",_[w]);var A=function(e,t,r){return function(n){var i;i=r?function(e){return o[t](o[r](e))}:o[t];for(var a=(n+"").split(e),s=0,u=a.length;u>s;s++)a[s]=i(a[s]);return a.join(e)}};o.decodePath=A("/","decodePathSegment"),o.decodeUrnPath=A(":","decodeUrnPathSegment"),o.recodePath=A("/","encodePathSegment","decode"),o.recodeUrnPath=A(":","encodeUrnPathSegment","decode"),o.encodeReserved=k("reserved","encode"),o.parse=function(e,t){var r;return t||(t={preventInvalidHostname:o.preventInvalidHostname}),r=e.indexOf("#"),r>-1&&(t.fragment=e.substring(r+1)||null,e=e.substring(0,r)),r=e.indexOf("?"),r>-1&&(t.query=e.substring(r+1)||null,e=e.substring(0,r)),"//"===e.substring(0,2)?(t.protocol=null,e=e.substring(2),e=o.parseAuthority(e,t)):(r=e.indexOf(":"),r>-1&&(t.protocol=e.substring(0,r)||null,t.protocol&&!t.protocol.match(o.protocol_expression)?t.protocol=void 0:"//"===e.substring(r+1,r+3)?(e=e.substring(r+3),e=o.parseAuthority(e,t)):(e=e.substring(r+1),t.urn=!0))),t.path=e,t},o.parseHost=function(e,t){e||(e=""),e=e.replace(/\\/g,"/");var r,n,i=e.indexOf("/");if(-1===i&&(i=e.length),"["===e.charAt(0))r=e.indexOf("]"),t.hostname=e.substring(1,r)||null,t.port=e.substring(r+2,i)||null,"/"===t.port&&(t.port=null);else{var a=e.indexOf(":"),s=e.indexOf("/"),u=e.indexOf(":",a+1);-1!==u&&(-1===s||s>u)?(t.hostname=e.substring(0,i)||null,t.port=null):(n=e.substring(0,i).split(":"),t.hostname=n[0]||null,t.port=n[1]||null)}return t.hostname&&"/"!==e.substring(i).charAt(0)&&(i++,e="/"+e),t.preventInvalidHostname&&o.ensureValidHostname(t.hostname,t.protocol),t.port&&o.ensureValidPort(t.port),e.substring(i)||"/"},o.parseAuthority=function(e,t){return e=o.parseUserinfo(e,t),o.parseHost(e,t)},o.parseUserinfo=function(e,t){var r,n=e.indexOf("/"),i=e.lastIndexOf("@",n>-1?n:e.length-1);return i>-1&&(-1===n||n>i)?(r=e.substring(0,i).split(":"),t.username=r[0]?o.decode(r[0]):null,r.shift(),t.password=r[0]?o.decode(r.join(":")):null,e=e.substring(i+1)):(t.username=null,t.password=null),e},o.parseQuery=function(e,t){if(!e)return{};if(e=e.replace(/&+/g,"&").replace(/^\?*&*|&+$/g,""),!e)return{};for(var r,n,i,a={},s=e.split("&"),u=s.length,c=0;u>c;c++)r=s[c].split("="),n=o.decodeQuery(r.shift(),t),i=r.length?o.decodeQuery(r.join("="),t):null,b.call(a,n)?(("string"==typeof a[n]||null===a[n])&&(a[n]=[a[n]]),a[n].push(i)):a[n]=i;return a},o.build=function(e){var t="";return e.protocol&&(t+=e.protocol+":"),e.urn||!t&&!e.hostname||(t+="//"),t+=o.buildAuthority(e)||"","string"==typeof e.path&&("/"!==e.path.charAt(0)&&"string"==typeof e.hostname&&(t+="/"),t+=e.path),"string"==typeof e.query&&e.query&&(t+="?"+e.query),"string"==typeof e.fragment&&e.fragment&&(t+="#"+e.fragment),t},o.buildHost=function(e){var t="";return e.hostname?(t+=o.ip6_expression.test(e.hostname)?"["+e.hostname+"]":e.hostname,e.port&&(t+=":"+e.port),t):""},o.buildAuthority=function(e){return o.buildUserinfo(e)+o.buildHost(e)},o.buildUserinfo=function(e){var t="";return e.username&&(t+=o.encode(e.username)),e.password&&(t+=":"+o.encode(e.password)),t&&(t+="@"),t},o.buildQuery=function(e,t,r){var n,i,a,s,c="";for(i in e)if(b.call(e,i)&&i)if(u(e[i]))for(n={},a=0,s=e[i].length;s>a;a++)void 0!==e[i][a]&&void 0===n[e[i][a]+""]&&(c+="&"+o.buildQueryParameter(i,e[i][a],r),t!==!0&&(n[e[i][a]+""]=!0));else void 0!==e[i]&&(c+="&"+o.buildQueryParameter(i,e[i],r));return c.substring(1)},o.buildQueryParameter=function(e,t,r){return o.encodeQuery(e,r)+(null!==t?"="+o.encodeQuery(t,r):"")},o.addQuery=function(e,t,r){if("object"==typeof t)for(var n in t)b.call(t,n)&&o.addQuery(e,n,t[n]);else{if("string"!=typeof t)throw new TypeError("URI.addQuery() accepts an object, string as the name parameter");if(void 0===e[t])return e[t]=r,void 0;"string"==typeof e[t]&&(e[t]=[e[t]]),u(r)||(r=[r]),e[t]=(e[t]||[]).concat(r)}},o.setQuery=function(e,t,r){if("object"==typeof t)for(var n in t)b.call(t,n)&&o.setQuery(e,n,t[n]);else{if("string"!=typeof t)throw new TypeError("URI.setQuery() accepts an object, string as the name parameter");e[t]=void 0===r?null:r}},o.removeQuery=function(e,t,r){var n,i,a;if(u(t))for(n=0,i=t.length;i>n;n++)e[t[n]]=void 0;else if("RegExp"===s(t))for(a in e)t.test(a)&&(e[a]=void 0);else if("object"==typeof t)for(a in t)b.call(t,a)&&o.removeQuery(e,a,t[a]);else{if("string"!=typeof t)throw new TypeError("URI.removeQuery() accepts an object, string, RegExp as the first parameter");void 0!==r?"RegExp"===s(r)?e[t]=!u(e[t])&&r.test(e[t])?void 0:c(e[t],r):e[t]!==String(r)||u(r)&&1!==r.length?u(e[t])&&(e[t]=c(e[t],r)):e[t]=void 0:e[t]=void 0}},o.hasQuery=function(e,t,r,n){switch(s(t)){case"String":break;case"RegExp":for(var i in e)if(b.call(e,i)&&t.test(i)&&(void 0===r||o.hasQuery(e,i,r)))return!0;return!1;case"Object":for(var a in t)if(b.call(t,a)&&!o.hasQuery(e,a,t[a]))return!1;return!0;default:throw new TypeError("URI.hasQuery() accepts a string, regular expression or object as the name parameter")}switch(s(r)){case"Undefined":return t in e;case"Boolean":var c=Boolean(u(e[t])?e[t].length:e[t]);return r===c;case"Function":return!!r(e[t],t,e);case"Array":if(!u(e[t]))return!1;var h=n?f:l;return h(e[t],r);case"RegExp":return u(e[t])?n?f(e[t],r):!1:Boolean(e[t]&&e[t].match(r));case"Number":r=String(r);case"String":return u(e[t])?n?f(e[t],r):!1:e[t]===r;default:throw new TypeError("URI.hasQuery() accepts undefined, boolean, string, number, RegExp, Function as the value parameter")}},o.joinPaths=function(){for(var e=[],t=[],r=0,n=0;n<arguments.length;n++){var i=new o(arguments[n]);e.push(i);for(var a=i.segment(),s=0;s<a.length;s++)"string"==typeof a[s]&&t.push(a[s]),a[s]&&r++}if(!t.length||!r)return new o("");var u=new o("").segment(t);return(""===e[0].path()||"/"===e[0].path().slice(0,1))&&u.path("/"+u.path()),u.normalize()},o.commonPath=function(e,t){var r,n=Math.min(e.length,t.length);for(r=0;n>r;r++)if(e.charAt(r)!==t.charAt(r)){r--;break}return 1>r?e.charAt(0)===t.charAt(0)&&"/"===e.charAt(0)?"/":"":(("/"!==e.charAt(r)||"/"!==t.charAt(r))&&(r=e.substring(0,r).lastIndexOf("/")),e.substring(0,r+1))},o.withinString=function(e,t,r){r||(r={});var n=r.start||o.findUri.start,i=r.end||o.findUri.end,a=r.trim||o.findUri.trim,s=r.parens||o.findUri.parens,u=/[a-z0-9-]=["']?$/i;for(n.lastIndex=0;;){var c=n.exec(e);if(!c)break;var f=c.index;if(r.ignoreHtml){var l=e.slice(Math.max(f-3,0),f);if(l&&u.test(l))continue}for(var h=f+e.slice(f).search(i),p=e.slice(f,h),d=-1;;){var y=s.exec(p);if(!y)break;var v=y.index+y[0].length;d=Math.max(d,v)}if(p=d>-1?p.slice(0,d)+p.slice(d).replace(a,""):p.replace(a,""),!(p.length<=c[0].length||r.ignore&&r.ignore.test(p))){h=f+p.length;var g=t(p,f,h,e);void 0!==g?(g=String(g),e=e.slice(0,f)+g+e.slice(h),n.lastIndex=f+g.length):n.lastIndex=h}}return n.lastIndex=0,e},o.ensureValidHostname=function(t,r){var n=!!t,i=!!r,a=!1;if(i&&(a=f(o.hostProtocols,r)),a&&!n)throw new TypeError("Hostname cannot be empty, if protocol is "+r);if(t&&t.match(o.invalid_hostname_characters)){if(!e)throw new TypeError('Hostname "'+t+'" contains characters other than [A-Z0-9.-:_] and Punycode.js is not available');if(e.toASCII(t).match(o.invalid_hostname_characters))throw new TypeError('Hostname "'+t+'" contains characters other than [A-Z0-9.-:_]')}},o.ensureValidPort=function(e){if(e){var t=Number(e);if(!(i(t)&&t>0&&65536>t))throw new TypeError('Port "'+e+'" is not a valid port')}},o.noConflict=function(e){if(e){var t={URI:this.noConflict()};return n.URITemplate&&"function"==typeof n.URITemplate.noConflict&&(t.URITemplate=n.URITemplate.noConflict()),n.IPv6&&"function"==typeof n.IPv6.noConflict&&(t.IPv6=n.IPv6.noConflict()),n.SecondLevelDomains&&"function"==typeof n.SecondLevelDomains.noConflict&&(t.SecondLevelDomains=n.SecondLevelDomains.noConflict()),t}return n.URI===this&&(n.URI=g),this},m.build=function(e){return e===!0?this._deferred_build=!0:(void 0===e||this._deferred_build)&&(this._string=o.build(this._parts),this._deferred_build=!1),this},m.clone=function(){return new o(this)},m.valueOf=m.toString=function(){return this.build(!1)._string},m.protocol=y("protocol"),m.username=y("username"),m.password=y("password"),m.hostname=y("hostname"),m.port=y("port"),m.query=v("query","?"),m.fragment=v("fragment","#"),m.search=function(e,t){var r=this.query(e,t);return"string"==typeof r&&r.length?"?"+r:r},m.hash=function(e,t){var r=this.fragment(e,t);return"string"==typeof r&&r.length?"#"+r:r},m.pathname=function(e,t){if(void 0===e||e===!0){var r=this._parts.path||(this._parts.hostname?"/":"");return e?(this._parts.urn?o.decodeUrnPath:o.decodePath)(r):r}return this._parts.path=this._parts.urn?e?o.recodeUrnPath(e):"":e?o.recodePath(e):"/",this.build(!t),this},m.path=m.pathname,m.href=function(e,t){var r;if(void 0===e)return this.toString();this._string="",this._parts=o._parts();var n=e instanceof o,i="object"==typeof e&&(e.hostname||e.path||e.pathname);if(e.nodeName){var a=o.getDomAttribute(e);e=e[a]||"",i=!1}if(!n&&i&&void 0!==e.pathname&&(e=e.toString()),"string"==typeof e||e instanceof String)this._parts=o.parse(String(e),this._parts);else{if(!n&&!i)throw new TypeError("invalid input");var s=n?e._parts:e;for(r in s)"query"!==r&&b.call(this._parts,r)&&(this._parts[r]=s[r]);s.query&&this.query(s.query,!1)}return this.build(!t),this},m.is=function(e){var t=!1,n=!1,i=!1,a=!1,s=!1,u=!1,c=!1,f=!this._parts.urn;switch(this._parts.hostname&&(f=!1,n=o.ip4_expression.test(this._parts.hostname),i=o.ip6_expression.test(this._parts.hostname),t=n||i,a=!t,s=a&&r&&r.has(this._parts.hostname),u=a&&o.idn_expression.test(this._parts.hostname),c=a&&o.punycode_expression.test(this._parts.hostname)),e.toLowerCase()){case"relative":return f;case"absolute":return!f;case"domain":case"name":return a;case"sld":return s;case"ip":return t;case"ip4":case"ipv4":case"inet4":return n;case"ip6":case"ipv6":case"inet6":return i;case"idn":return u;case"url":return!this._parts.urn;case"urn":return!!this._parts.urn;case"punycode":return c}return null};var O=m.protocol,E=m.port,S=m.hostname;m.protocol=function(e,t){if(e&&(e=e.replace(/:(\/\/)?$/,""),!e.match(o.protocol_expression)))throw new TypeError('Protocol "'+e+"\" contains characters other than [A-Z0-9.+-] or doesn't start with [A-Z]");return O.call(this,e,t)},m.scheme=m.protocol,m.port=function(e,t){return this._parts.urn?void 0===e?"":this:(void 0!==e&&(0===e&&(e=null),e&&(e+="",":"===e.charAt(0)&&(e=e.substring(1)),o.ensureValidPort(e))),E.call(this,e,t))},m.hostname=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0!==e){var r={preventInvalidHostname:this._parts.preventInvalidHostname},n=o.parseHost(e,r);if("/"!==n)throw new TypeError('Hostname "'+e+'" contains characters other than [A-Z0-9.-]');e=r.hostname,this._parts.preventInvalidHostname&&o.ensureValidHostname(e,this._parts.protocol)}return S.call(this,e,t)},m.origin=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0===e){var r=this.protocol(),n=this.authority();return n?(r?r+"://":"")+this.authority():""}var i=o(e);return this.protocol(i.protocol()).authority(i.authority()).build(!t),this},m.host=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0===e)return this._parts.hostname?o.buildHost(this._parts):"";var r=o.parseHost(e,this._parts);if("/"!==r)throw new TypeError('Hostname "'+e+'" contains characters other than [A-Z0-9.-]');return this.build(!t),this},m.authority=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0===e)return this._parts.hostname?o.buildAuthority(this._parts):"";var r=o.parseAuthority(e,this._parts);if("/"!==r)throw new TypeError('Hostname "'+e+'" contains characters other than [A-Z0-9.-]');return this.build(!t),this},m.userinfo=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0===e){var r=o.buildUserinfo(this._parts);return r?r.substring(0,r.length-1):r}return"@"!==e[e.length-1]&&(e+="@"),o.parseUserinfo(e,this._parts),this.build(!t),this},m.resource=function(e,t){var r;return void 0===e?this.path()+this.search()+this.hash():(r=o.parse(e),this._parts.path=r.path,this._parts.query=r.query,this._parts.fragment=r.fragment,this.build(!t),this)},m.subdomain=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0===e){if(!this._parts.hostname||this.is("IP"))return"";var r=this._parts.hostname.length-this.domain().length-1;return this._parts.hostname.substring(0,r)||""}var n=this._parts.hostname.length-this.domain().length,i=this._parts.hostname.substring(0,n),s=new RegExp("^"+a(i));if(e&&"."!==e.charAt(e.length-1)&&(e+="."),-1!==e.indexOf(":"))throw new TypeError("Domains cannot contain colons");return e&&o.ensureValidHostname(e,this._parts.protocol),this._parts.hostname=this._parts.hostname.replace(s,e),this.build(!t),this},m.domain=function(e,t){if(this._parts.urn)return void 0===e?"":this;if("boolean"==typeof e&&(t=e,e=void 0),void 0===e){if(!this._parts.hostname||this.is("IP"))return"";var r=this._parts.hostname.match(/\./g);if(r&&r.length<2)return this._parts.hostname;var n=this._parts.hostname.length-this.tld(t).length-1;return n=this._parts.hostname.lastIndexOf(".",n-1)+1,this._parts.hostname.substring(n)||""}if(!e)throw new TypeError("cannot set domain empty");if(-1!==e.indexOf(":"))throw new TypeError("Domains cannot contain colons");if(o.ensureValidHostname(e,this._parts.protocol),!this._parts.hostname||this.is("IP"))this._parts.hostname=e;else{var i=new RegExp(a(this.domain())+"$");this._parts.hostname=this._parts.hostname.replace(i,e)}return this.build(!t),this},m.tld=function(e,t){if(this._parts.urn)return void 0===e?"":this;if("boolean"==typeof e&&(t=e,e=void 0),void 0===e){if(!this._parts.hostname||this.is("IP"))return"";var n=this._parts.hostname.lastIndexOf("."),o=this._parts.hostname.substring(n+1);return t!==!0&&r&&r.list[o.toLowerCase()]?r.get(this._parts.hostname)||o:o}var i;if(!e)throw new TypeError("cannot set TLD empty");if(e.match(/[^a-zA-Z0-9-]/)){if(!r||!r.is(e))throw new TypeError('TLD "'+e+'" contains characters other than [A-Z0-9]');i=new RegExp(a(this.tld())+"$"),this._parts.hostname=this._parts.hostname.replace(i,e)}else{if(!this._parts.hostname||this.is("IP"))throw new ReferenceError("cannot set TLD on non-domain host");i=new RegExp(a(this.tld())+"$"),this._parts.hostname=this._parts.hostname.replace(i,e)}return this.build(!t),this},m.directory=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0===e||e===!0){if(!this._parts.path&&!this._parts.hostname)return"";if("/"===this._parts.path)return"/";var r=this._parts.path.length-this.filename().length-1,n=this._parts.path.substring(0,r)||(this._parts.hostname?"/":"");return e?o.decodePath(n):n}var i=this._parts.path.length-this.filename().length,s=this._parts.path.substring(0,i),u=new RegExp("^"+a(s));return this.is("relative")||(e||(e="/"),"/"!==e.charAt(0)&&(e="/"+e)),e&&"/"!==e.charAt(e.length-1)&&(e+="/"),e=o.recodePath(e),this._parts.path=this._parts.path.replace(u,e),this.build(!t),this},m.filename=function(e,t){if(this._parts.urn)return void 0===e?"":this;if("string"!=typeof e){if(!this._parts.path||"/"===this._parts.path)return"";var r=this._parts.path.lastIndexOf("/"),n=this._parts.path.substring(r+1);return e?o.decodePathSegment(n):n}var i=!1;"/"===e.charAt(0)&&(e=e.substring(1)),e.match(/\.?\//)&&(i=!0);var s=new RegExp(a(this.filename())+"$");return e=o.recodePath(e),this._parts.path=this._parts.path.replace(s,e),i?this.normalizePath(t):this.build(!t),this},m.suffix=function(e,t){if(this._parts.urn)return void 0===e?"":this;if(void 0===e||e===!0){if(!this._parts.path||"/"===this._parts.path)return"";var r,n,i=this.filename(),s=i.lastIndexOf(".");return-1===s?"":(r=i.substring(s+1),n=/^[a-z0-9%]+$/i.test(r)?r:"",e?o.decodePathSegment(n):n)}"."===e.charAt(0)&&(e=e.substring(1));var u,c=this.suffix();if(c)u=e?new RegExp(a(c)+"$"):new RegExp(a("."+c)+"$");else{if(!e)return this;this._parts.path+="."+o.recodePath(e)}return u&&(e=o.recodePath(e),this._parts.path=this._parts.path.replace(u,e)),this.build(!t),this},m.segment=function(e,t,r){var n=this._parts.urn?":":"/",o=this.path(),i="/"===o.substring(0,1),a=o.split(n);if(void 0!==e&&"number"!=typeof e&&(r=t,t=e,e=void 0),void 0!==e&&"number"!=typeof e)throw new Error('Bad segment "'+e+'", must be 0-based integer');if(i&&a.shift(),0>e&&(e=Math.max(a.length+e,0)),void 0===t)return void 0===e?a:a[e];if(null===e||void 0===a[e])if(u(t)){a=[];for(var s=0,c=t.length;c>s;s++)(t[s].length||a.length&&a[a.length-1].length)&&(a.length&&!a[a.length-1].length&&a.pop(),a.push(h(t[s])))}else(t||"string"==typeof t)&&(t=h(t),""===a[a.length-1]?a[a.length-1]=t:a.push(t));else t?a[e]=h(t):a.splice(e,1);return i&&a.unshift(""),this.path(a.join(n),r)},m.segmentCoded=function(e,t,r){var n,i,a;if("number"!=typeof e&&(r=t,t=e,e=void 0),void 0===t){if(n=this.segment(e,t,r),u(n))for(i=0,a=n.length;a>i;i++)n[i]=o.decode(n[i]);else n=void 0!==n?o.decode(n):void 0;return n}if(u(t))for(i=0,a=t.length;a>i;i++)t[i]=o.encode(t[i]);else t="string"==typeof t||t instanceof String?o.encode(t):t;return this.segment(e,t,r)};var x=m.query;return m.query=function(e,t){if(e===!0)return o.parseQuery(this._parts.query,this._parts.escapeQuerySpace);if("function"==typeof e){var r=o.parseQuery(this._parts.query,this._parts.escapeQuerySpace),n=e.call(this,r);return this._parts.query=o.buildQuery(n||r,this._parts.duplicateQueryParameters,this._parts.escapeQuerySpace),this.build(!t),this}return void 0!==e&&"string"!=typeof e?(this._parts.query=o.buildQuery(e,this._parts.duplicateQueryParameters,this._parts.escapeQuerySpace),this.build(!t),this):x.call(this,e,t)},m.setQuery=function(e,t,r){var n=o.parseQuery(this._parts.query,this._parts.escapeQuerySpace);if("string"==typeof e||e instanceof String)n[e]=void 0!==t?t:null;else{if("object"!=typeof e)throw new TypeError("URI.addQuery() accepts an object, string as the name parameter");for(var i in e)b.call(e,i)&&(n[i]=e[i])}return this._parts.query=o.buildQuery(n,this._parts.duplicateQueryParameters,this._parts.escapeQuerySpace),"string"!=typeof e&&(r=t),this.build(!r),this},m.addQuery=function(e,t,r){var n=o.parseQuery(this._parts.query,this._parts.escapeQuerySpace);return o.addQuery(n,e,void 0===t?null:t),this._parts.query=o.buildQuery(n,this._parts.duplicateQueryParameters,this._parts.escapeQuerySpace),"string"!=typeof e&&(r=t),this.build(!r),this},m.removeQuery=function(e,t,r){var n=o.parseQuery(this._parts.query,this._parts.escapeQuerySpace);return o.removeQuery(n,e,t),this._parts.query=o.buildQuery(n,this._parts.duplicateQueryParameters,this._parts.escapeQuerySpace),"string"!=typeof e&&(r=t),this.build(!r),this},m.hasQuery=function(e,t,r){var n=o.parseQuery(this._parts.query,this._parts.escapeQuerySpace);return o.hasQuery(n,e,t,r)},m.setSearch=m.setQuery,m.addSearch=m.addQuery,m.removeSearch=m.removeQuery,m.hasSearch=m.hasQuery,m.normalize=function(){return this._parts.urn?this.normalizeProtocol(!1).normalizePath(!1).normalizeQuery(!1).normalizeFragment(!1).build():this.normalizeProtocol(!1).normalizeHostname(!1).normalizePort(!1).normalizePath(!1).normalizeQuery(!1).normalizeFragment(!1).build()},m.normalizeProtocol=function(e){return"string"==typeof this._parts.protocol&&(this._parts.protocol=this._parts.protocol.toLowerCase(),this.build(!e)),this},m.normalizeHostname=function(r){return this._parts.hostname&&(this.is("IDN")&&e?this._parts.hostname=e.toASCII(this._parts.hostname):this.is("IPv6")&&t&&(this._parts.hostname=t.best(this._parts.hostname)),this._parts.hostname=this._parts.hostname.toLowerCase(),this.build(!r)),this},m.normalizePort=function(e){return"string"==typeof this._parts.protocol&&this._parts.port===o.defaultPorts[this._parts.protocol]&&(this._parts.port=null,this.build(!e)),this},m.normalizePath=function(e){var t=this._parts.path;if(!t)return this;if(this._parts.urn)return this._parts.path=o.recodeUrnPath(this._parts.path),this.build(!e),this;if("/"===this._parts.path)return this;t=o.recodePath(t);var r,n,i,a="";for("/"!==t.charAt(0)&&(r=!0,t="/"+t),("/.."===t.slice(-3)||"/."===t.slice(-2))&&(t+="/"),t=t.replace(/(\/(\.\/)+)|(\/\.$)/g,"/").replace(/\/{2,}/g,"/"),r&&(a=t.substring(1).match(/^(\.\.\/)+/)||"",a&&(a=a[0]));;){if(n=t.search(/\/\.\.(\/|$)/),-1===n)break;0!==n?(i=t.substring(0,n).lastIndexOf("/"),-1===i&&(i=n),t=t.substring(0,i)+t.substring(n+3)):t=t.substring(3)}return r&&this.is("relative")&&(t=a+t.substring(1)),this._parts.path=t,this.build(!e),this},m.normalizePathname=m.normalizePath,m.normalizeQuery=function(e){return"string"==typeof this._parts.query&&(this._parts.query.length?this.query(o.parseQuery(this._parts.query,this._parts.escapeQuerySpace)):this._parts.query=null,this.build(!e)),this
},m.normalizeFragment=function(e){return this._parts.fragment||(this._parts.fragment=null,this.build(!e)),this},m.normalizeSearch=m.normalizeQuery,m.normalizeHash=m.normalizeFragment,m.iso8859=function(){var e=o.encode,t=o.decode;o.encode=escape,o.decode=decodeURIComponent;try{this.normalize()}finally{o.encode=e,o.decode=t}return this},m.unicode=function(){var e=o.encode,t=o.decode;o.encode=d,o.decode=unescape;try{this.normalize()}finally{o.encode=e,o.decode=t}return this},m.readable=function(){var t=this.clone();t.username("").password("").normalize();var r="";if(t._parts.protocol&&(r+=t._parts.protocol+"://"),t._parts.hostname&&(t.is("punycode")&&e?(r+=e.toUnicode(t._parts.hostname),t._parts.port&&(r+=":"+t._parts.port)):r+=t.host()),t._parts.hostname&&t._parts.path&&"/"!==t._parts.path.charAt(0)&&(r+="/"),r+=t.path(!0),t._parts.query){for(var n="",i=0,a=t._parts.query.split("&"),s=a.length;s>i;i++){var u=(a[i]||"").split("=");n+="&"+o.decodeQuery(u[0],this._parts.escapeQuerySpace).replace(/&/g,"%26"),void 0!==u[1]&&(n+="="+o.decodeQuery(u[1],this._parts.escapeQuerySpace).replace(/&/g,"%26"))}r+="?"+n.substring(1)}return r+=o.decodeQuery(t.hash(),!0)},m.absoluteTo=function(e){var t,r,n,i=this.clone(),a=["protocol","username","password","hostname","port"];if(this._parts.urn)throw new Error("URNs do not have any generally defined hierarchical components");if(e instanceof o||(e=new o(e)),i._parts.protocol)return i;if(i._parts.protocol=e._parts.protocol,this._parts.hostname)return i;for(r=0;n=a[r];r++)i._parts[n]=e._parts[n];return i._parts.path?(".."===i._parts.path.substring(-2)&&(i._parts.path+="/"),"/"!==i.path().charAt(0)&&(t=e.directory(),t=t?t:0===e.path().indexOf("/")?"/":"",i._parts.path=(t?t+"/":"")+i._parts.path,i.normalizePath())):(i._parts.path=e._parts.path,i._parts.query||(i._parts.query=e._parts.query)),i.build(),i},m.relativeTo=function(e){var t,r,n,i,a,s=this.clone().normalize();if(s._parts.urn)throw new Error("URNs do not have any generally defined hierarchical components");if(e=new o(e).normalize(),t=s._parts,r=e._parts,i=s.path(),a=e.path(),"/"!==i.charAt(0))throw new Error("URI is already relative");if("/"!==a.charAt(0))throw new Error("Cannot calculate a URI relative to another relative URI");if(t.protocol===r.protocol&&(t.protocol=null),t.username!==r.username||t.password!==r.password)return s.build();if(null!==t.protocol||null!==t.username||null!==t.password)return s.build();if(t.hostname!==r.hostname||t.port!==r.port)return s.build();if(t.hostname=null,t.port=null,i===a)return t.path="",s.build();if(n=o.commonPath(i,a),!n)return s.build();var u=r.path.substring(n.length).replace(/[^\/]*$/,"").replace(/.*?\//g,"../");return t.path=u+t.path.substring(n.length)||"./",s.build()},m.equals=function(e){var t,r,n,i=this.clone(),a=new o(e),s={},c={},f={};if(i.normalize(),a.normalize(),i.toString()===a.toString())return!0;if(t=i.query(),r=a.query(),i.query(""),a.query(""),i.toString()!==a.toString())return!1;if(t.length!==r.length)return!1;s=o.parseQuery(t,this._parts.escapeQuerySpace),c=o.parseQuery(r,this._parts.escapeQuerySpace);for(n in s)if(b.call(s,n)){if(u(s[n])){if(!l(s[n],c[n]))return!1}else if(s[n]!==c[n])return!1;f[n]=!0}for(n in c)if(b.call(c,n)&&!f[n])return!1;return!0},m.preventInvalidHostname=function(e){return this._parts.preventInvalidHostname=!!e,this},m.duplicateQueryParameters=function(e){return this._parts.duplicateQueryParameters=!!e,this},m.escapeQuerySpace=function(e){return this._parts.escapeQuerySpace=!!e,this},o})},function(e,t,r){var n;(function(e,o){!function(i){function a(e){throw new RangeError(R[e])}function s(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function u(e,t){var r=e.split("@"),n="";r.length>1&&(n=r[0]+"@",e=r[1]),e=e.replace(j,".");var o=e.split("."),i=s(o,t).join(".");return n+i}function c(e){for(var t,r,n=[],o=0,i=e.length;i>o;)t=e.charCodeAt(o++),t>=55296&&56319>=t&&i>o?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function f(e){return s(e,function(e){var t="";return e>65535&&(e-=65536,t+=M(e>>>10&1023|55296),e=56320|1023&e),t+=M(e)}).join("")}function l(e){return 10>e-48?e-22:26>e-65?e-65:26>e-97?e-97:_}function h(e,t){return e+22+75*(26>e)-((0!=t)<<5)}function p(e,t,r){var n=0;for(e=r?B(e/E):e>>1,e+=B(e/t);e>I*A>>1;n+=_)e=B(e/I);return B(n+(I+1)*e/(e+O))}function d(e){var t,r,n,o,i,s,u,c,h,d,y=[],v=e.length,g=0,m=x,b=S;for(r=e.lastIndexOf(C),0>r&&(r=0),n=0;r>n;++n)e.charCodeAt(n)>=128&&a("not-basic"),y.push(e.charCodeAt(n));for(o=r>0?r+1:0;v>o;){for(i=g,s=1,u=_;o>=v&&a("invalid-input"),c=l(e.charCodeAt(o++)),(c>=_||c>B((w-g)/s))&&a("overflow"),g+=c*s,h=b>=u?k:u>=b+A?A:u-b,!(h>c);u+=_)d=_-h,s>B(w/d)&&a("overflow"),s*=d;t=y.length+1,b=p(g-i,t,0==i),B(g/t)>w-m&&a("overflow"),m+=B(g/t),g%=t,y.splice(g++,0,m)}return f(y)}function y(e){var t,r,n,o,i,s,u,f,l,d,y,v,g,m,b,O=[];for(e=c(e),v=e.length,t=x,r=0,i=S,s=0;v>s;++s)y=e[s],128>y&&O.push(M(y));for(n=o=O.length,o&&O.push(C);v>n;){for(u=w,s=0;v>s;++s)y=e[s],y>=t&&u>y&&(u=y);for(g=n+1,u-t>B((w-r)/g)&&a("overflow"),r+=(u-t)*g,t=u,s=0;v>s;++s)if(y=e[s],t>y&&++r>w&&a("overflow"),y==t){for(f=r,l=_;d=i>=l?k:l>=i+A?A:l-i,!(d>f);l+=_)b=f-d,m=_-d,O.push(M(h(d+b%m,0))),f=B(b/m);O.push(M(h(f,0))),i=p(r,g,n==o),r=0,++n}++r,++t}return O.join("")}function v(e){return u(e,function(e){return P.test(e)?d(e.slice(4).toLowerCase()):e})}function g(e){return u(e,function(e){return T.test(e)?"xn--"+y(e):e})}var m=("object"==typeof t&&t&&!t.nodeType&&t,"object"==typeof e&&e&&!e.nodeType&&e,"object"==typeof o&&o);(m.global===m||m.window===m||m.self===m)&&(i=m);var b,w=2147483647,_=36,k=1,A=26,O=38,E=700,S=72,x=128,C="-",P=/^xn--/,T=/[^\x20-\x7E]/,j=/[\x2E\u3002\uFF0E\uFF61]/g,R={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},I=_-k,B=Math.floor,M=String.fromCharCode;b={version:"1.3.2",ucs2:{decode:c,encode:f},decode:d,encode:y,toASCII:g,toUnicode:v},n=function(){return b}.call(t,r,t,e),!(void 0!==n&&(e.exports=n))}(this)}).call(t,r(64)(e),function(){return this}())},function(e,t,r){var n,o;!function(i,a){"use strict";"object"==typeof e&&e.exports?e.exports=a():(n=a,o="function"==typeof n?n.call(t,r,t,e):n,!(void 0!==o&&(e.exports=o)))}(this,function(e){"use strict";function t(e){var t=e.toLowerCase(),r=t.split(":"),n=r.length,o=8;""===r[0]&&""===r[1]&&""===r[2]?(r.shift(),r.shift()):""===r[0]&&""===r[1]?r.shift():""===r[n-1]&&""===r[n-2]&&r.pop(),n=r.length,-1!==r[n-1].indexOf(".")&&(o=7);var i;for(i=0;n>i&&""!==r[i];i++);if(o>i)for(r.splice(i,1,"0000");r.length<o;)r.splice(i,0,"0000");for(var a,s=0;o>s;s++){a=r[s].split("");for(var u=0;3>u&&("0"===a[0]&&a.length>1);u++)a.splice(0,1);r[s]=a.join("")}var c=-1,f=0,l=0,h=-1,p=!1;for(s=0;o>s;s++)p?"0"===r[s]?l+=1:(p=!1,l>f&&(c=h,f=l)):"0"===r[s]&&(p=!0,h=s,l=1);l>f&&(c=h,f=l),f>1&&r.splice(c,f,""),n=r.length;var d="";for(""===r[0]&&(d=":"),s=0;n>s&&(d+=r[s],s!==n-1);s++)d+=":";return""===r[n-1]&&(d+=":"),d}function r(){return e.IPv6===this&&(e.IPv6=n),this}var n=e&&e.IPv6;return{best:t,noConflict:r}})},function(e,t,r){var n,o;!function(i,a){"use strict";"object"==typeof e&&e.exports?e.exports=a():(n=a,o="function"==typeof n?n.call(t,r,t,e):n,!(void 0!==o&&(e.exports=o)))}(this,function(e){"use strict";var t=e&&e.SecondLevelDomains,r={list:{ac:" com gov mil net org ",ae:" ac co gov mil name net org pro sch ",af:" com edu gov net org ",al:" com edu gov mil net org ",ao:" co ed gv it og pb ",ar:" com edu gob gov int mil net org tur ",at:" ac co gv or ",au:" asn com csiro edu gov id net org ",ba:" co com edu gov mil net org rs unbi unmo unsa untz unze ",bb:" biz co com edu gov info net org store tv ",bh:" biz cc com edu gov info net org ",bn:" com edu gov net org ",bo:" com edu gob gov int mil net org tv ",br:" adm adv agr am arq art ato b bio blog bmd cim cng cnt com coop ecn edu eng esp etc eti far flog fm fnd fot fst g12 ggf gov imb ind inf jor jus lel mat med mil mus net nom not ntr odo org ppg pro psc psi qsl rec slg srv tmp trd tur tv vet vlog wiki zlg ",bs:" com edu gov net org ",bz:" du et om ov rg ",ca:" ab bc mb nb nf nl ns nt nu on pe qc sk yk ",ck:" biz co edu gen gov info net org ",cn:" ac ah bj com cq edu fj gd gov gs gx gz ha hb he hi hl hn jl js jx ln mil net nm nx org qh sc sd sh sn sx tj tw xj xz yn zj ",co:" com edu gov mil net nom org ",cr:" ac c co ed fi go or sa ",cy:" ac biz com ekloges gov ltd name net org parliament press pro tm ","do":" art com edu gob gov mil net org sld web ",dz:" art asso com edu gov net org pol ",ec:" com edu fin gov info med mil net org pro ",eg:" com edu eun gov mil name net org sci ",er:" com edu gov ind mil net org rochest w ",es:" com edu gob nom org ",et:" biz com edu gov info name net org ",fj:" ac biz com info mil name net org pro ",fk:" ac co gov net nom org ",fr:" asso com f gouv nom prd presse tm ",gg:" co net org ",gh:" com edu gov mil org ",gn:" ac com gov net org ",gr:" com edu gov mil net org ",gt:" com edu gob ind mil net org ",gu:" com edu gov net org ",hk:" com edu gov idv net org ",hu:" 2000 agrar bolt casino city co erotica erotika film forum games hotel info ingatlan jogasz konyvelo lakas media news org priv reklam sex shop sport suli szex tm tozsde utazas video ",id:" ac co go mil net or sch web ",il:" ac co gov idf k12 muni net org ","in":" ac co edu ernet firm gen gov i ind mil net nic org res ",iq:" com edu gov i mil net org ",ir:" ac co dnssec gov i id net org sch ",it:" edu gov ",je:" co net org ",jo:" com edu gov mil name net org sch ",jp:" ac ad co ed go gr lg ne or ",ke:" ac co go info me mobi ne or sc ",kh:" com edu gov mil net org per ",ki:" biz com de edu gov info mob net org tel ",km:" asso com coop edu gouv k medecin mil nom notaires pharmaciens presse tm veterinaire ",kn:" edu gov net org ",kr:" ac busan chungbuk chungnam co daegu daejeon es gangwon go gwangju gyeongbuk gyeonggi gyeongnam hs incheon jeju jeonbuk jeonnam k kg mil ms ne or pe re sc seoul ulsan ",kw:" com edu gov net org ",ky:" com edu gov net org ",kz:" com edu gov mil net org ",lb:" com edu gov net org ",lk:" assn com edu gov grp hotel int ltd net ngo org sch soc web ",lr:" com edu gov net org ",lv:" asn com conf edu gov id mil net org ",ly:" com edu gov id med net org plc sch ",ma:" ac co gov m net org press ",mc:" asso tm ",me:" ac co edu gov its net org priv ",mg:" com edu gov mil nom org prd tm ",mk:" com edu gov inf name net org pro ",ml:" com edu gov net org presse ",mn:" edu gov org ",mo:" com edu gov net org ",mt:" com edu gov net org ",mv:" aero biz com coop edu gov info int mil museum name net org pro ",mw:" ac co com coop edu gov int museum net org ",mx:" com edu gob net org ",my:" com edu gov mil name net org sch ",nf:" arts com firm info net other per rec store web ",ng:" biz com edu gov mil mobi name net org sch ",ni:" ac co com edu gob mil net nom org ",np:" com edu gov mil net org ",nr:" biz com edu gov info net org ",om:" ac biz co com edu gov med mil museum net org pro sch ",pe:" com edu gob mil net nom org sld ",ph:" com edu gov i mil net ngo org ",pk:" biz com edu fam gob gok gon gop gos gov net org web ",pl:" art bialystok biz com edu gda gdansk gorzow gov info katowice krakow lodz lublin mil net ngo olsztyn org poznan pwr radom slupsk szczecin torun warszawa waw wroc wroclaw zgora ",pr:" ac biz com edu est gov info isla name net org pro prof ",ps:" com edu gov net org plo sec ",pw:" belau co ed go ne or ",ro:" arts com firm info nom nt org rec store tm www ",rs:" ac co edu gov in org ",sb:" com edu gov net org ",sc:" com edu gov net org ",sh:" co com edu gov net nom org ",sl:" com edu gov net org ",st:" co com consulado edu embaixada gov mil net org principe saotome store ",sv:" com edu gob org red ",sz:" ac co org ",tr:" av bbs bel biz com dr edu gen gov info k12 name net org pol tel tsk tv web ",tt:" aero biz cat co com coop edu gov info int jobs mil mobi museum name net org pro tel travel ",tw:" club com ebiz edu game gov idv mil net org ",mu:" ac co com gov net or org ",mz:" ac co edu gov org ",na:" co com ",nz:" ac co cri geek gen govt health iwi maori mil net org parliament school ",pa:" abo ac com edu gob ing med net nom org sld ",pt:" com edu gov int net nome org publ ",py:" com edu gov mil net org ",qa:" com edu gov mil net org ",re:" asso com nom ",ru:" ac adygeya altai amur arkhangelsk astrakhan bashkiria belgorod bir bryansk buryatia cbg chel chelyabinsk chita chukotka chuvashia com dagestan e-burg edu gov grozny int irkutsk ivanovo izhevsk jar joshkar-ola kalmykia kaluga kamchatka karelia kazan kchr kemerovo khabarovsk khakassia khv kirov koenig komi kostroma kranoyarsk kuban kurgan kursk lipetsk magadan mari mari-el marine mil mordovia mosreg msk murmansk nalchik net nnov nov novosibirsk nsk omsk orenburg org oryol penza perm pp pskov ptz rnd ryazan sakhalin samara saratov simbirsk smolensk spb stavropol stv surgut tambov tatarstan tom tomsk tsaritsyn tsk tula tuva tver tyumen udm udmurtia ulan-ude vladikavkaz vladimir vladivostok volgograd vologda voronezh vrn vyatka yakutia yamal yekaterinburg yuzhno-sakhalinsk ",rw:" ac co com edu gouv gov int mil net ",sa:" com edu gov med net org pub sch ",sd:" com edu gov info med net org tv ",se:" a ac b bd c d e f g h i k l m n o org p parti pp press r s t tm u w x y z ",sg:" com edu gov idn net org per ",sn:" art com edu gouv org perso univ ",sy:" com edu gov mil net news org ",th:" ac co go in mi net or ",tj:" ac biz co com edu go gov info int mil name net nic org test web ",tn:" agrinet com defense edunet ens fin gov ind info intl mincom nat net org perso rnrt rns rnu tourism ",tz:" ac co go ne or ",ua:" biz cherkassy chernigov chernovtsy ck cn co com crimea cv dn dnepropetrovsk donetsk dp edu gov if in ivano-frankivsk kh kharkov kherson khmelnitskiy kiev kirovograd km kr ks kv lg lugansk lutsk lviv me mk net nikolaev od odessa org pl poltava pp rovno rv sebastopol sumy te ternopil uzhgorod vinnica vn zaporizhzhe zhitomir zp zt ",ug:" ac co go ne or org sc ",uk:" ac bl british-library co cym gov govt icnet jet lea ltd me mil mod national-library-scotland nel net nhs nic nls org orgn parliament plc police sch scot soc ",us:" dni fed isa kids nsn ",uy:" com edu gub mil net org ",ve:" co com edu gob info mil net org web ",vi:" co com k12 net org ",vn:" ac biz com edu gov health info int name net org pro ",ye:" co com gov ltd me net org plc ",yu:" ac co edu gov org ",za:" ac agric alt bourse city co cybernet db edu gov grondar iaccess imt inca landesign law mil net ngo nis nom olivetti org pix school tm web ",zm:" ac co com edu gov net org sch ",com:"ar br cn de eu gb gr hu jpn kr no qc ru sa se uk us uy za ",net:"gb jp se uk ",org:"ae",de:"com "},has:function(e){var t=e.lastIndexOf(".");if(0>=t||t>=e.length-1)return!1;var n=e.lastIndexOf(".",t-1);if(0>=n||n>=t-1)return!1;var o=r.list[e.slice(t+1)];return o?o.indexOf(" "+e.slice(n+1,t)+" ")>=0:!1},is:function(e){var t=e.lastIndexOf(".");if(0>=t||t>=e.length-1)return!1;var n=e.lastIndexOf(".",t-1);if(n>=0)return!1;var o=r.list[e.slice(t+1)];return o?o.indexOf(" "+e.slice(0,t)+" ")>=0:!1},get:function(e){var t=e.lastIndexOf(".");if(0>=t||t>=e.length-1)return null;var n=e.lastIndexOf(".",t-1);if(0>=n||n>=t-1)return null;var o=r.list[e.slice(t+1)];return o?o.indexOf(" "+e.slice(n+1,t)+" ")<0?null:e.slice(n+1):null},noConflict:function(){return e.SecondLevelDomains===this&&(e.SecondLevelDomains=t),this}};return r})},function(e,t,r){var n,o,i;!function(a,s){"use strict";"object"==typeof e&&e.exports?e.exports=s(r(124)):(o=[r(124)],n=s,i="function"==typeof n?n.apply(t,o):n,!(void 0!==i&&(e.exports=i)))}(this,function(e,t){"use strict";function r(e){return r._cache[e]?r._cache[e]:this instanceof r?(this.expression=e,r._cache[e]=this,this):new r(e)}function n(e){this.data=e,this.cache={}}var o=t&&t.URITemplate,i=Object.prototype.hasOwnProperty,a=r.prototype,s={"":{prefix:"",separator:",",named:!1,empty_name_separator:!1,encode:"encode"},"+":{prefix:"",separator:",",named:!1,empty_name_separator:!1,encode:"encodeReserved"},"#":{prefix:"#",separator:",",named:!1,empty_name_separator:!1,encode:"encodeReserved"},".":{prefix:".",separator:".",named:!1,empty_name_separator:!1,encode:"encode"},"/":{prefix:"/",separator:"/",named:!1,empty_name_separator:!1,encode:"encode"},";":{prefix:";",separator:";",named:!0,empty_name_separator:!1,encode:"encode"},"?":{prefix:"?",separator:"&",named:!0,empty_name_separator:!0,encode:"encode"},"&":{prefix:"&",separator:"&",named:!0,empty_name_separator:!0,encode:"encode"}};return r._cache={},r.EXPRESSION_PATTERN=/\{([^a-zA-Z0-9%_]?)([^\}]+)(\}|$)/g,r.VARIABLE_PATTERN=/^([^*:.](?:\.?[^*:.])*)((\*)|:(\d+))?$/,r.VARIABLE_NAME_PATTERN=/[^a-zA-Z0-9%_.]/,r.LITERAL_PATTERN=/[<>{}"`^| \\]/,r.expand=function(e,t,n){var o,i,a,u=s[e.operator],c=u.named?"Named":"Unnamed",f=e.variables,l=[];for(a=0;i=f[a];a++){if(o=t.get(i.name),0===o.type&&n&&n.strict)throw new Error('Missing expansion value for variable "'+i.name+'"');if(o.val.length){if(o.type>1&&i.maxlength)throw new Error('Invalid expression: Prefix modifier not applicable to variable "'+i.name+'"');l.push(r["expand"+c](o,u,i.explode,i.explode&&u.separator||",",i.maxlength,i.name))}else o.type&&l.push("")}return l.length?u.prefix+l.join(u.separator):""},r.expandNamed=function(t,r,n,o,i,a){var s,u,c,f="",l=r.encode,h=r.empty_name_separator,p=!t[l].length,d=2===t.type?"":e[l](a);for(u=0,c=t.val.length;c>u;u++)i?(s=e[l](t.val[u][1].substring(0,i)),2===t.type&&(d=e[l](t.val[u][0].substring(0,i)))):p?(s=e[l](t.val[u][1]),2===t.type?(d=e[l](t.val[u][0]),t[l].push([d,s])):t[l].push([void 0,s])):(s=t[l][u][1],2===t.type&&(d=t[l][u][0])),f&&(f+=o),n?f+=d+(h||s?"=":"")+s:(u||(f+=e[l](a)+(h||s?"=":"")),2===t.type&&(f+=d+","),f+=s);return f},r.expandUnnamed=function(t,r,n,o,i){var a,s,u,c,f="",l=r.encode,h=r.empty_name_separator,p=!t[l].length;for(u=0,c=t.val.length;c>u;u++)i?s=e[l](t.val[u][1].substring(0,i)):p?(s=e[l](t.val[u][1]),t[l].push([2===t.type?e[l](t.val[u][0]):void 0,s])):s=t[l][u][1],f&&(f+=o),2===t.type&&(a=i?e[l](t.val[u][0].substring(0,i)):t[l][u][0],f+=a,f+=n?h||s?"=":"":","),f+=s;return f},r.noConflict=function(){return t.URITemplate===r&&(t.URITemplate=o),r},a.expand=function(e,t){var o="";this.parts&&this.parts.length||this.parse(),e instanceof n||(e=new n(e));for(var i=0,a=this.parts.length;a>i;i++)o+="string"==typeof this.parts[i]?this.parts[i]:r.expand(this.parts[i],e,t);return o},a.parse=function(){var e,t,n,o=this.expression,i=r.EXPRESSION_PATTERN,a=r.VARIABLE_PATTERN,u=r.VARIABLE_NAME_PATTERN,c=r.LITERAL_PATTERN,f=[],l=0,h=function(e){if(e.match(c))throw new Error('Invalid Literal "'+e+'"');return e};for(i.lastIndex=0;;){if(t=i.exec(o),null===t){f.push(h(o.substring(l)));break}if(f.push(h(o.substring(l,t.index))),l=t.index+t[0].length,!s[t[1]])throw new Error('Unknown Operator "'+t[1]+'" in "'+t[0]+'"');if(!t[3])throw new Error('Unclosed Expression "'+t[0]+'"');e=t[2].split(",");for(var p=0,d=e.length;d>p;p++){if(n=e[p].match(a),null===n)throw new Error('Invalid Variable "'+e[p]+'" in "'+t[0]+'"');if(n[1].match(u))throw new Error('Invalid Variable Name "'+n[1]+'" in "'+t[0]+'"');e[p]={name:n[1],explode:!!n[3],maxlength:n[4]&&parseInt(n[4],10)}}if(!e.length)throw new Error('Expression Missing Variable(s) "'+t[0]+'"');f.push({expression:t[0],operator:t[1],variables:e})}return f.length||f.push(h(o)),this.parts=f,this},n.prototype.get=function(e){var t,r,n,o=this.data,a={type:0,val:[],encode:[],encodeReserved:[]};if(void 0!==this.cache[e])return this.cache[e];if(this.cache[e]=a,n="[object Function]"===String(Object.prototype.toString.call(o))?o(e):"[object Function]"===String(Object.prototype.toString.call(o[e]))?o[e](e):o[e],void 0===n||null===n)return a;if("[object Array]"===String(Object.prototype.toString.call(n))){for(t=0,r=n.length;r>t;t++)void 0!==n[t]&&null!==n[t]&&a.val.push([void 0,String(n[t])]);a.val.length&&(a.type=3)}else if("[object Object]"===String(Object.prototype.toString.call(n))){for(t in n)i.call(n,t)&&void 0!==n[t]&&null!==n[t]&&a.val.push([t,String(n[t])]);a.val.length&&(a.type=2)}else a.type=1,a.val.push([void 0,String(n)]);return a},e.expand=function(t,n){var o=new r(t),i=o.expand(n);return new e(i)},r})},function(e,t,r){e.exports=r(130)},function(e,t,r){"use strict";function n(e){var t=new a(e),r=i(a.prototype.request,t);return o.extend(r,a.prototype,t),o.extend(r,t),r}var o=r(131),i=r(132),a=r(134),s=r(135),u=n(s);u.Axios=a,u.create=function(e){return n(o.merge(s,e))},u.Cancel=r(152),u.CancelToken=r(153),u.isCancel=r(149),u.all=function(e){return Promise.all(e)},u.spread=r(154),e.exports=u,e.exports.default=u},function(e,t,r){"use strict";function n(e){return"[object Array]"===O.call(e)}function o(e){return"[object ArrayBuffer]"===O.call(e)}function i(e){return"undefined"!=typeof FormData&&e instanceof FormData}function a(e){var t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer}function s(e){return"string"==typeof e}function u(e){return"number"==typeof e}function c(e){return"undefined"==typeof e}function f(e){return null!==e&&"object"==typeof e}function l(e){return"[object Date]"===O.call(e)}function h(e){return"[object File]"===O.call(e)}function p(e){return"[object Blob]"===O.call(e)}function d(e){return"[object Function]"===O.call(e)}function y(e){return f(e)&&d(e.pipe)}function v(e){return"undefined"!=typeof URLSearchParams&&e instanceof URLSearchParams}function g(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")}function m(){return"undefined"!=typeof navigator&&"ReactNative"===navigator.product?!1:"undefined"!=typeof window&&"undefined"!=typeof document}function b(e,t){if(null!==e&&"undefined"!=typeof e)if("object"!=typeof e&&(e=[e]),n(e))for(var r=0,o=e.length;o>r;r++)t.call(null,e[r],r,e);else for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.call(null,e[i],i,e)}function w(){function e(e,r){t[r]="object"==typeof t[r]&&"object"==typeof e?w(t[r],e):e}for(var t={},r=0,n=arguments.length;n>r;r++)b(arguments[r],e);return t}function _(e,t,r){return b(t,function(t,n){e[n]=r&&"function"==typeof t?k(t,r):t}),e}var k=r(132),A=r(133),O=Object.prototype.toString;e.exports={isArray:n,isArrayBuffer:o,isBuffer:A,isFormData:i,isArrayBufferView:a,isString:s,isNumber:u,isObject:f,isUndefined:c,isDate:l,isFile:h,isBlob:p,isFunction:d,isStream:y,isURLSearchParams:v,isStandardBrowserEnv:m,forEach:b,merge:w,extend:_,trim:g}},function(e){"use strict";e.exports=function(e,t){return function(){for(var r=new Array(arguments.length),n=0;n<r.length;n++)r[n]=arguments[n];return e.apply(t,r)}}},function(e){e.exports=function(e){return null!=e&&null!=e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}},function(e,t,r){"use strict";function n(e){this.defaults=e,this.interceptors={request:new a,response:new a}}var o=r(135),i=r(131),a=r(146),s=r(147);n.prototype.request=function(e){"string"==typeof e&&(e=i.merge({url:arguments[0]},arguments[1])),e=i.merge(o,{method:"get"},this.defaults,e),e.method=e.method.toLowerCase();var t=[s,void 0],r=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)r=r.then(t.shift(),t.shift());return r},i.forEach(["delete","get","head","options"],function(e){n.prototype[e]=function(t,r){return this.request(i.merge(r||{},{method:e,url:t}))}}),i.forEach(["post","put","patch"],function(e){n.prototype[e]=function(t,r,n){return this.request(i.merge(n||{},{method:e,url:t,data:r}))}}),e.exports=n},function(e,t,r){(function(t){"use strict";function n(e,t){!i.isUndefined(e)&&i.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function o(){var e;return"undefined"!=typeof XMLHttpRequest?e=r(138):"undefined"!=typeof t&&(e=r(138)),e}var i=r(131),a=r(137),s={"Content-Type":"application/x-www-form-urlencoded"},u={adapter:o(),transformRequest:[function(e,t){return a(t,"Content-Type"),i.isFormData(e)||i.isArrayBuffer(e)||i.isBuffer(e)||i.isStream(e)||i.isFile(e)||i.isBlob(e)?e:i.isArrayBufferView(e)?e.buffer:i.isURLSearchParams(e)?(n(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):i.isObject(e)?(n(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(t){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,validateStatus:function(e){return e>=200&&300>e}};u.headers={common:{Accept:"application/json, text/plain, */*"}},i.forEach(["delete","get","head"],function(e){u.headers[e]={}}),i.forEach(["post","put","patch"],function(e){u.headers[e]=i.merge(s)}),e.exports=u}).call(t,r(136))},function(e){function t(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function n(e){if(c===setTimeout)return setTimeout(e,0);if((c===t||!c)&&setTimeout)return c=setTimeout,setTimeout(e,0);try{return c(e,0)}catch(r){try{return c.call(null,e,0)}catch(r){return c.call(this,e,0)}}}function o(e){if(f===clearTimeout)return clearTimeout(e);if((f===r||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function i(){d&&h&&(d=!1,h.length?p=h.concat(p):y=-1,p.length&&a())}function a(){if(!d){var e=n(i);d=!0;for(var t=p.length;t;){for(h=p,p=[];++y<t;)h&&h[y].run();y=-1,t=p.length}h=null,d=!1,o(e)}}function s(e,t){this.fun=e,this.array=t}function u(){}var c,f,l=e.exports={};!function(){try{c="function"==typeof setTimeout?setTimeout:t}catch(e){c=t}try{f="function"==typeof clearTimeout?clearTimeout:r}catch(e){f=r}}();var h,p=[],d=!1,y=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];p.push(new s(e,t)),1!==p.length||d||n(a)},s.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=u,l.addListener=u,l.once=u,l.off=u,l.removeListener=u,l.removeAllListeners=u,l.emit=u,l.prependListener=u,l.prependOnceListener=u,l.listeners=function(){return[]},l.binding=function(){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},function(e,t,r){"use strict";var n=r(131);e.exports=function(e,t){n.forEach(e,function(r,n){n!==t&&n.toUpperCase()===t.toUpperCase()&&(e[t]=r,delete e[n])})}},function(e,t,r){"use strict";var n=r(131),o=r(139),i=r(142),a=r(143),s=r(144),u=r(140);e.exports=function(e){return new Promise(function(t,c){var f=e.data,l=e.headers;n.isFormData(f)&&delete l["Content-Type"];var h=new XMLHttpRequest;if(e.auth){var p=e.auth.username||"",d=e.auth.password||"";l.Authorization="Basic "+btoa(p+":"+d)}if(h.open(e.method.toUpperCase(),i(e.url,e.params,e.paramsSerializer),!0),h.timeout=e.timeout,h.onreadystatechange=function(){if(h&&4===h.readyState&&(0!==h.status||h.responseURL&&0===h.responseURL.indexOf("file:"))){var r="getAllResponseHeaders"in h?a(h.getAllResponseHeaders()):null,n=e.responseType&&"text"!==e.responseType?h.response:h.responseText,i={data:n,status:h.status,statusText:h.statusText,headers:r,config:e,request:h};o(t,c,i),h=null}},h.onerror=function(){c(u("Network Error",e,null,h)),h=null},h.ontimeout=function(){c(u("timeout of "+e.timeout+"ms exceeded",e,"ECONNABORTED",h)),h=null},n.isStandardBrowserEnv()){var y=r(145),v=(e.withCredentials||s(e.url))&&e.xsrfCookieName?y.read(e.xsrfCookieName):void 0;v&&(l[e.xsrfHeaderName]=v)}if("setRequestHeader"in h&&n.forEach(l,function(e,t){"undefined"==typeof f&&"content-type"===t.toLowerCase()?delete l[t]:h.setRequestHeader(t,e)}),e.withCredentials&&(h.withCredentials=!0),e.responseType)try{h.responseType=e.responseType}catch(g){if("json"!==e.responseType)throw g}"function"==typeof e.onDownloadProgress&&h.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&h.upload&&h.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(e){h&&(h.abort(),c(e),h=null)}),void 0===f&&(f=null),h.send(f)})}},function(e,t,r){"use strict";var n=r(140);e.exports=function(e,t,r){var o=r.config.validateStatus;r.status&&o&&!o(r.status)?t(n("Request failed with status code "+r.status,r.config,null,r.request,r)):e(r)}},function(e,t,r){"use strict";var n=r(141);e.exports=function(e,t,r,o,i){var a=new Error(e);return n(a,t,r,o,i)}},function(e){"use strict";e.exports=function(e,t,r,n,o){return e.config=t,r&&(e.code=r),e.request=n,e.response=o,e}},function(e,t,r){"use strict";function n(e){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var o=r(131);e.exports=function(e,t,r){if(!t)return e;var i;if(r)i=r(t);else if(o.isURLSearchParams(t))i=t.toString();else{var a=[];o.forEach(t,function(e,t){null!==e&&"undefined"!=typeof e&&(o.isArray(e)?t+="[]":e=[e],o.forEach(e,function(e){o.isDate(e)?e=e.toISOString():o.isObject(e)&&(e=JSON.stringify(e)),a.push(n(t)+"="+n(e))}))}),i=a.join("&")}return i&&(e+=(-1===e.indexOf("?")?"?":"&")+i),e}},function(e,t,r){"use strict";var n=r(131),o=["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"];e.exports=function(e){var t,r,i,a={};return e?(n.forEach(e.split("\n"),function(e){if(i=e.indexOf(":"),t=n.trim(e.substr(0,i)).toLowerCase(),r=n.trim(e.substr(i+1)),t){if(a[t]&&o.indexOf(t)>=0)return;a[t]="set-cookie"===t?(a[t]?a[t]:[]).concat([r]):a[t]?a[t]+", "+r:r}}),a):a}},function(e,t,r){"use strict";var n=r(131);e.exports=n.isStandardBrowserEnv()?function(){function e(e){var t=e;return r&&(o.setAttribute("href",t),t=o.href),o.setAttribute("href",t),{href:o.href,protocol:o.protocol?o.protocol.replace(/:$/,""):"",host:o.host,search:o.search?o.search.replace(/^\?/,""):"",hash:o.hash?o.hash.replace(/^#/,""):"",hostname:o.hostname,port:o.port,pathname:"/"===o.pathname.charAt(0)?o.pathname:"/"+o.pathname}}var t,r=/(msie|trident)/i.test(navigator.userAgent),o=document.createElement("a");return t=e(window.location.href),function(r){var o=n.isString(r)?e(r):r;return o.protocol===t.protocol&&o.host===t.host}}():function(){return function(){return!0}}()},function(e,t,r){"use strict";var n=r(131);e.exports=n.isStandardBrowserEnv()?function(){return{write:function(e,t,r,o,i,a){var s=[];s.push(e+"="+encodeURIComponent(t)),n.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),n.isString(o)&&s.push("path="+o),n.isString(i)&&s.push("domain="+i),a===!0&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}()},function(e,t,r){"use strict";function n(){this.handlers=[]}var o=r(131);n.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},n.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},n.prototype.forEach=function(e){o.forEach(this.handlers,function(t){null!==t&&e(t)})},e.exports=n},function(e,t,r){"use strict";function n(e){e.cancelToken&&e.cancelToken.throwIfRequested()}var o=r(131),i=r(148),a=r(149),s=r(135),u=r(150),c=r(151);e.exports=function(e){n(e),e.baseURL&&!u(e.url)&&(e.url=c(e.baseURL,e.url)),e.headers=e.headers||{},e.data=i(e.data,e.headers,e.transformRequest),e.headers=o.merge(e.headers.common||{},e.headers[e.method]||{},e.headers||{}),o.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]
});var t=e.adapter||s.adapter;return t(e).then(function(t){return n(e),t.data=i(t.data,t.headers,e.transformResponse),t},function(t){return a(t)||(n(e),t&&t.response&&(t.response.data=i(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})}},function(e,t,r){"use strict";var n=r(131);e.exports=function(e,t,r){return n.forEach(r,function(r){e=r(e,t)}),e}},function(e){"use strict";e.exports=function(e){return!(!e||!e.__CANCEL__)}},function(e){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},function(e){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},function(e){"use strict";function t(e){this.message=e}t.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},t.prototype.__CANCEL__=!0,e.exports=t},function(e,t,r){"use strict";function n(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(e){t=e});var r=this;e(function(e){r.reason||(r.reason=new o(e),t(r.reason))})}var o=r(152);n.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},n.source=function(){var e,t=new n(function(t){e=t});return{token:t,cancel:e}},e.exports=n},function(e){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},function(e,t,r){(function(t,n){function o(e){return y.every(function(t,r){return e[r]===t})}function i(e,r){function f(t){k!==i.CLOSED&&(k=i.CONNECTING,w("error",new a("error",{message:t})),P&&(e=P,P=null),setTimeout(function(){k===i.CONNECTING&&p()},A.reconnectInterval))}function p(){var s=c(e),u="https:"===s.protocol;if(s.headers={"Cache-Control":"no-cache",Accept:"text/event-stream"},E&&(s.headers["Last-Event-ID"]=E),r&&r.headers)for(var g in r.headers){var x=r.headers[g];x&&(s.headers[g]=x)}s.rejectUnauthorized=!(r&&!r.rejectUnauthorized);var C=r&&r.proxy;if(C){var T=c(r.proxy);u="https:"===T.protocol,s.protocol=u?"https:":"http:",s.path=e,s.headers.Host=s.host,s.hostname=T.hostname,s.host=T.host,s.port=T.port}if(r&&r.https)for(var j in r.https)if(-1!==d.indexOf(j)){var R=r.https[j];void 0!==R&&(s[j]=R)}r&&void 0!==r.withCredentials&&(s.withCredentials=r.withCredentials),O=(u?l:h).request(s,function(r){if(500===r.statusCode||502===r.statusCode||503===r.statusCode||504===r.statusCode)return w("error",new a("error",{status:r.statusCode,message:r.statusMessage})),f(),void 0;if(301===r.statusCode||307===r.statusCode)return r.headers.location?(307===r.statusCode&&(P=e),e=r.headers.location,t.nextTick(p),void 0):(w("error",new a("error",{status:r.statusCode,message:r.statusMessage})),void 0);if(200!==r.statusCode)return w("error",new a("error",{status:r.statusCode,message:r.statusMessage})),A.close();k=i.OPEN,r.on("close",function(){r.removeAllListeners("close"),r.removeAllListeners("end"),f()}),r.on("end",function(){r.removeAllListeners("close"),r.removeAllListeners("end"),f()}),w("open",new a("open"));var s,u=!0;r.on("data",function(e){s=s?n.concat([s,e]):e,u&&o(s)&&(s=s.slice(y.length)),u=!1;for(var t=0,r=s.length;r>t;){S&&(s[t]===m&&++t,S=!1);for(var i,a=-1,c=-1,f=t;0>a&&r>f;++f)i=s[f],i===v?0>c&&(c=f-t):i===b?(S=!0,a=f-t):i===m&&(a=f-t);if(0>a)break;_(s,t,c,a),t+=a+1}t===r?s=void 0:t>0&&(s=s.slice(t))})}),O.on("error",function(e){f(e.message)}),O.setNoDelay&&O.setNoDelay(!0),O.end()}function w(){A.listeners(arguments[0]).length>0&&A.emit.apply(A,arguments)}function _(t,r,n,o){if(0===o){if(x.length>0){var i=C||"message";w(i,new s(i,{data:x.slice(0,-1),lastEventId:E,origin:u(e)})),x=""}C=void 0}else if(n>0){var a=0>n,c=0,f=t.slice(r,r+(a?o:n)).toString();c=a?o:t[r+n+1]!==g?n+1:n+2,r+=c;var l=o-c,h=t.slice(r,r+l).toString();if("data"===f)x+=h+"\n";else if("event"===f)C=h;else if("id"===f)E=h;else if("retry"===f){var p=parseInt(h,10);Number.isNaN(p)||(A.reconnectInterval=p)}}}var k=i.CONNECTING;Object.defineProperty(this,"readyState",{get:function(){return k}}),Object.defineProperty(this,"url",{get:function(){return e}});var A=this;A.reconnectInterval=1e3;var O,E="";r&&r.headers&&r.headers["Last-Event-ID"]&&(E=r.headers["Last-Event-ID"],delete r.headers["Last-Event-ID"]);var S=!1,x="",C="",P=null;p(),this._close=function(){k!==i.CLOSED&&(k=i.CLOSED,O.abort&&O.abort(),O.xhr&&O.xhr.abort&&O.xhr.abort())}}function a(e,t){if(Object.defineProperty(this,"type",{writable:!1,value:e,enumerable:!0}),t)for(var r in t)t.hasOwnProperty(r)&&Object.defineProperty(this,r,{writable:!1,value:t[r],enumerable:!0})}function s(e,t){Object.defineProperty(this,"type",{writable:!1,value:e,enumerable:!0});for(var r in t)t.hasOwnProperty(r)&&Object.defineProperty(this,r,{writable:!1,value:t[r],enumerable:!0})}var u=r(160),c=r(164).parse,f=r(170),l=r(171),h=r(172),p=r(199),d=["pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","secureProtocol","servername","checkServerIdentity"],y=[239,187,191],v=58,g=32,m=10,b=13;e.exports=i,p.inherits(i,f.EventEmitter),i.prototype.constructor=i,["open","error","message"].forEach(function(e){Object.defineProperty(i.prototype,"on"+e,{get:function(){var t=this.listeners(e)[0];return t?t._listener?t._listener:t:void 0},set:function(t){this.removeAllListeners(e),this.addEventListener(e,t)}})}),Object.defineProperty(i,"CONNECTING",{enumerable:!0,value:0}),Object.defineProperty(i,"OPEN",{enumerable:!0,value:1}),Object.defineProperty(i,"CLOSED",{enumerable:!0,value:2}),i.prototype.CONNECTING=0,i.prototype.OPEN=1,i.prototype.CLOSED=2,i.prototype.close=function(){this._close()},i.prototype.addEventListener=function(e,t){"function"==typeof t&&(t._listener=t,this.on(e,t))},i.prototype.dispatchEvent=function(e){if(!e.type)throw new Error("UNSPECIFIED_EVENT_TYPE_ERR");this.emit(e.type,e.detail)},i.prototype.removeEventListener=function(e,t){"function"==typeof t&&(t._listener=void 0,this.removeListener(e,t))}}).call(t,r(136),r(156).Buffer)},function(e,t,r){(function(e){"use strict";function n(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(t){return!1}}function o(){return a.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function i(e,t){if(o()<t)throw new RangeError("Invalid typed array length");return a.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t),e.__proto__=a.prototype):(null===e&&(e=new a(t)),e.length=t),e}function a(e,t,r){if(!(a.TYPED_ARRAY_SUPPORT||this instanceof a))return new a(e,t,r);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return s(this,e,t,r)}function s(e,t,r,n){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?p(e,t,r,n):"string"==typeof t?l(e,t,r):d(e,t)}function u(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(0>e)throw new RangeError('"size" argument must not be negative')}function c(e,t,r,n){return u(t),0>=t?i(e,t):void 0!==r?"string"==typeof n?i(e,t).fill(r,n):i(e,t).fill(r):i(e,t)}function f(e,t){if(u(t),e=i(e,0>t?0:0|y(t)),!a.TYPED_ARRAY_SUPPORT)for(var r=0;t>r;++r)e[r]=0;return e}function l(e,t,r){if(("string"!=typeof r||""===r)&&(r="utf8"),!a.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var n=0|g(t,r);e=i(e,n);var o=e.write(t,r);return o!==n&&(e=e.slice(0,o)),e}function h(e,t){var r=t.length<0?0:0|y(t.length);e=i(e,r);for(var n=0;r>n;n+=1)e[n]=255&t[n];return e}function p(e,t,r,n){if(t.byteLength,0>r||t.byteLength<r)throw new RangeError("'offset' is out of bounds");if(t.byteLength<r+(n||0))throw new RangeError("'length' is out of bounds");return t=void 0===r&&void 0===n?new Uint8Array(t):void 0===n?new Uint8Array(t,r):new Uint8Array(t,r,n),a.TYPED_ARRAY_SUPPORT?(e=t,e.__proto__=a.prototype):e=h(e,t),e}function d(e,t){if(a.isBuffer(t)){var r=0|y(t.length);return e=i(e,r),0===e.length?e:(t.copy(e,0,0,r),e)}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||W(t.length)?i(e,0):h(e,t);if("Buffer"===t.type&&J(t.data))return h(e,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function y(e){if(e>=o())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o().toString(16)+" bytes");return 0|e}function v(e){return+e!=e&&(e=0),a.alloc(+e)}function g(e,t){if(a.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return K(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return Y(e).length;default:if(n)return K(e).length;t=(""+t).toLowerCase(),n=!0}}function m(e,t,r){var n=!1;if((void 0===t||0>t)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),0>=r)return"";if(r>>>=0,t>>>=0,t>=r)return"";for(e||(e="utf8");;)switch(e){case"hex":return I(this,t,r);case"utf8":case"utf-8":return P(this,t,r);case"ascii":return j(this,t,r);case"latin1":case"binary":return R(this,t,r);case"base64":return C(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return B(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function b(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function w(e,t,r,n,o){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:-2147483648>r&&(r=-2147483648),r=+r,isNaN(r)&&(r=o?0:e.length-1),0>r&&(r=e.length+r),r>=e.length){if(o)return-1;r=e.length-1}else if(0>r){if(!o)return-1;r=0}if("string"==typeof t&&(t=a.from(t,n)),a.isBuffer(t))return 0===t.length?-1:_(e,t,r,n,o);if("number"==typeof t)return t=255&t,a.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):_(e,[t],r,n,o);throw new TypeError("val must be string, number or Buffer")}function _(e,t,r,n,o){function i(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}var a=1,s=e.length,u=t.length;if(void 0!==n&&(n=String(n).toLowerCase(),"ucs2"===n||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,r/=2}var c;if(o){var f=-1;for(c=r;s>c;c++)if(i(e,c)===i(t,-1===f?0:c-f)){if(-1===f&&(f=c),c-f+1===u)return f*a}else-1!==f&&(c-=c-f),f=-1}else for(r+u>s&&(r=s-u),c=r;c>=0;c--){for(var l=!0,h=0;u>h;h++)if(i(e,c+h)!==i(t,h)){l=!1;break}if(l)return c}return-1}function k(e,t,r,n){r=Number(r)||0;var o=e.length-r;n?(n=Number(n),n>o&&(n=o)):n=o;var i=t.length;if(i%2!==0)throw new TypeError("Invalid hex string");n>i/2&&(n=i/2);for(var a=0;n>a;++a){var s=parseInt(t.substr(2*a,2),16);if(isNaN(s))return a;e[r+a]=s}return a}function A(e,t,r,n){return $(K(t,e.length-r),e,r,n)}function O(e,t,r,n){return $(X(t),e,r,n)}function E(e,t,r,n){return O(e,t,r,n)}function S(e,t,r,n){return $(Y(t),e,r,n)}function x(e,t,r,n){return $(Q(t,e.length-r),e,r,n)}function C(e,t,r){return 0===t&&r===e.length?Z.fromByteArray(e):Z.fromByteArray(e.slice(t,r))}function P(e,t,r){r=Math.min(e.length,r);for(var n=[],o=t;r>o;){var i=e[o],a=null,s=i>239?4:i>223?3:i>191?2:1;if(r>=o+s){var u,c,f,l;switch(s){case 1:128>i&&(a=i);break;case 2:u=e[o+1],128===(192&u)&&(l=(31&i)<<6|63&u,l>127&&(a=l));break;case 3:u=e[o+1],c=e[o+2],128===(192&u)&&128===(192&c)&&(l=(15&i)<<12|(63&u)<<6|63&c,l>2047&&(55296>l||l>57343)&&(a=l));break;case 4:u=e[o+1],c=e[o+2],f=e[o+3],128===(192&u)&&128===(192&c)&&128===(192&f)&&(l=(15&i)<<18|(63&u)<<12|(63&c)<<6|63&f,l>65535&&1114112>l&&(a=l))}}null===a?(a=65533,s=1):a>65535&&(a-=65536,n.push(a>>>10&1023|55296),a=56320|1023&a),n.push(a),o+=s}return T(n)}function T(e){var t=e.length;if(et>=t)return String.fromCharCode.apply(String,e);for(var r="",n=0;t>n;)r+=String.fromCharCode.apply(String,e.slice(n,n+=et));return r}function j(e,t,r){var n="";r=Math.min(e.length,r);for(var o=t;r>o;++o)n+=String.fromCharCode(127&e[o]);return n}function R(e,t,r){var n="";r=Math.min(e.length,r);for(var o=t;r>o;++o)n+=String.fromCharCode(e[o]);return n}function I(e,t,r){var n=e.length;(!t||0>t)&&(t=0),(!r||0>r||r>n)&&(r=n);for(var o="",i=t;r>i;++i)o+=V(e[i]);return o}function B(e,t,r){for(var n=e.slice(t,r),o="",i=0;i<n.length;i+=2)o+=String.fromCharCode(n[i]+256*n[i+1]);return o}function M(e,t,r){if(e%1!==0||0>e)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}function N(e,t,r,n,o,i){if(!a.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||i>t)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function U(e,t,r,n){0>t&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-r,2);i>o;++o)e[r+o]=(t&255<<8*(n?o:1-o))>>>8*(n?o:1-o)}function L(e,t,r,n){0>t&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-r,4);i>o;++o)e[r+o]=t>>>8*(n?o:3-o)&255}function D(e,t,r,n){if(r+n>e.length)throw new RangeError("Index out of range");if(0>r)throw new RangeError("Index out of range")}function q(e,t,r,n,o){return o||D(e,t,r,4,3.4028234663852886e38,-3.4028234663852886e38),G.write(e,t,r,n,23,4),r+4}function F(e,t,r,n,o){return o||D(e,t,r,8,1.7976931348623157e308,-1.7976931348623157e308),G.write(e,t,r,n,52,8),r+8}function z(e){if(e=H(e).replace(tt,""),e.length<2)return"";for(;e.length%4!==0;)e+="=";return e}function H(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function V(e){return 16>e?"0"+e.toString(16):e.toString(16)}function K(e,t){t=t||1/0;for(var r,n=e.length,o=null,i=[],a=0;n>a;++a){if(r=e.charCodeAt(a),r>55295&&57344>r){if(!o){if(r>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(56320>r){(t-=3)>-1&&i.push(239,191,189),o=r;continue}r=(o-55296<<10|r-56320)+65536}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,128>r){if((t-=1)<0)break;i.push(r)}else if(2048>r){if((t-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(65536>r){if((t-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(1114112>r))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return i}function X(e){for(var t=[],r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}function Q(e,t){for(var r,n,o,i=[],a=0;a<e.length&&!((t-=2)<0);++a)r=e.charCodeAt(a),n=r>>8,o=r%256,i.push(o),i.push(n);return i}function Y(e){return Z.toByteArray(z(e))}function $(e,t,r,n){for(var o=0;n>o&&!(o+r>=t.length||o>=e.length);++o)t[o+r]=e[o];return o}function W(e){return e!==e}var Z=r(157),G=r(158),J=r(159);t.Buffer=a,t.SlowBuffer=v,t.INSPECT_MAX_BYTES=50,a.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:n(),t.kMaxLength=o(),a.poolSize=8192,a._augment=function(e){return e.__proto__=a.prototype,e},a.from=function(e,t,r){return s(null,e,t,r)},a.TYPED_ARRAY_SUPPORT&&(a.prototype.__proto__=Uint8Array.prototype,a.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&a[Symbol.species]===a&&Object.defineProperty(a,Symbol.species,{value:null,configurable:!0})),a.alloc=function(e,t,r){return c(null,e,t,r)},a.allocUnsafe=function(e){return f(null,e)},a.allocUnsafeSlow=function(e){return f(null,e)},a.isBuffer=function(e){return!(null==e||!e._isBuffer)},a.compare=function(e,t){if(!a.isBuffer(e)||!a.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var r=e.length,n=t.length,o=0,i=Math.min(r,n);i>o;++o)if(e[o]!==t[o]){r=e[o],n=t[o];break}return n>r?-1:r>n?1:0},a.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},a.concat=function(e,t){if(!J(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return a.alloc(0);var r;if(void 0===t)for(t=0,r=0;r<e.length;++r)t+=e[r].length;var n=a.allocUnsafe(t),o=0;for(r=0;r<e.length;++r){var i=e[r];if(!a.isBuffer(i))throw new TypeError('"list" argument must be an Array of Buffers');i.copy(n,o),o+=i.length}return n},a.byteLength=g,a.prototype._isBuffer=!0,a.prototype.swap16=function(){var e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;e>t;t+=2)b(this,t,t+1);return this},a.prototype.swap32=function(){var e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;e>t;t+=4)b(this,t,t+3),b(this,t+1,t+2);return this},a.prototype.swap64=function(){var e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;e>t;t+=8)b(this,t,t+7),b(this,t+1,t+6),b(this,t+2,t+5),b(this,t+3,t+4);return this},a.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?P(this,0,e):m.apply(this,arguments)},a.prototype.equals=function(e){if(!a.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e?!0:0===a.compare(this,e)},a.prototype.inspect=function(){var e="",r=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),"<Buffer "+e+">"},a.prototype.compare=function(e,t,r,n,o){if(!a.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),0>t||r>e.length||0>n||o>this.length)throw new RangeError("out of range index");if(n>=o&&t>=r)return 0;if(n>=o)return-1;if(t>=r)return 1;if(t>>>=0,r>>>=0,n>>>=0,o>>>=0,this===e)return 0;for(var i=o-n,s=r-t,u=Math.min(i,s),c=this.slice(n,o),f=e.slice(t,r),l=0;u>l;++l)if(c[l]!==f[l]){i=c[l],s=f[l];break}return s>i?-1:i>s?1:0},a.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},a.prototype.indexOf=function(e,t,r){return w(this,e,t,r,!0)},a.prototype.lastIndexOf=function(e,t,r){return w(this,e,t,r,!1)},a.prototype.write=function(e,t,r,n){if(void 0===t)n="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)n=t,r=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t=0|t,isFinite(r)?(r=0|r,void 0===n&&(n="utf8")):(n=r,r=void 0)}var o=this.length-t;if((void 0===r||r>o)&&(r=o),e.length>0&&(0>r||0>t)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var i=!1;;)switch(n){case"hex":return k(this,e,t,r);case"utf8":case"utf-8":return A(this,e,t,r);case"ascii":return O(this,e,t,r);case"latin1":case"binary":return E(this,e,t,r);case"base64":return S(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,e,t,r);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),i=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var et=4096;a.prototype.slice=function(e,t){var r=this.length;e=~~e,t=void 0===t?r:~~t,0>e?(e+=r,0>e&&(e=0)):e>r&&(e=r),0>t?(t+=r,0>t&&(t=0)):t>r&&(t=r),e>t&&(t=e);var n;if(a.TYPED_ARRAY_SUPPORT)n=this.subarray(e,t),n.__proto__=a.prototype;else{var o=t-e;n=new a(o,void 0);for(var i=0;o>i;++i)n[i]=this[i+e]}return n},a.prototype.readUIntLE=function(e,t,r){e=0|e,t=0|t,r||M(e,t,this.length);for(var n=this[e],o=1,i=0;++i<t&&(o*=256);)n+=this[e+i]*o;return n},a.prototype.readUIntBE=function(e,t,r){e=0|e,t=0|t,r||M(e,t,this.length);for(var n=this[e+--t],o=1;t>0&&(o*=256);)n+=this[e+--t]*o;return n},a.prototype.readUInt8=function(e,t){return t||M(e,1,this.length),this[e]},a.prototype.readUInt16LE=function(e,t){return t||M(e,2,this.length),this[e]|this[e+1]<<8},a.prototype.readUInt16BE=function(e,t){return t||M(e,2,this.length),this[e]<<8|this[e+1]},a.prototype.readUInt32LE=function(e,t){return t||M(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},a.prototype.readUInt32BE=function(e,t){return t||M(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},a.prototype.readIntLE=function(e,t,r){e=0|e,t=0|t,r||M(e,t,this.length);for(var n=this[e],o=1,i=0;++i<t&&(o*=256);)n+=this[e+i]*o;return o*=128,n>=o&&(n-=Math.pow(2,8*t)),n},a.prototype.readIntBE=function(e,t,r){e=0|e,t=0|t,r||M(e,t,this.length);for(var n=t,o=1,i=this[e+--n];n>0&&(o*=256);)i+=this[e+--n]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*t)),i},a.prototype.readInt8=function(e,t){return t||M(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},a.prototype.readInt16LE=function(e,t){t||M(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},a.prototype.readInt16BE=function(e,t){t||M(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},a.prototype.readInt32LE=function(e,t){return t||M(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},a.prototype.readInt32BE=function(e,t){return t||M(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},a.prototype.readFloatLE=function(e,t){return t||M(e,4,this.length),G.read(this,e,!0,23,4)},a.prototype.readFloatBE=function(e,t){return t||M(e,4,this.length),G.read(this,e,!1,23,4)},a.prototype.readDoubleLE=function(e,t){return t||M(e,8,this.length),G.read(this,e,!0,52,8)},a.prototype.readDoubleBE=function(e,t){return t||M(e,8,this.length),G.read(this,e,!1,52,8)},a.prototype.writeUIntLE=function(e,t,r,n){if(e=+e,t=0|t,r=0|r,!n){var o=Math.pow(2,8*r)-1;N(this,e,t,r,o,0)}var i=1,a=0;for(this[t]=255&e;++a<r&&(i*=256);)this[t+a]=e/i&255;return t+r},a.prototype.writeUIntBE=function(e,t,r,n){if(e=+e,t=0|t,r=0|r,!n){var o=Math.pow(2,8*r)-1;N(this,e,t,r,o,0)}var i=r-1,a=1;for(this[t+i]=255&e;--i>=0&&(a*=256);)this[t+i]=e/a&255;return t+r},a.prototype.writeUInt8=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,1,255,0),a.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},a.prototype.writeUInt16LE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,2,65535,0),a.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):U(this,e,t,!0),t+2},a.prototype.writeUInt16BE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,2,65535,0),a.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):U(this,e,t,!1),t+2},a.prototype.writeUInt32LE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,4,4294967295,0),a.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):L(this,e,t,!0),t+4},a.prototype.writeUInt32BE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,4,4294967295,0),a.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):L(this,e,t,!1),t+4},a.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t=0|t,!n){var o=Math.pow(2,8*r-1);N(this,e,t,r,o-1,-o)}var i=0,a=1,s=0;for(this[t]=255&e;++i<r&&(a*=256);)0>e&&0===s&&0!==this[t+i-1]&&(s=1),this[t+i]=(e/a>>0)-s&255;return t+r},a.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t=0|t,!n){var o=Math.pow(2,8*r-1);N(this,e,t,r,o-1,-o)}var i=r-1,a=1,s=0;for(this[t+i]=255&e;--i>=0&&(a*=256);)0>e&&0===s&&0!==this[t+i+1]&&(s=1),this[t+i]=(e/a>>0)-s&255;return t+r},a.prototype.writeInt8=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,1,127,-128),a.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),0>e&&(e=255+e+1),this[t]=255&e,t+1},a.prototype.writeInt16LE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,2,32767,-32768),a.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):U(this,e,t,!0),t+2},a.prototype.writeInt16BE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,2,32767,-32768),a.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):U(this,e,t,!1),t+2},a.prototype.writeInt32LE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,4,2147483647,-2147483648),a.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):L(this,e,t,!0),t+4},a.prototype.writeInt32BE=function(e,t,r){return e=+e,t=0|t,r||N(this,e,t,4,2147483647,-2147483648),0>e&&(e=4294967295+e+1),a.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):L(this,e,t,!1),t+4},a.prototype.writeFloatLE=function(e,t,r){return q(this,e,t,!0,r)},a.prototype.writeFloatBE=function(e,t,r){return q(this,e,t,!1,r)},a.prototype.writeDoubleLE=function(e,t,r){return F(this,e,t,!0,r)},a.prototype.writeDoubleBE=function(e,t,r){return F(this,e,t,!1,r)},a.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&r>n&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(0>t)throw new RangeError("targetStart out of bounds");if(0>r||r>=this.length)throw new RangeError("sourceStart out of bounds");if(0>n)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);var o,i=n-r;if(this===e&&t>r&&n>t)for(o=i-1;o>=0;--o)e[o+t]=this[o+r];else if(1e3>i||!a.TYPED_ARRAY_SUPPORT)for(o=0;i>o;++o)e[o+t]=this[o+r];else Uint8Array.prototype.set.call(e,this.subarray(r,r+i),t);return i},a.prototype.fill=function(e,t,r,n){if("string"==typeof e){if("string"==typeof t?(n=t,t=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),1===e.length){var o=e.charCodeAt(0);256>o&&(e=o)}if(void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!a.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"==typeof e&&(e=255&e);if(0>t||this.length<t||this.length<r)throw new RangeError("Out of range index");if(t>=r)return this;t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0);var i;if("number"==typeof e)for(i=t;r>i;++i)this[i]=e;else{var s=a.isBuffer(e)?e:K(new a(e,n).toString()),u=s.length;for(i=0;r-t>i;++i)this[i+t]=s[i%u]}return this};var tt=/[^+\/0-9A-Za-z-_]/g}).call(t,function(){return this}())},function(e,t){"use strict";function r(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");-1===r&&(r=t);var n=r===t?0:4-r%4;return[r,n]}function n(e){var t=r(e),n=t[0],o=t[1];return 3*(n+o)/4-o}function o(e,t,r){return 3*(t+r)/4-r}function i(e){var t,n,i=r(e),a=i[0],s=i[1],u=new l(o(e,a,s)),c=0,h=s>0?a-4:a;for(n=0;h>n;n+=4)t=f[e.charCodeAt(n)]<<18|f[e.charCodeAt(n+1)]<<12|f[e.charCodeAt(n+2)]<<6|f[e.charCodeAt(n+3)],u[c++]=t>>16&255,u[c++]=t>>8&255,u[c++]=255&t;return 2===s&&(t=f[e.charCodeAt(n)]<<2|f[e.charCodeAt(n+1)]>>4,u[c++]=255&t),1===s&&(t=f[e.charCodeAt(n)]<<10|f[e.charCodeAt(n+1)]<<4|f[e.charCodeAt(n+2)]>>2,u[c++]=t>>8&255,u[c++]=255&t),u}function a(e){return c[e>>18&63]+c[e>>12&63]+c[e>>6&63]+c[63&e]}function s(e,t,r){for(var n,o=[],i=t;r>i;i+=3)n=(e[i]<<16&16711680)+(e[i+1]<<8&65280)+(255&e[i+2]),o.push(a(n));return o.join("")}function u(e){for(var t,r=e.length,n=r%3,o=[],i=16383,a=0,u=r-n;u>a;a+=i)o.push(s(e,a,a+i>u?u:a+i));return 1===n?(t=e[r-1],o.push(c[t>>2]+c[t<<4&63]+"==")):2===n&&(t=(e[r-2]<<8)+e[r-1],o.push(c[t>>10]+c[t>>4&63]+c[t<<2&63]+"=")),o.join("")}t.byteLength=n,t.toByteArray=i,t.fromByteArray=u;for(var c=[],f=[],l="undefined"!=typeof Uint8Array?Uint8Array:Array,h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",p=0,d=h.length;d>p;++p)c[p]=h[p],f[h.charCodeAt(p)]=p;f["-".charCodeAt(0)]=62,f["_".charCodeAt(0)]=63},function(e,t){t.read=function(e,t,r,n,o){var i,a,s=8*o-n-1,u=(1<<s)-1,c=u>>1,f=-7,l=r?o-1:0,h=r?-1:1,p=e[t+l];for(l+=h,i=p&(1<<-f)-1,p>>=-f,f+=s;f>0;i=256*i+e[t+l],l+=h,f-=8);for(a=i&(1<<-f)-1,i>>=-f,f+=n;f>0;a=256*a+e[t+l],l+=h,f-=8);if(0===i)i=1-c;else{if(i===u)return a?0/0:1/0*(p?-1:1);a+=Math.pow(2,n),i-=c}return(p?-1:1)*a*Math.pow(2,i-n)},t.write=function(e,t,r,n,o,i){var a,s,u,c=8*i-o-1,f=(1<<c)-1,l=f>>1,h=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=n?0:i-1,d=n?1:-1,y=0>t||0===t&&0>1/t?1:0;for(t=Math.abs(t),isNaN(t)||1/0===t?(s=isNaN(t)?1:0,a=f):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),t+=a+l>=1?h/u:h*Math.pow(2,1-l),t*u>=2&&(a++,u/=2),a+l>=f?(s=0,a=f):a+l>=1?(s=(t*u-1)*Math.pow(2,o),a+=l):(s=t*Math.pow(2,l-1)*Math.pow(2,o),a=0));o>=8;e[r+p]=255&s,p+=d,s/=256,o-=8);for(a=a<<o|s,c+=o;c>0;e[r+p]=255&a,p+=d,a/=256,c-=8);e[r+p-d]|=128*y}},function(e){var t={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==t.call(e)}},function(e,t,r){"use strict";function n(e){return"string"==typeof e&&(e=o(e)),e.protocol&&e.hostname?(e.protocol+"//"+e.host).toLowerCase():"null"}var o=r(161);n.same=function(e,t){return n(e)===n(t)},e.exports=n},function(e,t,r){(function(t){"use strict";function n(e){return(e?e:"").toString().replace(y,"")}function o(e){var r;r="undefined"!=typeof window?window:"undefined"!=typeof t?t:"undefined"!=typeof self?self:{};var n=r.location||{};e=e||n;var o,i={},a=typeof e;if("blob:"===e.protocol)i=new s(unescape(e.pathname),{});else if("string"===a){i=new s(e,{});for(o in g)delete i[o]}else if("object"===a){for(o in e)o in g||(i[o]=e[o]);void 0===i.slashes&&(i.slashes=h.test(e.href))}return i}function i(e){e=n(e);var t=p.exec(e);return{protocol:t[1]?t[1].toLowerCase():"",slashes:!!t[2],rest:t[3]}}function a(e,t){if(""===e)return t;for(var r=(t||"/").split("/").slice(0,-1).concat(e.split("/")),n=r.length,o=r[n-1],i=!1,a=0;n--;)"."===r[n]?r.splice(n,1):".."===r[n]?(r.splice(n,1),a++):a&&(0===n&&(i=!0),r.splice(n,1),a--);return i&&r.unshift(""),("."===o||".."===o)&&r.push(""),r.join("/")}function s(e,t,r){if(e=n(e),!(this instanceof s))return new s(e,t,r);var u,c,h,p,d,y,g=v.slice(),m=typeof t,b=this,w=0;for("object"!==m&&"string"!==m&&(r=t,t=null),r&&"function"!=typeof r&&(r=l.parse),t=o(t),c=i(e||""),u=!c.protocol&&!c.slashes,b.slashes=c.slashes||u&&t.slashes,b.protocol=c.protocol||t.protocol||"",e=c.rest,c.slashes||(g[3]=[/(.*)/,"pathname"]);w<g.length;w++)p=g[w],"function"!=typeof p?(h=p[0],y=p[1],h!==h?b[y]=e:"string"==typeof h?~(d=e.indexOf(h))&&("number"==typeof p[2]?(b[y]=e.slice(0,d),e=e.slice(d+p[2])):(b[y]=e.slice(d),e=e.slice(0,d))):(d=h.exec(e))&&(b[y]=d[1],e=e.slice(0,d.index)),b[y]=b[y]||(u&&p[3]?t[y]||"":""),p[4]&&(b[y]=b[y].toLowerCase())):e=p(e);r&&(b.query=r(b.query)),u&&t.slashes&&"/"!==b.pathname.charAt(0)&&(""!==b.pathname||""!==t.pathname)&&(b.pathname=a(b.pathname,t.pathname)),f(b.port,b.protocol)||(b.host=b.hostname,b.port=""),b.username=b.password="",b.auth&&(p=b.auth.split(":"),b.username=p[0]||"",b.password=p[1]||""),b.origin=b.protocol&&b.host&&"file:"!==b.protocol?b.protocol+"//"+b.host:"null",b.href=b.toString()}function u(e,t,r){var n=this;switch(e){case"query":"string"==typeof t&&t.length&&(t=(r||l.parse)(t)),n[e]=t;break;case"port":n[e]=t,f(t,n.protocol)?t&&(n.host=n.hostname+":"+t):(n.host=n.hostname,n[e]="");break;case"hostname":n[e]=t,n.port&&(t+=":"+n.port),n.host=t;break;case"host":n[e]=t,/:\d+$/.test(t)?(t=t.split(":"),n.port=t.pop(),n.hostname=t.join(":")):(n.hostname=t,n.port="");break;case"protocol":n.protocol=t.toLowerCase(),n.slashes=!r;break;case"pathname":case"hash":if(t){var o="pathname"===e?"/":"#";n[e]=t.charAt(0)!==o?o+t:t}else n[e]=t;break;default:n[e]=t}for(var i=0;i<v.length;i++){var a=v[i];a[4]&&(n[a[1]]=n[a[1]].toLowerCase())}return n.origin=n.protocol&&n.host&&"file:"!==n.protocol?n.protocol+"//"+n.host:"null",n.href=n.toString(),n}function c(e){e&&"function"==typeof e||(e=l.stringify);var t,r=this,n=r.protocol;n&&":"!==n.charAt(n.length-1)&&(n+=":");var o=n+(r.slashes?"//":"");return r.username&&(o+=r.username,r.password&&(o+=":"+r.password),o+="@"),o+=r.host+r.pathname,t="object"==typeof r.query?e(r.query):r.query,t&&(o+="?"!==t.charAt(0)?"?"+t:t),r.hash&&(o+=r.hash),o}var f=r(162),l=r(163),h=/^[A-Za-z][A-Za-z0-9+-.]*:\/\//,p=/^([a-z][a-z0-9.+-]*:)?(\/\/)?([\S\s]*)/i,d="[\\x09\\x0A\\x0B\\x0C\\x0D\\x20\\xA0\\u1680\\u180E\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200A\\u202F\\u205F\\u3000\\u2028\\u2029\\uFEFF]",y=new RegExp("^"+d+"+"),v=[["#","hash"],["?","query"],function(e){return e.replace("\\","/")},["/","pathname"],["@","auth",1],[0/0,"host",void 0,1,1],[/:(\d+)$/,"port",void 0,1],[0/0,"hostname",void 0,1,1]],g={hash:1,query:1};
s.prototype={set:u,toString:c},s.extractProtocol=i,s.location=o,s.trimLeft=n,s.qs=l,e.exports=s}).call(t,function(){return this}())},function(e){"use strict";e.exports=function(e,t){if(t=t.split(":")[0],e=+e,!e)return!1;switch(t){case"http":case"ws":return 80!==e;case"https":case"wss":return 443!==e;case"ftp":return 21!==e;case"gopher":return 70!==e;case"file":return!1}return 0!==e}},function(e,t){"use strict";function r(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(t){return null}}function n(e){for(var t,n=/([^=?&]+)=?([^&]*)/g,o={};t=n.exec(e);){var i=r(t[1]),a=r(t[2]);null===i||null===a||i in o||(o[i]=a)}return o}function o(e,t){t=t||"";var r,n,o=[];"string"!=typeof t&&(t="?");for(n in e)if(a.call(e,n)){if(r=e[n],r||null!==r&&r!==i&&!isNaN(r)||(r=""),n=encodeURIComponent(n),r=encodeURIComponent(r),null===n||null===r)continue;o.push(n+"="+r)}return o.length?t+o.join("&"):""}var i,a=Object.prototype.hasOwnProperty;t.stringify=o,t.parse=n},function(e,t,r){"use strict";function n(){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}function o(e,t,r){if(e&&c.isObject(e)&&e instanceof n)return e;var o=new n;return o.parse(e,t,r),o}function i(e){return c.isString(e)&&(e=o(e)),e instanceof n?e.format():n.prototype.format.call(e)}function a(e,t){return o(e,!1,!0).resolve(t)}function s(e,t){return e?o(e,!1,!0).resolveObject(t):t}var u=r(165),c=r(166);t.parse=o,t.resolve=a,t.resolveObject=s,t.format=i,t.Url=n;var f=/^([a-z0-9.+-]+:)/i,l=/:[0-9]*$/,h=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,p=["<",">",'"',"`"," ","\r","\n"," "],d=["{","}","|","\\","^","`"].concat(p),y=["'"].concat(d),v=["%","/","?",";","#"].concat(y),g=["/","?","#"],m=255,b=/^[+a-z0-9A-Z_-]{0,63}$/,w=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,_={javascript:!0,"javascript:":!0},k={javascript:!0,"javascript:":!0},A={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},O=r(167);n.prototype.parse=function(e,t,r){if(!c.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var n=e.indexOf("?"),o=-1!==n&&n<e.indexOf("#")?"?":"#",i=e.split(o),a=/\\/g;i[0]=i[0].replace(a,"/"),e=i.join(o);var s=e;if(s=s.trim(),!r&&1===e.split("#").length){var l=h.exec(s);if(l)return this.path=s,this.href=s,this.pathname=l[1],l[2]?(this.search=l[2],this.query=t?O.parse(this.search.substr(1)):this.search.substr(1)):t&&(this.search="",this.query={}),this}var p=f.exec(s);if(p){p=p[0];var d=p.toLowerCase();this.protocol=d,s=s.substr(p.length)}if(r||p||s.match(/^\/\/[^@\/]+@[^@\/]+/)){var E="//"===s.substr(0,2);!E||p&&k[p]||(s=s.substr(2),this.slashes=!0)}if(!k[p]&&(E||p&&!A[p])){for(var S=-1,x=0;x<g.length;x++){var C=s.indexOf(g[x]);-1!==C&&(-1===S||S>C)&&(S=C)}var P,T;T=-1===S?s.lastIndexOf("@"):s.lastIndexOf("@",S),-1!==T&&(P=s.slice(0,T),s=s.slice(T+1),this.auth=decodeURIComponent(P)),S=-1;for(var x=0;x<v.length;x++){var C=s.indexOf(v[x]);-1!==C&&(-1===S||S>C)&&(S=C)}-1===S&&(S=s.length),this.host=s.slice(0,S),s=s.slice(S),this.parseHost(),this.hostname=this.hostname||"";var j="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!j)for(var R=this.hostname.split(/\./),x=0,I=R.length;I>x;x++){var B=R[x];if(B&&!B.match(b)){for(var M="",N=0,U=B.length;U>N;N++)M+=B.charCodeAt(N)>127?"x":B[N];if(!M.match(b)){var L=R.slice(0,x),D=R.slice(x+1),q=B.match(w);q&&(L.push(q[1]),D.unshift(q[2])),D.length&&(s="/"+D.join(".")+s),this.hostname=L.join(".");break}}}this.hostname=this.hostname.length>m?"":this.hostname.toLowerCase(),j||(this.hostname=u.toASCII(this.hostname));var F=this.port?":"+this.port:"",z=this.hostname||"";this.host=z+F,this.href+=this.host,j&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==s[0]&&(s="/"+s))}if(!_[d])for(var x=0,I=y.length;I>x;x++){var H=y[x];if(-1!==s.indexOf(H)){var V=encodeURIComponent(H);V===H&&(V=escape(H)),s=s.split(H).join(V)}}var K=s.indexOf("#");-1!==K&&(this.hash=s.substr(K),s=s.slice(0,K));var X=s.indexOf("?");if(-1!==X?(this.search=s.substr(X),this.query=s.substr(X+1),t&&(this.query=O.parse(this.query)),s=s.slice(0,X)):t&&(this.search="",this.query={}),s&&(this.pathname=s),A[d]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var F=this.pathname||"",Q=this.search||"";this.path=F+Q}return this.href=this.format(),this},n.prototype.format=function(){var e=this.auth||"";e&&(e=encodeURIComponent(e),e=e.replace(/%3A/i,":"),e+="@");var t=this.protocol||"",r=this.pathname||"",n=this.hash||"",o=!1,i="";this.host?o=e+this.host:this.hostname&&(o=e+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(o+=":"+this.port)),this.query&&c.isObject(this.query)&&Object.keys(this.query).length&&(i=O.stringify(this.query));var a=this.search||i&&"?"+i||"";return t&&":"!==t.substr(-1)&&(t+=":"),this.slashes||(!t||A[t])&&o!==!1?(o="//"+(o||""),r&&"/"!==r.charAt(0)&&(r="/"+r)):o||(o=""),n&&"#"!==n.charAt(0)&&(n="#"+n),a&&"?"!==a.charAt(0)&&(a="?"+a),r=r.replace(/[?#]/g,function(e){return encodeURIComponent(e)}),a=a.replace("#","%23"),t+o+r+a+n},n.prototype.resolve=function(e){return this.resolveObject(o(e,!1,!0)).format()},n.prototype.resolveObject=function(e){if(c.isString(e)){var t=new n;t.parse(e,!1,!0),e=t}for(var r=new n,o=Object.keys(this),i=0;i<o.length;i++){var a=o[i];r[a]=this[a]}if(r.hash=e.hash,""===e.href)return r.href=r.format(),r;if(e.slashes&&!e.protocol){for(var s=Object.keys(e),u=0;u<s.length;u++){var f=s[u];"protocol"!==f&&(r[f]=e[f])}return A[r.protocol]&&r.hostname&&!r.pathname&&(r.path=r.pathname="/"),r.href=r.format(),r}if(e.protocol&&e.protocol!==r.protocol){if(!A[e.protocol]){for(var l=Object.keys(e),h=0;h<l.length;h++){var p=l[h];r[p]=e[p]}return r.href=r.format(),r}if(r.protocol=e.protocol,e.host||k[e.protocol])r.pathname=e.pathname;else{for(var d=(e.pathname||"").split("/");d.length&&!(e.host=d.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),""!==d[0]&&d.unshift(""),d.length<2&&d.unshift(""),r.pathname=d.join("/")}if(r.search=e.search,r.query=e.query,r.host=e.host||"",r.auth=e.auth,r.hostname=e.hostname||e.host,r.port=e.port,r.pathname||r.search){var y=r.pathname||"",v=r.search||"";r.path=y+v}return r.slashes=r.slashes||e.slashes,r.href=r.format(),r}var g=r.pathname&&"/"===r.pathname.charAt(0),m=e.host||e.pathname&&"/"===e.pathname.charAt(0),b=m||g||r.host&&e.pathname,w=b,_=r.pathname&&r.pathname.split("/")||[],d=e.pathname&&e.pathname.split("/")||[],O=r.protocol&&!A[r.protocol];if(O&&(r.hostname="",r.port=null,r.host&&(""===_[0]?_[0]=r.host:_.unshift(r.host)),r.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(""===d[0]?d[0]=e.host:d.unshift(e.host)),e.host=null),b=b&&(""===d[0]||""===_[0])),m)r.host=e.host||""===e.host?e.host:r.host,r.hostname=e.hostname||""===e.hostname?e.hostname:r.hostname,r.search=e.search,r.query=e.query,_=d;else if(d.length)_||(_=[]),_.pop(),_=_.concat(d),r.search=e.search,r.query=e.query;else if(!c.isNullOrUndefined(e.search)){if(O){r.hostname=r.host=_.shift();var E=r.host&&r.host.indexOf("@")>0?r.host.split("@"):!1;E&&(r.auth=E.shift(),r.host=r.hostname=E.shift())}return r.search=e.search,r.query=e.query,c.isNull(r.pathname)&&c.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!_.length)return r.pathname=null,r.path=r.search?"/"+r.search:null,r.href=r.format(),r;for(var S=_.slice(-1)[0],x=(r.host||e.host||_.length>1)&&("."===S||".."===S)||""===S,C=0,P=_.length;P>=0;P--)S=_[P],"."===S?_.splice(P,1):".."===S?(_.splice(P,1),C++):C&&(_.splice(P,1),C--);if(!b&&!w)for(;C--;C)_.unshift("..");!b||""===_[0]||_[0]&&"/"===_[0].charAt(0)||_.unshift(""),x&&"/"!==_.join("/").substr(-1)&&_.push("");var T=""===_[0]||_[0]&&"/"===_[0].charAt(0);if(O){r.hostname=r.host=T?"":_.length?_.shift():"";var E=r.host&&r.host.indexOf("@")>0?r.host.split("@"):!1;E&&(r.auth=E.shift(),r.host=r.hostname=E.shift())}return b=b||r.host&&_.length,b&&!T&&_.unshift(""),_.length?r.pathname=_.join("/"):(r.pathname=null,r.path=null),c.isNull(r.pathname)&&c.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},n.prototype.parseHost=function(){var e=this.host,t=l.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},function(e,t,r){var n;(function(e,o){!function(i){function a(e){throw RangeError(R[e])}function s(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function u(e,t){var r=e.split("@"),n="";r.length>1&&(n=r[0]+"@",e=r[1]),e=e.replace(j,".");var o=e.split("."),i=s(o,t).join(".");return n+i}function c(e){for(var t,r,n=[],o=0,i=e.length;i>o;)t=e.charCodeAt(o++),t>=55296&&56319>=t&&i>o?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function f(e){return s(e,function(e){var t="";return e>65535&&(e-=65536,t+=M(e>>>10&1023|55296),e=56320|1023&e),t+=M(e)}).join("")}function l(e){return 10>e-48?e-22:26>e-65?e-65:26>e-97?e-97:_}function h(e,t){return e+22+75*(26>e)-((0!=t)<<5)}function p(e,t,r){var n=0;for(e=r?B(e/E):e>>1,e+=B(e/t);e>I*A>>1;n+=_)e=B(e/I);return B(n+(I+1)*e/(e+O))}function d(e){var t,r,n,o,i,s,u,c,h,d,y=[],v=e.length,g=0,m=x,b=S;for(r=e.lastIndexOf(C),0>r&&(r=0),n=0;r>n;++n)e.charCodeAt(n)>=128&&a("not-basic"),y.push(e.charCodeAt(n));for(o=r>0?r+1:0;v>o;){for(i=g,s=1,u=_;o>=v&&a("invalid-input"),c=l(e.charCodeAt(o++)),(c>=_||c>B((w-g)/s))&&a("overflow"),g+=c*s,h=b>=u?k:u>=b+A?A:u-b,!(h>c);u+=_)d=_-h,s>B(w/d)&&a("overflow"),s*=d;t=y.length+1,b=p(g-i,t,0==i),B(g/t)>w-m&&a("overflow"),m+=B(g/t),g%=t,y.splice(g++,0,m)}return f(y)}function y(e){var t,r,n,o,i,s,u,f,l,d,y,v,g,m,b,O=[];for(e=c(e),v=e.length,t=x,r=0,i=S,s=0;v>s;++s)y=e[s],128>y&&O.push(M(y));for(n=o=O.length,o&&O.push(C);v>n;){for(u=w,s=0;v>s;++s)y=e[s],y>=t&&u>y&&(u=y);for(g=n+1,u-t>B((w-r)/g)&&a("overflow"),r+=(u-t)*g,t=u,s=0;v>s;++s)if(y=e[s],t>y&&++r>w&&a("overflow"),y==t){for(f=r,l=_;d=i>=l?k:l>=i+A?A:l-i,!(d>f);l+=_)b=f-d,m=_-d,O.push(M(h(d+b%m,0))),f=B(b/m);O.push(M(h(f,0))),i=p(r,g,n==o),r=0,++n}++r,++t}return O.join("")}function v(e){return u(e,function(e){return P.test(e)?d(e.slice(4).toLowerCase()):e})}function g(e){return u(e,function(e){return T.test(e)?"xn--"+y(e):e})}var m=("object"==typeof t&&t&&!t.nodeType&&t,"object"==typeof e&&e&&!e.nodeType&&e,"object"==typeof o&&o);(m.global===m||m.window===m||m.self===m)&&(i=m);var b,w=2147483647,_=36,k=1,A=26,O=38,E=700,S=72,x=128,C="-",P=/^xn--/,T=/[^\x20-\x7E]/,j=/[\x2E\u3002\uFF0E\uFF61]/g,R={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},I=_-k,B=Math.floor,M=String.fromCharCode;b={version:"1.3.2",ucs2:{decode:c,encode:f},decode:d,encode:y,toASCII:g,toUnicode:v},n=function(){return b}.call(t,r,t,e),!(void 0!==n&&(e.exports=n))}(this)}).call(t,r(64)(e),function(){return this}())},function(e){"use strict";e.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"==typeof e&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},function(e,t,r){"use strict";t.decode=t.parse=r(168),t.encode=t.stringify=r(169)},function(e){"use strict";function t(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,r,n,o){r=r||"&",n=n||"=";var i={};if("string"!=typeof e||0===e.length)return i;var a=/\+/g;e=e.split(r);var s=1e3;o&&"number"==typeof o.maxKeys&&(s=o.maxKeys);var u=e.length;s>0&&u>s&&(u=s);for(var c=0;u>c;++c){var f,l,h,p,d=e[c].replace(a,"%20"),y=d.indexOf(n);y>=0?(f=d.substr(0,y),l=d.substr(y+1)):(f=d,l=""),h=decodeURIComponent(f),p=decodeURIComponent(l),t(i,h)?Array.isArray(i[h])?i[h].push(p):i[h]=[i[h],p]:i[h]=p}return i}},function(e){"use strict";var t=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,r,n,o){return r=r||"&",n=n||"=",null===e&&(e=void 0),"object"==typeof e?Object.keys(e).map(function(o){var i=encodeURIComponent(t(o))+n;return Array.isArray(e[o])?e[o].map(function(e){return i+encodeURIComponent(t(e))}).join(r):i+encodeURIComponent(t(e[o]))}).join(r):o?encodeURIComponent(t(o))+n+encodeURIComponent(t(e)):""}},function(e){function t(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function r(e){return"function"==typeof e}function n(e){return"number"==typeof e}function o(e){return"object"==typeof e&&null!==e}function i(e){return void 0===e}e.exports=t,t.EventEmitter=t,t.prototype._events=void 0,t.prototype._maxListeners=void 0,t.defaultMaxListeners=10,t.prototype.setMaxListeners=function(e){if(!n(e)||0>e||isNaN(e))throw TypeError("n must be a positive number");return this._maxListeners=e,this},t.prototype.emit=function(e){var t,n,a,s,u,c;if(this._events||(this._events={}),"error"===e&&(!this._events.error||o(this._events.error)&&!this._events.error.length)){if(t=arguments[1],t instanceof Error)throw t;var f=new Error('Uncaught, unspecified "error" event. ('+t+")");throw f.context=t,f}if(n=this._events[e],i(n))return!1;if(r(n))switch(arguments.length){case 1:n.call(this);break;case 2:n.call(this,arguments[1]);break;case 3:n.call(this,arguments[1],arguments[2]);break;default:s=Array.prototype.slice.call(arguments,1),n.apply(this,s)}else if(o(n))for(s=Array.prototype.slice.call(arguments,1),c=n.slice(),a=c.length,u=0;a>u;u++)c[u].apply(this,s);return!0},t.prototype.addListener=function(e,n){var a;if(!r(n))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",e,r(n.listener)?n.listener:n),this._events[e]?o(this._events[e])?this._events[e].push(n):this._events[e]=[this._events[e],n]:this._events[e]=n,o(this._events[e])&&!this._events[e].warned&&(a=i(this._maxListeners)?t.defaultMaxListeners:this._maxListeners,a&&a>0&&this._events[e].length>a&&(this._events[e].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[e].length),"function"==typeof console.trace&&console.trace())),this},t.prototype.on=t.prototype.addListener,t.prototype.once=function(e,t){function n(){this.removeListener(e,n),o||(o=!0,t.apply(this,arguments))}if(!r(t))throw TypeError("listener must be a function");var o=!1;return n.listener=t,this.on(e,n),this},t.prototype.removeListener=function(e,t){var n,i,a,s;if(!r(t))throw TypeError("listener must be a function");if(!this._events||!this._events[e])return this;if(n=this._events[e],a=n.length,i=-1,n===t||r(n.listener)&&n.listener===t)delete this._events[e],this._events.removeListener&&this.emit("removeListener",e,t);else if(o(n)){for(s=a;s-->0;)if(n[s]===t||n[s].listener&&n[s].listener===t){i=s;break}if(0>i)return this;1===n.length?(n.length=0,delete this._events[e]):n.splice(i,1),this._events.removeListener&&this.emit("removeListener",e,t)}return this},t.prototype.removeAllListeners=function(e){var t,n;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[e]&&delete this._events[e],this;if(0===arguments.length){for(t in this._events)"removeListener"!==t&&this.removeAllListeners(t);return this.removeAllListeners("removeListener"),this._events={},this}if(n=this._events[e],r(n))this.removeListener(e,n);else if(n)for(;n.length;)this.removeListener(e,n[n.length-1]);return delete this._events[e],this},t.prototype.listeners=function(e){var t;return t=this._events&&this._events[e]?r(this._events[e])?[this._events[e]]:this._events[e].slice():[]},t.prototype.listenerCount=function(e){if(this._events){var t=this._events[e];if(r(t))return 1;if(t)return t.length}return 0},t.listenerCount=function(e,t){return e.listenerCount(t)}},function(e,t,r){var n=r(172),o=e.exports;for(var i in n)n.hasOwnProperty(i)&&(o[i]=n[i]);o.request=function(e,t){return e||(e={}),e.scheme="https",e.protocol="https:",n.request.call(this,e,t)}},function(e,t,r){(function(e){var n=r(173),o=r(176),i=r(197),a=r(198),s=r(164),u=t;u.request=function(t,r){t="string"==typeof t?s.parse(t):i(t);var o=-1===e.location.protocol.search(/^https?:$/)?"http:":"",a=t.protocol||o,u=t.hostname||t.host,c=t.port,f=t.path||"/";u&&-1!==u.indexOf(":")&&(u="["+u+"]"),t.url=(u?a+"//"+u:"")+(c?":"+c:"")+f,t.method=(t.method||"GET").toUpperCase(),t.headers=t.headers||{};var l=new n(t);return r&&l.on("response",r),l},u.get=function(e,t){var r=u.request(e,t);return r.end(),r},u.ClientRequest=n,u.IncomingMessage=o.IncomingMessage,u.Agent=function(){},u.Agent.defaultMaxSockets=4,u.globalAgent=new u.Agent,u.STATUS_CODES=a,u.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]}).call(t,function(){return this}())},function(e,t,r){(function(t,n,o){function i(e,t){return s.fetch&&t?"fetch":s.mozchunkedarraybuffer?"moz-chunked-arraybuffer":s.msstream?"ms-stream":s.arraybuffer&&e?"arraybuffer":s.vbArray&&e?"text:vbarray":"text"}function a(e){try{var t=e.status;return null!==t&&0!==t}catch(r){return!1}}var s=r(174),u=r(175),c=r(176),f=r(177),l=r(196),h=c.IncomingMessage,p=c.readyStates,d=e.exports=function(e){var r=this;f.Writable.call(r),r._opts=e,r._body=[],r._headers={},e.auth&&r.setHeader("Authorization","Basic "+new t(e.auth).toString("base64")),Object.keys(e.headers).forEach(function(t){r.setHeader(t,e.headers[t])});var n,o=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!s.abortController)o=!1,n=!0;else if("prefer-streaming"===e.mode)n=!1;else if("allow-wrong-content-type"===e.mode)n=!s.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");n=!0}r._mode=i(n,o),r._fetchTimer=null,r.on("finish",function(){r._onFinish()})};u(d,f.Writable),d.prototype.setHeader=function(e,t){var r=this,n=e.toLowerCase();-1===y.indexOf(n)&&(r._headers[n]={name:e,value:t})},d.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},d.prototype.removeHeader=function(e){var t=this;delete t._headers[e.toLowerCase()]},d.prototype._onFinish=function(){var e=this;if(!e._destroyed){var r=e._opts,i=e._headers,a=null;"GET"!==r.method&&"HEAD"!==r.method&&(a=s.arraybuffer?l(t.concat(e._body)):s.blobConstructor?new n.Blob(e._body.map(function(e){return l(e)}),{type:(i["content-type"]||{}).value||""}):t.concat(e._body).toString());var u=[];if(Object.keys(i).forEach(function(e){var t=i[e].name,r=i[e].value;Array.isArray(r)?r.forEach(function(e){u.push([t,e])}):u.push([t,r])}),"fetch"===e._mode){var c=null;if(s.abortController){var f=new AbortController;c=f.signal,e._fetchAbortController=f,"requestTimeout"in r&&0!==r.requestTimeout&&(e._fetchTimer=n.setTimeout(function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()},r.requestTimeout))}n.fetch(e._opts.url,{method:e._opts.method,headers:u,body:a||void 0,mode:"cors",credentials:r.withCredentials?"include":"same-origin",signal:c}).then(function(t){e._fetchResponse=t,e._connect()},function(t){n.clearTimeout(e._fetchTimer),e._destroyed||e.emit("error",t)})}else{var h=e._xhr=new n.XMLHttpRequest;try{h.open(e._opts.method,e._opts.url,!0)}catch(d){return o.nextTick(function(){e.emit("error",d)}),void 0}"responseType"in h&&(h.responseType=e._mode.split(":")[0]),"withCredentials"in h&&(h.withCredentials=!!r.withCredentials),"text"===e._mode&&"overrideMimeType"in h&&h.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in r&&(h.timeout=r.requestTimeout,h.ontimeout=function(){e.emit("requestTimeout")}),u.forEach(function(e){h.setRequestHeader(e[0],e[1])}),e._response=null,h.onreadystatechange=function(){switch(h.readyState){case p.LOADING:case p.DONE:e._onXHRProgress()}},"moz-chunked-arraybuffer"===e._mode&&(h.onprogress=function(){e._onXHRProgress()}),h.onerror=function(){e._destroyed||e.emit("error",new Error("XHR error"))};try{h.send(a)}catch(d){return o.nextTick(function(){e.emit("error",d)}),void 0}}}},d.prototype._onXHRProgress=function(){var e=this;a(e._xhr)&&!e._destroyed&&(e._response||e._connect(),e._response._onXHRProgress())},d.prototype._connect=function(){var e=this;e._destroyed||(e._response=new h(e._xhr,e._fetchResponse,e._mode,e._fetchTimer),e._response.on("error",function(t){e.emit("error",t)}),e.emit("response",e._response))},d.prototype._write=function(e,t,r){var n=this;n._body.push(e),r()},d.prototype.abort=d.prototype.destroy=function(){var e=this;e._destroyed=!0,n.clearTimeout(e._fetchTimer),e._response&&(e._response._destroyed=!0),e._xhr?e._xhr.abort():e._fetchAbortController&&e._fetchAbortController.abort()},d.prototype.end=function(e,t,r){var n=this;"function"==typeof e&&(r=e,e=void 0),f.Writable.prototype.end.call(n,e,t,r)},d.prototype.flushHeaders=function(){},d.prototype.setTimeout=function(){},d.prototype.setNoDelay=function(){},d.prototype.setSocketKeepAlive=function(){};var y=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]}).call(t,r(156).Buffer,function(){return this}(),r(136))},function(e,t){(function(e){function r(){if(void 0!==a)return a;if(e.XMLHttpRequest){a=new e.XMLHttpRequest;try{a.open("GET",e.XDomainRequest?"/":"https://example.com")}catch(t){a=null}}else a=null;return a}function n(e){var t=r();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(n){}return!1}function o(e){return"function"==typeof e}t.fetch=o(e.fetch)&&o(e.ReadableStream),t.writableStream=o(e.WritableStream),t.abortController=o(e.AbortController),t.blobConstructor=!1;try{new Blob([new ArrayBuffer(1)]),t.blobConstructor=!0}catch(i){}var a,s="undefined"!=typeof e.ArrayBuffer,u=s&&o(e.ArrayBuffer.prototype.slice);t.arraybuffer=t.fetch||s&&n("arraybuffer"),t.msstream=!t.fetch&&u&&n("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&s&&n("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||(r()?o(r().overrideMimeType):!1),t.vbArray=o(e.VBArray),a=null}).call(t,function(){return this}())},function(e){e.exports="function"==typeof Object.create?function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},function(e,t,r){(function(e,n,o){var i=r(174),a=r(175),s=r(177),u=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},c=t.IncomingMessage=function(t,r,a,u){function c(){p.read().then(function(e){if(!f._destroyed){if(e.done)return o.clearTimeout(u),f.push(null),void 0;f.push(new n(e.value)),c()}}).catch(function(e){o.clearTimeout(u),f._destroyed||f.emit("error",e)})}var f=this;if(s.Readable.call(f),f._mode=a,f.headers={},f.rawHeaders=[],f.trailers={},f.rawTrailers=[],f.on("end",function(){e.nextTick(function(){f.emit("close")})}),"fetch"===a){if(f._fetchResponse=r,f.url=r.url,f.statusCode=r.status,f.statusMessage=r.statusText,r.headers.forEach(function(e,t){f.headers[t.toLowerCase()]=e,f.rawHeaders.push(t,e)}),i.writableStream){var l=new WritableStream({write:function(e){return new Promise(function(t,r){f._destroyed?r():f.push(new n(e))?t():f._resumeFetch=t})},close:function(){o.clearTimeout(u),f._destroyed||f.push(null)},abort:function(e){f._destroyed||f.emit("error",e)}});try{return r.body.pipeTo(l).catch(function(e){o.clearTimeout(u),f._destroyed||f.emit("error",e)}),void 0}catch(h){}}var p=r.body.getReader();c()}else{f._xhr=t,f._pos=0,f.url=t.responseURL,f.statusCode=t.status,f.statusMessage=t.statusText;var d=t.getAllResponseHeaders().split(/\r?\n/);if(d.forEach(function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var r=t[1].toLowerCase();"set-cookie"===r?(void 0===f.headers[r]&&(f.headers[r]=[]),f.headers[r].push(t[2])):void 0!==f.headers[r]?f.headers[r]+=", "+t[2]:f.headers[r]=t[2],f.rawHeaders.push(t[1],t[2])}}),f._charset="x-user-defined",!i.overrideMimeType){var y=f.rawHeaders["mime-type"];if(y){var v=y.match(/;\s*charset=([^;])(;|$)/);v&&(f._charset=v[1].toLowerCase())}f._charset||(f._charset="utf-8")}}};a(c,s.Readable),c.prototype._read=function(){var e=this,t=e._resumeFetch;t&&(e._resumeFetch=null,t())},c.prototype._onXHRProgress=function(){var e=this,t=e._xhr,r=null;switch(e._mode){case"text:vbarray":if(t.readyState!==u.DONE)break;try{r=new o.VBArray(t.responseBody).toArray()}catch(i){}if(null!==r){e.push(new n(r));break}case"text":try{r=t.responseText}catch(i){e._mode="text:vbarray";break}if(r.length>e._pos){var a=r.substr(e._pos);if("x-user-defined"===e._charset){for(var s=new n(a.length),c=0;c<a.length;c++)s[c]=255&a.charCodeAt(c);e.push(s)}else e.push(a,e._charset);e._pos=r.length}break;case"arraybuffer":if(t.readyState!==u.DONE||!t.response)break;r=t.response,e.push(new n(new Uint8Array(r)));break;case"moz-chunked-arraybuffer":if(r=t.response,t.readyState!==u.LOADING||!r)break;e.push(new n(new Uint8Array(r)));break;case"ms-stream":if(r=t.response,t.readyState!==u.LOADING)break;var f=new o.MSStreamReader;f.onprogress=function(){f.result.byteLength>e._pos&&(e.push(new n(new Uint8Array(f.result.slice(e._pos)))),e._pos=f.result.byteLength)},f.onload=function(){e.push(null)},f.readAsArrayBuffer(r)}e._xhr.readyState===u.DONE&&"ms-stream"!==e._mode&&e.push(null)}}).call(t,r(136),r(156).Buffer,function(){return this}())},function(e,t,r){t=e.exports=r(178),t.Stream=t,t.Readable=t,t.Writable=r(188),t.Duplex=r(187),t.Transform=r(194),t.PassThrough=r(195)},function(e,t,r){(function(t,n){"use strict";function o(e){return U.from(e)}function i(e){return U.isBuffer(e)||e instanceof L}function a(e,t,r){return"function"==typeof e.prependListener?e.prependListener(t,r):(e._events&&e._events[t]?B(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r),void 0)}function s(e,t){I=I||r(187),e=e||{};var n=t instanceof I;this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var o=e.highWaterMark,i=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=o||0===o?o:n&&(i||0===i)?i:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new H,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.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(z||(z=r(192).StringDecoder),this.decoder=new z(e.encoding),this.encoding=e.encoding)}function u(e){return I=I||r(187),this instanceof u?(this._readableState=new s(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),N.call(this),void 0):new u(e)}function c(e,t,r,n,i){var a=e._readableState;if(null===t)a.reading=!1,y(e,a);else{var s;i||(s=l(a,t)),s?e.emit("error",s):a.objectMode||t&&t.length>0?("string"==typeof t||a.objectMode||Object.getPrototypeOf(t)===U.prototype||(t=o(t)),n?a.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):f(e,a,t,!0):a.ended?e.emit("error",new Error("stream.push() after EOF")):(a.reading=!1,a.decoder&&!r?(t=a.decoder.write(t),a.objectMode||0!==t.length?f(e,a,t,!1):m(e,a)):f(e,a,t,!1))):n||(a.reading=!1)}return h(a)}function f(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&v(e)),m(e,t)}function l(e,t){var r;return i(t)||"string"==typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk")),r}function h(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}function p(e){return e>=X?e=X:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function d(e,t){return 0>=e||0===t.length&&t.ended?0:t.objectMode?1:e!==e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=p(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function y(e,t){if(!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,v(e)}}function v(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(F("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?R.nextTick(g,e):g(e))}function g(e){F("emit readable"),e.emit("readable"),O(e)}function m(e,t){t.readingMore||(t.readingMore=!0,R.nextTick(b,e,t))}function b(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(F("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function w(e){return function(){var t=e._readableState;F("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&M(e,"data")&&(t.flowing=!0,O(e))}}function _(e){F("readable nexttick read 0"),e.read(0)}function k(e,t){t.resumeScheduled||(t.resumeScheduled=!0,R.nextTick(A,e,t))}function A(e,t){t.reading||(F("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),O(e),t.flowing&&!t.reading&&e.read(0)}function O(e){var t=e._readableState;for(F("flow",t.flowing);t.flowing&&null!==e.read(););}function E(e,t){if(0===t.length)return null;var r;return t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=S(e,t.buffer,t.decoder),r}function S(e,t,r){var n;return e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):n=e===t.head.data.length?t.shift():r?x(e,t):C(e,t),n}function x(e,t){var r=t.head,n=1,o=r.data;for(e-=o.length;r=r.next;){var i=r.data,a=e>i.length?i.length:e;if(o+=a===i.length?i:i.slice(0,e),e-=a,0===e){a===i.length?(++n,t.head=r.next?r.next:t.tail=null):(t.head=r,r.data=i.slice(a));break}++n}return t.length-=n,o}function C(e,t){var r=U.allocUnsafe(e),n=t.head,o=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var i=n.data,a=e>i.length?i.length:e;if(i.copy(r,r.length-e,0,a),e-=a,0===e){a===i.length?(++o,t.head=n.next?n.next:t.tail=null):(t.head=n,n.data=i.slice(a));break}++o}return t.length-=o,r}function P(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,R.nextTick(T,t,e))}function T(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function j(e,t){for(var r=0,n=e.length;n>r;r++)if(e[r]===t)return r;return-1}var R=r(179);e.exports=u;var I,B=r(159);u.ReadableState=s;var M=(r(170).EventEmitter,function(e,t){return e.listeners(t).length}),N=r(180),U=r(181).Buffer,L=t.Uint8Array||function(){},D=Object.create(r(182));D.inherits=r(175);var q=r(183),F=void 0;F=q&&q.debuglog?q.debuglog("stream"):function(){};var z,H=r(184),V=r(186);D.inherits(u,N);var K=["error","close","destroy","pause","resume"];Object.defineProperty(u.prototype,"destroyed",{get:function(){return void 0===this._readableState?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),u.prototype.destroy=V.destroy,u.prototype._undestroy=V.undestroy,u.prototype._destroy=function(e,t){this.push(null),t(e)},u.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=U.from(e,t),t=""),r=!0),c(this,e,t,!1,r)},u.prototype.unshift=function(e){return c(this,e,null,!0,!1)},u.prototype.isPaused=function(){return this._readableState.flowing===!1
},u.prototype.setEncoding=function(e){return z||(z=r(192).StringDecoder),this._readableState.decoder=new z(e),this._readableState.encoding=e,this};var X=8388608;u.prototype.read=function(e){F("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return F("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?P(this):v(this),null;if(e=d(e,t),0===e&&t.ended)return 0===t.length&&P(this),null;var n=t.needReadable;F("need readable",n),(0===t.length||t.length-e<t.highWaterMark)&&(n=!0,F("length less than watermark",n)),t.ended||t.reading?(n=!1,F("reading or ended",n)):n&&(F("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=d(r,t)));var o;return o=e>0?E(e,t):null,null===o?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&P(this)),null!==o&&this.emit("data",o),o},u.prototype._read=function(){this.emit("error",new Error("_read() is not implemented"))},u.prototype.pipe=function(e,t){function r(e,t){F("onunpipe"),e===h&&t&&t.hasUnpiped===!1&&(t.hasUnpiped=!0,i())}function o(){F("onend"),e.end()}function i(){F("cleanup"),e.removeListener("close",c),e.removeListener("finish",f),e.removeListener("drain",v),e.removeListener("error",u),e.removeListener("unpipe",r),h.removeListener("end",o),h.removeListener("end",l),h.removeListener("data",s),g=!0,!p.awaitDrain||e._writableState&&!e._writableState.needDrain||v()}function s(t){F("ondata"),m=!1;var r=e.write(t);!1!==r||m||((1===p.pipesCount&&p.pipes===e||p.pipesCount>1&&-1!==j(p.pipes,e))&&!g&&(F("false write response, pause",h._readableState.awaitDrain),h._readableState.awaitDrain++,m=!0),h.pause())}function u(t){F("onerror",t),l(),e.removeListener("error",u),0===M(e,"error")&&e.emit("error",t)}function c(){e.removeListener("finish",f),l()}function f(){F("onfinish"),e.removeListener("close",c),l()}function l(){F("unpipe"),h.unpipe(e)}var h=this,p=this._readableState;switch(p.pipesCount){case 0:p.pipes=e;break;case 1:p.pipes=[p.pipes,e];break;default:p.pipes.push(e)}p.pipesCount+=1,F("pipe count=%d opts=%j",p.pipesCount,t);var d=(!t||t.end!==!1)&&e!==n.stdout&&e!==n.stderr,y=d?o:l;p.endEmitted?R.nextTick(y):h.once("end",y),e.on("unpipe",r);var v=w(h);e.on("drain",v);var g=!1,m=!1;return h.on("data",s),a(e,"error",u),e.once("close",c),e.once("finish",f),e.emit("pipe",h),p.flowing||(F("pipe resume"),h.resume()),e},u.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,o=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;o>i;i++)n[i].emit("unpipe",this,r);return this}var a=j(t.pipes,e);return-1===a?this:(t.pipes.splice(a,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)},u.prototype.on=function(e,t){var r=N.prototype.on.call(this,e,t);if("data"===e)this._readableState.flowing!==!1&&this.resume();else if("readable"===e){var n=this._readableState;n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&v(this):R.nextTick(_,this))}return r},u.prototype.addListener=u.prototype.on,u.prototype.resume=function(){var e=this._readableState;return e.flowing||(F("resume"),e.flowing=!0,k(this,e)),this},u.prototype.pause=function(){return F("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(F("pause"),this._readableState.flowing=!1,this.emit("pause")),this},u.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;e.on("end",function(){if(F("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(o){if(F("wrapped data"),r.decoder&&(o=r.decoder.write(o)),(!r.objectMode||null!==o&&void 0!==o)&&(r.objectMode||o&&o.length)){var i=t.push(o);i||(n=!0,e.pause())}});for(var o in e)void 0===this[o]&&"function"==typeof e[o]&&(this[o]=function(t){return function(){return e[t].apply(e,arguments)}}(o));for(var i=0;i<K.length;i++)e.on(K[i],this.emit.bind(this,K[i]));return this._read=function(t){F("wrapped _read",t),n&&(n=!1,e.resume())},this},Object.defineProperty(u.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),u._fromList=E}).call(t,function(){return this}(),r(136))},function(e,t,r){(function(t){"use strict";function r(e,r,n,o){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var i,a,s=arguments.length;switch(s){case 0:case 1:return t.nextTick(e);case 2:return t.nextTick(function(){e.call(null,r)});case 3:return t.nextTick(function(){e.call(null,r,n)});case 4:return t.nextTick(function(){e.call(null,r,n,o)});default:for(i=new Array(s-1),a=0;a<i.length;)i[a++]=arguments[a];return t.nextTick(function(){e.apply(null,i)})}}e.exports="undefined"==typeof t||!t.version||0===t.version.indexOf("v0.")||0===t.version.indexOf("v1.")&&0!==t.version.indexOf("v1.8.")?{nextTick:r}:t}).call(t,r(136))},function(e,t,r){e.exports=r(170).EventEmitter},function(e,t,r){function n(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return a(e,t,r)}var i=r(156),a=i.Buffer;a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=i:(n(i,t),t.Buffer=o),n(a,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return a(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=a(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return a(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i.SlowBuffer(e)}},function(e,t,r){(function(e){function r(e){return Array.isArray?Array.isArray(e):"[object Array]"===v(e)}function n(e){return"boolean"==typeof e}function o(e){return null===e}function i(e){return null==e}function a(e){return"number"==typeof e}function s(e){return"string"==typeof e}function u(e){return"symbol"==typeof e}function c(e){return void 0===e}function f(e){return"[object RegExp]"===v(e)}function l(e){return"object"==typeof e&&null!==e}function h(e){return"[object Date]"===v(e)}function p(e){return"[object Error]"===v(e)||e instanceof Error}function d(e){return"function"==typeof e}function y(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||"undefined"==typeof e}function v(e){return Object.prototype.toString.call(e)}t.isArray=r,t.isBoolean=n,t.isNull=o,t.isNullOrUndefined=i,t.isNumber=a,t.isString=s,t.isSymbol=u,t.isUndefined=c,t.isRegExp=f,t.isObject=l,t.isDate=h,t.isError=p,t.isFunction=d,t.isPrimitive=y,t.isBuffer=e.isBuffer}).call(t,r(156).Buffer)},function(){},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t,r){e.copy(t,r)}var i=r(181).Buffer,a=r(185);e.exports=function(){function e(){n(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return this.head=1===this.length?this.tail=null:this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},e.prototype.concat=function(e){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var t=i.allocUnsafe(e>>>0),r=this.head,n=0;r;)o(r.data,t,n),n+=r.data.length,r=r.next;return t},e}(),a&&a.inspect&&a.inspect.custom&&(e.exports.prototype[a.inspect.custom]=function(){var e=a.inspect({length:this.length});return this.constructor.name+" "+e})},function(){},function(e,t,r){"use strict";function n(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return n||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||a.nextTick(i,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(a.nextTick(i,r,e),r._writableState&&(r._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){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.finished=!1,this._writableState.errorEmitted=!1)}function i(e,t){e.emit("error",t)}var a=r(179);e.exports={destroy:n,undestroy:o}},function(e,t,r){"use strict";function n(e){return this instanceof n?(c.call(this,e),f.call(this,e),e&&e.readable===!1&&(this.readable=!1),e&&e.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,e&&e.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",o),void 0):new n(e)}function o(){this.allowHalfOpen||this._writableState.ended||a.nextTick(i,this)}function i(e){e.end()}var a=r(179),s=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=n;var u=Object.create(r(182));u.inherits=r(175);var c=r(178),f=r(188);u.inherits(n,c);for(var l=s(f.prototype),h=0;h<l.length;h++){var p=l[h];n.prototype[p]||(n.prototype[p]=f.prototype[p])}Object.defineProperty(n.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(n.prototype,"destroyed",{get:function(){return void 0===this._readableState||void 0===this._writableState?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),n.prototype._destroy=function(e,t){this.push(null),this.end(),a.nextTick(t,e)}},function(e,t,r){(function(t,n,o){"use strict";function i(e){var t=this;this.next=null,this.entry=null,this.finish=function(){x(t,e)}}function a(e){return B.from(e)}function s(e){return B.isBuffer(e)||e instanceof M}function u(){}function c(e,t){P=P||r(187),e=e||{};var n=t instanceof P;this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var o=e.highWaterMark,a=e.writableHighWaterMark,s=this.objectMode?16:16384;this.highWaterMark=o||0===o?o:n&&(a||0===a)?a:s,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=e.decodeStrings===!1;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){m(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new i(this)}function f(e){return P=P||r(187),U.call(f,this)||this instanceof P?(this._writableState=new c(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),I.call(this),void 0):new f(e)}function l(e,t){var r=new Error("write after end");e.emit("error",r),C.nextTick(t,r)}function h(e,t,r,n){var o=!0,i=!1;return null===r?i=new TypeError("May not write null values to stream"):"string"==typeof r||void 0===r||t.objectMode||(i=new TypeError("Invalid non-string/buffer chunk")),i&&(e.emit("error",i),C.nextTick(n,i),o=!1),o}function p(e,t,r){return e.objectMode||e.decodeStrings===!1||"string"!=typeof t||(t=B.from(t,r)),t}function d(e,t,r,n,o,i){if(!r){var a=p(t,n,o);n!==a&&(r=!0,o="buffer",n=a)}var s=t.objectMode?1:n.length;t.length+=s;var u=t.length<t.highWaterMark;if(u||(t.needDrain=!0),t.writing||t.corked){var c=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:o,isBuf:r,callback:i,next:null},c?c.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else y(e,t,!1,s,n,o,i);return u}function y(e,t,r,n,o,i,a){t.writelen=n,t.writecb=a,t.writing=!0,t.sync=!0,r?e._writev(o,t.onwrite):e._write(o,i,t.onwrite),t.sync=!1}function v(e,t,r,n,o){--t.pendingcb,r?(C.nextTick(o,n),C.nextTick(E,e,t),e._writableState.errorEmitted=!0,e.emit("error",n)):(o(n),e._writableState.errorEmitted=!0,e.emit("error",n),E(e,t))}function g(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function m(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if(g(r),t)v(e,r,n,t,o);else{var i=k(r);i||r.corked||r.bufferProcessing||!r.bufferedRequest||_(e,r),n?T(b,e,r,i,o):b(e,r,i,o)}}function b(e,t,r,n){r||w(e,t),t.pendingcb--,n(),E(e,t)}function w(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function _(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,o=new Array(n),a=t.corkedRequestsFree;a.entry=r;for(var s=0,u=!0;r;)o[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;o.allBuffers=u,y(e,t,!0,t.length,o,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new i(t),t.bufferedRequestCount=0}else{for(;r;){var c=r.chunk,f=r.encoding,l=r.callback,h=t.objectMode?1:c.length;if(y(e,t,!1,h,c,f,l),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function k(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function A(e,t){e._final(function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),E(e,t)})}function O(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,C.nextTick(A,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function E(e,t){var r=k(t);return r&&(O(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),r}function S(e,t,r){t.ending=!0,E(e,t),r&&(t.finished?C.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}function x(e,t,r){var n=e.entry;for(e.entry=null;n;){var o=n.callback;t.pendingcb--,o(r),n=n.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}var C=r(179);e.exports=f;var P,T=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?n:C.nextTick;f.WritableState=c;var j=Object.create(r(182));j.inherits=r(175);var R={deprecate:r(191)},I=r(180),B=r(181).Buffer,M=o.Uint8Array||function(){},N=r(186);j.inherits(f,I),c.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(c.prototype,"buffer",{get:R.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}();var U;"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(U=Function.prototype[Symbol.hasInstance],Object.defineProperty(f,Symbol.hasInstance,{value:function(e){return U.call(this,e)?!0:this!==f?!1:e&&e._writableState instanceof c}})):U=function(e){return e instanceof this},f.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},f.prototype.write=function(e,t,r){var n=this._writableState,o=!1,i=!n.objectMode&&s(e);return i&&!B.isBuffer(e)&&(e=a(e)),"function"==typeof t&&(r=t,t=null),i?t="buffer":t||(t=n.defaultEncoding),"function"!=typeof r&&(r=u),n.ended?l(this,r):(i||h(this,n,e,r))&&(n.pendingcb++,o=d(this,n,i,e,t,r)),o},f.prototype.cork=function(){var e=this._writableState;e.corked++},f.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||_(this,e))},f.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(f.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),f.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},f.prototype._writev=null,f.prototype.end=function(e,t,r){var n=this._writableState;"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!==e&&void 0!==e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||n.finished||S(this,n,r)},Object.defineProperty(f.prototype,"destroyed",{get:function(){return void 0===this._writableState?!1:this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),f.prototype.destroy=N.destroy,f.prototype._undestroy=N.undestroy,f.prototype._destroy=function(e,t){this.end(),t(e)}}).call(t,r(136),r(189).setImmediate,function(){return this}())},function(e,t,r){(function(e){function n(e,t){this._id=e,this._clearFn=t}var o="undefined"!=typeof e&&e||"undefined"!=typeof self&&self||window,i=Function.prototype.apply;t.setTimeout=function(){return new n(i.call(setTimeout,o,arguments),clearTimeout)},t.setInterval=function(){return new n(i.call(setInterval,o,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e&&e.close()},n.prototype.unref=n.prototype.ref=function(){},n.prototype.close=function(){this._clearFn.call(o,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},r(190),t.setImmediate="undefined"!=typeof self&&self.setImmediate||"undefined"!=typeof e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||"undefined"!=typeof e&&e.clearImmediate||this&&this.clearImmediate}).call(t,function(){return this}())},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return y[d]=n,p(d),d++}function o(e){delete y[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(v)setTimeout(a,0,e);else{var t=y[e];if(t){v=!0;try{i(t)}finally{o(e),v=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function u(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function f(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function l(){var e=g.documentElement;p=function(t){var r=g.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function h(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,d=1,y={},v=!1,g=e.document,m=Object.getPrototypeOf&&Object.getPrototypeOf(e);m=m&&m.setTimeout?m:e,"[object process]"==={}.toString.call(e.process)?s():u()?c():e.MessageChannel?f():g&&"onreadystatechange"in g.createElement("script")?l():h(),m.setImmediate=n,m.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,function(){return this}(),r(136))},function(e,t){(function(t){function r(e,t){function r(){if(!o){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),o=!0}return e.apply(this,arguments)}if(n("noDeprecation"))return e;var o=!1;return r}function n(e){try{if(!t.localStorage)return!1}catch(r){return!1}var n=t.localStorage[e];return null==n?!1:"true"===String(n).toLowerCase()}e.exports=r}).call(t,function(){return this}())},function(e,t,r){"use strict";function n(e){if(!e)return"utf8";for(var t;;)switch(e){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 e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function o(e){var t=n(e);if("string"!=typeof t&&(m.isEncoding===b||!b(e)))throw new Error("Unknown encoding: "+e);return t||e}function i(e){this.encoding=o(e);var t;switch(this.encoding){case"utf16le":this.text=h,this.end=p,t=4;break;case"utf8":this.fillLast=c,t=4;break;case"base64":this.text=d,this.end=y,t=3;break;default:return this.write=v,this.end=g,void 0}this.lastNeed=0,this.lastTotal=0,this.lastChar=m.allocUnsafe(t)}function a(e){return 127>=e?0:e>>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function s(e,t,r){var n=t.length-1;if(r>n)return 0;var o=a(t[n]);return o>=0?(o>0&&(e.lastNeed=o-1),o):--n<r||-2===o?0:(o=a(t[n]),o>=0?(o>0&&(e.lastNeed=o-2),o):--n<r||-2===o?0:(o=a(t[n]),o>=0?(o>0&&(2===o?o=0:e.lastNeed=o-3),o):0))}function u(e,t){if(128!==(192&t[0]))return e.lastNeed=0,"\ufffd";if(e.lastNeed>1&&t.length>1){if(128!==(192&t[1]))return e.lastNeed=1,"\ufffd";if(e.lastNeed>2&&t.length>2&&128!==(192&t[2]))return e.lastNeed=2,"\ufffd"}}function c(e){var t=this.lastTotal-this.lastNeed,r=u(this,e,t);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length,void 0)}function f(e,t){var r=s(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function l(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"\ufffd":t}function h(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&56319>=n)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function p(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function d(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function y(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function v(e){return e.toString(this.encoding)}function g(e){return e&&e.length?this.write(e):""}var m=r(193).Buffer,b=m.isEncoding||function(e){switch(e=""+e,e&&e.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}};t.StringDecoder=i,i.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(t=this.fillLast(e),void 0===t)return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},i.prototype.end=l,i.prototype.text=f,i.prototype.fillLast=function(e){return this.lastNeed<=e.length?(e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length,void 0)}},function(e,t,r){function n(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return a(e,t,r)}var i=r(156),a=i.Buffer;a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=i:(n(i,t),t.Buffer=o),n(a,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return a(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=a(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return a(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i.SlowBuffer(e)}},function(e,t,r){"use strict";function n(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var o=this._readableState;o.reading=!1,(o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}function o(e){return this instanceof o?(s.call(this,e),this._transformState={afterTransform:n.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",i),void 0):new o(e)}function i(){var e=this;"function"==typeof this._flush?this._flush(function(t,r){a(e,t,r)}):a(this,null,null)}function a(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}e.exports=o;var s=r(187),u=Object.create(r(182));u.inherits=r(175),u.inherits(o,s),o.prototype.push=function(e,t){return this._transformState.needTransform=!1,s.prototype.push.call(this,e,t)},o.prototype._transform=function(){throw new Error("_transform() is not implemented")},o.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var o=this._readableState;(n.needTransform||o.needReadable||o.length<o.highWaterMark)&&this._read(o.highWaterMark)}},o.prototype._read=function(){var e=this._transformState;null!==e.writechunk&&e.writecb&&!e.transforming?(e.transforming=!0,this._transform(e.writechunk,e.writeencoding,e.afterTransform)):e.needTransform=!0},o.prototype._destroy=function(e,t){var r=this;s.prototype._destroy.call(this,e,function(e){t(e),r.emit("close")})}},function(e,t,r){"use strict";function n(e){return this instanceof n?(o.call(this,e),void 0):new n(e)}e.exports=n;var o=r(194),i=Object.create(r(182));i.inherits=r(175),i.inherits(n,o),n.prototype._transform=function(e,t,r){r(null,e)}},function(e,t,r){var n=r(156).Buffer;e.exports=function(e){if(e instanceof Uint8Array){if(0===e.byteOffset&&e.byteLength===e.buffer.byteLength)return e.buffer;if("function"==typeof e.buffer.slice)return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)}if(n.isBuffer(e)){for(var t=new Uint8Array(e.length),r=e.length,o=0;r>o;o++)t[o]=e[o];return t.buffer}throw new Error("Argument must be a Buffer")}},function(e){function t(){for(var e={},t=0;t<arguments.length;t++){var n=arguments[t];for(var o in n)r.call(n,o)&&(e[o]=n[o])}return e}e.exports=t;var r=Object.prototype.hasOwnProperty},function(e){e.exports={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}},function(e,t,r){(function(e,n){function o(e,r){var n={seen:[],stylize:a};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),y(r)?n.showHidden=r:r&&t._extend(n,r),_(n.showHidden)&&(n.showHidden=!1),_(n.depth)&&(n.depth=2),_(n.colors)&&(n.colors=!1),_(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=i),u(n,e,n.depth)}function i(e,t){var r=o.styles[t];return r?"["+o.colors[r][0]+"m"+e+"["+o.colors[r][1]+"m":e}function a(e){return e}function s(e){var t={};return e.forEach(function(e){t[e]=!0}),t}function u(e,r,n){if(e.customInspect&&r&&S(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var o=r.inspect(n,e);return b(o)||(o=u(e,o,n)),o}var i=c(e,r);if(i)return i;var a=Object.keys(r),y=s(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),E(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return f(r);if(0===a.length){if(S(r)){var v=r.name?": "+r.name:"";return e.stylize("[Function"+v+"]","special")}if(k(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(O(r))return e.stylize(Date.prototype.toString.call(r),"date");if(E(r))return f(r)}var g="",m=!1,w=["{","}"];if(d(r)&&(m=!0,w=["[","]"]),S(r)){var _=r.name?": "+r.name:"";g=" [Function"+_+"]"}if(k(r)&&(g=" "+RegExp.prototype.toString.call(r)),O(r)&&(g=" "+Date.prototype.toUTCString.call(r)),E(r)&&(g=" "+f(r)),0===a.length&&(!m||0==r.length))return w[0]+g+w[1];if(0>n)return k(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special");e.seen.push(r);var A;return A=m?l(e,r,n,y,a):a.map(function(t){return h(e,r,n,y,t,m)}),e.seen.pop(),p(A,g,w)}function c(e,t){if(_(t))return e.stylize("undefined","undefined");if(b(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return m(t)?e.stylize(""+t,"number"):y(t)?e.stylize(""+t,"boolean"):v(t)?e.stylize("null","null"):void 0}function f(e){return"["+Error.prototype.toString.call(e)+"]"}function l(e,t,r,n,o){for(var i=[],a=0,s=t.length;s>a;++a)j(t,String(a))?i.push(h(e,t,r,n,String(a),!0)):i.push("");return o.forEach(function(o){o.match(/^\d+$/)||i.push(h(e,t,r,n,o,!0))}),i}function h(e,t,r,n,o,i){var a,s,c;if(c=Object.getOwnPropertyDescriptor(t,o)||{value:t[o]},c.get?s=c.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):c.set&&(s=e.stylize("[Setter]","special")),j(n,o)||(a="["+o+"]"),s||(e.seen.indexOf(c.value)<0?(s=v(r)?u(e,c.value,null):u(e,c.value,r-1),s.indexOf("\n")>-1&&(s=i?s.split("\n").map(function(e){return" "+e
}).join("\n").substr(2):"\n"+s.split("\n").map(function(e){return" "+e}).join("\n"))):s=e.stylize("[Circular]","special")),_(a)){if(i&&o.match(/^\d+$/))return s;a=JSON.stringify(""+o),a.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=e.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=e.stylize(a,"string"))}return a+": "+s}function p(e,t,r){var n=0,o=e.reduce(function(e,t){return n++,t.indexOf("\n")>=0&&n++,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0);return o>60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}function d(e){return Array.isArray(e)}function y(e){return"boolean"==typeof e}function v(e){return null===e}function g(e){return null==e}function m(e){return"number"==typeof e}function b(e){return"string"==typeof e}function w(e){return"symbol"==typeof e}function _(e){return void 0===e}function k(e){return A(e)&&"[object RegExp]"===C(e)}function A(e){return"object"==typeof e&&null!==e}function O(e){return A(e)&&"[object Date]"===C(e)}function E(e){return A(e)&&("[object Error]"===C(e)||e instanceof Error)}function S(e){return"function"==typeof e}function x(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||"undefined"==typeof e}function C(e){return Object.prototype.toString.call(e)}function P(e){return 10>e?"0"+e.toString(10):e.toString(10)}function T(){var e=new Date,t=[P(e.getHours()),P(e.getMinutes()),P(e.getSeconds())].join(":");return[e.getDate(),M[e.getMonth()],t].join(" ")}function j(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var R=/%[sdj%]/g;t.format=function(e){if(!b(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(o(arguments[r]));return t.join(" ")}for(var r=1,n=arguments,i=n.length,a=String(e).replace(R,function(e){if("%%"===e)return"%";if(r>=i)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(t){return"[Circular]"}default:return e}}),s=n[r];i>r;s=n[++r])a+=v(s)||!A(s)?" "+s:" "+o(s);return a},t.deprecate=function(r,o){function i(){if(!a){if(n.throwDeprecation)throw new Error(o);n.traceDeprecation?console.trace(o):console.error(o),a=!0}return r.apply(this,arguments)}if(_(e.process))return function(){return t.deprecate(r,o).apply(this,arguments)};if(n.noDeprecation===!0)return r;var a=!1;return i};var I,B={};t.debuglog=function(e){if(_(I)&&(I=n.env.NODE_DEBUG||""),e=e.toUpperCase(),!B[e])if(new RegExp("\\b"+e+"\\b","i").test(I)){var r=n.pid;B[e]=function(){var n=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,n)}}else B[e]=function(){};return B[e]},t.inspect=o,o.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},o.styles={special:"cyan",number:"yellow","boolean":"yellow",undefined:"grey","null":"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=d,t.isBoolean=y,t.isNull=v,t.isNullOrUndefined=g,t.isNumber=m,t.isString=b,t.isSymbol=w,t.isUndefined=_,t.isRegExp=k,t.isObject=A,t.isDate=O,t.isError=E,t.isFunction=S,t.isPrimitive=x,t.isBuffer=r(200);var M=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];t.log=function(){console.log("%s - %s",T(),t.format.apply(t,arguments))},t.inherits=r(201),t._extend=function(e,t){if(!t||!A(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}}).call(t,function(){return this}(),r(136))},function(e){e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},function(e){e.exports="function"==typeof Object.create?function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.AccountResponse=void 0;{var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(203),s=r(430),u=n(s);t.AccountResponse=function(){function e(t){var r=this;o(this,e),this._baseAccount=new a.Account(t.account_id,t.sequence),u.default(t,function(e,t){r[t]=e})}return i(e,[{key:"accountId",value:function(){return this._baseAccount.accountId()}},{key:"sequenceNumber",value:function(){return this._baseAccount.sequenceNumber()}},{key:"incrementSequenceNumber",value:function(){this._baseAccount.incrementSequenceNumber(),this.sequence=this._baseAccount.sequenceNumber()}}]),e}()}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Failed=t.Success=t.ResultCode=t.getBalanceAsset=t.getBalance=t.getState=t.getLedgerSeq=t.Decode=t.Encode=t.ReturnData=t.exec=t.OutputFormat=t.IContract=t.State=t.Storage=t.StrKey=t.Networks=t.Network=t.Account=t.ContrOperation=t.AuthImmutableFlag=t.AuthRevocableFlag=t.AuthRequiredFlag=t.Operation=t.ContractInput=t.Asset=t.TransactionBuilder=t.Transaction=t.Hyper=t.UnsignedHyper=t.Keypair=t.FastSigning=t.verify=t.sign=t.hash=t.xdr=void 0;var o=r(204);Object.defineProperty(t,"hash",{enumerable:!0,get:function(){return o.hash}});var i=r(214);Object.defineProperty(t,"sign",{enumerable:!0,get:function(){return i.sign}}),Object.defineProperty(t,"verify",{enumerable:!0,get:function(){return i.verify}}),Object.defineProperty(t,"FastSigning",{enumerable:!0,get:function(){return i.FastSigning}});var a=r(217);Object.defineProperty(t,"Keypair",{enumerable:!0,get:function(){return a.Keypair}});var s=r(242);Object.defineProperty(t,"UnsignedHyper",{enumerable:!0,get:function(){return s.UnsignedHyper}}),Object.defineProperty(t,"Hyper",{enumerable:!0,get:function(){return s.Hyper}});var u=r(333);Object.defineProperty(t,"Transaction",{enumerable:!0,get:function(){return u.Transaction}});var c=r(421);Object.defineProperty(t,"TransactionBuilder",{enumerable:!0,get:function(){return c.TransactionBuilder}});var f=r(335);Object.defineProperty(t,"Asset",{enumerable:!0,get:function(){return f.Asset}});var l=r(354);Object.defineProperty(t,"ContractInput",{enumerable:!0,get:function(){return l.ContractInput}});var h=r(334);Object.defineProperty(t,"Operation",{enumerable:!0,get:function(){return h.Operation}}),Object.defineProperty(t,"AuthRequiredFlag",{enumerable:!0,get:function(){return h.AuthRequiredFlag}}),Object.defineProperty(t,"AuthRevocableFlag",{enumerable:!0,get:function(){return h.AuthRevocableFlag}}),Object.defineProperty(t,"AuthImmutableFlag",{enumerable:!0,get:function(){return h.AuthImmutableFlag}});var p=r(358);Object.defineProperty(t,"ContrOperation",{enumerable:!0,get:function(){return p.ContrOperation}});var d=r(386);Object.keys(d).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return d[e]}})});var y=r(422);Object.defineProperty(t,"Account",{enumerable:!0,get:function(){return y.Account}});var v=r(218);Object.defineProperty(t,"Network",{enumerable:!0,get:function(){return v.Network}}),Object.defineProperty(t,"Networks",{enumerable:!0,get:function(){return v.Networks}});var g=r(223);Object.defineProperty(t,"StrKey",{enumerable:!0,get:function(){return g.StrKey}});var m=r(423);Object.defineProperty(t,"Storage",{enumerable:!0,get:function(){return m.Storage}}),Object.defineProperty(t,"State",{enumerable:!0,get:function(){return m.State}}),Object.defineProperty(t,"IContract",{enumerable:!0,get:function(){return m.IContract}}),Object.defineProperty(t,"OutputFormat",{enumerable:!0,get:function(){return m.OutputFormat}}),Object.defineProperty(t,"exec",{enumerable:!0,get:function(){return m.exec}}),Object.defineProperty(t,"ReturnData",{enumerable:!0,get:function(){return m.ReturnData}}),Object.defineProperty(t,"Encode",{enumerable:!0,get:function(){return m.Encode}}),Object.defineProperty(t,"Decode",{enumerable:!0,get:function(){return m.Decode}}),Object.defineProperty(t,"getLedgerSeq",{enumerable:!0,get:function(){return m.getLedgerSeq}}),Object.defineProperty(t,"getState",{enumerable:!0,get:function(){return m.getState}}),Object.defineProperty(t,"getBalance",{enumerable:!0,get:function(){return m.getBalance}}),Object.defineProperty(t,"getBalanceAsset",{enumerable:!0,get:function(){return m.getBalanceAsset}}),Object.defineProperty(t,"ResultCode",{enumerable:!0,get:function(){return m.ResultCode}}),Object.defineProperty(t,"Success",{enumerable:!0,get:function(){return m.Success}}),Object.defineProperty(t,"Failed",{enumerable:!0,get:function(){return m.Failed}});var b=r(241),w=n(b);t.xdr=w.default,t.default=e.exports},function(e,t,r){"use strict";function n(e){var t=new o.sha256;return t.update(e,"utf8"),t.digest()}Object.defineProperty(t,"__esModule",{value:!0}),t.hash=n;var o=r(205)},function(e,t,r){var t=e.exports=function(e){e=e.toLowerCase();var r=t[e];if(!r)throw new Error(e+" is not supported (we accept pull requests)");return new r};t.sha=r(206),t.sha1=r(209),t.sha224=r(210),t.sha256=r(211),t.sha384=r(212),t.sha512=r(213)},function(e,t,r){function n(){this.init(),this._w=l,u.call(this,64,56)}function o(e){return e<<5|e>>>27}function i(e){return e<<30|e>>>2}function a(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}var s=r(175),u=r(207),c=r(208).Buffer,f=[1518500249,1859775393,-1894007588,-899497514],l=new Array(80);s(n,u),n.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},n.prototype._update=function(e){for(var t=this._w,r=0|this._a,n=0|this._b,s=0|this._c,u=0|this._d,c=0|this._e,l=0;16>l;++l)t[l]=e.readInt32BE(4*l);for(;80>l;++l)t[l]=t[l-3]^t[l-8]^t[l-14]^t[l-16];for(var h=0;80>h;++h){var p=~~(h/20),d=o(r)+a(p,n,s,u)+c+t[h]+f[p]|0;c=u,u=s,s=i(n),n=r,r=d}this._a=r+this._a|0,this._b=n+this._b|0,this._c=s+this._c|0,this._d=u+this._d|0,this._e=c+this._e|0},n.prototype._hash=function(){var e=c.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=n},function(e,t,r){function n(e,t){this._block=o.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}var o=r(208).Buffer;n.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=o.from(e,t));for(var r=this._block,n=this._blockSize,i=e.length,a=this._len,s=0;i>s;){for(var u=a%n,c=Math.min(i-s,n-u),f=0;c>f;f++)r[u+f]=e[s+f];a+=c,s+=c,a%n===0&&this._update(r)}return this._len+=i,this},n.prototype.digest=function(e){var t=this._len%this._blockSize;this._block[t]=128,this._block.fill(0,t+1),t>=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(4294967295>=r)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,o=(r-n)/4294967296;this._block.writeUInt32BE(o,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var i=this._hash();return e?i.toString(e):i},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=n},function(e,t,r){function n(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return a(e,t,r)}var i=r(156),a=i.Buffer;a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=i:(n(i,t),t.Buffer=o),o.prototype=Object.create(a.prototype),n(a,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return a(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=a(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return a(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i.SlowBuffer(e)}},function(e,t,r){function n(){this.init(),this._w=h,c.call(this,64,56)}function o(e){return e<<1|e>>>31}function i(e){return e<<5|e>>>27}function a(e){return e<<30|e>>>2}function s(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}var u=r(175),c=r(207),f=r(208).Buffer,l=[1518500249,1859775393,-1894007588,-899497514],h=new Array(80);u(n,c),n.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},n.prototype._update=function(e){for(var t=this._w,r=0|this._a,n=0|this._b,u=0|this._c,c=0|this._d,f=0|this._e,h=0;16>h;++h)t[h]=e.readInt32BE(4*h);for(;80>h;++h)t[h]=o(t[h-3]^t[h-8]^t[h-14]^t[h-16]);for(var p=0;80>p;++p){var d=~~(p/20),y=i(r)+s(d,n,u,c)+f+t[p]+l[d]|0;f=c,c=u,u=a(n),n=r,r=y}this._a=r+this._a|0,this._b=n+this._b|0,this._c=u+this._c|0,this._d=c+this._d|0,this._e=f+this._e|0},n.prototype._hash=function(){var e=f.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=n},function(e,t,r){function n(){this.init(),this._w=u,a.call(this,64,56)}var o=r(175),i=r(211),a=r(207),s=r(208).Buffer,u=new Array(64);o(n,i),n.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},n.prototype._hash=function(){var e=s.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=n},function(e,t,r){function n(){this.init(),this._w=d,l.call(this,64,56)}function o(e,t,r){return r^e&(t^r)}function i(e,t,r){return e&t|r&(e|t)}function a(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function s(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function u(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}function c(e){return(e>>>17|e<<15)^(e>>>19|e<<13)^e>>>10}var f=r(175),l=r(207),h=r(208).Buffer,p=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],d=new Array(64);f(n,l),n.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},n.prototype._update=function(e){for(var t=this._w,r=0|this._a,n=0|this._b,f=0|this._c,l=0|this._d,h=0|this._e,d=0|this._f,y=0|this._g,v=0|this._h,g=0;16>g;++g)t[g]=e.readInt32BE(4*g);for(;64>g;++g)t[g]=c(t[g-2])+t[g-7]+u(t[g-15])+t[g-16]|0;for(var m=0;64>m;++m){var b=v+s(h)+o(h,d,y)+p[m]+t[m]|0,w=a(r)+i(r,n,f)|0;v=y,y=d,d=h,h=l+b|0,l=f,f=n,n=r,r=b+w|0}this._a=r+this._a|0,this._b=n+this._b|0,this._c=f+this._c|0,this._d=l+this._d|0,this._e=h+this._e|0,this._f=d+this._f|0,this._g=y+this._g|0,this._h=v+this._h|0},n.prototype._hash=function(){var e=h.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=n},function(e,t,r){function n(){this.init(),this._w=u,a.call(this,128,112)}var o=r(175),i=r(213),a=r(207),s=r(208).Buffer,u=new Array(160);o(n,i),n.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},n.prototype._hash=function(){function e(e,r,n){t.writeInt32BE(e,n),t.writeInt32BE(r,n+4)}var t=s.allocUnsafe(48);return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),t},e.exports=n},function(e,t,r){function n(){this.init(),this._w=g,d.call(this,128,112)}function o(e,t,r){return r^e&(t^r)}function i(e,t,r){return e&t|r&(e|t)}function a(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function s(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function u(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function c(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function f(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function l(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function h(e,t){return t>>>0>e>>>0?1:0}var p=r(175),d=r(207),y=r(208).Buffer,v=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],g=new Array(160);p(n,d),n.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},n.prototype._update=function(e){for(var t=this._w,r=0|this._ah,n=0|this._bh,p=0|this._ch,d=0|this._dh,y=0|this._eh,g=0|this._fh,m=0|this._gh,b=0|this._hh,w=0|this._al,_=0|this._bl,k=0|this._cl,A=0|this._dl,O=0|this._el,E=0|this._fl,S=0|this._gl,x=0|this._hl,C=0;32>C;C+=2)t[C]=e.readInt32BE(4*C),t[C+1]=e.readInt32BE(4*C+4);for(;160>C;C+=2){var P=t[C-30],T=t[C-30+1],j=u(P,T),R=c(T,P);P=t[C-4],T=t[C-4+1];var I=f(P,T),B=l(T,P),M=t[C-14],N=t[C-14+1],U=t[C-32],L=t[C-32+1],D=R+N|0,q=j+M+h(D,R)|0;D=D+B|0,q=q+I+h(D,B)|0,D=D+L|0,q=q+U+h(D,L)|0,t[C]=q,t[C+1]=D}for(var F=0;160>F;F+=2){q=t[F],D=t[F+1];var z=i(r,n,p),H=i(w,_,k),V=a(r,w),K=a(w,r),X=s(y,O),Q=s(O,y),Y=v[F],$=v[F+1],W=o(y,g,m),Z=o(O,E,S),G=x+Q|0,J=b+X+h(G,x)|0;G=G+Z|0,J=J+W+h(G,Z)|0,G=G+$|0,J=J+Y+h(G,$)|0,G=G+D|0,J=J+q+h(G,D)|0;var et=K+H|0,tt=V+z+h(et,K)|0;b=m,x=S,m=g,S=E,g=y,E=O,O=A+G|0,y=d+J+h(O,A)|0,d=p,A=k,p=n,k=_,n=r,_=w,w=G+et|0,r=J+tt+h(w,G)|0}this._al=this._al+w|0,this._bl=this._bl+_|0,this._cl=this._cl+k|0,this._dl=this._dl+A|0,this._el=this._el+O|0,this._fl=this._fl+E|0,this._gl=this._gl+S|0,this._hl=this._hl+x|0,this._ah=this._ah+r+h(this._al,w)|0,this._bh=this._bh+n+h(this._bl,_)|0,this._ch=this._ch+p+h(this._cl,k)|0,this._dh=this._dh+d+h(this._dl,A)|0,this._eh=this._eh+y+h(this._el,O)|0,this._fh=this._fh+g+h(this._fl,E)|0,this._gh=this._gh+m+h(this._gl,S)|0,this._hh=this._hh+b+h(this._hl,x)|0},n.prototype._hash=function(){function e(e,r,n){t.writeInt32BE(e,n),t.writeInt32BE(r,n+4)}var t=y.allocUnsafe(64);return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),e(this._gh,this._gl,48),e(this._hh,this._hl,56),t},e.exports=n},function(e,t,r){(function(e){"use strict";function n(e,t){return u.sign(e,t)}function o(e,t,r){return u.verify(e,t,r)}function i(){return"undefined"==typeof window?a():s()}function a(){var t=void 0;try{t=r(!function(){var e=new Error('Cannot find module "ed25519"');throw e.code="MODULE_NOT_FOUND",e}())}catch(n){return s()}return u.sign=function(r,n){return t.Sign(e.from(r),n)},u.verify=function(r,n,o){r=e.from(r);try{return t.Verify(r,n,o)}catch(i){return!1}},!0}function s(){var t=r(215);return u.sign=function(r,n){r=e.from(r),r=new Uint8Array(r.toJSON().data),n=new Uint8Array(n.toJSON().data);var o=t.sign.detached(r,n);return e.from(o)},u.verify=function(r,n,o){return r=e.from(r),r=new Uint8Array(r.toJSON().data),n=new Uint8Array(n.toJSON().data),o=new Uint8Array(o.toJSON().data),t.sign.detached.verify(r,n,o)},!1}Object.defineProperty(t,"__esModule",{value:!0}),t.sign=n,t.verify=o;{var u={};t.FastSigning=i()}}).call(t,r(156).Buffer)},function(e,t,r){!function(e){"use strict";function t(e,t,r,n){e[t]=r>>24&255,e[t+1]=r>>16&255,e[t+2]=r>>8&255,e[t+3]=255&r,e[t+4]=n>>24&255,e[t+5]=n>>16&255,e[t+6]=n>>8&255,e[t+7]=255&n}function n(e,t,r,n,o){var i,a=0;for(i=0;o>i;i++)a|=e[t+i]^r[n+i];return(1&a-1>>>8)-1}function o(e,t,r,o){return n(e,t,r,o,16)}function i(e,t,r,o){return n(e,t,r,o,32)}function a(e,t,r,n){for(var o,i=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,a=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,s=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,u=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,c=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,f=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,l=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,h=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,p=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,d=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,y=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,v=255&r[16]|(255&r[17])<<8|(255&r[18])<<16|(255&r[19])<<24,g=255&r[20]|(255&r[21])<<8|(255&r[22])<<16|(255&r[23])<<24,m=255&r[24]|(255&r[25])<<8|(255&r[26])<<16|(255&r[27])<<24,b=255&r[28]|(255&r[29])<<8|(255&r[30])<<16|(255&r[31])<<24,w=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,_=i,k=a,A=s,O=u,E=c,S=f,x=l,C=h,P=p,T=d,j=y,R=v,I=g,B=m,M=b,N=w,U=0;20>U;U+=2)o=_+I|0,E^=o<<7|o>>>25,o=E+_|0,P^=o<<9|o>>>23,o=P+E|0,I^=o<<13|o>>>19,o=I+P|0,_^=o<<18|o>>>14,o=S+k|0,T^=o<<7|o>>>25,o=T+S|0,B^=o<<9|o>>>23,o=B+T|0,k^=o<<13|o>>>19,o=k+B|0,S^=o<<18|o>>>14,o=j+x|0,M^=o<<7|o>>>25,o=M+j|0,A^=o<<9|o>>>23,o=A+M|0,x^=o<<13|o>>>19,o=x+A|0,j^=o<<18|o>>>14,o=N+R|0,O^=o<<7|o>>>25,o=O+N|0,C^=o<<9|o>>>23,o=C+O|0,R^=o<<13|o>>>19,o=R+C|0,N^=o<<18|o>>>14,o=_+O|0,k^=o<<7|o>>>25,o=k+_|0,A^=o<<9|o>>>23,o=A+k|0,O^=o<<13|o>>>19,o=O+A|0,_^=o<<18|o>>>14,o=S+E|0,x^=o<<7|o>>>25,o=x+S|0,C^=o<<9|o>>>23,o=C+x|0,E^=o<<13|o>>>19,o=E+C|0,S^=o<<18|o>>>14,o=j+T|0,R^=o<<7|o>>>25,o=R+j|0,P^=o<<9|o>>>23,o=P+R|0,T^=o<<13|o>>>19,o=T+P|0,j^=o<<18|o>>>14,o=N+M|0,I^=o<<7|o>>>25,o=I+N|0,B^=o<<9|o>>>23,o=B+I|0,M^=o<<13|o>>>19,o=M+B|0,N^=o<<18|o>>>14;_=_+i|0,k=k+a|0,A=A+s|0,O=O+u|0,E=E+c|0,S=S+f|0,x=x+l|0,C=C+h|0,P=P+p|0,T=T+d|0,j=j+y|0,R=R+v|0,I=I+g|0,B=B+m|0,M=M+b|0,N=N+w|0,e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=k>>>0&255,e[5]=k>>>8&255,e[6]=k>>>16&255,e[7]=k>>>24&255,e[8]=A>>>0&255,e[9]=A>>>8&255,e[10]=A>>>16&255,e[11]=A>>>24&255,e[12]=O>>>0&255,e[13]=O>>>8&255,e[14]=O>>>16&255,e[15]=O>>>24&255,e[16]=E>>>0&255,e[17]=E>>>8&255,e[18]=E>>>16&255,e[19]=E>>>24&255,e[20]=S>>>0&255,e[21]=S>>>8&255,e[22]=S>>>16&255,e[23]=S>>>24&255,e[24]=x>>>0&255,e[25]=x>>>8&255,e[26]=x>>>16&255,e[27]=x>>>24&255,e[28]=C>>>0&255,e[29]=C>>>8&255,e[30]=C>>>16&255,e[31]=C>>>24&255,e[32]=P>>>0&255,e[33]=P>>>8&255,e[34]=P>>>16&255,e[35]=P>>>24&255,e[36]=T>>>0&255,e[37]=T>>>8&255,e[38]=T>>>16&255,e[39]=T>>>24&255,e[40]=j>>>0&255,e[41]=j>>>8&255,e[42]=j>>>16&255,e[43]=j>>>24&255,e[44]=R>>>0&255,e[45]=R>>>8&255,e[46]=R>>>16&255,e[47]=R>>>24&255,e[48]=I>>>0&255,e[49]=I>>>8&255,e[50]=I>>>16&255,e[51]=I>>>24&255,e[52]=B>>>0&255,e[53]=B>>>8&255,e[54]=B>>>16&255,e[55]=B>>>24&255,e[56]=M>>>0&255,e[57]=M>>>8&255,e[58]=M>>>16&255,e[59]=M>>>24&255,e[60]=N>>>0&255,e[61]=N>>>8&255,e[62]=N>>>16&255,e[63]=N>>>24&255}function s(e,t,r,n){for(var o,i=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,a=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,s=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,u=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,c=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,f=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,l=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,h=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,p=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,d=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,y=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,v=255&r[16]|(255&r[17])<<8|(255&r[18])<<16|(255&r[19])<<24,g=255&r[20]|(255&r[21])<<8|(255&r[22])<<16|(255&r[23])<<24,m=255&r[24]|(255&r[25])<<8|(255&r[26])<<16|(255&r[27])<<24,b=255&r[28]|(255&r[29])<<8|(255&r[30])<<16|(255&r[31])<<24,w=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,_=i,k=a,A=s,O=u,E=c,S=f,x=l,C=h,P=p,T=d,j=y,R=v,I=g,B=m,M=b,N=w,U=0;20>U;U+=2)o=_+I|0,E^=o<<7|o>>>25,o=E+_|0,P^=o<<9|o>>>23,o=P+E|0,I^=o<<13|o>>>19,o=I+P|0,_^=o<<18|o>>>14,o=S+k|0,T^=o<<7|o>>>25,o=T+S|0,B^=o<<9|o>>>23,o=B+T|0,k^=o<<13|o>>>19,o=k+B|0,S^=o<<18|o>>>14,o=j+x|0,M^=o<<7|o>>>25,o=M+j|0,A^=o<<9|o>>>23,o=A+M|0,x^=o<<13|o>>>19,o=x+A|0,j^=o<<18|o>>>14,o=N+R|0,O^=o<<7|o>>>25,o=O+N|0,C^=o<<9|o>>>23,o=C+O|0,R^=o<<13|o>>>19,o=R+C|0,N^=o<<18|o>>>14,o=_+O|0,k^=o<<7|o>>>25,o=k+_|0,A^=o<<9|o>>>23,o=A+k|0,O^=o<<13|o>>>19,o=O+A|0,_^=o<<18|o>>>14,o=S+E|0,x^=o<<7|o>>>25,o=x+S|0,C^=o<<9|o>>>23,o=C+x|0,E^=o<<13|o>>>19,o=E+C|0,S^=o<<18|o>>>14,o=j+T|0,R^=o<<7|o>>>25,o=R+j|0,P^=o<<9|o>>>23,o=P+R|0,T^=o<<13|o>>>19,o=T+P|0,j^=o<<18|o>>>14,o=N+M|0,I^=o<<7|o>>>25,o=I+N|0,B^=o<<9|o>>>23,o=B+I|0,M^=o<<13|o>>>19,o=M+B|0,N^=o<<18|o>>>14;e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=S>>>0&255,e[5]=S>>>8&255,e[6]=S>>>16&255,e[7]=S>>>24&255,e[8]=j>>>0&255,e[9]=j>>>8&255,e[10]=j>>>16&255,e[11]=j>>>24&255,e[12]=N>>>0&255,e[13]=N>>>8&255,e[14]=N>>>16&255,e[15]=N>>>24&255,e[16]=x>>>0&255,e[17]=x>>>8&255,e[18]=x>>>16&255,e[19]=x>>>24&255,e[20]=C>>>0&255,e[21]=C>>>8&255,e[22]=C>>>16&255,e[23]=C>>>24&255,e[24]=P>>>0&255,e[25]=P>>>8&255,e[26]=P>>>16&255,e[27]=P>>>24&255,e[28]=T>>>0&255,e[29]=T>>>8&255,e[30]=T>>>16&255,e[31]=T>>>24&255}function u(e,t,r,n){a(e,t,r,n)}function c(e,t,r,n){s(e,t,r,n)}function f(e,t,r,n,o,i,a){var s,c,f=new Uint8Array(16),l=new Uint8Array(64);for(c=0;16>c;c++)f[c]=0;for(c=0;8>c;c++)f[c]=i[c];for(;o>=64;){for(u(l,f,a,ht),c=0;64>c;c++)e[t+c]=r[n+c]^l[c];for(s=1,c=8;16>c;c++)s=s+(255&f[c])|0,f[c]=255&s,s>>>=8;o-=64,t+=64,n+=64}if(o>0)for(u(l,f,a,ht),c=0;o>c;c++)e[t+c]=r[n+c]^l[c];return 0}function l(e,t,r,n,o){var i,a,s=new Uint8Array(16),c=new Uint8Array(64);for(a=0;16>a;a++)s[a]=0;for(a=0;8>a;a++)s[a]=n[a];for(;r>=64;){for(u(c,s,o,ht),a=0;64>a;a++)e[t+a]=c[a];for(i=1,a=8;16>a;a++)i=i+(255&s[a])|0,s[a]=255&i,i>>>=8;r-=64,t+=64}if(r>0)for(u(c,s,o,ht),a=0;r>a;a++)e[t+a]=c[a];return 0}function h(e,t,r,n,o){var i=new Uint8Array(32);c(i,n,o,ht);for(var a=new Uint8Array(8),s=0;8>s;s++)a[s]=n[s+16];return l(e,t,r,a,i)}function p(e,t,r,n,o,i,a){var s=new Uint8Array(32);c(s,i,a,ht);for(var u=new Uint8Array(8),l=0;8>l;l++)u[l]=i[l+16];return f(e,t,r,n,o,u,s)}function d(e,t,r,n,o,i){var a=new pt(i);return a.update(r,n,o),a.finish(e,t),0}function y(e,t,r,n,i,a){var s=new Uint8Array(16);return d(s,0,r,n,i,a),o(e,t,s,0)}function v(e,t,r,n,o){var i;if(32>r)return-1;for(p(e,0,t,0,r,n,o),d(e,16,e,32,r-32,e),i=0;16>i;i++)e[i]=0;return 0}function g(e,t,r,n,o){var i,a=new Uint8Array(32);if(32>r)return-1;if(h(a,0,32,n,o),0!==y(t,16,t,32,r-32,a))return-1;for(p(e,0,t,0,r,n,o),i=0;32>i;i++)e[i]=0;return 0}function m(e,t){var r;for(r=0;16>r;r++)e[r]=0|t[r]}function b(e){var t,r,n=1;for(t=0;16>t;t++)r=e[t]+n+65535,n=Math.floor(r/65536),e[t]=r-65536*n;e[0]+=n-1+37*(n-1)}function w(e,t,r){for(var n,o=~(r-1),i=0;16>i;i++)n=o&(e[i]^t[i]),e[i]^=n,t[i]^=n}function _(e,t){var r,n,o,i=et(),a=et();for(r=0;16>r;r++)a[r]=t[r];for(b(a),b(a),b(a),n=0;2>n;n++){for(i[0]=a[0]-65517,r=1;15>r;r++)i[r]=a[r]-65535-(i[r-1]>>16&1),i[r-1]&=65535;i[15]=a[15]-32767-(i[14]>>16&1),o=i[15]>>16&1,i[14]&=65535,w(a,i,1-o)}for(r=0;16>r;r++)e[2*r]=255&a[r],e[2*r+1]=a[r]>>8}function k(e,t){var r=new Uint8Array(32),n=new Uint8Array(32);return _(r,e),_(n,t),i(r,0,n,0)}function A(e){var t=new Uint8Array(32);return _(t,e),1&t[0]}function O(e,t){var r;for(r=0;16>r;r++)e[r]=t[2*r]+(t[2*r+1]<<8);e[15]&=32767}function E(e,t,r){for(var n=0;16>n;n++)e[n]=t[n]+r[n]}function S(e,t,r){for(var n=0;16>n;n++)e[n]=t[n]-r[n]}function x(e,t,r){var n,o,i=0,a=0,s=0,u=0,c=0,f=0,l=0,h=0,p=0,d=0,y=0,v=0,g=0,m=0,b=0,w=0,_=0,k=0,A=0,O=0,E=0,S=0,x=0,C=0,P=0,T=0,j=0,R=0,I=0,B=0,M=0,N=r[0],U=r[1],L=r[2],D=r[3],q=r[4],F=r[5],z=r[6],H=r[7],V=r[8],K=r[9],X=r[10],Q=r[11],Y=r[12],$=r[13],W=r[14],Z=r[15];n=t[0],i+=n*N,a+=n*U,s+=n*L,u+=n*D,c+=n*q,f+=n*F,l+=n*z,h+=n*H,p+=n*V,d+=n*K,y+=n*X,v+=n*Q,g+=n*Y,m+=n*$,b+=n*W,w+=n*Z,n=t[1],a+=n*N,s+=n*U,u+=n*L,c+=n*D,f+=n*q,l+=n*F,h+=n*z,p+=n*H,d+=n*V,y+=n*K,v+=n*X,g+=n*Q,m+=n*Y,b+=n*$,w+=n*W,_+=n*Z,n=t[2],s+=n*N,u+=n*U,c+=n*L,f+=n*D,l+=n*q,h+=n*F,p+=n*z,d+=n*H,y+=n*V,v+=n*K,g+=n*X,m+=n*Q,b+=n*Y,w+=n*$,_+=n*W,k+=n*Z,n=t[3],u+=n*N,c+=n*U,f+=n*L,l+=n*D,h+=n*q,p+=n*F,d+=n*z,y+=n*H,v+=n*V,g+=n*K,m+=n*X,b+=n*Q,w+=n*Y,_+=n*$,k+=n*W,A+=n*Z,n=t[4],c+=n*N,f+=n*U,l+=n*L,h+=n*D,p+=n*q,d+=n*F,y+=n*z,v+=n*H,g+=n*V,m+=n*K,b+=n*X,w+=n*Q,_+=n*Y,k+=n*$,A+=n*W,O+=n*Z,n=t[5],f+=n*N,l+=n*U,h+=n*L,p+=n*D,d+=n*q,y+=n*F,v+=n*z,g+=n*H,m+=n*V,b+=n*K,w+=n*X,_+=n*Q,k+=n*Y,A+=n*$,O+=n*W,E+=n*Z,n=t[6],l+=n*N,h+=n*U,p+=n*L,d+=n*D,y+=n*q,v+=n*F,g+=n*z,m+=n*H,b+=n*V,w+=n*K,_+=n*X,k+=n*Q,A+=n*Y,O+=n*$,E+=n*W,S+=n*Z,n=t[7],h+=n*N,p+=n*U,d+=n*L,y+=n*D,v+=n*q,g+=n*F,m+=n*z,b+=n*H,w+=n*V,_+=n*K,k+=n*X,A+=n*Q,O+=n*Y,E+=n*$,S+=n*W,x+=n*Z,n=t[8],p+=n*N,d+=n*U,y+=n*L,v+=n*D,g+=n*q,m+=n*F,b+=n*z,w+=n*H,_+=n*V,k+=n*K,A+=n*X,O+=n*Q,E+=n*Y,S+=n*$,x+=n*W,C+=n*Z,n=t[9],d+=n*N,y+=n*U,v+=n*L,g+=n*D,m+=n*q,b+=n*F,w+=n*z,_+=n*H,k+=n*V,A+=n*K,O+=n*X,E+=n*Q,S+=n*Y,x+=n*$,C+=n*W,P+=n*Z,n=t[10],y+=n*N,v+=n*U,g+=n*L,m+=n*D,b+=n*q,w+=n*F,_+=n*z,k+=n*H,A+=n*V,O+=n*K,E+=n*X,S+=n*Q,x+=n*Y,C+=n*$,P+=n*W,T+=n*Z,n=t[11],v+=n*N,g+=n*U,m+=n*L,b+=n*D,w+=n*q,_+=n*F,k+=n*z,A+=n*H,O+=n*V,E+=n*K,S+=n*X,x+=n*Q,C+=n*Y,P+=n*$,T+=n*W,j+=n*Z,n=t[12],g+=n*N,m+=n*U,b+=n*L,w+=n*D,_+=n*q,k+=n*F,A+=n*z,O+=n*H,E+=n*V,S+=n*K,x+=n*X,C+=n*Q,P+=n*Y,T+=n*$,j+=n*W,R+=n*Z,n=t[13],m+=n*N,b+=n*U,w+=n*L,_+=n*D,k+=n*q,A+=n*F,O+=n*z,E+=n*H,S+=n*V,x+=n*K,C+=n*X,P+=n*Q,T+=n*Y,j+=n*$,R+=n*W,I+=n*Z,n=t[14],b+=n*N,w+=n*U,_+=n*L,k+=n*D,A+=n*q,O+=n*F,E+=n*z,S+=n*H,x+=n*V,C+=n*K,P+=n*X,T+=n*Q,j+=n*Y,R+=n*$,I+=n*W,B+=n*Z,n=t[15],w+=n*N,_+=n*U,k+=n*L,A+=n*D,O+=n*q,E+=n*F,S+=n*z,x+=n*H,C+=n*V,P+=n*K,T+=n*X,j+=n*Q,R+=n*Y,I+=n*$,B+=n*W,M+=n*Z,i+=38*_,a+=38*k,s+=38*A,u+=38*O,c+=38*E,f+=38*S,l+=38*x,h+=38*C,p+=38*P,d+=38*T,y+=38*j,v+=38*R,g+=38*I,m+=38*B,b+=38*M,o=1,n=i+o+65535,o=Math.floor(n/65536),i=n-65536*o,n=a+o+65535,o=Math.floor(n/65536),a=n-65536*o,n=s+o+65535,o=Math.floor(n/65536),s=n-65536*o,n=u+o+65535,o=Math.floor(n/65536),u=n-65536*o,n=c+o+65535,o=Math.floor(n/65536),c=n-65536*o,n=f+o+65535,o=Math.floor(n/65536),f=n-65536*o,n=l+o+65535,o=Math.floor(n/65536),l=n-65536*o,n=h+o+65535,o=Math.floor(n/65536),h=n-65536*o,n=p+o+65535,o=Math.floor(n/65536),p=n-65536*o,n=d+o+65535,o=Math.floor(n/65536),d=n-65536*o,n=y+o+65535,o=Math.floor(n/65536),y=n-65536*o,n=v+o+65535,o=Math.floor(n/65536),v=n-65536*o,n=g+o+65535,o=Math.floor(n/65536),g=n-65536*o,n=m+o+65535,o=Math.floor(n/65536),m=n-65536*o,n=b+o+65535,o=Math.floor(n/65536),b=n-65536*o,n=w+o+65535,o=Math.floor(n/65536),w=n-65536*o,i+=o-1+37*(o-1),o=1,n=i+o+65535,o=Math.floor(n/65536),i=n-65536*o,n=a+o+65535,o=Math.floor(n/65536),a=n-65536*o,n=s+o+65535,o=Math.floor(n/65536),s=n-65536*o,n=u+o+65535,o=Math.floor(n/65536),u=n-65536*o,n=c+o+65535,o=Math.floor(n/65536),c=n-65536*o,n=f+o+65535,o=Math.floor(n/65536),f=n-65536*o,n=l+o+65535,o=Math.floor(n/65536),l=n-65536*o,n=h+o+65535,o=Math.floor(n/65536),h=n-65536*o,n=p+o+65535,o=Math.floor(n/65536),p=n-65536*o,n=d+o+65535,o=Math.floor(n/65536),d=n-65536*o,n=y+o+65535,o=Math.floor(n/65536),y=n-65536*o,n=v+o+65535,o=Math.floor(n/65536),v=n-65536*o,n=g+o+65535,o=Math.floor(n/65536),g=n-65536*o,n=m+o+65535,o=Math.floor(n/65536),m=n-65536*o,n=b+o+65535,o=Math.floor(n/65536),b=n-65536*o,n=w+o+65535,o=Math.floor(n/65536),w=n-65536*o,i+=o-1+37*(o-1),e[0]=i,e[1]=a,e[2]=s,e[3]=u,e[4]=c,e[5]=f,e[6]=l,e[7]=h,e[8]=p,e[9]=d,e[10]=y,e[11]=v,e[12]=g,e[13]=m,e[14]=b,e[15]=w
}function C(e,t){x(e,t,t)}function P(e,t){var r,n=et();for(r=0;16>r;r++)n[r]=t[r];for(r=253;r>=0;r--)C(n,n),2!==r&&4!==r&&x(n,n,t);for(r=0;16>r;r++)e[r]=n[r]}function T(e,t){var r,n=et();for(r=0;16>r;r++)n[r]=t[r];for(r=250;r>=0;r--)C(n,n),1!==r&&x(n,n,t);for(r=0;16>r;r++)e[r]=n[r]}function j(e,t,r){var n,o,i=new Uint8Array(32),a=new Float64Array(80),s=et(),u=et(),c=et(),f=et(),l=et(),h=et();for(o=0;31>o;o++)i[o]=t[o];for(i[31]=127&t[31]|64,i[0]&=248,O(a,r),o=0;16>o;o++)u[o]=a[o],f[o]=s[o]=c[o]=0;for(s[0]=f[0]=1,o=254;o>=0;--o)n=i[o>>>3]>>>(7&o)&1,w(s,u,n),w(c,f,n),E(l,s,c),S(s,s,c),E(c,u,f),S(u,u,f),C(f,l),C(h,s),x(s,c,s),x(c,u,l),E(l,s,c),S(s,s,c),C(u,s),S(c,f,h),x(s,c,at),E(s,s,f),x(c,c,s),x(s,f,h),x(f,u,a),C(u,l),w(s,u,n),w(c,f,n);for(o=0;16>o;o++)a[o+16]=s[o],a[o+32]=c[o],a[o+48]=u[o],a[o+64]=f[o];var p=a.subarray(32),d=a.subarray(16);return P(p,p),x(d,d,p),_(e,d),0}function R(e,t){return j(e,t,nt)}function I(e,t){return tt(t,32),R(e,t)}function B(e,t,r){var n=new Uint8Array(32);return j(n,r,t),c(e,rt,n,ht)}function M(e,t,r,n,o,i){var a=new Uint8Array(32);return B(a,o,i),dt(e,t,r,n,a)}function N(e,t,r,n,o,i){var a=new Uint8Array(32);return B(a,o,i),yt(e,t,r,n,a)}function U(e,t,r,n){for(var o,i,a,s,u,c,f,l,h,p,d,y,v,g,m,b,w,_,k,A,O,E,S,x,C,P,T=new Int32Array(16),j=new Int32Array(16),R=e[0],I=e[1],B=e[2],M=e[3],N=e[4],U=e[5],L=e[6],D=e[7],q=t[0],F=t[1],z=t[2],H=t[3],V=t[4],K=t[5],X=t[6],Q=t[7],Y=0;n>=128;){for(k=0;16>k;k++)A=8*k+Y,T[k]=r[A+0]<<24|r[A+1]<<16|r[A+2]<<8|r[A+3],j[k]=r[A+4]<<24|r[A+5]<<16|r[A+6]<<8|r[A+7];for(k=0;80>k;k++)if(o=R,i=I,a=B,s=M,u=N,c=U,f=L,l=D,h=q,p=F,d=z,y=H,v=V,g=K,m=X,b=Q,O=D,E=Q,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=(N>>>14|V<<18)^(N>>>18|V<<14)^(V>>>9|N<<23),E=(V>>>14|N<<18)^(V>>>18|N<<14)^(N>>>9|V<<23),S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,O=N&U^~N&L,E=V&K^~V&X,S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,O=vt[2*k],E=vt[2*k+1],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,O=T[k%16],E=j[k%16],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,w=65535&C|P<<16,_=65535&S|x<<16,O=w,E=_,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=(R>>>28|q<<4)^(q>>>2|R<<30)^(q>>>7|R<<25),E=(q>>>28|R<<4)^(R>>>2|q<<30)^(R>>>7|q<<25),S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,O=R&I^R&B^I&B,E=q&F^q&z^F&z,S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,l=65535&C|P<<16,b=65535&S|x<<16,O=s,E=y,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=w,E=_,S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,s=65535&C|P<<16,y=65535&S|x<<16,I=o,B=i,M=a,N=s,U=u,L=c,D=f,R=l,F=h,z=p,H=d,V=y,K=v,X=g,Q=m,q=b,k%16===15)for(A=0;16>A;A++)O=T[A],E=j[A],S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=T[(A+9)%16],E=j[(A+9)%16],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,w=T[(A+1)%16],_=j[(A+1)%16],O=(w>>>1|_<<31)^(w>>>8|_<<24)^w>>>7,E=(_>>>1|w<<31)^(_>>>8|w<<24)^(_>>>7|w<<25),S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,w=T[(A+14)%16],_=j[(A+14)%16],O=(w>>>19|_<<13)^(_>>>29|w<<3)^w>>>6,E=(_>>>19|w<<13)^(w>>>29|_<<3)^(_>>>6|w<<26),S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,T[A]=65535&C|P<<16,j[A]=65535&S|x<<16;O=R,E=q,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[0],E=t[0],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[0]=R=65535&C|P<<16,t[0]=q=65535&S|x<<16,O=I,E=F,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[1],E=t[1],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[1]=I=65535&C|P<<16,t[1]=F=65535&S|x<<16,O=B,E=z,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[2],E=t[2],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[2]=B=65535&C|P<<16,t[2]=z=65535&S|x<<16,O=M,E=H,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[3],E=t[3],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[3]=M=65535&C|P<<16,t[3]=H=65535&S|x<<16,O=N,E=V,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[4],E=t[4],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[4]=N=65535&C|P<<16,t[4]=V=65535&S|x<<16,O=U,E=K,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[5],E=t[5],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[5]=U=65535&C|P<<16,t[5]=K=65535&S|x<<16,O=L,E=X,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[6],E=t[6],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[6]=L=65535&C|P<<16,t[6]=X=65535&S|x<<16,O=D,E=Q,S=65535&E,x=E>>>16,C=65535&O,P=O>>>16,O=e[7],E=t[7],S+=65535&E,x+=E>>>16,C+=65535&O,P+=O>>>16,x+=S>>>16,C+=x>>>16,P+=C>>>16,e[7]=D=65535&C|P<<16,t[7]=Q=65535&S|x<<16,Y+=128,n-=128}return n}function L(e,r,n){var o,i=new Int32Array(8),a=new Int32Array(8),s=new Uint8Array(256),u=n;for(i[0]=1779033703,i[1]=3144134277,i[2]=1013904242,i[3]=2773480762,i[4]=1359893119,i[5]=2600822924,i[6]=528734635,i[7]=1541459225,a[0]=4089235720,a[1]=2227873595,a[2]=4271175723,a[3]=1595750129,a[4]=2917565137,a[5]=725511199,a[6]=4215389547,a[7]=327033209,U(i,a,r,n),n%=128,o=0;n>o;o++)s[o]=r[u-n+o];for(s[n]=128,n=256-128*(112>n?1:0),s[n-9]=0,t(s,n-8,u/536870912|0,u<<3),U(i,a,s,n),o=0;8>o;o++)t(e,8*o,i[o],a[o]);return 0}function D(e,t){var r=et(),n=et(),o=et(),i=et(),a=et(),s=et(),u=et(),c=et(),f=et();S(r,e[1],e[0]),S(f,t[1],t[0]),x(r,r,f),E(n,e[0],e[1]),E(f,t[0],t[1]),x(n,n,f),x(o,e[3],t[3]),x(o,o,ut),x(i,e[2],t[2]),E(i,i,i),S(a,n,r),S(s,i,o),E(u,i,o),E(c,n,r),x(e[0],a,s),x(e[1],c,u),x(e[2],u,s),x(e[3],a,c)}function q(e,t,r){var n;for(n=0;4>n;n++)w(e[n],t[n],r)}function F(e,t){var r=et(),n=et(),o=et();P(o,t[2]),x(r,t[0],o),x(n,t[1],o),_(e,n),e[31]^=A(r)<<7}function z(e,t,r){var n,o;for(m(e[0],ot),m(e[1],it),m(e[2],it),m(e[3],ot),o=255;o>=0;--o)n=r[o/8|0]>>(7&o)&1,q(e,t,n),D(t,e),D(e,e),q(e,t,n)}function H(e,t){var r=[et(),et(),et(),et()];m(r[0],ct),m(r[1],ft),m(r[2],it),x(r[3],ct,ft),z(e,r,t)}function V(e,t,r){var n,o=new Uint8Array(64),i=[et(),et(),et(),et()];for(r||tt(t,32),L(o,t,32),o[0]&=248,o[31]&=127,o[31]|=64,H(i,o),F(e,i),n=0;32>n;n++)t[n+32]=e[n];return 0}function K(e,t){var r,n,o,i;for(n=63;n>=32;--n){for(r=0,o=n-32,i=n-12;i>o;++o)t[o]+=r-16*t[n]*gt[o-(n-32)],r=Math.floor((t[o]+128)/256),t[o]-=256*r;t[o]+=r,t[n]=0}for(r=0,o=0;32>o;o++)t[o]+=r-(t[31]>>4)*gt[o],r=t[o]>>8,t[o]&=255;for(o=0;32>o;o++)t[o]-=r*gt[o];for(n=0;32>n;n++)t[n+1]+=t[n]>>8,e[n]=255&t[n]}function X(e){var t,r=new Float64Array(64);for(t=0;64>t;t++)r[t]=e[t];for(t=0;64>t;t++)e[t]=0;K(e,r)}function Q(e,t,r,n){var o,i,a=new Uint8Array(64),s=new Uint8Array(64),u=new Uint8Array(64),c=new Float64Array(64),f=[et(),et(),et(),et()];L(a,n,32),a[0]&=248,a[31]&=127,a[31]|=64;var l=r+64;for(o=0;r>o;o++)e[64+o]=t[o];for(o=0;32>o;o++)e[32+o]=a[32+o];for(L(u,e.subarray(32),r+32),X(u),H(f,u),F(e,f),o=32;64>o;o++)e[o]=n[o];for(L(s,e,r+64),X(s),o=0;64>o;o++)c[o]=0;for(o=0;32>o;o++)c[o]=u[o];for(o=0;32>o;o++)for(i=0;32>i;i++)c[o+i]+=s[o]*a[i];return K(e.subarray(32),c),l}function Y(e,t){var r=et(),n=et(),o=et(),i=et(),a=et(),s=et(),u=et();return m(e[2],it),O(e[1],t),C(o,e[1]),x(i,o,st),S(o,o,e[2]),E(i,e[2],i),C(a,i),C(s,a),x(u,s,a),x(r,u,o),x(r,r,i),T(r,r),x(r,r,o),x(r,r,i),x(r,r,i),x(e[0],r,i),C(n,e[0]),x(n,n,i),k(n,o)&&x(e[0],e[0],lt),C(n,e[0]),x(n,n,i),k(n,o)?-1:(A(e[0])===t[31]>>7&&S(e[0],ot,e[0]),x(e[3],e[0],e[1]),0)}function $(e,t,r,n){var o,a=new Uint8Array(32),s=new Uint8Array(64),u=[et(),et(),et(),et()],c=[et(),et(),et(),et()];if(64>r)return-1;if(Y(c,n))return-1;for(o=0;r>o;o++)e[o]=t[o];for(o=0;32>o;o++)e[o+32]=n[o];if(L(s,e,r),X(s),z(u,c,s),H(c,t.subarray(32)),D(u,c),F(a,u),r-=64,i(t,0,a,0)){for(o=0;r>o;o++)e[o]=0;return-1}for(o=0;r>o;o++)e[o]=t[o+64];return r}function W(e,t){if(e.length!==mt)throw new Error("bad key size");if(t.length!==bt)throw new Error("bad nonce size")}function Z(e,t){if(e.length!==Ot)throw new Error("bad public key size");if(t.length!==Et)throw new Error("bad secret key size")}function G(){for(var e=0;e<arguments.length;e++)if(!(arguments[e]instanceof Uint8Array))throw new TypeError("unexpected type, use Uint8Array")}function J(e){for(var t=0;t<e.length;t++)e[t]=0}var et=function(e){var t,r=new Float64Array(16);if(e)for(t=0;t<e.length;t++)r[t]=e[t];return r},tt=function(){throw new Error("no PRNG")},rt=new Uint8Array(16),nt=new Uint8Array(32);nt[0]=9;var ot=et(),it=et([1]),at=et([56129,1]),st=et([30883,4953,19914,30187,55467,16705,2637,112,59544,30585,16505,36039,65139,11119,27886,20995]),ut=et([61785,9906,39828,60374,45398,33411,5274,224,53552,61171,33010,6542,64743,22239,55772,9222]),ct=et([54554,36645,11616,51542,42930,38181,51040,26924,56412,64982,57905,49316,21502,52590,14035,8553]),ft=et([26200,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214]),lt=et([41136,18958,6951,50414,58488,44335,6150,12099,55207,15867,153,11085,57099,20417,9344,11139]),ht=new Uint8Array([101,120,112,97,110,100,32,51,50,45,98,121,116,101,32,107]),pt=function(e){this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.leftover=0,this.fin=0;var t,r,n,o,i,a,s,u;t=255&e[0]|(255&e[1])<<8,this.r[0]=8191&t,r=255&e[2]|(255&e[3])<<8,this.r[1]=8191&(t>>>13|r<<3),n=255&e[4]|(255&e[5])<<8,this.r[2]=7939&(r>>>10|n<<6),o=255&e[6]|(255&e[7])<<8,this.r[3]=8191&(n>>>7|o<<9),i=255&e[8]|(255&e[9])<<8,this.r[4]=255&(o>>>4|i<<12),this.r[5]=i>>>1&8190,a=255&e[10]|(255&e[11])<<8,this.r[6]=8191&(i>>>14|a<<2),s=255&e[12]|(255&e[13])<<8,this.r[7]=8065&(a>>>11|s<<5),u=255&e[14]|(255&e[15])<<8,this.r[8]=8191&(s>>>8|u<<8),this.r[9]=u>>>5&127,this.pad[0]=255&e[16]|(255&e[17])<<8,this.pad[1]=255&e[18]|(255&e[19])<<8,this.pad[2]=255&e[20]|(255&e[21])<<8,this.pad[3]=255&e[22]|(255&e[23])<<8,this.pad[4]=255&e[24]|(255&e[25])<<8,this.pad[5]=255&e[26]|(255&e[27])<<8,this.pad[6]=255&e[28]|(255&e[29])<<8,this.pad[7]=255&e[30]|(255&e[31])<<8};pt.prototype.blocks=function(e,t,r){for(var n,o,i,a,s,u,c,f,l,h,p,d,y,v,g,m,b,w,_,k=this.fin?0:2048,A=this.h[0],O=this.h[1],E=this.h[2],S=this.h[3],x=this.h[4],C=this.h[5],P=this.h[6],T=this.h[7],j=this.h[8],R=this.h[9],I=this.r[0],B=this.r[1],M=this.r[2],N=this.r[3],U=this.r[4],L=this.r[5],D=this.r[6],q=this.r[7],F=this.r[8],z=this.r[9];r>=16;)n=255&e[t+0]|(255&e[t+1])<<8,A+=8191&n,o=255&e[t+2]|(255&e[t+3])<<8,O+=8191&(n>>>13|o<<3),i=255&e[t+4]|(255&e[t+5])<<8,E+=8191&(o>>>10|i<<6),a=255&e[t+6]|(255&e[t+7])<<8,S+=8191&(i>>>7|a<<9),s=255&e[t+8]|(255&e[t+9])<<8,x+=8191&(a>>>4|s<<12),C+=s>>>1&8191,u=255&e[t+10]|(255&e[t+11])<<8,P+=8191&(s>>>14|u<<2),c=255&e[t+12]|(255&e[t+13])<<8,T+=8191&(u>>>11|c<<5),f=255&e[t+14]|(255&e[t+15])<<8,j+=8191&(c>>>8|f<<8),R+=f>>>5|k,l=0,h=l,h+=A*I,h+=5*O*z,h+=5*E*F,h+=5*S*q,h+=5*x*D,l=h>>>13,h&=8191,h+=5*C*L,h+=5*P*U,h+=5*T*N,h+=5*j*M,h+=5*R*B,l+=h>>>13,h&=8191,p=l,p+=A*B,p+=O*I,p+=5*E*z,p+=5*S*F,p+=5*x*q,l=p>>>13,p&=8191,p+=5*C*D,p+=5*P*L,p+=5*T*U,p+=5*j*N,p+=5*R*M,l+=p>>>13,p&=8191,d=l,d+=A*M,d+=O*B,d+=E*I,d+=5*S*z,d+=5*x*F,l=d>>>13,d&=8191,d+=5*C*q,d+=5*P*D,d+=5*T*L,d+=5*j*U,d+=5*R*N,l+=d>>>13,d&=8191,y=l,y+=A*N,y+=O*M,y+=E*B,y+=S*I,y+=5*x*z,l=y>>>13,y&=8191,y+=5*C*F,y+=5*P*q,y+=5*T*D,y+=5*j*L,y+=5*R*U,l+=y>>>13,y&=8191,v=l,v+=A*U,v+=O*N,v+=E*M,v+=S*B,v+=x*I,l=v>>>13,v&=8191,v+=5*C*z,v+=5*P*F,v+=5*T*q,v+=5*j*D,v+=5*R*L,l+=v>>>13,v&=8191,g=l,g+=A*L,g+=O*U,g+=E*N,g+=S*M,g+=x*B,l=g>>>13,g&=8191,g+=C*I,g+=5*P*z,g+=5*T*F,g+=5*j*q,g+=5*R*D,l+=g>>>13,g&=8191,m=l,m+=A*D,m+=O*L,m+=E*U,m+=S*N,m+=x*M,l=m>>>13,m&=8191,m+=C*B,m+=P*I,m+=5*T*z,m+=5*j*F,m+=5*R*q,l+=m>>>13,m&=8191,b=l,b+=A*q,b+=O*D,b+=E*L,b+=S*U,b+=x*N,l=b>>>13,b&=8191,b+=C*M,b+=P*B,b+=T*I,b+=5*j*z,b+=5*R*F,l+=b>>>13,b&=8191,w=l,w+=A*F,w+=O*q,w+=E*D,w+=S*L,w+=x*U,l=w>>>13,w&=8191,w+=C*N,w+=P*M,w+=T*B,w+=j*I,w+=5*R*z,l+=w>>>13,w&=8191,_=l,_+=A*z,_+=O*F,_+=E*q,_+=S*D,_+=x*L,l=_>>>13,_&=8191,_+=C*U,_+=P*N,_+=T*M,_+=j*B,_+=R*I,l+=_>>>13,_&=8191,l=(l<<2)+l|0,l=l+h|0,h=8191&l,l>>>=13,p+=l,A=h,O=p,E=d,S=y,x=v,C=g,P=m,T=b,j=w,R=_,t+=16,r-=16;this.h[0]=A,this.h[1]=O,this.h[2]=E,this.h[3]=S,this.h[4]=x,this.h[5]=C,this.h[6]=P,this.h[7]=T,this.h[8]=j,this.h[9]=R},pt.prototype.finish=function(e,t){var r,n,o,i,a=new Uint16Array(10);if(this.leftover){for(i=this.leftover,this.buffer[i++]=1;16>i;i++)this.buffer[i]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(r=this.h[1]>>>13,this.h[1]&=8191,i=2;10>i;i++)this.h[i]+=r,r=this.h[i]>>>13,this.h[i]&=8191;for(this.h[0]+=5*r,r=this.h[0]>>>13,this.h[0]&=8191,this.h[1]+=r,r=this.h[1]>>>13,this.h[1]&=8191,this.h[2]+=r,a[0]=this.h[0]+5,r=a[0]>>>13,a[0]&=8191,i=1;10>i;i++)a[i]=this.h[i]+r,r=a[i]>>>13,a[i]&=8191;for(a[9]-=8192,n=(1^r)-1,i=0;10>i;i++)a[i]&=n;for(n=~n,i=0;10>i;i++)this.h[i]=this.h[i]&n|a[i];for(this.h[0]=65535&(this.h[0]|this.h[1]<<13),this.h[1]=65535&(this.h[1]>>>3|this.h[2]<<10),this.h[2]=65535&(this.h[2]>>>6|this.h[3]<<7),this.h[3]=65535&(this.h[3]>>>9|this.h[4]<<4),this.h[4]=65535&(this.h[4]>>>12|this.h[5]<<1|this.h[6]<<14),this.h[5]=65535&(this.h[6]>>>2|this.h[7]<<11),this.h[6]=65535&(this.h[7]>>>5|this.h[8]<<8),this.h[7]=65535&(this.h[8]>>>8|this.h[9]<<5),o=this.h[0]+this.pad[0],this.h[0]=65535&o,i=1;8>i;i++)o=(this.h[i]+this.pad[i]|0)+(o>>>16)|0,this.h[i]=65535&o;e[t+0]=this.h[0]>>>0&255,e[t+1]=this.h[0]>>>8&255,e[t+2]=this.h[1]>>>0&255,e[t+3]=this.h[1]>>>8&255,e[t+4]=this.h[2]>>>0&255,e[t+5]=this.h[2]>>>8&255,e[t+6]=this.h[3]>>>0&255,e[t+7]=this.h[3]>>>8&255,e[t+8]=this.h[4]>>>0&255,e[t+9]=this.h[4]>>>8&255,e[t+10]=this.h[5]>>>0&255,e[t+11]=this.h[5]>>>8&255,e[t+12]=this.h[6]>>>0&255,e[t+13]=this.h[6]>>>8&255,e[t+14]=this.h[7]>>>0&255,e[t+15]=this.h[7]>>>8&255},pt.prototype.update=function(e,t,r){var n,o;if(this.leftover){for(o=16-this.leftover,o>r&&(o=r),n=0;o>n;n++)this.buffer[this.leftover+n]=e[t+n];if(r-=o,t+=o,this.leftover+=o,this.leftover<16)return;this.blocks(this.buffer,0,16),this.leftover=0}if(r>=16&&(o=r-r%16,this.blocks(e,t,o),t+=o,r-=o),r){for(n=0;r>n;n++)this.buffer[this.leftover+n]=e[t+n];this.leftover+=r}};var dt=v,yt=g,vt=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],gt=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]),mt=32,bt=24,wt=32,_t=16,kt=32,At=32,Ot=32,Et=32,St=32,xt=bt,Ct=wt,Pt=_t,Tt=64,jt=32,Rt=64,It=32,Bt=64;e.lowlevel={crypto_core_hsalsa20:c,crypto_stream_xor:p,crypto_stream:h,crypto_stream_salsa20_xor:f,crypto_stream_salsa20:l,crypto_onetimeauth:d,crypto_onetimeauth_verify:y,crypto_verify_16:o,crypto_verify_32:i,crypto_secretbox:v,crypto_secretbox_open:g,crypto_scalarmult:j,crypto_scalarmult_base:R,crypto_box_beforenm:B,crypto_box_afternm:dt,crypto_box:M,crypto_box_open:N,crypto_box_keypair:I,crypto_hash:L,crypto_sign:Q,crypto_sign_keypair:V,crypto_sign_open:$,crypto_secretbox_KEYBYTES:mt,crypto_secretbox_NONCEBYTES:bt,crypto_secretbox_ZEROBYTES:wt,crypto_secretbox_BOXZEROBYTES:_t,crypto_scalarmult_BYTES:kt,crypto_scalarmult_SCALARBYTES:At,crypto_box_PUBLICKEYBYTES:Ot,crypto_box_SECRETKEYBYTES:Et,crypto_box_BEFORENMBYTES:St,crypto_box_NONCEBYTES:xt,crypto_box_ZEROBYTES:Ct,crypto_box_BOXZEROBYTES:Pt,crypto_sign_BYTES:Tt,crypto_sign_PUBLICKEYBYTES:jt,crypto_sign_SECRETKEYBYTES:Rt,crypto_sign_SEEDBYTES:It,crypto_hash_BYTES:Bt,gf:et,D:st,L:gt,pack25519:_,unpack25519:O,M:x,A:E,S:C,Z:S,pow2523:T,add:D,set25519:m,modL:K,scalarmult:z,scalarbase:H},e.randomBytes=function(e){var t=new Uint8Array(e);return tt(t,e),t},e.secretbox=function(e,t,r){G(e,t,r),W(r,t);for(var n=new Uint8Array(wt+e.length),o=new Uint8Array(n.length),i=0;i<e.length;i++)n[i+wt]=e[i];return v(o,n,n.length,t,r),o.subarray(_t)},e.secretbox.open=function(e,t,r){G(e,t,r),W(r,t);for(var n=new Uint8Array(_t+e.length),o=new Uint8Array(n.length),i=0;i<e.length;i++)n[i+_t]=e[i];return n.length<32?null:0!==g(o,n,n.length,t,r)?null:o.subarray(wt)},e.secretbox.keyLength=mt,e.secretbox.nonceLength=bt,e.secretbox.overheadLength=_t,e.scalarMult=function(e,t){if(G(e,t),e.length!==At)throw new Error("bad n size");if(t.length!==kt)throw new Error("bad p size");var r=new Uint8Array(kt);return j(r,e,t),r},e.scalarMult.base=function(e){if(G(e),e.length!==At)throw new Error("bad n size");var t=new Uint8Array(kt);return R(t,e),t},e.scalarMult.scalarLength=At,e.scalarMult.groupElementLength=kt,e.box=function(t,r,n,o){var i=e.box.before(n,o);return e.secretbox(t,r,i)},e.box.before=function(e,t){G(e,t),Z(e,t);var r=new Uint8Array(St);return B(r,e,t),r},e.box.after=e.secretbox,e.box.open=function(t,r,n,o){var i=e.box.before(n,o);return e.secretbox.open(t,r,i)},e.box.open.after=e.secretbox.open,e.box.keyPair=function(){var e=new Uint8Array(Ot),t=new Uint8Array(Et);return I(e,t),{publicKey:e,secretKey:t}},e.box.keyPair.fromSecretKey=function(e){if(G(e),e.length!==Et)throw new Error("bad secret key size");var t=new Uint8Array(Ot);return R(t,e),{publicKey:t,secretKey:new Uint8Array(e)}},e.box.publicKeyLength=Ot,e.box.secretKeyLength=Et,e.box.sharedKeyLength=St,e.box.nonceLength=xt,e.box.overheadLength=e.secretbox.overheadLength,e.sign=function(e,t){if(G(e,t),t.length!==Rt)throw new Error("bad secret key size");var r=new Uint8Array(Tt+e.length);return Q(r,e,e.length,t),r},e.sign.open=function(e,t){if(G(e,t),t.length!==jt)throw new Error("bad public key size");var r=new Uint8Array(e.length),n=$(r,e,e.length,t);if(0>n)return null;for(var o=new Uint8Array(n),i=0;i<o.length;i++)o[i]=r[i];return o},e.sign.detached=function(t,r){for(var n=e.sign(t,r),o=new Uint8Array(Tt),i=0;i<o.length;i++)o[i]=n[i];return o},e.sign.detached.verify=function(e,t,r){if(G(e,t,r),t.length!==Tt)throw new Error("bad signature size");if(r.length!==jt)throw new Error("bad public key size");var n,o=new Uint8Array(Tt+e.length),i=new Uint8Array(Tt+e.length);for(n=0;Tt>n;n++)o[n]=t[n];for(n=0;n<e.length;n++)o[n+Tt]=e[n];return $(i,o,o.length,r)>=0},e.sign.keyPair=function(){var e=new Uint8Array(jt),t=new Uint8Array(Rt);return V(e,t),{publicKey:e,secretKey:t}},e.sign.keyPair.fromSecretKey=function(e){if(G(e),e.length!==Rt)throw new Error("bad secret key size");for(var t=new Uint8Array(jt),r=0;r<t.length;r++)t[r]=e[32+r];return{publicKey:t,secretKey:new Uint8Array(e)}},e.sign.keyPair.fromSeed=function(e){if(G(e),e.length!==It)throw new Error("bad seed size");for(var t=new Uint8Array(jt),r=new Uint8Array(Rt),n=0;32>n;n++)r[n]=e[n];return V(t,r,!0),{publicKey:t,secretKey:r}},e.sign.publicKeyLength=jt,e.sign.secretKeyLength=Rt,e.sign.seedLength=It,e.sign.signatureLength=Tt,e.hash=function(e){G(e);var t=new Uint8Array(Bt);return L(t,e,e.length),t},e.hash.hashLength=Bt,e.verify=function(e,t){return G(e,t),0===e.length||0===t.length?!1:e.length!==t.length?!1:0===n(e,0,t,0,e.length)?!0:!1},e.setPRNG=function(e){tt=e},function(){var t="undefined"!=typeof self?self.crypto||self.msCrypto:null;if(t&&t.getRandomValues){var n=65536;e.setPRNG(function(e,r){var o,i=new Uint8Array(r);for(o=0;r>o;o+=n)t.getRandomValues(i.subarray(o,o+Math.min(r-o,n)));for(o=0;r>o;o++)e[o]=i[o];J(i)})}else t=r(216),t&&t.randomBytes&&e.setPRNG(function(e,r){var n,o=t.randomBytes(r);for(n=0;r>n;n++)e[n]=o[n];J(o)})}()}("undefined"!=typeof e&&e.exports?e.exports:self.nacl=self.nacl||{})},function(){},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Keypair=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(218),u=r(214),c=r(219),f=o(c),l=r(223),h=r(241),p=n(h),d=r(215),y=n(d);t.Keypair=function(){function t(r){if(i(this,t),"ed25519"!=r.type&&"contract"!=r.type)throw new Error("Invalid keys type");if(this.type=r.type,r.secretKey){if(r.secretKey=e.from(r.secretKey),32!=r.secretKey.length)throw new Error("secretKey length is invalid");var n=new Uint8Array(r.secretKey),o=y.default.sign.keyPair.fromSeed(n);if(this._secretSeed=r.secretKey,this._secretKey=e.from(o.secretKey),this._publicKey=e.from(o.publicKey),r.publicKey&&!this._publicKey.equals(e.from(r.publicKey)))throw new Error("secretKey does not match publicKey")}else if(r.publicKey){if(this._publicKey=e.from(r.publicKey),32!=this._publicKey.length)throw new Error("publicKey length is invalid")}else if(this._publicKey=e.from(r.contractKey),32!=this._publicKey.length)throw new Error("publicKey length is invalid")}return a(t,[{key:"xdrAccountId",value:function(){return new p.default.AccountId.publicKeyTypeEd25519(this._publicKey)}},{key:"xdrContractId",value:function(){return new p.default.ContractId.publicKeyTypeContract(this._publicKey)}},{key:"xdrPublicKey",value:function(){return new p.default.PublicKey.publicKeyTypeEd25519(this._publicKey)}},{key:"rawPublicKey",value:function(){return this._publicKey}},{key:"signatureHint",value:function(){var e=this.xdrAccountId().toXDR();return e.slice(e.length-4)}},{key:"publicKey",value:function(){return l.StrKey.encodeEd25519PublicKey(this._publicKey)}},{key:"secret",value:function(){if(!this._secretSeed)throw new Error("no secret key available");if("ed25519"==this.type)return l.StrKey.encodeEd25519SecretSeed(this._secretSeed);throw new Error("Invalid Keypair type")}},{key:"rawSecretKey",value:function(){return this._secretSeed}},{key:"canSign",value:function(){return!!this._secretKey}},{key:"sign",value:function(e){if(!this.canSign())throw new Error("cannot sign: no secret key available");return u.sign(e,this._secretKey)}},{key:"verify",value:function(e,t){return u.verify(e,t,this._publicKey)}},{key:"signDecorated",value:function(e){var t=this.sign(e),r=this.signatureHint();return new p.default.DecoratedSignature({hint:r,signature:t})}}],[{key:"fromSecret",value:function(e){var t=l.StrKey.decodeEd25519SecretSeed(e);return this.fromRawEd25519Seed(t)}},{key:"fromBase58Seed",value:function(e){var t=f.decodeBase58Check("seed",e);return this.fromRawEd25519Seed(t)}},{key:"fromRawEd25519Seed",value:function(e){return new this({type:"ed25519",secretKey:e})}},{key:"master",value:function(){if(null===s.Network.current())throw new Error("No network selected. Use `Network.use`, `Network.usePublicNetwork` or `Network.useTestNetwork` helper methods to select network.");return this.fromRawEd25519Seed(s.Network.current().networkId())}},{key:"fromPublicKey",value:function(e){if(e=l.StrKey.decodeEd25519PublicKey(e),32!==e.length)throw new Error("Invalid Stellar public key");return new this({type:"ed25519",publicKey:e})}},{key:"fromContractKey",value:function(e){if(e=l.StrKey.decodeContractKey(e),32!==e.length)throw new Error("Invalid Stellar contract key");return new this({type:"contract",contractKey:e})}},{key:"random",value:function(){var e=y.default.randomBytes(32);return this.fromRawEd25519Seed(e)}}]),t}()}}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Network=t.Networks=void 0;{var o=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),i=r(204),a=t.Networks={PUBLIC:"Public Global Stellar Network ; September 2015",TESTNET:"Test SDF Network ; September 2015"},s=null;t.Network=function(){function e(t){n(this,e),this._networkPassphrase=t}return o(e,[{key:"networkPassphrase",value:function(){return this._networkPassphrase}},{key:"networkId",value:function(){return i.hash(this.networkPassphrase())}}],[{key:"usePublicNetwork",value:function(){this.use(new e(a.PUBLIC))}},{key:"useTestNetwork",value:function(){this.use(new e(a.TESTNET))}},{key:"use",value:function(e){s=e}},{key:"current",value:function(){return s}}]),e}()}},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(t,r){var n=s.default.decode(r),o=n[0],a=n.slice(0,n.length-4),u=a.slice(1),f=n.slice(n.length-4),p=h[t];if(c.default(p))throw new Error(t+' is not a valid version byte name. expected one of "accountId", "seed", or "none"');if(o!==p)throw new Error("invalid version byte. expected "+p+", got "+o);var d=i(a);if(!l.verifyChecksum(d,f))throw new Error("invalid checksum");if("accountId"===t&&37!==n.length)throw new Error("Decoded address length is invalid. Expected 37, got "+n.length);return e.from(u)}function i(e){var t=f.hash(e),r=f.hash(t);return r.slice(0,4)}Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBase58Check=o;var a=r(220),s=n(a),u=r(221),c=n(u),f=r(204),l=r(222),h={accountId:0,none:1,seed:33}}).call(t,r(156).Buffer)},function(e){"use strict";function t(e){if(0===e.length)return[];var t,r,o=[0];for(t=0;t<e.length;++t){var a=e[t];if(!(a in n))throw new Error("Non-base58 character");for(r=0;r<o.length;++r)o[r]*=i;o[0]+=n[a];var s=0;for(r=0;r<o.length;++r)o[r]+=s,s=o[r]>>8,o[r]&=255;for(;s;)o.push(255&s),s>>=8}for(t=0;"g"===e[t]&&t<e.length-1;++t)o.push(0);return o.reverse()}for(var r="gsphnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCr65jkm8oFqi1tuvAxyz",n={},o=0;o<r.length;++o)n[r.charAt(o)]=o;var i=58;e.exports={decode:t}},function(e){function t(e){return void 0===e}e.exports=t},function(e,t){"use strict";function r(e,t){if(e.length!==t.length)return!1;if(0===e.length)return!0;for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}Object.defineProperty(t,"__esModule",{value:!0}),t.verifyChecksum=r},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(t&&56!=t.length)return!1;try{var r=a(e,t);if(32!==r.length)return!1}catch(n){return!1}return!0}function a(t,r){if(!b.default(r))throw new TypeError("encoded argument must be of type String");var n=l.default.decode(r),o=n[0],i=n.slice(0,-2),a=i.slice(1),s=n.slice(-2);if(r!=l.default.encode(n))throw new Error("invalid encoded string");var c=_[t];if(y.default(c))throw new Error(t+' is not a valid version byte name. expected one of "accountId" or "seed"');if(o!==c)throw new Error("invalid version byte. expected "+c+", got "+o);var f=u(i);if(!w.verifyChecksum(f,s))throw new Error("invalid checksum");return e.from(a)}function s(t,r){if(g.default(r)||y.default(r))throw new Error("cannot encode null data");var n=_[t];if(y.default(n))throw new Error(t+' is not a valid version byte name. expected one of "ed25519PublicKey", "ed25519SecretSeed", "preAuthTx", "sha256Hash", "preContract"');r=e.from(r);var o=e.from([n]),i=e.concat([o,r]),a=u(i),s=e.concat([i,a]);return l.default.encode(s)}function u(t){var r=e.alloc(2);return r.writeUInt16LE(p.default.crc16xmodem(t),0),r}Object.defineProperty(t,"__esModule",{value:!0}),t.StrKey=void 0;var c=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();t.decodeCheck=a,t.encodeCheck=s;{var f=r(224),l=n(f),h=r(225),p=n(h),d=r(221),y=n(d),v=r(239),g=n(v),m=r(240),b=n(m),w=r(222),_={ed25519PublicKey:48,ed25519SecretSeed:144,preAuthTx:152,sha256Hash:184,preContract:16};t.StrKey=function(){function e(){o(this,e)}return c(e,null,[{key:"encodeEd25519PublicKey",value:function(e){return s("ed25519PublicKey",e)}},{key:"encodeContractKey",value:function(e){return s("preContract",e)}},{key:"decodeEd25519PublicKey",value:function(e){return a("ed25519PublicKey",e)}},{key:"decodeContractKey",value:function(e){return a("preContract",e)}},{key:"isValidEd25519PublicKey",value:function(e){return i("ed25519PublicKey",e)}},{key:"isValidContractKey",value:function(e){return i("preContract",e)}},{key:"encodeEd25519SecretSeed",value:function(e){return s("ed25519SecretSeed",e)}},{key:"decodeEd25519SecretSeed",value:function(e){return a("ed25519SecretSeed",e)}},{key:"isValidEd25519SecretSeed",value:function(e){return i("ed25519SecretSeed",e)}},{key:"encodePreAuthTx",value:function(e){return s("preAuthTx",e)}},{key:"decodePreAuthTx",value:function(e){return a("preAuthTx",e)}},{key:"encodeSha256Hash",value:function(e){return s("sha256Hash",e)}},{key:"decodeSha256Hash",value:function(e){return a("sha256Hash",e)}}]),e}()}}).call(t,r(156).Buffer)},function(e,t){"use strict";function r(e){if(this.buf=[],this.shift=8,this.carry=0,e){switch(e.type){case"rfc4648":this.charmap=t.rfc4648.charmap;break;case"crockford":this.charmap=t.crockford.charmap;break;case"base32hex":this.charmap=t.base32hex.charmap;break;default:throw new Error("invalid type")}e.charmap&&(this.charmap=e.charmap)}}function n(e){if(this.buf="",this.shift=3,this.carry=0,e){switch(e.type){case"rfc4648":this.alphabet=t.rfc4648.alphabet;break;case"crockford":this.alphabet=t.crockford.alphabet;break;case"base32hex":this.alphabet=t.base32hex.alphabet;break;default:throw new Error("invalid type")}e.alphabet?this.alphabet=e.alphabet:e.lc&&(this.alphabet=this.alphabet.toLowerCase())}}var o=function(e,t){return t||(t={}),e.split("").forEach(function(e,r){e in t||(t[e]=r)}),t},i={alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",charmap:{0:14,1:8}};i.charmap=o(i.alphabet,i.charmap);var a={alphabet:"0123456789ABCDEFGHJKMNPQRSTVWXYZ",charmap:{O:0,I:1,L:1}};a.charmap=o(a.alphabet,a.charmap);var s={alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV",charmap:{}};s.charmap=o(s.alphabet,s.charmap),r.prototype.charmap=i.charmap,r.prototype.write=function(e){var t=this.charmap,r=this.buf,n=this.shift,o=this.carry;return e.toUpperCase().split("").forEach(function(e){if("="!=e){var i=255&t[e];n-=5,n>0?o|=i<<n:0>n?(r.push(o|i>>-n),n+=8,o=i<<n&255):(r.push(o|i),n=8,o=0)}}),this.shift=n,this.carry=o,this},r.prototype.finalize=function(e){return e&&this.write(e),8!==this.shift&&0!==this.carry&&(this.buf.push(this.carry),this.shift=8,this.carry=0),this.buf},n.prototype.alphabet=i.alphabet,n.prototype.write=function(e){var t,r,n,o=this.shift,i=this.carry;for(n=0;n<e.length;n++)r=e[n],t=i|r>>o,this.buf+=this.alphabet[31&t],o>5&&(o-=5,t=r>>o,this.buf+=this.alphabet[31&t]),o=5-o,i=r<<o,o=8-o;return this.shift=o,this.carry=i,this},n.prototype.finalize=function(e){return e&&this.write(e),3!==this.shift&&(this.buf+=this.alphabet[31&this.carry],this.shift=3,this.carry=0),this.buf},t.encode=function(e,t){return new n(t).finalize(e)
},t.decode=function(e,t){return new r(t).finalize(e)},t.Decoder=r,t.Encoder=n,t.charmap=o,t.crockford=a,t.rfc4648=i,t.base32hex=s},function(e,t,r){"use strict";e.exports={crc1:r(226),crc8:r(229),crc81wire:r(230),crc16:r(231),crc16ccitt:r(232),crc16modbus:r(233),crc16xmodem:r(234),crc16kermit:r(235),crc24:r(236),crc32:r(237),crcjam:r(238)}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s);e.exports=u.default("crc1",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r=~~t,n=0,i=0;i<e.length;i++){var s=e[i];n+=s}return r+=n%256,r%256})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(156),o=n.Buffer.from&&n.Buffer.alloc&&n.Buffer.allocUnsafe&&n.Buffer.allocUnsafeSlow?n.Buffer.from:function(e){return new n.Buffer(e)};t.default=o},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var r=function(e,r){return t(e,r)>>>0};return r.signed=t,r.unsigned=r,r.model=e,r}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,7,14,9,28,27,18,21,56,63,54,49,36,35,42,45,112,119,126,121,108,107,98,101,72,79,70,65,84,83,90,93,224,231,238,233,252,251,242,245,216,223,214,209,196,195,202,205,144,151,158,153,140,139,130,133,168,175,166,161,180,179,186,189,199,192,201,206,219,220,213,210,255,248,241,246,227,228,237,234,183,176,185,190,171,172,165,162,143,136,129,134,147,148,157,154,39,32,41,46,59,60,53,50,31,24,17,22,3,4,13,10,87,80,89,94,75,76,69,66,111,104,97,102,115,116,125,122,137,142,135,128,149,146,155,156,177,182,191,184,173,170,163,164,249,254,247,240,229,226,235,236,193,198,207,200,221,218,211,212,105,110,103,96,117,114,123,124,81,86,95,88,77,74,67,68,25,30,23,16,5,2,11,12,33,38,47,40,61,58,51,52,78,73,64,71,82,85,92,91,118,113,120,127,106,109,100,99,62,57,48,55,34,37,44,43,6,1,8,15,26,29,20,19,174,169,160,167,178,181,188,187,150,145,152,159,138,141,132,131,222,217,208,215,194,197,204,203,230,225,232,239,250,253,244,243];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("crc-8",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r=~~t,n=0;n<e.length;n++){var i=e[n];r=255&c[255&(r^i)]}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,94,188,226,97,63,221,131,194,156,126,32,163,253,31,65,157,195,33,127,252,162,64,30,95,1,227,189,62,96,130,220,35,125,159,193,66,28,254,160,225,191,93,3,128,222,60,98,190,224,2,92,223,129,99,61,124,34,192,158,29,67,161,255,70,24,250,164,39,121,155,197,132,218,56,102,229,187,89,7,219,133,103,57,186,228,6,88,25,71,165,251,120,38,196,154,101,59,217,135,4,90,184,230,167,249,27,69,198,152,122,36,248,166,68,26,153,199,37,123,58,100,134,216,91,5,231,185,140,210,48,110,237,179,81,15,78,16,242,172,47,113,147,205,17,79,173,243,112,46,204,146,211,141,111,49,178,236,14,80,175,241,19,77,206,144,114,44,109,51,209,143,12,82,176,238,50,108,142,208,83,13,239,177,240,174,76,18,145,207,45,115,202,148,118,40,171,245,23,73,8,86,180,234,105,55,213,139,87,9,235,181,54,104,138,212,149,203,41,119,244,170,72,22,233,183,85,11,136,214,52,106,43,117,151,201,74,20,246,168,116,42,200,150,21,75,169,247,182,232,10,84,215,137,107,53];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("dallas-1-wire",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r=~~t,n=0;n<e.length;n++){var i=e[n];r=255&c[255&(r^i)]}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,49345,49537,320,49921,960,640,49729,50689,1728,1920,51009,1280,50625,50305,1088,52225,3264,3456,52545,3840,53185,52865,3648,2560,51905,52097,2880,51457,2496,2176,51265,55297,6336,6528,55617,6912,56257,55937,6720,7680,57025,57217,8e3,56577,7616,7296,56385,5120,54465,54657,5440,55041,6080,5760,54849,53761,4800,4992,54081,4352,53697,53377,4160,61441,12480,12672,61761,13056,62401,62081,12864,13824,63169,63361,14144,62721,13760,13440,62529,15360,64705,64897,15680,65281,16320,16e3,65089,64001,15040,15232,64321,14592,63937,63617,14400,10240,59585,59777,10560,60161,11200,10880,59969,60929,11968,12160,61249,11520,60865,60545,11328,58369,9408,9600,58689,9984,59329,59009,9792,8704,58049,58241,9024,57601,8640,8320,57409,40961,24768,24960,41281,25344,41921,41601,25152,26112,42689,42881,26432,42241,26048,25728,42049,27648,44225,44417,27968,44801,28608,28288,44609,43521,27328,27520,43841,26880,43457,43137,26688,30720,47297,47489,31040,47873,31680,31360,47681,48641,32448,32640,48961,32e3,48577,48257,31808,46081,29888,30080,46401,30464,47041,46721,30272,29184,45761,45953,29504,45313,29120,28800,45121,20480,37057,37249,20800,37633,21440,21120,37441,38401,22208,22400,38721,21760,38337,38017,21568,39937,23744,23936,40257,24320,40897,40577,24128,23040,39617,39809,23360,39169,22976,22656,38977,34817,18624,18816,35137,19200,35777,35457,19008,19968,36545,36737,20288,36097,19904,19584,35905,17408,33985,34177,17728,34561,18368,18048,34369,33281,17088,17280,33601,16640,33217,32897,16448];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("crc-16",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r=~~t,n=0;n<e.length;n++){var i=e[n];r=65535&(c[255&(r^i)]^r>>8)}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,4129,8258,12387,16516,20645,24774,28903,33032,37161,41290,45419,49548,53677,57806,61935,4657,528,12915,8786,21173,17044,29431,25302,37689,33560,45947,41818,54205,50076,62463,58334,9314,13379,1056,5121,25830,29895,17572,21637,42346,46411,34088,38153,58862,62927,50604,54669,13907,9842,5649,1584,30423,26358,22165,18100,46939,42874,38681,34616,63455,59390,55197,51132,18628,22757,26758,30887,2112,6241,10242,14371,51660,55789,59790,63919,35144,39273,43274,47403,23285,19156,31415,27286,6769,2640,14899,10770,56317,52188,64447,60318,39801,35672,47931,43802,27814,31879,19684,23749,11298,15363,3168,7233,60846,64911,52716,56781,44330,48395,36200,40265,32407,28342,24277,20212,15891,11826,7761,3696,65439,61374,57309,53244,48923,44858,40793,36728,37256,33193,45514,41451,53516,49453,61774,57711,4224,161,12482,8419,20484,16421,28742,24679,33721,37784,41979,46042,49981,54044,58239,62302,689,4752,8947,13010,16949,21012,25207,29270,46570,42443,38312,34185,62830,58703,54572,50445,13538,9411,5280,1153,29798,25671,21540,17413,42971,47098,34713,38840,59231,63358,50973,55100,9939,14066,1681,5808,26199,30326,17941,22068,55628,51565,63758,59695,39368,35305,47498,43435,22596,18533,30726,26663,6336,2273,14466,10403,52093,56156,60223,64286,35833,39896,43963,48026,19061,23124,27191,31254,2801,6864,10931,14994,64814,60687,56684,52557,48554,44427,40424,36297,31782,27655,23652,19525,15522,11395,7392,3265,61215,65342,53085,57212,44955,49082,36825,40952,28183,32310,20053,24180,11923,16050,3793,7920];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("ccitt",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r="undefined"!=typeof t?~~t:65535,n=0;n<e.length;n++){var i=e[n];r=65535&(c[255&(r>>8^i)]^r<<8)}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,49345,49537,320,49921,960,640,49729,50689,1728,1920,51009,1280,50625,50305,1088,52225,3264,3456,52545,3840,53185,52865,3648,2560,51905,52097,2880,51457,2496,2176,51265,55297,6336,6528,55617,6912,56257,55937,6720,7680,57025,57217,8e3,56577,7616,7296,56385,5120,54465,54657,5440,55041,6080,5760,54849,53761,4800,4992,54081,4352,53697,53377,4160,61441,12480,12672,61761,13056,62401,62081,12864,13824,63169,63361,14144,62721,13760,13440,62529,15360,64705,64897,15680,65281,16320,16e3,65089,64001,15040,15232,64321,14592,63937,63617,14400,10240,59585,59777,10560,60161,11200,10880,59969,60929,11968,12160,61249,11520,60865,60545,11328,58369,9408,9600,58689,9984,59329,59009,9792,8704,58049,58241,9024,57601,8640,8320,57409,40961,24768,24960,41281,25344,41921,41601,25152,26112,42689,42881,26432,42241,26048,25728,42049,27648,44225,44417,27968,44801,28608,28288,44609,43521,27328,27520,43841,26880,43457,43137,26688,30720,47297,47489,31040,47873,31680,31360,47681,48641,32448,32640,48961,32e3,48577,48257,31808,46081,29888,30080,46401,30464,47041,46721,30272,29184,45761,45953,29504,45313,29120,28800,45121,20480,37057,37249,20800,37633,21440,21120,37441,38401,22208,22400,38721,21760,38337,38017,21568,39937,23744,23936,40257,24320,40897,40577,24128,23040,39617,39809,23360,39169,22976,22656,38977,34817,18624,18816,35137,19200,35777,35457,19008,19968,36545,36737,20288,36097,19904,19584,35905,17408,33985,34177,17728,34561,18368,18048,34369,33281,17088,17280,33601,16640,33217,32897,16448];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("crc-16-modbus",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r="undefined"!=typeof t?~~t:65535,n=0;n<e.length;n++){var i=e[n];r=65535&(c[255&(r^i)]^r>>8)}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s);e.exports=u.default("xmodem",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r="undefined"!=typeof t?~~t:0,n=0;n<e.length;n++){var i=e[n],s=r>>>8&255;s^=255&i,s^=s>>>4,r=r<<8&65535,r^=s,s=s<<5&65535,r^=s,s=s<<7&65535,r^=s}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,4489,8978,12955,17956,22445,25910,29887,35912,40385,44890,48851,51820,56293,59774,63735,4225,264,13203,8730,22181,18220,30135,25662,40137,36160,49115,44626,56045,52068,63999,59510,8450,12427,528,5017,26406,30383,17460,21949,44362,48323,36440,40913,60270,64231,51324,55797,12675,8202,4753,792,30631,26158,21685,17724,48587,44098,40665,36688,64495,60006,55549,51572,16900,21389,24854,28831,1056,5545,10034,14011,52812,57285,60766,64727,34920,39393,43898,47859,21125,17164,29079,24606,5281,1320,14259,9786,57037,53060,64991,60502,39145,35168,48123,43634,25350,29327,16404,20893,9506,13483,1584,6073,61262,65223,52316,56789,43370,47331,35448,39921,29575,25102,20629,16668,13731,9258,5809,1848,65487,60998,56541,52564,47595,43106,39673,35696,33800,38273,42778,46739,49708,54181,57662,61623,2112,6601,11090,15067,20068,24557,28022,31999,38025,34048,47003,42514,53933,49956,61887,57398,6337,2376,15315,10842,24293,20332,32247,27774,42250,46211,34328,38801,58158,62119,49212,53685,10562,14539,2640,7129,28518,32495,19572,24061,46475,41986,38553,34576,62383,57894,53437,49460,14787,10314,6865,2904,32743,28270,23797,19836,50700,55173,58654,62615,32808,37281,41786,45747,19012,23501,26966,30943,3168,7657,12146,16123,54925,50948,62879,58390,37033,33056,46011,41522,23237,19276,31191,26718,7393,3432,16371,11898,59150,63111,50204,54677,41258,45219,33336,37809,27462,31439,18516,23005,11618,15595,3696,8185,63375,58886,54429,50452,45483,40994,37561,33584,31687,27214,22741,18780,15843,11370,7921,3960];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("kermit",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r="undefined"!=typeof t?~~t:0,n=0;n<e.length;n++){var i=e[n];r=65535&(c[255&(r^i)]^r>>8)}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,8801531,9098509,825846,9692897,1419802,1651692,10452759,10584377,2608578,2839604,11344079,3303384,11807523,12104405,4128302,12930697,4391538,5217156,13227903,5679208,13690003,14450021,5910942,6606768,14844747,15604413,6837830,16197969,7431594,8256604,16494759,840169,9084178,8783076,18463,10434312,1670131,1434117,9678590,11358416,2825259,2590173,10602790,4109873,12122826,11821884,3289031,13213536,5231515,4409965,12912278,5929345,14431610,13675660,5693559,6823513,15618722,14863188,6588335,16513208,8238147,7417269,16212302,1680338,10481449,9664223,1391140,9061683,788936,36926,8838341,12067563,4091408,3340262,11844381,2868234,11372785,10555655,2579964,14478683,5939616,5650518,13661357,5180346,13190977,12967607,4428364,8219746,16457881,16234863,7468436,15633027,6866552,6578062,14816117,1405499,9649856,10463030,1698765,8819930,55329,803287,9047340,11858690,3325945,4072975,12086004,2561507,10574104,11387118,2853909,13647026,5664841,5958079,14460228,4446803,12949160,13176670,5194661,7454091,16249200,16476294,8201341,14834538,6559633,6852199,15647388,3360676,11864927,12161705,4185682,10527045,2551230,2782280,11286707,9619101,1346150,1577872,10379115,73852,8875143,9172337,899466,16124205,7357910,8182816,16421083,6680524,14918455,15678145,6911546,5736468,13747439,14507289,5968354,12873461,4334094,5159928,13170435,4167245,12180150,11879232,3346363,11301036,2767959,2532769,10545498,10360692,1596303,1360505,9604738,913813,9157998,8856728,92259,16439492,8164415,7343561,16138546,6897189,15692510,14936872,6662099,5986813,14488838,13733104,5750795,13156124,5174247,4352529,12855018,2810998,11315341,10498427,2522496,12124823,4148844,3397530,11901793,9135439,862644,110658,8912057,1606574,10407765,9590435,1317464,15706879,6940164,6651890,14889737,8145950,16384229,16161043,7394792,5123014,13133629,12910283,4370992,14535975,5997020,5707818,13718737,2504095,10516836,11329682,2796649,11916158,3383173,4130419,12143240,8893606,129117,876971,9121104,1331783,9576124,10389322,1625009,14908182,6633453,6925851,15721184,7380471,16175372,16402682,8127489,4389423,12891860,13119266,5137369,13704398,5722165,6015427,14517560];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("crc-24",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r="undefined"!=typeof t?~~t:11994318,n=0;n<e.length;n++){var i=e[n];r=16777215&(c[255&(r>>16^i)]^r<<8)}return r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("crc-32",function(e,t){o.Buffer.isBuffer(e)||(e=a.default(e));for(var r=0===t?0:-1^~~t,n=0;n<e.length;n++){var i=e[n];r=c[255&(r^i)]^r>>>8}return-1^r})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}var o=r(156),i=r(227),a=n(i),s=r(228),u=n(s),c=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];"undefined"!=typeof Int32Array&&(c=new Int32Array(c)),e.exports=u.default("jam",function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1;o.Buffer.isBuffer(e)||(e=a.default(e));for(var r=0===t?0:~~t,n=0;n<e.length;n++){var i=e[n];r=c[255&(r^i)]^r>>>8}return r})},function(e){function t(e){return null===e}e.exports=t},function(e,t,r){function n(e){return"string"==typeof e||!i(e)&&a(e)&&o(e)==s}var o=r(24),i=r(62),a=r(61),s="[object String]";e.exports=n},function(e,t,r){"use strict";function n(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}Object.defineProperty(t,"__esModule",{value:!0});var o=r(242),i=n(o),a=i.config(function(e){e.typedef("Value",e.varOpaque()),e.struct("ScpBallot",[["counter",e.lookup("Uint32")],["value",e.lookup("Value")]]),e.enum("ScpStatementType",{scpStPrepare:0,scpStConfirm:1,scpStExternalize:2,scpStNominate:3}),e.struct("ScpNomination",[["quorumSetHash",e.lookup("Hash")],["votes",e.varArray(e.lookup("Value"),2147483647)],["accepted",e.varArray(e.lookup("Value"),2147483647)]]),e.struct("ScpStatementPrepare",[["quorumSetHash",e.lookup("Hash")],["ballot",e.lookup("ScpBallot")],["prepared",e.option(e.lookup("ScpBallot"))],["preparedPrime",e.option(e.lookup("ScpBallot"))],["nC",e.lookup("Uint32")],["nH",e.lookup("Uint32")]]),e.struct("ScpStatementConfirm",[["ballot",e.lookup("ScpBallot")],["nPrepared",e.lookup("Uint32")],["nCommit",e.lookup("Uint32")],["nH",e.lookup("Uint32")],["quorumSetHash",e.lookup("Hash")]]),e.struct("ScpStatementExternalize",[["commit",e.lookup("ScpBallot")],["nH",e.lookup("Uint32")],["commitQuorumSetHash",e.lookup("Hash")]]),e.union("ScpStatementPledges",{switchOn:e.lookup("ScpStatementType"),switchName:"type",switches:[["scpStPrepare","prepare"],["scpStConfirm","confirm"],["scpStExternalize","externalize"],["scpStNominate","nominate"]],arms:{prepare:e.lookup("ScpStatementPrepare"),confirm:e.lookup("ScpStatementConfirm"),externalize:e.lookup("ScpStatementExternalize"),nominate:e.lookup("ScpNomination")}}),e.struct("ScpStatement",[["nodeId",e.lookup("NodeId")],["slotIndex",e.lookup("Uint64")],["pledges",e.lookup("ScpStatementPledges")]]),e.struct("ScpEnvelope",[["statement",e.lookup("ScpStatement")],["signature",e.lookup("Signature")]]),e.struct("ScpQuorumSet",[["threshold",e.lookup("Uint32")],["validators",e.varArray(e.lookup("PublicKey"),2147483647)],["innerSets",e.varArray(e.lookup("ScpQuorumSet"),2147483647)]]),e.typedef("AccountId",e.lookup("PublicKey")),e.typedef("ContractId",e.lookup("PublicKey")),e.typedef("Thresholds",e.opaque(4)),e.typedef("String32",e.string(32)),e.typedef("String64",e.string(64)),e.typedef("String128",e.string(128)),e.typedef("String256",e.string(256)),e.typedef("String2048",e.string(2048)),e.typedef("SequenceNumber",e.lookup("Int64")),e.typedef("DataValue",e.varOpaque(64)),e.typedef("ContractParams",e.varOpaque()),e.typedef("ContractExeCode",e.varOpaque()),e.typedef("StateString",e.varOpaque()),e.typedef("TxOldBody",e.varOpaque()),e.typedef("ContractAddr",e.varOpaque()),e.struct("ContractInput",[["funcName",e.lookup("String64")],["contractParams",e.lookup("ContractParams")]]),e.struct("ContractOutput",[["newState",e.lookup("StateString")],["exeCode",e.lookup("ContractExeCode")]]),e.enum("AssetType",{assetTypeNative:0,assetTypeCreditAlphanum4:1,assetTypeCreditAlphanum12:2}),e.struct("AssetAlphaNum4",[["assetCode",e.opaque(4)],["issuer",e.lookup("AccountId")]]),e.struct("AssetAlphaNum12",[["assetCode",e.opaque(12)],["issuer",e.lookup("AccountId")]]),e.union("Asset",{switchOn:e.lookup("AssetType"),switchName:"type",switches:[["assetTypeNative",e.void()],["assetTypeCreditAlphanum4","alphaNum4"],["assetTypeCreditAlphanum12","alphaNum12"]],arms:{alphaNum4:e.lookup("AssetAlphaNum4"),alphaNum12:e.lookup("AssetAlphaNum12")}}),e.struct("Price",[["n",e.lookup("Int32")],["d",e.lookup("Int32")]]),e.struct("Liabilities",[["buying",e.lookup("Int64")],["selling",e.lookup("Int64")]]),e.enum("ThresholdIndices",{thresholdMasterWeight:0,thresholdLow:1,thresholdMed:2,thresholdHigh:3}),e.enum("LedgerEntryType",{account:0,trustline:1,offer:2,datum:3,asset:4,contractstate:5}),e.struct("Signer",[["key",e.lookup("SignerKey")],["weight",e.lookup("Uint32")]]),e.enum("AccountFlags",{authRequiredFlag:1,authRevocableFlag:2,authImmutableFlag:4}),e.const("MASK_ACCOUNT_FLAGS",7),e.union("AccountEntryV1Ext",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("AccountEntryV1",[["liabilities",e.lookup("Liabilities")],["amountLock",e.lookup("Int64")],["ext",e.lookup("AccountEntryV1Ext")]]),e.union("AccountEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()],[1,"v1"]],arms:{v1:e.lookup("AccountEntryV1")}}),e.struct("AccountEntry",[["accountId",e.lookup("AccountId")],["balance",e.lookup("Int64")],["seqNum",e.lookup("SequenceNumber")],["numSubEntries",e.lookup("Uint32")],["inflationDest",e.option(e.lookup("AccountId"))],["flags",e.lookup("Uint32")],["homeDomain",e.lookup("String32")],["thresholds",e.lookup("Thresholds")],["signers",e.varArray(e.lookup("Signer"),20)],["ext",e.lookup("AccountEntryExt")]]),e.enum("TrustLineFlags",{authorizedFlag:1}),e.const("MASK_TRUSTLINE_FLAGS",1),e.union("TrustLineEntryV1Ext",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("TrustLineEntryV1",[["liabilities",e.lookup("Liabilities")],["ext",e.lookup("TrustLineEntryV1Ext")]]),e.union("TrustLineEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()],[1,"v1"]],arms:{v1:e.lookup("TrustLineEntryV1")}}),e.struct("TrustLineEntry",[["accountId",e.lookup("AccountId")],["asset",e.lookup("Asset")],["balance",e.lookup("Int64")],["limit",e.lookup("Int64")],["flags",e.lookup("Uint32")],["ext",e.lookup("TrustLineEntryExt")]]),e.enum("OfferEntryFlags",{passiveFlag:1}),e.const("MASK_OFFERENTRY_FLAGS",1),e.union("OfferEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("OfferEntry",[["sellerId",e.lookup("AccountId")],["offerId",e.lookup("Uint64")],["selling",e.lookup("Asset")],["buying",e.lookup("Asset")],["amount",e.lookup("Int64")],["price",e.lookup("Price")],["flags",e.lookup("Uint32")],["ext",e.lookup("OfferEntryExt")]]),e.union("DataEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("DataEntry",[["accountId",e.lookup("AccountId")],["dataName",e.lookup("String64")],["dataValue",e.lookup("DataValue")],["ext",e.lookup("DataEntryExt")]]),e.union("AssetEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("AssetEntry",[["asset",e.lookup("Asset")],["beneficiary",e.lookup("String64")],["fee",e.lookup("Uint32")],["ratio",e.lookup("Uint32")],["minfee",e.lookup("Int64")],["total",e.lookup("Int64")],["islimited",e.lookup("Uint32")],["ext",e.lookup("AssetEntryExt")]]),e.union("ContractStateEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("ContractStateEntry",[["accountId",e.lookup("AccountId")],["state",e.lookup("StateString")],["stateHash",e.lookup("String64")],["lastTxModified",e.lookup("String64")],["nonce",e.lookup("Uint32")],["contractAddr",e.lookup("ContractAddr")],["fileHash",e.lookup("String64")],["sourceAcc",e.lookup("AccountId")],["ext",e.lookup("ContractStateEntryExt")]]),e.union("LedgerEntryData",{switchOn:e.lookup("LedgerEntryType"),switchName:"type",switches:[["account","account"],["trustline","trustLine"],["offer","offer"],["datum","data"],["asset","asset"],["contractstate","contractState"]],arms:{account:e.lookup("AccountEntry"),trustLine:e.lookup("TrustLineEntry"),offer:e.lookup("OfferEntry"),data:e.lookup("DataEntry"),asset:e.lookup("AssetEntry"),contractState:e.lookup("ContractStateEntry")}}),e.union("LedgerEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("LedgerEntry",[["lastModifiedLedgerSeq",e.lookup("Uint32")],["data",e.lookup("LedgerEntryData")],["ext",e.lookup("LedgerEntryExt")]]),e.enum("EnvelopeType",{envelopeTypeScp:1,envelopeTypeTx:2,envelopeTypeAuth:3}),e.typedef("UpgradeType",e.varOpaque(128)),e.union("StellarValueExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("StellarValue",[["txSetHash",e.lookup("Hash")],["closeTime",e.lookup("Uint64")],["upgrades",e.varArray(e.lookup("UpgradeType"),6)],["ext",e.lookup("StellarValueExt")]]),e.union("LedgerHeaderExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("LedgerHeader",[["ledgerVersion",e.lookup("Uint32")],["previousLedgerHash",e.lookup("Hash")],["scpValue",e.lookup("StellarValue")],["txSetResultHash",e.lookup("Hash")],["bucketListHash",e.lookup("Hash")],["ledgerSeq",e.lookup("Uint32")],["totalCoins",e.lookup("Int64")],["feePool",e.lookup("Int64")],["inflationSeq",e.lookup("Uint32")],["idPool",e.lookup("Uint64")],["baseFee",e.lookup("Uint32")],["baseReserve",e.lookup("Uint32")],["maxTxSetSize",e.lookup("Uint32")],["skipList",e.array(e.lookup("Hash"),4)],["ext",e.lookup("LedgerHeaderExt")]]),e.enum("LedgerUpgradeType",{ledgerUpgradeVersion:1,ledgerUpgradeBaseFee:2,ledgerUpgradeMaxTxSetSize:3,ledgerUpgradeBaseReserve:4}),e.union("LedgerUpgrade",{switchOn:e.lookup("LedgerUpgradeType"),switchName:"type",switches:[["ledgerUpgradeVersion","newLedgerVersion"],["ledgerUpgradeBaseFee","newBaseFee"],["ledgerUpgradeMaxTxSetSize","newMaxTxSetSize"],["ledgerUpgradeBaseReserve","newBaseReserve"]],arms:{newLedgerVersion:e.lookup("Uint32"),newBaseFee:e.lookup("Uint32"),newMaxTxSetSize:e.lookup("Uint32"),newBaseReserve:e.lookup("Uint32")}}),e.struct("LedgerKeyAccount",[["accountId",e.lookup("AccountId")]]),e.struct("LedgerKeyTrustLine",[["accountId",e.lookup("AccountId")],["asset",e.lookup("Asset")]]),e.struct("LedgerKeyOffer",[["sellerId",e.lookup("AccountId")],["offerId",e.lookup("Uint64")]]),e.struct("LedgerKeyData",[["accountId",e.lookup("AccountId")],["dataName",e.lookup("String64")]]),e.struct("LedgerKeyAsset",[["asset",e.lookup("Asset")]]),e.struct("LedgerKeyContractState",[["accountId",e.lookup("AccountId")]]),e.union("LedgerKey",{switchOn:e.lookup("LedgerEntryType"),switchName:"type",switches:[["account","account"],["trustline","trustLine"],["offer","offer"],["datum","data"],["asset","asset"],["contractstate","contractState"]],arms:{account:e.lookup("LedgerKeyAccount"),trustLine:e.lookup("LedgerKeyTrustLine"),offer:e.lookup("LedgerKeyOffer"),data:e.lookup("LedgerKeyData"),asset:e.lookup("LedgerKeyAsset"),contractState:e.lookup("LedgerKeyContractState")}}),e.enum("BucketEntryType",{liveentry:0,deadentry:1}),e.union("BucketEntry",{switchOn:e.lookup("BucketEntryType"),switchName:"type",switches:[["liveentry","liveEntry"],["deadentry","deadEntry"]],arms:{liveEntry:e.lookup("LedgerEntry"),deadEntry:e.lookup("LedgerKey")}}),e.struct("TransactionSet",[["previousLedgerHash",e.lookup("Hash")],["txes",e.varArray(e.lookup("TransactionEnvelope"),2147483647)]]),e.struct("TransactionResultPair",[["transactionHash",e.lookup("Hash")],["result",e.lookup("TransactionResult")]]),e.struct("TransactionResultSet",[["results",e.varArray(e.lookup("TransactionResultPair"),2147483647)]]),e.union("TransactionHistoryEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("TransactionHistoryEntry",[["ledgerSeq",e.lookup("Uint32")],["txSet",e.lookup("TransactionSet")],["ext",e.lookup("TransactionHistoryEntryExt")]]),e.union("TransactionHistoryResultEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("TransactionHistoryResultEntry",[["ledgerSeq",e.lookup("Uint32")],["txResultSet",e.lookup("TransactionResultSet")],["ext",e.lookup("TransactionHistoryResultEntryExt")]]),e.union("LedgerHeaderHistoryEntryExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("LedgerHeaderHistoryEntry",[["hash",e.lookup("Hash")],["header",e.lookup("LedgerHeader")],["ext",e.lookup("LedgerHeaderHistoryEntryExt")]]),e.struct("LedgerScpMessages",[["ledgerSeq",e.lookup("Uint32")],["messages",e.varArray(e.lookup("ScpEnvelope"),2147483647)]]),e.struct("ScpHistoryEntryV0",[["quorumSets",e.varArray(e.lookup("ScpQuorumSet"),2147483647)],["ledgerMessages",e.lookup("LedgerScpMessages")]]),e.union("ScpHistoryEntry",{switchOn:e.int(),switchName:"v",switches:[[0,"v0"]],arms:{v0:e.lookup("ScpHistoryEntryV0")}}),e.enum("LedgerEntryChangeType",{ledgerEntryCreated:0,ledgerEntryUpdated:1,ledgerEntryRemoved:2,ledgerEntryState:3}),e.union("LedgerEntryChange",{switchOn:e.lookup("LedgerEntryChangeType"),switchName:"type",switches:[["ledgerEntryCreated","created"],["ledgerEntryUpdated","updated"],["ledgerEntryRemoved","removed"],["ledgerEntryState","state"]],arms:{created:e.lookup("LedgerEntry"),updated:e.lookup("LedgerEntry"),removed:e.lookup("LedgerKey"),state:e.lookup("LedgerEntry")}}),e.typedef("LedgerEntryChanges",e.varArray(e.lookup("LedgerEntryChange"),2147483647)),e.struct("OperationMeta",[["changes",e.lookup("LedgerEntryChanges")]]),e.struct("TransactionMetaV1",[["txChanges",e.lookup("LedgerEntryChanges")],["operations",e.varArray(e.lookup("OperationMeta"),2147483647)]]),e.union("TransactionMeta",{switchOn:e.int(),switchName:"v",switches:[[0,"operations"],[1,"v1"]],arms:{operations:e.varArray(e.lookup("OperationMeta"),2147483647),v1:e.lookup("TransactionMetaV1")}}),e.enum("ErrorCode",{errMisc:0,errDatum:1,errConf:2,errAuth:3,errLoad:4}),e.struct("Error",[["code",e.lookup("ErrorCode")],["msg",e.string(100)]]),e.struct("AuthCert",[["pubkey",e.lookup("Curve25519Public")],["expiration",e.lookup("Uint64")],["sig",e.lookup("Signature")]]),e.struct("Hello",[["ledgerVersion",e.lookup("Uint32")],["overlayVersion",e.lookup("Uint32")],["overlayMinVersion",e.lookup("Uint32")],["networkId",e.lookup("Hash")],["versionStr",e.string(100)],["listeningPort",e.int()],["peerId",e.lookup("NodeId")],["cert",e.lookup("AuthCert")],["nonce",e.lookup("Uint256")]]),e.struct("Auth",[["unused",e.int()]]),e.enum("IpAddrType",{iPv4:0,iPv6:1}),e.union("PeerAddressIp",{switchOn:e.lookup("IpAddrType"),switchName:"type",switches:[["iPv4","ipv4"],["iPv6","ipv6"]],arms:{ipv4:e.opaque(4),ipv6:e.opaque(16)}}),e.struct("PeerAddress",[["ip",e.lookup("PeerAddressIp")],["port",e.lookup("Uint32")],["numFailures",e.lookup("Uint32")]]),e.enum("MessageType",{errorMsg:0,auth:2,dontHave:3,getPeer:4,peer:5,getTxSet:6,txSet:7,transaction:8,getScpQuorumset:9,scpQuorumset:10,scpMessage:11,getScpState:12,hello:13}),e.struct("DontHave",[["type",e.lookup("MessageType")],["reqHash",e.lookup("Uint256")]]),e.union("StellarMessage",{switchOn:e.lookup("MessageType"),switchName:"type",switches:[["errorMsg","error"],["hello","hello"],["auth","auth"],["dontHave","dontHave"],["getPeer",e.void()],["peer","peers"],["getTxSet","txSetHash"],["txSet","txSet"],["transaction","transaction"],["getScpQuorumset","qSetHash"],["scpQuorumset","qSet"],["scpMessage","envelope"],["getScpState","getScpLedgerSeq"]],arms:{error:e.lookup("Error"),hello:e.lookup("Hello"),auth:e.lookup("Auth"),dontHave:e.lookup("DontHave"),peers:e.varArray(e.lookup("PeerAddress"),100),txSetHash:e.lookup("Uint256"),txSet:e.lookup("TransactionSet"),transaction:e.lookup("TransactionEnvelope"),qSetHash:e.lookup("Uint256"),qSet:e.lookup("ScpQuorumSet"),envelope:e.lookup("StellarMessage"),getScpLedgerSeq:e.lookup("Uint32")}}),e.struct("AuthenticatedMessageV0",[["sequence",e.lookup("Uint64")],["message",e.lookup("StellarMessage")],["mac",e.lookup("HmacSha256Mac")]]),e.union("AuthenticatedMessage",{switchOn:e.lookup("Uint32"),switchName:"v",switches:[[0,"v0"]],arms:{v0:e.lookup("AuthenticatedMessageV0")}}),e.struct("DecoratedSignature",[["hint",e.lookup("SignatureHint")],["signature",e.lookup("Signature")]]),e.enum("OperationType",{createAccount:0,payment:1,pathPayment:2,manageOffer:3,createPassiveOffer:4,setOption:5,changeTrust:6,allowTrust:7,accountMerge:8,inflation:9,manageDatum:10,bumpSequence:11,createAsset:12,changeAsset:13,limitAsset:14,createContract:15,callContract:16,sendAsset:17,checkContract:18,testContract:19}),e.struct("CreateAccountOp",[["destination",e.lookup("AccountId")],["startingBalance",e.lookup("Int64")]]),e.struct("PaymentOp",[["destination",e.lookup("AccountId")],["asset",e.lookup("Asset")],["amount",e.lookup("Int64")]]),e.struct("PathPaymentOp",[["sendAsset",e.lookup("Asset")],["sendMax",e.lookup("Int64")],["destination",e.lookup("AccountId")],["destAsset",e.lookup("Asset")],["destAmount",e.lookup("Int64")],["path",e.varArray(e.lookup("Asset"),5)]]),e.struct("ManageOfferOp",[["selling",e.lookup("Asset")],["buying",e.lookup("Asset")],["amount",e.lookup("Int64")],["price",e.lookup("Price")],["offerId",e.lookup("Uint64")]]),e.struct("CreatePassiveOfferOp",[["selling",e.lookup("Asset")],["buying",e.lookup("Asset")],["amount",e.lookup("Int64")],["price",e.lookup("Price")]]),e.struct("SetOptionsOp",[["inflationDest",e.option(e.lookup("AccountId"))],["clearFlags",e.option(e.lookup("Uint32"))],["setFlags",e.option(e.lookup("Uint32"))],["masterWeight",e.option(e.lookup("Uint32"))],["lowThreshold",e.option(e.lookup("Uint32"))],["medThreshold",e.option(e.lookup("Uint32"))],["highThreshold",e.option(e.lookup("Uint32"))],["homeDomain",e.option(e.lookup("String32"))],["signer",e.option(e.lookup("Signer"))]]),e.struct("ChangeTrustOp",[["line",e.lookup("Asset")],["limit",e.lookup("Int64")]]),e.union("AllowTrustOpAsset",{switchOn:e.lookup("AssetType"),switchName:"type",switches:[["assetTypeCreditAlphanum4","assetCode4"],["assetTypeCreditAlphanum12","assetCode12"]],arms:{assetCode4:e.opaque(4),assetCode12:e.opaque(12)}}),e.struct("AllowTrustOp",[["trustor",e.lookup("AccountId")],["asset",e.lookup("AllowTrustOpAsset")],["authorize",e.bool()]]),e.struct("ManageDataOp",[["dataName",e.lookup("String64")],["dataValue",e.option(e.lookup("DataValue"))]]),e.struct("BumpSequenceOp",[["bumpTo",e.lookup("SequenceNumber")]]),e.struct("CreateAssetOp",[["asset",e.lookup("Asset")],["beneficiary",e.lookup("String64")],["fee",e.lookup("Uint32")],["ratio",e.lookup("Uint32")],["minfee",e.lookup("Int64")]]),e.struct("ChangeAssetOp",[["asset",e.lookup("Asset")],["beneficiary",e.lookup("String64")]]),e.struct("LimitAssetOp",[["asset",e.lookup("Asset")],["islimited",e.lookup("Uint32")]]),e.struct("CreateContractOp",[["contractId",e.lookup("String64")],["startingBalance",e.lookup("Int64")],["contractAddr",e.lookup("ContractAddr")],["data",e.lookup("ContractInput")],["state",e.lookup("StateString")],["fileHash",e.lookup("String64")],["errFlag",e.lookup("Int32")]]),e.struct("SendAssetOp",[["contractId",e.lookup("ContractId")],["asset",e.lookup("Asset")],["amount",e.lookup("Int64")],["state",e.lookup("StateString")],["errFlag",e.lookup("Int32")]]),e.struct("CheckContractOp",[["isContract",e.lookup("Uint32")]]),e.struct("TestContractOp",[["startingBalance",e.lookup("Uint32")]]),e.struct("Check",[["sourceAccId",e.lookup("AccountId")],["amount",e.lookup("Int64")],["op",e.lookup("String32")]]),e.struct("Invoke",[["newState",e.lookup("StateString")]]),e.struct("Query",[["data",e.lookup("StateString")]]),e.struct("Transfer",[["destination",e.lookup("AccountId")],["asset",e.lookup("Asset")],["amount",e.lookup("Int64")]]),e.enum("ContrOperationType",{check:0,invoke:1,query:2,transfer:3}),e.union("ContrOperationBody",{switchOn:e.lookup("ContrOperationType"),switchName:"type",switches:[["check","check"],["invoke","invoke"],["query","query"],["transfer","transfer"]],arms:{check:e.lookup("Check"),invoke:e.lookup("Invoke"),query:e.lookup("Query"),transfer:e.lookup("Transfer")}}),e.struct("ContrOperation",[["body",e.lookup("ContrOperationBody")]]),e.struct("CallContractOp",[["contractId",e.lookup("ContractId")],["data",e.lookup("ContractInput")],["contrOps",e.varArray(e.lookup("ContrOperation"),100)],["errFlag",e.lookup("Int32")]]),e.union("OperationBody",{switchOn:e.lookup("OperationType"),switchName:"type",switches:[["createAccount","createAccountOp"],["payment","paymentOp"],["pathPayment","pathPaymentOp"],["manageOffer","manageOfferOp"],["createPassiveOffer","createPassiveOfferOp"],["setOption","setOptionsOp"],["changeTrust","changeTrustOp"],["allowTrust","allowTrustOp"],["accountMerge","destination"],["inflation",e.void()],["manageDatum","manageDataOp"],["bumpSequence","bumpSequenceOp"],["createAsset","createAssetOp"],["changeAsset","changeAssetOp"],["limitAsset","limitAssetOp"],["createContract","createContractOp"],["callContract","callContractOp"],["sendAsset","sendAssetOp"],["checkContract","checkContractOp"],["testContract","testContractOp"]],arms:{createAccountOp:e.lookup("CreateAccountOp"),paymentOp:e.lookup("PaymentOp"),pathPaymentOp:e.lookup("PathPaymentOp"),manageOfferOp:e.lookup("ManageOfferOp"),createPassiveOfferOp:e.lookup("CreatePassiveOfferOp"),setOptionsOp:e.lookup("SetOptionsOp"),changeTrustOp:e.lookup("ChangeTrustOp"),allowTrustOp:e.lookup("AllowTrustOp"),destination:e.lookup("AccountId"),manageDataOp:e.lookup("ManageDataOp"),bumpSequenceOp:e.lookup("BumpSequenceOp"),createAssetOp:e.lookup("CreateAssetOp"),changeAssetOp:e.lookup("ChangeAssetOp"),limitAssetOp:e.lookup("LimitAssetOp"),createContractOp:e.lookup("CreateContractOp"),callContractOp:e.lookup("CallContractOp"),sendAssetOp:e.lookup("SendAssetOp"),checkContractOp:e.lookup("CheckContractOp"),testContractOp:e.lookup("TestContractOp")}}),e.struct("Operation",[["sourceAccount",e.option(e.lookup("AccountId"))],["body",e.lookup("OperationBody")]]),e.enum("MemoType",{memoNone:0,memoText:1,memoId:2,memoHash:3,memoReturn:4}),e.union("Memo",{switchOn:e.lookup("MemoType"),switchName:"type",switches:[["memoNone",e.void()],["memoText","text"],["memoId","id"],["memoHash","hash"],["memoReturn","retHash"]],arms:{text:e.string(28),id:e.lookup("Uint64"),hash:e.lookup("Hash"),retHash:e.lookup("Hash")}}),e.struct("TimeBounds",[["minTime",e.lookup("Uint64")],["maxTime",e.lookup("Uint64")]]),e.union("TransactionV1Ext",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("TransactionV1",[["txOldBody",e.lookup("TxOldBody")],["ext",e.lookup("TransactionV1Ext")]]),e.union("TransactionExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()],[1,"v1"]],arms:{v1:e.lookup("TransactionV1")}}),e.struct("Transaction",[["sourceAccount",e.lookup("AccountId")],["fee",e.lookup("Uint32")],["seqNum",e.lookup("SequenceNumber")],["timeBounds",e.option(e.lookup("TimeBounds"))],["memo",e.lookup("Memo")],["operations",e.varArray(e.lookup("Operation"),100)],["ext",e.lookup("TransactionExt")]]),e.union("TransactionSignaturePayloadTaggedTransaction",{switchOn:e.lookup("EnvelopeType"),switchName:"type",switches:[["envelopeTypeTx","tx"]],arms:{tx:e.lookup("Transaction")}}),e.struct("TransactionSignaturePayload",[["networkId",e.lookup("Hash")],["taggedTransaction",e.lookup("TransactionSignaturePayloadTaggedTransaction")]]),e.struct("TransactionEnvelope",[["tx",e.lookup("Transaction")],["signatures",e.varArray(e.lookup("DecoratedSignature"),20)]]),e.struct("ClaimOfferAtom",[["sellerId",e.lookup("AccountId")],["offerId",e.lookup("Uint64")],["assetSold",e.lookup("Asset")],["amountSold",e.lookup("Int64")],["assetBought",e.lookup("Asset")],["amountBought",e.lookup("Int64")]]),e.enum("CreateAccountResultCode",{createAccountSuccess:0,createAccountMalformed:-1,createAccountUnderfunded:-2,createAccountLowReserve:-3,createAccountAlreadyExist:-4}),e.union("CreateAccountResult",{switchOn:e.lookup("CreateAccountResultCode"),switchName:"code",switches:[["createAccountSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("PaymentResultCode",{paymentSuccess:0,paymentMalformed:-1,paymentUnderfunded:-2,paymentSrcNoTrust:-3,paymentSrcNotAuthorized:-4,paymentNoDestination:-5,paymentNoTrust:-6,paymentNotAuthorized:-7,paymentLineFull:-8,paymentNoIssuer:-9,paymentAssetStopIssuing:-10}),e.union("PaymentResult",{switchOn:e.lookup("PaymentResultCode"),switchName:"code",switches:[["paymentSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("PathPaymentResultCode",{pathPaymentSuccess:0,pathPaymentMalformed:-1,pathPaymentUnderfunded:-2,pathPaymentSrcNoTrust:-3,pathPaymentSrcNotAuthorized:-4,pathPaymentNoDestination:-5,pathPaymentNoTrust:-6,pathPaymentNotAuthorized:-7,pathPaymentLineFull:-8,pathPaymentNoIssuer:-9,pathPaymentTooFewOffer:-10,pathPaymentOfferCrossSelf:-11,pathPaymentOverSendmax:-12,pathPaymentAssetStopIssuing:-13}),e.struct("SimplePaymentResult",[["destination",e.lookup("AccountId")],["asset",e.lookup("Asset")],["amount",e.lookup("Int64")]]),e.struct("PathPaymentResultSuccess",[["offers",e.varArray(e.lookup("ClaimOfferAtom"),2147483647)],["last",e.lookup("SimplePaymentResult")]]),e.union("PathPaymentResult",{switchOn:e.lookup("PathPaymentResultCode"),switchName:"code",switches:[["pathPaymentSuccess","success"],["pathPaymentNoIssuer","noIssuer"]],arms:{success:e.lookup("PathPaymentResultSuccess"),noIssuer:e.lookup("Asset")},defaultArm:e.void()}),e.enum("ManageOfferResultCode",{manageOfferSuccess:0,manageOfferMalformed:-1,manageOfferSellNoTrust:-2,manageOfferBuyNoTrust:-3,manageOfferSellNotAuthorized:-4,manageOfferBuyNotAuthorized:-5,manageOfferLineFull:-6,manageOfferUnderfunded:-7,manageOfferCrossSelf:-8,manageOfferSellNoIssuer:-9,manageOfferBuyNoIssuer:-10,manageOfferNotFound:-11,manageOfferLowReserve:-12}),e.enum("ManageOfferEffect",{manageOfferCreated:0,manageOfferUpdated:1,manageOfferDeleted:2}),e.union("ManageOfferSuccessResultOffer",{switchOn:e.lookup("ManageOfferEffect"),switchName:"effect",switches:[["manageOfferCreated","offer"],["manageOfferUpdated","offer"]],arms:{offer:e.lookup("OfferEntry")},defaultArm:e.void()}),e.struct("ManageOfferSuccessResult",[["offersClaimed",e.varArray(e.lookup("ClaimOfferAtom"),2147483647)],["offer",e.lookup("ManageOfferSuccessResultOffer")]]),e.union("ManageOfferResult",{switchOn:e.lookup("ManageOfferResultCode"),switchName:"code",switches:[["manageOfferSuccess","success"]],arms:{success:e.lookup("ManageOfferSuccessResult")},defaultArm:e.void()}),e.enum("SetOptionsResultCode",{setOptionsSuccess:0,setOptionsLowReserve:-1,setOptionsTooManySigner:-2,setOptionsBadFlag:-3,setOptionsInvalidInflation:-4,setOptionsCantChange:-5,setOptionsUnknownFlag:-6,setOptionsThresholdOutOfRange:-7,setOptionsBadSigner:-8,setOptionsInvalidHomeDomain:-9}),e.union("SetOptionsResult",{switchOn:e.lookup("SetOptionsResultCode"),switchName:"code",switches:[["setOptionsSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("ChangeTrustResultCode",{changeTrustSuccess:0,changeTrustMalformed:-1,changeTrustNoIssuer:-2,changeTrustInvalidLimit:-3,changeTrustLowReserve:-4,changeTrustSelfNotAllowed:-5,changeTrustNoNewAsset:-6}),e.union("ChangeTrustResult",{switchOn:e.lookup("ChangeTrustResultCode"),switchName:"code",switches:[["changeTrustSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("AllowTrustResultCode",{allowTrustSuccess:0,allowTrustMalformed:-1,allowTrustNoTrustLine:-2,allowTrustTrustNotRequired:-3,allowTrustCantRevoke:-4,allowTrustSelfNotAllowed:-5}),e.union("AllowTrustResult",{switchOn:e.lookup("AllowTrustResultCode"),switchName:"code",switches:[["allowTrustSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("AccountMergeResultCode",{accountMergeSuccess:0,accountMergeMalformed:-1,accountMergeNoAccount:-2,accountMergeImmutableSet:-3,accountMergeHasSubEntry:-4,accountMergeSeqnumTooFar:-5,accountMergeDestFull:-6}),e.union("AccountMergeResult",{switchOn:e.lookup("AccountMergeResultCode"),switchName:"code",switches:[["accountMergeSuccess","sourceAccountBalance"]],arms:{sourceAccountBalance:e.lookup("Int64")},defaultArm:e.void()}),e.enum("InflationResultCode",{inflationSuccess:0,inflationNotTime:-1}),e.struct("InflationPayout",[["destination",e.lookup("AccountId")],["amount",e.lookup("Int64")]]),e.union("InflationResult",{switchOn:e.lookup("InflationResultCode"),switchName:"code",switches:[["inflationSuccess","payouts"]],arms:{payouts:e.varArray(e.lookup("InflationPayout"),2147483647)},defaultArm:e.void()}),e.enum("ManageDataResultCode",{manageDataSuccess:0,manageDataNotSupportedYet:-1,manageDataNameNotFound:-2,manageDataLowReserve:-3,manageDataInvalidName:-4}),e.union("ManageDataResult",{switchOn:e.lookup("ManageDataResultCode"),switchName:"code",switches:[["manageDataSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("BumpSequenceResultCode",{bumpSequenceSuccess:0,bumpSequenceBadSeq:-1}),e.union("BumpSequenceResult",{switchOn:e.lookup("BumpSequenceResultCode"),switchName:"code",switches:[["bumpSequenceSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("CreateAssetResultCode",{createAssetSuccess:0,createAssetMalformed:-1,createAssetNoIssuer:-2,createAssetAssetExist:-3,createAssetNoBeneficiary:-4,createAssetTrustSelf:-5,createAssetIssuerDiffSigner:-6,createAssetUnderfunded:-7}),e.union("CreateAssetResult",{switchOn:e.lookup("CreateAssetResultCode"),switchName:"code",switches:[["createAssetSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("ChangeAssetResultCode",{changeAssetSuccess:0,changeAssetMalformed:-1,changeAssetAssetNoExist:-2,changeAssetNoBeneficiary:-3,changeAssetTrustSelf:-4,changeAssetIssuerDiffSigner:-5}),e.union("ChangeAssetResult",{switchOn:e.lookup("ChangeAssetResultCode"),switchName:"code",switches:[["changeAssetSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("LimitAssetResultCode",{limitAssetSuccess:0,limitAssetMalformed:-1,limitAssetAssetNoExist:-2,limitAssetIssuerDiffSigner:-3,limitAssetAssetStopIssuing:-4}),e.union("LimitAssetResult",{switchOn:e.lookup("LimitAssetResultCode"),switchName:"code",switches:[["limitAssetSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("CreateContractResultCode",{createContractSuccess:0,createContractMalformed:-1,createContractUnderfunded:-2,createContractLowReserve:-3,createContractAlreadyExist:-4,createContractDockerCannotDownload:-5,createContractDockerInvalidContractFile:-6,createContractDockerCannotExe:-7,createContractDockerInvalidJson:-8,createContractDockerInvalidEnv:-9,createContractDockerInvalidCondition:-10,createContractStateEmpty:-11}),e.union("CreateContractResult",{switchOn:e.lookup("CreateContractResultCode"),switchName:"code",switches:[["createContractSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("SendAssetResultCode",{sendAssetSuccess:0,sendAssetMalformed:-1,sendAssetUnderfunded:-2,sendAssetSrcNoTrust:-3,sendAssetSrcNotAuthorized:-4,sendAssetNoDestination:-5,sendAssetNoTrust:-6,sendAssetNotAuthorized:-7,sendAssetLineFull:-8,sendAssetNoIssuer:-9,sendAssetAssetStopIssuing:-10,sendAssetNoContractState:-11,sendAssetStateEmpty:-12,sendAssetDockerCannotDownload:-13,sendAssetDockerInvalidContractFile:-14,sendAssetDockerCannotExe:-15,sendAssetDockerInvalidJson:-16,sendAssetDockerInvalidEnv:-17,sendAssetDockerInvalidCondition:-18}),e.union("SendAssetResult",{switchOn:e.lookup("SendAssetResultCode"),switchName:"code",switches:[["sendAssetSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("CallContractResultCode",{callContractSuccess:0,callContractMalformed:-1,callContractNoContractState:-2,callContractCheckAmount:-3,callContractUnderfunded:-4,callContractSrcNoTrust:-5,callContractSrcNotAuthorized:-6,callContractNoDestination:-7,callContractNoTrust:-8,callContractNotAuthorized:-9,callContractLineFull:-10,callContractNoIssuer:-11,callContractOverSendmax:-12,callContractStateEmpty:-13,callContractDockerCannotDownload:-14,callContractDockerInvalidContractFile:-15,callContractDockerCannotExe:-16,callContractDockerInvalidJson:-17,callContractDockerInvalidEnv:-18,callContractDockerInvalidCondition:-19,callContractAssetStopIssuing:-20}),e.union("CallContractResult",{switchOn:e.lookup("CallContractResultCode"),switchName:"code",switches:[["callContractSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("CheckContractResultCode",{checkContractSuccess:0,checkContractMalformed:-1}),e.enum("TestContractResultCode",{testContractSuccess:0,testContractMalformed:-1}),e.union("CheckContractResult",{switchOn:e.lookup("CheckContractResultCode"),switchName:"code",switches:[["checkContractSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.union("TestContractResult",{switchOn:e.lookup("TestContractResultCode"),switchName:"code",switches:[["testContractSuccess",e.void()]],arms:{},defaultArm:e.void()}),e.enum("OperationResultCode",{opInner:0,opBadAuth:-1,opNoAccount:-2,opNotSupported:-3}),e.union("OperationResultTr",{switchOn:e.lookup("OperationType"),switchName:"type",switches:[["createAccount","createAccountResult"],["payment","paymentResult"],["pathPayment","pathPaymentResult"],["manageOffer","manageOfferResult"],["createPassiveOffer","createPassiveOfferResult"],["setOption","setOptionsResult"],["changeTrust","changeTrustResult"],["allowTrust","allowTrustResult"],["accountMerge","accountMergeResult"],["inflation","inflationResult"],["manageDatum","manageDataResult"],["bumpSequence","bumpSeqResult"],["createAsset","createAssetResult"],["changeAsset","changeAssetResult"],["limitAsset","limitAssetResult"],["createContract","createContractResult"],["callContract","callContractResult"],["sendAsset","sendAssetResult"],["checkContract","checkContractResult"],["testContract","testContractResult"]],arms:{createAccountResult:e.lookup("CreateAccountResult"),paymentResult:e.lookup("PaymentResult"),pathPaymentResult:e.lookup("PathPaymentResult"),manageOfferResult:e.lookup("ManageOfferResult"),createPassiveOfferResult:e.lookup("ManageOfferResult"),setOptionsResult:e.lookup("SetOptionsResult"),changeTrustResult:e.lookup("ChangeTrustResult"),allowTrustResult:e.lookup("AllowTrustResult"),accountMergeResult:e.lookup("AccountMergeResult"),inflationResult:e.lookup("InflationResult"),manageDataResult:e.lookup("ManageDataResult"),bumpSeqResult:e.lookup("BumpSequenceResult"),createAssetResult:e.lookup("CreateAssetResult"),changeAssetResult:e.lookup("ChangeAssetResult"),limitAssetResult:e.lookup("LimitAssetResult"),createContractResult:e.lookup("CreateContractResult"),callContractResult:e.lookup("CallContractResult"),sendAssetResult:e.lookup("SendAssetResult"),checkContractResult:e.lookup("CheckContractResult"),testContractResult:e.lookup("TestContractResult")}}),e.union("OperationResult",{switchOn:e.lookup("OperationResultCode"),switchName:"code",switches:[["opInner","tr"]],arms:{tr:e.lookup("OperationResultTr")},defaultArm:e.void()}),e.enum("TransactionResultCode",{txSuccess:0,txFailed:-1,txTooEarly:-2,txTooLate:-3,txMissingOperation:-4,txBadSeq:-5,txBadAuth:-6,txInsufficientBalance:-7,txNoAccount:-8,txInsufficientFee:-9,txBadAuthExtra:-10,txInternalError:-11}),e.union("TransactionResultResult",{switchOn:e.lookup("TransactionResultCode"),switchName:"code",switches:[["txSuccess","results"],["txFailed","results"]],arms:{results:e.varArray(e.lookup("OperationResult"),2147483647)},defaultArm:e.void()}),e.union("TransactionResultExt",{switchOn:e.int(),switchName:"v",switches:[[0,e.void()]],arms:{}}),e.struct("TransactionResult",[["feeCharged",e.lookup("Int64")],["result",e.lookup("TransactionResultResult")],["ext",e.lookup("TransactionResultExt")]]),e.typedef("Hash",e.opaque(32)),e.typedef("Uint256",e.opaque(32)),e.typedef("Uint32",e.uint()),e.typedef("Int32",e.int()),e.typedef("Uint64",e.uhyper()),e.typedef("Int64",e.hyper()),e.enum("CryptoKeyType",{keyTypeEd25519:0,keyTypePreAuthTx:1,keyTypeHashX:2,keyTypePreContract:3}),e.enum("PublicKeyType",{publicKeyTypeEd25519:0,publicKeyTypeContract:3}),e.enum("SignerKeyType",{signerKeyTypeEd25519:0,signerKeyTypePreAuthTx:1,signerKeyTypeHashX:2,signerKeyTypePreContract:3}),e.union("PublicKey",{switchOn:e.lookup("PublicKeyType"),switchName:"type",switches:[["publicKeyTypeEd25519","ed25519"],["publicKeyTypeContract","contract"]],arms:{ed25519:e.lookup("Uint256"),contract:e.lookup("Uint256")}}),e.union("SignerKey",{switchOn:e.lookup("SignerKeyType"),switchName:"type",switches:[["signerKeyTypeEd25519","ed25519"],["signerKeyTypePreAuthTx","preAuthTx"],["signerKeyTypeHashX","hashX"],["signerKeyTypePreContract","contract"]],arms:{ed25519:e.lookup("Uint256"),preAuthTx:e.lookup("Uint256"),hashX:e.lookup("Uint256"),contract:e.lookup("Uint256")}}),e.typedef("Signature",e.varOpaque(64)),e.typedef("SignatureHint",e.opaque(4)),e.typedef("NodeId",e.lookup("PublicKey")),e.struct("Curve25519Secret",[["key",e.opaque(32)]]),e.struct("Curve25519Public",[["key",e.opaque(32)]]),e.struct("HmacSha256Key",[["key",e.opaque(32)]]),e.struct("HmacSha256Mac",[["mac",e.opaque(32)]])
});t.default=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(243);Object.keys(n).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return n[e]}})});var o=r(332);Object.keys(o).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return o[e]}})})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(244);Object.keys(n).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return n[e]}})});var o=r(301);Object.keys(o).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return o[e]}})});var i=r(304);Object.keys(i).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return i[e]}})});var a=r(305);Object.keys(a).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return a[e]}})});var s=r(306);Object.keys(s).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return s[e]}})});var u=r(307);Object.keys(u).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return u[e]}})});var c=r(308);Object.keys(c).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return c[e]}})});var f=r(309);Object.keys(f).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return f[e]}})});var l=r(311);Object.keys(l).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return l[e]}})});var h=r(312);Object.keys(h).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return h[e]}})});var p=r(313);Object.keys(p).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return p[e]}})});var d=r(314);Object.keys(d).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return d[e]}})});var y=r(320);Object.keys(y).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return y[e]}})});var v=r(321);Object.keys(v).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return v[e]}})});var g=r(322);Object.keys(g).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return g[e]}})});var m=r(323);Object.keys(m).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return m[e]}})});var b=r(326);Object.keys(b).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return b[e]}})});var w=r(331);Object.keys(w).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return w[e]}})})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Int=void 0;var o=r(245),i=n(o),a=r(246),s=n(a),u=t.Int={read:function(e){return e.readInt32BE()},write:function(e,t){if(!i.default(e))throw new Error("XDR Write Error: not a number");if(Math.floor(e)!==e)throw new Error("XDR Write Error: not an integer");t.writeInt32BE(e)},isValid:function(e){return i.default(e)?Math.floor(e)!==e?!1:e>=u.MIN_VALUE&&e<=u.MAX_VALUE:!1}};u.MAX_VALUE=Math.pow(2,31)-1,u.MIN_VALUE=-Math.pow(2,31),s.default(u)},function(e,t,r){function n(e){return"number"==typeof e||i(e)&&o(e)==a}var o=r(24),i=r(61),a="[object Number]";e.exports=n},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e){a.default(e,l),u.default(e)&&a.default(e.prototype,h)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var i=r(247),a=n(i),s=r(23),u=n(s),c=r(258),f=Math.pow(2,16),l={toXDR:function(e){var t=new c.Cursor(f);this.write(e,t);var r=t.tell();return t.rewind(),t.slice(r).buffer()},fromXDR:function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"raw",n=void 0;switch(r){case"raw":n=t;break;case"hex":n=e.from(t,"hex");break;case"base64":n=e.from(t,"base64");break;default:throw new Error("Invalid format "+r+', must be "raw", "hex", "base64"')}var o=new c.Cursor(n),i=this.read(o);return i}},h={toXDR:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"raw",t=this.constructor.toXDR(this);switch(e){case"raw":return t;case"hex":return t.toString("hex");case"base64":return t.toString("base64");default:throw new Error("Invalid format "+e+', must be "raw", "hex", "base64"')}}}}).call(t,r(156).Buffer)},function(e,t,r){e.exports=r(248)},function(e,t,r){var n=r(55),o=r(249),i=r(78),a=o(function(e,t){n(t,i(t),e)});e.exports=a},function(e,t,r){function n(e){return o(function(t,r){var n=-1,o=r.length,a=o>1?r[o-1]:void 0,s=o>2?r[2]:void 0;for(a=e.length>3&&"function"==typeof a?(o--,a):void 0,s&&i(r[0],r[1],s)&&(a=3>o?void 0:a,o=1),t=Object(t);++n<o;){var u=r[n];u&&e(t,u,n,a)}return t})}var o=r(250),i=r(257);e.exports=n},function(e,t,r){function n(e,t){return a(i(e,t,o),e+"")}var o=r(123),i=r(251),a=r(253);e.exports=n},function(e,t,r){function n(e,t,r){return t=i(void 0===t?e.length-1:t,0),function(){for(var n=arguments,a=-1,s=i(n.length-t,0),u=Array(s);++a<s;)u[a]=n[t+a];a=-1;for(var c=Array(t+1);++a<t;)c[a]=n[a];return c[t]=r(u),o(e,this,c)}}var o=r(252),i=Math.max;e.exports=n},function(e){function t(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}e.exports=t},function(e,t,r){var n=r(254),o=r(256),i=o(n);e.exports=i},function(e,t,r){var n=r(255),o=r(53),i=r(123),a=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:n(t),writable:!0})}:i;e.exports=a},function(e){function t(e){return function(){return e}}e.exports=t},function(e){function t(e){var t=0,i=0;return function(){var a=o(),s=n-(a-i);if(i=a,s>0){if(++t>=r)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var r=800,n=16,o=Date.now;e.exports=t},function(e,t,r){function n(e,t,r){if(!s(r))return!1;var n=typeof t;return("number"==n?i(r)&&a(t,r.length):"string"==n&&t in r)?o(r[t],e):!1}var o=r(11),i=r(76),a=r(66),s=r(30);e.exports=n},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.Cursor=void 0;{var s=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),u=r(259),c=n(u),f=r(260);t.Cursor=function(t){function r(){return o(this,r),i(this,(r.__proto__||Object.getPrototypeOf(r)).apply(this,arguments))}return a(r,t),s(r,[{key:"writeBufferPadded",value:function(t){var n=f.calculatePadding(t.length),o=e.alloc(n);return this.copyFrom(new r(t)).copyFrom(new r(o))}}]),r}(c.default)}}).call(t,r(156).Buffer)},function(e,t,r){(function(t){var n=function(e){return this instanceof n?(e instanceof t||(e=new t(e)),this._setBuffer(e),this.rewind(),void 0):new n(e)};n.prototype._setBuffer=function(e){this._buffer=e,this.length=e.length},n.prototype.buffer=function(){return this._buffer},n.prototype.tap=function(e){return e(this),this},n.prototype.clone=function(e){var t=new this.constructor(this.buffer());return t.seek(0===arguments.length?this.tell():e),t},n.prototype.tell=function(){return this._index},n.prototype.seek=function(e,t){return 1==arguments.length&&(t=e,e="="),"+"==e?this._index+=t:"-"==e?this._index-=t:this._index=t,this},n.prototype.rewind=function(){return this.seek(0)},n.prototype.eof=function(){return this.tell()==this.buffer().length},n.prototype.write=function(e,t,r){return this.seek("+",this.buffer().write(e,this.tell(),t,r))},n.prototype.fill=function(e,t){return 1==arguments.length&&(t=this.buffer().length-this.tell()),this.buffer().fill(e,this.tell(),this.tell()+t),this.seek("+",t),this},n.prototype.slice=function(e){0===arguments.length&&(e=this.length-this.tell());var t=new this.constructor(this.buffer().slice(this.tell(),this.tell()+e));return this.seek("+",e),t},n.prototype.copyFrom=function(e){var r=e instanceof t?e:e.buffer();return r.copy(this.buffer(),this.tell(),0,r.length),this.seek("+",r.length),this},n.prototype.concat=function(e){for(var r in e)e[r]instanceof n&&(e[r]=e[r].buffer());e.unshift(this.buffer());var o=t.concat(e);return this._setBuffer(o),this},n.prototype.toString=function(e,t){0===arguments.length?(e="utf8",t=this.buffer().length-this.tell()):1===arguments.length&&(t=this.buffer().length-this.tell());var r=this.buffer().toString(e,this.tell(),this.tell()+t);return this.seek("+",t),r},[[1,["readInt8","readUInt8"]],[2,["readInt16BE","readInt16LE","readUInt16BE","readUInt16LE"]],[4,["readInt32BE","readInt32LE","readUInt32BE","readUInt32LE","readFloatBE","readFloatLE"]],[8,["readDoubleBE","readDoubleLE"]]].forEach(function(e){e[1].forEach(function(t){n.prototype[t]=function(){var r=this.buffer()[t](this.tell());return this.seek("+",e[0]),r}})}),[[1,["writeInt8","writeUInt8"]],[2,["writeInt16BE","writeInt16LE","writeUInt16BE","writeUInt16LE"]],[4,["writeInt32BE","writeInt32LE","writeUInt32BE","writeUInt32LE","writeFloatBE","writeFloatLE"]],[8,["writeDoubleBE","writeDoubleLE"]]].forEach(function(e){e[1].forEach(function(t){n.prototype[t]=function(r){return r=this.buffer()[t](r,this.tell()),this.seek("+",e[0]),this}})}),n.extend=function(e,t){var n=this;1===arguments.length&&(t=e,e=null),t=t||{},e=e||function(t){return this instanceof e?(n.call(this,t),void 0):new e(t)},r(199).inherits(e,n),e.extend=n.extend,e.define=n.define;for(var o in t)e.define(o,t[o]);return e},n.define=function(e,t){var r=this.prototype[e];this.prototype[e]=r&&function(){return this.__super=r,t.apply(this,arguments)}||t},e.exports=n}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e){switch(e%4){case 0:return 0;case 1:return 3;case 2:return 2;case 3:return 1;default:return null}}function i(e,t){var r=e.slice(t),n=s.default(r.buffer(),function(e){return 0===e});if(n!==!0)throw new Error("XDR Read Error: invalid padding")}Object.defineProperty(t,"__esModule",{value:!0}),t.calculatePadding=o,t.slicePadding=i;var a=r(261),s=n(a)},function(e,t,r){function n(e,t,r){var n=s(e)?o:i;return r&&u(e,t,r)&&(t=void 0),n(e,a(t,3))}var o=r(262),i=r(263),a=r(264),s=r(62),u=r(257);e.exports=n},function(e){function t(e,t){for(var r=-1,n=null==e?0:e.length;++r<n;)if(!t(e[r],r,e))return!1;return!0}e.exports=t},function(e,t,r){function n(e,t){var r=!0;return o(e,function(e,n,o){return r=!!t(e,n,o)}),r}var o=r(117);e.exports=n},function(e,t,r){function n(e){return"function"==typeof e?e:null==e?a:"object"==typeof e?s(e)?i(e[0],e[1]):o(e):u(e)}var o=r(265),i=r(282),a=r(123),s=r(62),u=r(298);e.exports=n},function(e,t,r){function n(e){var t=i(e);return 1==t.length&&t[0][2]?a(t[0][0],t[0][1]):function(r){return r===e||o(r,e,t)}}var o=r(266),i=r(279),a=r(281);e.exports=n},function(e,t,r){function n(e,t,r,n){var u=r.length,c=u,f=!n;if(null==e)return!c;for(e=Object(e);u--;){var l=r[u];if(f&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++u<c;){l=r[u];var h=l[0],p=e[h],d=l[1];if(f&&l[2]){if(void 0===p&&!(h in e))return!1}else{var y=new o;if(n)var v=n(p,d,h,e,t,y);if(!(void 0===v?i(d,p,a|s,n,y):v))return!1}}return!0}var o=r(6),i=r(267),a=1,s=2;e.exports=n},function(e,t,r){function n(e,t,r,a,s){return e===t?!0:null==e||null==t||!i(e)&&!i(t)?e!==e&&t!==t:o(e,t,r,a,n,s)}var o=r(268),i=r(61);e.exports=n},function(e,t,r){function n(e,t,r,n,v,m){var b=c(e),w=c(t),_=b?d:u(e),k=w?d:u(t);_=_==p?y:_,k=k==p?y:k;var A=_==y,O=k==y,E=_==k;if(E&&f(e)){if(!f(t))return!1;b=!0,A=!1}if(E&&!A)return m||(m=new o),b||l(e)?i(e,t,r,n,v,m):a(e,t,_,r,n,v,m);if(!(r&h)){var S=A&&g.call(e,"__wrapped__"),x=O&&g.call(t,"__wrapped__");if(S||x){var C=S?e.value():e,P=x?t.value():t;return m||(m=new o),v(C,P,r,n,m)}}return E?(m||(m=new o),s(e,t,r,n,v,m)):!1}var o=r(6),i=r(269),a=r(275),s=r(278),u=r(94),c=r(62),f=r(63),l=r(67),h=1,p="[object Arguments]",d="[object Array]",y="[object Object]",v=Object.prototype,g=v.hasOwnProperty;e.exports=n},function(e,t,r){function n(e,t,r,n,c,f){var l=r&s,h=e.length,p=t.length;if(h!=p&&!(l&&p>h))return!1;var d=f.get(e);if(d&&f.get(t))return d==t;var y=-1,v=!0,g=r&u?new o:void 0;for(f.set(e,t),f.set(t,e);++y<h;){var m=e[y],b=t[y];if(n)var w=l?n(b,m,y,t,e,f):n(m,b,y,e,t,f);if(void 0!==w){if(w)continue;v=!1;break}if(g){if(!i(t,function(e,t){return a(g,t)||m!==e&&!c(m,e,r,n,f)?void 0:g.push(t)})){v=!1;break}}else if(m!==b&&!c(m,b,r,n,f)){v=!1;break}}return f["delete"](e),f["delete"](t),v}var o=r(270),i=r(273),a=r(274),s=1,u=2;e.exports=n},function(e,t,r){function n(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new o;++t<r;)this.add(e[t])}var o=r(35),i=r(271),a=r(272);n.prototype.add=n.prototype.push=i,n.prototype.has=a,e.exports=n},function(e){function t(e){return this.__data__.set(e,r),this}var r="__lodash_hash_undefined__";e.exports=t},function(e){function t(e){return this.__data__.has(e)}e.exports=t},function(e){function t(e,t){for(var r=-1,n=null==e?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}e.exports=t},function(e){function t(e,t){return e.has(t)}e.exports=t},function(e,t,r){function n(e,t,r,n,o,A,E){switch(r){case k:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case _:return e.byteLength==t.byteLength&&A(new i(e),new i(t))?!0:!1;case h:case p:case v:return a(+e,+t);case d:return e.name==t.name&&e.message==t.message;case g:case b:return e==t+"";case y:var S=u;case m:var x=n&f;if(S||(S=c),e.size!=t.size&&!x)return!1;var C=E.get(e);if(C)return C==t;n|=l,E.set(e,t);var P=s(S(e),S(t),n,o,A,E);return E["delete"](e),P;case w:if(O)return O.call(e)==O.call(t)}return!1}var o=r(25),i=r(102),a=r(11),s=r(269),u=r(276),c=r(277),f=1,l=2,h="[object Boolean]",p="[object Date]",d="[object Error]",y="[object Map]",v="[object Number]",g="[object RegExp]",m="[object Set]",b="[object String]",w="[object Symbol]",_="[object ArrayBuffer]",k="[object DataView]",A=o?o.prototype:void 0,O=A?A.valueOf:void 0;e.exports=n},function(e){function t(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}e.exports=t},function(e){function t(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}e.exports=t},function(e,t,r){function n(e,t,r,n,a,u){var c=r&i,f=o(e),l=f.length,h=o(t),p=h.length;if(l!=p&&!c)return!1;for(var d=l;d--;){var y=f[d];if(!(c?y in t:s.call(t,y)))return!1}var v=u.get(e);if(v&&u.get(t))return v==t;var g=!0;u.set(e,t),u.set(t,e);for(var m=c;++d<l;){y=f[d];var b=e[y],w=t[y];if(n)var _=c?n(w,b,y,t,e,u):n(b,w,y,e,t,u);if(!(void 0===_?b===w||a(b,w,r,n,u):_)){g=!1;break}m||(m="constructor"==y)}if(g&&!m){var k=e.constructor,A=t.constructor;k!=A&&"constructor"in e&&"constructor"in t&&!("function"==typeof k&&k instanceof k&&"function"==typeof A&&A instanceof A)&&(g=!1)}return u["delete"](e),u["delete"](t),g}var o=r(91),i=1,a=Object.prototype,s=a.hasOwnProperty;e.exports=n},function(e,t,r){function n(e){for(var t=i(e),r=t.length;r--;){var n=t[r],a=e[n];t[r]=[n,a,o(a)]}return t}var o=r(280),i=r(56);e.exports=n},function(e,t,r){function n(e){return e===e&&!o(e)}var o=r(30);e.exports=n},function(e){function t(e,t){return function(r){return null==r?!1:r[e]===t&&(void 0!==t||e in Object(r))}}e.exports=t},function(e,t,r){function n(e,t){return s(e)&&u(t)?c(f(e),t):function(r){var n=i(r,e);return void 0===n&&n===t?a(r,e):o(t,n,l|h)}}var o=r(267),i=r(283),a=r(295),s=r(286),u=r(280),c=r(281),f=r(294),l=1,h=2;e.exports=n},function(e,t,r){function n(e,t,r){var n=null==e?void 0:o(e,t);return void 0===n?r:n}var o=r(284);e.exports=n},function(e,t,r){function n(e,t){t=o(t,e);for(var r=0,n=t.length;null!=e&&n>r;)e=e[i(t[r++])];return r&&r==n?e:void 0}var o=r(285),i=r(294);e.exports=n},function(e,t,r){function n(e,t){return o(e)?e:i(e,t)?[e]:a(s(e))}var o=r(62),i=r(286),a=r(288),s=r(291);e.exports=n},function(e,t,r){function n(e,t){if(o(e))return!1;var r=typeof e;return"number"==r||"symbol"==r||"boolean"==r||null==e||i(e)?!0:s.test(e)||!a.test(e)||null!=t&&e in Object(t)}var o=r(62),i=r(287),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,s=/^\w*$/;e.exports=n},function(e,t,r){function n(e){return"symbol"==typeof e||i(e)&&o(e)==a}var o=r(24),i=r(61),a="[object Symbol]";e.exports=n},function(e,t,r){var n=r(289),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g,a=n(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(o,function(e,r,n,o){t.push(n?o.replace(i,"$1"):r||e)}),t});e.exports=a},function(e,t,r){function n(e){var t=o(e,function(e){return r.size===i&&r.clear(),e}),r=t.cache;return t}var o=r(290),i=500;e.exports=n},function(e,t,r){function n(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError(i);var r=function(){var n=arguments,o=t?t.apply(this,n):n[0],i=r.cache;if(i.has(o))return i.get(o);var a=e.apply(this,n);return r.cache=i.set(o,a)||i,a};return r.cache=new(n.Cache||o),r}var o=r(35),i="Expected a function";n.Cache=o,e.exports=n},function(e,t,r){function n(e){return null==e?"":o(e)}var o=r(292);e.exports=n},function(e,t,r){function n(e){if("string"==typeof e)return e;if(a(e))return i(e,n)+"";if(s(e))return f?f.call(e):"";var t=e+"";return"0"==t&&1/e==-u?"-0":t}var o=r(25),i=r(293),a=r(62),s=r(287),u=1/0,c=o?o.prototype:void 0,f=c?c.toString:void 0;e.exports=n},function(e){function t(e,t){for(var r=-1,n=null==e?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}e.exports=t},function(e,t,r){function n(e){if("string"==typeof e||o(e))return e;var t=e+"";return"0"==t&&1/e==-i?"-0":t}var o=r(287),i=1/0;e.exports=n},function(e,t,r){function n(e,t){return null!=e&&i(e,t,o)}var o=r(296),i=r(297);e.exports=n},function(e){function t(e,t){return null!=e&&t in Object(e)}e.exports=t},function(e,t,r){function n(e,t,r){t=o(t,e);for(var n=-1,f=t.length,l=!1;++n<f;){var h=c(t[n]);if(!(l=null!=e&&r(e,h)))break;e=e[h]}return l||++n!=f?l:(f=null==e?0:e.length,!!f&&u(f)&&s(h,f)&&(a(e)||i(e)))}var o=r(285),i=r(59),a=r(62),s=r(66),u=r(69),c=r(294);e.exports=n},function(e,t,r){function n(e){return a(e)?o(s(e)):i(e)}var o=r(299),i=r(300),a=r(286),s=r(294);e.exports=n},function(e){function t(e){return function(t){return null==t?void 0:t[e]}}e.exports=t},function(e,t,r){function n(e){return function(t){return o(t,e)}}var o=r(284);e.exports=n},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.Hyper=void 0;var s=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),u=function d(e,t,r){null===e&&(e=Function.prototype);var n=Object.getOwnPropertyDescriptor(e,t);if(void 0===n){var o=Object.getPrototypeOf(e);return null===o?void 0:d(o,t,r)}if("value"in n)return n.value;var i=n.get;return void 0===i?void 0:i.call(r)},c=r(302),f=n(c),l=r(246),h=n(l),p=t.Hyper=function(e){function t(e,r){return o(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,r,!1))}return a(t,e),s(t,null,[{key:"read",value:function(e){var t=e.readInt32BE(),r=e.readInt32BE();return this.fromBits(r,t)}},{key:"write",value:function(e,t){if(!(e instanceof this))throw new Error("XDR Write Error: "+e+" is not a Hyper");t.writeInt32BE(e.high),t.writeInt32BE(e.low)}},{key:"fromString",value:function(e){if(!/^-?\d+$/.test(e))throw new Error("Invalid hyper string: "+e);var r=u(t.__proto__||Object.getPrototypeOf(t),"fromString",this).call(this,e,!1);return new this(r.low,r.high)}},{key:"fromBits",value:function(e,r){var n=u(t.__proto__||Object.getPrototypeOf(t),"fromBits",this).call(this,e,r,!1);return new this(n.low,n.high)}},{key:"isValid",value:function(e){return e instanceof this}}]),t}(f.default);h.default(p),p.MAX_VALUE=new p(f.default.MAX_VALUE.low,f.default.MAX_VALUE.high),p.MIN_VALUE=new p(f.default.MIN_VALUE.low,f.default.MIN_VALUE.high)},function(e,t,r){var n,o,i;(function(e){!function(a,s){r(303).amd?(o=[],n=s,i="function"==typeof n?n.apply(t,o):n,!(void 0!==i&&(e.exports=i))):"object"==typeof e&&e&&e.exports?e.exports=s():(a.dcodeIO=a.dcodeIO||{}).Long=s()}(this,function(){"use strict";function e(e,t,r){this.low=0|e,this.high=0|t,this.unsigned=!!r}e.__isLong__,Object.defineProperty(e.prototype,"__isLong__",{value:!0,enumerable:!1,configurable:!1}),e.isLong=function(e){return(e&&e.__isLong__)===!0};var t={},r={};e.fromInt=function(n,o){var i,a;return o?(n>>>=0,n>=0&&256>n&&(a=r[n])?a:(i=new e(n,0>(0|n)?-1:0,!0),n>=0&&256>n&&(r[n]=i),i)):(n=0|n,n>=-128&&128>n&&(a=t[n])?a:(i=new e(n,0>n?-1:0,!1),n>=-128&&128>n&&(t[n]=i),i))},e.fromNumber=function(t,r){return r=!!r,isNaN(t)||!isFinite(t)?e.ZERO:!r&&-s>=t?e.MIN_VALUE:!r&&t+1>=s?e.MAX_VALUE:r&&t>=a?e.MAX_UNSIGNED_VALUE:0>t?e.fromNumber(-t,r).negate():new e(t%i|0,t/i|0,r)},e.fromBits=function(t,r,n){return new e(t,r,n)},e.fromString=function(t,r,n){if(0===t.length)throw Error("number format error: empty string");if("NaN"===t||"Infinity"===t||"+Infinity"===t||"-Infinity"===t)return e.ZERO;if("number"==typeof r&&(n=r,r=!1),n=n||10,2>n||n>36)throw Error("radix out of range: "+n);var o;if((o=t.indexOf("-"))>0)throw Error('number format error: interior "-" character: '+t);if(0===o)return e.fromString(t.substring(1),r,n).negate();for(var i=e.fromNumber(Math.pow(n,8)),a=e.ZERO,s=0;s<t.length;s+=8){var u=Math.min(8,t.length-s),c=parseInt(t.substring(s,s+u),n);if(8>u){var f=e.fromNumber(Math.pow(n,u));a=a.multiply(f).add(e.fromNumber(c))}else a=a.multiply(i),a=a.add(e.fromNumber(c))}return a.unsigned=r,a},e.fromValue=function(t){return t instanceof e?t:"number"==typeof t?e.fromNumber(t):"string"==typeof t?e.fromString(t):new e(t.low,t.high,t.unsigned)};var n=65536,o=1<<24,i=n*n,a=i*i,s=a/2,u=e.fromInt(o);return e.ZERO=e.fromInt(0),e.UZERO=e.fromInt(0,!0),e.ONE=e.fromInt(1),e.UONE=e.fromInt(1,!0),e.NEG_ONE=e.fromInt(-1),e.MAX_VALUE=e.fromBits(-1,2147483647,!1),e.MAX_UNSIGNED_VALUE=e.fromBits(-1,-1,!0),e.MIN_VALUE=e.fromBits(0,-2147483648,!1),e.prototype.toInt=function(){return this.unsigned?this.low>>>0:this.low},e.prototype.toNumber=function(){return this.unsigned?(this.high>>>0)*i+(this.low>>>0):this.high*i+(this.low>>>0)},e.prototype.toString=function(t){if(t=t||10,2>t||t>36)throw RangeError("radix out of range: "+t);if(this.isZero())return"0";var r;if(this.isNegative()){if(this.equals(e.MIN_VALUE)){var n=e.fromNumber(t),o=this.divide(n);return r=o.multiply(n).subtract(this),o.toString(t)+r.toInt().toString(t)}return"-"+this.negate().toString(t)}var i=e.fromNumber(Math.pow(t,6),this.unsigned);r=this;for(var a="";;){var s=r.divide(i),u=r.subtract(s.multiply(i)).toInt()>>>0,c=u.toString(t);if(r=s,r.isZero())return c+a;for(;c.length<6;)c="0"+c;a=""+c+a}},e.prototype.getHighBits=function(){return this.high},e.prototype.getHighBitsUnsigned=function(){return this.high>>>0},e.prototype.getLowBits=function(){return this.low},e.prototype.getLowBitsUnsigned=function(){return this.low>>>0},e.prototype.getNumBitsAbs=function(){if(this.isNegative())return this.equals(e.MIN_VALUE)?64:this.negate().getNumBitsAbs();for(var t=0!=this.high?this.high:this.low,r=31;r>0&&0==(t&1<<r);r--);return 0!=this.high?r+33:r+1},e.prototype.isZero=function(){return 0===this.high&&0===this.low},e.prototype.isNegative=function(){return!this.unsigned&&this.high<0},e.prototype.isPositive=function(){return this.unsigned||this.high>=0},e.prototype.isOdd=function(){return 1===(1&this.low)},e.prototype.isEven=function(){return 0===(1&this.low)},e.prototype.equals=function(t){return e.isLong(t)||(t=e.fromValue(t)),this.unsigned!==t.unsigned&&this.high>>>31===1&&t.high>>>31===1?!1:this.high===t.high&&this.low===t.low},e.eq=e.prototype.equals,e.prototype.notEquals=function(e){return!this.equals(e)},e.neq=e.prototype.notEquals,e.prototype.lessThan=function(e){return this.compare(e)<0},e.prototype.lt=e.prototype.lessThan,e.prototype.lessThanOrEqual=function(e){return this.compare(e)<=0},e.prototype.lte=e.prototype.lessThanOrEqual,e.prototype.greaterThan=function(e){return this.compare(e)>0},e.prototype.gt=e.prototype.greaterThan,e.prototype.greaterThanOrEqual=function(e){return this.compare(e)>=0},e.prototype.gte=e.prototype.greaterThanOrEqual,e.prototype.compare=function(t){if(e.isLong(t)||(t=e.fromValue(t)),this.equals(t))return 0;var r=this.isNegative(),n=t.isNegative();return r&&!n?-1:!r&&n?1:this.unsigned?t.high>>>0>this.high>>>0||t.high===this.high&&t.low>>>0>this.low>>>0?-1:1:this.subtract(t).isNegative()?-1:1},e.prototype.negate=function(){return!this.unsigned&&this.equals(e.MIN_VALUE)?e.MIN_VALUE:this.not().add(e.ONE)},e.prototype.neg=e.prototype.negate,e.prototype.add=function(t){e.isLong(t)||(t=e.fromValue(t));var r=this.high>>>16,n=65535&this.high,o=this.low>>>16,i=65535&this.low,a=t.high>>>16,s=65535&t.high,u=t.low>>>16,c=65535&t.low,f=0,l=0,h=0,p=0;return p+=i+c,h+=p>>>16,p&=65535,h+=o+u,l+=h>>>16,h&=65535,l+=n+s,f+=l>>>16,l&=65535,f+=r+a,f&=65535,e.fromBits(h<<16|p,f<<16|l,this.unsigned)},e.prototype.subtract=function(t){return e.isLong(t)||(t=e.fromValue(t)),this.add(t.negate())},e.prototype.sub=e.prototype.subtract,e.prototype.multiply=function(t){if(this.isZero())return e.ZERO;if(e.isLong(t)||(t=e.fromValue(t)),t.isZero())return e.ZERO;if(this.equals(e.MIN_VALUE))return t.isOdd()?e.MIN_VALUE:e.ZERO;if(t.equals(e.MIN_VALUE))return this.isOdd()?e.MIN_VALUE:e.ZERO;if(this.isNegative())return t.isNegative()?this.negate().multiply(t.negate()):this.negate().multiply(t).negate();if(t.isNegative())return this.multiply(t.negate()).negate();if(this.lessThan(u)&&t.lessThan(u))return e.fromNumber(this.toNumber()*t.toNumber(),this.unsigned);var r=this.high>>>16,n=65535&this.high,o=this.low>>>16,i=65535&this.low,a=t.high>>>16,s=65535&t.high,c=t.low>>>16,f=65535&t.low,l=0,h=0,p=0,d=0;return d+=i*f,p+=d>>>16,d&=65535,p+=o*f,h+=p>>>16,p&=65535,p+=i*c,h+=p>>>16,p&=65535,h+=n*f,l+=h>>>16,h&=65535,h+=o*c,l+=h>>>16,h&=65535,h+=i*s,l+=h>>>16,h&=65535,l+=r*f+n*c+o*s+i*a,l&=65535,e.fromBits(p<<16|d,l<<16|h,this.unsigned)},e.prototype.mul=e.prototype.multiply,e.prototype.divide=function(t){if(e.isLong(t)||(t=e.fromValue(t)),t.isZero())throw new Error("division by zero");if(this.isZero())return this.unsigned?e.UZERO:e.ZERO;var r,n,o;if(this.equals(e.MIN_VALUE)){if(t.equals(e.ONE)||t.equals(e.NEG_ONE))return e.MIN_VALUE;if(t.equals(e.MIN_VALUE))return e.ONE;var i=this.shiftRight(1);return r=i.divide(t).shiftLeft(1),r.equals(e.ZERO)?t.isNegative()?e.ONE:e.NEG_ONE:(n=this.subtract(t.multiply(r)),o=r.add(n.divide(t)))}if(t.equals(e.MIN_VALUE))return this.unsigned?e.UZERO:e.ZERO;if(this.isNegative())return t.isNegative()?this.negate().divide(t.negate()):this.negate().divide(t).negate();if(t.isNegative())return this.divide(t.negate()).negate();for(o=e.ZERO,n=this;n.greaterThanOrEqual(t);){r=Math.max(1,Math.floor(n.toNumber()/t.toNumber()));for(var a=Math.ceil(Math.log(r)/Math.LN2),s=48>=a?1:Math.pow(2,a-48),u=e.fromNumber(r),c=u.multiply(t);c.isNegative()||c.greaterThan(n);)r-=s,u=e.fromNumber(r,this.unsigned),c=u.multiply(t);u.isZero()&&(u=e.ONE),o=o.add(u),n=n.subtract(c)}return o},e.prototype.div=e.prototype.divide,e.prototype.modulo=function(t){return e.isLong(t)||(t=e.fromValue(t)),this.subtract(this.divide(t).multiply(t))},e.prototype.mod=e.prototype.modulo,e.prototype.not=function(){return e.fromBits(~this.low,~this.high,this.unsigned)},e.prototype.and=function(t){return e.isLong(t)||(t=e.fromValue(t)),e.fromBits(this.low&t.low,this.high&t.high,this.unsigned)},e.prototype.or=function(t){return e.isLong(t)||(t=e.fromValue(t)),e.fromBits(this.low|t.low,this.high|t.high,this.unsigned)},e.prototype.xor=function(t){return e.isLong(t)||(t=e.fromValue(t)),e.fromBits(this.low^t.low,this.high^t.high,this.unsigned)},e.prototype.shiftLeft=function(t){return e.isLong(t)&&(t=t.toInt()),0===(t&=63)?this:32>t?e.fromBits(this.low<<t,this.high<<t|this.low>>>32-t,this.unsigned):e.fromBits(0,this.low<<t-32,this.unsigned)},e.prototype.shl=e.prototype.shiftLeft,e.prototype.shiftRight=function(t){return e.isLong(t)&&(t=t.toInt()),0===(t&=63)?this:32>t?e.fromBits(this.low>>>t|this.high<<32-t,this.high>>t,this.unsigned):e.fromBits(this.high>>t-32,this.high>=0?0:-1,this.unsigned)},e.prototype.shr=e.prototype.shiftRight,e.prototype.shiftRightUnsigned=function(t){if(e.isLong(t)&&(t=t.toInt()),t&=63,0===t)return this;var r=this.high;if(32>t){var n=this.low;return e.fromBits(n>>>t|r<<32-t,r>>>t,this.unsigned)}return 32===t?e.fromBits(r,0,this.unsigned):e.fromBits(r>>>t-32,0,this.unsigned)},e.prototype.shru=e.prototype.shiftRightUnsigned,e.prototype.toSigned=function(){return this.unsigned?new e(this.low,this.high,!1):this},e.prototype.toUnsigned=function(){return this.unsigned?this:new e(this.low,this.high,!0)},e})}).call(t,r(64)(e))},function(e){e.exports=function(){throw new Error("define cannot be used indirect")}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.UnsignedInt=void 0;var o=r(245),i=n(o),a=r(246),s=n(a),u=t.UnsignedInt={read:function(e){return e.readUInt32BE()},write:function(e,t){if(!i.default(e))throw new Error("XDR Write Error: not a number");if(Math.floor(e)!==e)throw new Error("XDR Write Error: not an integer");if(0>e)throw new Error("XDR Write Error: negative number "+e);t.writeUInt32BE(e)},isValid:function(e){return i.default(e)?Math.floor(e)!==e?!1:e>=u.MIN_VALUE&&e<=u.MAX_VALUE:!1}};u.MAX_VALUE=Math.pow(2,32)-1,u.MIN_VALUE=0,s.default(u)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)
}Object.defineProperty(t,"__esModule",{value:!0}),t.UnsignedHyper=void 0;var s=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),u=function d(e,t,r){null===e&&(e=Function.prototype);var n=Object.getOwnPropertyDescriptor(e,t);if(void 0===n){var o=Object.getPrototypeOf(e);return null===o?void 0:d(o,t,r)}if("value"in n)return n.value;var i=n.get;return void 0===i?void 0:i.call(r)},c=r(302),f=n(c),l=r(246),h=n(l),p=t.UnsignedHyper=function(e){function t(e,r){return o(this,t),i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,r,!0))}return a(t,e),s(t,null,[{key:"read",value:function(e){var t=e.readInt32BE(),r=e.readInt32BE();return this.fromBits(r,t)}},{key:"write",value:function(e,t){if(!(e instanceof this))throw new Error("XDR Write Error: "+e+" is not an UnsignedHyper");t.writeInt32BE(e.high),t.writeInt32BE(e.low)}},{key:"fromString",value:function(e){if(!/^\d+$/.test(e))throw new Error("Invalid hyper string: "+e);var r=u(t.__proto__||Object.getPrototypeOf(t),"fromString",this).call(this,e,!0);return new this(r.low,r.high)}},{key:"fromBits",value:function(e,r){var n=u(t.__proto__||Object.getPrototypeOf(t),"fromBits",this).call(this,e,r,!0);return new this(n.low,n.high)}},{key:"isValid",value:function(e){return e instanceof this}}]),t}(f.default);h.default(p),p.MAX_VALUE=new p(f.default.MAX_UNSIGNED_VALUE.low,f.default.MAX_UNSIGNED_VALUE.high),p.MIN_VALUE=new p(f.default.MIN_VALUE.low,f.default.MIN_VALUE.high)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Float=void 0;var o=r(245),i=n(o),a=r(246),s=n(a),u=t.Float={read:function(e){return e.readFloatBE()},write:function(e,t){if(!i.default(e))throw new Error("XDR Write Error: not a number");t.writeFloatBE(e)},isValid:function(e){return i.default(e)}};s.default(u)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Double=void 0;var o=r(245),i=n(o),a=r(246),s=n(a),u=t.Double={read:function(e){return e.readDoubleBE()},write:function(e,t){if(!i.default(e))throw new Error("XDR Write Error: not a number");t.writeDoubleBE(e)},isValid:function(e){return i.default(e)}};s.default(u)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Quadruple=void 0;var o=r(246),i=n(o),a=t.Quadruple={read:function(){throw new Error("XDR Read Error: quadruple not supported")},write:function(){throw new Error("XDR Write Error: quadruple not supported")},isValid:function(){return!1}};i.default(a)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Bool=void 0;var o=r(310),i=n(o),a=r(244),s=r(246),u=n(s),c=t.Bool={read:function(e){var t=a.Int.read(e);switch(t){case 0:return!1;case 1:return!0;default:throw new Error("XDR Read Error: Got "+t+" when trying to read a bool")}},write:function(e,t){var r=e?1:0;return a.Int.write(r,t)},isValid:function(e){return i.default(e)}};u.default(c)},function(e,t,r){function n(e){return e===!0||e===!1||i(e)&&o(e)==a}var o=r(24),i=r(61),a="[object Boolean]";e.exports=n},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.String=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(240),s=n(a),u=r(62),c=n(u),f=r(244),l=r(304),h=r(260),p=r(246),d=n(p),y=t.String=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:l.UnsignedInt.MAX_VALUE;o(this,t),this._maxLength=e}return i(t,[{key:"read",value:function(e){var t=f.Int.read(e);if(t>this._maxLength)throw new Error("XDR Read Error: Saw "+t+" length String,max allowed is "+this._maxLength);var r=h.calculatePadding(t),n=e.slice(t);return h.slicePadding(e,r),n.buffer()}},{key:"readString",value:function(e){return this.read(e).toString("utf8")}},{key:"write",value:function(t,r){if(t.length>this._maxLength)throw new Error("XDR Write Error: Got "+t.length+" bytes,max allows is "+this._maxLength);var n=void 0;n=s.default(t)?e.from(t,"utf8"):e.from(t),f.Int.write(n.length,r),r.writeBufferPadded(n)}},{key:"isValid",value:function(t){var r=void 0;if(s.default(t))r=e.from(t,"utf8");else{if(!c.default(t)&&!e.isBuffer(t))return!1;r=e.from(t)}return r.length<=this._maxLength}}]),t}();d.default(y.prototype)}).call(t,r(156).Buffer)},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Opaque=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(260),s=r(246),u=n(s),c=t.Opaque=function(){function t(e){o(this,t),this._length=e,this._padding=a.calculatePadding(e)}return i(t,[{key:"read",value:function(e){var t=e.slice(this._length);return a.slicePadding(e,this._padding),t.buffer()}},{key:"write",value:function(e,t){if(e.length!==this._length)throw new Error("XDR Write Error: Got "+e.length+" bytes, expected "+this._length);t.writeBufferPadded(e)}},{key:"isValid",value:function(t){return e.isBuffer(t)&&t.length===this._length}}]),t}();u.default(c.prototype)}).call(t,r(156).Buffer)},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.VarOpaque=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(244),s=r(304),u=r(260),c=r(246),f=n(c),l=t.VarOpaque=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s.UnsignedInt.MAX_VALUE;o(this,t),this._maxLength=e}return i(t,[{key:"read",value:function(e){var t=a.Int.read(e);if(t>this._maxLength)throw new Error("XDR Read Error: Saw "+t+" length VarOpaque,max allowed is "+this._maxLength);var r=u.calculatePadding(t),n=e.slice(t);return u.slicePadding(e,r),n.buffer()}},{key:"write",value:function(e,t){if(e.length>this._maxLength)throw new Error("XDR Write Error: Got "+e.length+" bytes,max allows is "+this._maxLength);a.Int.write(e.length,t),t.writeBufferPadded(e)}},{key:"isValid",value:function(t){return e.isBuffer(t)&&t.length<=this._maxLength}}]),t}();f.default(l.prototype)}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Array=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(261),s=n(a),u=r(315),c=n(u),f=r(316),l=n(f),h=r(62),p=n(h),d=r(246),y=n(d),v=t.Array=function(){function e(t,r){o(this,e),this._childType=t,this._length=r}return i(e,[{key:"read",value:function(e){var t=this;return l.default(this._length,function(){return t._childType.read(e)})}},{key:"write",value:function(e,t){var r=this;if(!p.default(e))throw new Error("XDR Write Error: value is not array");if(e.length!==this._length)throw new Error("XDR Write Error: Got array of size "+e.length+",expected "+this._length);c.default(e,function(e){return r._childType.write(e,t)})}},{key:"isValid",value:function(e){var t=this;return p.default(e)?e.length!==this._length?!1:s.default(e,function(e){return t._childType.isValid(e)}):!1}}]),e}();y.default(v.prototype)},function(e,t,r){e.exports=r(116)},function(e,t,r){function n(e,t){if(e=a(e),1>e||e>s)return[];var r=u,n=c(e,u);t=i(t),e-=u;for(var f=o(n,t);++r<e;)t(r);return f}var o=r(58),i=r(122),a=r(317),s=9007199254740991,u=4294967295,c=Math.min;e.exports=n},function(e,t,r){function n(e){var t=o(e),r=t%1;return t===t?r?t-r:t:0}var o=r(318);e.exports=n},function(e,t,r){function n(e){if(!e)return 0===e?e:0;if(e=o(e),e===i||e===-i){var t=0>e?-1:1;return t*a}return e===e?e:0}var o=r(319),i=1/0,a=1.7976931348623157e308;e.exports=n},function(e,t,r){function n(e){if("number"==typeof e)return e;if(i(e))return a;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(s,"");var r=c.test(e);return r||f.test(e)?l(e.slice(2),r?2:8):u.test(e)?a:+e}var o=r(30),i=r(287),a=0/0,s=/^\s+|\s+$/g,u=/^[-+]0x[0-9a-f]+$/i,c=/^0b[01]+$/i,f=/^0o[0-7]+$/i,l=parseInt;e.exports=n},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.VarArray=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(261),s=n(a),u=r(315),c=n(u),f=r(316),l=n(f),h=r(62),p=n(h),d=r(304),y=r(244),v=r(246),g=n(v),m=t.VarArray=function(){function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:d.UnsignedInt.MAX_VALUE;o(this,e),this._childType=t,this._maxLength=r}return i(e,[{key:"read",value:function(e){var t=this,r=y.Int.read(e);if(r>this._maxLength)throw new Error("XDR Read Error: Saw "+r+" length VarArray,max allowed is "+this._maxLength);return l.default(r,function(){return t._childType.read(e)})}},{key:"write",value:function(e,t){var r=this;if(!p.default(e))throw new Error("XDR Write Error: value is not array");if(e.length>this._maxLength)throw new Error("XDR Write Error: Got array of size "+e.length+",max allowed is "+this._maxLength);y.Int.write(e.length,t),c.default(e,function(e){return r._childType.write(e,t)})}},{key:"isValid",value:function(e){var t=this;return p.default(e)?e.length>this._maxLength?!1:s.default(e,function(e){return t._childType.isValid(e)}):!1}}]),e}();g.default(m.prototype)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Option=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(239),s=n(a),u=r(221),c=n(u),f=r(309),l=r(246),h=n(l),p=t.Option=function(){function e(t){o(this,e),this._childType=t}return i(e,[{key:"read",value:function(e){return f.Bool.read(e)?this._childType.read(e):void 0}},{key:"write",value:function(e,t){var r=!(s.default(e)||c.default(e));f.Bool.write(r,t),r&&this._childType.write(e,t)}},{key:"isValid",value:function(e){return s.default(e)?!0:c.default(e)?!0:this._childType.isValid(e)}}]),e}();h.default(p.prototype)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Void=void 0;var o=r(221),i=n(o),a=r(246),s=n(a),u=t.Void={read:function(){return void 0},write:function(e){if(!i.default(e))throw new Error("XDR Write Error: trying to write value to a void slot")},isValid:function(e){return i.default(e)}};s.default(u)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Enum=void 0;var s=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),u=r(315),c=n(u),f=r(324),l=n(f),h=r(244),p=r(246),d=n(p),y=t.Enum=function(){function e(t,r){a(this,e),this.name=t,this.value=r}return s(e,null,[{key:"read",value:function(e){var t=h.Int.read(e);if(!this._byValue.has(t))throw new Error("XDR Read Error: Unknown "+this.enumName+" member for value "+t);return this._byValue.get(t)}},{key:"write",value:function(e,t){if(!(e instanceof this))throw new Error("XDR Write Error: Unknown "+e+" is not a "+this.enumName);h.Int.write(e.value,t)}},{key:"isValid",value:function(e){return e instanceof this}},{key:"members",value:function(){return this._members}},{key:"values",value:function(){return l.default(this._members)}},{key:"fromName",value:function(e){var t=this._members[e];if(!t)throw new Error(e+" is not a member of "+this.enumName);return t}},{key:"fromValue",value:function(e){var t=this._byValue.get(e);if(!t)throw new Error(e+" is not a value of any member of "+this.enumName);return t}},{key:"create",value:function(t,r,n){var s=function(e){function t(){return a(this,t),o(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),t}(e);return s.enumName=r,t.results[r]=s,s._members={},s._byValue=new Map,c.default(n,function(e,t){var r=new s(t,e);s._members[t]=r,s._byValue.set(e,r),s[t]=function(){return r}}),s}}]),e}();d.default(y)},function(e,t,r){function n(e){return null==e?[]:o(e,i(e))}var o=r(325),i=r(56);e.exports=n},function(e,t,r){function n(e,t){return o(t,function(t){return e[t]})}var o=r(293);e.exports=n},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e){return function(t){return y.default(t)||(this._attributes[e]=t),this._attributes[e]}}Object.defineProperty(t,"__esModule",{value:!0}),t.Struct=void 0;var u=function(){function e(e,t){var r=[],n=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(n=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);n=!0);}catch(u){o=!0,i=u}finally{try{!n&&s["return"]&&s["return"]()}finally{if(o)throw i}}return r}return function(t,r){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),c=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),f=r(315),l=n(f),h=r(327),p=n(h),d=r(221),y=n(d),v=r(329),g=n(v),m=r(330),b=r(246),w=n(b),_=t.Struct=function(){function e(t){a(this,e),this._attributes=t||{}}return c(e,null,[{key:"read",value:function(e){var t=p.default(this._fields,function(t){var r=u(t,2),n=r[0],o=r[1],i=o.read(e);return[n,i]});return new this(g.default(t))}},{key:"write",value:function(e,t){if(!(e instanceof this))throw new Error("XDR Write Error: "+e+" is not a "+this.structName);l.default(this._fields,function(r){var n=u(r,2),o=n[0],i=n[1],a=e._attributes[o];i.write(a,t)})}},{key:"isValid",value:function(e){return e instanceof this}},{key:"create",value:function(t,r,n){var c=function(e){function t(){return a(this,t),o(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),t}(e);return c.structName=r,t.results[r]=c,c._fields=n.map(function(e){var r=u(e,2),n=r[0],o=r[1];return o instanceof m.Reference&&(o=o.resolve(t)),[n,o]}),l.default(c._fields,function(e){var t=u(e,1),r=t[0];c.prototype[r]=s(r)}),c}}]),e}();w.default(_)},function(e,t,r){function n(e,t){var r=s(e)?o:a;return r(e,i(t,3))}var o=r(293),i=r(264),a=r(328),s=r(62);e.exports=n},function(e,t,r){function n(e,t){var r=-1,n=i(e)?Array(e.length):[];return o(e,function(e,o,i){n[++r]=t(e,o,i)}),n}var o=r(117),i=r(76);e.exports=n},function(e){function t(e){for(var t=-1,r=null==e?0:e.length,n={};++t<r;){var o=e[t];n[o[0]]=o[1]}return n}e.exports=t},function(e,t){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});{var n=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();t.Reference=function(){function e(){r(this,e)}return n(e,[{key:"resolve",value:function(){throw new Error("implement resolve in child class")}}]),e}()}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Union=void 0;var s=function(){function e(e,t){var r=[],n=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(n=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);n=!0);}catch(u){o=!0,i=u}finally{try{!n&&s["return"]&&s["return"]()}finally{if(o)throw i}}return r}return function(t,r){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),u=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),c=r(315),f=n(c),l=r(221),h=n(l),p=r(240),d=n(p),y=r(322),v=r(330),g=r(246),m=n(g),b=t.Union=function(){function e(t,r){a(this,e),this.set(t,r)}return u(e,[{key:"set",value:function(e,t){d.default(e)&&(e=this.constructor._switchOn.fromName(e)),this._switch=e,this._arm=this.constructor.armForSwitch(this._switch),this._armType=this.constructor.armTypeForArm(this._arm),this._value=t}},{key:"get",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this._arm;if(this._arm!==y.Void&&this._arm!==e)throw new Error(e+" not set");return this._value}},{key:"switch",value:function(){return this._switch}},{key:"arm",value:function(){return this._arm}},{key:"armType",value:function(){return this._armType}},{key:"value",value:function(){return this._value}}],[{key:"armForSwitch",value:function(e){if(this._switches.has(e))return this._switches.get(e);if(this._defaultArm)return this._defaultArm;throw new Error("Bad union switch: "+e)}},{key:"armTypeForArm",value:function(e){return e===y.Void?y.Void:this._arms[e]}},{key:"read",value:function(e){var t=this._switchOn.read(e),r=this.armForSwitch(t),n=this.armTypeForArm(r),o=void 0;return o=h.default(n)?r.read(e):n.read(e),new this(t,o)}},{key:"write",value:function(e,t){if(!(e instanceof this))throw new Error("XDR Write Error: "+e+" is not a "+this.unionName);this._switchOn.write(e.switch(),t),e.armType().write(e.value(),t)}},{key:"isValid",value:function(e){return e instanceof this}},{key:"create",value:function(t,r,n){var u=function(e){function t(){return a(this,t),o(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return i(t,e),t}(e);u.unionName=r,t.results[r]=u,u._switchOn=n.switchOn instanceof v.Reference?n.switchOn.resolve(t):n.switchOn,u._switches=new Map,u._arms={},f.default(n.arms,function(e,r){e instanceof v.Reference&&(e=e.resolve(t)),u._arms[r]=e});var c=n.defaultArm;return c instanceof v.Reference&&(c=c.resolve(t)),u._defaultArm=c,f.default(n.switches,function(e){var t=s(e,2),r=t[0],n=t[1];d.default(r)&&(r=u._switchOn.fromName(r)),u._switches.set(r,n)}),h.default(u._switchOn.values)||f.default(u._switchOn.values(),function(e){u[e.name]=function(t){return new u(e,t)},u.prototype[e.name]=function(t){return this.set(e,t)}}),f.default(u._arms,function(e,t){e!==y.Void&&(u.prototype[t]=function(){return this.get(t)})}),u}}]),e}();m.default(b)},function(e,t,r){"use strict";function n(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function u(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e){var r=new O(t);e(r),r.resolve()}return t}function c(e,t,r){return r instanceof h.Reference&&(r=r.resolve(e)),e.results[t]=r,r}function f(e,t,r){return e.results[t]=r,r}Object.defineProperty(t,"__esModule",{value:!0});var l=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),h=r(330);Object.keys(h).forEach(function(e){"default"!==e&&"__esModule"!==e&&Object.defineProperty(t,e,{enumerable:!0,get:function(){return h[e]}})}),t.config=u;var p=r(221),d=o(p),y=r(315),v=o(y),g=r(243),m=n(g),b=function(e){function t(e){i(this,t);var r=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.name=e,r}return s(t,e),l(t,[{key:"resolve",value:function(e){var t=e.definitions[this.name];return t.resolve(e)}}]),t}(h.Reference),w=function(e){function t(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:!1;i(this,t);var o=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return o.childReference=e,o.length=r,o.variable=n,o}return s(t,e),l(t,[{key:"resolve",value:function(e){var t=this.childReference,r=this.length;return t instanceof h.Reference&&(t=t.resolve(e)),r instanceof h.Reference&&(r=r.resolve(e)),this.variable?new m.VarArray(t,r):new m.Array(t,r)}}]),t}(h.Reference),_=function(e){function t(e){i(this,t);var r=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return r.childReference=e,r.name=e.name,r}return s(t,e),l(t,[{key:"resolve",value:function(e){var t=this.childReference;return t instanceof h.Reference&&(t=t.resolve(e)),new m.Option(t)}}]),t}(h.Reference),k=function(e){function t(e,r){i(this,t);var n=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.sizedType=e,n.length=r,n}return s(t,e),l(t,[{key:"resolve",value:function(e){var t=this.length;return t instanceof h.Reference&&(t=t.resolve(e)),new this.sizedType(t)}}]),t}(h.Reference),A=function(){function e(t,r,n){i(this,e),this.constructor=t,this.name=r,this.config=n}return l(e,[{key:"resolve",value:function(e){return this.name in e.results?e.results[this.name]:this.constructor(e,this.name,this.config)}}]),e}(),O=function(){function e(t){i(this,e),this._destination=t,this._definitions={}}return l(e,[{key:"enum",value:function(e,t){var r=new A(m.Enum.create,e,t);this.define(e,r)}},{key:"struct",value:function(e,t){var r=new A(m.Struct.create,e,t);this.define(e,r)}},{key:"union",value:function(e,t){var r=new A(m.Union.create,e,t);this.define(e,r)}},{key:"typedef",value:function(e,t){var r=new A(c,e,t);this.define(e,r)}},{key:"const",value:function(e,t){var r=new A(f,e,t);this.define(e,r)}},{key:"void",value:function(){return m.Void}},{key:"bool",value:function(){return m.Bool}},{key:"int",value:function(){return m.Int}},{key:"hyper",value:function(){return m.Hyper}},{key:"uint",value:function(){return m.UnsignedInt}},{key:"uhyper",value:function(){return m.UnsignedHyper}},{key:"float",value:function(){return m.Float}},{key:"double",value:function(){return m.Double}},{key:"quadruple",value:function(){return m.Quadruple}},{key:"string",value:function(e){return new k(m.String,e)}},{key:"opaque",value:function(e){return new k(m.Opaque,e)}},{key:"varOpaque",value:function(e){return new k(m.VarOpaque,e)}},{key:"array",value:function(e,t){return new w(e,t)}},{key:"varArray",value:function(e,t){return new w(e,t,!0)}},{key:"option",value:function(e){return new _(e)}},{key:"define",value:function(e,t){if(!d.default(this._destination[e]))throw new Error("XDRTypes Error:"+e+" is already defined");this._definitions[e]=t}},{key:"lookup",value:function(e){return new b(e)}},{key:"resolve",value:function(){var e=this;v.default(this._definitions,function(t){t.resolve({definitions:e._definitions,results:e._destination})})}}]),e}()},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Transaction=void 0;{var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(203),s=r(223),u=r(334),c=r(218),f=r(386),l=r(327),h=n(l),p=r(315),d=n(p),y=r(240),v=n(y),g=r(387),m=n(g);t.Transaction=function(){function t(r){if(o(this,t),"string"==typeof r){var n=e.from(r,"base64");r=a.xdr.TransactionEnvelope.fromXDR(n)}this.tx=r.tx(),this.source=s.StrKey.encodeEd25519PublicKey(r.tx().sourceAccount().ed25519()),this.fee=this.tx.fee(),this._memo=this.tx.memo(),this.sequence=this.tx.seqNum().toString();var i=this.tx.timeBounds();i&&(this.timeBounds={minTime:i.minTime().toString(),maxTime:i.maxTime().toString()});var c=this.tx.operations()||[];this.operations=h.default(c,function(e){return u.Operation.fromXDRObject(e)});var f=r.signatures()||[];this.signatures=h.default(f,function(e){return e})}return i(t,[{key:"sign",value:function(){for(var e=this,t=this.hash(),r=arguments.length,n=Array(r),o=0;r>o;o++)n[o]=arguments[o];d.default(n,function(r){var n=r.signDecorated(t);e.signatures.push(n)})}},{key:"signHashX",value:function(t){if(v.default(t)&&(t=e.from(t,"hex")),t.length>64)throw new Error("preimage cannnot be longer than 64 bytes");var r=t,n=m.default.createHash("sha256").update(t).digest(),o=n.slice(n.length-4);this.signatures.push(new a.xdr.DecoratedSignature({hint:o,signature:r}))}},{key:"hash",value:function(){return a.hash(this.signatureBase())}},{key:"signatureBase",value:function(){if(null===c.Network.current())throw new Error("No network selected. Use `Network.use`, `Network.usePublicNetwork` or `Network.useTestNetwork` helper methods to select network.");return e.concat([c.Network.current().networkId(),a.xdr.EnvelopeType.envelopeTypeTx().toXDR(),this.tx.toXDR()])}},{key:"toEnvelope",value:function(){var e=this.tx,t=this.signatures,r=new a.xdr.TransactionEnvelope({tx:e,signatures:t});return r}},{key:"memo",get:function(){return f.Memo.fromXDRObject(this._memo)},set:function(){throw new Error("Transaction is immutable")}}]),t}()}}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Operation=t.AuthImmutableFlag=t.AuthRevocableFlag=t.AuthRequiredFlag=void 0;var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(241),u=o(s),c=r(217),f=(r(204),r(223)),l=r(242),h=r(335),p=r(354),d=r(355),y=o(d),v=r(356),g=r(348),m=o(g),b=r(221),w=o(b),_=r(240),k=o(_),A=r(245),O=o(A),E=r(357),S=o(E),x=r(358),C=r(364),P=n(C),T=1e7,j="9223372036854775807",R=(t.AuthRequiredFlag=1,t.AuthRevocableFlag=2,t.AuthImmutableFlag=4,t.Operation=function(){function e(){i(this,e)}return a(e,null,[{key:"setSourceAccount",value:function(e,t){if(t.source){if(!f.StrKey.isValidEd25519PublicKey(t.source))throw new Error("Source address is invalid");e.sourceAccount=c.Keypair.fromPublicKey(t.source).xdrAccountId()}}},{key:"fromXDRObject",value:function(e){function t(e){return f.StrKey.encodeEd25519PublicKey(e.ed25519())}function r(e){return f.StrKey.encodeContractKey(e.contract())}var n={};e.sourceAccount()&&(n.source=t(e.sourceAccount()));var o=e.body().value();switch(e.body().switch().name){case"createAccount":n.type="createAccount",n.destination=t(o.destination()),n.startingBalance=this._fromXDRAmount(o.startingBalance());break;case"payment":n.type="payment",n.destination=t(o.destination()),n.asset=h.Asset.fromOperation(o.asset()),n.amount=this._fromXDRAmount(o.amount());break;case"pathPayment":n.type="pathPayment",n.sendAsset=h.Asset.fromOperation(o.sendAsset()),n.sendMax=this._fromXDRAmount(o.sendMax()),n.destination=t(o.destination()),n.destAsset=h.Asset.fromOperation(o.destAsset()),n.destAmount=this._fromXDRAmount(o.destAmount());var i=o.path();n.path=[];for(var a in i)n.path.push(h.Asset.fromOperation(i[a]));break;case"changeTrust":n.type="changeTrust",n.line=h.Asset.fromOperation(o.line()),n.limit=this._fromXDRAmount(o.limit());break;case"allowTrust":n.type="allowTrust",n.trustor=t(o.trustor()),n.assetCode=o.asset().value().toString(),n.assetCode=m.default(n.assetCode,"\x00"),n.authorize=o.authorize();break;case"setOption":if(n.type="setOptions",o.inflationDest()&&(n.inflationDest=t(o.inflationDest())),n.clearFlags=o.clearFlags(),n.setFlags=o.setFlags(),n.masterWeight=o.masterWeight(),n.lowThreshold=o.lowThreshold(),n.medThreshold=o.medThreshold(),n.highThreshold=o.highThreshold(),n.homeDomain=o.homeDomain()?o.homeDomain().toString("ascii"):null,o.signer()){var s={},u=o.signer().key().arm();
"ed25519"==u?s.ed25519PublicKey=t(o.signer().key()):"preAuthTx"==u?s.preAuthTx=o.signer().key().preAuthTx():"hashX"==u&&(s.sha256Hash=o.signer().key().hashX()),s.weight=o.signer().weight(),n.signer=s}break;case"manageOffer":n.type="manageOffer",n.selling=h.Asset.fromOperation(o.selling()),n.buying=h.Asset.fromOperation(o.buying()),n.amount=this._fromXDRAmount(o.amount()),n.price=this._fromXDRPrice(o.price()),n.offerId=o.offerId().toString();break;case"createPassiveOffer":n.type="createPassiveOffer",n.selling=h.Asset.fromOperation(o.selling()),n.buying=h.Asset.fromOperation(o.buying()),n.amount=this._fromXDRAmount(o.amount()),n.price=this._fromXDRPrice(o.price());break;case"accountMerge":n.type="accountMerge",n.destination=t(o);break;case"manageDatum":n.type="manageData",n.name=o.dataName().toString("ascii"),n.value=o.dataValue();break;case"inflation":n.type="inflation";break;case"bumpSequence":n.type="bumpSequence",n.bumpTo=o.bumpTo().toString();break;case"createAsset":n.type="createAsset",n.asset=h.Asset.fromOperation(o.asset()),n.beneficiary=o.beneficiary().toString("ascii"),n.fee=o.fee(),n.ratio=o.ratio(),n.minfee=this._fromXDRAmount(o.minfee());break;case"changeAsset":n.type="changeAsset",n.asset=h.Asset.fromOperation(o.asset()),n.beneficiary=o.beneficiary().toString("ascii");break;case"limitAsset":n.type="limitAsset",n.asset=h.Asset.fromOperation(o.asset()),n.islimited=o.islimited();break;case"createContract":n.type="createContract",n.contractId=o.contractId().toString("ascii"),n.startingBalance=this._fromXDRAmount(o.startingBalance()),n.contractAddr=o.contractAddr(),n.fileHash=o.fileHash().toString("ascii"),n.state=o.state(),n.errFlag=o.errFlag();break;case"callContract":n.type="callContract",n.contractId=r(o.contractId()),n.data=p.ContractInput.fromOperation(o.data()),n.contrOps=x.ContrOperation.fromXDRObject(o.contrOps()),n.errFlag=o.errFlag();break;case"sendAsset":n.type="sendAsset",n.contractId=r(o.contractId()),n.asset=h.Asset.fromOperation(o.asset()),n.amount=this._fromXDRAmount(o.amount()),n.state=o.state(),n.errFlag=o.errFlag();break;case"checkContract":n.type="checkContract",n.isContract=o.isContract();break;case"testContract":n.type="testContract",n.startingBalance=o.startingBalance();break;default:throw new Error("Unknown operation")}return n}},{key:"isValidAmount",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:!1;if(!k.default(e))return!1;var r=void 0;try{r=new y.default(e)}catch(n){return!1}switch(!0){case!t&&r.isZero():case r.isNegative():case r.times(T).greaterThan(new y.default(j).toString()):case r.decimalPlaces()>7:case r.isNaN()||!r.isFinite():return!1;default:return!0}}},{key:"isValidIsContract",value:function(e){arguments.length>1&&void 0!==arguments[1]?arguments[1]:!1;if(!k.default(e))return!1;var t=void 0;try{t=new y.default(e)}catch(r){return!1}switch(!0){case t.isNegative():case t.isNaN()||!t.isFinite():return!1;default:return!0}}},{key:"constructIsContractRequirementsError",value:function(e){return e+" argument must be of type String, represent a positive number after the decimal"}},{key:"constructAmountRequirementsError",value:function(e){return e+" argument must be of type String, represent a positive number and have at most 7 digits after the decimal"}},{key:"_checkUnsignedIntValue",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(w.default(t))return void 0;switch(k.default(t)&&(t=parseFloat(t)),!0){case!O.default(t)||!S.default(t)||t%1!==0:throw new Error(e+" value is invalid");case 0>t:throw new Error(e+" value must be unsigned");case!r||r&&r(t,e):return t;default:throw new Error(e+" value is invalid")}}},{key:"_toXDRAmount",value:function(e){var t=new y.default(e).mul(T);return l.Hyper.fromString(t.toString())}},{key:"_fromXDRAmount",value:function(e){return new y.default(e).div(T).toString()}},{key:"_toXDRIsContract",value:function(e){var t=new y.default(e);return l.Hyper.fromString(t.toString())}},{key:"_fromXDRIsContract",value:function(e){return new y.default(e).toString()}},{key:"_fromXDRPrice",value:function(e){var t=new y.default(e.n());return t.div(new y.default(e.d())).toString()}},{key:"_toXDRPrice",value:function(e){var t=void 0;if(e.n&&e.d)t=new u.default.Price(e);else{e=new y.default(e);var r=v.best_r(e);t=new u.default.Price({n:parseInt(r[0]),d:parseInt(r[1])})}if(t.n()<0||t.d()<0)throw new Error("price must be positive");return t}}]),e}());R.accountMerge=P.accountMerge,R.allowTrust=P.allowTrust,R.bumpSequence=P.bumpSequence,R.changeTrust=P.changeTrust,R.createAccount=P.createAccount,R.createPassiveOffer=P.createPassiveOffer,R.inflation=P.inflation,R.manageData=P.manageData,R.manageOffer=P.manageOffer,R.pathPayment=P.pathPayment,R.payment=P.payment,R.setOptions=P.setOptions,R.createAsset=P.createAsset,R.changeAsset=P.changeAsset,R.limitAsset=P.limitAsset,R.createContract=P.createContract,R.callContract=P.callContract,R.sendAsset=P.sendAsset,R.checkContract=P.checkContract,R.testContract=P.testContract},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Asset=void 0;{var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(241),s=n(a),u=r(217),c=r(223),f=r(4),l=n(f),h=r(336),p=n(h),d=r(348),y=n(d);t.Asset=function(){function e(t,r){if(o(this,e),!/^[a-zA-Z0-9]{1,12}$/.test(t))throw new Error("Asset code is invalid (maximum alphanumeric, 12 characters at max)");if("xlm"!==String(t).toLowerCase()&&!r)throw new Error("Issuer cannot be null");if(r&&!c.StrKey.isValidEd25519PublicKey(r))throw new Error("Issuer is invalid");this.code=t,this.issuer=r}return i(e,[{key:"toXDRObject",value:function(){if(this.isNative())return s.default.Asset.assetTypeNative();var e=void 0,t=void 0;this.code.length<=4?(e=s.default.AssetAlphaNum4,t="assetTypeCreditAlphanum4"):(e=s.default.AssetAlphaNum12,t="assetTypeCreditAlphanum12");var r=this.code.length<=4?4:12,n=p.default(this.code,r,"\x00"),o=new e({assetCode:n,issuer:u.Keypair.fromPublicKey(this.issuer).xdrAccountId()});return new s.default.Asset(t,o)}},{key:"getCode",value:function(){return l.default(this.code)}},{key:"getIssuer",value:function(){return l.default(this.issuer)}},{key:"getAssetType",value:function(){return this.isNative()?"native":this.code.length>=1&&this.code.length<=4?"credit_alphanum4":this.code.length>=5&&this.code.length<=12?"credit_alphanum12":void 0}},{key:"isNative",value:function(){return!this.issuer}},{key:"equals",value:function(e){return this.code==e.getCode()&&this.issuer==e.getIssuer()}}],[{key:"native",value:function(){return new e("XLM")}},{key:"fromOperation",value:function(e){var t=void 0,r=void 0,n=void 0;switch(e.switch()){case s.default.AssetType.assetTypeNative():return this.native();case s.default.AssetType.assetTypeCreditAlphanum4():t=e.alphaNum4();case s.default.AssetType.assetTypeCreditAlphanum12():return t=t||e.alphaNum12(),n=c.StrKey.encodeEd25519PublicKey(t.issuer().ed25519()),r=y.default(t.assetCode(),"\x00"),new this(r,n);default:throw new Error("Invalid asset type: "+e.switch().name)}}}]),e}()}},function(e,t,r){function n(e,t,r){e=s(e),t=a(t);var n=t?i(e):0;return t&&t>n?e+o(t-n,r):e}var o=r(337),i=r(342),a=r(317),s=r(291);e.exports=n},function(e,t,r){function n(e,t){t=void 0===t?" ":i(t);var r=t.length;if(2>r)return r?o(t,e):t;var n=o(t,f(e/u(t)));return s(t)?a(c(n),0,e).join(""):n.slice(0,e)}var o=r(338),i=r(292),a=r(339),s=r(341),u=r(342),c=r(345),f=Math.ceil;e.exports=n},function(e){function t(e,t){var o="";if(!e||1>t||t>r)return o;do t%2&&(o+=e),t=n(t/2),t&&(e+=e);while(t);return o}var r=9007199254740991,n=Math.floor;e.exports=t},function(e,t,r){function n(e,t,r){var n=e.length;return r=void 0===r?n:r,!t&&r>=n?e:o(e,t,r)}var o=r(340);e.exports=n},function(e){function t(e,t,r){var n=-1,o=e.length;0>t&&(t=-t>o?0:o+t),r=r>o?o:r,0>r&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var i=Array(o);++n<o;)i[n]=e[n+t];return i}e.exports=t},function(e){function t(e){return c.test(e)}var r="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",a=n+o+i,s="\\ufe0e\\ufe0f",u="\\u200d",c=RegExp("["+u+r+a+s+"]");e.exports=t},function(e,t,r){function n(e){return i(e)?a(e):o(e)}var o=r(343),i=r(341),a=r(344);e.exports=n},function(e,t,r){var n=r(299),o=n("length");e.exports=o},function(e){function t(e){for(var t=_.lastIndex=0;_.test(e);)++t;return t}var r="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",a=n+o+i,s="\\ufe0e\\ufe0f",u="["+r+"]",c="["+a+"]",f="\\ud83c[\\udffb-\\udfff]",l="(?:"+c+"|"+f+")",h="[^"+r+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",d="[\\ud800-\\udbff][\\udc00-\\udfff]",y="\\u200d",v=l+"?",g="["+s+"]?",m="(?:"+y+"(?:"+[h,p,d].join("|")+")"+g+v+")*",b=g+v+m,w="(?:"+[h+c+"?",c,p,d,u].join("|")+")",_=RegExp(f+"(?="+f+")|"+w+b,"g");e.exports=t},function(e,t,r){function n(e){return i(e)?a(e):o(e)}var o=r(346),i=r(341),a=r(347);e.exports=n},function(e){function t(e){return e.split("")}e.exports=t},function(e){function t(e){return e.match(_)||[]}var r="\\ud800-\\udfff",n="\\u0300-\\u036f",o="\\ufe20-\\ufe2f",i="\\u20d0-\\u20ff",a=n+o+i,s="\\ufe0e\\ufe0f",u="["+r+"]",c="["+a+"]",f="\\ud83c[\\udffb-\\udfff]",l="(?:"+c+"|"+f+")",h="[^"+r+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",d="[\\ud800-\\udbff][\\udc00-\\udfff]",y="\\u200d",v=l+"?",g="["+s+"]?",m="(?:"+y+"(?:"+[h,p,d].join("|")+")"+g+v+")*",b=g+v+m,w="(?:"+[h+c+"?",c,p,d,u].join("|")+")",_=RegExp(f+"(?="+f+")|"+w+b,"g");e.exports=t},function(e,t,r){function n(e,t,r){if(e=u(e),e&&(r||void 0===t))return e.replace(c,"");if(!e||!(t=o(t)))return e;var n=s(e),f=a(n,s(t))+1;return i(n,0,f).join("")}var o=r(292),i=r(339),a=r(349),s=r(345),u=r(291),c=/\s+$/;e.exports=n},function(e,t,r){function n(e,t){for(var r=e.length;r--&&o(t,e[r],0)>-1;);return r}var o=r(350);e.exports=n},function(e,t,r){function n(e,t,r){return t===t?a(e,t,r):o(e,i,r)}var o=r(351),i=r(352),a=r(353);e.exports=n},function(e){function t(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1}e.exports=t},function(e){function t(e){return e!==e}e.exports=t},function(e){function t(e,t,r){for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}e.exports=t},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e){return String.fromCharCode.apply(null,new Uint16Array(e))}function a(e){for(var t=new ArrayBuffer(2*e.length),r=new Uint16Array(t),n=0,o=e.length;o>n;n++)r[n]=e.charCodeAt(n);return t}function s(e){for(var t=new ArrayBuffer(e.length),r=new Uint8Array(t),n=0;n<e.length;++n)r[n]=e[n];return t}function u(t){for(var r=new e(t.byteLength),n=new Uint8Array(t),o=0;o<r.length;++o)r[o]=n[o];return r}Object.defineProperty(t,"__esModule",{value:!0}),t.ContractInput=void 0;{var c=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),f=r(241),l=(n(f),r(4)),h=(n(l),r(336)),p=(n(h),r(348));n(p),t.ContractInput=function(){function e(t,r){o(this,e),this.funcName=t;var n=JSON.stringify(r),i=a(n),s=u(i);this.contractParams=s}return c(e,null,[{key:"fromOperation",value:function(e){var t=void 0,r=void 0;t=e.funcName().toString("ascii");var n=e.contractParams(),o=s(n),a=i(o);return r=JSON.parse(a),new this(t,r)}}]),e}()}}).call(t,r(156).Buffer)},function(e,t,r){var n;!function(o){"use strict";function i(e){function t(e,n){var o,i,a,s,u,c,f=this;if(!(f instanceof t))return H&&T(26,"constructor call without new",e),new t(e,n);if(null!=n&&V(n,2,64,B,"base")){if(n=0|n,c=e+"",10==n)return f=new t(e instanceof t?e:c),j(f,U+f.e+1,L);if((s="number"==typeof e)&&0*e!=0||!new RegExp("^-?"+(o="["+k.slice(0,n)+"]+")+"(?:\\."+o+")?$",37>n?"i":"").test(c))return I(f,c,s,n);s?(f.s=0>1/e?(c=c.slice(1),-1):1,H&&c.replace(/^0\.0*|\./,"").length>15&&T(B,_,e),s=!1):f.s=45===c.charCodeAt(0)?(c=c.slice(1),-1):1,c=r(c,10,n,f.s)}else{if(e instanceof t)return f.s=e.s,f.e=e.e,f.c=(e=e.c)?e.slice():e,B=0,void 0;if((s="number"==typeof e)&&0*e==0){if(f.s=0>1/e?(e=-e,-1):1,e===~~e){for(i=0,a=e;a>=10;a/=10,i++);return f.e=i,f.c=[e],B=0,void 0}c=e+""}else{if(!v.test(c=e+""))return I(f,c,s);f.s=45===c.charCodeAt(0)?(c=c.slice(1),-1):1}}for((i=c.indexOf("."))>-1&&(c=c.replace(".","")),(a=c.search(/e/i))>0?(0>i&&(i=a),i+=+c.slice(a+1),c=c.substring(0,a)):0>i&&(i=c.length),a=0;48===c.charCodeAt(a);a++);for(u=c.length;48===c.charCodeAt(--u););if(c=c.slice(a,u+1))if(u=c.length,s&&H&&u>15&&(e>E||e!==m(e))&&T(B,_,f.s*e),i=i-a-1,i>z)f.c=f.e=null;else if(F>i)f.c=[f.e=0];else{if(f.e=i,f.c=[],a=(i+1)%O,0>i&&(a+=O),u>a){for(a&&f.c.push(+c.slice(0,a)),u-=O;u>a;)f.c.push(+c.slice(a,a+=O));c=c.slice(a),a=O-c.length}else a-=u;for(;a--;c+="0");f.c.push(+c)}else f.c=[f.e=0];B=0}function r(e,r,n,o){var i,a,u,c,f,h,d,y=e.indexOf("."),v=U,g=L;for(37>n&&(e=e.toLowerCase()),y>=0&&(u=Q,Q=0,e=e.replace(".",""),d=new t(n),f=d.pow(e.length-y),Q=u,d.c=l(p(s(f.c),f.e),10,r),d.e=d.c.length),h=l(e,n,r),a=u=h.length;0==h[--u];h.pop());if(!h[0])return"0";if(0>y?--a:(f.c=h,f.e=a,f.s=o,f=R(f,d,v,g,r),h=f.c,c=f.r,a=f.e),i=a+v+1,y=h[i],u=r/2,c=c||0>i||null!=h[i+1],c=4>g?(null!=y||c)&&(0==g||g==(f.s<0?3:2)):y>u||y==u&&(4==g||c||6==g&&1&h[i-1]||g==(f.s<0?8:7)),1>i||!h[0])e=c?p("1",-v):"0";else{if(h.length=i,c)for(--r;++h[--i]>r;)h[i]=0,i||(++a,h=[1].concat(h));for(u=h.length;!h[--u];);for(y=0,e="";u>=y;e+=k.charAt(h[y++]));e=p(e,a)}return e}function n(e,r,n,o){var i,a,u,c,f;if(n=null!=n&&V(n,0,8,o,w)?0|n:L,!e.c)return e.toString();if(i=e.c[0],u=e.e,null==r)f=s(e.c),f=19==o||24==o&&D>=u?h(f,u):p(f,u);else if(e=j(new t(e),r,n),a=e.e,f=s(e.c),c=f.length,19==o||24==o&&(a>=r||D>=a)){for(;r>c;f+="0",c++);f=h(f,a)}else if(r-=u,f=p(f,a),a+1>c){if(--r>0)for(f+=".";r--;f+="0");}else if(r+=a-c,r>0)for(a+1==c&&(f+=".");r--;f+="0");return e.s<0&&i?"-"+f:f}function o(e,r){var n,o,i=0;for(f(e[0])&&(e=e[0]),n=new t(e[0]);++i<e.length;){if(o=new t(e[i]),!o.s){n=o;break}r.call(n,o)&&(n=o)}return n}function y(e,t,r,n,o){return(t>e||e>r||e!=d(e))&&T(n,(o||"decimal places")+(t>e||e>r?" out of range":" not an integer"),e),!0}function P(e,t,r){for(var n=1,o=t.length;!t[--o];t.pop());for(o=t[0];o>=10;o/=10,n++);return(r=n+r*O-1)>z?e.c=e.e=null:F>r?e.c=[e.e=0]:(e.e=r,e.c=t),e}function T(e,t,r){var n=new Error(["new BigNumber","cmp","config","div","divToInt","eq","gt","gte","lt","lte","minus","mod","plus","precision","random","round","shift","times","toDigits","toExponential","toFixed","toFormat","toFraction","pow","toPrecision","toString","BigNumber"][e]+"() "+t+": "+r);throw n.name="BigNumber Error",B=0,n}function j(e,t,r,n){var o,i,a,s,u,c,f,l=e.c,h=S;if(l){e:{for(o=1,s=l[0];s>=10;s/=10,o++);if(i=t-o,0>i)i+=O,a=t,u=l[c=0],f=u/h[o-a-1]%10|0;else if(c=g((i+1)/O),c>=l.length){if(!n)break e;for(;l.length<=c;l.push(0));u=f=0,o=1,i%=O,a=i-O+1}else{for(u=s=l[c],o=1;s>=10;s/=10,o++);i%=O,a=i-O+o,f=0>a?0:u/h[o-a-1]%10|0}if(n=n||0>t||null!=l[c+1]||(0>a?u:u%h[o-a-1]),n=4>r?(f||n)&&(0==r||r==(e.s<0?3:2)):f>5||5==f&&(4==r||n||6==r&&(i>0?a>0?u/h[o-a]:0:l[c-1])%10&1||r==(e.s<0?8:7)),1>t||!l[0])return l.length=0,n?(t-=e.e+1,l[0]=h[(O-t%O)%O],e.e=-t||0):l[0]=e.e=0,e;if(0==i?(l.length=c,s=1,c--):(l.length=c+1,s=h[O-i],l[c]=a>0?m(u/h[o-a]%h[a])*s:0),n)for(;;){if(0==c){for(i=1,a=l[0];a>=10;a/=10,i++);for(a=l[0]+=s,s=1;a>=10;a/=10,s++);i!=s&&(e.e++,l[0]==A&&(l[0]=1));break}if(l[c]+=s,l[c]!=A)break;l[c--]=0,s=1}for(i=l.length;0===l[--i];l.pop());}e.e>z?e.c=e.e=null:e.e<F&&(e.c=[e.e=0])}return e}var R,I,B=0,M=t.prototype,N=new t(1),U=20,L=4,D=-7,q=21,F=-1e7,z=1e7,H=!0,V=y,K=!1,X=1,Q=0,Y={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:"\xa0",fractionGroupSize:0};return t.another=i,t.ROUND_UP=0,t.ROUND_DOWN=1,t.ROUND_CEIL=2,t.ROUND_FLOOR=3,t.ROUND_HALF_UP=4,t.ROUND_HALF_DOWN=5,t.ROUND_HALF_EVEN=6,t.ROUND_HALF_CEIL=7,t.ROUND_HALF_FLOOR=8,t.EUCLID=9,t.config=t.set=function(){var e,t,r=0,n={},o=arguments,i=o[0],a=i&&"object"==typeof i?function(){return i.hasOwnProperty(t)?null!=(e=i[t]):void 0}:function(){return o.length>r?null!=(e=o[r++]):void 0};return a(t="DECIMAL_PLACES")&&V(e,0,C,2,t)&&(U=0|e),n[t]=U,a(t="ROUNDING_MODE")&&V(e,0,8,2,t)&&(L=0|e),n[t]=L,a(t="EXPONENTIAL_AT")&&(f(e)?V(e[0],-C,0,2,t)&&V(e[1],0,C,2,t)&&(D=0|e[0],q=0|e[1]):V(e,-C,C,2,t)&&(D=-(q=0|(0>e?-e:e)))),n[t]=[D,q],a(t="RANGE")&&(f(e)?V(e[0],-C,-1,2,t)&&V(e[1],1,C,2,t)&&(F=0|e[0],z=0|e[1]):V(e,-C,C,2,t)&&(0|e?F=-(z=0|(0>e?-e:e)):H&&T(2,t+" cannot be zero",e))),n[t]=[F,z],a(t="ERRORS")&&(e===!!e||1===e||0===e?(B=0,V=(H=!!e)?y:c):H&&T(2,t+b,e)),n[t]=H,a(t="CRYPTO")&&(e===!0||e===!1||1===e||0===e?e?(e="undefined"==typeof crypto,!e&&crypto&&(crypto.getRandomValues||crypto.randomBytes)?K=!0:H?T(2,"crypto unavailable",e?void 0:crypto):K=!1):K=!1:H&&T(2,t+b,e)),n[t]=K,a(t="MODULO_MODE")&&V(e,0,9,2,t)&&(X=0|e),n[t]=X,a(t="POW_PRECISION")&&V(e,0,C,2,t)&&(Q=0|e),n[t]=Q,a(t="FORMAT")&&("object"==typeof e?Y=e:H&&T(2,t+" not an object",e)),n[t]=Y,n},t.max=function(){return o(arguments,M.lt)},t.min=function(){return o(arguments,M.gt)},t.random=function(){var e=9007199254740992,r=Math.random()*e&2097151?function(){return m(Math.random()*e)}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(e){var n,o,i,a,s,u=0,c=[],f=new t(N);if(e=null!=e&&V(e,0,C,14)?0|e:U,a=g(e/O),K)if(crypto.getRandomValues){for(n=crypto.getRandomValues(new Uint32Array(a*=2));a>u;)s=131072*n[u]+(n[u+1]>>>11),s>=9e15?(o=crypto.getRandomValues(new Uint32Array(2)),n[u]=o[0],n[u+1]=o[1]):(c.push(s%1e14),u+=2);u=a/2}else if(crypto.randomBytes){for(n=crypto.randomBytes(a*=7);a>u;)s=281474976710656*(31&n[u])+1099511627776*n[u+1]+4294967296*n[u+2]+16777216*n[u+3]+(n[u+4]<<16)+(n[u+5]<<8)+n[u+6],s>=9e15?crypto.randomBytes(7).copy(n,u):(c.push(s%1e14),u+=7);u=a/7}else K=!1,H&&T(14,"crypto unavailable",crypto);if(!K)for(;a>u;)s=r(),9e15>s&&(c[u++]=s%1e14);for(a=c[--u],e%=O,a&&e&&(s=S[O-e],c[u]=m(a/s)*s);0===c[u];c.pop(),u--);if(0>u)c=[i=0];else{for(i=-1;0===c[0];c.splice(0,1),i-=O);for(u=1,s=c[0];s>=10;s/=10,u++);O>u&&(i-=O-u)}return f.e=i,f.c=c,f}}(),R=function(){function e(e,t,r){var n,o,i,a,s=0,u=e.length,c=t%x,f=t/x|0;for(e=e.slice();u--;)i=e[u]%x,a=e[u]/x|0,n=f*i+a*c,o=c*i+n%x*x+s,s=(o/r|0)+(n/x|0)+f*a,e[u]=o%r;return s&&(e=[s].concat(e)),e}function r(e,t,r,n){var o,i;if(r!=n)i=r>n?1:-1;else for(o=i=0;r>o;o++)if(e[o]!=t[o]){i=e[o]>t[o]?1:-1;break}return i}function n(e,t,r,n){for(var o=0;r--;)e[r]-=o,o=e[r]<t[r]?1:0,e[r]=o*n+e[r]-t[r];for(;!e[0]&&e.length>1;e.splice(0,1));}return function(o,i,s,u,c){var f,l,h,p,d,y,v,g,b,w,_,k,E,S,x,C,P,T=o.s==i.s?1:-1,R=o.c,I=i.c;if(!(R&&R[0]&&I&&I[0]))return new t(o.s&&i.s&&(R?!I||R[0]!=I[0]:I)?R&&0==R[0]||!I?0*T:T/0:0/0);for(g=new t(T),b=g.c=[],l=o.e-i.e,T=s+l+1,c||(c=A,l=a(o.e/O)-a(i.e/O),T=T/O|0),h=0;I[h]==(R[h]||0);h++);if(I[h]>(R[h]||0)&&l--,0>T)b.push(1),p=!0;else{for(S=R.length,C=I.length,h=0,T+=2,d=m(c/(I[0]+1)),d>1&&(I=e(I,d,c),R=e(R,d,c),C=I.length,S=R.length),E=C,w=R.slice(0,C),_=w.length;C>_;w[_++]=0);P=I.slice(),P=[0].concat(P),x=I[0],I[1]>=c/2&&x++;do{if(d=0,f=r(I,w,C,_),0>f){if(k=w[0],C!=_&&(k=k*c+(w[1]||0)),d=m(k/x),d>1)for(d>=c&&(d=c-1),y=e(I,d,c),v=y.length,_=w.length;1==r(y,w,v,_);)d--,n(y,v>C?P:I,v,c),v=y.length,f=1;else 0==d&&(f=d=1),y=I.slice(),v=y.length;if(_>v&&(y=[0].concat(y)),n(w,y,_,c),_=w.length,-1==f)for(;r(I,w,C,_)<1;)d++,n(w,_>C?P:I,_,c),_=w.length}else 0===f&&(d++,w=[0]);b[h++]=d,w[0]?w[_++]=R[E]||0:(w=[R[E]],_=1)}while((E++<S||null!=w[0])&&T--);p=null!=w[0],b[0]||b.splice(0,1)}if(c==A){for(h=1,T=b[0];T>=10;T/=10,h++);j(g,s+(g.e=h+l*O-1)+1,u,p)}else g.e=l,g.r=+p;return g}}(),I=function(){var e=/^(-?)0([xbo])(?=\w[\w.]*$)/i,r=/^([^.]+)\.$/,n=/^\.([^.]+)$/,o=/^-?(Infinity|NaN)$/,i=/^\s*\+(?=[\w.])|^\s+|\s+$/g;return function(a,s,u,c){var f,l=u?s:s.replace(i,"");if(o.test(l))a.s=isNaN(l)?null:0>l?-1:1;else{if(!u&&(l=l.replace(e,function(e,t,r){return f="x"==(r=r.toLowerCase())?16:"b"==r?2:8,c&&c!=f?e:t}),c&&(f=c,l=l.replace(r,"$1").replace(n,"0.$1")),s!=l))return new t(l,f);H&&T(B,"not a"+(c?" base "+c:"")+" number",s),a.s=null}a.c=a.e=null,B=0}}(),M.absoluteValue=M.abs=function(){var e=new t(this);return e.s<0&&(e.s=1),e},M.ceil=function(){return j(new t(this),this.e+1,2)},M.comparedTo=M.cmp=function(e,r){return B=1,u(this,new t(e,r))},M.decimalPlaces=M.dp=function(){var e,t,r=this.c;if(!r)return null;if(e=((t=r.length-1)-a(this.e/O))*O,t=r[t])for(;t%10==0;t/=10,e--);return 0>e&&(e=0),e},M.dividedBy=M.div=function(e,r){return B=3,R(this,new t(e,r),U,L)},M.dividedToIntegerBy=M.divToInt=function(e,r){return B=4,R(this,new t(e,r),0,1)},M.equals=M.eq=function(e,r){return B=5,0===u(this,new t(e,r))},M.floor=function(){return j(new t(this),this.e+1,3)},M.greaterThan=M.gt=function(e,r){return B=6,u(this,new t(e,r))>0},M.greaterThanOrEqualTo=M.gte=function(e,r){return B=7,1===(r=u(this,new t(e,r)))||0===r},M.isFinite=function(){return!!this.c},M.isInteger=M.isInt=function(){return!!this.c&&a(this.e/O)>this.c.length-2},M.isNaN=function(){return!this.s},M.isNegative=M.isNeg=function(){return this.s<0},M.isZero=function(){return!!this.c&&0==this.c[0]},M.lessThan=M.lt=function(e,r){return B=8,u(this,new t(e,r))<0},M.lessThanOrEqualTo=M.lte=function(e,r){return B=9,-1===(r=u(this,new t(e,r)))||0===r},M.minus=M.sub=function(e,r){var n,o,i,s,u=this,c=u.s;if(B=10,e=new t(e,r),r=e.s,!c||!r)return new t(0/0);if(c!=r)return e.s=-r,u.plus(e);var f=u.e/O,l=e.e/O,h=u.c,p=e.c;if(!f||!l){if(!h||!p)return h?(e.s=-r,e):new t(p?u:0/0);if(!h[0]||!p[0])return p[0]?(e.s=-r,e):new t(h[0]?u:3==L?-0:0)}if(f=a(f),l=a(l),h=h.slice(),c=f-l){for((s=0>c)?(c=-c,i=h):(l=f,i=p),i.reverse(),r=c;r--;i.push(0));i.reverse()}else for(o=(s=(c=h.length)<(r=p.length))?c:r,c=r=0;o>r;r++)if(h[r]!=p[r]){s=h[r]<p[r];break}if(s&&(i=h,h=p,p=i,e.s=-e.s),r=(o=p.length)-(n=h.length),r>0)for(;r--;h[n++]=0);for(r=A-1;o>c;){if(h[--o]<p[o]){for(n=o;n&&!h[--n];h[n]=r);--h[n],h[o]+=A}h[o]-=p[o]}for(;0==h[0];h.splice(0,1),--l);return h[0]?P(e,h,l):(e.s=3==L?-1:1,e.c=[e.e=0],e)},M.modulo=M.mod=function(e,r){var n,o,i=this;return B=11,e=new t(e,r),!i.c||!e.s||e.c&&!e.c[0]?new t(0/0):!e.c||i.c&&!i.c[0]?new t(i):(9==X?(o=e.s,e.s=1,n=R(i,e,0,3),e.s=o,n.s*=o):n=R(i,e,0,X),i.minus(n.times(e)))},M.negated=M.neg=function(){var e=new t(this);return e.s=-e.s||null,e},M.plus=M.add=function(e,r){var n,o=this,i=o.s;if(B=12,e=new t(e,r),r=e.s,!i||!r)return new t(0/0);if(i!=r)return e.s=-r,o.minus(e);var s=o.e/O,u=e.e/O,c=o.c,f=e.c;if(!s||!u){if(!c||!f)return new t(i/0);if(!c[0]||!f[0])return f[0]?e:new t(c[0]?o:0*i)}if(s=a(s),u=a(u),c=c.slice(),i=s-u){for(i>0?(u=s,n=f):(i=-i,n=c),n.reverse();i--;n.push(0));n.reverse()}for(i=c.length,r=f.length,0>i-r&&(n=f,f=c,c=n,r=i),i=0;r;)i=(c[--r]=c[r]+f[r]+i)/A|0,c[r]=A===c[r]?0:c[r]%A;return i&&(c=[i].concat(c),++u),P(e,c,u)},M.precision=M.sd=function(e){var t,r,n=this,o=n.c;if(null!=e&&e!==!!e&&1!==e&&0!==e&&(H&&T(13,"argument"+b,e),e!=!!e&&(e=null)),!o)return null;if(r=o.length-1,t=r*O+1,r=o[r]){for(;r%10==0;r/=10,t--);for(r=o[0];r>=10;r/=10,t++);}return e&&n.e+1>t&&(t=n.e+1),t},M.round=function(e,r){var n=new t(this);return(null==e||V(e,0,C,15))&&j(n,~~e+this.e+1,null!=r&&V(r,0,8,15,w)?0|r:L),n},M.shift=function(e){var r=this;return V(e,-E,E,16,"argument")?r.times("1e"+d(e)):new t(r.c&&r.c[0]&&(-E>e||e>E)?r.s*(0>e?0:1/0):r)},M.squareRoot=M.sqrt=function(){var e,r,n,o,i,u=this,c=u.c,f=u.s,l=u.e,h=U+4,p=new t("0.5");if(1!==f||!c||!c[0])return new t(!f||0>f&&(!c||c[0])?0/0:c?u:1/0);if(f=Math.sqrt(+u),0==f||f==1/0?(r=s(c),(r.length+l)%2==0&&(r+="0"),f=Math.sqrt(r),l=a((l+1)/2)-(0>l||l%2),f==1/0?r="1e"+l:(r=f.toExponential(),r=r.slice(0,r.indexOf("e")+1)+l),n=new t(r)):n=new t(f+""),n.c[0])for(l=n.e,f=l+h,3>f&&(f=0);;)if(i=n,n=p.times(i.plus(R(u,i,h,1))),s(i.c).slice(0,f)===(r=s(n.c)).slice(0,f)){if(n.e<l&&--f,r=r.slice(f-3,f+1),"9999"!=r&&(o||"4999"!=r)){(!+r||!+r.slice(1)&&"5"==r.charAt(0))&&(j(n,n.e+U+2,1),e=!n.times(n).eq(u));break}if(!o&&(j(i,i.e+U+2,0),i.times(i).eq(u))){n=i;break}h+=4,f+=4,o=1}return j(n,n.e+U+1,L,e)},M.times=M.mul=function(e,r){var n,o,i,s,u,c,f,l,h,p,d,y,v,g,m,b=this,w=b.c,_=(B=17,e=new t(e,r)).c;if(!(w&&_&&w[0]&&_[0]))return!b.s||!e.s||w&&!w[0]&&!_||_&&!_[0]&&!w?e.c=e.e=e.s=null:(e.s*=b.s,w&&_?(e.c=[0],e.e=0):e.c=e.e=null),e;for(o=a(b.e/O)+a(e.e/O),e.s*=b.s,f=w.length,p=_.length,p>f&&(v=w,w=_,_=v,i=f,f=p,p=i),i=f+p,v=[];i--;v.push(0));for(g=A,m=x,i=p;--i>=0;){for(n=0,d=_[i]%m,y=_[i]/m|0,u=f,s=i+u;s>i;)l=w[--u]%m,h=w[u]/m|0,c=y*l+h*d,l=d*l+c%m*m+v[s]+n,n=(l/g|0)+(c/m|0)+y*h,v[s--]=l%g;v[s]=n}return n?++o:v.splice(0,1),P(e,v,o)},M.toDigits=function(e,r){var n=new t(this);return e=null!=e&&V(e,1,C,18,"precision")?0|e:null,r=null!=r&&V(r,0,8,18,w)?0|r:L,e?j(n,e,r):n},M.toExponential=function(e,t){return n(this,null!=e&&V(e,0,C,19)?~~e+1:null,t,19)},M.toFixed=function(e,t){return n(this,null!=e&&V(e,0,C,20)?~~e+this.e+1:null,t,20)},M.toFormat=function(e,t){var r=n(this,null!=e&&V(e,0,C,21)?~~e+this.e+1:null,t,21);if(this.c){var o,i=r.split("."),a=+Y.groupSize,s=+Y.secondaryGroupSize,u=Y.groupSeparator,c=i[0],f=i[1],l=this.s<0,h=l?c.slice(1):c,p=h.length;if(s&&(o=a,a=s,s=o,p-=o),a>0&&p>0){for(o=p%a||a,c=h.substr(0,o);p>o;o+=a)c+=u+h.substr(o,a);s>0&&(c+=u+h.slice(o)),l&&(c="-"+c)}r=f?c+Y.decimalSeparator+((s=+Y.fractionGroupSize)?f.replace(new RegExp("\\d{"+s+"}\\B","g"),"$&"+Y.fractionGroupSeparator):f):c}return r},M.toFraction=function(e){var r,n,o,i,a,u,c,f,l,h=H,p=this,d=p.c,y=new t(N),v=n=new t(N),g=c=new t(N);if(null!=e&&(H=!1,u=new t(e),H=h,(!(h=u.isInt())||u.lt(N))&&(H&&T(22,"max denominator "+(h?"out of range":"not an integer"),e),e=!h&&u.c&&j(u,u.e+1,1).gte(N)?u:null)),!d)return p.toString();for(l=s(d),i=y.e=l.length-p.e-1,y.c[0]=S[(a=i%O)<0?O+a:a],e=!e||u.cmp(y)>0?i>0?y:v:u,a=z,z=1/0,u=new t(l),c.c[0]=0;f=R(u,y,0,1),o=n.plus(f.times(g)),1!=o.cmp(e);)n=g,g=o,v=c.plus(f.times(o=v)),c=o,y=u.minus(f.times(o=y)),u=o;return o=R(e.minus(n),g,0,1),c=c.plus(o.times(v)),n=n.plus(o.times(g)),c.s=v.s=p.s,i*=2,r=R(v,g,i,L).minus(p).abs().cmp(R(c,n,i,L).minus(p).abs())<1?[v.toString(),g.toString()]:[c.toString(),n.toString()],z=a,r},M.toNumber=function(){return+this},M.toPower=M.pow=function(e,r){var n,o,i,a=m(0>e?-e:+e),s=this;if(null!=r&&(B=23,r=new t(r)),!V(e,-E,E,23,"exponent")&&(!isFinite(e)||a>E&&(e/=0)||parseFloat(e)!=e&&!(e=0/0))||0==e)return n=Math.pow(+s,e),new t(r?n%r:n);for(r?e>1&&s.gt(N)&&s.isInt()&&r.gt(N)&&r.isInt()?s=s.mod(r):(i=r,r=null):Q&&(n=g(Q/O+2)),o=new t(N);;){if(a%2){if(o=o.times(s),!o.c)break;n?o.c.length>n&&(o.c.length=n):r&&(o=o.mod(r))}if(a=m(a/2),!a)break;s=s.times(s),n?s.c&&s.c.length>n&&(s.c.length=n):r&&(s=s.mod(r))}return r?o:(0>e&&(o=N.div(o)),i?o.mod(i):n?j(o,Q,L):o)},M.toPrecision=function(e,t){return n(this,null!=e&&V(e,1,C,24,"precision")?0|e:null,t,24)},M.toString=function(e){var t,n=this,o=n.s,i=n.e;return null===i?o?(t="Infinity",0>o&&(t="-"+t)):t="NaN":(t=s(n.c),t=null!=e&&V(e,2,64,25,"base")?r(p(t,i),0|e,10,o):D>=i||i>=q?h(t,i):p(t,i),0>o&&n.c[0]&&(t="-"+t)),t},M.truncated=M.trunc=function(){return j(new t(this),this.e+1,1)},M.valueOf=M.toJSON=function(){var e,t=this,r=t.e;return null===r?t.toString():(e=s(t.c),e=D>=r||r>=q?h(e,r):p(e,r),t.s<0?"-"+e:e)},M.isBigNumber=!0,null!=e&&t.config(e),t}function a(e){var t=0|e;return e>0||e===t?t:t-1}function s(e){for(var t,r,n=1,o=e.length,i=e[0]+"";o>n;){for(t=e[n++]+"",r=O-t.length;r--;t="0"+t);i+=t}for(o=i.length;48===i.charCodeAt(--o););return i.slice(0,o+1||1)}function u(e,t){var r,n,o=e.c,i=t.c,a=e.s,s=t.s,u=e.e,c=t.e;if(!a||!s)return null;if(r=o&&!o[0],n=i&&!i[0],r||n)return r?n?0:-s:a;if(a!=s)return a;if(r=0>a,n=u==c,!o||!i)return n?0:!o^r?1:-1;if(!n)return u>c^r?1:-1;for(s=(u=o.length)<(c=i.length)?u:c,a=0;s>a;a++)if(o[a]!=i[a])return o[a]>i[a]^r?1:-1;return u==c?0:u>c^r?1:-1}function c(e,t,r){return(e=d(e))>=t&&r>=e}function f(e){return"[object Array]"==Object.prototype.toString.call(e)}function l(e,t,r){for(var n,o,i=[0],a=0,s=e.length;s>a;){for(o=i.length;o--;i[o]*=t);for(i[n=0]+=k.indexOf(e.charAt(a++));n<i.length;n++)i[n]>r-1&&(null==i[n+1]&&(i[n+1]=0),i[n+1]+=i[n]/r|0,i[n]%=r)}return i.reverse()}function h(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(0>t?"e":"e+")+t}function p(e,t){var r,n;if(0>t){for(n="0.";++t;n+="0");e=n+e}else if(r=e.length,++t>r){for(n="0",t-=r;--t;n+="0");e+=n}else r>t&&(e=e.slice(0,t)+"."+e.slice(t));return e}function d(e){return e=parseFloat(e),0>e?g(e):m(e)}var y,v=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,g=Math.ceil,m=Math.floor,b=" not a boolean or binary digit",w="rounding mode",_="number type has more than 15 significant digits",k="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",A=1e14,O=14,E=9007199254740991,S=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],x=1e7,C=1e9;y=i(),y["default"]=y.BigNumber=y,n=function(){return y}.call(t,r,t,e),!(void 0!==n&&(e.exports=n))}(this)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e){e=new s.default(e);for(var t,r,n=[[new s.default(0),new s.default(1)],[new s.default(1),new s.default(0)]],o=2;;){if(e.gt(u))break;t=e.floor(),r=e.sub(t);var a=t.mul(n[o-1][0]).add(n[o-2][0]),c=t.mul(n[o-1][1]).add(n[o-2][1]);if(a.gt(u)||c.gt(u))break;if(n.push([a,c]),r.eq(0))break;e=new s.default(1).div(r),o++}var f=i(n[n.length-1],2),l=f[0],h=f[1];if(l.isZero()||h.isZero())throw new Error("Couldn't find approximation");return[l.toNumber(),h.toNumber()]}Object.defineProperty(t,"__esModule",{value:!0});var i=function(){function e(e,t){var r=[],n=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(n=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);n=!0);}catch(u){o=!0,i=u}finally{try{!n&&s["return"]&&s["return"]()}finally{if(o)throw i}}return r}return function(t,r){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();t.best_r=o;var a=r(355),s=n(a),u=2147483647},function(e,t,r){function n(e){return"number"==typeof e&&i(e)}var o=r(26),i=o.isFinite;e.exports=n},function(e,t,r){"use strict";function n(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{"default":e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.ContrOperation=void 0;var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(241),u=o(s),c=(r(217),r(204),r(223)),f=r(242),l=r(335),h=r(355),p=o(h),d=r(356),y=r(348),v=(o(y),r(221)),g=o(v),m=r(240),b=o(m),w=r(245),_=o(w),k=r(357),A=o(k),O=r(359),E=n(O),S=1e7,x="9223372036854775807",C=t.ContrOperation=function(){function e(){i(this,e)}return a(e,null,[{key:"fromXDRObject",value:function(e){function t(e){return c.StrKey.encodeEd25519PublicKey(e.ed25519())}var r={},n=e.body().value();switch(e.body().switch().name){case"check":r.type="check",r.sourceAccId=t(n.sourceAccId()),r.op=n.op().toString("ascii"),r.amount=this._fromXDRAmount(n.amount());break;case"invoke":r.type="invoke",r.newState=n.newState();break;case"query":r.type="query",r.data=n.data();break;case"transfer":r.destination=t(n.destination()),r.asset=l.Asset.fromOperation(n.asset()),r.amount=this._fromXDRAmount(n.amount());break;default:throw new Error("Unknown contract opration")
}return r}},{key:"isValidAmount",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:!1;if(!b.default(e))return!1;var r=void 0;try{r=new p.default(e)}catch(n){return!1}switch(!0){case!t&&r.isZero():case r.isNegative():case r.times(S).greaterThan(new p.default(x).toString()):case r.decimalPlaces()>7:case r.isNaN()||!r.isFinite():return!1;default:return!0}}},{key:"constructAmountRequirementsError",value:function(e){return e+" argument must be of type String, represent a positive number and have at most 7 digits after the decimal"}},{key:"_checkUnsignedIntValue",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(g.default(t))return void 0;switch(b.default(t)&&(t=parseFloat(t)),!0){case!_.default(t)||!A.default(t)||t%1!==0:throw new Error(e+" value is invalid");case 0>t:throw new Error(e+" value must be unsigned");case!r||r&&r(t,e):return t;default:throw new Error(e+" value is invalid")}}},{key:"_toXDRAmount",value:function(e){var t=new p.default(e).mul(S);return f.Hyper.fromString(t.toString())}},{key:"_fromXDRAmount",value:function(e){return new p.default(e).div(S).toString()}},{key:"_fromXDRPrice",value:function(e){var t=new p.default(e.n());return t.div(new p.default(e.d())).toString()}},{key:"_toXDRPrice",value:function(e){var t=void 0;if(e.n&&e.d)t=new u.default.Price(e);else{e=new p.default(e);var r=d.best_r(e);t=new u.default.Price({n:parseInt(r[0]),d:parseInt(r[1])})}if(t.n()<0||t.d()<0)throw new Error("price must be positive");return t}}]),e}();C.check=E.check,C.invoke=E.invoke,C.query=E.query,C.transfer=E.transfer},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(360);Object.defineProperty(t,"check",{enumerable:!0,get:function(){return n.check}});var o=r(361);Object.defineProperty(t,"invoke",{enumerable:!0,get:function(){return o.invoke}});var i=r(362);Object.defineProperty(t,"query",{enumerable:!0,get:function(){return i.query}});var a=r(363);Object.defineProperty(t,"transfer",{enumerable:!0,get:function(){return a.transfer}})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.check=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223);t.check=function u(e){if(!s.StrKey.isValidEd25519PublicKey(e.sourceAccId))throw new Error("destination is invalid");if(!this.isValidAmount(e.amount))throw new TypeError(this.constructAmountRequirementsError("amount"));var t={};t.sourceAccId=a.Keypair.fromPublicKey(e.sourceAccId).xdrAccountId(),t.op=e.op,t.amount=this._toXDRAmount(e.amount);var u=new i.default.Check(t),r={};return r.body=i.default.ContrOperationBody.check(u),new i.default.ContrOperation(r)}}},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.invoke=void 0;{var o=r(241),i=n(o),a=(r(217),r(223),r(221)),s=(n(a),r(240)),u=n(s);t.invoke=function c(t){var r={};if(!u.default(t.newState)&&!e.isBuffer(t.newState)&&null!==t.newState)throw new Error("newState must be a string, Buffer or null");u.default(t.newState)&&(t.newState=e.from(t.newState)),r.newState=t.newState;var c=new i.default.Invoke(r),n={};return n.body=i.default.ContrOperationBody.invoke(c),new i.default.ContrOperation(n)}}}).call(t,r(156).Buffer)},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.query=void 0;{var o=r(241),i=n(o),a=(r(217),r(223),r(221)),s=(n(a),r(240)),u=n(s);t.query=function c(t){var r={};if(!u.default(t.data)&&!e.isBuffer(t.data)&&null!==t.data)throw new Error("data must be a string, Buffer or null");u.default(t.data)&&(t.data=e.from(t.data)),r.data=t.data;var c=new i.default.Query(r),n={};return n.body=i.default.ContrOperationBody.query(c),new i.default.ContrOperation(n)}}}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.transfer=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223);t.transfer=function u(e){if(!s.StrKey.isValidEd25519PublicKey(e.destination))throw new Error("destination is invalid");if(!e.asset)throw new Error("Must provide an asset for a payment operation");if(!this.isValidAmount(e.amount))throw new TypeError(this.constructAmountRequirementsError("amount"));var t={};t.destination=a.Keypair.fromPublicKey(e.destination).xdrAccountId(),t.asset=e.asset.toXDRObject(),t.amount=this._toXDRAmount(e.amount);var u=new i.default.Transfer(t),r={};return r.body=i.default.ContrOperationBody.transfer(u),new i.default.ContrOperation(r)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(365);Object.defineProperty(t,"accountMerge",{enumerable:!0,get:function(){return n.accountMerge}});var o=r(366);Object.defineProperty(t,"allowTrust",{enumerable:!0,get:function(){return o.allowTrust}});var i=r(367);Object.defineProperty(t,"bumpSequence",{enumerable:!0,get:function(){return i.bumpSequence}});var a=r(368);Object.defineProperty(t,"changeTrust",{enumerable:!0,get:function(){return a.changeTrust}});var s=r(369);Object.defineProperty(t,"createAccount",{enumerable:!0,get:function(){return s.createAccount}});var u=r(370);Object.defineProperty(t,"createPassiveOffer",{enumerable:!0,get:function(){return u.createPassiveOffer}});var c=r(371);Object.defineProperty(t,"inflation",{enumerable:!0,get:function(){return c.inflation}});var f=r(372);Object.defineProperty(t,"manageData",{enumerable:!0,get:function(){return f.manageData}});var l=r(373);Object.defineProperty(t,"manageOffer",{enumerable:!0,get:function(){return l.manageOffer}});var h=r(374);Object.defineProperty(t,"pathPayment",{enumerable:!0,get:function(){return h.pathPayment}});var p=r(375);Object.defineProperty(t,"payment",{enumerable:!0,get:function(){return p.payment}});var d=r(376);Object.defineProperty(t,"setOptions",{enumerable:!0,get:function(){return d.setOptions}});var y=r(377);Object.defineProperty(t,"createAsset",{enumerable:!0,get:function(){return y.createAsset}});var v=r(379);Object.defineProperty(t,"changeAsset",{enumerable:!0,get:function(){return v.changeAsset}});var g=r(380);Object.defineProperty(t,"limitAsset",{enumerable:!0,get:function(){return g.limitAsset}});var m=r(381);Object.defineProperty(t,"createContract",{enumerable:!0,get:function(){return m.createContract}});var b=r(382);Object.defineProperty(t,"callContract",{enumerable:!0,get:function(){return b.callContract}});var w=r(383);Object.defineProperty(t,"sendAsset",{enumerable:!0,get:function(){return w.sendAsset}});var _=r(384);Object.defineProperty(t,"checkContract",{enumerable:!0,get:function(){return _.checkContract}});var k=r(385);Object.defineProperty(t,"testContract",{enumerable:!0,get:function(){return k.testContract}})},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.accountMerge=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223);t.accountMerge=function(e){var t={};if(!s.StrKey.isValidEd25519PublicKey(e.destination))throw new Error("destination is invalid");return t.body=i.default.OperationBody.accountMerge(a.Keypair.fromPublicKey(e.destination).xdrAccountId()),this.setSourceAccount(t,e),new i.default.Operation(t)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.allowTrust=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223),u=r(336),c=n(u);t.allowTrust=function(e){if(!s.StrKey.isValidEd25519PublicKey(e.trustor))throw new Error("trustor is invalid");var t={};if(t.trustor=a.Keypair.fromPublicKey(e.trustor).xdrAccountId(),e.assetCode.length<=4){var r=c.default(e.assetCode,4,"\x00");t.asset=i.default.AllowTrustOpAsset.assetTypeCreditAlphanum4(r)}else{if(!(e.assetCode.length<=12))throw new Error("Asset code must be 12 characters at max.");var n=c.default(e.assetCode,12,"\x00");t.asset=i.default.AllowTrustOpAsset.assetTypeCreditAlphanum12(n)}t.authorize=e.authorize;var o=new i.default.AllowTrustOp(t),u={};return u.body=i.default.OperationBody.allowTrust(o),this.setSourceAccount(u,e),new i.default.Operation(u)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.bumpSequence=void 0;{var o=r(241),i=n(o),a=r(242),s=r(355),u=n(s),c=r(240),f=n(c);t.bumpSequence=function(e){var t={};if(!f.default(e.bumpTo))throw new Error("bumpTo must be a string");try{new u.default(e.bumpTo)}catch(r){throw new Error("bumpTo must be a stringified number")}t.bumpTo=a.Hyper.fromString(e.bumpTo);var n=new i.default.BumpSequenceOp(t),o={};return o.body=i.default.OperationBody.bumpSequence(n),this.setSourceAccount(o,e),new i.default.Operation(o)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.changeTrust=void 0;{var o=r(241),i=n(o),a=(r(217),r(221)),s=n(a),u=r(242),c=r(355),f=n(c),l="9223372036854775807";t.changeTrust=function(e){var t={};if(t.line=e.asset.toXDRObject(),!s.default(e.limit)&&!this.isValidAmount(e.limit,!0))throw new TypeError(this.constructAmountRequirementsError("limit"));t.limit=e.limit?this._toXDRAmount(e.limit):u.Hyper.fromString(new f.default(l).toString()),e.source&&(t.source=e.source.masterKeypair);var r=new i.default.ChangeTrustOp(t),n={};return n.body=i.default.OperationBody.changeTrust(r),this.setSourceAccount(n,e),new i.default.Operation(n)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createAccount=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223);t.createAccount=function u(e){if(!s.StrKey.isValidEd25519PublicKey(e.destination))throw new Error("destination is invalid");if(!this.isValidAmount(e.startingBalance))throw new TypeError(this.constructAmountRequirementsError("startingBalance"));var t={};t.destination=a.Keypair.fromPublicKey(e.destination).xdrAccountId(),t.startingBalance=this._toXDRAmount(e.startingBalance);var u=new i.default.CreateAccountOp(t),r={};return r.body=i.default.OperationBody.createAccount(u),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createPassiveOffer=void 0;{var o=r(241),i=n(o),a=r(221),s=n(a);t.createPassiveOffer=function(e){var t={};if(t.selling=e.selling.toXDRObject(),t.buying=e.buying.toXDRObject(),!this.isValidAmount(e.amount))throw new TypeError(this.constructAmountRequirementsError("amount"));if(t.amount=this._toXDRAmount(e.amount),s.default(e.price))throw new TypeError("price argument is required");t.price=this._toXDRPrice(e.price);var r=new i.default.CreatePassiveOfferOp(t),n={};return n.body=i.default.OperationBody.createPassiveOffer(r),this.setSourceAccount(n,e),new i.default.Operation(n)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.inflation=void 0;{var o=r(241),i=n(o);t.inflation=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={};return t.body=i.default.OperationBody.inflation(),this.setSourceAccount(t,e),new i.default.Operation(t)}}},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.manageData=void 0;{var o=r(241),i=n(o),a=r(240),s=n(a);t.manageData=function(t){var r={};if(!(s.default(t.name)&&t.name.length<=64))throw new Error("name must be a string, up to 64 characters");if(r.dataName=t.name,!s.default(t.value)&&!e.isBuffer(t.value)&&null!==t.value)throw new Error("value must be a string, Buffer or null");if(r.dataValue=s.default(t.value)?e.from(t.value):t.value,null!==r.dataValue&&r.dataValue.length>64)throw new Error("value cannot be longer that 64 bytes");var n=new i.default.ManageDataOp(r),o={};return o.body=i.default.OperationBody.manageDatum(n),this.setSourceAccount(o,t),new i.default.Operation(o)}}}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.manageOffer=void 0;{var o=r(241),i=n(o),a=r(221),s=n(a),u=r(242);t.manageOffer=function(e){var t={};if(t.selling=e.selling.toXDRObject(),t.buying=e.buying.toXDRObject(),!this.isValidAmount(e.amount,!0))throw new TypeError(this.constructAmountRequirementsError("amount"));if(t.amount=this._toXDRAmount(e.amount),s.default(e.price))throw new TypeError("price argument is required");t.price=this._toXDRPrice(e.price),e.offerId=s.default(e.offerId)?"0":e.offerId.toString(),t.offerId=u.UnsignedHyper.fromString(e.offerId);var r=new i.default.ManageOfferOp(t),n={};return n.body=i.default.OperationBody.manageOffer(r),this.setSourceAccount(n,e),new i.default.Operation(n)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.pathPayment=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223);t.pathPayment=function(e){switch(!0){case!e.sendAsset:throw new Error("Must specify a send asset");case!this.isValidAmount(e.sendMax):throw new TypeError(this.constructAmountRequirementsError("sendMax"));case!s.StrKey.isValidEd25519PublicKey(e.destination):throw new Error("destination is invalid");case!e.destAsset:throw new Error("Must provide a destAsset for a payment operation");case!this.isValidAmount(e.destAmount):throw new TypeError(this.constructAmountRequirementsError("destAmount"))}var t={};t.sendAsset=e.sendAsset.toXDRObject(),t.sendMax=this._toXDRAmount(e.sendMax),t.destination=a.Keypair.fromPublicKey(e.destination).xdrAccountId(),t.destAsset=e.destAsset.toXDRObject(),t.destAmount=this._toXDRAmount(e.destAmount);var r=e.path?e.path:[];t.path=r.map(function(e){return e.toXDRObject()});var n=new i.default.PathPaymentOp(t),o={};return o.body=i.default.OperationBody.pathPayment(n),this.setSourceAccount(o,e),new i.default.Operation(o)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.payment=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223);t.payment=function u(e){if(!s.StrKey.isValidEd25519PublicKey(e.destination))throw new Error("destination is invalid");if(!e.asset)throw new Error("Must provide an asset for a payment operation");if(!this.isValidAmount(e.amount))throw new TypeError(this.constructAmountRequirementsError("amount"));var t={};t.destination=a.Keypair.fromPublicKey(e.destination).xdrAccountId(),t.asset=e.asset.toXDRObject(),t.amount=this._toXDRAmount(e.amount);var u=new i.default.PaymentOp(t),r={};return r.body=i.default.OperationBody.payment(u),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.setOptions=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223),u=r(221),c=n(u),f=r(240),l=n(f);t.setOptions=function(t){var r={};if(t.inflationDest){if(!s.StrKey.isValidEd25519PublicKey(t.inflationDest))throw new Error("inflationDest is invalid");r.inflationDest=a.Keypair.fromPublicKey(t.inflationDest).xdrAccountId()}var n=function(e,t){if(e>=0&&255>=e)return!0;throw new Error(t+" value must be between 0 and 255")};if(r.clearFlags=this._checkUnsignedIntValue("clearFlags",t.clearFlags),r.setFlags=this._checkUnsignedIntValue("setFlags",t.setFlags),r.masterWeight=this._checkUnsignedIntValue("masterWeight",t.masterWeight,n),r.lowThreshold=this._checkUnsignedIntValue("lowThreshold",t.lowThreshold,n),r.medThreshold=this._checkUnsignedIntValue("medThreshold",t.medThreshold,n),r.highThreshold=this._checkUnsignedIntValue("highThreshold",t.highThreshold,n),!c.default(t.homeDomain)&&!l.default(t.homeDomain))throw new TypeError("homeDomain argument must be of type String");if(r.homeDomain=t.homeDomain,t.signer){var o=this._checkUnsignedIntValue("signer.weight",t.signer.weight,n),u=void 0,f=0;if(t.signer.ed25519PublicKey){if(!s.StrKey.isValidEd25519PublicKey(t.signer.ed25519PublicKey))throw new Error("signer.ed25519PublicKey is invalid.");var h=s.StrKey.decodeEd25519PublicKey(t.signer.ed25519PublicKey);u=new i.default.SignerKey.signerKeyTypeEd25519(h),f++}if(t.signer.preAuthTx){if(l.default(t.signer.preAuthTx)&&(t.signer.preAuthTx=e.from(t.signer.preAuthTx,"hex")),!e.isBuffer(t.signer.preAuthTx)||32!=t.signer.preAuthTx.length)throw new Error("signer.preAuthTx must be 32 bytes Buffer.");u=new i.default.SignerKey.signerKeyTypePreAuthTx(t.signer.preAuthTx),f++}if(t.signer.sha256Hash){if(l.default(t.signer.sha256Hash)&&(t.signer.sha256Hash=e.from(t.signer.sha256Hash,"hex")),!e.isBuffer(t.signer.sha256Hash)||32!=t.signer.sha256Hash.length)throw new Error("signer.sha256Hash must be 32 bytes Buffer.");u=new i.default.SignerKey.signerKeyTypeHashX(t.signer.sha256Hash),f++}if(1!=f)throw new Error("Signer object must contain exactly one of signer.ed25519PublicKey, signer.sha256Hash, signer.preAuthTx.");r.signer=new i.default.Signer({key:u,weight:o})}var p=new i.default.SetOptionsOp(r),d={};return d.body=i.default.OperationBody.setOption(p),this.setSourceAccount(d,t),new i.default.Operation(d)}}}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createAsset=void 0;{var o=r(241),i=n(o),a=(r(217),r(378)),s=(n(a),r(221)),u=n(s),c=(r(242),r(223)),f=r(240),l=n(f);t.createAsset=function h(e){if(!e.asset)throw new Error("Must provide an asset for a createAsset operation");if(!u.default(e.minfee)&&!this.isValidAmount(e.minfee,!0))throw new TypeError(this.constructAmountRequirementsError("min fee"));var t={};if(t.asset=e.asset.toXDRObject(),t.fee=this._checkUnsignedIntValue("fee",e.fee),t.ratio=this._checkUnsignedIntValue("ratio",e.ratio),t.minfee=this._toXDRAmount(e.minfee),0==t.fee&&0==t.minfee){if(!l.default(e.beneficiary)||0!=e.beneficiary.length)throw new Error("beneficiary must be empty when fee and minfee are zero")}else{if(!l.default(e.beneficiary)||56!=e.beneficiary.length)throw new Error("beneficiary is invalid");if(!c.StrKey.isValidEd25519PublicKey(e.beneficiary))throw new Error("beneficiary is invalid")}t.beneficiary=e.beneficiary;var h=new i.default.CreateAssetOp(t),r={};return r.body=i.default.OperationBody.createAsset(h),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){function n(e){return"number"==typeof e&&e==o(e)}var o=r(317);e.exports=n},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.changeAsset=void 0;{var o=r(241),i=n(o),a=(r(217),r(223)),s=r(240),u=n(s);t.changeAsset=function c(e){if(!e.asset)throw new Error("Must provide an asset for a changeAsset operation");var t={};if(t.asset=e.asset.toXDRObject(),!u.default(e.beneficiary))throw new Error("beneficiary is invalid");if(0!=e.beneficiary.length||56!=e.beneficiary.length)throw new Error("beneficiary is invalid");if(56==e.beneficiary.length&&!a.StrKey.isValidEd25519PublicKey(e.beneficiary))throw new Error("beneficiary is invalid");t.beneficiary=e.beneficiary;var c=new i.default.ChangeAssetOp(t),r={};return r.body=i.default.OperationBody.changeAsset(c),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.limitAsset=void 0;{var o=r(241),i=n(o);r(217),r(242),r(223),t.limitAsset=function a(e){if(!e.asset)throw new Error("Must provide an asset for a limitAsset operation");var t={};if(t.asset=e.asset.toXDRObject(),t.islimited=this._checkUnsignedIntValue("islimited",e.islimited),0!=t.islimited&&1!=t.islimited)throw new Error("Islimited must be 0 or 1.");var a=new i.default.LimitAssetOp(t),r={};return r.body=i.default.OperationBody.limitAsset(a),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.createContract=void 0;{var o=r(241),i=n(o),a=(r(217),r(223),r(4)),s=(n(a),r(221)),u=n(s),c=r(240),f=n(c);t.createContract=function l(t){if(!this.isValidAmount(t.startingBalance))throw new TypeError(this.constructAmountRequirementsError("startingBalance"));var r={};if(r.contractId="",r.startingBalance=this._toXDRAmount(t.startingBalance),!u.default(t.contractAddr)&&!f.default(t.contractAddr))throw new TypeError("contractAddr argument must be of type String");if(!f.default(t.contractAddr)&&!e.isBuffer(t.contractAddr)&&null!==t.contractAddr)throw new Error("contractAddr must be a string, Buffer or null");if(f.default(t.contractAddr)&&(t.contractAddr=e.from(t.contractAddr)),r.contractAddr=t.contractAddr,!u.default(t.data.funcName)&&!f.default(t.data.funcName))throw new TypeError("funcName argument must be of type String");if(!f.default(t.data.contractParams)&&!e.isBuffer(t.data.contractParams)&&null!==t.data.contractParams)throw new Error("contractParams must be a string, Buffer or null");if(f.default(t.data.contractParams)&&(t.data.contractParams=e.from(t.data.contractParams)),r.data=new i.default.ContractInput({funcName:t.data.funcName,contractParams:t.data.contractParams}),r.state="",!(f.default(t.fileHash)&&t.fileHash.length<=64))throw new Error("fileHash must be a string, up to 64 characters");r.fileHash=t.fileHash,r.errFlag=0;var l=new i.default.CreateContractOp(r),n={};return n.body=i.default.OperationBody.createContract(l),this.setSourceAccount(n,t),new i.default.Operation(n)}}}).call(t,r(156).Buffer)},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.callContract=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223),u=r(4),c=(n(u),r(221)),f=n(c),l=r(240),h=n(l);t.callContract=function p(t){if(!s.StrKey.isValidContractKey(t.contractId))throw new Error("contract is invalid");var r={};if(r.contractId=a.Keypair.fromContractKey(t.contractId).xdrContractId(),!f.default(t.data.funcName)&&!h.default(t.data.funcName))throw new TypeError("funcName argument must be of type String");if(!h.default(t.data.contractParams)&&!e.isBuffer(t.data.contractParams)&&null!==t.data.contractParams)throw new Error("contractParams must be a string, Buffer or null");h.default(t.data.contractParams)&&(t.data.contractParams=e.from(t.data.contractParams)),r.data=new i.default.ContractInput(t.data),r.contrOps=[],r.errFlag=0;var p=new i.default.CallContractOp(r),n={};return n.body=i.default.OperationBody.callContract(p),this.setSourceAccount(n,t),new i.default.Operation(n)}}}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.sendAsset=void 0;{var o=r(241),i=n(o),a=r(217),s=r(223);t.sendAsset=function u(e){if(!s.StrKey.isValidContractKey(e.contractId))throw new Error("contract is invalid");if(!e.asset)throw new Error("Must provide an asset for a sendAsset operation");if(!this.isValidAmount(e.amount))throw new TypeError(this.constructAmountRequirementsError("amount"));var t={};t.contractId=a.Keypair.fromContractKey(e.contractId).xdrContractId(),t.asset=e.asset.toXDRObject(),t.amount=this._toXDRAmount(e.amount),t.state="",t.errFlag=0;var u=new i.default.SendAssetOp(t),r={};return r.body=i.default.OperationBody.sendAsset(u),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.checkContract=void 0;{var o=r(241),i=n(o);r(217),r(223),t.checkContract=function a(e){var t={};if(t.isContract=this._checkUnsignedIntValue("isContract",e.isContract),0!=t.isContract&&1!=t.isContract)throw new Error("IsContract must be 0 or 1.");var a=new i.default.CheckContractOp(t),r={};return r.body=i.default.OperationBody.checkContract(a),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}Object.defineProperty(t,"__esModule",{value:!0}),t.testContract=void 0;{var o=r(241),i=n(o),a=(r(217),r(223),r(4)),s=(n(a),r(221)),u=(n(s),r(240));n(u),t.testContract=function c(e){var t={};t.startingBalance=this._checkUnsignedIntValue("startingBalance",e.startingBalance);var c=new i.default.TestContractOp(t),r={};return r.body=i.default.OperationBody.testContract(c),this.setSourceAccount(r,e),new i.default.Operation(r)}}},function(e,t,r){(function(e){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Memo=t.MemoReturn=t.MemoHash=t.MemoText=t.MemoID=t.MemoNone=void 0;var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(241),s=n(a),u=r(221),c=n(u),f=r(239),l=(n(f),r(240)),h=n(l),p=r(4),d=n(p),y=r(242),v=r(355),g=n(v),m=t.MemoNone="none",b=t.MemoID="id",w=t.MemoText="text",_=t.MemoHash="hash",k=t.MemoReturn="return",A=function(){function t(r){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;switch(o(this,t),this._type=r,this._value=n,this._type){case m:break;case b:t._validateIdValue(n);break;case w:t._validateTextValue(n);break;case _:case k:t._validateHashValue(n),h.default(n)&&(this._value=e.from(n,"hex"));break;default:throw new Error("Invalid memo type")}}return i(t,[{key:"toXDRObject",value:function(){switch(this._type){case m:return s.default.Memo.memoNone();case b:return s.default.Memo.memoId(y.UnsignedHyper.fromString(this._value));case w:return s.default.Memo.memoText(this._value);case _:return s.default.Memo.memoHash(this._value);case k:return s.default.Memo.memoReturn(this._value)}}},{key:"type",get:function(){return d.default(this._type)},set:function(){throw new Error("Memo is immutable")}},{key:"value",get:function(){switch(this._type){case m:return null;case b:case w:return d.default(this._value);case _:case k:return e.from(this._value);default:throw new Error("Invalid memo type")}},set:function(){throw new Error("Memo is immutable")}}],[{key:"_validateIdValue",value:function(e){var t=new Error("Expects a int64 as a string. Got "+e);if(!h.default(e))throw t;var r=void 0;try{r=new g.default(e)}catch(n){throw t}if(!r.isFinite())throw t;if(r.isNaN())throw t}},{key:"_validateTextValue",value:function(e){if(!s.default.Memo.armTypeForArm("text").isValid(e))throw new Error("Expects string, array or buffer, max 28 bytes")}},{key:"_validateHashValue",value:function(t){var r=new Error("Expects a 32 byte hash value or hex encoded string. Got "+t);if(null===t||c.default(t))throw r;var n=void 0;if(h.default(t)){if(!/^[0-9A-Fa-f]{64}$/g.test(t))throw r;n=e.from(t,"hex")}else{if(!e.isBuffer(t))throw r;n=e.from(t)}if(!n.length||32!=n.length)throw r}},{key:"none",value:function(){return new t(m)}},{key:"text",value:function(e){return new t(w,e)}},{key:"id",value:function(e){return new t(b,e)}},{key:"hash",value:function(e){return new t(_,e)}},{key:"return",value:function(e){return new t(k,e)}},{key:"fromXDRObject",value:function(e){switch(e.arm()){case"id":return t.id(e.value().toString());case"text":return t.text(e.value());case"hash":return t.hash(e.value());case"retHash":return t.return(e.value())}if("undefined"==typeof e.value())return t.none();throw new Error("Unknown type")}}]),t}();t.Memo=A}).call(t,r(156).Buffer)},function(e,t,r){(function(n){function o(){var e=[].slice.call(arguments).join(" ");throw new Error([e,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join("\n"))}function i(e,t){for(var r in e)t(e[r],r)}var a=r(388);t.createHash=r(390),t.createHmac=r(399),t.randomBytes=function(e,t){if(!t||!t.call)return new n(a(e));try{t.call(this,void 0,new n(a(e)))}catch(r){t(r)}},t.getHashes=function(){return["sha1","sha256","sha512","md5","rmd160"]};var s=r(400)(t);t.pbkdf2=s.pbkdf2,t.pbkdf2Sync=s.pbkdf2Sync,r(402)(t,e.exports),i(["createCredentials","createSign","createVerify","createDiffieHellman"],function(e){t[e]=function(){o("sorry,",e,"is not implemented yet")}})}).call(t,r(156).Buffer)},function(e,t,r){(function(t,n){!function(){var o=("undefined"==typeof window?t:window)||{};_crypto=o.crypto||o.msCrypto||r(389),e.exports=function(e){if(_crypto.getRandomValues){var t=new n(e);return _crypto.getRandomValues(t),t}if(_crypto.randomBytes)return _crypto.randomBytes(e);throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}}()}).call(t,function(){return this}(),r(156).Buffer)},function(){},function(e,t,r){(function(t){function n(e){return function(){var r=[],n={update:function(e,n){return t.isBuffer(e)||(e=new t(e,n)),r.push(e),this},digest:function(n){var o=t.concat(r),i=e(o);return r=null,n?i.toString(n):i}};return n}}var o=r(391),i=n(r(396)),a=n(r(398));e.exports=function(e){return"md5"===e?new i:"rmd160"===e?new a:o(e)}}).call(t,r(156).Buffer)},function(e,t,r){var t=e.exports=function(e){var r=t[e];if(!r)throw new Error(e+" is not supported (we accept pull requests)");return new r},n=r(156).Buffer,o=r(392)(n);t.sha1=r(393)(n,o),t.sha256=r(394)(n,o),t.sha512=r(395)(n,o)},function(e){e.exports=function(e){function t(t,r){this._block=new e(t),this._finalSize=r,this._blockSize=t,this._len=0,this._s=0}return t.prototype.init=function(){this._s=0,this._len=0},t.prototype.update=function(t,r){"string"==typeof t&&(r=r||"utf8",t=new e(t,r));for(var n=this._len+=t.length,o=this._s=this._s||0,i=0,a=this._block;n>o;){for(var s=Math.min(t.length,i+this._blockSize-o%this._blockSize),u=s-i,c=0;u>c;c++)a[o%this._blockSize+c]=t[c+i];o+=u,i+=u,o%this._blockSize===0&&this._update(a)}return this._s=o,this},t.prototype.digest=function(e){var t=8*this._len;this._block[this._len%this._blockSize]=128,this._block.fill(0,this._len%this._blockSize+1),t%(8*this._blockSize)>=8*this._finalSize&&(this._update(this._block),this._block.fill(0)),this._block.writeInt32BE(t,this._blockSize-4);var r=this._update(this._block)||this._hash();return e?r.toString(e):r},t.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t}},function(e,t,r){var n=r(199).inherits;e.exports=function(e,t){function r(){return d.length?d.pop().init():this instanceof r?(this._w=p,t.call(this,64,56),this._h=null,this.init(),void 0):new r}function o(e,t,r,n){return 20>e?t&r|~t&n:40>e?t^r^n:60>e?t&r|t&n|r&n:t^r^n}function i(e){return 20>e?1518500249:40>e?1859775393:60>e?-1894007588:-899497514}function a(e,t){return e+t|0}function s(e,t){return e<<t|e>>>32-t}var u=0,c=4,f=8,l=12,h=16,p=new("undefined"==typeof Int32Array?Array:Int32Array)(80),d=[];return n(r,t),r.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,t.prototype.init.call(this),this},r.prototype._POOL=d,r.prototype._update=function(e){var t,r,n,u,c,f,l,h,p,d;t=f=this._a,r=l=this._b,n=h=this._c,u=p=this._d,c=d=this._e;for(var y=this._w,v=0;80>v;v++){var g=y[v]=16>v?e.readInt32BE(4*v):s(y[v-3]^y[v-8]^y[v-14]^y[v-16],1),m=a(a(s(t,5),o(v,r,n,u)),a(a(c,g),i(v)));c=u,u=n,n=s(r,30),r=t,t=m}this._a=a(t,f),this._b=a(r,l),this._c=a(n,h),this._d=a(u,p),this._e=a(c,d)},r.prototype._hash=function(){d.length<100&&d.push(this);var t=new e(20);return t.writeInt32BE(0|this._a,u),t.writeInt32BE(0|this._b,c),t.writeInt32BE(0|this._c,f),t.writeInt32BE(0|this._d,l),t.writeInt32BE(0|this._e,h),t},r}},function(e,t,r){var n=r(199).inherits;e.exports=function(e,t){function r(){this.init(),this._w=p,t.call(this,64,56)}function o(e,t){return e>>>t|e<<32-t
}function i(e,t){return e>>>t}function a(e,t,r){return e&t^~e&r}function s(e,t,r){return e&t^e&r^t&r}function u(e){return o(e,2)^o(e,13)^o(e,22)}function c(e){return o(e,6)^o(e,11)^o(e,25)}function f(e){return o(e,7)^o(e,18)^i(e,3)}function l(e){return o(e,17)^o(e,19)^i(e,10)}var h=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],p=new Array(64);return n(r,t),r.prototype.init=function(){return this._a=1779033703,this._b=-1150833019,this._c=1013904242,this._d=-1521486534,this._e=1359893119,this._f=-1694144372,this._g=528734635,this._h=1541459225,this._len=this._s=0,this},r.prototype._update=function(e){var t,r,n,o,i,p,d,y,v,g,m=this._w;t=0|this._a,r=0|this._b,n=0|this._c,o=0|this._d,i=0|this._e,p=0|this._f,d=0|this._g,y=0|this._h;for(var b=0;64>b;b++){var w=m[b]=16>b?e.readInt32BE(4*b):l(m[b-2])+m[b-7]+f(m[b-15])+m[b-16];v=y+c(i)+a(i,p,d)+h[b]+w,g=u(t)+s(t,r,n),y=d,d=p,p=i,i=o+v,o=n,n=r,r=t,t=v+g}this._a=t+this._a|0,this._b=r+this._b|0,this._c=n+this._c|0,this._d=o+this._d|0,this._e=i+this._e|0,this._f=p+this._f|0,this._g=d+this._g|0,this._h=y+this._h|0},r.prototype._hash=function(){var t=new e(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t},r}},function(e,t,r){var n=r(199).inherits;e.exports=function(e,t){function r(){this.init(),this._w=u,t.call(this,128,112)}function o(e,t,r){return e>>>r|t<<32-r}function i(e,t,r){return e&t^~e&r}function a(e,t,r){return e&t^e&r^t&r}var s=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],u=new Array(160);return n(r,t),r.prototype.init=function(){return this._a=1779033703,this._b=-1150833019,this._c=1013904242,this._d=-1521486534,this._e=1359893119,this._f=-1694144372,this._g=528734635,this._h=1541459225,this._al=-205731576,this._bl=-2067093701,this._cl=-23791573,this._dl=1595750129,this._el=-1377402159,this._fl=725511199,this._gl=-79577749,this._hl=327033209,this._len=this._s=0,this},r.prototype._update=function(e){var t,r,n,u,c,f,l,h,p,d,y,v,g,m,b,w,_=this._w;t=0|this._a,r=0|this._b,n=0|this._c,u=0|this._d,c=0|this._e,f=0|this._f,l=0|this._g,h=0|this._h,p=0|this._al,d=0|this._bl,y=0|this._cl,v=0|this._dl,g=0|this._el,m=0|this._fl,b=0|this._gl,w=0|this._hl;for(var k=0;80>k;k++){var A,O,E=2*k;if(16>k)A=_[E]=e.readInt32BE(4*E),O=_[E+1]=e.readInt32BE(4*E+4);else{var S=_[E-30],x=_[E-30+1],C=o(S,x,1)^o(S,x,8)^S>>>7,P=o(x,S,1)^o(x,S,8)^o(x,S,7);S=_[E-4],x=_[E-4+1];var T=o(S,x,19)^o(x,S,29)^S>>>6,j=o(x,S,19)^o(S,x,29)^o(x,S,6),R=_[E-14],I=_[E-14+1],B=_[E-32],M=_[E-32+1];O=P+I,A=C+R+(P>>>0>O>>>0?1:0),O+=j,A=A+T+(j>>>0>O>>>0?1:0),O+=M,A=A+B+(M>>>0>O>>>0?1:0),_[E]=A,_[E+1]=O}var N=a(t,r,n),U=a(p,d,y),L=o(t,p,28)^o(p,t,2)^o(p,t,7),D=o(p,t,28)^o(t,p,2)^o(t,p,7),q=o(c,g,14)^o(c,g,18)^o(g,c,9),F=o(g,c,14)^o(g,c,18)^o(c,g,9),z=s[E],H=s[E+1],V=i(c,f,l),K=i(g,m,b),X=w+F,Q=h+q+(w>>>0>X>>>0?1:0);X+=K,Q=Q+V+(K>>>0>X>>>0?1:0),X+=H,Q=Q+z+(H>>>0>X>>>0?1:0),X+=O,Q=Q+A+(O>>>0>X>>>0?1:0);var Y=D+U,$=L+N+(D>>>0>Y>>>0?1:0);h=l,w=b,l=f,b=m,f=c,m=g,g=v+X|0,c=u+Q+(v>>>0>g>>>0?1:0)|0,u=n,v=y,n=r,y=d,r=t,d=p,p=X+Y|0,t=Q+$+(X>>>0>p>>>0?1:0)|0}this._al=this._al+p|0,this._bl=this._bl+d|0,this._cl=this._cl+y|0,this._dl=this._dl+v|0,this._el=this._el+g|0,this._fl=this._fl+m|0,this._gl=this._gl+b|0,this._hl=this._hl+w|0,this._a=this._a+t+(this._al>>>0<p>>>0?1:0)|0,this._b=this._b+r+(this._bl>>>0<d>>>0?1:0)|0,this._c=this._c+n+(this._cl>>>0<y>>>0?1:0)|0,this._d=this._d+u+(this._dl>>>0<v>>>0?1:0)|0,this._e=this._e+c+(this._el>>>0<g>>>0?1:0)|0,this._f=this._f+f+(this._fl>>>0<m>>>0?1:0)|0,this._g=this._g+l+(this._gl>>>0<b>>>0?1:0)|0,this._h=this._h+h+(this._hl>>>0<w>>>0?1:0)|0},r.prototype._hash=function(){function t(e,t,n){r.writeInt32BE(e,n),r.writeInt32BE(t,n+4)}var r=new e(64);return t(this._a,this._al,0),t(this._b,this._bl,8),t(this._c,this._cl,16),t(this._d,this._dl,24),t(this._e,this._el,32),t(this._f,this._fl,40),t(this._g,this._gl,48),t(this._h,this._hl,56),r},r}},function(e,t,r){function n(e,t){e[t>>5]|=128<<t%32,e[(t+64>>>9<<4)+14]=t;for(var r=1732584193,n=-271733879,o=-1732584194,f=271733878,l=0;l<e.length;l+=16){var h=r,p=n,d=o,y=f;r=i(r,n,o,f,e[l+0],7,-680876936),f=i(f,r,n,o,e[l+1],12,-389564586),o=i(o,f,r,n,e[l+2],17,606105819),n=i(n,o,f,r,e[l+3],22,-1044525330),r=i(r,n,o,f,e[l+4],7,-176418897),f=i(f,r,n,o,e[l+5],12,1200080426),o=i(o,f,r,n,e[l+6],17,-1473231341),n=i(n,o,f,r,e[l+7],22,-45705983),r=i(r,n,o,f,e[l+8],7,1770035416),f=i(f,r,n,o,e[l+9],12,-1958414417),o=i(o,f,r,n,e[l+10],17,-42063),n=i(n,o,f,r,e[l+11],22,-1990404162),r=i(r,n,o,f,e[l+12],7,1804603682),f=i(f,r,n,o,e[l+13],12,-40341101),o=i(o,f,r,n,e[l+14],17,-1502002290),n=i(n,o,f,r,e[l+15],22,1236535329),r=a(r,n,o,f,e[l+1],5,-165796510),f=a(f,r,n,o,e[l+6],9,-1069501632),o=a(o,f,r,n,e[l+11],14,643717713),n=a(n,o,f,r,e[l+0],20,-373897302),r=a(r,n,o,f,e[l+5],5,-701558691),f=a(f,r,n,o,e[l+10],9,38016083),o=a(o,f,r,n,e[l+15],14,-660478335),n=a(n,o,f,r,e[l+4],20,-405537848),r=a(r,n,o,f,e[l+9],5,568446438),f=a(f,r,n,o,e[l+14],9,-1019803690),o=a(o,f,r,n,e[l+3],14,-187363961),n=a(n,o,f,r,e[l+8],20,1163531501),r=a(r,n,o,f,e[l+13],5,-1444681467),f=a(f,r,n,o,e[l+2],9,-51403784),o=a(o,f,r,n,e[l+7],14,1735328473),n=a(n,o,f,r,e[l+12],20,-1926607734),r=s(r,n,o,f,e[l+5],4,-378558),f=s(f,r,n,o,e[l+8],11,-2022574463),o=s(o,f,r,n,e[l+11],16,1839030562),n=s(n,o,f,r,e[l+14],23,-35309556),r=s(r,n,o,f,e[l+1],4,-1530992060),f=s(f,r,n,o,e[l+4],11,1272893353),o=s(o,f,r,n,e[l+7],16,-155497632),n=s(n,o,f,r,e[l+10],23,-1094730640),r=s(r,n,o,f,e[l+13],4,681279174),f=s(f,r,n,o,e[l+0],11,-358537222),o=s(o,f,r,n,e[l+3],16,-722521979),n=s(n,o,f,r,e[l+6],23,76029189),r=s(r,n,o,f,e[l+9],4,-640364487),f=s(f,r,n,o,e[l+12],11,-421815835),o=s(o,f,r,n,e[l+15],16,530742520),n=s(n,o,f,r,e[l+2],23,-995338651),r=u(r,n,o,f,e[l+0],6,-198630844),f=u(f,r,n,o,e[l+7],10,1126891415),o=u(o,f,r,n,e[l+14],15,-1416354905),n=u(n,o,f,r,e[l+5],21,-57434055),r=u(r,n,o,f,e[l+12],6,1700485571),f=u(f,r,n,o,e[l+3],10,-1894986606),o=u(o,f,r,n,e[l+10],15,-1051523),n=u(n,o,f,r,e[l+1],21,-2054922799),r=u(r,n,o,f,e[l+8],6,1873313359),f=u(f,r,n,o,e[l+15],10,-30611744),o=u(o,f,r,n,e[l+6],15,-1560198380),n=u(n,o,f,r,e[l+13],21,1309151649),r=u(r,n,o,f,e[l+4],6,-145523070),f=u(f,r,n,o,e[l+11],10,-1120210379),o=u(o,f,r,n,e[l+2],15,718787259),n=u(n,o,f,r,e[l+9],21,-343485551),r=c(r,h),n=c(n,p),o=c(o,d),f=c(f,y)}return Array(r,n,o,f)}function o(e,t,r,n,o,i){return c(f(c(c(t,e),c(n,i)),o),r)}function i(e,t,r,n,i,a,s){return o(t&r|~t&n,e,t,i,a,s)}function a(e,t,r,n,i,a,s){return o(t&n|r&~n,e,t,i,a,s)}function s(e,t,r,n,i,a,s){return o(t^r^n,e,t,i,a,s)}function u(e,t,r,n,i,a,s){return o(r^(t|~n),e,t,i,a,s)}function c(e,t){var r=(65535&e)+(65535&t),n=(e>>16)+(t>>16)+(r>>16);return n<<16|65535&r}function f(e,t){return e<<t|e>>>32-t}var l=r(397);e.exports=function(e){return l.hash(e,n,16)}},function(e,t,r){(function(t){function r(e,r){if(e.length%i!==0){var n=e.length+(i-e.length%i);e=t.concat([e,a],n)}for(var o=[],s=r?e.readInt32BE:e.readInt32LE,u=0;u<e.length;u+=i)o.push(s.call(e,u));return o}function n(e,r,n){for(var o=new t(r),i=n?o.writeInt32BE:o.writeInt32LE,a=0;a<e.length;a++)i.call(o,e[a],4*a,!0);return o}function o(e,o,i,a){t.isBuffer(e)||(e=new t(e));var u=o(r(e,a),e.length*s);return n(u,i,a)}var i=4,a=new t(i);a.fill(0);var s=8;e.exports={hash:o}}).call(t,r(156).Buffer)},function(e,t,r){(function(t){function r(e,t,r){return e^t^r}function n(e,t,r){return e&t|~e&r}function o(e,t,r){return(e|~t)^r}function i(e,t,r){return e&r|t&~r}function a(e,t,r){return e^(t|~r)}function s(e,t){return e<<t|e>>>32-t}function u(e){var r=[1732584193,4023233417,2562383102,271733878,3285377520];"string"==typeof e&&(e=new t(e,"utf8"));var n=y(e),o=8*e.length,i=8*e.length;n[o>>>5]|=128<<24-o%32,n[(o+64>>>9<<4)+14]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8);for(var a=0;a<n.length;a+=16)g(r,n,a);for(var a=0;5>a;a++){var s=r[a];r[a]=16711935&(s<<8|s>>>24)|4278255360&(s<<24|s>>>8)}var u=v(r);return new t(u)}e.exports=u;var c=[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],f=[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],l=[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],h=[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],p=[0,1518500249,1859775393,2400959708,2840853838],d=[1352829926,1548603684,1836072691,2053994217,0],y=function(e){for(var t=[],r=0,n=0;r<e.length;r++,n+=8)t[n>>>5]|=e[r]<<24-n%32;return t},v=function(e){for(var t=[],r=0;r<32*e.length;r+=8)t.push(e[r>>>5]>>>24-r%32&255);return t},g=function(e,t,u){for(var y=0;16>y;y++){var v=u+y,g=t[v];t[v]=16711935&(g<<8|g>>>24)|4278255360&(g<<24|g>>>8)}var m,b,w,_,k,A,O,E,S,x;A=m=e[0],O=b=e[1],E=w=e[2],S=_=e[3],x=k=e[4];for(var C,y=0;80>y;y+=1)C=m+t[u+c[y]]|0,C+=16>y?r(b,w,_)+p[0]:32>y?n(b,w,_)+p[1]:48>y?o(b,w,_)+p[2]:64>y?i(b,w,_)+p[3]:a(b,w,_)+p[4],C=0|C,C=s(C,l[y]),C=C+k|0,m=k,k=_,_=s(w,10),w=b,b=C,C=A+t[u+f[y]]|0,C+=16>y?a(O,E,S)+d[0]:32>y?i(O,E,S)+d[1]:48>y?o(O,E,S)+d[2]:64>y?n(O,E,S)+d[3]:r(O,E,S)+d[4],C=0|C,C=s(C,h[y]),C=C+x|0,A=x,x=S,S=s(E,10),E=O,O=C;C=e[1]+w+S|0,e[1]=e[2]+_+x|0,e[2]=e[3]+k+A|0,e[3]=e[4]+m+O|0,e[4]=e[0]+b+E|0,e[0]=C}}).call(t,r(156).Buffer)},function(e,t,r){(function(t){function n(e,r){if(!(this instanceof n))return new n(e,r);this._opad=u,this._alg=e;var a="sha512"===e?128:64;r=this._key=t.isBuffer(r)?r:new t(r),r.length>a?r=o(e).update(r).digest():r.length<a&&(r=t.concat([r,i],a));for(var s=this._ipad=new t(a),u=this._opad=new t(a),c=0;a>c;c++)s[c]=54^r[c],u[c]=92^r[c];this._hash=o(e).update(s)}var o=r(390),i=new t(128);i.fill(0),e.exports=n,n.prototype.update=function(e,t){return this._hash.update(e,t),this},n.prototype.digest=function(e){var t=this._hash.digest();return o(this._alg).update(this._opad).update(t).digest(e)}}).call(t,r(156).Buffer)},function(e,t,r){var n=r(401);e.exports=function(e,t){t=t||{};var r=n(e);return t.pbkdf2=r.pbkdf2,t.pbkdf2Sync=r.pbkdf2Sync,t}},function(e,t,r){(function(t){e.exports=function(e){function r(e,t,r,o,i,a){if("function"==typeof i&&(a=i,i=void 0),"function"!=typeof a)throw new Error("No callback provided to pbkdf2");setTimeout(function(){var s;try{s=n(e,t,r,o,i)}catch(u){return a(u)}a(void 0,s)})}function n(r,n,o,i,a){if("number"!=typeof o)throw new TypeError("Iterations not a number");if(0>o)throw new TypeError("Bad iterations");if("number"!=typeof i)throw new TypeError("Key length not a number");if(0>i)throw new TypeError("Bad key length");a=a||"sha1",t.isBuffer(r)||(r=new t(r)),t.isBuffer(n)||(n=new t(n));var s,u,c,f=1,l=new t(i),h=new t(n.length+4);n.copy(h,0,0,n.length);for(var p=1;f>=p;p++){h.writeUInt32BE(p,n.length);var d=e.createHmac(a,r).update(h).digest();if(!s&&(s=d.length,c=new t(s),f=Math.ceil(i/s),u=i-(f-1)*s,i>(Math.pow(2,32)-1)*s))throw new TypeError("keylen exceeds maximum length");d.copy(c,0,0,s);for(var y=1;o>y;y++){d=e.createHmac(a,r).update(d).digest();for(var v=0;s>v;v++)c[v]^=d[v]}var g=(p-1)*s,m=p==f?u:s;c.copy(l,g,0,m)}return l}return{pbkdf2:r,pbkdf2Sync:n}}}).call(t,r(156).Buffer)},function(e,t,r){e.exports=function(e,t){function n(){return Object.keys(a)}t=t||{};var o=r(403)(e);t.createCipher=o.createCipher,t.createCipheriv=o.createCipheriv;var i=r(420)(e);t.createDecipher=i.createDecipher,t.createDecipheriv=i.createDecipheriv;var a=r(411);t.listCiphers=n}},function(e,t,r){(function(t){function n(e,r,s){return this instanceof n?(a.call(this),this._cache=new o,this._cipher=new i.AES(r),this._prev=new t(s.length),s.copy(this._prev),this._mode=e,void 0):new n(e,r,s)}function o(){return this instanceof o?(this.cache=new t(""),void 0):new o}var i=r(404),a=r(405),s=r(175),u=r(411),c=r(412),f=r(413);s(n,a),n.prototype._transform=function(e,t,r){this._cache.add(e);for(var n,o;n=this._cache.get();)o=this._mode.encrypt(this,n),this.push(o);r()},n.prototype._flush=function(e){var t=this._cache.flush();this.push(this._mode.encrypt(this,t)),this._cipher.scrub(),e()},o.prototype.add=function(e){this.cache=t.concat([this.cache,e])},o.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},o.prototype.flush=function(){for(var e=16-this.cache.length,r=new t(e),n=-1;++n<e;)r.writeUInt8(e,n);var o=t.concat([this.cache,r]);return o};var l={ECB:r(414),CBC:r(415),CFB:r(417),OFB:r(418),CTR:r(419)};e.exports=function(e){function r(e,r,o){var i=u[e];if(!i)throw new TypeError("invalid suite type");if("string"==typeof o&&(o=new t(o)),"string"==typeof r&&(r=new t(r)),r.length!==i.key/8)throw new TypeError("invalid key length "+r.length);if(o.length!==i.iv)throw new TypeError("invalid iv length "+o.length);return"stream"===i.type?new f(l[i.mode],r,o):new n(l[i.mode],r,o)}function o(t,n){var o=u[t];if(!o)throw new TypeError("invalid suite type");var i=c(e,n,o.key,o.iv);return r(t,i.key,i.iv)}return{createCipher:o,createCipheriv:r}}}).call(t,r(156).Buffer)},function(e,t,r){(function(e){function r(e){var t,r;return t=e>s||0>e?(r=Math.abs(e)%s,0>e?s-r:r):e}function n(e){var t,r,n;for(t=r=0,n=e.length;n>=0?n>r:r>n;t=n>=0?++r:--r)e[t]=0;return!1}function o(){var e;this.SBOX=[],this.INV_SBOX=[],this.SUB_MIX=function(){var t,r;for(r=[],e=t=0;4>t;e=++t)r.push([]);return r}(),this.INV_SUB_MIX=function(){var t,r;for(r=[],e=t=0;4>t;e=++t)r.push([]);return r}(),this.init(),this.RCON=[0,1,2,4,8,16,32,64,128,27,54]}function i(e){for(var t=e.length/4,r=new Array(t),n=-1;++n<t;)r[n]=e.readUInt32BE(4*n);return r}function a(e){this._key=i(e),this._doReset()}var s=Math.pow(2,32);o.prototype.init=function(){var e,t,r,n,o,i,a,s,u,c;for(e=function(){var e,r;for(r=[],t=e=0;256>e;t=++e)128>t?r.push(t<<1):r.push(t<<1^283);return r}(),o=0,u=0,t=c=0;256>c;t=++c)r=u^u<<1^u<<2^u<<3^u<<4,r=r>>>8^255&r^99,this.SBOX[o]=r,this.INV_SBOX[r]=o,i=e[o],a=e[i],s=e[a],n=257*e[r]^16843008*r,this.SUB_MIX[0][o]=n<<24|n>>>8,this.SUB_MIX[1][o]=n<<16|n>>>16,this.SUB_MIX[2][o]=n<<8|n>>>24,this.SUB_MIX[3][o]=n,n=16843009*s^65537*a^257*i^16843008*o,this.INV_SUB_MIX[0][r]=n<<24|n>>>8,this.INV_SUB_MIX[1][r]=n<<16|n>>>16,this.INV_SUB_MIX[2][r]=n<<8|n>>>24,this.INV_SUB_MIX[3][r]=n,0===o?o=u=1:(o=i^e[e[e[s^i]]],u^=e[e[u]]);return!0};var u=new o;a.blockSize=16,a.prototype.blockSize=a.blockSize,a.keySize=32,a.prototype.keySize=a.keySize,a.ivSize=a.blockSize,a.prototype.ivSize=a.ivSize,a.prototype._doReset=function(){var e,t,r,n,o,i,a,s;for(r=this._key,t=r.length,this._nRounds=t+6,o=4*(this._nRounds+1),this._keySchedule=[],n=a=0;o>=0?o>a:a>o;n=o>=0?++a:--a)this._keySchedule[n]=t>n?r[n]:(i=this._keySchedule[n-1],n%t===0?(i=i<<8|i>>>24,i=u.SBOX[i>>>24]<<24|u.SBOX[i>>>16&255]<<16|u.SBOX[i>>>8&255]<<8|u.SBOX[255&i],i^=u.RCON[n/t|0]<<24):t>6&&n%t===4?i=u.SBOX[i>>>24]<<24|u.SBOX[i>>>16&255]<<16|u.SBOX[i>>>8&255]<<8|u.SBOX[255&i]:void 0,this._keySchedule[n-t]^i);for(this._invKeySchedule=[],e=s=0;o>=0?o>s:s>o;e=o>=0?++s:--s)n=o-e,i=this._keySchedule[n-(e%4?0:4)],this._invKeySchedule[e]=4>e||4>=n?i:u.INV_SUB_MIX[0][u.SBOX[i>>>24]]^u.INV_SUB_MIX[1][u.SBOX[i>>>16&255]]^u.INV_SUB_MIX[2][u.SBOX[i>>>8&255]]^u.INV_SUB_MIX[3][u.SBOX[255&i]];return!0},a.prototype.encryptBlock=function(t){t=i(new e(t));var r=this._doCryptBlock(t,this._keySchedule,u.SUB_MIX,u.SBOX),n=new e(16);return n.writeUInt32BE(r[0],0),n.writeUInt32BE(r[1],4),n.writeUInt32BE(r[2],8),n.writeUInt32BE(r[3],12),n},a.prototype.decryptBlock=function(t){t=i(new e(t));var r=[t[3],t[1]];t[1]=r[0],t[3]=r[1];var n=this._doCryptBlock(t,this._invKeySchedule,u.INV_SUB_MIX,u.INV_SBOX),o=new e(16);return o.writeUInt32BE(n[0],0),o.writeUInt32BE(n[3],4),o.writeUInt32BE(n[2],8),o.writeUInt32BE(n[1],12),o},a.prototype.scrub=function(){n(this._keySchedule),n(this._invKeySchedule),n(this._key)},a.prototype._doCryptBlock=function(e,t,n,o){var i,a,s,u,c,f,l,h,p,d,y,v;for(s=e[0]^t[0],u=e[1]^t[1],c=e[2]^t[2],f=e[3]^t[3],i=4,a=y=1,v=this._nRounds;v>=1?v>y:y>v;a=v>=1?++y:--y)l=n[0][s>>>24]^n[1][u>>>16&255]^n[2][c>>>8&255]^n[3][255&f]^t[i++],h=n[0][u>>>24]^n[1][c>>>16&255]^n[2][f>>>8&255]^n[3][255&s]^t[i++],p=n[0][c>>>24]^n[1][f>>>16&255]^n[2][s>>>8&255]^n[3][255&u]^t[i++],d=n[0][f>>>24]^n[1][s>>>16&255]^n[2][u>>>8&255]^n[3][255&c]^t[i++],s=l,u=h,c=p,f=d;return l=(o[s>>>24]<<24|o[u>>>16&255]<<16|o[c>>>8&255]<<8|o[255&f])^t[i++],h=(o[u>>>24]<<24|o[c>>>16&255]<<16|o[f>>>8&255]<<8|o[255&s])^t[i++],p=(o[c>>>24]<<24|o[f>>>16&255]<<16|o[s>>>8&255]<<8|o[255&u])^t[i++],d=(o[f>>>24]<<24|o[s>>>16&255]<<16|o[u>>>8&255]<<8|o[255&c])^t[i++],[r(l),r(h),r(p),r(d)]},t.AES=a}).call(t,r(156).Buffer)},function(e,t,r){(function(t){function n(){o.call(this)}var o=r(406).Transform,i=r(175);e.exports=n,i(n,o),n.prototype.update=function(e,r,n){this.write(e,r);for(var o,i=new t("");o=this.read();)i=t.concat([i,o]);return n&&(i=i.toString(n)),i},n.prototype.final=function(e){this.end();for(var r,n=new t("");r=this.read();)n=t.concat([n,r]);return e&&(n=n.toString(e)),n}}).call(t,r(156).Buffer)},function(e,t,r){function n(){o.call(this)}e.exports=n;var o=r(170).EventEmitter,i=r(175);i(n,o),n.Readable=r(177),n.Writable=r(407),n.Duplex=r(408),n.Transform=r(409),n.PassThrough=r(410),n.Stream=n,n.prototype.pipe=function(e,t){function r(t){e.writable&&!1===e.write(t)&&c.pause&&c.pause()}function n(){c.readable&&c.resume&&c.resume()}function i(){f||(f=!0,e.end())}function a(){f||(f=!0,"function"==typeof e.destroy&&e.destroy())}function s(e){if(u(),0===o.listenerCount(this,"error"))throw e}function u(){c.removeListener("data",r),e.removeListener("drain",n),c.removeListener("end",i),c.removeListener("close",a),c.removeListener("error",s),e.removeListener("error",s),c.removeListener("end",u),c.removeListener("close",u),e.removeListener("close",u)}var c=this;c.on("data",r),e.on("drain",n),e._isStdio||t&&t.end===!1||(c.on("end",i),c.on("close",a));var f=!1;return c.on("error",s),e.on("error",s),c.on("end",u),c.on("close",u),e.on("close",u),e.emit("pipe",c),e}},function(e,t,r){e.exports=r(188)},function(e,t,r){e.exports=r(187)},function(e,t,r){e.exports=r(177).Transform},function(e,t,r){e.exports=r(177).PassThrough},function(e,t){t["aes-128-ecb"]={cipher:"AES",key:128,iv:0,mode:"ECB",type:"block"},t["aes-192-ecb"]={cipher:"AES",key:192,iv:0,mode:"ECB",type:"block"},t["aes-256-ecb"]={cipher:"AES",key:256,iv:0,mode:"ECB",type:"block"},t["aes-128-cbc"]={cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},t["aes-192-cbc"]={cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},t["aes-256-cbc"]={cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},t.aes128=t["aes-128-cbc"],t.aes192=t["aes-192-cbc"],t.aes256=t["aes-256-cbc"],t["aes-128-cfb"]={cipher:"AES",key:128,iv:16,mode:"CFB",type:"stream"},t["aes-192-cfb"]={cipher:"AES",key:192,iv:16,mode:"CFB",type:"stream"},t["aes-256-cfb"]={cipher:"AES",key:256,iv:16,mode:"CFB",type:"stream"},t["aes-128-ofb"]={cipher:"AES",key:128,iv:16,mode:"OFB",type:"stream"},t["aes-192-ofb"]={cipher:"AES",key:192,iv:16,mode:"OFB",type:"stream"},t["aes-256-ofb"]={cipher:"AES",key:256,iv:16,mode:"OFB",type:"stream"},t["aes-128-ctr"]={cipher:"AES",key:128,iv:16,mode:"CTR",type:"stream"},t["aes-192-ctr"]={cipher:"AES",key:192,iv:16,mode:"CTR",type:"stream"},t["aes-256-ctr"]={cipher:"AES",key:256,iv:16,mode:"CTR",type:"stream"}},function(e,t,r){(function(t){e.exports=function(e,r,n,o){n/=8,o=o||0;for(var i,a,s,u=0,c=0,f=new t(n),l=new t(o),h=0;;){if(i=e.createHash("md5"),h++>0&&i.update(a),i.update(r),a=i.digest(),s=0,n>0)for(;;){if(0===n)break;if(s===a.length)break;f[u++]=a[s],n--,s++}if(o>0&&s!==a.length)for(;;){if(0===o)break;if(s===a.length)break;l[c++]=a[s],o--,s++}if(0===n&&0===o)break}for(s=0;s<a.length;s++)a[s]=0;return{key:f,iv:l}}}).call(t,r(156).Buffer)},function(e,t,r){(function(t){function n(e,r,a,s){return this instanceof n?(i.call(this),this._cipher=new o.AES(r),this._prev=new t(a.length),this._cache=new t(""),this._secCache=new t(""),this._decrypt=s,a.copy(this._prev),this._mode=e,void 0):new n(e,r,a)}var o=r(404),i=r(405),a=r(175);a(n,i),e.exports=n,n.prototype._transform=function(e,t,r){r(null,this._mode.encrypt(this,e,this._decrypt))},n.prototype._flush=function(e){this._cipher.scrub(),e()}}).call(t,r(156).Buffer)},function(e,t){t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},function(e,t,r){var n=r(416);t.encrypt=function(e,t){var r=n(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},t.decrypt=function(e,t){var r=e._prev;e._prev=t;var o=e._cipher.decryptBlock(t);return n(o,r)}},function(e,t,r){(function(t){function r(e,r){for(var n=Math.min(e.length,r.length),o=new t(n),i=-1;++i<n;)o.writeUInt8(e[i]^r[i],i);return o}e.exports=r}).call(t,r(156).Buffer)},function(e,t,r){(function(e){function n(t,r,n){var i=r.length,a=o(r,t._cache);return t._cache=t._cache.slice(i),t._prev=e.concat([t._prev,n?r:a]),a}var o=r(416);t.encrypt=function(t,r,o){for(var i,a=new e("");r.length;){if(0===t._cache.length&&(t._cache=t._cipher.encryptBlock(t._prev),t._prev=new e("")),!(t._cache.length<=r.length)){a=e.concat([a,n(t,r,o)]);break}i=t._cache.length,a=e.concat([a,n(t,r.slice(0,i),o)]),r=r.slice(i)}return a}}).call(t,r(156).Buffer)},function(e,t,r){(function(e){function n(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}var o=r(416);t.encrypt=function(t,r){for(;t._cache.length<r.length;)t._cache=e.concat([t._cache,n(t)]);var i=t._cache.slice(0,r.length);return t._cache=t._cache.slice(r.length),o(r,i)}}).call(t,r(156).Buffer)},function(e,t,r){(function(e){function n(e){var t=e._cipher.encryptBlock(e._prev);return o(e._prev),t}function o(e){for(var t,r=e.length;r--;){if(t=e.readUInt8(r),255!==t){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}var i=r(416);t.encrypt=function(t,r){for(;t._cache.length<r.length;)t._cache=e.concat([t._cache,n(t)]);var o=t._cache.slice(0,r.length);return t._cache=t._cache.slice(r.length),i(r,o)}}).call(t,r(156).Buffer)},function(e,t,r){(function(t){function n(e,r,i){return this instanceof n?(s.call(this),this._cache=new o,this._last=void 0,this._cipher=new a.AES(r),this._prev=new t(i.length),i.copy(this._prev),this._mode=e,void 0):new n(e,r,i)}function o(){return this instanceof o?(this.cache=new t(""),void 0):new o}function i(e){var t=e[15];if(16!==t)return e.slice(0,16-t)}var a=r(404),s=r(405),u=r(175),c=r(411),f=r(413),l=r(412);u(n,s),n.prototype._transform=function(e,t,r){this._cache.add(e);for(var n,o;n=this._cache.get();)o=this._mode.decrypt(this,n),this.push(o);r()},n.prototype._flush=function(e){var t=this._cache.flush();return t?(this.push(i(this._mode.decrypt(this,t))),e(),void 0):e},o.prototype.add=function(e){this.cache=t.concat([this.cache,e])},o.prototype.get=function(){if(this.cache.length>16){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},o.prototype.flush=function(){return this.cache.length?this.cache:void 0};var h={ECB:r(414),CBC:r(415),CFB:r(417),OFB:r(418),CTR:r(419)};e.exports=function(e){function r(e,r,o){var i=c[e];if(!i)throw new TypeError("invalid suite type");if("string"==typeof o&&(o=new t(o)),"string"==typeof r&&(r=new t(r)),r.length!==i.key/8)throw new TypeError("invalid key length "+r.length);if(o.length!==i.iv)throw new TypeError("invalid iv length "+o.length);return"stream"===i.type?new f(h[i.mode],r,o,!0):new n(h[i.mode],r,o)}function o(t,n){var o=c[t];if(!o)throw new TypeError("invalid suite type");var i=l(e,n,o.key,o.iv);return r(t,i.key,i.iv)}return{createDecipher:o,createDecipheriv:r}}}).call(t,r(156).Buffer)},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionBuilder=void 0;{var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(241),s=n(a),u=r(242),c=(r(204),r(217)),f=(r(422),r(334)),l=(r(358),r(333)),h=r(386),p=r(355),d=n(p),y=r(4),v=n(y),g=r(327),m=(n(g),r(221)),b=n(m),w=100;t.TransactionBuilder=function(){function e(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(o(this,e),!t)throw new Error("must specify source account for the transaction");this.source=t,this.operations=[],this.baseFee=b.default(r.fee)?w:r.fee,this.timebounds=v.default(r.timebounds),this.memo=r.memo||h.Memo.none(),this.blob=null}return i(e,[{key:"addOperation",value:function(e){if(this.operations.push(e),this.operations.length>0&&"checkContract"!=this.operations[0].body().switch().name||this.operations.length>0&&"checkContract"==this.operations[0].body().switch().name&&"0"==this.operations[0].body().value().isContract.toString())for(var t=0;t<this.operations.length;t++)if("callContract"==this.operations[t].body().switch().name||"sendAsset"==this.operations[t].body().switch().name||"createContract"==this.operations[t].body().switch().name){this.operations.unshift(f.Operation.checkContract({isContract:"1"}));break}return this}},{key:"addContrOperationForCallContractOp",value:function(e,t){if("callContract"!=this.operations[t].body().switch().name)throw new Error("The Operation at "+t+" is not CallContractOp");return this.operations[t].body().value().contrOps().push(e),this}},{key:"addMemo",value:function(e){return this.memo=e,this}},{key:"build",value:function(){var e=new d.default(this.source.sequenceNumber()).add(1),t={sourceAccount:c.Keypair.fromPublicKey(this.source.accountId()).xdrAccountId(),fee:this.baseFee*this.operations.length,seqNum:s.default.SequenceNumber.fromString(e.toString()),memo:this.memo?this.memo.toXDRObject():null,ext:new s.default.TransactionExt(0)};this.timebounds&&(this.timebounds.minTime=u.UnsignedHyper.fromString(this.timebounds.minTime.toString()),this.timebounds.maxTime=u.UnsignedHyper.fromString(this.timebounds.maxTime.toString()),t.timeBounds=new s.default.TimeBounds(this.timebounds));var r=new s.default.Transaction(t);r.operations(this.operations);var n=new s.default.TransactionEnvelope({tx:r}),o=new l.Transaction(n);return this.source.incrementSequenceNumber(),o}}]),e}()}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.Account=void 0;{var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(355),s=n(a),u=r(240),c=n(u),f=(r(217),r(223));t.Account=function(){function e(t,r){if(o(this,e),!f.StrKey.isValidEd25519PublicKey(t))throw new Error("accountId is invalid");if(!c.default(r))throw new Error("sequence must be of type string");this._accountId=t,this.sequence=new s.default(r)}return i(e,[{key:"accountId",value:function(){return this._accountId}},{key:"sequenceNumber",value:function(){return this.sequence.toString()}},{key:"incrementSequenceNumber",value:function(){this.sequence=this.sequence.add(1)}}]),e}()}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(424);Object.defineProperty(t,"Storage",{enumerable:!0,get:function(){return n.Storage}});var o=r(425);Object.defineProperty(t,"IContract",{enumerable:!0,get:function(){return o.IContract}});var i=r(426);Object.defineProperty(t,"State",{enumerable:!0,get:function(){return i.State}}),Object.defineProperty(t,"Decode",{enumerable:!0,get:function(){return i.Decode}}),Object.defineProperty(t,"Encode",{enumerable:!0,get:function(){return i.Encode}}),Object.defineProperty(t,"ReturnData",{enumerable:!0,get:function(){return i.ReturnData}}),Object.defineProperty(t,"OutputFormat",{enumerable:!0,get:function(){return i.OutputFormat}});var a=r(427);Object.defineProperty(t,"exec",{enumerable:!0,get:function(){return a.exec}});var s=r(429);Object.defineProperty(t,"getBalance",{enumerable:!0,get:function(){return s.getBalance}}),Object.defineProperty(t,"getLedgerSeq",{enumerable:!0,get:function(){return s.getLedgerSeq}}),Object.defineProperty(t,"getState",{enumerable:!0,get:function(){return s.getState}}),Object.defineProperty(t,"getBalanceAsset",{enumerable:!0,get:function(){return s.getBalanceAsset}});var u=r(428);Object.defineProperty(t,"ResultCode",{enumerable:!0,get:function(){return u.ResultCode}}),Object.defineProperty(t,"Success",{enumerable:!0,get:function(){return u.Success}}),Object.defineProperty(t,"Failed",{enumerable:!0,get:function(){return u.Failed}})},function(e,t,r){(function(e){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),o=(t.Storage=function(){function t(e){r(this,t),this.storage=e?Object.assign({},e):{}}return n(t,[{key:"set",value:function(e,t){if(this.storage.hasOwnProperty(e))throw new Error("storage has property"+e);
this.storage[e]=t}},{key:"get",value:function(e){return this.storage[e]}},{key:"remove",value:function(e){delete this.storage[e]}},{key:"update",value:function(e,t){if(!this.storage.hasOwnProperty(e))throw new Error("storage can not find property"+e);this.storage[e]=t}},{key:"save",value:function(){var e=JSON.stringify(this.storage),t=i(e),r=s(t);return r.toString("hex")}},{key:"recover",value:function(t){var r=e.from(t,"hex"),n=a(r),i=o(n),s=JSON.parse(i);return this.storage=Object.assign({},this.storage,s),this.storage}},{key:"has",value:function(e){return this.storage.hasOwnProperty(e)}},{key:"show",value:function(){return this.storage}}]),t}(),function(e){return String.fromCharCode.apply(null,new Uint16Array(e))}),i=function(e){for(var t=new ArrayBuffer(2*e.length),r=new Uint16Array(t),n=0,o=e.length;o>n;n++)r[n]=e.charCodeAt(n);return t},a=function(e){for(var t=new ArrayBuffer(e.length),r=new Uint8Array(t),n=0;n<e.length;++n)r[n]=e[n];return t},s=function(t){for(var r=new e(t.byteLength),n=new Uint8Array(t),o=0;o<r.length;++o)r[o]=n[o];return r}}).call(t,r(156).Buffer)},function(e,t){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});{var n=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();t.IContract=function(){function e(){r(this,e)}return n(e,[{key:"initialize",value:function(){}},{key:"fallback",value:function(){}},{key:"main",value:function(){}}]),e}()}},function(e,t,r){(function(e,r){"use strict";function n(){var t=e.argv[6],n=e.argv[5],o=e.argv[4],i=e.argv[3],a=e.argv[2],s=e.argv[1].split("/"),u=s[s.length-1].replace(".js",""),f=void 0;if("fallback"==a){var h=i.split("*"),p=new r(h[2],"hex");f={assetCode:p.toString("utf8"),assetIssuer:h[3],amount:h[1],sender:h[0]}}else{var d=r.from(i,"hex"),y=l(d),v=c(y);f=JSON.parse(v)}return{currentState:o,sender:n,ledSeq:t,param:f,functionName:a,contractKey:u}}function o(e,t,r,n,o){return{error:e,newState:t,ContrOps:r,contract:n,message:o}}function i(){throw new Error}function a(e){var t=JSON.stringify(e);console.log(t)}function s(e){try{var t=f(e),r=h(t);return r.toString("hex")}catch(n){throw new Error("Encode error: "+n.message)}}function u(e){try{var t=r.from(e,"hex"),n=l(t),o=c(n);return JSON.parse(o)}catch(i){throw new Error("Decode error: "+i.message)}}Object.defineProperty(t,"__esModule",{value:!0}),t.State=n,t.OutputFormat=o,t.ErrorHandle=i,t.ReturnData=a,t.Encode=s,t.Decode=u;var c=function(e){return String.fromCharCode.apply(null,new Uint16Array(e))},f=function(e){for(var t=new ArrayBuffer(2*e.length),r=new Uint16Array(t),n=0,o=e.length;o>n;n++)r[n]=e.charCodeAt(n);return t},l=function(e){for(var t=new ArrayBuffer(e.length),r=new Uint8Array(t),n=0;n<e.length;++n)r[n]=e[n];return t},h=function(e){for(var t=new r(e.byteLength),n=new Uint8Array(e),o=0;o<t.length;++o)t[o]=n[o];return t}}).call(t,r(136),r(156).Buffer)},function(e,t,r){"use strict";function n(e,t,r,n,o,i,a){try{var s=e[i](a),u=s.value}catch(c){return r(c),void 0}s.done?t(u):Promise.resolve(u).then(n,o)}function o(e){return function(){var t=this,r=arguments;return new Promise(function(o,i){function a(e){n(u,o,i,a,s,"next",e)}function s(e){n(u,o,i,a,s,"throw",e)}var u=e.apply(t,r);a(void 0)})}}function i(e){if("function"!=typeof(new e).main)throw new Error("Contract dose not have function main");if("function"!=typeof(new e).fallback)throw new Error("Contract dose not have function fallback");if("function"!=typeof(new e).initialize)throw new Error("Contract dose not have function initialize");var t=a.State();o(regeneratorRuntime.mark(function r(){var n,o,i,u,c,f;return regeneratorRuntime.wrap(function(r){for(;;)switch(r.prev=r.next){case 0:if(n=void 0,"constructor"!==t.functionName){r.next=8;break}if("empty"===t.currentState){r.next=4;break}throw new Error("Contract was initialize");case 4:o=new e,n=o.main(t.functionName,t.param),r.next=14;break;case 8:return i=a.Decode(t.currentState),u=new s.Storage(i),c=new e(u.show()),r.next=13,c.main(t.functionName,t.param);case 13:n=r.sent;case 14:return r.next=16,n;case 16:if(f=r.sent,void 0!==f.error&&void 0!==f.newState&&void 0!==f.ContrOps&&void 0!==f.contract){r.next=19;break}throw new Error("Json format invalid");case 19:a.ReturnData(f);case 20:case"end":return r.stop()}},r)}))().catch(function(e){var r=a.OutputFormat(u.ResultCode.ERR_ENV,"","",t.contractKey,e.message);a.ReturnData(r)})}Object.defineProperty(t,"__esModule",{value:!0}),t.exec=i;var a=r(426),s=r(424),u=r(428)},function(e,t,r){"use strict";var n=r(426),o=n.OutputFormat,i={SUCCESS:0,ERR_ENV:1,ERR_CONDITION:2},a=function(e,t,r,n){return o(i.SUCCESS,e,t,r,n)},s=function(e,t){return o(i.ERR_CONDITION,"","",e,t)};e.exports={ResultCode:i,Success:a,Failed:s}},function(e,t,r){(function(t){"use strict";var n=r(172),o=function(e){return new Promise(function(r,o){n.get("http://"+t.env.HOST+":"+t.env.PORT+"/balance?id="+e,function(e){var t=e.statusCode,n=e.headers["content-type"],i=void 0;if(200!==t?i=new Error("Request Failed.\nStatus Code: "+t):/^application\/json/.test(n)||(i=new Error("Invalid content-type.\nExpected application/json but received "+n)),i)return e.resume(),void 0;e.setEncoding("utf8");var a="";e.on("data",function(e){a+=e}),e.on("end",function(){try{var e=JSON.parse(a);r(e)}catch(t){o(t.message)}})})})},i=function(){return new Promise(function(e,r){n.get("http://"+t.env.HOST+":"+t.env.PORT+"/ledger",function(t){var n=t.statusCode,o=t.headers["content-type"],i=void 0;if(200!==n?i=new Error("Request Failed.\nStatus Code: "+n):/^application\/json/.test(o)||(i=new Error("Invalid content-type.\nExpected application/json but received "+o)),i)return t.resume(),void 0;t.setEncoding("utf8");var a="";t.on("data",function(e){a+=e}),t.on("end",function(){try{var t=JSON.parse(a);e(t)}catch(n){r(n.message)}})})})},a=function(e){return new Promise(function(r,o){n.get("http://"+t.env.HOST+":"+t.env.PORT+"/state?id="+e,function(e){var t=e.statusCode,n=e.headers["content-type"],i=void 0;if(200!==t?i=new Error("Request Failed.\nStatus Code: "+t):/^application\/json/.test(n)||(i=new Error("Invalid content-type.\nExpected application/json but received "+n)),i)return e.resume(),void 0;e.setEncoding("utf8");var a="";e.on("data",function(e){a+=e}),e.on("end",function(){try{var e=JSON.parse(a);r(e)}catch(t){o(t.message)}})})})},s=function(e,r,o){return new Promise(function(i,a){n.get("http://"+t.env.HOST+":"+t.env.PORT+"/gettrustorbalance?assetcode="+e+"&issuer="+r+"&accountid="+o,function(e){var t=e.statusCode,r=e.headers["content-type"],n=void 0;if(200!==t?n=new Error("Request Failed.\nStatus Code: "+t):/^application\/json/.test(r)||(n=new Error("Invalid content-type.\nExpected application/json but received "+r)),n)return e.resume(),void 0;e.setEncoding("utf8");var o="";e.on("data",function(e){o+=e}),e.on("end",function(){try{var e=JSON.parse(o);i(e)}catch(t){a(t.message)}})})})};e.exports={getState:a,getBalance:o,getLedgerSeq:i,getBalanceAsset:s}}).call(t,r(136))},function(e,t,r){function n(e,t){return null==e?e:o(e,i(t),a)}var o=r(119),i=r(122),a=r(78);e.exports=n},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.LedgerCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.LedgerCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("ledgers"),r}return i(t,e),a(t,[{key:"ledger",value:function(e){return this.filter.push(["ledgers",e.toString()]),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.TransactionCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.TransactionCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("transactions"),r}return i(t,e),a(t,[{key:"transaction",value:function(e){return this.filter.push(["transactions",e]),this}},{key:"forAccount",value:function(e){return this.filter.push(["accounts",e,"transactions"]),this}},{key:"forLedger",value:function(e){return"number"==typeof e&&(e=e.toString()),this.filter.push(["ledgers",e,"transactions"]),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.OperationCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.OperationCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("operations"),r}return i(t,e),a(t,[{key:"operation",value:function(e){return this.filter.push(["operations",e]),this}},{key:"forAccount",value:function(e){return this.filter.push(["accounts",e,"operations"]),this}},{key:"forLedger",value:function(e){return"number"==typeof e&&(e=e.toString()),this.filter.push(["ledgers",e,"operations"]),this}},{key:"forTransaction",value:function(e){return this.filter.push(["transactions",e,"operations"]),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.OfferCallBuilder=void 0;{var a=r(115),s=(r(435),r(2));t.OfferCallBuilder=function(e){function t(e,r){n(this,t);var i=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));if("accounts"!==r)throw new s.BadRequestError("Bad resource specified for offer:",r);for(var a=arguments.length,u=Array(a>2?a-2:0),c=2;a>c;c++)u[c-2]=arguments[c];return i.url.segment([r].concat(u,["offers"])),i}return i(t,e),t}(a.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.OrderbookCallBuilder=void 0;{var a=r(115);t.OrderbookCallBuilder=function(e){function t(e,r,i){n(this,t);var a=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return a.url.segment("order_book"),r.isNative()?a.url.setQuery("selling_asset_type","native"):(a.url.setQuery("selling_asset_type",r.getAssetType()),a.url.setQuery("selling_asset_code",r.getCode()),a.url.setQuery("selling_asset_issuer",r.getIssuer())),i.isNative()?a.url.setQuery("buying_asset_type","native"):(a.url.setQuery("buying_asset_type",i.getAssetType()),a.url.setQuery("buying_asset_code",i.getCode()),a.url.setQuery("buying_asset_issuer",i.getIssuer())),a}return i(t,e),t}(a.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.TradesCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.TradesCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("trades"),r}return i(t,e),a(t,[{key:"forAssetPair",value:function(e,t){return e.isNative()?this.url.setQuery("base_asset_type","native"):(this.url.setQuery("base_asset_type",e.getAssetType()),this.url.setQuery("base_asset_code",e.getCode()),this.url.setQuery("base_asset_issuer",e.getIssuer())),t.isNative()?this.url.setQuery("counter_asset_type","native"):(this.url.setQuery("counter_asset_type",t.getAssetType()),this.url.setQuery("counter_asset_code",t.getCode()),this.url.setQuery("counter_asset_issuer",t.getIssuer())),this}},{key:"forOffer",value:function(e){return this.url.setQuery("offer_id",e),this}},{key:"forAccount",value:function(e){return this.filter.push(["accounts",e,"trades"]),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.PathCallBuilder=void 0;{var a=r(115);t.PathCallBuilder=function(e){function t(e,r,i,a,s){n(this,t);var u=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return u.url.segment("paths"),u.url.setQuery("destination_account",i),u.url.setQuery("source_account",r),u.url.setQuery("destination_amount",s),a.isNative()?u.url.setQuery("destination_asset_type","native"):(u.url.setQuery("destination_asset_type",a.getAssetType()),u.url.setQuery("destination_asset_code",a.getCode()),u.url.setQuery("destination_asset_issuer",a.getIssuer())),u}return i(t,e),t}(a.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.PaymentCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.PaymentCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("payments"),r}return i(t,e),a(t,[{key:"forAccount",value:function(e){return this.filter.push(["accounts",e,"payments"]),this}},{key:"forLedger",value:function(e){return"number"==typeof e&&(e=e.toString()),this.filter.push(["ledgers",e,"payments"]),this}},{key:"forTransaction",value:function(e){return this.filter.push(["transactions",e,"payments"]),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.EffectCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.EffectCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("effects"),r}return i(t,e),a(t,[{key:"forAccount",value:function(e){return this.filter.push(["accounts",e,"effects"]),this}},{key:"forLedger",value:function(e){return"number"==typeof e&&(e=e.toString()),this.filter.push(["ledgers",e,"effects"]),this}},{key:"forTransaction",value:function(e){return this.filter.push(["transactions",e,"effects"]),this}},{key:"forOperation",value:function(e){return this.filter.push(["operations",e,"effects"]),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.FriendbotBuilder=void 0;{var a=r(115);t.FriendbotBuilder=function(e){function t(e,r){n(this,t);var i=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return i.url.segment("friendbot"),i.url.setQuery("addr",r),i}return i(t,e),t}(a.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.AssetsCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115);t.AssetsCallBuilder=function(e){function t(e){n(this,t);var r=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.url.segment("assets"),r}return i(t,e),a(t,[{key:"forCode",value:function(e){return this.url.setQuery("asset_code",e),this}},{key:"forIssuer",value:function(e){return this.url.setQuery("asset_issuer",e),this}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0}),t.TradeAggregationCallBuilder=void 0;{var a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(115),u=r(2),c=[6e4,3e5,9e5,36e5,864e5,6048e5];t.TradeAggregationCallBuilder=function(e){function t(e,r,i,a,s,c,f){n(this,t);var l=o(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));if(l.url.segment("trade_aggregations"),r.isNative()?l.url.setQuery("base_asset_type","native"):(l.url.setQuery("base_asset_type",r.getAssetType()),l.url.setQuery("base_asset_code",r.getCode()),l.url.setQuery("base_asset_issuer",r.getIssuer())),i.isNative()?l.url.setQuery("counter_asset_type","native"):(l.url.setQuery("counter_asset_type",i.getAssetType()),l.url.setQuery("counter_asset_code",i.getCode()),l.url.setQuery("counter_asset_issuer",i.getIssuer())),"undefined"==typeof a||"undefined"==typeof s)throw new u.BadRequestError("Invalid time bounds",[a,s]);if(l.url.setQuery("start_time",a),l.url.setQuery("end_time",s),!l.isValidResolution(c))throw new u.BadRequestError("Invalid resolution",c);if(l.url.setQuery("resolution",c),!l.isValidOffset(f,c))throw new u.BadRequestError("Invalid offset",f);return l.url.setQuery("offset",f),l}return i(t,e),a(t,[{key:"isValidResolution",value:function(e){for(var t=!1,r=0;r<c.length;r++)if(c[r]==e){t=!0;break}return t}},{key:"isValidOffset",value:function(e,t){var r=36e5;return!(e>t||e>24*r||e%r!==0)}}]),t}(s.CallBuilder)}},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.FederationServer=t.FEDERATION_RESPONSE_MAX_SIZE=void 0;{var i=function(){function e(e,t){var r=[],n=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(n=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);n=!0);}catch(u){o=!0,i=u}finally{try{!n&&s["return"]&&s["return"]()}finally{if(o)throw i}}return r}return function(t,r){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),s=r(129),u=n(s),c=r(124),f=n(c),l=r(240),h=(n(l),r(444)),p=(n(h),r(3)),d=r(203),y=r(2),v=r(452),g=t.FEDERATION_RESPONSE_MAX_SIZE=102400;t.FederationServer=function(){function e(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};o(this,e),this.serverURL=f.default(t),this.domain=r;var i=p.Config.isAllowHttp();if("undefined"!=typeof n.allowHttp&&(i=n.allowHttp),this.timeout=p.Config.getTimeout(),"number"==typeof n.timeout&&(this.timeout=n.timeout),"https"!=this.serverURL.protocol()&&!i)throw new Error("Cannot connect to insecure federation server")}return a(e,[{key:"resolveAddress",value:function(e){if(e.indexOf("*")<0){if(!this.domain)return Promise.reject(new Error("Unknown domain. Make sure `address` contains a domain (ex. `bob*stellar.org`) or pass `domain` parameter when instantiating the server object."));e=e+"*"+this.domain}var t=this.serverURL.query({type:"name",q:e});return this._sendRequest(t)}},{key:"resolveAccountId",value:function(e){var t=this.serverURL.query({type:"id",q:e});return this._sendRequest(t)}},{key:"resolveTransactionId",value:function(e){var t=this.serverURL.query({type:"txid",q:e});return this._sendRequest(t)}},{key:"_sendRequest",value:function(e){var t=this.timeout;return u.default.get(e.toString(),{maxContentLength:g,timeout:t}).then(function(e){if("undefined"!=typeof e.data.memo&&"string"!=typeof e.data.memo)throw new Error("memo value should be of type string");return e.data}).catch(function(e){if(e instanceof Error){if(e.message.match(/^maxContentLength size/))throw new Error("federation response exceeds allowed size of "+g);return Promise.reject(e)}return Promise.reject(new y.BadResponseError("Server query failed. Server responded: "+e.status+" "+e.statusText,e.data))})}}],[{key:"resolve",value:function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t.indexOf("*")<0)return d.StrKey.isValidEd25519PublicKey(t)?Promise.resolve({account_id:t}):Promise.reject(new Error("Invalid Account ID"));var n=t.split("*"),o=i(n,2),a=o[1];return 2==n.length&&a?e.createForDomain(a,r).then(function(e){return e.resolveAddress(t)}):Promise.reject(new Error("Invalid Stellar address"))}},{key:"createForDomain",value:function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return v.StellarTomlResolver.resolve(t,r).then(function(n){return n.FEDERATION_SERVER?new e(n.FEDERATION_SERVER,t,r):Promise.reject(new Error("stellar.toml does not contain FEDERATION_SERVER field"))})}}]),e}()}},function(e,t,r){var n=r(445),o=r(448),i=o(function(e,t){return null==e?{}:n(e,t)});e.exports=i},function(e,t,r){function n(e,t){return o(e,t,function(t,r){return i(e,r)})}var o=r(446),i=r(295);e.exports=n},function(e,t,r){function n(e,t,r){for(var n=-1,s=t.length,u={};++n<s;){var c=t[n],f=o(e,c);r(f,c)&&i(u,a(c,e),f)}return u}var o=r(284),i=r(447),a=r(285);e.exports=n},function(e,t,r){function n(e,t,r,n){if(!s(e))return e;t=i(t,e);for(var c=-1,f=t.length,l=f-1,h=e;null!=h&&++c<f;){var p=u(t[c]),d=r;if(c!=l){var y=h[p];d=n?n(y,p,h):void 0,void 0===d&&(d=s(y)?y:a(t[c+1])?[]:{})}o(h,p,d),h=h[p]}return e}var o=r(51),i=r(285),a=r(66),s=r(30),u=r(294);e.exports=n},function(e,t,r){function n(e){return a(i(e,void 0,o),e+"")}var o=r(449),i=r(251),a=r(253);e.exports=n},function(e,t,r){function n(e){var t=null==e?0:e.length;return t?o(e,1):[]}var o=r(450);e.exports=n},function(e,t,r){function n(e,t,r,a,s){var u=-1,c=e.length;for(r||(r=i),s||(s=[]);++u<c;){var f=e[u];t>0&&r(f)?t>1?n(f,t-1,r,a,s):o(s,f):a||(s[s.length]=f)}return s}var o=r(89),i=r(451);e.exports=n},function(e,t,r){function n(e){return a(e)||i(e)||!!(s&&e&&e[s])}var o=r(25),i=r(59),a=r(62),s=o?o.isConcatSpreadable:void 0;e.exports=n},function(e,t,r){"use strict";function n(e){return e&&e.__esModule?e:{"default":e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.StellarTomlResolver=t.STELLAR_TOML_MAX_SIZE=void 0;{var i=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),a=r(129),s=n(a),u=r(453),c=n(u),f=r(3),l=t.STELLAR_TOML_MAX_SIZE=102400;t.StellarTomlResolver=function(){function e(){o(this,e)}return i(e,null,[{key:"resolve",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=f.Config.isAllowHttp(),n=f.Config.getTimeout();"undefined"!=typeof t.allowHttp&&(r=t.allowHttp),"number"==typeof t.timeout&&(n=t.timeout);var o="https";return r&&(o="http"),s.default.get(o+"://"+e+"/.well-known/stellar.toml",{maxContentLength:l,timeout:n}).then(function(e){try{var t=c.default.parse(e.data);return Promise.resolve(t)}catch(r){return Promise.reject(new Error("Parsing error on line "+r.line+", column "+r.column+": "+r.message))}}).catch(function(e){throw e.message.match(/^maxContentLength size/)?new Error("stellar.toml file exceeds allowed size of "+l):e})}}]),e}()}},function(e,t,r){var n=r(454),o=r(455);e.exports={parse:function(e){var t=n.parse(e.toString());return o.compile(t)}}},function(e){e.exports=function(){function e(e,t){function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r}function t(e,t,r,n,o,i){this.message=e,this.expected=t,this.found=r,this.offset=n,this.line=o,this.column=i,this.name="SyntaxError"}function r(e){function r(){return o(Cn).line}function n(){return o(Cn).column}function o(t){function r(t,r,n){var o,i;for(o=r;n>o;o++)i=e.charAt(o),"\n"===i?(t.seenCR||t.line++,t.column=1,t.seenCR=!1):"\r"===i||"\u2028"===i||"\u2029"===i?(t.line++,t.column=1,t.seenCR=!0):(t.column++,t.seenCR=!1)}return Pn!==t&&(Pn>t&&(Pn=0,Tn={line:1,column:1,seenCR:!1}),r(Tn,Pn,t),Pn=t),Tn}function i(e){jn>xn||(xn>jn&&(jn=xn,Rn=[]),Rn.push(e))}function a(r,n,i){function a(e){var t=1;for(e.sort(function(e,t){return e.description<t.description?-1:e.description>t.description?1:0});t<e.length;)e[t-1]===e[t]?e.splice(t,1):t++}function s(e,t){function r(e){function t(e){return e.charCodeAt(0).toString(16).toUpperCase()}return e.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\x08/g,"\\b").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\f/g,"\\f").replace(/\r/g,"\\r").replace(/[\x00-\x07\x0B\x0E\x0F]/g,function(e){return"\\x0"+t(e)}).replace(/[\x10-\x1F\x80-\xFF]/g,function(e){return"\\x"+t(e)}).replace(/[\u0180-\u0FFF]/g,function(e){return"\\u0"+t(e)}).replace(/[\u1080-\uFFFF]/g,function(e){return"\\u"+t(e)})}var n,o,i,a=new Array(e.length);for(i=0;i<e.length;i++)a[i]=e[i].description;return n=e.length>1?a.slice(0,-1).join(", ")+" or "+a[e.length-1]:a[0],o=t?'"'+r(t)+'"':"end of input","Expected "+n+" but "+o+" found."
}var u=o(i),c=i<e.length?e.charAt(i):null;return null!==n&&a(n),new t(null!==r?r:s(n,c),n,c,i,u.line,u.column)}function s(){var e,t,r,n=49*xn+0,o=Bn[n];if(o)return xn=o.nextPos,o.result;for(e=xn,t=[],r=u();r!==ct;)t.push(r),r=u();return t!==ct&&(Cn=e,t=ht()),e=t,Bn[n]={nextPos:xn,result:e},e}function u(){var e,t,r,n,o,i,a,s=49*xn+1,u=Bn[s];if(u)return xn=u.nextPos,u.result;for(e=xn,t=[],r=X();r!==ct;)t.push(r),r=X();if(t!==ct)if(r=c(),r!==ct){for(n=[],o=X();o!==ct;)n.push(o),o=X();if(n!==ct){for(o=[],i=f();i!==ct;)o.push(i),i=f();if(o!==ct){if(i=[],a=Q(),a!==ct)for(;a!==ct;)i.push(a),a=Q();else i=pt;i===ct&&(i=$()),i!==ct?(t=[t,r,n,o,i],e=t):(xn=e,e=pt)}else xn=e,e=pt}else xn=e,e=pt}else xn=e,e=pt;else xn=e,e=pt;if(e===ct){if(e=xn,t=[],r=X(),r!==ct)for(;r!==ct;)t.push(r),r=X();else t=pt;if(t!==ct){if(r=[],n=Q(),n!==ct)for(;n!==ct;)r.push(n),n=Q();else r=pt;r===ct&&(r=$()),r!==ct?(t=[t,r],e=t):(xn=e,e=pt)}else xn=e,e=pt;e===ct&&(e=Q())}return Bn[s]={nextPos:xn,result:e},e}function c(){var e,t=49*xn+2,r=Bn[t];return r?(xn=r.nextPos,r.result):(e=f(),e===ct&&(e=l(),e===ct&&(e=h(),e===ct&&(e=v()))),Bn[t]={nextPos:xn,result:e},e)}function f(){var t,r,n,o,a,s,u=49*xn+3,c=Bn[u];if(c)return xn=c.nextPos,c.result;if(t=xn,35===e.charCodeAt(xn)?(r=dt,xn++):(r=ct,0===In&&i(yt)),r!==ct){for(n=[],o=xn,a=xn,In++,s=Q(),s===ct&&(s=$()),In--,s===ct?a=vt:(xn=a,a=pt),a!==ct?(e.length>xn?(s=e.charAt(xn),xn++):(s=ct,0===In&&i(gt)),s!==ct?(a=[a,s],o=a):(xn=o,o=pt)):(xn=o,o=pt);o!==ct;)n.push(o),o=xn,a=xn,In++,s=Q(),s===ct&&(s=$()),In--,s===ct?a=vt:(xn=a,a=pt),a!==ct?(e.length>xn?(s=e.charAt(xn),xn++):(s=ct,0===In&&i(gt)),s!==ct?(a=[a,s],o=a):(xn=o,o=pt)):(xn=o,o=pt);n!==ct?(r=[r,n],t=r):(xn=t,t=pt)}else xn=t,t=pt;return Bn[u]={nextPos:xn,result:t},t}function l(){var t,r,n,o,a,s,u=49*xn+4,c=Bn[u];if(c)return xn=c.nextPos,c.result;if(t=xn,91===e.charCodeAt(xn)?(r=mt,xn++):(r=ct,0===In&&i(bt)),r!==ct){for(n=[],o=X();o!==ct;)n.push(o),o=X();if(n!==ct)if(o=p(),o!==ct){for(a=[],s=X();s!==ct;)a.push(s),s=X();a!==ct?(93===e.charCodeAt(xn)?(s=wt,xn++):(s=ct,0===In&&i(_t)),s!==ct?(Cn=t,r=kt(o),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;return Bn[u]={nextPos:xn,result:t},t}function h(){var t,r,n,o,a,s,u,c,f=49*xn+5,l=Bn[f];if(l)return xn=l.nextPos,l.result;if(t=xn,91===e.charCodeAt(xn)?(r=mt,xn++):(r=ct,0===In&&i(bt)),r!==ct)if(91===e.charCodeAt(xn)?(n=mt,xn++):(n=ct,0===In&&i(bt)),n!==ct){for(o=[],a=X();a!==ct;)o.push(a),a=X();if(o!==ct)if(a=p(),a!==ct){for(s=[],u=X();u!==ct;)s.push(u),u=X();s!==ct?(93===e.charCodeAt(xn)?(u=wt,xn++):(u=ct,0===In&&i(_t)),u!==ct?(93===e.charCodeAt(xn)?(c=wt,xn++):(c=ct,0===In&&i(_t)),c!==ct?(Cn=t,r=At(a),t=r):(xn=t,t=pt)):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt;return Bn[f]={nextPos:xn,result:t},t}function p(){var e,t,r,n=49*xn+6,o=Bn[n];if(o)return xn=o.nextPos,o.result;if(e=xn,t=[],r=y(),r!==ct)for(;r!==ct;)t.push(r),r=y();else t=pt;return t!==ct?(r=d(),r!==ct?(Cn=e,t=Ot(t,r),e=t):(xn=e,e=pt)):(xn=e,e=pt),e===ct&&(e=xn,t=d(),t!==ct&&(Cn=e,t=Et(t)),e=t),Bn[n]={nextPos:xn,result:e},e}function d(){var e,t,r,n,o,i=49*xn+7,a=Bn[i];if(a)return xn=a.nextPos,a.result;for(e=xn,t=[],r=X();r!==ct;)t.push(r),r=X();if(t!==ct)if(r=g(),r!==ct){for(n=[],o=X();o!==ct;)n.push(o),o=X();n!==ct?(Cn=e,t=St(r),e=t):(xn=e,e=pt)}else xn=e,e=pt;else xn=e,e=pt;if(e===ct){for(e=xn,t=[],r=X();r!==ct;)t.push(r),r=X();if(t!==ct)if(r=m(),r!==ct){for(n=[],o=X();o!==ct;)n.push(o),o=X();n!==ct?(Cn=e,t=St(r),e=t):(xn=e,e=pt)}else xn=e,e=pt;else xn=e,e=pt}return Bn[i]={nextPos:xn,result:e},e}function y(){var t,r,n,o,a,s,u,c=49*xn+8,f=Bn[c];if(f)return xn=f.nextPos,f.result;for(t=xn,r=[],n=X();n!==ct;)r.push(n),n=X();if(r!==ct)if(n=g(),n!==ct){for(o=[],a=X();a!==ct;)o.push(a),a=X();if(o!==ct)if(46===e.charCodeAt(xn)?(a=xt,xn++):(a=ct,0===In&&i(Ct)),a!==ct){for(s=[],u=X();u!==ct;)s.push(u),u=X();s!==ct?(Cn=t,r=St(n),t=r):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt;if(t===ct){for(t=xn,r=[],n=X();n!==ct;)r.push(n),n=X();if(r!==ct)if(n=m(),n!==ct){for(o=[],a=X();a!==ct;)o.push(a),a=X();if(o!==ct)if(46===e.charCodeAt(xn)?(a=xt,xn++):(a=ct,0===In&&i(Ct)),a!==ct){for(s=[],u=X();u!==ct;)s.push(u),u=X();s!==ct?(Cn=t,r=St(n),t=r):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt}return Bn[c]={nextPos:xn,result:t},t}function v(){var t,r,n,o,a,s,u=49*xn+9,c=Bn[u];if(c)return xn=c.nextPos,c.result;if(t=xn,r=g(),r!==ct){for(n=[],o=X();o!==ct;)n.push(o),o=X();if(n!==ct)if(61===e.charCodeAt(xn)?(o=Pt,xn++):(o=ct,0===In&&i(Tt)),o!==ct){for(a=[],s=X();s!==ct;)a.push(s),s=X();a!==ct?(s=b(),s!==ct?(Cn=t,r=jt(r,s),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;if(t===ct)if(t=xn,r=m(),r!==ct){for(n=[],o=X();o!==ct;)n.push(o),o=X();if(n!==ct)if(61===e.charCodeAt(xn)?(o=Pt,xn++):(o=ct,0===In&&i(Tt)),o!==ct){for(a=[],s=X();s!==ct;)a.push(s),s=X();a!==ct?(s=b(),s!==ct?(Cn=t,r=jt(r,s),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;return Bn[u]={nextPos:xn,result:t},t}function g(){var e,t,r,n=49*xn+10,o=Bn[n];if(o)return xn=o.nextPos,o.result;if(e=xn,t=[],r=G(),r!==ct)for(;r!==ct;)t.push(r),r=G();else t=pt;return t!==ct&&(Cn=e,t=Rt(t)),e=t,Bn[n]={nextPos:xn,result:e},e}function m(){var e,t,r=49*xn+11,n=Bn[r];return n?(xn=n.nextPos,n.result):(e=xn,t=k(),t!==ct&&(Cn=e,t=It(t)),e=t,e===ct&&(e=xn,t=O(),t!==ct&&(Cn=e,t=It(t)),e=t),Bn[r]={nextPos:xn,result:e},e)}function b(){var e,t=49*xn+12,r=Bn[t];return r?(xn=r.nextPos,r.result):(e=w(),e===ct&&(e=K(),e===ct&&(e=T(),e===ct&&(e=R(),e===ct&&(e=B(),e===ct&&(e=M(),e===ct&&(e=D())))))),Bn[t]={nextPos:xn,result:e},e)}function w(){var e,t=49*xn+13,r=Bn[t];return r?(xn=r.nextPos,r.result):(e=_(),e===ct&&(e=k(),e===ct&&(e=A(),e===ct&&(e=O()))),Bn[t]={nextPos:xn,result:e},e)}function _(){var t,r,n,o,a,s=49*xn+14,u=Bn[s];if(u)return xn=u.nextPos,u.result;if(t=xn,e.substr(xn,3)===Bt?(r=Bt,xn+=3):(r=ct,0===In&&i(Mt)),r!==ct)if(n=Q(),n===ct&&(n=Nt),n!==ct){for(o=[],a=x();a!==ct;)o.push(a),a=x();o!==ct?(e.substr(xn,3)===Bt?(a=Bt,xn+=3):(a=ct,0===In&&i(Mt)),a!==ct?(Cn=t,r=Ut(o),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt;return Bn[s]={nextPos:xn,result:t},t}function k(){var t,r,n,o,a=49*xn+15,s=Bn[a];if(s)return xn=s.nextPos,s.result;if(t=xn,34===e.charCodeAt(xn)?(r=Lt,xn++):(r=ct,0===In&&i(Dt)),r!==ct){for(n=[],o=E();o!==ct;)n.push(o),o=E();n!==ct?(34===e.charCodeAt(xn)?(o=Lt,xn++):(o=ct,0===In&&i(Dt)),o!==ct?(Cn=t,r=Ut(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;return Bn[a]={nextPos:xn,result:t},t}function A(){var t,r,n,o,a,s=49*xn+16,u=Bn[s];if(u)return xn=u.nextPos,u.result;if(t=xn,e.substr(xn,3)===qt?(r=qt,xn+=3):(r=ct,0===In&&i(Ft)),r!==ct)if(n=Q(),n===ct&&(n=Nt),n!==ct){for(o=[],a=P();a!==ct;)o.push(a),a=P();o!==ct?(e.substr(xn,3)===qt?(a=qt,xn+=3):(a=ct,0===In&&i(Ft)),a!==ct?(Cn=t,r=Ut(o),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt;return Bn[s]={nextPos:xn,result:t},t}function O(){var t,r,n,o,a=49*xn+17,s=Bn[a];if(s)return xn=s.nextPos,s.result;if(t=xn,39===e.charCodeAt(xn)?(r=zt,xn++):(r=ct,0===In&&i(Ht)),r!==ct){for(n=[],o=S();o!==ct;)n.push(o),o=S();n!==ct?(39===e.charCodeAt(xn)?(o=zt,xn++):(o=ct,0===In&&i(Ht)),o!==ct?(Cn=t,r=Ut(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;return Bn[a]={nextPos:xn,result:t},t}function E(){var t,r,n,o=49*xn+18,a=Bn[o];return a?(xn=a.nextPos,a.result):(t=et(),t===ct&&(t=xn,r=xn,In++,34===e.charCodeAt(xn)?(n=Lt,xn++):(n=ct,0===In&&i(Dt)),In--,n===ct?r=vt:(xn=r,r=pt),r!==ct?(e.length>xn?(n=e.charAt(xn),xn++):(n=ct,0===In&&i(gt)),n!==ct?(Cn=t,r=Vt(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)),Bn[o]={nextPos:xn,result:t},t)}function S(){var t,r,n,o=49*xn+19,a=Bn[o];return a?(xn=a.nextPos,a.result):(t=xn,r=xn,In++,39===e.charCodeAt(xn)?(n=zt,xn++):(n=ct,0===In&&i(Ht)),In--,n===ct?r=vt:(xn=r,r=pt),r!==ct?(e.length>xn?(n=e.charAt(xn),xn++):(n=ct,0===In&&i(gt)),n!==ct?(Cn=t,r=Vt(n),t=r):(xn=t,t=pt)):(xn=t,t=pt),Bn[o]={nextPos:xn,result:t},t)}function x(){var t,r,n,o=49*xn+20,a=Bn[o];return a?(xn=a.nextPos,a.result):(t=et(),t===ct&&(t=C(),t===ct&&(t=xn,r=xn,In++,e.substr(xn,3)===Bt?(n=Bt,xn+=3):(n=ct,0===In&&i(Mt)),In--,n===ct?r=vt:(xn=r,r=pt),r!==ct?(e.length>xn?(n=e.charAt(xn),xn++):(n=ct,0===In&&i(gt)),n!==ct?(Cn=t,r=Kt(n),t=r):(xn=t,t=pt)):(xn=t,t=pt))),Bn[o]={nextPos:xn,result:t},t)}function C(){var t,r,n,o,a,s=49*xn+21,u=Bn[s];if(u)return xn=u.nextPos,u.result;if(t=xn,92===e.charCodeAt(xn)?(r=Xt,xn++):(r=ct,0===In&&i(Qt)),r!==ct)if(n=Q(),n!==ct){for(o=[],a=Y();a!==ct;)o.push(a),a=Y();o!==ct?(Cn=t,r=Yt(),t=r):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt;return Bn[s]={nextPos:xn,result:t},t}function P(){var t,r,n,o=49*xn+22,a=Bn[o];return a?(xn=a.nextPos,a.result):(t=xn,r=xn,In++,e.substr(xn,3)===qt?(n=qt,xn+=3):(n=ct,0===In&&i(Ft)),In--,n===ct?r=vt:(xn=r,r=pt),r!==ct?(e.length>xn?(n=e.charAt(xn),xn++):(n=ct,0===In&&i(gt)),n!==ct?(Cn=t,r=Vt(n),t=r):(xn=t,t=pt)):(xn=t,t=pt),Bn[o]={nextPos:xn,result:t},t)}function T(){var t,r,n,o,a=49*xn+23,s=Bn[a];return s?(xn=s.nextPos,s.result):(t=xn,r=j(),r===ct&&(r=I()),r!==ct?(101===e.charCodeAt(xn)?(n=$t,xn++):(n=ct,0===In&&i(Wt)),n===ct&&(69===e.charCodeAt(xn)?(n=Zt,xn++):(n=ct,0===In&&i(Gt))),n!==ct?(o=I(),o!==ct?(Cn=t,r=Jt(r,o),t=r):(xn=t,t=pt)):(xn=t,t=pt)):(xn=t,t=pt),t===ct&&(t=xn,r=j(),r!==ct&&(Cn=t,r=er(r)),t=r),Bn[a]={nextPos:xn,result:t},t)}function j(){var t,r,n,o,a,s,u=49*xn+24,c=Bn[u];return c?(xn=c.nextPos,c.result):(t=xn,43===e.charCodeAt(xn)?(r=tr,xn++):(r=ct,0===In&&i(rr)),r===ct&&(r=Nt),r!==ct?(n=xn,o=J(),o!==ct?(46===e.charCodeAt(xn)?(a=xt,xn++):(a=ct,0===In&&i(Ct)),a!==ct?(s=J(),s!==ct?(o=[o,a,s],n=o):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt),n!==ct?(Cn=t,r=nr(n),t=r):(xn=t,t=pt)):(xn=t,t=pt),t===ct&&(t=xn,45===e.charCodeAt(xn)?(r=or,xn++):(r=ct,0===In&&i(ir)),r!==ct?(n=xn,o=J(),o!==ct?(46===e.charCodeAt(xn)?(a=xt,xn++):(a=ct,0===In&&i(Ct)),a!==ct?(s=J(),s!==ct?(o=[o,a,s],n=o):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt),n!==ct?(Cn=t,r=ar(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)),Bn[u]={nextPos:xn,result:t},t)}function R(){var e,t,r=49*xn+25,n=Bn[r];return n?(xn=n.nextPos,n.result):(e=xn,t=I(),t!==ct&&(Cn=e,t=sr(t)),e=t,Bn[r]={nextPos:xn,result:e},e)}function I(){var t,r,n,o,a,s=49*xn+26,u=Bn[s];if(u)return xn=u.nextPos,u.result;if(t=xn,43===e.charCodeAt(xn)?(r=tr,xn++):(r=ct,0===In&&i(rr)),r===ct&&(r=Nt),r!==ct){if(n=[],o=Z(),o!==ct)for(;o!==ct;)n.push(o),o=Z();else n=pt;n!==ct?(o=xn,In++,46===e.charCodeAt(xn)?(a=xt,xn++):(a=ct,0===In&&i(Ct)),In--,a===ct?o=vt:(xn=o,o=pt),o!==ct?(Cn=t,r=nr(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;if(t===ct)if(t=xn,45===e.charCodeAt(xn)?(r=or,xn++):(r=ct,0===In&&i(ir)),r!==ct){if(n=[],o=Z(),o!==ct)for(;o!==ct;)n.push(o),o=Z();else n=pt;n!==ct?(o=xn,In++,46===e.charCodeAt(xn)?(a=xt,xn++):(a=ct,0===In&&i(Ct)),In--,a===ct?o=vt:(xn=o,o=pt),o!==ct?(Cn=t,r=ar(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;return Bn[s]={nextPos:xn,result:t},t}function B(){var t,r,n=49*xn+27,o=Bn[n];return o?(xn=o.nextPos,o.result):(t=xn,e.substr(xn,4)===ur?(r=ur,xn+=4):(r=ct,0===In&&i(cr)),r!==ct&&(Cn=t,r=fr()),t=r,t===ct&&(t=xn,e.substr(xn,5)===lr?(r=lr,xn+=5):(r=ct,0===In&&i(hr)),r!==ct&&(Cn=t,r=pr()),t=r),Bn[n]={nextPos:xn,result:t},t)}function M(){var t,r,n,o,a,s=49*xn+28,u=Bn[s];if(u)return xn=u.nextPos,u.result;if(t=xn,91===e.charCodeAt(xn)?(r=mt,xn++):(r=ct,0===In&&i(bt)),r!==ct){for(n=[],o=L();o!==ct;)n.push(o),o=L();n!==ct?(93===e.charCodeAt(xn)?(o=wt,xn++):(o=ct,0===In&&i(_t)),o!==ct?(Cn=t,r=dr(),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;if(t===ct&&(t=xn,91===e.charCodeAt(xn)?(r=mt,xn++):(r=ct,0===In&&i(bt)),r!==ct?(n=N(),n===ct&&(n=Nt),n!==ct?(93===e.charCodeAt(xn)?(o=wt,xn++):(o=ct,0===In&&i(_t)),o!==ct?(Cn=t,r=yr(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)):(xn=t,t=pt),t===ct)){if(t=xn,91===e.charCodeAt(xn)?(r=mt,xn++):(r=ct,0===In&&i(bt)),r!==ct){if(n=[],o=U(),o!==ct)for(;o!==ct;)n.push(o),o=U();else n=pt;n!==ct?(93===e.charCodeAt(xn)?(o=wt,xn++):(o=ct,0===In&&i(_t)),o!==ct?(Cn=t,r=vr(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;if(t===ct)if(t=xn,91===e.charCodeAt(xn)?(r=mt,xn++):(r=ct,0===In&&i(bt)),r!==ct){if(n=[],o=U(),o!==ct)for(;o!==ct;)n.push(o),o=U();else n=pt;n!==ct?(o=N(),o!==ct?(93===e.charCodeAt(xn)?(a=wt,xn++):(a=ct,0===In&&i(_t)),a!==ct?(Cn=t,r=gr(n,o),t=r):(xn=t,t=pt)):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt}return Bn[s]={nextPos:xn,result:t},t}function N(){var e,t,r,n,o,i=49*xn+29,a=Bn[i];if(a)return xn=a.nextPos,a.result;for(e=xn,t=[],r=L();r!==ct;)t.push(r),r=L();if(t!==ct)if(r=b(),r!==ct){for(n=[],o=L();o!==ct;)n.push(o),o=L();n!==ct?(Cn=e,t=mr(r),e=t):(xn=e,e=pt)}else xn=e,e=pt;else xn=e,e=pt;return Bn[i]={nextPos:xn,result:e},e}function U(){var t,r,n,o,a,s,u,c=49*xn+30,f=Bn[c];if(f)return xn=f.nextPos,f.result;for(t=xn,r=[],n=L();n!==ct;)r.push(n),n=L();if(r!==ct)if(n=b(),n!==ct){for(o=[],a=L();a!==ct;)o.push(a),a=L();if(o!==ct)if(44===e.charCodeAt(xn)?(a=br,xn++):(a=ct,0===In&&i(wr)),a!==ct){for(s=[],u=L();u!==ct;)s.push(u),u=L();s!==ct?(Cn=t,r=mr(n),t=r):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt;return Bn[c]={nextPos:xn,result:t},t}function L(){var e,t=49*xn+31,r=Bn[t];return r?(xn=r.nextPos,r.result):(e=X(),e===ct&&(e=Q(),e===ct&&(e=f())),Bn[t]={nextPos:xn,result:e},e)}function D(){var t,r,n,o,a,s,u=49*xn+32,c=Bn[u];if(c)return xn=c.nextPos,c.result;if(t=xn,123===e.charCodeAt(xn)?(r=_r,xn++):(r=ct,0===In&&i(kr)),r!==ct){for(n=[],o=X();o!==ct;)n.push(o),o=X();if(n!==ct){for(o=[],a=q();a!==ct;)o.push(a),a=q();if(o!==ct){for(a=[],s=X();s!==ct;)a.push(s),s=X();a!==ct?(125===e.charCodeAt(xn)?(s=Ar,xn++):(s=ct,0===In&&i(Or)),s!==ct?(Cn=t,r=Er(o),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt}else xn=t,t=pt}else xn=t,t=pt;return Bn[u]={nextPos:xn,result:t},t}function q(){var t,r,n,o,a,s,u,c,f,l,h,p=49*xn+33,d=Bn[p];if(d)return xn=d.nextPos,d.result;for(t=xn,r=[],n=X();n!==ct;)r.push(n),n=X();if(r!==ct)if(n=g(),n!==ct){for(o=[],a=X();a!==ct;)o.push(a),a=X();if(o!==ct)if(61===e.charCodeAt(xn)?(a=Pt,xn++):(a=ct,0===In&&i(Tt)),a!==ct){for(s=[],u=X();u!==ct;)s.push(u),u=X();if(s!==ct)if(u=b(),u!==ct){for(c=[],f=X();f!==ct;)c.push(f),f=X();if(c!==ct)if(44===e.charCodeAt(xn)?(f=br,xn++):(f=ct,0===In&&i(wr)),f!==ct){for(l=[],h=X();h!==ct;)l.push(h),h=X();l!==ct?(Cn=t,r=Sr(n,u),t=r):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt;if(t===ct){for(t=xn,r=[],n=X();n!==ct;)r.push(n),n=X();if(r!==ct)if(n=g(),n!==ct){for(o=[],a=X();a!==ct;)o.push(a),a=X();if(o!==ct)if(61===e.charCodeAt(xn)?(a=Pt,xn++):(a=ct,0===In&&i(Tt)),a!==ct){for(s=[],u=X();u!==ct;)s.push(u),u=X();s!==ct?(u=b(),u!==ct?(Cn=t,r=Sr(n,u),t=r):(xn=t,t=pt)):(xn=t,t=pt)}else xn=t,t=pt;else xn=t,t=pt}else xn=t,t=pt;else xn=t,t=pt}return Bn[p]={nextPos:xn,result:t},t}function F(){var t,r,n,o=49*xn+34,a=Bn[o];return a?(xn=a.nextPos,a.result):(t=xn,46===e.charCodeAt(xn)?(r=xt,xn++):(r=ct,0===In&&i(Ct)),r!==ct?(n=J(),n!==ct?(Cn=t,r=xr(n),t=r):(xn=t,t=pt)):(xn=t,t=pt),Bn[o]={nextPos:xn,result:t},t)}function z(){var t,r,n,o,a,s,u,c,f,l,h,p,d=49*xn+35,y=Bn[d];return y?(xn=y.nextPos,y.result):(t=xn,r=xn,n=Z(),n!==ct?(o=Z(),o!==ct?(a=Z(),a!==ct?(s=Z(),s!==ct?(45===e.charCodeAt(xn)?(u=or,xn++):(u=ct,0===In&&i(ir)),u!==ct?(c=Z(),c!==ct?(f=Z(),f!==ct?(45===e.charCodeAt(xn)?(l=or,xn++):(l=ct,0===In&&i(ir)),l!==ct?(h=Z(),h!==ct?(p=Z(),p!==ct?(n=[n,o,a,s,u,c,f,l,h,p],r=n):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt),r!==ct&&(Cn=t,r=Cr(r)),t=r,Bn[d]={nextPos:xn,result:t},t)}function H(){var t,r,n,o,a,s,u,c,f,l,h,p=49*xn+36,d=Bn[p];return d?(xn=d.nextPos,d.result):(t=xn,r=xn,n=Z(),n!==ct?(o=Z(),o!==ct?(58===e.charCodeAt(xn)?(a=Pr,xn++):(a=ct,0===In&&i(Tr)),a!==ct?(s=Z(),s!==ct?(u=Z(),u!==ct?(58===e.charCodeAt(xn)?(c=Pr,xn++):(c=ct,0===In&&i(Tr)),c!==ct?(f=Z(),f!==ct?(l=Z(),l!==ct?(h=F(),h===ct&&(h=Nt),h!==ct?(n=[n,o,a,s,u,c,f,l,h],r=n):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt),r!==ct&&(Cn=t,r=jr(r)),t=r,Bn[p]={nextPos:xn,result:t},t)}function V(){var t,r,n,o,a,s,u,c,f,l,h,p,d,y,v,g,m,b=49*xn+37,w=Bn[b];return w?(xn=w.nextPos,w.result):(t=xn,r=xn,n=Z(),n!==ct?(o=Z(),o!==ct?(58===e.charCodeAt(xn)?(a=Pr,xn++):(a=ct,0===In&&i(Tr)),a!==ct?(s=Z(),s!==ct?(u=Z(),u!==ct?(58===e.charCodeAt(xn)?(c=Pr,xn++):(c=ct,0===In&&i(Tr)),c!==ct?(f=Z(),f!==ct?(l=Z(),l!==ct?(h=F(),h===ct&&(h=Nt),h!==ct?(45===e.charCodeAt(xn)?(p=or,xn++):(p=ct,0===In&&i(ir)),p===ct&&(43===e.charCodeAt(xn)?(p=tr,xn++):(p=ct,0===In&&i(rr))),p!==ct?(d=Z(),d!==ct?(y=Z(),y!==ct?(58===e.charCodeAt(xn)?(v=Pr,xn++):(v=ct,0===In&&i(Tr)),v!==ct?(g=Z(),g!==ct?(m=Z(),m!==ct?(n=[n,o,a,s,u,c,f,l,h,p,d,y,v,g,m],r=n):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt)):(xn=r,r=pt),r!==ct&&(Cn=t,r=jr(r)),t=r,Bn[b]={nextPos:xn,result:t},t)}function K(){var t,r,n,o,a,s=49*xn+38,u=Bn[s];return u?(xn=u.nextPos,u.result):(t=xn,r=z(),r!==ct?(84===e.charCodeAt(xn)?(n=Rr,xn++):(n=ct,0===In&&i(Ir)),n!==ct?(o=H(),o!==ct?(90===e.charCodeAt(xn)?(a=Br,xn++):(a=ct,0===In&&i(Mr)),a!==ct?(Cn=t,r=Nr(r,o),t=r):(xn=t,t=pt)):(xn=t,t=pt)):(xn=t,t=pt)):(xn=t,t=pt),t===ct&&(t=xn,r=z(),r!==ct?(84===e.charCodeAt(xn)?(n=Rr,xn++):(n=ct,0===In&&i(Ir)),n!==ct?(o=V(),o!==ct?(Cn=t,r=Ur(r,o),t=r):(xn=t,t=pt)):(xn=t,t=pt)):(xn=t,t=pt)),Bn[s]={nextPos:xn,result:t},t)}function X(){var t,r=49*xn+39,n=Bn[r];return n?(xn=n.nextPos,n.result):(Lr.test(e.charAt(xn))?(t=e.charAt(xn),xn++):(t=ct,0===In&&i(Dr)),Bn[r]={nextPos:xn,result:t},t)}function Q(){var t,r,n,o=49*xn+40,a=Bn[o];return a?(xn=a.nextPos,a.result):(10===e.charCodeAt(xn)?(t=qr,xn++):(t=ct,0===In&&i(Fr)),t===ct&&(t=xn,13===e.charCodeAt(xn)?(r=zr,xn++):(r=ct,0===In&&i(Hr)),r!==ct?(10===e.charCodeAt(xn)?(n=qr,xn++):(n=ct,0===In&&i(Fr)),n!==ct?(r=[r,n],t=r):(xn=t,t=pt)):(xn=t,t=pt)),Bn[o]={nextPos:xn,result:t},t)}function Y(){var e,t=49*xn+41,r=Bn[t];return r?(xn=r.nextPos,r.result):(e=Q(),e===ct&&(e=X()),Bn[t]={nextPos:xn,result:e},e)}function $(){var t,r,n=49*xn+42,o=Bn[n];return o?(xn=o.nextPos,o.result):(t=xn,In++,e.length>xn?(r=e.charAt(xn),xn++):(r=ct,0===In&&i(gt)),In--,r===ct?t=vt:(xn=t,t=pt),Bn[n]={nextPos:xn,result:t},t)}function W(){var t,r=49*xn+43,n=Bn[r];return n?(xn=n.nextPos,n.result):(Vr.test(e.charAt(xn))?(t=e.charAt(xn),xn++):(t=ct,0===In&&i(Kr)),Bn[r]={nextPos:xn,result:t},t)}function Z(){var t,r,n=49*xn+44,o=Bn[n];return o?(xn=o.nextPos,o.result):(Xr.test(e.charAt(xn))?(t=e.charAt(xn),xn++):(t=ct,0===In&&i(Qr)),t===ct&&(t=xn,95===e.charCodeAt(xn)?(r=Yr,xn++):(r=ct,0===In&&i($r)),r!==ct&&(Cn=t,r=Wr()),t=r),Bn[n]={nextPos:xn,result:t},t)}function G(){var t,r=49*xn+45,n=Bn[r];return n?(xn=n.nextPos,n.result):(Zr.test(e.charAt(xn))?(t=e.charAt(xn),xn++):(t=ct,0===In&&i(Gr)),Bn[r]={nextPos:xn,result:t},t)}function J(){var e,t,r,n=49*xn+46,o=Bn[n];if(o)return xn=o.nextPos,o.result;if(e=xn,t=[],r=Z(),r!==ct)for(;r!==ct;)t.push(r),r=Z();else t=pt;return t!==ct&&(Cn=e,t=Jr(t)),e=t,Bn[n]={nextPos:xn,result:e},e}function et(){var t,r,n=49*xn+47,o=Bn[n];return o?(xn=o.nextPos,o.result):(t=xn,e.substr(xn,2)===en?(r=en,xn+=2):(r=ct,0===In&&i(tn)),r!==ct&&(Cn=t,r=rn()),t=r,t===ct&&(t=xn,e.substr(xn,2)===nn?(r=nn,xn+=2):(r=ct,0===In&&i(on)),r!==ct&&(Cn=t,r=an()),t=r,t===ct&&(t=xn,e.substr(xn,2)===sn?(r=sn,xn+=2):(r=ct,0===In&&i(un)),r!==ct&&(Cn=t,r=cn()),t=r,t===ct&&(t=xn,e.substr(xn,2)===fn?(r=fn,xn+=2):(r=ct,0===In&&i(ln)),r!==ct&&(Cn=t,r=hn()),t=r,t===ct&&(t=xn,e.substr(xn,2)===pn?(r=pn,xn+=2):(r=ct,0===In&&i(dn)),r!==ct&&(Cn=t,r=yn()),t=r,t===ct&&(t=xn,e.substr(xn,2)===vn?(r=vn,xn+=2):(r=ct,0===In&&i(gn)),r!==ct&&(Cn=t,r=mn()),t=r,t===ct&&(t=xn,e.substr(xn,2)===bn?(r=bn,xn+=2):(r=ct,0===In&&i(wn)),r!==ct&&(Cn=t,r=_n()),t=r,t===ct&&(t=tt()))))))),Bn[n]={nextPos:xn,result:t},t)}function tt(){var t,r,n,o,a,s,u,c,f,l,h,p=49*xn+48,d=Bn[p];return d?(xn=d.nextPos,d.result):(t=xn,e.substr(xn,2)===kn?(r=kn,xn+=2):(r=ct,0===In&&i(An)),r!==ct?(n=xn,o=W(),o!==ct?(a=W(),a!==ct?(s=W(),s!==ct?(u=W(),u!==ct?(c=W(),c!==ct?(f=W(),f!==ct?(l=W(),l!==ct?(h=W(),h!==ct?(o=[o,a,s,u,c,f,l,h],n=o):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt),n!==ct?(Cn=t,r=On(n),t=r):(xn=t,t=pt)):(xn=t,t=pt),t===ct&&(t=xn,e.substr(xn,2)===En?(r=En,xn+=2):(r=ct,0===In&&i(Sn)),r!==ct?(n=xn,o=W(),o!==ct?(a=W(),a!==ct?(s=W(),s!==ct?(u=W(),u!==ct?(o=[o,a,s,u],n=o):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt)):(xn=n,n=pt),n!==ct?(Cn=t,r=On(n),t=r):(xn=t,t=pt)):(xn=t,t=pt)),Bn[p]={nextPos:xn,result:t},t)}function rt(e,t,r){var n=new Error(e);throw n.line=t,n.column=r,n}function nt(e){Mn.push(e)}function ot(e,t,r,n,o){var i={type:e,value:t,line:r(),column:n()};return o&&(i.key=o),i}function it(e,t,r){var n=parseInt("0x"+e);return!isFinite(n)||Math.floor(n)!=n||0>n||n>1114111||n>55295&&57344>n?(rt("Invalid Unicode escape code: "+e,t,r),void 0):at(n)}function at(){var e,t,r=16384,n=[],o=-1,i=arguments.length;if(!i)return"";for(var a="";++o<i;){var s=Number(arguments[o]);65535>=s?n.push(s):(s-=65536,e=(s>>10)+55296,t=s%1024+56320,n.push(e,t)),(o+1==i||n.length>r)&&(a+=String.fromCharCode.apply(null,n),n.length=0)}return a}var st,ut=arguments.length>1?arguments[1]:{},ct={},ft={start:s},lt=s,ht=function(){return Mn},pt=ct,dt="#",yt={type:"literal",value:"#",description:'"#"'},vt=void 0,gt={type:"any",description:"any character"},mt="[",bt={type:"literal",value:"[",description:'"["'},wt="]",_t={type:"literal",value:"]",description:'"]"'},kt=function(e){nt(ot("ObjectPath",e,r,n))},At=function(e){nt(ot("ArrayPath",e,r,n))},Ot=function(e,t){return e.concat(t)},Et=function(e){return[e]},St=function(e){return e},xt=".",Ct={type:"literal",value:".",description:'"."'},Pt="=",Tt={type:"literal",value:"=",description:'"="'},jt=function(e,t){nt(ot("Assign",t,r,n,e))},Rt=function(e){return e.join("")},It=function(e){return e.value},Bt='"""',Mt={type:"literal",value:'"""',description:'"\\"\\"\\""'},Nt=null,Ut=function(e){return ot("String",e.join(""),r,n)},Lt='"',Dt={type:"literal",value:'"',description:'"\\""'},qt="'''",Ft={type:"literal",value:"'''",description:"\"'''\""},zt="'",Ht={type:"literal",value:"'",description:'"\'"'},Vt=function(e){return e},Kt=function(e){return e},Xt="\\",Qt={type:"literal",value:"\\",description:'"\\\\"'},Yt=function(){return""},$t="e",Wt={type:"literal",value:"e",description:'"e"'},Zt="E",Gt={type:"literal",value:"E",description:'"E"'},Jt=function(e,t){return ot("Float",parseFloat(e+"e"+t),r,n)},er=function(e){return ot("Float",parseFloat(e),r,n)},tr="+",rr={type:"literal",value:"+",description:'"+"'},nr=function(e){return e.join("")},or="-",ir={type:"literal",value:"-",description:'"-"'},ar=function(e){return"-"+e.join("")},sr=function(e){return ot("Integer",parseInt(e,10),r,n)},ur="true",cr={type:"literal",value:"true",description:'"true"'},fr=function(){return ot("Boolean",!0,r,n)},lr="false",hr={type:"literal",value:"false",description:'"false"'},pr=function(){return ot("Boolean",!1,r,n)},dr=function(){return ot("Array",[],r,n)},yr=function(e){return ot("Array",e?[e]:[],r,n)},vr=function(e){return ot("Array",e,r,n)},gr=function(e,t){return ot("Array",e.concat(t),r,n)},mr=function(e){return e},br=",",wr={type:"literal",value:",",description:'","'},_r="{",kr={type:"literal",value:"{",description:'"{"'},Ar="}",Or={type:"literal",value:"}",description:'"}"'},Er=function(e){return ot("InlineTable",e,r,n)},Sr=function(e,t){return ot("InlineTableValue",t,r,n,e)},xr=function(e){return"."+e},Cr=function(e){return e.join("")},Pr=":",Tr={type:"literal",value:":",description:'":"'},jr=function(e){return e.join("")},Rr="T",Ir={type:"literal",value:"T",description:'"T"'},Br="Z",Mr={type:"literal",value:"Z",description:'"Z"'},Nr=function(e,t){return ot("Date",new Date(e+"T"+t+"Z"),r,n)},Ur=function(e,t){return ot("Date",new Date(e+"T"+t),r,n)},Lr=/^[ \t]/,Dr={type:"class",value:"[ \\t]",description:"[ \\t]"},qr="\n",Fr={type:"literal",value:"\n",description:'"\\n"'},zr="\r",Hr={type:"literal",value:"\r",description:'"\\r"'},Vr=/^[0-9a-f]/i,Kr={type:"class",value:"[0-9a-f]i",description:"[0-9a-f]i"},Xr=/^[0-9]/,Qr={type:"class",value:"[0-9]",description:"[0-9]"},Yr="_",$r={type:"literal",value:"_",description:'"_"'},Wr=function(){return""},Zr=/^[A-Za-z0-9_\-]/,Gr={type:"class",value:"[A-Za-z0-9_\\-]",description:"[A-Za-z0-9_\\-]"},Jr=function(e){return e.join("")},en='\\"',tn={type:"literal",value:'\\"',description:'"\\\\\\""'},rn=function(){return'"'},nn="\\\\",on={type:"literal",value:"\\\\",description:'"\\\\\\\\"'},an=function(){return"\\"},sn="\\b",un={type:"literal",value:"\\b",description:'"\\\\b"'},cn=function(){return"\b"},fn="\\t",ln={type:"literal",value:"\\t",description:'"\\\\t"'},hn=function(){return" "},pn="\\n",dn={type:"literal",value:"\\n",description:'"\\\\n"'},yn=function(){return"\n"},vn="\\f",gn={type:"literal",value:"\\f",description:'"\\\\f"'},mn=function(){return"\f"},bn="\\r",wn={type:"literal",value:"\\r",description:'"\\\\r"'},_n=function(){return"\r"},kn="\\U",An={type:"literal",value:"\\U",description:'"\\\\U"'},On=function(e){return it(e.join(""))},En="\\u",Sn={type:"literal",value:"\\u",description:'"\\\\u"'},xn=0,Cn=0,Pn=0,Tn={line:1,column:1,seenCR:!1},jn=0,Rn=[],In=0,Bn={};if("startRule"in ut){if(!(ut.startRule in ft))throw new Error("Can't start parsing from rule \""+ut.startRule+'".');lt=ft[ut.startRule]}var Mn=[];if(st=lt(),st!==ct&&xn===e.length)return st;throw st!==ct&&xn<e.length&&i({type:"end",description:"end of input"}),a(null,Rn,jn)}return e(t,Error),{SyntaxError:t,parse:r}}()},function(e){"use strict";function t(e){function t(e){for(var t,r=0;r<e.length;r++)switch(t=e[r],t.type){case"Assign":n(t);break;case"ObjectPath":s(t);break;case"ArrayPath":u(t)}return y}function r(e,t,r){var n=new Error(e);throw n.line=t,n.column=r,n}function n(e){var t,n=e.key,a=e.value,s=e.line,u=e.column;t=d?d+"."+n:n,"undefined"!=typeof v[n]&&r("Cannot redefine existing key '"+t+"'.",s,u),v[n]=i(a),o(t)||(h.push(t),p.push(t))}function o(e){return-1!==h.indexOf(e)}function i(e){return"Array"===e.type?f(e.value):"InlineTable"===e.type?a(e.value):e.value}function a(e){for(var t={},r=0;r<e.length;r++){var n=e[r];"InlineTable"===n.value.type?t[n.key]=a(n.value.value):"InlineTableValue"===n.type&&(t[n.key]=i(n.value))}return t}function s(e){var t=e.value,n=t.map(l).join("."),i=e.line,a=e.column;o(n)&&r("Cannot redefine existing key '"+t+"'.",i,a),h.push(n),v=c(y,t,{},i,a),d=t}function u(e){var t=e.value,n=t.map(l).join("."),i=e.line,a=e.column;if(o(n)||h.push(n),h=h.filter(function(e){return 0!==e.indexOf(n)}),h.push(n),v=c(y,t,[],i,a),d=n,v instanceof Array){var s={};v.push(s),v=s}else r("Cannot redefine existing key '"+t+"'.",i,a)}function c(e,t,n,o,i){for(var a=[],s="",u=(t.join("."),e),c=0;c<t.length;c++){var f=t[c];a.push(f),s=a.join("."),"undefined"==typeof u[f]?u[f]=c===t.length-1?n:{}:c!==t.length-1&&p.indexOf(s)>-1&&r("Cannot redefine existing key '"+s+"'.",o,i),u=u[f],u instanceof Array&&u.length&&c<t.length-1&&(u=u[u.length-1])}return u}function f(e){for(var t=null,n=0;n<e.length;n++){var o=e[n];null===t?t=o.type:o.type!==t&&r("Cannot add value of type "+o.type+" to array of type "+t+".",o.line,o.column)}return e.map(i)}function l(e){return e.indexOf(".")>-1?'"'+e+'"':e}var h=[],p=[],d="",y={},v=y;return t(e)}e.exports={compile:t}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});{var o=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();r(172),t.CoreConnection=function(){function e(){n(this,e)}return o(e,[{key:"getBalance",value:function(e){return https.get("http://localhost:11626/balance?id="+e,function(e){var t=JSON.stringify(e);return obj=JSON.parse(t),obj.balance}).on("error",function(e){console.log("Error: "+e.message)})}},{key:"getState",value:function(e){return https.get("http://localhost:11626/contract?id="+e,function(e){var t=JSON.stringify(e);return obj=JSON.parse(t),obj.state}).on("error",function(e){console.log("Error: "+e.message)})}},{key:"getLedger",value:function(){return https.get("http://localhost:11626/ledger",function(e){var t=JSON.stringify(e);return obj=JSON.parse(t),obj.num}).on("error",function(e){console.log("Error: "+e.message)})}}]),e}()}},function(e,t,r){(function(t,r){!function(t,r){e.exports=r()}(this,function(){"use strict";function e(e){var t=typeof e;return null!==e&&("object"===t||"function"===t)}function n(e){return"function"==typeof e}function o(e){H=e}function i(e){V=e}function a(){return function(){return t.nextTick(l)}}function s(){return"undefined"!=typeof z?function(){z(l)}:f()}function u(){var e=0,t=new Q(l),r=document.createTextNode("");return t.observe(r,{characterData:!0}),function(){r.data=e=++e%2}}function c(){var e=new MessageChannel;return e.port1.onmessage=l,function(){return e.port2.postMessage(0)}}function f(){var e=setTimeout;return function(){return e(l,1)}}function l(){for(var e=0;F>e;e+=2){var t=W[e],r=W[e+1];t(r),W[e]=void 0,W[e+1]=void 0}F=0}function h(){try{var e=Function("return this")().require("vertx");return z=e.runOnLoop||e.runOnContext,s()}catch(t){return f()}}function p(e,t){var r=this,n=new this.constructor(y);void 0===n[G]&&j(n);var o=r._state;if(o){var i=arguments[o-1];V(function(){return C(o,n,i,r._result)})}else S(r,n,e,t);return n}function d(e){var t=this;if(e&&"object"==typeof e&&e.constructor===t)return e;var r=new t(y);return k(r,e),r}function y(){}function v(){return new TypeError("You cannot resolve a promise with itself")}function g(){return new TypeError("A promises callback cannot return that same promise.")}function m(e,t,r,n){try{e.call(t,r,n)}catch(o){return o}}function b(e,t,r){V(function(e){var n=!1,o=m(r,t,function(r){n||(n=!0,t!==r?k(e,r):O(e,r))},function(t){n||(n=!0,E(e,t))},"Settle: "+(e._label||" unknown promise"));!n&&o&&(n=!0,E(e,o))},e)}function w(e,t){t._state===et?O(e,t._result):t._state===tt?E(e,t._result):S(t,void 0,function(t){return k(e,t)},function(t){return E(e,t)})}function _(e,t,r){t.constructor===e.constructor&&r===p&&t.constructor.resolve===d?w(e,t):void 0===r?O(e,t):n(r)?b(e,t,r):O(e,t)}function k(t,r){if(t===r)E(t,v());else if(e(r)){var n=void 0;try{n=r.then}catch(o){return E(t,o),void 0}_(t,r,n)}else O(t,r)}function A(e){e._onerror&&e._onerror(e._result),x(e)}function O(e,t){e._state===J&&(e._result=t,e._state=et,0!==e._subscribers.length&&V(x,e))}function E(e,t){e._state===J&&(e._state=tt,e._result=t,V(A,e))}function S(e,t,r,n){var o=e._subscribers,i=o.length;e._onerror=null,o[i]=t,o[i+et]=r,o[i+tt]=n,0===i&&e._state&&V(x,e)}function x(e){var t=e._subscribers,r=e._state;if(0!==t.length){for(var n=void 0,o=void 0,i=e._result,a=0;a<t.length;a+=3)n=t[a],o=t[a+r],n?C(r,n,o,i):o(i);e._subscribers.length=0}}function C(e,t,r,o){var i=n(r),a=void 0,s=void 0,u=!0;if(i){try{a=r(o)}catch(c){u=!1,s=c}if(t===a)return E(t,g()),void 0}else a=o;t._state!==J||(i&&u?k(t,a):u===!1?E(t,s):e===et?O(t,a):e===tt&&E(t,a))}function P(e,t){try{t(function(t){k(e,t)},function(t){E(e,t)})}catch(r){E(e,r)}}function T(){return rt++}function j(e){e[G]=rt++,e._state=void 0,e._result=void 0,e._subscribers=[]}function R(){return new Error("Array Methods must be provided an Array")}function I(e){return new nt(this,e).promise}function B(e){var t=this;return q(e)?new t(function(r,n){for(var o=e.length,i=0;o>i;i++)t.resolve(e[i]).then(r,n)}):new t(function(e,t){return t(new TypeError("You must pass an array to race."))})}function M(e){var t=this,r=new t(y);return E(r,e),r}function N(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function U(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")
}function L(){var e=void 0;if("undefined"!=typeof r)e=r;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var n=e.Promise;if(n){var o=null;try{o=Object.prototype.toString.call(n.resolve())}catch(t){}if("[object Promise]"===o&&!n.cast)return}e.Promise=ot}var D=void 0;D=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)};var q=D,F=0,z=void 0,H=void 0,V=function(e,t){W[F]=e,W[F+1]=t,F+=2,2===F&&(H?H(l):Z())},K="undefined"!=typeof window?window:void 0,X=K||{},Q=X.MutationObserver||X.WebKitMutationObserver,Y="undefined"==typeof self&&"undefined"!=typeof t&&"[object process]"==={}.toString.call(t),$="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel,W=new Array(1e3),Z=void 0;Z=Y?a():Q?u():$?c():void 0===K?h():f();var G=Math.random().toString(36).substring(2),J=void 0,et=1,tt=2,rt=0,nt=function(){function e(e,t){this._instanceConstructor=e,this.promise=new e(y),this.promise[G]||j(this.promise),q(t)?(this.length=t.length,this._remaining=t.length,this._result=new Array(this.length),0===this.length?O(this.promise,this._result):(this.length=this.length||0,this._enumerate(t),0===this._remaining&&O(this.promise,this._result))):E(this.promise,R())}return e.prototype._enumerate=function(e){for(var t=0;this._state===J&&t<e.length;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var r=this._instanceConstructor,n=r.resolve;if(n===d){var o=void 0,i=void 0,a=!1;try{o=e.then}catch(s){a=!0,i=s}if(o===p&&e._state!==J)this._settledAt(e._state,t,e._result);else if("function"!=typeof o)this._remaining--,this._result[t]=e;else if(r===ot){var u=new r(y);a?E(u,i):_(u,e,o),this._willSettleAt(u,t)}else this._willSettleAt(new r(function(t){return t(e)}),t)}else this._willSettleAt(n(e),t)},e.prototype._settledAt=function(e,t,r){var n=this.promise;n._state===J&&(this._remaining--,e===tt?E(n,r):this._result[t]=r),0===this._remaining&&O(n,this._result)},e.prototype._willSettleAt=function(e,t){var r=this;S(e,void 0,function(e){return r._settledAt(et,t,e)},function(e){return r._settledAt(tt,t,e)})},e}(),ot=function(){function e(t){this[G]=T(),this._result=this._state=void 0,this._subscribers=[],y!==t&&("function"!=typeof t&&N(),this instanceof e?P(this,t):U())}return e.prototype.catch=function(e){return this.then(null,e)},e.prototype.finally=function(e){var t=this,r=t.constructor;return n(e)?t.then(function(t){return r.resolve(e()).then(function(){return t})},function(t){return r.resolve(e()).then(function(){throw t})}):t.then(e,e)},e}();return ot.prototype.then=p,ot.all=I,ot.race=B,ot.resolve=d,ot.reject=M,ot._setScheduler=o,ot._setAsap=i,ot._asap=V,ot.polyfill=L,ot.Promise=ot,ot})}).call(t,r(136),function(){return this}())}]);