Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@burstjs/contracts

Package Overview
Dependencies
Maintainers
2
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@burstjs/contracts - npm Package Compare versions

Comparing version 0.6.0-beta.5 to 0.6.0-beta.6

2

dist/burstjs.contracts.min.js

@@ -1,2 +0,2 @@

var b$contracts=function(e){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function n(e,t){return e(t={exports:{}},t.exports),t.exports}function o(e){return e&&e.default||e}var i=n(function(e,r){var n=t&&t.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(o,i){function a(e){try{c(n.next(e))}catch(e){i(e)}}function u(e){try{c(n.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r(function(e){e(t)})).then(a,u)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.asyncRetry=function e(t){return n(this,void 0,void 0,function*(){const{asyncFn:r,onFailureAsync:n,retryCount:o=1,maxRetrials:i=20}=t;try{return yield r()}catch(t){if(o>i)throw t;if(!(yield n(t,o)))throw t;yield e({asyncFn:r,onFailureAsync:n,retryCount:o+1})}})}});r(i);i.asyncRetry;var a=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.AddressPrefix="BURST",t.GenesisBlockTime=Date.UTC(2014,7,11,2,0,0,0)/1e3,t.initialCodeword=[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],t.gexp=[1,2,4,8,16,5,10,20,13,26,17,7,14,28,29,31,27,19,3,6,12,24,21,15,30,25,23,11,22,9,18,1],t.glog=[0,0,1,18,2,5,19,11,3,29,6,27,20,8,12,23,4,10,30,17,7,22,28,26,21,25,9,16,13,14,24,15],t.cwmap=[3,2,1,0,7,6,5,4,13,14,15,16,12,8,9,10,11],t.alphabet="23456789ABCDEFGHJKLMNPQRSTUVWXYZ".split(""),t.base32Length=13,t.ginv=(e=>t.gexp[31-t.glog[e]]),t.gmult=((e,r)=>{if(0===e||0===r)return 0;const n=(t.glog[e]+t.glog[r])%31;return t.gexp[n]})});r(a);a.AddressPrefix,a.GenesisBlockTime,a.initialCodeword,a.gexp,a.glog,a.cwmap,a.alphabet,a.base32Length,a.ginv,a.gmult;var u=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});class r{constructor(e){this._burstTimestamp=e}static fromBurstTimestamp(e){return new r(e)}static fromDate(e){const t=new r(0);return t.setDate(e),t}getBurstTimestamp(){return this._burstTimestamp}setBurstTimestamp(e){this._burstTimestamp=e}getEpoch(){return 1e3*(a.GenesisBlockTime+this._burstTimestamp)}getDate(){return new Date(this.getEpoch())}setDate(e){this._burstTimestamp=Math.round(e.getTime()/1e3)-a.GenesisBlockTime}equals(e){return this._burstTimestamp===e._burstTimestamp}before(e){return this._burstTimestamp<e._burstTimestamp}after(e){return this._burstTimestamp>e._burstTimestamp}}t.BurstTime=r});r(u);u.BurstTime;var c=n(function(e){!function(t){var r,n=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,o=Math.ceil,i=Math.floor,a="[BigNumber Error] ",u=a+"Number primitive has more than 15 significant digits: ",c=1e14,s=14,l=9007199254740991,f=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],h=1e7,d=1e9;function g(e){var t=0|e;return e>0||e===t?t:t-1}function p(e){for(var t,r,n=1,o=e.length,i=e[0]+"";n<o;){for(t=e[n++]+"",r=s-t.length;r--;t="0"+t);i+=t}for(o=i.length;48===i.charCodeAt(--o););return i.slice(0,o+1||1)}function v(e,t){var r,n,o=e.c,i=t.c,a=e.s,u=t.s,c=e.e,s=t.e;if(!a||!u)return null;if(r=o&&!o[0],n=i&&!i[0],r||n)return r?n?0:-u:a;if(a!=u)return a;if(r=a<0,n=c==s,!o||!i)return n?0:!o^r?1:-1;if(!n)return c>s^r?1:-1;for(u=(c=o.length)<(s=i.length)?c:s,a=0;a<u;a++)if(o[a]!=i[a])return o[a]>i[a]^r?1:-1;return c==s?0:c>s^r?1:-1}function m(e,t,r,n){if(e<t||e>r||e!==i(e))throw Error(a+(n||"Argument")+("number"==typeof e?e<t||e>r?" out of range: ":" not an integer: ":" not a primitive number: ")+String(e))}function y(e){var t=e.c.length-1;return g(e.e/s)==t&&e.c[t]%2!=0}function b(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(t<0?"e":"e+")+t}function w(e,t,r){var n,o;if(t<0){for(o=r+".";++t;o+=r);e=o+e}else if(++t>(n=e.length)){for(o=r,t-=n;--t;o+=r);e+=o}else t<n&&(e=e.slice(0,t)+"."+e.slice(t));return e}(r=function e(t){var r,_,S,A,T,B,x,O,P,E=V.prototype={constructor:V,toString:null,valueOf:null},N=new V(1),k=20,C=4,D=-7,M=21,j=-1e7,U=1e7,F=!1,I=1,R=0,H={prefix:"",groupSize:3,secondaryGroupSize:0,groupSeparator:",",decimalSeparator:".",fractionGroupSize:0,fractionGroupSeparator:" ",suffix:""},L="0123456789abcdefghijklmnopqrstuvwxyz";function V(e,t){var r,o,a,c,f,h,d,g,p=this;if(!(p instanceof V))return new V(e,t);if(null==t){if(e&&!0===e._isBigNumber)return p.s=e.s,void(!e.c||e.e>U?p.c=p.e=null:e.e<j?p.c=[p.e=0]:(p.e=e.e,p.c=e.c.slice()));if((h="number"==typeof e)&&0*e==0){if(p.s=1/e<0?(e=-e,-1):1,e===~~e){for(c=0,f=e;f>=10;f/=10,c++);return void(c>U?p.c=p.e=null:(p.e=c,p.c=[e]))}g=String(e)}else{if(!n.test(g=String(e)))return S(p,g,h);p.s=45==g.charCodeAt(0)?(g=g.slice(1),-1):1}(c=g.indexOf("."))>-1&&(g=g.replace(".","")),(f=g.search(/e/i))>0?(c<0&&(c=f),c+=+g.slice(f+1),g=g.substring(0,f)):c<0&&(c=g.length)}else{if(m(t,2,L.length,"Base"),10==t)return q(p=new V(e),k+p.e+1,C);if(g=String(e),h="number"==typeof e){if(0*e!=0)return S(p,g,h,t);if(p.s=1/e<0?(g=g.slice(1),-1):1,V.DEBUG&&g.replace(/^0\.0*|\./,"").length>15)throw Error(u+e)}else p.s=45===g.charCodeAt(0)?(g=g.slice(1),-1):1;for(r=L.slice(0,t),c=f=0,d=g.length;f<d;f++)if(r.indexOf(o=g.charAt(f))<0){if("."==o){if(f>c){c=d;continue}}else if(!a&&(g==g.toUpperCase()&&(g=g.toLowerCase())||g==g.toLowerCase()&&(g=g.toUpperCase()))){a=!0,f=-1,c=0;continue}return S(p,String(e),h,t)}h=!1,(c=(g=_(g,t,10,p.s)).indexOf("."))>-1?g=g.replace(".",""):c=g.length}for(f=0;48===g.charCodeAt(f);f++);for(d=g.length;48===g.charCodeAt(--d););if(g=g.slice(f,++d)){if(d-=f,h&&V.DEBUG&&d>15&&(e>l||e!==i(e)))throw Error(u+p.s*e);if((c=c-f-1)>U)p.c=p.e=null;else if(c<j)p.c=[p.e=0];else{if(p.e=c,p.c=[],f=(c+1)%s,c<0&&(f+=s),f<d){for(f&&p.c.push(+g.slice(0,f)),d-=s;f<d;)p.c.push(+g.slice(f,f+=s));f=s-(g=g.slice(f)).length}else f-=d;for(;f--;g+="0");p.c.push(+g)}}else p.c=[p.e=0]}function $(e,t,r,n){var o,i,a,u,c;if(null==r?r=C:m(r,0,8),!e.c)return e.toString();if(o=e.c[0],a=e.e,null==t)c=p(e.c),c=1==n||2==n&&(a<=D||a>=M)?b(c,a):w(c,a,"0");else if(i=(e=q(new V(e),t,r)).e,u=(c=p(e.c)).length,1==n||2==n&&(t<=i||i<=D)){for(;u<t;c+="0",u++);c=b(c,i)}else if(t-=a,c=w(c,i,"0"),i+1>u){if(--t>0)for(c+=".";t--;c+="0");}else if((t+=i-u)>0)for(i+1==u&&(c+=".");t--;c+="0");return e.s<0&&o?"-"+c:c}function G(e,t){for(var r,n=1,o=new V(e[0]);n<e.length;n++){if(!(r=new V(e[n])).s){o=r;break}t.call(o,r)&&(o=r)}return o}function z(e,t,r){for(var n=1,o=t.length;!t[--o];t.pop());for(o=t[0];o>=10;o/=10,n++);return(r=n+r*s-1)>U?e.c=e.e=null:r<j?e.c=[e.e=0]:(e.e=r,e.c=t),e}function q(e,t,r,n){var a,u,l,h,d,g,p,v=e.c,m=f;if(v){e:{for(a=1,h=v[0];h>=10;h/=10,a++);if((u=t-a)<0)u+=s,l=t,p=(d=v[g=0])/m[a-l-1]%10|0;else if((g=o((u+1)/s))>=v.length){if(!n)break e;for(;v.length<=g;v.push(0));d=p=0,a=1,l=(u%=s)-s+1}else{for(d=h=v[g],a=1;h>=10;h/=10,a++);p=(l=(u%=s)-s+a)<0?0:d/m[a-l-1]%10|0}if(n=n||t<0||null!=v[g+1]||(l<0?d:d%m[a-l-1]),n=r<4?(p||n)&&(0==r||r==(e.s<0?3:2)):p>5||5==p&&(4==r||n||6==r&&(u>0?l>0?d/m[a-l]:0:v[g-1])%10&1||r==(e.s<0?8:7)),t<1||!v[0])return v.length=0,n?(t-=e.e+1,v[0]=m[(s-t%s)%s],e.e=-t||0):v[0]=e.e=0,e;if(0==u?(v.length=g,h=1,g--):(v.length=g+1,h=m[s-u],v[g]=l>0?i(d/m[a-l]%m[l])*h:0),n)for(;;){if(0==g){for(u=1,l=v[0];l>=10;l/=10,u++);for(l=v[0]+=h,h=1;l>=10;l/=10,h++);u!=h&&(e.e++,v[0]==c&&(v[0]=1));break}if(v[g]+=h,v[g]!=c)break;v[g--]=0,h=1}for(u=v.length;0===v[--u];v.pop());}e.e>U?e.c=e.e=null:e.e<j&&(e.c=[e.e=0])}return e}function Z(e){var t,r=e.e;return null===r?e.toString():(t=p(e.c),t=r<=D||r>=M?b(t,r):w(t,r,"0"),e.s<0?"-"+t:t)}return V.clone=e,V.ROUND_UP=0,V.ROUND_DOWN=1,V.ROUND_CEIL=2,V.ROUND_FLOOR=3,V.ROUND_HALF_UP=4,V.ROUND_HALF_DOWN=5,V.ROUND_HALF_EVEN=6,V.ROUND_HALF_CEIL=7,V.ROUND_HALF_FLOOR=8,V.EUCLID=9,V.config=V.set=function(e){var t,r;if(null!=e){if("object"!=typeof e)throw Error(a+"Object expected: "+e);if(e.hasOwnProperty(t="DECIMAL_PLACES")&&(m(r=e[t],0,d,t),k=r),e.hasOwnProperty(t="ROUNDING_MODE")&&(m(r=e[t],0,8,t),C=r),e.hasOwnProperty(t="EXPONENTIAL_AT")&&((r=e[t])&&r.pop?(m(r[0],-d,0,t),m(r[1],0,d,t),D=r[0],M=r[1]):(m(r,-d,d,t),D=-(M=r<0?-r:r))),e.hasOwnProperty(t="RANGE"))if((r=e[t])&&r.pop)m(r[0],-d,-1,t),m(r[1],1,d,t),j=r[0],U=r[1];else{if(m(r,-d,d,t),!r)throw Error(a+t+" cannot be zero: "+r);j=-(U=r<0?-r:r)}if(e.hasOwnProperty(t="CRYPTO")){if((r=e[t])!==!!r)throw Error(a+t+" not true or false: "+r);if(r){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw F=!r,Error(a+"crypto unavailable");F=r}else F=r}if(e.hasOwnProperty(t="MODULO_MODE")&&(m(r=e[t],0,9,t),I=r),e.hasOwnProperty(t="POW_PRECISION")&&(m(r=e[t],0,d,t),R=r),e.hasOwnProperty(t="FORMAT")){if("object"!=typeof(r=e[t]))throw Error(a+t+" not an object: "+r);H=r}if(e.hasOwnProperty(t="ALPHABET")){if("string"!=typeof(r=e[t])||/^.$|[+-.\s]|(.).*\1/.test(r))throw Error(a+t+" invalid: "+r);L=r}}return{DECIMAL_PLACES:k,ROUNDING_MODE:C,EXPONENTIAL_AT:[D,M],RANGE:[j,U],CRYPTO:F,MODULO_MODE:I,POW_PRECISION:R,FORMAT:H,ALPHABET:L}},V.isBigNumber=function(e){if(!e||!0!==e._isBigNumber)return!1;if(!V.DEBUG)return!0;var t,r,n=e.c,o=e.e,u=e.s;e:if("[object Array]"=={}.toString.call(n)){if((1===u||-1===u)&&o>=-d&&o<=d&&o===i(o)){if(0===n[0]){if(0===o&&1===n.length)return!0;break e}if((t=(o+1)%s)<1&&(t+=s),String(n[0]).length==t){for(t=0;t<n.length;t++)if((r=n[t])<0||r>=c||r!==i(r))break e;if(0!==r)return!0}}}else if(null===n&&null===o&&(null===u||1===u||-1===u))return!0;throw Error(a+"Invalid BigNumber: "+e)},V.maximum=V.max=function(){return G(arguments,E.lt)},V.minimum=V.min=function(){return G(arguments,E.gt)},V.random=(A=9007199254740992*Math.random()&2097151?function(){return i(9007199254740992*Math.random())}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)},function(e){var t,r,n,u,c,l=0,h=[],g=new V(N);if(null==e?e=k:m(e,0,d),u=o(e/s),F)if(crypto.getRandomValues){for(t=crypto.getRandomValues(new Uint32Array(u*=2));l<u;)(c=131072*t[l]+(t[l+1]>>>11))>=9e15?(r=crypto.getRandomValues(new Uint32Array(2)),t[l]=r[0],t[l+1]=r[1]):(h.push(c%1e14),l+=2);l=u/2}else{if(!crypto.randomBytes)throw F=!1,Error(a+"crypto unavailable");for(t=crypto.randomBytes(u*=7);l<u;)(c=281474976710656*(31&t[l])+1099511627776*t[l+1]+4294967296*t[l+2]+16777216*t[l+3]+(t[l+4]<<16)+(t[l+5]<<8)+t[l+6])>=9e15?crypto.randomBytes(7).copy(t,l):(h.push(c%1e14),l+=7);l=u/7}if(!F)for(;l<u;)(c=A())<9e15&&(h[l++]=c%1e14);for(u=h[--l],e%=s,u&&e&&(c=f[s-e],h[l]=i(u/c)*c);0===h[l];h.pop(),l--);if(l<0)h=[n=0];else{for(n=-1;0===h[0];h.splice(0,1),n-=s);for(l=1,c=h[0];c>=10;c/=10,l++);l<s&&(n-=s-l)}return g.e=n,g.c=h,g}),V.sum=function(){for(var e=1,t=arguments,r=new V(t[0]);e<t.length;)r=r.plus(t[e++]);return r},_=function(){function e(e,t,r,n){for(var o,i,a=[0],u=0,c=e.length;u<c;){for(i=a.length;i--;a[i]*=t);for(a[0]+=n.indexOf(e.charAt(u++)),o=0;o<a.length;o++)a[o]>r-1&&(null==a[o+1]&&(a[o+1]=0),a[o+1]+=a[o]/r|0,a[o]%=r)}return a.reverse()}return function(t,n,o,i,a){var u,c,s,l,f,h,d,g,v=t.indexOf("."),m=k,y=C;for(v>=0&&(l=R,R=0,t=t.replace(".",""),h=(g=new V(n)).pow(t.length-v),R=l,g.c=e(w(p(h.c),h.e,"0"),10,o,"0123456789"),g.e=g.c.length),s=l=(d=e(t,n,o,a?(u=L,"0123456789"):(u="0123456789",L))).length;0==d[--l];d.pop());if(!d[0])return u.charAt(0);if(v<0?--s:(h.c=d,h.e=s,h.s=i,d=(h=r(h,g,m,y,o)).c,f=h.r,s=h.e),v=d[c=s+m+1],l=o/2,f=f||c<0||null!=d[c+1],f=y<4?(null!=v||f)&&(0==y||y==(h.s<0?3:2)):v>l||v==l&&(4==y||f||6==y&&1&d[c-1]||y==(h.s<0?8:7)),c<1||!d[0])t=f?w(u.charAt(1),-m,u.charAt(0)):u.charAt(0);else{if(d.length=c,f)for(--o;++d[--c]>o;)d[c]=0,c||(++s,d=[1].concat(d));for(l=d.length;!d[--l];);for(v=0,t="";v<=l;t+=u.charAt(d[v++]));t=w(t,s,u.charAt(0))}return t}}(),r=function(){function e(e,t,r){var n,o,i,a,u=0,c=e.length,s=t%h,l=t/h|0;for(e=e.slice();c--;)u=((o=s*(i=e[c]%h)+(n=l*i+(a=e[c]/h|0)*s)%h*h+u)/r|0)+(n/h|0)+l*a,e[c]=o%r;return u&&(e=[u].concat(e)),e}function t(e,t,r,n){var o,i;if(r!=n)i=r>n?1:-1;else for(o=i=0;o<r;o++)if(e[o]!=t[o]){i=e[o]>t[o]?1:-1;break}return i}function r(e,t,r,n){for(var o=0;r--;)e[r]-=o,o=e[r]<t[r]?1:0,e[r]=o*n+e[r]-t[r];for(;!e[0]&&e.length>1;e.splice(0,1));}return function(n,o,a,u,l){var f,h,d,p,v,m,y,b,w,_,S,A,T,B,x,O,P,E=n.s==o.s?1:-1,N=n.c,k=o.c;if(!(N&&N[0]&&k&&k[0]))return new V(n.s&&o.s&&(N?!k||N[0]!=k[0]:k)?N&&0==N[0]||!k?0*E:E/0:NaN);for(w=(b=new V(E)).c=[],E=a+(h=n.e-o.e)+1,l||(l=c,h=g(n.e/s)-g(o.e/s),E=E/s|0),d=0;k[d]==(N[d]||0);d++);if(k[d]>(N[d]||0)&&h--,E<0)w.push(1),p=!0;else{for(B=N.length,O=k.length,d=0,E+=2,(v=i(l/(k[0]+1)))>1&&(k=e(k,v,l),N=e(N,v,l),O=k.length,B=N.length),T=O,S=(_=N.slice(0,O)).length;S<O;_[S++]=0);P=k.slice(),P=[0].concat(P),x=k[0],k[1]>=l/2&&x++;do{if(v=0,(f=t(k,_,O,S))<0){if(A=_[0],O!=S&&(A=A*l+(_[1]||0)),(v=i(A/x))>1)for(v>=l&&(v=l-1),y=(m=e(k,v,l)).length,S=_.length;1==t(m,_,y,S);)v--,r(m,O<y?P:k,y,l),y=m.length,f=1;else 0==v&&(f=v=1),y=(m=k.slice()).length;if(y<S&&(m=[0].concat(m)),r(_,m,S,l),S=_.length,-1==f)for(;t(k,_,O,S)<1;)v++,r(_,O<S?P:k,S,l),S=_.length}else 0===f&&(v++,_=[0]);w[d++]=v,_[0]?_[S++]=N[T]||0:(_=[N[T]],S=1)}while((T++<B||null!=_[0])&&E--);p=null!=_[0],w[0]||w.splice(0,1)}if(l==c){for(d=1,E=w[0];E>=10;E/=10,d++);q(b,a+(b.e=d+h*s-1)+1,u,p)}else b.e=h,b.r=+p;return b}}(),T=/^(-?)0([xbo])(?=\w[\w.]*$)/i,B=/^([^.]+)\.$/,x=/^\.([^.]+)$/,O=/^-?(Infinity|NaN)$/,P=/^\s*\+(?=[\w.])|^\s+|\s+$/g,S=function(e,t,r,n){var o,i=r?t:t.replace(P,"");if(O.test(i))e.s=isNaN(i)?null:i<0?-1:1;else{if(!r&&(i=i.replace(T,function(e,t,r){return o="x"==(r=r.toLowerCase())?16:"b"==r?2:8,n&&n!=o?e:t}),n&&(o=n,i=i.replace(B,"$1").replace(x,"0.$1")),t!=i))return new V(i,o);if(V.DEBUG)throw Error(a+"Not a"+(n?" base "+n:"")+" number: "+t);e.s=null}e.c=e.e=null},E.absoluteValue=E.abs=function(){var e=new V(this);return e.s<0&&(e.s=1),e},E.comparedTo=function(e,t){return v(this,new V(e,t))},E.decimalPlaces=E.dp=function(e,t){var r,n,o,i=this;if(null!=e)return m(e,0,d),null==t?t=C:m(t,0,8),q(new V(i),e+i.e+1,t);if(!(r=i.c))return null;if(n=((o=r.length-1)-g(this.e/s))*s,o=r[o])for(;o%10==0;o/=10,n--);return n<0&&(n=0),n},E.dividedBy=E.div=function(e,t){return r(this,new V(e,t),k,C)},E.dividedToIntegerBy=E.idiv=function(e,t){return r(this,new V(e,t),0,1)},E.exponentiatedBy=E.pow=function(e,t){var r,n,u,c,l,f,h,d,g=this;if((e=new V(e)).c&&!e.isInteger())throw Error(a+"Exponent not an integer: "+Z(e));if(null!=t&&(t=new V(t)),l=e.e>14,!g.c||!g.c[0]||1==g.c[0]&&!g.e&&1==g.c.length||!e.c||!e.c[0])return d=new V(Math.pow(+Z(g),l?2-y(e):+Z(e))),t?d.mod(t):d;if(f=e.s<0,t){if(t.c?!t.c[0]:!t.s)return new V(NaN);(n=!f&&g.isInteger()&&t.isInteger())&&(g=g.mod(t))}else{if(e.e>9&&(g.e>0||g.e<-1||(0==g.e?g.c[0]>1||l&&g.c[1]>=24e7:g.c[0]<8e13||l&&g.c[0]<=9999975e7)))return c=g.s<0&&y(e)?-0:0,g.e>-1&&(c=1/c),new V(f?1/c:c);R&&(c=o(R/s+2))}for(l?(r=new V(.5),f&&(e.s=1),h=y(e)):h=(u=Math.abs(+Z(e)))%2,d=new V(N);;){if(h){if(!(d=d.times(g)).c)break;c?d.c.length>c&&(d.c.length=c):n&&(d=d.mod(t))}if(u){if(0===(u=i(u/2)))break;h=u%2}else if(q(e=e.times(r),e.e+1,1),e.e>14)h=y(e);else{if(0==(u=+Z(e)))break;h=u%2}g=g.times(g),c?g.c&&g.c.length>c&&(g.c.length=c):n&&(g=g.mod(t))}return n?d:(f&&(d=N.div(d)),t?d.mod(t):c?q(d,R,C,void 0):d)},E.integerValue=function(e){var t=new V(this);return null==e?e=C:m(e,0,8),q(t,t.e+1,e)},E.isEqualTo=E.eq=function(e,t){return 0===v(this,new V(e,t))},E.isFinite=function(){return!!this.c},E.isGreaterThan=E.gt=function(e,t){return v(this,new V(e,t))>0},E.isGreaterThanOrEqualTo=E.gte=function(e,t){return 1===(t=v(this,new V(e,t)))||0===t},E.isInteger=function(){return!!this.c&&g(this.e/s)>this.c.length-2},E.isLessThan=E.lt=function(e,t){return v(this,new V(e,t))<0},E.isLessThanOrEqualTo=E.lte=function(e,t){return-1===(t=v(this,new V(e,t)))||0===t},E.isNaN=function(){return!this.s},E.isNegative=function(){return this.s<0},E.isPositive=function(){return this.s>0},E.isZero=function(){return!!this.c&&0==this.c[0]},E.minus=function(e,t){var r,n,o,i,a=this,u=a.s;if(t=(e=new V(e,t)).s,!u||!t)return new V(NaN);if(u!=t)return e.s=-t,a.plus(e);var l=a.e/s,f=e.e/s,h=a.c,d=e.c;if(!l||!f){if(!h||!d)return h?(e.s=-t,e):new V(d?a:NaN);if(!h[0]||!d[0])return d[0]?(e.s=-t,e):new V(h[0]?a:3==C?-0:0)}if(l=g(l),f=g(f),h=h.slice(),u=l-f){for((i=u<0)?(u=-u,o=h):(f=l,o=d),o.reverse(),t=u;t--;o.push(0));o.reverse()}else for(n=(i=(u=h.length)<(t=d.length))?u:t,u=t=0;t<n;t++)if(h[t]!=d[t]){i=h[t]<d[t];break}if(i&&(o=h,h=d,d=o,e.s=-e.s),(t=(n=d.length)-(r=h.length))>0)for(;t--;h[r++]=0);for(t=c-1;n>u;){if(h[--n]<d[n]){for(r=n;r&&!h[--r];h[r]=t);--h[r],h[n]+=c}h[n]-=d[n]}for(;0==h[0];h.splice(0,1),--f);return h[0]?z(e,h,f):(e.s=3==C?-1:1,e.c=[e.e=0],e)},E.modulo=E.mod=function(e,t){var n,o,i=this;return e=new V(e,t),!i.c||!e.s||e.c&&!e.c[0]?new V(NaN):!e.c||i.c&&!i.c[0]?new V(i):(9==I?(o=e.s,e.s=1,n=r(i,e,0,3),e.s=o,n.s*=o):n=r(i,e,0,I),(e=i.minus(n.times(e))).c[0]||1!=I||(e.s=i.s),e)},E.multipliedBy=E.times=function(e,t){var r,n,o,i,a,u,l,f,d,p,v,m,y,b,w,_=this,S=_.c,A=(e=new V(e,t)).c;if(!(S&&A&&S[0]&&A[0]))return!_.s||!e.s||S&&!S[0]&&!A||A&&!A[0]&&!S?e.c=e.e=e.s=null:(e.s*=_.s,S&&A?(e.c=[0],e.e=0):e.c=e.e=null),e;for(n=g(_.e/s)+g(e.e/s),e.s*=_.s,(l=S.length)<(p=A.length)&&(y=S,S=A,A=y,o=l,l=p,p=o),o=l+p,y=[];o--;y.push(0));for(b=c,w=h,o=p;--o>=0;){for(r=0,v=A[o]%w,m=A[o]/w|0,i=o+(a=l);i>o;)r=((f=v*(f=S[--a]%w)+(u=m*f+(d=S[a]/w|0)*v)%w*w+y[i]+r)/b|0)+(u/w|0)+m*d,y[i--]=f%b;y[i]=r}return r?++n:y.splice(0,1),z(e,y,n)},E.negated=function(){var e=new V(this);return e.s=-e.s||null,e},E.plus=function(e,t){var r,n=this,o=n.s;if(t=(e=new V(e,t)).s,!o||!t)return new V(NaN);if(o!=t)return e.s=-t,n.minus(e);var i=n.e/s,a=e.e/s,u=n.c,l=e.c;if(!i||!a){if(!u||!l)return new V(o/0);if(!u[0]||!l[0])return l[0]?e:new V(u[0]?n:0*o)}if(i=g(i),a=g(a),u=u.slice(),o=i-a){for(o>0?(a=i,r=l):(o=-o,r=u),r.reverse();o--;r.push(0));r.reverse()}for((o=u.length)-(t=l.length)<0&&(r=l,l=u,u=r,t=o),o=0;t;)o=(u[--t]=u[t]+l[t]+o)/c|0,u[t]=c===u[t]?0:u[t]%c;return o&&(u=[o].concat(u),++a),z(e,u,a)},E.precision=E.sd=function(e,t){var r,n,o,i=this;if(null!=e&&e!==!!e)return m(e,1,d),null==t?t=C:m(t,0,8),q(new V(i),e,t);if(!(r=i.c))return null;if(n=(o=r.length-1)*s+1,o=r[o]){for(;o%10==0;o/=10,n--);for(o=r[0];o>=10;o/=10,n++);}return e&&i.e+1>n&&(n=i.e+1),n},E.shiftedBy=function(e){return m(e,-l,l),this.times("1e"+e)},E.squareRoot=E.sqrt=function(){var e,t,n,o,i,a=this,u=a.c,c=a.s,s=a.e,l=k+4,f=new V("0.5");if(1!==c||!u||!u[0])return new V(!c||c<0&&(!u||u[0])?NaN:u?a:1/0);if(0==(c=Math.sqrt(+Z(a)))||c==1/0?(((t=p(u)).length+s)%2==0&&(t+="0"),c=Math.sqrt(+t),s=g((s+1)/2)-(s<0||s%2),n=new V(t=c==1/0?"1e"+s:(t=c.toExponential()).slice(0,t.indexOf("e")+1)+s)):n=new V(c+""),n.c[0])for((c=(s=n.e)+l)<3&&(c=0);;)if(i=n,n=f.times(i.plus(r(a,i,l,1))),p(i.c).slice(0,c)===(t=p(n.c)).slice(0,c)){if(n.e<s&&--c,"9999"!=(t=t.slice(c-3,c+1))&&(o||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||(q(n,n.e+k+2,1),e=!n.times(n).eq(a));break}if(!o&&(q(i,i.e+k+2,0),i.times(i).eq(a))){n=i;break}l+=4,c+=4,o=1}return q(n,n.e+k+1,C,e)},E.toExponential=function(e,t){return null!=e&&(m(e,0,d),e++),$(this,e,t,1)},E.toFixed=function(e,t){return null!=e&&(m(e,0,d),e=e+this.e+1),$(this,e,t)},E.toFormat=function(e,t,r){var n,o=this;if(null==r)null!=e&&t&&"object"==typeof t?(r=t,t=null):e&&"object"==typeof e?(r=e,e=t=null):r=H;else if("object"!=typeof r)throw Error(a+"Argument not an object: "+r);if(n=o.toFixed(e,t),o.c){var i,u=n.split("."),c=+r.groupSize,s=+r.secondaryGroupSize,l=r.groupSeparator||"",f=u[0],h=u[1],d=o.s<0,g=d?f.slice(1):f,p=g.length;if(s&&(i=c,c=s,s=i,p-=i),c>0&&p>0){for(i=p%c||c,f=g.substr(0,i);i<p;i+=c)f+=l+g.substr(i,c);s>0&&(f+=l+g.slice(i)),d&&(f="-"+f)}n=h?f+(r.decimalSeparator||"")+((s=+r.fractionGroupSize)?h.replace(new RegExp("\\d{"+s+"}\\B","g"),"$&"+(r.fractionGroupSeparator||"")):h):f}return(r.prefix||"")+n+(r.suffix||"")},E.toFraction=function(e){var t,n,o,i,u,c,l,h,d,g,v,m,y=this,b=y.c;if(null!=e&&(!(l=new V(e)).isInteger()&&(l.c||1!==l.s)||l.lt(N)))throw Error(a+"Argument "+(l.isInteger()?"out of range: ":"not an integer: ")+Z(l));if(!b)return new V(y);for(t=new V(N),d=n=new V(N),o=h=new V(N),m=p(b),u=t.e=m.length-y.e-1,t.c[0]=f[(c=u%s)<0?s+c:c],e=!e||l.comparedTo(t)>0?u>0?t:d:l,c=U,U=1/0,l=new V(m),h.c[0]=0;g=r(l,t,0,1),1!=(i=n.plus(g.times(o))).comparedTo(e);)n=o,o=i,d=h.plus(g.times(i=d)),h=i,t=l.minus(g.times(i=t)),l=i;return i=r(e.minus(n),o,0,1),h=h.plus(i.times(d)),n=n.plus(i.times(o)),h.s=d.s=y.s,v=r(d,o,u*=2,C).minus(y).abs().comparedTo(r(h,n,u,C).minus(y).abs())<1?[d,o]:[h,n],U=c,v},E.toNumber=function(){return+Z(this)},E.toPrecision=function(e,t){return null!=e&&m(e,1,d),$(this,e,t,2)},E.toString=function(e){var t,r=this,n=r.s,o=r.e;return null===o?n?(t="Infinity",n<0&&(t="-"+t)):t="NaN":(null==e?t=o<=D||o>=M?b(p(r.c),o):w(p(r.c),o,"0"):10===e?t=w(p((r=q(new V(r),k+o+1,C)).c),r.e,"0"):(m(e,2,L.length,"Base"),t=_(w(p(r.c),o,"0"),10,e,n,!0)),n<0&&r.c[0]&&(t="-"+t)),t},E.valueOf=E.toJSON=function(){return Z(this)},E._isBigNumber=!0,null!=t&&V.set(t),V}()).default=r.BigNumber=r,e.exports?e.exports=r:(t||(t="undefined"!=typeof self&&self?self:window),t.BigNumber=r)}(t)}),s=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.BurstSymbol="Ƀ",t.BurstPlanckSymbol="ƀ",t.FeeQuantPlanck=735e3,t.OneBurstPlanck=1e8});r(s);s.BurstSymbol,s.BurstPlanckSymbol,s.FeeQuantPlanck,s.OneBurstPlanck;var l=n(function(e,t){var r;function n(e){if(!e||!/^-?\d*(\.\d+)?$/.test(e))throw new Error(`Invalid value: ${e}`)}Object.defineProperty(t,"__esModule",{value:!0}),c.default.config({EXPONENTIAL_AT:[-9,20]}),function(e){e[e.PLANCK=0]="PLANCK",e[e.BURST=1]="BURST"}(r=t.BurstValueFormat||(t.BurstValueFormat={}));class o{constructor(e){"string"==typeof e&&n(e),this._planck=new c.default(e)}static Zero(){return new o("0")}static fromPlanck(e){return new o(e)}static fromBurst(e){const t=new o("0");return t.setBurst("number"==typeof e?e.toString(10):e),t}getRaw(){return this._planck}getPlanck(){return this._planck.toString()}setPlanck(e){n(e),this._planck=new c.default(e)}getBurst(){return this._planck.dividedBy(1e8).toString()}setBurst(e){n(e),this._planck=new c.default(e).multipliedBy(1e8)}equals(e){return this._planck.eq(e._planck)}lessOrEqual(e){return this._planck.lte(e._planck)}less(e){return this._planck.lt(e._planck)}greaterOrEqual(e){return this._planck.gte(e._planck)}greater(e){return this._planck.gt(e._planck)}add(e){return this._planck=this._planck.plus(e._planck),this}subtract(e){return this._planck=this._planck.minus(e._planck),this}multiply(e){return this._planck=this._planck.multipliedBy(e),this}divide(e){if(0===e)throw new Error("Division by zero");return this._planck=this._planck.div(e),this}toString(e=r.BURST){return e===r.BURST?`${s.BurstSymbol} ${this.getBurst()}`:`${s.BurstPlanckSymbol} ${this._planck}`}clone(){return o.fromPlanck(this.getPlanck())}}t.BurstValue=o});r(l);l.BurstValueFormat,l.BurstValue;var f=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.isValid=(e=>{0===e.indexOf(`${a.AddressPrefix}-`)&&(e=e.substr(6));const t=a.initialCodeword.slice();let r=0;for(let n=0;n<e.length;n++){const o=a.alphabet.indexOf(e.charAt(n));if(!(o<=-1||o>a.alphabet.length)){if(r>16)return!1;t[a.cwmap[r]]=o,r++}}if(17!==r)return!1;let n=0;for(let e=1;e<5;e++){let r=0;for(let n=0;n<31;n++){if(n>12&&n<27)continue;let o=n;n>26&&(o-=14),r^=a.gmult(t[o],a.gexp[e*n%31])}n|=r}return 0===n}),t.isBurstAddress=(e=>{if(!new RegExp(`${a.AddressPrefix}-[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{5}(-w+)?`,"i").test(e))return!1;const r=e.lastIndexOf("-"),n=e.substr(r+1);return e=n.length>5?e.substr(0,r):e,t.isValid(e)})});r(f);f.isValid,f.isBurstAddress;var h=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertAddressToNumericId=(e=>{if(null==e||0===e.trim().length)return;if(0!==e.indexOf(`${a.AddressPrefix}-`))return;e=e.substr(6);const t=a.initialCodeword.slice();let r=0;for(let n=0;n<e.length;n++){const o=a.alphabet.indexOf(e.charAt(n));if(!(o<=-1||o>a.alphabet.length)){if(r>16)return;t[a.cwmap[r]]=o,r++}}if(!f.isValid(e))return;let n=a.base32Length;const o=[];for(let e=0;e<n;e++)o[e]=t[n-e-1];let i,u="",c=0;do{i=0,c=0;for(let e=0;e<n;e++)(c=32*c+o[e])>=10?(o[i]=Math.floor(c/10),c%=10,i+=1):i>0&&(o[i]=0,i+=1);n=i,u+=c}while(n>0);return u.split("").reverse().join("")})});r(h);h.convertAddressToNumericId;var d=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBase36StringToHexString=(e=>new c.default(e,36).toString(16))});r(d);d.convertBase36StringToHexString;const g="function"==typeof atob,p="function"==typeof btoa,v="function"==typeof Buffer,m="function"==typeof TextDecoder?new TextDecoder:void 0,y="function"==typeof TextEncoder?new TextEncoder:void 0,b=[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],w=(e=>{let t={};return b.forEach((e,r)=>t[e]=r),t})(),_=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,S=String.fromCharCode.bind(String),A="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):(e,t=(e=>e))=>new Uint8Array(Array.prototype.slice.call(e,0).map(t)),T=e=>e.replace(/[+\/]/g,e=>"+"==e?"-":"_").replace(/=+$/m,""),B=e=>e.replace(/[^A-Za-z0-9\+\/]/g,""),x=e=>{let t,r,n,o,i="";const a=e.length%3;for(let a=0;a<e.length;){if((r=e.charCodeAt(a++))>255||(n=e.charCodeAt(a++))>255||(o=e.charCodeAt(a++))>255)throw new TypeError("invalid character found");i+=b[(t=r<<16|n<<8|o)>>18&63]+b[t>>12&63]+b[t>>6&63]+b[63&t]}return a?i.slice(0,a-3)+"===".substring(a):i},O=p?e=>btoa(e):v?e=>Buffer.from(e,"binary").toString("base64"):x,P=v?e=>Buffer.from(e).toString("base64"):e=>{let t=[];for(let r=0,n=e.length;r<n;r+=4096)t.push(S.apply(null,e.subarray(r,r+4096)));return O(t.join(""))},E=(e,t=!1)=>t?T(P(e)):P(e),N=e=>{if(e.length<2)return(t=e.charCodeAt(0))<128?e:t<2048?S(192|t>>>6)+S(128|63&t):S(224|t>>>12&15)+S(128|t>>>6&63)+S(128|63&t);var t=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);return S(240|t>>>18&7)+S(128|t>>>12&63)+S(128|t>>>6&63)+S(128|63&t)},k=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,C=e=>e.replace(k,N),D=v?e=>Buffer.from(e,"utf8").toString("base64"):y?e=>P(y.encode(e)):e=>O(C(e)),M=(e,t=!1)=>t?T(D(e)):D(e),j=e=>M(e,!0),U=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,F=e=>{switch(e.length){case 4:var t=((7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3))-65536;return S(55296+(t>>>10))+S(56320+(1023&t));case 3:return S((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return S((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},I=e=>e.replace(U,F),R=e=>{if(e=e.replace(/\s+/g,""),!_.test(e))throw new TypeError("malformed base64.");e+="==".slice(2-(3&e.length));let t,r,n,o="";for(let i=0;i<e.length;)t=w[e.charAt(i++)]<<18|w[e.charAt(i++)]<<12|(r=w[e.charAt(i++)])<<6|(n=w[e.charAt(i++)]),o+=64===r?S(t>>16&255):64===n?S(t>>16&255,t>>8&255):S(t>>16&255,t>>8&255,255&t);return o},H=g?e=>atob(B(e)):v?e=>Buffer.from(e,"base64").toString("binary"):R,L=v?e=>A(Buffer.from(e,"base64")):e=>A(H(e),e=>e.charCodeAt(0)),V=e=>L(G(e)),$=v?e=>Buffer.from(e,"base64").toString("utf8"):m?e=>m.decode(L(e)):e=>I(H(e)),G=e=>B(e.replace(/[-_]/g,e=>"-"==e?"+":"/")),z=e=>$(G(e)),q=e=>{if("string"!=typeof e)return!1;const t=e.replace(/\s+/g,"").replace(/=+$/,"");return!/[^\s0-9a-zA-Z\+/]/.test(t)||!/[^\s0-9a-zA-Z\-_]/.test(t)},Z=e=>({value:e,enumerable:!1,writable:!0,configurable:!0}),Q=function(){const e=(e,t)=>Object.defineProperty(String.prototype,e,Z(t));e("fromBase64",function(){return z(this)}),e("toBase64",function(e){return M(this,e)}),e("toBase64URI",function(){return M(this,!0)}),e("toBase64URL",function(){return M(this,!0)}),e("toUint8Array",function(){return V(this)})},W=function(){const e=(e,t)=>Object.defineProperty(Uint8Array.prototype,e,Z(t));e("toBase64",function(e){return E(this,e)}),e("toBase64URI",function(){return E(this,!0)}),e("toBase64URL",function(){return E(this,!0)})},X=()=>{Q(),W()},J={version:"3.6.0",VERSION:"3.6.0",atob:H,atobPolyfill:R,btoa:O,btoaPolyfill:x,fromBase64:z,toBase64:M,encode:M,encodeURI:j,encodeURL:j,utob:C,btou:I,decode:z,isValid:q,fromUint8Array:E,toUint8Array:V,extendString:Q,extendUint8Array:W,extendBuiltins:X};var K=o(Object.freeze({__proto__:null,version:"3.6.0",VERSION:"3.6.0",atob:H,atobPolyfill:R,btoa:O,btoaPolyfill:x,fromBase64:z,toBase64:M,utob:C,encode:M,encodeURI:j,encodeURL:j,btou:I,decode:z,isValid:q,fromUint8Array:E,toUint8Array:V,extendString:Q,extendUint8Array:W,extendBuiltins:X,Base64:J})),Y=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBase64StringToString=(e=>K.Base64.decode(e))});r(Y);Y.convertBase64StringToString;var ee=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBurstTimeToEpochTime=(e=>1e3*(a.GenesisBlockTime+e))});r(ee);ee.convertBurstTimeToEpochTime;var te=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBurstTimeToDate=(e=>new Date(ee.convertBurstTimeToEpochTime(e)))});r(te);te.convertBurstTimeToDate;var re=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertByteArrayToHexString=((e,t=!1)=>{const r=[];for(let t=0;t<e.length;t++)r.push((e[t]>>>4).toString(16)),r.push((15&e[t]).toString(16));return t?r.join("").toUpperCase():r.join("")})});r(re);re.convertByteArrayToHexString;var ne=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertByteArrayToString=((e,t=0,r=null)=>{if(0===r)return"";let n=e;if(0!==t){const o=null===r?e.length-t:r;!function(e,t,r=0){if(r<0)throw new Error("Start index should not be negative");if(e.length<r+t)throw new Error("Need at least "+t+" bytes to convert to an integer")}(n,o,t),n=e.slice(t,t+o)}return decodeURIComponent(escape(String.fromCharCode.apply(null,Array.from(n))))})});r(ne);ne.convertByteArrayToString;var oe=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertDateToBurstTime=(e=>Math.round(e.getTime()/1e3)-a.GenesisBlockTime)});r(oe);oe.convertDateToBurstTime;String.prototype.padStart||(String.prototype.padStart=function(e,t){return e>>=0,t=String(void 0!==t?t:" "),this.length>=e?String(this):((e-=this.length)>t.length&&(t+=t.repeat(e/t.length)),t.slice(0,e)+String(this))});var ie=Object.freeze({__proto__:null}),ae=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.twosComplementBinary=(e=>{let t=e.multipliedBy(-1).toString(2);for(;t.length%8;)t="0"+t;const r="1"===t[0]&&-1!==t.slice(1).indexOf("1")?"11111111":"";return t=t.split("").map(e=>"0"===e?"1":"0").join(""),new c.default(r+t,2).plus(1)})});r(ae);ae.twosComplementBinary;o(ie);var ue=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertDecStringToHexString=((e,t=2)=>{let r="string"==typeof e?new c.default(e):e;if(r.isNaN())throw new Error(`Invalid decimal argument: [${e}] - Expected a valid decimal value`);if(t<0)throw new Error(`Invalid padding argument: [${t}] - Expected a positive value`);const n=r.lt(0);n&&(r=ae.twosComplementBinary(r));const o=r.toString(16),i=Math.ceil(o.length/t);return o.padStart(i*t,n?"f":"0")})});r(ue);ue.convertDecStringToHexString;var ce=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexEndianess=(e=>{let t="";const r=e;for(let e=r.length-1;e>=0;e-=2)t+=r[e-1]+r[e];return t})});r(ce);ce.convertHexEndianess;var se=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToBase36String=(e=>new c.default(e,16).toString(36))});r(se);se.convertHexStringToBase36String;var le=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToByteArray=(e=>{if(e.length%2)throw new Error(`Invalid Hex String: ${e}`);const t=new Uint8Array(e.length/2);for(let r=0;r<e.length;r+=2){const n=parseInt(e.substr(r,2),16);if(Number.isNaN(n))throw new Error(`Invalid Hex String: ${e}`);t[r/2]=n}return t})});r(le);le.convertHexStringToByteArray;var fe=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToDecString=(e=>{const t=[0];let r,n,o;for(r=0;r<e.length;r+=1){for(o=parseInt(e.charAt(r),16),n=0;n<t.length;n+=1)t[n]=16*t[n]+o,o=t[n]/10|0,t[n]%=10;for(;o>0;)t.push(o%10),o=o/10|0}return t.reverse().join("")})});r(fe);fe.convertHexStringToDecString;var he=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToString=(e=>ne.convertByteArrayToString(le.convertHexStringToByteArray(e)))});r(he);he.convertHexStringToString;var de=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertNQTStringToNumber=(e=>{if(null==e||""===e)throw new Error("Invalid argument");return parseFloat(e)/1e8})});r(de);de.convertNQTStringToNumber;var ge=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertNumberToNQTString=(e=>{if(null==e)throw new Error("Invalid argument");return parseFloat(e.toString()).toFixed(8).replace(".","")})});r(ge);ge.convertNumberToNQTString;var pe=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertNumericIdToAddress=(e=>{if(null==e||0===e.trim().length)return;const t=[],r=a.initialCodeword.slice();let n=0,o=e.length;for(let r=0;r<o;r++)t[r]=e.charCodeAt(r)-"0".charCodeAt(0);let i=0,u=0;do{i=0,u=0;for(let e=0;e<o;e++)(i=10*i+t[e])>=32?(t[u]=i>>5,i&=31,u++):u>0&&(t[u]=0,u++);o=u,r[n]=i,n++}while(o>0);const c=[0,0,0,0];for(let e=a.base32Length-1;e>=0;e--){const t=r[e]^c[3];c[3]=c[2]^a.gmult(30,t),c[2]=c[1]^a.gmult(6,t),c[1]=c[0]^a.gmult(9,t),c[0]=a.gmult(17,t)}r[13]=c[0],r[14]=c[1],r[15]=c[2],r[16]=c[3];let s=a.AddressPrefix+"-";for(let e=0;e<17;e++)s+=a.alphabet[r[a.cwmap[e]]],3==(3&e)&&e<13&&(s+="-");return s})});r(pe);pe.convertNumericIdToAddress;var ve=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStringToBase64String=((e,t=!0)=>t?K.Base64.encodeURI(e):K.Base64.encode(e))});r(ve);ve.convertStringToBase64String;var me=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStringToByteArray=(e=>{const t=unescape(encodeURIComponent(e)),r=new Uint8Array(t.length);for(let e=0;e<t.length;++e)r[e]=t.charCodeAt(e);return r})});r(me);me.convertStringToByteArray;var ye=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStringToHexString=(e=>re.convertByteArrayToHexString(me.convertStringToByteArray(e)))});r(ye);ye.convertStringToHexString;var be=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Text=0]="Text",e[e.Hexadecimal=1]="Hexadecimal",e[e.Base64=2]="Base64"}(t.EncoderFormat||(t.EncoderFormat={}))});r(be);be.EncoderFormat;var we=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.createDeeplink=(e=>{const{encoderFormat:t=be.EncoderFormat.Base64,domain:r,action:n,payload:o}=e;let i=`burst.${r}://v1`;return n&&(i+=`?action=${n}`),o&&(i+=`&payload=${function(e,t){let r=e;switch("string"!=typeof e&&(r=JSON.stringify(e)),t){case be.EncoderFormat.Hexadecimal:return ye.convertStringToHexString(r);case be.EncoderFormat.Base64:return ve.convertStringToBase64String(r);case be.EncoderFormat.Text:default:return r}}(o,t)}`),i})});r(we);we.createDeeplink;var _e=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=/^burst.(.+):\/\/(v.+?)\??/i;t.parseDeeplink=(e=>{const t=()=>{throw new Error("Invalid deeplink: "+e)},n=(e,r)=>(e.startsWith(r+"=")||t(),e.split("=")[1]),o=e.match(r);o&&3===o.length||t();const i={domain:o[1],version:o[2],action:void 0,payload:void 0,decodedPayload:void 0};try{const r=e.indexOf("?");if(-1!==r){const o=e.substring(r+1).split("&");o.length>=1&&(o.length>2&&t(),i.action=n(o[0],"action"),2===o.length&&(i.payload=n(o[1],"payload")))}}catch(e){t()}return i})});r(_e);_e.parseDeeplink;var Se=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.sumNQTStringToNumber=function(...e){return e.reduce((e,t)=>e+de.convertNQTStringToNumber(t),0)}});r(Se);Se.sumNQTStringToNumber;var Ae=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(be)});r(Ae);var Te=n(function(e,t){function r(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),r(i),r(u),r(l),r(s),r(h),r(d),r(Y),r(te),r(ee),r(re),r(ne),r(oe),r(ue),r(ce),r(se),r(le),r(fe),r(he),r(de),r(ge),r(pe),r(ve),r(me),r(ye),r(we),r(f),r(_e),r(Se),r(Ae)});r(Te);var Be=Te.BurstValue,xe=Te.FeeQuantPlanck,Oe=Te.OneBurstPlanck,Pe=Te.convertHexStringToDecString,Ee=Te.convertDecStringToHexString,Ne=Te.convertHexStringToString,ke=Te.convertHexEndianess;Te.convertHexStringToByteArray,Te.convertByteArrayToHexString;function Ce(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:16,n=16*t,o=n+r;if(o>e.machineData.length)throw new Error("Insufficient length for variable at position: ".concat(n," (and given length: ").concat(r,")"));if(o%2!=0)throw new Error("Invalid position: ".concat(n," (or given length: ").concat(r,") - must be at least multiple of 2"));return ke(e.machineData.substr(n,r))}function De(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function Me(e){return function(e){if(Array.isArray(e)){for(var t=0,r=new Array(e.length);t<e.length;t++)r[t]=e[t];return r}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var je=256;function Ue(e){return Math.ceil(e.length/2/je)}var Fe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._contract=t}var t,r,n;return t=e,(r=[{key:"getContract",value:function(){return this._contract}},{key:"countCodePages",value:function(){return Ue(this._contract.machineCode)}},{key:"getVariableAsString",value:function(t){var r=this.getHexDataAt(t,e.VariableLength);return Ne(r.replace(/00/g,""))}},{key:"getDataBlocksAsString",value:function(t,r){var n=this.getHexDataAt(t,r*e.VariableLength);return Ne(n.replace(/00/g,""))}},{key:"getVariableAsDecimal",value:function(e){return Pe(this.getVariable(e))}},{key:"getVariable",value:function(t){return this.getHexDataAt(t,e.VariableLength)}},{key:"getHexDataAt",value:function(t,r){var n=r||this._contract.machineData.length-e.VariableLength*t;return Ce(this._contract,t,n)}}])&&De(t.prototype,r),n&&De(t,n),e}();Fe.VariableLength=16;var Ie=function(e){return"boolean"==typeof e?e?"1":"0":"number"==typeof e?"".concat(e):e};return e.CodePageSize=je,e.ContractDataView=Fe,e.calculateMinimumCreationFee=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return Be.fromPlanck((t?10*xe:Oe).toString(10)).multiply(2+Ue(e)+1)},e.countCodePages=Ue,e.generateMethodCall=function(e){var t=e.methodArgs?[e.methodHash].concat(Me(e.methodArgs)):[e.methodHash];if(t.length>4)throw new Error("At maximum ".concat(3," are supported"));return t.map(Ie).map(function(e){return Ee(e,16)}).map(ke).join("")},e.getContractDatablock=Ce,e}({});
var b$contracts=function(e){"use strict";var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function n(e,t){return e(t={exports:{}},t.exports),t.exports}function o(e){return e&&e.default||e}var i=n(function(e,r){var n=t&&t.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(o,i){function a(e){try{u(n.next(e))}catch(e){i(e)}}function c(e){try{u(n.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r(function(e){e(t)})).then(a,c)}u((n=n.apply(e,t||[])).next())})};Object.defineProperty(r,"__esModule",{value:!0}),r.asyncRetry=function e(t){return n(this,void 0,void 0,function*(){const{asyncFn:r,onFailureAsync:n,retryCount:o=1,maxRetrials:i=20}=t;try{return yield r()}catch(t){if(o>i)throw t;if(!(yield n(t,o)))throw t;yield e({asyncFn:r,onFailureAsync:n,retryCount:o+1})}})}});r(i);i.asyncRetry;var a=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.AddressPrefix="BURST",t.GenesisBlockTime=Date.UTC(2014,7,11,2,0,0,0)/1e3,t.initialCodeword=[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],t.gexp=[1,2,4,8,16,5,10,20,13,26,17,7,14,28,29,31,27,19,3,6,12,24,21,15,30,25,23,11,22,9,18,1],t.glog=[0,0,1,18,2,5,19,11,3,29,6,27,20,8,12,23,4,10,30,17,7,22,28,26,21,25,9,16,13,14,24,15],t.cwmap=[3,2,1,0,7,6,5,4,13,14,15,16,12,8,9,10,11],t.alphabet="23456789ABCDEFGHJKLMNPQRSTUVWXYZ".split(""),t.base32Length=13,t.ginv=(e=>t.gexp[31-t.glog[e]]),t.gmult=((e,r)=>{if(0===e||0===r)return 0;const n=(t.glog[e]+t.glog[r])%31;return t.gexp[n]})});r(a);a.AddressPrefix,a.GenesisBlockTime,a.initialCodeword,a.gexp,a.glog,a.cwmap,a.alphabet,a.base32Length,a.ginv,a.gmult;var c=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});class r{constructor(e){this._burstTimestamp=e}static fromBurstTimestamp(e){return new r(e)}static fromDate(e){const t=new r(0);return t.setDate(e),t}getBurstTimestamp(){return this._burstTimestamp}setBurstTimestamp(e){this._burstTimestamp=e}getEpoch(){return 1e3*(a.GenesisBlockTime+this._burstTimestamp)}getDate(){return new Date(this.getEpoch())}setDate(e){this._burstTimestamp=Math.round(e.getTime()/1e3)-a.GenesisBlockTime}equals(e){return this._burstTimestamp===e._burstTimestamp}before(e){return this._burstTimestamp<e._burstTimestamp}after(e){return this._burstTimestamp>e._burstTimestamp}}t.BurstTime=r});r(c);c.BurstTime;var u=n(function(e){!function(t){var r,n=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,o=Math.ceil,i=Math.floor,a="[BigNumber Error] ",c=a+"Number primitive has more than 15 significant digits: ",u=1e14,s=14,l=9007199254740991,f=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],h=1e7,d=1e9;function g(e){var t=0|e;return e>0||e===t?t:t-1}function p(e){for(var t,r,n=1,o=e.length,i=e[0]+"";n<o;){for(t=e[n++]+"",r=s-t.length;r--;t="0"+t);i+=t}for(o=i.length;48===i.charCodeAt(--o););return i.slice(0,o+1||1)}function v(e,t){var r,n,o=e.c,i=t.c,a=e.s,c=t.s,u=e.e,s=t.e;if(!a||!c)return null;if(r=o&&!o[0],n=i&&!i[0],r||n)return r?n?0:-c:a;if(a!=c)return a;if(r=a<0,n=u==s,!o||!i)return n?0:!o^r?1:-1;if(!n)return u>s^r?1:-1;for(c=(u=o.length)<(s=i.length)?u:s,a=0;a<c;a++)if(o[a]!=i[a])return o[a]>i[a]^r?1:-1;return u==s?0:u>s^r?1:-1}function m(e,t,r,n){if(e<t||e>r||e!==i(e))throw Error(a+(n||"Argument")+("number"==typeof e?e<t||e>r?" out of range: ":" not an integer: ":" not a primitive number: ")+String(e))}function y(e){var t=e.c.length-1;return g(e.e/s)==t&&e.c[t]%2!=0}function b(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(t<0?"e":"e+")+t}function w(e,t,r){var n,o;if(t<0){for(o=r+".";++t;o+=r);e=o+e}else if(++t>(n=e.length)){for(o=r,t-=n;--t;o+=r);e+=o}else t<n&&(e=e.slice(0,t)+"."+e.slice(t));return e}(r=function e(t){var r,_,S,A,T,B,x,O,E,P=V.prototype={constructor:V,toString:null,valueOf:null},N=new V(1),k=20,C=4,D=-7,M=21,j=-1e7,U=1e7,F=!1,I=1,R=0,H={prefix:"",groupSize:3,secondaryGroupSize:0,groupSeparator:",",decimalSeparator:".",fractionGroupSize:0,fractionGroupSeparator:" ",suffix:""},L="0123456789abcdefghijklmnopqrstuvwxyz";function V(e,t){var r,o,a,u,f,h,d,g,p=this;if(!(p instanceof V))return new V(e,t);if(null==t){if(e&&!0===e._isBigNumber)return p.s=e.s,void(!e.c||e.e>U?p.c=p.e=null:e.e<j?p.c=[p.e=0]:(p.e=e.e,p.c=e.c.slice()));if((h="number"==typeof e)&&0*e==0){if(p.s=1/e<0?(e=-e,-1):1,e===~~e){for(u=0,f=e;f>=10;f/=10,u++);return void(u>U?p.c=p.e=null:(p.e=u,p.c=[e]))}g=String(e)}else{if(!n.test(g=String(e)))return S(p,g,h);p.s=45==g.charCodeAt(0)?(g=g.slice(1),-1):1}(u=g.indexOf("."))>-1&&(g=g.replace(".","")),(f=g.search(/e/i))>0?(u<0&&(u=f),u+=+g.slice(f+1),g=g.substring(0,f)):u<0&&(u=g.length)}else{if(m(t,2,L.length,"Base"),10==t)return q(p=new V(e),k+p.e+1,C);if(g=String(e),h="number"==typeof e){if(0*e!=0)return S(p,g,h,t);if(p.s=1/e<0?(g=g.slice(1),-1):1,V.DEBUG&&g.replace(/^0\.0*|\./,"").length>15)throw Error(c+e)}else p.s=45===g.charCodeAt(0)?(g=g.slice(1),-1):1;for(r=L.slice(0,t),u=f=0,d=g.length;f<d;f++)if(r.indexOf(o=g.charAt(f))<0){if("."==o){if(f>u){u=d;continue}}else if(!a&&(g==g.toUpperCase()&&(g=g.toLowerCase())||g==g.toLowerCase()&&(g=g.toUpperCase()))){a=!0,f=-1,u=0;continue}return S(p,String(e),h,t)}h=!1,(u=(g=_(g,t,10,p.s)).indexOf("."))>-1?g=g.replace(".",""):u=g.length}for(f=0;48===g.charCodeAt(f);f++);for(d=g.length;48===g.charCodeAt(--d););if(g=g.slice(f,++d)){if(d-=f,h&&V.DEBUG&&d>15&&(e>l||e!==i(e)))throw Error(c+p.s*e);if((u=u-f-1)>U)p.c=p.e=null;else if(u<j)p.c=[p.e=0];else{if(p.e=u,p.c=[],f=(u+1)%s,u<0&&(f+=s),f<d){for(f&&p.c.push(+g.slice(0,f)),d-=s;f<d;)p.c.push(+g.slice(f,f+=s));f=s-(g=g.slice(f)).length}else f-=d;for(;f--;g+="0");p.c.push(+g)}}else p.c=[p.e=0]}function $(e,t,r,n){var o,i,a,c,u;if(null==r?r=C:m(r,0,8),!e.c)return e.toString();if(o=e.c[0],a=e.e,null==t)u=p(e.c),u=1==n||2==n&&(a<=D||a>=M)?b(u,a):w(u,a,"0");else if(i=(e=q(new V(e),t,r)).e,c=(u=p(e.c)).length,1==n||2==n&&(t<=i||i<=D)){for(;c<t;u+="0",c++);u=b(u,i)}else if(t-=a,u=w(u,i,"0"),i+1>c){if(--t>0)for(u+=".";t--;u+="0");}else if((t+=i-c)>0)for(i+1==c&&(u+=".");t--;u+="0");return e.s<0&&o?"-"+u:u}function G(e,t){for(var r,n=1,o=new V(e[0]);n<e.length;n++){if(!(r=new V(e[n])).s){o=r;break}t.call(o,r)&&(o=r)}return o}function z(e,t,r){for(var n=1,o=t.length;!t[--o];t.pop());for(o=t[0];o>=10;o/=10,n++);return(r=n+r*s-1)>U?e.c=e.e=null:r<j?e.c=[e.e=0]:(e.e=r,e.c=t),e}function q(e,t,r,n){var a,c,l,h,d,g,p,v=e.c,m=f;if(v){e:{for(a=1,h=v[0];h>=10;h/=10,a++);if((c=t-a)<0)c+=s,l=t,p=(d=v[g=0])/m[a-l-1]%10|0;else if((g=o((c+1)/s))>=v.length){if(!n)break e;for(;v.length<=g;v.push(0));d=p=0,a=1,l=(c%=s)-s+1}else{for(d=h=v[g],a=1;h>=10;h/=10,a++);p=(l=(c%=s)-s+a)<0?0:d/m[a-l-1]%10|0}if(n=n||t<0||null!=v[g+1]||(l<0?d:d%m[a-l-1]),n=r<4?(p||n)&&(0==r||r==(e.s<0?3:2)):p>5||5==p&&(4==r||n||6==r&&(c>0?l>0?d/m[a-l]:0:v[g-1])%10&1||r==(e.s<0?8:7)),t<1||!v[0])return v.length=0,n?(t-=e.e+1,v[0]=m[(s-t%s)%s],e.e=-t||0):v[0]=e.e=0,e;if(0==c?(v.length=g,h=1,g--):(v.length=g+1,h=m[s-c],v[g]=l>0?i(d/m[a-l]%m[l])*h:0),n)for(;;){if(0==g){for(c=1,l=v[0];l>=10;l/=10,c++);for(l=v[0]+=h,h=1;l>=10;l/=10,h++);c!=h&&(e.e++,v[0]==u&&(v[0]=1));break}if(v[g]+=h,v[g]!=u)break;v[g--]=0,h=1}for(c=v.length;0===v[--c];v.pop());}e.e>U?e.c=e.e=null:e.e<j&&(e.c=[e.e=0])}return e}function Z(e){var t,r=e.e;return null===r?e.toString():(t=p(e.c),t=r<=D||r>=M?b(t,r):w(t,r,"0"),e.s<0?"-"+t:t)}return V.clone=e,V.ROUND_UP=0,V.ROUND_DOWN=1,V.ROUND_CEIL=2,V.ROUND_FLOOR=3,V.ROUND_HALF_UP=4,V.ROUND_HALF_DOWN=5,V.ROUND_HALF_EVEN=6,V.ROUND_HALF_CEIL=7,V.ROUND_HALF_FLOOR=8,V.EUCLID=9,V.config=V.set=function(e){var t,r;if(null!=e){if("object"!=typeof e)throw Error(a+"Object expected: "+e);if(e.hasOwnProperty(t="DECIMAL_PLACES")&&(m(r=e[t],0,d,t),k=r),e.hasOwnProperty(t="ROUNDING_MODE")&&(m(r=e[t],0,8,t),C=r),e.hasOwnProperty(t="EXPONENTIAL_AT")&&((r=e[t])&&r.pop?(m(r[0],-d,0,t),m(r[1],0,d,t),D=r[0],M=r[1]):(m(r,-d,d,t),D=-(M=r<0?-r:r))),e.hasOwnProperty(t="RANGE"))if((r=e[t])&&r.pop)m(r[0],-d,-1,t),m(r[1],1,d,t),j=r[0],U=r[1];else{if(m(r,-d,d,t),!r)throw Error(a+t+" cannot be zero: "+r);j=-(U=r<0?-r:r)}if(e.hasOwnProperty(t="CRYPTO")){if((r=e[t])!==!!r)throw Error(a+t+" not true or false: "+r);if(r){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw F=!r,Error(a+"crypto unavailable");F=r}else F=r}if(e.hasOwnProperty(t="MODULO_MODE")&&(m(r=e[t],0,9,t),I=r),e.hasOwnProperty(t="POW_PRECISION")&&(m(r=e[t],0,d,t),R=r),e.hasOwnProperty(t="FORMAT")){if("object"!=typeof(r=e[t]))throw Error(a+t+" not an object: "+r);H=r}if(e.hasOwnProperty(t="ALPHABET")){if("string"!=typeof(r=e[t])||/^.$|[+-.\s]|(.).*\1/.test(r))throw Error(a+t+" invalid: "+r);L=r}}return{DECIMAL_PLACES:k,ROUNDING_MODE:C,EXPONENTIAL_AT:[D,M],RANGE:[j,U],CRYPTO:F,MODULO_MODE:I,POW_PRECISION:R,FORMAT:H,ALPHABET:L}},V.isBigNumber=function(e){if(!e||!0!==e._isBigNumber)return!1;if(!V.DEBUG)return!0;var t,r,n=e.c,o=e.e,c=e.s;e:if("[object Array]"=={}.toString.call(n)){if((1===c||-1===c)&&o>=-d&&o<=d&&o===i(o)){if(0===n[0]){if(0===o&&1===n.length)return!0;break e}if((t=(o+1)%s)<1&&(t+=s),String(n[0]).length==t){for(t=0;t<n.length;t++)if((r=n[t])<0||r>=u||r!==i(r))break e;if(0!==r)return!0}}}else if(null===n&&null===o&&(null===c||1===c||-1===c))return!0;throw Error(a+"Invalid BigNumber: "+e)},V.maximum=V.max=function(){return G(arguments,P.lt)},V.minimum=V.min=function(){return G(arguments,P.gt)},V.random=(A=9007199254740992*Math.random()&2097151?function(){return i(9007199254740992*Math.random())}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)},function(e){var t,r,n,c,u,l=0,h=[],g=new V(N);if(null==e?e=k:m(e,0,d),c=o(e/s),F)if(crypto.getRandomValues){for(t=crypto.getRandomValues(new Uint32Array(c*=2));l<c;)(u=131072*t[l]+(t[l+1]>>>11))>=9e15?(r=crypto.getRandomValues(new Uint32Array(2)),t[l]=r[0],t[l+1]=r[1]):(h.push(u%1e14),l+=2);l=c/2}else{if(!crypto.randomBytes)throw F=!1,Error(a+"crypto unavailable");for(t=crypto.randomBytes(c*=7);l<c;)(u=281474976710656*(31&t[l])+1099511627776*t[l+1]+4294967296*t[l+2]+16777216*t[l+3]+(t[l+4]<<16)+(t[l+5]<<8)+t[l+6])>=9e15?crypto.randomBytes(7).copy(t,l):(h.push(u%1e14),l+=7);l=c/7}if(!F)for(;l<c;)(u=A())<9e15&&(h[l++]=u%1e14);for(c=h[--l],e%=s,c&&e&&(u=f[s-e],h[l]=i(c/u)*u);0===h[l];h.pop(),l--);if(l<0)h=[n=0];else{for(n=-1;0===h[0];h.splice(0,1),n-=s);for(l=1,u=h[0];u>=10;u/=10,l++);l<s&&(n-=s-l)}return g.e=n,g.c=h,g}),V.sum=function(){for(var e=1,t=arguments,r=new V(t[0]);e<t.length;)r=r.plus(t[e++]);return r},_=function(){function e(e,t,r,n){for(var o,i,a=[0],c=0,u=e.length;c<u;){for(i=a.length;i--;a[i]*=t);for(a[0]+=n.indexOf(e.charAt(c++)),o=0;o<a.length;o++)a[o]>r-1&&(null==a[o+1]&&(a[o+1]=0),a[o+1]+=a[o]/r|0,a[o]%=r)}return a.reverse()}return function(t,n,o,i,a){var c,u,s,l,f,h,d,g,v=t.indexOf("."),m=k,y=C;for(v>=0&&(l=R,R=0,t=t.replace(".",""),h=(g=new V(n)).pow(t.length-v),R=l,g.c=e(w(p(h.c),h.e,"0"),10,o,"0123456789"),g.e=g.c.length),s=l=(d=e(t,n,o,a?(c=L,"0123456789"):(c="0123456789",L))).length;0==d[--l];d.pop());if(!d[0])return c.charAt(0);if(v<0?--s:(h.c=d,h.e=s,h.s=i,d=(h=r(h,g,m,y,o)).c,f=h.r,s=h.e),v=d[u=s+m+1],l=o/2,f=f||u<0||null!=d[u+1],f=y<4?(null!=v||f)&&(0==y||y==(h.s<0?3:2)):v>l||v==l&&(4==y||f||6==y&&1&d[u-1]||y==(h.s<0?8:7)),u<1||!d[0])t=f?w(c.charAt(1),-m,c.charAt(0)):c.charAt(0);else{if(d.length=u,f)for(--o;++d[--u]>o;)d[u]=0,u||(++s,d=[1].concat(d));for(l=d.length;!d[--l];);for(v=0,t="";v<=l;t+=c.charAt(d[v++]));t=w(t,s,c.charAt(0))}return t}}(),r=function(){function e(e,t,r){var n,o,i,a,c=0,u=e.length,s=t%h,l=t/h|0;for(e=e.slice();u--;)c=((o=s*(i=e[u]%h)+(n=l*i+(a=e[u]/h|0)*s)%h*h+c)/r|0)+(n/h|0)+l*a,e[u]=o%r;return c&&(e=[c].concat(e)),e}function t(e,t,r,n){var o,i;if(r!=n)i=r>n?1:-1;else for(o=i=0;o<r;o++)if(e[o]!=t[o]){i=e[o]>t[o]?1:-1;break}return i}function r(e,t,r,n){for(var o=0;r--;)e[r]-=o,o=e[r]<t[r]?1:0,e[r]=o*n+e[r]-t[r];for(;!e[0]&&e.length>1;e.splice(0,1));}return function(n,o,a,c,l){var f,h,d,p,v,m,y,b,w,_,S,A,T,B,x,O,E,P=n.s==o.s?1:-1,N=n.c,k=o.c;if(!(N&&N[0]&&k&&k[0]))return new V(n.s&&o.s&&(N?!k||N[0]!=k[0]:k)?N&&0==N[0]||!k?0*P:P/0:NaN);for(w=(b=new V(P)).c=[],P=a+(h=n.e-o.e)+1,l||(l=u,h=g(n.e/s)-g(o.e/s),P=P/s|0),d=0;k[d]==(N[d]||0);d++);if(k[d]>(N[d]||0)&&h--,P<0)w.push(1),p=!0;else{for(B=N.length,O=k.length,d=0,P+=2,(v=i(l/(k[0]+1)))>1&&(k=e(k,v,l),N=e(N,v,l),O=k.length,B=N.length),T=O,S=(_=N.slice(0,O)).length;S<O;_[S++]=0);E=k.slice(),E=[0].concat(E),x=k[0],k[1]>=l/2&&x++;do{if(v=0,(f=t(k,_,O,S))<0){if(A=_[0],O!=S&&(A=A*l+(_[1]||0)),(v=i(A/x))>1)for(v>=l&&(v=l-1),y=(m=e(k,v,l)).length,S=_.length;1==t(m,_,y,S);)v--,r(m,O<y?E:k,y,l),y=m.length,f=1;else 0==v&&(f=v=1),y=(m=k.slice()).length;if(y<S&&(m=[0].concat(m)),r(_,m,S,l),S=_.length,-1==f)for(;t(k,_,O,S)<1;)v++,r(_,O<S?E:k,S,l),S=_.length}else 0===f&&(v++,_=[0]);w[d++]=v,_[0]?_[S++]=N[T]||0:(_=[N[T]],S=1)}while((T++<B||null!=_[0])&&P--);p=null!=_[0],w[0]||w.splice(0,1)}if(l==u){for(d=1,P=w[0];P>=10;P/=10,d++);q(b,a+(b.e=d+h*s-1)+1,c,p)}else b.e=h,b.r=+p;return b}}(),T=/^(-?)0([xbo])(?=\w[\w.]*$)/i,B=/^([^.]+)\.$/,x=/^\.([^.]+)$/,O=/^-?(Infinity|NaN)$/,E=/^\s*\+(?=[\w.])|^\s+|\s+$/g,S=function(e,t,r,n){var o,i=r?t:t.replace(E,"");if(O.test(i))e.s=isNaN(i)?null:i<0?-1:1;else{if(!r&&(i=i.replace(T,function(e,t,r){return o="x"==(r=r.toLowerCase())?16:"b"==r?2:8,n&&n!=o?e:t}),n&&(o=n,i=i.replace(B,"$1").replace(x,"0.$1")),t!=i))return new V(i,o);if(V.DEBUG)throw Error(a+"Not a"+(n?" base "+n:"")+" number: "+t);e.s=null}e.c=e.e=null},P.absoluteValue=P.abs=function(){var e=new V(this);return e.s<0&&(e.s=1),e},P.comparedTo=function(e,t){return v(this,new V(e,t))},P.decimalPlaces=P.dp=function(e,t){var r,n,o,i=this;if(null!=e)return m(e,0,d),null==t?t=C:m(t,0,8),q(new V(i),e+i.e+1,t);if(!(r=i.c))return null;if(n=((o=r.length-1)-g(this.e/s))*s,o=r[o])for(;o%10==0;o/=10,n--);return n<0&&(n=0),n},P.dividedBy=P.div=function(e,t){return r(this,new V(e,t),k,C)},P.dividedToIntegerBy=P.idiv=function(e,t){return r(this,new V(e,t),0,1)},P.exponentiatedBy=P.pow=function(e,t){var r,n,c,u,l,f,h,d,g=this;if((e=new V(e)).c&&!e.isInteger())throw Error(a+"Exponent not an integer: "+Z(e));if(null!=t&&(t=new V(t)),l=e.e>14,!g.c||!g.c[0]||1==g.c[0]&&!g.e&&1==g.c.length||!e.c||!e.c[0])return d=new V(Math.pow(+Z(g),l?2-y(e):+Z(e))),t?d.mod(t):d;if(f=e.s<0,t){if(t.c?!t.c[0]:!t.s)return new V(NaN);(n=!f&&g.isInteger()&&t.isInteger())&&(g=g.mod(t))}else{if(e.e>9&&(g.e>0||g.e<-1||(0==g.e?g.c[0]>1||l&&g.c[1]>=24e7:g.c[0]<8e13||l&&g.c[0]<=9999975e7)))return u=g.s<0&&y(e)?-0:0,g.e>-1&&(u=1/u),new V(f?1/u:u);R&&(u=o(R/s+2))}for(l?(r=new V(.5),f&&(e.s=1),h=y(e)):h=(c=Math.abs(+Z(e)))%2,d=new V(N);;){if(h){if(!(d=d.times(g)).c)break;u?d.c.length>u&&(d.c.length=u):n&&(d=d.mod(t))}if(c){if(0===(c=i(c/2)))break;h=c%2}else if(q(e=e.times(r),e.e+1,1),e.e>14)h=y(e);else{if(0==(c=+Z(e)))break;h=c%2}g=g.times(g),u?g.c&&g.c.length>u&&(g.c.length=u):n&&(g=g.mod(t))}return n?d:(f&&(d=N.div(d)),t?d.mod(t):u?q(d,R,C,void 0):d)},P.integerValue=function(e){var t=new V(this);return null==e?e=C:m(e,0,8),q(t,t.e+1,e)},P.isEqualTo=P.eq=function(e,t){return 0===v(this,new V(e,t))},P.isFinite=function(){return!!this.c},P.isGreaterThan=P.gt=function(e,t){return v(this,new V(e,t))>0},P.isGreaterThanOrEqualTo=P.gte=function(e,t){return 1===(t=v(this,new V(e,t)))||0===t},P.isInteger=function(){return!!this.c&&g(this.e/s)>this.c.length-2},P.isLessThan=P.lt=function(e,t){return v(this,new V(e,t))<0},P.isLessThanOrEqualTo=P.lte=function(e,t){return-1===(t=v(this,new V(e,t)))||0===t},P.isNaN=function(){return!this.s},P.isNegative=function(){return this.s<0},P.isPositive=function(){return this.s>0},P.isZero=function(){return!!this.c&&0==this.c[0]},P.minus=function(e,t){var r,n,o,i,a=this,c=a.s;if(t=(e=new V(e,t)).s,!c||!t)return new V(NaN);if(c!=t)return e.s=-t,a.plus(e);var l=a.e/s,f=e.e/s,h=a.c,d=e.c;if(!l||!f){if(!h||!d)return h?(e.s=-t,e):new V(d?a:NaN);if(!h[0]||!d[0])return d[0]?(e.s=-t,e):new V(h[0]?a:3==C?-0:0)}if(l=g(l),f=g(f),h=h.slice(),c=l-f){for((i=c<0)?(c=-c,o=h):(f=l,o=d),o.reverse(),t=c;t--;o.push(0));o.reverse()}else for(n=(i=(c=h.length)<(t=d.length))?c:t,c=t=0;t<n;t++)if(h[t]!=d[t]){i=h[t]<d[t];break}if(i&&(o=h,h=d,d=o,e.s=-e.s),(t=(n=d.length)-(r=h.length))>0)for(;t--;h[r++]=0);for(t=u-1;n>c;){if(h[--n]<d[n]){for(r=n;r&&!h[--r];h[r]=t);--h[r],h[n]+=u}h[n]-=d[n]}for(;0==h[0];h.splice(0,1),--f);return h[0]?z(e,h,f):(e.s=3==C?-1:1,e.c=[e.e=0],e)},P.modulo=P.mod=function(e,t){var n,o,i=this;return e=new V(e,t),!i.c||!e.s||e.c&&!e.c[0]?new V(NaN):!e.c||i.c&&!i.c[0]?new V(i):(9==I?(o=e.s,e.s=1,n=r(i,e,0,3),e.s=o,n.s*=o):n=r(i,e,0,I),(e=i.minus(n.times(e))).c[0]||1!=I||(e.s=i.s),e)},P.multipliedBy=P.times=function(e,t){var r,n,o,i,a,c,l,f,d,p,v,m,y,b,w,_=this,S=_.c,A=(e=new V(e,t)).c;if(!(S&&A&&S[0]&&A[0]))return!_.s||!e.s||S&&!S[0]&&!A||A&&!A[0]&&!S?e.c=e.e=e.s=null:(e.s*=_.s,S&&A?(e.c=[0],e.e=0):e.c=e.e=null),e;for(n=g(_.e/s)+g(e.e/s),e.s*=_.s,(l=S.length)<(p=A.length)&&(y=S,S=A,A=y,o=l,l=p,p=o),o=l+p,y=[];o--;y.push(0));for(b=u,w=h,o=p;--o>=0;){for(r=0,v=A[o]%w,m=A[o]/w|0,i=o+(a=l);i>o;)r=((f=v*(f=S[--a]%w)+(c=m*f+(d=S[a]/w|0)*v)%w*w+y[i]+r)/b|0)+(c/w|0)+m*d,y[i--]=f%b;y[i]=r}return r?++n:y.splice(0,1),z(e,y,n)},P.negated=function(){var e=new V(this);return e.s=-e.s||null,e},P.plus=function(e,t){var r,n=this,o=n.s;if(t=(e=new V(e,t)).s,!o||!t)return new V(NaN);if(o!=t)return e.s=-t,n.minus(e);var i=n.e/s,a=e.e/s,c=n.c,l=e.c;if(!i||!a){if(!c||!l)return new V(o/0);if(!c[0]||!l[0])return l[0]?e:new V(c[0]?n:0*o)}if(i=g(i),a=g(a),c=c.slice(),o=i-a){for(o>0?(a=i,r=l):(o=-o,r=c),r.reverse();o--;r.push(0));r.reverse()}for((o=c.length)-(t=l.length)<0&&(r=l,l=c,c=r,t=o),o=0;t;)o=(c[--t]=c[t]+l[t]+o)/u|0,c[t]=u===c[t]?0:c[t]%u;return o&&(c=[o].concat(c),++a),z(e,c,a)},P.precision=P.sd=function(e,t){var r,n,o,i=this;if(null!=e&&e!==!!e)return m(e,1,d),null==t?t=C:m(t,0,8),q(new V(i),e,t);if(!(r=i.c))return null;if(n=(o=r.length-1)*s+1,o=r[o]){for(;o%10==0;o/=10,n--);for(o=r[0];o>=10;o/=10,n++);}return e&&i.e+1>n&&(n=i.e+1),n},P.shiftedBy=function(e){return m(e,-l,l),this.times("1e"+e)},P.squareRoot=P.sqrt=function(){var e,t,n,o,i,a=this,c=a.c,u=a.s,s=a.e,l=k+4,f=new V("0.5");if(1!==u||!c||!c[0])return new V(!u||u<0&&(!c||c[0])?NaN:c?a:1/0);if(0==(u=Math.sqrt(+Z(a)))||u==1/0?(((t=p(c)).length+s)%2==0&&(t+="0"),u=Math.sqrt(+t),s=g((s+1)/2)-(s<0||s%2),n=new V(t=u==1/0?"1e"+s:(t=u.toExponential()).slice(0,t.indexOf("e")+1)+s)):n=new V(u+""),n.c[0])for((u=(s=n.e)+l)<3&&(u=0);;)if(i=n,n=f.times(i.plus(r(a,i,l,1))),p(i.c).slice(0,u)===(t=p(n.c)).slice(0,u)){if(n.e<s&&--u,"9999"!=(t=t.slice(u-3,u+1))&&(o||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||(q(n,n.e+k+2,1),e=!n.times(n).eq(a));break}if(!o&&(q(i,i.e+k+2,0),i.times(i).eq(a))){n=i;break}l+=4,u+=4,o=1}return q(n,n.e+k+1,C,e)},P.toExponential=function(e,t){return null!=e&&(m(e,0,d),e++),$(this,e,t,1)},P.toFixed=function(e,t){return null!=e&&(m(e,0,d),e=e+this.e+1),$(this,e,t)},P.toFormat=function(e,t,r){var n,o=this;if(null==r)null!=e&&t&&"object"==typeof t?(r=t,t=null):e&&"object"==typeof e?(r=e,e=t=null):r=H;else if("object"!=typeof r)throw Error(a+"Argument not an object: "+r);if(n=o.toFixed(e,t),o.c){var i,c=n.split("."),u=+r.groupSize,s=+r.secondaryGroupSize,l=r.groupSeparator||"",f=c[0],h=c[1],d=o.s<0,g=d?f.slice(1):f,p=g.length;if(s&&(i=u,u=s,s=i,p-=i),u>0&&p>0){for(i=p%u||u,f=g.substr(0,i);i<p;i+=u)f+=l+g.substr(i,u);s>0&&(f+=l+g.slice(i)),d&&(f="-"+f)}n=h?f+(r.decimalSeparator||"")+((s=+r.fractionGroupSize)?h.replace(new RegExp("\\d{"+s+"}\\B","g"),"$&"+(r.fractionGroupSeparator||"")):h):f}return(r.prefix||"")+n+(r.suffix||"")},P.toFraction=function(e){var t,n,o,i,c,u,l,h,d,g,v,m,y=this,b=y.c;if(null!=e&&(!(l=new V(e)).isInteger()&&(l.c||1!==l.s)||l.lt(N)))throw Error(a+"Argument "+(l.isInteger()?"out of range: ":"not an integer: ")+Z(l));if(!b)return new V(y);for(t=new V(N),d=n=new V(N),o=h=new V(N),m=p(b),c=t.e=m.length-y.e-1,t.c[0]=f[(u=c%s)<0?s+u:u],e=!e||l.comparedTo(t)>0?c>0?t:d:l,u=U,U=1/0,l=new V(m),h.c[0]=0;g=r(l,t,0,1),1!=(i=n.plus(g.times(o))).comparedTo(e);)n=o,o=i,d=h.plus(g.times(i=d)),h=i,t=l.minus(g.times(i=t)),l=i;return i=r(e.minus(n),o,0,1),h=h.plus(i.times(d)),n=n.plus(i.times(o)),h.s=d.s=y.s,v=r(d,o,c*=2,C).minus(y).abs().comparedTo(r(h,n,c,C).minus(y).abs())<1?[d,o]:[h,n],U=u,v},P.toNumber=function(){return+Z(this)},P.toPrecision=function(e,t){return null!=e&&m(e,1,d),$(this,e,t,2)},P.toString=function(e){var t,r=this,n=r.s,o=r.e;return null===o?n?(t="Infinity",n<0&&(t="-"+t)):t="NaN":(null==e?t=o<=D||o>=M?b(p(r.c),o):w(p(r.c),o,"0"):10===e?t=w(p((r=q(new V(r),k+o+1,C)).c),r.e,"0"):(m(e,2,L.length,"Base"),t=_(w(p(r.c),o,"0"),10,e,n,!0)),n<0&&r.c[0]&&(t="-"+t)),t},P.valueOf=P.toJSON=function(){return Z(this)},P._isBigNumber=!0,null!=t&&V.set(t),V}()).default=r.BigNumber=r,e.exports?e.exports=r:(t||(t="undefined"!=typeof self&&self?self:window),t.BigNumber=r)}(t)}),s=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.BurstSymbol="Ƀ",t.BurstPlanckSymbol="ƀ",t.FeeQuantPlanck=735e3,t.OneBurstPlanck=1e8});r(s);s.BurstSymbol,s.BurstPlanckSymbol,s.FeeQuantPlanck,s.OneBurstPlanck;var l=n(function(e,t){var r;function n(e){if(!e||!/^-?\d*(\.\d+)?$/.test(e))throw new Error(`Invalid value: ${e}`)}Object.defineProperty(t,"__esModule",{value:!0}),u.default.config({EXPONENTIAL_AT:[-9,20]}),function(e){e[e.PLANCK=0]="PLANCK",e[e.BURST=1]="BURST"}(r=t.BurstValueFormat||(t.BurstValueFormat={}));class o{constructor(e){"string"==typeof e&&n(e),this._planck=new u.default(e)}static Zero(){return new o("0")}static fromPlanck(e){return new o(e)}static fromBurst(e){const t=new o("0");return t.setBurst("number"==typeof e?e.toString(10):e),t}getRaw(){return this._planck}getPlanck(){return this._planck.toString()}setPlanck(e){n(e),this._planck=new u.default(e)}getBurst(){return this._planck.dividedBy(1e8).toString()}setBurst(e){n(e),this._planck=new u.default(e).multipliedBy(1e8)}equals(e){return this._planck.eq(e._planck)}lessOrEqual(e){return this._planck.lte(e._planck)}less(e){return this._planck.lt(e._planck)}greaterOrEqual(e){return this._planck.gte(e._planck)}greater(e){return this._planck.gt(e._planck)}add(e){return this._planck=this._planck.plus(e._planck),this}subtract(e){return this._planck=this._planck.minus(e._planck),this}multiply(e){return this._planck=this._planck.multipliedBy(e),this}divide(e){if(0===e)throw new Error("Division by zero");return this._planck=this._planck.div(e),this}toString(e=r.BURST){return e===r.BURST?`${s.BurstSymbol} ${this.getBurst()}`:`${s.BurstPlanckSymbol} ${this._planck}`}clone(){return o.fromPlanck(this.getPlanck())}}t.BurstValue=o});r(l);l.BurstValueFormat,l.BurstValue;var f=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.isValid=(e=>{0===e.indexOf(`${a.AddressPrefix}-`)&&(e=e.substr(6));const t=a.initialCodeword.slice();let r=0;for(let n=0;n<e.length;n++){const o=a.alphabet.indexOf(e.charAt(n));if(!(o<=-1||o>a.alphabet.length)){if(r>16)return!1;t[a.cwmap[r]]=o,r++}}if(17!==r)return!1;let n=0;for(let e=1;e<5;e++){let r=0;for(let n=0;n<31;n++){if(n>12&&n<27)continue;let o=n;n>26&&(o-=14),r^=a.gmult(t[o],a.gexp[e*n%31])}n|=r}return 0===n}),t.isBurstAddress=(e=>{if(!new RegExp(`${a.AddressPrefix}-[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{4}-[A-Z0-9]{5}(-w+)?`,"i").test(e))return!1;const r=e.lastIndexOf("-"),n=e.substr(r+1);return e=n.length>5?e.substr(0,r):e,t.isValid(e)})});r(f);f.isValid,f.isBurstAddress;var h=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertAddressToNumericId=(e=>{if(null==e||0===e.trim().length)return;if(0!==e.indexOf(`${a.AddressPrefix}-`))return;e=e.substr(6);const t=a.initialCodeword.slice();let r=0;for(let n=0;n<e.length;n++){const o=a.alphabet.indexOf(e.charAt(n));if(!(o<=-1||o>a.alphabet.length)){if(r>16)return;t[a.cwmap[r]]=o,r++}}if(!f.isValid(e))return;let n=a.base32Length;const o=[];for(let e=0;e<n;e++)o[e]=t[n-e-1];let i,c="",u=0;do{i=0,u=0;for(let e=0;e<n;e++)(u=32*u+o[e])>=10?(o[i]=Math.floor(u/10),u%=10,i+=1):i>0&&(o[i]=0,i+=1);n=i,c+=u}while(n>0);return c.split("").reverse().join("")})});r(h);h.convertAddressToNumericId;var d=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBase36StringToHexString=(e=>new u.default(e,36).toString(16))});r(d);d.convertBase36StringToHexString;const g="function"==typeof atob,p="function"==typeof btoa,v="function"==typeof Buffer,m="function"==typeof TextDecoder?new TextDecoder:void 0,y="function"==typeof TextEncoder?new TextEncoder:void 0,b=[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],w=(e=>{let t={};return b.forEach((e,r)=>t[e]=r),t})(),_=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,S=String.fromCharCode.bind(String),A="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):(e,t=(e=>e))=>new Uint8Array(Array.prototype.slice.call(e,0).map(t)),T=e=>e.replace(/[+\/]/g,e=>"+"==e?"-":"_").replace(/=+$/m,""),B=e=>e.replace(/[^A-Za-z0-9\+\/]/g,""),x=e=>{let t,r,n,o,i="";const a=e.length%3;for(let a=0;a<e.length;){if((r=e.charCodeAt(a++))>255||(n=e.charCodeAt(a++))>255||(o=e.charCodeAt(a++))>255)throw new TypeError("invalid character found");i+=b[(t=r<<16|n<<8|o)>>18&63]+b[t>>12&63]+b[t>>6&63]+b[63&t]}return a?i.slice(0,a-3)+"===".substring(a):i},O=p?e=>btoa(e):v?e=>Buffer.from(e,"binary").toString("base64"):x,E=v?e=>Buffer.from(e).toString("base64"):e=>{let t=[];for(let r=0,n=e.length;r<n;r+=4096)t.push(S.apply(null,e.subarray(r,r+4096)));return O(t.join(""))},P=(e,t=!1)=>t?T(E(e)):E(e),N=e=>{if(e.length<2)return(t=e.charCodeAt(0))<128?e:t<2048?S(192|t>>>6)+S(128|63&t):S(224|t>>>12&15)+S(128|t>>>6&63)+S(128|63&t);var t=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);return S(240|t>>>18&7)+S(128|t>>>12&63)+S(128|t>>>6&63)+S(128|63&t)},k=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,C=e=>e.replace(k,N),D=v?e=>Buffer.from(e,"utf8").toString("base64"):y?e=>E(y.encode(e)):e=>O(C(e)),M=(e,t=!1)=>t?T(D(e)):D(e),j=e=>M(e,!0),U=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,F=e=>{switch(e.length){case 4:var t=((7&e.charCodeAt(0))<<18|(63&e.charCodeAt(1))<<12|(63&e.charCodeAt(2))<<6|63&e.charCodeAt(3))-65536;return S(55296+(t>>>10))+S(56320+(1023&t));case 3:return S((15&e.charCodeAt(0))<<12|(63&e.charCodeAt(1))<<6|63&e.charCodeAt(2));default:return S((31&e.charCodeAt(0))<<6|63&e.charCodeAt(1))}},I=e=>e.replace(U,F),R=e=>{if(e=e.replace(/\s+/g,""),!_.test(e))throw new TypeError("malformed base64.");e+="==".slice(2-(3&e.length));let t,r,n,o="";for(let i=0;i<e.length;)t=w[e.charAt(i++)]<<18|w[e.charAt(i++)]<<12|(r=w[e.charAt(i++)])<<6|(n=w[e.charAt(i++)]),o+=64===r?S(t>>16&255):64===n?S(t>>16&255,t>>8&255):S(t>>16&255,t>>8&255,255&t);return o},H=g?e=>atob(B(e)):v?e=>Buffer.from(e,"base64").toString("binary"):R,L=v?e=>A(Buffer.from(e,"base64")):e=>A(H(e),e=>e.charCodeAt(0)),V=e=>L(G(e)),$=v?e=>Buffer.from(e,"base64").toString("utf8"):m?e=>m.decode(L(e)):e=>I(H(e)),G=e=>B(e.replace(/[-_]/g,e=>"-"==e?"+":"/")),z=e=>$(G(e)),q=e=>{if("string"!=typeof e)return!1;const t=e.replace(/\s+/g,"").replace(/=+$/,"");return!/[^\s0-9a-zA-Z\+/]/.test(t)||!/[^\s0-9a-zA-Z\-_]/.test(t)},Z=e=>({value:e,enumerable:!1,writable:!0,configurable:!0}),Q=function(){const e=(e,t)=>Object.defineProperty(String.prototype,e,Z(t));e("fromBase64",function(){return z(this)}),e("toBase64",function(e){return M(this,e)}),e("toBase64URI",function(){return M(this,!0)}),e("toBase64URL",function(){return M(this,!0)}),e("toUint8Array",function(){return V(this)})},W=function(){const e=(e,t)=>Object.defineProperty(Uint8Array.prototype,e,Z(t));e("toBase64",function(e){return P(this,e)}),e("toBase64URI",function(){return P(this,!0)}),e("toBase64URL",function(){return P(this,!0)})},J=()=>{Q(),W()},X={version:"3.6.0",VERSION:"3.6.0",atob:H,atobPolyfill:R,btoa:O,btoaPolyfill:x,fromBase64:z,toBase64:M,encode:M,encodeURI:j,encodeURL:j,utob:C,btou:I,decode:z,isValid:q,fromUint8Array:P,toUint8Array:V,extendString:Q,extendUint8Array:W,extendBuiltins:J};var K=o(Object.freeze({__proto__:null,version:"3.6.0",VERSION:"3.6.0",atob:H,atobPolyfill:R,btoa:O,btoaPolyfill:x,fromBase64:z,toBase64:M,utob:C,encode:M,encodeURI:j,encodeURL:j,btou:I,decode:z,isValid:q,fromUint8Array:P,toUint8Array:V,extendString:Q,extendUint8Array:W,extendBuiltins:J,Base64:X})),Y=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBase64StringToString=(e=>K.Base64.decode(e))});r(Y);Y.convertBase64StringToString;var ee=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBurstTimeToEpochTime=(e=>1e3*(a.GenesisBlockTime+e))});r(ee);ee.convertBurstTimeToEpochTime;var te=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertBurstTimeToDate=(e=>new Date(ee.convertBurstTimeToEpochTime(e)))});r(te);te.convertBurstTimeToDate;var re=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertByteArrayToHexString=((e,t=!1)=>{const r=[];for(let t=0;t<e.length;t++)r.push((e[t]>>>4).toString(16)),r.push((15&e[t]).toString(16));return t?r.join("").toUpperCase():r.join("")})});r(re);re.convertByteArrayToHexString;var ne=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertByteArrayToString=((e,t=0,r=null)=>{if(0===r)return"";let n=e;if(0!==t){const o=null===r?e.length-t:r;!function(e,t,r=0){if(r<0)throw new Error("Start index should not be negative");if(e.length<r+t)throw new Error("Need at least "+t+" bytes to convert to an integer")}(n,o,t),n=e.slice(t,t+o)}return decodeURIComponent(escape(String.fromCharCode.apply(null,Array.from(n))))})});r(ne);ne.convertByteArrayToString;var oe=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertDateToBurstTime=(e=>Math.round(e.getTime()/1e3)-a.GenesisBlockTime)});r(oe);oe.convertDateToBurstTime;String.prototype.padStart||(String.prototype.padStart=function(e,t){return e>>=0,t=String(void 0!==t?t:" "),this.length>=e?String(this):((e-=this.length)>t.length&&(t+=t.repeat(e/t.length)),t.slice(0,e)+String(this))});var ie=Object.freeze({__proto__:null}),ae=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.twosComplementBinary=(e=>{let t=e.multipliedBy(-1).toString(2);for(;t.length%8;)t="0"+t;const r="1"===t[0]&&-1!==t.slice(1).indexOf("1")?"11111111":"";return t=t.split("").map(e=>"0"===e?"1":"0").join(""),new u.default(r+t,2).plus(1)})});r(ae);ae.twosComplementBinary;o(ie);var ce=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertDecStringToHexString=((e,t=2)=>{let r="string"==typeof e?new u.default(e):e;if(r.isNaN())throw new Error(`Invalid decimal argument: [${e}] - Expected a valid decimal value`);if(t<0)throw new Error(`Invalid padding argument: [${t}] - Expected a positive value`);const n=r.lt(0);n&&(r=ae.twosComplementBinary(r));const o=r.toString(16),i=Math.ceil(o.length/t);return o.padStart(i*t,n?"f":"0")})});r(ce);ce.convertDecStringToHexString;var ue=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexEndianess=(e=>{let t="";const r=e;for(let e=r.length-1;e>=0;e-=2)t+=r[e-1]+r[e];return t})});r(ue);ue.convertHexEndianess;var se=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToBase36String=(e=>new u.default(e,16).toString(36))});r(se);se.convertHexStringToBase36String;var le=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToByteArray=(e=>{if(e.length%2)throw new Error(`Invalid Hex String: ${e}`);const t=new Uint8Array(e.length/2);for(let r=0;r<e.length;r+=2){const n=parseInt(e.substr(r,2),16);if(Number.isNaN(n))throw new Error(`Invalid Hex String: ${e}`);t[r/2]=n}return t})});r(le);le.convertHexStringToByteArray;var fe=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToDecString=(e=>{const t=[0];let r,n,o;for(r=0;r<e.length;r+=1){for(o=parseInt(e.charAt(r),16),n=0;n<t.length;n+=1)t[n]=16*t[n]+o,o=t[n]/10|0,t[n]%=10;for(;o>0;)t.push(o%10),o=o/10|0}return t.reverse().join("")})});r(fe);fe.convertHexStringToDecString;var he=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexStringToString=(e=>ne.convertByteArrayToString(le.convertHexStringToByteArray(e)))});r(he);he.convertHexStringToString;var de=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertNQTStringToNumber=(e=>{if(null==e||""===e)throw new Error("Invalid argument");return parseFloat(e)/1e8})});r(de);de.convertNQTStringToNumber;var ge=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertNumberToNQTString=(e=>{if(null==e)throw new Error("Invalid argument");return parseFloat(e.toString()).toFixed(8).replace(".","")})});r(ge);ge.convertNumberToNQTString;var pe=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertNumericIdToAddress=(e=>{if(null==e||0===e.trim().length)return;const t=[],r=a.initialCodeword.slice();let n=0,o=e.length;for(let r=0;r<o;r++)t[r]=e.charCodeAt(r)-"0".charCodeAt(0);let i=0,c=0;do{i=0,c=0;for(let e=0;e<o;e++)(i=10*i+t[e])>=32?(t[c]=i>>5,i&=31,c++):c>0&&(t[c]=0,c++);o=c,r[n]=i,n++}while(o>0);const u=[0,0,0,0];for(let e=a.base32Length-1;e>=0;e--){const t=r[e]^u[3];u[3]=u[2]^a.gmult(30,t),u[2]=u[1]^a.gmult(6,t),u[1]=u[0]^a.gmult(9,t),u[0]=a.gmult(17,t)}r[13]=u[0],r[14]=u[1],r[15]=u[2],r[16]=u[3];let s=a.AddressPrefix+"-";for(let e=0;e<17;e++)s+=a.alphabet[r[a.cwmap[e]]],3==(3&e)&&e<13&&(s+="-");return s})});r(pe);pe.convertNumericIdToAddress;var ve=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStringToBase64String=((e,t=!0)=>t?K.Base64.encodeURI(e):K.Base64.encode(e))});r(ve);ve.convertStringToBase64String;var me=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStringToByteArray=(e=>{const t=unescape(encodeURIComponent(e)),r=new Uint8Array(t.length);for(let e=0;e<t.length;++e)r[e]=t.charCodeAt(e);return r})});r(me);me.convertStringToByteArray;var ye=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStringToHexString=(e=>re.convertByteArrayToHexString(me.convertStringToByteArray(e)))});r(ye);ye.convertStringToHexString;var be=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Text=0]="Text",e[e.Hexadecimal=1]="Hexadecimal",e[e.Base64=2]="Base64"}(t.EncoderFormat||(t.EncoderFormat={}))});r(be);be.EncoderFormat;var we=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.createDeeplink=(e=>{const{encoderFormat:t=be.EncoderFormat.Base64,domain:r,action:n,payload:o}=e;let i=r?`burst.${r}://v1`:"burst://v1";return n&&(i+=`?action=${n}`),o&&(i+=`&payload=${function(e,t){let r=e;switch("string"!=typeof e&&(r=JSON.stringify(e)),t){case be.EncoderFormat.Hexadecimal:return ye.convertStringToHexString(r);case be.EncoderFormat.Base64:return ve.convertStringToBase64String(r);case be.EncoderFormat.Text:default:return r}}(o,t)}`),i})});r(we);we.createDeeplink;var _e=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(be)});r(_e);var Se=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=/^burst.?(.+)?:\/\/(v.+?)\??/i;t.parseDeeplink=((e,t=_e.EncoderFormat.Base64)=>{const n=()=>{throw new Error("Invalid deeplink: "+e)},o=(e,t)=>(e.startsWith(t+"=")||n(),e.split("=")[1]),i=e.match(r);i&&3===i.length||n();const a={domain:i[1],version:i[2],action:void 0,payload:void 0,decodedPayload:void 0};try{const r=e.indexOf("?");if(-1!==r){const i=e.substring(r+1).split("&");i.length>=1&&(i.length>2&&n(),a.action=o(i[0],"action"),2===i.length&&(a.payload=o(i[1],"payload"),a.decodedPayload=((e,t)=>{let r=e;switch(t){case _e.EncoderFormat.Hexadecimal:r=he.convertHexStringToString(e);break;case _e.EncoderFormat.Base64:r=Y.convertBase64StringToString(e);break;case _e.EncoderFormat.Text:}try{return JSON.parse(r)}catch(e){return r}})(a.payload,t)))}}catch(e){n()}return a})});r(Se);Se.parseDeeplink;var Ae=n(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.sumNQTStringToNumber=function(...e){return e.reduce((e,t)=>e+de.convertNQTStringToNumber(t),0)}});r(Ae);Ae.sumNQTStringToNumber;var Te=n(function(e,t){function r(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),r(i),r(c),r(l),r(s),r(h),r(d),r(Y),r(te),r(ee),r(re),r(ne),r(oe),r(ce),r(ue),r(se),r(le),r(fe),r(he),r(de),r(ge),r(pe),r(ve),r(me),r(ye),r(we),r(f),r(Se),r(Ae),r(_e)});r(Te);var Be=Te.BurstValue,xe=Te.FeeQuantPlanck,Oe=Te.OneBurstPlanck,Ee=Te.convertHexStringToDecString,Pe=Te.convertDecStringToHexString,Ne=Te.convertHexStringToString,ke=Te.convertHexEndianess;Te.convertHexStringToByteArray,Te.convertByteArrayToHexString;function Ce(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:16,n=16*t,o=n+r;if(o>e.machineData.length)throw new Error("Insufficient length for variable at position: ".concat(n," (and given length: ").concat(r,")"));if(o%2!=0)throw new Error("Invalid position: ".concat(n," (or given length: ").concat(r,") - must be at least multiple of 2"));return ke(e.machineData.substr(n,r))}function De(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function Me(e){return function(e){if(Array.isArray(e)){for(var t=0,r=new Array(e.length);t<e.length;t++)r[t]=e[t];return r}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var je=256;function Ue(e){return Math.ceil(e.length/2/je)}var Fe=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._contract=t}var t,r,n;return t=e,(r=[{key:"getContract",value:function(){return this._contract}},{key:"countCodePages",value:function(){return Ue(this._contract.machineCode)}},{key:"getVariableAsString",value:function(t){var r=this.getHexDataAt(t,e.VariableLength);return Ne(r.replace(/00/g,""))}},{key:"getDataBlocksAsString",value:function(t,r){var n=this.getHexDataAt(t,r*e.VariableLength);return Ne(n.replace(/00/g,""))}},{key:"getVariableAsDecimal",value:function(e){return Ee(this.getVariable(e))}},{key:"getVariable",value:function(t){return this.getHexDataAt(t,e.VariableLength)}},{key:"getHexDataAt",value:function(t,r){var n=r||this._contract.machineData.length-e.VariableLength*t;return Ce(this._contract,t,n)}}])&&De(t.prototype,r),n&&De(t,n),e}();Fe.VariableLength=16;var Ie=function(e){return"boolean"==typeof e?e?"1":"0":"number"==typeof e?"".concat(e):e};return e.CodePageSize=je,e.ContractDataView=Fe,e.calculateMinimumCreationFee=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return Be.fromPlanck((t?10*xe:Oe).toString(10)).multiply(2+Ue(e)+1)},e.countCodePages=Ue,e.generateMethodCall=function(e){var t=e.methodArgs?[e.methodHash].concat(Me(e.methodArgs)):[e.methodHash];if(t.length>4)throw new Error("At maximum ".concat(3," are supported"));return t.map(Ie).map(function(e){return Pe(e,16)}).map(ke).join("")},e.getContractDatablock=Ce,e}({});
//# sourceMappingURL=burstjs.contracts.min.js.map
{
"name": "@burstjs/contracts",
"version": "0.6.0-beta.5",
"version": "0.6.0-beta.6",
"description": "Smart Contracts package for BURST",

@@ -47,3 +47,3 @@ "contributors": [

"dependencies": {
"@burstjs/util": "^0.6.0-beta.5"
"@burstjs/util": "^0.6.0-beta.6"
},

@@ -55,3 +55,3 @@ "husky": {

},
"gitHead": "3f8f40435d9c379feee73f457bb2953777614c7c",
"gitHead": "5299fc8ccc11cf28e869a169df77d4fbc5d6cf42",
"publishConfig": {

@@ -58,0 +58,0 @@ "access": "public"

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc