text: /*! For license information please see 2.5fd8ac5f.chunk.js.LICENSE.txt */
  (this["webpackJsonpbuildspace-solana"]=this["webpackJsonpbuildspace-solana"]||[]).push([[2],[function(e,t,r){"use strict";r.d(t,"a",(function(){return L})),r.d(t,"b",(function(){return z})),r.d(t,"c",(function(){return P})),r.d(t,"d",(function(){return U})),r.d(t,"e",(function(){return J})),r.d(t,"f",(function(){return R})),r.d(t,"g",(function(){return N})),r.d(t,"h",(function(){return D})),r.d(t,"i",(function(){return q})),r.d(t,"j",(function(){return H})),r.d(t,"k",(function(){return W})),r.d(t,"l",(function(){return K})),r.d(t,"m",(function(){return V})),r.d(t,"n",(function(){return Z})),r.d(t,"o",(function(){return Y})),r.d(t,"p",(function(){return X})),r.d(t,"q",(function(){return G}));var n=r(62),i=r(65),o=r(31),a=r(63);var u=r(9),s=r(10),c=r(7),f=r(12);function l(e,t){if(null==e)return{};var r,n,i=function(e,t){if(null==e)return{};var r,n,i={},o=Object.keys(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||(i[r]=e[r]);return i}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)r=o[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}var h=r(5),d=r(4),p=r(66),b=r(29),v=r(30),y=r(37),m=r(1),g=r.n(m),w=["message"],k=g.a.mark(M),_=g.a.mark(j),x=function(e){Object(b.a)(r,e);var t=Object(v.a)(r);function r(e,n){var i,o;Object(d.a)(this,r);var a=e.message,u=l(e,w),s=e.path,c=0===s.length?a:"At path: "+s.join(".")+" -- "+a;return i=t.call(this,c),Object.assign(Object(p.a)(i),u),i.name=i.constructor.name,i.failures=function(){var t;return null!=(t=o)?t:o=[e].concat(Object(f.a)(n()))},i}return Object(h.a)(r)}(Object(y.a)(TypeError));function S(e){return"object"===typeof e&&null!=e}function E(e){return"string"===typeof e?JSON.stringify(e):""+e}function O(e){var t=e.next(),r=t.done,n=t.value;return r?void 0:n}function A(e,t,r,n){if(!0!==e){!1===e?e={}:"string"===typeof e&&(e={message:e});var i=t.path,o=t.branch,a=r.type,u=e,s=u.refinement,f=u.message,l=void 0===f?"Expected a value of type `"+a+"`"+(s?" with refinement `"+s+"`":"")+", but received: `"+E(n)+"`":f;return Object(c.a)(Object(c.a)({value:n,type:a,refinement:s,key:i[i.length-1],path:i,branch:o},e),{},{message:l})}}function M(e,t,r,n){var i,o,a,u;return g.a.wrap((function(c){for(;;)switch(c.prev=c.next){case 0:S(f=e)&&"function"===typeof f[Symbol.iterator]||(e=[e]),i=Object(s.a)(e),c.prev=2,i.s();case 4:if((o=i.n()).done){c.next=12;break}if(a=o.value,!(u=A(a,t,r,n))){c.next=10;break}return c.next=10,u;case 10:c.next=4;break;case 12:c.next=17;break;case 14:c.prev=14,c.t0=c.catch(2),i.e(c.t0);case 17:return c.prev=17,i.f(),c.finish(17);case 20:case"end":return c.stop()}var f}),k,null,[[2,14,17,20]])}function j(e,t){var r,n,i,o,a,c,l,h,d,p,b,v,y,m,w,k,x,E,O,A,M,I,P,R,C,T,B,L,z=arguments;return g.a.wrap((function(g){for(;;)switch(g.prev=g.next){case 0:if(r=z.length>2&&void 0!==z[2]?z[2]:{},n=r.path,i=void 0===n?[]:n,o=r.branch,a=void 0===o?[e]:o,c=r.coerce,l=void 0!==c&&c,h=r.mask,d=void 0!==h&&h,p={path:i,branch:a},l&&(e=t.coercer(e,p),d&&"type"!==t.type&&S(t.schema)&&S(e)&&!Array.isArray(e)))for(b in e)void 0===t.schema[b]&&delete e[b];v=!0,y=Object(s.a)(t.validator(e,p)),g.prev=6,y.s();case 8:if((m=y.n()).done){g.next=15;break}return w=m.value,v=!1,g.next=13,[w,void 0];case 13:g.next=8;break;case 15:g.next=20;break;case 17:g.prev=17,g.t0=g.catch(6),y.e(g.t0);case 20:return g.prev=20,y.f(),g.finish(20);case 23:k=Object(s.a)(t.entries(e,p)),g.prev=24,k.s();case 26:if((x=k.n()).done){g.next=53;break}E=Object(u.a)(x.value,3),O=E[0],A=E[1],M=E[2],I=j(A,M,{path:void 0===O?i:[].concat(Object(f.a)(i),[O]),branch:void 0===O?a:[].concat(Object(f.a)(a),[A]),coerce:l,mask:d}),P=Object(s.a)(I),g.prev=30,P.s();case 32:if((R=P.n()).done){g.next=43;break}if(!(C=R.value)[0]){g.next=40;break}return v=!1,g.next=38,[C[0],void 0];case 38:g.next=41;break;case 40:l&&(A=C[1],void 0===O?e=A:e instanceof Map?e.set(O,A):e instanceof Set?e.add(A):S(e)&&(e[O]=A));case 41:g.next=32;break;case 43:g.next=48;break;case 45:g.prev=45,g.t1=g.catch(30),P.e(g.t1);case 48:return g.prev=48,P.f(),g.finish(48);case 51:g.next=26;break;case 53:g.next=58;break;case 55:g.prev=55,g.t2=g.catch(24),k.e(g.t2);case 58:return g.prev=58,k.f(),g.finish(58);case 61:if(!v){g.next=80;break}T=Object(s.a)(t.refiner(e,p)),g.prev=63,T.s();case 65:if((B=T.n()).done){g.next=72;break}return L=B.value,v=!1,g.next=70,[L,void 0];case 70:g.next=65;break;case 72:g.next=77;break;case 74:g.prev=74,g.t3=g.catch(63),T.e(g.t3);case 77:return g.prev=77,T.f(),g.finish(77);case 80:if(!v){g.next=83;break}return g.next=83,[void 0,e];case 83:case"end":return g.stop()}}),_,null,[[6,17,20,23],[24,55,58,61],[30,45,48,51],[63,74,77,80]])}var I=function(){function e(t){var r=this;Object(d.a)(this,e);var n=t.type,i=t.schema,o=t.validator,a=t.refiner,u=t.coercer,s=void 0===u?function(e){return e}:u,c=t.entries,f=void 0===c?g.a.mark((function e(){return g.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:case"end":return e.stop()}}),e)})):c;this.type=n,this.schema=i,this.entries=f,this.coercer=s,this.validator=o?function(e,t){return M(o(e,t),t,r,e)}:function(){return[]},this.refiner=a?function(e,t){return M(a(e,t),t,r,e)}:function(){return[]}}return Object(h.a)(e,[{key:"assert",value:function(e){return P(e,this)}},{key:"create",value:function(e){return R(e,this)}},{key:"is",value:function(e){return C(e,this)}},{key:"mask",value:function(e){return function(e,t){var r=T(e,t,{coerce:!0,mask:!0});if(r[0])throw r[0];return r[1]}(e,this)}},{key:"validate",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return T(e,this,t)}}]),e}();function P(e,t){var r=T(e,t);if(r[0])throw r[0]}function R(e,t){var r=T(e,t,{coerce:!0});if(r[0])throw r[0];return r[1]}function C(e,t){return!T(e,t)[0]}function T(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=j(e,t,r),i=O(n);if(i[0]){var o=new x(i[0],g.a.mark((function e(){var t,r,i;return g.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t=Object(s.a)(n),e.prev=1,t.s();case 3:if((r=t.n()).done){e.next=10;break}if(!(i=r.value)[0]){e.next=8;break}return e.next=8,i[0];case 8:e.next=3;break;case 10:e.next=15;break;case 12:e.prev=12,e.t0=e.catch(1),t.e(e.t0);case 15:return e.prev=15,t.f(),e.finish(15);case 18:case"end":return e.stop()}}),e,null,[[1,12,15,18]])})));return[o,void 0]}var a=i[1];return[void 0,a]}function B(e,t){return new I({type:e,schema:null,validator:t})}function L(){return B("any",(function(){return!0}))}function z(e){return new I({type:"array",schema:e,entries:g.a.mark((function t(r){var n,i,o,a,c;return g.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e||!Array.isArray(r)){t.next=18;break}n=Object(s.a)(r.entries()),t.prev=2,n.s();case 4:if((i=n.n()).done){t.next=10;break}return o=Object(u.a)(i.value,2),a=o[0],c=o[1],t.next=8,[a,c,e];case 8:t.next=4;break;case 10:t.next=15;break;case 12:t.prev=12,t.t0=t.catch(2),n.e(t.t0);case 15:return t.prev=15,n.f(),t.finish(15);case 18:case"end":return t.stop()}}),t,null,[[2,12,15,18]])})),coercer:function(e){return Array.isArray(e)?e.slice():e},validator:function(e){return Array.isArray(e)||"Expected an array value, but received: "+E(e)}})}function U(){return B("boolean",(function(e){return"boolean"===typeof e}))}function N(e){return B("instance",(function(t){return t instanceof e||"Expected a `"+e.name+"` instance, but received: "+E(t)}))}function D(e){var t=E(e),r=typeof e;return new I({type:"literal",schema:"string"===r||"number"===r||"boolean"===r?e:null,validator:function(r){return r===e||"Expected the literal `"+t+"`, but received: "+E(r)}})}function F(){return B("never",(function(){return!1}))}function q(e){return new I(Object(c.a)(Object(c.a)({},e),{},{validator:function(t,r){return null===t||e.validator(t,r)},refiner:function(t,r){return null===t||e.refiner(t,r)}}))}function H(){return B("number",(function(e){return"number"===typeof e&&!isNaN(e)||"Expected a number, but received: "+E(e)}))}function W(e){return new I(Object(c.a)(Object(c.a)({},e),{},{validator:function(t,r){return void 0===t||e.validator(t,r)},refiner:function(t,r){return void 0===t||e.refiner(t,r)}}))}function K(e,t){return new I({type:"record",schema:null,entries:g.a.mark((function r(n){var i,o;return g.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!S(n)){r.next=11;break}r.t0=g.a.keys(n);case 2:if((r.t1=r.t0()).done){r.next=11;break}return i=r.t1.value,o=n[i],r.next=7,[i,i,e];case 7:return r.next=9,[i,o,t];case 9:r.next=2;break;case 11:case"end":return r.stop()}}),r)})),validator:function(e){return S(e)||"Expected an object, but received: "+E(e)}})}function V(){return B("string",(function(e){return"string"===typeof e||"Expected a string, but received: "+E(e)}))}function Z(e){var t=F();return new I({type:"tuple",schema:null,entries:g.a.mark((function r(n){var i,o;return g.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!Array.isArray(n)){r.next=9;break}i=Math.max(e.length,n.length),o=0;case 3:if(!(o<i)){r.next=9;break}return r.next=6,[o,n[o],e[o]||t];case 6:o++,r.next=3;break;case 9:case"end":return r.stop()}}),r)})),validator:function(e){return Array.isArray(e)||"Expected an array, but received: "+E(e)}})}function Y(e){var t=Object.keys(e);return new I({type:"type",schema:e,entries:g.a.mark((function r(n){var i,o,a;return g.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!S(n)){r.next=18;break}i=Object(s.a)(t),r.prev=2,i.s();case 4:if((o=i.n()).done){r.next=10;break}return a=o.value,r.next=8,[a,n[a],e[a]];case 8:r.next=4;break;case 10:r.next=15;break;case 12:r.prev=12,r.t0=r.catch(2),i.e(r.t0);case 15:return r.prev=15,i.f(),r.finish(15);case 18:case"end":return r.stop()}}),r,null,[[2,12,15,18]])})),validator:function(e){return S(e)||"Expected an object, but received: "+E(e)}})}function X(e){var t=e.map((function(e){return e.type})).join(" | ");return new I({type:"union",schema:null,validator:function(r,c){var f,l,h=[],d=Object(s.a)(e);try{for(d.s();!(f=d.n()).done;){var p=j(r,f.value,c),b=(l=p,Object(n.a)(l)||Object(i.a)(l)||Object(o.a)(l)||Object(a.a)()).slice(0);if(!Object(u.a)(b,1)[0][0])return[];var v,y=Object(s.a)(b);try{for(y.s();!(v=y.n()).done;){var m=Object(u.a)(v.value,1)[0];m&&h.push(m)}}catch(g){y.e(g)}finally{y.f()}}}catch(g){d.e(g)}finally{d.f()}return["Expected the value to satisfy a union of `"+t+"`, but received: "+E(r)].concat(h)}})}function G(){return B("unknown",(function(){return!0}))}function J(e,t,r){return new I(Object(c.a)(Object(c.a)({},e),{},{coercer:function(n,i){return C(n,t)?e.coercer(r(n,i),i):e.coercer(n,i)}}))}},function(e,t,r){e.exports=r(106)},function(e,t,r){"use strict";var n=this&&this.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},e(t,r)};return function(t,r){if("function"!==typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}();t.__esModule=!0,t.s16=t.s8=t.nu64be=t.u48be=t.u40be=t.u32be=t.u24be=t.u16be=t.nu64=t.u48=t.u40=t.u32=t.u24=t.u16=t.u8=t.offset=t.greedy=t.Constant=t.UTF8=t.CString=t.Blob=t.Boolean=t.BitField=t.BitStructure=t.VariantLayout=t.Union=t.UnionLayoutDiscriminator=t.UnionDiscriminator=t.Structure=t.Sequence=t.DoubleBE=t.Double=t.FloatBE=t.Float=t.NearInt64BE=t.NearInt64=t.NearUInt64BE=t.NearUInt64=t.IntBE=t.Int=t.UIntBE=t.UInt=t.OffsetLayout=t.GreedyCount=t.ExternalLayout=t.bindConstructorLayout=t.nameWithProperty=t.Layout=t.uint8ArrayToBuffer=t.checkUint8Array=void 0,t.constant=t.utf8=t.cstr=t.blob=t.unionLayoutDiscriminator=t.union=t.seq=t.bits=t.struct=t.f64be=t.f64=t.f32be=t.f32=t.ns64be=t.s48be=t.s40be=t.s32be=t.s24be=t.s16be=t.ns64=t.s48=t.s40=t.s32=t.s24=void 0;var i=r(6);function o(e){if(!(e instanceof Uint8Array))throw new TypeError("b must be a Uint8Array")}function a(e){return o(e),i.Buffer.from(e.buffer,e.byteOffset,e.length)}t.checkUint8Array=o,t.uint8ArrayToBuffer=a;var u=function(){function e(e,t){if(!Number.isInteger(e))throw new TypeError("span must be an integer");this.span=e,this.property=t}return e.prototype.makeDestinationObject=function(){return{}},e.prototype.decode=function(e,t){throw new Error("Layout is abstract")},e.prototype.encode=function(e,t,r){throw new Error("Layout is abstract")},e.prototype.getSpan=function(e,t){if(0>this.span)throw new RangeError("indeterminate span");return this.span},e.prototype.replicate=function(e){var t=Object.create(this.constructor.prototype);return Object.assign(t,this),t.property=e,t},e.prototype.fromArray=function(e){},e}();function s(e,t){return t.property?e+"["+t.property+"]":e}t.Layout=u,t.nameWithProperty=s,t.bindConstructorLayout=function(e,t){if("function"!==typeof e)throw new TypeError("Class must be constructor");if(Object.prototype.hasOwnProperty.call(e,"layout_"))throw new Error("Class is already bound to a layout");if(!(t&&t instanceof u))throw new TypeError("layout must be a Layout");if(Object.prototype.hasOwnProperty.call(t,"boundConstructor_"))throw new Error("layout is already bound to a constructor");e.layout_=t,t.boundConstructor_=e,t.makeDestinationObject=function(){return new e},Object.defineProperty(e.prototype,"encode",{value:function(e,r){return t.encode(this,e,r)},writable:!0}),Object.defineProperty(e,"decode",{value:function(e,r){return t.decode(e,r)},writable:!0})};var c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n(t,e),t.prototype.isCount=function(){throw new Error("ExternalLayout is abstract")},t}(u);t.ExternalLayout=c;var f=function(e){function t(t,r){var n=this;if(void 0===t&&(t=1),!Number.isInteger(t)||0>=t)throw new TypeError("elementSpan must be a (positive) integer");return(n=e.call(this,-1,r)||this).elementSpan=t,n}return n(t,e),t.prototype.isCount=function(){return!0},t.prototype.decode=function(e,t){o(e),void 0===t&&(t=0);var r=e.length-t;return Math.floor(r/this.elementSpan)},t.prototype.encode=function(e,t,r){return 0},t}(c);t.GreedyCount=f;var l=function(e){function t(t,r,n){var i=this;if(!(t instanceof u))throw new TypeError("layout must be a Layout");if(void 0===r)r=0;else if(!Number.isInteger(r))throw new TypeError("offset must be integer or undefined");return(i=e.call(this,t.span,n||t.property)||this).layout=t,i.offset=r,i}return n(t,e),t.prototype.isCount=function(){return this.layout instanceof h||this.layout instanceof d},t.prototype.decode=function(e,t){return void 0===t&&(t=0),this.layout.decode(e,t+this.offset)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),this.layout.encode(e,t,r+this.offset)},t}(c);t.OffsetLayout=l;var h=function(e){function t(t,r){var n=e.call(this,t,r)||this;if(6<n.span)throw new RangeError("span must not exceed 6 bytes");return n}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readUIntLE(t,this.span)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeUIntLE(e,r,this.span),this.span},t}(u);t.UInt=h;var d=function(e){function t(t,r){var n=e.call(this,t,r)||this;if(6<n.span)throw new RangeError("span must not exceed 6 bytes");return n}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readUIntBE(t,this.span)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeUIntBE(e,r,this.span),this.span},t}(u);t.UIntBE=d;var p=function(e){function t(t,r){var n=e.call(this,t,r)||this;if(6<n.span)throw new RangeError("span must not exceed 6 bytes");return n}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readIntLE(t,this.span)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeIntLE(e,r,this.span),this.span},t}(u);t.Int=p;var b=function(e){function t(t,r){var n=e.call(this,t,r)||this;if(6<n.span)throw new RangeError("span must not exceed 6 bytes");return n}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readIntBE(t,this.span)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeIntBE(e,r,this.span),this.span},t}(u);t.IntBE=b;var v=Math.pow(2,32);function y(e){var t=Math.floor(e/v);return{hi32:t,lo32:e-t*v}}function m(e,t){return e*v+t}var g=function(e){function t(t){return e.call(this,8,t)||this}return n(t,e),t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=a(e),n=r.readUInt32LE(t);return m(r.readUInt32LE(t+4),n)},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=y(e),i=a(t);return i.writeUInt32LE(n.lo32,r),i.writeUInt32LE(n.hi32,r+4),8},t}(u);t.NearUInt64=g;var w=function(e){function t(t){return e.call(this,8,t)||this}return n(t,e),t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=a(e);return m(r.readUInt32BE(t),r.readUInt32BE(t+4))},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=y(e),i=a(t);return i.writeUInt32BE(n.hi32,r),i.writeUInt32BE(n.lo32,r+4),8},t}(u);t.NearUInt64BE=w;var k=function(e){function t(t){return e.call(this,8,t)||this}return n(t,e),t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=a(e),n=r.readUInt32LE(t);return m(r.readInt32LE(t+4),n)},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=y(e),i=a(t);return i.writeUInt32LE(n.lo32,r),i.writeInt32LE(n.hi32,r+4),8},t}(u);t.NearInt64=k;var _=function(e){function t(t){return e.call(this,8,t)||this}return n(t,e),t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=a(e);return m(r.readInt32BE(t),r.readUInt32BE(t+4))},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=y(e),i=a(t);return i.writeInt32BE(n.hi32,r),i.writeUInt32BE(n.lo32,r+4),8},t}(u);t.NearInt64BE=_;var x=function(e){function t(t){return e.call(this,4,t)||this}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readFloatLE(t)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeFloatLE(e,r),4},t}(u);t.Float=x;var S=function(e){function t(t){return e.call(this,4,t)||this}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readFloatBE(t)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeFloatBE(e,r),4},t}(u);t.FloatBE=S;var E=function(e){function t(t){return e.call(this,8,t)||this}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readDoubleLE(t)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeDoubleLE(e,r),8},t}(u);t.Double=E;var O=function(e){function t(t){return e.call(this,8,t)||this}return n(t,e),t.prototype.decode=function(e,t){return void 0===t&&(t=0),a(e).readDoubleBE(t)},t.prototype.encode=function(e,t,r){return void 0===r&&(r=0),a(t).writeDoubleBE(e,r),8},t}(u);t.DoubleBE=O;var A=function(e){function t(t,r,n){var i=this;if(!(t instanceof u))throw new TypeError("elementLayout must be a Layout");if(!(r instanceof c&&r.isCount()||Number.isInteger(r)&&0<=r))throw new TypeError("count must be non-negative integer or an unsigned integer ExternalLayout");var o=-1;return!(r instanceof c)&&0<t.span&&(o=r*t.span),(i=e.call(this,o,n)||this).elementLayout=t,i.count=r,i}return n(t,e),t.prototype.getSpan=function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=0,n=this.count;if(n instanceof c&&(n=n.decode(e,t)),0<this.elementLayout.span)r=n*this.elementLayout.span;else for(var i=0;i<n;)r+=this.elementLayout.getSpan(e,t+r),++i;return r},t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=[],n=0,i=this.count;for(i instanceof c&&(i=i.decode(e,t));n<i;)r.push(this.elementLayout.decode(e,t)),t+=this.elementLayout.getSpan(e,t),n+=1;return r},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=this.elementLayout,i=e.reduce((function(e,i){return e+n.encode(i,t,r+e)}),0);return this.count instanceof c&&this.count.encode(e.length,t,r),i},t}(u);t.Sequence=A;var M=function(e){function t(t,r,n){var i=this;if(!Array.isArray(t)||!t.reduce((function(e,t){return e&&t instanceof u}),!0))throw new TypeError("fields must be array of Layout instances");"boolean"===typeof r&&void 0===n&&(n=r,r=void 0);for(var o=0,a=t;o<a.length;o++){var s=a[o];if(0>s.span&&void 0===s.property)throw new Error("fields cannot contain unnamed variable-length layout")}var c=-1;try{c=t.reduce((function(e,t){return e+t.getSpan()}),0)}catch(f){}return(i=e.call(this,c,r)||this).fields=t,i.decodePrefixes=!!n,i}return n(t,e),t.prototype.getSpan=function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=0;try{r=this.fields.reduce((function(r,n){var i=n.getSpan(e,t);return t+=i,r+i}),0)}catch(n){throw new RangeError("indeterminate span")}return r},t.prototype.decode=function(e,t){o(e),void 0===t&&(t=0);for(var r=this.makeDestinationObject(),n=0,i=this.fields;n<i.length;n++){var a=i[n];if(void 0!==a.property&&(r[a.property]=a.decode(e,t)),t+=a.getSpan(e,t),this.decodePrefixes&&e.length===t)break}return r},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);for(var n=r,i=0,o=0,a=0,u=this.fields;a<u.length;a++){var s=u[a],c=s.span;if(o=0<c?c:0,void 0!==s.property){var f=e[s.property];void 0!==f&&(o=s.encode(f,t,r),0>c&&(c=s.getSpan(t,r)))}i=r,r+=c}return i+o-n},t.prototype.fromArray=function(e){for(var t=this.makeDestinationObject(),r=0,n=this.fields;r<n.length;r++){var i=n[r];void 0!==i.property&&0<e.length&&(t[i.property]=e.shift())}return t},t.prototype.layoutFor=function(e){if("string"!==typeof e)throw new TypeError("property must be string");for(var t=0,r=this.fields;t<r.length;t++){var n=r[t];if(n.property===e)return n}},t.prototype.offsetOf=function(e){if("string"!==typeof e)throw new TypeError("property must be string");for(var t=0,r=0,n=this.fields;r<n.length;r++){var i=n[r];if(i.property===e)return t;0>i.span?t=-1:0<=t&&(t+=i.span)}},t}(u);t.Structure=M;var j=function(){function e(e){this.property=e}return e.prototype.decode=function(e,t){throw new Error("UnionDiscriminator is abstract")},e.prototype.encode=function(e,t,r){throw new Error("UnionDiscriminator is abstract")},e}();t.UnionDiscriminator=j;var I=function(e){function t(t,r){var n=this;if(!(t instanceof c&&t.isCount()))throw new TypeError("layout must be an unsigned integer ExternalLayout");return(n=e.call(this,r||t.property||"variant")||this).layout=t,n}return n(t,e),t.prototype.decode=function(e,t){return this.layout.decode(e,t)},t.prototype.encode=function(e,t,r){return this.layout.encode(e,t,r)},t}(j);t.UnionLayoutDiscriminator=I;var P=function(e){function t(t,r,n){var i,o=this,a=t instanceof h||t instanceof d;if(a)i=new I(new l(t));else if(t instanceof c&&t.isCount())i=new I(t);else{if(!(t instanceof j))throw new TypeError("discr must be a UnionDiscriminator or an unsigned integer layout");i=t}if(void 0===r&&(r=null),!(null===r||r instanceof u))throw new TypeError("defaultLayout must be null or a Layout");if(null!==r){if(0>r.span)throw new Error("defaultLayout must have constant span");void 0===r.property&&(r=r.replicate("content"))}var s=-1;r&&0<=(s=r.span)&&a&&(s+=i.layout.span),(o=e.call(this,s,n)||this).discriminator=i,o.usesPrefixDiscriminator=a,o.defaultLayout=r,o.registry={};var f=o.defaultGetSourceVariant.bind(o);return o.getSourceVariant=function(e){return f(e)},o.configGetSourceVariant=function(e){f=e.bind(this)},o}return n(t,e),t.prototype.getSpan=function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=this.getVariant(e,t);if(!r)throw new Error("unable to determine span for unrecognized variant");return r.getSpan(e,t)},t.prototype.defaultGetSourceVariant=function(e){if(Object.prototype.hasOwnProperty.call(e,this.discriminator.property)){if(this.defaultLayout&&this.defaultLayout.property&&Object.prototype.hasOwnProperty.call(e,this.defaultLayout.property))return;if((r=this.registry[e[this.discriminator.property]])&&(!r.layout||r.property&&Object.prototype.hasOwnProperty.call(e,r.property)))return r}else for(var t in this.registry){var r;if((r=this.registry[t]).property&&Object.prototype.hasOwnProperty.call(e,r.property))return r}throw new Error("unable to infer src variant")},t.prototype.decode=function(e,t){var r;void 0===t&&(t=0);var n=this.discriminator,i=n.decode(e,t),o=this.registry[i];if(void 0===o){var a=this.defaultLayout,u=0;this.usesPrefixDiscriminator&&(u=n.layout.span),(r=this.makeDestinationObject())[n.property]=i,r[a.property]=a.decode(e,t+u)}else r=o.decode(e,t);return r},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=this.getSourceVariant(e);if(void 0===n){var i=this.discriminator,o=this.defaultLayout,a=0;return this.usesPrefixDiscriminator&&(a=i.layout.span),i.encode(e[i.property],t,r),a+o.encode(e[o.property],t,r+a)}return n.encode(e,t,r)},t.prototype.addVariant=function(e,t,r){var n=new R(this,e,t,r);return this.registry[e]=n,n},t.prototype.getVariant=function(e,t){var r;return e instanceof Uint8Array?(void 0===t&&(t=0),r=this.discriminator.decode(e,t)):r=e,this.registry[r]},t}(u);t.Union=P;var R=function(e){function t(t,r,n,i){var o=this;if(!(t instanceof P))throw new TypeError("union must be a Union");if(!Number.isInteger(r)||0>r)throw new TypeError("variant must be a (non-negative) integer");if("string"===typeof n&&void 0===i&&(i=n,n=null),n){if(!(n instanceof u))throw new TypeError("layout must be a Layout");if(null!==t.defaultLayout&&0<=n.span&&n.span>t.defaultLayout.span)throw new Error("variant span exceeds span of containing union");if("string"!==typeof i)throw new TypeError("variant must have a String property")}var a=t.span;return 0>t.span&&0<=(a=n?n.span:0)&&t.usesPrefixDiscriminator&&(a+=t.discriminator.layout.span),(o=e.call(this,a,i)||this).union=t,o.variant=r,o.layout=n||null,o}return n(t,e),t.prototype.getSpan=function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=0;this.union.usesPrefixDiscriminator&&(r=this.union.discriminator.layout.span);var n=0;return this.layout&&(n=this.layout.getSpan(e,t+r)),r+n},t.prototype.decode=function(e,t){var r=this.makeDestinationObject();if(void 0===t&&(t=0),this!==this.union.getVariant(e,t))throw new Error("variant mismatch");var n=0;this.union.usesPrefixDiscriminator&&(n=this.union.discriminator.layout.span);var i=this.property;return this.layout?r[i]=this.layout.decode(e,t+n):i?r[i]=!0:this.union.usesPrefixDiscriminator&&(r[this.union.discriminator.property]=this.variant),r},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=0;this.union.usesPrefixDiscriminator&&(n=this.union.discriminator.layout.span);var i=this.property;if(this.layout&&!Object.prototype.hasOwnProperty.call(e,i))throw new TypeError("variant lacks property "+i);this.union.discriminator.encode(this.variant,t,r);var o=n;if(this.layout&&(this.layout.encode(e[i],t,r+n),o+=this.layout.getSpan(t,r+n),0<=this.union.span&&o>this.union.span))throw new Error("encoded variant overruns containing union");return o},t.prototype.fromArray=function(e){if(this.layout)return this.layout.fromArray(e)},t}(u);function C(e){return 0>e&&(e+=4294967296),e}t.VariantLayout=R;var T=function(e){function t(t,r,n){var i=this;if(!(t instanceof h||t instanceof d))throw new TypeError("word must be a UInt or UIntBE layout");if("string"===typeof r&&void 0===n&&(n=r,r=!1),4<t.span)throw new RangeError("word cannot exceed 32 bits");(i=e.call(this,t.span,n)||this).word=t,i.msb=!!r,i.fields=[];var o=0;return i._packedSetValue=function(e){return o=C(e),this},i._packedGetValue=function(){return o},i}return n(t,e),t.prototype.decode=function(e,t){var r=this.makeDestinationObject();void 0===t&&(t=0);var n=this.word.decode(e,t);this._packedSetValue(n);for(var i=0,o=this.fields;i<o.length;i++){var a=o[i];void 0!==a.property&&(r[a.property]=a.decode(n))}return r},t.prototype.encode=function(e,t,r){void 0===r&&(r=0);var n=this.word.decode(t,r);this._packedSetValue(n);for(var i=0,o=this.fields;i<o.length;i++){var a=o[i];if(void 0!==a.property){var u=e[a.property];void 0!==u&&a.encode(u)}}return this.word.encode(this._packedGetValue(),t,r)},t.prototype.addField=function(e,t){var r=new B(this,e,t);return this.fields.push(r),r},t.prototype.addBoolean=function(e){var t=new L(this,e);return this.fields.push(t),t},t.prototype.fieldFor=function(e){if("string"!==typeof e)throw new TypeError("property must be string");for(var t=0,r=this.fields;t<r.length;t++){var n=r[t];if(n.property===e)return n}},t}(u);t.BitStructure=T;var B=function(){function e(e,t,r){if(!(e instanceof T))throw new TypeError("container must be a BitStructure");if(!Number.isInteger(t)||0>=t)throw new TypeError("bits must be positive integer");var n=8*e.span,i=e.fields.reduce((function(e,t){return e+t.bits}),0);if(t+i>n)throw new Error("bits too long for span remainder ("+(n-i)+" of "+n+" remain)");this.container=e,this.bits=t,this.valueMask=(1<<t)-1,32===t&&(this.valueMask=4294967295),this.start=i,this.container.msb&&(this.start=n-i-t),this.wordMask=C(this.valueMask<<this.start),this.property=r}return e.prototype.decode=function(e,t){return C(this.container._packedGetValue()&this.wordMask)>>>this.start},e.prototype.encode=function(e){if(!Number.isInteger(e)||e!==C(e&this.valueMask))throw new TypeError(s("BitField.encode",this)+" value must be integer not exceeding "+this.valueMask);var t=this.container._packedGetValue(),r=C(e<<this.start);this.container._packedSetValue(C(t&~this.wordMask)|r)},e}();t.BitField=B;var L=function(e){function t(t,r){return e.call(this,t,1,r)||this}return n(t,e),t.prototype.decode=function(e,t){return!!B.prototype.decode.call(this,e,t)},t.prototype.encode=function(e){return"boolean"===typeof e&&(e=+e),B.prototype.encode.call(this,e)},t}(B);t.Boolean=L;var z=function(e){function t(t,r){var n=this;if(!(t instanceof c&&t.isCount()||Number.isInteger(t)&&0<=t))throw new TypeError("length must be positive integer or an unsigned integer ExternalLayout");var i=-1;return t instanceof c||(i=t),(n=e.call(this,i,r)||this).length=t,n}return n(t,e),t.prototype.getSpan=function(e,t){var r=this.span;return 0>r&&(r=this.length.decode(e,t)),r},t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=this.span;return 0>r&&(r=this.length.decode(e,t)),a(e).slice(t,t+r)},t.prototype.encode=function(e,t,r){var n=this.length;if(this.length instanceof c&&(n=e.length),!(e instanceof Uint8Array&&n===e.length))throw new TypeError(s("Blob.encode",this)+" requires (length "+n+") Uint8Array as src");if(r+n>t.length)throw new RangeError("encoding overruns Uint8Array");var i=a(e);return a(t).write(i.toString("hex"),r,n,"hex"),this.length instanceof c&&this.length.encode(n,t,r),n},t}(u);t.Blob=z;var U=function(e){function t(t){return e.call(this,-1,t)||this}return n(t,e),t.prototype.getSpan=function(e,t){o(e),void 0===t&&(t=0);for(var r=t;r<e.length&&0!==e[r];)r+=1;return 1+r-t},t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=this.getSpan(e,t);return a(e).slice(t,t+r-1).toString("utf-8")},t.prototype.encode=function(e,t,r){void 0===r&&(r=0),"string"!==typeof e&&(e=e.toString());var n=i.Buffer.from(e,"utf8"),o=n.length;if(r+o>t.length)throw new RangeError("encoding overruns Buffer");var u=a(t);return n.copy(u,r),u[r+o]=0,o+1},t}(u);t.CString=U;var N=function(e){function t(t,r){var n=this;if("string"===typeof t&&void 0===r&&(r=t,t=void 0),void 0===t)t=-1;else if(!Number.isInteger(t))throw new TypeError("maxSpan must be an integer");return(n=e.call(this,-1,r)||this).maxSpan=t,n}return n(t,e),t.prototype.getSpan=function(e,t){return o(e),void 0===t&&(t=0),e.length-t},t.prototype.decode=function(e,t){void 0===t&&(t=0);var r=this.getSpan(e,t);if(0<=this.maxSpan&&this.maxSpan<r)throw new RangeError("text length exceeds maxSpan");return a(e).slice(t,t+r).toString("utf-8")},t.prototype.encode=function(e,t,r){void 0===r&&(r=0),"string"!==typeof e&&(e=e.toString());var n=i.Buffer.from(e,"utf8"),o=n.length;if(0<=this.maxSpan&&this.maxSpan<o)throw new RangeError("text length exceeds maxSpan");if(r+o>t.length)throw new RangeError("encoding overruns Buffer");return n.copy(a(t),r),o},t}(u);t.UTF8=N;var D=function(e){function t(t,r){var n=e.call(this,0,r)||this;return n.value=t,n}return n(t,e),t.prototype.decode=function(e,t){return this.value},t.prototype.encode=function(e,t,r){return 0},t}(u);t.Constant=D,t.greedy=function(e,t){return new f(e,t)},t.offset=function(e,t,r){return new l(e,t,r)},t.u8=function(e){return new h(1,e)},t.u16=function(e){return new h(2,e)},t.u24=function(e){return new h(3,e)},t.u32=function(e){return new h(4,e)},t.u40=function(e){return new h(5,e)},t.u48=function(e){return new h(6,e)},t.nu64=function(e){return new g(e)},t.u16be=function(e){return new d(2,e)},t.u24be=function(e){return new d(3,e)},t.u32be=function(e){return new d(4,e)},t.u40be=function(e){return new d(5,e)},t.u48be=function(e){return new d(6,e)},t.nu64be=function(e){return new w(e)},t.s8=function(e){return new p(1,e)},t.s16=function(e){return new p(2,e)},t.s24=function(e){return new p(3,e)},t.s32=function(e){return new p(4,e)},t.s40=function(e){return new p(5,e)},t.s48=function(e){return new p(6,e)},t.ns64=function(e){return new k(e)},t.s16be=function(e){return new b(2,e)},t.s24be=function(e){return new b(3,e)},t.s32be=function(e){return new b(4,e)},t.s40be=function(e){return new b(5,e)},t.s48be=function(e){return new b(6,e)},t.ns64be=function(e){return new _(e)},t.f32=function(e){return new x(e)},t.f32be=function(e){return new S(e)},t.f64=function(e){return new E(e)},t.f64be=function(e){return new O(e)},t.struct=function(e,t,r){return new M(e,t,r)},t.bits=function(e,t,r){return new T(e,t,r)},t.seq=function(e,t,r){return new A(e,t,r)},t.union=function(e,t,r){return new P(e,t,r)},t.unionLayoutDiscriminator=function(e,t){return new I(e,t)},t.blob=function(e,t){return new z(e,t)},t.cstr=function(e){return new U(e)},t.utf8=function(e,t){return new N(e,t)},t.constant=function(e,t){return new D(e,t)}},function(e,t,r){"use strict";function n(e,t,r,n,i,o,a){try{var u=e[o](a),s=u.value}catch(c){return void r(c)}u.done?t(s):Promise.resolve(s).then(n,i)}function i(e){return function(){var t=this,r=arguments;return new Promise((function(i,o){var a=e.apply(t,r);function u(e){n(a,i,o,u,s,"next",e)}function s(e){n(a,i,o,u,s,"throw",e)}u(void 0)}))}}r.d(t,"a",(function(){return i}))},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(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)}}function i(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}r.d(t,"a",(function(){return i}))},function(e,t,r){"use strict";(function(e){var n=r(33),i=r(109),o=r(110);function a(){return s.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function u(e,t){if(a()<t)throw new RangeError("Invalid typed array length");return s.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=s.prototype:(null===e&&(e=new s(t)),e.length=t),e}function s(e,t,r){if(!s.TYPED_ARRAY_SUPPORT&&!(this instanceof s))return new s(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 l(this,e)}return c(this,e,t,r)}function c(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?function(e,t,r,n){if(t.byteLength,r<0||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");t=void 0===r&&void 0===n?new Uint8Array(t):void 0===n?new Uint8Array(t,r):new Uint8Array(t,r,n);s.TYPED_ARRAY_SUPPORT?(e=t).__proto__=s.prototype:e=h(e,t);return e}(e,t,r,n):"string"===typeof t?function(e,t,r){"string"===typeof r&&""!==r||(r="utf8");if(!s.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var n=0|p(t,r),i=(e=u(e,n)).write(t,r);i!==n&&(e=e.slice(0,i));return e}(e,t,r):function(e,t){if(s.isBuffer(t)){var r=0|d(t.length);return 0===(e=u(e,r)).length||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||(n=t.length)!==n?u(e,0):h(e,t);if("Buffer"===t.type&&o(t.data))return h(e,t.data)}var n;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function f(e){if("number"!==typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function l(e,t){if(f(t),e=u(e,t<0?0:0|d(t)),!s.TYPED_ARRAY_SUPPORT)for(var r=0;r<t;++r)e[r]=0;return e}function h(e,t){var r=t.length<0?0:0|d(t.length);e=u(e,r);for(var n=0;n<r;n+=1)e[n]=255&t[n];return e}function d(e){if(e>=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function p(e,t){if(s.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 F(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return q(e).length;default:if(n)return F(e).length;t=(""+t).toLowerCase(),n=!0}}function b(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return I(this,t,r);case"utf8":case"utf-8":return O(this,t,r);case"ascii":return M(this,t,r);case"latin1":case"binary":return j(this,t,r);case"base64":return E(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function v(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function y(e,t,r,n,i){if(0===e.length)return-1;if("string"===typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"===typeof t&&(t=s.from(t,n)),s.isBuffer(t))return 0===t.length?-1:m(e,t,r,n,i);if("number"===typeof t)return t&=255,s.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):m(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function m(e,t,r,n,i){var o,a=1,u=e.length,s=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a=2,u/=2,s/=2,r/=2}function c(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var f=-1;for(o=r;o<u;o++)if(c(e,o)===c(t,-1===f?0:o-f)){if(-1===f&&(f=o),o-f+1===s)return f*a}else-1!==f&&(o-=o-f),f=-1}else for(r+s>u&&(r=u-s),o=r;o>=0;o--){for(var l=!0,h=0;h<s;h++)if(c(e,o+h)!==c(t,h)){l=!1;break}if(l)return o}return-1}function g(e,t,r,n){r=Number(r)||0;var i=e.length-r;n?(n=Number(n))>i&&(n=i):n=i;var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var a=0;a<n;++a){var u=parseInt(t.substr(2*a,2),16);if(isNaN(u))return a;e[r+a]=u}return a}function w(e,t,r,n){return H(F(t,e.length-r),e,r,n)}function k(e,t,r,n){return H(function(e){for(var t=[],r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function _(e,t,r,n){return k(e,t,r,n)}function x(e,t,r,n){return H(q(t),e,r,n)}function S(e,t,r,n){return H(function(e,t){for(var r,n,i,o=[],a=0;a<e.length&&!((t-=2)<0);++a)n=(r=e.charCodeAt(a))>>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function E(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function O(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i<r;){var o,a,u,s,c=e[i],f=null,l=c>239?4:c>223?3:c>191?2:1;if(i+l<=r)switch(l){case 1:c<128&&(f=c);break;case 2:128===(192&(o=e[i+1]))&&(s=(31&c)<<6|63&o)>127&&(f=s);break;case 3:o=e[i+1],a=e[i+2],128===(192&o)&&128===(192&a)&&(s=(15&c)<<12|(63&o)<<6|63&a)>2047&&(s<55296||s>57343)&&(f=s);break;case 4:o=e[i+1],a=e[i+2],u=e[i+3],128===(192&o)&&128===(192&a)&&128===(192&u)&&(s=(15&c)<<18|(63&o)<<12|(63&a)<<6|63&u)>65535&&s<1114112&&(f=s)}null===f?(f=65533,l=1):f>65535&&(f-=65536,n.push(f>>>10&1023|55296),f=56320|1023&f),n.push(f),i+=l}return function(e){var t=e.length;if(t<=A)return String.fromCharCode.apply(String,e);var r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=A));return r}(n)}t.Buffer=s,t.SlowBuffer=function(e){+e!=e&&(e=0);return s.alloc(+e)},t.INSPECT_MAX_BYTES=50,s.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){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}}(),t.kMaxLength=a(),s.poolSize=8192,s._augment=function(e){return e.__proto__=s.prototype,e},s.from=function(e,t,r){return c(null,e,t,r)},s.TYPED_ARRAY_SUPPORT&&(s.prototype.__proto__=Uint8Array.prototype,s.__proto__=Uint8Array,"undefined"!==typeof Symbol&&Symbol.species&&s[Symbol.species]===s&&Object.defineProperty(s,Symbol.species,{value:null,configurable:!0})),s.alloc=function(e,t,r){return function(e,t,r,n){return f(t),t<=0?u(e,t):void 0!==r?"string"===typeof n?u(e,t).fill(r,n):u(e,t).fill(r):u(e,t)}(null,e,t,r)},s.allocUnsafe=function(e){return l(null,e)},s.allocUnsafeSlow=function(e){return l(null,e)},s.isBuffer=function(e){return!(null==e||!e._isBuffer)},s.compare=function(e,t){if(!s.isBuffer(e)||!s.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i<o;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0},s.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}},s.concat=function(e,t){if(!o(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return s.alloc(0);var r;if(void 0===t)for(t=0,r=0;r<e.length;++r)t+=e[r].length;var n=s.allocUnsafe(t),i=0;for(r=0;r<e.length;++r){var a=e[r];if(!s.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(n,i),i+=a.length}return n},s.byteLength=p,s.prototype._isBuffer=!0,s.prototype.swap16=function(){var e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)v(this,t,t+1);return this},s.prototype.swap32=function(){var e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)v(this,t,t+3),v(this,t+1,t+2);return this},s.prototype.swap64=function(){var e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)v(this,t,t+7),v(this,t+1,t+6),v(this,t+2,t+5),v(this,t+3,t+4);return this},s.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?O(this,0,e):b.apply(this,arguments)},s.prototype.equals=function(e){if(!s.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===s.compare(this,e)},s.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+">"},s.prototype.compare=function(e,t,r,n,i){if(!s.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===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0),u=Math.min(o,a),c=this.slice(n,i),f=e.slice(t,r),l=0;l<u;++l)if(c[l]!==f[l]){o=c[l],a=f[l];break}return o<a?-1:a<o?1:0},s.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},s.prototype.indexOf=function(e,t,r){return y(this,e,t,r,!0)},s.prototype.lastIndexOf=function(e,t,r){return y(this,e,t,r,!1)},s.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,isFinite(r)?(r|=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-t;if((void 0===r||r>i)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return g(this,e,t,r);case"utf8":case"utf-8":return w(this,e,t,r);case"ascii":return k(this,e,t,r);case"latin1":case"binary":return _(this,e,t,r);case"base64":return x(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return S(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},s.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var A=4096;function M(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(127&e[i]);return n}function j(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(e[i]);return n}function I(e,t,r){var n=e.length;(!t||t<0)&&(t=0),(!r||r<0||r>n)&&(r=n);for(var i="",o=t;o<r;++o)i+=D(e[o]);return i}function P(e,t,r){for(var n=e.slice(t,r),i="",o=0;o<n.length;o+=2)i+=String.fromCharCode(n[o]+256*n[o+1]);return i}function R(e,t,r){if(e%1!==0||e<0)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}function C(e,t,r,n,i,o){if(!s.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<o)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function T(e,t,r,n){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-r,2);i<o;++i)e[r+i]=(t&255<<8*(n?i:1-i))>>>8*(n?i:1-i)}function B(e,t,r,n){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-r,4);i<o;++i)e[r+i]=t>>>8*(n?i:3-i)&255}function L(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function z(e,t,r,n,o){return o||L(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function U(e,t,r,n,o){return o||L(e,0,r,8),i.write(e,t,r,n,52,8),r+8}s.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t<e&&(t=e),s.TYPED_ARRAY_SUPPORT)(r=this.subarray(e,t)).__proto__=s.prototype;else{var i=t-e;r=new s(i,void 0);for(var o=0;o<i;++o)r[o]=this[o+e]}return r},s.prototype.readUIntLE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=this[e],i=1,o=0;++o<t&&(i*=256);)n+=this[e+o]*i;return n},s.prototype.readUIntBE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=this[e+--t],i=1;t>0&&(i*=256);)n+=this[e+--t]*i;return n},s.prototype.readUInt8=function(e,t){return t||R(e,1,this.length),this[e]},s.prototype.readUInt16LE=function(e,t){return t||R(e,2,this.length),this[e]|this[e+1]<<8},s.prototype.readUInt16BE=function(e,t){return t||R(e,2,this.length),this[e]<<8|this[e+1]},s.prototype.readUInt32LE=function(e,t){return t||R(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},s.prototype.readUInt32BE=function(e,t){return t||R(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},s.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=this[e],i=1,o=0;++o<t&&(i*=256);)n+=this[e+o]*i;return n>=(i*=128)&&(n-=Math.pow(2,8*t)),n},s.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||R(e,t,this.length);for(var n=t,i=1,o=this[e+--n];n>0&&(i*=256);)o+=this[e+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},s.prototype.readInt8=function(e,t){return t||R(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},s.prototype.readInt16LE=function(e,t){t||R(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},s.prototype.readInt16BE=function(e,t){t||R(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},s.prototype.readInt32LE=function(e,t){return t||R(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},s.prototype.readInt32BE=function(e,t){return t||R(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},s.prototype.readFloatLE=function(e,t){return t||R(e,4,this.length),i.read(this,e,!0,23,4)},s.prototype.readFloatBE=function(e,t){return t||R(e,4,this.length),i.read(this,e,!1,23,4)},s.prototype.readDoubleLE=function(e,t){return t||R(e,8,this.length),i.read(this,e,!0,52,8)},s.prototype.readDoubleBE=function(e,t){return t||R(e,8,this.length),i.read(this,e,!1,52,8)},s.prototype.writeUIntLE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||C(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[t]=255&e;++o<r&&(i*=256);)this[t+o]=e/i&255;return t+r},s.prototype.writeUIntBE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||C(this,e,t,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[t+i]=255&e;--i>=0&&(o*=256);)this[t+i]=e/o&255;return t+r},s.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,255,0),s.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},s.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):T(this,e,t,!0),t+2},s.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,65535,0),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):T(this,e,t,!1),t+2},s.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):B(this,e,t,!0),t+4},s.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,4294967295,0),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):B(this,e,t,!1),t+4},s.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);C(this,e,t,r,i-1,-i)}var o=0,a=1,u=0;for(this[t]=255&e;++o<r&&(a*=256);)e<0&&0===u&&0!==this[t+o-1]&&(u=1),this[t+o]=(e/a>>0)-u&255;return t+r},s.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);C(this,e,t,r,i-1,-i)}var o=r-1,a=1,u=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===u&&0!==this[t+o+1]&&(u=1),this[t+o]=(e/a>>0)-u&255;return t+r},s.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,1,127,-128),s.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},s.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):T(this,e,t,!0),t+2},s.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,2,32767,-32768),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):T(this,e,t,!1),t+2},s.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),s.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):B(this,e,t,!0),t+4},s.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||C(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),s.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):B(this,e,t,!1),t+4},s.prototype.writeFloatLE=function(e,t,r){return z(this,e,t,!0,r)},s.prototype.writeFloatBE=function(e,t,r){return z(this,e,t,!1,r)},s.prototype.writeDoubleLE=function(e,t,r){return U(this,e,t,!0,r)},s.prototype.writeDoubleBE=function(e,t,r){return U(this,e,t,!1,r)},s.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&&n<r&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);var i,o=n-r;if(this===e&&r<t&&t<n)for(i=o-1;i>=0;--i)e[i+t]=this[i+r];else if(o<1e3||!s.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)e[i+t]=this[i+r];else Uint8Array.prototype.set.call(e,this.subarray(r,r+o),t);return o},s.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 i=e.charCodeAt(0);i<256&&(e=i)}if(void 0!==n&&"string"!==typeof n)throw new TypeError("encoding must be a string");if("string"===typeof n&&!s.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"===typeof e&&(e&=255);if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;var o;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"===typeof e)for(o=t;o<r;++o)this[o]=e;else{var a=s.isBuffer(e)?e:F(new s(e,n).toString()),u=a.length;for(o=0;o<r-t;++o)this[o+t]=a[o%u]}return this};var N=/[^+\/0-9A-Za-z-_]/g;function D(e){return e<16?"0"+e.toString(16):e.toString(16)}function F(e,t){var r;t=t||1/0;for(var n=e.length,i=null,o=[],a=0;a<n;++a){if((r=e.charCodeAt(a))>55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function q(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(N,"")).length<2)return"";for(;e.length%4!==0;)e+="=";return e}(e))}function H(e,t,r,n){for(var i=0;i<n&&!(i+r>=t.length||i>=e.length);++i)t[i+r]=e[i];return i}}).call(this,r(39))},function(e,t,r){"use strict";function n(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function o(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}r.d(t,"a",(function(){return o}))},function(e,t,r){"use strict";r.r(t),function(e){r.d(t,"Account",(function(){return ar})),r.d(t,"Authorized",(function(){return ki})),r.d(t,"BLOCKHASH_CACHE_TIMEOUT_MS",(function(){return Xr})),r.d(t,"BPF_LOADER_DEPRECATED_PROGRAM_ID",(function(){return ur})),r.d(t,"BPF_LOADER_PROGRAM_ID",(function(){return Ur})),r.d(t,"BpfLoader",(function(){return Nr})),r.d(t,"Connection",(function(){return vi})),r.d(t,"Ed25519Program",(function(){return gi})),r.d(t,"Enum",(function(){return Jt})),r.d(t,"EpochSchedule",(function(){return Hr})),r.d(t,"FeeCalculatorLayout",(function(){return jr})),r.d(t,"Keypair",(function(){return yi})),r.d(t,"LAMPORTS_PER_SOL",(function(){return Fi})),r.d(t,"Loader",(function(){return zr})),r.d(t,"Lockup",(function(){return _i})),r.d(t,"MAX_SEED_LENGTH",(function(){return Qt})),r.d(t,"Message",(function(){return hr})),r.d(t,"NONCE_ACCOUNT_LENGTH",(function(){return Pr})),r.d(t,"NonceAccount",(function(){return Rr})),r.d(t,"PACKET_DATA_SIZE",(function(){return br})),r.d(t,"PublicKey",(function(){return er})),r.d(t,"SOLANA_SCHEMA",(function(){return $t})),r.d(t,"STAKE_CONFIG_ID",(function(){return wi})),r.d(t,"STAKE_INSTRUCTION_LAYOUTS",(function(){return Si})),r.d(t,"SYSTEM_INSTRUCTION_LAYOUTS",(function(){return Tr})),r.d(t,"SYSVAR_CLOCK_PUBKEY",(function(){return mr})),r.d(t,"SYSVAR_INSTRUCTIONS_PUBKEY",(function(){return xr})),r.d(t,"SYSVAR_RECENT_BLOCKHASHES_PUBKEY",(function(){return gr})),r.d(t,"SYSVAR_RENT_PUBKEY",(function(){return wr})),r.d(t,"SYSVAR_REWARDS_PUBKEY",(function(){return kr})),r.d(t,"SYSVAR_STAKE_HISTORY_PUBKEY",(function(){return _r})),r.d(t,"Secp256k1Program",(function(){return Ii})),r.d(t,"SendTransactionError",(function(){return Wr})),r.d(t,"StakeAuthorizationLayout",(function(){return Ei})),r.d(t,"StakeInstruction",(function(){return xi})),r.d(t,"StakeProgram",(function(){return Oi})),r.d(t,"Struct",(function(){return Gt})),r.d(t,"SystemInstruction",(function(){return Cr})),r.d(t,"SystemProgram",(function(){return Br})),r.d(t,"Transaction",(function(){return yr})),r.d(t,"TransactionInstruction",(function(){return vr})),r.d(t,"VALIDATOR_INFO_KEY",(function(){return Pi})),r.d(t,"VOTE_PROGRAM_ID",(function(){return Ti})),r.d(t,"ValidatorInfo",(function(){return Ci})),r.d(t,"VoteAccount",(function(){return Li})),r.d(t,"clusterApiUrl",(function(){return Di})),r.d(t,"sendAndConfirmRawTransaction",(function(){return zi})),r.d(t,"sendAndConfirmTransaction",(function(){return Sr}));var n=r(37),i=r(10),o=r(9),a=r(7),u=r(12),s=r(3),c=r(29),f=r(30),l=r(4),h=r(5),d=r(1),p=r.n(d),b=r(20),v=r.n(b),y=r(6),m=r(23),g=r.n(m),w=r(13),k=r.n(w),_=r(67),x=r(2),S=r(0),E=r(96),O=r(97),A=r.n(O),M=r(76),j=r.n(M),I=r(77),P=r.n(I),R=function(e){return y.Buffer.isBuffer(e)?e:e instanceof Uint8Array?y.Buffer.from(e.buffer,e.byteOffset,e.byteLength):y.Buffer.from(e)},C="undefined"!==typeof globalThis?globalThis:"undefined"!==typeof window?window:"undefined"!==typeof e?e:"undefined"!==typeof self?self:{};function T(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var B={},L={},z=U;function U(e,t){if(!e)throw new Error(t||"Assertion failed")}U.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var N={exports:{}};"function"===typeof Object.create?N.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:N.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e};var D=z,F=N.exports;function q(e,t){return 55296===(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320===(64512&e.charCodeAt(t+1)))}function H(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function W(e){return 1===e.length?"0"+e:e}function K(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}L.inherits=F,L.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"===typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!==0&&(e="0"+e),i=0;i<e.length;i+=2)r.push(parseInt(e[i]+e[i+1],16))}else for(var n=0,i=0;i<e.length;i++){var o=e.charCodeAt(i);o<128?r[n++]=o:o<2048?(r[n++]=o>>6|192,r[n++]=63&o|128):q(e,i)?(o=65536+((1023&o)<<10)+(1023&e.charCodeAt(++i)),r[n++]=o>>18|240,r[n++]=o>>12&63|128,r[n++]=o>>6&63|128,r[n++]=63&o|128):(r[n++]=o>>12|224,r[n++]=o>>6&63|128,r[n++]=63&o|128)}else for(i=0;i<e.length;i++)r[i]=0|e[i];return r},L.toHex=function(e){for(var t="",r=0;r<e.length;r++)t+=W(e[r].toString(16));return t},L.htonl=H,L.toHex32=function(e,t){for(var r="",n=0;n<e.length;n++){var i=e[n];"little"===t&&(i=H(i)),r+=K(i.toString(16))}return r},L.zero2=W,L.zero8=K,L.join32=function(e,t,r,n){var i=r-t;D(i%4===0);for(var o=new Array(i/4),a=0,u=t;a<o.length;a++,u+=4){var s;s="big"===n?e[u]<<24|e[u+1]<<16|e[u+2]<<8|e[u+3]:e[u+3]<<24|e[u+2]<<16|e[u+1]<<8|e[u],o[a]=s>>>0}return o},L.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n<e.length;n++,i+=4){var o=e[n];"big"===t?(r[i]=o>>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},L.rotr32=function(e,t){return e>>>t|e<<32-t},L.rotl32=function(e,t){return e<<t|e>>>32-t},L.sum32=function(e,t){return e+t>>>0},L.sum32_3=function(e,t,r){return e+t+r>>>0},L.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},L.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},L.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o<n?1:0)+r+i;e[t]=a>>>0,e[t+1]=o},L.sum64_hi=function(e,t,r,n){return(t+n>>>0<t?1:0)+e+r>>>0},L.sum64_lo=function(e,t,r,n){return t+n>>>0},L.sum64_4_hi=function(e,t,r,n,i,o,a,u){var s=0,c=t;return s+=(c=c+n>>>0)<t?1:0,s+=(c=c+o>>>0)<o?1:0,e+r+i+a+(s+=(c=c+u>>>0)<u?1:0)>>>0},L.sum64_4_lo=function(e,t,r,n,i,o,a,u){return t+n+o+u>>>0},L.sum64_5_hi=function(e,t,r,n,i,o,a,u,s,c){var f=0,l=t;return f+=(l=l+n>>>0)<t?1:0,f+=(l=l+o>>>0)<o?1:0,f+=(l=l+u>>>0)<u?1:0,e+r+i+a+s+(f+=(l=l+c>>>0)<c?1:0)>>>0},L.sum64_5_lo=function(e,t,r,n,i,o,a,u,s,c){return t+n+o+u+c>>>0},L.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},L.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},L.shr64_hi=function(e,t,r){return e>>>r},L.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0};var V={},Z=L,Y=z;function X(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}V.BlockHash=X,X.prototype.update=function(e,t){if(e=Z.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=Z.join32(e,0,e.length-r,this.endian);for(var n=0;n<e.length;n+=this._delta32)this._update(e,n,n+this._delta32)}return this},X.prototype.digest=function(e){return this.update(this._pad()),Y(null===this.pending),this._digest(e)},X.prototype._pad=function(){var e=this.pendingTotal,t=this._delta8,r=t-(e+this.padLength)%t,n=new Array(r+this.padLength);n[0]=128;for(var i=1;i<r;i++)n[i]=0;if(e<<=3,"big"===this.endian){for(var o=8;o<this.padLength;o++)n[i++]=0;n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=e>>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o<this.padLength;o++)n[i++]=0;return n};var G={},J={},$=L.rotr32;function Q(e,t,r){return e&t^~e&r}function ee(e,t,r){return e&t^e&r^t&r}function te(e,t,r){return e^t^r}J.ft_1=function(e,t,r,n){return 0===e?Q(t,r,n):1===e||3===e?te(t,r,n):2===e?ee(t,r,n):void 0},J.ch32=Q,J.maj32=ee,J.p32=te,J.s0_256=function(e){return $(e,2)^$(e,13)^$(e,22)},J.s1_256=function(e){return $(e,6)^$(e,11)^$(e,25)},J.g0_256=function(e){return $(e,7)^$(e,18)^e>>>3},J.g1_256=function(e){return $(e,17)^$(e,19)^e>>>10};var re=L,ne=V,ie=J,oe=re.rotl32,ae=re.sum32,ue=re.sum32_5,se=ie.ft_1,ce=ne.BlockHash,fe=[1518500249,1859775393,2400959708,3395469782];function le(){if(!(this instanceof le))return new le;ce.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}re.inherits(le,ce);var he=le;le.blockSize=512,le.outSize=160,le.hmacStrength=80,le.padLength=64,le.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=oe(r[n-3]^r[n-8]^r[n-14]^r[n-16],1);var i=this.h[0],o=this.h[1],a=this.h[2],u=this.h[3],s=this.h[4];for(n=0;n<r.length;n++){var c=~~(n/20),f=ue(oe(i,5),se(c,o,a,u),s,r[n],fe[c]);s=u,u=a,a=oe(o,30),o=i,i=f}this.h[0]=ae(this.h[0],i),this.h[1]=ae(this.h[1],o),this.h[2]=ae(this.h[2],a),this.h[3]=ae(this.h[3],u),this.h[4]=ae(this.h[4],s)},le.prototype._digest=function(e){return"hex"===e?re.toHex32(this.h,"big"):re.split32(this.h,"big")};var de=L,pe=V,be=J,ve=z,ye=de.sum32,me=de.sum32_4,ge=de.sum32_5,we=be.ch32,ke=be.maj32,_e=be.s0_256,xe=be.s1_256,Se=be.g0_256,Ee=be.g1_256,Oe=pe.BlockHash,Ae=[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];function Me(){if(!(this instanceof Me))return new Me;Oe.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=Ae,this.W=new Array(64)}de.inherits(Me,Oe);var je=Me;Me.blockSize=512,Me.outSize=256,Me.hmacStrength=192,Me.padLength=64,Me.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=me(Ee(r[n-2]),r[n-7],Se(r[n-15]),r[n-16]);var i=this.h[0],o=this.h[1],a=this.h[2],u=this.h[3],s=this.h[4],c=this.h[5],f=this.h[6],l=this.h[7];for(ve(this.k.length===r.length),n=0;n<r.length;n++){var h=ge(l,xe(s),we(s,c,f),this.k[n],r[n]),d=ye(_e(i),ke(i,o,a));l=f,f=c,c=s,s=ye(u,h),u=a,a=o,o=i,i=ye(h,d)}this.h[0]=ye(this.h[0],i),this.h[1]=ye(this.h[1],o),this.h[2]=ye(this.h[2],a),this.h[3]=ye(this.h[3],u),this.h[4]=ye(this.h[4],s),this.h[5]=ye(this.h[5],c),this.h[6]=ye(this.h[6],f),this.h[7]=ye(this.h[7],l)},Me.prototype._digest=function(e){return"hex"===e?de.toHex32(this.h,"big"):de.split32(this.h,"big")};var Ie=L,Pe=je;function Re(){if(!(this instanceof Re))return new Re;Pe.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}Ie.inherits(Re,Pe);var Ce=Re;Re.blockSize=512,Re.outSize=224,Re.hmacStrength=192,Re.padLength=64,Re.prototype._digest=function(e){return"hex"===e?Ie.toHex32(this.h.slice(0,7),"big"):Ie.split32(this.h.slice(0,7),"big")};var Te=L,Be=V,Le=z,ze=Te.rotr64_hi,Ue=Te.rotr64_lo,Ne=Te.shr64_hi,De=Te.shr64_lo,Fe=Te.sum64,qe=Te.sum64_hi,He=Te.sum64_lo,We=Te.sum64_4_hi,Ke=Te.sum64_4_lo,Ve=Te.sum64_5_hi,Ze=Te.sum64_5_lo,Ye=Be.BlockHash,Xe=[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];function Ge(){if(!(this instanceof Ge))return new Ge;Ye.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=Xe,this.W=new Array(160)}Te.inherits(Ge,Ye);var Je=Ge;function $e(e,t,r,n,i){var o=e&r^~e&i;return o<0&&(o+=4294967296),o}function Qe(e,t,r,n,i,o){var a=t&n^~t&o;return a<0&&(a+=4294967296),a}function et(e,t,r,n,i){var o=e&r^e&i^r&i;return o<0&&(o+=4294967296),o}function tt(e,t,r,n,i,o){var a=t&n^t&o^n&o;return a<0&&(a+=4294967296),a}function rt(e,t){var r=ze(e,t,28)^ze(t,e,2)^ze(t,e,7);return r<0&&(r+=4294967296),r}function nt(e,t){var r=Ue(e,t,28)^Ue(t,e,2)^Ue(t,e,7);return r<0&&(r+=4294967296),r}function it(e,t){var r=ze(e,t,14)^ze(e,t,18)^ze(t,e,9);return r<0&&(r+=4294967296),r}function ot(e,t){var r=Ue(e,t,14)^Ue(e,t,18)^Ue(t,e,9);return r<0&&(r+=4294967296),r}function at(e,t){var r=ze(e,t,1)^ze(e,t,8)^Ne(e,t,7);return r<0&&(r+=4294967296),r}function ut(e,t){var r=Ue(e,t,1)^Ue(e,t,8)^De(e,t,7);return r<0&&(r+=4294967296),r}function st(e,t){var r=ze(e,t,19)^ze(t,e,29)^Ne(e,t,6);return r<0&&(r+=4294967296),r}function ct(e,t){var r=Ue(e,t,19)^Ue(t,e,29)^De(e,t,6);return r<0&&(r+=4294967296),r}Ge.blockSize=1024,Ge.outSize=512,Ge.hmacStrength=192,Ge.padLength=128,Ge.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n<r.length;n+=2){var i=st(r[n-4],r[n-3]),o=ct(r[n-4],r[n-3]),a=r[n-14],u=r[n-13],s=at(r[n-30],r[n-29]),c=ut(r[n-30],r[n-29]),f=r[n-32],l=r[n-31];r[n]=We(i,o,a,u,s,c,f,l),r[n+1]=Ke(i,o,a,u,s,c,f,l)}},Ge.prototype._update=function(e,t){this._prepareBlock(e,t);var r=this.W,n=this.h[0],i=this.h[1],o=this.h[2],a=this.h[3],u=this.h[4],s=this.h[5],c=this.h[6],f=this.h[7],l=this.h[8],h=this.h[9],d=this.h[10],p=this.h[11],b=this.h[12],v=this.h[13],y=this.h[14],m=this.h[15];Le(this.k.length===r.length);for(var g=0;g<r.length;g+=2){var w=y,k=m,_=it(l,h),x=ot(l,h),S=$e(l,h,d,p,b),E=Qe(l,h,d,p,b,v),O=this.k[g],A=this.k[g+1],M=r[g],j=r[g+1],I=Ve(w,k,_,x,S,E,O,A,M,j),P=Ze(w,k,_,x,S,E,O,A,M,j);w=rt(n,i),k=nt(n,i),_=et(n,i,o,a,u),x=tt(n,i,o,a,u,s);var R=qe(w,k,_,x),C=He(w,k,_,x);y=b,m=v,b=d,v=p,d=l,p=h,l=qe(c,f,I,P),h=He(f,f,I,P),c=u,f=s,u=o,s=a,o=n,a=i,n=qe(I,P,R,C),i=He(I,P,R,C)}Fe(this.h,0,n,i),Fe(this.h,2,o,a),Fe(this.h,4,u,s),Fe(this.h,6,c,f),Fe(this.h,8,l,h),Fe(this.h,10,d,p),Fe(this.h,12,b,v),Fe(this.h,14,y,m)},Ge.prototype._digest=function(e){return"hex"===e?Te.toHex32(this.h,"big"):Te.split32(this.h,"big")};var ft=L,lt=Je;function ht(){if(!(this instanceof ht))return new ht;lt.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}ft.inherits(ht,lt);var dt=ht;ht.blockSize=1024,ht.outSize=384,ht.hmacStrength=192,ht.padLength=128,ht.prototype._digest=function(e){return"hex"===e?ft.toHex32(this.h.slice(0,12),"big"):ft.split32(this.h.slice(0,12),"big")},G.sha1=he,G.sha224=Ce,G.sha256=je,G.sha384=dt,G.sha512=Je;var pt={},bt=L,vt=V,yt=bt.rotl32,mt=bt.sum32,gt=bt.sum32_3,wt=bt.sum32_4,kt=vt.BlockHash;function _t(){if(!(this instanceof _t))return new _t;kt.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function xt(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function St(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function Et(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}bt.inherits(_t,kt),pt.ripemd160=_t,_t.blockSize=512,_t.outSize=160,_t.hmacStrength=192,_t.padLength=64,_t.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],o=this.h[3],a=this.h[4],u=r,s=n,c=i,f=o,l=a,h=0;h<80;h++){var d=mt(yt(wt(r,xt(h,n,i,o),e[Ot[h]+t],St(h)),Mt[h]),a);r=a,a=o,o=yt(i,10),i=n,n=d,d=mt(yt(wt(u,xt(79-h,s,c,f),e[At[h]+t],Et(h)),jt[h]),l),u=l,l=f,f=yt(c,10),c=s,s=d}d=gt(this.h[1],i,f),this.h[1]=gt(this.h[2],o,l),this.h[2]=gt(this.h[3],a,u),this.h[3]=gt(this.h[4],r,s),this.h[4]=gt(this.h[0],n,c),this.h[0]=d},_t.prototype._digest=function(e){return"hex"===e?bt.toHex32(this.h,"little"):bt.split32(this.h,"little")};var Ot=[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],At=[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],Mt=[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],jt=[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],It=L,Pt=z;function Rt(e,t,r){if(!(this instanceof Rt))return new Rt(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(It.toArray(t,r))}var Ct=Rt;Rt.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),Pt(e.length<=this.blockSize);for(var t=e.length;t<this.blockSize;t++)e.push(0);for(t=0;t<e.length;t++)e[t]^=54;for(this.inner=(new this.Hash).update(e),t=0;t<e.length;t++)e[t]^=106;this.outer=(new this.Hash).update(e)},Rt.prototype.update=function(e,t){return this.inner.update(e,t),this},Rt.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)},function(e){var t=e;t.utils=L,t.common=V,t.sha=G,t.ripemd=pt,t.hmac=Ct,t.sha1=t.sha.sha1,t.sha256=t.sha.sha256,t.sha224=t.sha.sha224,t.sha384=t.sha.sha384,t.sha512=t.sha.sha512,t.ripemd160=t.ripemd.ripemd160}(B);var Tt=B,Bt=!1,Lt=!1,zt={debug:1,default:2,info:2,warning:3,error:4,off:5},Ut=zt.default,Nt=null;var Dt,Ft,qt=function(){try{var e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((function(t){try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(t){return t.message}return null}();!function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(Dt||(Dt={})),function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED"}(Ft||(Ft={}));var Ht="0123456789abcdef",Wt=function(){function e(t){Object(l.a)(this,e),Object.defineProperty(this,"version",{enumerable:!0,value:t,writable:!1})}return Object(h.a)(e,[{key:"_log",value:function(e,t){var r=e.toLowerCase();null==zt[r]&&this.throwArgumentError("invalid log level name","logLevel",e),Ut>zt[r]||console.log.apply(console,t)}},{key:"debug",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];this._log(e.levels.DEBUG,r)}},{key:"info",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];this._log(e.levels.INFO,r)}},{key:"warn",value:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];this._log(e.levels.WARNING,r)}},{key:"makeError",value:function(t,r,n){if(Lt)return this.makeError("censored error",r,{});r||(r=e.errors.UNKNOWN_ERROR),n||(n={});var i=[];Object.keys(n).forEach((function(e){var t=n[e];try{if(t instanceof Uint8Array){for(var r="",o=0;o<t.length;o++)r+=Ht[t[o]>>4],r+=Ht[15&t[o]];i.push(e+"=Uint8Array(0x"+r+")")}else i.push(e+"="+JSON.stringify(t))}catch(a){i.push(e+"="+JSON.stringify(n[e].toString()))}})),i.push("code=".concat(r)),i.push("version=".concat(this.version));var o=t;i.length&&(t+=" ("+i.join(", ")+")");var a=new Error(t);return a.reason=o,a.code=r,Object.keys(n).forEach((function(e){a[e]=n[e]})),a}},{key:"throwError",value:function(e,t,r){throw this.makeError(e,t,r)}},{key:"throwArgumentError",value:function(t,r,n){return this.throwError(t,e.errors.INVALID_ARGUMENT,{argument:r,value:n})}},{key:"assert",value:function(e,t,r,n){e||this.throwError(t,r,n)}},{key:"assertArgument",value:function(e,t,r,n){e||this.throwArgumentError(t,r,n)}},{key:"checkNormalize",value:function(t){qt&&this.throwError("platform missing String.prototype.normalize",e.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:qt})}},{key:"checkSafeUint53",value:function(t,r){"number"===typeof t&&(null==r&&(r="value not safe"),(t<0||t>=9007199254740991)&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(r,e.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}},{key:"checkArgumentCount",value:function(t,r,n){n=n?": "+n:"",t<r&&this.throwError("missing argument"+n,e.errors.MISSING_ARGUMENT,{count:t,expectedCount:r}),t>r&&this.throwError("too many arguments"+n,e.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:r})}},{key:"checkNew",value:function(t,r){t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}},{key:"checkAbstract",value:function(t,r){t===r?this.throwError("cannot instantiate abstract class "+JSON.stringify(r.name)+" directly; use a sub-class",e.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",e.errors.MISSING_NEW,{name:r.name})}}],[{key:"globalLogger",value:function(){return Nt||(Nt=new e("logger/5.5.0")),Nt}},{key:"setCensorship",value:function(t,r){if(!t&&r&&this.globalLogger().throwError("cannot permanently disable censorship",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),Bt){if(!t)return;this.globalLogger().throwError("error censorship permanent",e.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}Lt=!!t,Bt=!!r}},{key:"setLogLevel",value:function(t){var r=zt[t.toLowerCase()];null!=r?Ut=r:e.globalLogger().warn("invalid log level - "+t)}},{key:"from",value:function(t){return new e(t)}}]),e}();Wt.errors=Ft,Wt.levels=Dt;var Kt=new Wt("bytes/5.5.0");function Vt(e){return e.slice||(e.slice=function(){var t=Array.prototype.slice.call(arguments);return Vt(new Uint8Array(Array.prototype.slice.apply(e,t)))}),e}function Zt(e){return"number"===typeof e&&e==e&&e%1===0}function Yt(e,t){if(t||(t={}),"number"===typeof e){Kt.checkSafeUint53(e,"invalid arrayify value");for(var r=[];e;)r.unshift(255&e),e=parseInt(String(e/256));return 0===r.length&&r.push(0),Vt(new Uint8Array(r))}if(t.allowMissingPrefix&&"string"===typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),function(e){return!!e.toHexString}(e)&&(e=e.toHexString()),function(e,t){if("string"!==typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))return!1;if(t&&e.length!==2+2*t)return!1;return!0}(e)){var n=e.substring(2);n.length%2&&("left"===t.hexPad?n="0x0"+n.substring(2):"right"===t.hexPad?n+="0":Kt.throwArgumentError("hex data is odd-length","value",e));for(var i=[],o=0;o<n.length;o+=2)i.push(parseInt(n.substring(o,o+2),16));return Vt(new Uint8Array(i))}return function(e){if(null==e)return!1;if(e.constructor===Uint8Array)return!0;if("string"===typeof e)return!1;if(!Zt(e.length)||e.length<0)return!1;for(var t=0;t<e.length;t++){var r=e[t];if(!Zt(r)||r<0||r>=256)return!1}return!0}(e)?Vt(new Uint8Array(e)):Kt.throwArgumentError("invalid arrayify value","value",e)}function Xt(e){return"0x"+Tt.sha256().update(Yt(e)).digest("hex")}new Wt("sha2/5.5.0");var Gt=function(){function e(t){Object(l.a)(this,e),Object.assign(this,t)}return Object(h.a)(e,[{key:"encode",value:function(){return y.Buffer.from(Object(_.serialize)($t,this))}}],[{key:"decode",value:function(e){return Object(_.deserialize)($t,this,e)}},{key:"decodeUnchecked",value:function(e){return Object(_.deserializeUnchecked)($t,this,e)}}]),e}(),Jt=function(e){Object(c.a)(r,e);var t=Object(f.a)(r);function r(e){var n;if(Object(l.a)(this,r),(n=t.call(this,e)).enum="",1!==Object.keys(e).length)throw new Error("Enum can only take single value");return Object.keys(e).map((function(e){n.enum=e})),n}return Object(h.a)(r)}(Gt),$t=new Map,Qt=32;var er=function(e){Object(c.a)(r,e);var t=Object(f.a)(r);function r(e){var n;if(Object(l.a)(this,r),(n=t.call(this,{}))._bn=void 0,function(e){return void 0!==e._bn}(e))n._bn=e._bn;else{if("string"===typeof e){var i=k.a.decode(e);if(32!=i.length)throw new Error("Invalid public key input");n._bn=new g.a(i)}else n._bn=new g.a(e);if(n._bn.byteLength()>32)throw new Error("Invalid public key input")}return n}return Object(h.a)(r,[{key:"equals",value:function(e){return this._bn.eq(e._bn)}},{key:"toBase58",value:function(){return k.a.encode(this.toBytes())}},{key:"toBytes",value:function(){return this.toBuffer()}},{key:"toBuffer",value:function(){var e=this._bn.toArrayLike(y.Buffer);if(32===e.length)return e;var t=y.Buffer.alloc(32);return e.copy(t,32-e.length),t}},{key:"toString",value:function(){return this.toBase58()}}],[{key:"createWithSeed",value:function(){var e=Object(s.a)(p.a.mark((function e(t,n,i){var o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=y.Buffer.concat([t.toBuffer(),y.Buffer.from(n),i.toBuffer()]),a=Xt(new Uint8Array(o)).slice(2),e.abrupt("return",new r(y.Buffer.from(a,"hex")));case 3:case"end":return e.stop()}}),e)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"createProgramAddress",value:function(){var e=Object(s.a)(p.a.mark((function e(t,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(i=y.Buffer.alloc(0),t.forEach((function(e){if(e.length>Qt)throw new TypeError("Max seed length exceeded");i=y.Buffer.concat([i,R(e)])})),i=y.Buffer.concat([i,n.toBuffer(),y.Buffer.from("ProgramDerivedAddress")]),o=Xt(new Uint8Array(i)).slice(2),!rr(a=new g.a(o,16).toArray(void 0,32))){e.next=7;break}throw new Error("Invalid seeds, address must fall off the curve");case 7:return e.abrupt("return",new r(a));case 8:case"end":return e.stop()}}),e)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"findProgramAddress",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=255;case 1:if(0==n){e.next=18;break}return e.prev=2,o=t.concat(y.Buffer.from([n])),e.next=6,this.createProgramAddress(o,r);case 6:i=e.sent,e.next=15;break;case 9:if(e.prev=9,e.t0=e.catch(2),!(e.t0 instanceof TypeError)){e.next=13;break}throw e.t0;case 13:return n--,e.abrupt("continue",1);case 15:return e.abrupt("return",[i,n]);case 18:throw new Error("Unable to find a viable program address nonce");case 19:case"end":return e.stop()}}),e,this,[[2,9]])})));return function(t,r){return e.apply(this,arguments)}}()},{key:"isOnCurve",value:function(e){return 1==rr(e)}}]),r}(Gt);er.default=new er("11111111111111111111111111111111"),$t.set(er,{kind:"struct",fields:[["_bn","u256"]]});var tr=v.a.lowlevel;function rr(e){var t=[tr.gf(),tr.gf(),tr.gf(),tr.gf()],r=tr.gf(),n=tr.gf(),i=tr.gf(),o=tr.gf(),a=tr.gf(),u=tr.gf(),s=tr.gf();return tr.set25519(t[2],nr),tr.unpack25519(t[1],e),tr.S(i,t[1]),tr.M(o,i,tr.D),tr.Z(i,i,t[2]),tr.A(o,t[2],o),tr.S(a,o),tr.S(u,a),tr.M(s,u,a),tr.M(r,s,i),tr.M(r,r,o),tr.pow2523(r,r),tr.M(r,r,i),tr.M(r,r,o),tr.M(r,r,o),tr.M(t[0],r,o),tr.S(n,t[0]),tr.M(n,n,o),or(n,i)&&tr.M(t[0],t[0],ir),tr.S(n,t[0]),tr.M(n,n,o),or(n,i)?0:1}var nr=tr.gf([1]),ir=tr.gf([41136,18958,6951,50414,58488,44335,6150,12099,55207,15867,153,11085,57099,20417,9344,11139]);function or(e,t){var r=new Uint8Array(32),n=new Uint8Array(32);return tr.pack25519(r,e),tr.pack25519(n,t),tr.crypto_verify_32(r,0,n,0)}var ar=function(){function e(t){Object(l.a)(this,e),this._keypair=void 0,this._keypair=t?v.a.sign.keyPair.fromSecretKey(R(t)):v.a.sign.keyPair()}return Object(h.a)(e,[{key:"publicKey",get:function(){return new er(this._keypair.publicKey)}},{key:"secretKey",get:function(){return R(this._keypair.secretKey)}}]),e}(),ur=new er("BPFLoader1111111111111111111111111111111111"),sr=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"publicKey";return x.blob(32,e)},cr=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"string",t=x.struct([x.u32("length"),x.u32("lengthPadding"),x.blob(x.offset(x.u32(),-8),"chars")],e),r=t.decode.bind(t),n=t.encode.bind(t);return t.decode=function(e,t){return r(e,t).chars.toString("utf8")},t.encode=function(e,t,r){var i={chars:y.Buffer.from(e,"utf8")};return n(i,t,r)},t.alloc=function(e){return x.u32().span+x.u32().span+y.Buffer.from(e,"utf8").length},t};function fr(e){for(var t=0,r=0;;){var n=e.shift();if(t|=(127&n)<<7*r,r+=1,0===(128&n))break}return t}function lr(e,t){for(var r=t;;){var n=127&r;if(0==(r>>=7)){e.push(n);break}n|=128,e.push(n)}}var hr=function(){function e(t){var r=this;Object(l.a)(this,e),this.header=void 0,this.accountKeys=void 0,this.recentBlockhash=void 0,this.instructions=void 0,this.indexToProgramIds=new Map,this.header=t.header,this.accountKeys=t.accountKeys.map((function(e){return new er(e)})),this.recentBlockhash=t.recentBlockhash,this.instructions=t.instructions,this.instructions.forEach((function(e){return r.indexToProgramIds.set(e.programIdIndex,r.accountKeys[e.programIdIndex])}))}return Object(h.a)(e,[{key:"isAccountSigner",value:function(e){return e<this.header.numRequiredSignatures}},{key:"isAccountWritable",value:function(e){return e<this.header.numRequiredSignatures-this.header.numReadonlySignedAccounts||e>=this.header.numRequiredSignatures&&e<this.accountKeys.length-this.header.numReadonlyUnsignedAccounts}},{key:"isProgramId",value:function(e){return this.indexToProgramIds.has(e)}},{key:"programIds",value:function(){return Object(u.a)(this.indexToProgramIds.values())}},{key:"nonProgramIds",value:function(){var e=this;return this.accountKeys.filter((function(t,r){return!e.isProgramId(r)}))}},{key:"serialize",value:function(){var e=this.accountKeys.length,t=[];lr(t,e);var r=this.instructions.map((function(e){var t=e.accounts,r=e.programIdIndex,n=k.a.decode(e.data),i=[];lr(i,t.length);var o=[];return lr(o,n.length),{programIdIndex:r,keyIndicesCount:y.Buffer.from(i),keyIndices:y.Buffer.from(t),dataLength:y.Buffer.from(o),data:n}})),n=[];lr(n,r.length);var i=y.Buffer.alloc(br);y.Buffer.from(n).copy(i);var o=n.length;r.forEach((function(e){var t=x.struct([x.u8("programIdIndex"),x.blob(e.keyIndicesCount.length,"keyIndicesCount"),x.seq(x.u8("keyIndex"),e.keyIndices.length,"keyIndices"),x.blob(e.dataLength.length,"dataLength"),x.seq(x.u8("userdatum"),e.data.length,"data")]).encode(e,i,o);o+=t})),i=i.slice(0,o);var a=x.struct([x.blob(1,"numRequiredSignatures"),x.blob(1,"numReadonlySignedAccounts"),x.blob(1,"numReadonlyUnsignedAccounts"),x.blob(t.length,"keyCount"),x.seq(sr("key"),e,"keys"),sr("recentBlockhash")]),u={numRequiredSignatures:y.Buffer.from([this.header.numRequiredSignatures]),numReadonlySignedAccounts:y.Buffer.from([this.header.numReadonlySignedAccounts]),numReadonlyUnsignedAccounts:y.Buffer.from([this.header.numReadonlyUnsignedAccounts]),keyCount:y.Buffer.from(t),keys:this.accountKeys.map((function(e){return R(e.toBytes())})),recentBlockhash:k.a.decode(this.recentBlockhash)},s=y.Buffer.alloc(2048),c=a.encode(u,s);return i.copy(s,c),s.slice(0,c+i.length)}}],[{key:"from",value:function(t){for(var r=Object(u.a)(t),n=r.shift(),i=r.shift(),o=r.shift(),a=fr(r),s=[],c=0;c<a;c++){var f=r.slice(0,32);r=r.slice(32),s.push(k.a.encode(y.Buffer.from(f)))}for(var l=r.slice(0,32),h=fr(r=r.slice(32)),d=[],p=0;p<h;p++){var b=r.shift(),v=fr(r),m=r.slice(0,v),g=fr(r=r.slice(v)),w=r.slice(0,g),_=k.a.encode(y.Buffer.from(w));r=r.slice(g),d.push({programIdIndex:b,accounts:m,data:_})}return new e({header:{numRequiredSignatures:n,numReadonlySignedAccounts:i,numReadonlyUnsignedAccounts:o},recentBlockhash:k.a.encode(y.Buffer.from(l)),accountKeys:s,instructions:d})}}]),e}();function dr(e,t){if(!e)throw new Error(t||"Assertion failed")}var pr=y.Buffer.alloc(64).fill(0),br=1232,vr=Object(h.a)((function e(t){Object(l.a)(this,e),this.keys=void 0,this.programId=void 0,this.data=y.Buffer.alloc(0),this.programId=t.programId,this.keys=t.keys,t.data&&(this.data=t.data)})),yr=function(){function e(t){Object(l.a)(this,e),this.signatures=[],this.feePayer=void 0,this.instructions=[],this.recentBlockhash=void 0,this.nonceInfo=void 0,t&&Object.assign(this,t)}return Object(h.a)(e,[{key:"signature",get:function(){return this.signatures.length>0?this.signatures[0].signature:null}},{key:"add",value:function(){for(var e=this,t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];if(0===r.length)throw new Error("No instructions");return r.forEach((function(t){"instructions"in t?e.instructions=e.instructions.concat(t.instructions):"data"in t&&"programId"in t&&"keys"in t?e.instructions.push(t):e.instructions.push(new vr(t))})),this}},{key:"compileMessage",value:function(){var e=this.nonceInfo;e&&this.instructions[0]!=e.nonceInstruction&&(this.recentBlockhash=e.nonce,this.instructions.unshift(e.nonceInstruction));var t,r=this.recentBlockhash;if(!r)throw new Error("Transaction recentBlockhash required");if(this.instructions.length<1&&console.warn("No instructions provided"),this.feePayer)t=this.feePayer;else{if(!(this.signatures.length>0&&this.signatures[0].publicKey))throw new Error("Transaction fee payer required");t=this.signatures[0].publicKey}for(var n=0;n<this.instructions.length;n++)if(void 0===this.instructions[n].programId)throw new Error("Transaction instruction index ".concat(n," has undefined program id"));var u=[],s=[];this.instructions.forEach((function(e){e.keys.forEach((function(e){s.push(Object(a.a)({},e))}));var t=e.programId.toString();u.includes(t)||u.push(t)})),u.forEach((function(e){s.push({pubkey:new er(e),isSigner:!1,isWritable:!1})})),s.sort((function(e,t){var r=e.isSigner===t.isSigner?0:e.isSigner?-1:1,n=e.isWritable===t.isWritable?0:e.isWritable?-1:1;return r||n}));var c=[];s.forEach((function(e){var t=e.pubkey.toString(),r=c.findIndex((function(e){return e.pubkey.toString()===t}));r>-1?c[r].isWritable=c[r].isWritable||e.isWritable:c.push(e)}));var f=c.findIndex((function(e){return e.pubkey.equals(t)}));if(f>-1){var l=c.splice(f,1),h=Object(o.a)(l,1)[0];h.isSigner=!0,h.isWritable=!0,c.unshift(h)}else c.unshift({pubkey:t,isSigner:!0,isWritable:!0});var d,p=Object(i.a)(this.signatures);try{var b=function(){var e=d.value,t=c.findIndex((function(t){return t.pubkey.equals(e.publicKey)}));if(!(t>-1))throw new Error("unknown signer: ".concat(e.publicKey.toString()));c[t].isSigner||(c[t].isSigner=!0,console.warn("Transaction references a signature that is unnecessary, only the fee payer and instruction signer accounts should sign a transaction. This behavior is deprecated and will throw an error in the next major version release."))};for(p.s();!(d=p.n()).done;)b()}catch(S){p.e(S)}finally{p.f()}var v=0,y=0,m=0,g=[],w=[];c.forEach((function(e){var t=e.pubkey,r=e.isSigner,n=e.isWritable;r?(g.push(t.toString()),v+=1,n||(y+=1)):(w.push(t.toString()),n||(m+=1))}));var _=g.concat(w),x=this.instructions.map((function(e){var t=e.data,r=e.programId;return{programIdIndex:_.indexOf(r.toString()),accounts:e.keys.map((function(e){return _.indexOf(e.pubkey.toString())})),data:k.a.encode(t)}}));return x.forEach((function(e){dr(e.programIdIndex>=0),e.accounts.forEach((function(e){return dr(e>=0)}))})),new hr({header:{numRequiredSignatures:v,numReadonlySignedAccounts:y,numReadonlyUnsignedAccounts:m},accountKeys:_,recentBlockhash:r,instructions:x})}},{key:"_compile",value:function(){var e=this.compileMessage(),t=e.accountKeys.slice(0,e.header.numRequiredSignatures);if(this.signatures.length===t.length&&this.signatures.every((function(e,r){return t[r].equals(e.publicKey)})))return e;return this.signatures=t.map((function(e){return{signature:null,publicKey:e}})),e}},{key:"serializeMessage",value:function(){return this._compile().serialize()}},{key:"setSigners",value:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];if(0===t.length)throw new Error("No signers");var n=new Set;this.signatures=t.filter((function(e){var t=e.toString();return!n.has(t)&&(n.add(t),!0)})).map((function(e){return{signature:null,publicKey:e}}))}},{key:"sign",value:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];if(0===t.length)throw new Error("No signers");for(var n=new Set,i=[],o=0,a=t;o<a.length;o++){var u=a[o],s=u.publicKey.toString();n.has(s)||(n.add(s),i.push(u))}this.signatures=i.map((function(e){return{signature:null,publicKey:e.publicKey}}));var c=this._compile();this._partialSign.apply(this,[c].concat(i)),this._verifySignatures(c.serialize(),!0)}},{key:"partialSign",value:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];if(0===t.length)throw new Error("No signers");for(var n=new Set,i=[],o=0,a=t;o<a.length;o++){var u=a[o],s=u.publicKey.toString();n.has(s)||(n.add(s),i.push(u))}var c=this._compile();this._partialSign.apply(this,[c].concat(i))}},{key:"_partialSign",value:function(e){for(var t=this,r=e.serialize(),n=arguments.length,i=new Array(n>1?n-1:0),o=1;o<n;o++)i[o-1]=arguments[o];i.forEach((function(e){var n=v.a.sign.detached(r,e.secretKey);t._addSignature(e.publicKey,R(n))}))}},{key:"addSignature",value:function(e,t){this._compile(),this._addSignature(e,t)}},{key:"_addSignature",value:function(e,t){dr(64===t.length);var r=this.signatures.findIndex((function(t){return e.equals(t.publicKey)}));if(r<0)throw new Error("unknown signer: ".concat(e.toString()));this.signatures[r].signature=y.Buffer.from(t)}},{key:"verifySignatures",value:function(){return this._verifySignatures(this.serializeMessage(),!0)}},{key:"_verifySignatures",value:function(e,t){var r,n=Object(i.a)(this.signatures);try{for(n.s();!(r=n.n()).done;){var o=r.value,a=o.signature,u=o.publicKey;if(null===a){if(t)return!1}else if(!v.a.sign.detached.verify(e,a,u.toBuffer()))return!1}}catch(s){n.e(s)}finally{n.f()}return!0}},{key:"serialize",value:function(e){var t=Object.assign({requireAllSignatures:!0,verifySignatures:!0},e),r=t.requireAllSignatures,n=t.verifySignatures,i=this.serializeMessage();if(n&&!this._verifySignatures(i,r))throw new Error("Signature verification failed");return this._serialize(i)}},{key:"_serialize",value:function(e){var t=this.signatures,r=[];lr(r,t.length);var n=r.length+64*t.length+e.length,i=y.Buffer.alloc(n);return dr(t.length<256),y.Buffer.from(r).copy(i,0),t.forEach((function(e,t){var n=e.signature;null!==n&&(dr(64===n.length,"signature has invalid length"),y.Buffer.from(n).copy(i,r.length+64*t))})),e.copy(i,r.length+64*t.length),dr(i.length<=br,"Transaction too large: ".concat(i.length," > ").concat(br)),i}},{key:"keys",get:function(){return dr(1===this.instructions.length),this.instructions[0].keys.map((function(e){return e.pubkey}))}},{key:"programId",get:function(){return dr(1===this.instructions.length),this.instructions[0].programId}},{key:"data",get:function(){return dr(1===this.instructions.length),this.instructions[0].data}}],[{key:"from",value:function(t){for(var r=Object(u.a)(t),n=fr(r),i=[],o=0;o<n;o++){var a=r.slice(0,64);r=r.slice(64),i.push(k.a.encode(y.Buffer.from(a)))}return e.populate(hr.from(r),i)}},{key:"populate",value:function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=new e;return n.recentBlockhash=t.recentBlockhash,t.header.numRequiredSignatures>0&&(n.feePayer=t.accountKeys[0]),r.forEach((function(e,r){var i={signature:e==k.a.encode(pr)?null:k.a.decode(e),publicKey:t.accountKeys[r]};n.signatures.push(i)})),t.instructions.forEach((function(e){var r=e.accounts.map((function(e){var r=t.accountKeys[e];return{pubkey:r,isSigner:n.signatures.some((function(e){return e.publicKey.toString()===r.toString()}))||t.isAccountSigner(e),isWritable:t.isAccountWritable(e)}}));n.instructions.push(new vr({keys:r,programId:t.accountKeys[e.programIdIndex],data:k.a.decode(e.data)}))})),n}}]),e}(),mr=new er("SysvarC1ock11111111111111111111111111111111"),gr=new er("SysvarRecentB1ockHashes11111111111111111111"),wr=new er("SysvarRent111111111111111111111111111111111"),kr=new er("SysvarRewards111111111111111111111111111111"),_r=new er("SysvarStakeHistory1111111111111111111111111"),xr=new er("Sysvar1nstructions1111111111111111111111111");function Sr(e,t,r,n){return Er.apply(this,arguments)}function Er(){return(Er=Object(s.a)(p.a.mark((function e(t,r,n,i){var o,a,u;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=i&&{skipPreflight:i.skipPreflight,preflightCommitment:i.preflightCommitment||i.commitment},e.next=3,t.sendTransaction(r,n,o);case 3:return a=e.sent,e.next=6,t.confirmTransaction(a,i&&i.commitment);case 6:if(!(u=e.sent.value).err){e.next=9;break}throw new Error("Transaction ".concat(a," failed (").concat(JSON.stringify(u),")"));case 9:return e.abrupt("return",a);case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function Or(e){return new Promise((function(t){return setTimeout(t,e)}))}function Ar(e,t){var r=e.layout.span>=0?e.layout.span:function(e,t){var r=0;return e.layout.fields.forEach((function(e){e.span>=0?r+=e.span:"function"===typeof e.alloc&&(r+=e.alloc(t[e.property]))})),r}(e,t),n=y.Buffer.alloc(r),i=Object.assign({instruction:e.index},t);return e.layout.encode(i,n),n}function Mr(e,t){var r;try{r=e.layout.decode(t)}catch(n){throw new Error("invalid instruction; "+n)}if(r.instruction!==e.index)throw new Error("invalid instruction; instruction index mismatch ".concat(r.instruction," != ").concat(e.index));return r}var jr=x.nu64("lamportsPerSignature"),Ir=x.struct([x.u32("version"),x.u32("state"),sr("authorizedPubkey"),sr("nonce"),x.struct([jr],"feeCalculator")]),Pr=Ir.span,Rr=function(){function e(t){Object(l.a)(this,e),this.authorizedPubkey=void 0,this.nonce=void 0,this.feeCalculator=void 0,this.authorizedPubkey=t.authorizedPubkey,this.nonce=t.nonce,this.feeCalculator=t.feeCalculator}return Object(h.a)(e,null,[{key:"fromAccountData",value:function(t){var r=Ir.decode(R(t),0);return new e({authorizedPubkey:new er(r.authorizedPubkey),nonce:new er(r.nonce).toString(),feeCalculator:r.feeCalculator})}}]),e}(),Cr=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"decodeInstructionType",value:function(e){this.checkProgramId(e.programId);for(var t,r=x.u32("instruction").decode(e.data),n=0,i=Object.entries(Tr);n<i.length;n++){var a=Object(o.a)(i[n],2),u=a[0];if(a[1].index==r){t=u;break}}if(!t)throw new Error("Instruction type incorrect; not a SystemInstruction");return t}},{key:"decodeCreateAccount",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,2);var t=Mr(Tr.Create,e.data),r=t.lamports,n=t.space,i=t.programId;return{fromPubkey:e.keys[0].pubkey,newAccountPubkey:e.keys[1].pubkey,lamports:r,space:n,programId:new er(i)}}},{key:"decodeTransfer",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,2);var t=Mr(Tr.Transfer,e.data).lamports;return{fromPubkey:e.keys[0].pubkey,toPubkey:e.keys[1].pubkey,lamports:t}}},{key:"decodeTransferWithSeed",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,3);var t=Mr(Tr.TransferWithSeed,e.data),r=t.lamports,n=t.seed,i=t.programId;return{fromPubkey:e.keys[0].pubkey,basePubkey:e.keys[1].pubkey,toPubkey:e.keys[2].pubkey,lamports:r,seed:n,programId:new er(i)}}},{key:"decodeAllocate",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,1);var t=Mr(Tr.Allocate,e.data).space;return{accountPubkey:e.keys[0].pubkey,space:t}}},{key:"decodeAllocateWithSeed",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,1);var t=Mr(Tr.AllocateWithSeed,e.data),r=t.base,n=t.seed,i=t.space,o=t.programId;return{accountPubkey:e.keys[0].pubkey,basePubkey:new er(r),seed:n,space:i,programId:new er(o)}}},{key:"decodeAssign",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,1);var t=Mr(Tr.Assign,e.data).programId;return{accountPubkey:e.keys[0].pubkey,programId:new er(t)}}},{key:"decodeAssignWithSeed",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,1);var t=Mr(Tr.AssignWithSeed,e.data),r=t.base,n=t.seed,i=t.programId;return{accountPubkey:e.keys[0].pubkey,basePubkey:new er(r),seed:n,programId:new er(i)}}},{key:"decodeCreateWithSeed",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,2);var t=Mr(Tr.CreateWithSeed,e.data),r=t.base,n=t.seed,i=t.lamports,o=t.space,a=t.programId;return{fromPubkey:e.keys[0].pubkey,newAccountPubkey:e.keys[1].pubkey,basePubkey:new er(r),seed:n,lamports:i,space:o,programId:new er(a)}}},{key:"decodeNonceInitialize",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,3);var t=Mr(Tr.InitializeNonceAccount,e.data).authorized;return{noncePubkey:e.keys[0].pubkey,authorizedPubkey:new er(t)}}},{key:"decodeNonceAdvance",value:function(e){return this.checkProgramId(e.programId),this.checkKeyLength(e.keys,3),Mr(Tr.AdvanceNonceAccount,e.data),{noncePubkey:e.keys[0].pubkey,authorizedPubkey:e.keys[2].pubkey}}},{key:"decodeNonceWithdraw",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,5);var t=Mr(Tr.WithdrawNonceAccount,e.data).lamports;return{noncePubkey:e.keys[0].pubkey,toPubkey:e.keys[1].pubkey,authorizedPubkey:e.keys[4].pubkey,lamports:t}}},{key:"decodeNonceAuthorize",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,2);var t=Mr(Tr.AuthorizeNonceAccount,e.data).authorized;return{noncePubkey:e.keys[0].pubkey,authorizedPubkey:e.keys[1].pubkey,newAuthorizedPubkey:new er(t)}}},{key:"checkProgramId",value:function(e){if(!e.equals(Br.programId))throw new Error("invalid instruction; programId is not SystemProgram")}},{key:"checkKeyLength",value:function(e,t){if(e.length<t)throw new Error("invalid instruction; found ".concat(e.length," keys, expected at least ").concat(t))}}]),e}(),Tr=Object.freeze({Create:{index:0,layout:x.struct([x.u32("instruction"),x.ns64("lamports"),x.ns64("space"),sr("programId")])},Assign:{index:1,layout:x.struct([x.u32("instruction"),sr("programId")])},Transfer:{index:2,layout:x.struct([x.u32("instruction"),x.ns64("lamports")])},CreateWithSeed:{index:3,layout:x.struct([x.u32("instruction"),sr("base"),cr("seed"),x.ns64("lamports"),x.ns64("space"),sr("programId")])},AdvanceNonceAccount:{index:4,layout:x.struct([x.u32("instruction")])},WithdrawNonceAccount:{index:5,layout:x.struct([x.u32("instruction"),x.ns64("lamports")])},InitializeNonceAccount:{index:6,layout:x.struct([x.u32("instruction"),sr("authorized")])},AuthorizeNonceAccount:{index:7,layout:x.struct([x.u32("instruction"),sr("authorized")])},Allocate:{index:8,layout:x.struct([x.u32("instruction"),x.ns64("space")])},AllocateWithSeed:{index:9,layout:x.struct([x.u32("instruction"),sr("base"),cr("seed"),x.ns64("space"),sr("programId")])},AssignWithSeed:{index:10,layout:x.struct([x.u32("instruction"),sr("base"),cr("seed"),sr("programId")])},TransferWithSeed:{index:11,layout:x.struct([x.u32("instruction"),x.ns64("lamports"),cr("seed"),sr("programId")])}}),Br=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"createAccount",value:function(e){var t=Ar(Tr.Create,{lamports:e.lamports,space:e.space,programId:R(e.programId.toBuffer())});return new vr({keys:[{pubkey:e.fromPubkey,isSigner:!0,isWritable:!0},{pubkey:e.newAccountPubkey,isSigner:!0,isWritable:!0}],programId:this.programId,data:t})}},{key:"transfer",value:function(e){var t,r;"basePubkey"in e?(t=Ar(Tr.TransferWithSeed,{lamports:e.lamports,seed:e.seed,programId:R(e.programId.toBuffer())}),r=[{pubkey:e.fromPubkey,isSigner:!1,isWritable:!0},{pubkey:e.basePubkey,isSigner:!0,isWritable:!1},{pubkey:e.toPubkey,isSigner:!1,isWritable:!0}]):(t=Ar(Tr.Transfer,{lamports:e.lamports}),r=[{pubkey:e.fromPubkey,isSigner:!0,isWritable:!0},{pubkey:e.toPubkey,isSigner:!1,isWritable:!0}]);return new vr({keys:r,programId:this.programId,data:t})}},{key:"assign",value:function(e){var t,r;"basePubkey"in e?(t=Ar(Tr.AssignWithSeed,{base:R(e.basePubkey.toBuffer()),seed:e.seed,programId:R(e.programId.toBuffer())}),r=[{pubkey:e.accountPubkey,isSigner:!1,isWritable:!0},{pubkey:e.basePubkey,isSigner:!0,isWritable:!1}]):(t=Ar(Tr.Assign,{programId:R(e.programId.toBuffer())}),r=[{pubkey:e.accountPubkey,isSigner:!0,isWritable:!0}]);return new vr({keys:r,programId:this.programId,data:t})}},{key:"createAccountWithSeed",value:function(e){var t=Ar(Tr.CreateWithSeed,{base:R(e.basePubkey.toBuffer()),seed:e.seed,lamports:e.lamports,space:e.space,programId:R(e.programId.toBuffer())}),r=[{pubkey:e.fromPubkey,isSigner:!0,isWritable:!0},{pubkey:e.newAccountPubkey,isSigner:!1,isWritable:!0}];return e.basePubkey!=e.fromPubkey&&r.push({pubkey:e.basePubkey,isSigner:!0,isWritable:!1}),new vr({keys:r,programId:this.programId,data:t})}},{key:"createNonceAccount",value:function(t){var r=new yr;"basePubkey"in t&&"seed"in t?r.add(e.createAccountWithSeed({fromPubkey:t.fromPubkey,newAccountPubkey:t.noncePubkey,basePubkey:t.basePubkey,seed:t.seed,lamports:t.lamports,space:Pr,programId:this.programId})):r.add(e.createAccount({fromPubkey:t.fromPubkey,newAccountPubkey:t.noncePubkey,lamports:t.lamports,space:Pr,programId:this.programId}));var n={noncePubkey:t.noncePubkey,authorizedPubkey:t.authorizedPubkey};return r.add(this.nonceInitialize(n)),r}},{key:"nonceInitialize",value:function(e){var t=Ar(Tr.InitializeNonceAccount,{authorized:R(e.authorizedPubkey.toBuffer())}),r={keys:[{pubkey:e.noncePubkey,isSigner:!1,isWritable:!0},{pubkey:gr,isSigner:!1,isWritable:!1},{pubkey:wr,isSigner:!1,isWritable:!1}],programId:this.programId,data:t};return new vr(r)}},{key:"nonceAdvance",value:function(e){var t=Ar(Tr.AdvanceNonceAccount),r={keys:[{pubkey:e.noncePubkey,isSigner:!1,isWritable:!0},{pubkey:gr,isSigner:!1,isWritable:!1},{pubkey:e.authorizedPubkey,isSigner:!0,isWritable:!1}],programId:this.programId,data:t};return new vr(r)}},{key:"nonceWithdraw",value:function(e){var t=Ar(Tr.WithdrawNonceAccount,{lamports:e.lamports});return new vr({keys:[{pubkey:e.noncePubkey,isSigner:!1,isWritable:!0},{pubkey:e.toPubkey,isSigner:!1,isWritable:!0},{pubkey:gr,isSigner:!1,isWritable:!1},{pubkey:wr,isSigner:!1,isWritable:!1},{pubkey:e.authorizedPubkey,isSigner:!0,isWritable:!1}],programId:this.programId,data:t})}},{key:"nonceAuthorize",value:function(e){var t=Ar(Tr.AuthorizeNonceAccount,{authorized:R(e.newAuthorizedPubkey.toBuffer())});return new vr({keys:[{pubkey:e.noncePubkey,isSigner:!1,isWritable:!0},{pubkey:e.authorizedPubkey,isSigner:!0,isWritable:!1}],programId:this.programId,data:t})}},{key:"allocate",value:function(e){var t,r;"basePubkey"in e?(t=Ar(Tr.AllocateWithSeed,{base:R(e.basePubkey.toBuffer()),seed:e.seed,space:e.space,programId:R(e.programId.toBuffer())}),r=[{pubkey:e.accountPubkey,isSigner:!1,isWritable:!0},{pubkey:e.basePubkey,isSigner:!0,isWritable:!1}]):(t=Ar(Tr.Allocate,{space:e.space}),r=[{pubkey:e.accountPubkey,isSigner:!0,isWritable:!0}]);return new vr({keys:r,programId:this.programId,data:t})}}]),e}();Br.programId=new er("11111111111111111111111111111111");var Lr=br-300,zr=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"getMinNumSignatures",value:function(t){return 2*(Math.ceil(t/e.chunkSize)+1+1)}},{key:"load",value:function(){var t=Object(s.a)(p.a.mark((function t(r,n,i,o,a){var u,s,c,f,l,h,d,b,v,m,g,w,k,_;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,r.getMinimumBalanceForRentExemption(a.length);case 2:return u=t.sent,t.next=5,r.getAccountInfo(i.publicKey,"confirmed");case 5:if(s=t.sent,c=null,null===s){t.next=16;break}if(!s.executable){t.next=11;break}return console.error("Program load failed, account is already executable"),t.abrupt("return",!1);case 11:s.data.length!==a.length&&(c=c||new yr).add(Br.allocate({accountPubkey:i.publicKey,space:a.length})),s.owner.equals(o)||(c=c||new yr).add(Br.assign({accountPubkey:i.publicKey,programId:o})),s.lamports<u&&(c=c||new yr).add(Br.transfer({fromPubkey:n.publicKey,toPubkey:i.publicKey,lamports:u-s.lamports})),t.next=17;break;case 16:c=(new yr).add(Br.createAccount({fromPubkey:n.publicKey,newAccountPubkey:i.publicKey,lamports:u>0?u:1,space:a.length,programId:o}));case 17:if(null===c){t.next=20;break}return t.next=20,Sr(r,c,[n,i],{commitment:"confirmed"});case 20:f=x.struct([x.u32("instruction"),x.u32("offset"),x.u32("bytesLength"),x.u32("bytesLengthPadding"),x.seq(x.u8("byte"),x.offset(x.u32(),-8),"bytes")]),l=e.chunkSize,h=0,d=a,b=[];case 25:if(!(d.length>0)){t.next=39;break}if(v=d.slice(0,l),m=y.Buffer.alloc(l+16),f.encode({instruction:0,offset:h,bytes:v},m),g=(new yr).add({keys:[{pubkey:i.publicKey,isSigner:!0,isWritable:!0}],programId:o,data:m}),b.push(Sr(r,g,[n,i],{commitment:"confirmed"})),!r._rpcEndpoint.includes("solana.com")){t.next=35;break}return 4,t.next=35,Or(250);case 35:h+=l,d=d.slice(l),t.next=25;break;case 39:return t.next=41,Promise.all(b);case 41:return w=x.struct([x.u32("instruction")]),k=y.Buffer.alloc(w.span),w.encode({instruction:1},k),_=(new yr).add({keys:[{pubkey:i.publicKey,isSigner:!0,isWritable:!0},{pubkey:wr,isSigner:!1,isWritable:!1}],programId:o,data:k}),t.next=47,Sr(r,_,[n,i],{commitment:"confirmed"});case 47:return t.abrupt("return",!0);case 48:case"end":return t.stop()}}),t)})));return function(e,r,n,i,o){return t.apply(this,arguments)}}()}]),e}();zr.chunkSize=Lr;var Ur=new er("BPFLoader2111111111111111111111111111111111"),Nr=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"getMinNumSignatures",value:function(e){return zr.getMinNumSignatures(e)}},{key:"load",value:function(e,t,r,n,i){return zr.load(e,t,r,i,n)}}]),e}(),Dr={exports:{}};!function(e,t){var r="undefined"!==typeof self?self:C,n=function(){function e(){this.fetch=!1,this.DOMException=r.DOMException}return e.prototype=r,new e}();!function(e){!function(t){var r="URLSearchParams"in e,n="Symbol"in e&&"iterator"in Symbol,i="FileReader"in e&&"Blob"in e&&function(){try{return new Blob,!0}catch(e){return!1}}(),o="FormData"in e,a="ArrayBuffer"in e;if(a)var u=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],s=ArrayBuffer.isView||function(e){return e&&u.indexOf(Object.prototype.toString.call(e))>-1};function c(e){if("string"!==typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(e))throw new TypeError("Invalid character in header field name");return e.toLowerCase()}function f(e){return"string"!==typeof e&&(e=String(e)),e}function l(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return n&&(t[Symbol.iterator]=function(){return t}),t}function h(e){this.map={},e instanceof h?e.forEach((function(e,t){this.append(t,e)}),this):Array.isArray(e)?e.forEach((function(e){this.append(e[0],e[1])}),this):e&&Object.getOwnPropertyNames(e).forEach((function(t){this.append(t,e[t])}),this)}function d(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function p(e){return new Promise((function(t,r){e.onload=function(){t(e.result)},e.onerror=function(){r(e.error)}}))}function b(e){var t=new FileReader,r=p(t);return t.readAsArrayBuffer(e),r}function v(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function y(){return this.bodyUsed=!1,this._initBody=function(e){var t;this._bodyInit=e,e?"string"===typeof e?this._bodyText=e:i&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:o&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:r&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():a&&i&&((t=e)&&DataView.prototype.isPrototypeOf(t))?(this._bodyArrayBuffer=v(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):a&&(ArrayBuffer.prototype.isPrototypeOf(e)||s(e))?this._bodyArrayBuffer=v(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||("string"===typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):r&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},i&&(this.blob=function(){var e=d(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?d(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(b)}),this.text=function(){var e=d(this);if(e)return e;if(this._bodyBlob)return function(e){var t=new FileReader,r=p(t);return t.readAsText(e),r}(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),r=new Array(t.length),n=0;n<t.length;n++)r[n]=String.fromCharCode(t[n]);return r.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},o&&(this.formData=function(){return this.text().then(w)}),this.json=function(){return this.text().then(JSON.parse)},this}h.prototype.append=function(e,t){e=c(e),t=f(t);var r=this.map[e];this.map[e]=r?r+", "+t:t},h.prototype.delete=function(e){delete this.map[c(e)]},h.prototype.get=function(e){return e=c(e),this.has(e)?this.map[e]:null},h.prototype.has=function(e){return this.map.hasOwnProperty(c(e))},h.prototype.set=function(e,t){this.map[c(e)]=f(t)},h.prototype.forEach=function(e,t){for(var r in this.map)this.map.hasOwnProperty(r)&&e.call(t,this.map[r],r,this)},h.prototype.keys=function(){var e=[];return this.forEach((function(t,r){e.push(r)})),l(e)},h.prototype.values=function(){var e=[];return this.forEach((function(t){e.push(t)})),l(e)},h.prototype.entries=function(){var e=[];return this.forEach((function(t,r){e.push([r,t])})),l(e)},n&&(h.prototype[Symbol.iterator]=h.prototype.entries);var m=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function g(e,t){var r=(t=t||{}).body;if(e instanceof g){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new h(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,r||null==e._bodyInit||(r=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new h(t.headers)),this.method=function(e){var t=e.toUpperCase();return m.indexOf(t)>-1?t:e}(t.method||this.method||"GET"),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&r)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(r)}function w(e){var t=new FormData;return e.trim().split("&").forEach((function(e){if(e){var r=e.split("="),n=r.shift().replace(/\+/g," "),i=r.join("=").replace(/\+/g," ");t.append(decodeURIComponent(n),decodeURIComponent(i))}})),t}function k(e){var t=new h;return e.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach((function(e){var r=e.split(":"),n=r.shift().trim();if(n){var i=r.join(":").trim();t.append(n,i)}})),t}function _(e,t){t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"OK",this.headers=new h(t.headers),this.url=t.url||"",this._initBody(e)}g.prototype.clone=function(){return new g(this,{body:this._bodyInit})},y.call(g.prototype),y.call(_.prototype),_.prototype.clone=function(){return new _(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},_.error=function(){var e=new _(null,{status:0,statusText:""});return e.type="error",e};var x=[301,302,303,307,308];_.redirect=function(e,t){if(-1===x.indexOf(t))throw new RangeError("Invalid status code");return new _(null,{status:t,headers:{location:e}})},t.DOMException=e.DOMException;try{new t.DOMException}catch(E){t.DOMException=function(e,t){this.message=e,this.name=t;var r=Error(e);this.stack=r.stack},t.DOMException.prototype=Object.create(Error.prototype),t.DOMException.prototype.constructor=t.DOMException}function S(e,r){return new Promise((function(n,o){var a=new g(e,r);if(a.signal&&a.signal.aborted)return o(new t.DOMException("Aborted","AbortError"));var u=new XMLHttpRequest;function s(){u.abort()}u.onload=function(){var e={status:u.status,statusText:u.statusText,headers:k(u.getAllResponseHeaders()||"")};e.url="responseURL"in u?u.responseURL:e.headers.get("X-Request-URL");var t="response"in u?u.response:u.responseText;n(new _(t,e))},u.onerror=function(){o(new TypeError("Network request failed"))},u.ontimeout=function(){o(new TypeError("Network request failed"))},u.onabort=function(){o(new t.DOMException("Aborted","AbortError"))},u.open(a.method,a.url,!0),"include"===a.credentials?u.withCredentials=!0:"omit"===a.credentials&&(u.withCredentials=!1),"responseType"in u&&i&&(u.responseType="blob"),a.headers.forEach((function(e,t){u.setRequestHeader(t,e)})),a.signal&&(a.signal.addEventListener("abort",s),u.onreadystatechange=function(){4===u.readyState&&a.signal.removeEventListener("abort",s)}),u.send("undefined"===typeof a._bodyInit?null:a._bodyInit)}))}S.polyfill=!0,e.fetch||(e.fetch=S,e.Headers=h,e.Request=g,e.Response=_),t.Headers=h,t.Request=g,t.Response=_,t.fetch=S,Object.defineProperty(t,"__esModule",{value:!0})}({})}(n),n.fetch.ponyfill=!0,delete n.fetch.polyfill;var i=n;(t=i.fetch).default=i.fetch,t.fetch=i.fetch,t.Headers=i.Headers,t.Request=i.Request,t.Response=i.Response,e.exports=t}(Dr,Dr.exports);var Fr=T(Dr.exports);function qr(e){for(var t=0;e>1;)e/=2,t++;return t}var Hr=function(){function e(t,r,n,i,o){Object(l.a)(this,e),this.slotsPerEpoch=void 0,this.leaderScheduleSlotOffset=void 0,this.warmup=void 0,this.firstNormalEpoch=void 0,this.firstNormalSlot=void 0,this.slotsPerEpoch=t,this.leaderScheduleSlotOffset=r,this.warmup=n,this.firstNormalEpoch=i,this.firstNormalSlot=o}return Object(h.a)(e,[{key:"getEpoch",value:function(e){return this.getEpochAndSlotIndex(e)[0]}},{key:"getEpochAndSlotIndex",value:function(e){if(e<this.firstNormalSlot){var t=qr(0===(r=e+32+1)?1:(r--,r|=r>>1,r|=r>>2,r|=r>>4,r|=r>>8,r|=r>>16,1+(r|=r>>32)))-qr(32)-1;return[t,e-(this.getSlotsInEpoch(t)-32)]}var r,n=e-this.firstNormalSlot,i=Math.floor(n/this.slotsPerEpoch);return[this.firstNormalEpoch+i,n%this.slotsPerEpoch]}},{key:"getFirstSlotInEpoch",value:function(e){return e<=this.firstNormalEpoch?32*(Math.pow(2,e)-1):(e-this.firstNormalEpoch)*this.slotsPerEpoch+this.firstNormalSlot}},{key:"getLastSlotInEpoch",value:function(e){return this.getFirstSlotInEpoch(e)+this.getSlotsInEpoch(e)-1}},{key:"getSlotsInEpoch",value:function(e){return e<this.firstNormalEpoch?Math.pow(2,e+qr(32)):this.slotsPerEpoch}}]),e}(),Wr=function(e){Object(c.a)(r,e);var t=Object(f.a)(r);function r(e,n){var i;return Object(l.a)(this,r),(i=t.call(this,e)).logs=void 0,i.logs=n,i}return Object(h.a)(r)}(Object(n.a)(Error));function Kr(e,t){var r,n=new Promise((function(e){r=setTimeout((function(){return e(null)}),t)}));return Promise.race([e,n]).then((function(e){return clearTimeout(r),e}))}var Vr=Object(S.e)(Object(S.g)(er),Object(S.m)(),(function(e){return new er(e)})),Zr=Object(S.n)([Object(S.m)(),Object(S.h)("base64")]),Yr=Object(S.e)(Object(S.g)(y.Buffer),Zr,(function(e){return y.Buffer.from(e[0],"base64")})),Xr=3e4;function Gr(e){return Object(S.p)([Object(S.o)({jsonrpc:Object(S.h)("2.0"),id:Object(S.m)(),result:e}),Object(S.o)({jsonrpc:Object(S.h)("2.0"),id:Object(S.m)(),error:Object(S.o)({code:Object(S.q)(),message:Object(S.m)(),data:Object(S.k)(Object(S.a)())})})])}var Jr=Gr(Object(S.q)());function $r(e){return Object(S.e)(Gr(e),Jr,(function(t){return"error"in t?t:Object(a.a)(Object(a.a)({},t),{},{result:Object(S.f)(t.result,e)})}))}function Qr(e){return $r(Object(S.o)({context:Object(S.o)({slot:Object(S.j)()}),value:e}))}function en(e){return Object(S.o)({context:Object(S.o)({slot:Object(S.j)()}),value:e})}var tn=Object(S.o)({foundation:Object(S.j)(),foundationTerm:Object(S.j)(),initial:Object(S.j)(),taper:Object(S.j)(),terminal:Object(S.j)()}),rn=$r(Object(S.b)(Object(S.i)(Object(S.o)({epoch:Object(S.j)(),effectiveSlot:Object(S.j)(),amount:Object(S.j)(),postBalance:Object(S.j)()})))),nn=Object(S.o)({epoch:Object(S.j)(),slotIndex:Object(S.j)(),slotsInEpoch:Object(S.j)(),absoluteSlot:Object(S.j)(),blockHeight:Object(S.k)(Object(S.j)()),transactionCount:Object(S.k)(Object(S.j)())}),on=Object(S.o)({slotsPerEpoch:Object(S.j)(),leaderScheduleSlotOffset:Object(S.j)(),warmup:Object(S.d)(),firstNormalEpoch:Object(S.j)(),firstNormalSlot:Object(S.j)()}),an=Object(S.l)(Object(S.m)(),Object(S.b)(Object(S.j)())),un=Object(S.i)(Object(S.p)([Object(S.o)({}),Object(S.m)()])),sn=Object(S.o)({err:un}),cn=Object(S.h)("receivedSignature"),fn=Object(S.o)({"solana-core":Object(S.m)(),"feature-set":Object(S.k)(Object(S.j)())}),ln=Qr(Object(S.o)({err:Object(S.i)(Object(S.p)([Object(S.o)({}),Object(S.m)()])),logs:Object(S.i)(Object(S.b)(Object(S.m)())),accounts:Object(S.k)(Object(S.i)(Object(S.b)(Object(S.o)({executable:Object(S.d)(),owner:Object(S.m)(),lamports:Object(S.j)(),data:Object(S.b)(Object(S.m)()),rentEpoch:Object(S.k)(Object(S.j)())})))),unitsConsumed:Object(S.k)(Object(S.j)())}));var hn=$r(tn),dn=$r(nn),pn=$r(on),bn=$r(an),vn=$r(Object(S.j)()),yn=Qr(Object(S.o)({total:Object(S.j)(),circulating:Object(S.j)(),nonCirculating:Object(S.j)(),nonCirculatingAccounts:Object(S.b)(Vr)})),mn=Object(S.o)({amount:Object(S.m)(),uiAmount:Object(S.i)(Object(S.j)()),decimals:Object(S.j)(),uiAmountString:Object(S.k)(Object(S.m)())}),gn=Qr(Object(S.b)(Object(S.o)({address:Vr,amount:Object(S.m)(),uiAmount:Object(S.i)(Object(S.j)()),decimals:Object(S.j)(),uiAmountString:Object(S.k)(Object(S.m)())}))),wn=Qr(Object(S.b)(Object(S.o)({pubkey:Vr,account:Object(S.o)({executable:Object(S.d)(),owner:Vr,lamports:Object(S.j)(),data:Yr,rentEpoch:Object(S.j)()})}))),kn=Object(S.o)({program:Object(S.m)(),parsed:Object(S.q)(),space:Object(S.j)()}),_n=Qr(Object(S.b)(Object(S.o)({pubkey:Vr,account:Object(S.o)({executable:Object(S.d)(),owner:Vr,lamports:Object(S.j)(),data:kn,rentEpoch:Object(S.j)()})}))),xn=Qr(Object(S.b)(Object(S.o)({lamports:Object(S.j)(),address:Vr}))),Sn=Object(S.o)({executable:Object(S.d)(),owner:Vr,lamports:Object(S.j)(),data:Yr,rentEpoch:Object(S.j)()}),En=Object(S.o)({pubkey:Vr,account:Sn}),On=Object(S.e)(Object(S.p)([Object(S.g)(y.Buffer),kn]),Object(S.p)([Zr,kn]),(function(e){return Array.isArray(e)?Object(S.f)(e,Yr):e})),An=Object(S.o)({executable:Object(S.d)(),owner:Vr,lamports:Object(S.j)(),data:On,rentEpoch:Object(S.j)()}),Mn=Object(S.o)({pubkey:Vr,account:An}),jn=Object(S.o)({state:Object(S.p)([Object(S.h)("active"),Object(S.h)("inactive"),Object(S.h)("activating"),Object(S.h)("deactivating")]),active:Object(S.j)(),inactive:Object(S.j)()}),In=$r(Object(S.b)(Object(S.o)({signature:Object(S.m)(),slot:Object(S.j)(),err:un,memo:Object(S.i)(Object(S.m)()),blockTime:Object(S.k)(Object(S.i)(Object(S.j)()))}))),Pn=$r(Object(S.b)(Object(S.o)({signature:Object(S.m)(),slot:Object(S.j)(),err:un,memo:Object(S.i)(Object(S.m)()),blockTime:Object(S.k)(Object(S.i)(Object(S.j)()))}))),Rn=Object(S.o)({subscription:Object(S.j)(),result:en(Sn)}),Cn=Object(S.o)({pubkey:Vr,account:Sn}),Tn=Object(S.o)({subscription:Object(S.j)(),result:en(Cn)}),Bn=Object(S.o)({parent:Object(S.j)(),slot:Object(S.j)(),root:Object(S.j)()}),Ln=Object(S.o)({subscription:Object(S.j)(),result:Bn}),zn=Object(S.p)([Object(S.o)({type:Object(S.p)([Object(S.h)("firstShredReceived"),Object(S.h)("completed"),Object(S.h)("optimisticConfirmation"),Object(S.h)("root")]),slot:Object(S.j)(),timestamp:Object(S.j)()}),Object(S.o)({type:Object(S.h)("createdBank"),parent:Object(S.j)(),slot:Object(S.j)(),timestamp:Object(S.j)()}),Object(S.o)({type:Object(S.h)("frozen"),slot:Object(S.j)(),timestamp:Object(S.j)(),stats:Object(S.o)({numTransactionEntries:Object(S.j)(),numSuccessfulTransactions:Object(S.j)(),numFailedTransactions:Object(S.j)(),maxTransactionsPerEntry:Object(S.j)()})}),Object(S.o)({type:Object(S.h)("dead"),slot:Object(S.j)(),timestamp:Object(S.j)(),err:Object(S.m)()})]),Un=Object(S.o)({subscription:Object(S.j)(),result:zn}),Nn=Object(S.o)({subscription:Object(S.j)(),result:en(Object(S.p)([sn,cn]))}),Dn=Object(S.o)({subscription:Object(S.j)(),result:Object(S.j)()}),Fn=Object(S.o)({pubkey:Object(S.m)(),gossip:Object(S.i)(Object(S.m)()),tpu:Object(S.i)(Object(S.m)()),rpc:Object(S.i)(Object(S.m)()),version:Object(S.i)(Object(S.m)())}),qn=Object(S.o)({votePubkey:Object(S.m)(),nodePubkey:Object(S.m)(),activatedStake:Object(S.j)(),epochVoteAccount:Object(S.d)(),epochCredits:Object(S.b)(Object(S.n)([Object(S.j)(),Object(S.j)(),Object(S.j)()])),commission:Object(S.j)(),lastVote:Object(S.j)(),rootSlot:Object(S.i)(Object(S.j)())}),Hn=$r(Object(S.o)({current:Object(S.b)(qn),delinquent:Object(S.b)(qn)})),Wn=Object(S.p)([Object(S.h)("processed"),Object(S.h)("confirmed"),Object(S.h)("finalized")]),Kn=Object(S.o)({slot:Object(S.j)(),confirmations:Object(S.i)(Object(S.j)()),err:un,confirmationStatus:Object(S.k)(Wn)}),Vn=Qr(Object(S.b)(Object(S.i)(Kn))),Zn=$r(Object(S.j)()),Yn=Object(S.o)({signatures:Object(S.b)(Object(S.m)()),message:Object(S.o)({accountKeys:Object(S.b)(Object(S.m)()),header:Object(S.o)({numRequiredSignatures:Object(S.j)(),numReadonlySignedAccounts:Object(S.j)(),numReadonlyUnsignedAccounts:Object(S.j)()}),instructions:Object(S.b)(Object(S.o)({accounts:Object(S.b)(Object(S.j)()),data:Object(S.m)(),programIdIndex:Object(S.j)()})),recentBlockhash:Object(S.m)()})}),Xn=Object(S.o)({parsed:Object(S.q)(),program:Object(S.m)(),programId:Vr}),Gn=Object(S.o)({accounts:Object(S.b)(Vr),data:Object(S.m)(),programId:Vr}),Jn=Object(S.p)([Gn,Xn]),$n=Object(S.p)([Object(S.o)({parsed:Object(S.q)(),program:Object(S.m)(),programId:Object(S.m)()}),Object(S.o)({accounts:Object(S.b)(Object(S.m)()),data:Object(S.m)(),programId:Object(S.m)()})]),Qn=Object(S.e)(Jn,$n,(function(e){return"accounts"in e?Object(S.f)(e,Gn):Object(S.f)(e,Xn)})),ei=Object(S.o)({signatures:Object(S.b)(Object(S.m)()),message:Object(S.o)({accountKeys:Object(S.b)(Object(S.o)({pubkey:Vr,signer:Object(S.d)(),writable:Object(S.d)()})),instructions:Object(S.b)(Qn),recentBlockhash:Object(S.m)()})}),ti=Object(S.o)({accountIndex:Object(S.j)(),mint:Object(S.m)(),uiTokenAmount:mn}),ri=Object(S.o)({err:un,fee:Object(S.j)(),innerInstructions:Object(S.k)(Object(S.i)(Object(S.b)(Object(S.o)({index:Object(S.j)(),instructions:Object(S.b)(Object(S.o)({accounts:Object(S.b)(Object(S.j)()),data:Object(S.m)(),programIdIndex:Object(S.j)()}))})))),preBalances:Object(S.b)(Object(S.j)()),postBalances:Object(S.b)(Object(S.j)()),logMessages:Object(S.k)(Object(S.i)(Object(S.b)(Object(S.m)()))),preTokenBalances:Object(S.k)(Object(S.i)(Object(S.b)(ti))),postTokenBalances:Object(S.k)(Object(S.i)(Object(S.b)(ti)))}),ni=Object(S.o)({err:un,fee:Object(S.j)(),innerInstructions:Object(S.k)(Object(S.i)(Object(S.b)(Object(S.o)({index:Object(S.j)(),instructions:Object(S.b)(Qn)})))),preBalances:Object(S.b)(Object(S.j)()),postBalances:Object(S.b)(Object(S.j)()),logMessages:Object(S.k)(Object(S.i)(Object(S.b)(Object(S.m)()))),preTokenBalances:Object(S.k)(Object(S.i)(Object(S.b)(ti))),postTokenBalances:Object(S.k)(Object(S.i)(Object(S.b)(ti)))}),ii=$r(Object(S.i)(Object(S.o)({blockhash:Object(S.m)(),previousBlockhash:Object(S.m)(),parentSlot:Object(S.j)(),transactions:Object(S.b)(Object(S.o)({transaction:Yn,meta:Object(S.i)(ri)})),rewards:Object(S.k)(Object(S.b)(Object(S.o)({pubkey:Object(S.m)(),lamports:Object(S.j)(),postBalance:Object(S.i)(Object(S.j)()),rewardType:Object(S.i)(Object(S.m)())}))),blockTime:Object(S.i)(Object(S.j)())}))),oi=$r(Object(S.i)(Object(S.o)({blockhash:Object(S.m)(),previousBlockhash:Object(S.m)(),parentSlot:Object(S.j)(),signatures:Object(S.b)(Object(S.m)()),blockTime:Object(S.i)(Object(S.j)())}))),ai=$r(Object(S.i)(Object(S.o)({slot:Object(S.j)(),meta:ri,blockTime:Object(S.k)(Object(S.i)(Object(S.j)())),transaction:Yn}))),ui=$r(Object(S.i)(Object(S.o)({slot:Object(S.j)(),transaction:ei,meta:Object(S.i)(ni),blockTime:Object(S.k)(Object(S.i)(Object(S.j)()))}))),si=Qr(Object(S.o)({blockhash:Object(S.m)(),feeCalculator:Object(S.o)({lamportsPerSignature:Object(S.j)()})})),ci=Object(S.o)({slot:Object(S.j)(),numTransactions:Object(S.j)(),numSlots:Object(S.j)(),samplePeriodSecs:Object(S.j)()}),fi=$r(Object(S.b)(ci)),li=Qr(Object(S.i)(Object(S.o)({feeCalculator:Object(S.o)({lamportsPerSignature:Object(S.j)()})}))),hi=$r(Object(S.m)()),di=$r(Object(S.m)()),pi=Object(S.o)({err:un,logs:Object(S.b)(Object(S.m)()),signature:Object(S.m)()}),bi=Object(S.o)({result:en(pi),subscription:Object(S.j)()}),vi=function(){function e(t,r){Object(l.a)(this,e),this._commitment=void 0,this._confirmTransactionInitialTimeout=void 0,this._rpcEndpoint=void 0,this._rpcWsEndpoint=void 0,this._rpcClient=void 0,this._rpcRequest=void 0,this._rpcBatchRequest=void 0,this._rpcWebSocket=void 0,this._rpcWebSocketConnected=!1,this._rpcWebSocketHeartbeat=null,this._rpcWebSocketIdleTimeout=null,this._disableBlockhashCaching=!1,this._pollingBlockhash=!1,this._blockhashInfo={recentBlockhash:null,lastFetch:0,transactionSignatures:[],simulatedSignatures:[]},this._accountChangeSubscriptionCounter=0,this._accountChangeSubscriptions={},this._programAccountChangeSubscriptionCounter=0,this._programAccountChangeSubscriptions={},this._rootSubscriptionCounter=0,this._rootSubscriptions={},this._signatureSubscriptionCounter=0,this._signatureSubscriptions={},this._slotSubscriptionCounter=0,this._slotSubscriptions={},this._logsSubscriptionCounter=0,this._logsSubscriptions={},this._slotUpdateSubscriptionCounter=0,this._slotUpdateSubscriptions={};var n,i,o,a,u,c=new URL(t);c.protocol;r&&"string"===typeof r?this._commitment=r:r&&(this._commitment=r.commitment,this._confirmTransactionInitialTimeout=r.confirmTransactionInitialTimeout,n=r.wsEndpoint,i=r.httpHeaders,o=r.fetchMiddleware,a=r.disableRetryOnRateLimit),this._rpcEndpoint=t,this._rpcWsEndpoint=n||function(e){var t=new URL(e),r="https:"===t.protocol;return t.protocol=r?"wss:":"ws:",t.host="",""!==t.port&&(t.port=String(Number(t.port)+1)),t.toString()}(t),this._rpcClient=function(e,t,r,n,i){var o;n&&(o=function(e,t){return new Promise((function(r,i){n(e,t,function(){var e=Object(s.a)(p.a.mark((function e(t,n){return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.t0=r,e.next=4,Fr(t,n);case 4:e.t1=e.sent,(0,e.t0)(e.t1),e.next=11;break;case 8:e.prev=8,e.t2=e.catch(0),i(e.t2);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t,r){return e.apply(this,arguments)}}())}))});var a=new A.a(function(){var t=Object(s.a)(p.a.mark((function t(n,a){var u,s,c,f,l;return p.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:u={method:"POST",body:n,agent:void 0,headers:Object.assign({"Content-Type":"application/json"},r||{})},t.prev=2,s=5,f=500;case 5:if(!o){t.next=11;break}return t.next=8,o(e,u);case 8:c=t.sent,t.next=14;break;case 11:return t.next=13,Fr(e,u);case 13:c=t.sent;case 14:if(429===c.status){t.next=16;break}return t.abrupt("break",27);case 16:if(!0!==i){t.next=18;break}return t.abrupt("break",27);case 18:if(0!==(s-=1)){t.next=21;break}return t.abrupt("break",27);case 21:return console.log("Server responded with ".concat(c.status," ").concat(c.statusText,".  Retrying after ").concat(f,"ms delay...")),t.next=24,Or(f);case 24:f*=2;case 25:t.next=5;break;case 27:return t.next=29,c.text();case 29:l=t.sent,c.ok?a(null,l):a(new Error("".concat(c.status," ").concat(c.statusText,": ").concat(l))),t.next=36;break;case 33:t.prev=33,t.t0=t.catch(2),t.t0 instanceof Error&&a(t.t0);case 36:return t.prev=36,t.finish(36);case 38:case"end":return t.stop()}}),t,null,[[2,33,36,38]])})));return function(e,r){return t.apply(this,arguments)}}(),{});return a}(c.toString(),0,i,o,a),this._rpcRequest=(u=this._rpcClient,function(e,t){return new Promise((function(r,n){u.request(e,t,(function(e,t){e?n(e):r(t)}))}))}),this._rpcBatchRequest=function(e){return function(t){return new Promise((function(r,n){0===t.length&&r([]);var i=t.map((function(t){return e.request(t.methodName,t.args)}));e.request(i,(function(e,t){e?n(e):r(t)}))}))}}(this._rpcClient),this._rpcWebSocket=new E.Client(this._rpcWsEndpoint,{autoconnect:!1,max_reconnects:1/0}),this._rpcWebSocket.on("open",this._wsOnOpen.bind(this)),this._rpcWebSocket.on("error",this._wsOnError.bind(this)),this._rpcWebSocket.on("close",this._wsOnClose.bind(this)),this._rpcWebSocket.on("accountNotification",this._wsOnAccountNotification.bind(this)),this._rpcWebSocket.on("programNotification",this._wsOnProgramAccountNotification.bind(this)),this._rpcWebSocket.on("slotNotification",this._wsOnSlotNotification.bind(this)),this._rpcWebSocket.on("slotsUpdatesNotification",this._wsOnSlotUpdatesNotification.bind(this)),this._rpcWebSocket.on("signatureNotification",this._wsOnSignatureNotification.bind(this)),this._rpcWebSocket.on("rootNotification",this._wsOnRootNotification.bind(this)),this._rpcWebSocket.on("logsNotification",this._wsOnLogsNotification.bind(this))}return Object(h.a)(e,[{key:"commitment",get:function(){return this._commitment}},{key:"getBalanceAndContext",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t.toBase58()],r),e.next=3,this._rpcRequest("getBalance",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,Qr(Object(S.j)()))))){e.next=7;break}throw new Error("failed to get balance for "+t.toBase58()+": "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getBalance",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getBalanceAndContext(t,r).then((function(e){return e.value})).catch((function(e){throw new Error("failed to get balance of account "+t.toBase58()+": "+e)}));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getBlockTime",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("getBlockTime",[t]);case 2:if(r=e.sent,!("error"in(n=Object(S.f)(r,$r(Object(S.i)(Object(S.j)())))))){e.next=6;break}throw new Error("failed to get block time for slot "+t+": "+n.error.message);case 6:return e.abrupt("return",n.result);case 7:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getMinimumLedgerSlot",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("minimumLedgerSlot",[]);case 2:if(t=e.sent,!("error"in(r=Object(S.f)(t,$r(Object(S.j)()))))){e.next=6;break}throw new Error("failed to get minimum ledger slot: "+r.error.message);case 6:return e.abrupt("return",r.result);case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getFirstAvailableBlock",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("getFirstAvailableBlock",[]);case 2:if(t=e.sent,!("error"in(r=Object(S.f)(t,vn)))){e.next=6;break}throw new Error("failed to get first available block: "+r.error.message);case 6:return e.abrupt("return",r.result);case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getSupply",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r={},r="string"===typeof t?{commitment:t}:t?Object(a.a)(Object(a.a)({},t),{},{commitment:t&&t.commitment||this.commitment}):{commitment:this.commitment},e.next=4,this._rpcRequest("getSupply",[r]);case 4:if(n=e.sent,!("error"in(i=Object(S.f)(n,yn)))){e.next=8;break}throw new Error("failed to get supply: "+i.error.message);case 8:return e.abrupt("return",i.result);case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getTokenSupply",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t.toBase58()],r),e.next=3,this._rpcRequest("getTokenSupply",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,Qr(mn))))){e.next=7;break}throw new Error("failed to get token supply: "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getTokenAccountBalance",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t.toBase58()],r),e.next=3,this._rpcRequest("getTokenAccountBalance",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,Qr(mn))))){e.next=7;break}throw new Error("failed to get token account balance: "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getTokenAccountsByOwner",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a,u;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=[t.toBase58()],"mint"in r?i.push({mint:r.mint.toBase58()}):i.push({programId:r.programId.toBase58()}),o=this._buildArgs(i,n,"base64"),e.next=5,this._rpcRequest("getTokenAccountsByOwner",o);case 5:if(a=e.sent,!("error"in(u=Object(S.f)(a,wn)))){e.next=9;break}throw new Error("failed to get token accounts owned by account "+t.toBase58()+": "+u.error.message);case 9:return e.abrupt("return",u.result);case 10:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getParsedTokenAccountsByOwner",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a,u;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=[t.toBase58()],"mint"in r?i.push({mint:r.mint.toBase58()}):i.push({programId:r.programId.toBase58()}),o=this._buildArgs(i,n,"jsonParsed"),e.next=5,this._rpcRequest("getTokenAccountsByOwner",o);case 5:if(a=e.sent,!("error"in(u=Object(S.f)(a,_n)))){e.next=9;break}throw new Error("failed to get token accounts owned by account "+t.toBase58()+": "+u.error.message);case 9:return e.abrupt("return",u.result);case 10:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getLargestAccounts",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=Object(a.a)(Object(a.a)({},t),{},{commitment:t&&t.commitment||this.commitment}),n=r.filter||r.commitment?[r]:[],e.next=4,this._rpcRequest("getLargestAccounts",n);case 4:if(i=e.sent,!("error"in(o=Object(S.f)(i,xn)))){e.next=8;break}throw new Error("failed to get largest accounts: "+o.error.message);case 8:return e.abrupt("return",o.result);case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getTokenLargestAccounts",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t.toBase58()],r),e.next=3,this._rpcRequest("getTokenLargestAccounts",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,gn)))){e.next=7;break}throw new Error("failed to get token largest accounts: "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getAccountInfoAndContext",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t.toBase58()],r,"base64"),e.next=3,this._rpcRequest("getAccountInfo",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,Qr(Object(S.i)(Sn)))))){e.next=7;break}throw new Error("failed to get info about account "+t.toBase58()+": "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getParsedAccountInfo",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t.toBase58()],r,"jsonParsed"),e.next=3,this._rpcRequest("getAccountInfo",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,Qr(Object(S.i)(An)))))){e.next=7;break}throw new Error("failed to get info about account "+t.toBase58()+": "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getAccountInfo",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.getAccountInfoAndContext(t,r);case 3:return n=e.sent,e.abrupt("return",n.value);case 7:throw e.prev=7,e.t0=e.catch(0),new Error("failed to get info about account "+t.toBase58()+": "+e.t0);case 10:case"end":return e.stop()}}),e,this,[[0,7]])})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getMultipleAccountsInfo",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.map((function(e){return e.toBase58()})),i=this._buildArgs([n],r,"base64"),e.next=4,this._rpcRequest("getMultipleAccounts",i);case 4:if(o=e.sent,!("error"in(a=Object(S.f)(o,Qr(Object(S.b)(Object(S.i)(Sn))))))){e.next=8;break}throw new Error("failed to get info for accounts "+n+": "+a.error.message);case 8:return e.abrupt("return",a.result.value);case 9:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getStakeActivation",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=this._buildArgs([t.toBase58()],r,void 0,void 0!==n?{epoch:n}:void 0),e.next=3,this._rpcRequest("getStakeActivation",i);case 3:if(o=e.sent,!("error"in(a=Object(S.f)(o,$r(jn))))){e.next=7;break}throw new Error("failed to get Stake Activation ".concat(t.toBase58(),": ").concat(a.error.message));case 7:return e.abrupt("return",a.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getProgramAccounts",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a,u,s;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n={},r&&("string"===typeof r?i=r:(i=r.commitment,o=r.encoding,r.dataSlice&&(n.dataSlice=r.dataSlice),r.filters&&(n.filters=r.filters))),a=this._buildArgs([t.toBase58()],i,o||"base64",n),e.next=5,this._rpcRequest("getProgramAccounts",a);case 5:if(u=e.sent,!("error"in(s=Object(S.f)(u,$r(Object(S.b)(En)))))){e.next=9;break}throw new Error("failed to get accounts owned by program "+t.toBase58()+": "+s.error.message);case 9:return e.abrupt("return",s.result);case 10:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getParsedProgramAccounts",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a,u;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n={},r&&("string"===typeof r?i=r:(i=r.commitment,r.filters&&(n.filters=r.filters))),o=this._buildArgs([t.toBase58()],i,"jsonParsed",n),e.next=5,this._rpcRequest("getProgramAccounts",o);case 5:if(a=e.sent,!("error"in(u=Object(S.f)(a,$r(Object(S.b)(Mn)))))){e.next=9;break}throw new Error("failed to get accounts owned by program "+t.toBase58()+": "+u.error.message);case 9:return e.abrupt("return",u.result);case 10:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"confirmTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a,u,s,c,f,l=this;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:e.prev=0,n=k.a.decode(t),e.next=7;break;case 4:throw e.prev=4,e.t0=e.catch(0),new Error("signature must be base58 encoded: "+t);case 7:dr(64===n.length,"signature has invalid length"),i=Date.now(),o=r||this.commitment,u=null,s=new Promise((function(e,r){try{a=l.onSignature(t,(function(t,r){a=void 0,u={context:r,value:t},e(null)}),o)}catch(n){r(n)}})),c=this._confirmTransactionInitialTimeout||6e4,e.t1=o,e.next="processed"===e.t1||"recent"===e.t1||"single"===e.t1||"confirmed"===e.t1||"singleGossip"===e.t1?16:18;break;case 16:return c=this._confirmTransactionInitialTimeout||3e4,e.abrupt("break",18);case 18:return e.prev=18,e.next=21,Kr(s,c);case 21:return e.prev=21,a&&this.removeSignatureListener(a),e.finish(21);case 24:if(null!==u){e.next=27;break}throw f=(Date.now()-i)/1e3,new Error("Transaction was not confirmed in ".concat(f.toFixed(2)," seconds. It is unknown if it succeeded or failed. Check signature ").concat(t," using the Solana Explorer or CLI tools."));case 27:return e.abrupt("return",u);case 28:case"end":return e.stop()}}),e,this,[[0,4],[18,,21,24]])})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getClusterNodes",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("getClusterNodes",[]);case 2:if(t=e.sent,!("error"in(r=Object(S.f)(t,$r(Object(S.b)(Fn)))))){e.next=6;break}throw new Error("failed to get cluster nodes: "+r.error.message);case 6:return e.abrupt("return",r.result);case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getVoteAccounts",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs([],t),e.next=3,this._rpcRequest("getVoteAccounts",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,Hn)))){e.next=7;break}throw new Error("failed to get vote accounts: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getSlot",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs([],t),e.next=3,this._rpcRequest("getSlot",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,$r(Object(S.j)()))))){e.next=7;break}throw new Error("failed to get slot: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getSlotLeader",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs([],t),e.next=3,this._rpcRequest("getSlotLeader",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,$r(Object(S.m)()))))){e.next=7;break}throw new Error("failed to get slot leader: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getSlotLeaders",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=[t,r],e.next=3,this._rpcRequest("getSlotLeaders",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,$r(Object(S.b)(Vr)))))){e.next=7;break}throw new Error("failed to get slot leaders: "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getSignatureStatus",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getSignatureStatuses([t],r);case 2:return n=e.sent,i=n.context,dr(1===(o=n.value).length),a=o[0],e.abrupt("return",{context:i,value:a});case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getSignatureStatuses",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=[t],r&&n.push(r),e.next=4,this._rpcRequest("getSignatureStatuses",n);case 4:if(i=e.sent,!("error"in(o=Object(S.f)(i,Vn)))){e.next=8;break}throw new Error("failed to get signature status: "+o.error.message);case 8:return e.abrupt("return",o.result);case 9:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getTransactionCount",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs([],t),e.next=3,this._rpcRequest("getTransactionCount",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,$r(Object(S.j)()))))){e.next=7;break}throw new Error("failed to get transaction count: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getTotalSupply",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getSupply({commitment:t,excludeNonCirculatingAccountsList:!0});case 2:return r=e.sent,e.abrupt("return",r.value.total);case 4:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getInflationGovernor",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs([],t),e.next=3,this._rpcRequest("getInflationGovernor",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,hn)))){e.next=7;break}throw new Error("failed to get inflation: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getInflationReward",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=this._buildArgs([t.map((function(e){return e.toBase58()}))],n,void 0,{epoch:r}),e.next=3,this._rpcRequest("getInflationReward",i);case 3:if(o=e.sent,!("error"in(a=Object(S.f)(o,rn)))){e.next=7;break}throw new Error("failed to get inflation reward: "+a.error.message);case 7:return e.abrupt("return",a.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getEpochInfo",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs([],t),e.next=3,this._rpcRequest("getEpochInfo",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,dn)))){e.next=7;break}throw new Error("failed to get epoch info: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getEpochSchedule",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r,n;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("getEpochSchedule",[]);case 2:if(t=e.sent,!("error"in(r=Object(S.f)(t,pn)))){e.next=6;break}throw new Error("failed to get epoch schedule: "+r.error.message);case 6:return n=r.result,e.abrupt("return",new Hr(n.slotsPerEpoch,n.leaderScheduleSlotOffset,n.warmup,n.firstNormalEpoch,n.firstNormalSlot));case 8:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getLeaderSchedule",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("getLeaderSchedule",[]);case 2:if(t=e.sent,!("error"in(r=Object(S.f)(t,bn)))){e.next=6;break}throw new Error("failed to get leader schedule: "+r.error.message);case 6:return e.abrupt("return",r.result);case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getMinimumBalanceForRentExemption",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t],r),e.next=3,this._rpcRequest("getMinimumBalanceForRentExemption",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,Zn)))){e.next=8;break}return console.warn("Unable to fetch minimum balance for rent exemption"),e.abrupt("return",0);case 8:return e.abrupt("return",o.result);case 9:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getRecentBlockhashAndContext",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs([],t),e.next=3,this._rpcRequest("getRecentBlockhash",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,si)))){e.next=7;break}throw new Error("failed to get recent blockhash: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getRecentPerformanceSamples",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=this._buildArgs(t?[t]:[]),e.next=3,this._rpcRequest("getRecentPerformanceSamples",r);case 3:if(n=e.sent,!("error"in(i=Object(S.f)(n,fi)))){e.next=7;break}throw new Error("failed to get recent performance samples: "+i.error.message);case 7:return e.abrupt("return",i.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"getFeeCalculatorForBlockhash",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a,u,s;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgs([t],r),e.next=3,this._rpcRequest("getFeeCalculatorForBlockhash",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,li)))){e.next=7;break}throw new Error("failed to get fee calculator: "+o.error.message);case 7:return a=o.result,u=a.context,s=a.value,e.abrupt("return",{context:u,value:null!==s?s.feeCalculator:null});case 9:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getRecentBlockhash",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,this.getRecentBlockhashAndContext(t);case 3:return r=e.sent,e.abrupt("return",r.value);case 7:throw e.prev=7,e.t0=e.catch(0),new Error("failed to get recent blockhash: "+e.t0);case 10:case"end":return e.stop()}}),e,this,[[0,7]])})));return function(t){return e.apply(this,arguments)}}()},{key:"getVersion",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("getVersion",[]);case 2:if(t=e.sent,!("error"in(r=Object(S.f)(t,$r(fn))))){e.next=6;break}throw new Error("failed to get version: "+r.error.message);case 6:return e.abrupt("return",r.result);case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getGenesisHash",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("getGenesisHash",[]);case 2:if(t=e.sent,!("error"in(r=Object(S.f)(t,$r(Object(S.m)()))))){e.next=6;break}throw new Error("failed to get genesis hash: "+r.error.message);case 6:return e.abrupt("return",r.result);case 7:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"getBlock",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,u;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgsAtLeastConfirmed([t],r&&r.commitment),e.next=3,this._rpcRequest("getConfirmedBlock",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,ii)))){e.next=7;break}throw new Error("failed to get confirmed block: "+o.error.message);case 7:if(u=o.result){e.next=10;break}return e.abrupt("return",u);case 10:return e.abrupt("return",Object(a.a)(Object(a.a)({},u),{},{transactions:u.transactions.map((function(e){var t=e.transaction,r=e.meta,n=new hr(t.message);return{meta:r,transaction:Object(a.a)(Object(a.a)({},t),{},{message:n})}}))}));case 11:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,u;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgsAtLeastConfirmed([t],r&&r.commitment),e.next=3,this._rpcRequest("getConfirmedTransaction",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,ai)))){e.next=7;break}throw new Error("failed to get confirmed transaction: "+o.error.message);case 7:if(u=o.result){e.next=10;break}return e.abrupt("return",u);case 10:return e.abrupt("return",Object(a.a)(Object(a.a)({},u),{},{transaction:Object(a.a)(Object(a.a)({},u.transaction),{},{message:new hr(u.transaction.message)})}));case 11:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getConfirmedBlock",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getBlock(t,{commitment:r});case 2:if(n=e.sent){e.next=5;break}throw new Error("Confirmed block "+t+" not found");case 5:return e.abrupt("return",Object(a.a)(Object(a.a)({},n),{},{transactions:n.transactions.map((function(e){var t=e.transaction;return{meta:e.meta,transaction:yr.populate(t.message,t.signatures)}}))}));case 6:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getBlocks",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=this._buildArgsAtLeastConfirmed(void 0!==r?[t,r]:[t],n),e.next=3,this._rpcRequest("getConfirmedBlocks",i);case 3:if(o=e.sent,!("error"in(a=Object(S.f)(o,$r(Object(S.b)(Object(S.j)())))))){e.next=7;break}throw new Error("failed to get blocks: "+a.error.message);case 7:return e.abrupt("return",a.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getConfirmedBlockSignatures",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgsAtLeastConfirmed([t],r,void 0,{transactionDetails:"signatures",rewards:!1}),e.next=3,this._rpcRequest("getConfirmedBlock",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,oi)))){e.next=7;break}throw new Error("failed to get confirmed block: "+o.error.message);case 7:if(a=o.result){e.next=10;break}throw new Error("Confirmed block "+t+" not found");case 10:return e.abrupt("return",a);case 11:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getConfirmedTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,u;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getTransaction(t,{commitment:r});case 2:if(n=e.sent){e.next=5;break}return e.abrupt("return",n);case 5:return i=n.transaction,o=i.message,u=i.signatures,e.abrupt("return",Object(a.a)(Object(a.a)({},n),{},{transaction:yr.populate(o,u)}));case 7:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getParsedConfirmedTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this._buildArgsAtLeastConfirmed([t],r,"jsonParsed"),e.next=3,this._rpcRequest("getConfirmedTransaction",n);case 3:if(i=e.sent,!("error"in(o=Object(S.f)(i,ui)))){e.next=7;break}throw new Error("failed to get confirmed transaction: "+o.error.message);case 7:return e.abrupt("return",o.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getParsedConfirmedTransactions",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a=this;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=t.map((function(e){return{methodName:"getConfirmedTransaction",args:a._buildArgsAtLeastConfirmed([e],r,"jsonParsed")}})),e.next=3,this._rpcBatchRequest(n);case 3:return i=e.sent,o=i.map((function(e){var t=Object(S.f)(e,ui);if("error"in t)throw new Error("failed to get confirmed transactions: "+t.error.message);return t.result})),e.abrupt("return",o);case 6:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getConfirmedSignaturesForAddress",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a,u,s,c;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i={},e.next=3,this.getFirstAvailableBlock();case 3:o=e.sent;case 4:if("until"in i){e.next=24;break}if(!(--r<=0||r<o)){e.next=8;break}return e.abrupt("break",24);case 8:return e.prev=8,e.next=11,this.getConfirmedBlockSignatures(r,"finalized");case 11:(a=e.sent).signatures.length>0&&(i.until=a.signatures[a.signatures.length-1].toString()),e.next=22;break;case 15:if(e.prev=15,e.t0=e.catch(8),!(e.t0 instanceof Error&&e.t0.message.includes("skipped"))){e.next=21;break}return e.abrupt("continue",4);case 21:throw e.t0;case 22:e.next=4;break;case 24:return e.next=26,this.getSlot("finalized");case 26:u=e.sent;case 27:if("before"in i){e.next=47;break}if(!(++n>u)){e.next=31;break}return e.abrupt("break",47);case 31:return e.prev=31,e.next=34,this.getConfirmedBlockSignatures(n);case 34:(s=e.sent).signatures.length>0&&(i.before=s.signatures[s.signatures.length-1].toString()),e.next=45;break;case 38:if(e.prev=38,e.t1=e.catch(31),!(e.t1 instanceof Error&&e.t1.message.includes("skipped"))){e.next=44;break}return e.abrupt("continue",27);case 44:throw e.t1;case 45:e.next=27;break;case 47:return e.next=49,this.getConfirmedSignaturesForAddress2(t,i);case 49:return c=e.sent,e.abrupt("return",c.map((function(e){return e.signature})));case 51:case"end":return e.stop()}}),e,this,[[8,15],[31,38]])})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getConfirmedSignaturesForAddress2",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=this._buildArgsAtLeastConfirmed([t.toBase58()],n,void 0,r),e.next=3,this._rpcRequest("getConfirmedSignaturesForAddress2",i);case 3:if(o=e.sent,!("error"in(a=Object(S.f)(o,In)))){e.next=7;break}throw new Error("failed to get confirmed signatures for address: "+a.error.message);case 7:return e.abrupt("return",a.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getSignaturesForAddress",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=this._buildArgsAtLeastConfirmed([t.toBase58()],n,void 0,r),e.next=3,this._rpcRequest("getSignaturesForAddress",i);case 3:if(o=e.sent,!("error"in(a=Object(S.f)(o,Pn)))){e.next=7;break}throw new Error("failed to get signatures for address: "+a.error.message);case 7:return e.abrupt("return",a.result);case 8:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"getNonceAndContext",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getAccountInfoAndContext(t,r);case 2:return n=e.sent,i=n.context,o=n.value,a=null,null!==o&&(a=Rr.fromAccountData(o.data)),e.abrupt("return",{context:i,value:a});case 8:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"getNonce",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.getNonceAndContext(t,r).then((function(e){return e.value})).catch((function(e){throw new Error("failed to get nonce for account "+t.toBase58()+": "+e)}));case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"requestAirdrop",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._rpcRequest("requestAirdrop",[t.toBase58(),r]);case 2:if(n=e.sent,!("error"in(i=Object(S.f)(n,hi)))){e.next=6;break}throw new Error("airdrop to "+t.toBase58()+" failed: "+i.error.message);case 6:return e.abrupt("return",i.result);case 7:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"_recentBlockhash",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r,n;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t){e.next=10;break}case 1:if(!this._pollingBlockhash){e.next=6;break}return e.next=4,Or(100);case 4:e.next=1;break;case 6:if(r=Date.now()-this._blockhashInfo.lastFetch,n=r>=Xr,null===this._blockhashInfo.recentBlockhash||n){e.next=10;break}return e.abrupt("return",this._blockhashInfo.recentBlockhash);case 10:return e.next=12,this._pollNewBlockhash();case 12:return e.abrupt("return",e.sent);case 13:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_pollNewBlockhash",value:function(){var e=Object(s.a)(p.a.mark((function e(){var t,r,n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this._pollingBlockhash=!0,e.prev=1,t=Date.now(),r=0;case 4:if(!(r<50)){e.next=17;break}return e.next=7,this.getRecentBlockhash("finalized");case 7:if(n=e.sent,i=n.blockhash,this._blockhashInfo.recentBlockhash==i){e.next=12;break}return this._blockhashInfo={recentBlockhash:i,lastFetch:Date.now(),transactionSignatures:[],simulatedSignatures:[]},e.abrupt("return",i);case 12:return e.next=14,Or(200);case 14:r++,e.next=4;break;case 17:throw new Error("Unable to obtain a new blockhash after ".concat(Date.now()-t,"ms"));case 18:return e.prev=18,this._pollingBlockhash=!1,e.finish(18);case 21:case"end":return e.stop()}}),e,this,[[1,,18,21]])})));return function(){return e.apply(this,arguments)}}()},{key:"simulateTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a,s,c,f,l,h,d,b,v,y,m,g,w,k,_;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(i=t instanceof yr?t:yr.populate(t)).nonceInfo||!r){e.next=5;break}(o=i).sign.apply(o,Object(u.a)(r)),e.next=23;break;case 5:a=this._disableBlockhashCaching;case 6:return e.next=8,this._recentBlockhash(a);case 8:if(i.recentBlockhash=e.sent,r){e.next=11;break}return e.abrupt("break",23);case 11:if((s=i).sign.apply(s,Object(u.a)(r)),i.signature){e.next=14;break}throw new Error("!signature");case 14:if(c=i.signature.toString("base64"),this._blockhashInfo.simulatedSignatures.includes(c)||this._blockhashInfo.transactionSignatures.includes(c)){e.next=20;break}return this._blockhashInfo.simulatedSignatures.push(c),e.abrupt("break",23);case 20:a=!0;case 21:e.next=6;break;case 23:return f=i._compile(),l=f.serialize(),h=i._serialize(l),d=h.toString("base64"),b={encoding:"base64",commitment:this.commitment},n&&(v=(Array.isArray(n)?n:f.nonProgramIds()).map((function(e){return e.toBase58()})),b.accounts={encoding:"base64",addresses:v}),r&&(b.sigVerify=!0),y=[d,b],e.next=33,this._rpcRequest("simulateTransaction",y);case 33:if(m=e.sent,!("error"in(g=Object(S.f)(m,ln)))){e.next=38;break}throw"data"in g.error&&(w=g.error.data.logs)&&Array.isArray(w)&&(_=(k="\n    ")+w.join(k),console.error(g.error.message,_)),new Wr("failed to simulate transaction: "+g.error.message,w);case 38:return e.abrupt("return",g.result);case 39:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"sendTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!t.nonceInfo){e.next=4;break}t.sign.apply(t,Object(u.a)(r)),e.next=20;break;case 4:i=this._disableBlockhashCaching;case 5:return e.next=7,this._recentBlockhash(i);case 7:if(t.recentBlockhash=e.sent,t.sign.apply(t,Object(u.a)(r)),t.signature){e.next=11;break}throw new Error("!signature");case 11:if(o=t.signature.toString("base64"),this._blockhashInfo.transactionSignatures.includes(o)){e.next=17;break}return this._blockhashInfo.transactionSignatures.push(o),e.abrupt("break",20);case 17:i=!0;case 18:e.next=5;break;case 20:return a=t.serialize(),e.next=23,this.sendRawTransaction(a,n);case 23:return e.abrupt("return",e.sent);case 24:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"sendRawTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=R(t).toString("base64"),e.next=3,this.sendEncodedTransaction(n,r);case 3:return i=e.sent,e.abrupt("return",i);case 5:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"sendEncodedTransaction",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i,o,a,u,s,c,f,l;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n={encoding:"base64"},i=r&&r.skipPreflight,o=r&&r.preflightCommitment||this.commitment,i&&(n.skipPreflight=i),o&&(n.preflightCommitment=o),a=[t,n],e.next=8,this._rpcRequest("sendTransaction",a);case 8:if(u=e.sent,!("error"in(s=Object(S.f)(u,di)))){e.next=13;break}throw"data"in s.error&&(c=s.error.data.logs)&&Array.isArray(c)&&(l=(f="\n    ")+c.join(f),console.error(s.error.message,l)),new Wr("failed to send transaction: "+s.error.message,c);case 13:return e.abrupt("return",s.result);case 14:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"_wsOnOpen",value:function(){var e=this;this._rpcWebSocketConnected=!0,this._rpcWebSocketHeartbeat=setInterval((function(){e._rpcWebSocket.notify("ping").catch((function(){}))}),5e3),this._updateSubscriptions()}},{key:"_wsOnError",value:function(e){console.error("ws error:",e.message)}},{key:"_wsOnClose",value:function(e){this._rpcWebSocketHeartbeat&&(clearInterval(this._rpcWebSocketHeartbeat),this._rpcWebSocketHeartbeat=null),1e3!==e?this._resetSubscriptions():this._updateSubscriptions()}},{key:"_subscribe",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r,n){var i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null!=t.subscriptionId){e.next=13;break}return t.subscriptionId="subscribing",e.prev=2,e.next=5,this._rpcWebSocket.call(r,n);case 5:"number"===typeof(i=e.sent)&&"subscribing"===t.subscriptionId&&(t.subscriptionId=i),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(2),"subscribing"===t.subscriptionId&&(t.subscriptionId=null),e.t0 instanceof Error&&console.error("".concat(r," error for argument"),n,e.t0.message);case 13:case"end":return e.stop()}}),e,this,[[2,9]])})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"_unsubscribe",value:function(){var e=Object(s.a)(p.a.mark((function e(t,r){var n,i;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null==(n=t.subscriptionId)||"string"==typeof n){e.next=11;break}return i=n,e.prev=3,e.next=6,this._rpcWebSocket.call(r,[i]);case 6:e.next=11;break;case 8:e.prev=8,e.t0=e.catch(3),e.t0 instanceof Error&&console.error("".concat(r," error:"),e.t0.message);case 11:case"end":return e.stop()}}),e,this,[[3,8]])})));return function(t,r){return e.apply(this,arguments)}}()},{key:"_resetSubscriptions",value:function(){Object.values(this._accountChangeSubscriptions).forEach((function(e){return e.subscriptionId=null})),Object.values(this._programAccountChangeSubscriptions).forEach((function(e){return e.subscriptionId=null})),Object.values(this._rootSubscriptions).forEach((function(e){return e.subscriptionId=null})),Object.values(this._signatureSubscriptions).forEach((function(e){return e.subscriptionId=null})),Object.values(this._slotSubscriptions).forEach((function(e){return e.subscriptionId=null})),Object.values(this._slotUpdateSubscriptions).forEach((function(e){return e.subscriptionId=null}))}},{key:"_updateSubscriptions",value:function(){var e=this,t=Object.keys(this._accountChangeSubscriptions).map(Number),r=Object.keys(this._programAccountChangeSubscriptions).map(Number),n=Object.keys(this._slotSubscriptions).map(Number),o=Object.keys(this._slotUpdateSubscriptions).map(Number),a=Object.keys(this._signatureSubscriptions).map(Number),u=Object.keys(this._rootSubscriptions).map(Number),s=Object.keys(this._logsSubscriptions).map(Number);if(0!==t.length||0!==r.length||0!==n.length||0!==o.length||0!==a.length||0!==u.length||0!==s.length)if(null!==this._rpcWebSocketIdleTimeout&&(clearTimeout(this._rpcWebSocketIdleTimeout),this._rpcWebSocketIdleTimeout=null,this._rpcWebSocketConnected=!0),this._rpcWebSocketConnected){var c,f=Object(i.a)(t);try{for(f.s();!(c=f.n()).done;){var l=c.value,h=this._accountChangeSubscriptions[l];this._subscribe(h,"accountSubscribe",this._buildArgs([h.publicKey],h.commitment,"base64"))}}catch(N){f.e(N)}finally{f.f()}var d,p=Object(i.a)(r);try{for(p.s();!(d=p.n()).done;){var b=d.value,v=this._programAccountChangeSubscriptions[b];this._subscribe(v,"programSubscribe",this._buildArgs([v.programId],v.commitment,"base64",{filters:v.filters}))}}catch(N){p.e(N)}finally{p.f()}var y,m=Object(i.a)(n);try{for(m.s();!(y=m.n()).done;){var g=y.value,w=this._slotSubscriptions[g];this._subscribe(w,"slotSubscribe",[])}}catch(N){m.e(N)}finally{m.f()}var k,_=Object(i.a)(o);try{for(_.s();!(k=_.n()).done;){var x=k.value,S=this._slotUpdateSubscriptions[x];this._subscribe(S,"slotsUpdatesSubscribe",[])}}catch(N){_.e(N)}finally{_.f()}var E,O=Object(i.a)(a);try{for(O.s();!(E=O.n()).done;){var A=E.value,M=this._signatureSubscriptions[A],j=[M.signature];M.options&&j.push(M.options),this._subscribe(M,"signatureSubscribe",j)}}catch(N){O.e(N)}finally{O.f()}var I,P=Object(i.a)(u);try{for(P.s();!(I=P.n()).done;){var R=I.value,C=this._rootSubscriptions[R];this._subscribe(C,"rootSubscribe",[])}}catch(N){P.e(N)}finally{P.f()}var T,B=Object(i.a)(s);try{for(B.s();!(T=B.n()).done;){var L=T.value,z=this._logsSubscriptions[L],U=void 0;U="object"===typeof z.filter?{mentions:[z.filter.toString()]}:z.filter,this._subscribe(z,"logsSubscribe",this._buildArgs([U],z.commitment))}}catch(N){B.e(N)}finally{B.f()}}else this._rpcWebSocket.connect();else this._rpcWebSocketConnected&&(this._rpcWebSocketConnected=!1,this._rpcWebSocketIdleTimeout=setTimeout((function(){e._rpcWebSocketIdleTimeout=null,e._rpcWebSocket.close()}),500))}},{key:"_wsOnAccountNotification",value:function(e){for(var t=Object(S.f)(e,Rn),r=0,n=Object.values(this._accountChangeSubscriptions);r<n.length;r++){var i=n[r];if(i.subscriptionId===t.subscription)return void i.callback(t.result.value,t.result.context)}}},{key:"onAccountChange",value:function(e,t,r){var n=++this._accountChangeSubscriptionCounter;return this._accountChangeSubscriptions[n]={publicKey:e.toBase58(),callback:t,commitment:r,subscriptionId:null},this._updateSubscriptions(),n}},{key:"removeAccountChangeListener",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._accountChangeSubscriptions[t]){e.next=8;break}return r=this._accountChangeSubscriptions[t],delete this._accountChangeSubscriptions[t],e.next=5,this._unsubscribe(r,"accountUnsubscribe");case 5:this._updateSubscriptions(),e.next=9;break;case 8:throw new Error("Unknown account change id: ".concat(t));case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_wsOnProgramAccountNotification",value:function(e){for(var t=Object(S.f)(e,Tn),r=0,n=Object.values(this._programAccountChangeSubscriptions);r<n.length;r++){var i=n[r];if(i.subscriptionId===t.subscription){var o=t.result,a=o.value,u=o.context;return void i.callback({accountId:a.pubkey,accountInfo:a.account},u)}}}},{key:"onProgramAccountChange",value:function(e,t,r,n){var i=++this._programAccountChangeSubscriptionCounter;return this._programAccountChangeSubscriptions[i]={programId:e.toBase58(),callback:t,commitment:r,subscriptionId:null,filters:n},this._updateSubscriptions(),i}},{key:"removeProgramAccountChangeListener",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._programAccountChangeSubscriptions[t]){e.next=8;break}return r=this._programAccountChangeSubscriptions[t],delete this._programAccountChangeSubscriptions[t],e.next=5,this._unsubscribe(r,"programUnsubscribe");case 5:this._updateSubscriptions(),e.next=9;break;case 8:throw new Error("Unknown program account change id: ".concat(t));case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"onLogs",value:function(e,t,r){var n=++this._logsSubscriptionCounter;return this._logsSubscriptions[n]={filter:e,callback:t,commitment:r,subscriptionId:null},this._updateSubscriptions(),n}},{key:"removeOnLogsListener",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(this._logsSubscriptions[t]){e.next=2;break}throw new Error("Unknown logs id: ".concat(t));case 2:return r=this._logsSubscriptions[t],delete this._logsSubscriptions[t],e.next=6,this._unsubscribe(r,"logsUnsubscribe");case 6:this._updateSubscriptions();case 7:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_wsOnLogsNotification",value:function(e){var t,r=Object(S.f)(e,bi),n=Object.keys(this._logsSubscriptions).map(Number),o=Object(i.a)(n);try{for(o.s();!(t=o.n()).done;){var a=t.value,u=this._logsSubscriptions[a];if(u.subscriptionId===r.subscription)return void u.callback(r.result.value,r.result.context)}}catch(s){o.e(s)}finally{o.f()}}},{key:"_wsOnSlotNotification",value:function(e){for(var t=Object(S.f)(e,Ln),r=0,n=Object.values(this._slotSubscriptions);r<n.length;r++){var i=n[r];if(i.subscriptionId===t.subscription)return void i.callback(t.result)}}},{key:"onSlotChange",value:function(e){var t=++this._slotSubscriptionCounter;return this._slotSubscriptions[t]={callback:e,subscriptionId:null},this._updateSubscriptions(),t}},{key:"removeSlotChangeListener",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._slotSubscriptions[t]){e.next=8;break}return r=this._slotSubscriptions[t],delete this._slotSubscriptions[t],e.next=5,this._unsubscribe(r,"slotUnsubscribe");case 5:this._updateSubscriptions(),e.next=9;break;case 8:throw new Error("Unknown slot change id: ".concat(t));case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_wsOnSlotUpdatesNotification",value:function(e){for(var t=Object(S.f)(e,Un),r=0,n=Object.values(this._slotUpdateSubscriptions);r<n.length;r++){var i=n[r];if(i.subscriptionId===t.subscription)return void i.callback(t.result)}}},{key:"onSlotUpdate",value:function(e){var t=++this._slotUpdateSubscriptionCounter;return this._slotUpdateSubscriptions[t]={callback:e,subscriptionId:null},this._updateSubscriptions(),t}},{key:"removeSlotUpdateListener",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._slotUpdateSubscriptions[t]){e.next=8;break}return r=this._slotUpdateSubscriptions[t],delete this._slotUpdateSubscriptions[t],e.next=5,this._unsubscribe(r,"slotsUpdatesUnsubscribe");case 5:this._updateSubscriptions(),e.next=9;break;case 8:throw new Error("Unknown slot update id: ".concat(t));case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_buildArgs",value:function(e,t,r,n){var i=t||this._commitment;if(i||r||n){var o={};r&&(o.encoding=r),i&&(o.commitment=i),n&&(o=Object.assign(o,n)),e.push(o)}return e}},{key:"_buildArgsAtLeastConfirmed",value:function(e,t,r,n){var i=t||this._commitment;if(i&&!["confirmed","finalized"].includes(i))throw new Error("Using Connection with default commitment: `"+this._commitment+"`, but method requires at least `confirmed`");return this._buildArgs(e,t,r,n)}},{key:"_wsOnSignatureNotification",value:function(e){for(var t=Object(S.f)(e,Nn),r=0,n=Object.entries(this._signatureSubscriptions);r<n.length;r++){var i=Object(o.a)(n[r],2),a=i[0],u=i[1];if(u.subscriptionId===t.subscription)return void("receivedSignature"===t.result.value?u.callback({type:"received"},t.result.context):(delete this._signatureSubscriptions[Number(a)],this._updateSubscriptions(),u.callback({type:"status",result:t.result.value},t.result.context)))}}},{key:"onSignature",value:function(e,t,r){var n=++this._signatureSubscriptionCounter;return this._signatureSubscriptions[n]={signature:e,callback:function(e,r){"status"===e.type&&t(e.result,r)},options:{commitment:r},subscriptionId:null},this._updateSubscriptions(),n}},{key:"onSignatureWithOptions",value:function(e,t,r){var n=++this._signatureSubscriptionCounter;return this._signatureSubscriptions[n]={signature:e,callback:t,options:r,subscriptionId:null},this._updateSubscriptions(),n}},{key:"removeSignatureListener",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._signatureSubscriptions[t]){e.next=8;break}return r=this._signatureSubscriptions[t],delete this._signatureSubscriptions[t],e.next=5,this._unsubscribe(r,"signatureUnsubscribe");case 5:this._updateSubscriptions(),e.next=9;break;case 8:throw new Error("Unknown signature result id: ".concat(t));case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"_wsOnRootNotification",value:function(e){for(var t=Object(S.f)(e,Dn),r=0,n=Object.values(this._rootSubscriptions);r<n.length;r++){var i=n[r];if(i.subscriptionId===t.subscription)return void i.callback(t.result)}}},{key:"onRootChange",value:function(e){var t=++this._rootSubscriptionCounter;return this._rootSubscriptions[t]={callback:e,subscriptionId:null},this._updateSubscriptions(),t}},{key:"removeRootChangeListener",value:function(){var e=Object(s.a)(p.a.mark((function e(t){var r;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this._rootSubscriptions[t]){e.next=8;break}return r=this._rootSubscriptions[t],delete this._rootSubscriptions[t],e.next=5,this._unsubscribe(r,"rootUnsubscribe");case 5:this._updateSubscriptions(),e.next=9;break;case 8:throw new Error("Unknown root change id: ".concat(t));case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()}]),e}(),yi=function(){function e(t){Object(l.a)(this,e),this._keypair=void 0,this._keypair=t||v.a.sign.keyPair()}return Object(h.a)(e,[{key:"publicKey",get:function(){return new er(this._keypair.publicKey)}},{key:"secretKey",get:function(){return this._keypair.secretKey}}],[{key:"generate",value:function(){return new e(v.a.sign.keyPair())}},{key:"fromSecretKey",value:function(t,r){var n=v.a.sign.keyPair.fromSecretKey(t);if(!r||!r.skipValidation){var i=(new TextEncoder).encode("@solana/web3.js-validation-v1"),o=v.a.sign.detached(i,n.secretKey);if(!v.a.sign.detached.verify(i,o,n.publicKey))throw new Error("provided secretKey is invalid")}return new e(n)}},{key:"fromSeed",value:function(t){return new e(v.a.sign.keyPair.fromSeed(t))}}]),e}(),mi=x.struct([x.u8("numSignatures"),x.u8("padding"),x.u16("signatureOffset"),x.u16("signatureInstructionIndex"),x.u16("publicKeyOffset"),x.u16("publicKeyInstructionIndex"),x.u16("messageDataOffset"),x.u16("messageDataSize"),x.u16("messageInstructionIndex")]),gi=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"createInstructionWithPublicKey",value:function(t){var r=t.publicKey,n=t.message,i=t.signature,o=t.instructionIndex;dr(32===r.length,"Public Key must be ".concat(32," bytes but received ").concat(r.length," bytes")),dr(64===i.length,"Signature must be ".concat(64," bytes but received ").concat(i.length," bytes"));var a=mi.span,u=a+r.length,s=u+i.length,c=y.Buffer.alloc(s+n.length);return mi.encode({numSignatures:1,padding:0,signatureOffset:u,signatureInstructionIndex:o,publicKeyOffset:a,publicKeyInstructionIndex:o,messageDataOffset:s,messageDataSize:n.length,messageInstructionIndex:o},c),c.fill(r,a),c.fill(i,u),c.fill(n,s),new vr({keys:[],programId:e.programId,data:c})}},{key:"createInstructionWithPrivateKey",value:function(e){var t=e.privateKey,r=e.message,n=e.instructionIndex;dr(64===t.length,"Private key must be ".concat(64," bytes but received ").concat(t.length," bytes"));try{var i=yi.fromSecretKey(t),o=i.publicKey.toBytes(),a=v.a.sign.detached(r,i.secretKey);return this.createInstructionWithPublicKey({publicKey:o,message:r,signature:a,instructionIndex:n})}catch(u){throw new Error("Error creating instruction; ".concat(u))}}}]),e}();gi.programId=new er("Ed25519SigVerify111111111111111111111111111");var wi=new er("StakeConfig11111111111111111111111111111111"),ki=Object(h.a)((function e(t,r){Object(l.a)(this,e),this.staker=void 0,this.withdrawer=void 0,this.staker=t,this.withdrawer=r})),_i=Object(h.a)((function e(t,r,n){Object(l.a)(this,e),this.unixTimestamp=void 0,this.epoch=void 0,this.custodian=void 0,this.unixTimestamp=t,this.epoch=r,this.custodian=n}));_i.default=new _i(0,0,er.default);var xi=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"decodeInstructionType",value:function(e){this.checkProgramId(e.programId);for(var t,r=x.u32("instruction").decode(e.data),n=0,i=Object.entries(Si);n<i.length;n++){var a=Object(o.a)(i[n],2),u=a[0];if(a[1].index==r){t=u;break}}if(!t)throw new Error("Instruction type incorrect; not a StakeInstruction");return t}},{key:"decodeInitialize",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,2);var t=Mr(Si.Initialize,e.data),r=t.authorized,n=t.lockup;return{stakePubkey:e.keys[0].pubkey,authorized:new ki(new er(r.staker),new er(r.withdrawer)),lockup:new _i(n.unixTimestamp,n.epoch,new er(n.custodian))}}},{key:"decodeDelegate",value:function(e){return this.checkProgramId(e.programId),this.checkKeyLength(e.keys,6),Mr(Si.Delegate,e.data),{stakePubkey:e.keys[0].pubkey,votePubkey:e.keys[1].pubkey,authorizedPubkey:e.keys[5].pubkey}}},{key:"decodeAuthorize",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,3);var t=Mr(Si.Authorize,e.data),r=t.newAuthorized,n=t.stakeAuthorizationType,i={stakePubkey:e.keys[0].pubkey,authorizedPubkey:e.keys[2].pubkey,newAuthorizedPubkey:new er(r),stakeAuthorizationType:{index:n}};return e.keys.length>3&&(i.custodianPubkey=e.keys[3].pubkey),i}},{key:"decodeAuthorizeWithSeed",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,2);var t=Mr(Si.AuthorizeWithSeed,e.data),r=t.newAuthorized,n=t.stakeAuthorizationType,i=t.authoritySeed,o=t.authorityOwner,a={stakePubkey:e.keys[0].pubkey,authorityBase:e.keys[1].pubkey,authoritySeed:i,authorityOwner:new er(o),newAuthorizedPubkey:new er(r),stakeAuthorizationType:{index:n}};return e.keys.length>3&&(a.custodianPubkey=e.keys[3].pubkey),a}},{key:"decodeSplit",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,3);var t=Mr(Si.Split,e.data).lamports;return{stakePubkey:e.keys[0].pubkey,splitStakePubkey:e.keys[1].pubkey,authorizedPubkey:e.keys[2].pubkey,lamports:t}}},{key:"decodeMerge",value:function(e){return this.checkProgramId(e.programId),this.checkKeyLength(e.keys,3),Mr(Si.Merge,e.data),{stakePubkey:e.keys[0].pubkey,sourceStakePubKey:e.keys[1].pubkey,authorizedPubkey:e.keys[4].pubkey}}},{key:"decodeWithdraw",value:function(e){this.checkProgramId(e.programId),this.checkKeyLength(e.keys,5);var t=Mr(Si.Withdraw,e.data).lamports,r={stakePubkey:e.keys[0].pubkey,toPubkey:e.keys[1].pubkey,authorizedPubkey:e.keys[4].pubkey,lamports:t};return e.keys.length>5&&(r.custodianPubkey=e.keys[5].pubkey),r}},{key:"decodeDeactivate",value:function(e){return this.checkProgramId(e.programId),this.checkKeyLength(e.keys,3),Mr(Si.Deactivate,e.data),{stakePubkey:e.keys[0].pubkey,authorizedPubkey:e.keys[2].pubkey}}},{key:"checkProgramId",value:function(e){if(!e.equals(Oi.programId))throw new Error("invalid instruction; programId is not StakeProgram")}},{key:"checkKeyLength",value:function(e,t){if(e.length<t)throw new Error("invalid instruction; found ".concat(e.length," keys, expected at least ").concat(t))}}]),e}(),Si=Object.freeze({Initialize:{index:0,layout:x.struct([x.u32("instruction"),function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"authorized";return x.struct([sr("staker"),sr("withdrawer")],e)}(),function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"lockup";return x.struct([x.ns64("unixTimestamp"),x.ns64("epoch"),sr("custodian")],e)}()])},Authorize:{index:1,layout:x.struct([x.u32("instruction"),sr("newAuthorized"),x.u32("stakeAuthorizationType")])},Delegate:{index:2,layout:x.struct([x.u32("instruction")])},Split:{index:3,layout:x.struct([x.u32("instruction"),x.ns64("lamports")])},Withdraw:{index:4,layout:x.struct([x.u32("instruction"),x.ns64("lamports")])},Deactivate:{index:5,layout:x.struct([x.u32("instruction")])},Merge:{index:7,layout:x.struct([x.u32("instruction")])},AuthorizeWithSeed:{index:8,layout:x.struct([x.u32("instruction"),sr("newAuthorized"),x.u32("stakeAuthorizationType"),cr("authoritySeed"),sr("authorityOwner")])}}),Ei=Object.freeze({Staker:{index:0},Withdrawer:{index:1}}),Oi=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"initialize",value:function(e){var t=e.stakePubkey,r=e.authorized,n=e.lockup||_i.default,i=Ar(Si.Initialize,{authorized:{staker:R(r.staker.toBuffer()),withdrawer:R(r.withdrawer.toBuffer())},lockup:{unixTimestamp:n.unixTimestamp,epoch:n.epoch,custodian:R(n.custodian.toBuffer())}}),o={keys:[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:wr,isSigner:!1,isWritable:!1}],programId:this.programId,data:i};return new vr(o)}},{key:"createAccountWithSeed",value:function(e){var t=new yr;t.add(Br.createAccountWithSeed({fromPubkey:e.fromPubkey,newAccountPubkey:e.stakePubkey,basePubkey:e.basePubkey,seed:e.seed,lamports:e.lamports,space:this.space,programId:this.programId}));var r=e.stakePubkey,n=e.authorized,i=e.lockup;return t.add(this.initialize({stakePubkey:r,authorized:n,lockup:i}))}},{key:"createAccount",value:function(e){var t=new yr;t.add(Br.createAccount({fromPubkey:e.fromPubkey,newAccountPubkey:e.stakePubkey,lamports:e.lamports,space:this.space,programId:this.programId}));var r=e.stakePubkey,n=e.authorized,i=e.lockup;return t.add(this.initialize({stakePubkey:r,authorized:n,lockup:i}))}},{key:"delegate",value:function(e){var t=e.stakePubkey,r=e.authorizedPubkey,n=e.votePubkey,i=Ar(Si.Delegate);return(new yr).add({keys:[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:n,isSigner:!1,isWritable:!1},{pubkey:mr,isSigner:!1,isWritable:!1},{pubkey:_r,isSigner:!1,isWritable:!1},{pubkey:wi,isSigner:!1,isWritable:!1},{pubkey:r,isSigner:!0,isWritable:!1}],programId:this.programId,data:i})}},{key:"authorize",value:function(e){var t=e.stakePubkey,r=e.authorizedPubkey,n=e.newAuthorizedPubkey,i=e.stakeAuthorizationType,o=e.custodianPubkey,a=Ar(Si.Authorize,{newAuthorized:R(n.toBuffer()),stakeAuthorizationType:i.index}),u=[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:mr,isSigner:!1,isWritable:!0},{pubkey:r,isSigner:!0,isWritable:!1}];return o&&u.push({pubkey:o,isSigner:!1,isWritable:!1}),(new yr).add({keys:u,programId:this.programId,data:a})}},{key:"authorizeWithSeed",value:function(e){var t=e.stakePubkey,r=e.authorityBase,n=e.authoritySeed,i=e.authorityOwner,o=e.newAuthorizedPubkey,a=e.stakeAuthorizationType,u=e.custodianPubkey,s=Ar(Si.AuthorizeWithSeed,{newAuthorized:R(o.toBuffer()),stakeAuthorizationType:a.index,authoritySeed:n,authorityOwner:R(i.toBuffer())}),c=[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:r,isSigner:!0,isWritable:!1},{pubkey:mr,isSigner:!1,isWritable:!1}];return u&&c.push({pubkey:u,isSigner:!1,isWritable:!1}),(new yr).add({keys:c,programId:this.programId,data:s})}},{key:"split",value:function(e){var t=e.stakePubkey,r=e.authorizedPubkey,n=e.splitStakePubkey,i=e.lamports,o=new yr;o.add(Br.createAccount({fromPubkey:r,newAccountPubkey:n,lamports:0,space:this.space,programId:this.programId}));var a=Ar(Si.Split,{lamports:i});return o.add({keys:[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:n,isSigner:!1,isWritable:!0},{pubkey:r,isSigner:!0,isWritable:!1}],programId:this.programId,data:a})}},{key:"merge",value:function(e){var t=e.stakePubkey,r=e.sourceStakePubKey,n=e.authorizedPubkey,i=Ar(Si.Merge);return(new yr).add({keys:[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:r,isSigner:!1,isWritable:!0},{pubkey:mr,isSigner:!1,isWritable:!1},{pubkey:_r,isSigner:!1,isWritable:!1},{pubkey:n,isSigner:!0,isWritable:!1}],programId:this.programId,data:i})}},{key:"withdraw",value:function(e){var t=e.stakePubkey,r=e.authorizedPubkey,n=e.toPubkey,i=e.lamports,o=e.custodianPubkey,a=Ar(Si.Withdraw,{lamports:i}),u=[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:n,isSigner:!1,isWritable:!0},{pubkey:mr,isSigner:!1,isWritable:!1},{pubkey:_r,isSigner:!1,isWritable:!1},{pubkey:r,isSigner:!0,isWritable:!1}];return o&&u.push({pubkey:o,isSigner:!1,isWritable:!1}),(new yr).add({keys:u,programId:this.programId,data:a})}},{key:"deactivate",value:function(e){var t=e.stakePubkey,r=e.authorizedPubkey,n=Ar(Si.Deactivate);return(new yr).add({keys:[{pubkey:t,isSigner:!1,isWritable:!0},{pubkey:mr,isSigner:!1,isWritable:!1},{pubkey:r,isSigner:!0,isWritable:!1}],programId:this.programId,data:n})}}]),e}();Oi.programId=new er("Stake11111111111111111111111111111111111111"),Oi.space=200;var Ai=j.a.publicKeyCreate,Mi=j.a.ecdsaSign,ji=x.struct([x.u8("numSignatures"),x.u16("signatureOffset"),x.u8("signatureInstructionIndex"),x.u16("ethAddressOffset"),x.u8("ethAddressInstructionIndex"),x.u16("messageDataOffset"),x.u16("messageDataSize"),x.u8("messageInstructionIndex"),x.blob(20,"ethAddress"),x.blob(64,"signature"),x.u8("recoveryId")]),Ii=function(){function e(){Object(l.a)(this,e)}return Object(h.a)(e,null,[{key:"publicKeyToEthAddress",value:function(e){dr(64===e.length,"Public key must be ".concat(64," bytes but received ").concat(e.length," bytes"));try{return y.Buffer.from(P.a.keccak_256.update(R(e)).digest()).slice(-20)}catch(t){throw new Error("Error constructing Ethereum address: ".concat(t))}}},{key:"createInstructionWithPublicKey",value:function(t){var r=t.publicKey,n=t.message,i=t.signature,o=t.recoveryId,a=t.instructionIndex;return e.createInstructionWithEthAddress({ethAddress:e.publicKeyToEthAddress(r),message:n,signature:i,recoveryId:o,instructionIndex:a})}},{key:"createInstructionWithEthAddress",value:function(t){var r,n=t.ethAddress,i=t.message,o=t.signature,a=t.recoveryId,u=t.instructionIndex,s=void 0===u?0:u;dr(20===(r="string"===typeof n?n.startsWith("0x")?y.Buffer.from(n.substr(2),"hex"):y.Buffer.from(n,"hex"):n).length,"Address must be ".concat(20," bytes but received ").concat(r.length," bytes"));var c=12+r.length,f=c+o.length+1,l=y.Buffer.alloc(ji.span+i.length);return ji.encode({numSignatures:1,signatureOffset:c,signatureInstructionIndex:s,ethAddressOffset:12,ethAddressInstructionIndex:s,messageDataOffset:f,messageDataSize:i.length,messageInstructionIndex:s,signature:R(o),ethAddress:R(r),recoveryId:a},l),l.fill(R(i),ji.span),new vr({keys:[],programId:e.programId,data:l})}},{key:"createInstructionWithPrivateKey",value:function(e){var t=e.privateKey,r=e.message,n=e.instructionIndex;dr(32===t.length,"Private key must be ".concat(32," bytes but received ").concat(t.length," bytes"));try{var i=R(t),o=Ai(i,!1).slice(1),a=y.Buffer.from(P.a.keccak_256.update(R(r)).digest()),u=Mi(a,i),s=u.signature,c=u.recid;return this.createInstructionWithPublicKey({publicKey:o,message:r,signature:s,recoveryId:c,instructionIndex:n})}catch(f){throw new Error("Error creating instruction; ".concat(f))}}}]),e}();Ii.programId=new er("KeccakSecp256k11111111111111111111111111111");var Pi=new er("Va1idator1nfo111111111111111111111111111111"),Ri=Object(S.o)({name:Object(S.m)(),website:Object(S.k)(Object(S.m)()),details:Object(S.k)(Object(S.m)()),keybaseUsername:Object(S.k)(Object(S.m)())}),Ci=function(){function e(t,r){Object(l.a)(this,e),this.key=void 0,this.info=void 0,this.key=t,this.info=r}return Object(h.a)(e,null,[{key:"fromConfigData",value:function(t){var r=Object(u.a)(t);if(2!==fr(r))return null;for(var n=[],i=0;i<2;i++){var o=new er(r.slice(0,32)),a=1===(r=r.slice(32)).slice(0,1)[0];r=r.slice(1),n.push({publicKey:o,isSigner:a})}if(n[0].publicKey.equals(Pi)&&n[1].isSigner){var s=cr().decode(y.Buffer.from(r)),c=JSON.parse(s);return Object(S.c)(c,Ri),new e(n[1].publicKey,c)}return null}}]),e}(),Ti=new er("Vote111111111111111111111111111111111111111"),Bi=x.struct([sr("nodePubkey"),sr("authorizedVoterPubkey"),sr("authorizedWithdrawerPubkey"),x.u8("commission"),x.nu64(),x.seq(x.struct([x.nu64("slot"),x.u32("confirmationCount")]),x.offset(x.u32(),-8),"votes"),x.u8("rootSlotValid"),x.nu64("rootSlot"),x.nu64("epoch"),x.nu64("credits"),x.nu64("lastEpochCredits"),x.nu64(),x.seq(x.struct([x.nu64("epoch"),x.nu64("credits"),x.nu64("prevCredits")]),x.offset(x.u32(),-8),"epochCredits")]),Li=function(){function e(t){Object(l.a)(this,e),this.nodePubkey=void 0,this.authorizedVoterPubkey=void 0,this.authorizedWithdrawerPubkey=void 0,this.commission=void 0,this.votes=void 0,this.rootSlot=void 0,this.epoch=void 0,this.credits=void 0,this.lastEpochCredits=void 0,this.epochCredits=void 0,this.nodePubkey=t.nodePubkey,this.authorizedVoterPubkey=t.authorizedVoterPubkey,this.authorizedWithdrawerPubkey=t.authorizedWithdrawerPubkey,this.commission=t.commission,this.votes=t.votes,this.rootSlot=t.rootSlot,this.epoch=t.epoch,this.credits=t.credits,this.lastEpochCredits=t.lastEpochCredits,this.epochCredits=t.epochCredits}return Object(h.a)(e,null,[{key:"fromAccountData",value:function(t){var r=Bi.decode(R(t),0),n=r.rootSlot;return r.rootSlotValid||(n=null),new e({nodePubkey:new er(r.nodePubkey),authorizedVoterPubkey:new er(r.authorizedVoterPubkey),authorizedWithdrawerPubkey:new er(r.authorizedWithdrawerPubkey),commission:r.commission,votes:r.votes,rootSlot:n,epoch:r.epoch,credits:r.credits,lastEpochCredits:r.lastEpochCredits,epochCredits:r.epochCredits})}}]),e}();function zi(e,t,r){return Ui.apply(this,arguments)}function Ui(){return(Ui=Object(s.a)(p.a.mark((function e(t,r,n){var i,o,a;return p.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=n&&{skipPreflight:n.skipPreflight,preflightCommitment:n.preflightCommitment||n.commitment},e.next=3,t.sendRawTransaction(r,i);case 3:return o=e.sent,e.next=6,t.confirmTransaction(o,n&&n.commitment);case 6:if(!(a=e.sent.value).err){e.next=9;break}throw new Error("Raw transaction ".concat(o," failed (").concat(JSON.stringify(a),")"));case 9:return e.abrupt("return",o);case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var Ni={http:{devnet:"http://api.devnet.solana.com",testnet:"http://api.testnet.solana.com","mainnet-beta":"http://api.mainnet-beta.solana.com"},https:{devnet:"https://api.devnet.solana.com",testnet:"https://api.testnet.solana.com","mainnet-beta":"https://api.mainnet-beta.solana.com"}};function Di(e,t){var r=!1===t?"http":"https";if(!e)return Ni[r].devnet;var n=Ni[r][e];if(!n)throw new Error("Unknown ".concat(r," cluster: ").concat(e));return n}var Fi=1e9}.call(this,r(39))},function(e,t,r){"use strict";r.d(t,"a",(function(){return a}));var n=r(62);var i=r(31),o=r(63);function a(e,t){return Object(n.a)(e)||function(e,t){var r=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,o=[],a=!0,u=!1;try{for(r=r.call(e);!(a=(n=r.next()).done)&&(o.push(n.value),!t||o.length!==t);a=!0);}catch(s){u=!0,i=s}finally{try{a||null==r.return||r.return()}finally{if(u)throw i}}return o}}(e,t)||Object(i.a)(e,t)||Object(o.a)()}},function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(31);function i(e,t){var r="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Object(n.a)(e))||t&&e&&"number"===typeof e.length){r&&(e=r);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,u=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return u=e.done,e},e:function(e){s=!0,a=e},f:function(){try{u||null==r.return||r.return()}finally{if(s)throw a}}}}},function(e,t,r){"use strict";(function(e){var n=r(40).default,i=r(45).default,o=r(41).default,a=r(70).default,u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.map=t.array=t.rustEnum=t.str=t.vecU8=t.tagged=t.vec=t.bool=t.option=t.publicKey=t.i128=t.u128=t.i64=t.u64=t.struct=t.i32=t.u32=t.i16=t.u16=t.i8=t.u8=void 0;var s=r(91),c=r(8),f=u(r(23)),l=r(91);Object.defineProperty(t,"u8",{enumerable:!0,get:function(){return l.u8}}),Object.defineProperty(t,"i8",{enumerable:!0,get:function(){return l.s8}}),Object.defineProperty(t,"u16",{enumerable:!0,get:function(){return l.u16}}),Object.defineProperty(t,"i16",{enumerable:!0,get:function(){return l.s16}}),Object.defineProperty(t,"u32",{enumerable:!0,get:function(){return l.u32}}),Object.defineProperty(t,"i32",{enumerable:!0,get:function(){return l.s32}}),Object.defineProperty(t,"struct",{enumerable:!0,get:function(){return l.struct}});var h=function(t){o(u,t);var r=a(u);function u(e,t,i){var o;return n(this,u),(o=r.call(this,e,i)).blob=s.blob(e),o.signed=t,o}return i(u,[{key:"decode",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=new f.default(this.blob.decode(e,t),10,"le");return this.signed?r.fromTwos(8*this.span).clone():r}},{key:"encode",value:function(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return this.signed&&(t=t.toTwos(8*this.span)),this.blob.encode(t.toArrayLike(e,"le",this.span),r,n)}}]),u}(s.Layout);function d(e){return new h(8,!1,e)}t.u64=d,t.i64=function(e){return new h(8,!0,e)},t.u128=function(e){return new h(16,!1,e)},t.i128=function(e){return new h(16,!0,e)};var p=function(e){o(r,e);var t=a(r);function r(e,i,o,a){var u;return n(this,r),(u=t.call(this,e.span,a)).layout=e,u.decoder=i,u.encoder=o,u}return i(r,[{key:"decode",value:function(e,t){return this.decoder(this.layout.decode(e,t))}},{key:"encode",value:function(e,t,r){return this.layout.encode(this.encoder(e),t,r)}},{key:"getSpan",value:function(e,t){return this.layout.getSpan(e,t)}}]),r}(s.Layout);t.publicKey=function(e){return new p(s.blob(32),(function(e){return new c.PublicKey(e)}),(function(e){return e.toBuffer()}),e)};var b=function(e){o(r,e);var t=a(r);function r(e,i){var o;return n(this,r),(o=t.call(this,-1,i)).layout=e,o.discriminator=s.u8(),o}return i(r,[{key:"encode",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return null===e||void 0===e?this.discriminator.encode(0,t,r):(this.discriminator.encode(1,t,r),this.layout.encode(e,t,r+1)+1)}},{key:"decode",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=this.discriminator.decode(e,t);if(0===r)return null;if(1===r)return this.layout.decode(e,t+1);throw new Error("Invalid option "+this.property)}},{key:"getSpan",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=this.discriminator.decode(e,t);if(0===r)return 1;if(1===r)return this.layout.getSpan(e,t+1)+1;throw new Error("Invalid option "+this.property)}}]),r}(s.Layout);function v(e){if(0===e)return!1;if(1===e)return!0;throw new Error("Invalid bool: "+e)}function y(e){return e?1:0}function m(e){var t=s.u32("length"),r=s.struct([t,s.blob(s.offset(t,-t.span),"data")]);return new p(r,(function(e){return e.data}),(function(e){return{data:e}}),e)}t.option=function(e,t){return new b(e,t)},t.bool=function(e){return new p(s.u8(),v,y,e)},t.vec=function(e,t){var r=s.u32("length"),n=s.struct([r,s.seq(e,s.offset(r,-r.span),"values")]);return new p(n,(function(e){return e.values}),(function(e){return{values:e}}),t)},t.tagged=function(e,t,r){var n=s.struct([d("tag"),t.replicate("data")]);return new p(n,(function(t){var r=t.tag,n=t.data;if(!r.eq(e))throw new Error("Invalid tag, expected: "+e.toString("hex")+", got: "+r.toString("hex"));return n}),(function(t){return{tag:e,data:t}}),r)},t.vecU8=m,t.str=function(t){return new p(m(),(function(e){return e.toString("utf-8")}),(function(t){return e.from(t,"utf-8")}),t)},t.rustEnum=function(e,t){var r=s.union(s.u8(),t);return e.forEach((function(e,t){return r.addVariant(t,e,e.property)})),r},t.array=function(e,t,r){var n=s.struct([s.seq(e,t,"values")]);return new p(n,(function(e){return e.values}),(function(e){return{values:e}}),r)};var g=function(e){o(r,e);var t=a(r);function r(e,i,o){var a;return n(this,r),(a=t.call(this,e.span+i.span,o)).keyLayout=e,a.valueLayout=i,a}return i(r,[{key:"decode",value:function(e,t){return t=t||0,[this.keyLayout.decode(e,t),this.valueLayout.decode(e,t+this.keyLayout.getSpan(e,t))]}},{key:"encode",value:function(e,t,r){r=r||0;var n=this.keyLayout.encode(e[0],t,r);return n+this.valueLayout.encode(e[1],t,r+n)}},{key:"getSpan",value:function(e,t){return this.keyLayout.getSpan(e,t)+this.valueLayout.getSpan(e,t)}}]),r}(s.Layout);t.map=function(e,t,r){var n=s.u32("length"),i=s.struct([n,s.seq(new g(e,t),s.offset(n,-n.span),"values")]);return new p(i,(function(e){var t=e.values;return new Map(t)}),(function(e){return{values:Array.from(e.entries())}}),r)}}).call(this,r(6).Buffer)},function(e,t,r){"use strict";r.d(t,"a",(function(){return a}));var n=r(51);var i=r(65),o=r(31);function a(e){return function(e){if(Array.isArray(e))return Object(n.a)(e)}(e)||Object(i.a)(e)||Object(o.a)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},function(e,t,r){var n=r(112);e.exports=n("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz")},function(e,t,r){"use strict";r.d(t,"a",(function(){return i})),r.d(t,"b",(function(){return o})),r.d(t,"d",(function(){return a})),r.d(t,"c",(function(){return u}));var n=r(8);function i(e){var t=new Map;return e.errors&&e.errors.forEach((function(e){var r,n=null!==(r=e.msg)&&void 0!==r?r:e.name;t.set(e.code,n)})),t}function o(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(e.args.length!=r.length)throw new Error("Invalid argument length");var i={},o=0;return e.args.forEach((function(e){i[e.name]=r[o],o+=1})),i}function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};e.forEach((function(e){if("accounts"in e)a(e.accounts,t[e.name]);else if(void 0===t[e.name])throw new Error("Invalid arguments: ".concat(e.name," not provided."))}))}function u(e){return"string"===typeof e?new n.PublicKey(e):e}},function(e,t,r){"use strict";e.exports=r(157)},function(e,t,r){"use strict";var n=function(e,t){if("string"!==typeof e&&!Array.isArray(e))throw new TypeError("Expected the input to be `string | string[]`");t=Object.assign({pascalCase:!1},t);var r;return e=Array.isArray(e)?e.map((function(e){return e.trim()})).filter((function(e){return e.length})).join("-"):e.trim(),0===e.length?"":1===e.length?t.pascalCase?e.toUpperCase():e.toLowerCase():(e!==e.toLowerCase()&&(e=function(e){for(var t=!1,r=!1,n=!1,i=0;i<e.length;i++){var o=e[i];t&&/[a-zA-Z]/.test(o)&&o.toUpperCase()===o?(e=e.slice(0,i)+"-"+e.slice(i),t=!1,n=r,r=!0,i++):r&&n&&/[a-zA-Z]/.test(o)&&o.toLowerCase()===o?(e=e.slice(0,i-1)+"-"+e.slice(i-1),n=r,r=!1,t=!0):(t=o.toLowerCase()===o&&o.toUpperCase()!==o,n=r,r=o.toUpperCase()===o&&o.toLowerCase()!==o)}return e}(e)),e=e.replace(/^[_.\- ]+/,"").toLowerCase().replace(/[_.\- ]+(\w|$)/g,(function(e,t){return t.toUpperCase()})).replace(/\d+(\w|$)/g,(function(e){return e.toUpperCase()})),r=e,t.pascalCase?r.charAt(0).toUpperCase()+r.slice(1):r)};e.exports=n,e.exports.default=n},function(e,t,r){"use strict";r.d(t,"d",(function(){return f}));var n=r(4),i=r(5),o=r(58),a=r(48),u=r(49),s=r(50),c=r(32);r.d(t,"c",(function(){return c.a})),r.d(t,"b",(function(){return a.b})),r.d(t,"a",(function(){return a.a})),r.d(t,"e",(function(){return s.b}));var f=function(){function e(t){Object(n.a)(this,e),this.instruction=new o.a(t),this.accounts=new a.b(t),this.events=new u.a(t),t.state&&(this.state=new s.a(t))}return Object(i.a)(e,[{key:"sighash",value:function(e,t){return Object(c.b)(e,t)}}]),e}()},function(e,t,r){"use strict";r.d(t,"a",(function(){return s})),r.d(t,"b",(function(){return c}));var n=r(5),i=r(4),o=r(29),a=r(30),u=r(37),s=function(e){Object(o.a)(r,e);var t=Object(a.a)(r);function r(e){var n;return Object(i.a)(this,r),(n=t.call(this,e)).name="IdlError",n}return Object(n.a)(r)}(Object(u.a)(Error)),c=function(e){Object(o.a)(r,e);var t=Object(a.a)(r);function r(e,n){var o;Object(i.a)(this,r);for(var a=arguments.length,u=new Array(a>2?a-2:0),s=2;s<a;s++)u[s-2]=arguments[s];return(o=t.call.apply(t,[this].concat(u))).code=e,o.msg=n,o}return Object(n.a)(r,[{key:"toString",value:function(){return this.msg}}],[{key:"parse",value:function(e,t){var n,i=e.toString().split("custom program error: ");if(2!==i.length)return null;try{n=parseInt(i[1])}catch(a){return null}var o=t.get(n);return void 0!==o||void 0!==(o=f.get(n))?new r(n,o,n+": "+o):null}}]),r}(Object(u.a)(Error)),f=new Map([[100,"8 byte instruction identifier not provided"],[101,"Fallback functions are not supported"],[102,"The program could not deserialize the given instruction"],[103,"The program could not serialize the given instruction"],[120,"The program was compiled without idl instructions"],[121,"The transaction was given an invalid program for the IDL instruction"],[140,"A mut constraint was violated"],[141,"A has_one constraint was violated"],[142,"A signer constraint was violated"],[143,"A raw constraint was violated"],[144,"An owner constraint was violated"],[145,"A rent exempt constraint was violated"],[146,"A seeds constraint was violated"],[147,"An executable constraint was violated"],[148,"A state constraint was violated"],[149,"An associated constraint was violated"],[150,"An associated init constraint was violated"],[151,"A close constraint was violated"],[152,"An address constraint was violated"],[160,"The account discriminator was already set on this account"],[161,"No 8 byte discriminator was found on the account"],[162,"8 byte discriminator did not match what was expected"],[163,"Failed to deserialize the account"],[164,"Failed to serialize the account"],[165,"Not enough account keys given to the instruction"],[166,"The given account is not mutable"],[167,"The given account is not owned by the executing program"],[168,"Program ID was not as expected"],[169,"Program account is not executable"],[170,"The given account did not sign"],[171,"The given account is not owned by the system program"],[180,"The given state account does not have the correct address"],[299,"The API being used is deprecated and should no longer be used"]])},function(module,exports,__webpack_require__){(function(process,global){var __WEBPACK_AMD_DEFINE_RESULT__;(function(){"use strict";var ERROR="input is invalid type",WINDOW="object"===typeof window,root=WINDOW?window:{};root.JS_SHA256_NO_WINDOW&&(WINDOW=!1);var WEB_WORKER=!WINDOW&&"object"===typeof self,NODE_JS=!root.JS_SHA256_NO_NODE_JS&&"object"===typeof process&&process.versions&&process.versions.node;NODE_JS?root=global:WEB_WORKER&&(root=self);var COMMON_JS=!root.JS_SHA256_NO_COMMON_JS&&"object"===typeof module&&module.exports,AMD=__webpack_require__(90),ARRAY_BUFFER=!root.JS_SHA256_NO_ARRAY_BUFFER&&"undefined"!==typeof ArrayBuffer,HEX_CHARS="0123456789abcdef".split(""),EXTRA=[-2147483648,8388608,32768,128],SHIFT=[24,16,8,0],K=[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],OUTPUT_TYPES=["hex","array","digest","arrayBuffer"],blocks=[];!root.JS_SHA256_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!ARRAY_BUFFER||!root.JS_SHA256_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});var createOutputMethod=function(e,t){return function(r){return new Sha256(t,!0).update(r)[e]()}},createMethod=function(e){var t=createOutputMethod("hex",e);NODE_JS&&(t=nodeWrap(t,e)),t.create=function(){return new Sha256(e)},t.update=function(e){return t.create().update(e)};for(var r=0;r<OUTPUT_TYPES.length;++r){var n=OUTPUT_TYPES[r];t[n]=createOutputMethod(n,e)}return t},nodeWrap=function nodeWrap(method,is224){var crypto=eval("require('crypto')"),Buffer=eval("require('buffer').Buffer"),algorithm=is224?"sha224":"sha256",nodeMethod=function(e){if("string"===typeof e)return crypto.createHash(algorithm).update(e,"utf8").digest("hex");if(null===e||void 0===e)throw new Error(ERROR);return e.constructor===ArrayBuffer&&(e=new Uint8Array(e)),Array.isArray(e)||ArrayBuffer.isView(e)||e.constructor===Buffer?crypto.createHash(algorithm).update(new Buffer(e)).digest("hex"):method(e)};return nodeMethod},createHmacOutputMethod=function(e,t){return function(r,n){return new HmacSha256(r,t,!0).update(n)[e]()}},createHmacMethod=function(e){var t=createHmacOutputMethod("hex",e);t.create=function(t){return new HmacSha256(t,e)},t.update=function(e,r){return t.create(e).update(r)};for(var r=0;r<OUTPUT_TYPES.length;++r){var n=OUTPUT_TYPES[r];t[n]=createHmacOutputMethod(n,e)}return t};function Sha256(e,t){t?(blocks[0]=blocks[16]=blocks[1]=blocks[2]=blocks[3]=blocks[4]=blocks[5]=blocks[6]=blocks[7]=blocks[8]=blocks[9]=blocks[10]=blocks[11]=blocks[12]=blocks[13]=blocks[14]=blocks[15]=0,this.blocks=blocks):this.blocks=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],e?(this.h0=3238371032,this.h1=914150663,this.h2=812702999,this.h3=4144912697,this.h4=4290775857,this.h5=1750603025,this.h6=1694076839,this.h7=3204075428):(this.h0=1779033703,this.h1=3144134277,this.h2=1013904242,this.h3=2773480762,this.h4=1359893119,this.h5=2600822924,this.h6=528734635,this.h7=1541459225),this.block=this.start=this.bytes=this.hBytes=0,this.finalized=this.hashed=!1,this.first=!0,this.is224=e}function HmacSha256(e,t,r){var n,i=typeof e;if("string"===i){var o,a=[],u=e.length,s=0;for(n=0;n<u;++n)(o=e.charCodeAt(n))<128?a[s++]=o:o<2048?(a[s++]=192|o>>6,a[s++]=128|63&o):o<55296||o>=57344?(a[s++]=224|o>>12,a[s++]=128|o>>6&63,a[s++]=128|63&o):(o=65536+((1023&o)<<10|1023&e.charCodeAt(++n)),a[s++]=240|o>>18,a[s++]=128|o>>12&63,a[s++]=128|o>>6&63,a[s++]=128|63&o);e=a}else{if("object"!==i)throw new Error(ERROR);if(null===e)throw new Error(ERROR);if(ARRAY_BUFFER&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!ARRAY_BUFFER||!ArrayBuffer.isView(e)))throw new Error(ERROR)}e.length>64&&(e=new Sha256(t,!0).update(e).array());var c=[],f=[];for(n=0;n<64;++n){var l=e[n]||0;c[n]=92^l,f[n]=54^l}Sha256.call(this,t,r),this.update(f),this.oKeyPad=c,this.inner=!0,this.sharedMemory=r}Sha256.prototype.update=function(e){if(!this.finalized){var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(ERROR);if(null===e)throw new Error(ERROR);if(ARRAY_BUFFER&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!ARRAY_BUFFER||!ArrayBuffer.isView(e)))throw new Error(ERROR);t=!0}for(var n,i,o=0,a=e.length,u=this.blocks;o<a;){if(this.hashed&&(this.hashed=!1,u[0]=this.block,u[16]=u[1]=u[2]=u[3]=u[4]=u[5]=u[6]=u[7]=u[8]=u[9]=u[10]=u[11]=u[12]=u[13]=u[14]=u[15]=0),t)for(i=this.start;o<a&&i<64;++o)u[i>>2]|=e[o]<<SHIFT[3&i++];else for(i=this.start;o<a&&i<64;++o)(n=e.charCodeAt(o))<128?u[i>>2]|=n<<SHIFT[3&i++]:n<2048?(u[i>>2]|=(192|n>>6)<<SHIFT[3&i++],u[i>>2]|=(128|63&n)<<SHIFT[3&i++]):n<55296||n>=57344?(u[i>>2]|=(224|n>>12)<<SHIFT[3&i++],u[i>>2]|=(128|n>>6&63)<<SHIFT[3&i++],u[i>>2]|=(128|63&n)<<SHIFT[3&i++]):(n=65536+((1023&n)<<10|1023&e.charCodeAt(++o)),u[i>>2]|=(240|n>>18)<<SHIFT[3&i++],u[i>>2]|=(128|n>>12&63)<<SHIFT[3&i++],u[i>>2]|=(128|n>>6&63)<<SHIFT[3&i++],u[i>>2]|=(128|63&n)<<SHIFT[3&i++]);this.lastByteIndex=i,this.bytes+=i-this.start,i>=64?(this.block=u[16],this.start=i-64,this.hash(),this.hashed=!0):this.start=i}return this.bytes>4294967295&&(this.hBytes+=this.bytes/4294967296<<0,this.bytes=this.bytes%4294967296),this}},Sha256.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var e=this.blocks,t=this.lastByteIndex;e[16]=this.block,e[t>>2]|=EXTRA[3&t],this.block=e[16],t>=56&&(this.hashed||this.hash(),e[0]=this.block,e[16]=e[1]=e[2]=e[3]=e[4]=e[5]=e[6]=e[7]=e[8]=e[9]=e[10]=e[11]=e[12]=e[13]=e[14]=e[15]=0),e[14]=this.hBytes<<3|this.bytes>>>29,e[15]=this.bytes<<3,this.hash()}},Sha256.prototype.hash=function(){var e,t,r,n,i,o,a,u,s,c=this.h0,f=this.h1,l=this.h2,h=this.h3,d=this.h4,p=this.h5,b=this.h6,v=this.h7,y=this.blocks;for(e=16;e<64;++e)t=((i=y[e-15])>>>7|i<<25)^(i>>>18|i<<14)^i>>>3,r=((i=y[e-2])>>>17|i<<15)^(i>>>19|i<<13)^i>>>10,y[e]=y[e-16]+t+y[e-7]+r<<0;for(s=f&l,e=0;e<64;e+=4)this.first?(this.is224?(o=300032,v=(i=y[0]-1413257819)-150054599<<0,h=i+24177077<<0):(o=704751109,v=(i=y[0]-210244248)-1521486534<<0,h=i+143694565<<0),this.first=!1):(t=(c>>>2|c<<30)^(c>>>13|c<<19)^(c>>>22|c<<10),n=(o=c&f)^c&l^s,v=h+(i=v+(r=(d>>>6|d<<26)^(d>>>11|d<<21)^(d>>>25|d<<7))+(d&p^~d&b)+K[e]+y[e])<<0,h=i+(t+n)<<0),t=(h>>>2|h<<30)^(h>>>13|h<<19)^(h>>>22|h<<10),n=(a=h&c)^h&f^o,b=l+(i=b+(r=(v>>>6|v<<26)^(v>>>11|v<<21)^(v>>>25|v<<7))+(v&d^~v&p)+K[e+1]+y[e+1])<<0,t=((l=i+(t+n)<<0)>>>2|l<<30)^(l>>>13|l<<19)^(l>>>22|l<<10),n=(u=l&h)^l&c^a,p=f+(i=p+(r=(b>>>6|b<<26)^(b>>>11|b<<21)^(b>>>25|b<<7))+(b&v^~b&d)+K[e+2]+y[e+2])<<0,t=((f=i+(t+n)<<0)>>>2|f<<30)^(f>>>13|f<<19)^(f>>>22|f<<10),n=(s=f&l)^f&h^u,d=c+(i=d+(r=(p>>>6|p<<26)^(p>>>11|p<<21)^(p>>>25|p<<7))+(p&b^~p&v)+K[e+3]+y[e+3])<<0,c=i+(t+n)<<0;this.h0=this.h0+c<<0,this.h1=this.h1+f<<0,this.h2=this.h2+l<<0,this.h3=this.h3+h<<0,this.h4=this.h4+d<<0,this.h5=this.h5+p<<0,this.h6=this.h6+b<<0,this.h7=this.h7+v<<0},Sha256.prototype.hex=function(){this.finalize();var e=this.h0,t=this.h1,r=this.h2,n=this.h3,i=this.h4,o=this.h5,a=this.h6,u=this.h7,s=HEX_CHARS[e>>28&15]+HEX_CHARS[e>>24&15]+HEX_CHARS[e>>20&15]+HEX_CHARS[e>>16&15]+HEX_CHARS[e>>12&15]+HEX_CHARS[e>>8&15]+HEX_CHARS[e>>4&15]+HEX_CHARS[15&e]+HEX_CHARS[t>>28&15]+HEX_CHARS[t>>24&15]+HEX_CHARS[t>>20&15]+HEX_CHARS[t>>16&15]+HEX_CHARS[t>>12&15]+HEX_CHARS[t>>8&15]+HEX_CHARS[t>>4&15]+HEX_CHARS[15&t]+HEX_CHARS[r>>28&15]+HEX_CHARS[r>>24&15]+HEX_CHARS[r>>20&15]+HEX_CHARS[r>>16&15]+HEX_CHARS[r>>12&15]+HEX_CHARS[r>>8&15]+HEX_CHARS[r>>4&15]+HEX_CHARS[15&r]+HEX_CHARS[n>>28&15]+HEX_CHARS[n>>24&15]+HEX_CHARS[n>>20&15]+HEX_CHARS[n>>16&15]+HEX_CHARS[n>>12&15]+HEX_CHARS[n>>8&15]+HEX_CHARS[n>>4&15]+HEX_CHARS[15&n]+HEX_CHARS[i>>28&15]+HEX_CHARS[i>>24&15]+HEX_CHARS[i>>20&15]+HEX_CHARS[i>>16&15]+HEX_CHARS[i>>12&15]+HEX_CHARS[i>>8&15]+HEX_CHARS[i>>4&15]+HEX_CHARS[15&i]+HEX_CHARS[o>>28&15]+HEX_CHARS[o>>24&15]+HEX_CHARS[o>>20&15]+HEX_CHARS[o>>16&15]+HEX_CHARS[o>>12&15]+HEX_CHARS[o>>8&15]+HEX_CHARS[o>>4&15]+HEX_CHARS[15&o]+HEX_CHARS[a>>28&15]+HEX_CHARS[a>>24&15]+HEX_CHARS[a>>20&15]+HEX_CHARS[a>>16&15]+HEX_CHARS[a>>12&15]+HEX_CHARS[a>>8&15]+HEX_CHARS[a>>4&15]+HEX_CHARS[15&a];return this.is224||(s+=HEX_CHARS[u>>28&15]+HEX_CHARS[u>>24&15]+HEX_CHARS[u>>20&15]+HEX_CHARS[u>>16&15]+HEX_CHARS[u>>12&15]+HEX_CHARS[u>>8&15]+HEX_CHARS[u>>4&15]+HEX_CHARS[15&u]),s},Sha256.prototype.toString=Sha256.prototype.hex,Sha256.prototype.digest=function(){this.finalize();var e=this.h0,t=this.h1,r=this.h2,n=this.h3,i=this.h4,o=this.h5,a=this.h6,u=this.h7,s=[e>>24&255,e>>16&255,e>>8&255,255&e,t>>24&255,t>>16&255,t>>8&255,255&t,r>>24&255,r>>16&255,r>>8&255,255&r,n>>24&255,n>>16&255,n>>8&255,255&n,i>>24&255,i>>16&255,i>>8&255,255&i,o>>24&255,o>>16&255,o>>8&255,255&o,a>>24&255,a>>16&255,a>>8&255,255&a];return this.is224||s.push(u>>24&255,u>>16&255,u>>8&255,255&u),s},Sha256.prototype.array=Sha256.prototype.digest,Sha256.prototype.arrayBuffer=function(){this.finalize();var e=new ArrayBuffer(this.is224?28:32),t=new DataView(e);return t.setUint32(0,this.h0),t.setUint32(4,this.h1),t.setUint32(8,this.h2),t.setUint32(12,this.h3),t.setUint32(16,this.h4),t.setUint32(20,this.h5),t.setUint32(24,this.h6),this.is224||t.setUint32(28,this.h7),e},HmacSha256.prototype=new Sha256,HmacSha256.prototype.finalize=function(){if(Sha256.prototype.finalize.call(this),this.inner){this.inner=!1;var e=this.array();Sha256.call(this,this.is224,this.sharedMemory),this.update(this.oKeyPad),this.update(e),Sha256.prototype.finalize.call(this)}};var exports=createMethod();exports.sha256=exports,exports.sha224=createMethod(!0),exports.sha256.hmac=createHmacMethod(),exports.sha224.hmac=createHmacMethod(!0),COMMON_JS?module.exports=exports:(root.sha256=exports.sha256,root.sha224=exports.sha224,AMD&&(__WEBPACK_AMD_DEFINE_RESULT__=function(){return exports}.call(exports,__webpack_require__,exports,module),void 0===__WEBPACK_AMD_DEFINE_RESULT__||(module.exports=__WEBPACK_AMD_DEFINE_RESULT__)))})()}).call(this,__webpack_require__(35),__webpack_require__(39))},function(e,t,r){!function(e){"use strict";var t=function(e){var t,r=new Float64Array(16);if(e)for(t=0;t<e.length;t++)r[t]=e[t];return r},n=function(){throw new Error("no PRNG")},i=new Uint8Array(16),o=new Uint8Array(32);o[0]=9;var a=t(),u=t([1]),s=t([56129,1]),c=t([30883,4953,19914,30187,55467,16705,2637,112,59544,30585,16505,36039,65139,11119,27886,20995]),f=t([61785,9906,39828,60374,45398,33411,5274,224,53552,61171,33010,6542,64743,22239,55772,9222]),l=t([54554,36645,11616,51542,42930,38181,51040,26924,56412,64982,57905,49316,21502,52590,14035,8553]),h=t([26200,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214]),d=t([41136,18958,6951,50414,58488,44335,6150,12099,55207,15867,153,11085,57099,20417,9344,11139]);function p(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 b(e,t,r,n,i){var o,a=0;for(o=0;o<i;o++)a|=e[t+o]^r[n+o];return(1&a-1>>>8)-1}function v(e,t,r,n){return b(e,t,r,n,16)}function y(e,t,r,n){return b(e,t,r,n,32)}function m(e,t,r,n){!function(e,t,r,n){for(var i,o=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,u=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,s=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,d=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,b=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,y=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,g=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,k=o,_=a,x=u,S=s,E=c,O=f,A=l,M=h,j=d,I=p,P=b,R=v,C=y,T=m,B=g,L=w,z=0;z<20;z+=2)k^=(i=(C^=(i=(j^=(i=(E^=(i=k+C|0)<<7|i>>>25)+k|0)<<9|i>>>23)+E|0)<<13|i>>>19)+j|0)<<18|i>>>14,O^=(i=(_^=(i=(T^=(i=(I^=(i=O+_|0)<<7|i>>>25)+O|0)<<9|i>>>23)+I|0)<<13|i>>>19)+T|0)<<18|i>>>14,P^=(i=(A^=(i=(x^=(i=(B^=(i=P+A|0)<<7|i>>>25)+P|0)<<9|i>>>23)+B|0)<<13|i>>>19)+x|0)<<18|i>>>14,L^=(i=(R^=(i=(M^=(i=(S^=(i=L+R|0)<<7|i>>>25)+L|0)<<9|i>>>23)+S|0)<<13|i>>>19)+M|0)<<18|i>>>14,k^=(i=(S^=(i=(x^=(i=(_^=(i=k+S|0)<<7|i>>>25)+k|0)<<9|i>>>23)+_|0)<<13|i>>>19)+x|0)<<18|i>>>14,O^=(i=(E^=(i=(M^=(i=(A^=(i=O+E|0)<<7|i>>>25)+O|0)<<9|i>>>23)+A|0)<<13|i>>>19)+M|0)<<18|i>>>14,P^=(i=(I^=(i=(j^=(i=(R^=(i=P+I|0)<<7|i>>>25)+P|0)<<9|i>>>23)+R|0)<<13|i>>>19)+j|0)<<18|i>>>14,L^=(i=(B^=(i=(T^=(i=(C^=(i=L+B|0)<<7|i>>>25)+L|0)<<9|i>>>23)+C|0)<<13|i>>>19)+T|0)<<18|i>>>14;k=k+o|0,_=_+a|0,x=x+u|0,S=S+s|0,E=E+c|0,O=O+f|0,A=A+l|0,M=M+h|0,j=j+d|0,I=I+p|0,P=P+b|0,R=R+v|0,C=C+y|0,T=T+m|0,B=B+g|0,L=L+w|0,e[0]=k>>>0&255,e[1]=k>>>8&255,e[2]=k>>>16&255,e[3]=k>>>24&255,e[4]=_>>>0&255,e[5]=_>>>8&255,e[6]=_>>>16&255,e[7]=_>>>24&255,e[8]=x>>>0&255,e[9]=x>>>8&255,e[10]=x>>>16&255,e[11]=x>>>24&255,e[12]=S>>>0&255,e[13]=S>>>8&255,e[14]=S>>>16&255,e[15]=S>>>24&255,e[16]=E>>>0&255,e[17]=E>>>8&255,e[18]=E>>>16&255,e[19]=E>>>24&255,e[20]=O>>>0&255,e[21]=O>>>8&255,e[22]=O>>>16&255,e[23]=O>>>24&255,e[24]=A>>>0&255,e[25]=A>>>8&255,e[26]=A>>>16&255,e[27]=A>>>24&255,e[28]=M>>>0&255,e[29]=M>>>8&255,e[30]=M>>>16&255,e[31]=M>>>24&255,e[32]=j>>>0&255,e[33]=j>>>8&255,e[34]=j>>>16&255,e[35]=j>>>24&255,e[36]=I>>>0&255,e[37]=I>>>8&255,e[38]=I>>>16&255,e[39]=I>>>24&255,e[40]=P>>>0&255,e[41]=P>>>8&255,e[42]=P>>>16&255,e[43]=P>>>24&255,e[44]=R>>>0&255,e[45]=R>>>8&255,e[46]=R>>>16&255,e[47]=R>>>24&255,e[48]=C>>>0&255,e[49]=C>>>8&255,e[50]=C>>>16&255,e[51]=C>>>24&255,e[52]=T>>>0&255,e[53]=T>>>8&255,e[54]=T>>>16&255,e[55]=T>>>24&255,e[56]=B>>>0&255,e[57]=B>>>8&255,e[58]=B>>>16&255,e[59]=B>>>24&255,e[60]=L>>>0&255,e[61]=L>>>8&255,e[62]=L>>>16&255,e[63]=L>>>24&255}(e,t,r,n)}function g(e,t,r,n){!function(e,t,r,n){for(var i,o=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,u=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,s=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,d=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,b=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,y=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,g=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,k=0;k<20;k+=2)o^=(i=(y^=(i=(d^=(i=(c^=(i=o+y|0)<<7|i>>>25)+o|0)<<9|i>>>23)+c|0)<<13|i>>>19)+d|0)<<18|i>>>14,f^=(i=(a^=(i=(m^=(i=(p^=(i=f+a|0)<<7|i>>>25)+f|0)<<9|i>>>23)+p|0)<<13|i>>>19)+m|0)<<18|i>>>14,b^=(i=(l^=(i=(u^=(i=(g^=(i=b+l|0)<<7|i>>>25)+b|0)<<9|i>>>23)+g|0)<<13|i>>>19)+u|0)<<18|i>>>14,w^=(i=(v^=(i=(h^=(i=(s^=(i=w+v|0)<<7|i>>>25)+w|0)<<9|i>>>23)+s|0)<<13|i>>>19)+h|0)<<18|i>>>14,o^=(i=(s^=(i=(u^=(i=(a^=(i=o+s|0)<<7|i>>>25)+o|0)<<9|i>>>23)+a|0)<<13|i>>>19)+u|0)<<18|i>>>14,f^=(i=(c^=(i=(h^=(i=(l^=(i=f+c|0)<<7|i>>>25)+f|0)<<9|i>>>23)+l|0)<<13|i>>>19)+h|0)<<18|i>>>14,b^=(i=(p^=(i=(d^=(i=(v^=(i=b+p|0)<<7|i>>>25)+b|0)<<9|i>>>23)+v|0)<<13|i>>>19)+d|0)<<18|i>>>14,w^=(i=(g^=(i=(m^=(i=(y^=(i=w+g|0)<<7|i>>>25)+w|0)<<9|i>>>23)+y|0)<<13|i>>>19)+m|0)<<18|i>>>14;e[0]=o>>>0&255,e[1]=o>>>8&255,e[2]=o>>>16&255,e[3]=o>>>24&255,e[4]=f>>>0&255,e[5]=f>>>8&255,e[6]=f>>>16&255,e[7]=f>>>24&255,e[8]=b>>>0&255,e[9]=b>>>8&255,e[10]=b>>>16&255,e[11]=b>>>24&255,e[12]=w>>>0&255,e[13]=w>>>8&255,e[14]=w>>>16&255,e[15]=w>>>24&255,e[16]=l>>>0&255,e[17]=l>>>8&255,e[18]=l>>>16&255,e[19]=l>>>24&255,e[20]=h>>>0&255,e[21]=h>>>8&255,e[22]=h>>>16&255,e[23]=h>>>24&255,e[24]=d>>>0&255,e[25]=d>>>8&255,e[26]=d>>>16&255,e[27]=d>>>24&255,e[28]=p>>>0&255,e[29]=p>>>8&255,e[30]=p>>>16&255,e[31]=p>>>24&255}(e,t,r,n)}var w=new Uint8Array([101,120,112,97,110,100,32,51,50,45,98,121,116,101,32,107]);function k(e,t,r,n,i,o,a){var u,s,c=new Uint8Array(16),f=new Uint8Array(64);for(s=0;s<16;s++)c[s]=0;for(s=0;s<8;s++)c[s]=o[s];for(;i>=64;){for(m(f,c,a,w),s=0;s<64;s++)e[t+s]=r[n+s]^f[s];for(u=1,s=8;s<16;s++)u=u+(255&c[s])|0,c[s]=255&u,u>>>=8;i-=64,t+=64,n+=64}if(i>0)for(m(f,c,a,w),s=0;s<i;s++)e[t+s]=r[n+s]^f[s];return 0}function _(e,t,r,n,i){var o,a,u=new Uint8Array(16),s=new Uint8Array(64);for(a=0;a<16;a++)u[a]=0;for(a=0;a<8;a++)u[a]=n[a];for(;r>=64;){for(m(s,u,i,w),a=0;a<64;a++)e[t+a]=s[a];for(o=1,a=8;a<16;a++)o=o+(255&u[a])|0,u[a]=255&o,o>>>=8;r-=64,t+=64}if(r>0)for(m(s,u,i,w),a=0;a<r;a++)e[t+a]=s[a];return 0}function x(e,t,r,n,i){var o=new Uint8Array(32);g(o,n,i,w);for(var a=new Uint8Array(8),u=0;u<8;u++)a[u]=n[u+16];return _(e,t,r,a,o)}function S(e,t,r,n,i,o,a){var u=new Uint8Array(32);g(u,o,a,w);for(var s=new Uint8Array(8),c=0;c<8;c++)s[c]=o[c+16];return k(e,t,r,n,i,s,u)}var E=function(e){var t,r,n,i,o,a,u,s;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,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),i=255&e[6]|(255&e[7])<<8,this.r[3]=8191&(n>>>7|i<<9),o=255&e[8]|(255&e[9])<<8,this.r[4]=255&(i>>>4|o<<12),this.r[5]=o>>>1&8190,a=255&e[10]|(255&e[11])<<8,this.r[6]=8191&(o>>>14|a<<2),u=255&e[12]|(255&e[13])<<8,this.r[7]=8065&(a>>>11|u<<5),s=255&e[14]|(255&e[15])<<8,this.r[8]=8191&(u>>>8|s<<8),this.r[9]=s>>>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};function O(e,t,r,n,i,o){var a=new E(o);return a.update(r,n,i),a.finish(e,t),0}function A(e,t,r,n,i,o){var a=new Uint8Array(16);return O(a,0,r,n,i,o),v(e,t,a,0)}function M(e,t,r,n,i){var o;if(r<32)return-1;for(S(e,0,t,0,r,n,i),O(e,16,e,32,r-32,e),o=0;o<16;o++)e[o]=0;return 0}function j(e,t,r,n,i){var o,a=new Uint8Array(32);if(r<32)return-1;if(x(a,0,32,n,i),0!==A(t,16,t,32,r-32,a))return-1;for(S(e,0,t,0,r,n,i),o=0;o<32;o++)e[o]=0;return 0}function I(e,t){var r;for(r=0;r<16;r++)e[r]=0|t[r]}function P(e){var t,r,n=1;for(t=0;t<16;t++)r=e[t]+n+65535,n=Math.floor(r/65536),e[t]=r-65536*n;e[0]+=n-1+37*(n-1)}function R(e,t,r){for(var n,i=~(r-1),o=0;o<16;o++)n=i&(e[o]^t[o]),e[o]^=n,t[o]^=n}function C(e,r){var n,i,o,a=t(),u=t();for(n=0;n<16;n++)u[n]=r[n];for(P(u),P(u),P(u),i=0;i<2;i++){for(a[0]=u[0]-65517,n=1;n<15;n++)a[n]=u[n]-65535-(a[n-1]>>16&1),a[n-1]&=65535;a[15]=u[15]-32767-(a[14]>>16&1),o=a[15]>>16&1,a[14]&=65535,R(u,a,1-o)}for(n=0;n<16;n++)e[2*n]=255&u[n],e[2*n+1]=u[n]>>8}function T(e,t){var r=new Uint8Array(32),n=new Uint8Array(32);return C(r,e),C(n,t),y(r,0,n,0)}function B(e){var t=new Uint8Array(32);return C(t,e),1&t[0]}function L(e,t){var r;for(r=0;r<16;r++)e[r]=t[2*r]+(t[2*r+1]<<8);e[15]&=32767}function z(e,t,r){for(var n=0;n<16;n++)e[n]=t[n]+r[n]}function U(e,t,r){for(var n=0;n<16;n++)e[n]=t[n]-r[n]}function N(e,t,r){var n,i,o=0,a=0,u=0,s=0,c=0,f=0,l=0,h=0,d=0,p=0,b=0,v=0,y=0,m=0,g=0,w=0,k=0,_=0,x=0,S=0,E=0,O=0,A=0,M=0,j=0,I=0,P=0,R=0,C=0,T=0,B=0,L=r[0],z=r[1],U=r[2],N=r[3],D=r[4],F=r[5],q=r[6],H=r[7],W=r[8],K=r[9],V=r[10],Z=r[11],Y=r[12],X=r[13],G=r[14],J=r[15];o+=(n=t[0])*L,a+=n*z,u+=n*U,s+=n*N,c+=n*D,f+=n*F,l+=n*q,h+=n*H,d+=n*W,p+=n*K,b+=n*V,v+=n*Z,y+=n*Y,m+=n*X,g+=n*G,w+=n*J,a+=(n=t[1])*L,u+=n*z,s+=n*U,c+=n*N,f+=n*D,l+=n*F,h+=n*q,d+=n*H,p+=n*W,b+=n*K,v+=n*V,y+=n*Z,m+=n*Y,g+=n*X,w+=n*G,k+=n*J,u+=(n=t[2])*L,s+=n*z,c+=n*U,f+=n*N,l+=n*D,h+=n*F,d+=n*q,p+=n*H,b+=n*W,v+=n*K,y+=n*V,m+=n*Z,g+=n*Y,w+=n*X,k+=n*G,_+=n*J,s+=(n=t[3])*L,c+=n*z,f+=n*U,l+=n*N,h+=n*D,d+=n*F,p+=n*q,b+=n*H,v+=n*W,y+=n*K,m+=n*V,g+=n*Z,w+=n*Y,k+=n*X,_+=n*G,x+=n*J,c+=(n=t[4])*L,f+=n*z,l+=n*U,h+=n*N,d+=n*D,p+=n*F,b+=n*q,v+=n*H,y+=n*W,m+=n*K,g+=n*V,w+=n*Z,k+=n*Y,_+=n*X,x+=n*G,S+=n*J,f+=(n=t[5])*L,l+=n*z,h+=n*U,d+=n*N,p+=n*D,b+=n*F,v+=n*q,y+=n*H,m+=n*W,g+=n*K,w+=n*V,k+=n*Z,_+=n*Y,x+=n*X,S+=n*G,E+=n*J,l+=(n=t[6])*L,h+=n*z,d+=n*U,p+=n*N,b+=n*D,v+=n*F,y+=n*q,m+=n*H,g+=n*W,w+=n*K,k+=n*V,_+=n*Z,x+=n*Y,S+=n*X,E+=n*G,O+=n*J,h+=(n=t[7])*L,d+=n*z,p+=n*U,b+=n*N,v+=n*D,y+=n*F,m+=n*q,g+=n*H,w+=n*W,k+=n*K,_+=n*V,x+=n*Z,S+=n*Y,E+=n*X,O+=n*G,A+=n*J,d+=(n=t[8])*L,p+=n*z,b+=n*U,v+=n*N,y+=n*D,m+=n*F,g+=n*q,w+=n*H,k+=n*W,_+=n*K,x+=n*V,S+=n*Z,E+=n*Y,O+=n*X,A+=n*G,M+=n*J,p+=(n=t[9])*L,b+=n*z,v+=n*U,y+=n*N,m+=n*D,g+=n*F,w+=n*q,k+=n*H,_+=n*W,x+=n*K,S+=n*V,E+=n*Z,O+=n*Y,A+=n*X,M+=n*G,j+=n*J,b+=(n=t[10])*L,v+=n*z,y+=n*U,m+=n*N,g+=n*D,w+=n*F,k+=n*q,_+=n*H,x+=n*W,S+=n*K,E+=n*V,O+=n*Z,A+=n*Y,M+=n*X,j+=n*G,I+=n*J,v+=(n=t[11])*L,y+=n*z,m+=n*U,g+=n*N,w+=n*D,k+=n*F,_+=n*q,x+=n*H,S+=n*W,E+=n*K,O+=n*V,A+=n*Z,M+=n*Y,j+=n*X,I+=n*G,P+=n*J,y+=(n=t[12])*L,m+=n*z,g+=n*U,w+=n*N,k+=n*D,_+=n*F,x+=n*q,S+=n*H,E+=n*W,O+=n*K,A+=n*V,M+=n*Z,j+=n*Y,I+=n*X,P+=n*G,R+=n*J,m+=(n=t[13])*L,g+=n*z,w+=n*U,k+=n*N,_+=n*D,x+=n*F,S+=n*q,E+=n*H,O+=n*W,A+=n*K,M+=n*V,j+=n*Z,I+=n*Y,P+=n*X,R+=n*G,C+=n*J,g+=(n=t[14])*L,w+=n*z,k+=n*U,_+=n*N,x+=n*D,S+=n*F,E+=n*q,O+=n*H,A+=n*W,M+=n*K,j+=n*V,I+=n*Z,P+=n*Y,R+=n*X,C+=n*G,T+=n*J,w+=(n=t[15])*L,a+=38*(_+=n*U),u+=38*(x+=n*N),s+=38*(S+=n*D),c+=38*(E+=n*F),f+=38*(O+=n*q),l+=38*(A+=n*H),h+=38*(M+=n*W),d+=38*(j+=n*K),p+=38*(I+=n*V),b+=38*(P+=n*Z),v+=38*(R+=n*Y),y+=38*(C+=n*X),m+=38*(T+=n*G),g+=38*(B+=n*J),o=(n=(o+=38*(k+=n*z))+(i=1)+65535)-65536*(i=Math.floor(n/65536)),a=(n=a+i+65535)-65536*(i=Math.floor(n/65536)),u=(n=u+i+65535)-65536*(i=Math.floor(n/65536)),s=(n=s+i+65535)-65536*(i=Math.floor(n/65536)),c=(n=c+i+65535)-65536*(i=Math.floor(n/65536)),f=(n=f+i+65535)-65536*(i=Math.floor(n/65536)),l=(n=l+i+65535)-65536*(i=Math.floor(n/65536)),h=(n=h+i+65535)-65536*(i=Math.floor(n/65536)),d=(n=d+i+65535)-65536*(i=Math.floor(n/65536)),p=(n=p+i+65535)-65536*(i=Math.floor(n/65536)),b=(n=b+i+65535)-65536*(i=Math.floor(n/65536)),v=(n=v+i+65535)-65536*(i=Math.floor(n/65536)),y=(n=y+i+65535)-65536*(i=Math.floor(n/65536)),m=(n=m+i+65535)-65536*(i=Math.floor(n/65536)),g=(n=g+i+65535)-65536*(i=Math.floor(n/65536)),w=(n=w+i+65535)-65536*(i=Math.floor(n/65536)),o=(n=(o+=i-1+37*(i-1))+(i=1)+65535)-65536*(i=Math.floor(n/65536)),a=(n=a+i+65535)-65536*(i=Math.floor(n/65536)),u=(n=u+i+65535)-65536*(i=Math.floor(n/65536)),s=(n=s+i+65535)-65536*(i=Math.floor(n/65536)),c=(n=c+i+65535)-65536*(i=Math.floor(n/65536)),f=(n=f+i+65535)-65536*(i=Math.floor(n/65536)),l=(n=l+i+65535)-65536*(i=Math.floor(n/65536)),h=(n=h+i+65535)-65536*(i=Math.floor(n/65536)),d=(n=d+i+65535)-65536*(i=Math.floor(n/65536)),p=(n=p+i+65535)-65536*(i=Math.floor(n/65536)),b=(n=b+i+65535)-65536*(i=Math.floor(n/65536)),v=(n=v+i+65535)-65536*(i=Math.floor(n/65536)),y=(n=y+i+65535)-65536*(i=Math.floor(n/65536)),m=(n=m+i+65535)-65536*(i=Math.floor(n/65536)),g=(n=g+i+65535)-65536*(i=Math.floor(n/65536)),w=(n=w+i+65535)-65536*(i=Math.floor(n/65536)),o+=i-1+37*(i-1),e[0]=o,e[1]=a,e[2]=u,e[3]=s,e[4]=c,e[5]=f,e[6]=l,e[7]=h,e[8]=d,e[9]=p,e[10]=b,e[11]=v,e[12]=y,e[13]=m,e[14]=g,e[15]=w}function D(e,t){N(e,t,t)}function F(e,r){var n,i=t();for(n=0;n<16;n++)i[n]=r[n];for(n=253;n>=0;n--)D(i,i),2!==n&&4!==n&&N(i,i,r);for(n=0;n<16;n++)e[n]=i[n]}function q(e,r){var n,i=t();for(n=0;n<16;n++)i[n]=r[n];for(n=250;n>=0;n--)D(i,i),1!==n&&N(i,i,r);for(n=0;n<16;n++)e[n]=i[n]}function H(e,r,n){var i,o,a=new Uint8Array(32),u=new Float64Array(80),c=t(),f=t(),l=t(),h=t(),d=t(),p=t();for(o=0;o<31;o++)a[o]=r[o];for(a[31]=127&r[31]|64,a[0]&=248,L(u,n),o=0;o<16;o++)f[o]=u[o],h[o]=c[o]=l[o]=0;for(c[0]=h[0]=1,o=254;o>=0;--o)R(c,f,i=a[o>>>3]>>>(7&o)&1),R(l,h,i),z(d,c,l),U(c,c,l),z(l,f,h),U(f,f,h),D(h,d),D(p,c),N(c,l,c),N(l,f,d),z(d,c,l),U(c,c,l),D(f,c),U(l,h,p),N(c,l,s),z(c,c,h),N(l,l,c),N(c,h,p),N(h,f,u),D(f,d),R(c,f,i),R(l,h,i);for(o=0;o<16;o++)u[o+16]=c[o],u[o+32]=l[o],u[o+48]=f[o],u[o+64]=h[o];var b=u.subarray(32),v=u.subarray(16);return F(b,b),N(v,v,b),C(e,v),0}function W(e,t){return H(e,t,o)}function K(e,t){return n(t,32),W(e,t)}function V(e,t,r){var n=new Uint8Array(32);return H(n,r,t),g(e,i,n,w)}E.prototype.blocks=function(e,t,r){for(var n,i,o,a,u,s,c,f,l,h,d,p,b,v,y,m,g,w,k,_=this.fin?0:2048,x=this.h[0],S=this.h[1],E=this.h[2],O=this.h[3],A=this.h[4],M=this.h[5],j=this.h[6],I=this.h[7],P=this.h[8],R=this.h[9],C=this.r[0],T=this.r[1],B=this.r[2],L=this.r[3],z=this.r[4],U=this.r[5],N=this.r[6],D=this.r[7],F=this.r[8],q=this.r[9];r>=16;)h=l=0,h+=(x+=8191&(n=255&e[t+0]|(255&e[t+1])<<8))*C,h+=(S+=8191&(n>>>13|(i=255&e[t+2]|(255&e[t+3])<<8)<<3))*(5*q),h+=(E+=8191&(i>>>10|(o=255&e[t+4]|(255&e[t+5])<<8)<<6))*(5*F),h+=(O+=8191&(o>>>7|(a=255&e[t+6]|(255&e[t+7])<<8)<<9))*(5*D),l=(h+=(A+=8191&(a>>>4|(u=255&e[t+8]|(255&e[t+9])<<8)<<12))*(5*N))>>>13,h&=8191,h+=(M+=u>>>1&8191)*(5*U),h+=(j+=8191&(u>>>14|(s=255&e[t+10]|(255&e[t+11])<<8)<<2))*(5*z),h+=(I+=8191&(s>>>11|(c=255&e[t+12]|(255&e[t+13])<<8)<<5))*(5*L),h+=(P+=8191&(c>>>8|(f=255&e[t+14]|(255&e[t+15])<<8)<<8))*(5*B),d=l+=(h+=(R+=f>>>5|_)*(5*T))>>>13,d+=x*T,d+=S*C,d+=E*(5*q),d+=O*(5*F),l=(d+=A*(5*D))>>>13,d&=8191,d+=M*(5*N),d+=j*(5*U),d+=I*(5*z),d+=P*(5*L),l+=(d+=R*(5*B))>>>13,d&=8191,p=l,p+=x*B,p+=S*T,p+=E*C,p+=O*(5*q),l=(p+=A*(5*F))>>>13,p&=8191,p+=M*(5*D),p+=j*(5*N),p+=I*(5*U),p+=P*(5*z),b=l+=(p+=R*(5*L))>>>13,b+=x*L,b+=S*B,b+=E*T,b+=O*C,l=(b+=A*(5*q))>>>13,b&=8191,b+=M*(5*F),b+=j*(5*D),b+=I*(5*N),b+=P*(5*U),v=l+=(b+=R*(5*z))>>>13,v+=x*z,v+=S*L,v+=E*B,v+=O*T,l=(v+=A*C)>>>13,v&=8191,v+=M*(5*q),v+=j*(5*F),v+=I*(5*D),v+=P*(5*N),y=l+=(v+=R*(5*U))>>>13,y+=x*U,y+=S*z,y+=E*L,y+=O*B,l=(y+=A*T)>>>13,y&=8191,y+=M*C,y+=j*(5*q),y+=I*(5*F),y+=P*(5*D),m=l+=(y+=R*(5*N))>>>13,m+=x*N,m+=S*U,m+=E*z,m+=O*L,l=(m+=A*B)>>>13,m&=8191,m+=M*T,m+=j*C,m+=I*(5*q),m+=P*(5*F),g=l+=(m+=R*(5*D))>>>13,g+=x*D,g+=S*N,g+=E*U,g+=O*z,l=(g+=A*L)>>>13,g&=8191,g+=M*B,g+=j*T,g+=I*C,g+=P*(5*q),w=l+=(g+=R*(5*F))>>>13,w+=x*F,w+=S*D,w+=E*N,w+=O*U,l=(w+=A*z)>>>13,w&=8191,w+=M*L,w+=j*B,w+=I*T,w+=P*C,k=l+=(w+=R*(5*q))>>>13,k+=x*q,k+=S*F,k+=E*D,k+=O*N,l=(k+=A*U)>>>13,k&=8191,k+=M*z,k+=j*L,k+=I*B,k+=P*T,x=h=8191&(l=(l=((l+=(k+=R*C)>>>13)<<2)+l|0)+(h&=8191)|0),S=d+=l>>>=13,E=p&=8191,O=b&=8191,A=v&=8191,M=y&=8191,j=m&=8191,I=g&=8191,P=w&=8191,R=k&=8191,t+=16,r-=16;this.h[0]=x,this.h[1]=S,this.h[2]=E,this.h[3]=O,this.h[4]=A,this.h[5]=M,this.h[6]=j,this.h[7]=I,this.h[8]=P,this.h[9]=R},E.prototype.finish=function(e,t){var r,n,i,o,a=new Uint16Array(10);if(this.leftover){for(o=this.leftover,this.buffer[o++]=1;o<16;o++)this.buffer[o]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(r=this.h[1]>>>13,this.h[1]&=8191,o=2;o<10;o++)this.h[o]+=r,r=this.h[o]>>>13,this.h[o]&=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,o=1;o<10;o++)a[o]=this.h[o]+r,r=a[o]>>>13,a[o]&=8191;for(a[9]-=8192,n=(1^r)-1,o=0;o<10;o++)a[o]&=n;for(n=~n,o=0;o<10;o++)this.h[o]=this.h[o]&n|a[o];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),i=this.h[0]+this.pad[0],this.h[0]=65535&i,o=1;o<8;o++)i=(this.h[o]+this.pad[o]|0)+(i>>>16)|0,this.h[o]=65535&i;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},E.prototype.update=function(e,t,r){var n,i;if(this.leftover){for((i=16-this.leftover)>r&&(i=r),n=0;n<i;n++)this.buffer[this.leftover+n]=e[t+n];if(r-=i,t+=i,this.leftover+=i,this.leftover<16)return;this.blocks(this.buffer,0,16),this.leftover=0}if(r>=16&&(i=r-r%16,this.blocks(e,t,i),t+=i,r-=i),r){for(n=0;n<r;n++)this.buffer[this.leftover+n]=e[t+n];this.leftover+=r}};var Z=M,Y=j;var X=[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];function G(e,t,r,n){for(var i,o,a,u,s,c,f,l,h,d,p,b,v,y,m,g,w,k,_,x,S,E,O,A,M,j,I=new Int32Array(16),P=new Int32Array(16),R=e[0],C=e[1],T=e[2],B=e[3],L=e[4],z=e[5],U=e[6],N=e[7],D=t[0],F=t[1],q=t[2],H=t[3],W=t[4],K=t[5],V=t[6],Z=t[7],Y=0;n>=128;){for(_=0;_<16;_++)x=8*_+Y,I[_]=r[x+0]<<24|r[x+1]<<16|r[x+2]<<8|r[x+3],P[_]=r[x+4]<<24|r[x+5]<<16|r[x+6]<<8|r[x+7];for(_=0;_<80;_++)if(i=R,o=C,a=T,u=B,s=L,c=z,f=U,N,h=D,d=F,p=q,b=H,v=W,y=K,m=V,Z,O=65535&(E=Z),A=E>>>16,M=65535&(S=N),j=S>>>16,O+=65535&(E=(W>>>14|L<<18)^(W>>>18|L<<14)^(L>>>9|W<<23)),A+=E>>>16,M+=65535&(S=(L>>>14|W<<18)^(L>>>18|W<<14)^(W>>>9|L<<23)),j+=S>>>16,O+=65535&(E=W&K^~W&V),A+=E>>>16,M+=65535&(S=L&z^~L&U),j+=S>>>16,O+=65535&(E=X[2*_+1]),A+=E>>>16,M+=65535&(S=X[2*_]),j+=S>>>16,S=I[_%16],A+=(E=P[_%16])>>>16,M+=65535&S,j+=S>>>16,M+=(A+=(O+=65535&E)>>>16)>>>16,O=65535&(E=k=65535&O|A<<16),A=E>>>16,M=65535&(S=w=65535&M|(j+=M>>>16)<<16),j=S>>>16,O+=65535&(E=(D>>>28|R<<4)^(R>>>2|D<<30)^(R>>>7|D<<25)),A+=E>>>16,M+=65535&(S=(R>>>28|D<<4)^(D>>>2|R<<30)^(D>>>7|R<<25)),j+=S>>>16,A+=(E=D&F^D&q^F&q)>>>16,M+=65535&(S=R&C^R&T^C&T),j+=S>>>16,l=65535&(M+=(A+=(O+=65535&E)>>>16)>>>16)|(j+=M>>>16)<<16,g=65535&O|A<<16,O=65535&(E=b),A=E>>>16,M=65535&(S=u),j=S>>>16,A+=(E=k)>>>16,M+=65535&(S=w),j+=S>>>16,C=i,T=o,B=a,L=u=65535&(M+=(A+=(O+=65535&E)>>>16)>>>16)|(j+=M>>>16)<<16,z=s,U=c,N=f,R=l,F=h,q=d,H=p,W=b=65535&O|A<<16,K=v,V=y,Z=m,D=g,_%16===15)for(x=0;x<16;x++)S=I[x],O=65535&(E=P[x]),A=E>>>16,M=65535&S,j=S>>>16,S=I[(x+9)%16],O+=65535&(E=P[(x+9)%16]),A+=E>>>16,M+=65535&S,j+=S>>>16,w=I[(x+1)%16],O+=65535&(E=((k=P[(x+1)%16])>>>1|w<<31)^(k>>>8|w<<24)^(k>>>7|w<<25)),A+=E>>>16,M+=65535&(S=(w>>>1|k<<31)^(w>>>8|k<<24)^w>>>7),j+=S>>>16,w=I[(x+14)%16],A+=(E=((k=P[(x+14)%16])>>>19|w<<13)^(w>>>29|k<<3)^(k>>>6|w<<26))>>>16,M+=65535&(S=(w>>>19|k<<13)^(k>>>29|w<<3)^w>>>6),j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,I[x]=65535&M|j<<16,P[x]=65535&O|A<<16;O=65535&(E=D),A=E>>>16,M=65535&(S=R),j=S>>>16,S=e[0],A+=(E=t[0])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[0]=R=65535&M|j<<16,t[0]=D=65535&O|A<<16,O=65535&(E=F),A=E>>>16,M=65535&(S=C),j=S>>>16,S=e[1],A+=(E=t[1])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[1]=C=65535&M|j<<16,t[1]=F=65535&O|A<<16,O=65535&(E=q),A=E>>>16,M=65535&(S=T),j=S>>>16,S=e[2],A+=(E=t[2])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[2]=T=65535&M|j<<16,t[2]=q=65535&O|A<<16,O=65535&(E=H),A=E>>>16,M=65535&(S=B),j=S>>>16,S=e[3],A+=(E=t[3])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[3]=B=65535&M|j<<16,t[3]=H=65535&O|A<<16,O=65535&(E=W),A=E>>>16,M=65535&(S=L),j=S>>>16,S=e[4],A+=(E=t[4])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[4]=L=65535&M|j<<16,t[4]=W=65535&O|A<<16,O=65535&(E=K),A=E>>>16,M=65535&(S=z),j=S>>>16,S=e[5],A+=(E=t[5])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[5]=z=65535&M|j<<16,t[5]=K=65535&O|A<<16,O=65535&(E=V),A=E>>>16,M=65535&(S=U),j=S>>>16,S=e[6],A+=(E=t[6])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[6]=U=65535&M|j<<16,t[6]=V=65535&O|A<<16,O=65535&(E=Z),A=E>>>16,M=65535&(S=N),j=S>>>16,S=e[7],A+=(E=t[7])>>>16,M+=65535&S,j+=S>>>16,j+=(M+=(A+=(O+=65535&E)>>>16)>>>16)>>>16,e[7]=N=65535&M|j<<16,t[7]=Z=65535&O|A<<16,Y+=128,n-=128}return n}function J(e,t,r){var n,i=new Int32Array(8),o=new Int32Array(8),a=new Uint8Array(256),u=r;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,o[0]=4089235720,o[1]=2227873595,o[2]=4271175723,o[3]=1595750129,o[4]=2917565137,o[5]=725511199,o[6]=4215389547,o[7]=327033209,G(i,o,t,r),r%=128,n=0;n<r;n++)a[n]=t[u-r+n];for(a[r]=128,a[(r=256-128*(r<112?1:0))-9]=0,p(a,r-8,u/536870912|0,u<<3),G(i,o,a,r),n=0;n<8;n++)p(e,8*n,i[n],o[n]);return 0}function $(e,r){var n=t(),i=t(),o=t(),a=t(),u=t(),s=t(),c=t(),l=t(),h=t();U(n,e[1],e[0]),U(h,r[1],r[0]),N(n,n,h),z(i,e[0],e[1]),z(h,r[0],r[1]),N(i,i,h),N(o,e[3],r[3]),N(o,o,f),N(a,e[2],r[2]),z(a,a,a),U(u,i,n),U(s,a,o),z(c,a,o),z(l,i,n),N(e[0],u,s),N(e[1],l,c),N(e[2],c,s),N(e[3],u,l)}function Q(e,t,r){var n;for(n=0;n<4;n++)R(e[n],t[n],r)}function ee(e,r){var n=t(),i=t(),o=t();F(o,r[2]),N(n,r[0],o),N(i,r[1],o),C(e,i),e[31]^=B(n)<<7}function te(e,t,r){var n,i;for(I(e[0],a),I(e[1],u),I(e[2],u),I(e[3],a),i=255;i>=0;--i)Q(e,t,n=r[i/8|0]>>(7&i)&1),$(t,e),$(e,e),Q(e,t,n)}function re(e,r){var n=[t(),t(),t(),t()];I(n[0],l),I(n[1],h),I(n[2],u),N(n[3],l,h),te(e,n,r)}function ne(e,r,i){var o,a=new Uint8Array(64),u=[t(),t(),t(),t()];for(i||n(r,32),J(a,r,32),a[0]&=248,a[31]&=127,a[31]|=64,re(u,a),ee(e,u),o=0;o<32;o++)r[o+32]=e[o];return 0}var ie=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]);function oe(e,t){var r,n,i,o;for(n=63;n>=32;--n){for(r=0,i=n-32,o=n-12;i<o;++i)t[i]+=r-16*t[n]*ie[i-(n-32)],r=Math.floor((t[i]+128)/256),t[i]-=256*r;t[i]+=r,t[n]=0}for(r=0,i=0;i<32;i++)t[i]+=r-(t[31]>>4)*ie[i],r=t[i]>>8,t[i]&=255;for(i=0;i<32;i++)t[i]-=r*ie[i];for(n=0;n<32;n++)t[n+1]+=t[n]>>8,e[n]=255&t[n]}function ae(e){var t,r=new Float64Array(64);for(t=0;t<64;t++)r[t]=e[t];for(t=0;t<64;t++)e[t]=0;oe(e,r)}function ue(e,r,n,i){var o,a,u=new Uint8Array(64),s=new Uint8Array(64),c=new Uint8Array(64),f=new Float64Array(64),l=[t(),t(),t(),t()];J(u,i,32),u[0]&=248,u[31]&=127,u[31]|=64;var h=n+64;for(o=0;o<n;o++)e[64+o]=r[o];for(o=0;o<32;o++)e[32+o]=u[32+o];for(J(c,e.subarray(32),n+32),ae(c),re(l,c),ee(e,l),o=32;o<64;o++)e[o]=i[o];for(J(s,e,n+64),ae(s),o=0;o<64;o++)f[o]=0;for(o=0;o<32;o++)f[o]=c[o];for(o=0;o<32;o++)for(a=0;a<32;a++)f[o+a]+=s[o]*u[a];return oe(e.subarray(32),f),h}function se(e,r,n,i){var o,s=new Uint8Array(32),f=new Uint8Array(64),l=[t(),t(),t(),t()],h=[t(),t(),t(),t()];if(n<64)return-1;if(function(e,r){var n=t(),i=t(),o=t(),s=t(),f=t(),l=t(),h=t();return I(e[2],u),L(e[1],r),D(o,e[1]),N(s,o,c),U(o,o,e[2]),z(s,e[2],s),D(f,s),D(l,f),N(h,l,f),N(n,h,o),N(n,n,s),q(n,n),N(n,n,o),N(n,n,s),N(n,n,s),N(e[0],n,s),D(i,e[0]),N(i,i,s),T(i,o)&&N(e[0],e[0],d),D(i,e[0]),N(i,i,s),T(i,o)?-1:(B(e[0])===r[31]>>7&&U(e[0],a,e[0]),N(e[3],e[0],e[1]),0)}(h,i))return-1;for(o=0;o<n;o++)e[o]=r[o];for(o=0;o<32;o++)e[o+32]=i[o];if(J(f,e,n),ae(f),te(l,h,f),re(h,r.subarray(32)),$(l,h),ee(s,l),n-=64,y(r,0,s,0)){for(o=0;o<n;o++)e[o]=0;return-1}for(o=0;o<n;o++)e[o]=r[o+64];return n}var ce=16,fe=64,le=32,he=64;function de(e,t){if(32!==e.length)throw new Error("bad key size");if(24!==t.length)throw new Error("bad nonce size")}function pe(){for(var e=0;e<arguments.length;e++)if(!(arguments[e]instanceof Uint8Array))throw new TypeError("unexpected type, use Uint8Array")}function be(e){for(var t=0;t<e.length;t++)e[t]=0}e.lowlevel={crypto_core_hsalsa20:g,crypto_stream_xor:S,crypto_stream:x,crypto_stream_salsa20_xor:k,crypto_stream_salsa20:_,crypto_onetimeauth:O,crypto_onetimeauth_verify:A,crypto_verify_16:v,crypto_verify_32:y,crypto_secretbox:M,crypto_secretbox_open:j,crypto_scalarmult:H,crypto_scalarmult_base:W,crypto_box_beforenm:V,crypto_box_afternm:Z,crypto_box:function(e,t,r,n,i,o){var a=new Uint8Array(32);return V(a,i,o),Z(e,t,r,n,a)},crypto_box_open:function(e,t,r,n,i,o){var a=new Uint8Array(32);return V(a,i,o),Y(e,t,r,n,a)},crypto_box_keypair:K,crypto_hash:J,crypto_sign:ue,crypto_sign_keypair:ne,crypto_sign_open:se,crypto_secretbox_KEYBYTES:32,crypto_secretbox_NONCEBYTES:24,crypto_secretbox_ZEROBYTES:32,crypto_secretbox_BOXZEROBYTES:ce,crypto_scalarmult_BYTES:32,crypto_scalarmult_SCALARBYTES:32,crypto_box_PUBLICKEYBYTES:32,crypto_box_SECRETKEYBYTES:32,crypto_box_BEFORENMBYTES:32,crypto_box_NONCEBYTES:24,crypto_box_ZEROBYTES:32,crypto_box_BOXZEROBYTES:16,crypto_sign_BYTES:fe,crypto_sign_PUBLICKEYBYTES:le,crypto_sign_SECRETKEYBYTES:he,crypto_sign_SEEDBYTES:32,crypto_hash_BYTES:64,gf:t,D:c,L:ie,pack25519:C,unpack25519:L,M:N,A:z,S:D,Z:U,pow2523:q,add:$,set25519:I,modL:oe,scalarmult:te,scalarbase:re},e.randomBytes=function(e){var t=new Uint8Array(e);return n(t,e),t},e.secretbox=function(e,t,r){pe(e,t,r),de(r,t);for(var n=new Uint8Array(32+e.length),i=new Uint8Array(n.length),o=0;o<e.length;o++)n[o+32]=e[o];return M(i,n,n.length,t,r),i.subarray(ce)},e.secretbox.open=function(e,t,r){pe(e,t,r),de(r,t);for(var n=new Uint8Array(ce+e.length),i=new Uint8Array(n.length),o=0;o<e.length;o++)n[o+ce]=e[o];return n.length<32||0!==j(i,n,n.length,t,r)?null:i.subarray(32)},e.secretbox.keyLength=32,e.secretbox.nonceLength=24,e.secretbox.overheadLength=ce,e.scalarMult=function(e,t){if(pe(e,t),32!==e.length)throw new Error("bad n size");if(32!==t.length)throw new Error("bad p size");var r=new Uint8Array(32);return H(r,e,t),r},e.scalarMult.base=function(e){if(pe(e),32!==e.length)throw new Error("bad n size");var t=new Uint8Array(32);return W(t,e),t},e.scalarMult.scalarLength=32,e.scalarMult.groupElementLength=32,e.box=function(t,r,n,i){var o=e.box.before(n,i);return e.secretbox(t,r,o)},e.box.before=function(e,t){pe(e,t),function(e,t){if(32!==e.length)throw new Error("bad public key size");if(32!==t.length)throw new Error("bad secret key size")}(e,t);var r=new Uint8Array(32);return V(r,e,t),r},e.box.after=e.secretbox,e.box.open=function(t,r,n,i){var o=e.box.before(n,i);return e.secretbox.open(t,r,o)},e.box.open.after=e.secretbox.open,e.box.keyPair=function(){var e=new Uint8Array(32),t=new Uint8Array(32);return K(e,t),{publicKey:e,secretKey:t}},e.box.keyPair.fromSecretKey=function(e){if(pe(e),32!==e.length)throw new Error("bad secret key size");var t=new Uint8Array(32);return W(t,e),{publicKey:t,secretKey:new Uint8Array(e)}},e.box.publicKeyLength=32,e.box.secretKeyLength=32,e.box.sharedKeyLength=32,e.box.nonceLength=24,e.box.overheadLength=e.secretbox.overheadLength,e.sign=function(e,t){if(pe(e,t),t.length!==he)throw new Error("bad secret key size");var r=new Uint8Array(fe+e.length);return ue(r,e,e.length,t),r},e.sign.open=function(e,t){if(pe(e,t),t.length!==le)throw new Error("bad public key size");var r=new Uint8Array(e.length),n=se(r,e,e.length,t);if(n<0)return null;for(var i=new Uint8Array(n),o=0;o<i.length;o++)i[o]=r[o];return i},e.sign.detached=function(t,r){for(var n=e.sign(t,r),i=new Uint8Array(fe),o=0;o<i.length;o++)i[o]=n[o];return i},e.sign.detached.verify=function(e,t,r){if(pe(e,t,r),t.length!==fe)throw new Error("bad signature size");if(r.length!==le)throw new Error("bad public key size");var n,i=new Uint8Array(fe+e.length),o=new Uint8Array(fe+e.length);for(n=0;n<fe;n++)i[n]=t[n];for(n=0;n<e.length;n++)i[n+fe]=e[n];return se(o,i,i.length,r)>=0},e.sign.keyPair=function(){var e=new Uint8Array(le),t=new Uint8Array(he);return ne(e,t),{publicKey:e,secretKey:t}},e.sign.keyPair.fromSecretKey=function(e){if(pe(e),e.length!==he)throw new Error("bad secret key size");for(var t=new Uint8Array(le),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(pe(e),32!==e.length)throw new Error("bad seed size");for(var t=new Uint8Array(le),r=new Uint8Array(he),n=0;n<32;n++)r[n]=e[n];return ne(t,r,!0),{publicKey:t,secretKey:r}},e.sign.publicKeyLength=le,e.sign.secretKeyLength=he,e.sign.seedLength=32,e.sign.signatureLength=fe,e.hash=function(e){pe(e);var t=new Uint8Array(64);return J(t,e,e.length),t},e.hash.hashLength=64,e.verify=function(e,t){return pe(e,t),0!==e.length&&0!==t.length&&(e.length===t.length&&0===b(e,0,t,0,e.length))},e.setPRNG=function(e){n=e},function(){var t="undefined"!==typeof self?self.crypto||self.msCrypto:null;if(t&&t.getRandomValues){e.setPRNG((function(e,r){var n,i=new Uint8Array(r);for(n=0;n<r;n+=65536)t.getRandomValues(i.subarray(n,n+Math.min(r-n,65536)));for(n=0;n<r;n++)e[n]=i[n];be(i)}))}else(t=r(108))&&t.randomBytes&&e.setPRNG((function(e,r){var n,i=t.randomBytes(r);for(n=0;n<r;n++)e[n]=i[n];be(i)}))}()}(e.exports?e.exports:self.nacl=self.nacl||{})},function(e,t,r){"use strict";var n=t,i=r(26),o=r(34),a=r(84);n.assert=o,n.toArray=a.toArray,n.zero2=a.zero2,n.toHex=a.toHex,n.encode=a.encode,n.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var i=1<<t+1,o=e.clone(),a=0;a<n.length;a++){var u,s=o.andln(i-1);o.isOdd()?(u=s>(i>>1)-1?(i>>1)-s:s,o.isubn(u)):u=0,n[a]=u,o.iushrn(1)}return n},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,i=0,o=0;e.cmpn(-i)>0||t.cmpn(-o)>0;){var a,u,s=e.andln(3)+i&3,c=t.andln(3)+o&3;3===s&&(s=-1),3===c&&(c=-1),a=0===(1&s)?0:3!==(n=e.andln(7)+i&7)&&5!==n||2!==c?s:-s,r[0].push(a),u=0===(1&c)?0:3!==(n=t.andln(7)+o&7)&&5!==n||2!==s?c:-c,r[1].push(u),2*i===a+1&&(i=1-i),2*o===u+1&&(o=1-o),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"===typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new i(e,"hex","le")}},function(e,t,r){"use strict";var n=r(34),i=r(57);function o(e,t){return 55296===(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320===(64512&e.charCodeAt(t+1)))}function a(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function u(e){return 1===e.length?"0"+e:e}function s(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=i,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"===typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!==0&&(e="0"+e),i=0;i<e.length;i+=2)r.push(parseInt(e[i]+e[i+1],16))}else for(var n=0,i=0;i<e.length;i++){var a=e.charCodeAt(i);a<128?r[n++]=a:a<2048?(r[n++]=a>>6|192,r[n++]=63&a|128):o(e,i)?(a=65536+((1023&a)<<10)+(1023&e.charCodeAt(++i)),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=63&a|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=63&a|128)}else for(i=0;i<e.length;i++)r[i]=0|e[i];return r},t.toHex=function(e){for(var t="",r=0;r<e.length;r++)t+=u(e[r].toString(16));return t},t.htonl=a,t.toHex32=function(e,t){for(var r="",n=0;n<e.length;n++){var i=e[n];"little"===t&&(i=a(i)),r+=s(i.toString(16))}return r},t.zero2=u,t.zero8=s,t.join32=function(e,t,r,i){var o=r-t;n(o%4===0);for(var a=new Array(o/4),u=0,s=t;u<a.length;u++,s+=4){var c;c="big"===i?e[s]<<24|e[s+1]<<16|e[s+2]<<8|e[s+3]:e[s+3]<<24|e[s+2]<<16|e[s+1]<<8|e[s],a[u]=c>>>0}return a},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n<e.length;n++,i+=4){var o=e[n];"big"===t?(r[i]=o>>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<<t|e>>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o<n?1:0)+r+i;e[t]=a>>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,n){return(t+n>>>0<t?1:0)+e+r>>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,o,a,u){var s=0,c=t;return s+=(c=c+n>>>0)<t?1:0,s+=(c=c+o>>>0)<o?1:0,e+r+i+a+(s+=(c=c+u>>>0)<u?1:0)>>>0},t.sum64_4_lo=function(e,t,r,n,i,o,a,u){return t+n+o+u>>>0},t.sum64_5_hi=function(e,t,r,n,i,o,a,u,s,c){var f=0,l=t;return f+=(l=l+n>>>0)<t?1:0,f+=(l=l+o>>>0)<o?1:0,f+=(l=l+u>>>0)<u?1:0,e+r+i+a+s+(f+=(l=l+c>>>0)<c?1:0)>>>0},t.sum64_5_lo=function(e,t,r,n,i,o,a,u,s,c){return t+n+o+u+c>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"===typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!==typeof window&&"undefined"!==typeof window.Buffer?window.Buffer:r(111).Buffer}catch(M){}function u(e,t){var r=e.charCodeAt(t);return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:void n(!1,"Invalid character in "+e)}function s(e,t,r){var n=u(e,r);return r-1>=t&&(n|=u(e,r-1)<<4),n}function c(e,t,r,i){for(var o=0,a=0,u=Math.min(e.length,r),s=t;s<u;s++){var c=e.charCodeAt(s)-48;o*=i,a=c>=49?c-49+10:c>=17?c-17+10:c,n(c>=0&&a<i,"Invalid character"),o+=a}return o}function f(e,t){e.words=t.words,e.length=t.length,e.negative=t.negative,e.red=t.red}if(o.isBN=function(e){return e instanceof o||null!==e&&"object"===typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i<e.length&&(16===t?this._parseHex(e,i,r):(this._parseBase(e,t,i),"le"===r&&this._initArray(this.toArray(),t,r)))},o.prototype._initNumber=function(e,t,r){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(n(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},o.prototype._initArray=function(e,t,r){if(n("number"===typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var i=0;i<this.length;i++)this.words[i]=0;var o,a,u=0;if("be"===r)for(i=e.length-1,o=0;i>=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<<u&67108863,this.words[o+1]=a>>>26-u&67108863,(u+=24)>=26&&(u-=26,o++);else if("le"===r)for(i=0,o=0;i<e.length;i+=3)a=e[i]|e[i+1]<<8|e[i+2]<<16,this.words[o]|=a<<u&67108863,this.words[o+1]=a>>>26-u&67108863,(u+=24)>=26&&(u-=26,o++);return this._strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var i,o=0,a=0;if("be"===r)for(n=e.length-1;n>=t;n-=2)i=s(e,t,n)<<o,this.words[a]|=67108863&i,o>=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2===0?t+1:t;n<e.length;n+=2)i=s(e,t,n)<<o,this.words[a]|=67108863&i,o>=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this._strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,u=Math.min(o,o-a)+r,s=0,f=r;f<u;f+=n)s=c(e,f,f+n,t),this.imuln(i),this.words[0]+s<67108864?this.words[0]+=s:this._iaddn(s);if(0!==a){var l=1;for(s=c(e,f,e.length,t),f=0;f<a;f++)l*=t;this.imuln(l),this.words[0]+s<67108864?this.words[0]+=s:this._iaddn(s)}this._strip()},o.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},o.prototype._move=function(e){f(e,this)},o.prototype.clone=function(){var e=new o(null);return this.copy(e),e},o.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},o.prototype._strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!==typeof Symbol&&"function"===typeof Symbol.for)try{o.prototype[Symbol.for("nodejs.util.inspect.custom")]=l}catch(M){o.prototype.inspect=l}else o.prototype.inspect=l;function l(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var h=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],d=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a<this.length;a++){var u=this.words[a],s=(16777215&(u<<i|o)).toString(16);r=0!==(o=u>>>24-i&16777215)||a!==this.length-1?h[6-s.length]+s+r:s+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=d[e],f=p[e];r="";var l=this.clone();for(l.negative=0;!l.isZero();){var b=l.modrn(f).toString(e);r=(l=l.idivn(f)).isZero()?b+r:h[c-b.length]+b+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16,2)},a&&(o.prototype.toBuffer=function(e,t){return this.toArrayLike(a,e,t)}),o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)};function b(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,u=67108863&a,s=a/67108864|0;r.words[0]=u;for(var c=1;c<n;c++){for(var f=s>>>26,l=67108863&s,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;f+=(a=(i=0|e.words[p])*(o=0|t.words[d])+l)/67108864|0,l=67108863&a}r.words[c]=0|l,s=0|f}return 0!==s?r.words[c]=0|s:r.length--,r._strip()}o.prototype.toArrayLike=function(e,t,r){this._strip();var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0");var a=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,o);return this["_toArrayLike"+("le"===t?"LE":"BE")](a,i),a},o.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,i=0,o=0;i<this.length;i++){var a=this.words[i]<<o|n;e[r++]=255&a,r<e.length&&(e[r++]=a>>8&255),r<e.length&&(e[r++]=a>>16&255),6===o?(r<e.length&&(e[r++]=a>>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r<e.length)for(e[r++]=n;r<e.length;)e[r++]=0},o.prototype._toArrayLikeBE=function(e,t){for(var r=e.length-1,n=0,i=0,o=0;i<this.length;i++){var a=this.words[i]<<o|n;e[r--]=255&a,r>=0&&(e[r--]=a>>8&255),r>=0&&(e[r--]=a>>16&255),6===o?(r>=0&&(e[r--]=a>>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var r=this._zeroBits(this.words[t]);if(e+=r,26!==r)break}return e},o.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},o.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},o.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},o.prototype.isNeg=function(){return 0!==this.negative},o.prototype.neg=function(){return this.clone().ineg()},o.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},o.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this._strip()},o.prototype.ior=function(e){return n(0===(this.negative|e.negative)),this.iuor(e)},o.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;r<t.length;r++)this.words[r]=this.words[r]&e.words[r];return this.length=t.length,this._strip()},o.prototype.iand=function(e){return n(0===(this.negative|e.negative)),this.iuand(e)},o.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;n<r.length;n++)this.words[n]=t.words[n]^r.words[n];if(this!==t)for(;n<t.length;n++)this.words[n]=t.words[n];return this.length=t.length,this._strip()},o.prototype.ixor=function(e){return n(0===(this.negative|e.negative)),this.iuxor(e)},o.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i<t;i++)this.words[i]=67108863&~this.words[i];return r>0&&(this.words[i]=~this.words[i]&67108863>>26-r),this._strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<<i:this.words[r]&~(1<<i),this._strip()},o.prototype.iadd=function(e){var t,r,n;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o<n.length;o++)t=(0|r.words[o])+(0|n.words[o])+i,this.words[o]=67108863&t,i=t>>>26;for(;0!==i&&o<r.length;o++)t=(0|r.words[o])+i,this.words[o]=67108863&t,i=t>>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;o<r.length;o++)this.words[o]=r.words[o];return this},o.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a<n.length;a++)o=(t=(0|r.words[a])-(0|n.words[a])+o)>>26,this.words[a]=67108863&t;for(;0!==o&&a<r.length;a++)o=(t=(0|r.words[a])+o)>>26,this.words[a]=67108863&t;if(0===o&&a<r.length&&r!==this)for(;a<r.length;a++)this.words[a]=r.words[a];return this.length=Math.max(this.length,a),r!==this&&(this.negative=1),this._strip()},o.prototype.sub=function(e){return this.clone().isub(e)};var v=function(e,t,r){var n,i,o,a=e.words,u=t.words,s=r.words,c=0,f=0|a[0],l=8191&f,h=f>>>13,d=0|a[1],p=8191&d,b=d>>>13,v=0|a[2],y=8191&v,m=v>>>13,g=0|a[3],w=8191&g,k=g>>>13,_=0|a[4],x=8191&_,S=_>>>13,E=0|a[5],O=8191&E,A=E>>>13,M=0|a[6],j=8191&M,I=M>>>13,P=0|a[7],R=8191&P,C=P>>>13,T=0|a[8],B=8191&T,L=T>>>13,z=0|a[9],U=8191&z,N=z>>>13,D=0|u[0],F=8191&D,q=D>>>13,H=0|u[1],W=8191&H,K=H>>>13,V=0|u[2],Z=8191&V,Y=V>>>13,X=0|u[3],G=8191&X,J=X>>>13,$=0|u[4],Q=8191&$,ee=$>>>13,te=0|u[5],re=8191&te,ne=te>>>13,ie=0|u[6],oe=8191&ie,ae=ie>>>13,ue=0|u[7],se=8191&ue,ce=ue>>>13,fe=0|u[8],le=8191&fe,he=fe>>>13,de=0|u[9],pe=8191&de,be=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ve=(c+(n=Math.imul(l,F))|0)+((8191&(i=(i=Math.imul(l,q))+Math.imul(h,F)|0))<<13)|0;c=((o=Math.imul(h,q))+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(p,F),i=(i=Math.imul(p,q))+Math.imul(b,F)|0,o=Math.imul(b,q);var ye=(c+(n=n+Math.imul(l,W)|0)|0)+((8191&(i=(i=i+Math.imul(l,K)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,K)|0)+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(y,F),i=(i=Math.imul(y,q))+Math.imul(m,F)|0,o=Math.imul(m,q),n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,K)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,K)|0;var me=(c+(n=n+Math.imul(l,Z)|0)|0)+((8191&(i=(i=i+Math.imul(l,Y)|0)+Math.imul(h,Z)|0))<<13)|0;c=((o=o+Math.imul(h,Y)|0)+(i>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(w,F),i=(i=Math.imul(w,q))+Math.imul(k,F)|0,o=Math.imul(k,q),n=n+Math.imul(y,W)|0,i=(i=i+Math.imul(y,K)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,K)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,Y)|0)+Math.imul(b,Z)|0,o=o+Math.imul(b,Y)|0;var ge=(c+(n=n+Math.imul(l,G)|0)|0)+((8191&(i=(i=i+Math.imul(l,J)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,J)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(x,F),i=(i=Math.imul(x,q))+Math.imul(S,F)|0,o=Math.imul(S,q),n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,K)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,K)|0,n=n+Math.imul(y,Z)|0,i=(i=i+Math.imul(y,Y)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,Y)|0,n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,J)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,J)|0;var we=(c+(n=n+Math.imul(l,Q)|0)|0)+((8191&(i=(i=i+Math.imul(l,ee)|0)+Math.imul(h,Q)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(O,F),i=(i=Math.imul(O,q))+Math.imul(A,F)|0,o=Math.imul(A,q),n=n+Math.imul(x,W)|0,i=(i=i+Math.imul(x,K)|0)+Math.imul(S,W)|0,o=o+Math.imul(S,K)|0,n=n+Math.imul(w,Z)|0,i=(i=i+Math.imul(w,Y)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,Y)|0,n=n+Math.imul(y,G)|0,i=(i=i+Math.imul(y,J)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,J)|0,n=n+Math.imul(p,Q)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(b,Q)|0,o=o+Math.imul(b,ee)|0;var ke=(c+(n=n+Math.imul(l,re)|0)|0)+((8191&(i=(i=i+Math.imul(l,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(j,F),i=(i=Math.imul(j,q))+Math.imul(I,F)|0,o=Math.imul(I,q),n=n+Math.imul(O,W)|0,i=(i=i+Math.imul(O,K)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,K)|0,n=n+Math.imul(x,Z)|0,i=(i=i+Math.imul(x,Y)|0)+Math.imul(S,Z)|0,o=o+Math.imul(S,Y)|0,n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,J)|0)+Math.imul(k,G)|0,o=o+Math.imul(k,J)|0,n=n+Math.imul(y,Q)|0,i=(i=i+Math.imul(y,ee)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0;var _e=(c+(n=n+Math.imul(l,oe)|0)|0)+((8191&(i=(i=i+Math.imul(l,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(R,F),i=(i=Math.imul(R,q))+Math.imul(C,F)|0,o=Math.imul(C,q),n=n+Math.imul(j,W)|0,i=(i=i+Math.imul(j,K)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,K)|0,n=n+Math.imul(O,Z)|0,i=(i=i+Math.imul(O,Y)|0)+Math.imul(A,Z)|0,o=o+Math.imul(A,Y)|0,n=n+Math.imul(x,G)|0,i=(i=i+Math.imul(x,J)|0)+Math.imul(S,G)|0,o=o+Math.imul(S,J)|0,n=n+Math.imul(w,Q)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,ee)|0,n=n+Math.imul(y,re)|0,i=(i=i+Math.imul(y,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0;var xe=(c+(n=n+Math.imul(l,se)|0)|0)+((8191&(i=(i=i+Math.imul(l,ce)|0)+Math.imul(h,se)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(B,F),i=(i=Math.imul(B,q))+Math.imul(L,F)|0,o=Math.imul(L,q),n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,K)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,K)|0,n=n+Math.imul(j,Z)|0,i=(i=i+Math.imul(j,Y)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,Y)|0,n=n+Math.imul(O,G)|0,i=(i=i+Math.imul(O,J)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,J)|0,n=n+Math.imul(x,Q)|0,i=(i=i+Math.imul(x,ee)|0)+Math.imul(S,Q)|0,o=o+Math.imul(S,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ne)|0,n=n+Math.imul(y,oe)|0,i=(i=i+Math.imul(y,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0,n=n+Math.imul(p,se)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(b,se)|0,o=o+Math.imul(b,ce)|0;var Se=(c+(n=n+Math.imul(l,le)|0)|0)+((8191&(i=(i=i+Math.imul(l,he)|0)+Math.imul(h,le)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(U,F),i=(i=Math.imul(U,q))+Math.imul(N,F)|0,o=Math.imul(N,q),n=n+Math.imul(B,W)|0,i=(i=i+Math.imul(B,K)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,K)|0,n=n+Math.imul(R,Z)|0,i=(i=i+Math.imul(R,Y)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,Y)|0,n=n+Math.imul(j,G)|0,i=(i=i+Math.imul(j,J)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,J)|0,n=n+Math.imul(O,Q)|0,i=(i=i+Math.imul(O,ee)|0)+Math.imul(A,Q)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(x,re)|0,i=(i=i+Math.imul(x,ne)|0)+Math.imul(S,re)|0,o=o+Math.imul(S,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,ae)|0,n=n+Math.imul(y,se)|0,i=(i=i+Math.imul(y,ce)|0)+Math.imul(m,se)|0,o=o+Math.imul(m,ce)|0,n=n+Math.imul(p,le)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(b,le)|0,o=o+Math.imul(b,he)|0;var Ee=(c+(n=n+Math.imul(l,pe)|0)|0)+((8191&(i=(i=i+Math.imul(l,be)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,be)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(U,W),i=(i=Math.imul(U,K))+Math.imul(N,W)|0,o=Math.imul(N,K),n=n+Math.imul(B,Z)|0,i=(i=i+Math.imul(B,Y)|0)+Math.imul(L,Z)|0,o=o+Math.imul(L,Y)|0,n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,J)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,J)|0,n=n+Math.imul(j,Q)|0,i=(i=i+Math.imul(j,ee)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(O,re)|0,i=(i=i+Math.imul(O,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(x,oe)|0,i=(i=i+Math.imul(x,ae)|0)+Math.imul(S,oe)|0,o=o+Math.imul(S,ae)|0,n=n+Math.imul(w,se)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(k,se)|0,o=o+Math.imul(k,ce)|0,n=n+Math.imul(y,le)|0,i=(i=i+Math.imul(y,he)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,he)|0;var Oe=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,be)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,be)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(U,Z),i=(i=Math.imul(U,Y))+Math.imul(N,Z)|0,o=Math.imul(N,Y),n=n+Math.imul(B,G)|0,i=(i=i+Math.imul(B,J)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,J)|0,n=n+Math.imul(R,Q)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(j,re)|0,i=(i=i+Math.imul(j,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(O,oe)|0,i=(i=i+Math.imul(O,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(x,se)|0,i=(i=i+Math.imul(x,ce)|0)+Math.imul(S,se)|0,o=o+Math.imul(S,ce)|0,n=n+Math.imul(w,le)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,he)|0;var Ae=(c+(n=n+Math.imul(y,pe)|0)|0)+((8191&(i=(i=i+Math.imul(y,be)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,be)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(U,G),i=(i=Math.imul(U,J))+Math.imul(N,G)|0,o=Math.imul(N,J),n=n+Math.imul(B,Q)|0,i=(i=i+Math.imul(B,ee)|0)+Math.imul(L,Q)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(j,oe)|0,i=(i=i+Math.imul(j,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(O,se)|0,i=(i=i+Math.imul(O,ce)|0)+Math.imul(A,se)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(x,le)|0,i=(i=i+Math.imul(x,he)|0)+Math.imul(S,le)|0,o=o+Math.imul(S,he)|0;var Me=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,be)|0)+Math.imul(k,pe)|0))<<13)|0;c=((o=o+Math.imul(k,be)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(U,Q),i=(i=Math.imul(U,ee))+Math.imul(N,Q)|0,o=Math.imul(N,ee),n=n+Math.imul(B,re)|0,i=(i=i+Math.imul(B,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(j,se)|0,i=(i=i+Math.imul(j,ce)|0)+Math.imul(I,se)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(O,le)|0,i=(i=i+Math.imul(O,he)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,he)|0;var je=(c+(n=n+Math.imul(x,pe)|0)|0)+((8191&(i=(i=i+Math.imul(x,be)|0)+Math.imul(S,pe)|0))<<13)|0;c=((o=o+Math.imul(S,be)|0)+(i>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(U,re),i=(i=Math.imul(U,ne))+Math.imul(N,re)|0,o=Math.imul(N,ne),n=n+Math.imul(B,oe)|0,i=(i=i+Math.imul(B,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,se)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,se)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(j,le)|0,i=(i=i+Math.imul(j,he)|0)+Math.imul(I,le)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(O,pe)|0)|0)+((8191&(i=(i=i+Math.imul(O,be)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,be)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(U,oe),i=(i=Math.imul(U,ae))+Math.imul(N,oe)|0,o=Math.imul(N,ae),n=n+Math.imul(B,se)|0,i=(i=i+Math.imul(B,ce)|0)+Math.imul(L,se)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,le)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,le)|0,o=o+Math.imul(C,he)|0;var Pe=(c+(n=n+Math.imul(j,pe)|0)|0)+((8191&(i=(i=i+Math.imul(j,be)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,be)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(U,se),i=(i=Math.imul(U,ce))+Math.imul(N,se)|0,o=Math.imul(N,ce),n=n+Math.imul(B,le)|0,i=(i=i+Math.imul(B,he)|0)+Math.imul(L,le)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,be)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,be)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(U,le),i=(i=Math.imul(U,he))+Math.imul(N,le)|0,o=Math.imul(N,he);var Ce=(c+(n=n+Math.imul(B,pe)|0)|0)+((8191&(i=(i=i+Math.imul(B,be)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,be)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Te=(c+(n=Math.imul(U,pe))|0)+((8191&(i=(i=Math.imul(U,be))+Math.imul(N,pe)|0))<<13)|0;return c=((o=Math.imul(N,be))+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,s[0]=ve,s[1]=ye,s[2]=me,s[3]=ge,s[4]=we,s[5]=ke,s[6]=_e,s[7]=xe,s[8]=Se,s[9]=Ee,s[10]=Oe,s[11]=Ae,s[12]=Me,s[13]=je,s[14]=Ie,s[15]=Pe,s[16]=Re,s[17]=Ce,s[18]=Te,0!==c&&(s[19]=c,r.length++),r};function y(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o<r.length-1;o++){var a=i;i=0;for(var u=67108863&n,s=Math.min(o,t.length-1),c=Math.max(0,o-e.length+1);c<=s;c++){var f=o-c,l=(0|e.words[f])*(0|t.words[c]),h=67108863&l;u=67108863&(h=h+u|0),i+=(a=(a=a+(l/67108864|0)|0)+(h>>>26)|0)>>>26,a&=67108863}r.words[o]=u,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r._strip()}function m(e,t,r){return y(e,t,r)}function g(e,t){this.x=e,this.y=t}Math.imul||(v=b),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?v(this,e,t):r<63?b(this,e,t):r<1024?y(this,e,t):m(this,e,t)},g.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n<e;n++)t[n]=this.revBin(n,r,e);return t},g.prototype.revBin=function(e,t,r){if(0===e||e===r-1)return e;for(var n=0,i=0;i<t;i++)n|=(1&e)<<t-i-1,e>>=1;return n},g.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a<o;a++)n[a]=t[e[a]],i[a]=r[e[a]]},g.prototype.transform=function(e,t,r,n,i,o){this.permute(o,e,t,r,n,i);for(var a=1;a<i;a<<=1)for(var u=a<<1,s=Math.cos(2*Math.PI/u),c=Math.sin(2*Math.PI/u),f=0;f<i;f+=u)for(var l=s,h=c,d=0;d<a;d++){var p=r[f+d],b=n[f+d],v=r[f+d+a],y=n[f+d+a],m=l*v-h*y;y=l*y+h*v,v=m,r[f+d]=p+v,n[f+d]=b+y,r[f+d+a]=p-v,n[f+d+a]=b-y,d!==u&&(m=s*l-c*h,h=s*h+c*l,l=m)}},g.prototype.guessLen13b=function(e,t){var r=1|Math.max(t,e),n=1&r,i=0;for(r=r/2|0;r;r>>>=1)i++;return 1<<i+1+n},g.prototype.conjugate=function(e,t,r){if(!(r<=1))for(var n=0;n<r/2;n++){var i=e[n];e[n]=e[r-n-1],e[r-n-1]=i,i=t[n],t[n]=-t[r-n-1],t[r-n-1]=-i}},g.prototype.normalize13b=function(e,t){for(var r=0,n=0;n<t/2;n++){var i=8192*Math.round(e[2*n+1]/t)+Math.round(e[2*n]/t)+r;e[n]=67108863&i,r=i<67108864?0:i/67108864|0}return e},g.prototype.convert13b=function(e,t,r,i){for(var o=0,a=0;a<t;a++)o+=0|e[a],r[2*a]=8191&o,o>>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a<i;++a)r[a]=0;n(0===o),n(0===(-8192&o))},g.prototype.stub=function(e){for(var t=new Array(e),r=0;r<e;r++)t[r]=0;return t},g.prototype.mulp=function(e,t,r){var n=2*this.guessLen13b(e.length,t.length),i=this.makeRBT(n),o=this.stub(n),a=new Array(n),u=new Array(n),s=new Array(n),c=new Array(n),f=new Array(n),l=new Array(n),h=r.words;h.length=n,this.convert13b(e.words,e.length,a,n),this.convert13b(t.words,t.length,c,n),this.transform(a,o,u,s,n,i),this.transform(c,o,f,l,n,i);for(var d=0;d<n;d++){var p=u[d]*f[d]-s[d]*l[d];s[d]=u[d]*l[d]+s[d]*f[d],u[d]=p}return this.conjugate(u,s,n),this.transform(u,s,h,o,n,i),this.conjugate(h,o,n),this.normalize13b(h,n),r.negative=e.negative^t.negative,r.length=e.length+t.length,r._strip()},o.prototype.mul=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},o.prototype.mulf=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),m(this,e,t)},o.prototype.imul=function(e){return this.clone().mulTo(e,this)},o.prototype.imuln=function(e){var t=e<0;t&&(e=-e),n("number"===typeof e),n(e<67108864);for(var r=0,i=0;i<this.length;i++){var o=(0|this.words[i])*e,a=(67108863&o)+(67108863&r);r>>=26,r+=o/67108864|0,r+=a>>>26,this.words[i]=67108863&a}return 0!==r&&(this.words[i]=r,this.length++),t?this.ineg():this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r<t.length;r++){var n=r/26|0,i=r%26;t[r]=e.words[n]>>>i&1}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n<t.length&&0===t[n];n++,r=r.sqr());if(++n<t.length)for(var i=r.sqr();n<t.length;n++,i=i.sqr())0!==t[n]&&(r=r.mul(i));return r},o.prototype.iushln=function(e){n("number"===typeof e&&e>=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t<this.length;t++){var u=this.words[t]&o,s=(0|this.words[t])-u<<r;this.words[t]=s|a,a=u>>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t<i;t++)this.words[t]=0;this.length+=i}return this._strip()},o.prototype.ishln=function(e){return n(0===this.negative),this.iushln(e)},o.prototype.iushrn=function(e,t,r){var i;n("number"===typeof e&&e>=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),u=67108863^67108863>>>o<<o,s=r;if(i-=a,i=Math.max(0,i),s){for(var c=0;c<a;c++)s.words[c]=this.words[c];s.length=a}if(0===a);else if(this.length>a)for(this.length-=a,c=0;c<this.length;c++)this.words[c]=this.words[c+a];else this.words[0]=0,this.length=1;var f=0;for(c=this.length-1;c>=0&&(0!==f||c>=i);c--){var l=0|this.words[c];this.words[c]=f<<26-o|l>>>o,f=l&u}return s&&0!==f&&(s.words[s.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<<t;return!(this.length<=r)&&!!(this.words[r]&i)},o.prototype.imaskn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<<t;this.words[this.length-1]&=i}return this._strip()},o.prototype.maskn=function(e){return this.clone().imaskn(e)},o.prototype.iaddn=function(e){return n("number"===typeof e),n(e<67108864),e<0?this.isubn(-e):0!==this.negative?1===this.length&&(0|this.words[0])<=e?(this.words[0]=e-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(e),this.negative=1,this):this._iaddn(e)},o.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&this.words[t]>=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this._strip()},o.prototype.addn=function(e){return this.clone().iaddn(e)},o.prototype.subn=function(e){return this.clone().isubn(e)},o.prototype.iabs=function(){return this.negative=0,this},o.prototype.abs=function(){return this.clone().iabs()},o.prototype._ishlnsubmul=function(e,t,r){var i,o,a=e.length+r;this._expand(a);var u=0;for(i=0;i<e.length;i++){o=(0|this.words[i+r])+u;var s=(0|e.words[i])*t;u=((o-=67108863&s)>>26)-(s/67108864|0),this.words[i+r]=67108863&o}for(;i<this.length-r;i++)u=(o=(0|this.words[i+r])+u)>>26,this.words[i+r]=67108863&o;if(0===u)return this._strip();for(n(-1===u),u=0,i=0;i<this.length;i++)u=(o=-(0|this.words[i])+u)>>26,this.words[i]=67108863&o;return this.negative=1,this._strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var u,s=n.length-i.length;if("mod"!==t){(u=new o(null)).length=s+1,u.words=new Array(u.length);for(var c=0;c<u.length;c++)u.words[c]=0}var f=n.clone()._ishlnsubmul(i,1,s);0===f.negative&&(n=f,u&&(u.words[s]=1));for(var l=s-1;l>=0;l--){var h=67108864*(0|n.words[i.length+l])+(0|n.words[i.length+l-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,l);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,l),n.isZero()||(n.negative^=1);u&&(u.words[l]=h)}return u&&u._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:u||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(u=this.neg().divmod(e,t),"mod"!==t&&(i=u.div.neg()),"div"!==t&&(a=u.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(u=this.divmod(e.neg(),t),"mod"!==t&&(i=u.div.neg()),{div:i,mod:u.mod}):0!==(this.negative&e.negative)?(u=this.neg().divmod(e.neg(),t),"div"!==t&&(a=u.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:u.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modrn(e.words[0]))}:this._wordDiv(e,t);var i,a,u},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modrn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=(1<<26)%e,i=0,o=this.length-1;o>=0;o--)i=(r*i+(0|this.words[o]))%e;return t?-i:i},o.prototype.modn=function(e){return this.modrn(e)},o.prototype.idivn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=0,i=this.length-1;i>=0;i--){var o=(0|this.words[i])+67108864*r;this.words[i]=o/e|0,r=o%e}return this._strip(),t?this.ineg():this},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),u=new o(0),s=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var f=r.clone(),l=t.clone();!t.isZero();){for(var h=0,d=1;0===(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(f),a.isub(l)),i.iushrn(1),a.iushrn(1);for(var p=0,b=1;0===(r.words[0]&b)&&p<26;++p,b<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(u.isOdd()||s.isOdd())&&(u.iadd(f),s.isub(l)),u.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(u),a.isub(s)):(r.isub(t),u.isub(i),s.isub(a))}return{a:u,b:s,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),u=new o(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,f=1;0===(t.words[0]&f)&&c<26;++c,f<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(s),a.iushrn(1);for(var l=0,h=1;0===(r.words[0]&h)&&l<26;++l,h<<=1);if(l>0)for(r.iushrn(l);l-- >0;)u.isOdd()&&u.iadd(s),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(u)):(r.isub(t),u.isub(a))}return(i=0===t.cmpn(1)?a:u).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,i=1<<t;if(this.length<=r)return this._expand(r+1),this.words[r]|=i,this;for(var o=i,a=r;0!==o&&a<this.length;a++){var u=0|this.words[a];o=(u+=o)>>>26,u&=67108863,this.words[a]=u}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:i<e?-1:1}return 0!==this.negative?0|-t:t},o.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},o.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,r=this.length-1;r>=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){n<i?t=-1:n>i&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new O(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var w={k256:null,p224:null,p192:null,p25519:null};function k(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function _(){k.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function x(){k.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function S(){k.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function E(){k.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function O(e){if("string"===typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function A(e){O.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}k.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},k.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t<this.n?-1:r.ucmp(this.p);return 0===n?(r.words[0]=0,r.length=1):n>0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},k.prototype.split=function(e,t){e.iushrn(this.n,0,t)},k.prototype.imulK=function(e){return e.imul(this.k)},i(_,k),_.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i<n;i++)t.words[i]=e.words[i];if(t.length=n,e.length<=9)return e.words[0]=0,void(e.length=1);var o=e.words[9];for(t.words[t.length++]=o&r,i=10;i<e.length;i++){var a=0|e.words[i];e.words[i-10]=(a&r)<<4|o>>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},_.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r<e.length;r++){var n=0|e.words[r];t+=977*n,e.words[r]=67108863&t,t=64*n+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},i(x,k),i(S,k),i(E,k),E.prototype.imulK=function(e){for(var t=0,r=0;r<e.length;r++){var n=19*(0|e.words[r])+t,i=67108863&n;n>>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(w[e])return w[e];var t;if("k256"===e)t=new _;else if("p224"===e)t=new x;else if("p192"===e)t=new S;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new E}return w[e]=t,t},O.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},O.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},O.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(f(e,e.umod(this.m)._forceRed(this)),e)},O.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},O.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},O.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},O.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},O.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},O.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},O.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},O.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},O.prototype.isqr=function(e){return this.imul(e,e.clone())},O.prototype.sqr=function(e){return this.mul(e,e)},O.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var u=new o(1).toRed(this),s=u.redNeg(),c=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,c).cmp(s);)f.redIAdd(s);for(var l=this.pow(f,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(u);){for(var b=d,v=0;0!==b.cmp(u);v++)b=b.redSqr();n(v<p);var y=this.pow(l,new o(1).iushln(p-v-1));h=h.redMul(y),l=y.redSqr(),d=d.redMul(l),p=v}return h},O.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},O.prototype.pow=function(e,t){if(t.isZero())return new o(1).toRed(this);if(0===t.cmpn(1))return e.clone();var r=new Array(16);r[0]=new o(1).toRed(this),r[1]=e;for(var n=2;n<r.length;n++)r[n]=this.mul(r[n-1],e);var i=r[0],a=0,u=0,s=t.bitLength()%26;for(0===s&&(s=26),n=t.length-1;n>=0;n--){for(var c=t.words[n],f=s-1;f>=0;f--){var l=c>>f&1;i!==r[0]&&(i=this.sqr(i)),0!==l||0!==a?(a<<=1,a|=l,(4===++u||0===n&&0===f)&&(i=this.mul(i,r[a]),u=0,a=0)):u=0}s=26}return i},O.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},O.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new A(e)},i(A,O),A.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},A.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},A.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(79)(e))},function(e,t,r){"use strict";e.exports=r(101)},function(e,t,r){"use strict";r.d(t,"d",(function(){return i})),r.d(t,"b",(function(){return o.a})),r.d(t,"c",(function(){return o.b})),r.d(t,"a",(function(){return Nr}));var n={};r.r(n),r.d(n,"decode",(function(){return zr})),r.d(n,"encode",(function(){return Ur}));r(23);var i=r(8),o=r(36),a=r(17),u=r(18),s=r(16),c=r.n(s),f=r(98),l=r(3),h=r(9),d=r(4),p=r(5),b=r(1),v=r.n(b);function y(e){for(var t=e.length;--t>=0;)e[t]=0}var m=256,g=286,w=30,k=15,_=new Uint8Array([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0]),x=new Uint8Array([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13]),S=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),E=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),O=new Array(576);y(O);var A=new Array(60);y(A);var M=new Array(512);y(M);var j=new Array(256);y(j);var I=new Array(29);y(I);var P,R,C,T=new Array(w);function B(e,t,r,n,i){this.static_tree=e,this.extra_bits=t,this.extra_base=r,this.elems=n,this.max_length=i,this.has_stree=e&&e.length}function L(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}y(T);var z=function(e){return e<256?M[e]:M[256+(e>>>7)]},U=function(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255},N=function(e,t,r){e.bi_valid>16-r?(e.bi_buf|=t<<e.bi_valid&65535,U(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=r-16):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=r)},D=function(e,t,r){N(e,r[2*t],r[2*t+1])},F=function(e,t){var r=0;do{r|=1&e,e>>>=1,r<<=1}while(--t>0);return r>>>1},q=function(e,t,r){var n,i,o=new Array(16),a=0;for(n=1;n<=k;n++)o[n]=a=a+r[n-1]<<1;for(i=0;i<=t;i++){var u=e[2*i+1];0!==u&&(e[2*i]=F(o[u]++,u))}},H=function(e){var t;for(t=0;t<g;t++)e.dyn_ltree[2*t]=0;for(t=0;t<w;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0},W=function(e){e.bi_valid>8?U(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0},K=function(e,t,r,n){var i=2*t,o=2*r;return e[i]<e[o]||e[i]===e[o]&&n[t]<=n[r]},V=function(e,t,r){for(var n=e.heap[r],i=r<<1;i<=e.heap_len&&(i<e.heap_len&&K(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!K(t,n,e.heap[i],e.depth));)e.heap[r]=e.heap[i],r=i,i<<=1;e.heap[r]=n},Z=function(e,t,r){var n,i,o,a,u=0;if(0!==e.last_lit)do{n=e.pending_buf[e.d_buf+2*u]<<8|e.pending_buf[e.d_buf+2*u+1],i=e.pending_buf[e.l_buf+u],u++,0===n?D(e,i,t):(o=j[i],D(e,o+m+1,t),0!==(a=_[o])&&(i-=I[o],N(e,i,a)),n--,o=z(n),D(e,o,r),0!==(a=x[o])&&(n-=T[o],N(e,n,a)))}while(u<e.last_lit);D(e,256,t)},Y=function(e,t){var r,n,i,o=t.dyn_tree,a=t.stat_desc.static_tree,u=t.stat_desc.has_stree,s=t.stat_desc.elems,c=-1;for(e.heap_len=0,e.heap_max=573,r=0;r<s;r++)0!==o[2*r]?(e.heap[++e.heap_len]=c=r,e.depth[r]=0):o[2*r+1]=0;for(;e.heap_len<2;)o[2*(i=e.heap[++e.heap_len]=c<2?++c:0)]=1,e.depth[i]=0,e.opt_len--,u&&(e.static_len-=a[2*i+1]);for(t.max_code=c,r=e.heap_len>>1;r>=1;r--)V(e,o,r);i=s;do{r=e.heap[1],e.heap[1]=e.heap[e.heap_len--],V(e,o,1),n=e.heap[1],e.heap[--e.heap_max]=r,e.heap[--e.heap_max]=n,o[2*i]=o[2*r]+o[2*n],e.depth[i]=(e.depth[r]>=e.depth[n]?e.depth[r]:e.depth[n])+1,o[2*r+1]=o[2*n+1]=i,e.heap[1]=i++,V(e,o,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var r,n,i,o,a,u,s=t.dyn_tree,c=t.max_code,f=t.stat_desc.static_tree,l=t.stat_desc.has_stree,h=t.stat_desc.extra_bits,d=t.stat_desc.extra_base,p=t.stat_desc.max_length,b=0;for(o=0;o<=k;o++)e.bl_count[o]=0;for(s[2*e.heap[e.heap_max]+1]=0,r=e.heap_max+1;r<573;r++)(o=s[2*s[2*(n=e.heap[r])+1]+1]+1)>p&&(o=p,b++),s[2*n+1]=o,n>c||(e.bl_count[o]++,a=0,n>=d&&(a=h[n-d]),u=s[2*n],e.opt_len+=u*(o+a),l&&(e.static_len+=u*(f[2*n+1]+a)));if(0!==b){do{for(o=p-1;0===e.bl_count[o];)o--;e.bl_count[o]--,e.bl_count[o+1]+=2,e.bl_count[p]--,b-=2}while(b>0);for(o=p;0!==o;o--)for(n=e.bl_count[o];0!==n;)(i=e.heap[--r])>c||(s[2*i+1]!==o&&(e.opt_len+=(o-s[2*i+1])*s[2*i],s[2*i+1]=o),n--)}}(e,t),q(o,c,e.bl_count)},X=function(e,t,r){var n,i,o=-1,a=t[1],u=0,s=7,c=4;for(0===a&&(s=138,c=3),t[2*(r+1)+1]=65535,n=0;n<=r;n++)i=a,a=t[2*(n+1)+1],++u<s&&i===a||(u<c?e.bl_tree[2*i]+=u:0!==i?(i!==o&&e.bl_tree[2*i]++,e.bl_tree[32]++):u<=10?e.bl_tree[34]++:e.bl_tree[36]++,u=0,o=i,0===a?(s=138,c=3):i===a?(s=6,c=3):(s=7,c=4))},G=function(e,t,r){var n,i,o=-1,a=t[1],u=0,s=7,c=4;for(0===a&&(s=138,c=3),n=0;n<=r;n++)if(i=a,a=t[2*(n+1)+1],!(++u<s&&i===a)){if(u<c)do{D(e,i,e.bl_tree)}while(0!==--u);else 0!==i?(i!==o&&(D(e,i,e.bl_tree),u--),D(e,16,e.bl_tree),N(e,u-3,2)):u<=10?(D(e,17,e.bl_tree),N(e,u-3,3)):(D(e,18,e.bl_tree),N(e,u-11,7));u=0,o=i,0===a?(s=138,c=3):i===a?(s=6,c=3):(s=7,c=4)}},J=!1,$=function(e,t,r,n){N(e,0+(n?1:0),3),function(e,t,r,n){W(e),n&&(U(e,r),U(e,~r)),e.pending_buf.set(e.window.subarray(t,t+r),e.pending),e.pending+=r}(e,t,r,!0)},Q=function(e,t,r,n){var i,o,a=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,r=4093624447;for(t=0;t<=31;t++,r>>>=1)if(1&r&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<m;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),Y(e,e.l_desc),Y(e,e.d_desc),a=function(e){var t;for(X(e,e.dyn_ltree,e.l_desc.max_code),X(e,e.dyn_dtree,e.d_desc.max_code),Y(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*E[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),i=e.opt_len+3+7>>>3,(o=e.static_len+3+7>>>3)<=i&&(i=o)):i=o=r+5,r+4<=i&&-1!==t?$(e,t,r,n):4===e.strategy||o===i?(N(e,2+(n?1:0),3),Z(e,O,A)):(N(e,4+(n?1:0),3),function(e,t,r,n){var i;for(N(e,t-257,5),N(e,r-1,5),N(e,n-4,4),i=0;i<n;i++)N(e,e.bl_tree[2*E[i]+1],3);G(e,e.dyn_ltree,t-1),G(e,e.dyn_dtree,r-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,a+1),Z(e,e.dyn_ltree,e.dyn_dtree)),H(e),n&&W(e)},ee={_tr_init:function(e){J||(!function(){var e,t,r,n,i,o=new Array(16);for(r=0,n=0;n<28;n++)for(I[n]=r,e=0;e<1<<_[n];e++)j[r++]=n;for(j[r-1]=n,i=0,n=0;n<16;n++)for(T[n]=i,e=0;e<1<<x[n];e++)M[i++]=n;for(i>>=7;n<w;n++)for(T[n]=i<<7,e=0;e<1<<x[n]-7;e++)M[256+i++]=n;for(t=0;t<=k;t++)o[t]=0;for(e=0;e<=143;)O[2*e+1]=8,e++,o[8]++;for(;e<=255;)O[2*e+1]=9,e++,o[9]++;for(;e<=279;)O[2*e+1]=7,e++,o[7]++;for(;e<=287;)O[2*e+1]=8,e++,o[8]++;for(q(O,287,o),e=0;e<w;e++)A[2*e+1]=5,A[2*e]=F(e,5);P=new B(O,_,257,g,k),R=new B(A,x,0,w,k),C=new B(new Array(0),S,0,19,7)}(),J=!0),e.l_desc=new L(e.dyn_ltree,P),e.d_desc=new L(e.dyn_dtree,R),e.bl_desc=new L(e.bl_tree,C),e.bi_buf=0,e.bi_valid=0,H(e)},_tr_stored_block:$,_tr_flush_block:Q,_tr_tally:function(e,t,r){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&r,e.last_lit++,0===t?e.dyn_ltree[2*r]++:(e.matches++,t--,e.dyn_ltree[2*(j[r]+m+1)]++,e.dyn_dtree[2*z(t)]++),e.last_lit===e.lit_bufsize-1},_tr_align:function(e){N(e,2,3),D(e,256,O),function(e){16===e.bi_valid?(U(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)}},te=function(e,t,r,n){for(var i=65535&e|0,o=e>>>16&65535|0,a=0;0!==r;){r-=a=r>2e3?2e3:r;do{o=o+(i=i+t[n++]|0)|0}while(--a);i%=65521,o%=65521}return i|o<<16|0},re=new Uint32Array(function(){for(var e,t=[],r=0;r<256;r++){e=r;for(var n=0;n<8;n++)e=1&e?3988292384^e>>>1:e>>>1;t[r]=e}return t}()),ne=function(e,t,r,n){var i=re,o=n+r;e^=-1;for(var a=n;a<o;a++)e=e>>>8^i[255&(e^t[a])];return-1^e},ie={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},oe={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8},ae=ee._tr_init,ue=ee._tr_stored_block,se=ee._tr_flush_block,ce=ee._tr_tally,fe=ee._tr_align,le=oe.Z_NO_FLUSH,he=oe.Z_PARTIAL_FLUSH,de=oe.Z_FULL_FLUSH,pe=oe.Z_FINISH,be=oe.Z_BLOCK,ve=oe.Z_OK,ye=oe.Z_STREAM_END,me=oe.Z_STREAM_ERROR,ge=oe.Z_DATA_ERROR,we=oe.Z_BUF_ERROR,ke=oe.Z_DEFAULT_COMPRESSION,_e=oe.Z_FILTERED,xe=oe.Z_HUFFMAN_ONLY,Se=oe.Z_RLE,Ee=oe.Z_FIXED,Oe=oe.Z_DEFAULT_STRATEGY,Ae=oe.Z_UNKNOWN,Me=oe.Z_DEFLATED,je=258,Ie=262,Pe=103,Re=113,Ce=666,Te=function(e,t){return e.msg=ie[t],t},Be=function(e){return(e<<1)-(e>4?9:0)},Le=function(e){for(var t=e.length;--t>=0;)e[t]=0},ze=function(e,t,r){return(t<<e.hash_shift^r)&e.hash_mask},Ue=function(e){var t=e.state,r=t.pending;r>e.avail_out&&(r=e.avail_out),0!==r&&(e.output.set(t.pending_buf.subarray(t.pending_out,t.pending_out+r),e.next_out),e.next_out+=r,t.pending_out+=r,e.total_out+=r,e.avail_out-=r,t.pending-=r,0===t.pending&&(t.pending_out=0))},Ne=function(e,t){se(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,Ue(e.strm)},De=function(e,t){e.pending_buf[e.pending++]=t},Fe=function(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t},qe=function(e,t,r,n){var i=e.avail_in;return i>n&&(i=n),0===i?0:(e.avail_in-=i,t.set(e.input.subarray(e.next_in,e.next_in+i),r),1===e.state.wrap?e.adler=te(e.adler,t,i,r):2===e.state.wrap&&(e.adler=ne(e.adler,t,i,r)),e.next_in+=i,e.total_in+=i,i)},He=function(e,t){var r,n,i=e.max_chain_length,o=e.strstart,a=e.prev_length,u=e.nice_match,s=e.strstart>e.w_size-Ie?e.strstart-(e.w_size-Ie):0,c=e.window,f=e.w_mask,l=e.prev,h=e.strstart+je,d=c[o+a-1],p=c[o+a];e.prev_length>=e.good_match&&(i>>=2),u>e.lookahead&&(u=e.lookahead);do{if(c[(r=t)+a]===p&&c[r+a-1]===d&&c[r]===c[o]&&c[++r]===c[o+1]){o+=2,r++;do{}while(c[++o]===c[++r]&&c[++o]===c[++r]&&c[++o]===c[++r]&&c[++o]===c[++r]&&c[++o]===c[++r]&&c[++o]===c[++r]&&c[++o]===c[++r]&&c[++o]===c[++r]&&o<h);if(n=je-(h-o),o=h-je,n>a){if(e.match_start=t,a=n,n>=u)break;d=c[o+a-1],p=c[o+a]}}}while((t=l[t&f])>s&&0!==--i);return a<=e.lookahead?a:e.lookahead},We=function(e){var t,r,n,i,o,a=e.w_size;do{if(i=e.window_size-e.lookahead-e.strstart,e.strstart>=a+(a-Ie)){e.window.set(e.window.subarray(a,a+a),0),e.match_start-=a,e.strstart-=a,e.block_start-=a,t=r=e.hash_size;do{n=e.head[--t],e.head[t]=n>=a?n-a:0}while(--r);t=r=a;do{n=e.prev[--t],e.prev[t]=n>=a?n-a:0}while(--r);i+=a}if(0===e.strm.avail_in)break;if(r=qe(e.strm,e.window,e.strstart+e.lookahead,i),e.lookahead+=r,e.lookahead+e.insert>=3)for(o=e.strstart-e.insert,e.ins_h=e.window[o],e.ins_h=ze(e,e.ins_h,e.window[o+1]);e.insert&&(e.ins_h=ze(e,e.ins_h,e.window[o+3-1]),e.prev[o&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=o,o++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<Ie&&0!==e.strm.avail_in)},Ke=function(e,t){for(var r,n;;){if(e.lookahead<Ie){if(We(e),e.lookahead<Ie&&t===le)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=3&&(e.ins_h=ze(e,e.ins_h,e.window[e.strstart+3-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==r&&e.strstart-r<=e.w_size-Ie&&(e.match_length=He(e,r)),e.match_length>=3)if(n=ce(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=3){e.match_length--;do{e.strstart++,e.ins_h=ze(e,e.ins_h,e.window[e.strstart+3-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!==--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=ze(e,e.ins_h,e.window[e.strstart+1]);else n=ce(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(n&&(Ne(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<2?e.strstart:2,t===pe?(Ne(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Ne(e,!1),0===e.strm.avail_out)?1:2},Ve=function(e,t){for(var r,n,i;;){if(e.lookahead<Ie){if(We(e),e.lookahead<Ie&&t===le)return 1;if(0===e.lookahead)break}if(r=0,e.lookahead>=3&&(e.ins_h=ze(e,e.ins_h,e.window[e.strstart+3-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==r&&e.prev_length<e.max_lazy_match&&e.strstart-r<=e.w_size-Ie&&(e.match_length=He(e,r),e.match_length<=5&&(e.strategy===_e||3===e.match_length&&e.strstart-e.match_start>4096)&&(e.match_length=2)),e.prev_length>=3&&e.match_length<=e.prev_length){i=e.strstart+e.lookahead-3,n=ce(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=i&&(e.ins_h=ze(e,e.ins_h,e.window[e.strstart+3-1]),r=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!==--e.prev_length);if(e.match_available=0,e.match_length=2,e.strstart++,n&&(Ne(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((n=ce(e,0,e.window[e.strstart-1]))&&Ne(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(n=ce(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,t===pe?(Ne(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Ne(e,!1),0===e.strm.avail_out)?1:2};function Ze(e,t,r,n,i){this.good_length=e,this.max_lazy=t,this.nice_length=r,this.max_chain=n,this.func=i}var Ye=[new Ze(0,0,0,0,(function(e,t){var r=65535;for(r>e.pending_buf_size-5&&(r=e.pending_buf_size-5);;){if(e.lookahead<=1){if(We(e),0===e.lookahead&&t===le)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var n=e.block_start+r;if((0===e.strstart||e.strstart>=n)&&(e.lookahead=e.strstart-n,e.strstart=n,Ne(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-Ie&&(Ne(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,t===pe?(Ne(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(Ne(e,!1),e.strm.avail_out),1)})),new Ze(4,4,8,4,Ke),new Ze(4,5,16,8,Ke),new Ze(4,6,32,32,Ke),new Ze(4,4,16,16,Ve),new Ze(8,16,32,32,Ve),new Ze(8,16,128,128,Ve),new Ze(8,32,128,256,Ve),new Ze(32,128,258,1024,Ve),new Ze(32,258,258,4096,Ve)];function Xe(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Me,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(1146),this.dyn_dtree=new Uint16Array(122),this.bl_tree=new Uint16Array(78),Le(this.dyn_ltree),Le(this.dyn_dtree),Le(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(16),this.heap=new Uint16Array(573),Le(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),Le(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}var Ge=function(e){if(!e||!e.state)return Te(e,me);e.total_in=e.total_out=0,e.data_type=Ae;var t=e.state;return t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?42:Re,e.adler=2===t.wrap?0:1,t.last_flush=le,ae(t),ve},Je=function(e){var t,r=Ge(e);return r===ve&&((t=e.state).window_size=2*t.w_size,Le(t.head),t.max_lazy_match=Ye[t.level].max_lazy,t.good_match=Ye[t.level].good_length,t.nice_match=Ye[t.level].nice_length,t.max_chain_length=Ye[t.level].max_chain,t.strstart=0,t.block_start=0,t.lookahead=0,t.insert=0,t.match_length=t.prev_length=2,t.match_available=0,t.ins_h=0),r},$e=function(e,t,r,n,i,o){if(!e)return me;var a=1;if(t===ke&&(t=6),n<0?(a=0,n=-n):n>15&&(a=2,n-=16),i<1||i>9||r!==Me||n<8||n>15||t<0||t>9||o<0||o>Ee)return Te(e,me);8===n&&(n=9);var u=new Xe;return e.state=u,u.strm=e,u.wrap=a,u.gzhead=null,u.w_bits=n,u.w_size=1<<u.w_bits,u.w_mask=u.w_size-1,u.hash_bits=i+7,u.hash_size=1<<u.hash_bits,u.hash_mask=u.hash_size-1,u.hash_shift=~~((u.hash_bits+3-1)/3),u.window=new Uint8Array(2*u.w_size),u.head=new Uint16Array(u.hash_size),u.prev=new Uint16Array(u.w_size),u.lit_bufsize=1<<i+6,u.pending_buf_size=4*u.lit_bufsize,u.pending_buf=new Uint8Array(u.pending_buf_size),u.d_buf=1*u.lit_bufsize,u.l_buf=3*u.lit_bufsize,u.level=t,u.strategy=o,u.method=r,Je(e)},Qe={deflateInit:function(e,t){return $e(e,t,Me,15,8,Oe)},deflateInit2:$e,deflateReset:Je,deflateResetKeep:Ge,deflateSetHeader:function(e,t){return e&&e.state?2!==e.state.wrap?me:(e.state.gzhead=t,ve):me},deflate:function(e,t){var r,n;if(!e||!e.state||t>be||t<0)return e?Te(e,me):me;var i=e.state;if(!e.output||!e.input&&0!==e.avail_in||i.status===Ce&&t!==pe)return Te(e,0===e.avail_out?we:me);i.strm=e;var o=i.last_flush;if(i.last_flush=t,42===i.status)if(2===i.wrap)e.adler=0,De(i,31),De(i,139),De(i,8),i.gzhead?(De(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),De(i,255&i.gzhead.time),De(i,i.gzhead.time>>8&255),De(i,i.gzhead.time>>16&255),De(i,i.gzhead.time>>24&255),De(i,9===i.level?2:i.strategy>=xe||i.level<2?4:0),De(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(De(i,255&i.gzhead.extra.length),De(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=ne(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69):(De(i,0),De(i,0),De(i,0),De(i,0),De(i,0),De(i,9===i.level?2:i.strategy>=xe||i.level<2?4:0),De(i,3),i.status=Re);else{var a=Me+(i.w_bits-8<<4)<<8;a|=(i.strategy>=xe||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(a|=32),a+=31-a%31,i.status=Re,Fe(i,a),0!==i.strstart&&(Fe(i,e.adler>>>16),Fe(i,65535&e.adler)),e.adler=1}if(69===i.status)if(i.gzhead.extra){for(r=i.pending;i.gzindex<(65535&i.gzhead.extra.length)&&(i.pending!==i.pending_buf_size||(i.gzhead.hcrc&&i.pending>r&&(e.adler=ne(e.adler,i.pending_buf,i.pending-r,r)),Ue(e),r=i.pending,i.pending!==i.pending_buf_size));)De(i,255&i.gzhead.extra[i.gzindex]),i.gzindex++;i.gzhead.hcrc&&i.pending>r&&(e.adler=ne(e.adler,i.pending_buf,i.pending-r,r)),i.gzindex===i.gzhead.extra.length&&(i.gzindex=0,i.status=73)}else i.status=73;if(73===i.status)if(i.gzhead.name){r=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>r&&(e.adler=ne(e.adler,i.pending_buf,i.pending-r,r)),Ue(e),r=i.pending,i.pending===i.pending_buf_size)){n=1;break}n=i.gzindex<i.gzhead.name.length?255&i.gzhead.name.charCodeAt(i.gzindex++):0,De(i,n)}while(0!==n);i.gzhead.hcrc&&i.pending>r&&(e.adler=ne(e.adler,i.pending_buf,i.pending-r,r)),0===n&&(i.gzindex=0,i.status=91)}else i.status=91;if(91===i.status)if(i.gzhead.comment){r=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>r&&(e.adler=ne(e.adler,i.pending_buf,i.pending-r,r)),Ue(e),r=i.pending,i.pending===i.pending_buf_size)){n=1;break}n=i.gzindex<i.gzhead.comment.length?255&i.gzhead.comment.charCodeAt(i.gzindex++):0,De(i,n)}while(0!==n);i.gzhead.hcrc&&i.pending>r&&(e.adler=ne(e.adler,i.pending_buf,i.pending-r,r)),0===n&&(i.status=Pe)}else i.status=Pe;if(i.status===Pe&&(i.gzhead.hcrc?(i.pending+2>i.pending_buf_size&&Ue(e),i.pending+2<=i.pending_buf_size&&(De(i,255&e.adler),De(i,e.adler>>8&255),e.adler=0,i.status=Re)):i.status=Re),0!==i.pending){if(Ue(e),0===e.avail_out)return i.last_flush=-1,ve}else if(0===e.avail_in&&Be(t)<=Be(o)&&t!==pe)return Te(e,we);if(i.status===Ce&&0!==e.avail_in)return Te(e,we);if(0!==e.avail_in||0!==i.lookahead||t!==le&&i.status!==Ce){var u=i.strategy===xe?function(e,t){for(var r;;){if(0===e.lookahead&&(We(e),0===e.lookahead)){if(t===le)return 1;break}if(e.match_length=0,r=ce(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,r&&(Ne(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,t===pe?(Ne(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Ne(e,!1),0===e.strm.avail_out)?1:2}(i,t):i.strategy===Se?function(e,t){for(var r,n,i,o,a=e.window;;){if(e.lookahead<=je){if(We(e),e.lookahead<=je&&t===le)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=3&&e.strstart>0&&(n=a[i=e.strstart-1])===a[++i]&&n===a[++i]&&n===a[++i]){o=e.strstart+je;do{}while(n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&n===a[++i]&&i<o);e.match_length=je-(o-i),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(r=ce(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(r=ce(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),r&&(Ne(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,t===pe?(Ne(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(Ne(e,!1),0===e.strm.avail_out)?1:2}(i,t):Ye[i.level].func(i,t);if(3!==u&&4!==u||(i.status=Ce),1===u||3===u)return 0===e.avail_out&&(i.last_flush=-1),ve;if(2===u&&(t===he?fe(i):t!==be&&(ue(i,0,0,!1),t===de&&(Le(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),Ue(e),0===e.avail_out))return i.last_flush=-1,ve}return t!==pe?ve:i.wrap<=0?ye:(2===i.wrap?(De(i,255&e.adler),De(i,e.adler>>8&255),De(i,e.adler>>16&255),De(i,e.adler>>24&255),De(i,255&e.total_in),De(i,e.total_in>>8&255),De(i,e.total_in>>16&255),De(i,e.total_in>>24&255)):(Fe(i,e.adler>>>16),Fe(i,65535&e.adler)),Ue(e),i.wrap>0&&(i.wrap=-i.wrap),0!==i.pending?ve:ye)},deflateEnd:function(e){if(!e||!e.state)return me;var t=e.state.status;return 42!==t&&69!==t&&73!==t&&91!==t&&t!==Pe&&t!==Re&&t!==Ce?Te(e,me):(e.state=null,t===Re?Te(e,ge):ve)},deflateSetDictionary:function(e,t){var r=t.length;if(!e||!e.state)return me;var n=e.state,i=n.wrap;if(2===i||1===i&&42!==n.status||n.lookahead)return me;if(1===i&&(e.adler=te(e.adler,t,r,0)),n.wrap=0,r>=n.w_size){0===i&&(Le(n.head),n.strstart=0,n.block_start=0,n.insert=0);var o=new Uint8Array(n.w_size);o.set(t.subarray(r-n.w_size,r),0),t=o,r=n.w_size}var a=e.avail_in,u=e.next_in,s=e.input;for(e.avail_in=r,e.next_in=0,e.input=t,We(n);n.lookahead>=3;){var c=n.strstart,f=n.lookahead-2;do{n.ins_h=ze(n,n.ins_h,n.window[c+3-1]),n.prev[c&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=c,c++}while(--f);n.strstart=c,n.lookahead=2,We(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=2,n.match_available=0,e.next_in=u,e.input=s,e.avail_in=a,n.wrap=i,ve},deflateInfo:"pako deflate (from Nodeca project)"},et=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},tt=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var r=t.shift();if(r){if("object"!==typeof r)throw new TypeError(r+"must be non-object");for(var n in r)et(r,n)&&(e[n]=r[n])}}return e},rt=function(e){for(var t=0,r=0,n=e.length;r<n;r++)t+=e[r].length;for(var i=new Uint8Array(t),o=0,a=0,u=e.length;o<u;o++){var s=e[o];i.set(s,a),a+=s.length}return i},nt=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(qr){nt=!1}for(var it=new Uint8Array(256),ot=0;ot<256;ot++)it[ot]=ot>=252?6:ot>=248?5:ot>=240?4:ot>=224?3:ot>=192?2:1;it[254]=it[254]=1;var at=function(e){if("function"===typeof TextEncoder&&TextEncoder.prototype.encode)return(new TextEncoder).encode(e);var t,r,n,i,o,a=e.length,u=0;for(i=0;i<a;i++)55296===(64512&(r=e.charCodeAt(i)))&&i+1<a&&56320===(64512&(n=e.charCodeAt(i+1)))&&(r=65536+(r-55296<<10)+(n-56320),i++),u+=r<128?1:r<2048?2:r<65536?3:4;for(t=new Uint8Array(u),o=0,i=0;o<u;i++)55296===(64512&(r=e.charCodeAt(i)))&&i+1<a&&56320===(64512&(n=e.charCodeAt(i+1)))&&(r=65536+(r-55296<<10)+(n-56320),i++),r<128?t[o++]=r:r<2048?(t[o++]=192|r>>>6,t[o++]=128|63&r):r<65536?(t[o++]=224|r>>>12,t[o++]=128|r>>>6&63,t[o++]=128|63&r):(t[o++]=240|r>>>18,t[o++]=128|r>>>12&63,t[o++]=128|r>>>6&63,t[o++]=128|63&r);return t},ut=function(e,t){var r,n,i=t||e.length;if("function"===typeof TextDecoder&&TextDecoder.prototype.decode)return(new TextDecoder).decode(e.subarray(0,t));var o=new Array(2*i);for(n=0,r=0;r<i;){var a=e[r++];if(a<128)o[n++]=a;else{var u=it[a];if(u>4)o[n++]=65533,r+=u-1;else{for(a&=2===u?31:3===u?15:7;u>1&&r<i;)a=a<<6|63&e[r++],u--;u>1?o[n++]=65533:a<65536?o[n++]=a:(a-=65536,o[n++]=55296|a>>10&1023,o[n++]=56320|1023&a)}}}return function(e,t){if(t<65534&&e.subarray&&nt)return String.fromCharCode.apply(null,e.length===t?e:e.subarray(0,t));for(var r="",n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r}(o,n)},st=function(e,t){(t=t||e.length)>e.length&&(t=e.length);for(var r=t-1;r>=0&&128===(192&e[r]);)r--;return r<0||0===r?t:r+it[e[r]]>t?r:t};var ct=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0},ft=Object.prototype.toString,lt=oe.Z_NO_FLUSH,ht=oe.Z_SYNC_FLUSH,dt=oe.Z_FULL_FLUSH,pt=oe.Z_FINISH,bt=oe.Z_OK,vt=oe.Z_STREAM_END,yt=oe.Z_DEFAULT_COMPRESSION,mt=oe.Z_DEFAULT_STRATEGY,gt=oe.Z_DEFLATED;function wt(e){this.options=tt({level:yt,method:gt,chunkSize:16384,windowBits:15,memLevel:8,strategy:mt},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new ct,this.strm.avail_out=0;var r=Qe.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(r!==bt)throw new Error(ie[r]);if(t.header&&Qe.deflateSetHeader(this.strm,t.header),t.dictionary){var n;if(n="string"===typeof t.dictionary?at(t.dictionary):"[object ArrayBuffer]"===ft.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(r=Qe.deflateSetDictionary(this.strm,n))!==bt)throw new Error(ie[r]);this._dict_set=!0}}wt.prototype.push=function(e,t){var r,n,i=this.strm,o=this.options.chunkSize;if(this.ended)return!1;for(n=t===~~t?t:!0===t?pt:lt,"string"===typeof e?i.input=at(e):"[object ArrayBuffer]"===ft.call(e)?i.input=new Uint8Array(e):i.input=e,i.next_in=0,i.avail_in=i.input.length;;)if(0===i.avail_out&&(i.output=new Uint8Array(o),i.next_out=0,i.avail_out=o),(n===ht||n===dt)&&i.avail_out<=6)this.onData(i.output.subarray(0,i.next_out)),i.avail_out=0;else{if((r=Qe.deflate(i,n))===vt)return i.next_out>0&&this.onData(i.output.subarray(0,i.next_out)),r=Qe.deflateEnd(this.strm),this.onEnd(r),this.ended=!0,r===bt;if(0!==i.avail_out){if(n>0&&i.next_out>0)this.onData(i.output.subarray(0,i.next_out)),i.avail_out=0;else if(0===i.avail_in)break}else this.onData(i.output)}return!0},wt.prototype.onData=function(e){this.chunks.push(e)},wt.prototype.onEnd=function(e){e===bt&&(this.result=rt(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var kt=function(e,t){var r,n,i,o,a,u,s,c,f,l,h,d,p,b,v,y,m,g,w,k,_,x,S,E,O=e.state;r=e.next_in,S=e.input,n=r+(e.avail_in-5),i=e.next_out,E=e.output,o=i-(t-e.avail_out),a=i+(e.avail_out-257),u=O.dmax,s=O.wsize,c=O.whave,f=O.wnext,l=O.window,h=O.hold,d=O.bits,p=O.lencode,b=O.distcode,v=(1<<O.lenbits)-1,y=(1<<O.distbits)-1;e:do{d<15&&(h+=S[r++]<<d,d+=8,h+=S[r++]<<d,d+=8),m=p[h&v];t:for(;;){if(h>>>=g=m>>>24,d-=g,0===(g=m>>>16&255))E[i++]=65535&m;else{if(!(16&g)){if(0===(64&g)){m=p[(65535&m)+(h&(1<<g)-1)];continue t}if(32&g){O.mode=12;break e}e.msg="invalid literal/length code",O.mode=30;break e}w=65535&m,(g&=15)&&(d<g&&(h+=S[r++]<<d,d+=8),w+=h&(1<<g)-1,h>>>=g,d-=g),d<15&&(h+=S[r++]<<d,d+=8,h+=S[r++]<<d,d+=8),m=b[h&y];r:for(;;){if(h>>>=g=m>>>24,d-=g,!(16&(g=m>>>16&255))){if(0===(64&g)){m=b[(65535&m)+(h&(1<<g)-1)];continue r}e.msg="invalid distance code",O.mode=30;break e}if(k=65535&m,d<(g&=15)&&(h+=S[r++]<<d,(d+=8)<g&&(h+=S[r++]<<d,d+=8)),(k+=h&(1<<g)-1)>u){e.msg="invalid distance too far back",O.mode=30;break e}if(h>>>=g,d-=g,k>(g=i-o)){if((g=k-g)>c&&O.sane){e.msg="invalid distance too far back",O.mode=30;break e}if(_=0,x=l,0===f){if(_+=s-g,g<w){w-=g;do{E[i++]=l[_++]}while(--g);_=i-k,x=E}}else if(f<g){if(_+=s+f-g,(g-=f)<w){w-=g;do{E[i++]=l[_++]}while(--g);if(_=0,f<w){w-=g=f;do{E[i++]=l[_++]}while(--g);_=i-k,x=E}}}else if(_+=f-g,g<w){w-=g;do{E[i++]=l[_++]}while(--g);_=i-k,x=E}for(;w>2;)E[i++]=x[_++],E[i++]=x[_++],E[i++]=x[_++],w-=3;w&&(E[i++]=x[_++],w>1&&(E[i++]=x[_++]))}else{_=i-k;do{E[i++]=E[_++],E[i++]=E[_++],E[i++]=E[_++],w-=3}while(w>2);w&&(E[i++]=E[_++],w>1&&(E[i++]=E[_++]))}break}}break}}while(r<n&&i<a);r-=w=d>>3,h&=(1<<(d-=w<<3))-1,e.next_in=r,e.next_out=i,e.avail_in=r<n?n-r+5:5-(r-n),e.avail_out=i<a?a-i+257:257-(i-a),O.hold=h,O.bits=d},_t=15,xt=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),St=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),Et=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),Ot=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]),At=function(e,t,r,n,i,o,a,u){var s,c,f,l,h,d,p,b,v,y=u.bits,m=0,g=0,w=0,k=0,_=0,x=0,S=0,E=0,O=0,A=0,M=null,j=0,I=new Uint16Array(16),P=new Uint16Array(16),R=null,C=0;for(m=0;m<=_t;m++)I[m]=0;for(g=0;g<n;g++)I[t[r+g]]++;for(_=y,k=_t;k>=1&&0===I[k];k--);if(_>k&&(_=k),0===k)return i[o++]=20971520,i[o++]=20971520,u.bits=1,0;for(w=1;w<k&&0===I[w];w++);for(_<w&&(_=w),E=1,m=1;m<=_t;m++)if(E<<=1,(E-=I[m])<0)return-1;if(E>0&&(0===e||1!==k))return-1;for(P[1]=0,m=1;m<_t;m++)P[m+1]=P[m]+I[m];for(g=0;g<n;g++)0!==t[r+g]&&(a[P[t[r+g]]++]=g);if(0===e?(M=R=a,d=19):1===e?(M=xt,j-=257,R=St,C-=257,d=256):(M=Et,R=Ot,d=-1),A=0,g=0,m=w,h=o,x=_,S=0,f=-1,l=(O=1<<_)-1,1===e&&O>852||2===e&&O>592)return 1;for(;;){p=m-S,a[g]<d?(b=0,v=a[g]):a[g]>d?(b=R[C+a[g]],v=M[j+a[g]]):(b=96,v=0),s=1<<m-S,w=c=1<<x;do{i[h+(A>>S)+(c-=s)]=p<<24|b<<16|v|0}while(0!==c);for(s=1<<m-1;A&s;)s>>=1;if(0!==s?(A&=s-1,A+=s):A=0,g++,0===--I[m]){if(m===k)break;m=t[r+a[g]]}if(m>_&&(A&l)!==f){for(0===S&&(S=_),h+=w,E=1<<(x=m-S);x+S<k&&!((E-=I[x+S])<=0);)x++,E<<=1;if(O+=1<<x,1===e&&O>852||2===e&&O>592)return 1;i[f=A&l]=_<<24|x<<16|h-o|0}}return 0!==A&&(i[h+A]=m-S<<24|64<<16|0),u.bits=_,0},Mt=oe.Z_FINISH,jt=oe.Z_BLOCK,It=oe.Z_TREES,Pt=oe.Z_OK,Rt=oe.Z_STREAM_END,Ct=oe.Z_NEED_DICT,Tt=oe.Z_STREAM_ERROR,Bt=oe.Z_DATA_ERROR,Lt=oe.Z_MEM_ERROR,zt=oe.Z_BUF_ERROR,Ut=oe.Z_DEFLATED,Nt=12,Dt=30,Ft=function(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)};function qt(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}var Ht,Wt,Kt=function(e){if(!e||!e.state)return Tt;var t=e.state;return e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=1,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(852),t.distcode=t.distdyn=new Int32Array(592),t.sane=1,t.back=-1,Pt},Vt=function(e){if(!e||!e.state)return Tt;var t=e.state;return t.wsize=0,t.whave=0,t.wnext=0,Kt(e)},Zt=function(e,t){var r;if(!e||!e.state)return Tt;var n=e.state;return t<0?(r=0,t=-t):(r=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?Tt:(null!==n.window&&n.wbits!==t&&(n.window=null),n.wrap=r,n.wbits=t,Vt(e))},Yt=function(e,t){if(!e)return Tt;var r=new qt;e.state=r,r.window=null;var n=Zt(e,t);return n!==Pt&&(e.state=null),n},Xt=!0,Gt=function(e){if(Xt){Ht=new Int32Array(512),Wt=new Int32Array(32);for(var t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(At(1,e.lens,0,288,Ht,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;At(2,e.lens,0,32,Wt,0,e.work,{bits:5}),Xt=!1}e.lencode=Ht,e.lenbits=9,e.distcode=Wt,e.distbits=5},Jt=function(e,t,r,n){var i,o=e.state;return null===o.window&&(o.wsize=1<<o.wbits,o.wnext=0,o.whave=0,o.window=new Uint8Array(o.wsize)),n>=o.wsize?(o.window.set(t.subarray(r-o.wsize,r),0),o.wnext=0,o.whave=o.wsize):((i=o.wsize-o.wnext)>n&&(i=n),o.window.set(t.subarray(r-n,r-n+i),o.wnext),(n-=i)?(o.window.set(t.subarray(r-n,r),0),o.wnext=n,o.whave=o.wsize):(o.wnext+=i,o.wnext===o.wsize&&(o.wnext=0),o.whave<o.wsize&&(o.whave+=i))),0},$t={inflateReset:Vt,inflateReset2:Zt,inflateResetKeep:Kt,inflateInit:function(e){return Yt(e,15)},inflateInit2:Yt,inflate:function(e,t){var r,n,i,o,a,u,s,c,f,l,h,d,p,b,v,y,m,g,w,k,_,x,S,E,O=0,A=new Uint8Array(4),M=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return Tt;(r=e.state).mode===Nt&&(r.mode=13),a=e.next_out,i=e.output,s=e.avail_out,o=e.next_in,n=e.input,u=e.avail_in,c=r.hold,f=r.bits,l=u,h=s,x=Pt;e:for(;;)switch(r.mode){case 1:if(0===r.wrap){r.mode=13;break}for(;f<16;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(2&r.wrap&&35615===c){r.check=0,A[0]=255&c,A[1]=c>>>8&255,r.check=ne(r.check,A,2,0),c=0,f=0,r.mode=2;break}if(r.flags=0,r.head&&(r.head.done=!1),!(1&r.wrap)||(((255&c)<<8)+(c>>8))%31){e.msg="incorrect header check",r.mode=Dt;break}if((15&c)!==Ut){e.msg="unknown compression method",r.mode=Dt;break}if(f-=4,_=8+(15&(c>>>=4)),0===r.wbits)r.wbits=_;else if(_>r.wbits){e.msg="invalid window size",r.mode=Dt;break}r.dmax=1<<r.wbits,e.adler=r.check=1,r.mode=512&c?10:Nt,c=0,f=0;break;case 2:for(;f<16;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(r.flags=c,(255&r.flags)!==Ut){e.msg="unknown compression method",r.mode=Dt;break}if(57344&r.flags){e.msg="unknown header flags set",r.mode=Dt;break}r.head&&(r.head.text=c>>8&1),512&r.flags&&(A[0]=255&c,A[1]=c>>>8&255,r.check=ne(r.check,A,2,0)),c=0,f=0,r.mode=3;case 3:for(;f<32;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}r.head&&(r.head.time=c),512&r.flags&&(A[0]=255&c,A[1]=c>>>8&255,A[2]=c>>>16&255,A[3]=c>>>24&255,r.check=ne(r.check,A,4,0)),c=0,f=0,r.mode=4;case 4:for(;f<16;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}r.head&&(r.head.xflags=255&c,r.head.os=c>>8),512&r.flags&&(A[0]=255&c,A[1]=c>>>8&255,r.check=ne(r.check,A,2,0)),c=0,f=0,r.mode=5;case 5:if(1024&r.flags){for(;f<16;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}r.length=c,r.head&&(r.head.extra_len=c),512&r.flags&&(A[0]=255&c,A[1]=c>>>8&255,r.check=ne(r.check,A,2,0)),c=0,f=0}else r.head&&(r.head.extra=null);r.mode=6;case 6:if(1024&r.flags&&((d=r.length)>u&&(d=u),d&&(r.head&&(_=r.head.extra_len-r.length,r.head.extra||(r.head.extra=new Uint8Array(r.head.extra_len)),r.head.extra.set(n.subarray(o,o+d),_)),512&r.flags&&(r.check=ne(r.check,n,d,o)),u-=d,o+=d,r.length-=d),r.length))break e;r.length=0,r.mode=7;case 7:if(2048&r.flags){if(0===u)break e;d=0;do{_=n[o+d++],r.head&&_&&r.length<65536&&(r.head.name+=String.fromCharCode(_))}while(_&&d<u);if(512&r.flags&&(r.check=ne(r.check,n,d,o)),u-=d,o+=d,_)break e}else r.head&&(r.head.name=null);r.length=0,r.mode=8;case 8:if(4096&r.flags){if(0===u)break e;d=0;do{_=n[o+d++],r.head&&_&&r.length<65536&&(r.head.comment+=String.fromCharCode(_))}while(_&&d<u);if(512&r.flags&&(r.check=ne(r.check,n,d,o)),u-=d,o+=d,_)break e}else r.head&&(r.head.comment=null);r.mode=9;case 9:if(512&r.flags){for(;f<16;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(c!==(65535&r.check)){e.msg="header crc mismatch",r.mode=Dt;break}c=0,f=0}r.head&&(r.head.hcrc=r.flags>>9&1,r.head.done=!0),e.adler=r.check=0,r.mode=Nt;break;case 10:for(;f<32;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}e.adler=r.check=Ft(c),c=0,f=0,r.mode=11;case 11:if(0===r.havedict)return e.next_out=a,e.avail_out=s,e.next_in=o,e.avail_in=u,r.hold=c,r.bits=f,Ct;e.adler=r.check=1,r.mode=Nt;case Nt:if(t===jt||t===It)break e;case 13:if(r.last){c>>>=7&f,f-=7&f,r.mode=27;break}for(;f<3;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}switch(r.last=1&c,f-=1,3&(c>>>=1)){case 0:r.mode=14;break;case 1:if(Gt(r),r.mode=20,t===It){c>>>=2,f-=2;break e}break;case 2:r.mode=17;break;case 3:e.msg="invalid block type",r.mode=Dt}c>>>=2,f-=2;break;case 14:for(c>>>=7&f,f-=7&f;f<32;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if((65535&c)!==(c>>>16^65535)){e.msg="invalid stored block lengths",r.mode=Dt;break}if(r.length=65535&c,c=0,f=0,r.mode=15,t===It)break e;case 15:r.mode=16;case 16:if(d=r.length){if(d>u&&(d=u),d>s&&(d=s),0===d)break e;i.set(n.subarray(o,o+d),a),u-=d,o+=d,s-=d,a+=d,r.length-=d;break}r.mode=Nt;break;case 17:for(;f<14;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(r.nlen=257+(31&c),c>>>=5,f-=5,r.ndist=1+(31&c),c>>>=5,f-=5,r.ncode=4+(15&c),c>>>=4,f-=4,r.nlen>286||r.ndist>30){e.msg="too many length or distance symbols",r.mode=Dt;break}r.have=0,r.mode=18;case 18:for(;r.have<r.ncode;){for(;f<3;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}r.lens[M[r.have++]]=7&c,c>>>=3,f-=3}for(;r.have<19;)r.lens[M[r.have++]]=0;if(r.lencode=r.lendyn,r.lenbits=7,S={bits:r.lenbits},x=At(0,r.lens,0,19,r.lencode,0,r.work,S),r.lenbits=S.bits,x){e.msg="invalid code lengths set",r.mode=Dt;break}r.have=0,r.mode=19;case 19:for(;r.have<r.nlen+r.ndist;){for(;y=(O=r.lencode[c&(1<<r.lenbits)-1])>>>16&255,m=65535&O,!((v=O>>>24)<=f);){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(m<16)c>>>=v,f-=v,r.lens[r.have++]=m;else{if(16===m){for(E=v+2;f<E;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(c>>>=v,f-=v,0===r.have){e.msg="invalid bit length repeat",r.mode=Dt;break}_=r.lens[r.have-1],d=3+(3&c),c>>>=2,f-=2}else if(17===m){for(E=v+3;f<E;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}f-=v,_=0,d=3+(7&(c>>>=v)),c>>>=3,f-=3}else{for(E=v+7;f<E;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}f-=v,_=0,d=11+(127&(c>>>=v)),c>>>=7,f-=7}if(r.have+d>r.nlen+r.ndist){e.msg="invalid bit length repeat",r.mode=Dt;break}for(;d--;)r.lens[r.have++]=_}}if(r.mode===Dt)break;if(0===r.lens[256]){e.msg="invalid code -- missing end-of-block",r.mode=Dt;break}if(r.lenbits=9,S={bits:r.lenbits},x=At(1,r.lens,0,r.nlen,r.lencode,0,r.work,S),r.lenbits=S.bits,x){e.msg="invalid literal/lengths set",r.mode=Dt;break}if(r.distbits=6,r.distcode=r.distdyn,S={bits:r.distbits},x=At(2,r.lens,r.nlen,r.ndist,r.distcode,0,r.work,S),r.distbits=S.bits,x){e.msg="invalid distances set",r.mode=Dt;break}if(r.mode=20,t===It)break e;case 20:r.mode=21;case 21:if(u>=6&&s>=258){e.next_out=a,e.avail_out=s,e.next_in=o,e.avail_in=u,r.hold=c,r.bits=f,kt(e,h),a=e.next_out,i=e.output,s=e.avail_out,o=e.next_in,n=e.input,u=e.avail_in,c=r.hold,f=r.bits,r.mode===Nt&&(r.back=-1);break}for(r.back=0;y=(O=r.lencode[c&(1<<r.lenbits)-1])>>>16&255,m=65535&O,!((v=O>>>24)<=f);){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(y&&0===(240&y)){for(g=v,w=y,k=m;y=(O=r.lencode[k+((c&(1<<g+w)-1)>>g)])>>>16&255,m=65535&O,!(g+(v=O>>>24)<=f);){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}c>>>=g,f-=g,r.back+=g}if(c>>>=v,f-=v,r.back+=v,r.length=m,0===y){r.mode=26;break}if(32&y){r.back=-1,r.mode=Nt;break}if(64&y){e.msg="invalid literal/length code",r.mode=Dt;break}r.extra=15&y,r.mode=22;case 22:if(r.extra){for(E=r.extra;f<E;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}r.length+=c&(1<<r.extra)-1,c>>>=r.extra,f-=r.extra,r.back+=r.extra}r.was=r.length,r.mode=23;case 23:for(;y=(O=r.distcode[c&(1<<r.distbits)-1])>>>16&255,m=65535&O,!((v=O>>>24)<=f);){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(0===(240&y)){for(g=v,w=y,k=m;y=(O=r.distcode[k+((c&(1<<g+w)-1)>>g)])>>>16&255,m=65535&O,!(g+(v=O>>>24)<=f);){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}c>>>=g,f-=g,r.back+=g}if(c>>>=v,f-=v,r.back+=v,64&y){e.msg="invalid distance code",r.mode=Dt;break}r.offset=m,r.extra=15&y,r.mode=24;case 24:if(r.extra){for(E=r.extra;f<E;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}r.offset+=c&(1<<r.extra)-1,c>>>=r.extra,f-=r.extra,r.back+=r.extra}if(r.offset>r.dmax){e.msg="invalid distance too far back",r.mode=Dt;break}r.mode=25;case 25:if(0===s)break e;if(d=h-s,r.offset>d){if((d=r.offset-d)>r.whave&&r.sane){e.msg="invalid distance too far back",r.mode=Dt;break}d>r.wnext?(d-=r.wnext,p=r.wsize-d):p=r.wnext-d,d>r.length&&(d=r.length),b=r.window}else b=i,p=a-r.offset,d=r.length;d>s&&(d=s),s-=d,r.length-=d;do{i[a++]=b[p++]}while(--d);0===r.length&&(r.mode=21);break;case 26:if(0===s)break e;i[a++]=r.length,s--,r.mode=21;break;case 27:if(r.wrap){for(;f<32;){if(0===u)break e;u--,c|=n[o++]<<f,f+=8}if(h-=s,e.total_out+=h,r.total+=h,h&&(e.adler=r.check=r.flags?ne(r.check,i,h,a-h):te(r.check,i,h,a-h)),h=s,(r.flags?c:Ft(c))!==r.check){e.msg="incorrect data check",r.mode=Dt;break}c=0,f=0}r.mode=28;case 28:if(r.wrap&&r.flags){for(;f<32;){if(0===u)break e;u--,c+=n[o++]<<f,f+=8}if(c!==(4294967295&r.total)){e.msg="incorrect length check",r.mode=Dt;break}c=0,f=0}r.mode=29;case 29:x=Rt;break e;case Dt:x=Bt;break e;case 31:return Lt;default:return Tt}return e.next_out=a,e.avail_out=s,e.next_in=o,e.avail_in=u,r.hold=c,r.bits=f,(r.wsize||h!==e.avail_out&&r.mode<Dt&&(r.mode<27||t!==Mt))&&Jt(e,e.output,e.next_out,h-e.avail_out),l-=e.avail_in,h-=e.avail_out,e.total_in+=l,e.total_out+=h,r.total+=h,r.wrap&&h&&(e.adler=r.check=r.flags?ne(r.check,i,h,e.next_out-h):te(r.check,i,h,e.next_out-h)),e.data_type=r.bits+(r.last?64:0)+(r.mode===Nt?128:0)+(20===r.mode||15===r.mode?256:0),(0===l&&0===h||t===Mt)&&x===Pt&&(x=zt),x},inflateEnd:function(e){if(!e||!e.state)return Tt;var t=e.state;return t.window&&(t.window=null),e.state=null,Pt},inflateGetHeader:function(e,t){if(!e||!e.state)return Tt;var r=e.state;return 0===(2&r.wrap)?Tt:(r.head=t,t.done=!1,Pt)},inflateSetDictionary:function(e,t){var r,n=t.length;return e&&e.state?0!==(r=e.state).wrap&&11!==r.mode?Tt:11===r.mode&&te(1,t,n,0)!==r.check?Bt:Jt(e,t,n,n)?(r.mode=31,Lt):(r.havedict=1,Pt):Tt},inflateInfo:"pako inflate (from Nodeca project)"};var Qt=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1},er=Object.prototype.toString,tr=oe.Z_NO_FLUSH,rr=oe.Z_FINISH,nr=oe.Z_OK,ir=oe.Z_STREAM_END,or=oe.Z_NEED_DICT,ar=oe.Z_STREAM_ERROR,ur=oe.Z_DATA_ERROR,sr=oe.Z_MEM_ERROR;function cr(e){this.options=tt({chunkSize:65536,windowBits:15,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&0===(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new ct,this.strm.avail_out=0;var r=$t.inflateInit2(this.strm,t.windowBits);if(r!==nr)throw new Error(ie[r]);if(this.header=new Qt,$t.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"===typeof t.dictionary?t.dictionary=at(t.dictionary):"[object ArrayBuffer]"===er.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(r=$t.inflateSetDictionary(this.strm,t.dictionary))!==nr))throw new Error(ie[r])}function fr(e,t){var r=new cr(t);if(r.push(e),r.err)throw r.msg||ie[r.err];return r.result}cr.prototype.push=function(e,t){var r,n,i,o=this.strm,a=this.options.chunkSize,u=this.options.dictionary;if(this.ended)return!1;for(n=t===~~t?t:!0===t?rr:tr,"[object ArrayBuffer]"===er.call(e)?o.input=new Uint8Array(e):o.input=e,o.next_in=0,o.avail_in=o.input.length;;){for(0===o.avail_out&&(o.output=new Uint8Array(a),o.next_out=0,o.avail_out=a),(r=$t.inflate(o,n))===or&&u&&((r=$t.inflateSetDictionary(o,u))===nr?r=$t.inflate(o,n):r===ur&&(r=or));o.avail_in>0&&r===ir&&o.state.wrap>0&&0!==e[o.next_in];)$t.inflateReset(o),r=$t.inflate(o,n);switch(r){case ar:case ur:case or:case sr:return this.onEnd(r),this.ended=!0,!1}if(i=o.avail_out,o.next_out&&(0===o.avail_out||r===ir))if("string"===this.options.to){var s=st(o.output,o.next_out),c=o.next_out-s,f=ut(o.output,s);o.next_out=c,o.avail_out=a-c,c&&o.output.set(o.output.subarray(s,s+c),0),this.onData(f)}else this.onData(o.output.length===o.next_out?o.output:o.output.subarray(0,o.next_out));if(r!==nr||0!==i){if(r===ir)return r=$t.inflateEnd(this.strm),this.onEnd(r),this.ended=!0,!0;if(0===o.avail_in)break}}return!0},cr.prototype.onData=function(e){this.chunks.push(e)},cr.prototype.onEnd=function(e){e===nr&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=rt(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var lr={Inflate:cr,inflate:fr,inflateRaw:function(e,t){return(t=t||{}).raw=!0,fr(e,t)},ungzip:fr,constants:oe},hr=lr.inflate,dr=r(78),pr=r(42),br=r.n(pr),vr=r(14),yr=r(28),mr=r(12);function gr(e,t){var r,n,i={},o=e.args?e.args.length:0;if(t.length>o){if(t.length!==o+1)throw new Error("provided too many arguments ".concat(t," to instruction ").concat(null===e||void 0===e?void 0:e.name," expecting: ").concat(null!==(n=null===(r=e.args)||void 0===r?void 0:r.map((function(e){return e.name})))&&void 0!==n?n:[]));i=t.pop()}return[t,i]}var wr=function(){function e(){Object(d.a)(this,e)}return Object(p.a)(e,null,[{key:"build",value:function(t,r,n){if("_inner"===t.name)throw new u.a("the _inner name is reserved");var o=function e(){for(var o=arguments.length,a=new Array(o),u=0;u<o;u++)a[u]=arguments[u];var s=gr(t,[].concat(a)),c=Object(h.a)(s,2),f=c[0],l=c[1];Object(vr.d)(t.accounts,l.accounts),kr.apply(void 0,[t].concat(a));var d=e.accounts(l.accounts);return void 0!==l.remainingAccounts&&d.push.apply(d,Object(mr.a)(l.remainingAccounts)),l.__private&&l.__private.logAccounts&&console.log("Outgoing account metas:",d),new i.TransactionInstruction({keys:d,programId:n,data:r(t.name,vr.b.apply(void 0,[t].concat(Object(mr.a)(f))))})};return o.accounts=function(r){return e.accountsArray(r,t.accounts)},o}},{key:"accountsArray",value:function(t,r){return t?r.map((function(r){if(void 0!==("accounts"in r?r.accounts:void 0)){var n=t[r.name];return e.accountsArray(n,r.accounts).flat()}var i=r;return{pubkey:Object(vr.c)(t[r.name]),isWritable:i.isMut,isSigner:i.isSigner}})).flat():[]}}]),e}();function kr(e){}var _r=function(){function e(){Object(d.a)(this,e)}return Object(p.a)(e,null,[{key:"build",value:function(e,t,r,n){var i=function(){var i=Object(l.a)(v.a.mark((function i(){var o,a,s,c,f,l,d,p,b,y=arguments;return v.a.wrap((function(i){for(;;)switch(i.prev=i.next){case 0:for(o=y.length,a=new Array(o),s=0;s<o;s++)a[s]=y[s];return c=t.apply(void 0,a),f=gr(e,[].concat(a)),l=Object(h.a)(f,2),d=l[1],i.prev=3,i.next=6,n.send(c,d.signers,d.options);case 6:return p=i.sent,i.abrupt("return",p);case 10:if(i.prev=10,i.t0=i.catch(3),console.log("Translating error",i.t0),null!==(b=u.b.parse(i.t0,r))){i.next=16;break}throw i.t0;case 16:throw b;case 17:case"end":return i.stop()}}),i,null,[[3,10]])})));return function(){return i.apply(this,arguments)}}();return i}}]),e}(),xr=function(){function e(){Object(d.a)(this,e)}return Object(p.a)(e,null,[{key:"build",value:function(e,t){return function(){for(var r,n=arguments.length,o=new Array(n),a=0;a<n;a++)o[a]=arguments[a];var u=gr(e,[].concat(o)),s=Object(h.a)(u,2),c=s[1],f=new i.Transaction;return null===(r=c.instructions)||void 0===r||r.forEach((function(e){return f.add(e)})),f.add(t.apply(void 0,o)),f}}}]),e}(),Sr=function(){function e(){Object(d.a)(this,e)}return Object(p.a)(e,null,[{key:"build",value:function(e,t,r,n){if(void 0!==e.state)return new Er(e,r,n,t)}}]),e}(),Er=function(){function e(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Object(o.b)(),i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:new a.d(t);Object(d.a)(this,e),this.provider=n,this.coder=i,this._idl=t,this._programId=r,this._address=Or(r),this._sub=null;var u=function(){var e,o={},a={},u={};return null===(e=t.state)||void 0===e||e.methods.forEach((function(e){var s=wr.build(e,(function(e,t){return i.instruction.encodeState(e,t)}),r);s.accounts=function(t){return Ar(r,n,e,t).concat(wr.accountsArray(t,e.accounts))};var f=xr.build(e,s),l=_r.build(e,f,Object(vr.a)(t),n),h=c()(e.name);o[h]=s,a[h]=f,u[h]=l})),[o,a,u]}(),s=Object(h.a)(u,3),f=s[0],l=s[1],p=s[2];this.instruction=f,this.transaction=l,this.rpc=p}return Object(p.a)(e,[{key:"programId",get:function(){return this._programId}},{key:"fetch",value:function(){var e=Object(l.a)(v.a.mark((function e(){var t,r,n;return v.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=this.address(),e.next=3,this.provider.connection.getAccountInfo(t);case 3:if(null!==(r=e.sent)){e.next=6;break}throw new Error("Account does not exist ".concat(t.toString()));case 6:if(n=this._idl.state){e.next=9;break}throw new Error("State is not specified in IDL.");case 9:return e.next=11,Object(a.e)(n.struct.name);case 11:if(!e.sent.compare(r.data.slice(0,8))){e.next=14;break}throw new Error("Invalid account discriminator");case 14:return e.abrupt("return",this.coder.state.decode(r.data));case 15:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"address",value:function(){return this._address}},{key:"subscribe",value:function(e){var t=this;if(null!==this._sub)return this._sub.ee;var r=new br.a,n=this.provider.connection.onAccountChange(this.address(),(function(e){var n=t.coder.state.decode(e.data);r.emit("change",n)}),e);return this._sub={ee:r,listener:n},r}},{key:"unsubscribe",value:function(){var e=this;null!==this._sub&&this.provider.connection.removeAccountChangeListener(this._sub.listener).then(Object(l.a)(v.a.mark((function t(){return v.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e._sub=null;case 1:case"end":return t.stop()}}),t)})))).catch(console.error)}}]),e}();function Or(e){var t=Object(yr.findProgramAddressSync)([],e),r=Object(h.a)(t,1)[0];return Object(yr.createWithSeedSync)(r,"unversioned",e)}function Ar(e,t,r,n){if("new"===r.name){var o=Object(yr.findProgramAddressSync)([],e),a=Object(h.a)(o,1)[0];return[{pubkey:t.wallet.publicKey,isWritable:!1,isSigner:!0},{pubkey:Or(e),isWritable:!0,isSigner:!1},{pubkey:a,isWritable:!1,isSigner:!1},{pubkey:i.SystemProgram.programId,isWritable:!1,isSigner:!1},{pubkey:e,isWritable:!1,isSigner:!1}]}return Object(vr.d)(r.accounts,n),[{pubkey:Or(e),isWritable:!0,isSigner:!1}]}var Mr=r(60),jr=r(38),Ir="Program log: ".length,Pr=function(){function e(t,r,n){Object(d.a)(this,e),this._programId=t,this._provider=r,this._eventParser=new Rr(t,n),this._eventCallbacks=new Map,this._eventListeners=new Map,this._listenerIdCount=0}return Object(p.a)(e,[{key:"addEventListener",value:function(e,t){var r,n=this,i=this._listenerIdCount;return this._listenerIdCount+=1,e in this._eventCallbacks||this._eventListeners.set(e,[]),this._eventListeners.set(e,(null!==(r=this._eventListeners.get(e))&&void 0!==r?r:[]).concat(i)),this._eventCallbacks.set(i,[e,t]),void 0!==this._onLogsSubscriptionId||(this._onLogsSubscriptionId=this._provider.connection.onLogs(this._programId,(function(e,t){e.err?console.error(e):n._eventParser.parseLogs(e.logs,(function(e){var r=n._eventListeners.get(e.name);r&&r.forEach((function(r){var i=n._eventCallbacks.get(r);i&&(0,Object(h.a)(i,2)[1])(e.data,t.slot)}))}))}))),i}},{key:"removeEventListener",value:function(){var e=Object(l.a)(v.a.mark((function e(t){var r,n,i,o;return v.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=this._eventCallbacks.get(t)){e.next=3;break}throw new Error("Event listener ".concat(t," doesn't exist!"));case 3:if(n=Object(h.a)(r,1),i=n[0],o=this._eventListeners.get(i)){e.next=7;break}throw new Error("Event listeners don't exist for ".concat(i,"!"));case 7:if(this._eventCallbacks.delete(t),0===(o=o.filter((function(e){return e!==t}))).length&&this._eventListeners.delete(i),0!=this._eventCallbacks.size){e.next=16;break}if(jr.ok(0===this._eventListeners.size),void 0===this._onLogsSubscriptionId){e.next=16;break}return e.next=15,this._provider.connection.removeOnLogsListener(this._onLogsSubscriptionId);case 15:this._onLogsSubscriptionId=void 0;case 16:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()}]),e}(),Rr=function(){function e(t,r){Object(d.a)(this,e),this.coder=r,this.programId=t}return Object(p.a)(e,[{key:"parseLogs",value:function(e,t){for(var r=new Tr(e),n=new Cr(r.next()),i=r.next();null!==i;){var o=this.handleLog(n,i),a=Object(h.a)(o,3),u=a[0],s=a[1],c=a[2];u&&t(u),s&&n.push(s),c&&n.pop(),i=r.next()}}},{key:"handleLog",value:function(e,t){return e.stack.length>0&&e.program()===this.programId.toString()?this.handleProgramLog(t):[null].concat(Object(mr.a)(this.handleSystemLog(t)))}},{key:"handleProgramLog",value:function(e){if(e.startsWith("Program log:")){var t=e.slice(Ir);return[this.coder.events.decode(t),null,!1]}return[null].concat(Object(mr.a)(this.handleSystemLog(e)))}},{key:"handleSystemLog",value:function(e){var t=e.split(":")[0];return null!==t.match(/^Program (.*) success/g)?[null,!0]:t.startsWith("Program ".concat(this.programId.toString()," invoke"))?[this.programId.toString(),!1]:t.includes("invoke")?["cpi",!1]:[null,!1]}}]),e}(),Cr=function(){function e(t){var r;Object(d.a)(this,e);var n=null===(r=/^Program (.*) invoke.*$/g.exec(t))||void 0===r?void 0:r[1];if(!n)throw new Error("Could not find program invocation log line");this.stack=[n]}return Object(p.a)(e,[{key:"program",value:function(){return jr.ok(this.stack.length>0),this.stack[this.stack.length-1]}},{key:"push",value:function(e){this.stack.push(e)}},{key:"pop",value:function(){jr.ok(this.stack.length>0),this.stack.pop()}}]),e}(),Tr=function(){function e(t){Object(d.a)(this,e),this.logs=t}return Object(p.a)(e,[{key:"next",value:function(){if(0===this.logs.length)return null;var e=this.logs[0];return this.logs=this.logs.slice(1),e}}]),e}(),Br=function(){function e(){Object(d.a)(this,e)}return Object(p.a)(e,null,[{key:"build",value:function(e,t,r,n,i,o,a){var s=function(){var s=Object(l.a)(v.a.mark((function s(){var c,f,l,d,p,b,y,m,g,w,k,_=arguments;return v.a.wrap((function(s){for(;;)switch(s.prev=s.next){case 0:for(c=_.length,f=new Array(c),l=0;l<c;l++)f[l]=_[l];return d=t.apply(void 0,f),p=gr(e,[].concat(f)),b=Object(h.a)(p,2),y=b[1],m=void 0,s.prev=4,s.next=7,n.simulate(d,y.signers,y.options);case 7:m=s.sent,s.next=17;break;case 10:if(s.prev=10,s.t0=s.catch(4),console.log("Translating error",s.t0),null!==(g=u.b.parse(s.t0,r))){s.next=16;break}throw s.t0;case 16:throw g;case 17:if(void 0!==m){s.next=19;break}throw new Error("Unable to simulate transaction");case 19:if(!m.value.err){s.next=21;break}throw new Error("Simulate error: ".concat(m.value.err.toString()));case 21:if(w=m.value.logs){s.next=24;break}throw new Error("Simulated logs not found");case 24:return k=[],a.events&&new Rr(o,i).parseLogs(w,(function(e){k.push(e)})),s.abrupt("return",{events:k,raw:w});case 27:case"end":return s.stop()}}),s,null,[[4,10]])})));return function(){return s.apply(this,arguments)}}();return s}}]),e}(),Lr=function(){function e(){Object(d.a)(this,e)}return Object(p.a)(e,null,[{key:"build",value:function(e,t,r,n){var i={},o={},a={},u={},s=Object(vr.a)(e),f=Sr.build(e,t,r,n);e.instructions.forEach((function(f){var l=wr.build(f,(function(e,r){return t.instruction.encode(e,r)}),r),h=xr.build(f,l),d=_r.build(f,h,s,n),p=Br.build(f,h,s,n,t,r,e),b=c()(f.name);o[b]=l,a[b]=h,i[b]=d,u[b]=p}));var l=e.accounts?Mr.a.build(e,t,r,n):{};return[i,o,a,l,u,f]}}]),e}();r(92);function zr(e){return("undefined"===typeof TextDecoder?new(r(75).TextDecoder)("utf-8"):new TextDecoder("utf-8")).decode(e)}function Ur(e){return("undefined"===typeof TextEncoder?new(r(75).TextEncoder)("utf-8"):new TextEncoder).encode(e)}r(13);r(93);var Nr=function(){function e(t,r,n){Object(d.a)(this,e),r=Object(vr.c)(r),n||(n=Object(o.b)()),this._idl=t,this._provider=n,this._programId=r,this._coder=new a.d(t),this._events=new Pr(this._programId,n,this._coder);var i=Lr.build(t,this._coder,r,n),u=Object(h.a)(i,6),s=u[0],c=u[1],f=u[2],l=u[3],p=u[4],b=u[5];this.rpc=s,this.instruction=c,this.transaction=f,this.account=l,this.simulate=p,this.state=b}return Object(p.a)(e,[{key:"programId",get:function(){return this._programId}},{key:"idl",get:function(){return this._idl}},{key:"coder",get:function(){return this._coder}},{key:"provider",get:function(){return this._provider}},{key:"addEventListener",value:function(e,t){return this._events.addEventListener(e,t)}},{key:"removeEventListener",value:function(){var e=Object(l.a)(v.a.mark((function e(t){return v.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._events.removeEventListener(t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()}],[{key:"at",value:function(){var t=Object(l.a)(v.a.mark((function t(r,n){var i,o;return v.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=Object(vr.c)(r),t.next=3,e.fetchIdl(i,n);case 3:if(o=t.sent){t.next=6;break}throw new Error("IDL not found for program: ".concat(r.toString()));case 6:return t.abrupt("return",new e(o,i,n));case 7:case"end":return t.stop()}}),t)})));return function(e,r){return t.apply(this,arguments)}}()},{key:"fetchIdl",value:function(){var e=Object(l.a)(v.a.mark((function e(t,r){var i,a,u,s,c;return v.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=null!==r&&void 0!==r?r:Object(o.b)(),i=Object(vr.c)(t),e.next=4,Object(dr.b)(i);case 4:return a=e.sent,e.next=7,r.connection.getAccountInfo(a);case 7:if(u=e.sent){e.next=10;break}return e.abrupt("return",null);case 10:return s=Object(dr.a)(u.data.slice(8)),c=hr(s.data),e.abrupt("return",JSON.parse(n.decode(c)));case 13:case"end":return e.stop()}}),e)})));return function(t,r){return e.apply(this,arguments)}}()}]),e}(),Dr=r(44),Fr=!1;new Proxy({},{get:function(e,t){if(!Dr.b){var n=r(74),o=r(35);if(!Fr){for(var a=r(156),u=o.cwd();!n.existsSync(a.join(u,"Anchor.toml"));){var s=a.dirname(u);s===u&&(u=void 0),u=s}if(void 0===u)throw new Error("Could not find workspace root.");var l="".concat(u,"/target/idl");if(!n.existsSync(l))throw new Error("".concat(l,' doesn\'t exist. Did you use "anchor build"?'));var h=new Map;n.readdirSync(l).forEach((function(t){var r="".concat(l,"/").concat(t),o=n.readFileSync(r),a=JSON.parse(o);h.set(a.name,a);var u=c()(a.name,{pascalCase:!0});a.metadata&&a.metadata.address&&(e[u]=new Nr(a,new i.PublicKey(a.metadata.address)))}));var d=f.parse(n.readFileSync(a.join(u,"Anchor.toml"),"utf-8")),p=d.provider.cluster;d.programs&&d.programs[p]&&function(e,t,n){Object.keys(t).forEach((function(o){var a=c()(o,{pascalCase:!0}),u=t[o],s=new i.PublicKey("string"===typeof u?u:u.address),f=n.get(o);if("string"!==typeof u&&u.idl&&(f=JSON.parse(r(74).readFileSync(u.idl,"utf-8"))),!f)throw new Error("Error loading workspace IDL for ".concat(o));e[a]=new Nr(f,s)}))}(e,d.programs[p],h),Fr=!0}return e[t]}console.log("Workspaces aren't available in the browser")}}),r(19);r(61),new i.PublicKey("TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"),new i.PublicKey("ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL");r(59)},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"===typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a="undefined"!==typeof window&&"undefined"!==typeof window.Buffer?window.Buffer:r(133).Buffer}catch(E){}function u(e,t){var r=e.charCodeAt(t);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function s(e,t,r){var n=u(e,r);return r-1>=t&&(n|=u(e,r-1)<<4),n}function c(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a<o;a++){var u=e.charCodeAt(a)-48;i*=n,i+=u>=49?u-49+10:u>=17?u-17+10:u}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"===typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(i++,this.negative=1),i<e.length&&(16===t?this._parseHex(e,i,r):(this._parseBase(e,t,i),"le"===r&&this._initArray(this.toArray(),t,r)))},o.prototype._initNumber=function(e,t,r){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(n(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},o.prototype._initArray=function(e,t,r){if(n("number"===typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var i=0;i<this.length;i++)this.words[i]=0;var o,a,u=0;if("be"===r)for(i=e.length-1,o=0;i>=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<<u&67108863,this.words[o+1]=a>>>26-u&67108863,(u+=24)>=26&&(u-=26,o++);else if("le"===r)for(i=0,o=0;i<e.length;i+=3)a=e[i]|e[i+1]<<8|e[i+2]<<16,this.words[o]|=a<<u&67108863,this.words[o+1]=a>>>26-u&67108863,(u+=24)>=26&&(u-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var i,o=0,a=0;if("be"===r)for(n=e.length-1;n>=t;n-=2)i=s(e,t,n)<<o,this.words[a]|=67108863&i,o>=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;else for(n=(e.length-t)%2===0?t+1:t;n<e.length;n+=2)i=s(e,t,n)<<o,this.words[a]|=67108863&i,o>=18?(o-=18,a+=1,this.words[a]|=i>>>26):o+=8;this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,u=Math.min(o,o-a)+r,s=0,f=r;f<u;f+=n)s=c(e,f,f+n,t),this.imuln(i),this.words[0]+s<67108864?this.words[0]+=s:this._iaddn(s);if(0!==a){var l=1;for(s=c(e,f,e.length,t),f=0;f<a;f++)l*=t;this.imuln(l),this.words[0]+s<67108864?this.words[0]+=s:this._iaddn(s)}this.strip()},o.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},o.prototype.clone=function(){var e=new o(null);return this.copy(e),e},o.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},o.prototype.strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var f=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],l=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],h=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,u=67108863&a,s=a/67108864|0;r.words[0]=u;for(var c=1;c<n;c++){for(var f=s>>>26,l=67108863&s,h=Math.min(c,t.length-1),d=Math.max(0,c-e.length+1);d<=h;d++){var p=c-d|0;f+=(a=(i=0|e.words[p])*(o=0|t.words[d])+l)/67108864|0,l=67108863&a}r.words[c]=0|l,s=0|f}return 0!==s?r.words[c]=0|s:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a<this.length;a++){var u=this.words[a],s=(16777215&(u<<i|o)).toString(16);r=0!==(o=u>>>24-i&16777215)||a!==this.length-1?f[6-s.length]+s+r:s+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var c=l[e],d=h[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var b=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?b+r:f[c-b.length]+b+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n("undefined"!==typeof a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,u,s="le"===t,c=new e(o),f=this.clone();if(s){for(u=0;!f.isZero();u++)a=f.andln(255),f.iushrn(8),c[u]=a;for(;u<o;u++)c[u]=0}else{for(u=0;u<o-i;u++)c[u]=0;for(u=0;!f.isZero();u++)a=f.andln(255),f.iushrn(8),c[o-u-1]=a}return c},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0===(8191&t)&&(r+=13,t>>>=13),0===(127&t)&&(r+=7,t>>>=7),0===(15&t)&&(r+=4,t>>>=4),0===(3&t)&&(r+=2,t>>>=2),0===(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var r=this._zeroBits(this.words[t]);if(e+=r,26!==r)break}return e},o.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},o.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},o.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},o.prototype.isNeg=function(){return 0!==this.negative},o.prototype.neg=function(){return this.clone().ineg()},o.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},o.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this.strip()},o.prototype.ior=function(e){return n(0===(this.negative|e.negative)),this.iuor(e)},o.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;r<t.length;r++)this.words[r]=this.words[r]&e.words[r];return this.length=t.length,this.strip()},o.prototype.iand=function(e){return n(0===(this.negative|e.negative)),this.iuand(e)},o.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;n<r.length;n++)this.words[n]=t.words[n]^r.words[n];if(this!==t)for(;n<t.length;n++)this.words[n]=t.words[n];return this.length=t.length,this.strip()},o.prototype.ixor=function(e){return n(0===(this.negative|e.negative)),this.iuxor(e)},o.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i<t;i++)this.words[i]=67108863&~this.words[i];return r>0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<<i:this.words[r]&~(1<<i),this.strip()},o.prototype.iadd=function(e){var t,r,n;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o<n.length;o++)t=(0|r.words[o])+(0|n.words[o])+i,this.words[o]=67108863&t,i=t>>>26;for(;0!==i&&o<r.length;o++)t=(0|r.words[o])+i,this.words[o]=67108863&t,i=t>>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;o<r.length;o++)this.words[o]=r.words[o];return this},o.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a<n.length;a++)o=(t=(0|r.words[a])-(0|n.words[a])+o)>>26,this.words[a]=67108863&t;for(;0!==o&&a<r.length;a++)o=(t=(0|r.words[a])+o)>>26,this.words[a]=67108863&t;if(0===o&&a<r.length&&r!==this)for(;a<r.length;a++)this.words[a]=r.words[a];return this.length=Math.max(this.length,a),r!==this&&(this.negative=1),this.strip()},o.prototype.sub=function(e){return this.clone().isub(e)};var p=function(e,t,r){var n,i,o,a=e.words,u=t.words,s=r.words,c=0,f=0|a[0],l=8191&f,h=f>>>13,d=0|a[1],p=8191&d,b=d>>>13,v=0|a[2],y=8191&v,m=v>>>13,g=0|a[3],w=8191&g,k=g>>>13,_=0|a[4],x=8191&_,S=_>>>13,E=0|a[5],O=8191&E,A=E>>>13,M=0|a[6],j=8191&M,I=M>>>13,P=0|a[7],R=8191&P,C=P>>>13,T=0|a[8],B=8191&T,L=T>>>13,z=0|a[9],U=8191&z,N=z>>>13,D=0|u[0],F=8191&D,q=D>>>13,H=0|u[1],W=8191&H,K=H>>>13,V=0|u[2],Z=8191&V,Y=V>>>13,X=0|u[3],G=8191&X,J=X>>>13,$=0|u[4],Q=8191&$,ee=$>>>13,te=0|u[5],re=8191&te,ne=te>>>13,ie=0|u[6],oe=8191&ie,ae=ie>>>13,ue=0|u[7],se=8191&ue,ce=ue>>>13,fe=0|u[8],le=8191&fe,he=fe>>>13,de=0|u[9],pe=8191&de,be=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ve=(c+(n=Math.imul(l,F))|0)+((8191&(i=(i=Math.imul(l,q))+Math.imul(h,F)|0))<<13)|0;c=((o=Math.imul(h,q))+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(p,F),i=(i=Math.imul(p,q))+Math.imul(b,F)|0,o=Math.imul(b,q);var ye=(c+(n=n+Math.imul(l,W)|0)|0)+((8191&(i=(i=i+Math.imul(l,K)|0)+Math.imul(h,W)|0))<<13)|0;c=((o=o+Math.imul(h,K)|0)+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(y,F),i=(i=Math.imul(y,q))+Math.imul(m,F)|0,o=Math.imul(m,q),n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,K)|0)+Math.imul(b,W)|0,o=o+Math.imul(b,K)|0;var me=(c+(n=n+Math.imul(l,Z)|0)|0)+((8191&(i=(i=i+Math.imul(l,Y)|0)+Math.imul(h,Z)|0))<<13)|0;c=((o=o+Math.imul(h,Y)|0)+(i>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(w,F),i=(i=Math.imul(w,q))+Math.imul(k,F)|0,o=Math.imul(k,q),n=n+Math.imul(y,W)|0,i=(i=i+Math.imul(y,K)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,K)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,Y)|0)+Math.imul(b,Z)|0,o=o+Math.imul(b,Y)|0;var ge=(c+(n=n+Math.imul(l,G)|0)|0)+((8191&(i=(i=i+Math.imul(l,J)|0)+Math.imul(h,G)|0))<<13)|0;c=((o=o+Math.imul(h,J)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(x,F),i=(i=Math.imul(x,q))+Math.imul(S,F)|0,o=Math.imul(S,q),n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,K)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,K)|0,n=n+Math.imul(y,Z)|0,i=(i=i+Math.imul(y,Y)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,Y)|0,n=n+Math.imul(p,G)|0,i=(i=i+Math.imul(p,J)|0)+Math.imul(b,G)|0,o=o+Math.imul(b,J)|0;var we=(c+(n=n+Math.imul(l,Q)|0)|0)+((8191&(i=(i=i+Math.imul(l,ee)|0)+Math.imul(h,Q)|0))<<13)|0;c=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(O,F),i=(i=Math.imul(O,q))+Math.imul(A,F)|0,o=Math.imul(A,q),n=n+Math.imul(x,W)|0,i=(i=i+Math.imul(x,K)|0)+Math.imul(S,W)|0,o=o+Math.imul(S,K)|0,n=n+Math.imul(w,Z)|0,i=(i=i+Math.imul(w,Y)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,Y)|0,n=n+Math.imul(y,G)|0,i=(i=i+Math.imul(y,J)|0)+Math.imul(m,G)|0,o=o+Math.imul(m,J)|0,n=n+Math.imul(p,Q)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(b,Q)|0,o=o+Math.imul(b,ee)|0;var ke=(c+(n=n+Math.imul(l,re)|0)|0)+((8191&(i=(i=i+Math.imul(l,ne)|0)+Math.imul(h,re)|0))<<13)|0;c=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(j,F),i=(i=Math.imul(j,q))+Math.imul(I,F)|0,o=Math.imul(I,q),n=n+Math.imul(O,W)|0,i=(i=i+Math.imul(O,K)|0)+Math.imul(A,W)|0,o=o+Math.imul(A,K)|0,n=n+Math.imul(x,Z)|0,i=(i=i+Math.imul(x,Y)|0)+Math.imul(S,Z)|0,o=o+Math.imul(S,Y)|0,n=n+Math.imul(w,G)|0,i=(i=i+Math.imul(w,J)|0)+Math.imul(k,G)|0,o=o+Math.imul(k,J)|0,n=n+Math.imul(y,Q)|0,i=(i=i+Math.imul(y,ee)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0;var _e=(c+(n=n+Math.imul(l,oe)|0)|0)+((8191&(i=(i=i+Math.imul(l,ae)|0)+Math.imul(h,oe)|0))<<13)|0;c=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(R,F),i=(i=Math.imul(R,q))+Math.imul(C,F)|0,o=Math.imul(C,q),n=n+Math.imul(j,W)|0,i=(i=i+Math.imul(j,K)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,K)|0,n=n+Math.imul(O,Z)|0,i=(i=i+Math.imul(O,Y)|0)+Math.imul(A,Z)|0,o=o+Math.imul(A,Y)|0,n=n+Math.imul(x,G)|0,i=(i=i+Math.imul(x,J)|0)+Math.imul(S,G)|0,o=o+Math.imul(S,J)|0,n=n+Math.imul(w,Q)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,ee)|0,n=n+Math.imul(y,re)|0,i=(i=i+Math.imul(y,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,ae)|0;var xe=(c+(n=n+Math.imul(l,se)|0)|0)+((8191&(i=(i=i+Math.imul(l,ce)|0)+Math.imul(h,se)|0))<<13)|0;c=((o=o+Math.imul(h,ce)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(B,F),i=(i=Math.imul(B,q))+Math.imul(L,F)|0,o=Math.imul(L,q),n=n+Math.imul(R,W)|0,i=(i=i+Math.imul(R,K)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,K)|0,n=n+Math.imul(j,Z)|0,i=(i=i+Math.imul(j,Y)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,Y)|0,n=n+Math.imul(O,G)|0,i=(i=i+Math.imul(O,J)|0)+Math.imul(A,G)|0,o=o+Math.imul(A,J)|0,n=n+Math.imul(x,Q)|0,i=(i=i+Math.imul(x,ee)|0)+Math.imul(S,Q)|0,o=o+Math.imul(S,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ne)|0,n=n+Math.imul(y,oe)|0,i=(i=i+Math.imul(y,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0,n=n+Math.imul(p,se)|0,i=(i=i+Math.imul(p,ce)|0)+Math.imul(b,se)|0,o=o+Math.imul(b,ce)|0;var Se=(c+(n=n+Math.imul(l,le)|0)|0)+((8191&(i=(i=i+Math.imul(l,he)|0)+Math.imul(h,le)|0))<<13)|0;c=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(U,F),i=(i=Math.imul(U,q))+Math.imul(N,F)|0,o=Math.imul(N,q),n=n+Math.imul(B,W)|0,i=(i=i+Math.imul(B,K)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,K)|0,n=n+Math.imul(R,Z)|0,i=(i=i+Math.imul(R,Y)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,Y)|0,n=n+Math.imul(j,G)|0,i=(i=i+Math.imul(j,J)|0)+Math.imul(I,G)|0,o=o+Math.imul(I,J)|0,n=n+Math.imul(O,Q)|0,i=(i=i+Math.imul(O,ee)|0)+Math.imul(A,Q)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(x,re)|0,i=(i=i+Math.imul(x,ne)|0)+Math.imul(S,re)|0,o=o+Math.imul(S,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,ae)|0,n=n+Math.imul(y,se)|0,i=(i=i+Math.imul(y,ce)|0)+Math.imul(m,se)|0,o=o+Math.imul(m,ce)|0,n=n+Math.imul(p,le)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(b,le)|0,o=o+Math.imul(b,he)|0;var Ee=(c+(n=n+Math.imul(l,pe)|0)|0)+((8191&(i=(i=i+Math.imul(l,be)|0)+Math.imul(h,pe)|0))<<13)|0;c=((o=o+Math.imul(h,be)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(U,W),i=(i=Math.imul(U,K))+Math.imul(N,W)|0,o=Math.imul(N,K),n=n+Math.imul(B,Z)|0,i=(i=i+Math.imul(B,Y)|0)+Math.imul(L,Z)|0,o=o+Math.imul(L,Y)|0,n=n+Math.imul(R,G)|0,i=(i=i+Math.imul(R,J)|0)+Math.imul(C,G)|0,o=o+Math.imul(C,J)|0,n=n+Math.imul(j,Q)|0,i=(i=i+Math.imul(j,ee)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,ee)|0,n=n+Math.imul(O,re)|0,i=(i=i+Math.imul(O,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(x,oe)|0,i=(i=i+Math.imul(x,ae)|0)+Math.imul(S,oe)|0,o=o+Math.imul(S,ae)|0,n=n+Math.imul(w,se)|0,i=(i=i+Math.imul(w,ce)|0)+Math.imul(k,se)|0,o=o+Math.imul(k,ce)|0,n=n+Math.imul(y,le)|0,i=(i=i+Math.imul(y,he)|0)+Math.imul(m,le)|0,o=o+Math.imul(m,he)|0;var Oe=(c+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,be)|0)+Math.imul(b,pe)|0))<<13)|0;c=((o=o+Math.imul(b,be)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(U,Z),i=(i=Math.imul(U,Y))+Math.imul(N,Z)|0,o=Math.imul(N,Y),n=n+Math.imul(B,G)|0,i=(i=i+Math.imul(B,J)|0)+Math.imul(L,G)|0,o=o+Math.imul(L,J)|0,n=n+Math.imul(R,Q)|0,i=(i=i+Math.imul(R,ee)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,ee)|0,n=n+Math.imul(j,re)|0,i=(i=i+Math.imul(j,ne)|0)+Math.imul(I,re)|0,o=o+Math.imul(I,ne)|0,n=n+Math.imul(O,oe)|0,i=(i=i+Math.imul(O,ae)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,ae)|0,n=n+Math.imul(x,se)|0,i=(i=i+Math.imul(x,ce)|0)+Math.imul(S,se)|0,o=o+Math.imul(S,ce)|0,n=n+Math.imul(w,le)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(k,le)|0,o=o+Math.imul(k,he)|0;var Ae=(c+(n=n+Math.imul(y,pe)|0)|0)+((8191&(i=(i=i+Math.imul(y,be)|0)+Math.imul(m,pe)|0))<<13)|0;c=((o=o+Math.imul(m,be)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(U,G),i=(i=Math.imul(U,J))+Math.imul(N,G)|0,o=Math.imul(N,J),n=n+Math.imul(B,Q)|0,i=(i=i+Math.imul(B,ee)|0)+Math.imul(L,Q)|0,o=o+Math.imul(L,ee)|0,n=n+Math.imul(R,re)|0,i=(i=i+Math.imul(R,ne)|0)+Math.imul(C,re)|0,o=o+Math.imul(C,ne)|0,n=n+Math.imul(j,oe)|0,i=(i=i+Math.imul(j,ae)|0)+Math.imul(I,oe)|0,o=o+Math.imul(I,ae)|0,n=n+Math.imul(O,se)|0,i=(i=i+Math.imul(O,ce)|0)+Math.imul(A,se)|0,o=o+Math.imul(A,ce)|0,n=n+Math.imul(x,le)|0,i=(i=i+Math.imul(x,he)|0)+Math.imul(S,le)|0,o=o+Math.imul(S,he)|0;var Me=(c+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,be)|0)+Math.imul(k,pe)|0))<<13)|0;c=((o=o+Math.imul(k,be)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(U,Q),i=(i=Math.imul(U,ee))+Math.imul(N,Q)|0,o=Math.imul(N,ee),n=n+Math.imul(B,re)|0,i=(i=i+Math.imul(B,ne)|0)+Math.imul(L,re)|0,o=o+Math.imul(L,ne)|0,n=n+Math.imul(R,oe)|0,i=(i=i+Math.imul(R,ae)|0)+Math.imul(C,oe)|0,o=o+Math.imul(C,ae)|0,n=n+Math.imul(j,se)|0,i=(i=i+Math.imul(j,ce)|0)+Math.imul(I,se)|0,o=o+Math.imul(I,ce)|0,n=n+Math.imul(O,le)|0,i=(i=i+Math.imul(O,he)|0)+Math.imul(A,le)|0,o=o+Math.imul(A,he)|0;var je=(c+(n=n+Math.imul(x,pe)|0)|0)+((8191&(i=(i=i+Math.imul(x,be)|0)+Math.imul(S,pe)|0))<<13)|0;c=((o=o+Math.imul(S,be)|0)+(i>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(U,re),i=(i=Math.imul(U,ne))+Math.imul(N,re)|0,o=Math.imul(N,ne),n=n+Math.imul(B,oe)|0,i=(i=i+Math.imul(B,ae)|0)+Math.imul(L,oe)|0,o=o+Math.imul(L,ae)|0,n=n+Math.imul(R,se)|0,i=(i=i+Math.imul(R,ce)|0)+Math.imul(C,se)|0,o=o+Math.imul(C,ce)|0,n=n+Math.imul(j,le)|0,i=(i=i+Math.imul(j,he)|0)+Math.imul(I,le)|0,o=o+Math.imul(I,he)|0;var Ie=(c+(n=n+Math.imul(O,pe)|0)|0)+((8191&(i=(i=i+Math.imul(O,be)|0)+Math.imul(A,pe)|0))<<13)|0;c=((o=o+Math.imul(A,be)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(U,oe),i=(i=Math.imul(U,ae))+Math.imul(N,oe)|0,o=Math.imul(N,ae),n=n+Math.imul(B,se)|0,i=(i=i+Math.imul(B,ce)|0)+Math.imul(L,se)|0,o=o+Math.imul(L,ce)|0,n=n+Math.imul(R,le)|0,i=(i=i+Math.imul(R,he)|0)+Math.imul(C,le)|0,o=o+Math.imul(C,he)|0;var Pe=(c+(n=n+Math.imul(j,pe)|0)|0)+((8191&(i=(i=i+Math.imul(j,be)|0)+Math.imul(I,pe)|0))<<13)|0;c=((o=o+Math.imul(I,be)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(U,se),i=(i=Math.imul(U,ce))+Math.imul(N,se)|0,o=Math.imul(N,ce),n=n+Math.imul(B,le)|0,i=(i=i+Math.imul(B,he)|0)+Math.imul(L,le)|0,o=o+Math.imul(L,he)|0;var Re=(c+(n=n+Math.imul(R,pe)|0)|0)+((8191&(i=(i=i+Math.imul(R,be)|0)+Math.imul(C,pe)|0))<<13)|0;c=((o=o+Math.imul(C,be)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(U,le),i=(i=Math.imul(U,he))+Math.imul(N,le)|0,o=Math.imul(N,he);var Ce=(c+(n=n+Math.imul(B,pe)|0)|0)+((8191&(i=(i=i+Math.imul(B,be)|0)+Math.imul(L,pe)|0))<<13)|0;c=((o=o+Math.imul(L,be)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863;var Te=(c+(n=Math.imul(U,pe))|0)+((8191&(i=(i=Math.imul(U,be))+Math.imul(N,pe)|0))<<13)|0;return c=((o=Math.imul(N,be))+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,s[0]=ve,s[1]=ye,s[2]=me,s[3]=ge,s[4]=we,s[5]=ke,s[6]=_e,s[7]=xe,s[8]=Se,s[9]=Ee,s[10]=Oe,s[11]=Ae,s[12]=Me,s[13]=je,s[14]=Ie,s[15]=Pe,s[16]=Re,s[17]=Ce,s[18]=Te,0!==c&&(s[19]=c,r.length++),r};function b(e,t,r){return(new v).mulp(e,t,r)}function v(e,t){this.x=e,this.y=t}Math.imul||(p=d),o.prototype.mulTo=function(e,t){var r,n=this.length+e.length;return r=10===this.length&&10===e.length?p(this,e,t):n<63?d(this,e,t):n<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o<r.length-1;o++){var a=i;i=0;for(var u=67108863&n,s=Math.min(o,t.length-1),c=Math.max(0,o-e.length+1);c<=s;c++){var f=o-c,l=(0|e.words[f])*(0|t.words[c]),h=67108863&l;u=67108863&(h=h+u|0),i+=(a=(a=a+(l/67108864|0)|0)+(h>>>26)|0)>>>26,a&=67108863}r.words[o]=u,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):b(this,e,t),r},v.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n<e;n++)t[n]=this.revBin(n,r,e);return t},v.prototype.revBin=function(e,t,r){if(0===e||e===r-1)return e;for(var n=0,i=0;i<t;i++)n|=(1&e)<<t-i-1,e>>=1;return n},v.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a<o;a++)n[a]=t[e[a]],i[a]=r[e[a]]},v.prototype.transform=function(e,t,r,n,i,o){this.permute(o,e,t,r,n,i);for(var a=1;a<i;a<<=1)for(var u=a<<1,s=Math.cos(2*Math.PI/u),c=Math.sin(2*Math.PI/u),f=0;f<i;f+=u)for(var l=s,h=c,d=0;d<a;d++){var p=r[f+d],b=n[f+d],v=r[f+d+a],y=n[f+d+a],m=l*v-h*y;y=l*y+h*v,v=m,r[f+d]=p+v,n[f+d]=b+y,r[f+d+a]=p-v,n[f+d+a]=b-y,d!==u&&(m=s*l-c*h,h=s*h+c*l,l=m)}},v.prototype.guessLen13b=function(e,t){var r=1|Math.max(t,e),n=1&r,i=0;for(r=r/2|0;r;r>>>=1)i++;return 1<<i+1+n},v.prototype.conjugate=function(e,t,r){if(!(r<=1))for(var n=0;n<r/2;n++){var i=e[n];e[n]=e[r-n-1],e[r-n-1]=i,i=t[n],t[n]=-t[r-n-1],t[r-n-1]=-i}},v.prototype.normalize13b=function(e,t){for(var r=0,n=0;n<t/2;n++){var i=8192*Math.round(e[2*n+1]/t)+Math.round(e[2*n]/t)+r;e[n]=67108863&i,r=i<67108864?0:i/67108864|0}return e},v.prototype.convert13b=function(e,t,r,i){for(var o=0,a=0;a<t;a++)o+=0|e[a],r[2*a]=8191&o,o>>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a<i;++a)r[a]=0;n(0===o),n(0===(-8192&o))},v.prototype.stub=function(e){for(var t=new Array(e),r=0;r<e;r++)t[r]=0;return t},v.prototype.mulp=function(e,t,r){var n=2*this.guessLen13b(e.length,t.length),i=this.makeRBT(n),o=this.stub(n),a=new Array(n),u=new Array(n),s=new Array(n),c=new Array(n),f=new Array(n),l=new Array(n),h=r.words;h.length=n,this.convert13b(e.words,e.length,a,n),this.convert13b(t.words,t.length,c,n),this.transform(a,o,u,s,n,i),this.transform(c,o,f,l,n,i);for(var d=0;d<n;d++){var p=u[d]*f[d]-s[d]*l[d];s[d]=u[d]*l[d]+s[d]*f[d],u[d]=p}return this.conjugate(u,s,n),this.transform(u,s,h,o,n,i),this.conjugate(h,o,n),this.normalize13b(h,n),r.negative=e.negative^t.negative,r.length=e.length+t.length,r.strip()},o.prototype.mul=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},o.prototype.mulf=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),b(this,e,t)},o.prototype.imul=function(e){return this.clone().mulTo(e,this)},o.prototype.imuln=function(e){n("number"===typeof e),n(e<67108864);for(var t=0,r=0;r<this.length;r++){var i=(0|this.words[r])*e,o=(67108863&i)+(67108863&t);t>>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r<t.length;r++){var n=r/26|0,i=r%26;t[r]=(e.words[n]&1<<i)>>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n<t.length&&0===t[n];n++,r=r.sqr());if(++n<t.length)for(var i=r.sqr();n<t.length;n++,i=i.sqr())0!==t[n]&&(r=r.mul(i));return r},o.prototype.iushln=function(e){n("number"===typeof e&&e>=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t<this.length;t++){var u=this.words[t]&o,s=(0|this.words[t])-u<<r;this.words[t]=s|a,a=u>>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t<i;t++)this.words[t]=0;this.length+=i}return this.strip()},o.prototype.ishln=function(e){return n(0===this.negative),this.iushln(e)},o.prototype.iushrn=function(e,t,r){var i;n("number"===typeof e&&e>=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),u=67108863^67108863>>>o<<o,s=r;if(i-=a,i=Math.max(0,i),s){for(var c=0;c<a;c++)s.words[c]=this.words[c];s.length=a}if(0===a);else if(this.length>a)for(this.length-=a,c=0;c<this.length;c++)this.words[c]=this.words[c+a];else this.words[0]=0,this.length=1;var f=0;for(c=this.length-1;c>=0&&(0!==f||c>=i);c--){var l=0|this.words[c];this.words[c]=f<<26-o|l>>>o,f=l&u}return s&&0!==f&&(s.words[s.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<<t;return!(this.length<=r)&&!!(this.words[r]&i)},o.prototype.imaskn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<<t;this.words[this.length-1]&=i}return this.strip()},o.prototype.maskn=function(e){return this.clone().imaskn(e)},o.prototype.iaddn=function(e){return n("number"===typeof e),n(e<67108864),e<0?this.isubn(-e):0!==this.negative?1===this.length&&(0|this.words[0])<e?(this.words[0]=e-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(e),this.negative=1,this):this._iaddn(e)},o.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&this.words[t]>=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(n("number"===typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this.strip()},o.prototype.addn=function(e){return this.clone().iaddn(e)},o.prototype.subn=function(e){return this.clone().isubn(e)},o.prototype.iabs=function(){return this.negative=0,this},o.prototype.abs=function(){return this.clone().iabs()},o.prototype._ishlnsubmul=function(e,t,r){var i,o,a=e.length+r;this._expand(a);var u=0;for(i=0;i<e.length;i++){o=(0|this.words[i+r])+u;var s=(0|e.words[i])*t;u=((o-=67108863&s)>>26)-(s/67108864|0),this.words[i+r]=67108863&o}for(;i<this.length-r;i++)u=(o=(0|this.words[i+r])+u)>>26,this.words[i+r]=67108863&o;if(0===u)return this.strip();for(n(-1===u),u=0,i=0;i<this.length;i++)u=(o=-(0|this.words[i])+u)>>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var u,s=n.length-i.length;if("mod"!==t){(u=new o(null)).length=s+1,u.words=new Array(u.length);for(var c=0;c<u.length;c++)u.words[c]=0}var f=n.clone()._ishlnsubmul(i,1,s);0===f.negative&&(n=f,u&&(u.words[s]=1));for(var l=s-1;l>=0;l--){var h=67108864*(0|n.words[i.length+l])+(0|n.words[i.length+l-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,l);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,l),n.isZero()||(n.negative^=1);u&&(u.words[l]=h)}return u&&u.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:u||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(u=this.neg().divmod(e,t),"mod"!==t&&(i=u.div.neg()),"div"!==t&&(a=u.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(u=this.divmod(e.neg(),t),"mod"!==t&&(i=u.div.neg()),{div:i,mod:u.mod}):0!==(this.negative&e.negative)?(u=this.neg().divmod(e.neg(),t),"div"!==t&&(a=u.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:u.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,u},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),u=new o(0),s=new o(1),c=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++c;for(var f=r.clone(),l=t.clone();!t.isZero();){for(var h=0,d=1;0===(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(f),a.isub(l)),i.iushrn(1),a.iushrn(1);for(var p=0,b=1;0===(r.words[0]&b)&&p<26;++p,b<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(u.isOdd()||s.isOdd())&&(u.iadd(f),s.isub(l)),u.iushrn(1),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(u),a.isub(s)):(r.isub(t),u.isub(i),s.isub(a))}return{a:u,b:s,gcd:r.iushln(c)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),u=new o(0),s=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var c=0,f=1;0===(t.words[0]&f)&&c<26;++c,f<<=1);if(c>0)for(t.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(s),a.iushrn(1);for(var l=0,h=1;0===(r.words[0]&h)&&l<26;++l,h<<=1);if(l>0)for(r.iushrn(l);l-- >0;)u.isOdd()&&u.iadd(s),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(u)):(r.isub(t),u.isub(a))}return(i=0===t.cmpn(1)?a:u).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,i=1<<t;if(this.length<=r)return this._expand(r+1),this.words[r]|=i,this;for(var o=i,a=r;0!==o&&a<this.length;a++){var u=0|this.words[a];o=(u+=o)>>>26,u&=67108863,this.words[a]=u}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:i<e?-1:1}return 0!==this.negative?0|-t:t},o.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},o.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,r=this.length-1;r>=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){n<i?t=-1:n>i&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new x(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var y={k256:null,p224:null,p192:null,p25519:null};function m(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function g(){m.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){m.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function k(){m.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){m.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function x(e){if("string"===typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function S(e){x.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}m.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},m.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t<this.n?-1:r.ucmp(this.p);return 0===n?(r.words[0]=0,r.length=1):n>0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},m.prototype.split=function(e,t){e.iushrn(this.n,0,t)},m.prototype.imulK=function(e){return e.imul(this.k)},i(g,m),g.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),i=0;i<n;i++)t.words[i]=e.words[i];if(t.length=n,e.length<=9)return e.words[0]=0,void(e.length=1);var o=e.words[9];for(t.words[t.length++]=o&r,i=10;i<e.length;i++){var a=0|e.words[i];e.words[i-10]=(a&r)<<4|o>>>22,o=a}o>>>=22,e.words[i-10]=o,0===o&&e.length>10?e.length-=10:e.length-=9},g.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r<e.length;r++){var n=0|e.words[r];t+=977*n,e.words[r]=67108863&t,t=64*n+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},i(w,m),i(k,m),i(_,m),_.prototype.imulK=function(e){for(var t=0,r=0;r<e.length;r++){var n=19*(0|e.words[r])+t,i=67108863&n;n>>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(y[e])return y[e];var t;if("k256"===e)t=new g;else if("p224"===e)t=new w;else if("p192"===e)t=new k;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new _}return y[e]=t,t},x.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},x.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},x.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},x.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},x.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},x.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},x.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},x.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},x.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},x.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},x.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},x.prototype.isqr=function(e){return this.imul(e,e.clone())},x.prototype.sqr=function(e){return this.mul(e,e)},x.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var u=new o(1).toRed(this),s=u.redNeg(),c=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,c).cmp(s);)f.redIAdd(s);for(var l=this.pow(f,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(u);){for(var b=d,v=0;0!==b.cmp(u);v++)b=b.redSqr();n(v<p);var y=this.pow(l,new o(1).iushln(p-v-1));h=h.redMul(y),l=y.redSqr(),d=d.redMul(l),p=v}return h},x.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},x.prototype.pow=function(e,t){if(t.isZero())return new o(1).toRed(this);if(0===t.cmpn(1))return e.clone();var r=new Array(16);r[0]=new o(1).toRed(this),r[1]=e;for(var n=2;n<r.length;n++)r[n]=this.mul(r[n-1],e);var i=r[0],a=0,u=0,s=t.bitLength()%26;for(0===s&&(s=26),n=t.length-1;n>=0;n--){for(var c=t.words[n],f=s-1;f>=0;f--){var l=c>>f&1;i!==r[0]&&(i=this.sqr(i)),0!==l||0!==a?(a<<=1,a|=l,(4===++u||0===n&&0===f)&&(i=this.mul(i,r[a]),u=0,a=0)):u=0}s=26}return i},x.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},x.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new S(e)},i(S,x),S.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},S.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},S.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},S.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},S.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(79)(e))},function(e,t,r){"use strict";r.d(t,"a",(function(){return c}));var n=r(4),i=r(5),o=r(16),a=r.n(o),u=r(11),s=r(18),c=function(){function e(){Object(n.a)(this,e)}return Object(i.a)(e,null,[{key:"fieldLayout",value:function(t,r){var n=void 0!==t.name?a()(t.name):void 0;switch(t.type){case"bool":return u.bool(n);case"u8":return u.u8(n);case"i8":return u.i8(n);case"u16":return u.u16(n);case"i16":return u.i16(n);case"u32":return u.u32(n);case"i32":return u.i32(n);case"u64":return u.u64(n);case"i64":return u.i64(n);case"u128":return u.u128(n);case"i128":return u.i128(n);case"bytes":return u.vecU8(n);case"string":return u.str(n);case"publicKey":return u.publicKey(n);default:if("vec"in t.type)return u.vec(e.fieldLayout({name:void 0,type:t.type.vec},r),n);if("option"in t.type)return u.option(e.fieldLayout({name:void 0,type:t.type.option},r),n);if("defined"in t.type){var i=t.type.defined;if(void 0===r)throw new s.a("User defined types not provided");var o=r.filter((function(e){return e.name===i}));if(1!==o.length)throw new s.a("Type not found: ".concat(JSON.stringify(t)));return e.typeDefLayout(o[0],r,n)}if("array"in t.type){var c=t.type.array[0],f=t.type.array[1],l=e.fieldLayout({name:void 0,type:c},r);return u.array(l,f,n)}throw new Error("Not yet implemented: ".concat(t))}}},{key:"typeDefLayout",value:function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0;if("struct"===t.type.kind){var i=t.type.fields.map((function(t){return e.fieldLayout(t,r)}));return u.struct(i,n)}if("enum"===t.type.kind){var o=t.type.variants.map((function(t){var n=a()(t.name);if(void 0===t.fields)return u.struct([],n);var i=t.fields.map((function(t){if(void 0===t.name)throw new Error("Tuple enum variants not yet implemented.");return e.fieldLayout(t,r)}));return u.struct(i,n)}));return void 0!==n?u.rustEnum(o).replicate(n):u.rustEnum(o,n)}throw new Error("Unknown type kint: ".concat(t))}}]),e}()},function(e,t,r){"use strict";r.r(t),function(e){r.d(t,"createWithSeedSync",(function(){return h})),r.d(t,"createProgramAddressSync",(function(){return d})),r.d(t,"findProgramAddressSync",(function(){return p})),r.d(t,"associated",(function(){return v}));var n=r(9),i=r(3),o=r(1),a=r.n(o),u=r(23),s=r.n(u),c=r(19),f=r(8),l=r(14);function h(t,r,n){var i=e.concat([t.toBuffer(),e.from(r),n.toBuffer()]),o=c.sha256.digest(i);return new f.PublicKey(e.from(o))}function d(t,r){var n=e.alloc(0);t.forEach((function(t){if(t.length>32)throw new TypeError("Max seed length exceeded");n=e.concat([n,b(t)])})),n=e.concat([n,r.toBuffer(),e.from("ProgramDerivedAddress")]);var i=Object(c.sha256)(new Uint8Array(n)),o=new s.a(i,16).toArray(void 0,32);if(f.PublicKey.isOnCurve(new Uint8Array(o)))throw new Error("Invalid seeds, address must fall off the curve");return new f.PublicKey(o)}function p(t,r){for(var n,i=255;0!=i;){try{n=d(t.concat(e.from([i])),r)}catch(o){if(o instanceof TypeError)throw o;i--;continue}return[n,i]}throw new Error("Unable to find a viable program address nonce")}var b=function(t){return t instanceof e?t:t instanceof Uint8Array?e.from(t.buffer,t.byteOffset,t.byteLength):e.from(t)};function v(e){return y.apply(this,arguments)}function y(){return y=Object(i.a)(a.a.mark((function t(r){var i,o,u,s,c,h,d,p=arguments;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:for(i=[e.from([97,110,99,104,111,114])],o=p.length,u=new Array(o>1?o-1:0),s=1;s<o;s++)u[s-1]=p[s];return u.forEach((function(e){i.push(void 0!==e.buffer?e:Object(l.c)(e).toBuffer())})),t.next=5,f.PublicKey.findProgramAddress(i,Object(l.c)(r));case 5:return c=t.sent,h=Object(n.a)(c,1),d=h[0],t.abrupt("return",d);case 9:case"end":return t.stop()}}),t)}))),y.apply(this,arguments)}}.call(this,r(6).Buffer)},function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(43);function i(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Object(n.a)(e,t)}},function(e,t,r){"use strict";r.d(t,"a",(function(){return s}));var n=r(52),i=r(64);function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}var a=r(66);function u(e,t){if(t&&("object"===o(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Object(a.a)(e)}function s(e){var t=Object(i.a)();return function(){var r,i=Object(n.a)(e);if(t){var o=Object(n.a)(this).constructor;r=Reflect.construct(i,arguments,o)}else r=i.apply(this,arguments);return u(this,r)}}},function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(51);function i(e,t){if(e){if("string"===typeof e)return Object(n.a)(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Object(n.a)(e,t):void 0}}},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return u})),r.d(t,"b",(function(){return c}));var n=r(12),i=r(100),o=r(19),a=r(18);function u(e,t){if("enum"===t.type.kind){var r=t.type.variants.map((function(t){return void 0===t.fields?0:t.fields.map((function(t){if("object"!==typeof t||!("name"in t))throw new Error("Tuple enum variants not yet implemented.");return s(e,t.type)})).reduce((function(e,t){return e+t}))}));return Math.max.apply(Math,Object(n.a)(r))+1}return void 0===t.type.fields?0:t.type.fields.map((function(t){return s(e,t.type)})).reduce((function(e,t){return e+t}),0)}function s(e,t){var r,n;switch(t){case"bool":case"u8":case"i8":case"bytes":case"string":return 1;case"i16":case"u16":return 2;case"u32":case"i32":return 4;case"u64":case"i64":return 8;case"u128":case"i128":return 16;case"publicKey":return 32;default:if("vec"in t)return 1;if("option"in t)return 1+s(e,t.option);if("defined"in t){var i=null!==(n=null===(r=e.types)||void 0===r?void 0:r.filter((function(e){return e.name===t.defined})))&&void 0!==n?n:[];if(1!==i.length)throw new a.a("Type not found: ".concat(JSON.stringify(t)));return u(e,i[0])}if("array"in t){var o=t.array[0],c=t.array[1];return s(e,o)*c}throw new Error("Invalid type ".concat(JSON.stringify(t)))}}function c(t,r){var n=Object(i.a)(r),a="".concat(t,":").concat(n);return e.from(o.sha256.digest(a)).slice(0,8)}}).call(this,r(6).Buffer)},function(e,t,r){"use strict";t.byteLength=function(e){var t=c(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,n=c(e),a=n[0],u=n[1],s=new o(function(e,t,r){return 3*(t+r)/4-r}(0,a,u)),f=0,l=u>0?a-4:a;for(r=0;r<l;r+=4)t=i[e.charCodeAt(r)]<<18|i[e.charCodeAt(r+1)]<<12|i[e.charCodeAt(r+2)]<<6|i[e.charCodeAt(r+3)],s[f++]=t>>16&255,s[f++]=t>>8&255,s[f++]=255&t;2===u&&(t=i[e.charCodeAt(r)]<<2|i[e.charCodeAt(r+1)]>>4,s[f++]=255&t);1===u&&(t=i[e.charCodeAt(r)]<<10|i[e.charCodeAt(r+1)]<<4|i[e.charCodeAt(r+2)]>>2,s[f++]=t>>8&255,s[f++]=255&t);return s},t.fromByteArray=function(e){for(var t,r=e.length,i=r%3,o=[],a=16383,u=0,s=r-i;u<s;u+=a)o.push(f(e,u,u+a>s?s:u+a));1===i?(t=e[r-1],o.push(n[t>>2]+n[t<<4&63]+"==")):2===i&&(t=(e[r-2]<<8)+e[r-1],o.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"="));return o.join("")};for(var n=[],i=[],o="undefined"!==typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",u=0,s=a.length;u<s;++u)n[u]=a[u],i[a.charCodeAt(u)]=u;function c(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("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function f(e,t,r){for(var i,o,a=[],u=t;u<r;u+=3)i=(e[u]<<16&16711680)+(e[u+1]<<8&65280)+(255&e[u+2]),a.push(n[(o=i)>>18&63]+n[o>>12&63]+n[o>>6&63]+n[63&o]);return a.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},function(e,t){function r(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=r,r.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},function(e,t){var r,n,i=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function u(e){if(r===setTimeout)return setTimeout(e,0);if((r===o||!r)&&setTimeout)return r=setTimeout,setTimeout(e,0);try{return r(e,0)}catch(t){try{return r.call(null,e,0)}catch(t){return r.call(this,e,0)}}}!function(){try{r="function"===typeof setTimeout?setTimeout:o}catch(e){r=o}try{n="function"===typeof clearTimeout?clearTimeout:a}catch(e){n=a}}();var s,c=[],f=!1,l=-1;function h(){f&&s&&(f=!1,s.length?c=s.concat(c):l=-1,c.length&&d())}function d(){if(!f){var e=u(h);f=!0;for(var t=c.length;t;){for(s=c,c=[];++l<t;)s&&s[l].run();l=-1,t=c.length}s=null,f=!1,function(e){if(n===clearTimeout)return clearTimeout(e);if((n===a||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(e);try{n(e)}catch(t){try{return n.call(null,e)}catch(t){return n.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function b(){}i.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];c.push(new p(e,t)),1!==c.length||f||u(d)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=b,i.addListener=b,i.once=b,i.off=b,i.removeListener=b,i.removeAllListeners=b,i.emit=b,i.prependListener=b,i.prependOnceListener=b,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return f})),r.d(t,"b",(function(){return p}));var n=r(3),i=r(4),o=r(5),a=r(1),u=r.n(a),s=r(8),c=r(44),f=function(){function e(t,r,n){Object(i.a)(this,e),this.connection=t,this.wallet=r,this.opts=n}return Object(o.a)(e,[{key:"send",value:function(){var e=Object(n.a)(u.a.mark((function e(t,r,n){var i,o;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return void 0===r&&(r=[]),void 0===n&&(n=this.opts),t.feePayer=this.wallet.publicKey,e.next=5,this.connection.getRecentBlockhash(n.preflightCommitment);case 5:return t.recentBlockhash=e.sent.blockhash,e.next=8,this.wallet.signTransaction(t);case 8:return r.filter((function(e){return void 0!==e})).forEach((function(e){t.partialSign(e)})),i=t.serialize(),e.next=12,Object(s.sendAndConfirmRawTransaction)(this.connection,i,n);case 12:return o=e.sent,e.abrupt("return",o);case 14:case"end":return e.stop()}}),e,this)})));return function(t,r,n){return e.apply(this,arguments)}}()},{key:"sendAll",value:function(){var e=Object(n.a)(u.a.mark((function e(t,r){var n,i,o,a,c,f,l,h=this;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return void 0===r&&(r=this.opts),e.next=3,this.connection.getRecentBlockhash(r.preflightCommitment);case 3:return n=e.sent,i=t.map((function(e){var t=e.tx,r=e.signers;return void 0===r&&(r=[]),t.feePayer=h.wallet.publicKey,t.recentBlockhash=n.blockhash,r.filter((function(e){return void 0!==e})).forEach((function(e){t.partialSign(e)})),t})),e.next=7,this.wallet.signAllTransactions(i);case 7:o=e.sent,a=[],c=0;case 10:if(!(c<i.length)){e.next=21;break}return f=o[c],l=f.serialize(),e.t0=a,e.next=16,Object(s.sendAndConfirmRawTransaction)(this.connection,l,r);case 16:e.t1=e.sent,e.t0.push.call(e.t0,e.t1);case 18:c+=1,e.next=10;break;case 21:return e.abrupt("return",a);case 22:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"simulate",value:function(){var e=Object(n.a)(u.a.mark((function e(t,r){var n,i,o,a,s=arguments;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=s.length>2&&void 0!==s[2]?s[2]:this.opts,void 0===r&&(r=[]),t.feePayer=this.wallet.publicKey,e.next=5,this.connection.getRecentBlockhash(null!==(i=n.preflightCommitment)&&void 0!==i?i:this.opts.preflightCommitment);case 5:return t.recentBlockhash=e.sent.blockhash,e.next=8,this.wallet.signTransaction(t);case 8:return r.filter((function(e){return void 0!==e})).forEach((function(e){t.partialSign(e)})),e.next=11,h(this.connection,t,null!==(a=null!==(o=n.commitment)&&void 0!==o?o:this.opts.commitment)&&void 0!==a?a:"recent");case 11:return e.abrupt("return",e.sent);case 12:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()}],[{key:"defaultOptions",value:function(){return{preflightCommitment:"recent",commitment:"recent"}}},{key:"local",value:function(t,r){return r=null!==r&&void 0!==r?r:e.defaultOptions(),new e(new s.Connection(null!==t&&void 0!==t?t:"http://localhost:8899",r.preflightCommitment),l.local(),r)}},{key:"env",value:function(){if(c.b)throw new Error("Provider env is not available on browser.");var t=r(35).env.ANCHOR_PROVIDER_URL;if(void 0===t)throw new Error("ANCHOR_PROVIDER_URL is not defined");var n=e.defaultOptions();return new e(new s.Connection(t,n.commitment),l.local(),n)}}]),e}(),l=function(){function t(e){Object(i.a)(this,t),this.payer=e}return Object(o.a)(t,[{key:"signTransaction",value:function(){var e=Object(n.a)(u.a.mark((function e(t){return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t.partialSign(this.payer),e.abrupt("return",t);case 2:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"signAllTransactions",value:function(){var e=Object(n.a)(u.a.mark((function e(t){var r=this;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",t.map((function(e){return e.partialSign(r.payer),e})));case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()},{key:"publicKey",get:function(){return this.payer.publicKey}}],[{key:"local",value:function(){var n=r(35);return new t(s.Keypair.fromSecretKey(e.from(JSON.parse(r(74).readFileSync(n.env.ANCHOR_WALLET,{encoding:"utf-8"})))))}}]),t}();function h(e,t,r){return d.apply(this,arguments)}function d(){return(d=Object(n.a)(u.a.mark((function e(t,r,n){var i,o,a,s,c;return u.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,t._recentBlockhash(t._disableBlockhashCaching);case 2:return r.recentBlockhash=e.sent,i=r.serializeMessage(),o=r._serialize(i),a=o.toString("base64"),s=[a,{encoding:"base64",commitment:n}],e.next=10,t._rpcRequest("simulateTransaction",s);case 10:if(!(c=e.sent).error){e.next=13;break}throw new Error("failed to simulate transaction: "+c.error.message);case 13:return e.abrupt("return",c.result);case 14:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function p(){return null===b?f.local():b}var b=null}).call(this,r(6).Buffer)},function(e,t,r){"use strict";r.d(t,"a",(function(){return u}));var n=r(52),i=r(43);var o=r(64);function a(e,t,r){return a=Object(o.a)()?Reflect.construct:function(e,t,r){var n=[null];n.push.apply(n,t);var o=new(Function.bind.apply(e,n));return r&&Object(i.a)(o,r.prototype),o},a.apply(null,arguments)}function u(e){var t="function"===typeof Map?new Map:void 0;return u=function(e){if(null===e||(r=e,-1===Function.toString.call(r).indexOf("[native code]")))return e;var r;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof t){if(t.has(e))return t.get(e);t.set(e,o)}function o(){return a(e,arguments,Object(n.a)(this).constructor)}return o.prototype=Object.create(e.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),Object(i.a)(o,e)},u(e)}},function(e,t,r){"use strict";(function(t){var n=r(54);function i(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i<o;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0}function o(e){return t.Buffer&&"function"===typeof t.Buffer.isBuffer?t.Buffer.isBuffer(e):!(null==e||!e._isBuffer)}var a=r(75),u=Object.prototype.hasOwnProperty,s=Array.prototype.slice,c="foo"===function(){}.name;function f(e){return Object.prototype.toString.call(e)}function l(e){return!o(e)&&("function"===typeof t.ArrayBuffer&&("function"===typeof ArrayBuffer.isView?ArrayBuffer.isView(e):!!e&&(e instanceof DataView||!!(e.buffer&&e.buffer instanceof ArrayBuffer))))}var h=e.exports=m,d=/\s*function\s+([^\(\s]*)\s*/;function p(e){if(a.isFunction(e)){if(c)return e.name;var t=e.toString().match(d);return t&&t[1]}}function b(e,t){return"string"===typeof e?e.length<t?e:e.slice(0,t):e}function v(e){if(c||!a.isFunction(e))return a.inspect(e);var t=p(e);return"[Function"+(t?": "+t:"")+"]"}function y(e,t,r,n,i){throw new h.AssertionError({message:r,actual:e,expected:t,operator:n,stackStartFunction:i})}function m(e,t){e||y(e,!0,t,"==",h.ok)}function g(e,t,r,n){if(e===t)return!0;if(o(e)&&o(t))return 0===i(e,t);if(a.isDate(e)&&a.isDate(t))return e.getTime()===t.getTime();if(a.isRegExp(e)&&a.isRegExp(t))return e.source===t.source&&e.global===t.global&&e.multiline===t.multiline&&e.lastIndex===t.lastIndex&&e.ignoreCase===t.ignoreCase;if(null!==e&&"object"===typeof e||null!==t&&"object"===typeof t){if(l(e)&&l(t)&&f(e)===f(t)&&!(e instanceof Float32Array||e instanceof Float64Array))return 0===i(new Uint8Array(e.buffer),new Uint8Array(t.buffer));if(o(e)!==o(t))return!1;var u=(n=n||{actual:[],expected:[]}).actual.indexOf(e);return-1!==u&&u===n.expected.indexOf(t)||(n.actual.push(e),n.expected.push(t),function(e,t,r,n){if(null===e||void 0===e||null===t||void 0===t)return!1;if(a.isPrimitive(e)||a.isPrimitive(t))return e===t;if(r&&Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;var i=w(e),o=w(t);if(i&&!o||!i&&o)return!1;if(i)return g(e=s.call(e),t=s.call(t),r);var u,c,f=x(e),l=x(t);if(f.length!==l.length)return!1;for(f.sort(),l.sort(),c=f.length-1;c>=0;c--)if(f[c]!==l[c])return!1;for(c=f.length-1;c>=0;c--)if(!g(e[u=f[c]],t[u],r,n))return!1;return!0}(e,t,r,n))}return r?e===t:e==t}function w(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function k(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(r){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function _(e,t,r,n){var i;if("function"!==typeof t)throw new TypeError('"block" argument must be a function');"string"===typeof r&&(n=r,r=null),i=function(e){var t;try{e()}catch(r){t=r}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!i&&y(i,r,"Missing expected exception"+n);var o="string"===typeof n,u=!e&&i&&!r;if((!e&&a.isError(i)&&o&&k(i,r)||u)&&y(i,r,"Got unwanted exception"+n),e&&i&&r&&!k(i,r)||!e&&i)throw i}h.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return b(v(e.actual),128)+" "+e.operator+" "+b(v(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||y;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,i=p(t),o=n.indexOf("\n"+i);if(o>=0){var a=n.indexOf("\n",o+1);n=n.substring(a+1)}this.stack=n}}},a.inherits(h.AssertionError,Error),h.fail=y,h.ok=m,h.equal=function(e,t,r){e!=t&&y(e,t,r,"==",h.equal)},h.notEqual=function(e,t,r){e==t&&y(e,t,r,"!=",h.notEqual)},h.deepEqual=function(e,t,r){g(e,t,!1)||y(e,t,r,"deepEqual",h.deepEqual)},h.deepStrictEqual=function(e,t,r){g(e,t,!0)||y(e,t,r,"deepStrictEqual",h.deepStrictEqual)},h.notDeepEqual=function(e,t,r){g(e,t,!1)&&y(e,t,r,"notDeepEqual",h.notDeepEqual)},h.notDeepStrictEqual=function e(t,r,n){g(t,r,!0)&&y(t,r,n,"notDeepStrictEqual",e)},h.strictEqual=function(e,t,r){e!==t&&y(e,t,r,"===",h.strictEqual)},h.notStrictEqual=function(e,t,r){e===t&&y(e,t,r,"!==",h.notStrictEqual)},h.throws=function(e,t,r){_(!0,e,t,r)},h.doesNotThrow=function(e,t,r){_(!1,e,t,r)},h.ifError=function(e){if(e)throw e},h.strict=n((function e(t,r){t||y(t,!0,r,"==",e)}),h,{equal:h.strictEqual,deepEqual:h.deepStrictEqual,notEqual:h.notStrictEqual,notDeepEqual:h.notDeepStrictEqual}),h.strict.strict=h.strict;var x=Object.keys||function(e){var t=[];for(var r in e)u.call(e,r)&&t.push(r);return t}}).call(this,r(39))},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(n){"object"===typeof window&&(r=window)}e.exports=r},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){var n=r(69);e.exports=function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&n(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){"use strict";var n=Object.prototype.hasOwnProperty,i="~";function o(){}function a(e,t,r){this.fn=e,this.context=t,this.once=r||!1}function u(e,t,r,n,o){if("function"!==typeof r)throw new TypeError("The listener must be a function");var u=new a(r,n||e,o),s=i?i+t:t;return e._events[s]?e._events[s].fn?e._events[s]=[e._events[s],u]:e._events[s].push(u):(e._events[s]=u,e._eventsCount++),e}function s(e,t){0===--e._eventsCount?e._events=new o:delete e._events[t]}function c(){this._events=new o,this._eventsCount=0}Object.create&&(o.prototype=Object.create(null),(new o).__proto__||(i=!1)),c.prototype.eventNames=function(){var e,t,r=[];if(0===this._eventsCount)return r;for(t in e=this._events)n.call(e,t)&&r.push(i?t.slice(1):t);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(e)):r},c.prototype.listeners=function(e){var t=i?i+e:e,r=this._events[t];if(!r)return[];if(r.fn)return[r.fn];for(var n=0,o=r.length,a=new Array(o);n<o;n++)a[n]=r[n].fn;return a},c.prototype.listenerCount=function(e){var t=i?i+e:e,r=this._events[t];return r?r.fn?1:r.length:0},c.prototype.emit=function(e,t,r,n,o,a){var u=i?i+e:e;if(!this._events[u])return!1;var s,c,f=this._events[u],l=arguments.length;if(f.fn){switch(f.once&&this.removeListener(e,f.fn,void 0,!0),l){case 1:return f.fn.call(f.context),!0;case 2:return f.fn.call(f.context,t),!0;case 3:return f.fn.call(f.context,t,r),!0;case 4:return f.fn.call(f.context,t,r,n),!0;case 5:return f.fn.call(f.context,t,r,n,o),!0;case 6:return f.fn.call(f.context,t,r,n,o,a),!0}for(c=1,s=new Array(l-1);c<l;c++)s[c-1]=arguments[c];f.fn.apply(f.context,s)}else{var h,d=f.length;for(c=0;c<d;c++)switch(f[c].once&&this.removeListener(e,f[c].fn,void 0,!0),l){case 1:f[c].fn.call(f[c].context);break;case 2:f[c].fn.call(f[c].context,t);break;case 3:f[c].fn.call(f[c].context,t,r);break;case 4:f[c].fn.call(f[c].context,t,r,n);break;default:if(!s)for(h=1,s=new Array(l-1);h<l;h++)s[h-1]=arguments[h];f[c].fn.apply(f[c].context,s)}}return!0},c.prototype.on=function(e,t,r){return u(this,e,t,r,!1)},c.prototype.once=function(e,t,r){return u(this,e,t,r,!0)},c.prototype.removeListener=function(e,t,r,n){var o=i?i+e:e;if(!this._events[o])return this;if(!t)return s(this,o),this;var a=this._events[o];if(a.fn)a.fn!==t||n&&!a.once||r&&a.context!==r||s(this,o);else{for(var u=0,c=[],f=a.length;u<f;u++)(a[u].fn!==t||n&&!a[u].once||r&&a[u].context!==r)&&c.push(a[u]);c.length?this._events[o]=1===c.length?c[0]:c:s(this,o)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=i?i+e:e,this._events[t]&&s(this,t)):(this._events=new o,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=i,c.EventEmitter=c,e.exports=c},function(e,t,r){"use strict";function n(e,t){return n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},n(e,t)}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";var n;r.d(t,"b",(function(){return i})),r.d(t,"a",(function(){return o}));var i="undefined"!==typeof window&&!(null===(n=window.process)||void 0===n?void 0:n.hasOwnProperty("type"));function o(e,t){return Array.apply(0,new Array(Math.ceil(e.length/t))).map((function(r,n){return e.slice(n*t,(n+1)*t)}))}},function(e,t){function r(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)}}e.exports=function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){function r(t){return e.exports=r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,r(t)}e.exports=r,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){"use strict";var n=r(22),i=r(34);function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}t.BlockHash=o,o.prototype.update=function(e,t){if(e=n.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var i=0;i<e.length;i+=this._delta32)this._update(e,i,i+this._delta32)}return this},o.prototype.digest=function(e){return this.update(this._pad()),i(null===this.pending),this._digest(e)},o.prototype._pad=function(){var e=this.pendingTotal,t=this._delta8,r=t-(e+this.padLength)%t,n=new Array(r+this.padLength);n[0]=128;for(var i=1;i<r;i++)n[i]=0;if(e<<=3,"big"===this.endian){for(var o=8;o<this.padLength;o++)n[i++]=0;n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=e>>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o<this.padLength;o++)n[i++]=0;return n}},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return h})),r.d(t,"b",(function(){return d}));var n=r(3),i=r(4),o=r(5),a=r(1),u=r.n(a),s=r(27),c=r(19),f=r(16),l=r.n(f),h=8,d=function(){function t(e){if(Object(i.a)(this,t),void 0!==e.accounts){var r=e.accounts.map((function(t){return[t.name,s.a.typeDefLayout(t,e.types)]}));this.accountLayouts=new Map(r)}else this.accountLayouts=new Map}return Object(o.a)(t,[{key:"encode",value:function(){var r=Object(n.a)(u.a.mark((function r(n,i){var o,a,s,c,f;return u.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(o=e.alloc(1e3),a=this.accountLayouts.get(n)){r.next=4;break}throw new Error("Unknown account: ".concat(n));case 4:return s=a.encode(i,o),c=o.slice(0,s),f=t.accountDiscriminator(n),r.abrupt("return",e.concat([f,c]));case 8:case"end":return r.stop()}}),r,this)})));return function(e,t){return r.apply(this,arguments)}}()},{key:"decode",value:function(e,t){var r=t.slice(h),n=this.accountLayouts.get(e);if(!n)throw new Error("Unknown account: ".concat(e));return n.decode(r)}}],[{key:"accountDiscriminator",value:function(t){return e.from(c.sha256.digest("account:".concat(l()(t,{pascalCase:!0})))).slice(0,h)}}]),t}()}).call(this,r(6).Buffer)},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return s}));var n=r(4),i=r(5),o=r(33),a=r(19),u=r(27),s=function(){function t(r){if(Object(n.a)(this,t),void 0!==r.events){var i=r.events.map((function(e){var t={name:e.name,type:{kind:"struct",fields:e.fields.map((function(e){return{name:e.name,type:e.type}}))}};return[e.name,u.a.typeDefLayout(t,r.types)]}));this.layouts=new Map(i),this.discriminators=new Map(void 0===r.events?[]:r.events.map((function(t){return[o.fromByteArray((r=t.name,e.from(a.sha256.digest("event:".concat(r))).slice(0,8))),t.name];var r})))}else this.layouts=new Map}return Object(i.a)(t,[{key:"decode",value:function(t){var r;try{r=e.from(o.toByteArray(t))}catch(u){return null}var n=o.fromByteArray(r.slice(0,8)),i=this.discriminators.get(n);if(void 0===i)return null;var a=this.layouts.get(i);if(!a)throw new Error("Unknown event: ".concat(i));return{data:a.decode(r.slice(8)),name:i}}}]),t}()}).call(this,r(6).Buffer)},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return l})),r.d(t,"b",(function(){return h}));var n=r(3),i=r(4),o=r(5),a=r(1),u=r.n(a),s=r(19),c=r(27),f=r(59),l=function(){function t(e){if(Object(i.a)(this,t),void 0===e.state)throw new Error("Idl state not defined.");this.layout=c.a.typeDefLayout(e.state.struct,e.types)}return Object(o.a)(t,[{key:"encode",value:function(){var t=Object(n.a)(u.a.mark((function t(r,n){var i,o,a,s;return u.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=e.alloc(1e3),o=this.layout.encode(n,i),t.next=4,h(r);case 4:return a=t.sent,s=i.slice(0,o),t.abrupt("return",e.concat([a,s]));case 7:case"end":return t.stop()}}),t,this)})));return function(e,r){return t.apply(this,arguments)}}()},{key:"decode",value:function(e){var t=e.slice(8);return this.layout.decode(t)}}]),t}();function h(e){return d.apply(this,arguments)}function d(){return(d=Object(n.a)(u.a.mark((function t(r){var n;return u.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=f.a("anchor-deprecated-state")?"account":"state",t.abrupt("return",e.from(s.sha256.digest("".concat(n,":").concat(r))).slice(0,8));case 2:case"end":return t.stop()}}),t)})))).apply(this,arguments)}}).call(this,r(6).Buffer)},function(e,t,r){"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(e){return n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(e)}r.d(t,"a",(function(){return n}))},,function(e,t,r){"use strict";var n=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function a(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(i){return!1}}()?Object.assign:function(e,t){for(var r,u,s=a(e),c=1;c<arguments.length;c++){for(var f in r=Object(arguments[c]))i.call(r,f)&&(s[f]=r[f]);if(n){u=n(r);for(var l=0;l<u.length;l++)o.call(r,u[l])&&(s[u[l]]=r[u[l]])}}return s}},function(e,t,r){var n=r(82).default,i=r(83);e.exports=function(e,t){if(t&&("object"===n(t)||"function"===typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return i(e)},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){"use strict";var n=r(26),i=r(21),o=i.getNAF,a=i.getJSF,u=i.assert;function s(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function c(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=s,s.prototype.point=function(){throw new Error("Not implemented")},s.prototype.validate=function(){throw new Error("Not implemented")},s.prototype._fixedNafMul=function(e,t){u(e.precomputed);var r=e._getDoubles(),n=o(t,1,this._bitLength),i=(1<<r.step+1)-(r.step%2===0?2:1);i/=3;var a,s,c=[];for(a=0;a<n.length;a+=r.step){s=0;for(var f=a+r.step-1;f>=a;f--)s=(s<<1)+n[f];c.push(s)}for(var l=this.jpoint(null,null,null),h=this.jpoint(null,null,null),d=i;d>0;d--){for(a=0;a<c.length;a++)(s=c[a])===d?h=h.mixedAdd(r.points[a]):s===-d&&(h=h.mixedAdd(r.points[a].neg()));l=l.add(h)}return l.toP()},s.prototype._wnafMul=function(e,t){var r=4,n=e._getNAFPoints(r);r=n.wnd;for(var i=n.points,a=o(t,r,this._bitLength),s=this.jpoint(null,null,null),c=a.length-1;c>=0;c--){for(var f=0;c>=0&&0===a[c];c--)f++;if(c>=0&&f++,s=s.dblp(f),c<0)break;var l=a[c];u(0!==l),s="affine"===e.type?l>0?s.mixedAdd(i[l-1>>1]):s.mixedAdd(i[-l-1>>1].neg()):l>0?s.add(i[l-1>>1]):s.add(i[-l-1>>1].neg())}return"affine"===e.type?s.toP():s},s.prototype._wnafMulAdd=function(e,t,r,n,i){var u,s,c,f=this._wnafT1,l=this._wnafT2,h=this._wnafT3,d=0;for(u=0;u<n;u++){var p=(c=t[u])._getNAFPoints(e);f[u]=p.wnd,l[u]=p.points}for(u=n-1;u>=1;u-=2){var b=u-1,v=u;if(1===f[b]&&1===f[v]){var y=[t[b],null,null,t[v]];0===t[b].y.cmp(t[v].y)?(y[1]=t[b].add(t[v]),y[2]=t[b].toJ().mixedAdd(t[v].neg())):0===t[b].y.cmp(t[v].y.redNeg())?(y[1]=t[b].toJ().mixedAdd(t[v]),y[2]=t[b].add(t[v].neg())):(y[1]=t[b].toJ().mixedAdd(t[v]),y[2]=t[b].toJ().mixedAdd(t[v].neg()));var m=[-3,-1,-5,-7,0,7,5,1,3],g=a(r[b],r[v]);for(d=Math.max(g[0].length,d),h[b]=new Array(d),h[v]=new Array(d),s=0;s<d;s++){var w=0|g[0][s],k=0|g[1][s];h[b][s]=m[3*(w+1)+(k+1)],h[v][s]=0,l[b]=y}}else h[b]=o(r[b],f[b],this._bitLength),h[v]=o(r[v],f[v],this._bitLength),d=Math.max(h[b].length,d),d=Math.max(h[v].length,d)}var _=this.jpoint(null,null,null),x=this._wnafT4;for(u=d;u>=0;u--){for(var S=0;u>=0;){var E=!0;for(s=0;s<n;s++)x[s]=0|h[s][u],0!==x[s]&&(E=!1);if(!E)break;S++,u--}if(u>=0&&S++,_=_.dblp(S),u<0)break;for(s=0;s<n;s++){var O=x[s];0!==O&&(O>0?c=l[s][O-1>>1]:O<0&&(c=l[s][-O-1>>1].neg()),_="affine"===c.type?_.mixedAdd(c):_.add(c))}}for(u=0;u<n;u++)l[u]=null;return i?_:_.toP()},s.BasePoint=c,c.prototype.eq=function(){throw new Error("Not implemented")},c.prototype.validate=function(){return this.curve.validate(this)},s.prototype.decodePoint=function(e,t){e=i.toArray(e,t);var r=this.p.byteLength();if((4===e[0]||6===e[0]||7===e[0])&&e.length-1===2*r)return 6===e[0]?u(e[e.length-1]%2===0):7===e[0]&&u(e[e.length-1]%2===1),this.point(e.slice(1,1+r),e.slice(1+r,1+2*r));if((2===e[0]||3===e[0])&&e.length-1===r)return this.pointFromX(e.slice(1,1+r),3===e[0]);throw new Error("Unknown point format")},c.prototype.encodeCompressed=function(e){return this.encode(e,!0)},c.prototype._encode=function(e){var t=this.curve.p.byteLength(),r=this.getX().toArray("be",t);return e?[this.getY().isEven()?2:3].concat(r):[4].concat(r,this.getY().toArray("be",t))},c.prototype.encode=function(e,t){return i.encode(this._encode(t),e)},c.prototype.precompute=function(e){if(this.precomputed)return this;var t={doubles:null,naf:null,beta:null};return t.naf=this._getNAFPoints(8),t.doubles=this._getDoubles(4,e),t.beta=this._getBeta(),this.precomputed=t,this},c.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var t=this.precomputed.doubles;return!!t&&t.points.length>=Math.ceil((e.bitLength()+1)/t.step)},c.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i<t;i+=e){for(var o=0;o<e;o++)n=n.dbl();r.push(n)}return{step:e,points:r}},c.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var t=[this],r=(1<<e)-1,n=1===r?null:this.dbl(),i=1;i<r;i++)t[i]=t[i-1].add(n);return{wnd:e,points:t}},c.prototype._getBeta=function(){return null},c.prototype.dblp=function(e){for(var t=this,r=0;r<e;r++)t=t.dbl();return t}},function(e,t){"function"===typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=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){"use strict";(function(e){r.d(t,"a",(function(){return b}));var n=r(7),i=r(12),o=r(4),a=r(5),u=r(16),s=r.n(u),c=r(11),f=r(13),l=r(27),h=r(32),d="state",p="global",b=function(){function t(e){var r=this;Object(o.a)(this,t),this.idl=e,this.ixLayout=t.parseIxLayout(e);var n=new Map;e.instructions.forEach((function(e){var t=Object(h.b)(p,e.name);n.set(f.encode(t),{layout:r.ixLayout.get(e.name),name:e.name})})),e.state&&e.state.methods.map((function(e){var t=Object(h.b)(d,e.name);n.set(f.encode(t),{layout:r.ixLayout.get(e.name),name:e.name})})),this.sighashLayouts=n}return Object(a.a)(t,[{key:"encode",value:function(e,t){return this._encode(p,e,t)}},{key:"encodeState",value:function(e,t){return this._encode(d,e,t)}},{key:"_encode",value:function(t,r,n){var i=e.alloc(1e3),o=s()(r),a=this.ixLayout.get(o);if(!a)throw new Error("Unknown method: ".concat(o));var u=a.encode(n,i),c=i.slice(0,u);return e.concat([Object(h.b)(t,r),c])}},{key:"decode",value:function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"hex";"string"===typeof t&&(t="hex"===r?e.from(t,"hex"):f.decode(t));var n=f.encode(t.slice(0,8)),i=t.slice(8),o=this.sighashLayouts.get(n);return o?{data:o.layout.decode(i),name:o.name}:null}},{key:"format",value:function(e,t){return v.format(e,t,this.idl)}}],[{key:"parseIxLayout",value:function(e){var t=(e.state?e.state.methods:[]).map((function(t){var r=t.args.map((function(t){var r,n;return l.a.fieldLayout(t,Array.from([].concat(Object(i.a)(null!==(r=e.accounts)&&void 0!==r?r:[]),Object(i.a)(null!==(n=e.types)&&void 0!==n?n:[]))))})),n=s()(t.name);return[n,c.struct(r,n)]})).concat(e.instructions.map((function(t){var r=t.args.map((function(t){var r,n;return l.a.fieldLayout(t,Array.from([].concat(Object(i.a)(null!==(r=e.accounts)&&void 0!==r?r:[]),Object(i.a)(null!==(n=e.types)&&void 0!==n?n:[]))))})),n=s()(t.name);return[n,c.struct(r,n)]})));return new Map(t)}}]),t}(),v=function(){function e(){Object(o.a)(this,e)}return Object(a.a)(e,null,[{key:"format",value:function(t,r,i){var o=i.instructions.filter((function(e){return t.name===e.name}))[0];if(void 0===o)return console.error("Invalid instruction given"),null;var a=o.args.map((function(r){return{name:r.name,type:e.formatIdlType(r.type),data:e.formatIdlData(r,t.data[r.name],i.types)}})),u=e.flattenIdlAccounts(o.accounts);return{args:a,accounts:r.map((function(e,t){return t<u.length?Object(n.a)({name:u[t].name},e):Object(n.a)({name:void 0},e)}))}}},{key:"formatIdlType",value:function(e){if("string"===typeof e)return e;if("vec"in e)return"Vec<".concat(this.formatIdlType(e.vec),">");if("option"in e)return"Option<".concat(this.formatIdlType(e.option),">");if("defined"in e)return e.defined;if("array"in e)return"Array<".concat(e.array[0],"; ").concat(e.array[1],">");throw new Error("Unknown IDL type: ".concat(e))}},{key:"formatIdlData",value:function(t,r,n){var i=this;if("string"===typeof t.type)return r.toString();if(t.type.vec)return"["+r.map((function(e){return i.formatIdlData({name:"",type:t.type.vec},e)})).join(", ")+"]";if(t.type.option)return null===r?"null":this.formatIdlData({name:"",type:t.type.option},r);if(t.type.defined){if(void 0===n)throw new Error("User defined types not provided");var o=n.filter((function(e){return e.name===t.type.defined}));if(1!==o.length)throw new Error("Type not found: ".concat(t.type.defined));return e.formatIdlDataDefined(o[0],r,n)}return"unknown"}},{key:"formatIdlDataDefined",value:function(t,r,n){if("struct"===t.type.kind){var i=t.type;return"{ "+Object.keys(r).map((function(t){var o=i.fields.filter((function(e){return e.name===t}))[0];if(void 0===o)throw new Error("Unable to find type");return t+": "+e.formatIdlData(o,r[t],n)})).join(", ")+" }"}if(0===t.type.variants.length)return"{}";if(t.type.variants[0].name){var o=t.type.variants,a=Object.keys(r)[0],u=r[a],c=Object.keys(u).map((function(t){var r,i=u[t],s=null===(r=o[a])||void 0===r?void 0:r.filter((function(e){return e.name===t}))[0];if(void 0===s)throw new Error("Unable to find variant");return t+": "+e.formatIdlData(s,i,n)})).join(", "),f=s()(a,{pascalCase:!0});return 0===c.length?f:"".concat(f," { ").concat(c," }")}return"Tuple formatting not yet implemented"}},{key:"flattenIdlAccounts",value:function(t,r){return t.map((function(t){var i=function(e){var t=e.replace(/([A-Z])/g," $1");return t.charAt(0).toUpperCase()+t.slice(1)}(t.name);if(t.accounts){var o=r?"".concat(r," > ").concat(i):i;return e.flattenIdlAccounts(t.accounts,o)}return Object(n.a)(Object(n.a)({},t),{},{name:r?"".concat(r," > ").concat(i):i})})).flat()}}]),e}()}).call(this,r(6).Buffer)},function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));new Set(["anchor-deprecated-state"]);var n=new Map;function i(e){return void 0!==n.get(e)}},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return w}));var n=r(12),i=r(3),o=r(4),a=r(5),u=r(1),s=r.n(u),c=r(16),f=r.n(c),l=r(42),h=r.n(l),d=r(13),p=r(8),b=r(17),v=r(14),y=r(25),m=r(28),g=r(61),w=function(){function e(){Object(o.a)(this,e)}return Object(a.a)(e,null,[{key:"build",value:function(e,t,r,n){var i,o={};return null===(i=e.accounts)||void 0===i||i.forEach((function(i){var a=f()(i.name);o[a]=new k(e,i,r,n,t)})),o}}]),e}(),k=function(){function t(e,r,n,i,a){var u;Object(o.a)(this,t),this._idlAccount=r,this._programId=n,this._provider=null!==i&&void 0!==i?i:Object(y.c)(),this._coder=null!==a&&void 0!==a?a:new b.d(e),this._size=b.a+(null!==(u=Object(b.c)(e,r))&&void 0!==u?u:0)}return Object(a.a)(t,[{key:"size",get:function(){return this._size}},{key:"programId",get:function(){return this._programId}},{key:"provider",get:function(){return this._provider}},{key:"coder",get:function(){return this._coder}},{key:"fetchNullable",value:function(){var e=Object(i.a)(s.a.mark((function e(t){var r;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this._provider.connection.getAccountInfo(Object(v.c)(t));case 2:if(null!==(r=e.sent)){e.next=5;break}return e.abrupt("return",null);case 5:if(!b.b.accountDiscriminator(this._idlAccount.name).compare(r.data.slice(0,8))){e.next=8;break}throw new Error("Invalid account discriminator");case 8:return e.abrupt("return",this._coder.accounts.decode(this._idlAccount.name,r.data));case 9:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"fetch",value:function(){var e=Object(i.a)(s.a.mark((function e(t){var r;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.fetchNullable(t);case 2:if(null!==(r=e.sent)){e.next=5;break}throw new Error("Account does not exist ".concat(t.toString()));case 5:return e.abrupt("return",r);case 6:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"fetchMultiple",value:function(){var e=Object(i.a)(s.a.mark((function e(t){var r,n,i=this;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,g.a(this._provider.connection,t.map((function(e){return Object(v.c)(e)})));case 2:return r=e.sent,n=b.b.accountDiscriminator(this._idlAccount.name),e.abrupt("return",r.map((function(e){return null==e||n.compare(null===e||void 0===e?void 0:e.account.data.slice(0,8))?null:i._coder.accounts.decode(i._idlAccount.name,null===e||void 0===e?void 0:e.account.data)})));case 5:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"all",value:function(){var t=Object(i.a)(s.a.mark((function t(r){var i,o,a=this;return s.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=b.b.accountDiscriminator(this._idlAccount.name),t.next=3,this._provider.connection.getProgramAccounts(this._programId,{commitment:this._provider.connection.commitment,filters:[{memcmp:{offset:0,bytes:d.encode(r instanceof e?e.concat([i,r]):i)}}].concat(Object(n.a)(Array.isArray(r)?r:[]))});case 3:return o=t.sent,t.abrupt("return",o.map((function(e){var t=e.pubkey,r=e.account;return{publicKey:t,account:a._coder.accounts.decode(a._idlAccount.name,r.data)}})));case 5:case"end":return t.stop()}}),t,this)})));return function(e){return t.apply(this,arguments)}}()},{key:"subscribe",value:function(e,t){var r=this,n=_.get(e.toString());if(n)return n.ee;var i=new h.a;e=Object(v.c)(e);var o=this._provider.connection.onAccountChange(e,(function(e){var t=r._coder.accounts.decode(r._idlAccount.name,e.data);i.emit("change",t)}),t);return _.set(e.toString(),{ee:i,listener:o}),i}},{key:"unsubscribe",value:function(){var e=Object(i.a)(s.a.mark((function e(t){var r;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=_.get(t.toString())){e.next=4;break}return console.warn("Address is not subscribed"),e.abrupt("return");case 4:if(!_){e.next=7;break}return e.next=7,this._provider.connection.removeAccountChangeListener(r.listener).then((function(){_.delete(t.toString())})).catch(console.error);case 7:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"createInstruction",value:function(){var e=Object(i.a)(s.a.mark((function e(t,r){var n;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=this.size,e.t0=p.SystemProgram,e.t1=this._provider.wallet.publicKey,e.t2=t.publicKey,e.t3=null!==r&&void 0!==r?r:n,e.next=7,this._provider.connection.getMinimumBalanceForRentExemption(null!==r&&void 0!==r?r:n);case 7:return e.t4=e.sent,e.t5=this._programId,e.t6={fromPubkey:e.t1,newAccountPubkey:e.t2,space:e.t3,lamports:e.t4,programId:e.t5},e.abrupt("return",e.t0.createAccount.call(e.t0,e.t6));case 11:case"end":return e.stop()}}),e,this)})));return function(t,r){return e.apply(this,arguments)}}()},{key:"associated",value:function(){var e=Object(i.a)(s.a.mark((function e(){var t,r=arguments;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.associatedAddress.apply(this,r);case 2:return t=e.sent,e.next=5,this.fetch(t);case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"associatedAddress",value:function(){var e=Object(i.a)(s.a.mark((function e(){var t,r,n,i=arguments;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:for(t=i.length,r=new Array(t),n=0;n<t;n++)r[n]=i[n];return e.next=3,m.associated.apply(m,[this._programId].concat(r));case 3:return e.abrupt("return",e.sent);case 4:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()}]),t}(),_=new Map}).call(this,r(6).Buffer)},function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return l}));var n=r(10),i=r(3),o=r(1),a=r.n(o),u=r(38),s=r.n(u),c=r(8),f=r(44);r(14),r(36);function l(e,t){return h.apply(this,arguments)}function h(){return(h=Object(i.a)(a.a.mark((function e(t,r){var n,i;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(r.length<=99)){e.next=6;break}return e.next=3,d(t,r);case 3:return e.abrupt("return",e.sent);case 6:return n=Object(f.a)(r,99),e.next=9,Promise.all(n.map((function(e){return d(t,e)})));case 9:return i=e.sent,e.abrupt("return",i.flat());case 11:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function d(e,t){return p.apply(this,arguments)}function p(){return(p=Object(i.a)(a.a.mark((function t(r,i){var o,u,f,l,h,d,p,b,v,y,m;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return o=[i.map((function(e){return e.toBase58()})),{commitment:"recent"}],t.next=3,r._rpcRequest("getMultipleAccounts",o);case 3:if(!(u=t.sent).error){t.next=6;break}throw new Error("failed to get info about accounts "+i.map((function(e){return e.toBase58()})).join(", ")+": "+u.error.message);case 6:s()("undefined"!==typeof u.result),f=[],l=Object(n.a)(u.result.value),t.prev=9,l.s();case 11:if((h=l.n()).done){t.next=23;break}if(d=h.value,p=null,null!==d){t.next=17;break}return f.push(null),t.abrupt("continue",21);case 17:if(u.result.value&&(b=d.executable,v=d.owner,y=d.lamports,m=d.data,s()("base64"===m[1]),p={executable:b,owner:new c.PublicKey(v),lamports:y,data:e.from(m[0],"base64")}),null!==p){t.next=20;break}throw new Error("Invalid response");case 20:f.push(p);case 21:t.next=11;break;case 23:t.next=28;break;case 25:t.prev=25,t.t0=t.catch(9),l.e(t.t0);case 28:return t.prev=28,l.f(),t.finish(28);case 31:return t.abrupt("return",f.map((function(e,t){return null===e?null:{publicKey:i[t],account:e}})));case 32:case"end":return t.stop()}}),t,null,[[9,25,28,31]])})))).apply(this,arguments)}}).call(this,r(6).Buffer)},function(e,t,r){"use strict";function n(e){if(Array.isArray(e))return e}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(e){if("undefined"!==typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";(function(e,n){var i=r(114).default,o=r(115).default,a=r(68).default,u=r(40).default,s=r(45).default,c=r(41).default,f=r(70).default,l=r(120).default,h=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),d=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),p=this&&this.__decorate||function(e,t,r,n){var i,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"===typeof Reflect&&"function"===typeof Reflect.decorate)a=Reflect.decorate(e,t,r,n);else for(var u=e.length-1;u>=0;u--)(i=e[u])&&(a=(o<3?i(a):o>3?i(t,r,a):i(t,r))||a);return o>3&&a&&Object.defineProperty(t,r,a),a},b=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&h(t,e,r);return d(t,e),t},v=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.deserializeUnchecked=t.deserialize=t.serialize=t.BinaryReader=t.BinaryWriter=t.BorshError=t.baseDecode=t.baseEncode=void 0;var y=v(r(23)),m=v(r(13)),g=b(r(123)),w=new("function"!==typeof e.TextDecoder?g.TextDecoder:e.TextDecoder)("utf-8",{fatal:!0});t.baseEncode=function(e){return"string"===typeof e&&(e=n.from(e,"utf8")),m.default.encode(n.from(e))},t.baseDecode=function(e){return n.from(m.default.decode(e))};var k=1024,_=function(e){c(r,e);var t=f(r);function r(e){var n;return u(this,r),(n=t.call(this,e)).fieldPath=[],n.originalMessage=e,n}return s(r,[{key:"addToFieldPath",value:function(e){this.fieldPath.splice(0,0,e),this.message=this.originalMessage+": "+this.fieldPath.join(".")}}]),r}(l(Error));t.BorshError=_;var x=function(){function e(){u(this,e),this.buf=n.alloc(k),this.length=0}return s(e,[{key:"maybeResize",value:function(){this.buf.length<16+this.length&&(this.buf=n.concat([this.buf,n.alloc(k)]))}},{key:"writeU8",value:function(e){this.maybeResize(),this.buf.writeUInt8(e,this.length),this.length+=1}},{key:"writeU16",value:function(e){this.maybeResize(),this.buf.writeUInt16LE(e,this.length),this.length+=2}},{key:"writeU32",value:function(e){this.maybeResize(),this.buf.writeUInt32LE(e,this.length),this.length+=4}},{key:"writeU64",value:function(e){this.maybeResize(),this.writeBuffer(n.from(new y.default(e).toArray("le",8)))}},{key:"writeU128",value:function(e){this.maybeResize(),this.writeBuffer(n.from(new y.default(e).toArray("le",16)))}},{key:"writeU256",value:function(e){this.maybeResize(),this.writeBuffer(n.from(new y.default(e).toArray("le",32)))}},{key:"writeU512",value:function(e){this.maybeResize(),this.writeBuffer(n.from(new y.default(e).toArray("le",64)))}},{key:"writeBuffer",value:function(e){this.buf=n.concat([n.from(this.buf.subarray(0,this.length)),e,n.alloc(k)]),this.length+=e.length}},{key:"writeString",value:function(e){this.maybeResize();var t=n.from(e,"utf8");this.writeU32(t.length),this.writeBuffer(t)}},{key:"writeFixedArray",value:function(e){this.writeBuffer(n.from(e))}},{key:"writeArray",value:function(e,t){this.maybeResize(),this.writeU32(e.length);var r,n=a(e);try{for(n.s();!(r=n.n()).done;){var i=r.value;this.maybeResize(),t(i)}}catch(o){n.e(o)}finally{n.f()}}},{key:"toArray",value:function(){return this.buf.subarray(0,this.length)}}]),e}();function S(e,t,r){var n=r.value;r.value=function(){try{for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return n.apply(this,t)}catch(o){if(o instanceof RangeError){var i=o.code;if(["ERR_BUFFER_OUT_OF_BOUNDS","ERR_OUT_OF_RANGE"].indexOf(i)>=0)throw new _("Reached the end of buffer when deserializing")}throw o}}}t.BinaryWriter=x;var E=function(){function e(t){u(this,e),this.buf=t,this.offset=0}return s(e,[{key:"readU8",value:function(){var e=this.buf.readUInt8(this.offset);return this.offset+=1,e}},{key:"readU16",value:function(){var e=this.buf.readUInt16LE(this.offset);return this.offset+=2,e}},{key:"readU32",value:function(){var e=this.buf.readUInt32LE(this.offset);return this.offset+=4,e}},{key:"readU64",value:function(){var e=this.readBuffer(8);return new y.default(e,"le")}},{key:"readU128",value:function(){var e=this.readBuffer(16);return new y.default(e,"le")}},{key:"readU256",value:function(){var e=this.readBuffer(32);return new y.default(e,"le")}},{key:"readU512",value:function(){var e=this.readBuffer(64);return new y.default(e,"le")}},{key:"readBuffer",value:function(e){if(this.offset+e>this.buf.length)throw new _("Expected buffer length ".concat(e," isn't within bounds"));var t=this.buf.slice(this.offset,this.offset+e);return this.offset+=e,t}},{key:"readString",value:function(){var e=this.readU32(),t=this.readBuffer(e);try{return w.decode(t)}catch(r){throw new _("Error decoding UTF-8 string: ".concat(r))}}},{key:"readFixedArray",value:function(e){return new Uint8Array(this.readBuffer(e))}},{key:"readArray",value:function(e){for(var t=this.readU32(),r=Array(),n=0;n<t;++n)r.push(e());return r}}]),e}();function O(e){return e.charAt(0).toUpperCase()+e.slice(1)}function A(e,t,r,n,i){try{if("string"===typeof n)i["write".concat(O(n))](r);else if(n instanceof Array)if("number"===typeof n[0]){if(r.length!==n[0])throw new _("Expecting byte array of length ".concat(n[0],", but got ").concat(r.length," bytes"));i.writeFixedArray(r)}else i.writeArray(r,(function(r){A(e,t,r,n[0],i)}));else if(void 0!==n.kind){if("option"!==n.kind)throw new _("FieldType ".concat(n," unrecognized"));null===r||void 0===r?i.writeU8(0):(i.writeU8(1),A(e,t,r,n.type,i))}else M(e,r,i)}catch(o){throw o instanceof _&&o.addToFieldPath(t),o}}function M(e,t,r){var n=e.get(t.constructor);if(!n)throw new _("Class ".concat(t.constructor.name," is missing in schema"));if("struct"===n.kind)n.fields.map((function(n){var i=o(n,2),a=i[0],u=i[1];A(e,a,t[a],u,r)}));else{if("enum"!==n.kind)throw new _("Unexpected schema kind: ".concat(n.kind," for ").concat(t.constructor.name));for(var i=t[n.field],a=0;a<n.values.length;++a){var u=o(n.values[a],2),s=u[0],c=u[1];if(s===i){r.writeU8(a),A(e,s,t[s],c,r);break}}}}function j(e,t,r,n){try{return"string"===typeof r?n["read".concat(O(r))]():r instanceof Array?"number"===typeof r[0]?n.readFixedArray(r[0]):n.readArray((function(){return j(e,t,r[0],n)})):"option"===r.kind?n.readU8()?j(e,t,r.type,n):void 0:I(e,r,n)}catch(i){throw i instanceof _&&i.addToFieldPath(t),i}}function I(e,t,r){var n=e.get(t);if(!n)throw new _("Class ".concat(t.name," is missing in schema"));if("struct"===n.kind){var u,s={},c=a(e.get(t).fields);try{for(c.s();!(u=c.n()).done;){var f=o(u.value,2),l=f[0],h=f[1];s[l]=j(e,l,h,r)}}catch(y){c.e(y)}finally{c.f()}return new t(s)}if("enum"===n.kind){var d=r.readU8();if(d>=n.values.length)throw new _("Enum index: ".concat(d," is out of range"));var p=o(n.values[d],2),b=p[0],v=j(e,b,p[1],r);return new t(i({},b,v))}throw new _("Unexpected schema kind: ".concat(n.kind," for ").concat(t.constructor.name))}p([S],E.prototype,"readU8",null),p([S],E.prototype,"readU16",null),p([S],E.prototype,"readU32",null),p([S],E.prototype,"readU64",null),p([S],E.prototype,"readU128",null),p([S],E.prototype,"readU256",null),p([S],E.prototype,"readU512",null),p([S],E.prototype,"readString",null),p([S],E.prototype,"readFixedArray",null),p([S],E.prototype,"readArray",null),t.BinaryReader=E,t.serialize=function(e,t){var r=new x;return M(e,t,r),r.toArray()},t.deserialize=function(e,t,r){var n=new E(r),i=I(e,t,n);if(n.offset<r.length)throw new _("Unexpected ".concat(r.length-n.offset," bytes after deserialized data"));return i},t.deserializeUnchecked=function(e,t,r){return I(e,t,new E(r))}}).call(this,r(39),r(6).Buffer)},function(e,t,r){var n=r(80);e.exports=function(e,t){var r="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=n(e))||t&&e&&"number"===typeof e.length){r&&(e=r);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,u=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var e=r.next();return u=e.done,e},e:function(e){s=!0,a=e},f:function(){try{u||null==r.return||r.return()}finally{if(s)throw a}}}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){function r(t,n){return e.exports=r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,r(t,n)}e.exports=r,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){var n=r(46),i=r(81),o=r(55);e.exports=function(e){var t=i();return function(){var r,i=n(e);if(t){var a=n(this).constructor;r=Reflect.construct(i,arguments,a)}else r=i.apply(this,arguments);return o(this,r)}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){"use strict";var n,i=t,o=r(73),a=r(86),u=r(21).assert;function s(e){"short"===e.type?this.curve=new a.short(e):"edwards"===e.type?this.curve=new a.edwards(e):this.curve=new a.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,u(this.g.validate(),"Invalid curve"),u(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(i,e,{configurable:!0,enumerable:!0,get:function(){var r=new s(t);return Object.defineProperty(i,e,{configurable:!0,enumerable:!0,value:r}),r}})}i.PresetCurve=s,c("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:o.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:o.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:o.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:o.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),c("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:o.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["9"]}),c("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{n=r(144)}catch(f){n=void 0}c("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:o.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",n]})},function(e,t,r){var n=t;n.utils=r(22),n.common=r(47),n.sha=r(138),n.ripemd=r(142),n.hmac=r(143),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},function(e,t){},function(e,t,r){(function(e){var n=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n<t.length;n++)r[t[n]]=Object.getOwnPropertyDescriptor(e,t[n]);return r},i=/%[sdj%]/g;t.format=function(e){if(!y(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(u(arguments[r]));return t.join(" ")}r=1;for(var n=arguments,o=n.length,a=String(e).replace(i,(function(e){if("%%"===e)return"%";if(r>=o)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];r<o;s=n[++r])b(s)||!w(s)?a+=" "+s:a+=" "+u(s);return a},t.deprecate=function(r,n){if("undefined"!==typeof e&&!0===e.noDeprecation)return r;if("undefined"===typeof e)return function(){return t.deprecate(r,n).apply(this,arguments)};var i=!1;return function(){if(!i){if(e.throwDeprecation)throw new Error(n);e.traceDeprecation?console.trace(n):console.error(n),i=!0}return r.apply(this,arguments)}};var o,a={};function u(e,r){var n={seen:[],stylize:c};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),p(r)?n.showHidden=r:r&&t._extend(n,r),m(n.showHidden)&&(n.showHidden=!1),m(n.depth)&&(n.depth=2),m(n.colors)&&(n.colors=!1),m(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=s),f(n,e,n.depth)}function s(e,t){var r=u.styles[t];return r?"\x1b["+u.colors[r][0]+"m"+e+"\x1b["+u.colors[r][1]+"m":e}function c(e,t){return e}function f(e,r,n){if(e.customInspect&&r&&x(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var i=r.inspect(n,e);return y(i)||(i=f(e,i,n)),i}var o=function(e,t){if(m(t))return e.stylize("undefined","undefined");if(y(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(v(t))return e.stylize(""+t,"number");if(p(t))return e.stylize(""+t,"boolean");if(b(t))return e.stylize("null","null")}(e,r);if(o)return o;var a=Object.keys(r),u=function(e){var t={};return e.forEach((function(e,r){t[e]=!0})),t}(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),_(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return l(r);if(0===a.length){if(x(r)){var s=r.name?": "+r.name:"";return e.stylize("[Function"+s+"]","special")}if(g(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(k(r))return e.stylize(Date.prototype.toString.call(r),"date");if(_(r))return l(r)}var c,w="",S=!1,E=["{","}"];(d(r)&&(S=!0,E=["[","]"]),x(r))&&(w=" [Function"+(r.name?": "+r.name:"")+"]");return g(r)&&(w=" "+RegExp.prototype.toString.call(r)),k(r)&&(w=" "+Date.prototype.toUTCString.call(r)),_(r)&&(w=" "+l(r)),0!==a.length||S&&0!=r.length?n<0?g(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),c=S?function(e,t,r,n,i){for(var o=[],a=0,u=t.length;a<u;++a)M(t,String(a))?o.push(h(e,t,r,n,String(a),!0)):o.push("");return i.forEach((function(i){i.match(/^\d+$/)||o.push(h(e,t,r,n,i,!0))})),o}(e,r,n,u,a):a.map((function(t){return h(e,r,n,u,t,S)})),e.seen.pop(),function(e,t,r){if(e.reduce((function(e,t){return t.indexOf("\n")>=0&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60)return r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n  ")+" "+r[1];return r[0]+t+" "+e.join(", ")+" "+r[1]}(c,w,E)):E[0]+w+E[1]}function l(e){return"["+Error.prototype.toString.call(e)+"]"}function h(e,t,r,n,i,o){var a,u,s;if((s=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?u=s.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):s.set&&(u=e.stylize("[Setter]","special")),M(n,i)||(a="["+i+"]"),u||(e.seen.indexOf(s.value)<0?(u=b(r)?f(e,s.value,null):f(e,s.value,r-1)).indexOf("\n")>-1&&(u=o?u.split("\n").map((function(e){return"  "+e})).join("\n").substr(2):"\n"+u.split("\n").map((function(e){return"   "+e})).join("\n")):u=e.stylize("[Circular]","special")),m(a)){if(o&&i.match(/^\d+$/))return u;(a=JSON.stringify(""+i)).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+": "+u}function d(e){return Array.isArray(e)}function p(e){return"boolean"===typeof e}function b(e){return null===e}function v(e){return"number"===typeof e}function y(e){return"string"===typeof e}function m(e){return void 0===e}function g(e){return w(e)&&"[object RegExp]"===S(e)}function w(e){return"object"===typeof e&&null!==e}function k(e){return w(e)&&"[object Date]"===S(e)}function _(e){return w(e)&&("[object Error]"===S(e)||e instanceof Error)}function x(e){return"function"===typeof e}function S(e){return Object.prototype.toString.call(e)}function E(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(r){if(m(o)&&(o=Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0,FAST_REFRESH:!0}).NODE_DEBUG||""),r=r.toUpperCase(),!a[r])if(new RegExp("\\b"+r+"\\b","i").test(o)){var n=e.pid;a[r]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",r,n,e)}}else a[r]=function(){};return a[r]},t.inspect=u,u.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]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=d,t.isBoolean=p,t.isNull=b,t.isNullOrUndefined=function(e){return null==e},t.isNumber=v,t.isString=y,t.isSymbol=function(e){return"symbol"===typeof e},t.isUndefined=m,t.isRegExp=g,t.isObject=w,t.isDate=k,t.isError=_,t.isFunction=x,t.isPrimitive=function(e){return null===e||"boolean"===typeof e||"number"===typeof e||"string"===typeof e||"symbol"===typeof e||"undefined"===typeof e},t.isBuffer=r(154);var O=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function A(){var e=new Date,t=[E(e.getHours()),E(e.getMinutes()),E(e.getSeconds())].join(":");return[e.getDate(),O[e.getMonth()],t].join(" ")}function M(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",A(),t.format.apply(t,arguments))},t.inherits=r(155),t._extend=function(e,t){if(!t||!w(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var j="undefined"!==typeof Symbol?Symbol("util.promisify.custom"):void 0;function I(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!==typeof e)throw new TypeError('The "original" argument must be of type Function');if(j&&e[j]){var t;if("function"!==typeof(t=e[j]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,j,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise((function(e,n){t=e,r=n})),i=[],o=0;o<arguments.length;o++)i.push(arguments[o]);i.push((function(e,n){e?r(e):t(n)}));try{e.apply(this,i)}catch(a){r(a)}return n}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),j&&Object.defineProperty(t,j,{value:t,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(t,n(e))},t.promisify.custom=j,t.callbackify=function(t){if("function"!==typeof t)throw new TypeError('The "original" argument must be of type Function');function r(){for(var r=[],n=0;n<arguments.length;n++)r.push(arguments[n]);var i=r.pop();if("function"!==typeof i)throw new TypeError("The last argument must be of type Function");var o=this,a=function(){return i.apply(o,arguments)};t.apply(this,r).then((function(t){e.nextTick(a,null,t)}),(function(t){e.nextTick(I,t,a)}))}return Object.setPrototypeOf(r,Object.getPrototypeOf(t)),Object.defineProperties(r,n(t)),r}}).call(this,r(35))},function(e,t,r){e.exports=r(129)(r(130))},function(e,t,r){(function(n,i){var o;!function(){"use strict";var a="input is invalid type",u="object"===typeof window,s=u?window:{};s.JS_SHA3_NO_WINDOW&&(u=!1);var c=!u&&"object"===typeof self;!s.JS_SHA3_NO_NODE_JS&&"object"===typeof n&&n.versions&&n.versions.node?s=i:c&&(s=self);var f=!s.JS_SHA3_NO_COMMON_JS&&"object"===typeof e&&e.exports,l=r(90),h=!s.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!==typeof ArrayBuffer,d="0123456789abcdef".split(""),p=[4,1024,262144,67108864],b=[0,8,16,24],v=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],y=[224,256,384,512],m=[128,256],g=["hex","buffer","arrayBuffer","array","digest"],w={128:168,256:136};!s.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!h||!s.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"===typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var k=function(e,t,r){return function(n){return new L(e,t,e).update(n)[r]()}},_=function(e,t,r){return function(n,i){return new L(e,t,i).update(n)[r]()}},x=function(e,t,r){return function(t,n,i,o){return M["cshake"+e].update(t,n,i,o)[r]()}},S=function(e,t,r){return function(t,n,i,o){return M["kmac"+e].update(t,n,i,o)[r]()}},E=function(e,t,r,n){for(var i=0;i<g.length;++i){var o=g[i];e[o]=t(r,n,o)}return e},O=function(e,t){var r=k(e,t,"hex");return r.create=function(){return new L(e,t,e)},r.update=function(e){return r.create().update(e)},E(r,k,e,t)},A=[{name:"keccak",padding:[1,256,65536,16777216],bits:y,createMethod:O},{name:"sha3",padding:[6,1536,393216,100663296],bits:y,createMethod:O},{name:"shake",padding:[31,7936,2031616,520093696],bits:m,createMethod:function(e,t){var r=_(e,t,"hex");return r.create=function(r){return new L(e,t,r)},r.update=function(e,t){return r.create(t).update(e)},E(r,_,e,t)}},{name:"cshake",padding:p,bits:m,createMethod:function(e,t){var r=w[e],n=x(e,0,"hex");return n.create=function(n,i,o){return i||o?new L(e,t,n).bytepad([i,o],r):M["shake"+e].create(n)},n.update=function(e,t,r,i){return n.create(t,r,i).update(e)},E(n,x,e,t)}},{name:"kmac",padding:p,bits:m,createMethod:function(e,t){var r=w[e],n=S(e,0,"hex");return n.create=function(n,i,o){return new z(e,t,i).bytepad(["KMAC",o],r).bytepad([n],r)},n.update=function(e,t,r,i){return n.create(e,r,i).update(t)},E(n,S,e,t)}}],M={},j=[],I=0;I<A.length;++I)for(var P=A[I],R=P.bits,C=0;C<R.length;++C){var T=P.name+"_"+R[C];if(j.push(T),M[T]=P.createMethod(R[C],P.padding),"sha3"!==P.name){var B=P.name+R[C];j.push(B),M[B]=M[T]}}function L(e,t,r){this.blocks=[],this.s=[],this.padding=t,this.outputBits=r,this.reset=!0,this.finalized=!1,this.block=0,this.start=0,this.blockCount=1600-(e<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function z(e,t,r){L.call(this,e,t,r)}L.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!h||!ArrayBuffer.isView(e)))throw new Error(a);t=!0}for(var n,i,o=this.blocks,u=this.byteCount,s=e.length,c=this.blockCount,f=0,l=this.s;f<s;){if(this.reset)for(this.reset=!1,o[0]=this.block,n=1;n<c+1;++n)o[n]=0;if(t)for(n=this.start;f<s&&n<u;++f)o[n>>2]|=e[f]<<b[3&n++];else for(n=this.start;f<s&&n<u;++f)(i=e.charCodeAt(f))<128?o[n>>2]|=i<<b[3&n++]:i<2048?(o[n>>2]|=(192|i>>6)<<b[3&n++],o[n>>2]|=(128|63&i)<<b[3&n++]):i<55296||i>=57344?(o[n>>2]|=(224|i>>12)<<b[3&n++],o[n>>2]|=(128|i>>6&63)<<b[3&n++],o[n>>2]|=(128|63&i)<<b[3&n++]):(i=65536+((1023&i)<<10|1023&e.charCodeAt(++f)),o[n>>2]|=(240|i>>18)<<b[3&n++],o[n>>2]|=(128|i>>12&63)<<b[3&n++],o[n>>2]|=(128|i>>6&63)<<b[3&n++],o[n>>2]|=(128|63&i)<<b[3&n++]);if(this.lastByteIndex=n,n>=u){for(this.start=n-u,this.block=o[c],n=0;n<c;++n)l[n]^=o[n];U(l),this.reset=!0}else this.start=n}return this},L.prototype.encode=function(e,t){var r=255&e,n=1,i=[r];for(r=255&(e>>=8);r>0;)i.unshift(r),r=255&(e>>=8),++n;return t?i.push(n):i.unshift(n),this.update(i),i.length},L.prototype.encodeString=function(e){var t,r=typeof e;if("string"!==r){if("object"!==r)throw new Error(a);if(null===e)throw new Error(a);if(h&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!Array.isArray(e)&&(!h||!ArrayBuffer.isView(e)))throw new Error(a);t=!0}var n=0,i=e.length;if(t)n=i;else for(var o=0;o<e.length;++o){var u=e.charCodeAt(o);u<128?n+=1:u<2048?n+=2:u<55296||u>=57344?n+=3:(u=65536+((1023&u)<<10|1023&e.charCodeAt(++o)),n+=4)}return n+=this.encode(8*n),this.update(e),n},L.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n<e.length;++n)r+=this.encodeString(e[n]);var i=t-r%t,o=[];return o.length=i,this.update(o),this},L.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var e=this.blocks,t=this.lastByteIndex,r=this.blockCount,n=this.s;if(e[t>>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t<r+1;++t)e[t]=0;for(e[r-1]|=2147483648,t=0;t<r;++t)n[t]^=e[t];U(n)}},L.prototype.toString=L.prototype.hex=function(){this.finalize();for(var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,u="";a<n;){for(o=0;o<t&&a<n;++o,++a)e=r[o],u+=d[e>>4&15]+d[15&e]+d[e>>12&15]+d[e>>8&15]+d[e>>20&15]+d[e>>16&15]+d[e>>28&15]+d[e>>24&15];a%t===0&&(U(r),o=0)}return i&&(e=r[o],u+=d[e>>4&15]+d[15&e],i>1&&(u+=d[e>>12&15]+d[e>>8&15]),i>2&&(u+=d[e>>20&15]+d[e>>16&15])),u},L.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,i=this.extraBytes,o=0,a=0,u=this.outputBits>>3;e=i?new ArrayBuffer(n+1<<2):new ArrayBuffer(u);for(var s=new Uint32Array(e);a<n;){for(o=0;o<t&&a<n;++o,++a)s[a]=r[o];a%t===0&&U(r)}return i&&(s[o]=r[o],e=e.slice(0,u)),e},L.prototype.buffer=L.prototype.arrayBuffer,L.prototype.digest=L.prototype.array=function(){this.finalize();for(var e,t,r=this.blockCount,n=this.s,i=this.outputBlocks,o=this.extraBytes,a=0,u=0,s=[];u<i;){for(a=0;a<r&&u<i;++a,++u)e=u<<2,t=n[a],s[e]=255&t,s[e+1]=t>>8&255,s[e+2]=t>>16&255,s[e+3]=t>>24&255;u%r===0&&U(n)}return o&&(e=u<<2,t=n[a],s[e]=255&t,o>1&&(s[e+1]=t>>8&255),o>2&&(s[e+2]=t>>16&255)),s},z.prototype=new L,z.prototype.finalize=function(){return this.encode(this.outputBits,!0),L.prototype.finalize.call(this)};var U=function(e){var t,r,n,i,o,a,u,s,c,f,l,h,d,p,b,y,m,g,w,k,_,x,S,E,O,A,M,j,I,P,R,C,T,B,L,z,U,N,D,F,q,H,W,K,V,Z,Y,X,G,J,$,Q,ee,te,re,ne,ie,oe,ae,ue,se,ce,fe;for(n=0;n<48;n+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],a=e[2]^e[12]^e[22]^e[32]^e[42],u=e[3]^e[13]^e[23]^e[33]^e[43],s=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],f=e[6]^e[16]^e[26]^e[36]^e[46],l=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(a<<1|u>>>31),r=(d=e[9]^e[19]^e[29]^e[39]^e[49])^(u<<1|a>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(s<<1|c>>>31),r=o^(c<<1|s>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=a^(f<<1|l>>>31),r=u^(l<<1|f>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=s^(h<<1|d>>>31),r=c^(d<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=f^(i<<1|o>>>31),r=l^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],b=e[1],Z=e[11]<<4|e[10]>>>28,Y=e[10]<<4|e[11]>>>28,j=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,ue=e[31]<<9|e[30]>>>23,se=e[30]<<9|e[31]>>>23,H=e[40]<<18|e[41]>>>14,W=e[41]<<18|e[40]>>>14,B=e[2]<<1|e[3]>>>31,L=e[3]<<1|e[2]>>>31,y=e[13]<<12|e[12]>>>20,m=e[12]<<12|e[13]>>>20,X=e[22]<<10|e[23]>>>22,G=e[23]<<10|e[22]>>>22,P=e[33]<<13|e[32]>>>19,R=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,fe=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,z=e[14]<<6|e[15]>>>26,U=e[15]<<6|e[14]>>>26,g=e[25]<<11|e[24]>>>21,w=e[24]<<11|e[25]>>>21,J=e[34]<<15|e[35]>>>17,$=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,T=e[44]<<29|e[45]>>>3,E=e[6]<<28|e[7]>>>4,O=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,N=e[26]<<25|e[27]>>>7,D=e[27]<<25|e[26]>>>7,k=e[36]<<21|e[37]>>>11,_=e[37]<<21|e[36]>>>11,Q=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,K=e[8]<<27|e[9]>>>5,V=e[9]<<27|e[8]>>>5,A=e[18]<<20|e[19]>>>12,M=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,ae=e[28]<<7|e[29]>>>25,F=e[38]<<8|e[39]>>>24,q=e[39]<<8|e[38]>>>24,x=e[48]<<14|e[49]>>>18,S=e[49]<<14|e[48]>>>18,e[0]=p^~y&g,e[1]=b^~m&w,e[10]=E^~A&j,e[11]=O^~M&I,e[20]=B^~z&N,e[21]=L^~U&D,e[30]=K^~Z&X,e[31]=V^~Y&G,e[40]=te^~ne&oe,e[41]=re^~ie&ae,e[2]=y^~g&k,e[3]=m^~w&_,e[12]=A^~j&P,e[13]=M^~I&R,e[22]=z^~N&F,e[23]=U^~D&q,e[32]=Z^~X&J,e[33]=Y^~G&$,e[42]=ne^~oe&ue,e[43]=ie^~ae&se,e[4]=g^~k&x,e[5]=w^~_&S,e[14]=j^~P&C,e[15]=I^~R&T,e[24]=N^~F&H,e[25]=D^~q&W,e[34]=X^~J&Q,e[35]=G^~$&ee,e[44]=oe^~ue&ce,e[45]=ae^~se&fe,e[6]=k^~x&p,e[7]=_^~S&b,e[16]=P^~C&E,e[17]=R^~T&O,e[26]=F^~H&B,e[27]=q^~W&L,e[36]=J^~Q&K,e[37]=$^~ee&V,e[46]=ue^~ce&te,e[47]=se^~fe&re,e[8]=x^~p&y,e[9]=S^~b&m,e[18]=C^~E&A,e[19]=T^~O&M,e[28]=H^~B&z,e[29]=W^~L&U,e[38]=Q^~K&Z,e[39]=ee^~V&Y,e[48]=ce^~te&ne,e[49]=fe^~re&ie,e[0]^=v[n],e[1]^=v[n+1]};if(f)e.exports=M;else{for(I=0;I<j.length;++I)s[j[I]]=M[j[I]];l&&(void 0===(o=function(){return M}.call(t,r,t,e))||(e.exports=o))}}()}).call(this,r(35),r(39))},function(e,t,r){"use strict";(function(e){r.d(t,"b",(function(){return s})),r.d(t,"a",(function(){return l}));var n=r(3),i=r(1),o=r.n(i),a=r(8),u=r(11);function s(e){return c.apply(this,arguments)}function c(){return(c=Object(n.a)(o.a.mark((function e(t){var r;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a.PublicKey.findProgramAddress([],t);case 2:return r=e.sent[0],e.next=5,a.PublicKey.createWithSeed(r,"anchor:idl",t);case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var f=u.struct([u.publicKey("authority"),u.vecU8("data")]);function l(e){return f.decode(e)}}).call(this,r(6).Buffer)},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,r){var n=r(118);e.exports=function(e,t){if(e){if("string"===typeof e)return n(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?n(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){function r(t){return e.exports=r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,r(t)}e.exports=r,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){"use strict";var n=t;function i(e){return 1===e.length?"0"+e:e}function o(e){for(var t="",r=0;r<e.length;r++)t+=i(e[r].toString(16));return t}n.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"!==typeof e){for(var n=0;n<e.length;n++)r[n]=0|e[n];return r}if("hex"===t){(e=e.replace(/[^a-z0-9]+/gi,"")).length%2!==0&&(e="0"+e);for(n=0;n<e.length;n+=2)r.push(parseInt(e[n]+e[n+1],16))}else for(n=0;n<e.length;n++){var i=e.charCodeAt(n),o=i>>8,a=255&i;o?r.push(o,a):r.push(a)}return r},n.zero2=i,n.toHex=o,n.encode=function(e,t){return"hex"===t?o(e):e}},function(e,t,r){var n;function i(e){this.rand=e}if(e.exports=function(e){return n||(n=new i(null)),n.generate(e)},e.exports.Rand=i,i.prototype.generate=function(e){return this._rand(e)},i.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r<t.length;r++)t[r]=this.rand.getByte();return t},"object"===typeof self)self.crypto&&self.crypto.getRandomValues?i.prototype._rand=function(e){var t=new Uint8Array(e);return self.crypto.getRandomValues(t),t}:self.msCrypto&&self.msCrypto.getRandomValues?i.prototype._rand=function(e){var t=new Uint8Array(e);return self.msCrypto.getRandomValues(t),t}:"object"===typeof window&&(i.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var o=r(134);if("function"!==typeof o.randomBytes)throw new Error("Not supported");i.prototype._rand=function(e){return o.randomBytes(e)}}catch(a){}},function(e,t,r){"use strict";var n=t;n.base=r(56),n.short=r(135),n.mont=r(136),n.edwards=r(137)},function(e,t,r){"use strict";var n=r(22).rotr32;function i(e,t,r){return e&t^~e&r}function o(e,t,r){return e&t^e&r^t&r}function a(e,t,r){return e^t^r}t.ft_1=function(e,t,r,n){return 0===e?i(t,r,n):1===e||3===e?a(t,r,n):2===e?o(t,r,n):void 0},t.ch32=i,t.maj32=o,t.p32=a,t.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},t.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},t.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},function(e,t,r){"use strict";var n=r(22),i=r(47),o=r(87),a=r(34),u=n.sum32,s=n.sum32_4,c=n.sum32_5,f=o.ch32,l=o.maj32,h=o.s0_256,d=o.s1_256,p=o.g0_256,b=o.g1_256,v=i.BlockHash,y=[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];function m(){if(!(this instanceof m))return new m;v.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=y,this.W=new Array(64)}n.inherits(m,v),e.exports=m,m.blockSize=512,m.outSize=256,m.hmacStrength=192,m.padLength=64,m.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=s(b(r[n-2]),r[n-7],p(r[n-15]),r[n-16]);var i=this.h[0],o=this.h[1],v=this.h[2],y=this.h[3],m=this.h[4],g=this.h[5],w=this.h[6],k=this.h[7];for(a(this.k.length===r.length),n=0;n<r.length;n++){var _=c(k,d(m),f(m,g,w),this.k[n],r[n]),x=u(h(i),l(i,o,v));k=w,w=g,g=m,m=u(y,_),y=v,v=o,o=i,i=u(_,x)}this.h[0]=u(this.h[0],i),this.h[1]=u(this.h[1],o),this.h[2]=u(this.h[2],v),this.h[3]=u(this.h[3],y),this.h[4]=u(this.h[4],m),this.h[5]=u(this.h[5],g),this.h[6]=u(this.h[6],w),this.h[7]=u(this.h[7],k)},m.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},function(e,t,r){"use strict";var n=r(22),i=r(47),o=r(34),a=n.rotr64_hi,u=n.rotr64_lo,s=n.shr64_hi,c=n.shr64_lo,f=n.sum64,l=n.sum64_hi,h=n.sum64_lo,d=n.sum64_4_hi,p=n.sum64_4_lo,b=n.sum64_5_hi,v=n.sum64_5_lo,y=i.BlockHash,m=[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];function g(){if(!(this instanceof g))return new g;y.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=m,this.W=new Array(160)}function w(e,t,r,n,i){var o=e&r^~e&i;return o<0&&(o+=4294967296),o}function k(e,t,r,n,i,o){var a=t&n^~t&o;return a<0&&(a+=4294967296),a}function _(e,t,r,n,i){var o=e&r^e&i^r&i;return o<0&&(o+=4294967296),o}function x(e,t,r,n,i,o){var a=t&n^t&o^n&o;return a<0&&(a+=4294967296),a}function S(e,t){var r=a(e,t,28)^a(t,e,2)^a(t,e,7);return r<0&&(r+=4294967296),r}function E(e,t){var r=u(e,t,28)^u(t,e,2)^u(t,e,7);return r<0&&(r+=4294967296),r}function O(e,t){var r=a(e,t,14)^a(e,t,18)^a(t,e,9);return r<0&&(r+=4294967296),r}function A(e,t){var r=u(e,t,14)^u(e,t,18)^u(t,e,9);return r<0&&(r+=4294967296),r}function M(e,t){var r=a(e,t,1)^a(e,t,8)^s(e,t,7);return r<0&&(r+=4294967296),r}function j(e,t){var r=u(e,t,1)^u(e,t,8)^c(e,t,7);return r<0&&(r+=4294967296),r}function I(e,t){var r=a(e,t,19)^a(t,e,29)^s(e,t,6);return r<0&&(r+=4294967296),r}function P(e,t){var r=u(e,t,19)^u(t,e,29)^c(e,t,6);return r<0&&(r+=4294967296),r}n.inherits(g,y),e.exports=g,g.blockSize=1024,g.outSize=512,g.hmacStrength=192,g.padLength=128,g.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n<r.length;n+=2){var i=I(r[n-4],r[n-3]),o=P(r[n-4],r[n-3]),a=r[n-14],u=r[n-13],s=M(r[n-30],r[n-29]),c=j(r[n-30],r[n-29]),f=r[n-32],l=r[n-31];r[n]=d(i,o,a,u,s,c,f,l),r[n+1]=p(i,o,a,u,s,c,f,l)}},g.prototype._update=function(e,t){this._prepareBlock(e,t);var r=this.W,n=this.h[0],i=this.h[1],a=this.h[2],u=this.h[3],s=this.h[4],c=this.h[5],d=this.h[6],p=this.h[7],y=this.h[8],m=this.h[9],g=this.h[10],M=this.h[11],j=this.h[12],I=this.h[13],P=this.h[14],R=this.h[15];o(this.k.length===r.length);for(var C=0;C<r.length;C+=2){var T=P,B=R,L=O(y,m),z=A(y,m),U=w(y,m,g,M,j),N=k(y,m,g,M,j,I),D=this.k[C],F=this.k[C+1],q=r[C],H=r[C+1],W=b(T,B,L,z,U,N,D,F,q,H),K=v(T,B,L,z,U,N,D,F,q,H);T=S(n,i),B=E(n,i),L=_(n,i,a,u,s),z=x(n,i,a,u,s,c);var V=l(T,B,L,z),Z=h(T,B,L,z);P=j,R=I,j=g,I=M,g=y,M=m,y=l(d,p,W,K),m=h(p,p,W,K),d=s,p=c,s=a,c=u,a=n,u=i,n=l(W,K,V,Z),i=h(W,K,V,Z)}f(this.h,0,n,i),f(this.h,2,a,u),f(this.h,4,s,c),f(this.h,6,d,p),f(this.h,8,y,m),f(this.h,10,g,M),f(this.h,12,j,I),f(this.h,14,P,R)},g.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},function(e,t){(function(t){e.exports=t}).call(this,{})},function(e,t,r){"use strict";(function(e){var n=r(83).default,i=r(68).default,o=r(41).default,a=r(70).default,u=r(40).default,s=r(45).default,c=function(){function e(t,r){if(u(this,e),!Number.isInteger(t))throw new TypeError("span must be an integer");this.span=t,this.property=r}return s(e,[{key:"makeDestinationObject",value:function(){return{}}},{key:"decode",value:function(e,t){throw new Error("Layout is abstract")}},{key:"encode",value:function(e,t,r){throw new Error("Layout is abstract")}},{key:"getSpan",value:function(e,t){if(0>this.span)throw new RangeError("indeterminate span");return this.span}},{key:"replicate",value:function(e){var t=Object.create(this.constructor.prototype);return Object.assign(t,this),t.property=e,t}},{key:"fromArray",value:function(e){}}]),e}();function f(e,t){return t.property?e+"["+t.property+"]":e}t.Layout=c,t.nameWithProperty=f,t.bindConstructorLayout=function(e,t){if("function"!==typeof e)throw new TypeError("Class must be constructor");if(e.hasOwnProperty("layout_"))throw new Error("Class is already bound to a layout");if(!(t&&t instanceof c))throw new TypeError("layout must be a Layout");if(t.hasOwnProperty("boundConstructor_"))throw new Error("layout is already bound to a constructor");e.layout_=t,t.boundConstructor_=e,t.makeDestinationObject=function(){return new e},Object.defineProperty(e.prototype,"encode",{value:function(e,r){return t.encode(this,e,r)},writable:!0}),Object.defineProperty(e,"decode",{value:function(e,r){return t.decode(e,r)},writable:!0})};var l=function(e){o(r,e);var t=a(r);function r(){return u(this,r),t.apply(this,arguments)}return s(r,[{key:"isCount",value:function(){throw new Error("ExternalLayout is abstract")}}]),r}(c),h=function(e){o(r,e);var t=a(r);function r(e,n){var i;if(u(this,r),void 0===e&&(e=1),!Number.isInteger(e)||0>=e)throw new TypeError("elementSpan must be a (positive) integer");return(i=t.call(this,-1,n)).elementSpan=e,i}return s(r,[{key:"isCount",value:function(){return!0}},{key:"decode",value:function(e,t){void 0===t&&(t=0);var r=e.length-t;return Math.floor(r/this.elementSpan)}},{key:"encode",value:function(e,t,r){return 0}}]),r}(l),d=function(e){o(r,e);var t=a(r);function r(e,n,i){var o;if(u(this,r),!(e instanceof c))throw new TypeError("layout must be a Layout");if(void 0===n)n=0;else if(!Number.isInteger(n))throw new TypeError("offset must be integer or undefined");return(o=t.call(this,e.span,i||e.property)).layout=e,o.offset=n,o}return s(r,[{key:"isCount",value:function(){return this.layout instanceof p||this.layout instanceof b}},{key:"decode",value:function(e,t){return void 0===t&&(t=0),this.layout.decode(e,t+this.offset)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),this.layout.encode(e,t,r+this.offset)}}]),r}(l),p=function(e){o(r,e);var t=a(r);function r(e,n){var i;if(u(this,r),6<(i=t.call(this,e,n)).span)throw new RangeError("span must not exceed 6 bytes");return i}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readUIntLE(t,this.span)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeUIntLE(e,r,this.span),this.span}}]),r}(c),b=function(e){o(r,e);var t=a(r);function r(e,n){var i;if(u(this,r),6<(i=t.call(this,e,n)).span)throw new RangeError("span must not exceed 6 bytes");return i}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readUIntBE(t,this.span)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeUIntBE(e,r,this.span),this.span}}]),r}(c),v=function(e){o(r,e);var t=a(r);function r(e,n){var i;if(u(this,r),6<(i=t.call(this,e,n)).span)throw new RangeError("span must not exceed 6 bytes");return i}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readIntLE(t,this.span)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeIntLE(e,r,this.span),this.span}}]),r}(c),y=function(e){o(r,e);var t=a(r);function r(e,n){var i;if(u(this,r),6<(i=t.call(this,e,n)).span)throw new RangeError("span must not exceed 6 bytes");return i}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readIntBE(t,this.span)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeIntBE(e,r,this.span),this.span}}]),r}(c),m=Math.pow(2,32);function g(e){var t=Math.floor(e/m);return{hi32:t,lo32:e-t*m}}function w(e,t){return e*m+t}var k=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,8,e)}return s(r,[{key:"decode",value:function(e,t){void 0===t&&(t=0);var r=e.readUInt32LE(t);return w(e.readUInt32LE(t+4),r)}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=g(e);return t.writeUInt32LE(n.lo32,r),t.writeUInt32LE(n.hi32,r+4),8}}]),r}(c),_=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,8,e)}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),w(e.readUInt32BE(t),e.readUInt32BE(t+4))}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=g(e);return t.writeUInt32BE(n.hi32,r),t.writeUInt32BE(n.lo32,r+4),8}}]),r}(c),x=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,8,e)}return s(r,[{key:"decode",value:function(e,t){void 0===t&&(t=0);var r=e.readUInt32LE(t);return w(e.readInt32LE(t+4),r)}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=g(e);return t.writeUInt32LE(n.lo32,r),t.writeInt32LE(n.hi32,r+4),8}}]),r}(c),S=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,8,e)}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),w(e.readInt32BE(t),e.readUInt32BE(t+4))}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=g(e);return t.writeInt32BE(n.hi32,r),t.writeUInt32BE(n.lo32,r+4),8}}]),r}(c),E=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,4,e)}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readFloatLE(t)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeFloatLE(e,r),4}}]),r}(c),O=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,4,e)}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readFloatBE(t)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeFloatBE(e,r),4}}]),r}(c),A=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,8,e)}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readDoubleLE(t)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeDoubleLE(e,r),8}}]),r}(c),M=function(e){o(r,e);var t=a(r);function r(e){return u(this,r),t.call(this,8,e)}return s(r,[{key:"decode",value:function(e,t){return void 0===t&&(t=0),e.readDoubleBE(t)}},{key:"encode",value:function(e,t,r){return void 0===r&&(r=0),t.writeDoubleBE(e,r),8}}]),r}(c),j=function(e){o(r,e);var t=a(r);function r(e,n,i){var o;if(u(this,r),!(e instanceof c))throw new TypeError("elementLayout must be a Layout");if(!(n instanceof l&&n.isCount()||Number.isInteger(n)&&0<=n))throw new TypeError("count must be non-negative integer or an unsigned integer ExternalLayout");var a=-1;return!(n instanceof l)&&0<e.span&&(a=n*e.span),(o=t.call(this,a,i)).elementLayout=e,o.count=n,o}return s(r,[{key:"getSpan",value:function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=0,n=this.count;if(n instanceof l&&(n=n.decode(e,t)),0<this.elementLayout.span)r=n*this.elementLayout.span;else for(var i=0;i<n;)r+=this.elementLayout.getSpan(e,t+r),++i;return r}},{key:"decode",value:function(e,t){void 0===t&&(t=0);var r=[],n=0,i=this.count;for(i instanceof l&&(i=i.decode(e,t));n<i;)r.push(this.elementLayout.decode(e,t)),t+=this.elementLayout.getSpan(e,t),n+=1;return r}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=this.elementLayout,i=e.reduce((function(e,i){return e+n.encode(i,t,r+e)}),0);return this.count instanceof l&&this.count.encode(e.length,t,r),i}}]),r}(c),I=function(e){o(r,e);var t=a(r);function r(e,n,o){var a;if(u(this,r),!Array.isArray(e)||!e.reduce((function(e,t){return e&&t instanceof c}),!0))throw new TypeError("fields must be array of Layout instances");"boolean"===typeof n&&void 0===o&&(o=n,n=void 0);var s,f=i(e);try{for(f.s();!(s=f.n()).done;){var l=s.value;if(0>l.span&&void 0===l.property)throw new Error("fields cannot contain unnamed variable-length layout")}}catch(d){f.e(d)}finally{f.f()}var h=-1;try{h=e.reduce((function(e,t){return e+t.getSpan()}),0)}catch(p){}return(a=t.call(this,h,n)).fields=e,a.decodePrefixes=!!o,a}return s(r,[{key:"getSpan",value:function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=0;try{r=this.fields.reduce((function(r,n){var i=n.getSpan(e,t);return t+=i,r+i}),0)}catch(n){throw new RangeError("indeterminate span")}return r}},{key:"decode",value:function(e,t){void 0===t&&(t=0);var r,n=this.makeDestinationObject(),o=i(this.fields);try{for(o.s();!(r=o.n()).done;){var a=r.value;if(void 0!==a.property&&(n[a.property]=a.decode(e,t)),t+=a.getSpan(e,t),this.decodePrefixes&&e.length===t)break}}catch(u){o.e(u)}finally{o.f()}return n}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n,o=r,a=0,u=0,s=i(this.fields);try{for(s.s();!(n=s.n()).done;){var c=n.value,f=c.span;if(u=0<f?f:0,void 0!==c.property){var l=e[c.property];void 0!==l&&(u=c.encode(l,t,r),0>f&&(f=c.getSpan(t,r)))}a=r,r+=f}}catch(h){s.e(h)}finally{s.f()}return a+u-o}},{key:"fromArray",value:function(e){var t,r=this.makeDestinationObject(),n=i(this.fields);try{for(n.s();!(t=n.n()).done;){var o=t.value;void 0!==o.property&&0<e.length&&(r[o.property]=e.shift())}}catch(a){n.e(a)}finally{n.f()}return r}},{key:"layoutFor",value:function(e){if("string"!==typeof e)throw new TypeError("property must be string");var t,r=i(this.fields);try{for(r.s();!(t=r.n()).done;){var n=t.value;if(n.property===e)return n}}catch(o){r.e(o)}finally{r.f()}}},{key:"offsetOf",value:function(e){if("string"!==typeof e)throw new TypeError("property must be string");var t,r=0,n=i(this.fields);try{for(n.s();!(t=n.n()).done;){var o=t.value;if(o.property===e)return r;0>o.span?r=-1:0<=r&&(r+=o.span)}}catch(a){n.e(a)}finally{n.f()}}}]),r}(c),P=function(){function e(t){u(this,e),this.property=t}return s(e,[{key:"decode",value:function(){throw new Error("UnionDiscriminator is abstract")}},{key:"encode",value:function(){throw new Error("UnionDiscriminator is abstract")}}]),e}(),R=function(e){o(r,e);var t=a(r);function r(e,n){var i;if(u(this,r),!(e instanceof l&&e.isCount()))throw new TypeError("layout must be an unsigned integer ExternalLayout");return(i=t.call(this,n||e.property||"variant")).layout=e,i}return s(r,[{key:"decode",value:function(e,t){return this.layout.decode(e,t)}},{key:"encode",value:function(e,t,r){return this.layout.encode(e,t,r)}}]),r}(P),C=function(t){o(i,t);var r=a(i);function i(e,t,o){var a;u(this,i);var s=e instanceof p||e instanceof b;if(s)e=new R(new d(e));else if(e instanceof l&&e.isCount())e=new R(e);else if(!(e instanceof P))throw new TypeError("discr must be a UnionDiscriminator or an unsigned integer layout");if(void 0===t&&(t=null),!(null===t||t instanceof c))throw new TypeError("defaultLayout must be null or a Layout");if(null!==t){if(0>t.span)throw new Error("defaultLayout must have constant span");void 0===t.property&&(t=t.replicate("content"))}var f=-1;t&&0<=(f=t.span)&&s&&(f+=e.layout.span),(a=r.call(this,f,o)).discriminator=e,a.usesPrefixDiscriminator=s,a.defaultLayout=t,a.registry={};var h=a.defaultGetSourceVariant.bind(n(a));return a.getSourceVariant=function(e){return h(e)},a.configGetSourceVariant=function(e){h=e.bind(this)},a}return s(i,[{key:"getSpan",value:function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=this.getVariant(e,t);if(!r)throw new Error("unable to determine span for unrecognized variant");return r.getSpan(e,t)}},{key:"defaultGetSourceVariant",value:function(e){if(e.hasOwnProperty(this.discriminator.property)){if(this.defaultLayout&&e.hasOwnProperty(this.defaultLayout.property))return;var t=this.registry[e[this.discriminator.property]];if(t&&(!t.layout||e.hasOwnProperty(t.property)))return t}else for(var r in this.registry){var n=this.registry[r];if(e.hasOwnProperty(n.property))return n}throw new Error("unable to infer src variant")}},{key:"decode",value:function(e,t){var r;void 0===t&&(t=0);var n=this.discriminator,i=n.decode(e,t),o=this.registry[i];if(void 0===o){var a=0;o=this.defaultLayout,this.usesPrefixDiscriminator&&(a=n.layout.span),(r=this.makeDestinationObject())[n.property]=i,r[o.property]=this.defaultLayout.decode(e,t+a)}else r=o.decode(e,t);return r}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=this.getSourceVariant(e);if(void 0===n){var i=this.discriminator,o=this.defaultLayout,a=0;return this.usesPrefixDiscriminator&&(a=i.layout.span),i.encode(e[i.property],t,r),a+o.encode(e[o.property],t,r+a)}return n.encode(e,t,r)}},{key:"addVariant",value:function(e,t,r){var n=new T(this,e,t,r);return this.registry[e]=n,n}},{key:"getVariant",value:function(t,r){var n=t;return e.isBuffer(t)&&(void 0===r&&(r=0),n=this.discriminator.decode(t,r)),this.registry[n]}}]),i}(c),T=function(e){o(r,e);var t=a(r);function r(e,n,i,o){var a;if(u(this,r),!(e instanceof C))throw new TypeError("union must be a Union");if(!Number.isInteger(n)||0>n)throw new TypeError("variant must be a (non-negative) integer");if("string"===typeof i&&void 0===o&&(o=i,i=null),i){if(!(i instanceof c))throw new TypeError("layout must be a Layout");if(null!==e.defaultLayout&&0<=i.span&&i.span>e.defaultLayout.span)throw new Error("variant span exceeds span of containing union");if("string"!==typeof o)throw new TypeError("variant must have a String property")}var s=e.span;return 0>e.span&&0<=(s=i?i.span:0)&&e.usesPrefixDiscriminator&&(s+=e.discriminator.layout.span),(a=t.call(this,s,o)).union=e,a.variant=n,a.layout=i||null,a}return s(r,[{key:"getSpan",value:function(e,t){if(0<=this.span)return this.span;void 0===t&&(t=0);var r=0;return this.union.usesPrefixDiscriminator&&(r=this.union.discriminator.layout.span),r+this.layout.getSpan(e,t+r)}},{key:"decode",value:function(e,t){var r=this.makeDestinationObject();if(void 0===t&&(t=0),this!==this.union.getVariant(e,t))throw new Error("variant mismatch");var n=0;return this.union.usesPrefixDiscriminator&&(n=this.union.discriminator.layout.span),this.layout?r[this.property]=this.layout.decode(e,t+n):this.property?r[this.property]=!0:this.union.usesPrefixDiscriminator&&(r[this.union.discriminator.property]=this.variant),r}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=0;if(this.union.usesPrefixDiscriminator&&(n=this.union.discriminator.layout.span),this.layout&&!e.hasOwnProperty(this.property))throw new TypeError("variant lacks property "+this.property);this.union.discriminator.encode(this.variant,t,r);var i=n;if(this.layout&&(this.layout.encode(e[this.property],t,r+n),i+=this.layout.getSpan(t,r+n),0<=this.union.span&&i>this.union.span))throw new Error("encoded variant overruns containing union");return i}},{key:"fromArray",value:function(e){if(this.layout)return this.layout.fromArray(e)}}]),r}(c);function B(e){return 0>e&&(e+=4294967296),e}var L=function(e){o(r,e);var t=a(r);function r(e,n,i){var o;if(u(this,r),!(e instanceof p||e instanceof b))throw new TypeError("word must be a UInt or UIntBE layout");if("string"===typeof n&&void 0===i&&(i=n,n=void 0),4<e.span)throw new RangeError("word cannot exceed 32 bits");(o=t.call(this,e.span,i)).word=e,o.msb=!!n,o.fields=[];var a=0;return o._packedSetValue=function(e){return a=B(e),this},o._packedGetValue=function(){return a},o}return s(r,[{key:"decode",value:function(e,t){var r=this.makeDestinationObject();void 0===t&&(t=0);var n=this.word.decode(e,t);this._packedSetValue(n);var o,a=i(this.fields);try{for(a.s();!(o=a.n()).done;){var u=o.value;void 0!==u.property&&(r[u.property]=u.decode(n))}}catch(s){a.e(s)}finally{a.f()}return r}},{key:"encode",value:function(e,t,r){void 0===r&&(r=0);var n=this.word.decode(t,r);this._packedSetValue(n);var o,a=i(this.fields);try{for(a.s();!(o=a.n()).done;){var u=o.value;if(void 0!==u.property){var s=e[u.property];void 0!==s&&u.encode(s)}}}catch(c){a.e(c)}finally{a.f()}return this.word.encode(this._packedGetValue(),t,r)}},{key:"addField",value:function(e,t){var r=new z(this,e,t);return this.fields.push(r),r}},{key:"addBoolean",value:function(e){var t=new U(this,e);return this.fields.push(t),t}},{key:"fieldFor",value:function(e){if("string"!==typeof e)throw new TypeError("property must be string");var t,r=i(this.fields);try{for(r.s();!(t=r.n()).done;){var n=t.value;if(n.property===e)return n}}catch(o){r.e(o)}finally{r.f()}}}]),r}(c),z=function(){function e(t,r,n){if(u(this,e),!(t instanceof L))throw new TypeError("container must be a BitStructure");if(!Number.isInteger(r)||0>=r)throw new TypeError("bits must be positive integer");var i=8*t.span,o=t.fields.reduce((function(e,t){return e+t.bits}),0);if(r+o>i)throw new Error("bits too long for span remainder ("+(i-o)+" of "+i+" remain)");this.container=t,this.bits=r,this.valueMask=(1<<r)-1,32===r&&(this.valueMask=4294967295),this.start=o,this.container.msb&&(this.start=i-o-r),this.wordMask=B(this.valueMask<<this.start),this.property=n}return s(e,[{key:"decode",value:function(){return B(this.container._packedGetValue()&this.wordMask)>>>this.start}},{key:"encode",value:function(e){if(!Number.isInteger(e)||e!==B(e&this.valueMask))throw new TypeError(f("BitField.encode",this)+" value must be integer not exceeding "+this.valueMask);var t=this.container._packedGetValue(),r=B(e<<this.start);this.container._packedSetValue(B(t&~this.wordMask)|r)}}]),e}(),U=function(e){o(r,e);var t=a(r);function r(e,n){return u(this,r),t.call(this,e,1,n)}return s(r,[{key:"decode",value:function(e,t){return!!z.prototype.decode.call(this,e,t)}},{key:"encode",value:function(e){return"boolean"===typeof e&&(e=+e),z.prototype.encode.call(this,e)}}]),r}(z),N=function(t){o(n,t);var r=a(n);function n(e,t){var i;if(u(this,n),!(e instanceof l&&e.isCount()||Number.isInteger(e)&&0<=e))throw new TypeError("length must be positive integer or an unsigned integer ExternalLayout");var o=-1;return e instanceof l||(o=e),(i=r.call(this,o,t)).length=e,i}return s(n,[{key:"getSpan",value:function(e,t){var r=this.span;return 0>r&&(r=this.length.decode(e,t)),r}},{key:"decode",value:function(e,t){void 0===t&&(t=0);var r=this.span;return 0>r&&(r=this.length.decode(e,t)),e.slice(t,t+r)}},{key:"encode",value:function(t,r,n){var i=this.length;if(this.length instanceof l&&(i=t.length),!e.isBuffer(t)||i!==t.length)throw new TypeError(f("Blob.encode",this)+" requires (length "+i+") Buffer as src");if(n+i>r.length)throw new RangeError("encoding overruns Buffer");return r.write(t.toString("hex"),n,i,"hex"),this.length instanceof l&&this.length.encode(i,r,n),i}}]),n}(c),D=function(t){o(n,t);var r=a(n);function n(e){return u(this,n),r.call(this,-1,e)}return s(n,[{key:"getSpan",value:function(t,r){if(!e.isBuffer(t))throw new TypeError("b must be a Buffer");void 0===r&&(r=0);for(var n=r;n<t.length&&0!==t[n];)n+=1;return 1+n-r}},{key:"decode",value:function(e,t,r){void 0===t&&(t=0);var n=this.getSpan(e,t);return e.slice(t,t+n-1).toString("utf-8")}},{key:"encode",value:function(t,r,n){void 0===n&&(n=0),"string"!==typeof t&&(t=t.toString());var i=new e(t,"utf8"),o=i.length;if(n+o>r.length)throw new RangeError("encoding overruns Buffer");return i.copy(r,n),r[n+o]=0,o+1}}]),n}(c),F=function(t){o(n,t);var r=a(n);function n(e,t){var i;if(u(this,n),"string"===typeof e&&void 0===t&&(t=e,e=void 0),void 0===e)e=-1;else if(!Number.isInteger(e))throw new TypeError("maxSpan must be an integer");return(i=r.call(this,-1,t)).maxSpan=e,i}return s(n,[{key:"getSpan",value:function(t,r){if(!e.isBuffer(t))throw new TypeError("b must be a Buffer");return void 0===r&&(r=0),t.length-r}},{key:"decode",value:function(e,t,r){void 0===t&&(t=0);var n=this.getSpan(e,t);if(0<=this.maxSpan&&this.maxSpan<n)throw new RangeError("text length exceeds maxSpan");return e.slice(t,t+n).toString("utf-8")}},{key:"encode",value:function(t,r,n){void 0===n&&(n=0),"string"!==typeof t&&(t=t.toString());var i=new e(t,"utf8"),o=i.length;if(0<=this.maxSpan&&this.maxSpan<o)throw new RangeError("text length exceeds maxSpan");if(n+o>r.length)throw new RangeError("encoding overruns Buffer");return i.copy(r,n),o}}]),n}(c),q=function(e){o(r,e);var t=a(r);function r(e,n){var i;return u(this,r),(i=t.call(this,0,n)).value=e,i}return s(r,[{key:"decode",value:function(e,t,r){return this.value}},{key:"encode",value:function(e,t,r){return 0}}]),r}(c);t.ExternalLayout=l,t.GreedyCount=h,t.OffsetLayout=d,t.UInt=p,t.UIntBE=b,t.Int=v,t.IntBE=y,t.Float=E,t.FloatBE=O,t.Double=A,t.DoubleBE=M,t.Sequence=j,t.Structure=I,t.UnionDiscriminator=P,t.UnionLayoutDiscriminator=R,t.Union=C,t.VariantLayout=T,t.BitStructure=L,t.BitField=z,t.Boolean=U,t.Blob=N,t.CString=D,t.UTF8=F,t.Constant=q,t.greedy=function(e,t){return new h(e,t)},t.offset=function(e,t,r){return new d(e,t,r)},t.u8=function(e){return new p(1,e)},t.u16=function(e){return new p(2,e)},t.u24=function(e){return new p(3,e)},t.u32=function(e){return new p(4,e)},t.u40=function(e){return new p(5,e)},t.u48=function(e){return new p(6,e)},t.nu64=function(e){return new k(e)},t.u16be=function(e){return new b(2,e)},t.u24be=function(e){return new b(3,e)},t.u32be=function(e){return new b(4,e)},t.u40be=function(e){return new b(5,e)},t.u48be=function(e){return new b(6,e)},t.nu64be=function(e){return new _(e)},t.s8=function(e){return new v(1,e)},t.s16=function(e){return new v(2,e)},t.s24=function(e){return new v(3,e)},t.s32=function(e){return new v(4,e)},t.s40=function(e){return new v(5,e)},t.s48=function(e){return new v(6,e)},t.ns64=function(e){return new x(e)},t.s16be=function(e){return new y(2,e)},t.s24be=function(e){return new y(3,e)},t.s32be=function(e){return new y(4,e)},t.s40be=function(e){return new y(5,e)},t.s48be=function(e){return new y(6,e)},t.ns64be=function(e){return new S(e)},t.f32=function(e){return new E(e)},t.f32be=function(e){return new O(e)},t.f64=function(e){return new A(e)},t.f64be=function(e){return new M(e)},t.struct=function(e,t,r){return new I(e,t,r)},t.bits=function(e,t,r){return new L(e,t,r)},t.seq=function(e,t,r){return new j(e,t,r)},t.union=function(e,t,r){return new C(e,t,r)},t.unionLayoutDiscriminator=function(e,t){return new R(e,t)},t.blob=function(e,t){return new N(e,t)},t.cstr=function(e){return new D(e)},t.utf8=function(e,t){return new F(e,t)},t.const=function(e,t){return new q(e,t)}}).call(this,r(6).Buffer)},function(e,t,r){"use strict";(function(e){}).call(this,r(6).Buffer)},function(e,t,r){"use strict";(function(e){r(33)}).call(this,r(6).Buffer)},function(e,t,r){"use strict";var n;r.r(t),r.d(t,"v1",(function(){return b})),r.d(t,"v3",(function(){return E})),r.d(t,"v4",(function(){return O})),r.d(t,"v5",(function(){return j})),r.d(t,"NIL",(function(){return I})),r.d(t,"version",(function(){return P})),r.d(t,"validate",(function(){return u})),r.d(t,"stringify",(function(){return h})),r.d(t,"parse",(function(){return v}));var i=new Uint8Array(16);function o(){if(!n&&!(n="undefined"!==typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!==typeof msCrypto&&"function"===typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return n(i)}var a=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;for(var u=function(e){return"string"===typeof e&&a.test(e)},s=[],c=0;c<256;++c)s.push((c+256).toString(16).substr(1));var f,l,h=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=(s[e[t+0]]+s[e[t+1]]+s[e[t+2]]+s[e[t+3]]+"-"+s[e[t+4]]+s[e[t+5]]+"-"+s[e[t+6]]+s[e[t+7]]+"-"+s[e[t+8]]+s[e[t+9]]+"-"+s[e[t+10]]+s[e[t+11]]+s[e[t+12]]+s[e[t+13]]+s[e[t+14]]+s[e[t+15]]).toLowerCase();if(!u(r))throw TypeError("Stringified UUID is invalid");return r},d=0,p=0;var b=function(e,t,r){var n=t&&r||0,i=t||new Array(16),a=(e=e||{}).node||f,u=void 0!==e.clockseq?e.clockseq:l;if(null==a||null==u){var s=e.random||(e.rng||o)();null==a&&(a=f=[1|s[0],s[1],s[2],s[3],s[4],s[5]]),null==u&&(u=l=16383&(s[6]<<8|s[7]))}var c=void 0!==e.msecs?e.msecs:Date.now(),b=void 0!==e.nsecs?e.nsecs:p+1,v=c-d+(b-p)/1e4;if(v<0&&void 0===e.clockseq&&(u=u+1&16383),(v<0||c>d)&&void 0===e.nsecs&&(b=0),b>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");d=c,p=b,l=u;var y=(1e4*(268435455&(c+=122192928e5))+b)%4294967296;i[n++]=y>>>24&255,i[n++]=y>>>16&255,i[n++]=y>>>8&255,i[n++]=255&y;var m=c/4294967296*1e4&268435455;i[n++]=m>>>8&255,i[n++]=255&m,i[n++]=m>>>24&15|16,i[n++]=m>>>16&255,i[n++]=u>>>8|128,i[n++]=255&u;for(var g=0;g<6;++g)i[n+g]=a[g];return t||h(i)};var v=function(e){if(!u(e))throw TypeError("Invalid UUID");var t,r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=255&t,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=255&t,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=255&t,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=255&t,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=255&t,r};var y=function(e,t,r){function n(e,n,i,o){if("string"===typeof e&&(e=function(e){e=unescape(encodeURIComponent(e));for(var t=[],r=0;r<e.length;++r)t.push(e.charCodeAt(r));return t}(e)),"string"===typeof n&&(n=v(n)),16!==n.length)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");var a=new Uint8Array(16+e.length);if(a.set(n),a.set(e,n.length),(a=r(a))[6]=15&a[6]|t,a[8]=63&a[8]|128,i){o=o||0;for(var u=0;u<16;++u)i[o+u]=a[u];return i}return h(a)}try{n.name=e}catch(i){}return n.DNS="6ba7b810-9dad-11d1-80b4-00c04fd430c8",n.URL="6ba7b811-9dad-11d1-80b4-00c04fd430c8",n};function m(e){return 14+(e+64>>>9<<4)+1}function g(e,t){var r=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(r>>16)<<16|65535&r}function w(e,t,r,n,i,o){return g((a=g(g(t,e),g(n,o)))<<(u=i)|a>>>32-u,r);var a,u}function k(e,t,r,n,i,o,a){return w(t&r|~t&n,e,t,i,o,a)}function _(e,t,r,n,i,o,a){return w(t&n|r&~n,e,t,i,o,a)}function x(e,t,r,n,i,o,a){return w(t^r^n,e,t,i,o,a)}function S(e,t,r,n,i,o,a){return w(r^(t|~n),e,t,i,o,a)}var E=y("v3",48,(function(e){if("string"===typeof e){var t=unescape(encodeURIComponent(e));e=new Uint8Array(t.length);for(var r=0;r<t.length;++r)e[r]=t.charCodeAt(r)}return function(e){for(var t=[],r=32*e.length,n="0123456789abcdef",i=0;i<r;i+=8){var o=e[i>>5]>>>i%32&255,a=parseInt(n.charAt(o>>>4&15)+n.charAt(15&o),16);t.push(a)}return t}(function(e,t){e[t>>5]|=128<<t%32,e[m(t)-1]=t;for(var r=1732584193,n=-271733879,i=-1732584194,o=271733878,a=0;a<e.length;a+=16){var u=r,s=n,c=i,f=o;r=k(r,n,i,o,e[a],7,-680876936),o=k(o,r,n,i,e[a+1],12,-389564586),i=k(i,o,r,n,e[a+2],17,606105819),n=k(n,i,o,r,e[a+3],22,-1044525330),r=k(r,n,i,o,e[a+4],7,-176418897),o=k(o,r,n,i,e[a+5],12,1200080426),i=k(i,o,r,n,e[a+6],17,-1473231341),n=k(n,i,o,r,e[a+7],22,-45705983),r=k(r,n,i,o,e[a+8],7,1770035416),o=k(o,r,n,i,e[a+9],12,-1958414417),i=k(i,o,r,n,e[a+10],17,-42063),n=k(n,i,o,r,e[a+11],22,-1990404162),r=k(r,n,i,o,e[a+12],7,1804603682),o=k(o,r,n,i,e[a+13],12,-40341101),i=k(i,o,r,n,e[a+14],17,-1502002290),r=_(r,n=k(n,i,o,r,e[a+15],22,1236535329),i,o,e[a+1],5,-165796510),o=_(o,r,n,i,e[a+6],9,-1069501632),i=_(i,o,r,n,e[a+11],14,643717713),n=_(n,i,o,r,e[a],20,-373897302),r=_(r,n,i,o,e[a+5],5,-701558691),o=_(o,r,n,i,e[a+10],9,38016083),i=_(i,o,r,n,e[a+15],14,-660478335),n=_(n,i,o,r,e[a+4],20,-405537848),r=_(r,n,i,o,e[a+9],5,568446438),o=_(o,r,n,i,e[a+14],9,-1019803690),i=_(i,o,r,n,e[a+3],14,-187363961),n=_(n,i,o,r,e[a+8],20,1163531501),r=_(r,n,i,o,e[a+13],5,-1444681467),o=_(o,r,n,i,e[a+2],9,-51403784),i=_(i,o,r,n,e[a+7],14,1735328473),r=x(r,n=_(n,i,o,r,e[a+12],20,-1926607734),i,o,e[a+5],4,-378558),o=x(o,r,n,i,e[a+8],11,-2022574463),i=x(i,o,r,n,e[a+11],16,1839030562),n=x(n,i,o,r,e[a+14],23,-35309556),r=x(r,n,i,o,e[a+1],4,-1530992060),o=x(o,r,n,i,e[a+4],11,1272893353),i=x(i,o,r,n,e[a+7],16,-155497632),n=x(n,i,o,r,e[a+10],23,-1094730640),r=x(r,n,i,o,e[a+13],4,681279174),o=x(o,r,n,i,e[a],11,-358537222),i=x(i,o,r,n,e[a+3],16,-722521979),n=x(n,i,o,r,e[a+6],23,76029189),r=x(r,n,i,o,e[a+9],4,-640364487),o=x(o,r,n,i,e[a+12],11,-421815835),i=x(i,o,r,n,e[a+15],16,530742520),r=S(r,n=x(n,i,o,r,e[a+2],23,-995338651),i,o,e[a],6,-198630844),o=S(o,r,n,i,e[a+7],10,1126891415),i=S(i,o,r,n,e[a+14],15,-1416354905),n=S(n,i,o,r,e[a+5],21,-57434055),r=S(r,n,i,o,e[a+12],6,1700485571),o=S(o,r,n,i,e[a+3],10,-1894986606),i=S(i,o,r,n,e[a+10],15,-1051523),n=S(n,i,o,r,e[a+1],21,-2054922799),r=S(r,n,i,o,e[a+8],6,1873313359),o=S(o,r,n,i,e[a+15],10,-30611744),i=S(i,o,r,n,e[a+6],15,-1560198380),n=S(n,i,o,r,e[a+13],21,1309151649),r=S(r,n,i,o,e[a+4],6,-145523070),o=S(o,r,n,i,e[a+11],10,-1120210379),i=S(i,o,r,n,e[a+2],15,718787259),n=S(n,i,o,r,e[a+9],21,-343485551),r=g(r,u),n=g(n,s),i=g(i,c),o=g(o,f)}return[r,n,i,o]}(function(e){if(0===e.length)return[];for(var t=8*e.length,r=new Uint32Array(m(t)),n=0;n<t;n+=8)r[n>>5]|=(255&e[n/8])<<n%32;return r}(e),8*e.length))}));var O=function(e,t,r){var n=(e=e||{}).random||(e.rng||o)();if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,t){r=r||0;for(var i=0;i<16;++i)t[r+i]=n[i];return t}return h(n)};function A(e,t,r,n){switch(e){case 0:return t&r^~t&n;case 1:case 3:return t^r^n;case 2:return t&r^t&n^r&n}}function M(e,t){return e<<t|e>>>32-t}var j=y("v5",80,(function(e){var t=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if("string"===typeof e){var n=unescape(encodeURIComponent(e));e=[];for(var i=0;i<n.length;++i)e.push(n.charCodeAt(i))}else Array.isArray(e)||(e=Array.prototype.slice.call(e));e.push(128);for(var o=e.length/4+2,a=Math.ceil(o/16),u=new Array(a),s=0;s<a;++s){for(var c=new Uint32Array(16),f=0;f<16;++f)c[f]=e[64*s+4*f]<<24|e[64*s+4*f+1]<<16|e[64*s+4*f+2]<<8|e[64*s+4*f+3];u[s]=c}u[a-1][14]=8*(e.length-1)/Math.pow(2,32),u[a-1][14]=Math.floor(u[a-1][14]),u[a-1][15]=8*(e.length-1)&4294967295;for(var l=0;l<a;++l){for(var h=new Uint32Array(80),d=0;d<16;++d)h[d]=u[l][d];for(var p=16;p<80;++p)h[p]=M(h[p-3]^h[p-8]^h[p-14]^h[p-16],1);for(var b=r[0],v=r[1],y=r[2],m=r[3],g=r[4],w=0;w<80;++w){var k=Math.floor(w/20),_=M(b,5)+A(k,v,y,m)+g+t[k]+h[w]>>>0;g=m,m=y,y=M(v,30)>>>0,v=b,b=_}r[0]=r[0]+b>>>0,r[1]=r[1]+v>>>0,r[2]=r[2]+y>>>0,r[3]=r[3]+m>>>0,r[4]=r[4]+g>>>0}return[r[0]>>24&255,r[0]>>16&255,r[0]>>8&255,255&r[0],r[1]>>24&255,r[1]>>16&255,r[1]>>8&255,255&r[1],r[2]>>24&255,r[2]>>16&255,r[2]>>8&255,255&r[2],r[3]>>24&255,r[3]>>16&255,r[3]>>8&255,255&r[3],r[4]>>24&255,r[4]>>16&255,r[4]>>8&255,255&r[4]]})),I="00000000-0000-0000-0000-000000000000";var P=function(e){if(!u(e))throw TypeError("Invalid UUID");return parseInt(e.substr(14,1),16)}},function(e,t,r){"use strict";!function e(){if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"===typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}(),e.exports=r(102)},function(e,t,r){"use strict";var n=r(71);Object.defineProperty(t,"__esModule",{value:!0}),t.Client=void 0;var i=n(r(40)),o=n(r(41)),a=n(r(55)),u=n(r(46)),s=n(r(124));function c(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,u.default)(e);if(t){var i=(0,u.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,a.default)(this,r)}}var f=function(e){(0,o.default)(r,e);var t=c(r);function r(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"ws://localhost:8080",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=n.autoconnect,a=void 0===o||o,u=n.reconnect,c=void 0===u||u,f=n.reconnect_interval,l=void 0===f?1e3:f,h=n.max_reconnects,d=void 0===h?5:h,p=arguments.length>2?arguments[2]:void 0;return(0,i.default)(this,r),t.call(this,s.default,e,{autoconnect:a,reconnect:c,reconnect_interval:l,max_reconnects:d},p)}return r}(n(r(125)).default);t.Client=f},function(e,t,r){"use strict";var n=r(94).v4,i=r(128),o=function e(t,r){if(!(this instanceof e))return new e(t,r);r||(r={}),this.options={reviver:"undefined"!==typeof r.reviver?r.reviver:null,replacer:"undefined"!==typeof r.replacer?r.replacer:null,generator:"undefined"!==typeof r.generator?r.generator:function(){return n()},version:"undefined"!==typeof r.version?r.version:2,notificationIdNull:"boolean"===typeof r.notificationIdNull&&r.notificationIdNull},this.callServer=t};e.exports=o,o.prototype.request=function(e,t,r,n){var o,a=this,u=null,s=Array.isArray(e)&&"function"===typeof t;if(1===this.options.version&&s)throw new TypeError("JSON-RPC 1.0 does not support batching");if(s||!s&&e&&"object"===typeof e&&"function"===typeof t)n=t,u=e;else{"function"===typeof r&&(n=r,r=void 0);var c="function"===typeof n;try{u=i(e,t,r,{generator:this.options.generator,version:this.options.version,notificationIdNull:this.options.notificationIdNull})}catch(f){if(c)return n(f);throw f}if(!c)return u}try{o=JSON.stringify(u,this.options.replacer)}catch(f){return n(f)}return this.callServer(o,(function(e,t){a._parseResponse(e,t,n)})),u},o.prototype._parseResponse=function(e,t,r){if(e)r(e);else{if(!t)return r();var n;try{n=JSON.parse(t,this.options.reviver)}catch(e){return r(e)}if(3===r.length){if(Array.isArray(n)){var i=function(e){return"undefined"!==typeof e.error};return r(null,n.filter(i),n.filter((function(e){return!i(e)})))}return r(null,n.error,n.result)}r(null,n)}}},function(e,t,r){var n=r(152),i=r(153);e.exports={parse:function(e){var t=n.parse(e.toString());return i.compile(t)}}},,function(e,t,r){"use strict";r.d(t,"a",(function(){return c}));var n=function(){return n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},n.apply(this,arguments)};Object.create;Object.create;function i(e){return e.toLowerCase()}var o=[/([a-z0-9])([A-Z])/g,/([A-Z])([A-Z][a-z])/g],a=/[^A-Z0-9]+/gi;function u(e,t,r){return t instanceof RegExp?e.replace(t,r):t.reduce((function(e,t){return e.replace(t,r)}),e)}function s(e,t){return void 0===t&&(t={}),function(e,t){void 0===t&&(t={});for(var r=t.splitRegexp,n=void 0===r?o:r,s=t.stripRegexp,c=void 0===s?a:s,f=t.transform,l=void 0===f?i:f,h=t.delimiter,d=void 0===h?" ":h,p=u(u(e,n,"$1\0$2"),c,"\0"),b=0,v=p.length;"\0"===p.charAt(b);)b++;for(;"\0"===p.charAt(v-1);)v--;return p.slice(b,v).split("\0").map(l).join(d)}(e,n({delimiter:"."},t))}function c(e,t){return void 0===t&&(t={}),s(e,n({delimiter:"_"},t))}},function(e,t,r){"use strict";var n=r(54),i=60103,o=60106;t.Fragment=60107,t.StrictMode=60108,t.Profiler=60114;var a=60109,u=60110,s=60112;t.Suspense=60113;var c=60115,f=60116;if("function"===typeof Symbol&&Symbol.for){var l=Symbol.for;i=l("react.element"),o=l("react.portal"),t.Fragment=l("react.fragment"),t.StrictMode=l("react.strict_mode"),t.Profiler=l("react.profiler"),a=l("react.provider"),u=l("react.context"),s=l("react.forward_ref"),t.Suspense=l("react.suspense"),c=l("react.memo"),f=l("react.lazy")}var h="function"===typeof Symbol&&Symbol.iterator;function d(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},b={};function v(e,t,r){this.props=e,this.context=t,this.refs=b,this.updater=r||p}function y(){}function m(e,t,r){this.props=e,this.context=t,this.refs=b,this.updater=r||p}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if("object"!==typeof e&&"function"!==typeof e&&null!=e)throw Error(d(85));this.updater.enqueueSetState(this,e,t,"setState")},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},y.prototype=v.prototype;var g=m.prototype=new y;g.constructor=m,n(g,v.prototype),g.isPureReactComponent=!0;var w={current:null},k=Object.prototype.hasOwnProperty,_={key:!0,ref:!0,__self:!0,__source:!0};function x(e,t,r){var n,o={},a=null,u=null;if(null!=t)for(n in void 0!==t.ref&&(u=t.ref),void 0!==t.key&&(a=""+t.key),t)k.call(t,n)&&!_.hasOwnProperty(n)&&(o[n]=t[n]);var s=arguments.length-2;if(1===s)o.children=r;else if(1<s){for(var c=Array(s),f=0;f<s;f++)c[f]=arguments[f+2];o.children=c}if(e&&e.defaultProps)for(n in s=e.defaultProps)void 0===o[n]&&(o[n]=s[n]);return{$$typeof:i,type:e,key:a,ref:u,props:o,_owner:w.current}}function S(e){return"object"===typeof e&&null!==e&&e.$$typeof===i}var E=/\/+/g;function O(e,t){return"object"===typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function A(e,t,r,n,a){var u=typeof e;"undefined"!==u&&"boolean"!==u||(e=null);var s=!1;if(null===e)s=!0;else switch(u){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case i:case o:s=!0}}if(s)return a=a(s=e),e=""===n?"."+O(s,0):n,Array.isArray(a)?(r="",null!=e&&(r=e.replace(E,"$&/")+"/"),A(a,t,r,"",(function(e){return e}))):null!=a&&(S(a)&&(a=function(e,t){return{$$typeof:i,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,r+(!a.key||s&&s.key===a.key?"":(""+a.key).replace(E,"$&/")+"/")+e)),t.push(a)),1;if(s=0,n=""===n?".":n+":",Array.isArray(e))for(var c=0;c<e.length;c++){var f=n+O(u=e[c],c);s+=A(u,t,r,f,a)}else if(f=function(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=h&&e[h]||e["@@iterator"])?e:null}(e),"function"===typeof f)for(e=f.call(e),c=0;!(u=e.next()).done;)s+=A(u=u.value,t,r,f=n+O(u,c++),a);else if("object"===u)throw t=""+e,Error(d(31,"[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t));return s}function M(e,t,r){if(null==e)return e;var n=[],i=0;return A(e,n,"","",(function(e){return t.call(r,e,i++)})),n}function j(e){if(-1===e._status){var t=e._result;t=t(),e._status=0,e._result=t,t.then((function(t){0===e._status&&(t=t.default,e._status=1,e._result=t)}),(function(t){0===e._status&&(e._status=2,e._result=t)}))}if(1===e._status)return e._result;throw e._result}var I={current:null};function P(){var e=I.current;if(null===e)throw Error(d(321));return e}var R={ReactCurrentDispatcher:I,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:w,IsSomeRendererActing:{current:!1},assign:n};t.Children={map:M,forEach:function(e,t,r){M(e,(function(){t.apply(this,arguments)}),r)},count:function(e){var t=0;return M(e,(function(){t++})),t},toArray:function(e){return M(e,(function(e){return e}))||[]},only:function(e){if(!S(e))throw Error(d(143));return e}},t.Component=v,t.PureComponent=m,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,t.cloneElement=function(e,t,r){if(null===e||void 0===e)throw Error(d(267,e));var o=n({},e.props),a=e.key,u=e.ref,s=e._owner;if(null!=t){if(void 0!==t.ref&&(u=t.ref,s=w.current),void 0!==t.key&&(a=""+t.key),e.type&&e.type.defaultProps)var c=e.type.defaultProps;for(f in t)k.call(t,f)&&!_.hasOwnProperty(f)&&(o[f]=void 0===t[f]&&void 0!==c?c[f]:t[f])}var f=arguments.length-2;if(1===f)o.children=r;else if(1<f){c=Array(f);for(var l=0;l<f;l++)c[l]=arguments[l+2];o.children=c}return{$$typeof:i,type:e.type,key:a,ref:u,props:o,_owner:s}},t.createContext=function(e,t){return void 0===t&&(t=null),(e={$$typeof:u,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:a,_context:e},e.Consumer=e},t.createElement=x,t.createFactory=function(e){var t=x.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:s,render:e}},t.isValidElement=S,t.lazy=function(e){return{$$typeof:f,_payload:{_status:-1,_result:e},_init:j}},t.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},t.useCallback=function(e,t){return P().useCallback(e,t)},t.useContext=function(e,t){return P().useContext(e,t)},t.useDebugValue=function(){},t.useEffect=function(e,t){return P().useEffect(e,t)},t.useImperativeHandle=function(e,t,r){return P().useImperativeHandle(e,t,r)},t.useLayoutEffect=function(e,t){return P().useLayoutEffect(e,t)},t.useMemo=function(e,t){return P().useMemo(e,t)},t.useReducer=function(e,t,r){return P().useReducer(e,t,r)},t.useRef=function(e){return P().useRef(e)},t.useState=function(e){return P().useState(e)},t.version="17.0.2"},function(e,t,r){"use strict";var n=r(24),i=r(54),o=r(103);function a(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!n)throw Error(a(227));var u=new Set,s={};function c(e,t){f(e,t),f(e+"Capture",t)}function f(e,t){for(s[e]=t,e=0;e<t.length;e++)u.add(t[e])}var l=!("undefined"===typeof window||"undefined"===typeof window.document||"undefined"===typeof window.document.createElement),h=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,d=Object.prototype.hasOwnProperty,p={},b={};function v(e,t,r,n,i,o,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=o,this.removeEmptyString=a}var y={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){y[e]=new v(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];y[t]=new v(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){y[e]=new v(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){y[e]=new v(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){y[e]=new v(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){y[e]=new v(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){y[e]=new v(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){y[e]=new v(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){y[e]=new v(e,5,!1,e.toLowerCase(),null,!1,!1)}));var m=/[\-:]([a-z])/g;function g(e){return e[1].toUpperCase()}function w(e,t,r,n){var i=y.hasOwnProperty(t)?y[t]:null;(null!==i?0===i.type:!n&&(2<t.length&&("o"===t[0]||"O"===t[0])&&("n"===t[1]||"N"===t[1])))||(function(e,t,r,n){if(null===t||"undefined"===typeof t||function(e,t,r,n){if(null!==r&&0===r.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!n&&(null!==r?!r.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,r,n))return!0;if(n)return!1;if(null!==r)switch(r.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,r,i,n)&&(r=null),n||null===i?function(e){return!!d.call(b,e)||!d.call(p,e)&&(h.test(e)?b[e]=!0:(p[e]=!0,!1))}(t)&&(null===r?e.removeAttribute(t):e.setAttribute(t,""+r)):i.mustUseProperty?e[i.propertyName]=null===r?3!==i.type&&"":r:(t=i.attributeName,n=i.attributeNamespace,null===r?e.removeAttribute(t):(r=3===(i=i.type)||4===i&&!0===r?"":""+r,n?e.setAttributeNS(n,t,r):e.setAttribute(t,r))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(m,g);y[t]=new v(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(m,g);y[t]=new v(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(m,g);y[t]=new v(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){y[e]=new v(e,1,!1,e.toLowerCase(),null,!1,!1)})),y.xlinkHref=new v("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){y[e]=new v(e,1,!1,e.toLowerCase(),null,!0,!0)}));var k=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,_=60103,x=60106,S=60107,E=60108,O=60114,A=60109,M=60110,j=60112,I=60113,P=60120,R=60115,C=60116,T=60121,B=60128,L=60129,z=60130,U=60131;if("function"===typeof Symbol&&Symbol.for){var N=Symbol.for;_=N("react.element"),x=N("react.portal"),S=N("react.fragment"),E=N("react.strict_mode"),O=N("react.profiler"),A=N("react.provider"),M=N("react.context"),j=N("react.forward_ref"),I=N("react.suspense"),P=N("react.suspense_list"),R=N("react.memo"),C=N("react.lazy"),T=N("react.block"),N("react.scope"),B=N("react.opaque.id"),L=N("react.debug_trace_mode"),z=N("react.offscreen"),U=N("react.legacy_hidden")}var D,F="function"===typeof Symbol&&Symbol.iterator;function q(e){return null===e||"object"!==typeof e?null:"function"===typeof(e=F&&e[F]||e["@@iterator"])?e:null}function H(e){if(void 0===D)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);D=t&&t[1]||""}return"\n"+D+e}var W=!1;function K(e,t){if(!e||W)return"";W=!0;var r=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"===typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(s){var n=s}Reflect.construct(e,[],t)}else{try{t.call()}catch(s){n=s}e.call(t.prototype)}else{try{throw Error()}catch(s){n=s}e()}}catch(s){if(s&&n&&"string"===typeof s.stack){for(var i=s.stack.split("\n"),o=n.stack.split("\n"),a=i.length-1,u=o.length-1;1<=a&&0<=u&&i[a]!==o[u];)u--;for(;1<=a&&0<=u;a--,u--)if(i[a]!==o[u]){if(1!==a||1!==u)do{if(a--,0>--u||i[a]!==o[u])return"\n"+i[a].replace(" at new "," at ")}while(1<=a&&0<=u);break}}}finally{W=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?H(e):""}function V(e){switch(e.tag){case 5:return H(e.type);case 16:return H("Lazy");case 13:return H("Suspense");case 19:return H("SuspenseList");case 0:case 2:case 15:return e=K(e.type,!1);case 11:return e=K(e.type.render,!1);case 22:return e=K(e.type._render,!1);case 1:return e=K(e.type,!0);default:return""}}function Z(e){if(null==e)return null;if("function"===typeof e)return e.displayName||e.name||null;if("string"===typeof e)return e;switch(e){case S:return"Fragment";case x:return"Portal";case O:return"Profiler";case E:return"StrictMode";case I:return"Suspense";case P:return"SuspenseList"}if("object"===typeof e)switch(e.$$typeof){case M:return(e.displayName||"Context")+".Consumer";case A:return(e._context.displayName||"Context")+".Provider";case j:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(""!==t?"ForwardRef("+t+")":"ForwardRef");case R:return Z(e.type);case T:return Z(e._render);case C:t=e._payload,e=e._init;try{return Z(e(t))}catch(r){}}return null}function Y(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function X(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function G(e){e._valueTracker||(e._valueTracker=function(e){var t=X(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&"undefined"!==typeof r&&"function"===typeof r.get&&"function"===typeof r.set){var i=r.get,o=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=""+e,o.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function J(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=X(e)?e.checked?"true":"false":e.value),(e=n)!==r&&(t.setValue(e),!0)}function $(e){if("undefined"===typeof(e=e||("undefined"!==typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function Q(e,t){var r=t.checked;return i({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=r?r:e._wrapperState.initialChecked})}function ee(e,t){var r=null==t.defaultValue?"":t.defaultValue,n=null!=t.checked?t.checked:t.defaultChecked;r=Y(null!=t.value?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function te(e,t){null!=(t=t.checked)&&w(e,"checked",t,!1)}function re(e,t){te(e,t);var r=Y(t.value),n=t.type;if(null!=r)"number"===n?(0===r&&""===e.value||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if("submit"===n||"reset"===n)return void e.removeAttribute("value");t.hasOwnProperty("value")?ie(e,t.type,r):t.hasOwnProperty("defaultValue")&&ie(e,t.type,Y(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function ne(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!("submit"!==n&&"reset"!==n||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}""!==(r=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==r&&(e.name=r)}function ie(e,t,r){"number"===t&&$(e.ownerDocument)===e||(null==r?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}function oe(e,t){return e=i({children:void 0},t),(t=function(e){var t="";return n.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(t.children))&&(e.children=t),e}function ae(e,t,r,n){if(e=e.options,t){t={};for(var i=0;i<r.length;i++)t["$"+r[i]]=!0;for(r=0;r<e.length;r++)i=t.hasOwnProperty("$"+e[r].value),e[r].selected!==i&&(e[r].selected=i),i&&n&&(e[r].defaultSelected=!0)}else{for(r=""+Y(r),t=null,i=0;i<e.length;i++){if(e[i].value===r)return e[i].selected=!0,void(n&&(e[i].defaultSelected=!0));null!==t||e[i].disabled||(t=e[i])}null!==t&&(t.selected=!0)}}function ue(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(a(91));return i({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function se(e,t){var r=t.value;if(null==r){if(r=t.children,t=t.defaultValue,null!=r){if(null!=t)throw Error(a(92));if(Array.isArray(r)){if(!(1>=r.length))throw Error(a(93));r=r[0]}t=r}null==t&&(t=""),r=t}e._wrapperState={initialValue:Y(r)}}function ce(e,t){var r=Y(t.value),n=Y(t.defaultValue);null!=r&&((r=""+r)!==e.value&&(e.value=r),null==t.defaultValue&&e.defaultValue!==r&&(e.defaultValue=r)),null!=n&&(e.defaultValue=""+n)}function fe(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}var le="http://www.w3.org/1999/xhtml",he="http://www.w3.org/2000/svg";function de(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function pe(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?de(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var be,ve,ye=(ve=function(e,t){if(e.namespaceURI!==he||"innerHTML"in e)e.innerHTML=t;else{for((be=be||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=be.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}},"undefined"!==typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,t,r,n){MSApp.execUnsafeLocalFunction((function(){return ve(e,t)}))}:ve);function me(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&3===r.nodeType)return void(r.nodeValue=t)}e.textContent=t}var ge={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},we=["Webkit","ms","Moz","O"];function ke(e,t,r){return null==t||"boolean"===typeof t||""===t?"":r||"number"!==typeof t||0===t||ge.hasOwnProperty(e)&&ge[e]?(""+t).trim():t+"px"}function _e(e,t){for(var r in e=e.style,t)if(t.hasOwnProperty(r)){var n=0===r.indexOf("--"),i=ke(r,t[r],n);"float"===r&&(r="cssFloat"),n?e.setProperty(r,i):e[r]=i}}Object.keys(ge).forEach((function(e){we.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),ge[t]=ge[e]}))}));var xe=i({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Se(e,t){if(t){if(xe[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(a(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(a(60));if("object"!==typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(a(61))}if(null!=t.style&&"object"!==typeof t.style)throw Error(a(62))}}function Ee(e,t){if(-1===e.indexOf("-"))return"string"===typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function Oe(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Ae=null,Me=null,je=null;function Ie(e){if(e=ni(e)){if("function"!==typeof Ae)throw Error(a(280));var t=e.stateNode;t&&(t=oi(t),Ae(e.stateNode,e.type,t))}}function Pe(e){Me?je?je.push(e):je=[e]:Me=e}function Re(){if(Me){var e=Me,t=je;if(je=Me=null,Ie(e),t)for(e=0;e<t.length;e++)Ie(t[e])}}function Ce(e,t){return e(t)}function Te(e,t,r,n,i){return e(t,r,n,i)}function Be(){}var Le=Ce,ze=!1,Ue=!1;function Ne(){null===Me&&null===je||(Be(),Re())}function De(e,t){var r=e.stateNode;if(null===r)return null;var n=oi(r);if(null===n)return null;r=n[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(n=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!n;break e;default:e=!1}if(e)return null;if(r&&"function"!==typeof r)throw Error(a(231,t,typeof r));return r}var Fe=!1;if(l)try{var qe={};Object.defineProperty(qe,"passive",{get:function(){Fe=!0}}),window.addEventListener("test",qe,qe),window.removeEventListener("test",qe,qe)}catch(ve){Fe=!1}function He(e,t,r,n,i,o,a,u,s){var c=Array.prototype.slice.call(arguments,3);try{t.apply(r,c)}catch(f){this.onError(f)}}var We=!1,Ke=null,Ve=!1,Ze=null,Ye={onError:function(e){We=!0,Ke=e}};function Xe(e,t,r,n,i,o,a,u,s){We=!1,Ke=null,He.apply(Ye,arguments)}function Ge(e){var t=e,r=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{0!==(1026&(t=e).flags)&&(r=t.return),e=t.return}while(e)}return 3===t.tag?r:null}function Je(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&(null!==(e=e.alternate)&&(t=e.memoizedState)),null!==t)return t.dehydrated}return null}function $e(e){if(Ge(e)!==e)throw Error(a(188))}function Qe(e){if(e=function(e){var t=e.alternate;if(!t){if(null===(t=Ge(e)))throw Error(a(188));return t!==e?null:e}for(var r=e,n=t;;){var i=r.return;if(null===i)break;var o=i.alternate;if(null===o){if(null!==(n=i.return)){r=n;continue}break}if(i.child===o.child){for(o=i.child;o;){if(o===r)return $e(i),e;if(o===n)return $e(i),t;o=o.sibling}throw Error(a(188))}if(r.return!==n.return)r=i,n=o;else{for(var u=!1,s=i.child;s;){if(s===r){u=!0,r=i,n=o;break}if(s===n){u=!0,n=i,r=o;break}s=s.sibling}if(!u){for(s=o.child;s;){if(s===r){u=!0,r=o,n=i;break}if(s===n){u=!0,n=o,r=i;break}s=s.sibling}if(!u)throw Error(a(189))}}if(r.alternate!==n)throw Error(a(190))}if(3!==r.tag)throw Error(a(188));return r.stateNode.current===r?e:t}(e),!e)return null;for(var t=e;;){if(5===t.tag||6===t.tag)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function et(e,t){for(var r=e.alternate;null!==t;){if(t===e||t===r)return!0;t=t.return}return!1}var tt,rt,nt,it,ot=!1,at=[],ut=null,st=null,ct=null,ft=new Map,lt=new Map,ht=[],dt="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function pt(e,t,r,n,i){return{blockedOn:e,domEventName:t,eventSystemFlags:16|r,nativeEvent:i,targetContainers:[n]}}function bt(e,t){switch(e){case"focusin":case"focusout":ut=null;break;case"dragenter":case"dragleave":st=null;break;case"mouseover":case"mouseout":ct=null;break;case"pointerover":case"pointerout":ft.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":lt.delete(t.pointerId)}}function vt(e,t,r,n,i,o){return null===e||e.nativeEvent!==o?(e=pt(t,r,n,i,o),null!==t&&(null!==(t=ni(t))&&rt(t)),e):(e.eventSystemFlags|=n,t=e.targetContainers,null!==i&&-1===t.indexOf(i)&&t.push(i),e)}function yt(e){var t=ri(e.target);if(null!==t){var r=Ge(t);if(null!==r)if(13===(t=r.tag)){if(null!==(t=Je(r)))return e.blockedOn=t,void it(e.lanePriority,(function(){o.unstable_runWithPriority(e.priority,(function(){nt(r)}))}))}else if(3===t&&r.stateNode.hydrate)return void(e.blockedOn=3===r.tag?r.stateNode.containerInfo:null)}e.blockedOn=null}function mt(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var r=Qt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==r)return null!==(t=ni(r))&&rt(t),e.blockedOn=r,!1;t.shift()}return!0}function gt(e,t,r){mt(e)&&r.delete(t)}function wt(){for(ot=!1;0<at.length;){var e=at[0];if(null!==e.blockedOn){null!==(e=ni(e.blockedOn))&&tt(e);break}for(var t=e.targetContainers;0<t.length;){var r=Qt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==r){e.blockedOn=r;break}t.shift()}null===e.blockedOn&&at.shift()}null!==ut&&mt(ut)&&(ut=null),null!==st&&mt(st)&&(st=null),null!==ct&&mt(ct)&&(ct=null),ft.forEach(gt),lt.forEach(gt)}function kt(e,t){e.blockedOn===t&&(e.blockedOn=null,ot||(ot=!0,o.unstable_scheduleCallback(o.unstable_NormalPriority,wt)))}function _t(e){function t(t){return kt(t,e)}if(0<at.length){kt(at[0],e);for(var r=1;r<at.length;r++){var n=at[r];n.blockedOn===e&&(n.blockedOn=null)}}for(null!==ut&&kt(ut,e),null!==st&&kt(st,e),null!==ct&&kt(ct,e),ft.forEach(t),lt.forEach(t),r=0;r<ht.length;r++)(n=ht[r]).blockedOn===e&&(n.blockedOn=null);for(;0<ht.length&&null===(r=ht[0]).blockedOn;)yt(r),null===r.blockedOn&&ht.shift()}function xt(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var St={animationend:xt("Animation","AnimationEnd"),animationiteration:xt("Animation","AnimationIteration"),animationstart:xt("Animation","AnimationStart"),transitionend:xt("Transition","TransitionEnd")},Et={},Ot={};function At(e){if(Et[e])return Et[e];if(!St[e])return e;var t,r=St[e];for(t in r)if(r.hasOwnProperty(t)&&t in Ot)return Et[e]=r[t];return e}l&&(Ot=document.createElement("div").style,"AnimationEvent"in window||(delete St.animationend.animation,delete St.animationiteration.animation,delete St.animationstart.animation),"TransitionEvent"in window||delete St.transitionend.transition);var Mt=At("animationend"),jt=At("animationiteration"),It=At("animationstart"),Pt=At("transitionend"),Rt=new Map,Ct=new Map,Tt=["abort","abort",Mt,"animationEnd",jt,"animationIteration",It,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",Pt,"transitionEnd","waiting","waiting"];function Bt(e,t){for(var r=0;r<e.length;r+=2){var n=e[r],i=e[r+1];i="on"+(i[0].toUpperCase()+i.slice(1)),Ct.set(n,t),Rt.set(n,i),c(i,[n])}}(0,o.unstable_now)();var Lt=8;function zt(e){if(0!==(1&e))return Lt=15,1;if(0!==(2&e))return Lt=14,2;if(0!==(4&e))return Lt=13,4;var t=24&e;return 0!==t?(Lt=12,t):0!==(32&e)?(Lt=11,32):0!==(t=192&e)?(Lt=10,t):0!==(256&e)?(Lt=9,256):0!==(t=3584&e)?(Lt=8,t):0!==(4096&e)?(Lt=7,4096):0!==(t=4186112&e)?(Lt=6,t):0!==(t=62914560&e)?(Lt=5,t):67108864&e?(Lt=4,67108864):0!==(134217728&e)?(Lt=3,134217728):0!==(t=805306368&e)?(Lt=2,t):0!==(1073741824&e)?(Lt=1,1073741824):(Lt=8,e)}function Ut(e,t){var r=e.pendingLanes;if(0===r)return Lt=0;var n=0,i=0,o=e.expiredLanes,a=e.suspendedLanes,u=e.pingedLanes;if(0!==o)n=o,i=Lt=15;else if(0!==(o=134217727&r)){var s=o&~a;0!==s?(n=zt(s),i=Lt):0!==(u&=o)&&(n=zt(u),i=Lt)}else 0!==(o=r&~a)?(n=zt(o),i=Lt):0!==u&&(n=zt(u),i=Lt);if(0===n)return 0;if(n=r&((0>(n=31-Wt(n))?0:1<<n)<<1)-1,0!==t&&t!==n&&0===(t&a)){if(zt(t),i<=Lt)return t;Lt=i}if(0!==(t=e.entangledLanes))for(e=e.entanglements,t&=n;0<t;)i=1<<(r=31-Wt(t)),n|=e[r],t&=~i;return n}function Nt(e){return 0!==(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function Dt(e,t){switch(e){case 15:return 1;case 14:return 2;case 12:return 0===(e=Ft(24&~t))?Dt(10,t):e;case 10:return 0===(e=Ft(192&~t))?Dt(8,t):e;case 8:return 0===(e=Ft(3584&~t))&&(0===(e=Ft(4186112&~t))&&(e=512)),e;case 2:return 0===(t=Ft(805306368&~t))&&(t=268435456),t}throw Error(a(358,e))}function Ft(e){return e&-e}function qt(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}function Ht(e,t,r){e.pendingLanes|=t;var n=t-1;e.suspendedLanes&=n,e.pingedLanes&=n,(e=e.eventTimes)[t=31-Wt(t)]=r}var Wt=Math.clz32?Math.clz32:function(e){return 0===e?32:31-(Kt(e)/Vt|0)|0},Kt=Math.log,Vt=Math.LN2;var Zt=o.unstable_UserBlockingPriority,Yt=o.unstable_runWithPriority,Xt=!0;function Gt(e,t,r,n){ze||Be();var i=$t,o=ze;ze=!0;try{Te(i,e,t,r,n)}finally{(ze=o)||Ne()}}function Jt(e,t,r,n){Yt(Zt,$t.bind(null,e,t,r,n))}function $t(e,t,r,n){var i;if(Xt)if((i=0===(4&t))&&0<at.length&&-1<dt.indexOf(e))e=pt(null,e,t,r,n),at.push(e);else{var o=Qt(e,t,r,n);if(null===o)i&&bt(e,n);else{if(i){if(-1<dt.indexOf(e))return e=pt(o,e,t,r,n),void at.push(e);if(function(e,t,r,n,i){switch(t){case"focusin":return ut=vt(ut,e,t,r,n,i),!0;case"dragenter":return st=vt(st,e,t,r,n,i),!0;case"mouseover":return ct=vt(ct,e,t,r,n,i),!0;case"pointerover":var o=i.pointerId;return ft.set(o,vt(ft.get(o)||null,e,t,r,n,i)),!0;case"gotpointercapture":return o=i.pointerId,lt.set(o,vt(lt.get(o)||null,e,t,r,n,i)),!0}return!1}(o,e,t,r,n))return;bt(e,n)}Bn(e,t,n,null,r)}}}function Qt(e,t,r,n){var i=Oe(n);if(null!==(i=ri(i))){var o=Ge(i);if(null===o)i=null;else{var a=o.tag;if(13===a){if(null!==(i=Je(o)))return i;i=null}else if(3===a){if(o.stateNode.hydrate)return 3===o.tag?o.stateNode.containerInfo:null;i=null}else o!==i&&(i=null)}}return Bn(e,t,n,i,r),null}var er=null,tr=null,rr=null;function nr(){if(rr)return rr;var e,t,r=tr,n=r.length,i="value"in er?er.value:er.textContent,o=i.length;for(e=0;e<n&&r[e]===i[e];e++);var a=n-e;for(t=1;t<=a&&r[n-t]===i[o-t];t++);return rr=i.slice(e,1<t?1-t:void 0)}function ir(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function or(){return!0}function ar(){return!1}function ur(e){function t(t,r,n,i,o){for(var a in this._reactName=t,this._targetInst=n,this.type=r,this.nativeEvent=i,this.target=o,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(i):i[a]);return this.isDefaultPrevented=(null!=i.defaultPrevented?i.defaultPrevented:!1===i.returnValue)?or:ar,this.isPropagationStopped=ar,this}return i(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!==typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=or)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!==typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=or)},persist:function(){},isPersistent:or}),t}var sr,cr,fr,lr={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},hr=ur(lr),dr=i({},lr,{view:0,detail:0}),pr=ur(dr),br=i({},dr,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ar,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==fr&&(fr&&"mousemove"===e.type?(sr=e.screenX-fr.screenX,cr=e.screenY-fr.screenY):cr=sr=0,fr=e),sr)},movementY:function(e){return"movementY"in e?e.movementY:cr}}),vr=ur(br),yr=ur(i({},br,{dataTransfer:0})),mr=ur(i({},dr,{relatedTarget:0})),gr=ur(i({},lr,{animationName:0,elapsedTime:0,pseudoElement:0})),wr=i({},lr,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),kr=ur(wr),_r=ur(i({},lr,{data:0})),xr={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Sr={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Er={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Or(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=Er[e])&&!!t[e]}function Ar(){return Or}var Mr=i({},dr,{key:function(e){if(e.key){var t=xr[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=ir(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?Sr[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ar,charCode:function(e){return"keypress"===e.type?ir(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?ir(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}}),jr=ur(Mr),Ir=ur(i({},br,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Pr=ur(i({},dr,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ar})),Rr=ur(i({},lr,{propertyName:0,elapsedTime:0,pseudoElement:0})),Cr=i({},br,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Tr=ur(Cr),Br=[9,13,27,32],Lr=l&&"CompositionEvent"in window,zr=null;l&&"documentMode"in document&&(zr=document.documentMode);var Ur=l&&"TextEvent"in window&&!zr,Nr=l&&(!Lr||zr&&8<zr&&11>=zr),Dr=String.fromCharCode(32),Fr=!1;function qr(e,t){switch(e){case"keyup":return-1!==Br.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Hr(e){return"object"===typeof(e=e.detail)&&"data"in e?e.data:null}var Wr=!1;var Kr={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Vr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!Kr[e.type]:"textarea"===t}function Zr(e,t,r,n){Pe(n),0<(t=zn(t,"onChange")).length&&(r=new hr("onChange","change",null,r,n),e.push({event:r,listeners:t}))}var Yr=null,Xr=null;function Gr(e){jn(e,0)}function Jr(e){if(J(ii(e)))return e}function $r(e,t){if("change"===e)return t}var Qr=!1;if(l){var en;if(l){var tn="oninput"in document;if(!tn){var rn=document.createElement("div");rn.setAttribute("oninput","return;"),tn="function"===typeof rn.oninput}en=tn}else en=!1;Qr=en&&(!document.documentMode||9<document.documentMode)}function nn(){Yr&&(Yr.detachEvent("onpropertychange",on),Xr=Yr=null)}function on(e){if("value"===e.propertyName&&Jr(Xr)){var t=[];if(Zr(t,Xr,e,Oe(e)),e=Gr,ze)e(t);else{ze=!0;try{Ce(e,t)}finally{ze=!1,Ne()}}}}function an(e,t,r){"focusin"===e?(nn(),Xr=r,(Yr=t).attachEvent("onpropertychange",on)):"focusout"===e&&nn()}function un(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return Jr(Xr)}function sn(e,t){if("click"===e)return Jr(t)}function cn(e,t){if("input"===e||"change"===e)return Jr(t)}var fn="function"===typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e===1/t)||e!==e&&t!==t},ln=Object.prototype.hasOwnProperty;function hn(e,t){if(fn(e,t))return!0;if("object"!==typeof e||null===e||"object"!==typeof t||null===t)return!1;var r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(n=0;n<r.length;n++)if(!ln.call(t,r[n])||!fn(e[r[n]],t[r[n]]))return!1;return!0}function dn(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function pn(e,t){var r,n=dn(e);for(e=0;n;){if(3===n.nodeType){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=dn(n)}}function bn(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?bn(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function vn(){for(var e=window,t=$();t instanceof e.HTMLIFrameElement;){try{var r="string"===typeof t.contentWindow.location.href}catch(n){r=!1}if(!r)break;t=$((e=t.contentWindow).document)}return t}function yn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var mn=l&&"documentMode"in document&&11>=document.documentMode,gn=null,wn=null,kn=null,_n=!1;function xn(e,t,r){var n=r.window===r?r.document:9===r.nodeType?r:r.ownerDocument;_n||null==gn||gn!==$(n)||("selectionStart"in(n=gn)&&yn(n)?n={start:n.selectionStart,end:n.selectionEnd}:n={anchorNode:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset},kn&&hn(kn,n)||(kn=n,0<(n=zn(wn,"onSelect")).length&&(t=new hr("onSelect","select",null,t,r),e.push({event:t,listeners:n}),t.target=gn)))}Bt("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0),Bt("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1),Bt(Tt,2);for(var Sn="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),En=0;En<Sn.length;En++)Ct.set(Sn[En],0);f("onMouseEnter",["mouseout","mouseover"]),f("onMouseLeave",["mouseout","mouseover"]),f("onPointerEnter",["pointerout","pointerover"]),f("onPointerLeave",["pointerout","pointerover"]),c("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),c("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),c("onBeforeInput",["compositionend","keypress","textInput","paste"]),c("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),c("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var On="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),An=new Set("cancel close invalid load scroll toggle".split(" ").concat(On));function Mn(e,t,r){var n=e.type||"unknown-event";e.currentTarget=r,function(e,t,r,n,i,o,u,s,c){if(Xe.apply(this,arguments),We){if(!We)throw Error(a(198));var f=Ke;We=!1,Ke=null,Ve||(Ve=!0,Ze=f)}}(n,t,void 0,e),e.currentTarget=null}function jn(e,t){t=0!==(4&t);for(var r=0;r<e.length;r++){var n=e[r],i=n.event;n=n.listeners;e:{var o=void 0;if(t)for(var a=n.length-1;0<=a;a--){var u=n[a],s=u.instance,c=u.currentTarget;if(u=u.listener,s!==o&&i.isPropagationStopped())break e;Mn(i,u,c),o=s}else for(a=0;a<n.length;a++){if(s=(u=n[a]).instance,c=u.currentTarget,u=u.listener,s!==o&&i.isPropagationStopped())break e;Mn(i,u,c),o=s}}}if(Ve)throw e=Ze,Ve=!1,Ze=null,e}function In(e,t){var r=ai(t),n=e+"__bubble";r.has(n)||(Tn(t,e,2,!1),r.add(n))}var Pn="_reactListening"+Math.random().toString(36).slice(2);function Rn(e){e[Pn]||(e[Pn]=!0,u.forEach((function(t){An.has(t)||Cn(t,!1,e,null),Cn(t,!0,e,null)})))}function Cn(e,t,r,n){var i=4<arguments.length&&void 0!==arguments[4]?arguments[4]:0,o=r;if("selectionchange"===e&&9!==r.nodeType&&(o=r.ownerDocument),null!==n&&!t&&An.has(e)){if("scroll"!==e)return;i|=2,o=n}var a=ai(o),u=e+"__"+(t?"capture":"bubble");a.has(u)||(t&&(i|=4),Tn(o,e,i,t),a.add(u))}function Tn(e,t,r,n){var i=Ct.get(t);switch(void 0===i?2:i){case 0:i=Gt;break;case 1:i=Jt;break;default:i=$t}r=i.bind(null,t,r,e),i=void 0,!Fe||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(i=!0),n?void 0!==i?e.addEventListener(t,r,{capture:!0,passive:i}):e.addEventListener(t,r,!0):void 0!==i?e.addEventListener(t,r,{passive:i}):e.addEventListener(t,r,!1)}function Bn(e,t,r,n,i){var o=n;if(0===(1&t)&&0===(2&t)&&null!==n)e:for(;;){if(null===n)return;var a=n.tag;if(3===a||4===a){var u=n.stateNode.containerInfo;if(u===i||8===u.nodeType&&u.parentNode===i)break;if(4===a)for(a=n.return;null!==a;){var s=a.tag;if((3===s||4===s)&&((s=a.stateNode.containerInfo)===i||8===s.nodeType&&s.parentNode===i))return;a=a.return}for(;null!==u;){if(null===(a=ri(u)))return;if(5===(s=a.tag)||6===s){n=o=a;continue e}u=u.parentNode}}n=n.return}!function(e,t,r){if(Ue)return e(t,r);Ue=!0;try{Le(e,t,r)}finally{Ue=!1,Ne()}}((function(){var n=o,i=Oe(r),a=[];e:{var u=Rt.get(e);if(void 0!==u){var s=hr,c=e;switch(e){case"keypress":if(0===ir(r))break e;case"keydown":case"keyup":s=jr;break;case"focusin":c="focus",s=mr;break;case"focusout":c="blur",s=mr;break;case"beforeblur":case"afterblur":s=mr;break;case"click":if(2===r.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":s=vr;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":s=yr;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":s=Pr;break;case Mt:case jt:case It:s=gr;break;case Pt:s=Rr;break;case"scroll":s=pr;break;case"wheel":s=Tr;break;case"copy":case"cut":case"paste":s=kr;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":s=Ir}var f=0!==(4&t),l=!f&&"scroll"===e,h=f?null!==u?u+"Capture":null:u;f=[];for(var d,p=n;null!==p;){var b=(d=p).stateNode;if(5===d.tag&&null!==b&&(d=b,null!==h&&(null!=(b=De(p,h))&&f.push(Ln(p,b,d)))),l)break;p=p.return}0<f.length&&(u=new s(u,c,null,r,i),a.push({event:u,listeners:f}))}}if(0===(7&t)){if(s="mouseout"===e||"pointerout"===e,(!(u="mouseover"===e||"pointerover"===e)||0!==(16&t)||!(c=r.relatedTarget||r.fromElement)||!ri(c)&&!c[ei])&&(s||u)&&(u=i.window===i?i:(u=i.ownerDocument)?u.defaultView||u.parentWindow:window,s?(s=n,null!==(c=(c=r.relatedTarget||r.toElement)?ri(c):null)&&(c!==(l=Ge(c))||5!==c.tag&&6!==c.tag)&&(c=null)):(s=null,c=n),s!==c)){if(f=vr,b="onMouseLeave",h="onMouseEnter",p="mouse","pointerout"!==e&&"pointerover"!==e||(f=Ir,b="onPointerLeave",h="onPointerEnter",p="pointer"),l=null==s?u:ii(s),d=null==c?u:ii(c),(u=new f(b,p+"leave",s,r,i)).target=l,u.relatedTarget=d,b=null,ri(i)===n&&((f=new f(h,p+"enter",c,r,i)).target=d,f.relatedTarget=l,b=f),l=b,s&&c)e:{for(h=c,p=0,d=f=s;d;d=Un(d))p++;for(d=0,b=h;b;b=Un(b))d++;for(;0<p-d;)f=Un(f),p--;for(;0<d-p;)h=Un(h),d--;for(;p--;){if(f===h||null!==h&&f===h.alternate)break e;f=Un(f),h=Un(h)}f=null}else f=null;null!==s&&Nn(a,u,s,f,!1),null!==c&&null!==l&&Nn(a,l,c,f,!0)}if("select"===(s=(u=n?ii(n):window).nodeName&&u.nodeName.toLowerCase())||"input"===s&&"file"===u.type)var v=$r;else if(Vr(u))if(Qr)v=cn;else{v=un;var y=an}else(s=u.nodeName)&&"input"===s.toLowerCase()&&("checkbox"===u.type||"radio"===u.type)&&(v=sn);switch(v&&(v=v(e,n))?Zr(a,v,r,i):(y&&y(e,u,n),"focusout"===e&&(y=u._wrapperState)&&y.controlled&&"number"===u.type&&ie(u,"number",u.value)),y=n?ii(n):window,e){case"focusin":(Vr(y)||"true"===y.contentEditable)&&(gn=y,wn=n,kn=null);break;case"focusout":kn=wn=gn=null;break;case"mousedown":_n=!0;break;case"contextmenu":case"mouseup":case"dragend":_n=!1,xn(a,r,i);break;case"selectionchange":if(mn)break;case"keydown":case"keyup":xn(a,r,i)}var m;if(Lr)e:{switch(e){case"compositionstart":var g="onCompositionStart";break e;case"compositionend":g="onCompositionEnd";break e;case"compositionupdate":g="onCompositionUpdate";break e}g=void 0}else Wr?qr(e,r)&&(g="onCompositionEnd"):"keydown"===e&&229===r.keyCode&&(g="onCompositionStart");g&&(Nr&&"ko"!==r.locale&&(Wr||"onCompositionStart"!==g?"onCompositionEnd"===g&&Wr&&(m=nr()):(tr="value"in(er=i)?er.value:er.textContent,Wr=!0)),0<(y=zn(n,g)).length&&(g=new _r(g,e,null,r,i),a.push({event:g,listeners:y}),m?g.data=m:null!==(m=Hr(r))&&(g.data=m))),(m=Ur?function(e,t){switch(e){case"compositionend":return Hr(t);case"keypress":return 32!==t.which?null:(Fr=!0,Dr);case"textInput":return(e=t.data)===Dr&&Fr?null:e;default:return null}}(e,r):function(e,t){if(Wr)return"compositionend"===e||!Lr&&qr(e,t)?(e=nr(),rr=tr=er=null,Wr=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Nr&&"ko"!==t.locale?null:t.data}}(e,r))&&(0<(n=zn(n,"onBeforeInput")).length&&(i=new _r("onBeforeInput","beforeinput",null,r,i),a.push({event:i,listeners:n}),i.data=m))}jn(a,t)}))}function Ln(e,t,r){return{instance:e,listener:t,currentTarget:r}}function zn(e,t){for(var r=t+"Capture",n=[];null!==e;){var i=e,o=i.stateNode;5===i.tag&&null!==o&&(i=o,null!=(o=De(e,r))&&n.unshift(Ln(e,o,i)),null!=(o=De(e,t))&&n.push(Ln(e,o,i))),e=e.return}return n}function Un(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Nn(e,t,r,n,i){for(var o=t._reactName,a=[];null!==r&&r!==n;){var u=r,s=u.alternate,c=u.stateNode;if(null!==s&&s===n)break;5===u.tag&&null!==c&&(u=c,i?null!=(s=De(r,o))&&a.unshift(Ln(r,s,u)):i||null!=(s=De(r,o))&&a.push(Ln(r,s,u))),r=r.return}0!==a.length&&e.push({event:t,listeners:a})}function Dn(){}var Fn=null,qn=null;function Hn(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function Wn(e,t){return"textarea"===e||"option"===e||"noscript"===e||"string"===typeof t.children||"number"===typeof t.children||"object"===typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var Kn="function"===typeof setTimeout?setTimeout:void 0,Vn="function"===typeof clearTimeout?clearTimeout:void 0;function Zn(e){1===e.nodeType?e.textContent="":9===e.nodeType&&(null!=(e=e.body)&&(e.textContent=""))}function Yn(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break}return e}function Xn(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var r=e.data;if("$"===r||"$!"===r||"$?"===r){if(0===t)return e;t--}else"/$"===r&&t++}e=e.previousSibling}return null}var Gn=0;var Jn=Math.random().toString(36).slice(2),$n="__reactFiber$"+Jn,Qn="__reactProps$"+Jn,ei="__reactContainer$"+Jn,ti="__reactEvents$"+Jn;function ri(e){var t=e[$n];if(t)return t;for(var r=e.parentNode;r;){if(t=r[ei]||r[$n]){if(r=t.alternate,null!==t.child||null!==r&&null!==r.child)for(e=Xn(e);null!==e;){if(r=e[$n])return r;e=Xn(e)}return t}r=(e=r).parentNode}return null}function ni(e){return!(e=e[$n]||e[ei])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function ii(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(a(33))}function oi(e){return e[Qn]||null}function ai(e){var t=e[ti];return void 0===t&&(t=e[ti]=new Set),t}var ui=[],si=-1;function ci(e){return{current:e}}function fi(e){0>si||(e.current=ui[si],ui[si]=null,si--)}function li(e,t){si++,ui[si]=e.current,e.current=t}var hi={},di=ci(hi),pi=ci(!1),bi=hi;function vi(e,t){var r=e.type.contextTypes;if(!r)return hi;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var i,o={};for(i in r)o[i]=t[i];return n&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function yi(e){return null!==(e=e.childContextTypes)&&void 0!==e}function mi(){fi(pi),fi(di)}function gi(e,t,r){if(di.current!==hi)throw Error(a(168));li(di,t),li(pi,r)}function wi(e,t,r){var n=e.stateNode;if(e=t.childContextTypes,"function"!==typeof n.getChildContext)return r;for(var o in n=n.getChildContext())if(!(o in e))throw Error(a(108,Z(t)||"Unknown",o));return i({},r,n)}function ki(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||hi,bi=di.current,li(di,e),li(pi,pi.current),!0}function _i(e,t,r){var n=e.stateNode;if(!n)throw Error(a(169));r?(e=wi(e,t,bi),n.__reactInternalMemoizedMergedChildContext=e,fi(pi),fi(di),li(di,e)):fi(pi),li(pi,r)}var xi=null,Si=null,Ei=o.unstable_runWithPriority,Oi=o.unstable_scheduleCallback,Ai=o.unstable_cancelCallback,Mi=o.unstable_shouldYield,ji=o.unstable_requestPaint,Ii=o.unstable_now,Pi=o.unstable_getCurrentPriorityLevel,Ri=o.unstable_ImmediatePriority,Ci=o.unstable_UserBlockingPriority,Ti=o.unstable_NormalPriority,Bi=o.unstable_LowPriority,Li=o.unstable_IdlePriority,zi={},Ui=void 0!==ji?ji:function(){},Ni=null,Di=null,Fi=!1,qi=Ii(),Hi=1e4>qi?Ii:function(){return Ii()-qi};function Wi(){switch(Pi()){case Ri:return 99;case Ci:return 98;case Ti:return 97;case Bi:return 96;case Li:return 95;default:throw Error(a(332))}}function Ki(e){switch(e){case 99:return Ri;case 98:return Ci;case 97:return Ti;case 96:return Bi;case 95:return Li;default:throw Error(a(332))}}function Vi(e,t){return e=Ki(e),Ei(e,t)}function Zi(e,t,r){return e=Ki(e),Oi(e,t,r)}function Yi(){if(null!==Di){var e=Di;Di=null,Ai(e)}Xi()}function Xi(){if(!Fi&&null!==Ni){Fi=!0;var e=0;try{var t=Ni;Vi(99,(function(){for(;e<t.length;e++){var r=t[e];do{r=r(!0)}while(null!==r)}})),Ni=null}catch(r){throw null!==Ni&&(Ni=Ni.slice(e+1)),Oi(Ri,Yi),r}finally{Fi=!1}}}var Gi=k.ReactCurrentBatchConfig;function Ji(e,t){if(e&&e.defaultProps){for(var r in t=i({},t),e=e.defaultProps)void 0===t[r]&&(t[r]=e[r]);return t}return t}var $i=ci(null),Qi=null,eo=null,to=null;function ro(){to=eo=Qi=null}function no(e){var t=$i.current;fi($i),e.type._context._currentValue=t}function io(e,t){for(;null!==e;){var r=e.alternate;if((e.childLanes&t)===t){if(null===r||(r.childLanes&t)===t)break;r.childLanes|=t}else e.childLanes|=t,null!==r&&(r.childLanes|=t);e=e.return}}function oo(e,t){Qi=e,to=eo=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!==(e.lanes&t)&&(za=!0),e.firstContext=null)}function ao(e,t){if(to!==e&&!1!==t&&0!==t)if("number"===typeof t&&1073741823!==t||(to=e,t=1073741823),t={context:e,observedBits:t,next:null},null===eo){if(null===Qi)throw Error(a(308));eo=t,Qi.dependencies={lanes:0,firstContext:t,responders:null}}else eo=eo.next=t;return e._currentValue}var uo=!1;function so(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}function co(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function fo(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function lo(e,t){if(null!==(e=e.updateQueue)){var r=(e=e.shared).pending;null===r?t.next=t:(t.next=r.next,r.next=t),e.pending=t}}function ho(e,t){var r=e.updateQueue,n=e.alternate;if(null!==n&&r===(n=n.updateQueue)){var i=null,o=null;if(null!==(r=r.firstBaseUpdate)){do{var a={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};null===o?i=o=a:o=o.next=a,r=r.next}while(null!==r);null===o?i=o=t:o=o.next=t}else i=o=t;return r={baseState:n.baseState,firstBaseUpdate:i,lastBaseUpdate:o,shared:n.shared,effects:n.effects},void(e.updateQueue=r)}null===(e=r.lastBaseUpdate)?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}function po(e,t,r,n){var o=e.updateQueue;uo=!1;var a=o.firstBaseUpdate,u=o.lastBaseUpdate,s=o.shared.pending;if(null!==s){o.shared.pending=null;var c=s,f=c.next;c.next=null,null===u?a=f:u.next=f,u=c;var l=e.alternate;if(null!==l){var h=(l=l.updateQueue).lastBaseUpdate;h!==u&&(null===h?l.firstBaseUpdate=f:h.next=f,l.lastBaseUpdate=c)}}if(null!==a){for(h=o.baseState,u=0,l=f=c=null;;){s=a.lane;var d=a.eventTime;if((n&s)===s){null!==l&&(l=l.next={eventTime:d,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var p=e,b=a;switch(s=t,d=r,b.tag){case 1:if("function"===typeof(p=b.payload)){h=p.call(d,h,s);break e}h=p;break e;case 3:p.flags=-4097&p.flags|64;case 0:if(null===(s="function"===typeof(p=b.payload)?p.call(d,h,s):p)||void 0===s)break e;h=i({},h,s);break e;case 2:uo=!0}}null!==a.callback&&(e.flags|=32,null===(s=o.effects)?o.effects=[a]:s.push(a))}else d={eventTime:d,lane:s,tag:a.tag,payload:a.payload,callback:a.callback,next:null},null===l?(f=l=d,c=h):l=l.next=d,u|=s;if(null===(a=a.next)){if(null===(s=o.shared.pending))break;a=s.next,s.next=null,o.lastBaseUpdate=s,o.shared.pending=null}}null===l&&(c=h),o.baseState=c,o.firstBaseUpdate=f,o.lastBaseUpdate=l,Fu|=u,e.lanes=u,e.memoizedState=h}}function bo(e,t,r){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var n=e[t],i=n.callback;if(null!==i){if(n.callback=null,n=r,"function"!==typeof i)throw Error(a(191,i));i.call(n)}}}var vo=(new n.Component).refs;function yo(e,t,r,n){r=null===(r=r(n,t=e.memoizedState))||void 0===r?t:i({},t,r),e.memoizedState=r,0===e.lanes&&(e.updateQueue.baseState=r)}var mo={isMounted:function(e){return!!(e=e._reactInternals)&&Ge(e)===e},enqueueSetState:function(e,t,r){e=e._reactInternals;var n=hs(),i=ds(e),o=fo(n,i);o.payload=t,void 0!==r&&null!==r&&(o.callback=r),lo(e,o),ps(e,i,n)},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var n=hs(),i=ds(e),o=fo(n,i);o.tag=1,o.payload=t,void 0!==r&&null!==r&&(o.callback=r),lo(e,o),ps(e,i,n)},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=hs(),n=ds(e),i=fo(r,n);i.tag=2,void 0!==t&&null!==t&&(i.callback=t),lo(e,i),ps(e,n,r)}};function go(e,t,r,n,i,o,a){return"function"===typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(n,o,a):!t.prototype||!t.prototype.isPureReactComponent||(!hn(r,n)||!hn(i,o))}function wo(e,t,r){var n=!1,i=hi,o=t.contextType;return"object"===typeof o&&null!==o?o=ao(o):(i=yi(t)?bi:di.current,o=(n=null!==(n=t.contextTypes)&&void 0!==n)?vi(e,i):hi),t=new t(r,o),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=mo,e.stateNode=t,t._reactInternals=e,n&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=o),t}function ko(e,t,r,n){e=t.state,"function"===typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(r,n),"function"===typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(r,n),t.state!==e&&mo.enqueueReplaceState(t,t.state,null)}function _o(e,t,r,n){var i=e.stateNode;i.props=r,i.state=e.memoizedState,i.refs=vo,so(e);var o=t.contextType;"object"===typeof o&&null!==o?i.context=ao(o):(o=yi(t)?bi:di.current,i.context=vi(e,o)),po(e,r,i,n),i.state=e.memoizedState,"function"===typeof(o=t.getDerivedStateFromProps)&&(yo(e,t,o,r),i.state=e.memoizedState),"function"===typeof t.getDerivedStateFromProps||"function"===typeof i.getSnapshotBeforeUpdate||"function"!==typeof i.UNSAFE_componentWillMount&&"function"!==typeof i.componentWillMount||(t=i.state,"function"===typeof i.componentWillMount&&i.componentWillMount(),"function"===typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),t!==i.state&&mo.enqueueReplaceState(i,i.state,null),po(e,r,i,n),i.state=e.memoizedState),"function"===typeof i.componentDidMount&&(e.flags|=4)}var xo=Array.isArray;function So(e,t,r){if(null!==(e=r.ref)&&"function"!==typeof e&&"object"!==typeof e){if(r._owner){if(r=r._owner){if(1!==r.tag)throw Error(a(309));var n=r.stateNode}if(!n)throw Error(a(147,e));var i=""+e;return null!==t&&null!==t.ref&&"function"===typeof t.ref&&t.ref._stringRef===i?t.ref:(t=function(e){var t=n.refs;t===vo&&(t=n.refs={}),null===e?delete t[i]:t[i]=e},t._stringRef=i,t)}if("string"!==typeof e)throw Error(a(284));if(!r._owner)throw Error(a(290,e))}return e}function Eo(e,t){if("textarea"!==e.type)throw Error(a(31,"[object Object]"===Object.prototype.toString.call(t)?"object with keys {"+Object.keys(t).join(", ")+"}":t))}function Oo(e){function t(t,r){if(e){var n=t.lastEffect;null!==n?(n.nextEffect=r,t.lastEffect=r):t.firstEffect=t.lastEffect=r,r.nextEffect=null,r.flags=8}}function r(r,n){if(!e)return null;for(;null!==n;)t(r,n),n=n.sibling;return null}function n(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function i(e,t){return(e=Vs(e,t)).index=0,e.sibling=null,e}function o(t,r,n){return t.index=n,e?null!==(n=t.alternate)?(n=n.index)<r?(t.flags=2,r):n:(t.flags=2,r):r}function u(t){return e&&null===t.alternate&&(t.flags=2),t}function s(e,t,r,n){return null===t||6!==t.tag?((t=Gs(r,e.mode,n)).return=e,t):((t=i(t,r)).return=e,t)}function c(e,t,r,n){return null!==t&&t.elementType===r.type?((n=i(t,r.props)).ref=So(e,t,r),n.return=e,n):((n=Zs(r.type,r.key,r.props,null,e.mode,n)).ref=So(e,t,r),n.return=e,n)}function f(e,t,r,n){return null===t||4!==t.tag||t.stateNode.containerInfo!==r.containerInfo||t.stateNode.implementation!==r.implementation?((t=Js(r,e.mode,n)).return=e,t):((t=i(t,r.children||[])).return=e,t)}function l(e,t,r,n,o){return null===t||7!==t.tag?((t=Ys(r,e.mode,n,o)).return=e,t):((t=i(t,r)).return=e,t)}function h(e,t,r){if("string"===typeof t||"number"===typeof t)return(t=Gs(""+t,e.mode,r)).return=e,t;if("object"===typeof t&&null!==t){switch(t.$$typeof){case _:return(r=Zs(t.type,t.key,t.props,null,e.mode,r)).ref=So(e,null,t),r.return=e,r;case x:return(t=Js(t,e.mode,r)).return=e,t}if(xo(t)||q(t))return(t=Ys(t,e.mode,r,null)).return=e,t;Eo(e,t)}return null}function d(e,t,r,n){var i=null!==t?t.key:null;if("string"===typeof r||"number"===typeof r)return null!==i?null:s(e,t,""+r,n);if("object"===typeof r&&null!==r){switch(r.$$typeof){case _:return r.key===i?r.type===S?l(e,t,r.props.children,n,i):c(e,t,r,n):null;case x:return r.key===i?f(e,t,r,n):null}if(xo(r)||q(r))return null!==i?null:l(e,t,r,n,null);Eo(e,r)}return null}function p(e,t,r,n,i){if("string"===typeof n||"number"===typeof n)return s(t,e=e.get(r)||null,""+n,i);if("object"===typeof n&&null!==n){switch(n.$$typeof){case _:return e=e.get(null===n.key?r:n.key)||null,n.type===S?l(t,e,n.props.children,i,n.key):c(t,e,n,i);case x:return f(t,e=e.get(null===n.key?r:n.key)||null,n,i)}if(xo(n)||q(n))return l(t,e=e.get(r)||null,n,i,null);Eo(t,n)}return null}function b(i,a,u,s){for(var c=null,f=null,l=a,b=a=0,v=null;null!==l&&b<u.length;b++){l.index>b?(v=l,l=null):v=l.sibling;var y=d(i,l,u[b],s);if(null===y){null===l&&(l=v);break}e&&l&&null===y.alternate&&t(i,l),a=o(y,a,b),null===f?c=y:f.sibling=y,f=y,l=v}if(b===u.length)return r(i,l),c;if(null===l){for(;b<u.length;b++)null!==(l=h(i,u[b],s))&&(a=o(l,a,b),null===f?c=l:f.sibling=l,f=l);return c}for(l=n(i,l);b<u.length;b++)null!==(v=p(l,i,b,u[b],s))&&(e&&null!==v.alternate&&l.delete(null===v.key?b:v.key),a=o(v,a,b),null===f?c=v:f.sibling=v,f=v);return e&&l.forEach((function(e){return t(i,e)})),c}function v(i,u,s,c){var f=q(s);if("function"!==typeof f)throw Error(a(150));if(null==(s=f.call(s)))throw Error(a(151));for(var l=f=null,b=u,v=u=0,y=null,m=s.next();null!==b&&!m.done;v++,m=s.next()){b.index>v?(y=b,b=null):y=b.sibling;var g=d(i,b,m.value,c);if(null===g){null===b&&(b=y);break}e&&b&&null===g.alternate&&t(i,b),u=o(g,u,v),null===l?f=g:l.sibling=g,l=g,b=y}if(m.done)return r(i,b),f;if(null===b){for(;!m.done;v++,m=s.next())null!==(m=h(i,m.value,c))&&(u=o(m,u,v),null===l?f=m:l.sibling=m,l=m);return f}for(b=n(i,b);!m.done;v++,m=s.next())null!==(m=p(b,i,v,m.value,c))&&(e&&null!==m.alternate&&b.delete(null===m.key?v:m.key),u=o(m,u,v),null===l?f=m:l.sibling=m,l=m);return e&&b.forEach((function(e){return t(i,e)})),f}return function(e,n,o,s){var c="object"===typeof o&&null!==o&&o.type===S&&null===o.key;c&&(o=o.props.children);var f="object"===typeof o&&null!==o;if(f)switch(o.$$typeof){case _:e:{for(f=o.key,c=n;null!==c;){if(c.key===f){if(7===c.tag){if(o.type===S){r(e,c.sibling),(n=i(c,o.props.children)).return=e,e=n;break e}}else if(c.elementType===o.type){r(e,c.sibling),(n=i(c,o.props)).ref=So(e,c,o),n.return=e,e=n;break e}r(e,c);break}t(e,c),c=c.sibling}o.type===S?((n=Ys(o.props.children,e.mode,s,o.key)).return=e,e=n):((s=Zs(o.type,o.key,o.props,null,e.mode,s)).ref=So(e,n,o),s.return=e,e=s)}return u(e);case x:e:{for(c=o.key;null!==n;){if(n.key===c){if(4===n.tag&&n.stateNode.containerInfo===o.containerInfo&&n.stateNode.implementation===o.implementation){r(e,n.sibling),(n=i(n,o.children||[])).return=e,e=n;break e}r(e,n);break}t(e,n),n=n.sibling}(n=Js(o,e.mode,s)).return=e,e=n}return u(e)}if("string"===typeof o||"number"===typeof o)return o=""+o,null!==n&&6===n.tag?(r(e,n.sibling),(n=i(n,o)).return=e,e=n):(r(e,n),(n=Gs(o,e.mode,s)).return=e,e=n),u(e);if(xo(o))return b(e,n,o,s);if(q(o))return v(e,n,o,s);if(f&&Eo(e,o),"undefined"===typeof o&&!c)switch(e.tag){case 1:case 22:case 0:case 11:case 15:throw Error(a(152,Z(e.type)||"Component"))}return r(e,n)}}var Ao=Oo(!0),Mo=Oo(!1),jo={},Io=ci(jo),Po=ci(jo),Ro=ci(jo);function Co(e){if(e===jo)throw Error(a(174));return e}function To(e,t){switch(li(Ro,t),li(Po,e),li(Io,jo),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:pe(null,"");break;default:t=pe(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}fi(Io),li(Io,t)}function Bo(){fi(Io),fi(Po),fi(Ro)}function Lo(e){Co(Ro.current);var t=Co(Io.current),r=pe(t,e.type);t!==r&&(li(Po,e),li(Io,r))}function zo(e){Po.current===e&&(fi(Io),fi(Po))}var Uo=ci(0);function No(e){for(var t=e;null!==t;){if(13===t.tag){var r=t.memoizedState;if(null!==r&&(null===(r=r.dehydrated)||"$?"===r.data||"$!"===r.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!==(64&t.flags))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Do=null,Fo=null,qo=!1;function Ho(e,t){var r=Ws(5,null,null,0);r.elementType="DELETED",r.type="DELETED",r.stateNode=t,r.return=e,r.flags=8,null!==e.lastEffect?(e.lastEffect.nextEffect=r,e.lastEffect=r):e.firstEffect=e.lastEffect=r}function Wo(e,t){switch(e.tag){case 5:var r=e.type;return null!==(t=1!==t.nodeType||r.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,!0);default:return!1}}function Ko(e){if(qo){var t=Fo;if(t){var r=t;if(!Wo(e,t)){if(!(t=Yn(r.nextSibling))||!Wo(e,t))return e.flags=-1025&e.flags|2,qo=!1,void(Do=e);Ho(Do,r)}Do=e,Fo=Yn(t.firstChild)}else e.flags=-1025&e.flags|2,qo=!1,Do=e}}function Vo(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;Do=e}function Zo(e){if(e!==Do)return!1;if(!qo)return Vo(e),qo=!0,!1;var t=e.type;if(5!==e.tag||"head"!==t&&"body"!==t&&!Wn(t,e.memoizedProps))for(t=Fo;t;)Ho(e,t),t=Yn(t.nextSibling);if(Vo(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var r=e.data;if("/$"===r){if(0===t){Fo=Yn(e.nextSibling);break e}t--}else"$"!==r&&"$!"!==r&&"$?"!==r||t++}e=e.nextSibling}Fo=null}}else Fo=Do?Yn(e.stateNode.nextSibling):null;return!0}function Yo(){Fo=Do=null,qo=!1}var Xo=[];function Go(){for(var e=0;e<Xo.length;e++)Xo[e]._workInProgressVersionPrimary=null;Xo.length=0}var Jo=k.ReactCurrentDispatcher,$o=k.ReactCurrentBatchConfig,Qo=0,ea=null,ta=null,ra=null,na=!1,ia=!1;function oa(){throw Error(a(321))}function aa(e,t){if(null===t)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!fn(e[r],t[r]))return!1;return!0}function ua(e,t,r,n,i,o){if(Qo=o,ea=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Jo.current=null===e||null===e.memoizedState?Ca:Ta,e=r(n,i),ia){o=0;do{if(ia=!1,!(25>o))throw Error(a(301));o+=1,ra=ta=null,t.updateQueue=null,Jo.current=Ba,e=r(n,i)}while(ia)}if(Jo.current=Ra,t=null!==ta&&null!==ta.next,Qo=0,ra=ta=ea=null,na=!1,t)throw Error(a(300));return e}function sa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===ra?ea.memoizedState=ra=e:ra=ra.next=e,ra}function ca(){if(null===ta){var e=ea.alternate;e=null!==e?e.memoizedState:null}else e=ta.next;var t=null===ra?ea.memoizedState:ra.next;if(null!==t)ra=t,ta=e;else{if(null===e)throw Error(a(310));e={memoizedState:(ta=e).memoizedState,baseState:ta.baseState,baseQueue:ta.baseQueue,queue:ta.queue,next:null},null===ra?ea.memoizedState=ra=e:ra=ra.next=e}return ra}function fa(e,t){return"function"===typeof t?t(e):t}function la(e){var t=ca(),r=t.queue;if(null===r)throw Error(a(311));r.lastRenderedReducer=e;var n=ta,i=n.baseQueue,o=r.pending;if(null!==o){if(null!==i){var u=i.next;i.next=o.next,o.next=u}n.baseQueue=i=o,r.pending=null}if(null!==i){i=i.next,n=n.baseState;var s=u=o=null,c=i;do{var f=c.lane;if((Qo&f)===f)null!==s&&(s=s.next={lane:0,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null}),n=c.eagerReducer===e?c.eagerState:e(n,c.action);else{var l={lane:f,action:c.action,eagerReducer:c.eagerReducer,eagerState:c.eagerState,next:null};null===s?(u=s=l,o=n):s=s.next=l,ea.lanes|=f,Fu|=f}c=c.next}while(null!==c&&c!==i);null===s?o=n:s.next=u,fn(n,t.memoizedState)||(za=!0),t.memoizedState=n,t.baseState=o,t.baseQueue=s,r.lastRenderedState=n}return[t.memoizedState,r.dispatch]}function ha(e){var t=ca(),r=t.queue;if(null===r)throw Error(a(311));r.lastRenderedReducer=e;var n=r.dispatch,i=r.pending,o=t.memoizedState;if(null!==i){r.pending=null;var u=i=i.next;do{o=e(o,u.action),u=u.next}while(u!==i);fn(o,t.memoizedState)||(za=!0),t.memoizedState=o,null===t.baseQueue&&(t.baseState=o),r.lastRenderedState=o}return[o,n]}function da(e,t,r){var n=t._getVersion;n=n(t._source);var i=t._workInProgressVersionPrimary;if(null!==i?e=i===n:(e=e.mutableReadLanes,(e=(Qo&e)===e)&&(t._workInProgressVersionPrimary=n,Xo.push(t))),e)return r(t._source);throw Xo.push(t),Error(a(350))}function pa(e,t,r,n){var i=Cu;if(null===i)throw Error(a(349));var o=t._getVersion,u=o(t._source),s=Jo.current,c=s.useState((function(){return da(i,t,r)})),f=c[1],l=c[0];c=ra;var h=e.memoizedState,d=h.refs,p=d.getSnapshot,b=h.source;h=h.subscribe;var v=ea;return e.memoizedState={refs:d,source:t,subscribe:n},s.useEffect((function(){d.getSnapshot=r,d.setSnapshot=f;var e=o(t._source);if(!fn(u,e)){e=r(t._source),fn(l,e)||(f(e),e=ds(v),i.mutableReadLanes|=e&i.pendingLanes),e=i.mutableReadLanes,i.entangledLanes|=e;for(var n=i.entanglements,a=e;0<a;){var s=31-Wt(a),c=1<<s;n[s]|=e,a&=~c}}}),[r,t,n]),s.useEffect((function(){return n(t._source,(function(){var e=d.getSnapshot,r=d.setSnapshot;try{r(e(t._source));var n=ds(v);i.mutableReadLanes|=n&i.pendingLanes}catch(o){r((function(){throw o}))}}))}),[t,n]),fn(p,r)&&fn(b,t)&&fn(h,n)||((e={pending:null,dispatch:null,lastRenderedReducer:fa,lastRenderedState:l}).dispatch=f=Pa.bind(null,ea,e),c.queue=e,c.baseQueue=null,l=da(i,t,r),c.memoizedState=c.baseState=l),l}function ba(e,t,r){return pa(ca(),e,t,r)}function va(e){var t=sa();return"function"===typeof e&&(e=e()),t.memoizedState=t.baseState=e,e=(e=t.queue={pending:null,dispatch:null,lastRenderedReducer:fa,lastRenderedState:e}).dispatch=Pa.bind(null,ea,e),[t.memoizedState,e]}function ya(e,t,r,n){return e={tag:e,create:t,destroy:r,deps:n,next:null},null===(t=ea.updateQueue)?(t={lastEffect:null},ea.updateQueue=t,t.lastEffect=e.next=e):null===(r=t.lastEffect)?t.lastEffect=e.next=e:(n=r.next,r.next=e,e.next=n,t.lastEffect=e),e}function ma(e){return e={current:e},sa().memoizedState=e}function ga(){return ca().memoizedState}function wa(e,t,r,n){var i=sa();ea.flags|=e,i.memoizedState=ya(1|t,r,void 0,void 0===n?null:n)}function ka(e,t,r,n){var i=ca();n=void 0===n?null:n;var o=void 0;if(null!==ta){var a=ta.memoizedState;if(o=a.destroy,null!==n&&aa(n,a.deps))return void ya(t,r,o,n)}ea.flags|=e,i.memoizedState=ya(1|t,r,o,n)}function _a(e,t){return wa(516,4,e,t)}function xa(e,t){return ka(516,4,e,t)}function Sa(e,t){return ka(4,2,e,t)}function Ea(e,t){return"function"===typeof t?(e=e(),t(e),function(){t(null)}):null!==t&&void 0!==t?(e=e(),t.current=e,function(){t.current=null}):void 0}function Oa(e,t,r){return r=null!==r&&void 0!==r?r.concat([e]):null,ka(4,2,Ea.bind(null,t,e),r)}function Aa(){}function Ma(e,t){var r=ca();t=void 0===t?null:t;var n=r.memoizedState;return null!==n&&null!==t&&aa(t,n[1])?n[0]:(r.memoizedState=[e,t],e)}function ja(e,t){var r=ca();t=void 0===t?null:t;var n=r.memoizedState;return null!==n&&null!==t&&aa(t,n[1])?n[0]:(e=e(),r.memoizedState=[e,t],e)}function Ia(e,t){var r=Wi();Vi(98>r?98:r,(function(){e(!0)})),Vi(97<r?97:r,(function(){var r=$o.transition;$o.transition=1;try{e(!1),t()}finally{$o.transition=r}}))}function Pa(e,t,r){var n=hs(),i=ds(e),o={lane:i,action:r,eagerReducer:null,eagerState:null,next:null},a=t.pending;if(null===a?o.next=o:(o.next=a.next,a.next=o),t.pending=o,a=e.alternate,e===ea||null!==a&&a===ea)ia=na=!0;else{if(0===e.lanes&&(null===a||0===a.lanes)&&null!==(a=t.lastRenderedReducer))try{var u=t.lastRenderedState,s=a(u,r);if(o.eagerReducer=a,o.eagerState=s,fn(s,u))return}catch(c){}ps(e,i,n)}}var Ra={readContext:ao,useCallback:oa,useContext:oa,useEffect:oa,useImperativeHandle:oa,useLayoutEffect:oa,useMemo:oa,useReducer:oa,useRef:oa,useState:oa,useDebugValue:oa,useDeferredValue:oa,useTransition:oa,useMutableSource:oa,useOpaqueIdentifier:oa,unstable_isNewReconciler:!1},Ca={readContext:ao,useCallback:function(e,t){return sa().memoizedState=[e,void 0===t?null:t],e},useContext:ao,useEffect:_a,useImperativeHandle:function(e,t,r){return r=null!==r&&void 0!==r?r.concat([e]):null,wa(4,2,Ea.bind(null,t,e),r)},useLayoutEffect:function(e,t){return wa(4,2,e,t)},useMemo:function(e,t){var r=sa();return t=void 0===t?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=sa();return t=void 0!==r?r(t):t,n.memoizedState=n.baseState=t,e=(e=n.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:t}).dispatch=Pa.bind(null,ea,e),[n.memoizedState,e]},useRef:ma,useState:va,useDebugValue:Aa,useDeferredValue:function(e){var t=va(e),r=t[0],n=t[1];return _a((function(){var t=$o.transition;$o.transition=1;try{n(e)}finally{$o.transition=t}}),[e]),r},useTransition:function(){var e=va(!1),t=e[0];return ma(e=Ia.bind(null,e[1])),[e,t]},useMutableSource:function(e,t,r){var n=sa();return n.memoizedState={refs:{getSnapshot:t,setSnapshot:null},source:e,subscribe:r},pa(n,e,t,r)},useOpaqueIdentifier:function(){if(qo){var e=!1,t=function(e){return{$$typeof:B,toString:e,valueOf:e}}((function(){throw e||(e=!0,r("r:"+(Gn++).toString(36))),Error(a(355))})),r=va(t)[1];return 0===(2&ea.mode)&&(ea.flags|=516,ya(5,(function(){r("r:"+(Gn++).toString(36))}),void 0,null)),t}return va(t="r:"+(Gn++).toString(36)),t},unstable_isNewReconciler:!1},Ta={readContext:ao,useCallback:Ma,useContext:ao,useEffect:xa,useImperativeHandle:Oa,useLayoutEffect:Sa,useMemo:ja,useReducer:la,useRef:ga,useState:function(){return la(fa)},useDebugValue:Aa,useDeferredValue:function(e){var t=la(fa),r=t[0],n=t[1];return xa((function(){var t=$o.transition;$o.transition=1;try{n(e)}finally{$o.transition=t}}),[e]),r},useTransition:function(){var e=la(fa)[0];return[ga().current,e]},useMutableSource:ba,useOpaqueIdentifier:function(){return la(fa)[0]},unstable_isNewReconciler:!1},Ba={readContext:ao,useCallback:Ma,useContext:ao,useEffect:xa,useImperativeHandle:Oa,useLayoutEffect:Sa,useMemo:ja,useReducer:ha,useRef:ga,useState:function(){return ha(fa)},useDebugValue:Aa,useDeferredValue:function(e){var t=ha(fa),r=t[0],n=t[1];return xa((function(){var t=$o.transition;$o.transition=1;try{n(e)}finally{$o.transition=t}}),[e]),r},useTransition:function(){var e=ha(fa)[0];return[ga().current,e]},useMutableSource:ba,useOpaqueIdentifier:function(){return ha(fa)[0]},unstable_isNewReconciler:!1},La=k.ReactCurrentOwner,za=!1;function Ua(e,t,r,n){t.child=null===e?Mo(t,null,r,n):Ao(t,e.child,r,n)}function Na(e,t,r,n,i){r=r.render;var o=t.ref;return oo(t,i),n=ua(e,t,r,n,o,i),null===e||za?(t.flags|=1,Ua(e,t,n,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ou(e,t,i))}function Da(e,t,r,n,i,o){if(null===e){var a=r.type;return"function"!==typeof a||Ks(a)||void 0!==a.defaultProps||null!==r.compare||void 0!==r.defaultProps?((e=Zs(r.type,null,n,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=a,Fa(e,t,a,n,i,o))}return a=e.child,0===(i&o)&&(i=a.memoizedProps,(r=null!==(r=r.compare)?r:hn)(i,n)&&e.ref===t.ref)?ou(e,t,o):(t.flags|=1,(e=Vs(a,n)).ref=t.ref,e.return=t,t.child=e)}function Fa(e,t,r,n,i,o){if(null!==e&&hn(e.memoizedProps,n)&&e.ref===t.ref){if(za=!1,0===(o&i))return t.lanes=e.lanes,ou(e,t,o);0!==(16384&e.flags)&&(za=!0)}return Wa(e,t,r,n,o)}function qa(e,t,r){var n=t.pendingProps,i=n.children,o=null!==e?e.memoizedState:null;if("hidden"===n.mode||"unstable-defer-without-hiding"===n.mode)if(0===(4&t.mode))t.memoizedState={baseLanes:0},_s(t,r);else{if(0===(1073741824&r))return e=null!==o?o.baseLanes|r:r,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e},_s(t,e),null;t.memoizedState={baseLanes:0},_s(t,null!==o?o.baseLanes:r)}else null!==o?(n=o.baseLanes|r,t.memoizedState=null):n=r,_s(t,n);return Ua(e,t,i,r),t.child}function Ha(e,t){var r=t.ref;(null===e&&null!==r||null!==e&&e.ref!==r)&&(t.flags|=128)}function Wa(e,t,r,n,i){var o=yi(r)?bi:di.current;return o=vi(t,o),oo(t,i),r=ua(e,t,r,n,o,i),null===e||za?(t.flags|=1,Ua(e,t,r,i),t.child):(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~i,ou(e,t,i))}function Ka(e,t,r,n,i){if(yi(r)){var o=!0;ki(t)}else o=!1;if(oo(t,i),null===t.stateNode)null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),wo(t,r,n),_o(t,r,n,i),n=!0;else if(null===e){var a=t.stateNode,u=t.memoizedProps;a.props=u;var s=a.context,c=r.contextType;"object"===typeof c&&null!==c?c=ao(c):c=vi(t,c=yi(r)?bi:di.current);var f=r.getDerivedStateFromProps,l="function"===typeof f||"function"===typeof a.getSnapshotBeforeUpdate;l||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(u!==n||s!==c)&&ko(t,a,n,c),uo=!1;var h=t.memoizedState;a.state=h,po(t,n,a,i),s=t.memoizedState,u!==n||h!==s||pi.current||uo?("function"===typeof f&&(yo(t,r,f,n),s=t.memoizedState),(u=uo||go(t,r,u,n,h,s,c))?(l||"function"!==typeof a.UNSAFE_componentWillMount&&"function"!==typeof a.componentWillMount||("function"===typeof a.componentWillMount&&a.componentWillMount(),"function"===typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"===typeof a.componentDidMount&&(t.flags|=4)):("function"===typeof a.componentDidMount&&(t.flags|=4),t.memoizedProps=n,t.memoizedState=s),a.props=n,a.state=s,a.context=c,n=u):("function"===typeof a.componentDidMount&&(t.flags|=4),n=!1)}else{a=t.stateNode,co(e,t),u=t.memoizedProps,c=t.type===t.elementType?u:Ji(t.type,u),a.props=c,l=t.pendingProps,h=a.context,"object"===typeof(s=r.contextType)&&null!==s?s=ao(s):s=vi(t,s=yi(r)?bi:di.current);var d=r.getDerivedStateFromProps;(f="function"===typeof d||"function"===typeof a.getSnapshotBeforeUpdate)||"function"!==typeof a.UNSAFE_componentWillReceiveProps&&"function"!==typeof a.componentWillReceiveProps||(u!==l||h!==s)&&ko(t,a,n,s),uo=!1,h=t.memoizedState,a.state=h,po(t,n,a,i);var p=t.memoizedState;u!==l||h!==p||pi.current||uo?("function"===typeof d&&(yo(t,r,d,n),p=t.memoizedState),(c=uo||go(t,r,c,n,h,p,s))?(f||"function"!==typeof a.UNSAFE_componentWillUpdate&&"function"!==typeof a.componentWillUpdate||("function"===typeof a.componentWillUpdate&&a.componentWillUpdate(n,p,s),"function"===typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(n,p,s)),"function"===typeof a.componentDidUpdate&&(t.flags|=4),"function"===typeof a.getSnapshotBeforeUpdate&&(t.flags|=256)):("function"!==typeof a.componentDidUpdate||u===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||u===e.memoizedProps&&h===e.memoizedState||(t.flags|=256),t.memoizedProps=n,t.memoizedState=p),a.props=n,a.state=p,a.context=s,n=c):("function"!==typeof a.componentDidUpdate||u===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),"function"!==typeof a.getSnapshotBeforeUpdate||u===e.memoizedProps&&h===e.memoizedState||(t.flags|=256),n=!1)}return Va(e,t,r,n,o,i)}function Va(e,t,r,n,i,o){Ha(e,t);var a=0!==(64&t.flags);if(!n&&!a)return i&&_i(t,r,!1),ou(e,t,o);n=t.stateNode,La.current=t;var u=a&&"function"!==typeof r.getDerivedStateFromError?null:n.render();return t.flags|=1,null!==e&&a?(t.child=Ao(t,e.child,null,o),t.child=Ao(t,null,u,o)):Ua(e,t,u,o),t.memoizedState=n.state,i&&_i(t,r,!0),t.child}function Za(e){var t=e.stateNode;t.pendingContext?gi(0,t.pendingContext,t.pendingContext!==t.context):t.context&&gi(0,t.context,!1),To(e,t.containerInfo)}var Ya,Xa,Ga,Ja={dehydrated:null,retryLane:0};function $a(e,t,r){var n,i=t.pendingProps,o=Uo.current,a=!1;return(n=0!==(64&t.flags))||(n=(null===e||null!==e.memoizedState)&&0!==(2&o)),n?(a=!0,t.flags&=-65):null!==e&&null===e.memoizedState||void 0===i.fallback||!0===i.unstable_avoidThisFallback||(o|=1),li(Uo,1&o),null===e?(void 0!==i.fallback&&Ko(t),e=i.children,o=i.fallback,a?(e=Qa(t,e,o,r),t.child.memoizedState={baseLanes:r},t.memoizedState=Ja,e):"number"===typeof i.unstable_expectedLoadTime?(e=Qa(t,e,o,r),t.child.memoizedState={baseLanes:r},t.memoizedState=Ja,t.lanes=33554432,e):((r=Xs({mode:"visible",children:e},t.mode,r,null)).return=t,t.child=r)):(e.memoizedState,a?(i=tu(e,t,i.children,i.fallback,r),a=t.child,o=e.child.memoizedState,a.memoizedState=null===o?{baseLanes:r}:{baseLanes:o.baseLanes|r},a.childLanes=e.childLanes&~r,t.memoizedState=Ja,i):(r=eu(e,t,i.children,r),t.memoizedState=null,r))}function Qa(e,t,r,n){var i=e.mode,o=e.child;return t={mode:"hidden",children:t},0===(2&i)&&null!==o?(o.childLanes=0,o.pendingProps=t):o=Xs(t,i,0,null),r=Ys(r,i,n,null),o.return=e,r.return=e,o.sibling=r,e.child=o,r}function eu(e,t,r,n){var i=e.child;return e=i.sibling,r=Vs(i,{mode:"visible",children:r}),0===(2&t.mode)&&(r.lanes=n),r.return=t,r.sibling=null,null!==e&&(e.nextEffect=null,e.flags=8,t.firstEffect=t.lastEffect=e),t.child=r}function tu(e,t,r,n,i){var o=t.mode,a=e.child;e=a.sibling;var u={mode:"hidden",children:r};return 0===(2&o)&&t.child!==a?((r=t.child).childLanes=0,r.pendingProps=u,null!==(a=r.lastEffect)?(t.firstEffect=r.firstEffect,t.lastEffect=a,a.nextEffect=null):t.firstEffect=t.lastEffect=null):r=Vs(a,u),null!==e?n=Vs(e,n):(n=Ys(n,o,i,null)).flags|=2,n.return=t,r.return=t,r.sibling=n,t.child=r,n}function ru(e,t){e.lanes|=t;var r=e.alternate;null!==r&&(r.lanes|=t),io(e.return,t)}function nu(e,t,r,n,i,o){var a=e.memoizedState;null===a?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:n,tail:r,tailMode:i,lastEffect:o}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=n,a.tail=r,a.tailMode=i,a.lastEffect=o)}function iu(e,t,r){var n=t.pendingProps,i=n.revealOrder,o=n.tail;if(Ua(e,t,n.children,r),0!==(2&(n=Uo.current)))n=1&n|2,t.flags|=64;else{if(null!==e&&0!==(64&e.flags))e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&ru(e,r);else if(19===e.tag)ru(e,r);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}n&=1}if(li(Uo,n),0===(2&t.mode))t.memoizedState=null;else switch(i){case"forwards":for(r=t.child,i=null;null!==r;)null!==(e=r.alternate)&&null===No(e)&&(i=r),r=r.sibling;null===(r=i)?(i=t.child,t.child=null):(i=r.sibling,r.sibling=null),nu(t,!1,i,r,o,t.lastEffect);break;case"backwards":for(r=null,i=t.child,t.child=null;null!==i;){if(null!==(e=i.alternate)&&null===No(e)){t.child=i;break}e=i.sibling,i.sibling=r,r=i,i=e}nu(t,!0,r,null,o,t.lastEffect);break;case"together":nu(t,!1,null,null,void 0,t.lastEffect);break;default:t.memoizedState=null}return t.child}function ou(e,t,r){if(null!==e&&(t.dependencies=e.dependencies),Fu|=t.lanes,0!==(r&t.childLanes)){if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(r=Vs(e=t.child,e.pendingProps),t.child=r,r.return=t;null!==e.sibling;)e=e.sibling,(r=r.sibling=Vs(e,e.pendingProps)).return=t;r.sibling=null}return t.child}return null}function au(e,t){if(!qo)switch(e.tailMode){case"hidden":t=e.tail;for(var r=null;null!==t;)null!==t.alternate&&(r=t),t=t.sibling;null===r?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var n=null;null!==r;)null!==r.alternate&&(n=r),r=r.sibling;null===n?t||null===e.tail?e.tail=null:e.tail.sibling=null:n.sibling=null}}function uu(e,t,r){var n=t.pendingProps;switch(t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:case 17:return yi(t.type)&&mi(),null;case 3:return Bo(),fi(pi),fi(di),Go(),(n=t.stateNode).pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),null!==e&&null!==e.child||(Zo(t)?t.flags|=4:n.hydrate||(t.flags|=256)),null;case 5:zo(t);var o=Co(Ro.current);if(r=t.type,null!==e&&null!=t.stateNode)Xa(e,t,r,n),e.ref!==t.ref&&(t.flags|=128);else{if(!n){if(null===t.stateNode)throw Error(a(166));return null}if(e=Co(Io.current),Zo(t)){n=t.stateNode,r=t.type;var u=t.memoizedProps;switch(n[$n]=t,n[Qn]=u,r){case"dialog":In("cancel",n),In("close",n);break;case"iframe":case"object":case"embed":In("load",n);break;case"video":case"audio":for(e=0;e<On.length;e++)In(On[e],n);break;case"source":In("error",n);break;case"img":case"image":case"link":In("error",n),In("load",n);break;case"details":In("toggle",n);break;case"input":ee(n,u),In("invalid",n);break;case"select":n._wrapperState={wasMultiple:!!u.multiple},In("invalid",n);break;case"textarea":se(n,u),In("invalid",n)}for(var c in Se(r,u),e=null,u)u.hasOwnProperty(c)&&(o=u[c],"children"===c?"string"===typeof o?n.textContent!==o&&(e=["children",o]):"number"===typeof o&&n.textContent!==""+o&&(e=["children",""+o]):s.hasOwnProperty(c)&&null!=o&&"onScroll"===c&&In("scroll",n));switch(r){case"input":G(n),ne(n,u,!0);break;case"textarea":G(n),fe(n);break;case"select":case"option":break;default:"function"===typeof u.onClick&&(n.onclick=Dn)}n=e,t.updateQueue=n,null!==n&&(t.flags|=4)}else{switch(c=9===o.nodeType?o:o.ownerDocument,e===le&&(e=de(r)),e===le?"script"===r?((e=c.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"===typeof n.is?e=c.createElement(r,{is:n.is}):(e=c.createElement(r),"select"===r&&(c=e,n.multiple?c.multiple=!0:n.size&&(c.size=n.size))):e=c.createElementNS(e,r),e[$n]=t,e[Qn]=n,Ya(e,t),t.stateNode=e,c=Ee(r,n),r){case"dialog":In("cancel",e),In("close",e),o=n;break;case"iframe":case"object":case"embed":In("load",e),o=n;break;case"video":case"audio":for(o=0;o<On.length;o++)In(On[o],e);o=n;break;case"source":In("error",e),o=n;break;case"img":case"image":case"link":In("error",e),In("load",e),o=n;break;case"details":In("toggle",e),o=n;break;case"input":ee(e,n),o=Q(e,n),In("invalid",e);break;case"option":o=oe(e,n);break;case"select":e._wrapperState={wasMultiple:!!n.multiple},o=i({},n,{value:void 0}),In("invalid",e);break;case"textarea":se(e,n),o=ue(e,n),In("invalid",e);break;default:o=n}Se(r,o);var f=o;for(u in f)if(f.hasOwnProperty(u)){var l=f[u];"style"===u?_e(e,l):"dangerouslySetInnerHTML"===u?null!=(l=l?l.__html:void 0)&&ye(e,l):"children"===u?"string"===typeof l?("textarea"!==r||""!==l)&&me(e,l):"number"===typeof l&&me(e,""+l):"suppressContentEditableWarning"!==u&&"suppressHydrationWarning"!==u&&"autoFocus"!==u&&(s.hasOwnProperty(u)?null!=l&&"onScroll"===u&&In("scroll",e):null!=l&&w(e,u,l,c))}switch(r){case"input":G(e),ne(e,n,!1);break;case"textarea":G(e),fe(e);break;case"option":null!=n.value&&e.setAttribute("value",""+Y(n.value));break;case"select":e.multiple=!!n.multiple,null!=(u=n.value)?ae(e,!!n.multiple,u,!1):null!=n.defaultValue&&ae(e,!!n.multiple,n.defaultValue,!0);break;default:"function"===typeof o.onClick&&(e.onclick=Dn)}Hn(r,n)&&(t.flags|=4)}null!==t.ref&&(t.flags|=128)}return null;case 6:if(e&&null!=t.stateNode)Ga(0,t,e.memoizedProps,n);else{if("string"!==typeof n&&null===t.stateNode)throw Error(a(166));r=Co(Ro.current),Co(Io.current),Zo(t)?(n=t.stateNode,r=t.memoizedProps,n[$n]=t,n.nodeValue!==r&&(t.flags|=4)):((n=(9===r.nodeType?r:r.ownerDocument).createTextNode(n))[$n]=t,t.stateNode=n)}return null;case 13:return fi(Uo),n=t.memoizedState,0!==(64&t.flags)?(t.lanes=r,t):(n=null!==n,r=!1,null===e?void 0!==t.memoizedProps.fallback&&Zo(t):r=null!==e.memoizedState,n&&!r&&0!==(2&t.mode)&&(null===e&&!0!==t.memoizedProps.unstable_avoidThisFallback||0!==(1&Uo.current)?0===Uu&&(Uu=3):(0!==Uu&&3!==Uu||(Uu=4),null===Cu||0===(134217727&Fu)&&0===(134217727&qu)||ms(Cu,Bu))),(n||r)&&(t.flags|=4),null);case 4:return Bo(),null===e&&Rn(t.stateNode.containerInfo),null;case 10:return no(t),null;case 19:if(fi(Uo),null===(n=t.memoizedState))return null;if(u=0!==(64&t.flags),null===(c=n.rendering))if(u)au(n,!1);else{if(0!==Uu||null!==e&&0!==(64&e.flags))for(e=t.child;null!==e;){if(null!==(c=No(e))){for(t.flags|=64,au(n,!1),null!==(u=c.updateQueue)&&(t.updateQueue=u,t.flags|=4),null===n.lastEffect&&(t.firstEffect=null),t.lastEffect=n.lastEffect,n=r,r=t.child;null!==r;)e=n,(u=r).flags&=2,u.nextEffect=null,u.firstEffect=null,u.lastEffect=null,null===(c=u.alternate)?(u.childLanes=0,u.lanes=e,u.child=null,u.memoizedProps=null,u.memoizedState=null,u.updateQueue=null,u.dependencies=null,u.stateNode=null):(u.childLanes=c.childLanes,u.lanes=c.lanes,u.child=c.child,u.memoizedProps=c.memoizedProps,u.memoizedState=c.memoizedState,u.updateQueue=c.updateQueue,u.type=c.type,e=c.dependencies,u.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return li(Uo,1&Uo.current|2),t.child}e=e.sibling}null!==n.tail&&Hi()>Vu&&(t.flags|=64,u=!0,au(n,!1),t.lanes=33554432)}else{if(!u)if(null!==(e=No(c))){if(t.flags|=64,u=!0,null!==(r=e.updateQueue)&&(t.updateQueue=r,t.flags|=4),au(n,!0),null===n.tail&&"hidden"===n.tailMode&&!c.alternate&&!qo)return null!==(t=t.lastEffect=n.lastEffect)&&(t.nextEffect=null),null}else 2*Hi()-n.renderingStartTime>Vu&&1073741824!==r&&(t.flags|=64,u=!0,au(n,!1),t.lanes=33554432);n.isBackwards?(c.sibling=t.child,t.child=c):(null!==(r=n.last)?r.sibling=c:t.child=c,n.last=c)}return null!==n.tail?(r=n.tail,n.rendering=r,n.tail=r.sibling,n.lastEffect=t.lastEffect,n.renderingStartTime=Hi(),r.sibling=null,t=Uo.current,li(Uo,u?1&t|2:1&t),r):null;case 23:case 24:return xs(),null!==e&&null!==e.memoizedState!==(null!==t.memoizedState)&&"unstable-defer-without-hiding"!==n.mode&&(t.flags|=4),null}throw Error(a(156,t.tag))}function su(e){switch(e.tag){case 1:yi(e.type)&&mi();var t=e.flags;return 4096&t?(e.flags=-4097&t|64,e):null;case 3:if(Bo(),fi(pi),fi(di),Go(),0!==(64&(t=e.flags)))throw Error(a(285));return e.flags=-4097&t|64,e;case 5:return zo(e),null;case 13:return fi(Uo),4096&(t=e.flags)?(e.flags=-4097&t|64,e):null;case 19:return fi(Uo),null;case 4:return Bo(),null;case 10:return no(e),null;case 23:case 24:return xs(),null;default:return null}}function cu(e,t){try{var r="",n=t;do{r+=V(n),n=n.return}while(n);var i=r}catch(o){i="\nError generating stack: "+o.message+"\n"+o.stack}return{value:e,source:t,stack:i}}function fu(e,t){try{console.error(t.value)}catch(r){setTimeout((function(){throw r}))}}Ya=function(e,t){for(var r=t.child;null!==r;){if(5===r.tag||6===r.tag)e.appendChild(r.stateNode);else if(4!==r.tag&&null!==r.child){r.child.return=r,r=r.child;continue}if(r===t)break;for(;null===r.sibling;){if(null===r.return||r.return===t)return;r=r.return}r.sibling.return=r.return,r=r.sibling}},Xa=function(e,t,r,n){var o=e.memoizedProps;if(o!==n){e=t.stateNode,Co(Io.current);var a,u=null;switch(r){case"input":o=Q(e,o),n=Q(e,n),u=[];break;case"option":o=oe(e,o),n=oe(e,n),u=[];break;case"select":o=i({},o,{value:void 0}),n=i({},n,{value:void 0}),u=[];break;case"textarea":o=ue(e,o),n=ue(e,n),u=[];break;default:"function"!==typeof o.onClick&&"function"===typeof n.onClick&&(e.onclick=Dn)}for(l in Se(r,n),r=null,o)if(!n.hasOwnProperty(l)&&o.hasOwnProperty(l)&&null!=o[l])if("style"===l){var c=o[l];for(a in c)c.hasOwnProperty(a)&&(r||(r={}),r[a]="")}else"dangerouslySetInnerHTML"!==l&&"children"!==l&&"suppressContentEditableWarning"!==l&&"suppressHydrationWarning"!==l&&"autoFocus"!==l&&(s.hasOwnProperty(l)?u||(u=[]):(u=u||[]).push(l,null));for(l in n){var f=n[l];if(c=null!=o?o[l]:void 0,n.hasOwnProperty(l)&&f!==c&&(null!=f||null!=c))if("style"===l)if(c){for(a in c)!c.hasOwnProperty(a)||f&&f.hasOwnProperty(a)||(r||(r={}),r[a]="");for(a in f)f.hasOwnProperty(a)&&c[a]!==f[a]&&(r||(r={}),r[a]=f[a])}else r||(u||(u=[]),u.push(l,r)),r=f;else"dangerouslySetInnerHTML"===l?(f=f?f.__html:void 0,c=c?c.__html:void 0,null!=f&&c!==f&&(u=u||[]).push(l,f)):"children"===l?"string"!==typeof f&&"number"!==typeof f||(u=u||[]).push(l,""+f):"suppressContentEditableWarning"!==l&&"suppressHydrationWarning"!==l&&(s.hasOwnProperty(l)?(null!=f&&"onScroll"===l&&In("scroll",e),u||c===f||(u=[])):"object"===typeof f&&null!==f&&f.$$typeof===B?f.toString():(u=u||[]).push(l,f))}r&&(u=u||[]).push("style",r);var l=u;(t.updateQueue=l)&&(t.flags|=4)}},Ga=function(e,t,r,n){r!==n&&(t.flags|=4)};var lu="function"===typeof WeakMap?WeakMap:Map;function hu(e,t,r){(r=fo(-1,r)).tag=3,r.payload={element:null};var n=t.value;return r.callback=function(){Gu||(Gu=!0,Ju=n),fu(0,t)},r}function du(e,t,r){(r=fo(-1,r)).tag=3;var n=e.type.getDerivedStateFromError;if("function"===typeof n){var i=t.value;r.payload=function(){return fu(0,t),n(i)}}var o=e.stateNode;return null!==o&&"function"===typeof o.componentDidCatch&&(r.callback=function(){"function"!==typeof n&&(null===$u?$u=new Set([this]):$u.add(this),fu(0,t));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),r}var pu="function"===typeof WeakSet?WeakSet:Set;function bu(e){var t=e.ref;if(null!==t)if("function"===typeof t)try{t(null)}catch(r){Ds(e,r)}else t.current=null}function vu(e,t){switch(t.tag){case 0:case 11:case 15:case 22:case 5:case 6:case 4:case 17:return;case 1:if(256&t.flags&&null!==e){var r=e.memoizedProps,n=e.memoizedState;t=(e=t.stateNode).getSnapshotBeforeUpdate(t.elementType===t.type?r:Ji(t.type,r),n),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:return void(256&t.flags&&Zn(t.stateNode.containerInfo))}throw Error(a(163))}function yu(e,t,r){switch(r.tag){case 0:case 11:case 15:case 22:if(null!==(t=null!==(t=r.updateQueue)?t.lastEffect:null)){e=t=t.next;do{if(3===(3&e.tag)){var n=e.create;e.destroy=n()}e=e.next}while(e!==t)}if(null!==(t=null!==(t=r.updateQueue)?t.lastEffect:null)){e=t=t.next;do{var i=e;n=i.next,0!==(4&(i=i.tag))&&0!==(1&i)&&(zs(r,e),Ls(r,e)),e=n}while(e!==t)}return;case 1:return e=r.stateNode,4&r.flags&&(null===t?e.componentDidMount():(n=r.elementType===r.type?t.memoizedProps:Ji(r.type,t.memoizedProps),e.componentDidUpdate(n,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),void(null!==(t=r.updateQueue)&&bo(r,t,e));case 3:if(null!==(t=r.updateQueue)){if(e=null,null!==r.child)switch(r.child.tag){case 5:case 1:e=r.child.stateNode}bo(r,t,e)}return;case 5:return e=r.stateNode,void(null===t&&4&r.flags&&Hn(r.type,r.memoizedProps)&&e.focus());case 6:case 4:case 12:case 19:case 17:case 20:case 21:case 23:case 24:return;case 13:return void(null===r.memoizedState&&(r=r.alternate,null!==r&&(r=r.memoizedState,null!==r&&(r=r.dehydrated,null!==r&&_t(r)))))}throw Error(a(163))}function mu(e,t){for(var r=e;;){if(5===r.tag){var n=r.stateNode;if(t)"function"===typeof(n=n.style).setProperty?n.setProperty("display","none","important"):n.display="none";else{n=r.stateNode;var i=r.memoizedProps.style;i=void 0!==i&&null!==i&&i.hasOwnProperty("display")?i.display:null,n.style.display=ke("display",i)}}else if(6===r.tag)r.stateNode.nodeValue=t?"":r.memoizedProps;else if((23!==r.tag&&24!==r.tag||null===r.memoizedState||r===e)&&null!==r.child){r.child.return=r,r=r.child;continue}if(r===e)break;for(;null===r.sibling;){if(null===r.return||r.return===e)return;r=r.return}r.sibling.return=r.return,r=r.sibling}}function gu(e,t){if(Si&&"function"===typeof Si.onCommitFiberUnmount)try{Si.onCommitFiberUnmount(xi,t)}catch(o){}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(null!==(e=t.updateQueue)&&null!==(e=e.lastEffect)){var r=e=e.next;do{var n=r,i=n.destroy;if(n=n.tag,void 0!==i)if(0!==(4&n))zs(t,r);else{n=t;try{i()}catch(o){Ds(n,o)}}r=r.next}while(r!==e)}break;case 1:if(bu(t),"function"===typeof(e=t.stateNode).componentWillUnmount)try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(o){Ds(t,o)}break;case 5:bu(t);break;case 4:Eu(e,t)}}function wu(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function ku(e){return 5===e.tag||3===e.tag||4===e.tag}function _u(e){e:{for(var t=e.return;null!==t;){if(ku(t))break e;t=t.return}throw Error(a(160))}var r=t;switch(t=r.stateNode,r.tag){case 5:var n=!1;break;case 3:case 4:t=t.containerInfo,n=!0;break;default:throw Error(a(161))}16&r.flags&&(me(t,""),r.flags&=-17);e:t:for(r=e;;){for(;null===r.sibling;){if(null===r.return||ku(r.return)){r=null;break e}r=r.return}for(r.sibling.return=r.return,r=r.sibling;5!==r.tag&&6!==r.tag&&18!==r.tag;){if(2&r.flags)continue t;if(null===r.child||4===r.tag)continue t;r.child.return=r,r=r.child}if(!(2&r.flags)){r=r.stateNode;break e}}n?xu(e,r,t):Su(e,r,t)}function xu(e,t,r){var n=e.tag,i=5===n||6===n;if(i)e=i?e.stateNode:e.stateNode.instance,t?8===r.nodeType?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(8===r.nodeType?(t=r.parentNode).insertBefore(e,r):(t=r).appendChild(e),null!==(r=r._reactRootContainer)&&void 0!==r||null!==t.onclick||(t.onclick=Dn));else if(4!==n&&null!==(e=e.child))for(xu(e,t,r),e=e.sibling;null!==e;)xu(e,t,r),e=e.sibling}function Su(e,t,r){var n=e.tag,i=5===n||6===n;if(i)e=i?e.stateNode:e.stateNode.instance,t?r.insertBefore(e,t):r.appendChild(e);else if(4!==n&&null!==(e=e.child))for(Su(e,t,r),e=e.sibling;null!==e;)Su(e,t,r),e=e.sibling}function Eu(e,t){for(var r,n,i=t,o=!1;;){if(!o){o=i.return;e:for(;;){if(null===o)throw Error(a(160));switch(r=o.stateNode,o.tag){case 5:n=!1;break e;case 3:case 4:r=r.containerInfo,n=!0;break e}o=o.return}o=!0}if(5===i.tag||6===i.tag){e:for(var u=e,s=i,c=s;;)if(gu(u,c),null!==c.child&&4!==c.tag)c.child.return=c,c=c.child;else{if(c===s)break e;for(;null===c.sibling;){if(null===c.return||c.return===s)break e;c=c.return}c.sibling.return=c.return,c=c.sibling}n?(u=r,s=i.stateNode,8===u.nodeType?u.parentNode.removeChild(s):u.removeChild(s)):r.removeChild(i.stateNode)}else if(4===i.tag){if(null!==i.child){r=i.stateNode.containerInfo,n=!0,i.child.return=i,i=i.child;continue}}else if(gu(e,i),null!==i.child){i.child.return=i,i=i.child;continue}if(i===t)break;for(;null===i.sibling;){if(null===i.return||i.return===t)return;4===(i=i.return).tag&&(o=!1)}i.sibling.return=i.return,i=i.sibling}}function Ou(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var r=t.updateQueue;if(null!==(r=null!==r?r.lastEffect:null)){var n=r=r.next;do{3===(3&n.tag)&&(e=n.destroy,n.destroy=void 0,void 0!==e&&e()),n=n.next}while(n!==r)}return;case 1:case 12:case 17:return;case 5:if(null!=(r=t.stateNode)){n=t.memoizedProps;var i=null!==e?e.memoizedProps:n;e=t.type;var o=t.updateQueue;if(t.updateQueue=null,null!==o){for(r[Qn]=n,"input"===e&&"radio"===n.type&&null!=n.name&&te(r,n),Ee(e,i),t=Ee(e,n),i=0;i<o.length;i+=2){var u=o[i],s=o[i+1];"style"===u?_e(r,s):"dangerouslySetInnerHTML"===u?ye(r,s):"children"===u?me(r,s):w(r,u,s,t)}switch(e){case"input":re(r,n);break;case"textarea":ce(r,n);break;case"select":e=r._wrapperState.wasMultiple,r._wrapperState.wasMultiple=!!n.multiple,null!=(o=n.value)?ae(r,!!n.multiple,o,!1):e!==!!n.multiple&&(null!=n.defaultValue?ae(r,!!n.multiple,n.defaultValue,!0):ae(r,!!n.multiple,n.multiple?[]:"",!1))}}}return;case 6:if(null===t.stateNode)throw Error(a(162));return void(t.stateNode.nodeValue=t.memoizedProps);case 3:return void((r=t.stateNode).hydrate&&(r.hydrate=!1,_t(r.containerInfo)));case 13:return null!==t.memoizedState&&(Ku=Hi(),mu(t.child,!0)),void Au(t);case 19:return void Au(t);case 23:case 24:return void mu(t,null!==t.memoizedState)}throw Error(a(163))}function Au(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var r=e.stateNode;null===r&&(r=e.stateNode=new pu),t.forEach((function(t){var n=qs.bind(null,e,t);r.has(t)||(r.add(t),t.then(n,n))}))}}function Mu(e,t){return null!==e&&(null===(e=e.memoizedState)||null!==e.dehydrated)&&(null!==(t=t.memoizedState)&&null===t.dehydrated)}var ju=Math.ceil,Iu=k.ReactCurrentDispatcher,Pu=k.ReactCurrentOwner,Ru=0,Cu=null,Tu=null,Bu=0,Lu=0,zu=ci(0),Uu=0,Nu=null,Du=0,Fu=0,qu=0,Hu=0,Wu=null,Ku=0,Vu=1/0;function Zu(){Vu=Hi()+500}var Yu,Xu=null,Gu=!1,Ju=null,$u=null,Qu=!1,es=null,ts=90,rs=[],ns=[],is=null,os=0,as=null,us=-1,ss=0,cs=0,fs=null,ls=!1;function hs(){return 0!==(48&Ru)?Hi():-1!==us?us:us=Hi()}function ds(e){if(0===(2&(e=e.mode)))return 1;if(0===(4&e))return 99===Wi()?1:2;if(0===ss&&(ss=Du),0!==Gi.transition){0!==cs&&(cs=null!==Wu?Wu.pendingLanes:0),e=ss;var t=4186112&~cs;return 0===(t&=-t)&&(0===(t=(e=4186112&~e)&-e)&&(t=8192)),t}return e=Wi(),0!==(4&Ru)&&98===e?e=Dt(12,ss):e=Dt(e=function(e){switch(e){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}(e),ss),e}function ps(e,t,r){if(50<os)throw os=0,as=null,Error(a(185));if(null===(e=bs(e,t)))return null;Ht(e,t,r),e===Cu&&(qu|=t,4===Uu&&ms(e,Bu));var n=Wi();1===t?0!==(8&Ru)&&0===(48&Ru)?gs(e):(vs(e,r),0===Ru&&(Zu(),Yi())):(0===(4&Ru)||98!==n&&99!==n||(null===is?is=new Set([e]):is.add(e)),vs(e,r)),Wu=e}function bs(e,t){e.lanes|=t;var r=e.alternate;for(null!==r&&(r.lanes|=t),r=e,e=e.return;null!==e;)e.childLanes|=t,null!==(r=e.alternate)&&(r.childLanes|=t),r=e,e=e.return;return 3===r.tag?r.stateNode:null}function vs(e,t){for(var r=e.callbackNode,n=e.suspendedLanes,i=e.pingedLanes,o=e.expirationTimes,u=e.pendingLanes;0<u;){var s=31-Wt(u),c=1<<s,f=o[s];if(-1===f){if(0===(c&n)||0!==(c&i)){f=t,zt(c);var l=Lt;o[s]=10<=l?f+250:6<=l?f+5e3:-1}}else f<=t&&(e.expiredLanes|=c);u&=~c}if(n=Ut(e,e===Cu?Bu:0),t=Lt,0===n)null!==r&&(r!==zi&&Ai(r),e.callbackNode=null,e.callbackPriority=0);else{if(null!==r){if(e.callbackPriority===t)return;r!==zi&&Ai(r)}15===t?(r=gs.bind(null,e),null===Ni?(Ni=[r],Di=Oi(Ri,Xi)):Ni.push(r),r=zi):14===t?r=Zi(99,gs.bind(null,e)):(r=function(e){switch(e){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(a(358,e))}}(t),r=Zi(r,ys.bind(null,e))),e.callbackPriority=t,e.callbackNode=r}}function ys(e){if(us=-1,cs=ss=0,0!==(48&Ru))throw Error(a(327));var t=e.callbackNode;if(Bs()&&e.callbackNode!==t)return null;var r=Ut(e,e===Cu?Bu:0);if(0===r)return null;var n=r,i=Ru;Ru|=16;var o=Os();for(Cu===e&&Bu===n||(Zu(),Ss(e,n));;)try{js();break}catch(s){Es(e,s)}if(ro(),Iu.current=o,Ru=i,null!==Tu?n=0:(Cu=null,Bu=0,n=Uu),0!==(Du&qu))Ss(e,0);else if(0!==n){if(2===n&&(Ru|=64,e.hydrate&&(e.hydrate=!1,Zn(e.containerInfo)),0!==(r=Nt(e))&&(n=As(e,r))),1===n)throw t=Nu,Ss(e,0),ms(e,r),vs(e,Hi()),t;switch(e.finishedWork=e.current.alternate,e.finishedLanes=r,n){case 0:case 1:throw Error(a(345));case 2:case 5:Rs(e);break;case 3:if(ms(e,r),(62914560&r)===r&&10<(n=Ku+500-Hi())){if(0!==Ut(e,0))break;if(((i=e.suspendedLanes)&r)!==r){hs(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Kn(Rs.bind(null,e),n);break}Rs(e);break;case 4:if(ms(e,r),(4186112&r)===r)break;for(n=e.eventTimes,i=-1;0<r;){var u=31-Wt(r);o=1<<u,(u=n[u])>i&&(i=u),r&=~o}if(r=i,10<(r=(120>(r=Hi()-r)?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*ju(r/1960))-r)){e.timeoutHandle=Kn(Rs.bind(null,e),r);break}Rs(e);break;default:throw Error(a(329))}}return vs(e,Hi()),e.callbackNode===t?ys.bind(null,e):null}function ms(e,t){for(t&=~Hu,t&=~qu,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var r=31-Wt(t),n=1<<r;e[r]=-1,t&=~n}}function gs(e){if(0!==(48&Ru))throw Error(a(327));if(Bs(),e===Cu&&0!==(e.expiredLanes&Bu)){var t=Bu,r=As(e,t);0!==(Du&qu)&&(r=As(e,t=Ut(e,t)))}else r=As(e,t=Ut(e,0));if(0!==e.tag&&2===r&&(Ru|=64,e.hydrate&&(e.hydrate=!1,Zn(e.containerInfo)),0!==(t=Nt(e))&&(r=As(e,t))),1===r)throw r=Nu,Ss(e,0),ms(e,t),vs(e,Hi()),r;return e.finishedWork=e.current.alternate,e.finishedLanes=t,Rs(e),vs(e,Hi()),null}function ws(e,t){var r=Ru;Ru|=1;try{return e(t)}finally{0===(Ru=r)&&(Zu(),Yi())}}function ks(e,t){var r=Ru;Ru&=-2,Ru|=8;try{return e(t)}finally{0===(Ru=r)&&(Zu(),Yi())}}function _s(e,t){li(zu,Lu),Lu|=t,Du|=t}function xs(){Lu=zu.current,fi(zu)}function Ss(e,t){e.finishedWork=null,e.finishedLanes=0;var r=e.timeoutHandle;if(-1!==r&&(e.timeoutHandle=-1,Vn(r)),null!==Tu)for(r=Tu.return;null!==r;){var n=r;switch(n.tag){case 1:null!==(n=n.type.childContextTypes)&&void 0!==n&&mi();break;case 3:Bo(),fi(pi),fi(di),Go();break;case 5:zo(n);break;case 4:Bo();break;case 13:case 19:fi(Uo);break;case 10:no(n);break;case 23:case 24:xs()}r=r.return}Cu=e,Tu=Vs(e.current,null),Bu=Lu=Du=t,Uu=0,Nu=null,Hu=qu=Fu=0}function Es(e,t){for(;;){var r=Tu;try{if(ro(),Jo.current=Ra,na){for(var n=ea.memoizedState;null!==n;){var i=n.queue;null!==i&&(i.pending=null),n=n.next}na=!1}if(Qo=0,ra=ta=ea=null,ia=!1,Pu.current=null,null===r||null===r.return){Uu=1,Nu=t,Tu=null;break}e:{var o=e,a=r.return,u=r,s=t;if(t=Bu,u.flags|=2048,u.firstEffect=u.lastEffect=null,null!==s&&"object"===typeof s&&"function"===typeof s.then){var c=s;if(0===(2&u.mode)){var f=u.alternate;f?(u.updateQueue=f.updateQueue,u.memoizedState=f.memoizedState,u.lanes=f.lanes):(u.updateQueue=null,u.memoizedState=null)}var l=0!==(1&Uo.current),h=a;do{var d;if(d=13===h.tag){var p=h.memoizedState;if(null!==p)d=null!==p.dehydrated;else{var b=h.memoizedProps;d=void 0!==b.fallback&&(!0!==b.unstable_avoidThisFallback||!l)}}if(d){var v=h.updateQueue;if(null===v){var y=new Set;y.add(c),h.updateQueue=y}else v.add(c);if(0===(2&h.mode)){if(h.flags|=64,u.flags|=16384,u.flags&=-2981,1===u.tag)if(null===u.alternate)u.tag=17;else{var m=fo(-1,1);m.tag=2,lo(u,m)}u.lanes|=1;break e}s=void 0,u=t;var g=o.pingCache;if(null===g?(g=o.pingCache=new lu,s=new Set,g.set(c,s)):void 0===(s=g.get(c))&&(s=new Set,g.set(c,s)),!s.has(u)){s.add(u);var w=Fs.bind(null,o,c,u);c.then(w,w)}h.flags|=4096,h.lanes=t;break e}h=h.return}while(null!==h);s=Error((Z(u.type)||"A React component")+" suspended while rendering, but no fallback UI was specified.\n\nAdd a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.")}5!==Uu&&(Uu=2),s=cu(s,u),h=a;do{switch(h.tag){case 3:o=s,h.flags|=4096,t&=-t,h.lanes|=t,ho(h,hu(0,o,t));break e;case 1:o=s;var k=h.type,_=h.stateNode;if(0===(64&h.flags)&&("function"===typeof k.getDerivedStateFromError||null!==_&&"function"===typeof _.componentDidCatch&&(null===$u||!$u.has(_)))){h.flags|=4096,t&=-t,h.lanes|=t,ho(h,du(h,o,t));break e}}h=h.return}while(null!==h)}Ps(r)}catch(x){t=x,Tu===r&&null!==r&&(Tu=r=r.return);continue}break}}function Os(){var e=Iu.current;return Iu.current=Ra,null===e?Ra:e}function As(e,t){var r=Ru;Ru|=16;var n=Os();for(Cu===e&&Bu===t||Ss(e,t);;)try{Ms();break}catch(i){Es(e,i)}if(ro(),Ru=r,Iu.current=n,null!==Tu)throw Error(a(261));return Cu=null,Bu=0,Uu}function Ms(){for(;null!==Tu;)Is(Tu)}function js(){for(;null!==Tu&&!Mi();)Is(Tu)}function Is(e){var t=Yu(e.alternate,e,Lu);e.memoizedProps=e.pendingProps,null===t?Ps(e):Tu=t,Pu.current=null}function Ps(e){var t=e;do{var r=t.alternate;if(e=t.return,0===(2048&t.flags)){if(null!==(r=uu(r,t,Lu)))return void(Tu=r);if(24!==(r=t).tag&&23!==r.tag||null===r.memoizedState||0!==(1073741824&Lu)||0===(4&r.mode)){for(var n=0,i=r.child;null!==i;)n|=i.lanes|i.childLanes,i=i.sibling;r.childLanes=n}null!==e&&0===(2048&e.flags)&&(null===e.firstEffect&&(e.firstEffect=t.firstEffect),null!==t.lastEffect&&(null!==e.lastEffect&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1<t.flags&&(null!==e.lastEffect?e.lastEffect.nextEffect=t:e.firstEffect=t,e.lastEffect=t))}else{if(null!==(r=su(t)))return r.flags&=2047,void(Tu=r);null!==e&&(e.firstEffect=e.lastEffect=null,e.flags|=2048)}if(null!==(t=t.sibling))return void(Tu=t);Tu=t=e}while(null!==t);0===Uu&&(Uu=5)}function Rs(e){var t=Wi();return Vi(99,Cs.bind(null,e,t)),null}function Cs(e,t){do{Bs()}while(null!==es);if(0!==(48&Ru))throw Error(a(327));var r=e.finishedWork;if(null===r)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error(a(177));e.callbackNode=null;var n=r.lanes|r.childLanes,i=n,o=e.pendingLanes&~i;e.pendingLanes=i,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=i,e.mutableReadLanes&=i,e.entangledLanes&=i,i=e.entanglements;for(var u=e.eventTimes,s=e.expirationTimes;0<o;){var c=31-Wt(o),f=1<<c;i[c]=0,u[c]=-1,s[c]=-1,o&=~f}if(null!==is&&0===(24&n)&&is.has(e)&&is.delete(e),e===Cu&&(Tu=Cu=null,Bu=0),1<r.flags?null!==r.lastEffect?(r.lastEffect.nextEffect=r,n=r.firstEffect):n=r:n=r.firstEffect,null!==n){if(i=Ru,Ru|=32,Pu.current=null,Fn=Xt,yn(u=vn())){if("selectionStart"in u)s={start:u.selectionStart,end:u.selectionEnd};else e:if(s=(s=u.ownerDocument)&&s.defaultView||window,(f=s.getSelection&&s.getSelection())&&0!==f.rangeCount){s=f.anchorNode,o=f.anchorOffset,c=f.focusNode,f=f.focusOffset;try{s.nodeType,c.nodeType}catch(O){s=null;break e}var l=0,h=-1,d=-1,p=0,b=0,v=u,y=null;t:for(;;){for(var m;v!==s||0!==o&&3!==v.nodeType||(h=l+o),v!==c||0!==f&&3!==v.nodeType||(d=l+f),3===v.nodeType&&(l+=v.nodeValue.length),null!==(m=v.firstChild);)y=v,v=m;for(;;){if(v===u)break t;if(y===s&&++p===o&&(h=l),y===c&&++b===f&&(d=l),null!==(m=v.nextSibling))break;y=(v=y).parentNode}v=m}s=-1===h||-1===d?null:{start:h,end:d}}else s=null;s=s||{start:0,end:0}}else s=null;qn={focusedElem:u,selectionRange:s},Xt=!1,fs=null,ls=!1,Xu=n;do{try{Ts()}catch(O){if(null===Xu)throw Error(a(330));Ds(Xu,O),Xu=Xu.nextEffect}}while(null!==Xu);fs=null,Xu=n;do{try{for(u=e;null!==Xu;){var g=Xu.flags;if(16&g&&me(Xu.stateNode,""),128&g){var w=Xu.alternate;if(null!==w){var k=w.ref;null!==k&&("function"===typeof k?k(null):k.current=null)}}switch(1038&g){case 2:_u(Xu),Xu.flags&=-3;break;case 6:_u(Xu),Xu.flags&=-3,Ou(Xu.alternate,Xu);break;case 1024:Xu.flags&=-1025;break;case 1028:Xu.flags&=-1025,Ou(Xu.alternate,Xu);break;case 4:Ou(Xu.alternate,Xu);break;case 8:Eu(u,s=Xu);var _=s.alternate;wu(s),null!==_&&wu(_)}Xu=Xu.nextEffect}}catch(O){if(null===Xu)throw Error(a(330));Ds(Xu,O),Xu=Xu.nextEffect}}while(null!==Xu);if(k=qn,w=vn(),g=k.focusedElem,u=k.selectionRange,w!==g&&g&&g.ownerDocument&&bn(g.ownerDocument.documentElement,g)){null!==u&&yn(g)&&(w=u.start,void 0===(k=u.end)&&(k=w),"selectionStart"in g?(g.selectionStart=w,g.selectionEnd=Math.min(k,g.value.length)):(k=(w=g.ownerDocument||document)&&w.defaultView||window).getSelection&&(k=k.getSelection(),s=g.textContent.length,_=Math.min(u.start,s),u=void 0===u.end?_:Math.min(u.end,s),!k.extend&&_>u&&(s=u,u=_,_=s),s=pn(g,_),o=pn(g,u),s&&o&&(1!==k.rangeCount||k.anchorNode!==s.node||k.anchorOffset!==s.offset||k.focusNode!==o.node||k.focusOffset!==o.offset)&&((w=w.createRange()).setStart(s.node,s.offset),k.removeAllRanges(),_>u?(k.addRange(w),k.extend(o.node,o.offset)):(w.setEnd(o.node,o.offset),k.addRange(w))))),w=[];for(k=g;k=k.parentNode;)1===k.nodeType&&w.push({element:k,left:k.scrollLeft,top:k.scrollTop});for("function"===typeof g.focus&&g.focus(),g=0;g<w.length;g++)(k=w[g]).element.scrollLeft=k.left,k.element.scrollTop=k.top}Xt=!!Fn,qn=Fn=null,e.current=r,Xu=n;do{try{for(g=e;null!==Xu;){var x=Xu.flags;if(36&x&&yu(g,Xu.alternate,Xu),128&x){w=void 0;var S=Xu.ref;if(null!==S){var E=Xu.stateNode;Xu.tag,w=E,"function"===typeof S?S(w):S.current=w}}Xu=Xu.nextEffect}}catch(O){if(null===Xu)throw Error(a(330));Ds(Xu,O),Xu=Xu.nextEffect}}while(null!==Xu);Xu=null,Ui(),Ru=i}else e.current=r;if(Qu)Qu=!1,es=e,ts=t;else for(Xu=n;null!==Xu;)t=Xu.nextEffect,Xu.nextEffect=null,8&Xu.flags&&((x=Xu).sibling=null,x.stateNode=null),Xu=t;if(0===(n=e.pendingLanes)&&($u=null),1===n?e===as?os++:(os=0,as=e):os=0,r=r.stateNode,Si&&"function"===typeof Si.onCommitFiberRoot)try{Si.onCommitFiberRoot(xi,r,void 0,64===(64&r.current.flags))}catch(O){}if(vs(e,Hi()),Gu)throw Gu=!1,e=Ju,Ju=null,e;return 0!==(8&Ru)||Yi(),null}function Ts(){for(;null!==Xu;){var e=Xu.alternate;ls||null===fs||(0!==(8&Xu.flags)?et(Xu,fs)&&(ls=!0):13===Xu.tag&&Mu(e,Xu)&&et(Xu,fs)&&(ls=!0));var t=Xu.flags;0!==(256&t)&&vu(e,Xu),0===(512&t)||Qu||(Qu=!0,Zi(97,(function(){return Bs(),null}))),Xu=Xu.nextEffect}}function Bs(){if(90!==ts){var e=97<ts?97:ts;return ts=90,Vi(e,Us)}return!1}function Ls(e,t){rs.push(t,e),Qu||(Qu=!0,Zi(97,(function(){return Bs(),null})))}function zs(e,t){ns.push(t,e),Qu||(Qu=!0,Zi(97,(function(){return Bs(),null})))}function Us(){if(null===es)return!1;var e=es;if(es=null,0!==(48&Ru))throw Error(a(331));var t=Ru;Ru|=32;var r=ns;ns=[];for(var n=0;n<r.length;n+=2){var i=r[n],o=r[n+1],u=i.destroy;if(i.destroy=void 0,"function"===typeof u)try{u()}catch(c){if(null===o)throw Error(a(330));Ds(o,c)}}for(r=rs,rs=[],n=0;n<r.length;n+=2){i=r[n],o=r[n+1];try{var s=i.create;i.destroy=s()}catch(c){if(null===o)throw Error(a(330));Ds(o,c)}}for(s=e.current.firstEffect;null!==s;)e=s.nextEffect,s.nextEffect=null,8&s.flags&&(s.sibling=null,s.stateNode=null),s=e;return Ru=t,Yi(),!0}function Ns(e,t,r){lo(e,t=hu(0,t=cu(r,t),1)),t=hs(),null!==(e=bs(e,1))&&(Ht(e,1,t),vs(e,t))}function Ds(e,t){if(3===e.tag)Ns(e,e,t);else for(var r=e.return;null!==r;){if(3===r.tag){Ns(r,e,t);break}if(1===r.tag){var n=r.stateNode;if("function"===typeof r.type.getDerivedStateFromError||"function"===typeof n.componentDidCatch&&(null===$u||!$u.has(n))){var i=du(r,e=cu(t,e),1);if(lo(r,i),i=hs(),null!==(r=bs(r,1)))Ht(r,1,i),vs(r,i);else if("function"===typeof n.componentDidCatch&&(null===$u||!$u.has(n)))try{n.componentDidCatch(t,e)}catch(o){}break}}r=r.return}}function Fs(e,t,r){var n=e.pingCache;null!==n&&n.delete(t),t=hs(),e.pingedLanes|=e.suspendedLanes&r,Cu===e&&(Bu&r)===r&&(4===Uu||3===Uu&&(62914560&Bu)===Bu&&500>Hi()-Ku?Ss(e,0):Hu|=r),vs(e,t)}function qs(e,t){var r=e.stateNode;null!==r&&r.delete(t),0===(t=0)&&(0===(2&(t=e.mode))?t=1:0===(4&t)?t=99===Wi()?1:2:(0===ss&&(ss=Du),0===(t=Ft(62914560&~ss))&&(t=4194304))),r=hs(),null!==(e=bs(e,t))&&(Ht(e,t,r),vs(e,r))}function Hs(e,t,r,n){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.flags=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childLanes=this.lanes=0,this.alternate=null}function Ws(e,t,r,n){return new Hs(e,t,r,n)}function Ks(e){return!(!(e=e.prototype)||!e.isReactComponent)}function Vs(e,t){var r=e.alternate;return null===r?((r=Ws(e.tag,t,e.key,e.mode)).elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.nextEffect=null,r.firstEffect=null,r.lastEffect=null),r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function Zs(e,t,r,n,i,o){var u=2;if(n=e,"function"===typeof e)Ks(e)&&(u=1);else if("string"===typeof e)u=5;else e:switch(e){case S:return Ys(r.children,i,o,t);case L:u=8,i|=16;break;case E:u=8,i|=1;break;case O:return(e=Ws(12,r,t,8|i)).elementType=O,e.type=O,e.lanes=o,e;case I:return(e=Ws(13,r,t,i)).type=I,e.elementType=I,e.lanes=o,e;case P:return(e=Ws(19,r,t,i)).elementType=P,e.lanes=o,e;case z:return Xs(r,i,o,t);case U:return(e=Ws(24,r,t,i)).elementType=U,e.lanes=o,e;default:if("object"===typeof e&&null!==e)switch(e.$$typeof){case A:u=10;break e;case M:u=9;break e;case j:u=11;break e;case R:u=14;break e;case C:u=16,n=null;break e;case T:u=22;break e}throw Error(a(130,null==e?e:typeof e,""))}return(t=Ws(u,r,t,i)).elementType=e,t.type=n,t.lanes=o,t}function Ys(e,t,r,n){return(e=Ws(7,e,n,t)).lanes=r,e}function Xs(e,t,r,n){return(e=Ws(23,e,n,t)).elementType=z,e.lanes=r,e}function Gs(e,t,r){return(e=Ws(6,e,null,t)).lanes=r,e}function Js(e,t,r){return(t=Ws(4,null!==e.children?e.children:[],e.key,t)).lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function $s(e,t,r){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=r,this.callbackNode=null,this.callbackPriority=0,this.eventTimes=qt(0),this.expirationTimes=qt(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=qt(0),this.mutableSourceEagerHydrationData=null}function Qs(e,t,r){var n=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:x,key:null==n?null:""+n,children:e,containerInfo:t,implementation:r}}function ec(e,t,r,n){var i=t.current,o=hs(),u=ds(i);e:if(r){t:{if(Ge(r=r._reactInternals)!==r||1!==r.tag)throw Error(a(170));var s=r;do{switch(s.tag){case 3:s=s.stateNode.context;break t;case 1:if(yi(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break t}}s=s.return}while(null!==s);throw Error(a(171))}if(1===r.tag){var c=r.type;if(yi(c)){r=wi(r,c,s);break e}}r=s}else r=hi;return null===t.context?t.context=r:t.pendingContext=r,(t=fo(o,u)).payload={element:e},null!==(n=void 0===n?null:n)&&(t.callback=n),lo(i,t),ps(i,u,o),u}function tc(e){return(e=e.current).child?(e.child.tag,e.child.stateNode):null}function rc(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var r=e.retryLane;e.retryLane=0!==r&&r<t?r:t}}function nc(e,t){rc(e,t),(e=e.alternate)&&rc(e,t)}function ic(e,t,r){var n=null!=r&&null!=r.hydrationOptions&&r.hydrationOptions.mutableSources||null;if(r=new $s(e,t,null!=r&&!0===r.hydrate),t=Ws(3,null,null,2===t?7:1===t?3:0),r.current=t,t.stateNode=r,so(t),e[ei]=r.current,Rn(8===e.nodeType?e.parentNode:e),n)for(e=0;e<n.length;e++){var i=(t=n[e])._getVersion;i=i(t._source),null==r.mutableSourceEagerHydrationData?r.mutableSourceEagerHydrationData=[t,i]:r.mutableSourceEagerHydrationData.push(t,i)}this._internalRoot=r}function oc(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function ac(e,t,r,n,i){var o=r._reactRootContainer;if(o){var a=o._internalRoot;if("function"===typeof i){var u=i;i=function(){var e=tc(a);u.call(e)}}ec(t,a,e,i)}else{if(o=r._reactRootContainer=function(e,t){if(t||(t=!(!(t=e?9===e.nodeType?e.documentElement:e.firstChild:null)||1!==t.nodeType||!t.hasAttribute("data-reactroot"))),!t)for(var r;r=e.lastChild;)e.removeChild(r);return new ic(e,0,t?{hydrate:!0}:void 0)}(r,n),a=o._internalRoot,"function"===typeof i){var s=i;i=function(){var e=tc(a);s.call(e)}}ks((function(){ec(t,a,e,i)}))}return tc(a)}function uc(e,t){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!oc(t))throw Error(a(200));return Qs(e,t,null,r)}Yu=function(e,t,r){var n=t.lanes;if(null!==e)if(e.memoizedProps!==t.pendingProps||pi.current)za=!0;else{if(0===(r&n)){switch(za=!1,t.tag){case 3:Za(t),Yo();break;case 5:Lo(t);break;case 1:yi(t.type)&&ki(t);break;case 4:To(t,t.stateNode.containerInfo);break;case 10:n=t.memoizedProps.value;var i=t.type._context;li($i,i._currentValue),i._currentValue=n;break;case 13:if(null!==t.memoizedState)return 0!==(r&t.child.childLanes)?$a(e,t,r):(li(Uo,1&Uo.current),null!==(t=ou(e,t,r))?t.sibling:null);li(Uo,1&Uo.current);break;case 19:if(n=0!==(r&t.childLanes),0!==(64&e.flags)){if(n)return iu(e,t,r);t.flags|=64}if(null!==(i=t.memoizedState)&&(i.rendering=null,i.tail=null,i.lastEffect=null),li(Uo,Uo.current),n)break;return null;case 23:case 24:return t.lanes=0,qa(e,t,r)}return ou(e,t,r)}za=0!==(16384&e.flags)}else za=!1;switch(t.lanes=0,t.tag){case 2:if(n=t.type,null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=vi(t,di.current),oo(t,r),i=ua(null,t,n,e,i,r),t.flags|=1,"object"===typeof i&&null!==i&&"function"===typeof i.render&&void 0===i.$$typeof){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,yi(n)){var o=!0;ki(t)}else o=!1;t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,so(t);var u=n.getDerivedStateFromProps;"function"===typeof u&&yo(t,n,u,e),i.updater=mo,t.stateNode=i,i._reactInternals=t,_o(t,n,e,r),t=Va(null,t,n,!0,o,r)}else t.tag=0,Ua(null,t,i,r),t=t.child;return t;case 16:i=t.elementType;e:{switch(null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=(o=i._init)(i._payload),t.type=i,o=t.tag=function(e){if("function"===typeof e)return Ks(e)?1:0;if(void 0!==e&&null!==e){if((e=e.$$typeof)===j)return 11;if(e===R)return 14}return 2}(i),e=Ji(i,e),o){case 0:t=Wa(null,t,i,e,r);break e;case 1:t=Ka(null,t,i,e,r);break e;case 11:t=Na(null,t,i,e,r);break e;case 14:t=Da(null,t,i,Ji(i.type,e),n,r);break e}throw Error(a(306,i,""))}return t;case 0:return n=t.type,i=t.pendingProps,Wa(e,t,n,i=t.elementType===n?i:Ji(n,i),r);case 1:return n=t.type,i=t.pendingProps,Ka(e,t,n,i=t.elementType===n?i:Ji(n,i),r);case 3:if(Za(t),n=t.updateQueue,null===e||null===n)throw Error(a(282));if(n=t.pendingProps,i=null!==(i=t.memoizedState)?i.element:null,co(e,t),po(t,n,null,r),(n=t.memoizedState.element)===i)Yo(),t=ou(e,t,r);else{if((o=(i=t.stateNode).hydrate)&&(Fo=Yn(t.stateNode.containerInfo.firstChild),Do=t,o=qo=!0),o){if(null!=(e=i.mutableSourceEagerHydrationData))for(i=0;i<e.length;i+=2)(o=e[i])._workInProgressVersionPrimary=e[i+1],Xo.push(o);for(r=Mo(t,null,n,r),t.child=r;r;)r.flags=-3&r.flags|1024,r=r.sibling}else Ua(e,t,n,r),Yo();t=t.child}return t;case 5:return Lo(t),null===e&&Ko(t),n=t.type,i=t.pendingProps,o=null!==e?e.memoizedProps:null,u=i.children,Wn(n,i)?u=null:null!==o&&Wn(n,o)&&(t.flags|=16),Ha(e,t),Ua(e,t,u,r),t.child;case 6:return null===e&&Ko(t),null;case 13:return $a(e,t,r);case 4:return To(t,t.stateNode.containerInfo),n=t.pendingProps,null===e?t.child=Ao(t,null,n,r):Ua(e,t,n,r),t.child;case 11:return n=t.type,i=t.pendingProps,Na(e,t,n,i=t.elementType===n?i:Ji(n,i),r);case 7:return Ua(e,t,t.pendingProps,r),t.child;case 8:case 12:return Ua(e,t,t.pendingProps.children,r),t.child;case 10:e:{n=t.type._context,i=t.pendingProps,u=t.memoizedProps,o=i.value;var s=t.type._context;if(li($i,s._currentValue),s._currentValue=o,null!==u)if(s=u.value,0===(o=fn(s,o)?0:0|("function"===typeof n._calculateChangedBits?n._calculateChangedBits(s,o):1073741823))){if(u.children===i.children&&!pi.current){t=ou(e,t,r);break e}}else for(null!==(s=t.child)&&(s.return=t);null!==s;){var c=s.dependencies;if(null!==c){u=s.child;for(var f=c.firstContext;null!==f;){if(f.context===n&&0!==(f.observedBits&o)){1===s.tag&&((f=fo(-1,r&-r)).tag=2,lo(s,f)),s.lanes|=r,null!==(f=s.alternate)&&(f.lanes|=r),io(s.return,r),c.lanes|=r;break}f=f.next}}else u=10===s.tag&&s.type===t.type?null:s.child;if(null!==u)u.return=s;else for(u=s;null!==u;){if(u===t){u=null;break}if(null!==(s=u.sibling)){s.return=u.return,u=s;break}u=u.return}s=u}Ua(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,n=(o=t.pendingProps).children,oo(t,r),n=n(i=ao(i,o.unstable_observedBits)),t.flags|=1,Ua(e,t,n,r),t.child;case 14:return o=Ji(i=t.type,t.pendingProps),Da(e,t,i,o=Ji(i.type,o),n,r);case 15:return Fa(e,t,t.type,t.pendingProps,n,r);case 17:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Ji(n,i),null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2),t.tag=1,yi(n)?(e=!0,ki(t)):e=!1,oo(t,r),wo(t,n,i),_o(t,n,i,r),Va(null,t,n,!0,e,r);case 19:return iu(e,t,r);case 23:case 24:return qa(e,t,r)}throw Error(a(156,t.tag))},ic.prototype.render=function(e){ec(e,this._internalRoot,null,null)},ic.prototype.unmount=function(){var e=this._internalRoot,t=e.containerInfo;ec(null,e,null,(function(){t[ei]=null}))},tt=function(e){13===e.tag&&(ps(e,4,hs()),nc(e,4))},rt=function(e){13===e.tag&&(ps(e,67108864,hs()),nc(e,67108864))},nt=function(e){if(13===e.tag){var t=hs(),r=ds(e);ps(e,r,t),nc(e,r)}},it=function(e,t){return t()},Ae=function(e,t,r){switch(t){case"input":if(re(e,r),t=r.name,"radio"===r.type&&null!=t){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<r.length;t++){var n=r[t];if(n!==e&&n.form===e.form){var i=oi(n);if(!i)throw Error(a(90));J(n),re(n,i)}}}break;case"textarea":ce(e,r);break;case"select":null!=(t=r.value)&&ae(e,!!r.multiple,t,!1)}},Ce=ws,Te=function(e,t,r,n,i){var o=Ru;Ru|=4;try{return Vi(98,e.bind(null,t,r,n,i))}finally{0===(Ru=o)&&(Zu(),Yi())}},Be=function(){0===(49&Ru)&&(function(){if(null!==is){var e=is;is=null,e.forEach((function(e){e.expiredLanes|=24&e.pendingLanes,vs(e,Hi())}))}Yi()}(),Bs())},Le=function(e,t){var r=Ru;Ru|=2;try{return e(t)}finally{0===(Ru=r)&&(Zu(),Yi())}};var sc={Events:[ni,ii,oi,Pe,Re,Bs,{current:!1}]},cc={findFiberByHostInstance:ri,bundleType:0,version:"17.0.2",rendererPackageName:"react-dom"},fc={bundleType:cc.bundleType,version:cc.version,rendererPackageName:cc.rendererPackageName,rendererConfig:cc.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:k.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=Qe(e))?null:e.stateNode},findFiberByHostInstance:cc.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if("undefined"!==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var lc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!lc.isDisabled&&lc.supportsFiber)try{xi=lc.inject(fc),Si=lc}catch(ve){}}t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=sc,t.createPortal=uc,t.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"===typeof e.render)throw Error(a(188));throw Error(a(268,Object.keys(e)))}return e=null===(e=Qe(t))?null:e.stateNode},t.flushSync=function(e,t){var r=Ru;if(0!==(48&r))return e(t);Ru|=1;try{if(e)return Vi(99,e.bind(null,t))}finally{Ru=r,Yi()}},t.hydrate=function(e,t,r){if(!oc(t))throw Error(a(200));return ac(null,e,t,!0,r)},t.render=function(e,t,r){if(!oc(t))throw Error(a(200));return ac(null,e,t,!1,r)},t.unmountComponentAtNode=function(e){if(!oc(e))throw Error(a(40));return!!e._reactRootContainer&&(ks((function(){ac(null,null,e,!1,(function(){e._reactRootContainer=null,e[ei]=null}))})),!0)},t.unstable_batchedUpdates=ws,t.unstable_createPortal=function(e,t){return uc(e,t,2<arguments.length&&void 0!==arguments[2]?arguments[2]:null)},t.unstable_renderSubtreeIntoContainer=function(e,t,r,n){if(!oc(r))throw Error(a(200));if(null==e||void 0===e._reactInternals)throw Error(a(38));return ac(e,t,r,!1,n)},t.version="17.0.2"},function(e,t,r){"use strict";e.exports=r(104)},function(e,t,r){"use strict";var n,i,o,a;if("object"===typeof performance&&"function"===typeof performance.now){var u=performance;t.unstable_now=function(){return u.now()}}else{var s=Date,c=s.now();t.unstable_now=function(){return s.now()-c}}if("undefined"===typeof window||"function"!==typeof MessageChannel){var f=null,l=null,h=function e(){if(null!==f)try{var r=t.unstable_now();f(!0,r),f=null}catch(n){throw setTimeout(e,0),n}};n=function(e){null!==f?setTimeout(n,0,e):(f=e,setTimeout(h,0))},i=function(e,t){l=setTimeout(e,t)},o=function(){clearTimeout(l)},t.unstable_shouldYield=function(){return!1},a=t.unstable_forceFrameRate=function(){}}else{var d=window.setTimeout,p=window.clearTimeout;if("undefined"!==typeof console){var b=window.cancelAnimationFrame;"function"!==typeof window.requestAnimationFrame&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),"function"!==typeof b&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var v=!1,y=null,m=-1,g=5,w=0;t.unstable_shouldYield=function(){return t.unstable_now()>=w},a=function(){},t.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):g=0<e?Math.floor(1e3/e):5};var k=new MessageChannel,_=k.port2;k.port1.onmessage=function(){if(null!==y){var e=t.unstable_now();w=e+g;try{y(!0,e)?_.postMessage(null):(v=!1,y=null)}catch(r){throw _.postMessage(null),r}}else v=!1},n=function(e){y=e,v||(v=!0,_.postMessage(null))},i=function(e,r){m=d((function(){e(t.unstable_now())}),r)},o=function(){p(m),m=-1}}function x(e,t){var r=e.length;e.push(t);e:for(;;){var n=r-1>>>1,i=e[n];if(!(void 0!==i&&0<O(i,t)))break e;e[n]=t,e[r]=i,r=n}}function S(e){return void 0===(e=e[0])?null:e}function E(e){var t=e[0];if(void 0!==t){var r=e.pop();if(r!==t){e[0]=r;e:for(var n=0,i=e.length;n<i;){var o=2*(n+1)-1,a=e[o],u=o+1,s=e[u];if(void 0!==a&&0>O(a,r))void 0!==s&&0>O(s,a)?(e[n]=s,e[u]=r,n=u):(e[n]=a,e[o]=r,n=o);else{if(!(void 0!==s&&0>O(s,r)))break e;e[n]=s,e[u]=r,n=u}}}return t}return null}function O(e,t){var r=e.sortIndex-t.sortIndex;return 0!==r?r:e.id-t.id}var A=[],M=[],j=1,I=null,P=3,R=!1,C=!1,T=!1;function B(e){for(var t=S(M);null!==t;){if(null===t.callback)E(M);else{if(!(t.startTime<=e))break;E(M),t.sortIndex=t.expirationTime,x(A,t)}t=S(M)}}function L(e){if(T=!1,B(e),!C)if(null!==S(A))C=!0,n(z);else{var t=S(M);null!==t&&i(L,t.startTime-e)}}function z(e,r){C=!1,T&&(T=!1,o()),R=!0;var n=P;try{for(B(r),I=S(A);null!==I&&(!(I.expirationTime>r)||e&&!t.unstable_shouldYield());){var a=I.callback;if("function"===typeof a){I.callback=null,P=I.priorityLevel;var u=a(I.expirationTime<=r);r=t.unstable_now(),"function"===typeof u?I.callback=u:I===S(A)&&E(A),B(r)}else E(A);I=S(A)}if(null!==I)var s=!0;else{var c=S(M);null!==c&&i(L,c.startTime-r),s=!1}return s}finally{I=null,P=n,R=!1}}var U=a;t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_continueExecution=function(){C||R||(C=!0,n(z))},t.unstable_getCurrentPriorityLevel=function(){return P},t.unstable_getFirstCallbackNode=function(){return S(A)},t.unstable_next=function(e){switch(P){case 1:case 2:case 3:var t=3;break;default:t=P}var r=P;P=t;try{return e()}finally{P=r}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=U,t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var r=P;P=e;try{return t()}finally{P=r}},t.unstable_scheduleCallback=function(e,r,a){var u=t.unstable_now();switch("object"===typeof a&&null!==a?a="number"===typeof(a=a.delay)&&0<a?u+a:u:a=u,e){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return e={id:j++,callback:r,priorityLevel:e,startTime:a,expirationTime:s=a+s,sortIndex:-1},a>u?(e.sortIndex=a,x(M,e),null===S(A)&&e===S(M)&&(T?o():T=!0,i(L,a-u))):(e.sortIndex=s,x(A,e),C||R||(C=!0,n(z))),e},t.unstable_wrapCallback=function(e){var t=P;return function(){var r=P;P=t;try{return e.apply(this,arguments)}finally{P=r}}}},,function(e,t,r){var n=function(e){"use strict";var t,r=Object.prototype,n=r.hasOwnProperty,i="function"===typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(P){s=function(e,t,r){return e[t]=r}}function c(e,t,r,n){var i=t&&t.prototype instanceof v?t:v,o=Object.create(i.prototype),a=new M(n||[]);return o._invoke=function(e,t,r){var n=l;return function(i,o){if(n===d)throw new Error("Generator is already running");if(n===p){if("throw"===i)throw o;return I()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=E(a,r);if(u){if(u===b)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===l)throw n=p,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=d;var s=f(e,t,r);if("normal"===s.type){if(n=r.done?p:h,s.arg===b)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n=p,r.method="throw",r.arg=s.arg)}}}(e,r,a),o}function f(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(P){return{type:"throw",arg:P}}}e.wrap=c;var l="suspendedStart",h="suspendedYield",d="executing",p="completed",b={};function v(){}function y(){}function m(){}var g={};s(g,o,(function(){return this}));var w=Object.getPrototypeOf,k=w&&w(w(j([])));k&&k!==r&&n.call(k,o)&&(g=k);var _=m.prototype=v.prototype=Object.create(g);function x(e){["next","throw","return"].forEach((function(t){s(e,t,(function(e){return this._invoke(t,e)}))}))}function S(e,t){function r(i,o,a,u){var s=f(e[i],e,o);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"===typeof l&&n.call(l,"__await")?t.resolve(l.__await).then((function(e){r("next",e,a,u)}),(function(e){r("throw",e,a,u)})):t.resolve(l).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,u)}))}u(s.arg)}var i;this._invoke=function(e,n){function o(){return new t((function(t,i){r(e,n,t,i)}))}return i=i?i.then(o,o):o()}}function E(e,r){var n=e.iterator[r.method];if(n===t){if(r.delegate=null,"throw"===r.method){if(e.iterator.return&&(r.method="return",r.arg=t,E(e,r),"throw"===r.method))return b;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return b}var i=f(n,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,b;var o=i.arg;return o?o.done?(r[e.resultName]=o.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,b):o:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,b)}function O(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function A(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function M(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(O,this),this.reset(!0)}function j(e){if(e){var r=e[o];if(r)return r.call(e);if("function"===typeof e.next)return e;if(!isNaN(e.length)){var i=-1,a=function r(){for(;++i<e.length;)if(n.call(e,i))return r.value=e[i],r.done=!1,r;return r.value=t,r.done=!0,r};return a.next=a}}return{next:I}}function I(){return{value:t,done:!0}}return y.prototype=m,s(_,"constructor",m),s(m,"constructor",y),y.displayName=s(m,u,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"===typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,m):(e.__proto__=m,s(e,u,"GeneratorFunction")),e.prototype=Object.create(_),e},e.awrap=function(e){return{__await:e}},x(S.prototype),s(S.prototype,a,(function(){return this})),e.AsyncIterator=S,e.async=function(t,r,n,i,o){void 0===o&&(o=Promise);var a=new S(c(t,r,n,i),o);return e.isGeneratorFunction(r)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},x(_),s(_,u,"Generator"),s(_,o,(function(){return this})),s(_,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=[];for(var r in e)t.push(r);return t.reverse(),function r(){for(;t.length;){var n=t.pop();if(n in e)return r.value=n,r.done=!1,r}return r.done=!0,r}},e.values=j,M.prototype={constructor:M,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(A),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var r=this;function i(n,i){return u.type="throw",u.arg=e,r.next=n,i&&(r.method="next",r.arg=t),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],u=a.completion;if("root"===a.tryLoc)return i("end");if(a.tryLoc<=this.prev){var s=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(s&&c){if(this.prev<a.catchLoc)return i(a.catchLoc,!0);if(this.prev<a.finallyLoc)return i(a.finallyLoc)}else if(s){if(this.prev<a.catchLoc)return i(a.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return i(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=e,a.arg=t,o?(this.method="next",this.next=o.finallyLoc,b):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),b},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),A(r),b}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var i=n.arg;A(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,r,n){return this.delegate={iterator:j(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),b}},e}(e.exports);try{regeneratorRuntime=n}catch(i){"object"===typeof globalThis?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}},,,function(e,t){t.read=function(e,t,r,n,i){var o,a,u=8*i-n-1,s=(1<<u)-1,c=s>>1,f=-7,l=r?i-1:0,h=r?-1:1,d=e[t+l];for(l+=h,o=d&(1<<-f)-1,d>>=-f,f+=u;f>0;o=256*o+e[t+l],l+=h,f-=8);for(a=o&(1<<-f)-1,o>>=-f,f+=n;f>0;a=256*a+e[t+l],l+=h,f-=8);if(0===o)o=1-c;else{if(o===s)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,n),o-=c}return(d?-1:1)*a*Math.pow(2,o-n)},t.write=function(e,t,r,n,i,o){var a,u,s,c=8*o-i-1,f=(1<<c)-1,l=f>>1,h=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,d=n?0:o-1,p=n?1:-1,b=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(u=isNaN(t)?1:0,a=f):(a=Math.floor(Math.log(t)/Math.LN2),t*(s=Math.pow(2,-a))<1&&(a--,s*=2),(t+=a+l>=1?h/s:h*Math.pow(2,1-l))*s>=2&&(a++,s/=2),a+l>=f?(u=0,a=f):a+l>=1?(u=(t*s-1)*Math.pow(2,i),a+=l):(u=t*Math.pow(2,l-1)*Math.pow(2,i),a=0));i>=8;e[r+d]=255&u,d+=p,u/=256,i-=8);for(a=a<<i|u,c+=i;c>0;e[r+d]=255&a,d+=p,a/=256,c-=8);e[r+d-p]|=128*b}},function(e,t){var r={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==r.call(e)}},,function(e,t,r){"use strict";var n=r(113).Buffer;e.exports=function(e){if(e.length>=255)throw new TypeError("Alphabet too long");for(var t=new Uint8Array(256),r=0;r<t.length;r++)t[r]=255;for(var i=0;i<e.length;i++){var o=e.charAt(i),a=o.charCodeAt(0);if(255!==t[a])throw new TypeError(o+" is ambiguous");t[a]=i}var u=e.length,s=e.charAt(0),c=Math.log(u)/Math.log(256),f=Math.log(256)/Math.log(u);function l(e){if("string"!==typeof e)throw new TypeError("Expected String");if(0===e.length)return n.alloc(0);for(var r=0,i=0,o=0;e[r]===s;)i++,r++;for(var a=(e.length-r)*c+1>>>0,f=new Uint8Array(a);e[r];){var l=t[e.charCodeAt(r)];if(255===l)return;for(var h=0,d=a-1;(0!==l||h<o)&&-1!==d;d--,h++)l+=u*f[d]>>>0,f[d]=l%256>>>0,l=l/256>>>0;if(0!==l)throw new Error("Non-zero carry");o=h,r++}for(var p=a-o;p!==a&&0===f[p];)p++;var b=n.allocUnsafe(i+(a-p));b.fill(0,0,i);for(var v=i;p!==a;)b[v++]=f[p++];return b}return{encode:function(t){if((Array.isArray(t)||t instanceof Uint8Array)&&(t=n.from(t)),!n.isBuffer(t))throw new TypeError("Expected Buffer");if(0===t.length)return"";for(var r=0,i=0,o=0,a=t.length;o!==a&&0===t[o];)o++,r++;for(var c=(a-o)*f+1>>>0,l=new Uint8Array(c);o!==a;){for(var h=t[o],d=0,p=c-1;(0!==h||d<i)&&-1!==p;p--,d++)h+=256*l[p]>>>0,l[p]=h%u>>>0,h=h/u>>>0;if(0!==h)throw new Error("Non-zero carry");i=d,o++}for(var b=c-i;b!==c&&0===l[b];)b++;for(var v=s.repeat(r);b<c;++b)v+=e.charAt(l[b]);return v},decodeUnsafe:l,decode:function(e){var t=l(e);if(t)return t;throw new Error("Non-base"+u+" character")}}}},function(e,t,r){var n=r(6),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function a(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=a),a.prototype=Object.create(i.prototype),o(i,a),a.from=function(e,t,r){if("number"===typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},a.alloc=function(e,t,r){if("number"!==typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"===typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},a.allocUnsafe=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return i(e)},a.allocUnsafeSlow=function(e){if("number"!==typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},function(e,t){e.exports=function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){var n=r(116),i=r(117),o=r(80),a=r(119);e.exports=function(e,t){return n(e)||i(e,t)||o(e,t)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e,t){var r=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,i,o=[],a=!0,u=!1;try{for(r=r.call(e);!(a=(n=r.next()).done)&&(o.push(n.value),!t||o.length!==t);a=!0);}catch(s){u=!0,i=s}finally{try{a||null==r.return||r.return()}finally{if(u)throw i}}return o}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){var n=r(46),i=r(69),o=r(121),a=r(122);function u(t){var r="function"===typeof Map?new Map:void 0;return e.exports=u=function(e){if(null===e||!o(e))return e;if("function"!==typeof e)throw new TypeError("Super expression must either be null or a function");if("undefined"!==typeof r){if(r.has(e))return r.get(e);r.set(e,t)}function t(){return a(e,arguments,n(this).constructor)}return t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i(t,e)},e.exports.__esModule=!0,e.exports.default=e.exports,u(t)}e.exports=u,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e){return-1!==Function.toString.call(e).indexOf("[native code]")},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){var n=r(69),i=r(81);function o(t,r,a){return i()?(e.exports=o=Reflect.construct,e.exports.__esModule=!0,e.exports.default=e.exports):(e.exports=o=function(e,t,r){var i=[null];i.push.apply(i,t);var o=new(Function.bind.apply(e,i));return r&&n(o,r.prototype),o},e.exports.__esModule=!0,e.exports.default=e.exports),o.apply(null,arguments)}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){"use strict";function n(e,t,r){return t<=e&&e<=r}function i(e){if(void 0===e)return{};if(e===Object(e))return e;throw TypeError("Could not convert argument to dictionary")}r.r(t),r.d(t,"TextEncoder",(function(){return f})),r.d(t,"TextDecoder",(function(){return c}));function o(e){this.tokens=[].slice.call(e)}o.prototype={endOfStream:function(){return!this.tokens.length},read:function(){return this.tokens.length?this.tokens.shift():-1},prepend:function(e){if(Array.isArray(e))for(var t=e;t.length;)this.tokens.unshift(t.pop());else this.tokens.unshift(e)},push:function(e){if(Array.isArray(e))for(var t=e;t.length;)this.tokens.push(t.shift());else this.tokens.push(e)}};var a=-1;function u(e,t){if(e)throw TypeError("Decoder error");return t||65533}var s="utf-8";function c(e,t){if(!(this instanceof c))return new c(e,t);if((e=void 0!==e?String(e).toLowerCase():s)!==s)throw new Error("Encoding not supported. Only utf-8 is supported");t=i(t),this._streaming=!1,this._BOMseen=!1,this._decoder=null,this._fatal=Boolean(t.fatal),this._ignoreBOM=Boolean(t.ignoreBOM),Object.defineProperty(this,"encoding",{value:"utf-8"}),Object.defineProperty(this,"fatal",{value:this._fatal}),Object.defineProperty(this,"ignoreBOM",{value:this._ignoreBOM})}function f(e,t){if(!(this instanceof f))return new f(e,t);if((e=void 0!==e?String(e).toLowerCase():s)!==s)throw new Error("Encoding not supported. Only utf-8 is supported");t=i(t),this._streaming=!1,this._encoder=null,this._options={fatal:Boolean(t.fatal)},Object.defineProperty(this,"encoding",{value:"utf-8"})}function l(e){var t=e.fatal,r=0,i=0,o=0,s=128,c=191;this.handler=function(e,f){if(-1===f&&0!==o)return o=0,u(t);if(-1===f)return a;if(0===o){if(n(f,0,127))return f;if(n(f,194,223))o=1,r=f-192;else if(n(f,224,239))224===f&&(s=160),237===f&&(c=159),o=2,r=f-224;else{if(!n(f,240,244))return u(t);240===f&&(s=144),244===f&&(c=143),o=3,r=f-240}return r<<=6*o,null}if(!n(f,s,c))return r=o=i=0,s=128,c=191,e.prepend(f),u(t);if(s=128,c=191,r+=f-128<<6*(o-(i+=1)),i!==o)return null;var l=r;return r=o=i=0,l}}function h(e){e.fatal;this.handler=function(e,t){if(-1===t)return a;if(n(t,0,127))return t;var r,i;n(t,128,2047)?(r=1,i=192):n(t,2048,65535)?(r=2,i=224):n(t,65536,1114111)&&(r=3,i=240);for(var o=[(t>>6*r)+i];r>0;){var u=t>>6*(r-1);o.push(128|63&u),r-=1}return o}}c.prototype={decode:function(e,t){var r;r="object"===typeof e&&e instanceof ArrayBuffer?new Uint8Array(e):"object"===typeof e&&"buffer"in e&&e.buffer instanceof ArrayBuffer?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(0),t=i(t),this._streaming||(this._decoder=new l({fatal:this._fatal}),this._BOMseen=!1),this._streaming=Boolean(t.stream);for(var n,u=new o(r),s=[];!u.endOfStream()&&(n=this._decoder.handler(u,u.read()))!==a;)null!==n&&(Array.isArray(n)?s.push.apply(s,n):s.push(n));if(!this._streaming){do{if((n=this._decoder.handler(u,u.read()))===a)break;null!==n&&(Array.isArray(n)?s.push.apply(s,n):s.push(n))}while(!u.endOfStream());this._decoder=null}return s.length&&(-1===["utf-8"].indexOf(this.encoding)||this._ignoreBOM||this._BOMseen||(65279===s[0]?(this._BOMseen=!0,s.shift()):this._BOMseen=!0)),function(e){for(var t="",r=0;r<e.length;++r){var n=e[r];n<=65535?t+=String.fromCharCode(n):(n-=65536,t+=String.fromCharCode(55296+(n>>10),56320+(1023&n)))}return t}(s)}},f.prototype={encode:function(e,t){e=e?String(e):"",t=i(t),this._streaming||(this._encoder=new h(this._options)),this._streaming=Boolean(t.stream);for(var r,n=[],u=new o(function(e){for(var t=String(e),r=t.length,n=0,i=[];n<r;){var o=t.charCodeAt(n);if(o<55296||o>57343)i.push(o);else if(56320<=o&&o<=57343)i.push(65533);else if(55296<=o&&o<=56319)if(n===r-1)i.push(65533);else{var a=e.charCodeAt(n+1);if(56320<=a&&a<=57343){var u=1023&o,s=1023&a;i.push(65536+(u<<10)+s),n+=1}else i.push(65533)}n+=1}return i}(e));!u.endOfStream()&&(r=this._encoder.handler(u,u.read()))!==a;)Array.isArray(r)?n.push.apply(n,r):n.push(r);if(!this._streaming){for(;(r=this._encoder.handler(u,u.read()))!==a;)Array.isArray(r)?n.push.apply(n,r):n.push(r);this._encoder=null}return new Uint8Array(n)}}},function(e,t,r){"use strict";var n=r(71);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return new f(e,t)};var i=n(r(40)),o=n(r(45)),a=n(r(41)),u=n(r(55)),s=n(r(46));function c(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,s.default)(e);if(t){var i=(0,s.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,u.default)(this,r)}}var f=function(e){(0,a.default)(r,e);var t=c(r);function r(e,n,o){var a;return(0,i.default)(this,r),(a=t.call(this)).socket=new window.WebSocket(e,o),a.socket.onopen=function(){return a.emit("open")},a.socket.onmessage=function(e){return a.emit("message",e.data)},a.socket.onerror=function(e){return a.emit("error",e)},a.socket.onclose=function(e){a.emit("close",e.code,e.reason)},a}return(0,o.default)(r,[{key:"send",value:function(e,t,r){var n=r||t;try{this.socket.send(e),n()}catch(i){n(i)}}},{key:"close",value:function(e,t){this.socket.close(e,t)}},{key:"addEventListener",value:function(e,t,r){this.socket.addEventListener(e,t,r)}}]),r}(r(42).EventEmitter)},function(e,t,r){"use strict";(function(e){var n=r(71);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(1)),o=n(r(126)),a=n(r(82)),u=n(r(40)),s=n(r(45)),c=n(r(41)),f=n(r(55)),l=n(r(46)),h=r(42),d=n(r(127));function p(e){var t=function(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var r,n=(0,l.default)(e);if(t){var i=(0,l.default)(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return(0,f.default)(this,r)}}var b=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]])}return r},v=function(t){(0,c.default)(n,t);var r=p(n);function n(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"ws://localhost:8080",o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=arguments.length>3?arguments[3]:void 0;(0,u.default)(this,n);var s=o.autoconnect,c=void 0===s||s,f=o.reconnect,l=void 0===f||f,h=o.reconnect_interval,d=void 0===h?1e3:h,p=o.max_reconnects,v=void 0===p?5:p,y=b(o,["autoconnect","reconnect","reconnect_interval","max_reconnects"]);return(t=r.call(this)).webSocketFactory=e,t.queue={},t.rpc_id=0,t.address=i,t.autoconnect=c,t.ready=!1,t.reconnect=l,t.reconnect_interval=d,t.max_reconnects=v,t.rest_options=y,t.current_reconnects=0,t.generate_request_id=a||function(){return++t.rpc_id},t.autoconnect&&t._connect(t.address,Object.assign({autoconnect:t.autoconnect,reconnect:t.reconnect,reconnect_interval:t.reconnect_interval,max_reconnects:t.max_reconnects},t.rest_options)),t}return(0,s.default)(n,[{key:"connect",value:function(){this.socket||this._connect(this.address,Object.assign({autoconnect:this.autoconnect,reconnect:this.reconnect,reconnect_interval:this.reconnect_interval,max_reconnects:this.max_reconnects},this.rest_options))}},{key:"call",value:function(e,t,r,n){var i=this;return n||"object"!==(0,a.default)(r)||(n=r,r=null),new Promise((function(o,a){if(!i.ready)return a(new Error("socket not ready"));var u=i.generate_request_id(e,t),s={jsonrpc:"2.0",method:e,params:t||null,id:u};i.socket.send(JSON.stringify(s),n,(function(e){if(e)return a(e);i.queue[u]={promise:[o,a]},r&&(i.queue[u].timeout=setTimeout((function(){delete i.queue[u],a(new Error("reply timeout"))}),r))}))}))}},{key:"login",value:function(){var e=(0,o.default)(i.default.mark((function e(t){var r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.call("rpc.login",t);case 2:if(r=e.sent){e.next=5;break}throw new Error("authentication failed");case 5:return e.abrupt("return",r);case 6:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"listMethods",value:function(){var e=(0,o.default)(i.default.mark((function e(){return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,this.call("__listMethods");case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e,this)})));return function(){return e.apply(this,arguments)}}()},{key:"notify",value:function(e,t){var r=this;return new Promise((function(n,i){if(!r.ready)return i(new Error("socket not ready"));var o={jsonrpc:"2.0",method:e,params:t||null};r.socket.send(JSON.stringify(o),(function(e){if(e)return i(e);n()}))}))}},{key:"subscribe",value:function(){var e=(0,o.default)(i.default.mark((function e(t){var r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return"string"===typeof t&&(t=[t]),e.next=3,this.call("rpc.on",t);case 3:if(r=e.sent,"string"!==typeof t||"ok"===r[t]){e.next=6;break}throw new Error("Failed subscribing to an event '"+t+"' with: "+r[t]);case 6:return e.abrupt("return",r);case 7:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"unsubscribe",value:function(){var e=(0,o.default)(i.default.mark((function e(t){var r;return i.default.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return"string"===typeof t&&(t=[t]),e.next=3,this.call("rpc.off",t);case 3:if(r=e.sent,"string"!==typeof t||"ok"===r[t]){e.next=6;break}throw new Error("Failed unsubscribing from an event with: "+r);case 6:return e.abrupt("return",r);case 7:case"end":return e.stop()}}),e,this)})));return function(t){return e.apply(this,arguments)}}()},{key:"close",value:function(e,t){this.socket.close(e||1e3,t)}},{key:"_connect",value:function(t,r){var n=this;this.socket=this.webSocketFactory(t,r),this.socket.addEventListener("open",(function(){n.ready=!0,n.emit("open"),n.current_reconnects=0})),this.socket.addEventListener("message",(function(t){var r=t.data;r instanceof ArrayBuffer&&(r=e.from(r).toString());try{r=d.default.parse(r)}catch(a){return}if(r.notification&&n.listeners(r.notification).length){if(!Object.keys(r.params).length)return n.emit(r.notification);var i=[r.notification];if(r.params.constructor===Object)i.push(r.params);else for(var o=0;o<r.params.length;o++)i.push(r.params[o]);return Promise.resolve().then((function(){n.emit.apply(n,i)}))}if(!n.queue[r.id])return r.method&&r.params?Promise.resolve().then((function(){n.emit(r.method,r.params)})):void 0;"error"in r==="result"in r&&n.queue[r.id].promise[1](new Error('Server response malformed. Response must include either "result" or "error", but not both.')),n.queue[r.id].timeout&&clearTimeout(n.queue[r.id].timeout),r.error?n.queue[r.id].promise[1](r.error):n.queue[r.id].promise[0](r.result),delete n.queue[r.id]})),this.socket.addEventListener("error",(function(e){return n.emit("error",e)})),this.socket.addEventListener("close",(function(e){var i=e.code,o=e.reason;n.ready&&setTimeout((function(){return n.emit("close",i,o)}),0),n.ready=!1,n.socket=void 0,1e3!==i&&(n.current_reconnects++,n.reconnect&&(n.max_reconnects>n.current_reconnects||0===n.max_reconnects)&&setTimeout((function(){return n._connect(t,r)}),n.reconnect_interval))}))}}]),n}(h.EventEmitter);t.default=v}).call(this,r(6).Buffer)},function(e,t){function r(e,t,r,n,i,o,a){try{var u=e[o](a),s=u.value}catch(c){return void r(c)}u.done?t(s):Promise.resolve(s).then(n,i)}e.exports=function(e){return function(){var t=this,n=arguments;return new Promise((function(i,o){var a=e.apply(t,n);function u(e){r(a,i,o,u,s,"next",e)}function s(e){r(a,i,o,u,s,"throw",e)}u(void 0)}))}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){var r="~",n="\\x"+("0"+r.charCodeAt(0).toString(16)).slice(-2),i="\\"+n,o=new RegExp(n,"g"),a=new RegExp(i,"g"),u=new RegExp("(?:^|([^\\\\]))"+i),s=[].indexOf||function(e){for(var t=this.length;t--&&this[t]!==e;);return t},c=String;function f(e,t,n){return t instanceof Array?function(e,t,r){for(var n=0,i=t.length;n<i;n++)t[n]=f(e,t[n],r);return t}(e,t,n):t instanceof c?t.length?n.hasOwnProperty(t)?n[t]:n[t]=function(e,t){for(var n=0,i=t.length;n<i;e=e[t[n++].replace(a,r)]);return e}(e,t.split(r)):e:t instanceof Object?function(e,t,r){for(var n in t)t.hasOwnProperty(n)&&(t[n]=f(e,t[n],r));return t}(e,t,n):t}var l={stringify:function(e,t,a,u){return l.parser.stringify(e,function(e,t,a){var u,c,f=!1,l=!!t,h=[],d=[e],p=[e],b=[a?r:"[Circular]"],v=e,y=1;return l&&(c="object"===typeof t?function(e,r){return""!==e&&t.indexOf(e)<0?void 0:r}:t),function(e,t){return l&&(t=c.call(this,e,t)),f?(v!==this&&(u=y-s.call(d,this)-1,y-=u,d.splice(y,d.length),h.splice(y-1,h.length),v=this),"object"===typeof t&&t?(s.call(d,t)<0&&d.push(v=t),y=d.length,(u=s.call(p,t))<0?(u=p.push(t)-1,a?(h.push((""+e).replace(o,n)),b[u]=r+h.join(r)):b[u]=b[0]):t=b[u]):"string"===typeof t&&a&&(t=t.replace(n,i).replace(r,n))):f=!0,t}}(e,t,!u),a)},parse:function(e,t){return l.parser.parse(e,function(e){return function(t,o){var a="string"===typeof o;return a&&o.charAt(0)===r?new c(o.slice(1)):(""===t&&(o=f(o,o,{})),a&&(o=o.replace(u,"$1~").replace(i,n)),e?e.call(this,t,o):o)}}(t))},parser:JSON};e.exports=l},function(e,t,r){"use strict";var n=r(94).v4;e.exports=function(e,t,r,i){if("string"!==typeof e)throw new TypeError(e+" must be a string");var o="number"===typeof(i=i||{}).version?i.version:2;if(1!==o&&2!==o)throw new TypeError(o+" must be 1 or 2");var a={method:e};if(2===o&&(a.jsonrpc="2.0"),t){if("object"!==typeof t&&!Array.isArray(t))throw new TypeError(t+" must be an object, array or omitted");a.params=t}if("undefined"===typeof r){var u="function"===typeof i.generator?i.generator:function(){return n()};a.id=u(a,i)}else 2===o&&null===r?i.notificationIdNull&&(a.id=null):a.id=r;return a}},function(e,t,r){var n=r(68).default,i="Impossible case. Please create issue.",o="The tweak was out of range or the resulted private key is invalid",a="The tweak was out of range or equal to zero",u="Unknow error on context randomization",s="Private Key is invalid",c="Public Key could not be parsed",f="Public Key serialization error",l="The sum of the public keys is not valid",h="Signature could not be parsed",d="The nonce generation function failed, or the private key was invalid",p="Public key could not be recover",b="Scalar was invalid (zero or overflow)";function v(e,t){if(!e)throw new Error(t)}function y(e,t,r){if(v(t instanceof Uint8Array,"Expected ".concat(e," to be an Uint8Array")),void 0!==r)if(Array.isArray(r)){var n=r.join(", "),i="Expected ".concat(e," to be an Uint8Array with length [").concat(n,"]");v(r.includes(t.length),i)}else{var o="Expected ".concat(e," to be an Uint8Array with length ").concat(r);v(t.length===r,o)}}function m(e){v("Boolean"===w(e),"Expected compressed to be a Boolean")}function g(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(e){return new Uint8Array(e)},t=arguments.length>1?arguments[1]:void 0;return"function"===typeof e&&(e=e(t)),y("output",e,t),e}function w(e){return Object.prototype.toString.call(e).slice(8,-1)}e.exports=function(e){return{contextRandomize:function(t){if(v(null===t||t instanceof Uint8Array,"Expected seed to be an Uint8Array or null"),null!==t&&y("seed",t,32),1===e.contextRandomize(t))throw new Error(u)},privateKeyVerify:function(t){return y("private key",t,32),0===e.privateKeyVerify(t)},privateKeyNegate:function(t){switch(y("private key",t,32),e.privateKeyNegate(t)){case 0:return t;case 1:throw new Error(i)}},privateKeyTweakAdd:function(t,r){switch(y("private key",t,32),y("tweak",r,32),e.privateKeyTweakAdd(t,r)){case 0:return t;case 1:throw new Error(o)}},privateKeyTweakMul:function(t,r){switch(y("private key",t,32),y("tweak",r,32),e.privateKeyTweakMul(t,r)){case 0:return t;case 1:throw new Error(a)}},publicKeyVerify:function(t){return y("public key",t,[33,65]),0===e.publicKeyVerify(t)},publicKeyCreate:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2?arguments[2]:void 0;switch(y("private key",t,32),m(r),n=g(n,r?33:65),e.publicKeyCreate(n,t)){case 0:return n;case 1:throw new Error(s);case 2:throw new Error(f)}},publicKeyConvert:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2?arguments[2]:void 0;switch(y("public key",t,[33,65]),m(r),n=g(n,r?33:65),e.publicKeyConvert(n,t)){case 0:return n;case 1:throw new Error(c);case 2:throw new Error(f)}},publicKeyNegate:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2?arguments[2]:void 0;switch(y("public key",t,[33,65]),m(r),n=g(n,r?33:65),e.publicKeyNegate(n,t)){case 0:return n;case 1:throw new Error(c);case 2:throw new Error(i);case 3:throw new Error(f)}},publicKeyCombine:function(t){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=arguments.length>2?arguments[2]:void 0;v(Array.isArray(t),"Expected public keys to be an Array"),v(t.length>0,"Expected public keys array will have more than zero items");var o,a=n(t);try{for(a.s();!(o=a.n()).done;){var u=o.value;y("public key",u,[33,65])}}catch(s){a.e(s)}finally{a.f()}switch(m(r),i=g(i,r?33:65),e.publicKeyCombine(i,t)){case 0:return i;case 1:throw new Error(c);case 2:throw new Error(l);case 3:throw new Error(f)}},publicKeyTweakAdd:function(t,r){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3?arguments[3]:void 0;switch(y("public key",t,[33,65]),y("tweak",r,32),m(n),i=g(i,n?33:65),e.publicKeyTweakAdd(i,t,r)){case 0:return i;case 1:throw new Error(c);case 2:throw new Error(o)}},publicKeyTweakMul:function(t,r){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3?arguments[3]:void 0;switch(y("public key",t,[33,65]),y("tweak",r,32),m(n),i=g(i,n?33:65),e.publicKeyTweakMul(i,t,r)){case 0:return i;case 1:throw new Error(c);case 2:throw new Error(a)}},signatureNormalize:function(t){switch(y("signature",t,64),e.signatureNormalize(t)){case 0:return t;case 1:throw new Error(h)}},signatureExport:function(t,r){y("signature",t,64);var n={output:r=g(r,72),outputlen:72};switch(e.signatureExport(n,t)){case 0:return r.slice(0,n.outputlen);case 1:throw new Error(h);case 2:throw new Error(i)}},signatureImport:function(t,r){switch(y("signature",t),r=g(r,64),e.signatureImport(r,t)){case 0:return r;case 1:throw new Error(h);case 2:throw new Error(i)}},ecdsaSign:function(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=arguments.length>3?arguments[3]:void 0;y("message",t,32),y("private key",r,32),v("Object"===w(n),"Expected options to be an Object"),void 0!==n.data&&y("options.data",n.data),void 0!==n.noncefn&&v("Function"===w(n.noncefn),"Expected options.noncefn to be a Function");var a={signature:o=g(o,64),recid:null};switch(e.ecdsaSign(a,t,r,n.data,n.noncefn)){case 0:return a;case 1:throw new Error(d);case 2:throw new Error(i)}},ecdsaVerify:function(t,r,n){switch(y("signature",t,64),y("message",r,32),y("public key",n,[33,65]),e.ecdsaVerify(t,r,n)){case 0:return!0;case 3:return!1;case 1:throw new Error(h);case 2:throw new Error(c)}},ecdsaRecover:function(t,r,n){var o=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],a=arguments.length>4?arguments[4]:void 0;switch(y("signature",t,64),v("Number"===w(r)&&r>=0&&r<=3,"Expected recovery id to be a Number within interval [0, 3]"),y("message",n,32),m(o),a=g(a,o?33:65),e.ecdsaRecover(a,t,r,n)){case 0:return a;case 1:throw new Error(h);case 2:throw new Error(p);case 3:throw new Error(i)}},ecdh:function(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3?arguments[3]:void 0;switch(y("public key",t,[33,65]),y("private key",r,32),v("Object"===w(n),"Expected options to be an Object"),void 0!==n.data&&y("options.data",n.data),void 0!==n.hashfn?(v("Function"===w(n.hashfn),"Expected options.hashfn to be a Function"),void 0!==n.xbuf&&y("options.xbuf",n.xbuf,32),void 0!==n.ybuf&&y("options.ybuf",n.ybuf,32),y("output",i)):i=g(i,32),e.ecdh(i,t,r,n.data,n.hashfn,n.xbuf,n.ybuf)){case 0:return i;case 1:throw new Error(c);case 2:throw new Error(b)}}}}},function(e,t,r){var n=new(0,r(131).ec)("secp256k1"),i=n.curve,o=i.n.constructor;function a(e){var t=e[0];switch(t){case 2:case 3:return 33!==e.length?null:function(e,t){var r=new o(t);if(r.cmp(i.p)>=0)return null;var a=(r=r.toRed(i.red)).redSqr().redIMul(r).redIAdd(i.b).redSqrt();return 3===e!==a.isOdd()&&(a=a.redNeg()),n.keyPair({pub:{x:r,y:a}})}(t,e.subarray(1,33));case 4:case 6:case 7:return 65!==e.length?null:function(e,t,r){var a=new o(t),u=new o(r);if(a.cmp(i.p)>=0||u.cmp(i.p)>=0)return null;if(a=a.toRed(i.red),u=u.toRed(i.red),(6===e||7===e)&&u.isOdd()!==(7===e))return null;var s=a.redSqr().redIMul(a);return u.redSqr().redISub(s.redIAdd(i.b)).isZero()?n.keyPair({pub:{x:a,y:u}}):null}(t,e.subarray(1,33),e.subarray(33,65));default:return null}}function u(e,t){for(var r=t.encode(null,33===e.length),n=0;n<e.length;++n)e[n]=r[n]}e.exports={contextRandomize:function(){return 0},privateKeyVerify:function(e){var t=new o(e);return t.cmp(i.n)<0&&!t.isZero()?0:1},privateKeyNegate:function(e){var t=new o(e),r=i.n.sub(t).umod(i.n).toArrayLike(Uint8Array,"be",32);return e.set(r),0},privateKeyTweakAdd:function(e,t){var r=new o(t);if(r.cmp(i.n)>=0)return 1;if(r.iadd(new o(e)),r.cmp(i.n)>=0&&r.isub(i.n),r.isZero())return 1;var n=r.toArrayLike(Uint8Array,"be",32);return e.set(n),0},privateKeyTweakMul:function(e,t){var r=new o(t);if(r.cmp(i.n)>=0||r.isZero())return 1;r.imul(new o(e)),r.cmp(i.n)>=0&&(r=r.umod(i.n));var n=r.toArrayLike(Uint8Array,"be",32);return e.set(n),0},publicKeyVerify:function(e){return null===a(e)?1:0},publicKeyCreate:function(e,t){var r=new o(t);return r.cmp(i.n)>=0||r.isZero()?1:(u(e,n.keyFromPrivate(t).getPublic()),0)},publicKeyConvert:function(e,t){var r=a(t);return null===r?1:(u(e,r.getPublic()),0)},publicKeyNegate:function(e,t){var r=a(t);if(null===r)return 1;var n=r.getPublic();return n.y=n.y.redNeg(),u(e,n),0},publicKeyCombine:function(e,t){for(var r=new Array(t.length),n=0;n<t.length;++n)if(r[n]=a(t[n]),null===r[n])return 1;for(var i=r[0].getPublic(),o=1;o<r.length;++o)i=i.add(r[o].pub);return i.isInfinity()?2:(u(e,i),0)},publicKeyTweakAdd:function(e,t,r){var n=a(t);if(null===n)return 1;if((r=new o(r)).cmp(i.n)>=0)return 2;var s=n.getPublic().add(i.g.mul(r));return s.isInfinity()?2:(u(e,s),0)},publicKeyTweakMul:function(e,t,r){var n=a(t);return null===n?1:(r=new o(r)).cmp(i.n)>=0||r.isZero()?2:(u(e,n.getPublic().mul(r)),0)},signatureNormalize:function(e){var t=new o(e.subarray(0,32)),r=new o(e.subarray(32,64));return t.cmp(i.n)>=0||r.cmp(i.n)>=0?1:(1===r.cmp(n.nh)&&e.set(i.n.sub(r).toArrayLike(Uint8Array,"be",32),32),0)},signatureExport:function(e,t){var r=t.subarray(0,32),n=t.subarray(32,64);if(new o(r).cmp(i.n)>=0)return 1;if(new o(n).cmp(i.n)>=0)return 1;var a=e.output,u=a.subarray(4,37);u[0]=0,u.set(r,1);for(var s=33,c=0;s>1&&0===u[c]&&!(128&u[c+1]);--s,++c);if(128&(u=u.subarray(c))[0])return 1;if(s>1&&0===u[0]&&!(128&u[1]))return 1;var f=a.subarray(39,72);f[0]=0,f.set(n,1);for(var l=33,h=0;l>1&&0===f[h]&&!(128&f[h+1]);--l,++h);return 128&(f=f.subarray(h))[0]||l>1&&0===f[0]&&!(128&f[1])?1:(e.outputlen=6+s+l,a[0]=48,a[1]=e.outputlen-2,a[2]=2,a[3]=u.length,a.set(u,4),a[4+s]=2,a[5+s]=f.length,a.set(f,6+s),0)},signatureImport:function(e,t){if(t.length<8)return 1;if(t.length>72)return 1;if(48!==t[0])return 1;if(t[1]!==t.length-2)return 1;if(2!==t[2])return 1;var r=t[3];if(0===r)return 1;if(5+r>=t.length)return 1;if(2!==t[4+r])return 1;var n=t[5+r];if(0===n)return 1;if(6+r+n!==t.length)return 1;if(128&t[4])return 1;if(r>1&&0===t[4]&&!(128&t[5]))return 1;if(128&t[r+6])return 1;if(n>1&&0===t[r+6]&&!(128&t[r+7]))return 1;var a=t.subarray(4,4+r);if(33===a.length&&0===a[0]&&(a=a.subarray(1)),a.length>32)return 1;var u=t.subarray(6+r);if(33===u.length&&0===u[0]&&(u=u.slice(1)),u.length>32)throw new Error("S length is too long");var s=new o(a);s.cmp(i.n)>=0&&(s=new o(0));var c=new o(t.subarray(6+r));return c.cmp(i.n)>=0&&(c=new o(0)),e.set(s.toArrayLike(Uint8Array,"be",32),0),e.set(c.toArrayLike(Uint8Array,"be",32),32),0},ecdsaSign:function(e,t,r,a,u){if(u){var s=u;u=function(e){var n=s(t,r,null,a,e);if(!(n instanceof Uint8Array&&32===n.length))throw new Error("This is the way");return new o(n)}}var c,f=new o(r);if(f.cmp(i.n)>=0||f.isZero())return 1;try{c=n.sign(t,r,{canonical:!0,k:u,pers:a})}catch(l){return 1}return e.signature.set(c.r.toArrayLike(Uint8Array,"be",32),0),e.signature.set(c.s.toArrayLike(Uint8Array,"be",32),32),e.recid=c.recoveryParam,0},ecdsaVerify:function(e,t,r){var u={r:e.subarray(0,32),s:e.subarray(32,64)},s=new o(u.r),c=new o(u.s);if(s.cmp(i.n)>=0||c.cmp(i.n)>=0)return 1;if(1===c.cmp(n.nh)||s.isZero()||c.isZero())return 3;var f=a(r);if(null===f)return 2;var l=f.getPublic();return n.verify(t,u,l)?0:3},ecdsaRecover:function(e,t,r,a){var s,c={r:t.slice(0,32),s:t.slice(32,64)},f=new o(c.r),l=new o(c.s);if(f.cmp(i.n)>=0||l.cmp(i.n)>=0)return 1;if(f.isZero()||l.isZero())return 2;try{s=n.recoverPubKey(a,c,r)}catch(h){return 2}return u(e,s),0},ecdh:function(e,t,r,u,s,c,f){var l=a(t);if(null===l)return 1;var h=new o(r);if(h.cmp(i.n)>=0||h.isZero())return 2;var d=l.getPublic().mul(h);if(void 0===s)for(var p=d.encode(null,!0),b=n.hash().update(p).digest(),v=0;v<32;++v)e[v]=b[v];else{c||(c=new Uint8Array(32));for(var y=d.getX().toArray("be",32),m=0;m<32;++m)c[m]=y[m];f||(f=new Uint8Array(32));for(var g=d.getY().toArray("be",32),w=0;w<32;++w)f[w]=g[w];var k=s(c,f,u);if(!(k instanceof Uint8Array&&k.length===e.length))return 2;e.set(k)}return 0}}},function(e,t,r){"use strict";var n=t;n.version=r(132).version,n.utils=r(21),n.rand=r(85),n.curve=r(86),n.curves=r(72),n.ec=r(145),n.eddsa=r(149)},function(e){e.exports=JSON.parse('{"_from":"elliptic@^6.5.4","_id":"elliptic@6.5.4","_inBundle":false,"_integrity":"sha1-2jfOvTHnmhNn6UG1ku0fvr1Yq7s=","_location":"/elliptic","_phantomChildren":{},"_requested":{"type":"range","registry":true,"raw":"elliptic@^6.5.4","name":"elliptic","escapedName":"elliptic","rawSpec":"^6.5.4","saveSpec":null,"fetchSpec":"^6.5.4"},"_requiredBy":["/browserify-sign","/create-ecdh","/secp256k1"],"_resolved":"https://registry.nlark.com/elliptic/download/elliptic-6.5.4.tgz","_shasum":"da37cebd31e79a1367e941b592ed1fbebd58abbb","_spec":"elliptic@^6.5.4","_where":"E:\\\\workspace_web3\\\\buildspace\\\\build_a_web3_app_with_solidity\\\\gif-portal-starter\\\\node_modules\\\\secp256k1","author":{"name":"Fedor Indutny","email":"fedor@indutny.com"},"bugs":{"url":"https://github.com/indutny/elliptic/issues"},"bundleDependencies":false,"dependencies":{"bn.js":"^4.11.9","brorand":"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1","inherits":"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"},"deprecated":false,"description":"EC cryptography","devDependencies":{"brfs":"^2.0.2","coveralls":"^3.1.0","eslint":"^7.6.0","grunt":"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1","istanbul":"^0.4.5","mocha":"^8.0.1"},"files":["lib"],"homepage":"https://github.com/indutny/elliptic","keywords":["EC","Elliptic","curve","Cryptography"],"license":"MIT","main":"lib/elliptic.js","name":"elliptic","repository":{"type":"git","url":"git+ssh://git@github.com/indutny/elliptic.git"},"scripts":{"lint":"eslint lib test","lint:fix":"npm run lint -- --fix","test":"npm run lint && npm run unit","unit":"istanbul test _mocha --reporter=spec test/index.js","version":"grunt dist && git add dist/"},"version":"6.5.4"}')},,,function(e,t,r){"use strict";var n=r(21),i=r(26),o=r(57),a=r(56),u=n.assert;function s(e){a.call(this,"short",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function c(e,t,r,n){a.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new i(t,16),this.y=new i(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function f(e,t,r,n){a.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new i(0)):(this.x=new i(t,16),this.y=new i(r,16),this.z=new i(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}o(s,a),e.exports=s,s.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new i(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new i(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],u(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new i(e.a,16),b:new i(e.b,16)}})):this._getEndoBasis(r)}}},s.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:i.mont(e),r=new i(2).toRed(t).redInvm(),n=r.redNeg(),o=new i(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(o).fromRed(),n.redSub(o).fromRed()]},s.prototype._getEndoBasis=function(e){for(var t,r,n,o,a,u,s,c,f,l=this.n.ushrn(Math.floor(this.n.bitLength()/2)),h=e,d=this.n.clone(),p=new i(1),b=new i(0),v=new i(0),y=new i(1),m=0;0!==h.cmpn(0);){var g=d.div(h);c=d.sub(g.mul(h)),f=v.sub(g.mul(p));var w=y.sub(g.mul(b));if(!n&&c.cmp(l)<0)t=s.neg(),r=p,n=c.neg(),o=f;else if(n&&2===++m)break;s=c,d=h,h=c,v=p,p=f,y=b,b=w}a=c.neg(),u=f;var k=n.sqr().add(o.sqr());return a.sqr().add(u.sqr()).cmp(k)>=0&&(a=t,u=r),n.negative&&(n=n.neg(),o=o.neg()),a.negative&&(a=a.neg(),u=u.neg()),[{a:n,b:o},{a:a,b:u}]},s.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),a=i.mul(r.a),u=o.mul(n.a),s=i.mul(r.b),c=o.mul(n.b);return{k1:e.sub(a).sub(u),k2:s.add(c).neg()}},s.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=n.fromRed().isOdd();return(t&&!o||!t&&o)&&(n=n.redNeg()),this.point(e,n)},s.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},s.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o<e.length;o++){var a=this._endoSplit(t[o]),u=e[o],s=u._getBeta();a.k1.negative&&(a.k1.ineg(),u=u.neg(!0)),a.k2.negative&&(a.k2.ineg(),s=s.neg(!0)),n[2*o]=u,n[2*o+1]=s,i[2*o]=a.k1,i[2*o+1]=a.k2}for(var c=this._wnafMulAdd(1,n,i,2*o,r),f=0;f<2*o;f++)n[f]=null,i[f]=null;return c},o(c,a.BasePoint),s.prototype.point=function(e,t,r){return new c(this,e,t,r)},s.prototype.pointFromJSON=function(e,t){return c.fromJSON(this,e,t)},c.prototype._getBeta=function(){if(this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var t=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var r=this.curve,n=function(e){return r.point(e.x.redMul(r.endo.beta),e.y)};e.beta=t,t.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(n)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(n)}}}return t}},c.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},c.fromJSON=function(e,t,r){"string"===typeof t&&(t=JSON.parse(t));var n=e.point(t[0],t[1],r);if(!t[2])return n;function i(t){return e.point(t[0],t[1],r)}var o=t[2];return n.precomputed={beta:null,doubles:o.doubles&&{step:o.doubles.step,points:[n].concat(o.doubles.points.map(i))},naf:o.naf&&{wnd:o.naf.wnd,points:[n].concat(o.naf.points.map(i))}},n},c.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},c.prototype.isInfinity=function(){return this.inf},c.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},c.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),a=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},c.prototype.getX=function(){return this.x.fromRed()},c.prototype.getY=function(){return this.y.fromRed()},c.prototype.mul=function(e){return e=new i(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},c.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},c.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},c.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},c.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(f,a.BasePoint),s.prototype.jpoint=function(e,t,r){return new f(this,e,t,r)},f.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},f.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},f.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),a=e.y.redMul(r.redMul(this.z)),u=n.redSub(i),s=o.redSub(a);if(0===u.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=u.redSqr(),f=c.redMul(u),l=n.redMul(c),h=s.redSqr().redIAdd(f).redISub(l).redISub(l),d=s.redMul(l.redISub(h)).redISub(o.redMul(f)),p=this.z.redMul(e.z).redMul(u);return this.curve.jpoint(h,d,p)},f.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),a=r.redSub(n),u=i.redSub(o);if(0===a.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var s=a.redSqr(),c=s.redMul(a),f=r.redMul(s),l=u.redSqr().redIAdd(c).redISub(f).redISub(f),h=u.redMul(f.redISub(l)).redISub(i.redMul(c)),d=this.z.redMul(a);return this.curve.jpoint(l,h,d)},f.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t<e;t++)r=r.dbl();return r}var n=this.curve.a,i=this.curve.tinv,o=this.x,a=this.y,u=this.z,s=u.redSqr().redSqr(),c=a.redAdd(a);for(t=0;t<e;t++){var f=o.redSqr(),l=c.redSqr(),h=l.redSqr(),d=f.redAdd(f).redIAdd(f).redIAdd(n.redMul(s)),p=o.redMul(l),b=d.redSqr().redISub(p.redAdd(p)),v=p.redISub(b),y=d.redMul(v);y=y.redIAdd(y).redISub(h);var m=c.redMul(u);t+1<e&&(s=s.redMul(h)),o=b,u=m,c=y}return this.curve.jpoint(o,c.redMul(i),u)},f.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},f.prototype._zeroDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),o=i.redSqr(),a=this.x.redAdd(i).redSqr().redISub(n).redISub(o);a=a.redIAdd(a);var u=n.redAdd(n).redIAdd(n),s=u.redSqr().redISub(a).redISub(a),c=o.redIAdd(o);c=(c=c.redIAdd(c)).redIAdd(c),e=s,t=u.redMul(a.redISub(s)).redISub(c),r=this.y.redAdd(this.y)}else{var f=this.x.redSqr(),l=this.y.redSqr(),h=l.redSqr(),d=this.x.redAdd(l).redSqr().redISub(f).redISub(h);d=d.redIAdd(d);var p=f.redAdd(f).redIAdd(f),b=p.redSqr(),v=h.redIAdd(h);v=(v=v.redIAdd(v)).redIAdd(v),e=b.redISub(d).redISub(d),t=p.redMul(d.redISub(e)).redISub(v),r=(r=this.y.redMul(this.z)).redIAdd(r)}return this.curve.jpoint(e,t,r)},f.prototype._threeDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),o=i.redSqr(),a=this.x.redAdd(i).redSqr().redISub(n).redISub(o);a=a.redIAdd(a);var u=n.redAdd(n).redIAdd(n).redIAdd(this.curve.a),s=u.redSqr().redISub(a).redISub(a);e=s;var c=o.redIAdd(o);c=(c=c.redIAdd(c)).redIAdd(c),t=u.redMul(a.redISub(s)).redISub(c),r=this.y.redAdd(this.y)}else{var f=this.z.redSqr(),l=this.y.redSqr(),h=this.x.redMul(l),d=this.x.redSub(f).redMul(this.x.redAdd(f));d=d.redAdd(d).redIAdd(d);var p=h.redIAdd(h),b=(p=p.redIAdd(p)).redAdd(p);e=d.redSqr().redISub(b),r=this.y.redAdd(this.z).redSqr().redISub(l).redISub(f);var v=l.redSqr();v=(v=(v=v.redIAdd(v)).redIAdd(v)).redIAdd(v),t=d.redMul(p.redISub(e)).redISub(v)}return this.curve.jpoint(e,t,r)},f.prototype._dbl=function(){var e=this.curve.a,t=this.x,r=this.y,n=this.z,i=n.redSqr().redSqr(),o=t.redSqr(),a=r.redSqr(),u=o.redAdd(o).redIAdd(o).redIAdd(e.redMul(i)),s=t.redAdd(t),c=(s=s.redIAdd(s)).redMul(a),f=u.redSqr().redISub(c.redAdd(c)),l=c.redISub(f),h=a.redSqr();h=(h=(h=h.redIAdd(h)).redIAdd(h)).redIAdd(h);var d=u.redMul(l).redISub(h),p=r.redAdd(r).redMul(n);return this.curve.jpoint(f,d,p)},f.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr(),n=t.redSqr(),i=e.redAdd(e).redIAdd(e),o=i.redSqr(),a=this.x.redAdd(t).redSqr().redISub(e).redISub(n),u=(a=(a=(a=a.redIAdd(a)).redAdd(a).redIAdd(a)).redISub(o)).redSqr(),s=n.redIAdd(n);s=(s=(s=s.redIAdd(s)).redIAdd(s)).redIAdd(s);var c=i.redIAdd(a).redSqr().redISub(o).redISub(u).redISub(s),f=t.redMul(c);f=(f=f.redIAdd(f)).redIAdd(f);var l=this.x.redMul(u).redISub(f);l=(l=l.redIAdd(l)).redIAdd(l);var h=this.y.redMul(c.redMul(s.redISub(c)).redISub(a.redMul(u)));h=(h=(h=h.redIAdd(h)).redIAdd(h)).redIAdd(h);var d=this.z.redAdd(a).redSqr().redISub(r).redISub(u);return this.curve.jpoint(l,h,d)},f.prototype.mul=function(e,t){return e=new i(e,t),this.curve._wnafMul(this,e)},f.prototype.eq=function(e){if("affine"===e.type)return this.eq(e.toJ());if(this===e)return!0;var t=this.z.redSqr(),r=e.z.redSqr();if(0!==this.x.redMul(r).redISub(e.x.redMul(t)).cmpn(0))return!1;var n=t.redMul(this.z),i=r.redMul(e.z);return 0===this.y.redMul(i).redISub(e.y.redMul(n)).cmpn(0)},f.prototype.eqXToP=function(e){var t=this.z.redSqr(),r=e.toRed(this.curve.red).redMul(t);if(0===this.x.cmp(r))return!0;for(var n=e.clone(),i=this.curve.redN.redMul(t);;){if(n.iadd(this.curve.n),n.cmp(this.curve.p)>=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},f.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},f.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},function(e,t,r){"use strict";var n=r(26),i=r(57),o=r(56),a=r(21);function u(e){o.call(this,"mont",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.i4=new n(4).toRed(this.red).redInvm(),this.two=new n(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function s(e,t,r){o.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new n(t,16),this.z=new n(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}i(u,o),e.exports=u,u.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===n.redSqrt().redSqr().cmp(n)},i(s,o.BasePoint),u.prototype.decodePoint=function(e,t){return this.point(a.toArray(e,t),1)},u.prototype.point=function(e,t){return new s(this,e,t)},u.prototype.pointFromJSON=function(e){return s.fromJSON(this,e)},s.prototype.precompute=function(){},s.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},s.fromJSON=function(e,t){return new s(e,t[0],t[1]||e.one)},s.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},s.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},s.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),n=e.redMul(t),i=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(n,i)},s.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},s.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),o=e.x.redSub(e.z).redMul(r),a=i.redMul(n),u=t.z.redMul(o.redAdd(a).redSqr()),s=t.x.redMul(o.redISub(a).redSqr());return this.curve.point(u,s)},s.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=[];0!==t.cmpn(0);t.iushrn(1))i.push(t.andln(1));for(var o=i.length-1;o>=0;o--)0===i[o]?(r=r.diffAdd(n,this),n=n.dbl()):(n=r.diffAdd(n,this),r=r.dbl());return n},s.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},s.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},s.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},s.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},s.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},function(e,t,r){"use strict";var n=r(21),i=r(26),o=r(57),a=r(56),u=n.assert;function s(e){this.twisted=1!==(0|e.a),this.mOneA=this.twisted&&-1===(0|e.a),this.extended=this.mOneA,a.call(this,"edwards",e),this.a=new i(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new i(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new i(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),u(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1===(0|e.c)}function c(e,t,r,n,o){a.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===n?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new i(t,16),this.y=new i(r,16),this.z=n?new i(n,16):this.curve.one,this.t=o&&new i(o,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}o(s,a),e.exports=s,s.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},s.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},s.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},s.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=n.redMul(o.redInvm()),u=a.redSqrt();if(0!==u.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");var s=u.fromRed().isOdd();return(t&&!s||!t&&s)&&(u=u.redNeg()),this.point(e,u)},s.prototype.pointFromY=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=n.redMul(o.redInvm());if(0===a.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var u=a.redSqrt();if(0!==u.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");return u.fromRed().isOdd()!==t&&(u=u.redNeg()),this.point(u,e)},s.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===n.cmp(i)},o(c,a.BasePoint),s.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},s.prototype.point=function(e,t,r,n){return new c(this,e,t,r,n)},c.fromJSON=function(e,t){return new c(e,t[0],t[1],t[2])},c.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},c.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},c.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),o=n.redAdd(t),a=o.redSub(r),u=n.redSub(t),s=i.redMul(a),c=o.redMul(u),f=i.redMul(u),l=a.redMul(o);return this.curve.point(s,c,l,f)},c.prototype._projDbl=function(){var e,t,r,n,i,o,a=this.x.redAdd(this.y).redSqr(),u=this.x.redSqr(),s=this.y.redSqr();if(this.curve.twisted){var c=(n=this.curve._mulA(u)).redAdd(s);this.zOne?(e=a.redSub(u).redSub(s).redMul(c.redSub(this.curve.two)),t=c.redMul(n.redSub(s)),r=c.redSqr().redSub(c).redSub(c)):(i=this.z.redSqr(),o=c.redSub(i).redISub(i),e=a.redSub(u).redISub(s).redMul(o),t=c.redMul(n.redSub(s)),r=c.redMul(o))}else n=u.redAdd(s),i=this.curve._mulC(this.z).redSqr(),o=n.redSub(i).redSub(i),e=this.curve._mulC(a.redISub(n)).redMul(o),t=this.curve._mulC(n).redMul(u.redISub(s)),r=n.redMul(o);return this.curve.point(e,t,r)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},c.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),o=r.redSub(t),a=i.redSub(n),u=i.redAdd(n),s=r.redAdd(t),c=o.redMul(a),f=u.redMul(s),l=o.redMul(s),h=a.redMul(u);return this.curve.point(c,f,h,l)},c.prototype._projAdd=function(e){var t,r,n=this.z.redMul(e.z),i=n.redSqr(),o=this.x.redMul(e.x),a=this.y.redMul(e.y),u=this.curve.d.redMul(o).redMul(a),s=i.redSub(u),c=i.redAdd(u),f=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(o).redISub(a),l=n.redMul(s).redMul(f);return this.curve.twisted?(t=n.redMul(c).redMul(a.redSub(this.curve._mulA(o))),r=s.redMul(c)):(t=n.redMul(c).redMul(a.redSub(o)),r=this.curve._mulC(s).redMul(c)),this.curve.point(l,t,r)},c.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},c.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},c.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},c.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},c.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()},c.prototype.getY=function(){return this.normalize(),this.y.fromRed()},c.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},c.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(n),0===this.x.cmp(t))return!0}},c.prototype.toP=c.prototype.normalize,c.prototype.mixedAdd=c.prototype.add},function(e,t,r){"use strict";t.sha1=r(139),t.sha224=r(140),t.sha256=r(88),t.sha384=r(141),t.sha512=r(89)},function(e,t,r){"use strict";var n=r(22),i=r(47),o=r(87),a=n.rotl32,u=n.sum32,s=n.sum32_5,c=o.ft_1,f=i.BlockHash,l=[1518500249,1859775393,2400959708,3395469782];function h(){if(!(this instanceof h))return new h;f.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}n.inherits(h,f),e.exports=h,h.blockSize=512,h.outSize=160,h.hmacStrength=80,h.padLength=64,h.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=a(r[n-3]^r[n-8]^r[n-14]^r[n-16],1);var i=this.h[0],o=this.h[1],f=this.h[2],h=this.h[3],d=this.h[4];for(n=0;n<r.length;n++){var p=~~(n/20),b=s(a(i,5),c(p,o,f,h),d,r[n],l[p]);d=h,h=f,f=a(o,30),o=i,i=b}this.h[0]=u(this.h[0],i),this.h[1]=u(this.h[1],o),this.h[2]=u(this.h[2],f),this.h[3]=u(this.h[3],h),this.h[4]=u(this.h[4],d)},h.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},function(e,t,r){"use strict";var n=r(22),i=r(88);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,7),"big"):n.split32(this.h.slice(0,7),"big")}},function(e,t,r){"use strict";var n=r(22),i=r(89);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}n.inherits(o,i),e.exports=o,o.blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,12),"big"):n.split32(this.h.slice(0,12),"big")}},function(e,t,r){"use strict";var n=r(22),i=r(47),o=n.rotl32,a=n.sum32,u=n.sum32_3,s=n.sum32_4,c=i.BlockHash;function f(){if(!(this instanceof f))return new f;c.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function l(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function h(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function d(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}n.inherits(f,c),t.ripemd160=f,f.blockSize=512,f.outSize=160,f.hmacStrength=192,f.padLength=64,f.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],c=this.h[3],f=this.h[4],m=r,g=n,w=i,k=c,_=f,x=0;x<80;x++){var S=a(o(s(r,l(x,n,i,c),e[p[x]+t],h(x)),v[x]),f);r=f,f=c,c=o(i,10),i=n,n=S,S=a(o(s(m,l(79-x,g,w,k),e[b[x]+t],d(x)),y[x]),_),m=_,_=k,k=o(w,10),w=g,g=S}S=u(this.h[1],i,k),this.h[1]=u(this.h[2],c,_),this.h[2]=u(this.h[3],f,m),this.h[3]=u(this.h[4],r,g),this.h[4]=u(this.h[0],n,w),this.h[0]=S},f.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"little"):n.split32(this.h,"little")};var p=[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],b=[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],v=[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],y=[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]},function(e,t,r){"use strict";var n=r(22),i=r(34);function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(n.toArray(t,r))}e.exports=o,o.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t<this.blockSize;t++)e.push(0);for(t=0;t<e.length;t++)e[t]^=54;for(this.inner=(new this.Hash).update(e),t=0;t<e.length;t++)e[t]^=106;this.outer=(new this.Hash).update(e)},o.prototype.update=function(e,t){return this.inner.update(e,t),this},o.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)}},function(e,t){e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},function(e,t,r){"use strict";var n=r(26),i=r(146),o=r(21),a=r(72),u=r(85),s=o.assert,c=r(147),f=r(148);function l(e){if(!(this instanceof l))return new l(e);"string"===typeof e&&(s(Object.prototype.hasOwnProperty.call(a,e),"Unknown curve "+e),e=a[e]),e instanceof a.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=l,l.prototype.keyPair=function(e){return new c(this,e)},l.prototype.keyFromPrivate=function(e,t){return c.fromPrivate(this,e,t)},l.prototype.keyFromPublic=function(e,t){return c.fromPublic(this,e,t)},l.prototype.genKeyPair=function(e){e||(e={});for(var t=new i({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||u(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),o=this.n.sub(new n(2));;){var a=new n(t.generate(r));if(!(a.cmp(o)>0))return a.iaddn(1),this.keyFromPrivate(a)}},l.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},l.prototype.sign=function(e,t,r,o){"object"===typeof r&&(o=r,r=null),o||(o={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new n(e,16));for(var a=this.n.byteLength(),u=t.getPrivate().toArray("be",a),s=e.toArray("be",a),c=new i({hash:this.hash,entropy:u,nonce:s,pers:o.pers,persEnc:o.persEnc||"utf8"}),l=this.n.sub(new n(1)),h=0;;h++){var d=o.k?o.k(h):new n(c.generate(this.n.byteLength()));if(!((d=this._truncateToN(d,!0)).cmpn(1)<=0||d.cmp(l)>=0)){var p=this.g.mul(d);if(!p.isInfinity()){var b=p.getX(),v=b.umod(this.n);if(0!==v.cmpn(0)){var y=d.invm(this.n).mul(v.mul(t.getPrivate()).iadd(e));if(0!==(y=y.umod(this.n)).cmpn(0)){var m=(p.getY().isOdd()?1:0)|(0!==b.cmp(v)?2:0);return o.canonical&&y.cmp(this.nh)>0&&(y=this.n.sub(y),m^=1),new f({r:v,s:y,recoveryParam:m})}}}}}},l.prototype.verify=function(e,t,r,i){e=this._truncateToN(new n(e,16)),r=this.keyFromPublic(r,i);var o=(t=new f(t,"hex")).r,a=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var u,s=a.invm(this.n),c=s.mul(e).umod(this.n),l=s.mul(o).umod(this.n);return this.curve._maxwellTrick?!(u=this.g.jmulAdd(c,r.getPublic(),l)).isInfinity()&&u.eqXToP(o):!(u=this.g.mulAdd(c,r.getPublic(),l)).isInfinity()&&0===u.getX().umod(this.n).cmp(o)},l.prototype.recoverPubKey=function(e,t,r,i){s((3&r)===r,"The recovery param is more than two bits"),t=new f(t,i);var o=this.n,a=new n(e),u=t.r,c=t.s,l=1&r,h=r>>1;if(u.cmp(this.curve.p.umod(this.curve.n))>=0&&h)throw new Error("Unable to find sencond key candinate");u=h?this.curve.pointFromX(u.add(this.curve.n),l):this.curve.pointFromX(u,l);var d=t.r.invm(o),p=o.sub(a).mul(d).umod(o),b=c.mul(d).umod(o);return this.g.mulAdd(p,u,b)},l.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new f(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")}},function(e,t,r){"use strict";var n=r(73),i=r(84),o=r(34);function a(e){if(!(this instanceof a))return new a(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=i.toArray(e.entropy,e.entropyEnc||"hex"),r=i.toArray(e.nonce,e.nonceEnc||"hex"),n=i.toArray(e.pers,e.persEnc||"hex");o(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}e.exports=a,a.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i<this.V.length;i++)this.K[i]=0,this.V[i]=1;this._update(n),this._reseed=1,this.reseedInterval=281474976710656},a.prototype._hmac=function(){return new n.hmac(this.hash,this.K)},a.prototype._update=function(e){var t=this._hmac().update(this.V).update([0]);e&&(t=t.update(e)),this.K=t.digest(),this.V=this._hmac().update(this.V).digest(),e&&(this.K=this._hmac().update(this.V).update([1]).update(e).digest(),this.V=this._hmac().update(this.V).digest())},a.prototype.reseed=function(e,t,r,n){"string"!==typeof t&&(n=r,r=t,t=null),e=i.toArray(e,t),r=i.toArray(r,n),o(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},a.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!==typeof t&&(n=r,r=t,t=null),r&&(r=i.toArray(r,n||"hex"),this._update(r));for(var o=[];o.length<e;)this.V=this._hmac().update(this.V).digest(),o=o.concat(this.V);var a=o.slice(0,e);return this._update(r),this._reseed++,i.encode(a,t)}},function(e,t,r){"use strict";var n=r(26),i=r(21).assert;function o(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=o,o.fromPublic=function(e,t,r){return t instanceof o?t:new o(e,{pub:t,pubEnc:r})},o.fromPrivate=function(e,t,r){return t instanceof o?t:new o(e,{priv:t,privEnc:r})},o.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},o.prototype.getPublic=function(e,t){return"string"===typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},o.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},o.prototype._importPrivate=function(e,t){this.priv=new n(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},o.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?i(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||i(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},o.prototype.derive=function(e){return e.validate()||i(e.validate(),"public point not validated"),e.mul(this.priv).getX()},o.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},o.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},o.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}},function(e,t,r){"use strict";var n=r(26),i=r(21),o=i.assert;function a(e,t){if(e instanceof a)return e;this._importDER(e,t)||(o(e.r&&e.s,"Signature without r or s"),this.r=new n(e.r,16),this.s=new n(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function u(){this.place=0}function s(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var i=0,o=0,a=t.place;o<n;o++,a++)i<<=8,i|=e[a],i>>>=0;return!(i<=127)&&(t.place=a,i)}function c(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t<r;)t++;return 0===t?e:e.slice(t)}function f(e,t){if(t<128)e.push(t);else{var r=1+(Math.log(t)/Math.LN2>>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}e.exports=a,a.prototype._importDER=function(e,t){e=i.toArray(e,t);var r=new u;if(48!==e[r.place++])return!1;var o=s(e,r);if(!1===o)return!1;if(o+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var a=s(e,r);if(!1===a)return!1;var c=e.slice(r.place,a+r.place);if(r.place+=a,2!==e[r.place++])return!1;var f=s(e,r);if(!1===f)return!1;if(e.length!==f+r.place)return!1;var l=e.slice(r.place,f+r.place);if(0===c[0]){if(!(128&c[1]))return!1;c=c.slice(1)}if(0===l[0]){if(!(128&l[1]))return!1;l=l.slice(1)}return this.r=new n(c),this.s=new n(l),this.recoveryParam=null,!0},a.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=c(t),r=c(r);!r[0]&&!(128&r[1]);)r=r.slice(1);var n=[2];f(n,t.length),(n=n.concat(t)).push(2),f(n,r.length);var o=n.concat(r),a=[48];return f(a,o.length),a=a.concat(o),i.encode(a,e)}},function(e,t,r){"use strict";var n=r(73),i=r(72),o=r(21),a=o.assert,u=o.parseBytes,s=r(150),c=r(151);function f(e){if(a("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof f))return new f(e);e=i[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=n.sha512}e.exports=f,f.prototype.sign=function(e,t){e=u(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),o=this.encodePoint(i),a=this.hashInt(o,r.pubBytes(),e).mul(r.priv()),s=n.add(a).umod(this.curve.n);return this.makeSignature({R:i,S:s,Rencoded:o})},f.prototype.verify=function(e,t,r){e=u(e),t=this.makeSignature(t);var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),o=this.g.mul(t.S());return t.R().add(n.pub().mul(i)).eq(o)},f.prototype.hashInt=function(){for(var e=this.hash(),t=0;t<arguments.length;t++)e.update(arguments[t]);return o.intFromLE(e.digest()).umod(this.curve.n)},f.prototype.keyFromPublic=function(e){return s.fromPublic(this,e)},f.prototype.keyFromSecret=function(e){return s.fromSecret(this,e)},f.prototype.makeSignature=function(e){return e instanceof c?e:new c(this,e)},f.prototype.encodePoint=function(e){var t=e.getY().toArray("le",this.encodingLength);return t[this.encodingLength-1]|=e.getX().isOdd()?128:0,t},f.prototype.decodePoint=function(e){var t=(e=o.parseBytes(e)).length-1,r=e.slice(0,t).concat(-129&e[t]),n=0!==(128&e[t]),i=o.intFromLE(r);return this.curve.pointFromY(i,n)},f.prototype.encodeInt=function(e){return e.toArray("le",this.encodingLength)},f.prototype.decodeInt=function(e){return o.intFromLE(e)},f.prototype.isPoint=function(e){return e instanceof this.pointClass}},function(e,t,r){"use strict";var n=r(21),i=n.assert,o=n.parseBytes,a=n.cachedProperty;function u(e,t){this.eddsa=e,this._secret=o(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=o(t.pub)}u.fromPublic=function(e,t){return t instanceof u?t:new u(e,{pub:t})},u.fromSecret=function(e,t){return t instanceof u?t:new u(e,{secret:t})},u.prototype.secret=function(){return this._secret},a(u,"pubBytes",(function(){return this.eddsa.encodePoint(this.pub())})),a(u,"pub",(function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())})),a(u,"privBytes",(function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n})),a(u,"priv",(function(){return this.eddsa.decodeInt(this.privBytes())})),a(u,"hash",(function(){return this.eddsa.hash().update(this.secret()).digest()})),a(u,"messagePrefix",(function(){return this.hash().slice(this.eddsa.encodingLength)})),u.prototype.sign=function(e){return i(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},u.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},u.prototype.getSecret=function(e){return i(this._secret,"KeyPair is public only"),n.encode(this.secret(),e)},u.prototype.getPublic=function(e){return n.encode(this.pubBytes(),e)},e.exports=u},function(e,t,r){"use strict";var n=r(26),i=r(21),o=i.assert,a=i.cachedProperty,u=i.parseBytes;function s(e,t){this.eddsa=e,"object"!==typeof t&&(t=u(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),o(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof n&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}a(s,"S",(function(){return this.eddsa.decodeInt(this.Sencoded())})),a(s,"R",(function(){return this.eddsa.decodePoint(this.Rencoded())})),a(s,"Rencoded",(function(){return this.eddsa.encodePoint(this.R())})),a(s,"Sencoded",(function(){return this.eddsa.encodeInt(this.S())})),s.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},s.prototype.toHex=function(){return i.encode(this.toBytes(),"hex").toUpperCase()},e.exports=s},function(e,t){e.exports=function(){function e(e,t,r,n,i,o){this.message=e,this.expected=t,this.found=r,this.offset=n,this.line=i,this.column=o,this.name="SyntaxError"}return function(e,t){function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r}(e,Error),{SyntaxError:e,parse:function(t){var r,n=arguments.length>1?arguments[1]:{},i={},o={start:Tt},a=Tt,u=function(){return jr},s=i,c="#",f={type:"literal",value:"#",description:'"#"'},l=void 0,h={type:"any",description:"any character"},d="[",p={type:"literal",value:"[",description:'"["'},b="]",v={type:"literal",value:"]",description:'"]"'},y=function(e){Pr(Rr("ObjectPath",e,jt,It))},m=function(e){Pr(Rr("ArrayPath",e,jt,It))},g=function(e,t){return e.concat(t)},w=function(e){return[e]},k=function(e){return e},_=".",x={type:"literal",value:".",description:'"."'},S="=",E={type:"literal",value:"=",description:'"="'},O=function(e,t){Pr(Rr("Assign",t,jt,It,e))},A=function(e){return e.join("")},M=function(e){return e.value},j='"""',I={type:"literal",value:'"""',description:'"\\"\\"\\""'},P=null,R=function(e){return Rr("String",e.join(""),jt,It)},C='"',T={type:"literal",value:'"',description:'"\\""'},B="'''",L={type:"literal",value:"'''",description:"\"'''\""},z="'",U={type:"literal",value:"'",description:'"\'"'},N=function(e){return e},D=function(e){return e},F="\\",q={type:"literal",value:"\\",description:'"\\\\"'},H=function(){return""},W="e",K={type:"literal",value:"e",description:'"e"'},V="E",Z={type:"literal",value:"E",description:'"E"'},Y=function(e,t){return Rr("Float",parseFloat(e+"e"+t),jt,It)},X=function(e){return Rr("Float",parseFloat(e),jt,It)},G="+",J={type:"literal",value:"+",description:'"+"'},$=function(e){return e.join("")},Q="-",ee={type:"literal",value:"-",description:'"-"'},te=function(e){return"-"+e.join("")},re=function(e){return Rr("Integer",parseInt(e,10),jt,It)},ne="true",ie={type:"literal",value:"true",description:'"true"'},oe=function(){return Rr("Boolean",!0,jt,It)},ae="false",ue={type:"literal",value:"false",description:'"false"'},se=function(){return Rr("Boolean",!1,jt,It)},ce=function(){return Rr("Array",[],jt,It)},fe=function(e){return Rr("Array",e?[e]:[],jt,It)},le=function(e){return Rr("Array",e,jt,It)},he=function(e,t){return Rr("Array",e.concat(t),jt,It)},de=function(e){return e},pe=",",be={type:"literal",value:",",description:'","'},ve="{",ye={type:"literal",value:"{",description:'"{"'},me="}",ge={type:"literal",value:"}",description:'"}"'},we=function(e){return Rr("InlineTable",e,jt,It)},ke=function(e,t){return Rr("InlineTableValue",t,jt,It,e)},_e=function(e){return"."+e},xe=function(e){return e.join("")},Se=":",Ee={type:"literal",value:":",description:'":"'},Oe=function(e){return e.join("")},Ae="T",Me={type:"literal",value:"T",description:'"T"'},je="Z",Ie={type:"literal",value:"Z",description:'"Z"'},Pe=function(e,t){return Rr("Date",new Date(e+"T"+t+"Z"),jt,It)},Re=function(e,t){return Rr("Date",new Date(e+"T"+t),jt,It)},Ce=/^[ \t]/,Te={type:"class",value:"[ \\t]",description:"[ \\t]"},Be="\n",Le={type:"literal",value:"\n",description:'"\\n"'},ze="\r",Ue={type:"literal",value:"\r",description:'"\\r"'},Ne=/^[0-9a-f]/i,De={type:"class",value:"[0-9a-f]i",description:"[0-9a-f]i"},Fe=/^[0-9]/,qe={type:"class",value:"[0-9]",description:"[0-9]"},He="_",We={type:"literal",value:"_",description:'"_"'},Ke=function(){return""},Ve=/^[A-Za-z0-9_\-]/,Ze={type:"class",value:"[A-Za-z0-9_\\-]",description:"[A-Za-z0-9_\\-]"},Ye=function(e){return e.join("")},Xe='\\"',Ge={type:"literal",value:'\\"',description:'"\\\\\\""'},Je=function(){return'"'},$e="\\\\",Qe={type:"literal",value:"\\\\",description:'"\\\\\\\\"'},et=function(){return"\\"},tt="\\b",rt={type:"literal",value:"\\b",description:'"\\\\b"'},nt=function(){return"\b"},it="\\t",ot={type:"literal",value:"\\t",description:'"\\\\t"'},at=function(){return"\t"},ut="\\n",st={type:"literal",value:"\\n",description:'"\\\\n"'},ct=function(){return"\n"},ft="\\f",lt={type:"literal",value:"\\f",description:'"\\\\f"'},ht=function(){return"\f"},dt="\\r",pt={type:"literal",value:"\\r",description:'"\\\\r"'},bt=function(){return"\r"},vt="\\U",yt={type:"literal",value:"\\U",description:'"\\\\U"'},mt=function(e){return Cr(e.join(""))},gt="\\u",wt={type:"literal",value:"\\u",description:'"\\\\u"'},kt=0,_t=0,xt=0,St={line:1,column:1,seenCR:!1},Et=0,Ot=[],At=0,Mt={};if("startRule"in n){if(!(n.startRule in o))throw new Error("Can't start parsing from rule \""+n.startRule+'".');a=o[n.startRule]}function jt(){return Pt(_t).line}function It(){return Pt(_t).column}function Pt(e){return xt!==e&&(xt>e&&(xt=0,St={line:1,column:1,seenCR:!1}),function(e,r,n){var i,o;for(i=r;i<n;i++)"\n"===(o=t.charAt(i))?(e.seenCR||e.line++,e.column=1,e.seenCR=!1):"\r"===o||"\u2028"===o||"\u2029"===o?(e.line++,e.column=1,e.seenCR=!0):(e.column++,e.seenCR=!1)}(St,xt,e),xt=e),St}function Rt(e){kt<Et||(kt>Et&&(Et=kt,Ot=[]),Ot.push(e))}function Ct(r,n,i){var o=Pt(i),a=i<t.length?t.charAt(i):null;return null!==n&&function(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++}(n),new e(null!==r?r:function(e,t){var r,n=new Array(e.length);for(r=0;r<e.length;r++)n[r]=e[r].description;return"Expected "+(e.length>1?n.slice(0,-1).join(", ")+" or "+n[e.length-1]:n[0])+" but "+(t?'"'+function(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)}))}(t)+'"':"end of input")+" found."}(n,a),n,a,i,o.line,o.column)}function Tt(){var e,t,r,n=49*kt+0,o=Mt[n];if(o)return kt=o.nextPos,o.result;for(e=kt,t=[],r=Bt();r!==i;)t.push(r),r=Bt();return t!==i&&(_t=e,t=u()),e=t,Mt[n]={nextPos:kt,result:e},e}function Bt(){var e,t,r,n,o,a,u,c=49*kt+1,f=Mt[c];if(f)return kt=f.nextPos,f.result;for(e=kt,t=[],r=gr();r!==i;)t.push(r),r=gr();if(t!==i)if((r=Lt())!==i){for(n=[],o=gr();o!==i;)n.push(o),o=gr();if(n!==i){for(o=[],a=zt();a!==i;)o.push(a),a=zt();if(o!==i){if(a=[],(u=wr())!==i)for(;u!==i;)a.push(u),u=wr();else a=s;a===i&&(a=_r()),a!==i?e=t=[t,r,n,o,a]:(kt=e,e=s)}else kt=e,e=s}else kt=e,e=s}else kt=e,e=s;else kt=e,e=s;if(e===i){if(e=kt,t=[],(r=gr())!==i)for(;r!==i;)t.push(r),r=gr();else t=s;if(t!==i){if(r=[],(n=wr())!==i)for(;n!==i;)r.push(n),n=wr();else r=s;r===i&&(r=_r()),r!==i?e=t=[t,r]:(kt=e,e=s)}else kt=e,e=s;e===i&&(e=wr())}return Mt[c]={nextPos:kt,result:e},e}function Lt(){var e,t=49*kt+2,r=Mt[t];return r?(kt=r.nextPos,r.result):((e=zt())===i&&(e=Ut())===i&&(e=Nt())===i&&(e=Ht()),Mt[t]={nextPos:kt,result:e},e)}function zt(){var e,r,n,o,a,u,d=49*kt+3,p=Mt[d];if(p)return kt=p.nextPos,p.result;if(e=kt,35===t.charCodeAt(kt)?(r=c,kt++):(r=i,0===At&&Rt(f)),r!==i){for(n=[],o=kt,a=kt,At++,(u=wr())===i&&(u=_r()),At--,u===i?a=l:(kt=a,a=s),a!==i?(t.length>kt?(u=t.charAt(kt),kt++):(u=i,0===At&&Rt(h)),u!==i?o=a=[a,u]:(kt=o,o=s)):(kt=o,o=s);o!==i;)n.push(o),o=kt,a=kt,At++,(u=wr())===i&&(u=_r()),At--,u===i?a=l:(kt=a,a=s),a!==i?(t.length>kt?(u=t.charAt(kt),kt++):(u=i,0===At&&Rt(h)),u!==i?o=a=[a,u]:(kt=o,o=s)):(kt=o,o=s);n!==i?e=r=[r,n]:(kt=e,e=s)}else kt=e,e=s;return Mt[d]={nextPos:kt,result:e},e}function Ut(){var e,r,n,o,a,u,c=49*kt+4,f=Mt[c];if(f)return kt=f.nextPos,f.result;if(e=kt,91===t.charCodeAt(kt)?(r=d,kt++):(r=i,0===At&&Rt(p)),r!==i){for(n=[],o=gr();o!==i;)n.push(o),o=gr();if(n!==i)if((o=Dt())!==i){for(a=[],u=gr();u!==i;)a.push(u),u=gr();a!==i?(93===t.charCodeAt(kt)?(u=b,kt++):(u=i,0===At&&Rt(v)),u!==i?(_t=e,e=r=y(o)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;return Mt[c]={nextPos:kt,result:e},e}function Nt(){var e,r,n,o,a,u,c,f,l=49*kt+5,h=Mt[l];if(h)return kt=h.nextPos,h.result;if(e=kt,91===t.charCodeAt(kt)?(r=d,kt++):(r=i,0===At&&Rt(p)),r!==i)if(91===t.charCodeAt(kt)?(n=d,kt++):(n=i,0===At&&Rt(p)),n!==i){for(o=[],a=gr();a!==i;)o.push(a),a=gr();if(o!==i)if((a=Dt())!==i){for(u=[],c=gr();c!==i;)u.push(c),c=gr();u!==i?(93===t.charCodeAt(kt)?(c=b,kt++):(c=i,0===At&&Rt(v)),c!==i?(93===t.charCodeAt(kt)?(f=b,kt++):(f=i,0===At&&Rt(v)),f!==i?(_t=e,e=r=m(a)):(kt=e,e=s)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s;return Mt[l]={nextPos:kt,result:e},e}function Dt(){var e,t,r,n=49*kt+6,o=Mt[n];if(o)return kt=o.nextPos,o.result;if(e=kt,t=[],(r=qt())!==i)for(;r!==i;)t.push(r),r=qt();else t=s;return t!==i&&(r=Ft())!==i?(_t=e,e=t=g(t,r)):(kt=e,e=s),e===i&&(e=kt,(t=Ft())!==i&&(_t=e,t=w(t)),e=t),Mt[n]={nextPos:kt,result:e},e}function Ft(){var e,t,r,n,o,a=49*kt+7,u=Mt[a];if(u)return kt=u.nextPos,u.result;for(e=kt,t=[],r=gr();r!==i;)t.push(r),r=gr();if(t!==i)if((r=Wt())!==i){for(n=[],o=gr();o!==i;)n.push(o),o=gr();n!==i?(_t=e,e=t=k(r)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s;if(e===i){for(e=kt,t=[],r=gr();r!==i;)t.push(r),r=gr();if(t!==i)if((r=Kt())!==i){for(n=[],o=gr();o!==i;)n.push(o),o=gr();n!==i?(_t=e,e=t=k(r)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}return Mt[a]={nextPos:kt,result:e},e}function qt(){var e,r,n,o,a,u,c,f=49*kt+8,l=Mt[f];if(l)return kt=l.nextPos,l.result;for(e=kt,r=[],n=gr();n!==i;)r.push(n),n=gr();if(r!==i)if((n=Wt())!==i){for(o=[],a=gr();a!==i;)o.push(a),a=gr();if(o!==i)if(46===t.charCodeAt(kt)?(a=_,kt++):(a=i,0===At&&Rt(x)),a!==i){for(u=[],c=gr();c!==i;)u.push(c),c=gr();u!==i?(_t=e,e=r=k(n)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s;if(e===i){for(e=kt,r=[],n=gr();n!==i;)r.push(n),n=gr();if(r!==i)if((n=Kt())!==i){for(o=[],a=gr();a!==i;)o.push(a),a=gr();if(o!==i)if(46===t.charCodeAt(kt)?(a=_,kt++):(a=i,0===At&&Rt(x)),a!==i){for(u=[],c=gr();c!==i;)u.push(c),c=gr();u!==i?(_t=e,e=r=k(n)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s}return Mt[f]={nextPos:kt,result:e},e}function Ht(){var e,r,n,o,a,u,c=49*kt+9,f=Mt[c];if(f)return kt=f.nextPos,f.result;if(e=kt,(r=Wt())!==i){for(n=[],o=gr();o!==i;)n.push(o),o=gr();if(n!==i)if(61===t.charCodeAt(kt)?(o=S,kt++):(o=i,0===At&&Rt(E)),o!==i){for(a=[],u=gr();u!==i;)a.push(u),u=gr();a!==i&&(u=Vt())!==i?(_t=e,e=r=O(r,u)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;if(e===i)if(e=kt,(r=Kt())!==i){for(n=[],o=gr();o!==i;)n.push(o),o=gr();if(n!==i)if(61===t.charCodeAt(kt)?(o=S,kt++):(o=i,0===At&&Rt(E)),o!==i){for(a=[],u=gr();u!==i;)a.push(u),u=gr();a!==i&&(u=Vt())!==i?(_t=e,e=r=O(r,u)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;return Mt[c]={nextPos:kt,result:e},e}function Wt(){var e,t,r,n=49*kt+10,o=Mt[n];if(o)return kt=o.nextPos,o.result;if(e=kt,t=[],(r=Er())!==i)for(;r!==i;)t.push(r),r=Er();else t=s;return t!==i&&(_t=e,t=A(t)),e=t,Mt[n]={nextPos:kt,result:e},e}function Kt(){var e,t,r=49*kt+11,n=Mt[r];return n?(kt=n.nextPos,n.result):(e=kt,(t=Xt())!==i&&(_t=e,t=M(t)),(e=t)===i&&(e=kt,(t=Jt())!==i&&(_t=e,t=M(t)),e=t),Mt[r]={nextPos:kt,result:e},e)}function Vt(){var e,t=49*kt+12,r=Mt[t];return r?(kt=r.nextPos,r.result):((e=Zt())===i&&(e=mr())===i&&(e=nr())===i&&(e=or())===i&&(e=ur())===i&&(e=sr())===i&&(e=hr()),Mt[t]={nextPos:kt,result:e},e)}function Zt(){var e,t=49*kt+13,r=Mt[t];return r?(kt=r.nextPos,r.result):((e=Yt())===i&&(e=Xt())===i&&(e=Gt())===i&&(e=Jt()),Mt[t]={nextPos:kt,result:e},e)}function Yt(){var e,r,n,o,a,u=49*kt+14,c=Mt[u];if(c)return kt=c.nextPos,c.result;if(e=kt,t.substr(kt,3)===j?(r=j,kt+=3):(r=i,0===At&&Rt(I)),r!==i)if((n=wr())===i&&(n=P),n!==i){for(o=[],a=er();a!==i;)o.push(a),a=er();o!==i?(t.substr(kt,3)===j?(a=j,kt+=3):(a=i,0===At&&Rt(I)),a!==i?(_t=e,e=r=R(o)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s;return Mt[u]={nextPos:kt,result:e},e}function Xt(){var e,r,n,o,a=49*kt+15,u=Mt[a];if(u)return kt=u.nextPos,u.result;if(e=kt,34===t.charCodeAt(kt)?(r=C,kt++):(r=i,0===At&&Rt(T)),r!==i){for(n=[],o=$t();o!==i;)n.push(o),o=$t();n!==i?(34===t.charCodeAt(kt)?(o=C,kt++):(o=i,0===At&&Rt(T)),o!==i?(_t=e,e=r=R(n)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;return Mt[a]={nextPos:kt,result:e},e}function Gt(){var e,r,n,o,a,u=49*kt+16,c=Mt[u];if(c)return kt=c.nextPos,c.result;if(e=kt,t.substr(kt,3)===B?(r=B,kt+=3):(r=i,0===At&&Rt(L)),r!==i)if((n=wr())===i&&(n=P),n!==i){for(o=[],a=rr();a!==i;)o.push(a),a=rr();o!==i?(t.substr(kt,3)===B?(a=B,kt+=3):(a=i,0===At&&Rt(L)),a!==i?(_t=e,e=r=R(o)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s;return Mt[u]={nextPos:kt,result:e},e}function Jt(){var e,r,n,o,a=49*kt+17,u=Mt[a];if(u)return kt=u.nextPos,u.result;if(e=kt,39===t.charCodeAt(kt)?(r=z,kt++):(r=i,0===At&&Rt(U)),r!==i){for(n=[],o=Qt();o!==i;)n.push(o),o=Qt();n!==i?(39===t.charCodeAt(kt)?(o=z,kt++):(o=i,0===At&&Rt(U)),o!==i?(_t=e,e=r=R(n)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;return Mt[a]={nextPos:kt,result:e},e}function $t(){var e,r,n,o=49*kt+18,a=Mt[o];return a?(kt=a.nextPos,a.result):((e=Ar())===i&&(e=kt,r=kt,At++,34===t.charCodeAt(kt)?(n=C,kt++):(n=i,0===At&&Rt(T)),At--,n===i?r=l:(kt=r,r=s),r!==i?(t.length>kt?(n=t.charAt(kt),kt++):(n=i,0===At&&Rt(h)),n!==i?(_t=e,e=r=N(n)):(kt=e,e=s)):(kt=e,e=s)),Mt[o]={nextPos:kt,result:e},e)}function Qt(){var e,r,n,o=49*kt+19,a=Mt[o];return a?(kt=a.nextPos,a.result):(e=kt,r=kt,At++,39===t.charCodeAt(kt)?(n=z,kt++):(n=i,0===At&&Rt(U)),At--,n===i?r=l:(kt=r,r=s),r!==i?(t.length>kt?(n=t.charAt(kt),kt++):(n=i,0===At&&Rt(h)),n!==i?(_t=e,e=r=N(n)):(kt=e,e=s)):(kt=e,e=s),Mt[o]={nextPos:kt,result:e},e)}function er(){var e,r,n,o=49*kt+20,a=Mt[o];return a?(kt=a.nextPos,a.result):((e=Ar())===i&&(e=tr())===i&&(e=kt,r=kt,At++,t.substr(kt,3)===j?(n=j,kt+=3):(n=i,0===At&&Rt(I)),At--,n===i?r=l:(kt=r,r=s),r!==i?(t.length>kt?(n=t.charAt(kt),kt++):(n=i,0===At&&Rt(h)),n!==i?(_t=e,e=r=D(n)):(kt=e,e=s)):(kt=e,e=s)),Mt[o]={nextPos:kt,result:e},e)}function tr(){var e,r,n,o,a=49*kt+21,u=Mt[a];if(u)return kt=u.nextPos,u.result;if(e=kt,92===t.charCodeAt(kt)?(r=F,kt++):(r=i,0===At&&Rt(q)),r!==i)if(wr()!==i){for(n=[],o=kr();o!==i;)n.push(o),o=kr();n!==i?(_t=e,e=r=H()):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s;return Mt[a]={nextPos:kt,result:e},e}function rr(){var e,r,n,o=49*kt+22,a=Mt[o];return a?(kt=a.nextPos,a.result):(e=kt,r=kt,At++,t.substr(kt,3)===B?(n=B,kt+=3):(n=i,0===At&&Rt(L)),At--,n===i?r=l:(kt=r,r=s),r!==i?(t.length>kt?(n=t.charAt(kt),kt++):(n=i,0===At&&Rt(h)),n!==i?(_t=e,e=r=N(n)):(kt=e,e=s)):(kt=e,e=s),Mt[o]={nextPos:kt,result:e},e)}function nr(){var e,r,n,o,a=49*kt+23,u=Mt[a];return u?(kt=u.nextPos,u.result):(e=kt,(r=ir())===i&&(r=ar()),r!==i?(101===t.charCodeAt(kt)?(n=W,kt++):(n=i,0===At&&Rt(K)),n===i&&(69===t.charCodeAt(kt)?(n=V,kt++):(n=i,0===At&&Rt(Z))),n!==i&&(o=ar())!==i?(_t=e,e=r=Y(r,o)):(kt=e,e=s)):(kt=e,e=s),e===i&&(e=kt,(r=ir())!==i&&(_t=e,r=X(r)),e=r),Mt[a]={nextPos:kt,result:e},e)}function ir(){var e,r,n,o,a,u,c=49*kt+24,f=Mt[c];return f?(kt=f.nextPos,f.result):(e=kt,43===t.charCodeAt(kt)?(r=G,kt++):(r=i,0===At&&Rt(J)),r===i&&(r=P),r!==i?(n=kt,(o=Or())!==i?(46===t.charCodeAt(kt)?(a=_,kt++):(a=i,0===At&&Rt(x)),a!==i&&(u=Or())!==i?n=o=[o,a,u]:(kt=n,n=s)):(kt=n,n=s),n!==i?(_t=e,e=r=$(n)):(kt=e,e=s)):(kt=e,e=s),e===i&&(e=kt,45===t.charCodeAt(kt)?(r=Q,kt++):(r=i,0===At&&Rt(ee)),r!==i?(n=kt,(o=Or())!==i?(46===t.charCodeAt(kt)?(a=_,kt++):(a=i,0===At&&Rt(x)),a!==i&&(u=Or())!==i?n=o=[o,a,u]:(kt=n,n=s)):(kt=n,n=s),n!==i?(_t=e,e=r=te(n)):(kt=e,e=s)):(kt=e,e=s)),Mt[c]={nextPos:kt,result:e},e)}function or(){var e,t,r=49*kt+25,n=Mt[r];return n?(kt=n.nextPos,n.result):(e=kt,(t=ar())!==i&&(_t=e,t=re(t)),e=t,Mt[r]={nextPos:kt,result:e},e)}function ar(){var e,r,n,o,a,u=49*kt+26,c=Mt[u];if(c)return kt=c.nextPos,c.result;if(e=kt,43===t.charCodeAt(kt)?(r=G,kt++):(r=i,0===At&&Rt(J)),r===i&&(r=P),r!==i){if(n=[],(o=Sr())!==i)for(;o!==i;)n.push(o),o=Sr();else n=s;n!==i?(o=kt,At++,46===t.charCodeAt(kt)?(a=_,kt++):(a=i,0===At&&Rt(x)),At--,a===i?o=l:(kt=o,o=s),o!==i?(_t=e,e=r=$(n)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;if(e===i)if(e=kt,45===t.charCodeAt(kt)?(r=Q,kt++):(r=i,0===At&&Rt(ee)),r!==i){if(n=[],(o=Sr())!==i)for(;o!==i;)n.push(o),o=Sr();else n=s;n!==i?(o=kt,At++,46===t.charCodeAt(kt)?(a=_,kt++):(a=i,0===At&&Rt(x)),At--,a===i?o=l:(kt=o,o=s),o!==i?(_t=e,e=r=te(n)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;return Mt[u]={nextPos:kt,result:e},e}function ur(){var e,r,n=49*kt+27,o=Mt[n];return o?(kt=o.nextPos,o.result):(e=kt,t.substr(kt,4)===ne?(r=ne,kt+=4):(r=i,0===At&&Rt(ie)),r!==i&&(_t=e,r=oe()),(e=r)===i&&(e=kt,t.substr(kt,5)===ae?(r=ae,kt+=5):(r=i,0===At&&Rt(ue)),r!==i&&(_t=e,r=se()),e=r),Mt[n]={nextPos:kt,result:e},e)}function sr(){var e,r,n,o,a,u=49*kt+28,c=Mt[u];if(c)return kt=c.nextPos,c.result;if(e=kt,91===t.charCodeAt(kt)?(r=d,kt++):(r=i,0===At&&Rt(p)),r!==i){for(n=[],o=lr();o!==i;)n.push(o),o=lr();n!==i?(93===t.charCodeAt(kt)?(o=b,kt++):(o=i,0===At&&Rt(v)),o!==i?(_t=e,e=r=ce()):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;if(e===i&&(e=kt,91===t.charCodeAt(kt)?(r=d,kt++):(r=i,0===At&&Rt(p)),r!==i?((n=cr())===i&&(n=P),n!==i?(93===t.charCodeAt(kt)?(o=b,kt++):(o=i,0===At&&Rt(v)),o!==i?(_t=e,e=r=fe(n)):(kt=e,e=s)):(kt=e,e=s)):(kt=e,e=s),e===i)){if(e=kt,91===t.charCodeAt(kt)?(r=d,kt++):(r=i,0===At&&Rt(p)),r!==i){if(n=[],(o=fr())!==i)for(;o!==i;)n.push(o),o=fr();else n=s;n!==i?(93===t.charCodeAt(kt)?(o=b,kt++):(o=i,0===At&&Rt(v)),o!==i?(_t=e,e=r=le(n)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s;if(e===i)if(e=kt,91===t.charCodeAt(kt)?(r=d,kt++):(r=i,0===At&&Rt(p)),r!==i){if(n=[],(o=fr())!==i)for(;o!==i;)n.push(o),o=fr();else n=s;n!==i&&(o=cr())!==i?(93===t.charCodeAt(kt)?(a=b,kt++):(a=i,0===At&&Rt(v)),a!==i?(_t=e,e=r=he(n,o)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s}return Mt[u]={nextPos:kt,result:e},e}function cr(){var e,t,r,n,o,a=49*kt+29,u=Mt[a];if(u)return kt=u.nextPos,u.result;for(e=kt,t=[],r=lr();r!==i;)t.push(r),r=lr();if(t!==i)if((r=Vt())!==i){for(n=[],o=lr();o!==i;)n.push(o),o=lr();n!==i?(_t=e,e=t=de(r)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s;return Mt[a]={nextPos:kt,result:e},e}function fr(){var e,r,n,o,a,u,c,f=49*kt+30,l=Mt[f];if(l)return kt=l.nextPos,l.result;for(e=kt,r=[],n=lr();n!==i;)r.push(n),n=lr();if(r!==i)if((n=Vt())!==i){for(o=[],a=lr();a!==i;)o.push(a),a=lr();if(o!==i)if(44===t.charCodeAt(kt)?(a=pe,kt++):(a=i,0===At&&Rt(be)),a!==i){for(u=[],c=lr();c!==i;)u.push(c),c=lr();u!==i?(_t=e,e=r=de(n)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s;return Mt[f]={nextPos:kt,result:e},e}function lr(){var e,t=49*kt+31,r=Mt[t];return r?(kt=r.nextPos,r.result):((e=gr())===i&&(e=wr())===i&&(e=zt()),Mt[t]={nextPos:kt,result:e},e)}function hr(){var e,r,n,o,a,u,c=49*kt+32,f=Mt[c];if(f)return kt=f.nextPos,f.result;if(e=kt,123===t.charCodeAt(kt)?(r=ve,kt++):(r=i,0===At&&Rt(ye)),r!==i){for(n=[],o=gr();o!==i;)n.push(o),o=gr();if(n!==i){for(o=[],a=dr();a!==i;)o.push(a),a=dr();if(o!==i){for(a=[],u=gr();u!==i;)a.push(u),u=gr();a!==i?(125===t.charCodeAt(kt)?(u=me,kt++):(u=i,0===At&&Rt(ge)),u!==i?(_t=e,e=r=we(o)):(kt=e,e=s)):(kt=e,e=s)}else kt=e,e=s}else kt=e,e=s}else kt=e,e=s;return Mt[c]={nextPos:kt,result:e},e}function dr(){var e,r,n,o,a,u,c,f,l,h,d,p=49*kt+33,b=Mt[p];if(b)return kt=b.nextPos,b.result;for(e=kt,r=[],n=gr();n!==i;)r.push(n),n=gr();if(r!==i)if((n=Wt())!==i){for(o=[],a=gr();a!==i;)o.push(a),a=gr();if(o!==i)if(61===t.charCodeAt(kt)?(a=S,kt++):(a=i,0===At&&Rt(E)),a!==i){for(u=[],c=gr();c!==i;)u.push(c),c=gr();if(u!==i)if((c=Vt())!==i){for(f=[],l=gr();l!==i;)f.push(l),l=gr();if(f!==i)if(44===t.charCodeAt(kt)?(l=pe,kt++):(l=i,0===At&&Rt(be)),l!==i){for(h=[],d=gr();d!==i;)h.push(d),d=gr();h!==i?(_t=e,e=r=ke(n,c)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s;if(e===i){for(e=kt,r=[],n=gr();n!==i;)r.push(n),n=gr();if(r!==i)if((n=Wt())!==i){for(o=[],a=gr();a!==i;)o.push(a),a=gr();if(o!==i)if(61===t.charCodeAt(kt)?(a=S,kt++):(a=i,0===At&&Rt(E)),a!==i){for(u=[],c=gr();c!==i;)u.push(c),c=gr();u!==i&&(c=Vt())!==i?(_t=e,e=r=ke(n,c)):(kt=e,e=s)}else kt=e,e=s;else kt=e,e=s}else kt=e,e=s;else kt=e,e=s}return Mt[p]={nextPos:kt,result:e},e}function pr(){var e,r,n,o=49*kt+34,a=Mt[o];return a?(kt=a.nextPos,a.result):(e=kt,46===t.charCodeAt(kt)?(r=_,kt++):(r=i,0===At&&Rt(x)),r!==i&&(n=Or())!==i?(_t=e,e=r=_e(n)):(kt=e,e=s),Mt[o]={nextPos:kt,result:e},e)}function br(){var e,r,n,o,a,u,c,f,l,h,d,p,b=49*kt+35,v=Mt[b];return v?(kt=v.nextPos,v.result):(e=kt,r=kt,(n=Sr())!==i&&(o=Sr())!==i&&(a=Sr())!==i&&(u=Sr())!==i?(45===t.charCodeAt(kt)?(c=Q,kt++):(c=i,0===At&&Rt(ee)),c!==i&&(f=Sr())!==i&&(l=Sr())!==i?(45===t.charCodeAt(kt)?(h=Q,kt++):(h=i,0===At&&Rt(ee)),h!==i&&(d=Sr())!==i&&(p=Sr())!==i?r=n=[n,o,a,u,c,f,l,h,d,p]:(kt=r,r=s)):(kt=r,r=s)):(kt=r,r=s),r!==i&&(_t=e,r=xe(r)),e=r,Mt[b]={nextPos:kt,result:e},e)}function vr(){var e,r,n,o,a,u,c,f,l,h,d,p=49*kt+36,b=Mt[p];return b?(kt=b.nextPos,b.result):(e=kt,r=kt,(n=Sr())!==i&&(o=Sr())!==i?(58===t.charCodeAt(kt)?(a=Se,kt++):(a=i,0===At&&Rt(Ee)),a!==i&&(u=Sr())!==i&&(c=Sr())!==i?(58===t.charCodeAt(kt)?(f=Se,kt++):(f=i,0===At&&Rt(Ee)),f!==i&&(l=Sr())!==i&&(h=Sr())!==i?((d=pr())===i&&(d=P),d!==i?r=n=[n,o,a,u,c,f,l,h,d]:(kt=r,r=s)):(kt=r,r=s)):(kt=r,r=s)):(kt=r,r=s),r!==i&&(_t=e,r=Oe(r)),e=r,Mt[p]={nextPos:kt,result:e},e)}function yr(){var e,r,n,o,a,u,c,f,l,h,d,p,b,v,y,m,g,w=49*kt+37,k=Mt[w];return k?(kt=k.nextPos,k.result):(e=kt,r=kt,(n=Sr())!==i&&(o=Sr())!==i?(58===t.charCodeAt(kt)?(a=Se,kt++):(a=i,0===At&&Rt(Ee)),a!==i&&(u=Sr())!==i&&(c=Sr())!==i?(58===t.charCodeAt(kt)?(f=Se,kt++):(f=i,0===At&&Rt(Ee)),f!==i&&(l=Sr())!==i&&(h=Sr())!==i?((d=pr())===i&&(d=P),d!==i?(45===t.charCodeAt(kt)?(p=Q,kt++):(p=i,0===At&&Rt(ee)),p===i&&(43===t.charCodeAt(kt)?(p=G,kt++):(p=i,0===At&&Rt(J))),p!==i&&(b=Sr())!==i&&(v=Sr())!==i?(58===t.charCodeAt(kt)?(y=Se,kt++):(y=i,0===At&&Rt(Ee)),y!==i&&(m=Sr())!==i&&(g=Sr())!==i?r=n=[n,o,a,u,c,f,l,h,d,p,b,v,y,m,g]:(kt=r,r=s)):(kt=r,r=s)):(kt=r,r=s)):(kt=r,r=s)):(kt=r,r=s)):(kt=r,r=s),r!==i&&(_t=e,r=Oe(r)),e=r,Mt[w]={nextPos:kt,result:e},e)}function mr(){var e,r,n,o,a,u=49*kt+38,c=Mt[u];return c?(kt=c.nextPos,c.result):(e=kt,(r=br())!==i?(84===t.charCodeAt(kt)?(n=Ae,kt++):(n=i,0===At&&Rt(Me)),n!==i&&(o=vr())!==i?(90===t.charCodeAt(kt)?(a=je,kt++):(a=i,0===At&&Rt(Ie)),a!==i?(_t=e,e=r=Pe(r,o)):(kt=e,e=s)):(kt=e,e=s)):(kt=e,e=s),e===i&&(e=kt,(r=br())!==i?(84===t.charCodeAt(kt)?(n=Ae,kt++):(n=i,0===At&&Rt(Me)),n!==i&&(o=yr())!==i?(_t=e,e=r=Re(r,o)):(kt=e,e=s)):(kt=e,e=s)),Mt[u]={nextPos:kt,result:e},e)}function gr(){var e,r=49*kt+39,n=Mt[r];return n?(kt=n.nextPos,n.result):(Ce.test(t.charAt(kt))?(e=t.charAt(kt),kt++):(e=i,0===At&&Rt(Te)),Mt[r]={nextPos:kt,result:e},e)}function wr(){var e,r,n,o=49*kt+40,a=Mt[o];return a?(kt=a.nextPos,a.result):(10===t.charCodeAt(kt)?(e=Be,kt++):(e=i,0===At&&Rt(Le)),e===i&&(e=kt,13===t.charCodeAt(kt)?(r=ze,kt++):(r=i,0===At&&Rt(Ue)),r!==i?(10===t.charCodeAt(kt)?(n=Be,kt++):(n=i,0===At&&Rt(Le)),n!==i?e=r=[r,n]:(kt=e,e=s)):(kt=e,e=s)),Mt[o]={nextPos:kt,result:e},e)}function kr(){var e,t=49*kt+41,r=Mt[t];return r?(kt=r.nextPos,r.result):((e=wr())===i&&(e=gr()),Mt[t]={nextPos:kt,result:e},e)}function _r(){var e,r,n=49*kt+42,o=Mt[n];return o?(kt=o.nextPos,o.result):(e=kt,At++,t.length>kt?(r=t.charAt(kt),kt++):(r=i,0===At&&Rt(h)),At--,r===i?e=l:(kt=e,e=s),Mt[n]={nextPos:kt,result:e},e)}function xr(){var e,r=49*kt+43,n=Mt[r];return n?(kt=n.nextPos,n.result):(Ne.test(t.charAt(kt))?(e=t.charAt(kt),kt++):(e=i,0===At&&Rt(De)),Mt[r]={nextPos:kt,result:e},e)}function Sr(){var e,r,n=49*kt+44,o=Mt[n];return o?(kt=o.nextPos,o.result):(Fe.test(t.charAt(kt))?(e=t.charAt(kt),kt++):(e=i,0===At&&Rt(qe)),e===i&&(e=kt,95===t.charCodeAt(kt)?(r=He,kt++):(r=i,0===At&&Rt(We)),r!==i&&(_t=e,r=Ke()),e=r),Mt[n]={nextPos:kt,result:e},e)}function Er(){var e,r=49*kt+45,n=Mt[r];return n?(kt=n.nextPos,n.result):(Ve.test(t.charAt(kt))?(e=t.charAt(kt),kt++):(e=i,0===At&&Rt(Ze)),Mt[r]={nextPos:kt,result:e},e)}function Or(){var e,t,r,n=49*kt+46,o=Mt[n];if(o)return kt=o.nextPos,o.result;if(e=kt,t=[],(r=Sr())!==i)for(;r!==i;)t.push(r),r=Sr();else t=s;return t!==i&&(_t=e,t=Ye(t)),e=t,Mt[n]={nextPos:kt,result:e},e}function Ar(){var e,r,n=49*kt+47,o=Mt[n];return o?(kt=o.nextPos,o.result):(e=kt,t.substr(kt,2)===Xe?(r=Xe,kt+=2):(r=i,0===At&&Rt(Ge)),r!==i&&(_t=e,r=Je()),(e=r)===i&&(e=kt,t.substr(kt,2)===$e?(r=$e,kt+=2):(r=i,0===At&&Rt(Qe)),r!==i&&(_t=e,r=et()),(e=r)===i&&(e=kt,t.substr(kt,2)===tt?(r=tt,kt+=2):(r=i,0===At&&Rt(rt)),r!==i&&(_t=e,r=nt()),(e=r)===i&&(e=kt,t.substr(kt,2)===it?(r=it,kt+=2):(r=i,0===At&&Rt(ot)),r!==i&&(_t=e,r=at()),(e=r)===i&&(e=kt,t.substr(kt,2)===ut?(r=ut,kt+=2):(r=i,0===At&&Rt(st)),r!==i&&(_t=e,r=ct()),(e=r)===i&&(e=kt,t.substr(kt,2)===ft?(r=ft,kt+=2):(r=i,0===At&&Rt(lt)),r!==i&&(_t=e,r=ht()),(e=r)===i&&(e=kt,t.substr(kt,2)===dt?(r=dt,kt+=2):(r=i,0===At&&Rt(pt)),r!==i&&(_t=e,r=bt()),(e=r)===i&&(e=Mr()))))))),Mt[n]={nextPos:kt,result:e},e)}function Mr(){var e,r,n,o,a,u,c,f,l,h,d,p=49*kt+48,b=Mt[p];return b?(kt=b.nextPos,b.result):(e=kt,t.substr(kt,2)===vt?(r=vt,kt+=2):(r=i,0===At&&Rt(yt)),r!==i?(n=kt,(o=xr())!==i&&(a=xr())!==i&&(u=xr())!==i&&(c=xr())!==i&&(f=xr())!==i&&(l=xr())!==i&&(h=xr())!==i&&(d=xr())!==i?n=o=[o,a,u,c,f,l,h,d]:(kt=n,n=s),n!==i?(_t=e,e=r=mt(n)):(kt=e,e=s)):(kt=e,e=s),e===i&&(e=kt,t.substr(kt,2)===gt?(r=gt,kt+=2):(r=i,0===At&&Rt(wt)),r!==i?(n=kt,(o=xr())!==i&&(a=xr())!==i&&(u=xr())!==i&&(c=xr())!==i?n=o=[o,a,u,c]:(kt=n,n=s),n!==i?(_t=e,e=r=mt(n)):(kt=e,e=s)):(kt=e,e=s)),Mt[p]={nextPos:kt,result:e},e)}var jr=[];function Ir(e,t,r){var n=new Error(e);throw n.line=t,n.column=r,n}function Pr(e){jr.push(e)}function Rr(e,t,r,n,i){var o={type:e,value:t,line:r(),column:n()};return i&&(o.key=i),o}function Cr(e,t,r){var n=parseInt("0x"+e);if(!(!isFinite(n)||Math.floor(n)!=n||n<0||n>1114111||n>55295&&n<57344))return Tr(n);Ir("Invalid Unicode escape code: "+e,t,r)}function Tr(){var e,t,r=16384,n=[],i=-1,o=arguments.length;if(!o)return"";for(var a="";++i<o;){var u=Number(arguments[i]);u<=65535?n.push(u):(e=55296+((u-=65536)>>10),t=u%1024+56320,n.push(e,t)),(i+1==o||n.length>r)&&(a+=String.fromCharCode.apply(null,n),n.length=0)}return a}if((r=a())!==i&&kt===t.length)return r;throw r!==i&&kt<t.length&&Rt({type:"end",description:"end of input"}),Ct(null,Ot,Et)}}}()},function(e,t,r){"use strict";e.exports={compile:function(e){var t=[],r=[],n="",i=Object.create(null),o=i;return function(e){for(var t,r=0;r<e.length;r++)switch((t=e[r]).type){case"Assign":u(t);break;case"ObjectPath":l(t);break;case"ArrayPath":h(t)}return i}(e);function a(e,t,r){var n=new Error(e);throw n.line=t,n.column=r,n}function u(e){var i,u=e.key,f=e.value,l=e.line,h=e.column;i=n?n+"."+u:u,"undefined"!==typeof o[u]&&a("Cannot redefine existing key '"+i+"'.",l,h),o[u]=c(f),s(i)||(t.push(i),r.push(i))}function s(e){return-1!==t.indexOf(e)}function c(e){return"Array"===e.type?function(e){for(var t=null,r=0;r<e.length;r++){var n=e[r];null===t?t=n.type:n.type!==t&&a("Cannot add value of type "+n.type+" to array of type "+t+".",n.line,n.column)}return e.map(c)}(e.value):"InlineTable"===e.type?f(e.value):e.value}function f(e){for(var t=Object.create(null),r=0;r<e.length;r++){var n=e[r];"InlineTable"===n.value.type?t[n.key]=f(n.value.value):"InlineTableValue"===n.type&&(t[n.key]=c(n.value))}return t}function l(e){var r=e.value,u=r.map(p).join("."),c=e.line,f=e.column;s(u)&&a("Cannot redefine existing key '"+r+"'.",c,f),t.push(u),o=d(i,r,Object.create(null),c,f),n=r}function h(e){var r=e.value,u=r.map(p).join("."),c=e.line,f=e.column;if(s(u)||t.push(u),(t=t.filter((function(e){return 0!==e.indexOf(u)}))).push(u),o=d(i,r,[],c,f),n=u,o instanceof Array){var l=Object.create(null);o.push(l),o=l}else a("Cannot redefine existing key '"+r+"'.",c,f)}function d(e,t,n,i,o){for(var u=[],s="",c=(t.join("."),e),f=0;f<t.length;f++){var l=t[f];u.push(l),s=u.join("."),"undefined"===typeof c[l]?f===t.length-1?c[l]=n:c[l]=Object.create(null):f!==t.length-1&&r.indexOf(s)>-1&&a("Cannot redefine existing key '"+s+"'.",i,o),(c=c[l])instanceof Array&&c.length&&f<t.length-1&&(c=c[c.length-1])}return c}function p(e){return e.indexOf(".")>-1?'"'+e+'"':e}}}},function(e,t){e.exports=function(e){return e&&"object"===typeof e&&"function"===typeof e.copy&&"function"===typeof e.fill&&"function"===typeof e.readUInt8}},function(e,t){"function"===typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=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){(function(e){function r(e,t){for(var r=0,n=e.length-1;n>=0;n--){var i=e[n];"."===i?e.splice(n,1):".."===i?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}t.resolve=function(){for(var t="",i=!1,o=arguments.length-1;o>=-1&&!i;o--){var a=o>=0?arguments[o]:e.cwd();if("string"!==typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(t=a+"/"+t,i="/"===a.charAt(0))}return(i?"/":"")+(t=r(n(t.split("/"),(function(e){return!!e})),!i).join("/"))||"."},t.normalize=function(e){var o=t.isAbsolute(e),a="/"===i(e,-1);return(e=r(n(e.split("/"),(function(e){return!!e})),!o).join("/"))||o||(e="."),e&&a&&(e+="/"),(o?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(n(e,(function(e,t){if("string"!==typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,r){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=t.resolve(e).substr(1),r=t.resolve(r).substr(1);for(var i=n(e.split("/")),o=n(r.split("/")),a=Math.min(i.length,o.length),u=a,s=0;s<a;s++)if(i[s]!==o[s]){u=s;break}var c=[];for(s=u;s<i.length;s++)c.push("..");return(c=c.concat(o.slice(u))).join("/")},t.sep="/",t.delimiter=":",t.dirname=function(e){if("string"!==typeof e&&(e+=""),0===e.length)return".";for(var t=e.charCodeAt(0),r=47===t,n=-1,i=!0,o=e.length-1;o>=1;--o)if(47===(t=e.charCodeAt(o))){if(!i){n=o;break}}else i=!1;return-1===n?r?"/":".":r&&1===n?"/":e.slice(0,n)},t.basename=function(e,t){var r=function(e){"string"!==typeof e&&(e+="");var t,r=0,n=-1,i=!0;for(t=e.length-1;t>=0;--t)if(47===e.charCodeAt(t)){if(!i){r=t+1;break}}else-1===n&&(i=!1,n=t+1);return-1===n?"":e.slice(r,n)}(e);return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},t.extname=function(e){"string"!==typeof e&&(e+="");for(var t=-1,r=0,n=-1,i=!0,o=0,a=e.length-1;a>=0;--a){var u=e.charCodeAt(a);if(47!==u)-1===n&&(i=!1,n=a+1),46===u?-1===t?t=a:1!==o&&(o=1):-1!==t&&(o=-1);else if(!i){r=a+1;break}}return-1===t||-1===n||0===o||1===o&&t===n-1&&t===r+1?"":e.slice(t,n)};var i="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,r(35))},function(e,t,r){"use strict";r(54);var n=r(24),i=60103;if(t.Fragment=60107,"function"===typeof Symbol&&Symbol.for){var o=Symbol.for;i=o("react.element"),t.Fragment=o("react.fragment")}var a=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,u=Object.prototype.hasOwnProperty,s={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,r){var n,o={},c=null,f=null;for(n in void 0!==r&&(c=""+r),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(f=t.ref),t)u.call(t,n)&&!s.hasOwnProperty(n)&&(o[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===o[n]&&(o[n]=t[n]);return{$$typeof:i,type:e,key:c,ref:f,props:o,_owner:a.current}}t.jsx=c,t.jsxs=c}]]);
  //# sourceMappingURL=2.5fd8ac5f.chunk.js.map