@dodoex/wallet-web3 0.0.22-0 → 0.0.22-2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. package/dist/__tslib-dd22ed7d.js +1 -0
  2. package/dist/_commonjs-dynamic-modules-7cfc9805.js +1 -0
  3. package/dist/blocto-69a506f8.js +1 -0
  4. package/dist/bn-3e892825.js +1 -0
  5. package/dist/cjs/__tslib-8344f379.cjs +1 -0
  6. package/dist/cjs/_commonjs-dynamic-modules-f09a98c7.cjs +1 -0
  7. package/dist/cjs/blocto-bdab3cea.cjs +1 -0
  8. package/dist/cjs/bn-ce9dbccd.cjs +1 -0
  9. package/dist/cjs/ethers-767c2337.cjs +1 -0
  10. package/dist/cjs/id-6c4d97dd.cjs +1 -0
  11. package/dist/cjs/index-2428f0a6.cjs +1 -0
  12. package/dist/cjs/index-3d1a3da9.cjs +1 -0
  13. package/dist/cjs/index-4585c950.cjs +1 -0
  14. package/dist/cjs/index-47f3e61d.cjs +1 -0
  15. package/dist/cjs/index-4abb9db3.cjs +1 -0
  16. package/dist/cjs/index-5d7b94fd.cjs +1 -0
  17. package/dist/cjs/index-659dc842.cjs +61 -0
  18. package/dist/cjs/index-67e59d1a.cjs +1 -0
  19. package/dist/cjs/index-795ad993.cjs +46 -0
  20. package/dist/cjs/index-a5fa1e6e.cjs +15 -0
  21. package/dist/cjs/index-aa04e7a3.cjs +1 -0
  22. package/dist/cjs/index-cfe3e391.cjs +10 -0
  23. package/dist/cjs/index-d226aab9.cjs +8 -0
  24. package/dist/cjs/index-e875b498.cjs +1 -0
  25. package/dist/cjs/index-f2c04d55.cjs +1 -0
  26. package/dist/cjs/index.cjs +1 -1
  27. package/dist/cjs/index.es-a3704620.cjs +9 -0
  28. package/dist/cjs/interface-1b54eefa.cjs +1 -0
  29. package/dist/cjs/node-ponyfill-a7a0b431.cjs +1 -0
  30. package/dist/cjs/portis-ec0ce54d.cjs +1 -0
  31. package/dist/cjs/provider-403219c9.cjs +1 -0
  32. package/dist/cjs/providers/wallets/index.d.ts +1 -0
  33. package/dist/cjs/providers/wallets/types.d.ts +1 -0
  34. package/dist/cjs/rainbow-caa66e39.cjs +1 -0
  35. package/dist/cjs/uAuth-a2d2617a.cjs +1 -0
  36. package/dist/cjs/walletConnect-c57b3b5d.cjs +1 -0
  37. package/dist/cjs/walletLink-f0f9e2a7.cjs +3 -0
  38. package/dist/ethers-51e19435.js +1 -0
  39. package/dist/id-830e09aa.js +1 -0
  40. package/dist/index-0103e089.js +1 -0
  41. package/dist/index-235259d8.js +1 -0
  42. package/dist/index-3158e93a.js +46 -0
  43. package/dist/index-46c2059e.js +1 -0
  44. package/dist/index-5091218e.js +1 -0
  45. package/dist/index-5f9e8321.js +1 -0
  46. package/dist/index-650785ec.js +1 -0
  47. package/dist/index-6bf494b0.js +1 -0
  48. package/dist/index-80483be2.js +8 -0
  49. package/dist/index-82b4fd64.js +60 -0
  50. package/dist/index-88837567.js +1 -0
  51. package/dist/index-c699a924.js +1 -0
  52. package/dist/index-cc453bb1.js +10 -0
  53. package/dist/index-de37f6bb.js +1 -0
  54. package/dist/index-f3052552.js +15 -0
  55. package/dist/index.es-877101c5.js +9 -0
  56. package/dist/index.js +1 -1
  57. package/dist/interface-f97a878a.js +1 -0
  58. package/dist/node-ponyfill-55b945e1.js +1 -0
  59. package/dist/portis-7d46b7ed.js +1 -0
  60. package/dist/provider-453e2483.js +1 -0
  61. package/dist/providers/wallets/index.d.ts +1 -0
  62. package/dist/providers/wallets/types.d.ts +1 -0
  63. package/dist/rainbow-61a52379.js +1 -0
  64. package/dist/uAuth-40d8acab.js +1 -0
  65. package/dist/walletConnect-d6a9aa67.js +1 -0
  66. package/dist/walletLink-106461e6.js +3 -0
  67. package/package.json +1 -1
  68. package/dist/blocto-81ce4cf0.js +0 -1
  69. package/dist/cjs/blocto-f4eca78a.cjs +0 -1
  70. package/dist/cjs/index-1aadca5d.cjs +0 -1
  71. package/dist/cjs/index-473f668c.cjs +0 -1
  72. package/dist/cjs/index-49e73d05.cjs +0 -1
  73. package/dist/cjs/index-8974ffc5.cjs +0 -1
  74. package/dist/cjs/index-9ca64306.cjs +0 -1
  75. package/dist/cjs/index-adec4f81.cjs +0 -1
  76. package/dist/cjs/portis-a7e7fb1a.cjs +0 -1
  77. package/dist/cjs/provider-c81ebdd6.cjs +0 -1
  78. package/dist/cjs/rainbow-7aaa17ca.cjs +0 -1
  79. package/dist/cjs/uAuth-d88a18fe.cjs +0 -1
  80. package/dist/cjs/walletConnect-1ed400eb.cjs +0 -1
  81. package/dist/cjs/walletLink-d7276923.cjs +0 -1
  82. package/dist/index-0915d9cd.js +0 -1
  83. package/dist/index-21b99e8f.js +0 -1
  84. package/dist/index-3f9057c8.js +0 -1
  85. package/dist/index-52b5f0d3.js +0 -1
  86. package/dist/index-7f590b21.js +0 -1
  87. package/dist/index-cb8cb0f4.js +0 -1
  88. package/dist/portis-2c8e6003.js +0 -1
  89. package/dist/provider-cd132432.js +0 -1
  90. package/dist/rainbow-7046183a.js +0 -1
  91. package/dist/uAuth-c3577e9b.js +0 -1
  92. package/dist/walletConnect-5350d3f5.js +0 -1
  93. package/dist/walletLink-69a6e65f.js +0 -1
@@ -0,0 +1 @@
1
+ import{c as t,k as i}from"./index-cc453bb1.js";import{isBytes as r,hexlify as e,isHexString as n,arrayify as h}from"@ethersproject/bytes";let o=!1,s=!1;const u={debug:1,default:2,info:2,warning:3,error:4,off:5};let a=u.default,l=null;const m=function(){try{const t=[];if(["NFD","NFC","NFKD","NFKC"].forEach((i=>{try{if("test"!=="test".normalize(i))throw new Error("bad normalize")}catch(r){t.push(i)}})),t.length)throw new Error("missing "+t.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(t){return t.message}return null}();var f,d;!function(t){t.DEBUG="DEBUG",t.INFO="INFO",t.WARNING="WARNING",t.ERROR="ERROR",t.OFF="OFF"}(f||(f={})),function(t){t.UNKNOWN_ERROR="UNKNOWN_ERROR",t.NOT_IMPLEMENTED="NOT_IMPLEMENTED",t.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",t.NETWORK_ERROR="NETWORK_ERROR",t.SERVER_ERROR="SERVER_ERROR",t.TIMEOUT="TIMEOUT",t.BUFFER_OVERRUN="BUFFER_OVERRUN",t.NUMERIC_FAULT="NUMERIC_FAULT",t.MISSING_NEW="MISSING_NEW",t.INVALID_ARGUMENT="INVALID_ARGUMENT",t.MISSING_ARGUMENT="MISSING_ARGUMENT",t.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",t.CALL_EXCEPTION="CALL_EXCEPTION",t.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",t.NONCE_EXPIRED="NONCE_EXPIRED",t.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",t.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",t.TRANSACTION_REPLACED="TRANSACTION_REPLACED",t.ACTION_REJECTED="ACTION_REJECTED"}(d||(d={}));const p="0123456789abcdef";class g{constructor(t){Object.defineProperty(this,"version",{enumerable:!0,value:t,writable:!1})}_log(t,i){const r=t.toLowerCase();null==u[r]&&this.throwArgumentError("invalid log level name","logLevel",t),a>u[r]||console.log.apply(console,i)}debug(...t){this._log(g.levels.DEBUG,t)}info(...t){this._log(g.levels.INFO,t)}warn(...t){this._log(g.levels.WARNING,t)}makeError(t,i,r){if(s)return this.makeError("censored error",i,{});i||(i=g.errors.UNKNOWN_ERROR),r||(r={});const e=[];Object.keys(r).forEach((t=>{const i=r[t];try{if(i instanceof Uint8Array){let r="";for(let t=0;t<i.length;t++)r+=p[i[t]>>4],r+=p[15&i[t]];e.push(t+"=Uint8Array(0x"+r+")")}else e.push(t+"="+JSON.stringify(i))}catch(i){e.push(t+"="+JSON.stringify(r[t].toString()))}})),e.push(`code=${i}`),e.push(`version=${this.version}`);const n=t;let h="";switch(i){case d.NUMERIC_FAULT:{h="NUMERIC_FAULT";const i=t;switch(i){case"overflow":case"underflow":case"division-by-zero":h+="-"+i;break;case"negative-power":case"negative-width":h+="-unsupported";break;case"unbound-bitwise-result":h+="-unbound-result"}break}case d.CALL_EXCEPTION:case d.INSUFFICIENT_FUNDS:case d.MISSING_NEW:case d.NONCE_EXPIRED:case d.REPLACEMENT_UNDERPRICED:case d.TRANSACTION_REPLACED:case d.UNPREDICTABLE_GAS_LIMIT:h=i}h&&(t+=" [ See: https://links.ethers.org/v5-errors-"+h+" ]"),e.length&&(t+=" ("+e.join(", ")+")");const o=new Error(t);return o.reason=n,o.code=i,Object.keys(r).forEach((function(t){o[t]=r[t]})),o}throwError(t,i,r){throw this.makeError(t,i,r)}throwArgumentError(t,i,r){return this.throwError(t,g.errors.INVALID_ARGUMENT,{argument:i,value:r})}assert(t,i,r,e){t||this.throwError(i,r,e)}assertArgument(t,i,r,e){t||this.throwArgumentError(i,r,e)}checkNormalize(t){m&&this.throwError("platform missing String.prototype.normalize",g.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:m})}checkSafeUint53(t,i){"number"==typeof t&&(null==i&&(i="value not safe"),(t<0||t>=9007199254740991)&&this.throwError(i,g.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:t}),t%1&&this.throwError(i,g.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:t}))}checkArgumentCount(t,i,r){r=r?": "+r:"",t<i&&this.throwError("missing argument"+r,g.errors.MISSING_ARGUMENT,{count:t,expectedCount:i}),t>i&&this.throwError("too many arguments"+r,g.errors.UNEXPECTED_ARGUMENT,{count:t,expectedCount:i})}checkNew(t,i){t!==Object&&null!=t||this.throwError("missing new",g.errors.MISSING_NEW,{name:i.name})}checkAbstract(t,i){t===i?this.throwError("cannot instantiate abstract class "+JSON.stringify(i.name)+" directly; use a sub-class",g.errors.UNSUPPORTED_OPERATION,{name:t.name,operation:"new"}):t!==Object&&null!=t||this.throwError("missing new",g.errors.MISSING_NEW,{name:i.name})}static globalLogger(){return l||(l=new g("logger/5.7.0")),l}static setCensorship(t,i){if(!t&&i&&this.globalLogger().throwError("cannot permanently disable censorship",g.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),o){if(!t)return;this.globalLogger().throwError("error censorship permanent",g.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}s=!!t,o=!!i}static setLogLevel(t){const i=u[t.toLowerCase()];null!=i?a=i:g.globalLogger().warn("invalid log level - "+t)}static from(t){return new g(t)}}g.errors=d,g.levels=f;var c=Object.freeze({__proto__:null,get LogLevel(){return f},get ErrorCode(){return d},Logger:g}),M={exports:{}};!function(t,i){function r(t,i){if(!t)throw new Error(i||"Assertion failed")}function e(t,i){t.super_=i;var r=function(){};r.prototype=i.prototype,t.prototype=new r,t.prototype.constructor=t}function n(t,i,r){if(n.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==i&&"be"!==i||(r=i,i=10),this._init(t||0,i||10,r||"be"))}var h;"object"==typeof t?t.exports=n:i.BN=n,n.BN=n,n.wordSize=26;try{h="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:require("buffer").Buffer}catch(t){}function o(t,i){var e=t.charCodeAt(i);return e>=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:void r(!1,"Invalid character in "+t)}function s(t,i,r){var e=o(t,r);return r-1>=i&&(e|=o(t,r-1)<<4),e}function u(t,i,e,n){for(var h=0,o=0,s=Math.min(t.length,e),u=i;u<s;u++){var a=t.charCodeAt(u)-48;h*=n,o=a>=49?a-49+10:a>=17?a-17+10:a,r(a>=0&&o<n,"Invalid character"),h+=o}return h}function a(t,i){t.words=i.words,t.length=i.length,t.negative=i.negative,t.red=i.red}if(n.isBN=function(t){return t instanceof n||null!==t&&"object"==typeof t&&t.constructor.wordSize===n.wordSize&&Array.isArray(t.words)},n.max=function(t,i){return t.cmp(i)>0?t:i},n.min=function(t,i){return t.cmp(i)<0?t:i},n.prototype._init=function(t,i,e){if("number"==typeof t)return this._initNumber(t,i,e);if("object"==typeof t)return this._initArray(t,i,e);"hex"===i&&(i=16),r(i===(0|i)&&i>=2&&i<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n<t.length&&(16===i?this._parseHex(t,n,e):(this._parseBase(t,i,n),"le"===e&&this._initArray(this.toArray(),i,e)))},n.prototype._initNumber=function(t,i,e){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):(r(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===e&&this._initArray(this.toArray(),i,e)},n.prototype._initArray=function(t,i,e){if(r("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 h,o,s=0;if("be"===e)for(n=t.length-1,h=0;n>=0;n-=3)o=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[h]|=o<<s&67108863,this.words[h+1]=o>>>26-s&67108863,(s+=24)>=26&&(s-=26,h++);else if("le"===e)for(n=0,h=0;n<t.length;n+=3)o=t[n]|t[n+1]<<8|t[n+2]<<16,this.words[h]|=o<<s&67108863,this.words[h+1]=o>>>26-s&67108863,(s+=24)>=26&&(s-=26,h++);return this._strip()},n.prototype._parseHex=function(t,i,r){this.length=Math.ceil((t.length-i)/6),this.words=new Array(this.length);for(var e=0;e<this.length;e++)this.words[e]=0;var n,h=0,o=0;if("be"===r)for(e=t.length-1;e>=i;e-=2)n=s(t,i,e)<<h,this.words[o]|=67108863&n,h>=18?(h-=18,o+=1,this.words[o]|=n>>>26):h+=8;else for(e=(t.length-i)%2==0?i+1:i;e<t.length;e+=2)n=s(t,i,e)<<h,this.words[o]|=67108863&n,h>=18?(h-=18,o+=1,this.words[o]|=n>>>26):h+=8;this._strip()},n.prototype._parseBase=function(t,i,r){this.words=[0],this.length=1;for(var e=0,n=1;n<=67108863;n*=i)e++;e--,n=n/i|0;for(var h=t.length-r,o=h%e,s=Math.min(h,h-o)+r,a=0,l=r;l<s;l+=e)a=u(t,l,l+e,i),this.imuln(n),this.words[0]+a<67108864?this.words[0]+=a:this._iaddn(a);if(0!==o){var m=1;for(a=u(t,l,t.length,i),l=0;l<o;l++)m*=i;this.imuln(m),this.words[0]+a<67108864?this.words[0]+=a:this._iaddn(a)}this._strip()},n.prototype.copy=function(t){t.words=new Array(this.length);for(var i=0;i<this.length;i++)t.words[i]=this.words[i];t.length=this.length,t.negative=this.negative,t.red=this.red},n.prototype._move=function(t){a(t,this)},n.prototype.clone=function(){var t=new n(null);return this.copy(t),t},n.prototype._expand=function(t){for(;this.length<t;)this.words[this.length++]=0;return this},n.prototype._strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},n.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{n.prototype[Symbol.for("nodejs.util.inspect.custom")]=l}catch(t){n.prototype.inspect=l}else n.prototype.inspect=l;function l(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var m=["","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"],f=[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],d=[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 p(t,i,r){r.negative=i.negative^t.negative;var e=t.length+i.length|0;r.length=e,e=e-1|0;var n=0|t.words[0],h=0|i.words[0],o=n*h,s=67108863&o,u=o/67108864|0;r.words[0]=s;for(var a=1;a<e;a++){for(var l=u>>>26,m=67108863&u,f=Math.min(a,i.length-1),d=Math.max(0,a-t.length+1);d<=f;d++){var p=a-d|0;l+=(o=(n=0|t.words[p])*(h=0|i.words[d])+m)/67108864|0,m=67108863&o}r.words[a]=0|m,u=0|l}return 0!==u?r.words[a]=0|u:r.length--,r._strip()}n.prototype.toString=function(t,i){var e;if(i=0|i||1,16===(t=t||10)||"hex"===t){e="";for(var n=0,h=0,o=0;o<this.length;o++){var s=this.words[o],u=(16777215&(s<<n|h)).toString(16);h=s>>>24-n&16777215,(n+=2)>=26&&(n-=26,o--),e=0!==h||o!==this.length-1?m[6-u.length]+u+e:u+e}for(0!==h&&(e=h.toString(16)+e);e.length%i!=0;)e="0"+e;return 0!==this.negative&&(e="-"+e),e}if(t===(0|t)&&t>=2&&t<=36){var a=f[t],l=d[t];e="";var p=this.clone();for(p.negative=0;!p.isZero();){var g=p.modrn(l).toString(t);e=(p=p.idivn(l)).isZero()?g+e:m[a-g.length]+g+e}for(this.isZero()&&(e="0"+e);e.length%i!=0;)e="0"+e;return 0!==this.negative&&(e="-"+e),e}r(!1,"Base should be between 2 and 36")},n.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&&r(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},n.prototype.toJSON=function(){return this.toString(16,2)},h&&(n.prototype.toBuffer=function(t,i){return this.toArrayLike(h,t,i)}),n.prototype.toArray=function(t,i){return this.toArrayLike(Array,t,i)},n.prototype.toArrayLike=function(t,i,e){this._strip();var n=this.byteLength(),h=e||Math.max(1,n);r(n<=h,"byte array longer than desired length"),r(h>0,"Requested array length <= 0");var o=function(t,i){return t.allocUnsafe?t.allocUnsafe(i):new t(i)}(t,h);return this["_toArrayLike"+("le"===i?"LE":"BE")](o,n),o},n.prototype._toArrayLikeLE=function(t,i){for(var r=0,e=0,n=0,h=0;n<this.length;n++){var o=this.words[n]<<h|e;t[r++]=255&o,r<t.length&&(t[r++]=o>>8&255),r<t.length&&(t[r++]=o>>16&255),6===h?(r<t.length&&(t[r++]=o>>24&255),e=0,h=0):(e=o>>>24,h+=2)}if(r<t.length)for(t[r++]=e;r<t.length;)t[r++]=0},n.prototype._toArrayLikeBE=function(t,i){for(var r=t.length-1,e=0,n=0,h=0;n<this.length;n++){var o=this.words[n]<<h|e;t[r--]=255&o,r>=0&&(t[r--]=o>>8&255),r>=0&&(t[r--]=o>>16&255),6===h?(r>=0&&(t[r--]=o>>24&255),e=0,h=0):(e=o>>>24,h+=2)}if(r>=0)for(t[r--]=e;r>=0;)t[r--]=0},Math.clz32?n.prototype._countBits=function(t){return 32-Math.clz32(t)}:n.prototype._countBits=function(t){var i=t,r=0;return i>=4096&&(r+=13,i>>>=13),i>=64&&(r+=7,i>>>=7),i>=8&&(r+=4,i>>>=4),i>=2&&(r+=2,i>>>=2),r+i},n.prototype._zeroBits=function(t){if(0===t)return 26;var i=t,r=0;return 0==(8191&i)&&(r+=13,i>>>=13),0==(127&i)&&(r+=7,i>>>=7),0==(15&i)&&(r+=4,i>>>=4),0==(3&i)&&(r+=2,i>>>=2),0==(1&i)&&r++,r},n.prototype.bitLength=function(){var t=this.words[this.length-1],i=this._countBits(t);return 26*(this.length-1)+i},n.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,i=0;i<this.length;i++){var r=this._zeroBits(this.words[i]);if(t+=r,26!==r)break}return t},n.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},n.prototype.toTwos=function(t){return 0!==this.negative?this.abs().inotn(t).iaddn(1):this.clone()},n.prototype.fromTwos=function(t){return this.testn(t-1)?this.notn(t).iaddn(1).ineg():this.clone()},n.prototype.isNeg=function(){return 0!==this.negative},n.prototype.neg=function(){return this.clone().ineg()},n.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},n.prototype.iuor=function(t){for(;this.length<t.length;)this.words[this.length++]=0;for(var i=0;i<t.length;i++)this.words[i]=this.words[i]|t.words[i];return this._strip()},n.prototype.ior=function(t){return r(0==(this.negative|t.negative)),this.iuor(t)},n.prototype.or=function(t){return this.length>t.length?this.clone().ior(t):t.clone().ior(this)},n.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},n.prototype.iuand=function(t){var i;i=this.length>t.length?t:this;for(var r=0;r<i.length;r++)this.words[r]=this.words[r]&t.words[r];return this.length=i.length,this._strip()},n.prototype.iand=function(t){return r(0==(this.negative|t.negative)),this.iuand(t)},n.prototype.and=function(t){return this.length>t.length?this.clone().iand(t):t.clone().iand(this)},n.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},n.prototype.iuxor=function(t){var i,r;this.length>t.length?(i=this,r=t):(i=t,r=this);for(var e=0;e<r.length;e++)this.words[e]=i.words[e]^r.words[e];if(this!==i)for(;e<i.length;e++)this.words[e]=i.words[e];return this.length=i.length,this._strip()},n.prototype.ixor=function(t){return r(0==(this.negative|t.negative)),this.iuxor(t)},n.prototype.xor=function(t){return this.length>t.length?this.clone().ixor(t):t.clone().ixor(this)},n.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},n.prototype.inotn=function(t){r("number"==typeof t&&t>=0);var i=0|Math.ceil(t/26),e=t%26;this._expand(i),e>0&&i--;for(var n=0;n<i;n++)this.words[n]=67108863&~this.words[n];return e>0&&(this.words[n]=~this.words[n]&67108863>>26-e),this._strip()},n.prototype.notn=function(t){return this.clone().inotn(t)},n.prototype.setn=function(t,i){r("number"==typeof t&&t>=0);var e=t/26|0,n=t%26;return this._expand(e+1),this.words[e]=i?this.words[e]|1<<n:this.words[e]&~(1<<n),this._strip()},n.prototype.iadd=function(t){var i,r,e;if(0!==this.negative&&0===t.negative)return this.negative=0,i=this.isub(t),this.negative^=1,this._normSign();if(0===this.negative&&0!==t.negative)return t.negative=0,i=this.isub(t),t.negative=1,i._normSign();this.length>t.length?(r=this,e=t):(r=t,e=this);for(var n=0,h=0;h<e.length;h++)i=(0|r.words[h])+(0|e.words[h])+n,this.words[h]=67108863&i,n=i>>>26;for(;0!==n&&h<r.length;h++)i=(0|r.words[h])+n,this.words[h]=67108863&i,n=i>>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;h<r.length;h++)this.words[h]=r.words[h];return this},n.prototype.add=function(t){var i;return 0!==t.negative&&0===this.negative?(t.negative=0,i=this.sub(t),t.negative^=1,i):0===t.negative&&0!==this.negative?(this.negative=0,i=t.sub(this),this.negative=1,i):this.length>t.length?this.clone().iadd(t):t.clone().iadd(this)},n.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var i=this.iadd(t);return t.negative=1,i._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,e,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,e=t):(r=t,e=this);for(var h=0,o=0;o<e.length;o++)h=(i=(0|r.words[o])-(0|e.words[o])+h)>>26,this.words[o]=67108863&i;for(;0!==h&&o<r.length;o++)h=(i=(0|r.words[o])+h)>>26,this.words[o]=67108863&i;if(0===h&&o<r.length&&r!==this)for(;o<r.length;o++)this.words[o]=r.words[o];return this.length=Math.max(this.length,o),r!==this&&(this.negative=1),this._strip()},n.prototype.sub=function(t){return this.clone().isub(t)};var g=function(t,i,r){var e,n,h,o=t.words,s=i.words,u=r.words,a=0,l=0|o[0],m=8191&l,f=l>>>13,d=0|o[1],p=8191&d,g=d>>>13,c=0|o[2],M=8191&c,v=c>>>13,w=0|o[3],y=8191&w,b=w>>>13,E=0|o[4],N=8191&E,_=E>>>13,R=0|o[5],S=8191&R,A=R>>>13,I=0|o[6],T=8191&I,O=I>>>13,U=0|o[7],C=8191&U,k=U>>>13,x=0|o[8],L=8191&x,P=x>>>13,D=0|o[9],B=8191&D,F=D>>>13,G=0|s[0],q=8191&G,Z=G>>>13,z=0|s[1],j=8191&z,X=z>>>13,K=0|s[2],V=8191&K,W=K>>>13,H=0|s[3],J=8191&H,$=H>>>13,Q=0|s[4],Y=8191&Q,tt=Q>>>13,it=0|s[5],rt=8191&it,et=it>>>13,nt=0|s[6],ht=8191&nt,ot=nt>>>13,st=0|s[7],ut=8191&st,at=st>>>13,lt=0|s[8],mt=8191&lt,ft=lt>>>13,dt=0|s[9],pt=8191&dt,gt=dt>>>13;r.negative=t.negative^i.negative,r.length=19;var ct=(a+(e=Math.imul(m,q))|0)+((8191&(n=(n=Math.imul(m,Z))+Math.imul(f,q)|0))<<13)|0;a=((h=Math.imul(f,Z))+(n>>>13)|0)+(ct>>>26)|0,ct&=67108863,e=Math.imul(p,q),n=(n=Math.imul(p,Z))+Math.imul(g,q)|0,h=Math.imul(g,Z);var Mt=(a+(e=e+Math.imul(m,j)|0)|0)+((8191&(n=(n=n+Math.imul(m,X)|0)+Math.imul(f,j)|0))<<13)|0;a=((h=h+Math.imul(f,X)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,e=Math.imul(M,q),n=(n=Math.imul(M,Z))+Math.imul(v,q)|0,h=Math.imul(v,Z),e=e+Math.imul(p,j)|0,n=(n=n+Math.imul(p,X)|0)+Math.imul(g,j)|0,h=h+Math.imul(g,X)|0;var vt=(a+(e=e+Math.imul(m,V)|0)|0)+((8191&(n=(n=n+Math.imul(m,W)|0)+Math.imul(f,V)|0))<<13)|0;a=((h=h+Math.imul(f,W)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,e=Math.imul(y,q),n=(n=Math.imul(y,Z))+Math.imul(b,q)|0,h=Math.imul(b,Z),e=e+Math.imul(M,j)|0,n=(n=n+Math.imul(M,X)|0)+Math.imul(v,j)|0,h=h+Math.imul(v,X)|0,e=e+Math.imul(p,V)|0,n=(n=n+Math.imul(p,W)|0)+Math.imul(g,V)|0,h=h+Math.imul(g,W)|0;var wt=(a+(e=e+Math.imul(m,J)|0)|0)+((8191&(n=(n=n+Math.imul(m,$)|0)+Math.imul(f,J)|0))<<13)|0;a=((h=h+Math.imul(f,$)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,e=Math.imul(N,q),n=(n=Math.imul(N,Z))+Math.imul(_,q)|0,h=Math.imul(_,Z),e=e+Math.imul(y,j)|0,n=(n=n+Math.imul(y,X)|0)+Math.imul(b,j)|0,h=h+Math.imul(b,X)|0,e=e+Math.imul(M,V)|0,n=(n=n+Math.imul(M,W)|0)+Math.imul(v,V)|0,h=h+Math.imul(v,W)|0,e=e+Math.imul(p,J)|0,n=(n=n+Math.imul(p,$)|0)+Math.imul(g,J)|0,h=h+Math.imul(g,$)|0;var yt=(a+(e=e+Math.imul(m,Y)|0)|0)+((8191&(n=(n=n+Math.imul(m,tt)|0)+Math.imul(f,Y)|0))<<13)|0;a=((h=h+Math.imul(f,tt)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,e=Math.imul(S,q),n=(n=Math.imul(S,Z))+Math.imul(A,q)|0,h=Math.imul(A,Z),e=e+Math.imul(N,j)|0,n=(n=n+Math.imul(N,X)|0)+Math.imul(_,j)|0,h=h+Math.imul(_,X)|0,e=e+Math.imul(y,V)|0,n=(n=n+Math.imul(y,W)|0)+Math.imul(b,V)|0,h=h+Math.imul(b,W)|0,e=e+Math.imul(M,J)|0,n=(n=n+Math.imul(M,$)|0)+Math.imul(v,J)|0,h=h+Math.imul(v,$)|0,e=e+Math.imul(p,Y)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(g,Y)|0,h=h+Math.imul(g,tt)|0;var bt=(a+(e=e+Math.imul(m,rt)|0)|0)+((8191&(n=(n=n+Math.imul(m,et)|0)+Math.imul(f,rt)|0))<<13)|0;a=((h=h+Math.imul(f,et)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,e=Math.imul(T,q),n=(n=Math.imul(T,Z))+Math.imul(O,q)|0,h=Math.imul(O,Z),e=e+Math.imul(S,j)|0,n=(n=n+Math.imul(S,X)|0)+Math.imul(A,j)|0,h=h+Math.imul(A,X)|0,e=e+Math.imul(N,V)|0,n=(n=n+Math.imul(N,W)|0)+Math.imul(_,V)|0,h=h+Math.imul(_,W)|0,e=e+Math.imul(y,J)|0,n=(n=n+Math.imul(y,$)|0)+Math.imul(b,J)|0,h=h+Math.imul(b,$)|0,e=e+Math.imul(M,Y)|0,n=(n=n+Math.imul(M,tt)|0)+Math.imul(v,Y)|0,h=h+Math.imul(v,tt)|0,e=e+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,et)|0)+Math.imul(g,rt)|0,h=h+Math.imul(g,et)|0;var Et=(a+(e=e+Math.imul(m,ht)|0)|0)+((8191&(n=(n=n+Math.imul(m,ot)|0)+Math.imul(f,ht)|0))<<13)|0;a=((h=h+Math.imul(f,ot)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,e=Math.imul(C,q),n=(n=Math.imul(C,Z))+Math.imul(k,q)|0,h=Math.imul(k,Z),e=e+Math.imul(T,j)|0,n=(n=n+Math.imul(T,X)|0)+Math.imul(O,j)|0,h=h+Math.imul(O,X)|0,e=e+Math.imul(S,V)|0,n=(n=n+Math.imul(S,W)|0)+Math.imul(A,V)|0,h=h+Math.imul(A,W)|0,e=e+Math.imul(N,J)|0,n=(n=n+Math.imul(N,$)|0)+Math.imul(_,J)|0,h=h+Math.imul(_,$)|0,e=e+Math.imul(y,Y)|0,n=(n=n+Math.imul(y,tt)|0)+Math.imul(b,Y)|0,h=h+Math.imul(b,tt)|0,e=e+Math.imul(M,rt)|0,n=(n=n+Math.imul(M,et)|0)+Math.imul(v,rt)|0,h=h+Math.imul(v,et)|0,e=e+Math.imul(p,ht)|0,n=(n=n+Math.imul(p,ot)|0)+Math.imul(g,ht)|0,h=h+Math.imul(g,ot)|0;var Nt=(a+(e=e+Math.imul(m,ut)|0)|0)+((8191&(n=(n=n+Math.imul(m,at)|0)+Math.imul(f,ut)|0))<<13)|0;a=((h=h+Math.imul(f,at)|0)+(n>>>13)|0)+(Nt>>>26)|0,Nt&=67108863,e=Math.imul(L,q),n=(n=Math.imul(L,Z))+Math.imul(P,q)|0,h=Math.imul(P,Z),e=e+Math.imul(C,j)|0,n=(n=n+Math.imul(C,X)|0)+Math.imul(k,j)|0,h=h+Math.imul(k,X)|0,e=e+Math.imul(T,V)|0,n=(n=n+Math.imul(T,W)|0)+Math.imul(O,V)|0,h=h+Math.imul(O,W)|0,e=e+Math.imul(S,J)|0,n=(n=n+Math.imul(S,$)|0)+Math.imul(A,J)|0,h=h+Math.imul(A,$)|0,e=e+Math.imul(N,Y)|0,n=(n=n+Math.imul(N,tt)|0)+Math.imul(_,Y)|0,h=h+Math.imul(_,tt)|0,e=e+Math.imul(y,rt)|0,n=(n=n+Math.imul(y,et)|0)+Math.imul(b,rt)|0,h=h+Math.imul(b,et)|0,e=e+Math.imul(M,ht)|0,n=(n=n+Math.imul(M,ot)|0)+Math.imul(v,ht)|0,h=h+Math.imul(v,ot)|0,e=e+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(g,ut)|0,h=h+Math.imul(g,at)|0;var _t=(a+(e=e+Math.imul(m,mt)|0)|0)+((8191&(n=(n=n+Math.imul(m,ft)|0)+Math.imul(f,mt)|0))<<13)|0;a=((h=h+Math.imul(f,ft)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,e=Math.imul(B,q),n=(n=Math.imul(B,Z))+Math.imul(F,q)|0,h=Math.imul(F,Z),e=e+Math.imul(L,j)|0,n=(n=n+Math.imul(L,X)|0)+Math.imul(P,j)|0,h=h+Math.imul(P,X)|0,e=e+Math.imul(C,V)|0,n=(n=n+Math.imul(C,W)|0)+Math.imul(k,V)|0,h=h+Math.imul(k,W)|0,e=e+Math.imul(T,J)|0,n=(n=n+Math.imul(T,$)|0)+Math.imul(O,J)|0,h=h+Math.imul(O,$)|0,e=e+Math.imul(S,Y)|0,n=(n=n+Math.imul(S,tt)|0)+Math.imul(A,Y)|0,h=h+Math.imul(A,tt)|0,e=e+Math.imul(N,rt)|0,n=(n=n+Math.imul(N,et)|0)+Math.imul(_,rt)|0,h=h+Math.imul(_,et)|0,e=e+Math.imul(y,ht)|0,n=(n=n+Math.imul(y,ot)|0)+Math.imul(b,ht)|0,h=h+Math.imul(b,ot)|0,e=e+Math.imul(M,ut)|0,n=(n=n+Math.imul(M,at)|0)+Math.imul(v,ut)|0,h=h+Math.imul(v,at)|0,e=e+Math.imul(p,mt)|0,n=(n=n+Math.imul(p,ft)|0)+Math.imul(g,mt)|0,h=h+Math.imul(g,ft)|0;var Rt=(a+(e=e+Math.imul(m,pt)|0)|0)+((8191&(n=(n=n+Math.imul(m,gt)|0)+Math.imul(f,pt)|0))<<13)|0;a=((h=h+Math.imul(f,gt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863,e=Math.imul(B,j),n=(n=Math.imul(B,X))+Math.imul(F,j)|0,h=Math.imul(F,X),e=e+Math.imul(L,V)|0,n=(n=n+Math.imul(L,W)|0)+Math.imul(P,V)|0,h=h+Math.imul(P,W)|0,e=e+Math.imul(C,J)|0,n=(n=n+Math.imul(C,$)|0)+Math.imul(k,J)|0,h=h+Math.imul(k,$)|0,e=e+Math.imul(T,Y)|0,n=(n=n+Math.imul(T,tt)|0)+Math.imul(O,Y)|0,h=h+Math.imul(O,tt)|0,e=e+Math.imul(S,rt)|0,n=(n=n+Math.imul(S,et)|0)+Math.imul(A,rt)|0,h=h+Math.imul(A,et)|0,e=e+Math.imul(N,ht)|0,n=(n=n+Math.imul(N,ot)|0)+Math.imul(_,ht)|0,h=h+Math.imul(_,ot)|0,e=e+Math.imul(y,ut)|0,n=(n=n+Math.imul(y,at)|0)+Math.imul(b,ut)|0,h=h+Math.imul(b,at)|0,e=e+Math.imul(M,mt)|0,n=(n=n+Math.imul(M,ft)|0)+Math.imul(v,mt)|0,h=h+Math.imul(v,ft)|0;var St=(a+(e=e+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,gt)|0)+Math.imul(g,pt)|0))<<13)|0;a=((h=h+Math.imul(g,gt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,e=Math.imul(B,V),n=(n=Math.imul(B,W))+Math.imul(F,V)|0,h=Math.imul(F,W),e=e+Math.imul(L,J)|0,n=(n=n+Math.imul(L,$)|0)+Math.imul(P,J)|0,h=h+Math.imul(P,$)|0,e=e+Math.imul(C,Y)|0,n=(n=n+Math.imul(C,tt)|0)+Math.imul(k,Y)|0,h=h+Math.imul(k,tt)|0,e=e+Math.imul(T,rt)|0,n=(n=n+Math.imul(T,et)|0)+Math.imul(O,rt)|0,h=h+Math.imul(O,et)|0,e=e+Math.imul(S,ht)|0,n=(n=n+Math.imul(S,ot)|0)+Math.imul(A,ht)|0,h=h+Math.imul(A,ot)|0,e=e+Math.imul(N,ut)|0,n=(n=n+Math.imul(N,at)|0)+Math.imul(_,ut)|0,h=h+Math.imul(_,at)|0,e=e+Math.imul(y,mt)|0,n=(n=n+Math.imul(y,ft)|0)+Math.imul(b,mt)|0,h=h+Math.imul(b,ft)|0;var At=(a+(e=e+Math.imul(M,pt)|0)|0)+((8191&(n=(n=n+Math.imul(M,gt)|0)+Math.imul(v,pt)|0))<<13)|0;a=((h=h+Math.imul(v,gt)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,e=Math.imul(B,J),n=(n=Math.imul(B,$))+Math.imul(F,J)|0,h=Math.imul(F,$),e=e+Math.imul(L,Y)|0,n=(n=n+Math.imul(L,tt)|0)+Math.imul(P,Y)|0,h=h+Math.imul(P,tt)|0,e=e+Math.imul(C,rt)|0,n=(n=n+Math.imul(C,et)|0)+Math.imul(k,rt)|0,h=h+Math.imul(k,et)|0,e=e+Math.imul(T,ht)|0,n=(n=n+Math.imul(T,ot)|0)+Math.imul(O,ht)|0,h=h+Math.imul(O,ot)|0,e=e+Math.imul(S,ut)|0,n=(n=n+Math.imul(S,at)|0)+Math.imul(A,ut)|0,h=h+Math.imul(A,at)|0,e=e+Math.imul(N,mt)|0,n=(n=n+Math.imul(N,ft)|0)+Math.imul(_,mt)|0,h=h+Math.imul(_,ft)|0;var It=(a+(e=e+Math.imul(y,pt)|0)|0)+((8191&(n=(n=n+Math.imul(y,gt)|0)+Math.imul(b,pt)|0))<<13)|0;a=((h=h+Math.imul(b,gt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,e=Math.imul(B,Y),n=(n=Math.imul(B,tt))+Math.imul(F,Y)|0,h=Math.imul(F,tt),e=e+Math.imul(L,rt)|0,n=(n=n+Math.imul(L,et)|0)+Math.imul(P,rt)|0,h=h+Math.imul(P,et)|0,e=e+Math.imul(C,ht)|0,n=(n=n+Math.imul(C,ot)|0)+Math.imul(k,ht)|0,h=h+Math.imul(k,ot)|0,e=e+Math.imul(T,ut)|0,n=(n=n+Math.imul(T,at)|0)+Math.imul(O,ut)|0,h=h+Math.imul(O,at)|0,e=e+Math.imul(S,mt)|0,n=(n=n+Math.imul(S,ft)|0)+Math.imul(A,mt)|0,h=h+Math.imul(A,ft)|0;var Tt=(a+(e=e+Math.imul(N,pt)|0)|0)+((8191&(n=(n=n+Math.imul(N,gt)|0)+Math.imul(_,pt)|0))<<13)|0;a=((h=h+Math.imul(_,gt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,e=Math.imul(B,rt),n=(n=Math.imul(B,et))+Math.imul(F,rt)|0,h=Math.imul(F,et),e=e+Math.imul(L,ht)|0,n=(n=n+Math.imul(L,ot)|0)+Math.imul(P,ht)|0,h=h+Math.imul(P,ot)|0,e=e+Math.imul(C,ut)|0,n=(n=n+Math.imul(C,at)|0)+Math.imul(k,ut)|0,h=h+Math.imul(k,at)|0,e=e+Math.imul(T,mt)|0,n=(n=n+Math.imul(T,ft)|0)+Math.imul(O,mt)|0,h=h+Math.imul(O,ft)|0;var Ot=(a+(e=e+Math.imul(S,pt)|0)|0)+((8191&(n=(n=n+Math.imul(S,gt)|0)+Math.imul(A,pt)|0))<<13)|0;a=((h=h+Math.imul(A,gt)|0)+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,e=Math.imul(B,ht),n=(n=Math.imul(B,ot))+Math.imul(F,ht)|0,h=Math.imul(F,ot),e=e+Math.imul(L,ut)|0,n=(n=n+Math.imul(L,at)|0)+Math.imul(P,ut)|0,h=h+Math.imul(P,at)|0,e=e+Math.imul(C,mt)|0,n=(n=n+Math.imul(C,ft)|0)+Math.imul(k,mt)|0,h=h+Math.imul(k,ft)|0;var Ut=(a+(e=e+Math.imul(T,pt)|0)|0)+((8191&(n=(n=n+Math.imul(T,gt)|0)+Math.imul(O,pt)|0))<<13)|0;a=((h=h+Math.imul(O,gt)|0)+(n>>>13)|0)+(Ut>>>26)|0,Ut&=67108863,e=Math.imul(B,ut),n=(n=Math.imul(B,at))+Math.imul(F,ut)|0,h=Math.imul(F,at),e=e+Math.imul(L,mt)|0,n=(n=n+Math.imul(L,ft)|0)+Math.imul(P,mt)|0,h=h+Math.imul(P,ft)|0;var Ct=(a+(e=e+Math.imul(C,pt)|0)|0)+((8191&(n=(n=n+Math.imul(C,gt)|0)+Math.imul(k,pt)|0))<<13)|0;a=((h=h+Math.imul(k,gt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,e=Math.imul(B,mt),n=(n=Math.imul(B,ft))+Math.imul(F,mt)|0,h=Math.imul(F,ft);var kt=(a+(e=e+Math.imul(L,pt)|0)|0)+((8191&(n=(n=n+Math.imul(L,gt)|0)+Math.imul(P,pt)|0))<<13)|0;a=((h=h+Math.imul(P,gt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863;var xt=(a+(e=Math.imul(B,pt))|0)+((8191&(n=(n=Math.imul(B,gt))+Math.imul(F,pt)|0))<<13)|0;return a=((h=Math.imul(F,gt))+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,u[0]=ct,u[1]=Mt,u[2]=vt,u[3]=wt,u[4]=yt,u[5]=bt,u[6]=Et,u[7]=Nt,u[8]=_t,u[9]=Rt,u[10]=St,u[11]=At,u[12]=It,u[13]=Tt,u[14]=Ot,u[15]=Ut,u[16]=Ct,u[17]=kt,u[18]=xt,0!==a&&(u[19]=a,r.length++),r};function c(t,i,r){r.negative=i.negative^t.negative,r.length=t.length+i.length;for(var e=0,n=0,h=0;h<r.length-1;h++){var o=n;n=0;for(var s=67108863&e,u=Math.min(h,i.length-1),a=Math.max(0,h-t.length+1);a<=u;a++){var l=h-a,m=(0|t.words[l])*(0|i.words[a]),f=67108863&m;s=67108863&(f=f+s|0),n+=(o=(o=o+(m/67108864|0)|0)+(f>>>26)|0)>>>26,o&=67108863}r.words[h]=s,e=o,o=n}return 0!==e?r.words[h]=e:r.length--,r._strip()}function M(t,i,r){return c(t,i,r)}Math.imul||(g=p),n.prototype.mulTo=function(t,i){var r=this.length+t.length;return 10===this.length&&10===t.length?g(this,t,i):r<63?p(this,t,i):r<1024?c(this,t,i):M(this,t,i)},n.prototype.mul=function(t){var i=new n(null);return i.words=new Array(this.length+t.length),this.mulTo(t,i)},n.prototype.mulf=function(t){var i=new n(null);return i.words=new Array(this.length+t.length),M(this,t,i)},n.prototype.imul=function(t){return this.clone().mulTo(t,this)},n.prototype.imuln=function(t){var i=t<0;i&&(t=-t),r("number"==typeof t),r(t<67108864);for(var e=0,n=0;n<this.length;n++){var h=(0|this.words[n])*t,o=(67108863&h)+(67108863&e);e>>=26,e+=h/67108864|0,e+=o>>>26,this.words[n]=67108863&o}return 0!==e&&(this.words[n]=e,this.length++),i?this.ineg():this},n.prototype.muln=function(t){return this.clone().imuln(t)},n.prototype.sqr=function(){return this.mul(this)},n.prototype.isqr=function(){return this.imul(this.clone())},n.prototype.pow=function(t){var i=function(t){for(var i=new Array(t.bitLength()),r=0;r<i.length;r++){var e=r/26|0,n=r%26;i[r]=t.words[e]>>>n&1}return i}(t);if(0===i.length)return new n(1);for(var r=this,e=0;e<i.length&&0===i[e];e++,r=r.sqr());if(++e<i.length)for(var h=r.sqr();e<i.length;e++,h=h.sqr())0!==i[e]&&(r=r.mul(h));return r},n.prototype.iushln=function(t){r("number"==typeof t&&t>=0);var i,e=t%26,n=(t-e)/26,h=67108863>>>26-e<<26-e;if(0!==e){var o=0;for(i=0;i<this.length;i++){var s=this.words[i]&h,u=(0|this.words[i])-s<<e;this.words[i]=u|o,o=s>>>26-e}o&&(this.words[i]=o,this.length++)}if(0!==n){for(i=this.length-1;i>=0;i--)this.words[i+n]=this.words[i];for(i=0;i<n;i++)this.words[i]=0;this.length+=n}return this._strip()},n.prototype.ishln=function(t){return r(0===this.negative),this.iushln(t)},n.prototype.iushrn=function(t,i,e){var n;r("number"==typeof t&&t>=0),n=i?(i-i%26)/26:0;var h=t%26,o=Math.min((t-h)/26,this.length),s=67108863^67108863>>>h<<h,u=e;if(n-=o,n=Math.max(0,n),u){for(var a=0;a<o;a++)u.words[a]=this.words[a];u.length=o}if(0===o);else if(this.length>o)for(this.length-=o,a=0;a<this.length;a++)this.words[a]=this.words[a+o];else this.words[0]=0,this.length=1;var l=0;for(a=this.length-1;a>=0&&(0!==l||a>=n);a--){var m=0|this.words[a];this.words[a]=l<<26-h|m>>>h,l=m&s}return u&&0!==l&&(u.words[u.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},n.prototype.ishrn=function(t,i,e){return r(0===this.negative),this.iushrn(t,i,e)},n.prototype.shln=function(t){return this.clone().ishln(t)},n.prototype.ushln=function(t){return this.clone().iushln(t)},n.prototype.shrn=function(t){return this.clone().ishrn(t)},n.prototype.ushrn=function(t){return this.clone().iushrn(t)},n.prototype.testn=function(t){r("number"==typeof t&&t>=0);var i=t%26,e=(t-i)/26,n=1<<i;return!(this.length<=e||!(this.words[e]&n))},n.prototype.imaskn=function(t){r("number"==typeof t&&t>=0);var i=t%26,e=(t-i)/26;if(r(0===this.negative,"imaskn works only with positive numbers"),this.length<=e)return this;if(0!==i&&e++,this.length=Math.min(e,this.length),0!==i){var n=67108863^67108863>>>i<<i;this.words[this.length-1]&=n}return this._strip()},n.prototype.maskn=function(t){return this.clone().imaskn(t)},n.prototype.iaddn=function(t){return r("number"==typeof t),r(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)},n.prototype._iaddn=function(t){this.words[0]+=t;for(var i=0;i<this.length&&this.words[i]>=67108864;i++)this.words[i]-=67108864,i===this.length-1?this.words[i+1]=1:this.words[i+1]++;return this.length=Math.max(this.length,i+1),this},n.prototype.isubn=function(t){if(r("number"==typeof t),r(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 i=0;i<this.length&&this.words[i]<0;i++)this.words[i]+=67108864,this.words[i+1]-=1;return this._strip()},n.prototype.addn=function(t){return this.clone().iaddn(t)},n.prototype.subn=function(t){return this.clone().isubn(t)},n.prototype.iabs=function(){return this.negative=0,this},n.prototype.abs=function(){return this.clone().iabs()},n.prototype._ishlnsubmul=function(t,i,e){var n,h,o=t.length+e;this._expand(o);var s=0;for(n=0;n<t.length;n++){h=(0|this.words[n+e])+s;var u=(0|t.words[n])*i;s=((h-=67108863&u)>>26)-(u/67108864|0),this.words[n+e]=67108863&h}for(;n<this.length-e;n++)s=(h=(0|this.words[n+e])+s)>>26,this.words[n+e]=67108863&h;if(0===s)return this._strip();for(r(-1===s),s=0,n=0;n<this.length;n++)s=(h=-(0|this.words[n])+s)>>26,this.words[n]=67108863&h;return this.negative=1,this._strip()},n.prototype._wordDiv=function(t,i){var r=(this.length,t.length),e=this.clone(),h=t,o=0|h.words[h.length-1];0!=(r=26-this._countBits(o))&&(h=h.ushln(r),e.iushln(r),o=0|h.words[h.length-1]);var s,u=e.length-h.length;if("mod"!==i){(s=new n(null)).length=u+1,s.words=new Array(s.length);for(var a=0;a<s.length;a++)s.words[a]=0}var l=e.clone()._ishlnsubmul(h,1,u);0===l.negative&&(e=l,s&&(s.words[u]=1));for(var m=u-1;m>=0;m--){var f=67108864*(0|e.words[h.length+m])+(0|e.words[h.length+m-1]);for(f=Math.min(f/o|0,67108863),e._ishlnsubmul(h,f,m);0!==e.negative;)f--,e.negative=0,e._ishlnsubmul(h,1,m),e.isZero()||(e.negative^=1);s&&(s.words[m]=f)}return s&&s._strip(),e._strip(),"div"!==i&&0!==r&&e.iushrn(r),{div:s||null,mod:e}},n.prototype.divmod=function(t,i,e){return r(!t.isZero()),this.isZero()?{div:new n(0),mod:new n(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,i),"mod"!==i&&(h=s.div.neg()),"div"!==i&&(o=s.mod.neg(),e&&0!==o.negative&&o.iadd(t)),{div:h,mod:o}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),i),"mod"!==i&&(h=s.div.neg()),{div:h,mod:s.mod}):0!=(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),i),"div"!==i&&(o=s.mod.neg(),e&&0!==o.negative&&o.isub(t)),{div:s.div,mod:o}):t.length>this.length||this.cmp(t)<0?{div:new n(0),mod:this}:1===t.length?"div"===i?{div:this.divn(t.words[0]),mod:null}:"mod"===i?{div:null,mod:new n(this.modrn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new n(this.modrn(t.words[0]))}:this._wordDiv(t,i);var h,o,s},n.prototype.div=function(t){return this.divmod(t,"div",!1).div},n.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},n.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},n.prototype.divRound=function(t){var i=this.divmod(t);if(i.mod.isZero())return i.div;var r=0!==i.div.negative?i.mod.isub(t):i.mod,e=t.ushrn(1),n=t.andln(1),h=r.cmp(e);return h<0||1===n&&0===h?i.div:0!==i.div.negative?i.div.isubn(1):i.div.iaddn(1)},n.prototype.modrn=function(t){var i=t<0;i&&(t=-t),r(t<=67108863);for(var e=(1<<26)%t,n=0,h=this.length-1;h>=0;h--)n=(e*n+(0|this.words[h]))%t;return i?-n:n},n.prototype.modn=function(t){return this.modrn(t)},n.prototype.idivn=function(t){var i=t<0;i&&(t=-t),r(t<=67108863);for(var e=0,n=this.length-1;n>=0;n--){var h=(0|this.words[n])+67108864*e;this.words[n]=h/t|0,e=h%t}return this._strip(),i?this.ineg():this},n.prototype.divn=function(t){return this.clone().idivn(t)},n.prototype.egcd=function(t){r(0===t.negative),r(!t.isZero());var i=this,e=t.clone();i=0!==i.negative?i.umod(t):i.clone();for(var h=new n(1),o=new n(0),s=new n(0),u=new n(1),a=0;i.isEven()&&e.isEven();)i.iushrn(1),e.iushrn(1),++a;for(var l=e.clone(),m=i.clone();!i.isZero();){for(var f=0,d=1;0==(i.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(i.iushrn(f);f-- >0;)(h.isOdd()||o.isOdd())&&(h.iadd(l),o.isub(m)),h.iushrn(1),o.iushrn(1);for(var p=0,g=1;0==(e.words[0]&g)&&p<26;++p,g<<=1);if(p>0)for(e.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(l),u.isub(m)),s.iushrn(1),u.iushrn(1);i.cmp(e)>=0?(i.isub(e),h.isub(s),o.isub(u)):(e.isub(i),s.isub(h),u.isub(o))}return{a:s,b:u,gcd:e.iushln(a)}},n.prototype._invmp=function(t){r(0===t.negative),r(!t.isZero());var i=this,e=t.clone();i=0!==i.negative?i.umod(t):i.clone();for(var h,o=new n(1),s=new n(0),u=e.clone();i.cmpn(1)>0&&e.cmpn(1)>0;){for(var a=0,l=1;0==(i.words[0]&l)&&a<26;++a,l<<=1);if(a>0)for(i.iushrn(a);a-- >0;)o.isOdd()&&o.iadd(u),o.iushrn(1);for(var m=0,f=1;0==(e.words[0]&f)&&m<26;++m,f<<=1);if(m>0)for(e.iushrn(m);m-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);i.cmp(e)>=0?(i.isub(e),o.isub(s)):(e.isub(i),s.isub(o))}return(h=0===i.cmpn(1)?o:s).cmpn(0)<0&&h.iadd(t),h},n.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var i=this.clone(),r=t.clone();i.negative=0,r.negative=0;for(var e=0;i.isEven()&&r.isEven();e++)i.iushrn(1),r.iushrn(1);for(;;){for(;i.isEven();)i.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=i.cmp(r);if(n<0){var h=i;i=r,r=h}else if(0===n||0===r.cmpn(1))break;i.isub(r)}return r.iushln(e)},n.prototype.invm=function(t){return this.egcd(t).a.umod(t)},n.prototype.isEven=function(){return 0==(1&this.words[0])},n.prototype.isOdd=function(){return 1==(1&this.words[0])},n.prototype.andln=function(t){return this.words[0]&t},n.prototype.bincn=function(t){r("number"==typeof t);var i=t%26,e=(t-i)/26,n=1<<i;if(this.length<=e)return this._expand(e+1),this.words[e]|=n,this;for(var h=n,o=e;0!==h&&o<this.length;o++){var s=0|this.words[o];h=(s+=h)>>>26,s&=67108863,this.words[o]=s}return 0!==h&&(this.words[o]=h,this.length++),this},n.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},n.prototype.cmpn=function(t){var i,e=t<0;if(0!==this.negative&&!e)return-1;if(0===this.negative&&e)return 1;if(this._strip(),this.length>1)i=1;else{e&&(t=-t),r(t<=67108863,"Number is too big");var n=0|this.words[0];i=n===t?0:n<t?-1:1}return 0!==this.negative?0|-i:i},n.prototype.cmp=function(t){if(0!==this.negative&&0===t.negative)return-1;if(0===this.negative&&0!==t.negative)return 1;var i=this.ucmp(t);return 0!==this.negative?0|-i:i},n.prototype.ucmp=function(t){if(this.length>t.length)return 1;if(this.length<t.length)return-1;for(var i=0,r=this.length-1;r>=0;r--){var e=0|this.words[r],n=0|t.words[r];if(e!==n){e<n?i=-1:e>n&&(i=1);break}}return i},n.prototype.gtn=function(t){return 1===this.cmpn(t)},n.prototype.gt=function(t){return 1===this.cmp(t)},n.prototype.gten=function(t){return this.cmpn(t)>=0},n.prototype.gte=function(t){return this.cmp(t)>=0},n.prototype.ltn=function(t){return-1===this.cmpn(t)},n.prototype.lt=function(t){return-1===this.cmp(t)},n.prototype.lten=function(t){return this.cmpn(t)<=0},n.prototype.lte=function(t){return this.cmp(t)<=0},n.prototype.eqn=function(t){return 0===this.cmpn(t)},n.prototype.eq=function(t){return 0===this.cmp(t)},n.red=function(t){return new _(t)},n.prototype.toRed=function(t){return r(!this.red,"Already a number in reduction context"),r(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},n.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},n.prototype._forceRed=function(t){return this.red=t,this},n.prototype.forceRed=function(t){return r(!this.red,"Already a number in reduction context"),this._forceRed(t)},n.prototype.redAdd=function(t){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},n.prototype.redIAdd=function(t){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},n.prototype.redSub=function(t){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},n.prototype.redISub=function(t){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},n.prototype.redShl=function(t){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},n.prototype.redMul=function(t){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},n.prototype.redIMul=function(t){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},n.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},n.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},n.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},n.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},n.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},n.prototype.redPow=function(t){return r(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var v={k256:null,p224:null,p192:null,p25519:null};function w(t,i){this.name=t,this.p=new n(i,16),this.n=this.p.bitLength(),this.k=new n(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function y(){w.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function b(){w.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function E(){w.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function N(){w.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(t){if("string"==typeof t){var i=n._prime(t);this.m=i.p,this.prime=i}else r(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function R(t){_.call(this,t),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new n(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)}w.prototype._tmp=function(){var t=new n(null);return t.words=new Array(Math.ceil(this.n/13)),t},w.prototype.ireduce=function(t){var i,r=t;do{this.split(r,this.tmp),i=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(i>this.n);var e=i<this.n?-1:r.ucmp(this.p);return 0===e?(r.words[0]=0,r.length=1):e>0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},w.prototype.split=function(t,i){t.iushrn(this.n,0,i)},w.prototype.imulK=function(t){return t.imul(this.k)},e(y,w),y.prototype.split=function(t,i){for(var r=4194303,e=Math.min(t.length,9),n=0;n<e;n++)i.words[n]=t.words[n];if(i.length=e,t.length<=9)return t.words[0]=0,void(t.length=1);var h=t.words[9];for(i.words[i.length++]=h&r,n=10;n<t.length;n++){var o=0|t.words[n];t.words[n-10]=(o&r)<<4|h>>>22,h=o}h>>>=22,t.words[n-10]=h,0===h&&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 i=0,r=0;r<t.length;r++){var e=0|t.words[r];i+=977*e,t.words[r]=67108863&i,i=64*e+(i/67108864|0)}return 0===t.words[t.length-1]&&(t.length--,0===t.words[t.length-1]&&t.length--),t},e(b,w),e(E,w),e(N,w),N.prototype.imulK=function(t){for(var i=0,r=0;r<t.length;r++){var e=19*(0|t.words[r])+i,n=67108863&e;e>>>=26,t.words[r]=n,i=e}return 0!==i&&(t.words[t.length++]=i),t},n._prime=function(t){if(v[t])return v[t];var i;if("k256"===t)i=new y;else if("p224"===t)i=new b;else if("p192"===t)i=new E;else{if("p25519"!==t)throw new Error("Unknown prime "+t);i=new N}return v[t]=i,i},_.prototype._verify1=function(t){r(0===t.negative,"red works only with positives"),r(t.red,"red works only with red numbers")},_.prototype._verify2=function(t,i){r(0==(t.negative|i.negative),"red works only with positives"),r(t.red&&t.red===i.red,"red works only with red numbers")},_.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):(a(t,t.umod(this.m)._forceRed(this)),t)},_.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},_.prototype.add=function(t,i){this._verify2(t,i);var r=t.add(i);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(t,i){this._verify2(t,i);var r=t.iadd(i);return r.cmp(this.m)>=0&&r.isub(this.m),r},_.prototype.sub=function(t,i){this._verify2(t,i);var r=t.sub(i);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(t,i){this._verify2(t,i);var r=t.isub(i);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(t,i){return this._verify1(t),this.imod(t.ushln(i))},_.prototype.imul=function(t,i){return this._verify2(t,i),this.imod(t.imul(i))},_.prototype.mul=function(t,i){return this._verify2(t,i),this.imod(t.mul(i))},_.prototype.isqr=function(t){return this.imul(t,t.clone())},_.prototype.sqr=function(t){return this.mul(t,t)},_.prototype.sqrt=function(t){if(t.isZero())return t.clone();var i=this.m.andln(3);if(r(i%2==1),3===i){var e=this.m.add(new n(1)).iushrn(2);return this.pow(t,e)}for(var h=this.m.subn(1),o=0;!h.isZero()&&0===h.andln(1);)o++,h.iushrn(1);r(!h.isZero());var s=new n(1).toRed(this),u=s.redNeg(),a=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new n(2*l*l).toRed(this);0!==this.pow(l,a).cmp(u);)l.redIAdd(u);for(var m=this.pow(l,h),f=this.pow(t,h.addn(1).iushrn(1)),d=this.pow(t,h),p=o;0!==d.cmp(s);){for(var g=d,c=0;0!==g.cmp(s);c++)g=g.redSqr();r(c<p);var M=this.pow(m,new n(1).iushln(p-c-1));f=f.redMul(M),m=M.redSqr(),d=d.redMul(m),p=c}return f},_.prototype.invm=function(t){var i=t._invmp(this.m);return 0!==i.negative?(i.negative=0,this.imod(i).redNeg()):this.imod(i)},_.prototype.pow=function(t,i){if(i.isZero())return new n(1).toRed(this);if(0===i.cmpn(1))return t.clone();var r=new Array(16);r[0]=new n(1).toRed(this),r[1]=t;for(var e=2;e<r.length;e++)r[e]=this.mul(r[e-1],t);var h=r[0],o=0,s=0,u=i.bitLength()%26;for(0===u&&(u=26),e=i.length-1;e>=0;e--){for(var a=i.words[e],l=u-1;l>=0;l--){var m=a>>l&1;h!==r[0]&&(h=this.sqr(h)),0!==m||0!==o?(o<<=1,o|=m,(4==++s||0===e&&0===l)&&(h=this.mul(h,r[o]),s=0,o=0)):s=0}u=26}return h},_.prototype.convertTo=function(t){var i=t.umod(this.m);return i===t?i.clone():i},_.prototype.convertFrom=function(t){var i=t.clone();return i.red=null,i},n.mont=function(t){return new R(t)},e(R,_),R.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},R.prototype.convertFrom=function(t){var i=this.imod(t.mul(this.rinv));return i.red=null,i},R.prototype.imul=function(t,i){if(t.isZero()||i.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(i),e=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(e).iushrn(this.shift),h=n;return n.cmp(this.m)>=0?h=n.isub(this.m):n.cmpn(0)<0&&(h=n.iadd(this.m)),h._forceRed(this)},R.prototype.mul=function(t,i){if(t.isZero()||i.isZero())return new n(0)._forceRed(this);var r=t.mul(i),e=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),h=r.isub(e).iushrn(this.shift),o=h;return h.cmp(this.m)>=0?o=h.isub(this.m):h.cmpn(0)<0&&(o=h.iadd(this.m)),o._forceRed(this)},R.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(M,t);const v="bignumber/5.7.0";var w=M.exports.BN;const y=new g(v),b={},E=9007199254740991;function N(t){return null!=t&&(R.isBigNumber(t)||"number"==typeof t&&t%1==0||"string"==typeof t&&!!t.match(/^-?[0-9]+$/)||n(t)||"bigint"==typeof t||r(t))}let _=!1;class R{constructor(t,i){t!==b&&y.throwError("cannot call constructor directly; use BigNumber.from",g.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=i,this._isBigNumber=!0,Object.freeze(this)}fromTwos(t){return A(I(this).fromTwos(t))}toTwos(t){return A(I(this).toTwos(t))}abs(){return"-"===this._hex[0]?R.from(this._hex.substring(1)):this}add(t){return A(I(this).add(I(t)))}sub(t){return A(I(this).sub(I(t)))}div(t){return R.from(t).isZero()&&T("division-by-zero","div"),A(I(this).div(I(t)))}mul(t){return A(I(this).mul(I(t)))}mod(t){const i=I(t);return i.isNeg()&&T("division-by-zero","mod"),A(I(this).umod(i))}pow(t){const i=I(t);return i.isNeg()&&T("negative-power","pow"),A(I(this).pow(i))}and(t){const i=I(t);return(this.isNegative()||i.isNeg())&&T("unbound-bitwise-result","and"),A(I(this).and(i))}or(t){const i=I(t);return(this.isNegative()||i.isNeg())&&T("unbound-bitwise-result","or"),A(I(this).or(i))}xor(t){const i=I(t);return(this.isNegative()||i.isNeg())&&T("unbound-bitwise-result","xor"),A(I(this).xor(i))}mask(t){return(this.isNegative()||t<0)&&T("negative-width","mask"),A(I(this).maskn(t))}shl(t){return(this.isNegative()||t<0)&&T("negative-width","shl"),A(I(this).shln(t))}shr(t){return(this.isNegative()||t<0)&&T("negative-width","shr"),A(I(this).shrn(t))}eq(t){return I(this).eq(I(t))}lt(t){return I(this).lt(I(t))}lte(t){return I(this).lte(I(t))}gt(t){return I(this).gt(I(t))}gte(t){return I(this).gte(I(t))}isNegative(){return"-"===this._hex[0]}isZero(){return I(this).isZero()}toNumber(){try{return I(this).toNumber()}catch(t){T("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch(t){}return y.throwError("this platform does not support BigInt",g.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(10===arguments[0]?_||(_=!0,y.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?y.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",g.errors.UNEXPECTED_ARGUMENT,{}):y.throwError("BigNumber.toString does not accept parameters",g.errors.UNEXPECTED_ARGUMENT,{})),I(this).toString(10)}toHexString(){return this._hex}toJSON(t){return{type:"BigNumber",hex:this.toHexString()}}static from(t){if(t instanceof R)return t;if("string"==typeof t)return t.match(/^-?0x[0-9a-f]+$/i)?new R(b,S(t)):t.match(/^-?[0-9]+$/)?new R(b,S(new w(t))):y.throwArgumentError("invalid BigNumber string","value",t);if("number"==typeof t)return t%1&&T("underflow","BigNumber.from",t),(t>=E||t<=-E)&&T("overflow","BigNumber.from",t),R.from(String(t));const i=t;if("bigint"==typeof i)return R.from(i.toString());if(r(i))return R.from(e(i));if(i)if(i.toHexString){const t=i.toHexString();if("string"==typeof t)return R.from(t)}else{let t=i._hex;if(null==t&&"BigNumber"===i.type&&(t=i.hex),"string"==typeof t&&(n(t)||"-"===t[0]&&n(t.substring(1))))return R.from(t)}return y.throwArgumentError("invalid BigNumber value","value",t)}static isBigNumber(t){return!(!t||!t._isBigNumber)}}function S(t){if("string"!=typeof t)return S(t.toString(16));if("-"===t[0])return"-"===(t=t.substring(1))[0]&&y.throwArgumentError("invalid hex","value",t),"0x00"===(t=S(t))?t:"-"+t;if("0x"!==t.substring(0,2)&&(t="0x"+t),"0x"===t)return"0x00";for(t.length%2&&(t="0x0"+t.substring(2));t.length>4&&"0x00"===t.substring(0,4);)t="0x"+t.substring(4);return t}function A(t){return R.from(S(t))}function I(t){const i=R.from(t).toHexString();return"-"===i[0]?new w("-"+i.substring(3),16):new w(i.substring(2),16)}function T(t,i,r){const e={fault:t,operation:i};return null!=r&&(e.value=r),y.throwError(t,g.errors.NUMERIC_FAULT,e)}const O=new g("strings/5.7.0");var U,C;function k(t,i,r,e,n){if(t===C.BAD_PREFIX||t===C.UNEXPECTED_CONTINUE){let t=0;for(let e=i+1;e<r.length&&r[e]>>6==2;e++)t++;return t}return t===C.OVERRUN?r.length-i-1:0}!function(t){t.current="",t.NFC="NFC",t.NFD="NFD",t.NFKC="NFKC",t.NFKD="NFKD"}(U||(U={})),function(t){t.UNEXPECTED_CONTINUE="unexpected continuation byte",t.BAD_PREFIX="bad codepoint prefix",t.OVERRUN="string overrun",t.MISSING_CONTINUE="missing continuation byte",t.OUT_OF_RANGE="out of UTF-8 range",t.UTF16_SURROGATE="UTF-16 surrogate",t.OVERLONG="overlong representation"}(C||(C={}));const x=Object.freeze({error:function(t,i,r,e,n){return O.throwArgumentError(`invalid codepoint at offset ${i}; ${t}`,"bytes",r)},ignore:k,replace:function(t,i,r,e,n){return t===C.OVERLONG?(e.push(n),0):(e.push(65533),k(t,i,r))}});function L(t,i){null==i&&(i=x.error),t=h(t);const r=[];let e=0;for(;e<t.length;){const n=t[e++];if(n>>7==0){r.push(n);continue}let h=null,o=null;if(192==(224&n))h=1,o=127;else if(224==(240&n))h=2,o=2047;else{if(240!=(248&n)){e+=i(128==(192&n)?C.UNEXPECTED_CONTINUE:C.BAD_PREFIX,e-1,t,r);continue}h=3,o=65535}if(e-1+h>=t.length){e+=i(C.OVERRUN,e-1,t,r);continue}let s=n&(1<<8-h-1)-1;for(let n=0;n<h;n++){let n=t[e];if(128!=(192&n)){e+=i(C.MISSING_CONTINUE,e,t,r),s=null;break}s=s<<6|63&n,e++}null!==s&&(s>1114111?e+=i(C.OUT_OF_RANGE,e-1-h,t,r,s):s>=55296&&s<=57343?e+=i(C.UTF16_SURROGATE,e-1-h,t,r,s):s<=o?e+=i(C.OVERLONG,e-1-h,t,r,s):r.push(s))}return r}function P(t,i=U.current){i!=U.current&&(O.checkNormalize(),t=t.normalize(i));let r=[];for(let i=0;i<t.length;i++){const e=t.charCodeAt(i);if(e<128)r.push(e);else if(e<2048)r.push(e>>6|192),r.push(63&e|128);else if(55296==(64512&e)){i++;const n=t.charCodeAt(i);if(i>=t.length||56320!=(64512&n))throw new Error("invalid utf-8 string");const h=65536+((1023&e)<<10)+(1023&n);r.push(h>>18|240),r.push(h>>12&63|128),r.push(h>>6&63|128),r.push(63&h|128)}else r.push(e>>12|224),r.push(e>>6&63|128),r.push(63&e|128)}return h(r)}function D(t){const i="0000"+t.toString(16);return"\\u"+i.substring(i.length-4)}function B(t,i){return'"'+L(t,i).map((t=>{if(t<256){switch(t){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 13:return"\\r";case 34:return'\\"';case 92:return"\\\\"}if(t>=32&&t<127)return String.fromCharCode(t)}return t<=65535?D(t):D(55296+((t-=65536)>>10&1023))+D(56320+(1023&t))})).join("")+'"'}function F(t){return t.map((t=>t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode(55296+(t>>10&1023),56320+(1023&t))))).join("")}function G(t,i){return F(L(t,i))}function q(t,i=U.current){return L(P(t,i))}function Z(t){return i(P(t))}export{R as B,d as E,g as L,U,F as _,G as a,N as b,q as c,B as d,x as e,C as f,Z as i,c as l,P as t,v};
@@ -0,0 +1 @@
1
+ import e from"util";var t={exports:{}};var r={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER||9007199254740991,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:"2.0.0",FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2};var s="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};!function(e,t){const{MAX_SAFE_COMPONENT_LENGTH:n}=r,i=s,o=(t=e.exports={}).re=[],a=t.src=[],l=t.t={};let h=0;const u=(e,t,r)=>{const s=h++;i(e,s,t),l[e]=s,a[s]=t,o[s]=new RegExp(t,r?"g":void 0)};u("NUMERICIDENTIFIER","0|[1-9]\\d*"),u("NUMERICIDENTIFIERLOOSE","[0-9]+"),u("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*"),u("MAINVERSION",`(${a[l.NUMERICIDENTIFIER]})\\.(${a[l.NUMERICIDENTIFIER]})\\.(${a[l.NUMERICIDENTIFIER]})`),u("MAINVERSIONLOOSE",`(${a[l.NUMERICIDENTIFIERLOOSE]})\\.(${a[l.NUMERICIDENTIFIERLOOSE]})\\.(${a[l.NUMERICIDENTIFIERLOOSE]})`),u("PRERELEASEIDENTIFIER",`(?:${a[l.NUMERICIDENTIFIER]}|${a[l.NONNUMERICIDENTIFIER]})`),u("PRERELEASEIDENTIFIERLOOSE",`(?:${a[l.NUMERICIDENTIFIERLOOSE]}|${a[l.NONNUMERICIDENTIFIER]})`),u("PRERELEASE",`(?:-(${a[l.PRERELEASEIDENTIFIER]}(?:\\.${a[l.PRERELEASEIDENTIFIER]})*))`),u("PRERELEASELOOSE",`(?:-?(${a[l.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${a[l.PRERELEASEIDENTIFIERLOOSE]})*))`),u("BUILDIDENTIFIER","[0-9A-Za-z-]+"),u("BUILD",`(?:\\+(${a[l.BUILDIDENTIFIER]}(?:\\.${a[l.BUILDIDENTIFIER]})*))`),u("FULLPLAIN",`v?${a[l.MAINVERSION]}${a[l.PRERELEASE]}?${a[l.BUILD]}?`),u("FULL",`^${a[l.FULLPLAIN]}$`),u("LOOSEPLAIN",`[v=\\s]*${a[l.MAINVERSIONLOOSE]}${a[l.PRERELEASELOOSE]}?${a[l.BUILD]}?`),u("LOOSE",`^${a[l.LOOSEPLAIN]}$`),u("GTLT","((?:<|>)?=?)"),u("XRANGEIDENTIFIERLOOSE",`${a[l.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),u("XRANGEIDENTIFIER",`${a[l.NUMERICIDENTIFIER]}|x|X|\\*`),u("XRANGEPLAIN",`[v=\\s]*(${a[l.XRANGEIDENTIFIER]})(?:\\.(${a[l.XRANGEIDENTIFIER]})(?:\\.(${a[l.XRANGEIDENTIFIER]})(?:${a[l.PRERELEASE]})?${a[l.BUILD]}?)?)?`),u("XRANGEPLAINLOOSE",`[v=\\s]*(${a[l.XRANGEIDENTIFIERLOOSE]})(?:\\.(${a[l.XRANGEIDENTIFIERLOOSE]})(?:\\.(${a[l.XRANGEIDENTIFIERLOOSE]})(?:${a[l.PRERELEASELOOSE]})?${a[l.BUILD]}?)?)?`),u("XRANGE",`^${a[l.GTLT]}\\s*${a[l.XRANGEPLAIN]}$`),u("XRANGELOOSE",`^${a[l.GTLT]}\\s*${a[l.XRANGEPLAINLOOSE]}$`),u("COERCE",`(^|[^\\d])(\\d{1,${n}})(?:\\.(\\d{1,${n}}))?(?:\\.(\\d{1,${n}}))?(?:$|[^\\d])`),u("COERCERTL",a[l.COERCE],!0),u("LONETILDE","(?:~>?)"),u("TILDETRIM",`(\\s*)${a[l.LONETILDE]}\\s+`,!0),t.tildeTrimReplace="$1~",u("TILDE",`^${a[l.LONETILDE]}${a[l.XRANGEPLAIN]}$`),u("TILDELOOSE",`^${a[l.LONETILDE]}${a[l.XRANGEPLAINLOOSE]}$`),u("LONECARET","(?:\\^)"),u("CARETTRIM",`(\\s*)${a[l.LONECARET]}\\s+`,!0),t.caretTrimReplace="$1^",u("CARET",`^${a[l.LONECARET]}${a[l.XRANGEPLAIN]}$`),u("CARETLOOSE",`^${a[l.LONECARET]}${a[l.XRANGEPLAINLOOSE]}$`),u("COMPARATORLOOSE",`^${a[l.GTLT]}\\s*(${a[l.LOOSEPLAIN]})$|^$`),u("COMPARATOR",`^${a[l.GTLT]}\\s*(${a[l.FULLPLAIN]})$|^$`),u("COMPARATORTRIM",`(\\s*)${a[l.GTLT]}\\s*(${a[l.LOOSEPLAIN]}|${a[l.XRANGEPLAIN]})`,!0),t.comparatorTrimReplace="$1$2$3",u("HYPHENRANGE",`^\\s*(${a[l.XRANGEPLAIN]})\\s+-\\s+(${a[l.XRANGEPLAIN]})\\s*$`),u("HYPHENRANGELOOSE",`^\\s*(${a[l.XRANGEPLAINLOOSE]})\\s+-\\s+(${a[l.XRANGEPLAINLOOSE]})\\s*$`),u("STAR","(<|>)?=?\\s*\\*"),u("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),u("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")}(t,t.exports);const n=Object.freeze({loose:!0}),i=Object.freeze({});var o=e=>e?"object"!=typeof e?n:e:i;const a=/^[0-9]+$/,l=(e,t)=>{const r=a.test(e),s=a.test(t);return r&&s&&(e=+e,t=+t),e===t?0:r&&!s?-1:s&&!r?1:e<t?-1:1};var h={compareIdentifiers:l,rcompareIdentifiers:(e,t)=>l(t,e)};const u=s,{MAX_LENGTH:p,MAX_SAFE_INTEGER:c}=r,{re:E,t:f}=t.exports,v=o,{compareIdentifiers:m}=h;class ${constructor(t,r){if(r=v(r),t instanceof $){if(t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease)return t;t=t.version}else if("string"!=typeof t)throw new TypeError(`Invalid Version: ${e.inspect(t)}`);if(t.length>p)throw new TypeError(`version is longer than ${p} characters`);u("SemVer",t,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;const s=t.trim().match(r.loose?E[f.LOOSE]:E[f.FULL]);if(!s)throw new TypeError(`Invalid Version: ${t}`);if(this.raw=t,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>c||this.major<0)throw new TypeError("Invalid major version");if(this.minor>c||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>c||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map((e=>{if(/^[0-9]+$/.test(e)){const t=+e;if(t>=0&&t<c)return t}return e})):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(u("SemVer.compare",this.version,this.options,e),!(e instanceof $)){if("string"==typeof e&&e===this.version)return 0;e=new $(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof $||(e=new $(e,this.options)),m(this.major,e.major)||m(this.minor,e.minor)||m(this.patch,e.patch)}comparePre(e){if(e instanceof $||(e=new $(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let t=0;do{const r=this.prerelease[t],s=e.prerelease[t];if(u("prerelease compare",t,r,s),void 0===r&&void 0===s)return 0;if(void 0===s)return 1;if(void 0===r)return-1;if(r!==s)return m(r,s)}while(++t)}compareBuild(e){e instanceof $||(e=new $(e,this.options));let t=0;do{const r=this.build[t],s=e.build[t];if(u("prerelease compare",t,r,s),void 0===r&&void 0===s)return 0;if(void 0===s)return 1;if(void 0===r)return-1;if(r!==s)return m(r,s)}while(++t)}inc(e,t,r){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t,r);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t,r);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t,r),this.inc("pre",t,r);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t,r),this.inc("pre",t,r);break;case"major":0===this.minor&&0===this.patch&&0!==this.prerelease.length||this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":0===this.patch&&0!==this.prerelease.length||this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":{const e=Number(r)?1:0;if(!t&&!1===r)throw new Error("invalid increment argument: identifier is empty");if(0===this.prerelease.length)this.prerelease=[e];else{let s=this.prerelease.length;for(;--s>=0;)"number"==typeof this.prerelease[s]&&(this.prerelease[s]++,s=-2);if(-1===s){if(t===this.prerelease.join(".")&&!1===r)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(e)}}if(t){let s=[t,e];!1===r&&(s=[t]),0===m(this.prerelease[0],t)?isNaN(this.prerelease[1])&&(this.prerelease=s):this.prerelease=s}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.format(),this.raw=this.version,this}}var R=$;const I=R;var g=(e,t,r=!1)=>{if(e instanceof I)return e;try{return new I(e,t)}catch(e){if(!r)return null;throw e}};const d=g;var N=(e,t)=>{const r=d(e,t);return r?r.version:null};const A=g;var L=(e,t)=>{const r=A(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null};const w=R;var O=(e,t,r,s,n)=>{"string"==typeof r&&(n=s,s=r,r=void 0);try{return new w(e instanceof w?e.version:e,r).inc(t,s,n).version}catch(e){return null}};const T=g;var S=(e,t)=>{const r=T(e,null,!0),s=T(t,null,!0),n=r.compare(s);if(0===n)return null;const i=n>0,o=i?s:r,a=!!(i?r:s).prerelease.length,l=a?"pre":"";return r.major!==s.major?l+"major":r.minor!==s.minor?l+"minor":r.patch!==s.patch?l+"patch":a?"prerelease":o.patch?"patch":o.minor?"minor":"major"};const y=R;var x=(e,t)=>new y(e,t).major;const P=R;var C=(e,t)=>new P(e,t).minor;const D=R;var b=(e,t)=>new D(e,t).patch;const G=g;var M=(e,t)=>{const r=G(e,t);return r&&r.prerelease.length?r.prerelease:null};const F=R;var j=(e,t,r)=>new F(e,r).compare(new F(t,r));const X=j;var U=(e,t,r)=>X(t,e,r);const _=j;var k=(e,t)=>_(e,t,!0);const V=R;var B=(e,t,r)=>{const s=new V(e,r),n=new V(t,r);return s.compare(n)||s.compareBuild(n)};const H=B;var Y=(e,t)=>e.sort(((e,r)=>H(e,r,t)));const W=B;var z=(e,t)=>e.sort(((e,r)=>W(r,e,t)));const q=j;var Z=(e,t,r)=>q(e,t,r)>0;const J=j;var K=(e,t,r)=>J(e,t,r)<0;const Q=j;var ee=(e,t,r)=>0===Q(e,t,r);const te=j;var re=(e,t,r)=>0!==te(e,t,r);const se=j;var ne=(e,t,r)=>se(e,t,r)>=0;const ie=j;var oe=(e,t,r)=>ie(e,t,r)<=0;const ae=ee,le=re,he=Z,ue=ne,pe=K,ce=oe;var Ee=(e,t,r,s)=>{switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e===r;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e!==r;case"":case"=":case"==":return ae(e,r,s);case"!=":return le(e,r,s);case">":return he(e,r,s);case">=":return ue(e,r,s);case"<":return pe(e,r,s);case"<=":return ce(e,r,s);default:throw new TypeError(`Invalid operator: ${t}`)}};const fe=R,ve=g,{re:me,t:$e}=t.exports;var Re,Ie,ge,de,Ne,Ae,Le,we,Oe,Te,Se=(e,t)=>{if(e instanceof fe)return e;if("number"==typeof e&&(e=String(e)),"string"!=typeof e)return null;let r=null;if((t=t||{}).rtl){let t;for(;(t=me[$e.COERCERTL].exec(e))&&(!r||r.index+r[0].length!==e.length);)r&&t.index+t[0].length===r.index+r[0].length||(r=t),me[$e.COERCERTL].lastIndex=t.index+t[1].length+t[2].length;me[$e.COERCERTL].lastIndex=-1}else r=e.match(me[$e.COERCE]);return null===r?null:ve(`${r[2]}.${r[3]||"0"}.${r[4]||"0"}`,t)};function ye(){if(de)return ge;function e(t){var r=this;if(r instanceof e||(r=new e),r.tail=null,r.head=null,r.length=0,t&&"function"==typeof t.forEach)t.forEach((function(e){r.push(e)}));else if(arguments.length>0)for(var s=0,n=arguments.length;s<n;s++)r.push(arguments[s]);return r}function t(e,t,r){var s=t===e.head?new n(r,null,t,e):new n(r,t,t.next,e);return null===s.next&&(e.tail=s),null===s.prev&&(e.head=s),e.length++,s}function r(e,t){e.tail=new n(t,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function s(e,t){e.head=new n(t,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function n(e,t,r,s){if(!(this instanceof n))return new n(e,t,r,s);this.list=s,this.value=e,t?(t.next=this,this.prev=t):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}de=1,ge=e,e.Node=n,e.create=e,e.prototype.removeNode=function(e){if(e.list!==this)throw new Error("removing node which does not belong to this list");var t=e.next,r=e.prev;return t&&(t.prev=r),r&&(r.next=t),e===this.head&&(this.head=t),e===this.tail&&(this.tail=r),e.list.length--,e.next=null,e.prev=null,e.list=null,t},e.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var t=this.head;e.list=this,e.next=t,t&&(t.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}},e.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var t=this.tail;e.list=this,e.prev=t,t&&(t.next=e),this.tail=e,this.head||(this.head=e),this.length++}},e.prototype.push=function(){for(var e=0,t=arguments.length;e<t;e++)r(this,arguments[e]);return this.length},e.prototype.unshift=function(){for(var e=0,t=arguments.length;e<t;e++)s(this,arguments[e]);return this.length},e.prototype.pop=function(){if(this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}},e.prototype.shift=function(){if(this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}},e.prototype.forEach=function(e,t){t=t||this;for(var r=this.head,s=0;null!==r;s++)e.call(t,r.value,s,this),r=r.next},e.prototype.forEachReverse=function(e,t){t=t||this;for(var r=this.tail,s=this.length-1;null!==r;s--)e.call(t,r.value,s,this),r=r.prev},e.prototype.get=function(e){for(var t=0,r=this.head;null!==r&&t<e;t++)r=r.next;if(t===e&&null!==r)return r.value},e.prototype.getReverse=function(e){for(var t=0,r=this.tail;null!==r&&t<e;t++)r=r.prev;if(t===e&&null!==r)return r.value},e.prototype.map=function(t,r){r=r||this;for(var s=new e,n=this.head;null!==n;)s.push(t.call(r,n.value,this)),n=n.next;return s},e.prototype.mapReverse=function(t,r){r=r||this;for(var s=new e,n=this.tail;null!==n;)s.push(t.call(r,n.value,this)),n=n.prev;return s},e.prototype.reduce=function(e,t){var r,s=this.head;if(arguments.length>1)r=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");s=this.head.next,r=this.head.value}for(var n=0;null!==s;n++)r=e(r,s.value,n),s=s.next;return r},e.prototype.reduceReverse=function(e,t){var r,s=this.tail;if(arguments.length>1)r=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");s=this.tail.prev,r=this.tail.value}for(var n=this.length-1;null!==s;n--)r=e(r,s.value,n),s=s.prev;return r},e.prototype.toArray=function(){for(var e=new Array(this.length),t=0,r=this.head;null!==r;t++)e[t]=r.value,r=r.next;return e},e.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,r=this.tail;null!==r;t++)e[t]=r.value,r=r.prev;return e},e.prototype.slice=function(t,r){(r=r||this.length)<0&&(r+=this.length),(t=t||0)<0&&(t+=this.length);var s=new e;if(r<t||r<0)return s;t<0&&(t=0),r>this.length&&(r=this.length);for(var n=0,i=this.head;null!==i&&n<t;n++)i=i.next;for(;null!==i&&n<r;n++,i=i.next)s.push(i.value);return s},e.prototype.sliceReverse=function(t,r){(r=r||this.length)<0&&(r+=this.length),(t=t||0)<0&&(t+=this.length);var s=new e;if(r<t||r<0)return s;t<0&&(t=0),r>this.length&&(r=this.length);for(var n=this.length,i=this.tail;null!==i&&n>r;n--)i=i.prev;for(;null!==i&&n>t;n--,i=i.prev)s.push(i.value);return s},e.prototype.splice=function(e,r,...s){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var n=0,i=this.head;null!==i&&n<e;n++)i=i.next;var o=[];for(n=0;i&&n<r;n++)o.push(i.value),i=this.removeNode(i);null===i&&(i=this.tail),i!==this.head&&i!==this.tail&&(i=i.prev);for(n=0;n<s.length;n++)i=t(this,i,s[n]);return o},e.prototype.reverse=function(){for(var e=this.head,t=this.tail,r=e;null!==r;r=r.prev){var s=r.prev;r.prev=r.next,r.next=s}return this.head=t,this.tail=e,this};try{(Ie?Re:(Ie=1,Re=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}))(e)}catch(e){}return ge}function xe(){if(we)return Le;we=1;class e{constructor(t,r){if(r=a(r),t instanceof e)return t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease?t:new e(t.raw,r);if(t instanceof l)return this.raw=t.value,this.set=[[t]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=t,this.set=t.split("||").map((e=>this.parseRange(e.trim()))).filter((e=>e.length)),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${t}`);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter((e=>!I(e[0]))),0===this.set.length)this.set=[e];else if(this.set.length>1)for(const e of this.set)if(1===e.length&&g(e[0])){this.set=[e];break}}this.format()}format(){return this.range=this.set.map((e=>e.join(" ").trim())).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();const t=((this.options.includePrerelease&&m)|(this.options.loose&&$))+":"+e,r=i.get(t);if(r)return r;const s=this.options.loose,n=s?p[c.HYPHENRANGELOOSE]:p[c.HYPHENRANGE];e=e.replace(n,C(this.options.includePrerelease)),h("hyphen replace",e),e=e.replace(p[c.COMPARATORTRIM],E),h("comparator trim",e);let o=(e=(e=(e=e.replace(p[c.TILDETRIM],f)).replace(p[c.CARETTRIM],v)).split(/\s+/).join(" ")).split(" ").map((e=>N(e,this.options))).join(" ").split(/\s+/).map((e=>P(e,this.options)));s&&(o=o.filter((e=>(h("loose invalid filter",e,this.options),!!e.match(p[c.COMPARATORLOOSE]))))),h("range list",o);const a=new Map,u=o.map((e=>new l(e,this.options)));for(const e of u){if(I(e))return[e];a.set(e.value,e)}a.size>1&&a.has("")&&a.delete("");const R=[...a.values()];return i.set(t,R),R}intersects(t,r){if(!(t instanceof e))throw new TypeError("a Range is required");return this.set.some((e=>d(e,r)&&t.set.some((t=>d(t,r)&&e.every((e=>t.every((t=>e.intersects(t,r)))))))))}test(e){if(!e)return!1;if("string"==typeof e)try{e=new u(e,this.options)}catch(e){return!1}for(let t=0;t<this.set.length;t++)if(D(this.set[t],e,this.options))return!0;return!1}}Le=e;const n=function(){if(Ae)return Ne;Ae=1;const e=ye(),t=Symbol("max"),r=Symbol("length"),s=Symbol("lengthCalculator"),n=Symbol("allowStale"),i=Symbol("maxAge"),o=Symbol("dispose"),a=Symbol("noDisposeOnSet"),l=Symbol("lruList"),h=Symbol("cache"),u=Symbol("updateAgeOnGet"),p=()=>1,c=(e,t,r)=>{const s=e[h].get(t);if(s){const t=s.value;if(E(e,t)){if(v(e,s),!e[n])return}else r&&(e[u]&&(s.value.now=Date.now()),e[l].unshiftNode(s));return t.value}},E=(e,t)=>{if(!t||!t.maxAge&&!e[i])return!1;const r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[i]&&r>e[i]},f=e=>{if(e[r]>e[t])for(let s=e[l].tail;e[r]>e[t]&&null!==s;){const t=s.prev;v(e,s),s=t}},v=(e,t)=>{if(t){const s=t.value;e[o]&&e[o](s.key,s.value),e[r]-=s.length,e[h].delete(s.key),e[l].removeNode(t)}};class m{constructor(e,t,r,s,n){this.key=e,this.value=t,this.length=r,this.now=s,this.maxAge=n||0}}const $=(e,t,r,s)=>{let i=r.value;E(e,i)&&(v(e,r),e[n]||(i=void 0)),i&&t.call(s,i.value,i.key,e)};return Ne=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");this[t]=e.max||1/0;const r=e.length||p;if(this[s]="function"!=typeof r?p:r,this[n]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[i]=e.maxAge||0,this[o]=e.dispose,this[a]=e.noDisposeOnSet||!1,this[u]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[t]=e||1/0,f(this)}get max(){return this[t]}set allowStale(e){this[n]=!!e}get allowStale(){return this[n]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[i]=e,f(this)}get maxAge(){return this[i]}set lengthCalculator(e){"function"!=typeof e&&(e=p),e!==this[s]&&(this[s]=e,this[r]=0,this[l].forEach((e=>{e.length=this[s](e.value,e.key),this[r]+=e.length}))),f(this)}get lengthCalculator(){return this[s]}get length(){return this[r]}get itemCount(){return this[l].length}rforEach(e,t){t=t||this;for(let r=this[l].tail;null!==r;){const s=r.prev;$(this,e,r,t),r=s}}forEach(e,t){t=t||this;for(let r=this[l].head;null!==r;){const s=r.next;$(this,e,r,t),r=s}}keys(){return this[l].toArray().map((e=>e.key))}values(){return this[l].toArray().map((e=>e.value))}reset(){this[o]&&this[l]&&this[l].length&&this[l].forEach((e=>this[o](e.key,e.value))),this[h]=new Map,this[l]=new e,this[r]=0}dump(){return this[l].map((e=>!E(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)})).toArray().filter((e=>e))}dumpLru(){return this[l]}set(e,n,u){if((u=u||this[i])&&"number"!=typeof u)throw new TypeError("maxAge must be a number");const p=u?Date.now():0,c=this[s](n,e);if(this[h].has(e)){if(c>this[t])return v(this,this[h].get(e)),!1;const s=this[h].get(e).value;return this[o]&&(this[a]||this[o](e,s.value)),s.now=p,s.maxAge=u,s.value=n,this[r]+=c-s.length,s.length=c,this.get(e),f(this),!0}const E=new m(e,n,c,p,u);return E.length>this[t]?(this[o]&&this[o](e,n),!1):(this[r]+=E.length,this[l].unshift(E),this[h].set(e,this[l].head),f(this),!0)}has(e){if(!this[h].has(e))return!1;const t=this[h].get(e).value;return!E(this,t)}get(e){return c(this,e,!0)}peek(e){return c(this,e,!1)}pop(){const e=this[l].tail;return e?(v(this,e),e.value):null}del(e){v(this,this[h].get(e))}load(e){this.reset();const t=Date.now();for(let r=e.length-1;r>=0;r--){const s=e[r],n=s.e||0;if(0===n)this.set(s.k,s.v);else{const e=n-t;e>0&&this.set(s.k,s.v,e)}}}prune(){this[h].forEach(((e,t)=>c(this,t,!1)))}}}(),i=new n({max:1e3}),a=o,l=Pe(),h=s,u=R,{re:p,t:c,comparatorTrimReplace:E,tildeTrimReplace:f,caretTrimReplace:v}=t.exports,{FLAG_INCLUDE_PRERELEASE:m,FLAG_LOOSE:$}=r,I=e=>"<0.0.0-0"===e.value,g=e=>""===e.value,d=(e,t)=>{let r=!0;const s=e.slice();let n=s.pop();for(;r&&s.length;)r=s.every((e=>n.intersects(e,t))),n=s.pop();return r},N=(e,t)=>(h("comp",e,t),e=O(e,t),h("caret",e),e=L(e,t),h("tildes",e),e=S(e,t),h("xrange",e),e=x(e,t),h("stars",e),e),A=e=>!e||"x"===e.toLowerCase()||"*"===e,L=(e,t)=>e.trim().split(/\s+/).map((e=>w(e,t))).join(" "),w=(e,t)=>{const r=t.loose?p[c.TILDELOOSE]:p[c.TILDE];return e.replace(r,((t,r,s,n,i)=>{let o;return h("tilde",e,t,r,s,n,i),A(r)?o="":A(s)?o=`>=${r}.0.0 <${+r+1}.0.0-0`:A(n)?o=`>=${r}.${s}.0 <${r}.${+s+1}.0-0`:i?(h("replaceTilde pr",i),o=`>=${r}.${s}.${n}-${i} <${r}.${+s+1}.0-0`):o=`>=${r}.${s}.${n} <${r}.${+s+1}.0-0`,h("tilde return",o),o}))},O=(e,t)=>e.trim().split(/\s+/).map((e=>T(e,t))).join(" "),T=(e,t)=>{h("caret",e,t);const r=t.loose?p[c.CARETLOOSE]:p[c.CARET],s=t.includePrerelease?"-0":"";return e.replace(r,((t,r,n,i,o)=>{let a;return h("caret",e,t,r,n,i,o),A(r)?a="":A(n)?a=`>=${r}.0.0${s} <${+r+1}.0.0-0`:A(i)?a="0"===r?`>=${r}.${n}.0${s} <${r}.${+n+1}.0-0`:`>=${r}.${n}.0${s} <${+r+1}.0.0-0`:o?(h("replaceCaret pr",o),a="0"===r?"0"===n?`>=${r}.${n}.${i}-${o} <${r}.${n}.${+i+1}-0`:`>=${r}.${n}.${i}-${o} <${r}.${+n+1}.0-0`:`>=${r}.${n}.${i}-${o} <${+r+1}.0.0-0`):(h("no pr"),a="0"===r?"0"===n?`>=${r}.${n}.${i}${s} <${r}.${n}.${+i+1}-0`:`>=${r}.${n}.${i}${s} <${r}.${+n+1}.0-0`:`>=${r}.${n}.${i} <${+r+1}.0.0-0`),h("caret return",a),a}))},S=(e,t)=>(h("replaceXRanges",e,t),e.split(/\s+/).map((e=>y(e,t))).join(" ")),y=(e,t)=>{e=e.trim();const r=t.loose?p[c.XRANGELOOSE]:p[c.XRANGE];return e.replace(r,((r,s,n,i,o,a)=>{h("xRange",e,r,s,n,i,o,a);const l=A(n),u=l||A(i),p=u||A(o),c=p;return"="===s&&c&&(s=""),a=t.includePrerelease?"-0":"",l?r=">"===s||"<"===s?"<0.0.0-0":"*":s&&c?(u&&(i=0),o=0,">"===s?(s=">=",u?(n=+n+1,i=0,o=0):(i=+i+1,o=0)):"<="===s&&(s="<",u?n=+n+1:i=+i+1),"<"===s&&(a="-0"),r=`${s+n}.${i}.${o}${a}`):u?r=`>=${n}.0.0${a} <${+n+1}.0.0-0`:p&&(r=`>=${n}.${i}.0${a} <${n}.${+i+1}.0-0`),h("xRange return",r),r}))},x=(e,t)=>(h("replaceStars",e,t),e.trim().replace(p[c.STAR],"")),P=(e,t)=>(h("replaceGTE0",e,t),e.trim().replace(p[t.includePrerelease?c.GTE0PRE:c.GTE0],"")),C=e=>(t,r,s,n,i,o,a,l,h,u,p,c,E)=>`${r=A(s)?"":A(n)?`>=${s}.0.0${e?"-0":""}`:A(i)?`>=${s}.${n}.0${e?"-0":""}`:o?`>=${r}`:`>=${r}${e?"-0":""}`} ${l=A(h)?"":A(u)?`<${+h+1}.0.0-0`:A(p)?`<${h}.${+u+1}.0-0`:c?`<=${h}.${u}.${p}-${c}`:e?`<${h}.${u}.${+p+1}-0`:`<=${l}`}`.trim(),D=(e,t,r)=>{for(let r=0;r<e.length;r++)if(!e[r].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(let r=0;r<e.length;r++)if(h(e[r].semver),e[r].semver!==l.ANY&&e[r].semver.prerelease.length>0){const s=e[r].semver;if(s.major===t.major&&s.minor===t.minor&&s.patch===t.patch)return!0}return!1}return!0};return Le}function Pe(){if(Te)return Oe;Te=1;const e=Symbol("SemVer ANY");class r{static get ANY(){return e}constructor(t,s){if(s=n(s),t instanceof r){if(t.loose===!!s.loose)return t;t=t.value}h("comparator",t,s),this.options=s,this.loose=!!s.loose,this.parse(t),this.semver===e?this.value="":this.value=this.operator+this.semver.version,h("comp",this)}parse(t){const r=this.options.loose?i[a.COMPARATORLOOSE]:i[a.COMPARATOR],s=t.match(r);if(!s)throw new TypeError(`Invalid comparator: ${t}`);this.operator=void 0!==s[1]?s[1]:"","="===this.operator&&(this.operator=""),s[2]?this.semver=new u(s[2],this.options.loose):this.semver=e}toString(){return this.value}test(t){if(h("Comparator.test",t,this.options.loose),this.semver===e||t===e)return!0;if("string"==typeof t)try{t=new u(t,this.options)}catch(e){return!1}return l(t,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof r))throw new TypeError("a Comparator is required");return""===this.operator?""===this.value||new p(e.value,t).test(this.value):""===e.operator?""===e.value||new p(this.value,t).test(e.semver):(!(t=n(t)).includePrerelease||"<0.0.0-0"!==this.value&&"<0.0.0-0"!==e.value)&&(!(!t.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0")))&&(!(!this.operator.startsWith(">")||!e.operator.startsWith(">"))||(!(!this.operator.startsWith("<")||!e.operator.startsWith("<"))||(!(this.semver.version!==e.semver.version||!this.operator.includes("=")||!e.operator.includes("="))||(!!(l(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<"))||!!(l(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">")))))))}}Oe=r;const n=o,{re:i,t:a}=t.exports,l=Ee,h=s,u=R,p=xe();return Oe}const Ce=xe();var De=(e,t,r)=>{try{t=new Ce(t,r)}catch(e){return!1}return t.test(e)};const be=xe();var Ge=(e,t)=>new be(e,t).set.map((e=>e.map((e=>e.value)).join(" ").trim().split(" ")));const Me=R,Fe=xe();var je=(e,t,r)=>{let s=null,n=null,i=null;try{i=new Fe(t,r)}catch(e){return null}return e.forEach((e=>{i.test(e)&&(s&&-1!==n.compare(e)||(s=e,n=new Me(s,r)))})),s};const Xe=R,Ue=xe();var _e=(e,t,r)=>{let s=null,n=null,i=null;try{i=new Ue(t,r)}catch(e){return null}return e.forEach((e=>{i.test(e)&&(s&&1!==n.compare(e)||(s=e,n=new Xe(s,r)))})),s};const ke=R,Ve=xe(),Be=Z;var He=(e,t)=>{e=new Ve(e,t);let r=new ke("0.0.0");if(e.test(r))return r;if(r=new ke("0.0.0-0"),e.test(r))return r;r=null;for(let t=0;t<e.set.length;++t){const s=e.set[t];let n=null;s.forEach((e=>{const t=new ke(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":n&&!Be(t,n)||(n=t);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${e.operator}`)}})),!n||r&&!Be(r,n)||(r=n)}return r&&e.test(r)?r:null};const Ye=xe();var We=(e,t)=>{try{return new Ye(e,t).range||"*"}catch(e){return null}};const ze=R,qe=Pe(),{ANY:Ze}=qe,Je=xe(),Ke=De,Qe=Z,et=K,tt=oe,rt=ne;var st=(e,t,r,s)=>{let n,i,o,a,l;switch(e=new ze(e,s),t=new Je(t,s),r){case">":n=Qe,i=tt,o=et,a=">",l=">=";break;case"<":n=et,i=rt,o=Qe,a="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(Ke(e,t,s))return!1;for(let r=0;r<t.set.length;++r){const h=t.set[r];let u=null,p=null;if(h.forEach((e=>{e.semver===Ze&&(e=new qe(">=0.0.0")),u=u||e,p=p||e,n(e.semver,u.semver,s)?u=e:o(e.semver,p.semver,s)&&(p=e)})),u.operator===a||u.operator===l)return!1;if((!p.operator||p.operator===a)&&i(e,p.semver))return!1;if(p.operator===l&&o(e,p.semver))return!1}return!0};const nt=st;var it=(e,t,r)=>nt(e,t,">",r);const ot=st;var at=(e,t,r)=>ot(e,t,"<",r);const lt=xe();var ht=(e,t,r)=>(e=new lt(e,r),t=new lt(t,r),e.intersects(t,r));const ut=De,pt=j;const ct=xe(),Et=Pe(),{ANY:ft}=Et,vt=De,mt=j,$t=[new Et(">=0.0.0-0")],Rt=[new Et(">=0.0.0")],It=(e,t,r)=>{if(e===t)return!0;if(1===e.length&&e[0].semver===ft){if(1===t.length&&t[0].semver===ft)return!0;e=r.includePrerelease?$t:Rt}if(1===t.length&&t[0].semver===ft){if(r.includePrerelease)return!0;t=Rt}const s=new Set;let n,i,o,a,l,h,u;for(const t of e)">"===t.operator||">="===t.operator?n=gt(n,t,r):"<"===t.operator||"<="===t.operator?i=dt(i,t,r):s.add(t.semver);if(s.size>1)return null;if(n&&i){if(o=mt(n.semver,i.semver,r),o>0)return null;if(0===o&&(">="!==n.operator||"<="!==i.operator))return null}for(const e of s){if(n&&!vt(e,String(n),r))return null;if(i&&!vt(e,String(i),r))return null;for(const s of t)if(!vt(e,String(s),r))return!1;return!0}let p=!(!i||r.includePrerelease||!i.semver.prerelease.length)&&i.semver,c=!(!n||r.includePrerelease||!n.semver.prerelease.length)&&n.semver;p&&1===p.prerelease.length&&"<"===i.operator&&0===p.prerelease[0]&&(p=!1);for(const e of t){if(u=u||">"===e.operator||">="===e.operator,h=h||"<"===e.operator||"<="===e.operator,n)if(c&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===c.major&&e.semver.minor===c.minor&&e.semver.patch===c.patch&&(c=!1),">"===e.operator||">="===e.operator){if(a=gt(n,e,r),a===e&&a!==n)return!1}else if(">="===n.operator&&!vt(n.semver,String(e),r))return!1;if(i)if(p&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===p.major&&e.semver.minor===p.minor&&e.semver.patch===p.patch&&(p=!1),"<"===e.operator||"<="===e.operator){if(l=dt(i,e,r),l===e&&l!==i)return!1}else if("<="===i.operator&&!vt(i.semver,String(e),r))return!1;if(!e.operator&&(i||n)&&0!==o)return!1}return!(n&&h&&!i&&0!==o)&&(!(i&&u&&!n&&0!==o)&&(!c&&!p))},gt=(e,t,r)=>{if(!e)return t;const s=mt(e.semver,t.semver,r);return s>0?e:s<0||">"===t.operator&&">="===e.operator?t:e},dt=(e,t,r)=>{if(!e)return t;const s=mt(e.semver,t.semver,r);return s<0?e:s>0||"<"===t.operator&&"<="===e.operator?t:e};var Nt=(e,t,r={})=>{if(e===t)return!0;e=new ct(e,r),t=new ct(t,r);let s=!1;e:for(const n of e.set){for(const e of t.set){const t=It(n,e,r);if(s=s||null!==t,t)continue e}if(s)return!1}return!0};const At=t.exports,Lt=r,wt=R,Ot=h,Tt=(e,t,r)=>{const s=[];let n=null,i=null;const o=e.sort(((e,t)=>pt(e,t,r)));for(const e of o){ut(e,t,r)?(i=e,n||(n=e)):(i&&s.push([n,i]),i=null,n=null)}n&&s.push([n,null]);const a=[];for(const[e,t]of s)e===t?a.push(e):t||e!==o[0]?t?e===o[0]?a.push(`<=${t}`):a.push(`${e} - ${t}`):a.push(`>=${e}`):a.push("*");const l=a.join(" || "),h="string"==typeof t.raw?t.raw:String(t);return l.length<h.length?l:t};var St={parse:g,valid:N,clean:L,inc:O,diff:S,major:x,minor:C,patch:b,prerelease:M,compare:j,rcompare:U,compareLoose:k,compareBuild:B,sort:Y,rsort:z,gt:Z,lt:K,eq:ee,neq:re,gte:ne,lte:oe,cmp:Ee,coerce:Se,Comparator:Pe(),Range:xe(),satisfies:De,toComparators:Ge,maxSatisfying:je,minSatisfying:_e,minVersion:He,validRange:We,outside:st,gtr:it,ltr:at,intersects:ht,simplifyRange:Tt,subset:Nt,SemVer:wt,re:At.re,src:At.src,tokens:At.t,SEMVER_SPEC_VERSION:Lt.SEMVER_SPEC_VERSION,RELEASE_TYPES:Lt.RELEASE_TYPES,compareIdentifiers:Ot.compareIdentifiers,rcompareIdentifiers:Ot.rcompareIdentifiers};export{St as s};
@@ -0,0 +1 @@
1
+ import{hexlify as r,arrayify as t,isBytesLike as o}from"@ethersproject/bytes";import{L as e}from"./id-830e09aa.js";const n=new e("rlp/5.7.0");function s(r){const t=[];for(;r;)t.unshift(255&r),r>>=8;return t}function c(r,t,o){let e=0;for(let n=0;n<o;n++)e=256*e+r[t+n];return e}function h(r){if(Array.isArray(r)){let t=[];if(r.forEach((function(r){t=t.concat(h(r))})),t.length<=55)return t.unshift(192+t.length),t;const o=s(t.length);return o.unshift(247+o.length),o.concat(t)}o(r)||n.throwArgumentError("RLP object must be BytesLike","object",r);const e=Array.prototype.slice.call(t(r));if(1===e.length&&e[0]<=127)return e;if(e.length<=55)return e.unshift(128+e.length),e;const c=s(e.length);return c.unshift(183+c.length),c.concat(e)}function u(t){return r(h(t))}function a(r,t,o,s){const c=[];for(;o<t+1+s;){const h=l(r,o);c.push(h.result),(o+=h.consumed)>t+1+s&&n.throwError("child data too short",e.errors.BUFFER_OVERRUN,{})}return{consumed:1+s,result:c}}function l(t,o){if(0===t.length&&n.throwError("data too short",e.errors.BUFFER_OVERRUN,{}),t[o]>=248){const r=t[o]-247;o+1+r>t.length&&n.throwError("data short segment too short",e.errors.BUFFER_OVERRUN,{});const s=c(t,o+1,r);return o+1+r+s>t.length&&n.throwError("data long segment too short",e.errors.BUFFER_OVERRUN,{}),a(t,o,o+1+r,r+s)}if(t[o]>=192){const r=t[o]-192;return o+1+r>t.length&&n.throwError("data array too short",e.errors.BUFFER_OVERRUN,{}),a(t,o,o+1,r)}if(t[o]>=184){const s=t[o]-183;o+1+s>t.length&&n.throwError("data array too short",e.errors.BUFFER_OVERRUN,{});const h=c(t,o+1,s);o+1+s+h>t.length&&n.throwError("data array too short",e.errors.BUFFER_OVERRUN,{});return{consumed:1+s+h,result:r(t.slice(o+1+s,o+1+s+h))}}if(t[o]>=128){const s=t[o]-128;o+1+s>t.length&&n.throwError("data too short",e.errors.BUFFER_OVERRUN,{});return{consumed:1+s,result:r(t.slice(o+1,o+1+s))}}return{consumed:1,result:r(t[o])}}function i(r){const o=t(r),e=l(o,0);return e.consumed!==o.length&&n.throwArgumentError("invalid rlp data","data",r),e.result}var f=Object.freeze({__proto__:null,encode:u,decode:i});export{i as d,u as e,f as l};