text: /*! For license information please see 0xcert-ethereum-asset-ledger.min.js.LICENSE.txt */
  (()=>{var t={1303:function(t,e,r){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var s;"object"==typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{s="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:r(2574).Buffer}catch(t){}function a(t,e){var r=t.charCodeAt(e);return r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:r-48&15}function u(t,e,r){var i=a(t,r);return r-1>=e&&(i|=a(t,r-1)<<4),i}function h(t,e,r,i){for(var n=0,o=Math.min(t.length,r),s=e;s<o;s++){var a=t.charCodeAt(s)-48;n*=i,n+=a>=49?a-49+10:a>=17?a-17+10:a}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"==typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"==typeof t)return this._initNumber(t,e,r);if("object"==typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n<t.length&&(16===e?this._parseHex(t,n,r):(this._parseBase(t,e,n),"le"===r&&this._initArray(this.toArray(),e,r)))},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"==typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var o,s,a=0;if("be"===r)for(n=t.length-1,o=0;n>=0;n-=3)s=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=s<<a&67108863,this.words[o+1]=s>>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);else if("le"===r)for(n=0,o=0;n<t.length;n+=3)s=t[n]|t[n+1]<<8|t[n+2]<<16,this.words[o]|=s<<a&67108863,this.words[o+1]=s>>>26-a&67108863,(a+=24)>=26&&(a-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e,r){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var i=0;i<this.length;i++)this.words[i]=0;var n,o=0,s=0;if("be"===r)for(i=t.length-1;i>=e;i-=2)n=u(t,e,i)<<o,this.words[s]|=67108863&n,o>=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;else for(i=(t.length-e)%2==0?e+1:e;i<t.length;i+=2)n=u(t,e,i)<<o,this.words[s]|=67108863&n,o>=18?(o-=18,s+=1,this.words[s]|=n>>>26):o+=8;this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,s=o%i,a=Math.min(o,o-s)+r,u=0,d=r;d<a;d+=i)u=h(t,d,d+i,e),this.imuln(n),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u);if(0!==s){var c=1;for(u=h(t,d,t.length,e),d=0;d<s;d++)c*=e;this.imuln(c),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u)}this.strip()},o.prototype.copy=function(t){t.words=new Array(this.length);for(var e=0;e<this.length;e++)t.words[e]=this.words[e];t.length=this.length,t.negative=this.negative,t.red=this.red},o.prototype.clone=function(){var t=new o(null);return this.copy(t),t},o.prototype._expand=function(t){for(;this.length<t;)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 d=["","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"],c=[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],l=[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 f(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],s=n*o,a=67108863&s,u=s/67108864|0;r.words[0]=a;for(var h=1;h<i;h++){for(var d=u>>>26,c=67108863&u,l=Math.min(h,e.length-1),f=Math.max(0,h-t.length+1);f<=l;f++){var p=h-f|0;d+=(s=(n=0|t.words[p])*(o=0|e.words[f])+c)/67108864|0,c=67108863&s}r.words[h]=0|c,u=0|d}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,s=0;s<this.length;s++){var a=this.words[s],u=(16777215&(a<<n|o)).toString(16);r=0!=(o=a>>>24-n&16777215)||s!==this.length-1?d[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,s--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var h=c[t],f=l[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var v=p.modn(f).toString(t);r=(p=p.idivn(f)).isZero()?v+r:d[h-v.length]+v+r}for(this.isZero()&&(r="0"+r);r.length%e!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i(void 0!==s),this.toArrayLike(s,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var s,a,u="le"===e,h=new t(o),d=this.clone();if(u){for(a=0;!d.isZero();a++)s=d.andln(255),d.iushrn(8),h[a]=s;for(;a<o;a++)h[a]=0}else{for(a=0;a<o-n;a++)h[a]=0;for(a=0;!d.isZero();a++)s=d.andln(255),d.iushrn(8),h[o-a-1]=s}return h},Math.clz32?o.prototype._countBits=function(t){return 32-Math.clz32(t)}:o.prototype._countBits=function(t){var e=t,r=0;return e>=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0==(8191&e)&&(r+=13,e>>>=13),0==(127&e)&&(r+=7,e>>>=7),0==(15&e)&&(r+=4,e>>>=4),0==(3&e)&&(r+=2,e>>>=2),0==(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;e<this.length;e++){var r=this._zeroBits(this.words[e]);if(t+=r,26!==r)break}return t},o.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},o.prototype.toTwos=function(t){return 0!==this.negative?this.abs().inotn(t).iaddn(1):this.clone()},o.prototype.fromTwos=function(t){return this.testn(t-1)?this.notn(t).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(t){for(;this.length<t.length;)this.words[this.length++]=0;for(var e=0;e<t.length;e++)this.words[e]=this.words[e]|t.words[e];return this.strip()},o.prototype.ior=function(t){return i(0==(this.negative|t.negative)),this.iuor(t)},o.prototype.or=function(t){return this.length>t.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;r<e.length;r++)this.words[r]=this.words[r]&t.words[r];return this.length=e.length,this.strip()},o.prototype.iand=function(t){return i(0==(this.negative|t.negative)),this.iuand(t)},o.prototype.and=function(t){return this.length>t.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;i<r.length;i++)this.words[i]=e.words[i]^r.words[i];if(this!==e)for(;i<e.length;i++)this.words[i]=e.words[i];return this.length=e.length,this.strip()},o.prototype.ixor=function(t){return i(0==(this.negative|t.negative)),this.iuxor(t)},o.prototype.xor=function(t){return this.length>t.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"==typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n<e;n++)this.words[n]=67108863&~this.words[n];return r>0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"==typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<<n:this.words[r]&~(1<<n),this.strip()},o.prototype.iadd=function(t){var e,r,i;if(0!==this.negative&&0===t.negative)return this.negative=0,e=this.isub(t),this.negative^=1,this._normSign();if(0===this.negative&&0!==t.negative)return t.negative=0,e=this.isub(t),t.negative=1,e._normSign();this.length>t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o<i.length;o++)e=(0|r.words[o])+(0|i.words[o])+n,this.words[o]=67108863&e,n=e>>>26;for(;0!==n&&o<r.length;o++)e=(0|r.words[o])+n,this.words[o]=67108863&e,n=e>>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;o<r.length;o++)this.words[o]=r.words[o];return this},o.prototype.add=function(t){var e;return 0!==t.negative&&0===this.negative?(t.negative=0,e=this.sub(t),t.negative^=1,e):0===t.negative&&0!==this.negative?(this.negative=0,e=t.sub(this),this.negative=1,e):this.length>t.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,s=0;s<i.length;s++)o=(e=(0|r.words[s])-(0|i.words[s])+o)>>26,this.words[s]=67108863&e;for(;0!==o&&s<r.length;s++)o=(e=(0|r.words[s])+o)>>26,this.words[s]=67108863&e;if(0===o&&s<r.length&&r!==this)for(;s<r.length;s++)this.words[s]=r.words[s];return this.length=Math.max(this.length,s),r!==this&&(this.negative=1),this.strip()},o.prototype.sub=function(t){return this.clone().isub(t)};var p=function(t,e,r){var i,n,o,s=t.words,a=e.words,u=r.words,h=0,d=0|s[0],c=8191&d,l=d>>>13,f=0|s[1],p=8191&f,v=f>>>13,_=0|s[2],m=8191&_,E=_>>>13,y=0|s[3],A=8191&y,g=y>>>13,w=0|s[4],T=8191&w,M=w>>>13,N=0|s[5],I=8191&N,R=N>>>13,O=0|s[6],b=8191&O,P=O>>>13,S=0|s[7],D=8191&S,L=S>>>13,C=0|s[8],x=8191&C,U=C>>>13,G=0|s[9],k=8191&G,B=G>>>13,j=0|a[0],F=8191&j,Y=j>>>13,V=0|a[1],W=8191&V,K=V>>>13,X=0|a[2],z=8191&X,Z=X>>>13,H=0|a[3],q=8191&H,$=H>>>13,J=0|a[4],Q=8191&J,tt=J>>>13,et=0|a[5],rt=8191&et,it=et>>>13,nt=0|a[6],ot=8191&nt,st=nt>>>13,at=0|a[7],ut=8191&at,ht=at>>>13,dt=0|a[8],ct=8191&dt,lt=dt>>>13,ft=0|a[9],pt=8191&ft,vt=ft>>>13;r.negative=t.negative^e.negative,r.length=19;var _t=(h+(i=Math.imul(c,F))|0)+((8191&(n=(n=Math.imul(c,Y))+Math.imul(l,F)|0))<<13)|0;h=((o=Math.imul(l,Y))+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(p,F),n=(n=Math.imul(p,Y))+Math.imul(v,F)|0,o=Math.imul(v,Y);var mt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,K)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,K)|0)+(n>>>13)|0)+(mt>>>26)|0,mt&=67108863,i=Math.imul(m,F),n=(n=Math.imul(m,Y))+Math.imul(E,F)|0,o=Math.imul(E,Y),i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,K)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,K)|0;var Et=(h+(i=i+Math.imul(c,z)|0)|0)+((8191&(n=(n=n+Math.imul(c,Z)|0)+Math.imul(l,z)|0))<<13)|0;h=((o=o+Math.imul(l,Z)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(A,F),n=(n=Math.imul(A,Y))+Math.imul(g,F)|0,o=Math.imul(g,Y),i=i+Math.imul(m,W)|0,n=(n=n+Math.imul(m,K)|0)+Math.imul(E,W)|0,o=o+Math.imul(E,K)|0,i=i+Math.imul(p,z)|0,n=(n=n+Math.imul(p,Z)|0)+Math.imul(v,z)|0,o=o+Math.imul(v,Z)|0;var yt=(h+(i=i+Math.imul(c,q)|0)|0)+((8191&(n=(n=n+Math.imul(c,$)|0)+Math.imul(l,q)|0))<<13)|0;h=((o=o+Math.imul(l,$)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(T,F),n=(n=Math.imul(T,Y))+Math.imul(M,F)|0,o=Math.imul(M,Y),i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,K)|0)+Math.imul(g,W)|0,o=o+Math.imul(g,K)|0,i=i+Math.imul(m,z)|0,n=(n=n+Math.imul(m,Z)|0)+Math.imul(E,z)|0,o=o+Math.imul(E,Z)|0,i=i+Math.imul(p,q)|0,n=(n=n+Math.imul(p,$)|0)+Math.imul(v,q)|0,o=o+Math.imul(v,$)|0;var At=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(I,F),n=(n=Math.imul(I,Y))+Math.imul(R,F)|0,o=Math.imul(R,Y),i=i+Math.imul(T,W)|0,n=(n=n+Math.imul(T,K)|0)+Math.imul(M,W)|0,o=o+Math.imul(M,K)|0,i=i+Math.imul(A,z)|0,n=(n=n+Math.imul(A,Z)|0)+Math.imul(g,z)|0,o=o+Math.imul(g,Z)|0,i=i+Math.imul(m,q)|0,n=(n=n+Math.imul(m,$)|0)+Math.imul(E,q)|0,o=o+Math.imul(E,$)|0,i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,tt)|0;var gt=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(b,F),n=(n=Math.imul(b,Y))+Math.imul(P,F)|0,o=Math.imul(P,Y),i=i+Math.imul(I,W)|0,n=(n=n+Math.imul(I,K)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,K)|0,i=i+Math.imul(T,z)|0,n=(n=n+Math.imul(T,Z)|0)+Math.imul(M,z)|0,o=o+Math.imul(M,Z)|0,i=i+Math.imul(A,q)|0,n=(n=n+Math.imul(A,$)|0)+Math.imul(g,q)|0,o=o+Math.imul(g,$)|0,i=i+Math.imul(m,Q)|0,n=(n=n+Math.imul(m,tt)|0)+Math.imul(E,Q)|0,o=o+Math.imul(E,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0;var wt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,st)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,st)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(D,F),n=(n=Math.imul(D,Y))+Math.imul(L,F)|0,o=Math.imul(L,Y),i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,K)|0)+Math.imul(P,W)|0,o=o+Math.imul(P,K)|0,i=i+Math.imul(I,z)|0,n=(n=n+Math.imul(I,Z)|0)+Math.imul(R,z)|0,o=o+Math.imul(R,Z)|0,i=i+Math.imul(T,q)|0,n=(n=n+Math.imul(T,$)|0)+Math.imul(M,q)|0,o=o+Math.imul(M,$)|0,i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(g,Q)|0,o=o+Math.imul(g,tt)|0,i=i+Math.imul(m,rt)|0,n=(n=n+Math.imul(m,it)|0)+Math.imul(E,rt)|0,o=o+Math.imul(E,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,st)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,st)|0;var Tt=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(x,F),n=(n=Math.imul(x,Y))+Math.imul(U,F)|0,o=Math.imul(U,Y),i=i+Math.imul(D,W)|0,n=(n=n+Math.imul(D,K)|0)+Math.imul(L,W)|0,o=o+Math.imul(L,K)|0,i=i+Math.imul(b,z)|0,n=(n=n+Math.imul(b,Z)|0)+Math.imul(P,z)|0,o=o+Math.imul(P,Z)|0,i=i+Math.imul(I,q)|0,n=(n=n+Math.imul(I,$)|0)+Math.imul(R,q)|0,o=o+Math.imul(R,$)|0,i=i+Math.imul(T,Q)|0,n=(n=n+Math.imul(T,tt)|0)+Math.imul(M,Q)|0,o=o+Math.imul(M,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(g,rt)|0,o=o+Math.imul(g,it)|0,i=i+Math.imul(m,ot)|0,n=(n=n+Math.imul(m,st)|0)+Math.imul(E,ot)|0,o=o+Math.imul(E,st)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0;var Mt=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(k,F),n=(n=Math.imul(k,Y))+Math.imul(B,F)|0,o=Math.imul(B,Y),i=i+Math.imul(x,W)|0,n=(n=n+Math.imul(x,K)|0)+Math.imul(U,W)|0,o=o+Math.imul(U,K)|0,i=i+Math.imul(D,z)|0,n=(n=n+Math.imul(D,Z)|0)+Math.imul(L,z)|0,o=o+Math.imul(L,Z)|0,i=i+Math.imul(b,q)|0,n=(n=n+Math.imul(b,$)|0)+Math.imul(P,q)|0,o=o+Math.imul(P,$)|0,i=i+Math.imul(I,Q)|0,n=(n=n+Math.imul(I,tt)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(T,rt)|0,n=(n=n+Math.imul(T,it)|0)+Math.imul(M,rt)|0,o=o+Math.imul(M,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,st)|0)+Math.imul(g,ot)|0,o=o+Math.imul(g,st)|0,i=i+Math.imul(m,ut)|0,n=(n=n+Math.imul(m,ht)|0)+Math.imul(E,ut)|0,o=o+Math.imul(E,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Nt=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,vt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,vt)|0)+(n>>>13)|0)+(Nt>>>26)|0,Nt&=67108863,i=Math.imul(k,W),n=(n=Math.imul(k,K))+Math.imul(B,W)|0,o=Math.imul(B,K),i=i+Math.imul(x,z)|0,n=(n=n+Math.imul(x,Z)|0)+Math.imul(U,z)|0,o=o+Math.imul(U,Z)|0,i=i+Math.imul(D,q)|0,n=(n=n+Math.imul(D,$)|0)+Math.imul(L,q)|0,o=o+Math.imul(L,$)|0,i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(P,Q)|0,o=o+Math.imul(P,tt)|0,i=i+Math.imul(I,rt)|0,n=(n=n+Math.imul(I,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(T,ot)|0,n=(n=n+Math.imul(T,st)|0)+Math.imul(M,ot)|0,o=o+Math.imul(M,st)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(g,ut)|0,o=o+Math.imul(g,ht)|0,i=i+Math.imul(m,ct)|0,n=(n=n+Math.imul(m,lt)|0)+Math.imul(E,ct)|0,o=o+Math.imul(E,lt)|0;var It=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,vt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,vt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(k,z),n=(n=Math.imul(k,Z))+Math.imul(B,z)|0,o=Math.imul(B,Z),i=i+Math.imul(x,q)|0,n=(n=n+Math.imul(x,$)|0)+Math.imul(U,q)|0,o=o+Math.imul(U,$)|0,i=i+Math.imul(D,Q)|0,n=(n=n+Math.imul(D,tt)|0)+Math.imul(L,Q)|0,o=o+Math.imul(L,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(P,rt)|0,o=o+Math.imul(P,it)|0,i=i+Math.imul(I,ot)|0,n=(n=n+Math.imul(I,st)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,st)|0,i=i+Math.imul(T,ut)|0,n=(n=n+Math.imul(T,ht)|0)+Math.imul(M,ut)|0,o=o+Math.imul(M,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(g,ct)|0,o=o+Math.imul(g,lt)|0;var Rt=(h+(i=i+Math.imul(m,pt)|0)|0)+((8191&(n=(n=n+Math.imul(m,vt)|0)+Math.imul(E,pt)|0))<<13)|0;h=((o=o+Math.imul(E,vt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863,i=Math.imul(k,q),n=(n=Math.imul(k,$))+Math.imul(B,q)|0,o=Math.imul(B,$),i=i+Math.imul(x,Q)|0,n=(n=n+Math.imul(x,tt)|0)+Math.imul(U,Q)|0,o=o+Math.imul(U,tt)|0,i=i+Math.imul(D,rt)|0,n=(n=n+Math.imul(D,it)|0)+Math.imul(L,rt)|0,o=o+Math.imul(L,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,st)|0)+Math.imul(P,ot)|0,o=o+Math.imul(P,st)|0,i=i+Math.imul(I,ut)|0,n=(n=n+Math.imul(I,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(T,ct)|0,n=(n=n+Math.imul(T,lt)|0)+Math.imul(M,ct)|0,o=o+Math.imul(M,lt)|0;var Ot=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,vt)|0)+Math.imul(g,pt)|0))<<13)|0;h=((o=o+Math.imul(g,vt)|0)+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,i=Math.imul(k,Q),n=(n=Math.imul(k,tt))+Math.imul(B,Q)|0,o=Math.imul(B,tt),i=i+Math.imul(x,rt)|0,n=(n=n+Math.imul(x,it)|0)+Math.imul(U,rt)|0,o=o+Math.imul(U,it)|0,i=i+Math.imul(D,ot)|0,n=(n=n+Math.imul(D,st)|0)+Math.imul(L,ot)|0,o=o+Math.imul(L,st)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(P,ut)|0,o=o+Math.imul(P,ht)|0,i=i+Math.imul(I,ct)|0,n=(n=n+Math.imul(I,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var bt=(h+(i=i+Math.imul(T,pt)|0)|0)+((8191&(n=(n=n+Math.imul(T,vt)|0)+Math.imul(M,pt)|0))<<13)|0;h=((o=o+Math.imul(M,vt)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(k,rt),n=(n=Math.imul(k,it))+Math.imul(B,rt)|0,o=Math.imul(B,it),i=i+Math.imul(x,ot)|0,n=(n=n+Math.imul(x,st)|0)+Math.imul(U,ot)|0,o=o+Math.imul(U,st)|0,i=i+Math.imul(D,ut)|0,n=(n=n+Math.imul(D,ht)|0)+Math.imul(L,ut)|0,o=o+Math.imul(L,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(P,ct)|0,o=o+Math.imul(P,lt)|0;var Pt=(h+(i=i+Math.imul(I,pt)|0)|0)+((8191&(n=(n=n+Math.imul(I,vt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,vt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(k,ot),n=(n=Math.imul(k,st))+Math.imul(B,ot)|0,o=Math.imul(B,st),i=i+Math.imul(x,ut)|0,n=(n=n+Math.imul(x,ht)|0)+Math.imul(U,ut)|0,o=o+Math.imul(U,ht)|0,i=i+Math.imul(D,ct)|0,n=(n=n+Math.imul(D,lt)|0)+Math.imul(L,ct)|0,o=o+Math.imul(L,lt)|0;var St=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,vt)|0)+Math.imul(P,pt)|0))<<13)|0;h=((o=o+Math.imul(P,vt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(k,ut),n=(n=Math.imul(k,ht))+Math.imul(B,ut)|0,o=Math.imul(B,ht),i=i+Math.imul(x,ct)|0,n=(n=n+Math.imul(x,lt)|0)+Math.imul(U,ct)|0,o=o+Math.imul(U,lt)|0;var Dt=(h+(i=i+Math.imul(D,pt)|0)|0)+((8191&(n=(n=n+Math.imul(D,vt)|0)+Math.imul(L,pt)|0))<<13)|0;h=((o=o+Math.imul(L,vt)|0)+(n>>>13)|0)+(Dt>>>26)|0,Dt&=67108863,i=Math.imul(k,ct),n=(n=Math.imul(k,lt))+Math.imul(B,ct)|0,o=Math.imul(B,lt);var Lt=(h+(i=i+Math.imul(x,pt)|0)|0)+((8191&(n=(n=n+Math.imul(x,vt)|0)+Math.imul(U,pt)|0))<<13)|0;h=((o=o+Math.imul(U,vt)|0)+(n>>>13)|0)+(Lt>>>26)|0,Lt&=67108863;var Ct=(h+(i=Math.imul(k,pt))|0)+((8191&(n=(n=Math.imul(k,vt))+Math.imul(B,pt)|0))<<13)|0;return h=((o=Math.imul(B,vt))+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,u[0]=_t,u[1]=mt,u[2]=Et,u[3]=yt,u[4]=At,u[5]=gt,u[6]=wt,u[7]=Tt,u[8]=Mt,u[9]=Nt,u[10]=It,u[11]=Rt,u[12]=Ot,u[13]=bt,u[14]=Pt,u[15]=St,u[16]=Dt,u[17]=Lt,u[18]=Ct,0!==h&&(u[19]=h,r.length++),r};function v(t,e,r){return(new _).mulp(t,e,r)}function _(t,e){this.x=t,this.y=e}Math.imul||(p=f),o.prototype.mulTo=function(t,e){var r,i=this.length+t.length;return r=10===this.length&&10===t.length?p(this,t,e):i<63?f(this,t,e):i<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o<r.length-1;o++){var s=n;n=0;for(var a=67108863&i,u=Math.min(o,e.length-1),h=Math.max(0,o-t.length+1);h<=u;h++){var d=o-h,c=(0|t.words[d])*(0|e.words[h]),l=67108863&c;a=67108863&(l=l+a|0),n+=(s=(s=s+(c/67108864|0)|0)+(l>>>26)|0)>>>26,s&=67108863}r.words[o]=a,i=s,s=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):v(this,t,e),r},_.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i<t;i++)e[i]=this.revBin(i,r,t);return e},_.prototype.revBin=function(t,e,r){if(0===t||t===r-1)return t;for(var i=0,n=0;n<e;n++)i|=(1&t)<<e-n-1,t>>=1;return i},_.prototype.permute=function(t,e,r,i,n,o){for(var s=0;s<o;s++)i[s]=e[t[s]],n[s]=r[t[s]]},_.prototype.transform=function(t,e,r,i,n,o){this.permute(o,t,e,r,i,n);for(var s=1;s<n;s<<=1)for(var a=s<<1,u=Math.cos(2*Math.PI/a),h=Math.sin(2*Math.PI/a),d=0;d<n;d+=a)for(var c=u,l=h,f=0;f<s;f++){var p=r[d+f],v=i[d+f],_=r[d+f+s],m=i[d+f+s],E=c*_-l*m;m=c*m+l*_,_=E,r[d+f]=p+_,i[d+f]=v+m,r[d+f+s]=p-_,i[d+f+s]=v-m,f!==a&&(E=u*c-h*l,l=u*l+h*c,c=E)}},_.prototype.guessLen13b=function(t,e){var r=1|Math.max(e,t),i=1&r,n=0;for(r=r/2|0;r;r>>>=1)n++;return 1<<n+1+i},_.prototype.conjugate=function(t,e,r){if(!(r<=1))for(var i=0;i<r/2;i++){var n=t[i];t[i]=t[r-i-1],t[r-i-1]=n,n=e[i],e[i]=-e[r-i-1],e[r-i-1]=-n}},_.prototype.normalize13b=function(t,e){for(var r=0,i=0;i<e/2;i++){var n=8192*Math.round(t[2*i+1]/e)+Math.round(t[2*i]/e)+r;t[i]=67108863&n,r=n<67108864?0:n/67108864|0}return t},_.prototype.convert13b=function(t,e,r,n){for(var o=0,s=0;s<e;s++)o+=0|t[s],r[2*s]=8191&o,o>>>=13,r[2*s+1]=8191&o,o>>>=13;for(s=2*e;s<n;++s)r[s]=0;i(0===o),i(0==(-8192&o))},_.prototype.stub=function(t){for(var e=new Array(t),r=0;r<t;r++)e[r]=0;return e},_.prototype.mulp=function(t,e,r){var i=2*this.guessLen13b(t.length,e.length),n=this.makeRBT(i),o=this.stub(i),s=new Array(i),a=new Array(i),u=new Array(i),h=new Array(i),d=new Array(i),c=new Array(i),l=r.words;l.length=i,this.convert13b(t.words,t.length,s,i),this.convert13b(e.words,e.length,h,i),this.transform(s,o,a,u,i,n),this.transform(h,o,d,c,i,n);for(var f=0;f<i;f++){var p=a[f]*d[f]-u[f]*c[f];u[f]=a[f]*c[f]+u[f]*d[f],a[f]=p}return this.conjugate(a,u,i),this.transform(a,u,l,o,i,n),this.conjugate(l,o,i),this.normalize13b(l,i),r.negative=t.negative^e.negative,r.length=t.length+e.length,r.strip()},o.prototype.mul=function(t){var e=new o(null);return e.words=new Array(this.length+t.length),this.mulTo(t,e)},o.prototype.mulf=function(t){var e=new o(null);return e.words=new Array(this.length+t.length),v(this,t,e)},o.prototype.imul=function(t){return this.clone().mulTo(t,this)},o.prototype.imuln=function(t){i("number"==typeof t),i(t<67108864);for(var e=0,r=0;r<this.length;r++){var n=(0|this.words[r])*t,o=(67108863&n)+(67108863&e);e>>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r<e.length;r++){var i=r/26|0,n=r%26;e[r]=(t.words[i]&1<<n)>>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i<e.length&&0===e[i];i++,r=r.sqr());if(++i<e.length)for(var n=r.sqr();i<e.length;i++,n=n.sqr())0!==e[i]&&(r=r.mul(n));return r},o.prototype.iushln=function(t){i("number"==typeof t&&t>=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var s=0;for(e=0;e<this.length;e++){var a=this.words[e]&o,u=(0|this.words[e])-a<<r;this.words[e]=u|s,s=a>>>26-r}s&&(this.words[e]=s,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e<n;e++)this.words[e]=0;this.length+=n}return this.strip()},o.prototype.ishln=function(t){return i(0===this.negative),this.iushln(t)},o.prototype.iushrn=function(t,e,r){var n;i("number"==typeof t&&t>=0),n=e?(e-e%26)/26:0;var o=t%26,s=Math.min((t-o)/26,this.length),a=67108863^67108863>>>o<<o,u=r;if(n-=s,n=Math.max(0,n),u){for(var h=0;h<s;h++)u.words[h]=this.words[h];u.length=s}if(0===s);else if(this.length>s)for(this.length-=s,h=0;h<this.length;h++)this.words[h]=this.words[h+s];else this.words[0]=0,this.length=1;var d=0;for(h=this.length-1;h>=0&&(0!==d||h>=n);h--){var c=0|this.words[h];this.words[h]=d<<26-o|c>>>o,d=c&a}return u&&0!==d&&(u.words[u.length++]=d),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"==typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<<e;return!(this.length<=r||!(this.words[r]&n))},o.prototype.imaskn=function(t){i("number"==typeof t&&t>=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<<e;this.words[this.length-1]&=n}return this.strip()},o.prototype.maskn=function(t){return this.clone().imaskn(t)},o.prototype.iaddn=function(t){return i("number"==typeof t),i(t<67108864),t<0?this.isubn(-t):0!==this.negative?1===this.length&&(0|this.words[0])<t?(this.words[0]=t-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(t),this.negative=1,this):this._iaddn(t)},o.prototype._iaddn=function(t){this.words[0]+=t;for(var e=0;e<this.length&&this.words[e]>=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"==typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e<this.length&&this.words[e]<0;e++)this.words[e]+=67108864,this.words[e+1]-=1;return this.strip()},o.prototype.addn=function(t){return this.clone().iaddn(t)},o.prototype.subn=function(t){return this.clone().isubn(t)},o.prototype.iabs=function(){return this.negative=0,this},o.prototype.abs=function(){return this.clone().iabs()},o.prototype._ishlnsubmul=function(t,e,r){var n,o,s=t.length+r;this._expand(s);var a=0;for(n=0;n<t.length;n++){o=(0|this.words[n+r])+a;var u=(0|t.words[n])*e;a=((o-=67108863&u)>>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n<this.length-r;n++)a=(o=(0|this.words[n+r])+a)>>26,this.words[n+r]=67108863&o;if(0===a)return this.strip();for(i(-1===a),a=0,n=0;n<this.length;n++)a=(o=-(0|this.words[n])+a)>>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,s=0|n.words[n.length-1];0!=(r=26-this._countBits(s))&&(n=n.ushln(r),i.iushln(r),s=0|n.words[n.length-1]);var a,u=i.length-n.length;if("mod"!==e){(a=new o(null)).length=u+1,a.words=new Array(a.length);for(var h=0;h<a.length;h++)a.words[h]=0}var d=i.clone()._ishlnsubmul(n,1,u);0===d.negative&&(i=d,a&&(a.words[u]=1));for(var c=u-1;c>=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/s|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);a&&(a.words[c]=l)}return a&&a.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:a||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(a=this.neg().divmod(t,e),"mod"!==e&&(n=a.div.neg()),"div"!==e&&(s=a.mod.neg(),r&&0!==s.negative&&s.iadd(t)),{div:n,mod:s}):0===this.negative&&0!==t.negative?(a=this.divmod(t.neg(),e),"mod"!==e&&(n=a.div.neg()),{div:n,mod:a.mod}):0!=(this.negative&t.negative)?(a=this.neg().divmod(t.neg(),e),"div"!==e&&(s=a.mod.neg(),r&&0!==s.negative&&s.isub(t)),{div:a.div,mod:s}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,s,a},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),s=new o(0),a=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var d=r.clone(),c=e.clone();!e.isZero();){for(var l=0,f=1;0==(e.words[0]&f)&&l<26;++l,f<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||s.isOdd())&&(n.iadd(d),s.isub(c)),n.iushrn(1),s.iushrn(1);for(var p=0,v=1;0==(r.words[0]&v)&&p<26;++p,v<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(a.isOdd()||u.isOdd())&&(a.iadd(d),u.isub(c)),a.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(a),s.isub(u)):(r.isub(e),a.isub(n),u.isub(s))}return{a,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,s=new o(1),a=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,d=1;0==(e.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(e.iushrn(h);h-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);for(var c=0,l=1;0==(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);e.cmp(r)>=0?(e.isub(r),s.isub(a)):(r.isub(e),a.isub(s))}return(n=0===e.cmpn(1)?s:a).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"==typeof t);var e=t%26,r=(t-e)/26,n=1<<e;if(this.length<=r)return this._expand(r+1),this.words[r]|=n,this;for(var o=n,s=r;0!==o&&s<this.length;s++){var a=0|this.words[s];o=(a+=o)>>>26,a&=67108863,this.words[s]=a}return 0!==o&&(this.words[s]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:n<t?-1:1}return 0!==this.negative?0|-e:e},o.prototype.cmp=function(t){if(0!==this.negative&&0===t.negative)return-1;if(0===this.negative&&0!==t.negative)return 1;var e=this.ucmp(t);return 0!==this.negative?0|-e:e},o.prototype.ucmp=function(t){if(this.length>t.length)return 1;if(this.length<t.length)return-1;for(var e=0,r=this.length-1;r>=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){i<n?e=-1:i>n&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new T(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var m={k256:null,p224:null,p192:null,p25519:null};function E(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function y(){E.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function A(){E.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function g(){E.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function w(){E.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function T(t){if("string"==typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function M(t){T.call(this,t),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)}E.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},E.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e<this.n?-1:r.ucmp(this.p);return 0===i?(r.words[0]=0,r.length=1):i>0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},E.prototype.split=function(t,e){t.iushrn(this.n,0,e)},E.prototype.imulK=function(t){return t.imul(this.k)},n(y,E),y.prototype.split=function(t,e){for(var r=4194303,i=Math.min(t.length,9),n=0;n<i;n++)e.words[n]=t.words[n];if(e.length=i,t.length<=9)return t.words[0]=0,void(t.length=1);var o=t.words[9];for(e.words[e.length++]=o&r,n=10;n<t.length;n++){var s=0|t.words[n];t.words[n-10]=(s&r)<<4|o>>>22,o=s}o>>>=22,t.words[n-10]=o,0===o&&t.length>10?t.length-=10:t.length-=9},y.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r<t.length;r++){var i=0|t.words[r];e+=977*i,t.words[r]=67108863&e,e=64*i+(e/67108864|0)}return 0===t.words[t.length-1]&&(t.length--,0===t.words[t.length-1]&&t.length--),t},n(A,E),n(g,E),n(w,E),w.prototype.imulK=function(t){for(var e=0,r=0;r<t.length;r++){var i=19*(0|t.words[r])+e,n=67108863&i;i>>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(m[t])return m[t];var e;if("k256"===t)e=new y;else if("p224"===t)e=new A;else if("p192"===t)e=new g;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new w}return m[t]=e,e},T.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},T.prototype._verify2=function(t,e){i(0==(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},T.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},T.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},T.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},T.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},T.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},T.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},T.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},T.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},T.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},T.prototype.isqr=function(t){return this.imul(t,t.clone())},T.prototype.sqr=function(t){return this.mul(t,t)},T.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2==1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),s=0;!n.isZero()&&0===n.andln(1);)s++,n.iushrn(1);i(!n.isZero());var a=new o(1).toRed(this),u=a.redNeg(),h=this.m.subn(1).iushrn(1),d=this.m.bitLength();for(d=new o(2*d*d).toRed(this);0!==this.pow(d,h).cmp(u);)d.redIAdd(u);for(var c=this.pow(d,n),l=this.pow(t,n.addn(1).iushrn(1)),f=this.pow(t,n),p=s;0!==f.cmp(a);){for(var v=f,_=0;0!==v.cmp(a);_++)v=v.redSqr();i(_<p);var m=this.pow(c,new o(1).iushln(p-_-1));l=l.redMul(m),c=m.redSqr(),f=f.redMul(c),p=_}return l},T.prototype.invm=function(t){var e=t._invmp(this.m);return 0!==e.negative?(e.negative=0,this.imod(e).redNeg()):this.imod(e)},T.prototype.pow=function(t,e){if(e.isZero())return new o(1).toRed(this);if(0===e.cmpn(1))return t.clone();var r=new Array(16);r[0]=new o(1).toRed(this),r[1]=t;for(var i=2;i<r.length;i++)r[i]=this.mul(r[i-1],t);var n=r[0],s=0,a=0,u=e.bitLength()%26;for(0===u&&(u=26),i=e.length-1;i>=0;i--){for(var h=e.words[i],d=u-1;d>=0;d--){var c=h>>d&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==s?(s<<=1,s|=c,(4==++a||0===i&&0===d)&&(n=this.mul(n,r[s]),a=0,s=0)):a=0}u=26}return n},T.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},T.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new M(t)},n(M,T),M.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},M.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},M.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},M.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},M.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t=r.nmd(t),this)},6395:t=>{const e="0123456789abcdef".split(""),r=[1,256,65536,16777216],i=[0,8,16,24],n=[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],o=t=>{var e,r,i,o,s,a,u,h,d,c,l,f,p,v,_,m,E,y,A,g,w,T,M,N,I,R,O,b,P,S,D,L,C,x,U,G,k,B,j,F,Y,V,W,K,X,z,Z,H,q,$,J,Q,tt,et,rt,it,nt,ot,st,at,ut,ht,dt;for(i=0;i<48;i+=2)o=t[0]^t[10]^t[20]^t[30]^t[40],s=t[1]^t[11]^t[21]^t[31]^t[41],a=t[2]^t[12]^t[22]^t[32]^t[42],u=t[3]^t[13]^t[23]^t[33]^t[43],h=t[4]^t[14]^t[24]^t[34]^t[44],d=t[5]^t[15]^t[25]^t[35]^t[45],c=t[6]^t[16]^t[26]^t[36]^t[46],l=t[7]^t[17]^t[27]^t[37]^t[47],e=(f=t[8]^t[18]^t[28]^t[38]^t[48])^(a<<1|u>>>31),r=(p=t[9]^t[19]^t[29]^t[39]^t[49])^(u<<1|a>>>31),t[0]^=e,t[1]^=r,t[10]^=e,t[11]^=r,t[20]^=e,t[21]^=r,t[30]^=e,t[31]^=r,t[40]^=e,t[41]^=r,e=o^(h<<1|d>>>31),r=s^(d<<1|h>>>31),t[2]^=e,t[3]^=r,t[12]^=e,t[13]^=r,t[22]^=e,t[23]^=r,t[32]^=e,t[33]^=r,t[42]^=e,t[43]^=r,e=a^(c<<1|l>>>31),r=u^(l<<1|c>>>31),t[4]^=e,t[5]^=r,t[14]^=e,t[15]^=r,t[24]^=e,t[25]^=r,t[34]^=e,t[35]^=r,t[44]^=e,t[45]^=r,e=h^(f<<1|p>>>31),r=d^(p<<1|f>>>31),t[6]^=e,t[7]^=r,t[16]^=e,t[17]^=r,t[26]^=e,t[27]^=r,t[36]^=e,t[37]^=r,t[46]^=e,t[47]^=r,e=c^(o<<1|s>>>31),r=l^(s<<1|o>>>31),t[8]^=e,t[9]^=r,t[18]^=e,t[19]^=r,t[28]^=e,t[29]^=r,t[38]^=e,t[39]^=r,t[48]^=e,t[49]^=r,v=t[0],_=t[1],z=t[11]<<4|t[10]>>>28,Z=t[10]<<4|t[11]>>>28,b=t[20]<<3|t[21]>>>29,P=t[21]<<3|t[20]>>>29,at=t[31]<<9|t[30]>>>23,ut=t[30]<<9|t[31]>>>23,V=t[40]<<18|t[41]>>>14,W=t[41]<<18|t[40]>>>14,x=t[2]<<1|t[3]>>>31,U=t[3]<<1|t[2]>>>31,m=t[13]<<12|t[12]>>>20,E=t[12]<<12|t[13]>>>20,H=t[22]<<10|t[23]>>>22,q=t[23]<<10|t[22]>>>22,S=t[33]<<13|t[32]>>>19,D=t[32]<<13|t[33]>>>19,ht=t[42]<<2|t[43]>>>30,dt=t[43]<<2|t[42]>>>30,et=t[5]<<30|t[4]>>>2,rt=t[4]<<30|t[5]>>>2,G=t[14]<<6|t[15]>>>26,k=t[15]<<6|t[14]>>>26,y=t[25]<<11|t[24]>>>21,A=t[24]<<11|t[25]>>>21,$=t[34]<<15|t[35]>>>17,J=t[35]<<15|t[34]>>>17,L=t[45]<<29|t[44]>>>3,C=t[44]<<29|t[45]>>>3,N=t[6]<<28|t[7]>>>4,I=t[7]<<28|t[6]>>>4,it=t[17]<<23|t[16]>>>9,nt=t[16]<<23|t[17]>>>9,B=t[26]<<25|t[27]>>>7,j=t[27]<<25|t[26]>>>7,g=t[36]<<21|t[37]>>>11,w=t[37]<<21|t[36]>>>11,Q=t[47]<<24|t[46]>>>8,tt=t[46]<<24|t[47]>>>8,K=t[8]<<27|t[9]>>>5,X=t[9]<<27|t[8]>>>5,R=t[18]<<20|t[19]>>>12,O=t[19]<<20|t[18]>>>12,ot=t[29]<<7|t[28]>>>25,st=t[28]<<7|t[29]>>>25,F=t[38]<<8|t[39]>>>24,Y=t[39]<<8|t[38]>>>24,T=t[48]<<14|t[49]>>>18,M=t[49]<<14|t[48]>>>18,t[0]=v^~m&y,t[1]=_^~E&A,t[10]=N^~R&b,t[11]=I^~O&P,t[20]=x^~G&B,t[21]=U^~k&j,t[30]=K^~z&H,t[31]=X^~Z&q,t[40]=et^~it&ot,t[41]=rt^~nt&st,t[2]=m^~y&g,t[3]=E^~A&w,t[12]=R^~b&S,t[13]=O^~P&D,t[22]=G^~B&F,t[23]=k^~j&Y,t[32]=z^~H&$,t[33]=Z^~q&J,t[42]=it^~ot&at,t[43]=nt^~st&ut,t[4]=y^~g&T,t[5]=A^~w&M,t[14]=b^~S&L,t[15]=P^~D&C,t[24]=B^~F&V,t[25]=j^~Y&W,t[34]=H^~$&Q,t[35]=q^~J&tt,t[44]=ot^~at&ht,t[45]=st^~ut&dt,t[6]=g^~T&v,t[7]=w^~M&_,t[16]=S^~L&N,t[17]=D^~C&I,t[26]=F^~V&x,t[27]=Y^~W&U,t[36]=$^~Q&K,t[37]=J^~tt&X,t[46]=at^~ht&et,t[47]=ut^~dt&rt,t[8]=T^~v&m,t[9]=M^~_&E,t[18]=L^~N&R,t[19]=C^~I&O,t[28]=V^~x&G,t[29]=W^~U&k,t[38]=Q^~K&z,t[39]=tt^~X&Z,t[48]=ht^~et&it,t[49]=dt^~rt&nt,t[0]^=n[i],t[1]^=n[i+1]},s=t=>n=>{var s;if("0x"===n.slice(0,2)){s=[];for(var a=2,u=n.length;a<u;a+=2)s.push(parseInt(n.slice(a,a+2),16))}else s=n;return((t,n)=>{for(var s,a=n.length,u=t.blocks,h=t.blockCount<<2,d=t.blockCount,c=t.outputBlocks,l=t.s,f=0;f<a;){if(t.reset)for(t.reset=!1,u[0]=t.block,_=1;_<d+1;++_)u[_]=0;if("string"!=typeof n)for(_=t.start;f<a&&_<h;++f)u[_>>2]|=n[f]<<i[3&_++];else for(_=t.start;f<a&&_<h;++f)(s=n.charCodeAt(f))<128?u[_>>2]|=s<<i[3&_++]:s<2048?(u[_>>2]|=(192|s>>6)<<i[3&_++],u[_>>2]|=(128|63&s)<<i[3&_++]):s<55296||s>=57344?(u[_>>2]|=(224|s>>12)<<i[3&_++],u[_>>2]|=(128|s>>6&63)<<i[3&_++],u[_>>2]|=(128|63&s)<<i[3&_++]):(s=65536+((1023&s)<<10|1023&n.charCodeAt(++f)),u[_>>2]|=(240|s>>18)<<i[3&_++],u[_>>2]|=(128|s>>12&63)<<i[3&_++],u[_>>2]|=(128|s>>6&63)<<i[3&_++],u[_>>2]|=(128|63&s)<<i[3&_++]);if(t.lastByteIndex=_,_>=h){for(t.start=_-h,t.block=u[d],_=0;_<d;++_)l[_]^=u[_];o(l),t.reset=!0}else t.start=_}if(u[(_=t.lastByteIndex)>>2]|=r[3&_],t.lastByteIndex===h)for(u[0]=u[d],_=1;_<d+1;++_)u[_]=0;for(u[d-1]|=2147483648,_=0;_<d;++_)l[_]^=u[_];o(l);for(var p,v="",_=0,m=0;m<c;){for(_=0;_<d&&m<c;++_,++m)p=l[_],v+=e[p>>4&15]+e[15&p]+e[p>>12&15]+e[p>>8&15]+e[p>>20&15]+e[p>>16&15]+e[p>>28&15]+e[p>>24&15];m%d==0&&(o(l),_=0)}return"0x"+v})((t=>{return{blocks:[],reset:!0,block:0,start:0,blockCount:1600-(t<<1)>>5,outputBlocks:t>>5,s:(e=[0,0,0,0,0,0,0,0,0,0],[].concat(e,e,e,e,e))};var e})(t),s)};t.exports={keccak256:s(256),keccak512:s(512),keccak256s:s(256),keccak512s:s(512)}},1041:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.version="4.0.47"},3850:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=r(2069);e.AddressZero="0x0000000000000000000000000000000000000000",e.HashZero="0x0000000000000000000000000000000000000000000000000000000000000000",e.EtherSymbol="Ξ";var n=i.bigNumberify(-1);e.NegativeOne=n;var o=i.bigNumberify(0);e.Zero=o;var s=i.bigNumberify(1);e.One=s;var a=i.bigNumberify(2);e.Two=a;var u=i.bigNumberify("1000000000000000000");e.WeiPerEther=u;var h=i.bigNumberify("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");e.MaxUint256=h},6666:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=r(1041);e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.MISSING_NEW="MISSING_NEW",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.NUMERIC_FAULT="NUMERIC_FAULT",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION";var n=!1,o=!1;function s(t,r,n){if(o)throw new Error("unknown error");r||(r=e.UNKNOWN_ERROR),n||(n={});var s=[];Object.keys(n).forEach((function(t){try{s.push(t+"="+JSON.stringify(n[t]))}catch(e){s.push(t+"="+JSON.stringify(n[t].toString()))}})),s.push("version="+i.version);var a=t;s.length&&(t+=" ("+s.join(", ")+")");var u=new Error(t);throw u.reason=a,u.code=r,Object.keys(n).forEach((function(t){u[t]=n[t]})),u}e.throwError=s,e.checkNew=function(t,r){t instanceof r||s("missing new",e.MISSING_NEW,{name:r.name})},e.checkArgumentCount=function(t,r,i){i||(i=""),t<r&&s("missing argument"+i,e.MISSING_ARGUMENT,{count:t,expectedCount:r}),t>r&&s("too many arguments"+i,e.UNEXPECTED_ARGUMENT,{count:t,expectedCount:r})},e.setCensorship=function(t,r){n&&s("error censorship permanent",e.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),o=!!t,n=!!r},e.checkNormalize=function(){try{if(["NFD","NFC","NFKD","NFKC"].forEach((function(t){try{"test".normalize(t)}catch(e){throw new Error("missing "+t)}})),String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(t){s("platform missing String.prototype.normalize",e.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:t.message})}};var a={debug:1,default:2,info:2,warn:3,error:4,off:5},u=a.default;function h(t,e){u>a[t]||console.log.apply(console,e)}function d(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];h("warn",t)}e.setLogLevel=function(t){var e=a[t];null!=e?u=e:d("invliad log level - "+t)},e.warn=d,e.info=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];h("info",t)}},4164:(t,e,r)=>{!function(){"use strict";var e="object"==typeof window?window:{};!e.JS_SHA3_NO_NODE_JS&&"object"==typeof process&&process.versions&&process.versions.node&&(e=r.g);for(var i=!e.JS_SHA3_NO_COMMON_JS&&t.exports,n="0123456789abcdef".split(""),o=[0,8,16,24],s=[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],a=[224,256,384,512],u=["hex","buffer","arrayBuffer","array"],h=function(t,e,r){return function(i){return new A(t,e,t).update(i)[r]()}},d=function(t,e,r){return function(i,n){return new A(t,e,n).update(i)[r]()}},c=function(t,e){var r=h(t,e,"hex");r.create=function(){return new A(t,e,t)},r.update=function(t){return r.create().update(t)};for(var i=0;i<u.length;++i){var n=u[i];r[n]=h(t,e,n)}return r},l=[{name:"keccak",padding:[1,256,65536,16777216],bits:a,createMethod:c},{name:"sha3",padding:[6,1536,393216,100663296],bits:a,createMethod:c},{name:"shake",padding:[31,7936,2031616,520093696],bits:[128,256],createMethod:function(t,e){var r=d(t,e,"hex");r.create=function(r){return new A(t,e,r)},r.update=function(t,e){return r.create(e).update(t)};for(var i=0;i<u.length;++i){var n=u[i];r[n]=d(t,e,n)}return r}}],f={},p=[],v=0;v<l.length;++v)for(var _=l[v],m=_.bits,E=0;E<m.length;++E){var y=_.name+"_"+m[E];p.push(y),f[y]=_.createMethod(m[E],_.padding)}function A(t,e,r){this.blocks=[],this.s=[],this.padding=e,this.outputBits=r,this.reset=!0,this.block=0,this.start=0,this.blockCount=1600-(t<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var i=0;i<50;++i)this.s[i]=0}A.prototype.update=function(t){var e="string"!=typeof t;e&&t.constructor===ArrayBuffer&&(t=new Uint8Array(t));for(var r,i,n=t.length,s=this.blocks,a=this.byteCount,u=this.blockCount,h=0,d=this.s;h<n;){if(this.reset)for(this.reset=!1,s[0]=this.block,r=1;r<u+1;++r)s[r]=0;if(e)for(r=this.start;h<n&&r<a;++h)s[r>>2]|=t[h]<<o[3&r++];else for(r=this.start;h<n&&r<a;++h)(i=t.charCodeAt(h))<128?s[r>>2]|=i<<o[3&r++]:i<2048?(s[r>>2]|=(192|i>>6)<<o[3&r++],s[r>>2]|=(128|63&i)<<o[3&r++]):i<55296||i>=57344?(s[r>>2]|=(224|i>>12)<<o[3&r++],s[r>>2]|=(128|i>>6&63)<<o[3&r++],s[r>>2]|=(128|63&i)<<o[3&r++]):(i=65536+((1023&i)<<10|1023&t.charCodeAt(++h)),s[r>>2]|=(240|i>>18)<<o[3&r++],s[r>>2]|=(128|i>>12&63)<<o[3&r++],s[r>>2]|=(128|i>>6&63)<<o[3&r++],s[r>>2]|=(128|63&i)<<o[3&r++]);if(this.lastByteIndex=r,r>=a){for(this.start=r-a,this.block=s[u],r=0;r<u;++r)d[r]^=s[r];g(d),this.reset=!0}else this.start=r}return this},A.prototype.finalize=function(){var t=this.blocks,e=this.lastByteIndex,r=this.blockCount,i=this.s;if(t[e>>2]|=this.padding[3&e],this.lastByteIndex===this.byteCount)for(t[0]=t[r],e=1;e<r+1;++e)t[e]=0;for(t[r-1]|=2147483648,e=0;e<r;++e)i[e]^=t[e];g(i)},A.prototype.toString=A.prototype.hex=function(){this.finalize();for(var t,e=this.blockCount,r=this.s,i=this.outputBlocks,o=this.extraBytes,s=0,a=0,u="";a<i;){for(s=0;s<e&&a<i;++s,++a)t=r[s],u+=n[t>>4&15]+n[15&t]+n[t>>12&15]+n[t>>8&15]+n[t>>20&15]+n[t>>16&15]+n[t>>28&15]+n[t>>24&15];a%e==0&&(g(r),s=0)}return o&&(t=r[s],o>0&&(u+=n[t>>4&15]+n[15&t]),o>1&&(u+=n[t>>12&15]+n[t>>8&15]),o>2&&(u+=n[t>>20&15]+n[t>>16&15])),u},A.prototype.arrayBuffer=function(){this.finalize();var t,e=this.blockCount,r=this.s,i=this.outputBlocks,n=this.extraBytes,o=0,s=0,a=this.outputBits>>3;t=n?new ArrayBuffer(i+1<<2):new ArrayBuffer(a);for(var u=new Uint32Array(t);s<i;){for(o=0;o<e&&s<i;++o,++s)u[s]=r[o];s%e==0&&g(r)}return n&&(u[o]=r[o],t=t.slice(0,a)),t},A.prototype.buffer=A.prototype.arrayBuffer,A.prototype.digest=A.prototype.array=function(){this.finalize();for(var t,e,r=this.blockCount,i=this.s,n=this.outputBlocks,o=this.extraBytes,s=0,a=0,u=[];a<n;){for(s=0;s<r&&a<n;++s,++a)t=a<<2,e=i[s],u[t]=255&e,u[t+1]=e>>8&255,u[t+2]=e>>16&255,u[t+3]=e>>24&255;a%r==0&&g(i)}return o&&(t=a<<2,e=i[s],o>0&&(u[t]=255&e),o>1&&(u[t+1]=e>>8&255),o>2&&(u[t+2]=e>>16&255)),u};var g=function(t){var e,r,i,n,o,a,u,h,d,c,l,f,p,v,_,m,E,y,A,g,w,T,M,N,I,R,O,b,P,S,D,L,C,x,U,G,k,B,j,F,Y,V,W,K,X,z,Z,H,q,$,J,Q,tt,et,rt,it,nt,ot,st,at,ut,ht,dt;for(i=0;i<48;i+=2)n=t[0]^t[10]^t[20]^t[30]^t[40],o=t[1]^t[11]^t[21]^t[31]^t[41],a=t[2]^t[12]^t[22]^t[32]^t[42],u=t[3]^t[13]^t[23]^t[33]^t[43],h=t[4]^t[14]^t[24]^t[34]^t[44],d=t[5]^t[15]^t[25]^t[35]^t[45],c=t[6]^t[16]^t[26]^t[36]^t[46],l=t[7]^t[17]^t[27]^t[37]^t[47],e=(f=t[8]^t[18]^t[28]^t[38]^t[48])^(a<<1|u>>>31),r=(p=t[9]^t[19]^t[29]^t[39]^t[49])^(u<<1|a>>>31),t[0]^=e,t[1]^=r,t[10]^=e,t[11]^=r,t[20]^=e,t[21]^=r,t[30]^=e,t[31]^=r,t[40]^=e,t[41]^=r,e=n^(h<<1|d>>>31),r=o^(d<<1|h>>>31),t[2]^=e,t[3]^=r,t[12]^=e,t[13]^=r,t[22]^=e,t[23]^=r,t[32]^=e,t[33]^=r,t[42]^=e,t[43]^=r,e=a^(c<<1|l>>>31),r=u^(l<<1|c>>>31),t[4]^=e,t[5]^=r,t[14]^=e,t[15]^=r,t[24]^=e,t[25]^=r,t[34]^=e,t[35]^=r,t[44]^=e,t[45]^=r,e=h^(f<<1|p>>>31),r=d^(p<<1|f>>>31),t[6]^=e,t[7]^=r,t[16]^=e,t[17]^=r,t[26]^=e,t[27]^=r,t[36]^=e,t[37]^=r,t[46]^=e,t[47]^=r,e=c^(n<<1|o>>>31),r=l^(o<<1|n>>>31),t[8]^=e,t[9]^=r,t[18]^=e,t[19]^=r,t[28]^=e,t[29]^=r,t[38]^=e,t[39]^=r,t[48]^=e,t[49]^=r,v=t[0],_=t[1],z=t[11]<<4|t[10]>>>28,Z=t[10]<<4|t[11]>>>28,b=t[20]<<3|t[21]>>>29,P=t[21]<<3|t[20]>>>29,at=t[31]<<9|t[30]>>>23,ut=t[30]<<9|t[31]>>>23,V=t[40]<<18|t[41]>>>14,W=t[41]<<18|t[40]>>>14,x=t[2]<<1|t[3]>>>31,U=t[3]<<1|t[2]>>>31,m=t[13]<<12|t[12]>>>20,E=t[12]<<12|t[13]>>>20,H=t[22]<<10|t[23]>>>22,q=t[23]<<10|t[22]>>>22,S=t[33]<<13|t[32]>>>19,D=t[32]<<13|t[33]>>>19,ht=t[42]<<2|t[43]>>>30,dt=t[43]<<2|t[42]>>>30,et=t[5]<<30|t[4]>>>2,rt=t[4]<<30|t[5]>>>2,G=t[14]<<6|t[15]>>>26,k=t[15]<<6|t[14]>>>26,y=t[25]<<11|t[24]>>>21,A=t[24]<<11|t[25]>>>21,$=t[34]<<15|t[35]>>>17,J=t[35]<<15|t[34]>>>17,L=t[45]<<29|t[44]>>>3,C=t[44]<<29|t[45]>>>3,N=t[6]<<28|t[7]>>>4,I=t[7]<<28|t[6]>>>4,it=t[17]<<23|t[16]>>>9,nt=t[16]<<23|t[17]>>>9,B=t[26]<<25|t[27]>>>7,j=t[27]<<25|t[26]>>>7,g=t[36]<<21|t[37]>>>11,w=t[37]<<21|t[36]>>>11,Q=t[47]<<24|t[46]>>>8,tt=t[46]<<24|t[47]>>>8,K=t[8]<<27|t[9]>>>5,X=t[9]<<27|t[8]>>>5,R=t[18]<<20|t[19]>>>12,O=t[19]<<20|t[18]>>>12,ot=t[29]<<7|t[28]>>>25,st=t[28]<<7|t[29]>>>25,F=t[38]<<8|t[39]>>>24,Y=t[39]<<8|t[38]>>>24,T=t[48]<<14|t[49]>>>18,M=t[49]<<14|t[48]>>>18,t[0]=v^~m&y,t[1]=_^~E&A,t[10]=N^~R&b,t[11]=I^~O&P,t[20]=x^~G&B,t[21]=U^~k&j,t[30]=K^~z&H,t[31]=X^~Z&q,t[40]=et^~it&ot,t[41]=rt^~nt&st,t[2]=m^~y&g,t[3]=E^~A&w,t[12]=R^~b&S,t[13]=O^~P&D,t[22]=G^~B&F,t[23]=k^~j&Y,t[32]=z^~H&$,t[33]=Z^~q&J,t[42]=it^~ot&at,t[43]=nt^~st&ut,t[4]=y^~g&T,t[5]=A^~w&M,t[14]=b^~S&L,t[15]=P^~D&C,t[24]=B^~F&V,t[25]=j^~Y&W,t[34]=H^~$&Q,t[35]=q^~J&tt,t[44]=ot^~at&ht,t[45]=st^~ut&dt,t[6]=g^~T&v,t[7]=w^~M&_,t[16]=S^~L&N,t[17]=D^~C&I,t[26]=F^~V&x,t[27]=Y^~W&U,t[36]=$^~Q&K,t[37]=J^~tt&X,t[46]=at^~ht&et,t[47]=ut^~dt&rt,t[8]=T^~v&m,t[9]=M^~_&E,t[18]=L^~N&R,t[19]=C^~I&O,t[28]=V^~x&G,t[29]=W^~U&k,t[38]=Q^~K&z,t[39]=tt^~X&Z,t[48]=ht^~et&it,t[49]=dt^~rt&nt,t[0]^=s[i],t[1]^=s[i+1]};if(i)t.exports=f;else for(v=0;v<p.length;++v)e[p[v]]=f[p[v]]}()},861:function(t,e,r){"use strict";var i,n=this&&this.__extends||(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}),o=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e};Object.defineProperty(e,"__esModule",{value:!0});var s=r(3850),a=o(r(6666)),u=r(2990),h=r(2069),d=r(2453),c=r(9469),l=r(589),f=new RegExp(/^bytes([0-9]*)$/),p=new RegExp(/^(u?int)([0-9]*)$/),v=new RegExp(/^(.*)\[([0-9]*)\]$/);e.defaultCoerceFunc=function(t,e){var r=t.match(p);return r&&parseInt(r[2])<=48?e.toNumber():e};var _=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$"),m=new RegExp("^[A-Za-z_][A-Za-z0-9_]*$");function E(t){return t.match(/^uint($|[^1-9])/)?t="uint256"+t.substring(4):t.match(/^int($|[^1-9])/)&&(t="int256"+t.substring(3)),t}function y(t,e){var r=t;function i(t){throw new Error('unexpected character "'+r[t]+'" at position '+t+' in "'+r+'"')}t=t.replace(/\s/g," ");for(var n={type:"",name:"",state:{allowType:!0}},o=n,s=0;s<t.length;s++){var a=t[s];switch(a){case"(":o.state.allowParams||i(s),o.state.allowType=!1,o.type=E(o.type),o.components=[{type:"",name:"",parent:o,state:{allowType:!0}}],o=o.components[0];break;case")":delete o.state,e&&"indexed"===o.name&&(o.indexed=!0,o.name=""),o.type=E(o.type);var u=o;(o=o.parent)||i(s),delete u.parent,o.state.allowParams=!1,o.state.allowName=!0,o.state.allowArray=!0;break;case",":delete o.state,e&&"indexed"===o.name&&(o.indexed=!0,o.name=""),o.type=E(o.type);var h={type:"",name:"",parent:o.parent,state:{allowType:!0}};o.parent.components.push(h),delete o.parent,o=h;break;case" ":o.state.allowType&&""!==o.type&&(o.type=E(o.type),delete o.state.allowType,o.state.allowName=!0,o.state.allowParams=!0),o.state.allowName&&""!==o.name&&(e&&"indexed"===o.name?(o.indexed=!0,o.name=""):o.state.allowName=!1);break;case"[":o.state.allowArray||i(s),o.type+=a,o.state.allowArray=!1,o.state.allowName=!1,o.state.readArray=!0;break;case"]":o.state.readArray||i(s),o.type+=a,o.state.readArray=!1,o.state.allowArray=!0,o.state.allowName=!0;break;default:o.state.allowType?(o.type+=a,o.state.allowParams=!0,o.state.allowArray=!0):o.state.allowName?(o.name+=a,delete o.state.allowArray):o.state.readArray?o.type+=a:i(s)}}if(o.parent)throw new Error("unexpected eof");return delete n.state,e&&"indexed"===o.name&&(o.indexed=!0,o.name=""),n.type=E(n.type),n}function A(t){return j(e.defaultCoerceFunc,t).type}e.parseParamType=function(t){return y(t,!0)},e.formatParamType=A,e.formatSignature=function(t){return t.name+"("+t.inputs.map((function(t){return A(t)})).join(",")+")"},e.parseSignature=function(t){if("string"==typeof t)return"event "===(t=(t=(t=t.replace(/\s/g," ")).replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," ")).trim()).substring(0,6)?function(t){var e={anonymous:!1,inputs:[],name:"",type:"event"},r=t.match(_);if(!r)throw new Error("invalid event: "+t);if(e.name=r[1].trim(),k(r[2]).forEach((function(t){(t=y(t,!0)).indexed=!!t.indexed,e.inputs.push(t)})),r[3].split(" ").forEach((function(t){switch(t){case"anonymous":e.anonymous=!0;break;case"":break;default:a.info("unknown modifier: "+t)}})),e.name&&!e.name.match(m))throw new Error('invalid identifier: "'+e.name+'"');return e}(t.substring(6).trim()):("function "===t.substring(0,9)&&(t=t.substring(9)),function(t){var e={constant:!1,gas:null,inputs:[],name:"",outputs:[],payable:!1,stateMutability:null,type:"function"},r=t.split("@");if(1!==r.length){if(r.length>2)throw new Error("invalid signature");if(!r[1].match(/^[0-9]+$/))throw new Error("invalid signature gas");e.gas=h.bigNumberify(r[1]),t=r[0]}var i=(r=t.split(" returns "))[0].match(_);if(!i)throw new Error("invalid signature");if(e.name=i[1].trim(),!e.name.match(m))throw new Error('invalid identifier: "'+i[1]+'"');if(k(i[2]).forEach((function(t){e.inputs.push(y(t))})),i[3].split(" ").forEach((function(t){switch(t){case"constant":e.constant=!0;break;case"payable":e.payable=!0,e.stateMutability="payable";break;case"pure":e.constant=!0,e.stateMutability="pure";break;case"view":e.constant=!0,e.stateMutability="view";break;case"external":case"public":case"":break;default:a.info("unknown modifier: "+t)}})),r.length>1){var n=r[1].match(_);if(""!=n[1].trim()||""!=n[3].trim())throw new Error("unexpected tokens");k(n[2]).forEach((function(t){e.outputs.push(y(t))}))}if("constructor"===e.name){if(e.type="constructor",e.outputs.length)throw new Error("constructor may not have outputs");delete e.name,delete e.outputs}return e}(t.trim()));throw new Error("unknown signature")};var g=function(t,e,r,i,n){this.coerceFunc=t,this.name=e,this.type=r,this.localName=i,this.dynamic=n},w=function(t){function e(e){var r=t.call(this,e.coerceFunc,e.name,e.type,void 0,e.dynamic)||this;return l.defineReadOnly(r,"coder",e),r}return n(e,t),e.prototype.encode=function(t){return this.coder.encode(t)},e.prototype.decode=function(t,e){return this.coder.decode(t,e)},e}(g),T=function(t){function e(e,r){return t.call(this,e,"null","",r,!1)||this}return n(e,t),e.prototype.encode=function(t){return d.arrayify([])},e.prototype.decode=function(t,e){if(e>t.length)throw new Error("invalid null");return{consumed:0,value:this.coerceFunc("null",void 0)}},e}(g),M=function(t){function e(e,r,i,n){var o=this,s=(i?"int":"uint")+8*r;return(o=t.call(this,e,s,s,n,!1)||this).size=r,o.signed=i,o}return n(e,t),e.prototype.encode=function(t){try{var e=h.bigNumberify(t);if(this.signed){var r=s.MaxUint256.maskn(8*this.size-1);if(e.gt(r))throw new Error("out-of-bounds");if(r=r.add(s.One).mul(s.NegativeOne),e.lt(r))throw new Error("out-of-bounds")}else if(e.lt(s.Zero)||e.gt(s.MaxUint256.maskn(8*this.size)))throw new Error("out-of-bounds");return e=e.toTwos(8*this.size).maskn(8*this.size),this.signed&&(e=e.fromTwos(8*this.size).toTwos(256)),d.padZeros(d.arrayify(e),32)}catch(e){a.throwError("invalid number value",a.INVALID_ARGUMENT,{arg:this.localName,coderType:this.name,value:t})}return null},e.prototype.decode=function(t,e){t.length<e+32&&a.throwError("insufficient data for "+this.name+" type",a.INVALID_ARGUMENT,{arg:this.localName,coderType:this.name,value:d.hexlify(t.slice(e,e+32))});var r=32-this.size,i=h.bigNumberify(t.slice(e+r,e+32));return i=this.signed?i.fromTwos(8*this.size):i.maskn(8*this.size),{consumed:32,value:this.coerceFunc(this.name,i)}},e}(g),N=new M((function(t,e){return e}),32,!1,"none"),I=function(t){function e(e,r){return t.call(this,e,"bool","bool",r,!1)||this}return n(e,t),e.prototype.encode=function(t){return N.encode(t?1:0)},e.prototype.decode=function(t,e){try{var r=N.decode(t,e)}catch(t){throw"insufficient data for uint256 type"===t.reason&&a.throwError("insufficient data for boolean type",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"boolean",value:t.value}),t}return{consumed:r.consumed,value:this.coerceFunc("bool",!r.value.isZero())}},e}(g),R=function(t){function e(e,r,i){var n=this,o="bytes"+r;return(n=t.call(this,e,o,o,i,!1)||this).length=r,n}return n(e,t),e.prototype.encode=function(t){var e=new Uint8Array(32);try{var r=d.arrayify(t);if(r.length!==this.length)throw new Error("incorrect data length");e.set(r)}catch(e){a.throwError("invalid "+this.name+" value",a.INVALID_ARGUMENT,{arg:this.localName,coderType:this.name,value:e.value||t})}return e},e.prototype.decode=function(t,e){return t.length<e+32&&a.throwError("insufficient data for "+this.name+" type",a.INVALID_ARGUMENT,{arg:this.localName,coderType:this.name,value:d.hexlify(t.slice(e,e+32))}),{consumed:32,value:this.coerceFunc(this.name,d.hexlify(t.slice(e,e+this.length)))}},e}(g),O=function(t){function e(e,r){return t.call(this,e,"address","address",r,!1)||this}return n(e,t),e.prototype.encode=function(t){var e=new Uint8Array(32);try{e.set(d.arrayify(u.getAddress(t)),12)}catch(e){a.throwError("invalid address",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"address",value:t})}return e},e.prototype.decode=function(t,e){return t.length<e+32&&a.throwError("insufficient data for address type",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"address",value:d.hexlify(t.slice(e,e+32))}),{consumed:32,value:this.coerceFunc("address",u.getAddress(d.hexlify(t.slice(e+12,e+32))))}},e}(g);function b(t){var e=32*Math.ceil(t.length/32),r=new Uint8Array(e-t.length);return d.concat([N.encode(t.length),t,r])}function P(t,e,r){t.length<e+32&&a.throwError("insufficient data for dynamicBytes length",a.INVALID_ARGUMENT,{arg:r,coderType:"dynamicBytes",value:d.hexlify(t.slice(e,e+32))});var i=N.decode(t,e).value;try{i=i.toNumber()}catch(t){a.throwError("dynamic bytes count too large",a.INVALID_ARGUMENT,{arg:r,coderType:"dynamicBytes",value:i.toString()})}return t.length<e+32+i&&a.throwError("insufficient data for dynamicBytes type",a.INVALID_ARGUMENT,{arg:r,coderType:"dynamicBytes",value:d.hexlify(t.slice(e,e+32+i))}),{consumed:32+32*Math.ceil(i/32),value:t.slice(e+32,e+32+i)}}var S=function(t){function e(e,r){return t.call(this,e,"bytes","bytes",r,!0)||this}return n(e,t),e.prototype.encode=function(t){try{return b(d.arrayify(t))}catch(t){a.throwError("invalid bytes value",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"bytes",value:t.value})}return null},e.prototype.decode=function(t,e){var r=P(t,e,this.localName);return r.value=this.coerceFunc("bytes",d.hexlify(r.value)),r},e}(g),D=function(t){function e(e,r){return t.call(this,e,"string","string",r,!0)||this}return n(e,t),e.prototype.encode=function(t){return"string"!=typeof t&&a.throwError("invalid string value",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"string",value:t}),b(c.toUtf8Bytes(t))},e.prototype.decode=function(t,e){var r=P(t,e,this.localName);return r.value=this.coerceFunc("string",c.toUtf8String(r.value)),r},e}(g);function L(t){return 32*Math.ceil(t/32)}function C(t,e){if(Array.isArray(e));else if(e&&"object"==typeof e){var r=[];t.forEach((function(t){r.push(e[t.localName])})),e=r}else a.throwError("invalid tuple value",a.INVALID_ARGUMENT,{coderType:"tuple",value:e});t.length!==e.length&&a.throwError("types/value length mismatch",a.INVALID_ARGUMENT,{coderType:"tuple",value:e});var i=[];t.forEach((function(t,r){i.push({dynamic:t.dynamic,value:t.encode(e[r])})}));var n=0,o=0;i.forEach((function(t){t.dynamic?(n+=32,o+=L(t.value.length)):n+=L(t.value.length)}));var s=0,u=n,h=new Uint8Array(n+o);return i.forEach((function(t){t.dynamic?(h.set(N.encode(u),s),s+=32,h.set(t.value,u),u+=L(t.value.length)):(h.set(t.value,s),s+=L(t.value.length))})),h}function x(t,e,r){var i=r,n=0,o=[];return t.forEach((function(t){if(t.dynamic){var s=N.decode(e,r);(a=t.decode(e,i+s.value.toNumber())).consumed=s.consumed}else var a=t.decode(e,r);null!=a.value&&o.push(a.value),r+=a.consumed,n+=a.consumed})),t.forEach((function(t,e){var r=t.localName;r&&("length"===r&&(r="_length"),null==o[r]&&(o[r]=o[e]))})),{value:o,consumed:n}}var U=function(t){function e(e,r,i,n){var o=this,s=r.type+"["+(i>=0?i:"")+"]",a=-1===i||r.dynamic;return(o=t.call(this,e,"array",s,n,a)||this).coder=r,o.length=i,o}return n(e,t),e.prototype.encode=function(t){Array.isArray(t)||a.throwError("expected array value",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"array",value:t});var e=this.length,r=new Uint8Array(0);-1===e&&(e=t.length,r=N.encode(e)),a.checkArgumentCount(e,t.length," in coder array"+(this.localName?" "+this.localName:""));for(var i=[],n=0;n<t.length;n++)i.push(this.coder);return d.concat([r,C(i,t)])},e.prototype.decode=function(t,e){var r=0,i=this.length;if(-1===i){try{var n=N.decode(t,e)}catch(t){a.throwError("insufficient data for dynamic array length",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"array",value:t.value})}try{i=n.value.toNumber()}catch(t){a.throwError("array count too large",a.INVALID_ARGUMENT,{arg:this.localName,coderType:"array",value:n.value.toString()})}r+=n.consumed,e+=n.consumed}for(var o=[],s=0;s<i;s++)o.push(new w(this.coder));var u=x(o,t,e);return u.consumed+=r,u.value=this.coerceFunc(this.type,u.value),u},e}(g),G=function(t){function e(e,r,i){var n=this,o=!1,s=[];r.forEach((function(t){t.dynamic&&(o=!0),s.push(t.type)}));var a="tuple("+s.join(",")+")";return(n=t.call(this,e,"tuple",a,i,o)||this).coders=r,n}return n(e,t),e.prototype.encode=function(t){return C(this.coders,t)},e.prototype.decode=function(t,e){var r=x(this.coders,t,e);return r.value=this.coerceFunc(this.type,r.value),r},e}(g);function k(t){t=t.trim();for(var e=[],r="",i=0,n=0;n<t.length;n++){var o=t[n];if(","===o&&0===i)e.push(r),r="";else if(r+=o,"("===o)i++;else if(")"===o&&-1==--i)throw new Error("unbalanced parenthsis")}return r&&e.push(r),e}var B={address:O,bool:I,string:D,bytes:S};function j(t,e){var r,i=B[e.type];if(i)return new i(t,e.name);if(r=e.type.match(p))return(0===(n=parseInt(r[2]||"256"))||n>256||n%8!=0)&&a.throwError("invalid "+r[1]+" bit length",a.INVALID_ARGUMENT,{arg:"param",value:e}),new M(t,n/8,"int"===r[1],e.name);if(r=e.type.match(f))return(0===(n=parseInt(r[1]))||n>32)&&a.throwError("invalid bytes length",a.INVALID_ARGUMENT,{arg:"param",value:e}),new R(t,n,e.name);if(r=e.type.match(v)){var n=parseInt(r[2]||"-1");return(e=l.shallowCopy(e)).type=r[1],e=l.deepCopy(e),new U(t,j(t,e),n,e.name)}return"tuple"===e.type.substring(0,5)?function(t,e,r){e||(e=[]);var i=[];return e.forEach((function(e){i.push(j(t,e))})),new G(t,i,r)}(t,e.components,e.name):""===e.type?new T(t,e.name):(a.throwError("invalid type",a.INVALID_ARGUMENT,{arg:"type",value:e.type}),null)}var F=function(){function t(r){a.checkNew(this,t),r||(r=e.defaultCoerceFunc),l.defineReadOnly(this,"coerceFunc",r)}return t.prototype.encode=function(t,e){t.length!==e.length&&a.throwError("types/values length mismatch",a.INVALID_ARGUMENT,{count:{types:t.length,values:e.length},value:{types:t,values:e}});var r=[];return t.forEach((function(t){var e;e="string"==typeof t?y(t):t,r.push(j(this.coerceFunc,e))}),this),d.hexlify(new G(this.coerceFunc,r,"_").encode(e))},t.prototype.decode=function(t,e){var r=[];return t.forEach((function(t){var e;e="string"==typeof t?y(t):l.deepCopy(t),r.push(j(this.coerceFunc,e))}),this),new G(this.coerceFunc,r,"_").decode(d.arrayify(e),0).value},t}();e.AbiCoder=F,e.defaultAbiCoder=new F},2990:function(t,e,r){"use strict";var i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var n=i(r(1303)),o=r(2453),s=r(7839),a=r(8854),u=r(6666);function h(t){"string"==typeof t&&t.match(/^0x[0-9A-Fa-f]{40}$/)||u.throwError("invalid address",u.INVALID_ARGUMENT,{arg:"address",value:t});for(var e=(t=t.toLowerCase()).substring(2).split(""),r=new Uint8Array(40),i=0;i<40;i++)r[i]=e[i].charCodeAt(0);r=o.arrayify(s.keccak256(r));for(var n=0;n<40;n+=2)r[n>>1]>>4>=8&&(e[n]=e[n].toUpperCase()),(15&r[n>>1])>=8&&(e[n+1]=e[n+1].toUpperCase());return"0x"+e.join("")}for(var d={},c=0;c<10;c++)d[String(c)]=String(c);for(c=0;c<26;c++)d[String.fromCharCode(65+c)]=String(10+c);var l,f=Math.floor((l=9007199254740991,Math.log10?Math.log10(l):Math.log(l)/Math.LN10));function p(t){t=(t=t.toUpperCase()).substring(4)+t.substring(0,2)+"00";var e="";for(t.split("").forEach((function(t){e+=d[t]}));e.length>=f;){var r=e.substring(0,f);e=parseInt(r,10)%97+e.substring(r.length)}for(var i=String(98-parseInt(e,10)%97);i.length<2;)i="0"+i;return i}function v(t){var e=null;if("string"!=typeof t&&u.throwError("invalid address",u.INVALID_ARGUMENT,{arg:"address",value:t}),t.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==t.substring(0,2)&&(t="0x"+t),e=h(t),t.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&e!==t&&u.throwError("bad address checksum",u.INVALID_ARGUMENT,{arg:"address",value:t});else if(t.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(t.substring(2,4)!==p(t)&&u.throwError("bad icap checksum",u.INVALID_ARGUMENT,{arg:"address",value:t}),e=new n.default.BN(t.substring(4),36).toString(16);e.length<40;)e="0"+e;e=h("0x"+e)}else u.throwError("invalid address",u.INVALID_ARGUMENT,{arg:"address",value:t});return e}e.getAddress=v,e.getIcapAddress=function(t){for(var e=new n.default.BN(v(t).substring(2),16).toString(36).toUpperCase();e.length<30;)e="0"+e;return"XE"+p("XE00"+e)+e},e.getContractAddress=function(t){if(!t.from)throw new Error("missing from address");var e=t.nonce;return v("0x"+s.keccak256(a.encode([v(t.from),o.stripZeros(o.hexlify(e))])).substring(26))},e.getCreate2Address=function(t){var e=t.initCodeHash;t.initCode&&(e?s.keccak256(t.initCode)!==e&&u.throwError("initCode/initCodeHash mismatch",u.INVALID_ARGUMENT,{arg:"options",value:t}):e=s.keccak256(t.initCode)),e||u.throwError("missing initCode or initCodeHash",u.INVALID_ARGUMENT,{arg:"options",value:t});var r=v(t.from),i=o.arrayify(t.salt);return 32!==i.length&&u.throwError("invalid salt",u.INVALID_ARGUMENT,{arg:"options",value:t}),v("0x"+s.keccak256(o.concat(["0xff",r,i,e])).substring(26))}},2069:function(t,e,r){"use strict";var i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}},n=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e};Object.defineProperty(e,"__esModule",{value:!0});var o=i(r(1303)),s=r(2453),a=r(589),u=n(r(6666)),h=new o.default.BN(-1);function d(t){var e=t.toString(16);return"-"===e[0]?e.length%2==0?"-0x0"+e.substring(1):"-0x"+e.substring(1):e.length%2==1?"0x0"+e:"0x"+e}function c(t){return f(v(t))}function l(t){return new p(d(t))}function f(t){var e=t._hex;return"-"===e[0]?new o.default.BN(e.substring(3),16).mul(h):new o.default.BN(e.substring(2),16)}var p=function(){function t(e){if(u.checkNew(this,t),a.setType(this,"BigNumber"),"string"==typeof e)s.isHexString(e)?("0x"==e&&(e="0x0"),a.defineReadOnly(this,"_hex",e)):"-"===e[0]&&s.isHexString(e.substring(1))?a.defineReadOnly(this,"_hex",e):e.match(/^-?[0-9]*$/)?(""==e&&(e="0"),a.defineReadOnly(this,"_hex",d(new o.default.BN(e)))):u.throwError("invalid BigNumber string value",u.INVALID_ARGUMENT,{arg:"value",value:e});else if("number"==typeof e){parseInt(String(e))!==e&&u.throwError("underflow",u.NUMERIC_FAULT,{operation:"setValue",fault:"underflow",value:e,outputValue:parseInt(String(e))});try{a.defineReadOnly(this,"_hex",d(new o.default.BN(e)))}catch(t){u.throwError("overflow",u.NUMERIC_FAULT,{operation:"setValue",fault:"overflow",details:t.message})}}else e instanceof t?a.defineReadOnly(this,"_hex",e._hex):e.toHexString?a.defineReadOnly(this,"_hex",d(c(e.toHexString()))):e._hex&&s.isHexString(e._hex)?a.defineReadOnly(this,"_hex",e._hex):s.isArrayish(e)?a.defineReadOnly(this,"_hex",d(new o.default.BN(s.hexlify(e).substring(2),16))):u.throwError("invalid BigNumber value",u.INVALID_ARGUMENT,{arg:"value",value:e})}return t.prototype.fromTwos=function(t){return l(f(this).fromTwos(t))},t.prototype.toTwos=function(t){return l(f(this).toTwos(t))},t.prototype.abs=function(){return"-"===this._hex[0]?l(f(this).mul(h)):this},t.prototype.add=function(t){return l(f(this).add(c(t)))},t.prototype.sub=function(t){return l(f(this).sub(c(t)))},t.prototype.div=function(t){return v(t).isZero()&&u.throwError("division by zero",u.NUMERIC_FAULT,{operation:"divide",fault:"division by zero"}),l(f(this).div(c(t)))},t.prototype.mul=function(t){return l(f(this).mul(c(t)))},t.prototype.mod=function(t){return l(f(this).mod(c(t)))},t.prototype.pow=function(t){return l(f(this).pow(c(t)))},t.prototype.maskn=function(t){return l(f(this).maskn(t))},t.prototype.eq=function(t){return f(this).eq(c(t))},t.prototype.lt=function(t){return f(this).lt(c(t))},t.prototype.lte=function(t){return f(this).lte(c(t))},t.prototype.gt=function(t){return f(this).gt(c(t))},t.prototype.gte=function(t){return f(this).gte(c(t))},t.prototype.isZero=function(){return f(this).isZero()},t.prototype.toNumber=function(){try{return f(this).toNumber()}catch(t){u.throwError("overflow",u.NUMERIC_FAULT,{operation:"setValue",fault:"overflow",details:t.message})}return null},t.prototype.toString=function(){return f(this).toString(10)},t.prototype.toHexString=function(){return this._hex},t.isBigNumber=function(t){return a.isType(t,"BigNumber")},t}();function v(t){return p.isBigNumber(t)?t:new p(t)}e.BigNumber=p,e.bigNumberify=v},2453:function(t,e,r){"use strict";var i=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e};Object.defineProperty(e,"__esModule",{value:!0});var n=i(r(6666));function o(t){return!!t.toHexString}function s(t){return t.slice||(t.slice=function(){var e=Array.prototype.slice.call(arguments);return s(new Uint8Array(Array.prototype.slice.apply(t,e)))}),t}function a(t){if(!t||parseInt(String(t.length))!=t.length||"string"==typeof t)return!1;for(var e=0;e<t.length;e++){var r=t[e];if(r<0||r>=256||parseInt(String(r))!=r)return!1}return!0}function u(t){if(null==t&&n.throwError("cannot convert null value to array",n.INVALID_ARGUMENT,{arg:"value",value:t}),o(t)&&(t=t.toHexString()),"string"==typeof t){var e=t.match(/^(0x)?[0-9a-fA-F]*$/);e||n.throwError("invalid hexidecimal string",n.INVALID_ARGUMENT,{arg:"value",value:t}),"0x"!==e[1]&&n.throwError("hex string must have 0x prefix",n.INVALID_ARGUMENT,{arg:"value",value:t}),(t=t.substring(2)).length%2&&(t="0"+t);for(var r=[],i=0;i<t.length;i+=2)r.push(parseInt(t.substr(i,2),16));return s(new Uint8Array(r))}return a(t)?s(new Uint8Array(t)):(n.throwError("invalid arrayify value",null,{arg:"value",value:t,type:typeof t}),null)}function h(t){for(var e=[],r=0,i=0;i<t.length;i++){var n=u(t[i]);e.push(n),r+=n.length}var o=new Uint8Array(r),a=0;for(i=0;i<e.length;i++)o.set(e[i],a),a+=e[i].length;return s(o)}function d(t,e){return!("string"!=typeof t||!t.match(/^0x[0-9A-Fa-f]*$/)||e&&t.length!==2+2*e)}e.isHexable=o,e.isArrayish=a,e.arrayify=u,e.concat=h,e.stripZeros=function(t){var e=u(t);if(0===e.length)return e;for(var r=0;0===e[r];)r++;return r&&(e=e.slice(r)),e},e.padZeros=function(t,e){if(e<(t=u(t)).length)throw new Error("cannot pad");var r=new Uint8Array(e);return r.set(t,e-t.length),s(r)},e.isHexString=d;var c="0123456789abcdef";function l(t){if(o(t))return t.toHexString();if("number"==typeof t){t<0&&n.throwError("cannot hexlify negative value",n.INVALID_ARGUMENT,{arg:"value",value:t}),t>=9007199254740991&&n.throwError("out-of-range",n.NUMERIC_FAULT,{operartion:"hexlify",fault:"out-of-safe-range"});for(var e="";t;)e=c[15&t]+e,t=Math.floor(t/16);return e.length?(e.length%2&&(e="0"+e),"0x"+e):"0x00"}if("string"==typeof t){var r=t.match(/^(0x)?[0-9a-fA-F]*$/);return r||n.throwError("invalid hexidecimal string",n.INVALID_ARGUMENT,{arg:"value",value:t}),"0x"!==r[1]&&n.throwError("hex string must have 0x prefix",n.INVALID_ARGUMENT,{arg:"value",value:t}),t.length%2&&(t="0x0"+t.substring(2)),t}if(a(t)){for(var i=[],s=0;s<t.length;s++){var u=t[s];i.push(c[(240&u)>>4]+c[15&u])}return"0x"+i.join("")}return n.throwError("invalid hexlify value",null,{arg:"value",value:t}),"never"}function f(t,e){for(d(t)||n.throwError("invalid hex string",n.INVALID_ARGUMENT,{arg:"value",value:t});t.length<2*e+2;)t="0x0"+t.substring(2);return t}function p(t){var e,r=0,i="0x",o="0x";if((e=t)&&null!=e.r&&null!=e.s){null==t.v&&null==t.recoveryParam&&n.throwError("at least on of recoveryParam or v must be specified",n.INVALID_ARGUMENT,{argument:"signature",value:t}),i=f(t.r,32),o=f(t.s,32),"string"==typeof(r=t.v)&&(r=parseInt(r,16));var s=t.recoveryParam;null==s&&null!=t.v&&(s=1-r%2),r=27+s}else{var a=u(t);if(65!==a.length)throw new Error("invalid signature");i=l(a.slice(0,32)),o=l(a.slice(32,64)),27!==(r=a[64])&&28!==r&&(r=27+r%2)}return{r:i,s:o,recoveryParam:r-27,v:r}}e.hexlify=l,e.hexDataLength=function(t){return d(t)&&t.length%2==0?(t.length-2)/2:null},e.hexDataSlice=function(t,e,r){return d(t)||n.throwError("invalid hex data",n.INVALID_ARGUMENT,{arg:"value",value:t}),t.length%2!=0&&n.throwError("hex data length must be even",n.INVALID_ARGUMENT,{arg:"value",value:t}),e=2+2*e,null!=r?"0x"+t.substring(e,2+2*r):"0x"+t.substring(e)},e.hexStripZeros=function(t){for(d(t)||n.throwError("invalid hex string",n.INVALID_ARGUMENT,{arg:"value",value:t});t.length>3&&"0x0"===t.substring(0,3);)t="0x"+t.substring(3);return t},e.hexZeroPad=f,e.splitSignature=p,e.joinSignature=function(t){return l(h([(t=p(t)).r,t.s,t.recoveryParam?"0x1c":"0x1b"]))}},7839:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=r(4164),n=r(2453);e.keccak256=function(t){return"0x"+i.keccak_256(n.arrayify(t))}},589:function(t,e,r){"use strict";var i=this&&this.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e};Object.defineProperty(e,"__esModule",{value:!0});var n=i(r(6666));function o(t,e,r){Object.defineProperty(t,e,{enumerable:!0,value:r,writable:!1})}function s(t,e){return t&&t._ethersType===e}e.defineReadOnly=o,e.setType=function(t,e){Object.defineProperty(t,"_ethersType",{configurable:!1,value:e,writable:!1})},e.isType=s,e.resolveProperties=function(t){var e={},r=[];return Object.keys(t).forEach((function(i){var n=t[i];n instanceof Promise?r.push(n.then((function(t){return e[i]=t,null}))):e[i]=n})),Promise.all(r).then((function(){return e}))},e.checkProperties=function(t,e){t&&"object"==typeof t||n.throwError("invalid object",n.INVALID_ARGUMENT,{argument:"object",value:t}),Object.keys(t).forEach((function(r){e[r]||n.throwError("invalid object key - "+r,n.INVALID_ARGUMENT,{argument:"transaction",value:t,key:r})}))},e.shallowCopy=function(t){var e={};for(var r in t)e[r]=t[r];return e};var a={boolean:!0,number:!0,string:!0};e.deepCopy=function t(e,r){if(null==e||a[typeof e])return e;if(Array.isArray(e)){var i=e.map((function(e){return t(e,r)}));return r&&Object.freeze(i),i}if("object"==typeof e){if(s(e,"BigNumber"))return e;if(s(e,"Description"))return e;if(s(e,"Indexed"))return e;for(var n in i={},e){var u=e[n];void 0!==u&&o(i,n,t(u,r))}return r&&Object.freeze(i),i}if("function"==typeof e)return e;throw new Error("Cannot deepCopy "+typeof e)},e.inheritable=function t(e){return function(r){var i,n;n=e,(i=r).super_=n,i.prototype=Object.create(n.prototype,{constructor:{value:i,enumerable:!1,writable:!0,configurable:!0}}),o(r,"inherits",t(r))}}},8854:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=r(2453);function n(t){for(var e=[];t;)e.unshift(255&t),t>>=8;return e}function o(t,e,r){for(var i=0,n=0;n<r;n++)i=256*i+t[e+n];return i}function s(t){if(Array.isArray(t)){var e=[];return t.forEach((function(t){e=e.concat(s(t))})),e.length<=55?(e.unshift(192+e.length),e):((r=n(e.length)).unshift(247+r.length),r.concat(e))}var r,o=Array.prototype.slice.call(i.arrayify(t));return 1===o.length&&o[0]<=127?o:o.length<=55?(o.unshift(128+o.length),o):((r=n(o.length)).unshift(183+r.length),r.concat(o))}function a(t,e,r,i){for(var n=[];r<e+1+i;){var o=u(t,r);if(n.push(o.result),(r+=o.consumed)>e+1+i)throw new Error("invalid rlp")}return{consumed:1+i,result:n}}function u(t,e){if(0===t.length)throw new Error("invalid rlp data");if(t[e]>=248){if(e+1+(r=t[e]-247)>t.length)throw new Error("too short");if(e+1+r+(n=o(t,e+1,r))>t.length)throw new Error("to short");return a(t,e,e+1+r,r+n)}if(t[e]>=192){if(e+1+(n=t[e]-192)>t.length)throw new Error("invalid rlp data");return a(t,e,e+1,n)}if(t[e]>=184){var r;if(e+1+(r=t[e]-183)>t.length)throw new Error("invalid rlp data");if(e+1+r+(n=o(t,e+1,r))>t.length)throw new Error("invalid rlp data");return{consumed:1+r+n,result:i.hexlify(t.slice(e+1+r,e+1+r+n))}}if(t[e]>=128){var n;if(e+1+(n=t[e]-128)>t.length)throw new Error("invalid rlp data");return{consumed:1+n,result:i.hexlify(t.slice(e+1,e+1+n))}}return{consumed:1,result:i.hexlify(t[e])}}e.encode=function(t){return i.hexlify(s(t))},e.decode=function(t){var e=i.arrayify(t),r=u(e,0);if(r.consumed!==e.length)throw new Error("invalid rlp data");return r.result}},9469:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i,n=r(3850),o=r(6666),s=r(2453);function a(t,e){void 0===e&&(e=i.current),e!=i.current&&(o.checkNormalize(),t=t.normalize(e));for(var r=[],n=0;n<t.length;n++){var a=t.charCodeAt(n);if(a<128)r.push(a);else if(a<2048)r.push(a>>6|192),r.push(63&a|128);else if(55296==(64512&a)){n++;var u=t.charCodeAt(n);if(n>=t.length||56320!=(64512&u))throw new Error("invalid utf-8 string");a=65536+((1023&a)<<10)+(1023&u),r.push(a>>18|240),r.push(a>>12&63|128),r.push(a>>6&63|128),r.push(63&a|128)}else r.push(a>>12|224),r.push(a>>6&63|128),r.push(63&a|128)}return s.arrayify(r)}function u(t,e){t=s.arrayify(t);for(var r="",i=0;i<t.length;){var n=t[i++];if(n>>7!=0){var o=null,a=null;if(192==(224&n))o=1,a=127;else if(224==(240&n))o=2,a=2047;else{if(240!=(248&n)){if(!e){if(128==(192&n))throw new Error("invalid utf8 byte sequence; unexpected continuation byte");throw new Error("invalid utf8 byte sequence; invalid prefix")}continue}o=3,a=65535}if(i+o>t.length){if(!e)throw new Error("invalid utf8 byte sequence; too short");for(;i<t.length&&t[i]>>6==2;i++);}else{for(var u=n&(1<<8-o-1)-1,h=0;h<o;h++){var d=t[i];if(128!=(192&d)){u=null;break}u=u<<6|63&d,i++}if(null!==u)if(u<=a){if(!e)throw new Error("invalid utf8 byte sequence; overlong")}else if(u>1114111){if(!e)throw new Error("invalid utf8 byte sequence; out-of-range")}else if(u>=55296&&u<=57343){if(!e)throw new Error("invalid utf8 byte sequence; utf-16 surrogate")}else u<=65535?r+=String.fromCharCode(u):(u-=65536,r+=String.fromCharCode(55296+(u>>10&1023),56320+(1023&u)));else if(!e)throw new Error("invalid utf8 byte sequence; invalid continuation byte")}}else r+=String.fromCharCode(n)}return r}!function(t){t.current="",t.NFC="NFC",t.NFD="NFD",t.NFKC="NFKC",t.NFKD="NFKD"}(i=e.UnicodeNormalizationForm||(e.UnicodeNormalizationForm={})),e.toUtf8Bytes=a,e.toUtf8String=u,e.formatBytes32String=function(t){var e=a(t);if(e.length>31)throw new Error("bytes32 string must be less than 32 bytes");return s.hexlify(s.concat([e,n.HashZero]).slice(0,32))},e.parseBytes32String=function(t){var e=s.arrayify(t);if(32!==e.length)throw new Error("invalid bytes32 - not 32 bytes long");if(0!==e[31])throw new Error("invalid bytes32 string - no null terminator");for(var r=31;0===e[r-1];)r--;return u(e.slice(0,r))}},7533:t=>{"use strict";var e,r="object"==typeof Reflect?Reflect:null,i=r&&"function"==typeof r.apply?r.apply:function(t,e,r){return Function.prototype.apply.call(t,e,r)};e=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var n=Number.isNaN||function(t){return t!=t};function o(){o.init.call(this)}t.exports=o,t.exports.once=function(t,e){return new Promise((function(r,i){function n(r){t.removeListener(e,o),i(r)}function o(){"function"==typeof t.removeListener&&t.removeListener("error",n),r([].slice.call(arguments))}v(t,e,o,{once:!0}),"error"!==e&&function(t,e,r){"function"==typeof t.on&&v(t,"error",e,{once:!0})}(t,n)}))},o.EventEmitter=o,o.prototype._events=void 0,o.prototype._eventsCount=0,o.prototype._maxListeners=void 0;var s=10;function a(t){if("function"!=typeof t)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof t)}function u(t){return void 0===t._maxListeners?o.defaultMaxListeners:t._maxListeners}function h(t,e,r,i){var n,o,s,h;if(a(r),void 0===(o=t._events)?(o=t._events=Object.create(null),t._eventsCount=0):(void 0!==o.newListener&&(t.emit("newListener",e,r.listener?r.listener:r),o=t._events),s=o[e]),void 0===s)s=o[e]=r,++t._eventsCount;else if("function"==typeof s?s=o[e]=i?[r,s]:[s,r]:i?s.unshift(r):s.push(r),(n=u(t))>0&&s.length>n&&!s.warned){s.warned=!0;var d=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");d.name="MaxListenersExceededWarning",d.emitter=t,d.type=e,d.count=s.length,h=d,console&&console.warn&&console.warn(h)}return t}function d(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function c(t,e,r){var i={fired:!1,wrapFn:void 0,target:t,type:e,listener:r},n=d.bind(i);return n.listener=r,i.wrapFn=n,n}function l(t,e,r){var i=t._events;if(void 0===i)return[];var n=i[e];return void 0===n?[]:"function"==typeof n?r?[n.listener||n]:[n]:r?function(t){for(var e=new Array(t.length),r=0;r<e.length;++r)e[r]=t[r].listener||t[r];return e}(n):p(n,n.length)}function f(t){var e=this._events;if(void 0!==e){var r=e[t];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function p(t,e){for(var r=new Array(e),i=0;i<e;++i)r[i]=t[i];return r}function v(t,e,r,i){if("function"==typeof t.on)i.once?t.once(e,r):t.on(e,r);else{if("function"!=typeof t.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof t);t.addEventListener(e,(function n(o){i.once&&t.removeEventListener(e,n),r(o)}))}}Object.defineProperty(o,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(t){if("number"!=typeof t||t<0||n(t))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+t+".");s=t}}),o.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},o.prototype.setMaxListeners=function(t){if("number"!=typeof t||t<0||n(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this},o.prototype.getMaxListeners=function(){return u(this)},o.prototype.emit=function(t){for(var e=[],r=1;r<arguments.length;r++)e.push(arguments[r]);var n="error"===t,o=this._events;if(void 0!==o)n=n&&void 0===o.error;else if(!n)return!1;if(n){var s;if(e.length>0&&(s=e[0]),s instanceof Error)throw s;var a=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var u=o[t];if(void 0===u)return!1;if("function"==typeof u)i(u,this,e);else{var h=u.length,d=p(u,h);for(r=0;r<h;++r)i(d[r],this,e)}return!0},o.prototype.addListener=function(t,e){return h(this,t,e,!1)},o.prototype.on=o.prototype.addListener,o.prototype.prependListener=function(t,e){return h(this,t,e,!0)},o.prototype.once=function(t,e){return a(e),this.on(t,c(this,t,e)),this},o.prototype.prependOnceListener=function(t,e){return a(e),this.prependListener(t,c(this,t,e)),this},o.prototype.removeListener=function(t,e){var r,i,n,o,s;if(a(e),void 0===(i=this._events))return this;if(void 0===(r=i[t]))return this;if(r===e||r.listener===e)0==--this._eventsCount?this._events=Object.create(null):(delete i[t],i.removeListener&&this.emit("removeListener",t,r.listener||e));else if("function"!=typeof r){for(n=-1,o=r.length-1;o>=0;o--)if(r[o]===e||r[o].listener===e){s=r[o].listener,n=o;break}if(n<0)return this;0===n?r.shift():function(t,e){for(;e+1<t.length;e++)t[e]=t[e+1];t.pop()}(r,n),1===r.length&&(i[t]=r[0]),void 0!==i.removeListener&&this.emit("removeListener",t,s||e)}return this},o.prototype.off=o.prototype.removeListener,o.prototype.removeAllListeners=function(t){var e,r,i;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[t]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[t]),this;if(0===arguments.length){var n,o=Object.keys(r);for(i=0;i<o.length;++i)"removeListener"!==(n=o[i])&&this.removeAllListeners(n);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(e=r[t]))this.removeListener(t,e);else if(void 0!==e)for(i=e.length-1;i>=0;i--)this.removeListener(t,e[i]);return this},o.prototype.listeners=function(t){return l(this,t,!0)},o.prototype.rawListeners=function(t){return l(this,t,!1)},o.listenerCount=function(t,e){return"function"==typeof t.listenerCount?t.listenerCount(e):f.call(t,e)},o.prototype.listenerCount=f,o.prototype.eventNames=function(){return this._eventsCount>0?e(this._events):[]}},9002:(t,e)=>{"use strict";var r=function(){if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if(void 0!==r)return r;throw new Error("unable to locate global object")}();t.exports=e=r.fetch,r.fetch&&(e.default=r.fetch.bind(r)),e.Headers=r.Headers,e.Request=r.Request,e.Response=r.Response},6428:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0}),e.AssetLedger=void 0;const n=r(3279),o=r(5291),s=r(877),a=r(212),u=r(3967),h=r(8260),d=r(8943),c=r(4494),l=r(3583),f=r(1463),p=r(7234),v=r(3016),_=r(5641),m=r(4583),E=r(5421),y=r(2513),A=r(1999),g=r(1741),w=r(3206),T=r(8661),M=r(195),N=r(8548),I=r(4977),R=r(5289),O=r(1066),b=r(4373),P=r(7877);e.AssetLedger=class{constructor(t,e){this._provider=t,this._id=this._provider.encoder.normalizeAddress(e)}static deploy(t,e){return i(this,void 0,void 0,(function*(){return u.default(t,e)}))}static getInstance(t,e){return new this(t,e)}get id(){return this._id}get provider(){return this._provider}getAbilities(t){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),A.default(this,t)}))}getApprovedAccount(t){return i(this,void 0,void 0,(function*(){return w.default(this,t)}))}getAssetAccount(t){return i(this,void 0,void 0,(function*(){return M.default(this,t)}))}getAsset(t){return i(this,void 0,void 0,(function*(){return T.default(this,t)}))}getBalance(t){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),I.default(this,t)}))}getCapabilities(){return i(this,void 0,void 0,(function*(){return R.default(this)}))}getInfo(){return i(this,void 0,void 0,(function*(){return O.default(this)}))}getAssetIdAt(t){return i(this,void 0,void 0,(function*(){return N.default(this,t)}))}getAccountAssetIdAt(t,e){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),g.default(this,t,e)}))}isApprovedAccount(t,e){return i(this,void 0,void 0,(function*(){return(e=this._provider.encoder.normalizeAddress(e))===(yield w.default(this,t))}))}isTransferable(){return i(this,void 0,void 0,(function*(){return P.default(this)}))}approveAccount(t,e){return i(this,void 0,void 0,(function*(){return e=this._provider.encoder.normalizeAddress(e),s.default(this,e,t)}))}disapproveAccount(t){return i(this,void 0,void 0,(function*(){return s.default(this,"0x0000000000000000000000000000000000000000",t)}))}grantAbilities(t,e){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),d.default(this,t,o.getBitfieldFromAbilities(e))}))}setAbilities(t,e){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),p.default(this,t,o.getBitfieldFromAbilities(e))}))}createAsset(t){return i(this,void 0,void 0,(function*(){const e=this._provider.encoder.normalizeAddress(t.receiverId);return a.default(this,e,t.id,`0x${t.imprint}`)}))}destroyAsset(t){return i(this,void 0,void 0,(function*(){return h.default(this,t)}))}revokeAbilities(t,e){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),c.default(this,t,o.getBitfieldFromAbilities(e))}))}revokeAsset(t){return i(this,void 0,void 0,(function*(){return l.default(this,t)}))}transferAsset(t){return i(this,void 0,void 0,(function*(){t.senderId||(t.senderId=this.provider.accountId);const e=this._provider.encoder.normalizeAddress(t.senderId),r=this._provider.encoder.normalizeAddress(t.receiverId);return-1!==this.provider.unsafeRecipientIds.indexOf(t.receiverId)?m.default(this,e,r,t.id):f.default(this,e,r,t.id,t.data)}))}enableTransfers(){return i(this,void 0,void 0,(function*(){return _.default(this,!0)}))}disableTransfers(){return i(this,void 0,void 0,(function*(){return _.default(this,!1)}))}updateAsset(t,e){return i(this,void 0,void 0,(function*(){return y.default(this,t,`0x${e.imprint}`)}))}update(t){return i(this,void 0,void 0,(function*(){return E.default(this,t.uriPrefix,t.uriPostfix)}))}approveOperator(t){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),v.default(this,t,!0)}))}disapproveOperator(t){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),v.default(this,t,!1)}))}isApprovedOperator(t,e){return i(this,void 0,void 0,(function*(){return t=this._provider.encoder.normalizeAddress(t),e=this._provider.encoder.normalizeAddress(e),b.default(this,t,e)}))}getContext(){return[{name:"Transfer",topic:"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef",types:[{kind:n.MutationEventTypeKind.INDEXED,name:"from",type:"address"},{kind:n.MutationEventTypeKind.INDEXED,name:"to",type:"address"},{kind:n.MutationEventTypeKind.INDEXED,name:"tokenId",type:"uint256"}]},{name:"Approval",topic:"0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925",types:[{kind:n.MutationEventTypeKind.INDEXED,name:"owner",type:"address"},{kind:n.MutationEventTypeKind.INDEXED,name:"approved",type:"address"},{kind:n.MutationEventTypeKind.INDEXED,name:"tokenId",type:"uint256"}]},{name:"ApprovalForAll",topic:"0x17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31",types:[{kind:n.MutationEventTypeKind.INDEXED,name:"owner",type:"address"},{kind:n.MutationEventTypeKind.INDEXED,name:"operator",type:"address"},{kind:n.MutationEventTypeKind.NORMAL,name:"approved",type:"bool"}]},{name:"IsPaused",topic:"0xff4a5dbbab6b1963d10f5edd139f33a7987ecb3c4f65969be77ddba28d946594",types:[{kind:n.MutationEventTypeKind.NORMAL,name:"isPaused",type:"bool"}]},{name:"TokenImprintUpdate",topic:"0xda81dc3bdaf65b621535dbd08fc4032c7e22d5ccab12c8aa2ad010611471d627",types:[{kind:n.MutationEventTypeKind.INDEXED,name:"tokenId",type:"uint256"},{kind:n.MutationEventTypeKind.NORMAL,name:"imprint",type:"bytes32"}]},{name:"SetAbilities",topic:"0xd1d59d2d212a435434e7a4a4676427610dfe2b6268b01e541d280d65bf3d6b90",types:[{kind:n.MutationEventTypeKind.INDEXED,name:"target",type:"address"},{kind:n.MutationEventTypeKind.INDEXED,name:"abilities",type:"uint256"}]}]}}},5291:function(t,e,r){"use strict";var i=this&&this.__createBinding||(Object.create?function(t,e,r,i){void 0===i&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){void 0===i&&(i=r),t[i]=e[r]}),n=this&&this.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||i(e,t,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.AssetLedgerCapability=e.SuperAssetLedgerAbility=e.GeneralAssetLedgerAbility=void 0;var o=r(6112);Object.defineProperty(e,"GeneralAssetLedgerAbility",{enumerable:!0,get:function(){return o.GeneralAssetLedgerAbility}}),Object.defineProperty(e,"SuperAssetLedgerAbility",{enumerable:!0,get:function(){return o.SuperAssetLedgerAbility}}),Object.defineProperty(e,"AssetLedgerCapability",{enumerable:!0,get:function(){return o.AssetLedgerCapability}}),n(r(6428),e),n(r(365),e),n(r(5378),e)},5378:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getBitfieldFromAbilities=void 0;const i=r(2624);e.getBitfieldFromAbilities=function(t){let e=i.bigNumberify(0);return t.forEach((t=>{e=e.add(t)})),e.toHexString()}},365:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getInterfaceCode=void 0;const i=r(6112);e.getInterfaceCode=function(t){return t==i.AssetLedgerCapability.DESTROY_ASSET?"0x9d118770":t==i.AssetLedgerCapability.REVOKE_ASSET?"0x20c5429b":t==i.AssetLedgerCapability.UPDATE_ASSET?"0x0d04c3b8":t==i.AssetLedgerCapability.TOGGLE_TRANSFERS?"0xbedb86fb":null}},877:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["address","uint256"];e.default=function(t,e,r){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0x095ea7b3"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},s=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,s.result,t)}))}},212:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["address","uint256","bytes32"];e.default=function(t,e,r,s){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0xb0e329e4"+t.provider.encoder.encodeParameters(o,[e,r,s]).substr(2)},a=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,a.result,t)}))}},3967:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=r(5353),s=r(365),a=["string","string","string","string","bytes32","bytes4[]"];e.default=function(t,{name:e,symbol:r,uriPrefix:u,uriPostfix:h,schemaId:d,capabilities:c}){return i(this,void 0,void 0,(function*(){const i=(yield o.fetchJson(t.assetLedgerSource)).XcertMock.evm.bytecode.object,l=(c||[]).map((t=>s.getInterfaceCode(t))),f={from:t.accountId,data:`0x${i}${t.encoder.encodeParameters(a,[e,r,u,h,`0x${d}`,l]).substr(2)}`},p=yield t.post({method:"eth_sendTransaction",params:[f]});return new n.Mutation(t,p.result)}))}},8260:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["uint256"];e.default=function(t,e){return i(this,void 0,void 0,(function*(){const r={from:t.provider.accountId,to:t.id,data:"0x9d118770"+t.provider.encoder.encodeParameters(o,[e]).substr(2)},i=yield t.provider.post({method:"eth_sendTransaction",params:[r]});return new n.Mutation(t.provider,i.result,t)}))}},8943:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["address","uint256"];e.default=function(t,e,r){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0x0ab319e8"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},s=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,s.result,t)}))}},4494:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["address","uint256"];e.default=function(t,e,r){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0xf394b6df"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},s=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,s.result,t)}))}},3583:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["uint256"];e.default=function(t,e){return i(this,void 0,void 0,(function*(){const r={from:t.provider.accountId,to:t.id,data:"0x20c5429b"+t.provider.encoder.encodeParameters(o,[e]).substr(2)},i=yield t.provider.post({method:"eth_sendTransaction",params:[r]});return new n.Mutation(t.provider,i.result,t)}))}},1463:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279);e.default=function(t,e,r,o,s){return i(this,void 0,void 0,(function*(){const i=void 0!==s?"0xb88d4fde":"0x42842e0e",a=["address","address","uint256"];void 0!==s&&a.push("bytes");const u=[e,r,o,s].filter((t=>void 0!==t)),h={from:t.provider.accountId,to:t.id,data:i+t.provider.encoder.encodeParameters(a,u).substr(2)},d=yield t.provider.post({method:"eth_sendTransaction",params:[h]});return new n.Mutation(t.provider,d.result,t)}))}},7234:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["address","uint256"];e.default=function(t,e,r){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0x15ec3b8b"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},s=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,s.result,t)}))}},3016:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["address","bool"];e.default=function(t,e,r){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0xa22cb465"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},s=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,s.result,t)}))}},5641:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["bool"];e.default=function(t,e){return i(this,void 0,void 0,(function*(){const r={from:t.provider.accountId,to:t.id,data:"0xbedb86fb"+t.provider.encoder.encodeParameters(o,[!e]).substr(2)},i=yield t.provider.post({method:"eth_sendTransaction",params:[r]});return new n.Mutation(t.provider,i.result,t)}))}},4583:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["address","address","uint256"];e.default=function(t,e,r,s){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0x23b872dd"+t.provider.encoder.encodeParameters(o,[e,r,s]).substr(2)},a=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,a.result,t)}))}},2513:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["uint256","bytes32"];e.default=function(t,e,r){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0x0d04c3b8"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},s=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,s.result,t)}))}},5421:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(3279),o=["string","string"];e.default=function(t,e,r){return i(this,void 0,void 0,(function*(){const i={from:t.provider.accountId,to:t.id,data:"0x89b73ec0"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},s=yield t.provider.post({method:"eth_sendTransaction",params:[i]});return new n.Mutation(t.provider,s.result,t)}))}},1999:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(6112),o=["address","uint256"],s=["bool"];e.default=function(t,e){return i(this,void 0,void 0,(function*(){return Promise.all([n.SuperAssetLedgerAbility.MANAGE_ABILITIES,n.GeneralAssetLedgerAbility.CREATE_ASSET,n.GeneralAssetLedgerAbility.REVOKE_ASSET,n.GeneralAssetLedgerAbility.TOGGLE_TRANSFERS,n.GeneralAssetLedgerAbility.UPDATE_ASSET,n.GeneralAssetLedgerAbility.ALLOW_CREATE_ASSET,n.GeneralAssetLedgerAbility.UPDATE_URI_BASE,n.GeneralAssetLedgerAbility.ALLOW_UPDATE_ASSET_IMPRINT].map((r=>i(this,void 0,void 0,(function*(){const i={to:t.id,data:"0xba00a330"+t.provider.encoder.encodeParameters(o,[e,r]).substr(2)},n=yield t.provider.post({method:"eth_call",params:[i,"latest"]});return t.provider.encoder.decodeParameters(s,n.result)[0]?r:-1}))))).then((t=>t.filter((t=>-1!==t)).sort(((t,e)=>t-e)))).catch((e=>(t.provider.log(e),[])))}))}},1741:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=["address","uint256"],n=["uint256"];e.default=function(t,e,o){return r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:"0x2f745c59"+t.provider.encoder.encodeParameters(i,[e,o]).substr(2)},s=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(n,s.result)[0]}catch(e){return t.provider.log(e),null}}))}},3206:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(9512),o=["uint256"],s=["address"];e.default=function(t,e){return i(this,void 0,void 0,(function*(){try{const r={to:t.id,data:"0x081812fc"+t.provider.encoder.encodeParameters(o,[e]).substr(2)},i=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(s,i.result)[0]}catch(r){return t.provider.log(r),n.default(t,e)}}))}},195:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=["uint256"],n=["address"];e.default=function(t,e){return r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:"0x6352211e"+t.provider.encoder.encodeParameters(i,[e]).substr(2)},o=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(n,o.result)[0]}catch(e){return t.provider.log(e),null}}))}},8548:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=["uint256"],n=["uint256"];e.default=function(t,e){return r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:"0x4f6ccce7"+t.provider.encoder.encodeParameters(i,[e]).substr(2)},o=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(n,o.result)[0]}catch(e){return t.provider.log(e),null}}))}},8661:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=[{signature:"0xc87b56dd",inputTypes:["uint256"],outputTypes:["string"]},{signature:"0x49846680",inputTypes:["uint256"],outputTypes:["bytes","string"]},{signature:"0xcaae188e",inputTypes:["uint256"],outputTypes:["bytes","string"]}];e.default=function(t,e){return r(this,void 0,void 0,(function*(){const n=yield Promise.all(i.map((i=>r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:i.signature+t.provider.encoder.encodeParameters(i.inputTypes,[e]).substr(2)},n=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(i.outputTypes,n.result)[0]}catch(e){return t.provider.log(e),null}})))));return{id:e,uri:n[0],imprint:n[1]?n[1].substr(2):null,schemaId:n[2]?n[2].substr(2):null}}))}},4977:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=["address"],n=["uint256"];e.default=function(t,e){return r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:"0x70a08231"+t.provider.encoder.encodeParameters(i,[e]).substr(2)},o=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(n,o.result)[0].toString()}catch(e){return t.provider.log(e),null}}))}},5289:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const n=r(6112),o=r(365),s=["bytes4"],a=["bool"];e.default=function(t){return i(this,void 0,void 0,(function*(){return Promise.all([n.AssetLedgerCapability.DESTROY_ASSET,n.AssetLedgerCapability.REVOKE_ASSET,n.AssetLedgerCapability.TOGGLE_TRANSFERS,n.AssetLedgerCapability.UPDATE_ASSET].map((e=>i(this,void 0,void 0,(function*(){const r=o.getInterfaceCode(e),i={to:t.id,data:"0x01ffc9a7"+t.provider.encoder.encodeParameters(s,[r]).substr(2)},n=yield t.provider.post({method:"eth_call",params:[i,"latest"]});return t.provider.encoder.decodeParameters(a,n.result)[0]?e:-1}))))).then((t=>t.filter((t=>-1!==t)).sort())).catch((e=>(t.provider.log(e),[])))}))}},1066:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=[{signature:"0x06fdde03",inputTypes:[],outputTypes:["string"]},{signature:"0x95d89b41",inputTypes:[],outputTypes:["string"]},{signature:"0x62b99ad4",inputTypes:[],outputTypes:["string"]},{signature:"0xc298bba5",inputTypes:[],outputTypes:["string"]},{signature:"0x18160ddd",inputTypes:[],outputTypes:["uint256"]}];e.default=function(t){return r(this,void 0,void 0,(function*(){const e=yield Promise.all(i.map((e=>r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:e.signature+t.provider.encoder.encodeParameters(e.inputTypes,[]).substr(2)},i=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(e.outputTypes,i.result)[0].toString()}catch(e){return t.provider.log(e),null}})))));return{name:e[0],symbol:e[1],uriPrefix:e[2],uriPostfix:e[3],supply:e[4]}}))}},4373:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=["address","address"],n=["bool"];e.default=function(t,e,o){return r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:"0xe985e9c5"+t.provider.encoder.encodeParameters(i,[e,o]).substr(2)},s=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(n,s.result)[0]}catch(e){return t.provider.log(e),null}}))}},7877:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=[],n=["bool"];e.default=function(t){return r(this,void 0,void 0,(function*(){try{const e={to:t.id,data:"0xb187bd26"+t.provider.encoder.encodeParameters(i,[]).substr(2)},r=yield t.provider.post({method:"eth_call",params:[e,"latest"]});return!t.provider.encoder.decodeParameters(n,r.result)[0]}catch(e){return t.provider.log(e),null}}))}},9512:function(t,e){"use strict";var r=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0});const i=["uint256"],n=["address"];e.default=function(t,e){return r(this,void 0,void 0,(function*(){try{const r={to:t.id,data:"0x481af3d3"+t.provider.encoder.encodeParameters(i,[e]).substr(2)},o=yield t.provider.post({method:"eth_call",params:[r,"latest"]});return t.provider.encoder.decodeParameters(n,o.result)[0]}catch(e){return t.provider.log(e),null}}))}},2143:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.parseError=void 0;const i=r(6112);e.parseError=function(t){return t instanceof i.ProviderError?t:Object.values(i.ProviderIssue).includes(t)?new i.ProviderError(t):new i.ProviderError(i.ProviderIssue.CONTRACT_ERROR,t)}},2072:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.buildGatewayConfig=void 0;const i=r(6898);e.buildGatewayConfig=function(t){switch(t){case i.NetworkKind.LIVE:return{actionsOrderId:"0x800ecA21614dA02Df076981Bca9c664dBE19089A",assetLedgerDeployOrderId:"0x984e781a6C09b433493767755f7b072183Ce7BfF",valueLedgerDeployOrderId:"0x9118bd4230EAb074f98527658f3649aA26420568"};case i.NetworkKind.RINKEBY:return{actionsOrderId:"0xF8254F1B119Cd263b066912B3Cb4FE568f580b6c",assetLedgerDeployOrderId:"0xC9F667603300390BCF8C4Fb5688d755811F34Da5",valueLedgerDeployOrderId:"0xA02121436e9307f9e369e188941b731D79c4DD7d"};case i.NetworkKind.ROPSTEN:return{actionsOrderId:"0xbb719e35c67198e4453923eeccF0c678C6129982",assetLedgerDeployOrderId:"0xC94284591B312c5551329F868420dec03C9044f8",valueLedgerDeployOrderId:"0xD348c4D9BE9585295891E0322FeFe58009c1514C"};default:throw new Error("Unsupported network kind.")}}},1868:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0}),e.Mutation=e.MutationStatus=void 0;const n=r(2624),o=r(6112),s=r(7533),a=r(6898);var u;!function(t){t[t.INITIALIZED=0]="INITIALIZED",t[t.PENDING=1]="PENDING",t[t.COMPLETED=2]="COMPLETED"}(u=e.MutationStatus||(e.MutationStatus={}));class h extends s.EventEmitter{constructor(t,e,r){super(),this._confirmations=0,this._speed=14e3,this._status=u.INITIALIZED,this._logs=[],this._id=e,this._provider=t,this._provider.sandbox&&(this._status=u.COMPLETED),this._context=r}get id(){return this._id}get provider(){return this._provider}get confirmations(){return this._confirmations}get senderId(){return this._senderId}get receiverId(){return this._receiverId}get logs(){return this._logs}isPending(){return this._status===u.PENDING}isCompleted(){return this._status===u.COMPLETED}emit(...t){return super.emit.call(this,...t),this}on(...t){return super.on.call(this,...t),this}once(...t){return super.once.call(this,...t),this}off(t,e){return e?super.off(t,e):super.removeAllListeners(t),this}complete(){return i(this,void 0,void 0,(function*(){const t=this._status===u.INITIALIZED;return this.isCompleted()?this.resolveCurrentState():(this.isPending()||(this._status=u.PENDING,this._started=Date.now()),yield new Promise(((e,r)=>{this.isCompleted()?e(null):(this.once(o.MutationEvent.COMPLETE,(()=>e(null))),this.once(o.MutationEvent.ERROR,(t=>r(t)))),t&&this.loopUntilCompleted()})),this)}))}forget(){return this._timer&&(clearTimeout(this._timer),this._timer=void 0),this}resolve(){return i(this,void 0,void 0,(function*(){return this.resolveCurrentState()}))}retry(){return i(this,void 0,void 0,(function*(){const t=yield this.getTransactionObject();if(!t)throw new Error("Mutation not found");if(t.blockNumber)throw new Error("Mutation already accepted onto the blockchain");const e=yield this._provider.post({method:"eth_gasPrice",params:[]}),r=t.gasPrice,i=e.result*this._provider.retryGasPriceMultiplier,n=i>=r?i:r*this._provider.retryGasPriceMultiplier,o={from:t.from,data:t.input,nonce:t.nonce,value:t.value,gas:t.gas,gasPrice:`0x${Math.ceil(n).toString(16)}`};t.to&&(o.to=t.to);const s=yield this._provider.post({method:"eth_sendTransaction",params:[o]});this._id=s.result}))}cancel(){return i(this,void 0,void 0,(function*(){const t=yield this.getTransactionObject();if(!t)throw new Error("Mutation not found");if(t.blockNumber)throw new Error("Mutation already accepted onto the blockchain");if(t.from.toLowerCase()!==this._provider.accountId.toLowerCase())throw new Error("You are not the maker of this mutation so you cannot cancel it.");const e=`0x${Math.ceil(1.1*t.gasPrice).toString(16)}`,r={from:t.from,to:t.from,nonce:t.nonce,value:"0x0",gasPrice:e},i=yield this._provider.post({method:"eth_sendTransaction",params:[r]});this._id=i.result}))}resolveCurrentState(){return i(this,void 0,void 0,(function*(){const t=yield this.getTransactionObject();if(!t||t.to&&"0x0"!==t.to||(t.to=yield this.getTransactionReceipt().then((t=>t?t.contractAddress:null))),t&&t.to){if(this._senderId=n.normalizeAddress(t.from),this._receiverId=n.normalizeAddress(t.to),this._confirmations=yield this.getLastBlock().then((e=>e-parseInt(t.blockNumber||e))).then((t=>t<0?0:t)),this._confirmations>=this._provider.requiredConfirmations)return yield this.parseLogs(),this._status=u.COMPLETED,this.emit(o.MutationEvent.COMPLETE,this);this.emit(o.MutationEvent.CONFIRM,this)}}))}loopUntilCompleted(){return i(this,void 0,void 0,(function*(){yield this.resolveCurrentState(),-1===this._provider.mutationTimeout||Date.now()-this._started<this._provider.mutationTimeout?this._timer=setTimeout(this.loopUntilCompleted.bind(this),this._speed):this.emit(o.MutationEvent.ERROR,new Error("Mutation has timed out"))}))}getTransactionObject(){return i(this,void 0,void 0,(function*(){return(yield this._provider.post({method:"eth_getTransactionByHash",params:[this.id]})).result}))}getTransactionReceipt(){return i(this,void 0,void 0,(function*(){return(yield this._provider.post({method:"eth_getTransactionReceipt",params:[this.id]})).result}))}getLastBlock(){return i(this,void 0,void 0,(function*(){const t=yield this._provider.post({method:"eth_blockNumber"});return parseInt(t.result)}))}parseLogs(){return i(this,void 0,void 0,(function*(){try{this._logs=[];const t=this._context.getContext();if(!t)return;(yield this.getTransactionReceipt()).logs.forEach((e=>{const r=t.find((t=>t.topic===e.topics[0]));if(!r)return void this._provider.log(JSON.stringify(e));const i={};i.event=r.name,i.address=e.address;const n=r.types.filter((t=>t.kind===a.MutationEventTypeKind.NORMAL)),o=r.types.filter((t=>t.kind===a.MutationEventTypeKind.INDEXED));if(n.length>0){const t=n.map((t=>t.type)),r=this._provider.encoder.decodeParameters(t,e.data);n.forEach(((t,e)=>{i[t.name]=r[e]}))}o.forEach(((t,r)=>{i[t.name]=this._provider.encoder.decodeParameters([t.type],e.topics[r+1])[0]})),this._logs.push(i)}))}catch(t){this._provider.log(t)}}))}}e.Mutation=h},1623:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0}),e.GenericProvider=void 0;const n=r(2624),o=r(6112),s=r(7533),a=r(2143),u=r(6898);class h extends s.EventEmitter{constructor(t){super(),this._id=0,this.encoder=void 0!==t.encoder?t.encoder:new n.Encoder,this.accountId=t.accountId,this.gatewayConfig=t.gatewayConfig,this.unsafeRecipientIds=t.unsafeRecipientIds,this.assetLedgerSource=t.assetLedgerSource||"https://conventions.0xcert.org/ethereum/xcert-mock.json",this.valueLedgerSource=t.valueLedgerSource||"https://conventions.0xcert.org/ethereum/token-mock.json",this.signMethod=void 0!==t.signMethod?t.signMethod:u.SignMethod.ETH_SIGN,this.requiredConfirmations=void 0!==t.requiredConfirmations?t.requiredConfirmations:1,this.mutationTimeout=void 0!==t.mutationTimeout?t.mutationTimeout:36e5,this.gasPriceMultiplier=void 0!==t.gasPriceMultiplier?t.gasPriceMultiplier:1.1,this.retryGasPriceMultiplier=void 0!==t.retryGasPriceMultiplier?t.retryGasPriceMultiplier:2,this.sandbox=void 0!==t.sandbox&&t.sandbox,this.verbose=void 0!==t.verbose&&t.verbose,this._client=t.client&&t.client.currentProvider?t.client.currentProvider:t.client}log(t){this.verbose&&console.log(t)}get accountId(){return this._accountId||null}set accountId(t){t=this.encoder.normalizeAddress(t),this.isCurrentAccount(t)||this.emit(o.ProviderEvent.ACCOUNT_CHANGE,t,this._accountId),this._accountId=t}get unsafeRecipientIds(){return this._unsafeRecipientIds||[]}set unsafeRecipientIds(t){this._unsafeRecipientIds=(t||[]).map((t=>this.encoder.normalizeAddress(t)))}get gatewayConfig(){return this._gatewayConfig}set gatewayConfig(t){this._gatewayConfig=void 0!==t?{actionsOrderId:this.encoder.normalizeAddress(t.actionsOrderId),assetLedgerDeployOrderId:this.encoder.normalizeAddress(t.assetLedgerDeployOrderId),valueLedgerDeployOrderId:this.encoder.normalizeAddress(t.valueLedgerDeployOrderId)}:null}emit(...t){return super.emit.call(this,...t),this}on(...t){return super.on.call(this,...t),this}once(...t){return super.once.call(this,...t),this}off(t,e){return e?super.off(t,e):super.removeAllListeners(t),this}sign(t){return i(this,void 0,void 0,(function*(){if(!this.accountId)throw new Error("accountId not set.");if(this.signMethod===u.SignMethod.PERSONAL_SIGN)return(yield this.post({method:"personal_sign",params:[t,this.accountId,null]})).result;if(this.signMethod===u.SignMethod.ETH_SIGN)return(yield this.post({method:"eth_sign",params:[this.accountId,t]})).result;throw new Error("Signing method not implemented.")}))}getAvailableAccounts(){return i(this,void 0,void 0,(function*(){return(yield this.post({method:"eth_accounts",params:[]})).result.map((t=>this.encoder.normalizeAddress(t)))}))}getNetworkVersion(){return i(this,void 0,void 0,(function*(){return(yield this.post({method:"net_version",params:[]})).result}))}isCurrentAccount(t){return this.accountId===this.encoder.normalizeAddress(t)}isUnsafeRecipientId(t){const e=this.encoder.normalizeAddress(t);return!!this.unsafeRecipientIds.find((t=>t===e))}post(t){return i(this,void 0,void 0,(function*(){const e=Object.assign({},t);if("eth_sendTransaction"===e.method&&e.params.length&&(this.sandbox||void 0===e.params[0].gas)){try{const t=yield this.request(Object.assign(Object.assign({},e),{method:"eth_estimateGas"}));e.params[0].gas=`0x${Math.ceil(1.1*t.result).toString(16)}`}catch(t){if(t&&t.original&&(-32603===t.original.code||-32e3===t.original.code)){e.params.push("latest");const t=yield this.request(Object.assign(Object.assign({},e),{method:"eth_call"}));throw new o.ProviderError(o.ProviderIssue.CONTRACT_ERROR,t.result)}throw t}if(this.sandbox)return{id:null,jsonrpc:null,result:e.params[0].gas};if(void 0===e.params[0].gasPrice){const t=yield this.request(Object.assign(Object.assign({},e),{method:"eth_gasPrice",params:[]}));e.params[0].gasPrice=`0x${Math.ceil(t.result*this.gasPriceMultiplier).toString(16)}`}}return this.request(e)}))}request(t){return i(this,void 0,void 0,(function*(){const e=Object.assign({jsonrpc:"2.0",id:t.id||this.getNextId(),params:[]},t);return new Promise(((t,r)=>{this._client.send(e,((i,n)=>i?(this.log(i),r(i)):n.error?(this.log(i),r(n.error)):n.id!==e.id?r("Invalid RPC id"):t(n)))})).catch((t=>{throw new o.ProviderError(o.ProviderIssue.GENERAL,t)})).then((t=>{if("eth_call"===e.method&&t&&t.result&&-1!==t.result.indexOf("0x08c379a0")){const e=this.encoder.decodeParameters(["string"],`0x${t.result.substring(10)}`);throw a.parseError(e[0])}return t}))}))}getNextId(){return this._id++,this._id}}e.GenericProvider=h},6898:(t,e)=>{"use strict";var r,i,n;Object.defineProperty(e,"__esModule",{value:!0}),e.NetworkKind=e.MutationEventTypeKind=e.SignMethod=void 0,(n=e.SignMethod||(e.SignMethod={}))[n.ETH_SIGN=0]="ETH_SIGN",n[n.TREZOR=1]="TREZOR",n[n.NO_PREFIX=2]="NO_PREFIX",n[n.PERSONAL_SIGN=3]="PERSONAL_SIGN",(i=e.MutationEventTypeKind||(e.MutationEventTypeKind={}))[i.NORMAL=0]="NORMAL",i[i.INDEXED=1]="INDEXED",(r=e.NetworkKind||(e.NetworkKind={}))[r.LIVE=0]="LIVE",r[r.ROPSTEN=1]="ROPSTEN",r[r.RINKEBY=2]="RINKEBY"},3279:function(t,e,r){"use strict";var i=this&&this.__createBinding||(Object.create?function(t,e,r,i){void 0===i&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){void 0===i&&(i=r),t[i]=e[r]}),n=this&&this.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||i(e,t,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(r(8330),e),n(r(677),e),n(r(2143),e),n(r(1868),e),n(r(1623),e),n(r(6898),e),n(r(2072),e)},2624:function(t,e,r){"use strict";var i=this&&this.__createBinding||(Object.create?function(t,e,r,i){void 0===i&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){void 0===i&&(i=r),t[i]=e[r]}),n=this&&this.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||i(e,t,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(r(7203),e),n(r(881),e),n(r(1402),e),n(r(9030),e),n(r(3690),e),n(r(7170),e),n(r(3710),e),n(r(2057),e),n(r(9555),e),n(r(1389),e)},7203:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.decodeParameters=e.encodeParameters=void 0;const i=new(r(861).AbiCoder);e.encodeParameters=function(t,e){return i.encode(t,e)},e.decodeParameters=function(t,e){return i.decode(t,e)}},1402:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.bigNumberify=e.BigNumber=void 0;const i=r(2069);var n=r(2069);Object.defineProperty(e,"BigNumber",{enumerable:!0,get:function(){return n.BigNumber}}),e.bigNumberify=function(t){return i.bigNumberify(t)}},9030:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Encoder=void 0;const i=r(861),n=r(2990);e.Encoder=class{constructor(){this.coder=new i.AbiCoder}encodeParameters(t,e){return this.coder.encode(t,e)}decodeParameters(t,e){return this.coder.decode(t,e)}normalizeAddress(t){return t?n.getAddress(t):null}}},3690:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.hexToBytes=void 0,e.hexToBytes=function(t){t=t.toString(16).replace(/^0x/i,"");const e=[];for(let r=0;r<t.length;r+=2)e.push(parseInt(t.substr(r,2),16));return e}},7170:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.leftPad=void 0,e.leftPad=function(t,e,r,i){const n=void 0===i?/^0x/i.test(t)||"number"==typeof t:i,o=e-(t=t.toString(16).replace(/^0x/i,"")).length+1>=0?e-t.length+1:0;return(n?"0x":"")+new Array(o).join(r||"0")+t}},881:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.normalizeAddress=void 0;const i=r(2990);e.normalizeAddress=function(t){return t?i.getAddress(t.toLowerCase()):null}},3710:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.rightPad=void 0,e.rightPad=function(t,e,r,i){const n=void 0===i?/^0x/i.test(t)||"number"==typeof t:i,o=e-(t=t.toString(16).replace(/^0x/i,"")).length+1>=0?e-t.length+1:0;return(n?"0x":"")+t+new Array(o).join(r||"0")}},2057:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.stringToHex=void 0,e.stringToHex=function(t){let e="";for(let r=0;r<t.length;r++)e+=t.charCodeAt(r).toString(16);return e}},9555:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ZERO_ADDRESS=void 0,e.ZERO_ADDRESS="0x0000000000000000000000000000000000000000"},1389:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},4508:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},1340:(t,e)=>{"use strict";var r,i,n;Object.defineProperty(e,"__esModule",{value:!0}),e.AssetLedgerCapability=e.SuperAssetLedgerAbility=e.GeneralAssetLedgerAbility=void 0,(n=e.GeneralAssetLedgerAbility||(e.GeneralAssetLedgerAbility={}))[n.CREATE_ASSET=16]="CREATE_ASSET",n[n.REVOKE_ASSET=32]="REVOKE_ASSET",n[n.TOGGLE_TRANSFERS=64]="TOGGLE_TRANSFERS",n[n.UPDATE_ASSET=128]="UPDATE_ASSET",n[n.UPDATE_URI_BASE=256]="UPDATE_URI_BASE",n[n.ALLOW_CREATE_ASSET=512]="ALLOW_CREATE_ASSET",n[n.ALLOW_UPDATE_ASSET_IMPRINT=1024]="ALLOW_UPDATE_ASSET_IMPRINT",(i=e.SuperAssetLedgerAbility||(e.SuperAssetLedgerAbility={}))[i.MANAGE_ABILITIES=1]="MANAGE_ABILITIES",i[i.ALLOW_MANAGE_ABILITIES=2]="ALLOW_MANAGE_ABILITIES",(r=e.AssetLedgerCapability||(e.AssetLedgerCapability={}))[r.DESTROY_ASSET=1]="DESTROY_ASSET",r[r.UPDATE_ASSET=2]="UPDATE_ASSET",r[r.REVOKE_ASSET=4]="REVOKE_ASSET",r[r.TOGGLE_TRANSFERS=3]="TOGGLE_TRANSFERS"},8096:(t,e)=>{"use strict";var r,i;Object.defineProperty(e,"__esModule",{value:!0}),e.ValueLedgerDeployOrder=e.AssetLedgerDeployOrder=e.SignedFixedActionsOrder=e.FixedActionsOrder=e.SignedDynamicActionsOrder=e.DynamicActionsOrder=e.AssetSetOperatorOrder=e.DappValueApproveOrder=e.OrderKind=e.ActionsOrderActionKind=void 0,(i=e.ActionsOrderActionKind||(e.ActionsOrderActionKind={}))[i.CREATE_ASSET=1]="CREATE_ASSET",i[i.TRANSFER_ASSET=2]="TRANSFER_ASSET",i[i.TRANSFER_VALUE=3]="TRANSFER_VALUE",i[i.UPDATE_ASSET_IMPRINT=4]="UPDATE_ASSET_IMPRINT",i[i.SET_ABILITIES=5]="SET_ABILITIES",i[i.DESTROY_ASSET=6]="DESTROY_ASSET",(r=e.OrderKind||(e.OrderKind={}))[r.ASSET_LEDGER_DEPLOY_ORDER=1]="ASSET_LEDGER_DEPLOY_ORDER",r[r.VALUE_LEDGER_DEPLOY_ORDER=2]="VALUE_LEDGER_DEPLOY_ORDER",r[r.FIXED_ACTIONS_ORDER=3]="FIXED_ACTIONS_ORDER",r[r.DYNAMIC_ACTIONS_ORDER=4]="DYNAMIC_ACTIONS_ORDER",r[r.SIGNED_FIXED_ACTIONS_ORDER=5]="SIGNED_FIXED_ACTIONS_ORDER",r[r.SIGNED_DYNAMIC_ACTIONS_ORDER=6]="SIGNED_DYNAMIC_ACTIONS_ORDER",r[r.ASSET_SET_OPERATOR_ORDER=7]="ASSET_SET_OPERATOR_ORDER",r[r.DAPP_VALUE_APPROVE_ORDER=8]="DAPP_VALUE_APPROVE_ORDER",e.DappValueApproveOrder=class{},e.AssetSetOperatorOrder=class{},e.DynamicActionsOrder=class{},e.SignedDynamicActionsOrder=class{},e.FixedActionsOrder=class{},e.SignedFixedActionsOrder=class{},e.AssetLedgerDeployOrder=class{},e.ValueLedgerDeployOrder=class{}},2503:(t,e)=>{"use strict";var r;Object.defineProperty(e,"__esModule",{value:!0}),e.ProviderIssue=void 0,(r=e.ProviderIssue||(e.ProviderIssue={})).GENERAL="0",r.CONTRACT_ERROR="1",r.ACTIONS_ORDER_KIND_NOT_SUPPORTED="5000001",r.DYNAMIC_ACTIONS_ORDER_SIGNATURES="5000002",r.FIXED_ACTIONS_ORDER_SIGNATURES="5000003",r.SIGNED_DYNAMIC_ACTIONS_ORDER_SIGNATURES="5000004",r.SIGNED_FIXED_ACTIONS_ORDER_SIGNATURES="5000005",r.NO_RECEIVER_ID="5000006",r.PROXY_KIND_NOT_SUPPORTED="5000007",r.SENDER_ID_NOT_A_SIGNER="5000008",r.SENDER_ID_AND_RECEIVER_ID_MISSING="5000009",r.ACTION_KIND_NOT_SUPPORTED="5000010",r.ERC20_APPROVAL_RACE_CONDITION="5000011",r.ERC20_NOT_ENOUGH_BALANCE="001001",r.ERC20_NOT_ENOUGH_ALLOWANCE="001002",r.ERC721_ZERO_ADDRESS="003001",r.ERC721_NOT_VALID_NFT="003002",r.ERC721_NOT_OWNER_OR_OPERATOR="003003",r.ERC721_NOT_OWNER_APPROWED_OR_OPERATOR="003004",r.ERC721_NOT_ABLE_TO_RECEIVE_NFT="003005",r.ERC721_NFT_ALREADY_EXISTS="003006",r.ERC721_METADATA_ZERO_ADDRESS="004001",r.ERC721_METADATA_NOT_VALID_NFT="004002",r.ERC721_METADATA_NOT_OWNER_OR_OPERATOR="004003",r.ERC721_METADATA_NOT_OWNER_APPROWED_OR_OPERATOR="004004",r.ERC721_METADATA_NOT_ABLE_TO_RECEIVE_NFT="004005",r.ERC721_METADATA_NFT_ALREADY_EXISTS="004006",r.ERC721_ENUMERABLE_ZERO_ADDRESS="005001",r.ERC721_ENUMERABLE_NOT_VALID_NFT="005002",r.ERC721_ENUMERABLE_NOT_OWNER_OR_OPERATOR="005003",r.ERC721_ENUMERABLE_NOT_OWNER_APPROWED_OR_OPERATOR="005004",r.ERC721_ENUMERABLE_NOT_ABLE_TO_RECEIVE_NFT="005005",r.ERC721_ENUMERABLE_NFT_ALREADY_EXISTS="005006",r.ERC721_ENUMERABLE_INVALID_INDEX="005007",r.ERC721_METADATA_ENUMERABLE_ZERO_ADDRESS="006001",r.ERC721_METADATA_ENUMERABLE_NOT_VALID_NFT="006002",r.ERC721_METADATA_ENUMERABLE_NOT_OWNER_OR_OPERATOR="006003",r.ERC721_METADATA_ENUMERABLE_NOT_OWNER_APPROWED_OR_OPERATOR="006004",r.ERC721_METADATA_ENUMERABLE_NOT_ABLE_TO_RECEIVE_NFT="006005",r.ERC721_METADATA_ENUMERABLE_NFT_ALREADY_EXISTS="006006",r.ERC721_METADATA_ENUMERABLE_INVALID_INDEX="006007",r.XCERT_CAPABILITY_NOT_SUPPORTED="007001",r.XCERT_TRANSFERS_DISABLED="007002",r.XCERT_NOT_VALID_XCERT="007003",r.XCERT_NOT_OWNER_OR_OPERATOR="007004",r.XCERT_INVALID_SIGNATURE="007005",r.XCERT_INVALID_SIGNATURE_KIND="007006",r.XCERT_CLAIM_PERFORMED="007007",r.XCERT_CLAIM_EXPIRED="007008",r.XCERT_CLAIM_CANCELED="007009",r.XCERT_NOT_OWNER="007010",r.SAFE_MATH_OVERFLOW="008001",r.SAFE_MATH_SUBTRAHEND_GREATER_THEN_MINUEND="008002",r.SAFE_MATH_DIVISION_BY_ZERO="008003",r.XCERT_DEPLOY_GATEWAY_INVALID_SIGNATURE_KIND="009001",r.XCERT_DEPLOY_GATEWAY_TAKER_NOT_EQUAL_TO_SENDER="009002",r.XCERT_DEPLOY_GATEWAY_CLAIM_EXPIRED="009003",r.XCERT_DEPLOY_GATEWAY_INVALID_SIGNATURE="009004",r.XCERT_DEPLOY_GATEWAY_DEPLOY_CANCELED="009005",r.XCERT_DEPLOY_GATEWAY_DEPLOY_ALREADY_PERFORMED="009006",r.XCERT_DEPLOY_GATEWAY_MAKER_NOT_EQUAL_TO_SENDER="009007",r.DAPP_TOKEN_NOT_ENOUGH_BALANCE="010001",r.DAPP_TOKEN_NOT_ENOUGH_ALLOWANCE="010002",r.DAPP_TOKEN_NOT_WHITELISTED_ADDRESS="010003",r.DAPP_TOKEN_NOT_MIGRATION_NOT_STARTED="010004",r.DAPP_TOKEN_MIGRATION_STARTED="010005",r.DAPP_TOKEN_NOT_ABLE_TO_MIGRATE="010006",r.DAPP_TOKEN_INVALID_SIGNATURE="010007",r.DAPP_TOKEN_CLAIM_PERFORMED="010008",r.DAPP_TOKEN_CLAIM_EXPIRED="010009",r.DAPP_TOKEN_INVALID_SIGNATURE_KIND="010010",r.DAPP_TOKEN_CLAIM_CANCELED="010011",r.ERC20_DEPLOY_GATEWAY_INVALID_SIGNATURE_KIND="011001",r.ERC20_DEPLOY_GATEWAY_TAKER_NOT_EQUAL_TO_SENDER="011002",r.ERC20_DEPLOY_GATEWAY_CLAIM_EXPIRED="011003",r.ERC20_DEPLOY_GATEWAY_INVALID_SIGNATURE="011004",r.ERC20_DEPLOY_GATEWAY_DEPLOY_CANCELED="011005",r.ERC20_DEPLOY_GATEWAY_DEPLOY_ALREADY_PERFORMED="011006",r.ERC20_DEPLOY_GATEWAY_MAKER_NOT_EQUAL_TO_SENDER="011007",r.ERC20_TRANSFER_PROXY_TRANSFER_FAILED="012001",r.ACTIONS_GATEWAY_INVALID_SIGNATURE_KIND="015001",r.ACTIONS_GATEWAY_INVALID_PROXY="015002",r.ACTIONS_GATEWAY_SENDER_NOT_A_SIGNER="015003",r.ACTIONS_GATEWAY_CLAIM_EXPIRED="015004",r.ACTIONS_GATEWAY_INVALID_SIGNATURE="015005",r.ACTIONS_GATEWAY_ORDER_CANCELED="015006",r.ACTIONS_GATEWAY_ORDER_ALREADY_PERFORMED="015007",r.ACTIONS_GATEWAY_SIGNERS_DOES_NOT_INCLUDE_SENDER="015008",r.SIGNER_DOES_NOT_HAVE_ALLOW_CREATE_ASSET_ABILITY="015009",r.SIGNER_DOES_NOT_HAVE_ALLOW_UPDATE_ASSET_ABILITY="015010",r.SIGNER_DOES_NOT_HAVE_ALLOW_MANAGE_ABILITIES_ABILITY="015011",r.SIGNER_IS_NOT_DESTROY_ASSET_OWNER="015012",r.ABILITABLE_NOT_AUTHORIZED="017001",r.ABILITABLE_INVALID_INPUT="017002",r.OWNABLE_NOT_OWNER="018001",r.OWNABLE_ZERO_ADDRESS="018002",r.CLAIMABLE_NOT_PENDING_OWNER="019001"},1414:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const i=r(2503);e.default={[i.ProviderIssue.ACTIONS_ORDER_KIND_NOT_SUPPORTED]:"Actions order kind not supported.",[i.ProviderIssue.DYNAMIC_ACTIONS_ORDER_SIGNATURES]:"Amount of signature not consistent with signers for DYNAMIC_ACTIONS_ORDER kind.",[i.ProviderIssue.FIXED_ACTIONS_ORDER_SIGNATURES]:"Amount of signature not consistent with signers for FIXED_ACTIONS_ORDER kind.",[i.ProviderIssue.SIGNED_DYNAMIC_ACTIONS_ORDER_SIGNATURES]:"Amount of signature not consistent with signers for SIGNED_DYNAMIC_ACTIONS_ORDER kind.",[i.ProviderIssue.SIGNED_FIXED_ACTIONS_ORDER_SIGNATURES]:"Amount of signature not consistent with signers for SIGNED_FIXED_ACTIONS_ORDER kind.",[i.ProviderIssue.NO_RECEIVER_ID]:"ReceiverId is not set.",[i.ProviderIssue.PROXY_KIND_NOT_SUPPORTED]:"Invalid proxy kind.",[i.ProviderIssue.SENDER_ID_NOT_A_SIGNER]:"SenderId is not a signer.",[i.ProviderIssue.SENDER_ID_AND_RECEIVER_ID_MISSING]:"Both senderId and receiverId are missing.",[i.ProviderIssue.ACTION_KIND_NOT_SUPPORTED]:"Not implemented.",[i.ProviderIssue.ERC20_APPROVAL_RACE_CONDITION]:"First set approval to 0. ERC-20 token potential attack.",[i.ProviderIssue.ERC20_NOT_ENOUGH_BALANCE]:"Sender does not have sufficient balance.",[i.ProviderIssue.ERC20_NOT_ENOUGH_ALLOWANCE]:"You do not have sufficient allowance.",[i.ProviderIssue.ERC721_ZERO_ADDRESS]:"Provided address cannot be zero address.",[i.ProviderIssue.ERC721_NOT_VALID_NFT]:"Asset with this ID does not exist.",[i.ProviderIssue.ERC721_NOT_OWNER_OR_OPERATOR]:"Sender is neither asset owner nor operator.",[i.ProviderIssue.ERC721_NOT_OWNER_APPROWED_OR_OPERATOR]:"Sender is neither asset owner, approved nor operator.",[i.ProviderIssue.ERC721_NOT_ABLE_TO_RECEIVE_NFT]:"Receiver is not able to safely receive the asset.",[i.ProviderIssue.ERC721_NFT_ALREADY_EXISTS]:"Asset with provided ID already exists.",[i.ProviderIssue.ERC721_METADATA_ZERO_ADDRESS]:"Provided address cannot be zero address.",[i.ProviderIssue.ERC721_METADATA_NOT_VALID_NFT]:"Asset with this ID does not exist.",[i.ProviderIssue.ERC721_METADATA_NOT_OWNER_OR_OPERATOR]:"Sender is neither asset owner nor operator.",[i.ProviderIssue.ERC721_METADATA_NOT_OWNER_APPROWED_OR_OPERATOR]:"Sender is neither asset owner, approved nor operator.",[i.ProviderIssue.ERC721_METADATA_NOT_ABLE_TO_RECEIVE_NFT]:"Receiver is not able to safely receive the asset.",[i.ProviderIssue.ERC721_METADATA_NFT_ALREADY_EXISTS]:"Asset with provided ID already exists.",[i.ProviderIssue.ERC721_ENUMERABLE_ZERO_ADDRESS]:"Provided address cannot be zero address.",[i.ProviderIssue.ERC721_ENUMERABLE_NOT_VALID_NFT]:"Asset with this ID does not exist.",[i.ProviderIssue.ERC721_ENUMERABLE_NOT_OWNER_OR_OPERATOR]:"Sender is neither asset owner nor operator.",[i.ProviderIssue.ERC721_ENUMERABLE_NOT_OWNER_APPROWED_OR_OPERATOR]:"Sender is neither asset owner, approved nor operator.",[i.ProviderIssue.ERC721_ENUMERABLE_NOT_ABLE_TO_RECEIVE_NFT]:"Receiver is not able to safely receive the asset.",[i.ProviderIssue.ERC721_ENUMERABLE_NFT_ALREADY_EXISTS]:"Asset with provided ID already exists.",[i.ProviderIssue.ERC721_ENUMERABLE_INVALID_INDEX]:"There is no asset at provided index.",[i.ProviderIssue.ERC721_METADATA_ENUMERABLE_ZERO_ADDRESS]:"Provided address cannot be zero address.",[i.ProviderIssue.ERC721_METADATA_ENUMERABLE_NOT_VALID_NFT]:"Asset with this ID does not exist.",[i.ProviderIssue.ERC721_METADATA_ENUMERABLE_NOT_OWNER_OR_OPERATOR]:"Sender is neither asset owner nor operator.",[i.ProviderIssue.ERC721_METADATA_ENUMERABLE_NOT_OWNER_APPROWED_OR_OPERATOR]:"Sender is neither asset owner, approved nor operator.",[i.ProviderIssue.ERC721_METADATA_ENUMERABLE_NOT_ABLE_TO_RECEIVE_NFT]:"Receiver is not able to safely receive the asset.",[i.ProviderIssue.ERC721_METADATA_ENUMERABLE_NFT_ALREADY_EXISTS]:"Asset with provided ID already exists.",[i.ProviderIssue.ERC721_METADATA_ENUMERABLE_INVALID_INDEX]:"There is no asset at provided index.",[i.ProviderIssue.XCERT_CAPABILITY_NOT_SUPPORTED]:"Asset ledger does not have capability for this action.",[i.ProviderIssue.XCERT_TRANSFERS_DISABLED]:"Transfers on this asset ledger are currently disabled.",[i.ProviderIssue.XCERT_NOT_VALID_XCERT]:"Asset with this ID does not exist.",[i.ProviderIssue.XCERT_NOT_OWNER_OR_OPERATOR]:"Sender is neither asset owner nor operator.",[i.ProviderIssue.XCERT_INVALID_SIGNATURE]:"Provided signature is invalid.",[i.ProviderIssue.XCERT_INVALID_SIGNATURE_KIND]:"Provided signature kind is invalid.",[i.ProviderIssue.XCERT_CLAIM_PERFORMED]:"This order was already performed.",[i.ProviderIssue.XCERT_CLAIM_EXPIRED]:"This order has expired.",[i.ProviderIssue.XCERT_CLAIM_CANCELED]:"This order was canceled.",[i.ProviderIssue.XCERT_NOT_OWNER]:"You are not the owner of the order.",[i.ProviderIssue.SAFE_MATH_OVERFLOW]:"This action caused a math error: overflow.",[i.ProviderIssue.SAFE_MATH_SUBTRAHEND_GREATER_THEN_MINUEND]:"This action caused a math error: subtrahend is greater than minuend.",[i.ProviderIssue.SAFE_MATH_DIVISION_BY_ZERO]:"This action caused a math error: division by zero.",[i.ProviderIssue.XCERT_DEPLOY_GATEWAY_INVALID_SIGNATURE_KIND]:"Provided signature kind is invalid.",[i.ProviderIssue.XCERT_DEPLOY_GATEWAY_TAKER_NOT_EQUAL_TO_SENDER]:"Sender is not allowed to execute this order.",[i.ProviderIssue.XCERT_DEPLOY_GATEWAY_CLAIM_EXPIRED]:"This order has expired.",[i.ProviderIssue.XCERT_DEPLOY_GATEWAY_INVALID_SIGNATURE]:"Provided signature is invalid.",[i.ProviderIssue.XCERT_DEPLOY_GATEWAY_DEPLOY_CANCELED]:"This order was canceled.",[i.ProviderIssue.XCERT_DEPLOY_GATEWAY_DEPLOY_ALREADY_PERFORMED]:"This order was already performed.",[i.ProviderIssue.XCERT_DEPLOY_GATEWAY_MAKER_NOT_EQUAL_TO_SENDER]:"Sender is not the creator of this order.",[i.ProviderIssue.DAPP_TOKEN_NOT_ENOUGH_BALANCE]:"Sender does not have sufficient balance.",[i.ProviderIssue.DAPP_TOKEN_NOT_ENOUGH_ALLOWANCE]:"You do not have sufficient allowance.",[i.ProviderIssue.DAPP_TOKEN_NOT_WHITELISTED_ADDRESS]:"Tokens cannot be sent to this recipient. Recipients are limited.",[i.ProviderIssue.DAPP_TOKEN_NOT_MIGRATION_NOT_STARTED]:"Migration is not in progress.",[i.ProviderIssue.DAPP_TOKEN_MIGRATION_STARTED]:"Migration is in progress.",[i.ProviderIssue.DAPP_TOKEN_NOT_ABLE_TO_MIGRATE]:"Migration cannot be performed. Please notify token owner.",[i.ProviderIssue.DAPP_TOKEN_INVALID_SIGNATURE]:"Provided signature is invalid.",[i.ProviderIssue.DAPP_TOKEN_CLAIM_PERFORMED]:"This order was already performed.",[i.ProviderIssue.DAPP_TOKEN_CLAIM_EXPIRED]:"This order has expired.",[i.ProviderIssue.DAPP_TOKEN_INVALID_SIGNATURE_KIND]:"Provided signature kind is invalid.",[i.ProviderIssue.DAPP_TOKEN_CLAIM_CANCELED]:"This order was canceled.",[i.ProviderIssue.ERC20_DEPLOY_GATEWAY_INVALID_SIGNATURE_KIND]:"Provided signature kind is invalid.",[i.ProviderIssue.ERC20_DEPLOY_GATEWAY_TAKER_NOT_EQUAL_TO_SENDER]:"Sender is not allowed to execute this order.",[i.ProviderIssue.ERC20_DEPLOY_GATEWAY_CLAIM_EXPIRED]:"This order has expired.",[i.ProviderIssue.ERC20_DEPLOY_GATEWAY_INVALID_SIGNATURE]:"Provided signature is invalid.",[i.ProviderIssue.ERC20_DEPLOY_GATEWAY_DEPLOY_CANCELED]:"This order was canceled.",[i.ProviderIssue.ERC20_DEPLOY_GATEWAY_DEPLOY_ALREADY_PERFORMED]:"This order was already performed.",[i.ProviderIssue.ERC20_DEPLOY_GATEWAY_MAKER_NOT_EQUAL_TO_SENDER]:"Sender is not the creator of this order.",[i.ProviderIssue.ERC20_TRANSFER_PROXY_TRANSFER_FAILED]:"Transfer failed.",[i.ProviderIssue.ACTIONS_GATEWAY_INVALID_SIGNATURE_KIND]:"Provided signature kind is invalid.",[i.ProviderIssue.ACTIONS_GATEWAY_INVALID_PROXY]:"Invalid proxy.",[i.ProviderIssue.ACTIONS_GATEWAY_SENDER_NOT_A_SIGNER]:"Sender is not one of the signers.",[i.ProviderIssue.ACTIONS_GATEWAY_CLAIM_EXPIRED]:"This order has expired.",[i.ProviderIssue.ACTIONS_GATEWAY_INVALID_SIGNATURE]:"Provided signature is invalid.",[i.ProviderIssue.ACTIONS_GATEWAY_ORDER_CANCELED]:"This order was canceled.",[i.ProviderIssue.ACTIONS_GATEWAY_ORDER_ALREADY_PERFORMED]:"This order was already performed.",[i.ProviderIssue.ACTIONS_GATEWAY_SIGNERS_DOES_NOT_INCLUDE_SENDER]:"Sender is not one of the signers.",[i.ProviderIssue.SIGNER_DOES_NOT_HAVE_ALLOW_CREATE_ASSET_ABILITY]:"Signer of CREATE_ASSET action does not have ALLOW_CREATE_ASSET ability.",[i.ProviderIssue.SIGNER_DOES_NOT_HAVE_ALLOW_UPDATE_ASSET_ABILITY]:"Signer of UPDATE_ASSET action does not have ALLOW_UPDATE_ASSET ability.",[i.ProviderIssue.SIGNER_DOES_NOT_HAVE_ALLOW_MANAGE_ABILITIES_ABILITY]:"Signer of SET_ASSET_LEDGER_ABILITY action does not have ALLOW_MANAGE_ABILITIES ability.",[i.ProviderIssue.SIGNER_IS_NOT_DESTROY_ASSET_OWNER]:"Signer of DESTROY_ASSET action is not the asset owner.",[i.ProviderIssue.ABILITABLE_NOT_AUTHORIZED]:"Sender does not have specified ability.",[i.ProviderIssue.ABILITABLE_INVALID_INPUT]:"Ability 0 is not a valid ability.",[i.ProviderIssue.OWNABLE_NOT_OWNER]:"Sender is not an owner.",[i.ProviderIssue.OWNABLE_ZERO_ADDRESS]:"Provided address cannot be zero address.",[i.ProviderIssue.CLAIMABLE_NOT_PENDING_OWNER]:"Sender cannot claim ownership."}},8330:(t,e)=>{"use strict";var r;Object.defineProperty(e,"__esModule",{value:!0}),e.MutationEvent=void 0,(r=e.MutationEvent||(e.MutationEvent={})).COMPLETE="complete",r.CONFIRM="confirm",r.ERROR="error"},677:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ProviderError=e.ProviderEvent=void 0;const i=r(1414);var n;(n=e.ProviderEvent||(e.ProviderEvent={})).ACCOUNT_CHANGE="accountChanged",n.NETWORK_CHANGE="networkChanged";class o extends Error{constructor(t,e){super(),this.name="ProviderError",this.issue=t,this.original=e,this.message=i.default[t]||`GenericProvider error [issue: ${t}]`,Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}}e.ProviderError=o},5079:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},6112:function(t,e,r){"use strict";var i=this&&this.__createBinding||(Object.create?function(t,e,r,i){void 0===i&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){void 0===i&&(i=r),t[i]=e[r]}),n=this&&this.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||i(e,t,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(r(4508),e),n(r(677),e),n(r(1340),e),n(r(8330),e),n(r(8096),e),n(r(5079),e),n(r(2503),e)},5353:function(t,e,r){"use strict";var i=this&&this.__createBinding||(Object.create?function(t,e,r,i){void 0===i&&(i=r),Object.defineProperty(t,i,{enumerable:!0,get:function(){return e[r]}})}:function(t,e,r,i){void 0===i&&(i=r),t[i]=e[r]}),n=this&&this.__exportStar||function(t,e){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(e,r)||i(e,t,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(r(6496),e),n(r(509),e),n(r(9203),e),n(r(2890),e),n(r(4467),e),n(r(899),e),n(r(2938),e),n(r(7612),e)},6496:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0}),e.fetchJson=void 0,e.fetchJson=function(t,e){return i(this,void 0,void 0,(function*(){if("undefined"!=typeof window)return window.fetch(t,e).then((t=>t.json()));if(0===t.lastIndexOf("http",0))return r(9002)(t,e).then((t=>t.json()));try{return Object(function(){var t=new Error("Cannot find module 'fs'");throw t.code="MODULE_NOT_FOUND",t}()).promises.readFile(t,"utf8").then((t=>JSON.parse(t)))}catch(t){return null}}))}},9203:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.keccak256=void 0;const i=r(6395);e.keccak256=function(t){return i.keccak256(t)}},509:function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r||(r=Promise))((function(n,o){function s(t){try{u(i.next(t))}catch(t){o(t)}}function a(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):(e=t.value,e instanceof r?e:new r((function(t){t(e)}))).then(s,a)}u((i=i.apply(t,e||[])).next())}))};Object.defineProperty(e,"__esModule",{value:!0}),e.sha=void 0,e.sha=function(t,e){return i(this,void 0,void 0,(function*(){if("undefined"!=typeof window){const r=new window.TextEncoder("utf-8").encode(e),i=yield window.crypto.subtle.digest(`SHA-${t}`,r);return Array.from(new Uint8Array(i)).map((t=>`00${t.toString(16)}`.slice(-2))).join("")}return r(1111).createHash(`sha${t}`).update(e).digest("hex")}))}},2890:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toFloat=void 0,e.toFloat=function(t){return parseFloat(`${t}`)||0}},4467:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toInteger=void 0,e.toInteger=function(t){return"number"==typeof t&&t>Number.MAX_SAFE_INTEGER?0:"boolean"==typeof t&&!0===t?1:parseInt(`${t}`)||0}},899:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toSeconds=void 0,e.toSeconds=function(t){return parseInt(""+parseFloat(`${t}`)/1e3)||0}},2938:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toString=void 0,e.toString=function(t){return null!=t?t.toString():null}},7612:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.toTuple=void 0,e.toTuple=function t(e){if(!(e instanceof Object))return[];const r=[];let i=0;return Object.keys(e).forEach((n=>{if(e[n]instanceof Object)r[i]=t(e[n]);else if(e[n]instanceof Array){let o=0;const s=[];e[n].forEach((r=>{s[o]=t(e[n]),o++})),r[i]=s}else r[i]=e[n];i++})),r}},1111:t=>{"use strict";t.exports=void 0},2574:()=>{}},e={};function r(i){if(e[i])return e[i].exports;var n=e[i]={id:i,loaded:!1,exports:{}};return t[i].call(n.exports,n,n.exports,r),n.loaded=!0,n.exports}r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),window.$0xcert=window.$0xcert||{},Object.assign(window.$0xcert,r(5291))})();