@dodoex/widgets 2.4.1 → 2.4.2-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.
- package/dist/cjs/index.cjs +7 -7
- package/dist/cjs/src/components/Bridge/SelectBridgeDialog/productList.d.ts +4 -1
- package/dist/cjs/src/components/Swap/components/SettingsDialog/index.d.ts +1 -1
- package/dist/cjs/src/components/Widget/index.d.ts +6 -1
- package/dist/cjs/src/constants/api.d.ts +13 -2
- package/dist/cjs/src/constants/localstorage.d.ts +10 -0
- package/dist/cjs/src/constants/swap.d.ts +1 -1
- package/dist/cjs/src/hooks/Bridge/createBridgeOrder.d.ts +1 -1
- package/dist/cjs/src/hooks/Bridge/useSendRoute.d.ts +1 -1
- package/dist/cjs/src/hooks/Bridge/useSwitchBridgeOrSwapSlippage.d.ts +1 -1
- package/dist/cjs/src/hooks/Swap/useFetchFiatPrice.d.ts +1 -1
- package/dist/cjs/src/hooks/Swap/useInitDefaultToken.d.ts +10 -0
- package/dist/cjs/src/hooks/Widget/useInitPropsToRedux.d.ts +1 -1
- package/dist/cjs/src/hooks/setting/useDefaultSlippage.d.ts +1 -0
- package/dist/cjs/src/hooks/setting/useGetAPIService.d.ts +2 -0
- package/dist/index.js +7 -7
- package/dist/src/components/Bridge/SelectBridgeDialog/productList.d.ts +4 -1
- package/dist/src/components/Swap/components/SettingsDialog/index.d.ts +1 -1
- package/dist/src/components/Widget/index.d.ts +6 -1
- package/dist/src/constants/api.d.ts +13 -2
- package/dist/src/constants/localstorage.d.ts +10 -0
- package/dist/src/constants/swap.d.ts +1 -1
- package/dist/src/hooks/Bridge/createBridgeOrder.d.ts +1 -1
- package/dist/src/hooks/Bridge/useSendRoute.d.ts +1 -1
- package/dist/src/hooks/Bridge/useSwitchBridgeOrSwapSlippage.d.ts +1 -1
- package/dist/src/hooks/Swap/useFetchFiatPrice.d.ts +1 -1
- package/dist/src/hooks/Swap/useInitDefaultToken.d.ts +10 -0
- package/dist/src/hooks/Widget/useInitPropsToRedux.d.ts +1 -1
- package/dist/src/hooks/setting/useDefaultSlippage.d.ts +1 -0
- package/dist/src/hooks/setting/useGetAPIService.d.ts +2 -0
- package/package.json +2 -2
package/dist/cjs/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@lingui/react"),t=require("bignumber.js"),r=require("lodash"),n=require("react"),o=require("@emotion/react"),i=require("@dodoex/icons"),s=require("@emotion/styled"),a=require("react-dom"),l=require("react-redux"),c=require("identicon.js"),u=require("@web3-react/core"),d=require("@web3-react/eip1193"),p=require("@web3-react/walletconnect-v2"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@lingui/react"),t=require("bignumber.js"),r=require("lodash"),n=require("react"),o=require("@emotion/react"),i=require("@dodoex/icons"),s=require("@emotion/styled"),a=require("react-dom"),l=require("react-redux"),c=require("identicon.js"),u=require("@web3-react/core"),d=require("@web3-react/eip1193"),p=require("@web3-react/walletconnect-v2"),f=require("@web3-react/metamask"),h=require("@web3-react/types"),m=require("@reduxjs/toolkit"),g=require("redux"),y=require("@ethersproject/bignumber"),b=require("@ethersproject/contracts"),v=require("@lingui/core"),x=require("react-window"),w=require("axios");function E(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function A(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(r){if("default"!==r){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:function(){return e[r]}})}})),t.default=e,Object.freeze(t)}var k,C=E(t),R=E(n),S=A(n),T=E(s),N=A(a),M=E(a),O=E(c),I=E(w),j="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},F={exports:{}},_={exports:{}},P={};var B,W,D,L,U,V,Z,H,z,Y,G,X,J,q,Q={};
|
|
2
2
|
/** @license React v16.13.1
|
|
3
3
|
* react-is.development.js
|
|
4
4
|
*
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/function K(){return W||(W=1,e=
|
|
9
|
+
*/function K(){return W||(W=1,e=_,"production"===process.env.NODE_ENV?e.exports=function(){if(k)return P;k=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:switch(e=e.type){case l:case c:case n:case i:case o:case d:return e;default:switch(e=e&&e.$$typeof){case a:case u:case h:case f:case s:return e;default:return p}}case r:return p}}}function x(e){return v(e)===c}return P.AsyncMode=l,P.ConcurrentMode=c,P.ContextConsumer=a,P.ContextProvider=s,P.Element=t,P.ForwardRef=u,P.Fragment=n,P.Lazy=h,P.Memo=f,P.Portal=r,P.Profiler=i,P.StrictMode=o,P.Suspense=d,P.isAsyncMode=function(e){return x(e)||v(e)===l},P.isConcurrentMode=x,P.isContextConsumer=function(e){return v(e)===a},P.isContextProvider=function(e){return v(e)===s},P.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},P.isForwardRef=function(e){return v(e)===u},P.isFragment=function(e){return v(e)===n},P.isLazy=function(e){return v(e)===h},P.isMemo=function(e){return v(e)===f},P.isPortal=function(e){return v(e)===r},P.isProfiler=function(e){return v(e)===i},P.isStrictMode=function(e){return v(e)===o},P.isSuspense=function(e){return v(e)===d},P.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===c||e===i||e===o||e===d||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===f||e.$$typeof===s||e.$$typeof===a||e.$$typeof===u||e.$$typeof===g||e.$$typeof===y||e.$$typeof===b||e.$$typeof===m)},P.typeOf=v,P}():e.exports=(B||(B=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:var m=e.type;switch(m){case l:case c:case n:case i:case o:case d:return m;default:var g=m&&m.$$typeof;switch(g){case a:case u:case h:case f:case s:return g;default:return p}}case r:return p}}}var x=l,w=c,E=a,A=s,k=t,C=u,R=n,S=h,T=f,N=r,M=i,O=o,I=d,j=!1;function F(e){return v(e)===c}Q.AsyncMode=x,Q.ConcurrentMode=w,Q.ContextConsumer=E,Q.ContextProvider=A,Q.Element=k,Q.ForwardRef=C,Q.Fragment=R,Q.Lazy=S,Q.Memo=T,Q.Portal=N,Q.Profiler=M,Q.StrictMode=O,Q.Suspense=I,Q.isAsyncMode=function(e){return j||(j=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),F(e)||v(e)===l},Q.isConcurrentMode=F,Q.isContextConsumer=function(e){return v(e)===a},Q.isContextProvider=function(e){return v(e)===s},Q.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Q.isForwardRef=function(e){return v(e)===u},Q.isFragment=function(e){return v(e)===n},Q.isLazy=function(e){return v(e)===h},Q.isMemo=function(e){return v(e)===f},Q.isPortal=function(e){return v(e)===r},Q.isProfiler=function(e){return v(e)===i},Q.isStrictMode=function(e){return v(e)===o},Q.isSuspense=function(e){return v(e)===d},Q.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===c||e===i||e===o||e===d||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===f||e.$$typeof===s||e.$$typeof===a||e.$$typeof===u||e.$$typeof===g||e.$$typeof===y||e.$$typeof===b||e.$$typeof===m)},Q.typeOf=v}()),Q)),_.exports;var e}
|
|
10
10
|
/*
|
|
11
11
|
object-assign
|
|
12
12
|
(c) Sindre Sorhus
|
|
13
13
|
@license MIT
|
|
14
|
-
*/function $(){if(V)return
|
|
14
|
+
*/function $(){if(V)return U;V=1;return U="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function ee(){return H?Z:(H=1,Z=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var te=K();F.exports=function(){if(X)return G;X=1;var e=K(),t=function(){if(L)return D;L=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;function n(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}return D=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(o,i){for(var s,a,l=n(o),c=1;c<arguments.length;c++){for(var u in s=Object(arguments[c]))t.call(s,u)&&(l[u]=s[u]);if(e){a=e(s);for(var d=0;d<a.length;d++)r.call(s,a[d])&&(l[a[d]]=s[a[d]])}}return l},D}(),r=$(),n=ee(),o=function(){if(Y)return z;Y=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=$(),r={},n=ee();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function o(o,i,s,a,l){if("production"!==process.env.NODE_ENV)for(var c in o)if(n(o,c)){var u;try{if("function"!=typeof o[c]){var d=Error((a||"React class")+": "+s+" type `"+c+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[c]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}u=o[c](i,c,a,s,null,t)}catch(e){u=e}if(!u||u instanceof Error||e((a||"React class")+": type specification of "+s+" `"+c+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof u+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),u instanceof Error&&!(u.message in r)){r[u.message]=!0;var p=l?l():"";e("Failed "+s+" type: "+u.message+(null!=p?p:""))}}}return o.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(r={})},z=o}(),i=function(){};function s(){return null}return"production"!==process.env.NODE_ENV&&(i=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),G=function(a,l){var c="function"==typeof Symbol&&Symbol.iterator,u="<<anonymous>>",d={array:m("array"),bigint:m("bigint"),bool:m("boolean"),func:m("function"),number:m("number"),object:m("object"),string:m("string"),symbol:m("symbol"),any:h(s),arrayOf:function(e){return h((function(t,n,o,i,s){if("function"!=typeof e)return new f("Property `"+s+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var a=t[n];if(!Array.isArray(a))return new f("Invalid "+i+" `"+s+"` of type `"+b(a)+"` supplied to `"+o+"`, expected an array.");for(var l=0;l<a.length;l++){var c=e(a,l,o,i,s+"["+l+"]",r);if(c instanceof Error)return c}return null}))},element:h((function(e,t,r,n,o){var i=e[t];return a(i)?null:new f("Invalid "+n+" `"+o+"` of type `"+b(i)+"` supplied to `"+r+"`, expected a single ReactElement.")})),elementType:h((function(t,r,n,o,i){var s=t[r];return e.isValidElementType(s)?null:new f("Invalid "+o+" `"+i+"` of type `"+b(s)+"` supplied to `"+n+"`, expected a single ReactElement type.")})),instanceOf:function(e){return h((function(t,r,n,o,i){if(!(t[r]instanceof e)){var s=e.name||u;return new f("Invalid "+o+" `"+i+"` of type `"+((a=t[r]).constructor&&a.constructor.name?a.constructor.name:u)+"` supplied to `"+n+"`, expected instance of `"+s+"`.")}var a;return null}))},node:h((function(e,t,r,n,o){return y(e[t])?null:new f("Invalid "+n+" `"+o+"` supplied to `"+r+"`, expected a ReactNode.")})),objectOf:function(e){return h((function(t,o,i,s,a){if("function"!=typeof e)return new f("Property `"+a+"` of component `"+i+"` has invalid PropType notation inside objectOf.");var l=t[o],c=b(l);if("object"!==c)return new f("Invalid "+s+" `"+a+"` of type `"+c+"` supplied to `"+i+"`, expected an object.");for(var u in l)if(n(l,u)){var d=e(l,u,i,s,a+"."+u,r);if(d instanceof Error)return d}return null}))},oneOf:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&i(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),s;function t(t,r,n,o,i){for(var s=t[r],a=0;a<e.length;a++)if(p(s,e[a]))return null;var l=JSON.stringify(e,(function(e,t){return"symbol"===v(t)?String(t):t}));return new f("Invalid "+o+" `"+i+"` of value `"+String(s)+"` supplied to `"+n+"`, expected one of "+l+".")}return h(t)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&i("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var t=0;t<e.length;t++){var o=e[t];if("function"!=typeof o)return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+x(o)+" at index "+t+"."),s}return h((function(t,o,i,s,a){for(var l=[],c=0;c<e.length;c++){var u=(0,e[c])(t,o,i,s,a,r);if(null==u)return null;u.data&&n(u.data,"expectedType")&&l.push(u.data.expectedType)}return new f("Invalid "+s+" `"+a+"` supplied to `"+i+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")}))},shape:function(e){return h((function(t,n,o,i,s){var a=t[n],l=b(a);if("object"!==l)return new f("Invalid "+i+" `"+s+"` of type `"+l+"` supplied to `"+o+"`, expected `object`.");for(var c in e){var u=e[c];if("function"!=typeof u)return g(o,i,s,c,v(u));var d=u(a,c,o,i,s+"."+c,r);if(d)return d}return null}))},exact:function(e){return h((function(o,i,s,a,l){var c=o[i],u=b(c);if("object"!==u)return new f("Invalid "+a+" `"+l+"` of type `"+u+"` supplied to `"+s+"`, expected `object`.");var d=t({},o[i],e);for(var p in d){var h=e[p];if(n(e,p)&&"function"!=typeof h)return g(s,a,l,p,v(h));if(!h)return new f("Invalid "+a+" `"+l+"` key `"+p+"` supplied to `"+s+"`.\nBad object: "+JSON.stringify(o[i],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var m=h(c,p,s,a,l+"."+p,r);if(m)return m}return null}))}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function f(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function h(e){if("production"!==process.env.NODE_ENV)var t={},n=0;function o(o,s,a,c,d,p,h){if(c=c||u,p=p||a,h!==r){if(l){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var g=c+":"+a;!t[g]&&n<3&&(i("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+c+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),t[g]=!0,n++)}}return null==s[a]?o?null===s[a]?new f("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `null`."):new f("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `undefined`."):null:e(s,a,c,d,p)}var s=o.bind(null,!1);return s.isRequired=o.bind(null,!0),s}function m(e){return h((function(t,r,n,o,i,s){var a=t[r];return b(a)!==e?new f("Invalid "+o+" `"+i+"` of type `"+v(a)+"` supplied to `"+n+"`, expected `"+e+"`.",{expectedType:e}):null}))}function g(e,t,r,n,o){return new f((e||"React class")+": "+t+" type `"+r+"."+n+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function y(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(y);if(null===e||a(e))return!0;var t=function(e){var t=e&&(c&&e[c]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var r,n=t.call(e);if(t!==e.entries){for(;!(r=n.next()).done;)if(!y(r.value))return!1}else for(;!(r=n.next()).done;){var o=r.value;if(o&&!y(o[1]))return!1}return!0;default:return!1}}function b(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function v(e){if(null==e)return""+e;var t=b(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function x(e){var t=v(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return f.prototype=Error.prototype,d.checkPropTypes=o,d.resetWarningCache=o.resetWarningCache,d.PropTypes=d,d},G}()(te.isElement,!0)}else F.exports=function(){if(q)return J;q=1;var e=$();function t(){}function r(){}return r.resetWarningCache=t,J=function(){function n(t,r,n,o,i,s){if(s!==e){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function o(){return n}n.isRequired=n;var i={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:o,element:n,elementType:n,instanceOf:o,node:n,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:r,resetWarningCache:t};return i.PropTypes=i,i}}()();var re,ne={exports:{}},oe={};var ie,se,ae={};
|
|
15
15
|
/**
|
|
16
16
|
* @license React
|
|
17
17
|
* react-jsx-runtime.development.js
|
|
@@ -20,7 +20,7 @@ object-assign
|
|
|
20
20
|
*
|
|
21
21
|
* This source code is licensed under the MIT license found in the
|
|
22
22
|
* LICENSE file in the root directory of this source tree.
|
|
23
|
-
*/function le(){return ie||(ie=1,"production"!==process.env.NODE_ENV&&function(){var e=R.default,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),h=Symbol.for("react.offscreen"),f=Symbol.iterator;var m=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function g(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];y("error",e,r)}function y(e,t,r){var n=m.ReactDebugCurrentFrame.getStackAddendum();""!==n&&(t+="%s",r=r.concat([n]));var o=r.map((function(e){return String(e)}));o.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,o)}var b;function x(e){return e.displayName||"Context"}function v(e){if(null==e)return null;if("number"==typeof e.tag&&g("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),"function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case n:return"Fragment";case r:return"Portal";case i:return"Profiler";case o:return"StrictMode";case c:return"Suspense";case u:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case a:return x(e)+".Consumer";case s:return x(e._context)+".Provider";case l:return function(e,t,r){var n=e.displayName;if(n)return n;var o=t.displayName||t.name||"";return""!==o?r+"("+o+")":r}(e,e.render,"ForwardRef");case d:var t=e.displayName||null;return null!==t?t:v(e.type)||"Memo";case p:var h=e,f=h._payload,m=h._init;try{return v(m(f))}catch(e){return null}}return null}b=Symbol.for("react.module.reference");var w,E,A,C,k,T,S,N=Object.assign,M=0;function F(){}F.__reactDisabledLog=!0;var O,I=m.ReactCurrentDispatcher;function j(e,t,r){if(void 0===O)try{throw Error()}catch(e){var n=e.stack.trim().match(/\n( *(at )?)/);O=n&&n[1]||""}return"\n"+O+e}var D,B=!1,P="function"==typeof WeakMap?WeakMap:Map;function W(e,t){if(!e||B)return"";var r,n=D.get(e);if(void 0!==n)return n;B=!0;var o,i=Error.prepareStackTrace;Error.prepareStackTrace=void 0,o=I.current,I.current=null,function(){if(0===M){w=console.log,E=console.info,A=console.warn,C=console.error,k=console.group,T=console.groupCollapsed,S=console.groupEnd;var e={configurable:!0,enumerable:!0,value:F,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}M++}();try{if(t){var s=function(){throw Error()};if(Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(s,[])}catch(e){r=e}Reflect.construct(e,[],s)}else{try{s.call()}catch(e){r=e}e.call(s.prototype)}}else{try{throw Error()}catch(e){r=e}e()}}catch(t){if(t&&r&&"string"==typeof t.stack){for(var a=t.stack.split("\n"),l=r.stack.split("\n"),c=a.length-1,u=l.length-1;c>=1&&u>=0&&a[c]!==l[u];)u--;for(;c>=1&&u>=0;c--,u--)if(a[c]!==l[u]){if(1!==c||1!==u)do{if(c--,--u<0||a[c]!==l[u]){var d="\n"+a[c].replace(" at new "," at ");return e.displayName&&d.includes("<anonymous>")&&(d=d.replace("<anonymous>",e.displayName)),"function"==typeof e&&D.set(e,d),d}}while(c>=1&&u>=0);break}}}finally{B=!1,I.current=o,function(){if(0==--M){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:N({},e,{value:w}),info:N({},e,{value:E}),warn:N({},e,{value:A}),error:N({},e,{value:C}),group:N({},e,{value:k}),groupCollapsed:N({},e,{value:T}),groupEnd:N({},e,{value:S})})}M<0&&g("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}(),Error.prepareStackTrace=i}var p=e?e.displayName||e.name:"",h=p?j(p):"";return"function"==typeof e&&D.set(e,h),h}function _(e,t,r){if(null==e)return"";if("function"==typeof e)return W(e,!(!(n=e.prototype)||!n.isReactComponent));var n;if("string"==typeof e)return j(e);switch(e){case c:return j("Suspense");case u:return j("SuspenseList")}if("object"==typeof e)switch(e.$$typeof){case l:return function(e,t,r){return W(e,!1)}(e.render);case d:return _(e.type,t,r);case p:var o=e,i=o._payload,s=o._init;try{return _(s(i),t,r)}catch(e){}}return""}D=new P;var U=Object.prototype.hasOwnProperty,L={},V=m.ReactDebugCurrentFrame;function Z(e){if(e){var t=e._owner,r=_(e.type,e._source,t?t.type:null);V.setExtraStackFrame(r)}else V.setExtraStackFrame(null)}var H=Array.isArray;function z(e){return H(e)}function Y(e){return""+e}function G(e){if(function(e){try{return Y(e),!1}catch(e){return!0}}(e))return g("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",function(e){return"function"==typeof Symbol&&Symbol.toStringTag&&e[Symbol.toStringTag]||e.constructor.name||"Object"}(e)),Y(e)}var X,J,q,Q=m.ReactCurrentOwner,K={key:!0,ref:!0,__self:!0,__source:!0};q={};function $(e,r,n,o,i){var s,a={},l=null,c=null;for(s in void 0!==n&&(G(n),l=""+n),function(e){if(U.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return void 0!==e.key}(r)&&(G(r.key),l=""+r.key),function(e){if(U.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return void 0!==e.ref}(r)&&(c=r.ref,function(e,t){if("string"==typeof e.ref&&Q.current&&t&&Q.current.stateNode!==t){var r=v(Q.current.type);q[r]||(g('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',v(Q.current.type),e.ref),q[r]=!0)}}(r,i)),r)U.call(r,s)&&!K.hasOwnProperty(s)&&(a[s]=r[s]);if(e&&e.defaultProps){var u=e.defaultProps;for(s in u)void 0===a[s]&&(a[s]=u[s])}if(l||c){var d="function"==typeof e?e.displayName||e.name||"Unknown":e;l&&function(e,t){var r=function(){X||(X=!0,g("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"key",{get:r,configurable:!0})}(a,d),c&&function(e,t){var r=function(){J||(J=!0,g("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"ref",{get:r,configurable:!0})}(a,d)}return function(e,r,n,o,i,s,a){var l={$$typeof:t,type:e,key:r,ref:n,props:a,_owner:s,_store:{}};return Object.defineProperty(l._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(l,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(l,"_source",{configurable:!1,enumerable:!1,writable:!1,value:i}),Object.freeze&&(Object.freeze(l.props),Object.freeze(l)),l}(e,l,c,i,o,Q.current,a)}var ee,te=m.ReactCurrentOwner,re=m.ReactDebugCurrentFrame;function ne(e){if(e){var t=e._owner,r=_(e.type,e._source,t?t.type:null);re.setExtraStackFrame(r)}else re.setExtraStackFrame(null)}function oe(e){return"object"==typeof e&&null!==e&&e.$$typeof===t}function ie(){if(te.current){var e=v(te.current.type);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}ee=!1;var se={};function le(e,t){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var r=function(e){var t=ie();if(!t){var r="string"==typeof e?e:e.displayName||e.name;r&&(t="\n\nCheck the top-level render call using <"+r+">.")}return t}(t);if(!se[r]){se[r]=!0;var n="";e&&e._owner&&e._owner!==te.current&&(n=" It was passed a child from "+v(e._owner.type)+"."),ne(e),g('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',r,n),ne(null)}}}function ce(e,t){if("object"==typeof e)if(z(e))for(var r=0;r<e.length;r++){var n=e[r];oe(n)&&le(n,t)}else if(oe(e))e._store&&(e._store.validated=!0);else if(e){var o=function(e){if(null===e||"object"!=typeof e)return null;var t=f&&e[f]||e["@@iterator"];return"function"==typeof t?t:null}(e);if("function"==typeof o&&o!==e.entries)for(var i,s=o.call(e);!(i=s.next()).done;)oe(i.value)&&le(i.value,t)}}function ue(e){var t,r=e.type;if(null!=r&&"string"!=typeof r){if("function"==typeof r)t=r.propTypes;else{if("object"!=typeof r||r.$$typeof!==l&&r.$$typeof!==d)return;t=r.propTypes}if(t){var n=v(r);!function(e,t,r,n,o){var i=Function.call.bind(U);for(var s in e)if(i(e,s)){var a=void 0;try{if("function"!=typeof e[s]){var l=Error((n||"React class")+": "+r+" type `"+s+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[s]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw l.name="Invariant Violation",l}a=e[s](t,s,n,r,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(e){a=e}!a||a instanceof Error||(Z(o),g("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",n||"React class",r,s,typeof a),Z(null)),a instanceof Error&&!(a.message in L)&&(L[a.message]=!0,Z(o),g("Failed %s type: %s",r,a.message),Z(null))}}(t,e.props,"prop",n,e)}else if(void 0!==r.PropTypes&&!ee){ee=!0,g("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",v(r)||"Unknown")}"function"!=typeof r.getDefaultProps||r.getDefaultProps.isReactClassApproved||g("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function de(e,r,f,m,y,x){var w=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===i||e===o||e===c||e===u||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===d||e.$$typeof===s||e.$$typeof===a||e.$$typeof===l||e.$$typeof===b||void 0!==e.getModuleId)}(e);if(!w){var E="";(void 0===e||"object"==typeof e&&null!==e&&0===Object.keys(e).length)&&(E+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var A,C=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(y);E+=C||ie(),null===e?A="null":z(e)?A="array":void 0!==e&&e.$$typeof===t?(A="<"+(v(e.type)||"Unknown")+" />",E=" Did you accidentally export a JSX literal instead of a component?"):A=typeof e,g("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",A,E)}var k=$(e,r,f,y,x);if(null==k)return k;if(w){var R=r.children;if(void 0!==R)if(m)if(z(R)){for(var T=0;T<R.length;T++)ce(R[T],e);Object.freeze&&Object.freeze(R)}else g("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else ce(R,e)}return e===n?function(e){for(var t=Object.keys(e.props),r=0;r<t.length;r++){var n=t[r];if("children"!==n&&"key"!==n){ne(e),g("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),ne(null);break}}null!==e.ref&&(ne(e),g("Invalid attribute `ref` supplied to `React.Fragment`."),ne(null))}(k):ue(k),k}var pe=function(e,t,r){return de(e,t,r,!1)},he=function(e,t,r){return de(e,t,r,!0)};ae.Fragment=n,ae.jsx=pe,ae.jsxs=he}()),ae}se=ne,"production"===process.env.NODE_ENV?se.exports=function(){if(re)return oe;re=1;var e=R.default,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function s(e,r,s){var a,l={},c=null,u=null;for(a in void 0!==s&&(c=""+s),void 0!==r.key&&(c=""+r.key),void 0!==r.ref&&(u=r.ref),r)n.call(r,a)&&!i.hasOwnProperty(a)&&(l[a]=r[a]);if(e&&e.defaultProps)for(a in r=e.defaultProps)void 0===l[a]&&(l[a]=r[a]);return{$$typeof:t,type:e,key:c,ref:u,props:l,_owner:o.current}}return oe.Fragment=r,oe.jsx=s,oe.jsxs=s,oe}():se.exports=le();var ce,ue={exports:{}},de={};var pe,he={};
|
|
23
|
+
*/function le(){return ie||(ie=1,"production"!==process.env.NODE_ENV&&function(){var e=R.default,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),f=Symbol.for("react.offscreen"),h=Symbol.iterator;var m=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function g(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];y("error",e,r)}function y(e,t,r){var n=m.ReactDebugCurrentFrame.getStackAddendum();""!==n&&(t+="%s",r=r.concat([n]));var o=r.map((function(e){return String(e)}));o.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,o)}var b;function v(e){return e.displayName||"Context"}function x(e){if(null==e)return null;if("number"==typeof e.tag&&g("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),"function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case n:return"Fragment";case r:return"Portal";case i:return"Profiler";case o:return"StrictMode";case c:return"Suspense";case u:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case a:return v(e)+".Consumer";case s:return v(e._context)+".Provider";case l:return function(e,t,r){var n=e.displayName;if(n)return n;var o=t.displayName||t.name||"";return""!==o?r+"("+o+")":r}(e,e.render,"ForwardRef");case d:var t=e.displayName||null;return null!==t?t:x(e.type)||"Memo";case p:var f=e,h=f._payload,m=f._init;try{return x(m(h))}catch(e){return null}}return null}b=Symbol.for("react.module.reference");var w,E,A,k,C,S,T,N=Object.assign,M=0;function O(){}O.__reactDisabledLog=!0;var I,j=m.ReactCurrentDispatcher;function F(e,t,r){if(void 0===I)try{throw Error()}catch(e){var n=e.stack.trim().match(/\n( *(at )?)/);I=n&&n[1]||""}return"\n"+I+e}var _,P=!1,B="function"==typeof WeakMap?WeakMap:Map;function W(e,t){if(!e||P)return"";var r,n=_.get(e);if(void 0!==n)return n;P=!0;var o,i=Error.prepareStackTrace;Error.prepareStackTrace=void 0,o=j.current,j.current=null,function(){if(0===M){w=console.log,E=console.info,A=console.warn,k=console.error,C=console.group,S=console.groupCollapsed,T=console.groupEnd;var e={configurable:!0,enumerable:!0,value:O,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}M++}();try{if(t){var s=function(){throw Error()};if(Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(s,[])}catch(e){r=e}Reflect.construct(e,[],s)}else{try{s.call()}catch(e){r=e}e.call(s.prototype)}}else{try{throw Error()}catch(e){r=e}e()}}catch(t){if(t&&r&&"string"==typeof t.stack){for(var a=t.stack.split("\n"),l=r.stack.split("\n"),c=a.length-1,u=l.length-1;c>=1&&u>=0&&a[c]!==l[u];)u--;for(;c>=1&&u>=0;c--,u--)if(a[c]!==l[u]){if(1!==c||1!==u)do{if(c--,--u<0||a[c]!==l[u]){var d="\n"+a[c].replace(" at new "," at ");return e.displayName&&d.includes("<anonymous>")&&(d=d.replace("<anonymous>",e.displayName)),"function"==typeof e&&_.set(e,d),d}}while(c>=1&&u>=0);break}}}finally{P=!1,j.current=o,function(){if(0==--M){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:N({},e,{value:w}),info:N({},e,{value:E}),warn:N({},e,{value:A}),error:N({},e,{value:k}),group:N({},e,{value:C}),groupCollapsed:N({},e,{value:S}),groupEnd:N({},e,{value:T})})}M<0&&g("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}(),Error.prepareStackTrace=i}var p=e?e.displayName||e.name:"",f=p?F(p):"";return"function"==typeof e&&_.set(e,f),f}function D(e,t,r){if(null==e)return"";if("function"==typeof e)return W(e,!(!(n=e.prototype)||!n.isReactComponent));var n;if("string"==typeof e)return F(e);switch(e){case c:return F("Suspense");case u:return F("SuspenseList")}if("object"==typeof e)switch(e.$$typeof){case l:return function(e,t,r){return W(e,!1)}(e.render);case d:return D(e.type,t,r);case p:var o=e,i=o._payload,s=o._init;try{return D(s(i),t,r)}catch(e){}}return""}_=new B;var L=Object.prototype.hasOwnProperty,U={},V=m.ReactDebugCurrentFrame;function Z(e){if(e){var t=e._owner,r=D(e.type,e._source,t?t.type:null);V.setExtraStackFrame(r)}else V.setExtraStackFrame(null)}var H=Array.isArray;function z(e){return H(e)}function Y(e){return""+e}function G(e){if(function(e){try{return Y(e),!1}catch(e){return!0}}(e))return g("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",function(e){return"function"==typeof Symbol&&Symbol.toStringTag&&e[Symbol.toStringTag]||e.constructor.name||"Object"}(e)),Y(e)}var X,J,q,Q=m.ReactCurrentOwner,K={key:!0,ref:!0,__self:!0,__source:!0};q={};function $(e,r,n,o,i){var s,a={},l=null,c=null;for(s in void 0!==n&&(G(n),l=""+n),function(e){if(L.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return void 0!==e.key}(r)&&(G(r.key),l=""+r.key),function(e){if(L.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return void 0!==e.ref}(r)&&(c=r.ref,function(e,t){if("string"==typeof e.ref&&Q.current&&t&&Q.current.stateNode!==t){var r=x(Q.current.type);q[r]||(g('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',x(Q.current.type),e.ref),q[r]=!0)}}(r,i)),r)L.call(r,s)&&!K.hasOwnProperty(s)&&(a[s]=r[s]);if(e&&e.defaultProps){var u=e.defaultProps;for(s in u)void 0===a[s]&&(a[s]=u[s])}if(l||c){var d="function"==typeof e?e.displayName||e.name||"Unknown":e;l&&function(e,t){var r=function(){X||(X=!0,g("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"key",{get:r,configurable:!0})}(a,d),c&&function(e,t){var r=function(){J||(J=!0,g("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};r.isReactWarning=!0,Object.defineProperty(e,"ref",{get:r,configurable:!0})}(a,d)}return function(e,r,n,o,i,s,a){var l={$$typeof:t,type:e,key:r,ref:n,props:a,_owner:s,_store:{}};return Object.defineProperty(l._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(l,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(l,"_source",{configurable:!1,enumerable:!1,writable:!1,value:i}),Object.freeze&&(Object.freeze(l.props),Object.freeze(l)),l}(e,l,c,i,o,Q.current,a)}var ee,te=m.ReactCurrentOwner,re=m.ReactDebugCurrentFrame;function ne(e){if(e){var t=e._owner,r=D(e.type,e._source,t?t.type:null);re.setExtraStackFrame(r)}else re.setExtraStackFrame(null)}function oe(e){return"object"==typeof e&&null!==e&&e.$$typeof===t}function ie(){if(te.current){var e=x(te.current.type);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}ee=!1;var se={};function le(e,t){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var r=function(e){var t=ie();if(!t){var r="string"==typeof e?e:e.displayName||e.name;r&&(t="\n\nCheck the top-level render call using <"+r+">.")}return t}(t);if(!se[r]){se[r]=!0;var n="";e&&e._owner&&e._owner!==te.current&&(n=" It was passed a child from "+x(e._owner.type)+"."),ne(e),g('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',r,n),ne(null)}}}function ce(e,t){if("object"==typeof e)if(z(e))for(var r=0;r<e.length;r++){var n=e[r];oe(n)&&le(n,t)}else if(oe(e))e._store&&(e._store.validated=!0);else if(e){var o=function(e){if(null===e||"object"!=typeof e)return null;var t=h&&e[h]||e["@@iterator"];return"function"==typeof t?t:null}(e);if("function"==typeof o&&o!==e.entries)for(var i,s=o.call(e);!(i=s.next()).done;)oe(i.value)&&le(i.value,t)}}function ue(e){var t,r=e.type;if(null!=r&&"string"!=typeof r){if("function"==typeof r)t=r.propTypes;else{if("object"!=typeof r||r.$$typeof!==l&&r.$$typeof!==d)return;t=r.propTypes}if(t){var n=x(r);!function(e,t,r,n,o){var i=Function.call.bind(L);for(var s in e)if(i(e,s)){var a=void 0;try{if("function"!=typeof e[s]){var l=Error((n||"React class")+": "+r+" type `"+s+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[s]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw l.name="Invariant Violation",l}a=e[s](t,s,n,r,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(e){a=e}!a||a instanceof Error||(Z(o),g("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",n||"React class",r,s,typeof a),Z(null)),a instanceof Error&&!(a.message in U)&&(U[a.message]=!0,Z(o),g("Failed %s type: %s",r,a.message),Z(null))}}(t,e.props,"prop",n,e)}else if(void 0!==r.PropTypes&&!ee){ee=!0,g("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",x(r)||"Unknown")}"function"!=typeof r.getDefaultProps||r.getDefaultProps.isReactClassApproved||g("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function de(e,r,h,m,y,v){var w=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===i||e===o||e===c||e===u||e===f||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===d||e.$$typeof===s||e.$$typeof===a||e.$$typeof===l||e.$$typeof===b||void 0!==e.getModuleId)}(e);if(!w){var E="";(void 0===e||"object"==typeof e&&null!==e&&0===Object.keys(e).length)&&(E+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var A,k=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(y);E+=k||ie(),null===e?A="null":z(e)?A="array":void 0!==e&&e.$$typeof===t?(A="<"+(x(e.type)||"Unknown")+" />",E=" Did you accidentally export a JSX literal instead of a component?"):A=typeof e,g("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",A,E)}var C=$(e,r,h,y,v);if(null==C)return C;if(w){var R=r.children;if(void 0!==R)if(m)if(z(R)){for(var S=0;S<R.length;S++)ce(R[S],e);Object.freeze&&Object.freeze(R)}else g("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else ce(R,e)}return e===n?function(e){for(var t=Object.keys(e.props),r=0;r<t.length;r++){var n=t[r];if("children"!==n&&"key"!==n){ne(e),g("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),ne(null);break}}null!==e.ref&&(ne(e),g("Invalid attribute `ref` supplied to `React.Fragment`."),ne(null))}(C):ue(C),C}var pe=function(e,t,r){return de(e,t,r,!1)},fe=function(e,t,r){return de(e,t,r,!0)};ae.Fragment=n,ae.jsx=pe,ae.jsxs=fe}()),ae}se=ne,"production"===process.env.NODE_ENV?se.exports=function(){if(re)return oe;re=1;var e=R.default,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function s(e,r,s){var a,l={},c=null,u=null;for(a in void 0!==s&&(c=""+s),void 0!==r.key&&(c=""+r.key),void 0!==r.ref&&(u=r.ref),r)n.call(r,a)&&!i.hasOwnProperty(a)&&(l[a]=r[a]);if(e&&e.defaultProps)for(a in r=e.defaultProps)void 0===l[a]&&(l[a]=r[a]);return{$$typeof:t,type:e,key:c,ref:u,props:l,_owner:o.current}}return oe.Fragment=r,oe.jsx=s,oe.jsxs=s,oe}():se.exports=le();var ce,ue={exports:{}},de={};var pe,fe={};
|
|
24
24
|
/**
|
|
25
25
|
* @license React
|
|
26
26
|
* react-is.development.js
|
|
@@ -29,12 +29,12 @@ object-assign
|
|
|
29
29
|
*
|
|
30
30
|
* This source code is licensed under the MIT license found in the
|
|
31
31
|
* LICENSE file in the root directory of this source tree.
|
|
32
|
-
*/function
|
|
32
|
+
*/function he(e){const{styles:t,defaultTheme:r={}}=e;return ne.exports.jsx(o.Global,{styles:"function"==typeof t?e=>{return t(null==(n=e)||0===Object.keys(n).length?r:e);var n}:t})}
|
|
33
33
|
/** @license MUI v5.10.8
|
|
34
34
|
*
|
|
35
35
|
* This source code is licensed under the MIT license found in the
|
|
36
36
|
* LICENSE file in the root directory of this source tree.
|
|
37
|
-
*/function me(e,t){const r=S.default(e,t);return"production"!==process.env.NODE_ENV?(...t)=>{const n="string"==typeof e?`"${e}"`:"component";return 0===t.length?console.error([`MUI: Seems like you called \`styled(${n})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join("\n")):t.some((e=>void 0===e))&&console.error(`MUI: the styled(${n})(...args) API requires all its args to be defined.`),r(...t)}:r}!function(e){"production"===process.env.NODE_ENV?e.exports=function(){if(ce)return de;ce=1;var e,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),f=Symbol.for("react.offscreen");function m(e){if("object"==typeof e&&null!==e){var f=e.$$typeof;switch(f){case t:switch(e=e.type){case n:case i:case o:case u:case d:return e;default:switch(e=e&&e.$$typeof){case l:case a:case c:case h:case p:case s:return e;default:return f}}case r:return f}}}return e=Symbol.for("react.module.reference"),de.ContextConsumer=a,de.ContextProvider=s,de.Element=t,de.ForwardRef=c,de.Fragment=n,de.Lazy=h,de.Memo=p,de.Portal=r,de.Profiler=i,de.StrictMode=o,de.Suspense=u,de.SuspenseList=d,de.isAsyncMode=function(){return!1},de.isConcurrentMode=function(){return!1},de.isContextConsumer=function(e){return m(e)===a},de.isContextProvider=function(e){return m(e)===s},de.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},de.isForwardRef=function(e){return m(e)===c},de.isFragment=function(e){return m(e)===n},de.isLazy=function(e){return m(e)===h},de.isMemo=function(e){return m(e)===p},de.isPortal=function(e){return m(e)===r},de.isProfiler=function(e){return m(e)===i},de.isStrictMode=function(e){return m(e)===o},de.isSuspense=function(e){return m(e)===u},de.isSuspenseList=function(e){return m(e)===d},de.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===n||t===i||t===o||t===u||t===d||t===f||"object"==typeof t&&null!==t&&(t.$$typeof===h||t.$$typeof===p||t.$$typeof===s||t.$$typeof===a||t.$$typeof===c||t.$$typeof===e||void 0!==t.getModuleId)},de.typeOf=m,de}():e.exports=(pe||(pe=1,"production"!==process.env.NODE_ENV&&function(){var e,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),f=Symbol.for("react.offscreen");function m(e){if("object"==typeof e&&null!==e){var f=e.$$typeof;switch(f){case t:var m=e.type;switch(m){case n:case i:case o:case u:case d:return m;default:var g=m&&m.$$typeof;switch(g){case l:case a:case c:case h:case p:case s:return g;default:return f}}case r:return f}}}e=Symbol.for("react.module.reference");var g=a,y=s,b=t,x=c,v=n,w=h,E=p,A=r,C=i,k=o,R=u,T=d,S=!1,N=!1;he.ContextConsumer=g,he.ContextProvider=y,he.Element=b,he.ForwardRef=x,he.Fragment=v,he.Lazy=w,he.Memo=E,he.Portal=A,he.Profiler=C,he.StrictMode=k,he.Suspense=R,he.SuspenseList=T,he.isAsyncMode=function(e){return S||(S=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1},he.isConcurrentMode=function(e){return N||(N=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1},he.isContextConsumer=function(e){return m(e)===a},he.isContextProvider=function(e){return m(e)===s},he.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},he.isForwardRef=function(e){return m(e)===c},he.isFragment=function(e){return m(e)===n},he.isLazy=function(e){return m(e)===h},he.isMemo=function(e){return m(e)===p},he.isPortal=function(e){return m(e)===r},he.isProfiler=function(e){return m(e)===i},he.isStrictMode=function(e){return m(e)===o},he.isSuspense=function(e){return m(e)===u},he.isSuspenseList=function(e){return m(e)===d},he.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===n||t===i||t===o||t===u||t===d||t===f||"object"==typeof t&&null!==t&&(t.$$typeof===h||t.$$typeof===p||t.$$typeof===s||t.$$typeof===a||t.$$typeof===c||t.$$typeof===e||void 0!==t.getModuleId)},he.typeOf=m}()),he)}(ue),"production"!==process.env.NODE_ENV&&(fe.propTypes={defaultTheme:j.exports.object,styles:j.exports.oneOfType([j.exports.string,j.exports.object,j.exports.func])});var ge="production"!==process.env.NODE_ENV?j.exports.oneOfType([j.exports.number,j.exports.string,j.exports.object,j.exports.array]):{};function ye(e,t){return"production"===process.env.NODE_ENV?()=>null:function(...r){return e(...r)||t(...r)}}function be(){return be=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},be.apply(this,arguments)}function xe(e){return null!==e&&"object"==typeof e&&e.constructor===Object}function ve(e){if(!xe(e))return e;const t={};return Object.keys(e).forEach((r=>{t[r]=ve(e[r])})),t}function we(e,t,r={clone:!0}){const n=r.clone?be({},e):e;return xe(e)&&xe(t)&&Object.keys(t).forEach((o=>{"__proto__"!==o&&(xe(t[o])&&o in e&&xe(e[o])?n[o]=we(e[o],t[o],r):r.clone?n[o]=xe(t[o])?ve(t[o]):t[o]:n[o]=t[o])})),n}function Ee(e,t,r,n,o){const i=e[t],s=o||t;if(null==i||"undefined"==typeof window)return null;let a;const l=i.type;return"function"!=typeof l||function(e){const{prototype:t={}}=e;return Boolean(t.isReactComponent)}(l)||(a="Did you accidentally use a plain function component for an element instead?"),void 0!==a?new Error(`Invalid ${n} \`${s}\` supplied to \`${r}\`. Expected an element that can hold a ref. ${a} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Ae=ye(j.exports.element,Ee);Ae.isRequired=ye(j.exports.element.isRequired,Ee);var Ce=Ae;function ke(e){return"production"===process.env.NODE_ENV?e:be({},e,{"exact-prop: ":t=>{const r=Object.keys(t).filter((t=>!e.hasOwnProperty(t)));return r.length>0?new Error(`The following props are not supported: ${r.map((e=>`\`${e}\``)).join(", ")}. Please remove them.`):null}})}function Re(e){let t="https://mui.com/production-error/?code="+e;for(let e=1;e<arguments.length;e+=1)t+="&args[]="+encodeURIComponent(arguments[e]);return"Minified MUI error #"+e+"; visit "+t+" for the full message."}const Te=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Se(e,t=""){return e.displayName||e.name||function(e){const t=`${e}`.match(Te);return t&&t[1]||""}(e)||t}function Ne(e,t,r){const n=Se(t);return e.displayName||(""!==n?`${r}(${n})`:r)}function Me(e,t,r,n,o){if("production"===process.env.NODE_ENV)return null;const i=e[t],s=o||t;return null==i?null:i&&1!==i.nodeType?new Error(`Invalid ${n} \`${s}\` supplied to \`${r}\`. Expected an HTMLElement.`):null}var Fe=j.exports.oneOfType([j.exports.func,j.exports.object]);function Oe(e){if("string"!=typeof e)throw new Error("production"!==process.env.NODE_ENV?"MUI: `capitalize(string)` expects a string argument.":Re(7));return e.charAt(0).toUpperCase()+e.slice(1)}function Ie(...e){return e.reduce(((e,t)=>null==t?e:function(...r){e.apply(this,r),t.apply(this,r)}),(()=>{}))}function je(e){return e&&e.ownerDocument||document}function De(e){return je(e).defaultView||window}function Be(e,t){"function"==typeof e?e(t):e&&(e.current=t)}var Pe="undefined"!=typeof window?T.useLayoutEffect:T.useEffect;function We(e){const t=T.useRef(e);return Pe((()=>{t.current=e})),T.useCallback(((...e)=>(0,t.current)(...e)),[])}function _e(...e){return T.useMemo((()=>e.every((e=>null==e))?null:t=>{e.forEach((e=>{Be(e,t)}))}),e)}let Ue,Le=!0,Ve=!1;const Ze={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function He(e){e.metaKey||e.altKey||e.ctrlKey||(Le=!0)}function ze(){Le=!1}function Ye(){"hidden"===this.visibilityState&&Ve&&(Le=!0)}function Ge(){const e=T.useCallback((e=>{var t;null!=e&&((t=e.ownerDocument).addEventListener("keydown",He,!0),t.addEventListener("mousedown",ze,!0),t.addEventListener("pointerdown",ze,!0),t.addEventListener("touchstart",ze,!0),t.addEventListener("visibilitychange",Ye,!0))}),[]),t=T.useRef(!1);return{isFocusVisibleRef:t,onFocus:function(e){return!!function(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch(e){}return Le||function(e){const{type:t,tagName:r}=e;return!("INPUT"!==r||!Ze[t]||e.readOnly)||"TEXTAREA"===r&&!e.readOnly||!!e.isContentEditable}(t)}(e)&&(t.current=!0,!0)},onBlur:function(){return!!t.current&&(Ve=!0,window.clearTimeout(Ue),Ue=window.setTimeout((()=>{Ve=!1}),100),t.current=!1,!0)},ref:e}}function Xe(e,t){const r=be({},t);return Object.keys(e).forEach((n=>{if(n.toString().match(/^(components|slots)$/))r[n]=be({},e[n],r[n]);else if(n.toString().match(/^(componentsProps|slotProps)$/)){const o=e[n]||{},i=t[n];r[n]={},i&&Object.keys(i)?o&&Object.keys(o)?(r[n]=be({},i),Object.keys(o).forEach((e=>{r[n][e]=Xe(o[e],i[e])}))):r[n]=i:r[n]=o}else void 0===r[n]&&(r[n]=e[n])})),r}function Je(e,t,r){const n={};return Object.keys(e).forEach((o=>{n[o]=e[o].reduce(((e,n)=>{if(n){const o=t(n);""!==o&&e.push(o),r&&r[n]&&e.push(r[n])}return e}),[]).join(" ")})),n}const qe=e=>e;var Qe=(()=>{let e=qe;return{configure(t){e=t},generate:t=>e(t),reset(){e=qe}}})();const Ke={active:"active",checked:"checked",completed:"completed",disabled:"disabled",readOnly:"readOnly",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",required:"required",selected:"selected"};function $e(e,t,r="Mui"){const n=Ke[t];return n?`${r}-${n}`:`${Qe.generate(e)}-${t}`}function et(e,t,r="Mui"){const n={};return t.forEach((t=>{n[t]=$e(e,t,r)})),n}function tt(e,t){return t?we(e,t,{clone:!1}):e}const rt={xs:0,sm:600,md:900,lg:1200,xl:1536},nt={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${rt[e]}px)`};function ot(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const e=n.breakpoints||nt;return t.reduce(((n,o,i)=>(n[e.up(e.keys[i])]=r(t[i]),n)),{})}if("object"==typeof t){const e=n.breakpoints||nt;return Object.keys(t).reduce(((n,o)=>{if(-1!==Object.keys(e.values||rt).indexOf(o))n[e.up(o)]=r(t[o],o);else{const e=o;n[e]=t[e]}return n}),{})}return r(t)}function it(e,t,r=!0){if(!t||"string"!=typeof t)return null;if(e&&e.vars&&r){const r=`vars.${t}`.split(".").reduce(((e,t)=>e&&e[t]?e[t]:null),e);if(null!=r)return r}return t.split(".").reduce(((e,t)=>e&&null!=e[t]?e[t]:null),e)}function st(e,t,r,n=r){let o;return o="function"==typeof e?e(r):Array.isArray(e)?e[r]||n:it(e,r)||n,t&&(o=t(o)),o}function at(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:o}=e,i=e=>{if(null==e[t])return null;const i=e[t],s=it(e.theme,n)||{};return ot(e,i,(e=>{let n=st(s,o,e);return e===n&&"string"==typeof e&&(n=st(s,o,`${t}${"default"===e?"":Oe(e)}`,e)),!1===r?n:{[r]:n}}))};return i.propTypes="production"!==process.env.NODE_ENV?{[t]:ge}:{},i.filterProps=[t],i}function lt(...e){const t=e.reduce(((e,t)=>(t.filterProps.forEach((r=>{e[r]=t})),e)),{}),r=e=>Object.keys(e).reduce(((r,n)=>t[n]?tt(r,t[n](e)):r),{});return r.propTypes="production"!==process.env.NODE_ENV?e.reduce(((e,t)=>Object.assign(e,t.propTypes)),{}):{},r.filterProps=e.reduce(((e,t)=>e.concat(t.filterProps)),[]),r}const ct={m:"margin",p:"padding"},ut={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},dt={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},pt=function(e){const t={};return e=>(void 0===t[e]&&(t[e]=(e=>{if(e.length>2){if(!dt[e])return[e];e=dt[e]}const[t,r]=e.split(""),n=ct[t],o=ut[r]||"";return Array.isArray(o)?o.map((e=>n+e)):[n+o]})(e)),t[e])}(),ht=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],ft=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],mt=[...ht,...ft];function gt(e,t,r,n){var o;const i=null!=(o=it(e,t,!1))?o:r;return"number"==typeof i?e=>"string"==typeof e?e:("production"!==process.env.NODE_ENV&&"number"!=typeof e&&console.error(`MUI: Expected ${n} argument to be a number or a string, got ${e}.`),i*e):Array.isArray(i)?e=>"string"==typeof e?e:("production"!==process.env.NODE_ENV&&(Number.isInteger(e)?e>i.length-1&&console.error([`MUI: The value provided (${e}) overflows.`,`The supported values are: ${JSON.stringify(i)}.`,`${e} > ${i.length-1}, you need to add the missing values.`].join("\n")):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join("\n"))),i[e]):"function"==typeof i?i:("production"!==process.env.NODE_ENV&&console.error([`MUI: The \`theme.${t}\` value (${i}) is invalid.`,"It should be a number, an array or a function."].join("\n")),()=>{})}function yt(e){return gt(e,"spacing",8,"spacing")}function bt(e,t){if("string"==typeof t||null==t)return t;const r=e(Math.abs(t));return t>=0?r:"number"==typeof r?-r:`-${r}`}function xt(e){return function(e,t){const r=yt(e.theme);return Object.keys(e).map((n=>function(e,t,r,n){if(-1===t.indexOf(r))return null;const o=function(e,t){return r=>e.reduce(((e,n)=>(e[n]=bt(t,r),e)),{})}(pt(r),n);return ot(e,e[r],o)}(e,t,n,r))).reduce(tt,{})}(e,mt)}function vt(e){return"number"!=typeof e?e:`${e}px solid`}"production"===process.env.NODE_ENV||ht.reduce(((e,t)=>(e[t]=ge,e)),{}),"production"===process.env.NODE_ENV||ft.reduce(((e,t)=>(e[t]=ge,e)),{}),xt.propTypes="production"!==process.env.NODE_ENV?mt.reduce(((e,t)=>(e[t]=ge,e)),{}):{},xt.filterProps=mt;const wt=at({prop:"border",themeKey:"borders",transform:vt}),Et=at({prop:"borderTop",themeKey:"borders",transform:vt}),At=at({prop:"borderRight",themeKey:"borders",transform:vt}),Ct=at({prop:"borderBottom",themeKey:"borders",transform:vt}),kt=at({prop:"borderLeft",themeKey:"borders",transform:vt}),Rt=at({prop:"borderColor",themeKey:"palette"}),Tt=at({prop:"borderTopColor",themeKey:"palette"}),St=at({prop:"borderRightColor",themeKey:"palette"}),Nt=at({prop:"borderBottomColor",themeKey:"palette"}),Mt=at({prop:"borderLeftColor",themeKey:"palette"}),Ft=e=>{if(void 0!==e.borderRadius&&null!==e.borderRadius){const t=gt(e.theme,"shape.borderRadius",4,"borderRadius"),r=e=>({borderRadius:bt(t,e)});return ot(e,e.borderRadius,r)}return null};Ft.propTypes="production"!==process.env.NODE_ENV?{borderRadius:ge}:{},Ft.filterProps=["borderRadius"];var Ot=lt(wt,Et,At,Ct,kt,Rt,Tt,St,Nt,Mt,Ft),It=lt(at({prop:"displayPrint",cssProperty:!1,transform:e=>({"@media print":{display:e}})}),at({prop:"display"}),at({prop:"overflow"}),at({prop:"textOverflow"}),at({prop:"visibility"}),at({prop:"whiteSpace"})),jt=lt(at({prop:"flexBasis"}),at({prop:"flexDirection"}),at({prop:"flexWrap"}),at({prop:"justifyContent"}),at({prop:"alignItems"}),at({prop:"alignContent"}),at({prop:"order"}),at({prop:"flex"}),at({prop:"flexGrow"}),at({prop:"flexShrink"}),at({prop:"alignSelf"}),at({prop:"justifyItems"}),at({prop:"justifySelf"}));const Dt=e=>{if(void 0!==e.gap&&null!==e.gap){const t=gt(e.theme,"spacing",8,"gap"),r=e=>({gap:bt(t,e)});return ot(e,e.gap,r)}return null};Dt.propTypes="production"!==process.env.NODE_ENV?{gap:ge}:{},Dt.filterProps=["gap"];const Bt=e=>{if(void 0!==e.columnGap&&null!==e.columnGap){const t=gt(e.theme,"spacing",8,"columnGap"),r=e=>({columnGap:bt(t,e)});return ot(e,e.columnGap,r)}return null};Bt.propTypes="production"!==process.env.NODE_ENV?{columnGap:ge}:{},Bt.filterProps=["columnGap"];const Pt=e=>{if(void 0!==e.rowGap&&null!==e.rowGap){const t=gt(e.theme,"spacing",8,"rowGap"),r=e=>({rowGap:bt(t,e)});return ot(e,e.rowGap,r)}return null};Pt.propTypes="production"!==process.env.NODE_ENV?{rowGap:ge}:{},Pt.filterProps=["rowGap"];var Wt=lt(Dt,Bt,Pt,at({prop:"gridColumn"}),at({prop:"gridRow"}),at({prop:"gridAutoFlow"}),at({prop:"gridAutoColumns"}),at({prop:"gridAutoRows"}),at({prop:"gridTemplateColumns"}),at({prop:"gridTemplateRows"}),at({prop:"gridTemplateAreas"}),at({prop:"gridArea"})),_t=lt(at({prop:"color",themeKey:"palette"}),at({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette"}),at({prop:"backgroundColor",themeKey:"palette"})),Ut=lt(at({prop:"position"}),at({prop:"zIndex",themeKey:"zIndex"}),at({prop:"top"}),at({prop:"right"}),at({prop:"bottom"}),at({prop:"left"})),Lt=at({prop:"boxShadow",themeKey:"shadows"});function Vt(e){return e<=1&&0!==e?100*e+"%":e}const Zt=at({prop:"width",transform:Vt}),Ht=e=>{if(void 0!==e.maxWidth&&null!==e.maxWidth){const t=t=>{var r,n,o;return{maxWidth:(null==(r=e.theme)||null==(n=r.breakpoints)||null==(o=n.values)?void 0:o[t])||rt[t]||Vt(t)}};return ot(e,e.maxWidth,t)}return null};Ht.filterProps=["maxWidth"];const zt=at({prop:"minWidth",transform:Vt}),Yt=at({prop:"height",transform:Vt}),Gt=at({prop:"maxHeight",transform:Vt}),Xt=at({prop:"minHeight",transform:Vt});at({prop:"size",cssProperty:"width",transform:Vt}),at({prop:"size",cssProperty:"height",transform:Vt});var Jt=lt(Zt,Ht,zt,Yt,Gt,Xt,at({prop:"boxSizing"}));const qt=at({prop:"fontFamily",themeKey:"typography"}),Qt=at({prop:"fontSize",themeKey:"typography"}),Kt=at({prop:"fontStyle",themeKey:"typography"}),$t=at({prop:"fontWeight",themeKey:"typography"}),er=at({prop:"letterSpacing"}),tr=at({prop:"textTransform"}),rr=at({prop:"lineHeight"}),nr=at({prop:"textAlign"});var or=lt(at({prop:"typography",cssProperty:!1,themeKey:"typography"}),qt,Qt,Kt,$t,er,rr,nr,tr);const ir={borders:Ot.filterProps,display:It.filterProps,flexbox:jt.filterProps,grid:Wt.filterProps,positions:Ut.filterProps,palette:_t.filterProps,shadows:Lt.filterProps,sizing:Jt.filterProps,spacing:xt.filterProps,typography:or.filterProps},sr={borders:Ot,display:It,flexbox:jt,grid:Wt,positions:Ut,palette:_t,shadows:Lt,sizing:Jt,spacing:xt,typography:or},ar=Object.keys(ir).reduce(((e,t)=>(ir[t].forEach((r=>{e[r]=sr[t]})),e)),{}),lr=function(e=sr){const t=Object.keys(e).reduce(((t,r)=>(e[r].filterProps.forEach((n=>{t[n]=e[r]})),t)),{});function r(e,r,n){const o={[e]:r,theme:n},i=t[e];return i?i(o):{[e]:r}}return function e(n){const{sx:o,theme:i={}}=n||{};if(!o)return null;function s(n){let o=n;if("function"==typeof n)o=n(i);else if("object"!=typeof n)return n;if(!o)return null;const s=function(e={}){var t;return(null==e||null==(t=e.keys)?void 0:t.reduce(((t,r)=>(t[e.up(r)]={},t)),{}))||{}}(i.breakpoints),a=Object.keys(s);let l=s;return Object.keys(o).forEach((n=>{const s="function"==typeof(a=o[n])?a(i):a;var a;if(null!=s)if("object"==typeof s)if(t[n])l=tt(l,r(n,s,i));else{const t=ot({theme:i},s,(e=>({[n]:e})));!function(...e){const t=e.reduce(((e,t)=>e.concat(Object.keys(t))),[]),r=new Set(t);return e.every((e=>r.size===Object.keys(e).length))}(t,s)?l=tt(l,t):l[n]=e({sx:s,theme:i})}else l=tt(l,r(n,s,i))})),function(e,t){return e.reduce(((e,t)=>{const r=e[t];return(!r||0===Object.keys(r).length)&&delete e[t],e}),t)}(a,l)}return Array.isArray(o)?o.map(s):s(o)}}();lr.filterProps=["sx"];var cr=lr;function ur(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}const dr=["sx"];function pr(e){var t,r,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(r=pr(e[t]))&&(n&&(n+=" "),n+=r);else for(t in e)e[t]&&(n&&(n+=" "),n+=t);return n}function hr(){for(var e,t,r=0,n="";r<arguments.length;)(e=arguments[r++])&&(t=pr(e))&&(n&&(n+=" "),n+=t);return n}const fr=["values","unit","step"];var mr={borderRadius:4};const gr=["breakpoints","palette","spacing","shape"];function yr(e={},...t){const{breakpoints:r={},palette:n={},spacing:o,shape:i={}}=e,s=ur(e,gr),a=function(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5}=e,o=ur(e,fr),i=(e=>{const t=Object.keys(e).map((t=>({key:t,val:e[t]})))||[];return t.sort(((e,t)=>e.val-t.val)),t.reduce(((e,t)=>be({},e,{[t.key]:t.val})),{})})(t),s=Object.keys(i);function a(e){return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r})`}function l(e){return`@media (max-width:${("number"==typeof t[e]?t[e]:e)-n/100}${r})`}function c(e,o){const i=s.indexOf(o);return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r}) and (max-width:${(-1!==i&&"number"==typeof t[s[i]]?t[s[i]]:o)-n/100}${r})`}return be({keys:s,values:i,up:a,down:l,between:c,only:function(e){return s.indexOf(e)+1<s.length?c(e,s[s.indexOf(e)+1]):a(e)},not:function(e){const t=s.indexOf(e);return 0===t?a(s[1]):t===s.length-1?l(s[t]):c(e,s[s.indexOf(e)+1]).replace("@media","@media not all and")},unit:r},o)}(r),l=function(e=8){if(e.mui)return e;const t=yt({spacing:e}),r=(...e)=>("production"!==process.env.NODE_ENV&&(e.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${e.length}`)),(0===e.length?[1]:e).map((e=>{const r=t(e);return"number"==typeof r?`${r}px`:r})).join(" "));return r.mui=!0,r}(o);let c=we({breakpoints:a,direction:"ltr",components:{},palette:be({mode:"light"},n),spacing:l,shape:be({},mr,i)},s);return c=t.reduce(((e,t)=>we(e,t)),c),c}const br=T.createContext(null);"production"!==process.env.NODE_ENV&&(br.displayName="ThemeContext");var xr=br;function vr(){const e=T.useContext(xr);return"production"!==process.env.NODE_ENV&&T.useDebugValue(e),e}var wr="function"==typeof Symbol&&Symbol.for?Symbol.for("mui.nested"):"__THEME_NESTED__";function Er(e){const{children:t,theme:r}=e,n=vr();"production"!==process.env.NODE_ENV&&null===n&&"function"==typeof r&&console.error(["MUI: You are providing a theme function prop to the ThemeProvider component:","<ThemeProvider theme={outerTheme => outerTheme} />","","However, no outer theme is present.","Make sure a theme is already injected higher in the React tree or provide a theme object."].join("\n"));const o=T.useMemo((()=>{const e=null===n?r:function(e,t){if("function"==typeof t){const r=t(e);return"production"!==process.env.NODE_ENV&&(r||console.error(["MUI: You should return an object from your theme function, i.e.","<ThemeProvider theme={() => ({})} />"].join("\n"))),r}return be({},e,t)}(n,r);return null!=e&&(e[wr]=null!==n),e}),[r,n]);return ne.exports.jsx(xr.Provider,{value:o,children:t})}function Ar(e=null){const t=vr();return t&&(r=t,0!==Object.keys(r).length)?t:e;var r}"production"!==process.env.NODE_ENV&&(Er.propTypes={children:j.exports.node,theme:j.exports.oneOfType([j.exports.object,j.exports.func]).isRequired}),"production"!==process.env.NODE_ENV&&"production"!==process.env.NODE_ENV&&(Er.propTypes=ke(Er.propTypes));const Cr=yr();function kr(e=Cr){return Ar(e)}const Rr=["className","component"],Tr=function(e={}){const{defaultTheme:t,defaultClassName:r="MuiBox-root",generateClassName:n,styleFunctionSx:o=cr}=e,i=me("div")(o);return T.forwardRef((function(e,o){const s=kr(t),a=function(e){const{sx:t}=e,r=ur(e,dr),{systemProps:n,otherProps:o}=(e=>{const t={systemProps:{},otherProps:{}};return Object.keys(e).forEach((r=>{ar[r]?t.systemProps[r]=e[r]:t.otherProps[r]=e[r]})),t})(r);let i;return i=Array.isArray(t)?[n,...t]:"function"==typeof t?(...e)=>{const r=t(...e);return xe(r)?be({},n,r):n}:be({},n,t),be({},o,{sx:i})}(e),{className:l,component:c="div"}=a,u=ur(a,Rr);return ne.exports.jsx(i,be({as:c,ref:o,className:hr(l,n?n(r):r),theme:s},u))}))}();"production"!==process.env.NODE_ENV&&(Tr.propTypes={children:j.exports.node,component:j.exports.elementType,sx:j.exports.oneOfType([j.exports.arrayOf(j.exports.oneOfType([j.exports.func,j.exports.object,j.exports.bool])),j.exports.func,j.exports.object])});var Sr=Tr;const Nr=["variant"];function Mr(e){return 0===e.length}function Fr(e){const{variant:t}=e,r=ur(e,Nr);let n=t||"";return Object.keys(r).sort().forEach((t=>{n+="color"===t?Mr(n)?e[t]:Oe(e[t]):`${Mr(n)?t:Oe(t)}${Oe(e[t].toString())}`})),n}const Or=["name","slot","skipVariantsResolver","skipSx","overridesResolver"],Ir=["theme"],jr=["theme"];function Dr(e){return 0===Object.keys(e).length}function Br(e){return"ownerState"!==e&&"theme"!==e&&"sx"!==e&&"as"!==e}const Pr=yr(),Wr=function(e={}){const{defaultTheme:t=Pr,rootShouldForwardProp:r=Br,slotShouldForwardProp:n=Br,styleFunctionSx:o=cr}=e;return(e,i={})=>{const{name:s,slot:a,skipVariantsResolver:l,skipSx:c,overridesResolver:u}=i,d=ur(i,Or),p=void 0!==l?l:a&&"Root"!==a||!1,h=c||!1;let f;var m;"production"!==process.env.NODE_ENV&&s&&(f=`${s}-${m=a||"Root",m.charAt(0).toLowerCase()+m.slice(1)}`);let g=Br;"Root"===a?g=r:a&&(g=n);const y=me(e,be({shouldForwardProp:g,label:f},d)),b=(r,...n)=>{const i=n?n.map((e=>"function"==typeof e&&e.__emotion_real!==e?r=>{let{theme:n}=r,o=ur(r,Ir);return e(be({theme:Dr(n)?t:n},o))}:e)):[];let l=r;s&&u&&i.push((e=>{const r=Dr(e.theme)?t:e.theme,n=((e,t)=>t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null)(s,r);if(n){const t={};return Object.entries(n).forEach((([n,o])=>{t[n]="function"==typeof o?o(be({},e,{theme:r})):o})),u(e,t)}return null})),s&&!p&&i.push((e=>{const r=Dr(e.theme)?t:e.theme;return((e,t,r,n)=>{var o,i;const{ownerState:s={}}=e,a=[],l=null==r||null==(o=r.components)||null==(i=o[n])?void 0:i.variants;return l&&l.forEach((r=>{let n=!0;Object.keys(r.props).forEach((t=>{s[t]!==r.props[t]&&e[t]!==r.props[t]&&(n=!1)})),n&&a.push(t[Fr(r.props)])})),a})(e,((e,t)=>{let r=[];t&&t.components&&t.components[e]&&t.components[e].variants&&(r=t.components[e].variants);const n={};return r.forEach((e=>{const t=Fr(e.props);n[t]=e.style})),n})(s,r),r,s)})),h||i.push((e=>{const r=Dr(e.theme)?t:e.theme;return o(be({},e,{theme:r}))}));const c=i.length-n.length;if(Array.isArray(r)&&c>0){const e=new Array(c).fill("");l=[...r,...e],l.raw=[...r.raw,...e]}else"function"==typeof r&&r.__emotion_real!==r&&(l=e=>{let{theme:n}=e,o=ur(e,jr);return r(be({theme:Dr(n)?t:n},o))});const d=y(l,...i);if("production"!==process.env.NODE_ENV){let t;s&&(t=`${s}${a||""}`),void 0===t&&(t=`Styled(${function(e){if(null!=e){if("string"==typeof e)return e;if("function"==typeof e)return Se(e,"Component");if("object"==typeof e)switch(e.$$typeof){case ue.exports.ForwardRef:return Ne(e,e.render,"ForwardRef");case ue.exports.Memo:return Ne(e,e.type,"memo");default:return}}}(e)})`),d.displayName=t}return d};return y.withConfig&&(b.withConfig=y.withConfig),b}}();var _r=Wr;function Ur(e){const{theme:t,name:r,props:n}=e;return t&&t.components&&t.components[r]&&t.components[r].defaultProps?Xe(t.components[r].defaultProps,n):n}function Lr(e){if(e.type)return e;if("#"===e.charAt(0))return Lr(function(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let r=e.match(t);return r&&1===r[0].length&&(r=r.map((e=>e+e))),r?`rgb${4===r.length?"a":""}(${r.map(((e,t)=>t<3?parseInt(e,16):Math.round(parseInt(e,16)/255*1e3)/1e3)).join(", ")})`:""}(e));const t=e.indexOf("("),r=e.substring(0,t);if(-1===["rgb","rgba","hsl","hsla","color"].indexOf(r))throw new Error("production"!==process.env.NODE_ENV?`MUI: Unsupported \`${e}\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:Re(9,e));let n,o=e.substring(t+1,e.length-1);if("color"===r){if(o=o.split(" "),n=o.shift(),4===o.length&&"/"===o[3].charAt(0)&&(o[3]=o[3].slice(1)),-1===["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(n))throw new Error("production"!==process.env.NODE_ENV?`MUI: unsupported \`${n}\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:Re(10,n))}else o=o.split(",");return o=o.map((e=>parseFloat(e))),{type:r,values:o,colorSpace:n}}function Vr(e,t){return e=Lr(e),t=function(e,t=0,r=1){return"production"!==process.env.NODE_ENV&&(e<t||e>r)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${r}].`),Math.min(Math.max(t,e),r)}(t),"rgb"!==e.type&&"hsl"!==e.type||(e.type+="a"),"color"===e.type?e.values[3]=`/${t}`:e.values[3]=t,function(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return-1!==t.indexOf("rgb")?n=n.map(((e,t)=>t<3?parseInt(e,10):e)):-1!==t.indexOf("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),n=-1!==t.indexOf("color")?`${r} ${n.join(" ")}`:`${n.join(", ")}`,`${t}(${n})`}(e)}function Zr(e){const t=kr();return ne.exports.jsx(o.ThemeContext.Provider,{value:"object"==typeof t?t:{},children:e.children})}function Hr(e){const{children:t,theme:r}=e;return ne.exports.jsx(Er,{theme:r,children:ne.exports.jsx(Zr,{children:t})})}"production"!==process.env.NODE_ENV&&(Zr.propTypes={children:j.exports.node}),"production"!==process.env.NODE_ENV&&(Hr.propTypes={children:j.exports.node,theme:j.exports.oneOfType([j.exports.func,j.exports.object]).isRequired}),"production"!==process.env.NODE_ENV&&"production"!==process.env.NODE_ENV&&(Hr.propTypes=ke(Hr.propTypes));var zr=function(){return zr=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},zr.apply(this,arguments)};function Yr(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}function Gr(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,o,i=r.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(e){o={error:e}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s}function Xr(e,t,r){if(r||2===arguments.length)for(var n,o=0,i=t.length;o<i;o++)!n&&o in t||(n||(n=Array.prototype.slice.call(t,0,o)),n[o]=t[o]);return e.concat(n||Array.prototype.slice.call(t))}function Jr(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var qr={mode:"dark",primary:{main:"#FFE804"},secondary:{main:"#FFE804",contrastText:"#1A1A1B"},error:{main:"#FF6187",contrastText:"#FFFFFF"},warning:{main:"#EB8D27",contrastText:"#1A1A1B"},success:{main:"#55F9C7",contrastText:"#1A1A1B"},purple:{main:"#BC9CFF",contrastText:"#1A1A1B"},background:{default:"#252831",paper:"#33363F",paperContrast:"#41454F",backdrop:Vr("#000",.9),input:"#252831",tag:Vr("#FFF",.04)},text:{primary:"#FFF",secondary:Vr("#FFF",.5),disabled:Vr("#FFF",.3),placeholder:Vr("#FFF",.3),link:"#FFE804"},border:{main:Vr("#FFF",.1),light:Vr("#FFF",.3),disabled:Vr("#FFF",.1)},hover:{default:Vr("#FFF",.1)}},Qr={mode:"light",primary:{main:"#1A1A1B"},secondary:{main:"#FFE804",contrastText:"#1A1A1B"},error:{main:"#EC5A7D",contrastText:"#FFFFFF"},warning:{main:"#B15600",contrastText:"#1A1A1B"},success:{main:"#2FBA90",contrastText:"#1A1A1B"},purple:{main:"#6851B4",contrastText:"#1A1A1B"},background:{default:"#F9F6E8",paper:"#FFFFFF",paperContrast:"#F6F6F6",backdrop:Vr("#000",.9),input:"#F0F0F0",tag:Vr("#1A1A1B",.04)},text:{primary:"#1A1A1B",secondary:Vr("#1A1A1B",.5),disabled:Vr("#1A1A1B",.3),placeholder:Vr("#1A1A1B",.3),link:"#1A1A1B"},border:{main:Vr("#1A1A1B",.1),light:Vr("#1A1A1B",.3),disabled:Vr("#1A1A1B",.1)},hover:{default:Vr("#1A1A1B",.1)}},Kr=function(e,t,n){var o,i,s,a="light"===e,l=n?function(e){return["zh-CN","ja-JP","ko-KR"].includes(e)?400:500}(n):400,c=a?Qr:qr;(null===(o=null==t?void 0:t.palette)||void 0===o?void 0:o.mode)===e&&(c=t.palette);var u={spacing:1,shape:{borderRadius:1},breakpoints:{values:{mobile:0,tablet:768,laptop:1024,desktop:1200,largeDesktop:1536}},typography:{fontFamily:Xr(Xr(["Manrope"],Gr("ja-JP"===n?["Meiryo"]:[]),!1),["Poppins","Inter","PingFangSC-Regular",'"Microsoft YaHei"',"sans-serif"],!1).join(","),fontSize:16,h1:{fontSize:36,lineHeight:"49px",fontWeight:600},h2:{fontSize:32,fontWeight:600,lineHeight:"44px"},h3:{fontSize:28,fontWeight:600,lineHeight:"38px"},caption:{fontSize:20,fontWeight:600,lineHeight:"28px"},h5:{fontSize:18,lineHeight:"24px",fontWeight:600},body1:{fontSize:16,lineHeight:"22px",fontWeight:l},body2:{fontSize:14,lineHeight:"19px",fontWeight:l},h6:{fontSize:12,lineHeight:"17px",fontWeight:l},button:{fontSize:16,lineHeight:1,fontWeight:600}},components:{MuiCssBaseline:{styleOverrides:{"::-webkit-scrollbar":{width:6,backgroundColor:"transparent"},"::-webkit-scrollbar-thumb":{backgroundColor:null===(i=c.border)||void 0===i?void 0:i.main,borderColor:null===(s=c.border)||void 0===s?void 0:s.main,borderRadius:100}}},MuiTypography:{defaultProps:{variantMapping:{h1:"h2",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"div",caption:"h5",subtitle1:"h5",subtitle2:"h5",body1:"div",body2:"div"}}}},zIndex:{tooltip:1500}};return zr(zr({},r.merge(u,t)),{palette:c})};var $r=function(e,t){var r;return zr({WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",boxSizing:"border-box",WebkitTextSizeAdjust:"100%"},t&&{colorScheme:null===(r=e.palette)||void 0===r?void 0:r.mode})},en=function(e){var t,r,n;return zr({color:null===(t=e.palette)||void 0===t?void 0:t.text.primary,fontFamily:null===(r=e.typography)||void 0===r?void 0:r.fontFamily},(null===(n=e.typography)||void 0===n?void 0:n.body1)||{})},tn=function(e){var t;return zr(zr({},en(e)),{backgroundColor:null===(t=e.palette)||void 0===t?void 0:t.background.default,"@media print":{backgroundColor:"#FFF"}})};function rn(e){var t=function({props:e,name:t,defaultTheme:r}){return Ur({theme:kr(r),name:t,props:e})}({props:e,name:"DODOCssBaseline"}),r=t.children,n=t.enableColorScheme,o=void 0!==n&&n,i=t.container;return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(fe,{styles:function(e){return function(e,t,r){var n,o,i,s,a,l;void 0===t&&(t=!1);var c={html:$r(e,t),"*, *::before, *::after":{boxSizing:"border-box"},"strong, b":{fontWeight:(null===(i=e.typography)||void 0===i?void 0:i.fontWeightBold)||"bolder"},body:zr(zr({margin:0},tn(e)),{"&::backdrop":{backgroundColor:null===(s=e.palette)||void 0===s?void 0:s.background.default}})};r&&(delete c.html,delete c.body,(n={})[r]=zr(zr({},c),en(e)),c=n);var u=null===(l=null===(a=e.components)||void 0===a?void 0:a.MuiCssBaseline)||void 0===l?void 0:l.styleOverrides;if(u){if(r){var d={};Object.keys(u).forEach((function(e){d["*"+e]=u[e]})),(o={})[r]=d,u=o}c=[c,u]}return c}(e,o,i)}}),r]})}function nn(e){return $e("MuiButton",e)}function on(e,t=[]){if(void 0===e)return{};const r={};return Object.keys(e).filter((r=>r.match(/^on[A-Z]/)&&"function"==typeof e[r]&&!t.includes(r))).forEach((t=>{r[t]=e[t]})),r}function sn(e){return"string"==typeof e}et("MuiButton",["root","active","disabled","focusVisible"]);const an={disableDefaultClasses:!1},ln=T.createContext(an);function cn(e){const{disableDefaultClasses:t}=T.useContext(ln);return r=>t?"":e(r)}function un(e){if(void 0===e)return{};const t={};return Object.keys(e).filter((t=>!(t.match(/^on[A-Z]/)&&"function"==typeof e[t]))).forEach((r=>{t[r]=e[r]})),t}const dn=["elementType","externalSlotProps","ownerState"];function pn(e){var t;const{elementType:r,externalSlotProps:n,ownerState:o}=e,i=ur(e,dn),s=function(e,t){return"function"==typeof e?e(t):e}(n,o),{props:a,internalRef:l}=function(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:n,externalForwardedProps:o,className:i}=e;if(!t){const e=hr(null==o?void 0:o.className,null==n?void 0:n.className,i,null==r?void 0:r.className),t=be({},null==r?void 0:r.style,null==o?void 0:o.style,null==n?void 0:n.style),s=be({},r,o,n);return e.length>0&&(s.className=e),Object.keys(t).length>0&&(s.style=t),{props:s,internalRef:void 0}}const s=on(be({},o,n)),a=un(n),l=un(o),c=t(s),u=hr(null==c?void 0:c.className,null==r?void 0:r.className,i,null==o?void 0:o.className,null==n?void 0:n.className),d=be({},null==c?void 0:c.style,null==r?void 0:r.style,null==o?void 0:o.style,null==n?void 0:n.style),p=be({},c,r,l,a);return u.length>0&&(p.className=u),Object.keys(d).length>0&&(p.style=d),{props:p,internalRef:c.ref}}(be({},i,{externalSlotProps:s})),c=function(e,t,r){return void 0===e||sn(e)?t:be({},t,{ownerState:be({},t.ownerState,r)})}(r,be({},a,{ref:_e(l,null==s?void 0:s.ref,null==(t=e.additionalProps)?void 0:t.ref)}),o);return c}const hn=["action","children","disabled","focusableWhenDisabled","onFocusVisible","slotProps","slots"],fn=T.forwardRef((function(e,t){var r;const{action:n,children:o,focusableWhenDisabled:i=!1,slotProps:s={},slots:a={}}=e,l=ur(e,hn),c=T.useRef(),{active:u,focusVisible:d,setFocusVisible:p,getRootProps:h}=function(e={}){const{disabled:t=!1,focusableWhenDisabled:r,href:n,rootRef:o,tabIndex:i,to:s,type:a}=e,l=T.useRef(),[c,u]=T.useState(!1),{isFocusVisibleRef:d,onFocus:p,onBlur:h,ref:f}=Ge(),[m,g]=T.useState(!1);t&&!r&&m&&g(!1),T.useEffect((()=>{d.current=m}),[m,d]);const[y,b]=T.useState(""),x=e=>t=>{var r;m&&t.preventDefault(),null==(r=e.onMouseLeave)||r.call(e,t)},v=e=>t=>{var r;h(t),!1===d.current&&g(!1),null==(r=e.onBlur)||r.call(e,t)},w=e=>t=>{var r,n;l.current||(l.current=t.currentTarget),p(t),!0===d.current&&(g(!0),null==(n=e.onFocusVisible)||n.call(e,t)),null==(r=e.onFocus)||r.call(e,t)},E=()=>{const e=l.current;return"BUTTON"===y||"INPUT"===y&&["button","submit","reset"].includes(null==e?void 0:e.type)||"A"===y&&(null==e?void 0:e.href)},A=e=>r=>{var n;t||null==(n=e.onClick)||n.call(e,r)},C=e=>r=>{var n;t||(u(!0),document.addEventListener("mouseup",(()=>{u(!1)}),{once:!0})),null==(n=e.onMouseDown)||n.call(e,r)},k=e=>r=>{var n,o;null==(n=e.onKeyDown)||n.call(e,r),r.defaultMuiPrevented||(r.target!==r.currentTarget||E()||" "!==r.key||r.preventDefault(),r.target!==r.currentTarget||" "!==r.key||t||u(!0),r.target!==r.currentTarget||E()||"Enter"!==r.key||t||(null==(o=e.onClick)||o.call(e,r),r.preventDefault()))},R=e=>r=>{var n,o;r.target===r.currentTarget&&u(!1),null==(n=e.onKeyUp)||n.call(e,r),r.target!==r.currentTarget||E()||t||" "!==r.key||r.defaultMuiPrevented||null==(o=e.onClick)||o.call(e,r)},S=_e(T.useCallback((e=>{var t;b(null!=(t=null==e?void 0:e.tagName)?t:"")}),[]),o,f,l),N={};return"BUTTON"===y?(N.type=null!=a?a:"button",r?N["aria-disabled"]=t:N.disabled=t):""!==y&&(n||s||(N.role="button",N.tabIndex=null!=i?i:0),t&&(N["aria-disabled"]=t,N.tabIndex=r?null!=i?i:0:-1)),{getRootProps:(t={})=>{const r=be({},on(e),t);return delete r.onFocusVisible,be({type:a},r,N,{onBlur:v(r),onClick:A(r),onFocus:w(r),onKeyDown:k(r),onKeyUp:R(r),onMouseDown:C(r),onMouseLeave:x(r),ref:S})},focusVisible:m,setFocusVisible:g,active:c,rootRef:S}}(be({},e,{focusableWhenDisabled:i}));T.useImperativeHandle(n,(()=>({focusVisible:()=>{p(!0),c.current.focus()}})),[p]);const f=be({},e,{active:u,focusableWhenDisabled:i,focusVisible:d}),m=(e=>{const{active:t,disabled:r,focusVisible:n}=e;return Je({root:["root",r&&"disabled",n&&"focusVisible",t&&"active"]},cn(nn))})(f),g=l.href||l.to?"a":"button",y=null!=(r=a.root)?r:g,b=pn({elementType:y,getSlotProps:h,externalForwardedProps:l,externalSlotProps:s.root,additionalProps:{ref:t},ownerState:f,className:m.root});return ne.exports.jsx(y,be({},b,{children:o}))}));"production"!==process.env.NODE_ENV&&(fn.propTypes={action:j.exports.oneOfType([j.exports.func,j.exports.shape({current:j.exports.shape({focusVisible:j.exports.func.isRequired})})]),children:j.exports.node,disabled:j.exports.bool,focusableWhenDisabled:j.exports.bool,href:j.exports.string,onFocusVisible:j.exports.func,slotProps:j.exports.shape({root:j.exports.oneOfType([j.exports.func,j.exports.object])}),slots:j.exports.shape({root:j.exports.elementType}),to:j.exports.string});var mn,gn,yn=fn;!function(e){e.contained="contained",e.outlined="outlined",e.dashed="dashed",e.second="second",e.tag="tag"}(mn||(mn={})),function(e){e.small="small",e.middle="middle",e.big="big"}(gn||(gn={}));var bn=function(e,t){var n,o,i,s,a,l=e.fullWidth,c=e.variant,u=e.sx,d=e.danger,p={px:16,py:10,typography:"button",whiteSpace:"nowrap",fontFamily:"inherit",display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},"&[disabled]":{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}};switch(e.size){case gn.small:p.height=36,p.borderRadius=8,p.typography="body2";break;case gn.big:p.height=60,p.borderRadius=16;break;default:p.height=48,p.borderRadius=8}l&&(p.display="flex",p.width="100%");var h="&:not([disabled]):hover";switch(c){case mn.outlined:p=zr(zr({},p),((n={border:"solid 1px ".concat(d?t.palette.error.main:t.palette.primary.main),color:d?"error.main":"primary.main","&[disabled]":{color:"text.disabled",borderColor:"border.disabled"}})[h]={background:Vr(d?t.palette.error.main:t.palette.primary.main,.1)},n));break;case mn.dashed:p=zr(zr({},p),((o={height:p.height-1,border:"dashed 1px ".concat(d?t.palette.error.main:t.palette.border.light),color:d?"error.main":"primary.main","&[disabled]":{backgroundColor:"border.disabled",color:"text.disabled"}})[h]={background:Vr(d?t.palette.error.main:t.palette.border.disabled,.1)},o));break;case mn.second:p=zr(zr({},p),((i={backgroundColor:d?"error.main":t.palette.background.tag,border:"none",color:d?"error.contrastText":"text.primary","&[disabled]":{backgroundColor:"border.disabled",color:"text.disabled"}})[h]={background:d?Vr(t.palette.error.main,.1):Vr(t.palette.border.disabled,.2)},i));break;case mn.tag:p=zr(zr({},p),((s={px:10,py:3,height:"auto",borderRadius:4,typography:"body2",backgroundColor:d?"error.main":"background.tag",border:"none",color:d?"error.contrastText":"primary.main","&[disabled]":{backgroundColor:"border.disabled",color:"text.disabled"}})[h]={background:d?Vr(t.palette.error.main,.1):Vr(t.palette.border.disabled,.2)},s));break;default:p=zr(zr({},p),((a={backgroundColor:d?"error.main":"secondary.main"})[h]={background:"linear-gradient(0deg, rgba(26, 26, 27, 0.1), rgba(26, 26, 27, 0.1)), ".concat(d?t.palette.error.main:(null==u?void 0:u.backgroundColor)||t.palette.secondary.main)},a.color=d?"error.contrastText":"secondary.contrastText",a["&[disabled]"]={backgroundColor:"border.disabled",color:"text.disabled"},a))}return r.merge(p,u)},xn=function(e){var t=e.onClick,r=e.disabled,n=e.children,o=e.component,s=e.to,a=e.isLoading,l=e.fullWidth,c=e.variant,u=e.sx,d=e.danger,p=e.size;e.ref;var h=Yr(e,["onClick","disabled","children","component","to","isLoading","fullWidth","variant","sx","danger","size","ref"]),f=kr(),m={disabled:r,sx:bn({fullWidth:l,variant:c,sx:u,danger:d,size:p},f),onClick:t,component:o,to:s};return ne.exports.jsx(Sr,zr({},m,h,{component:yn,disabled:!!a||r,className:c||mn.contained},{children:ne.exports.jsxs(ne.exports.Fragment,{children:[a&&ne.exports.jsx(Sr,{component:i.Loading,sx:{mr:8,"& path":{fill:f.palette.text.disabled},animation:"loadingRotate 1.1s infinite linear","@keyframes loadingRotate":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(359deg)"}}}}),n]})}))};xn.Variant=mn,xn.Size=gn;var vn,wn=_r(yn)(vn||(vn=Jr(["\n margin: 0;\n border: none;\n padding: 0;\n cursor: pointer;\n background: none;\n font-family: inherit;\n &:focus {\n outline: none;\n }\n &:active {\n outline: none;\n }\n"],["\n margin: 0;\n border: none;\n padding: 0;\n cursor: pointer;\n background: none;\n font-family: inherit;\n &:focus {\n outline: none;\n }\n &:active {\n outline: none;\n }\n"])));function En(e){return $e("MuiInput",e)}var An=et("MuiInput",["root","formControl","focused","disabled","error","multiline","input","inputMultiline","inputTypeSearch","adornedStart","adornedEnd"]);const Cn=T.createContext(void 0);"production"!==process.env.NODE_ENV&&(Cn.displayName="FormControlContext");var kn=Cn;function Rn(e){const{defaultValue:t,disabled:r=!1,error:n=!1,onBlur:o,onChange:i,onFocus:s,required:a=!1,value:l,inputRef:c}=e,u=T.useContext(kn);let d,p,h,f,m;var g,y,b;if(u){if(d=void 0,p=null!=(g=u.disabled)&&g,h=null!=(y=u.error)&&y,f=null!=(b=u.required)&&b,m=u.value,"production"!==process.env.NODE_ENV){const t=["defaultValue","disabled","error","required","value"].filter((t=>void 0!==e[t]));t.length>0&&console.warn(["MUI: You have set props on an input that is inside a FormControl.","Set these props on a FormControl instead. Otherwise they will be ignored.",`Ignored props: ${t.join(", ")}`].join("\n"))}}else d=t,p=r,h=n,f=a,m=l;const{current:x}=T.useRef(null!=m),v=T.useCallback((e=>{"production"!==process.env.NODE_ENV&&e&&"INPUT"!==e.nodeName&&!e.focus&&console.error(["MUI: You have provided a `slots.input` to the input component","that does not correctly handle the `ref` prop.","Make sure the `ref` prop is called with a HTMLInputElement."].join("\n"))}),[]),w=T.useRef(null),E=_e(w,c,v),[A,C]=T.useState(!1);T.useEffect((()=>{!u&&p&&A&&(C(!1),null==o||o())}),[u,p,A,o]);const k=e=>t=>{var r,n;null!=u&&u.disabled?t.stopPropagation():(null==(r=e.onFocus)||r.call(e,t),u&&u.onFocus?null==u||null==(n=u.onFocus)||n.call(u):C(!0))},R=e=>(t,...r)=>{var n,o;if(!x&&null==(t.target||w.current))throw new Error("production"!==process.env.NODE_ENV?"MUI: Expected valid input target. Did you use a custom `slots.input` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info.":Re(17));null==u||null==(n=u.onChange)||n.call(u,t),null==(o=e.onChange)||o.call(e,t,...r)};return{disabled:p,error:h,focused:A,formControlContext:u,getInputProps:(e={})=>{const t=be({},{onBlur:o,onChange:i,onFocus:s},on(e)),r=be({},e,t,{onBlur:(n=t,e=>{var t;null==(t=n.onBlur)||t.call(n,e),u&&u.onBlur?u.onBlur():C(!1)}),onChange:R(t),onFocus:k(t)});var n;return be({},r,{"aria-invalid":h||void 0,defaultValue:d,ref:E,value:m,required:f,disabled:p})},getRootProps:(t={})=>{const r=be({},on(e,["onBlur","onChange","onFocus"]),on(t));return be({},t,r,{onClick:(n=r,e=>{var t;w.current&&e.currentTarget===e.target&&w.current.focus(),null==(t=n.onClick)||t.call(n,e)})});var n},inputRef:E,required:f,value:m}}const Tn=["aria-describedby","aria-label","aria-labelledby","autoComplete","autoFocus","className","defaultValue","disabled","endAdornment","error","id","multiline","name","onClick","onChange","onKeyDown","onKeyUp","onFocus","onBlur","placeholder","readOnly","required","startAdornment","value","type","rows","slotProps","slots","minRows","maxRows"],Sn=T.forwardRef((function(e,t){var r,n,o;const{"aria-describedby":i,"aria-label":s,"aria-labelledby":a,autoComplete:l,autoFocus:c,className:u,defaultValue:d,disabled:p,endAdornment:h,error:f,id:m,multiline:g=!1,name:y,onClick:b,onChange:x,onKeyDown:v,onKeyUp:w,onFocus:E,onBlur:A,placeholder:C,readOnly:k,required:R,startAdornment:T,value:S,type:N,rows:M,slotProps:F={},slots:O={},minRows:I,maxRows:j}=e,D=ur(e,Tn),{getRootProps:B,getInputProps:P,focused:W,formControlContext:_,error:U,disabled:L}=Rn({disabled:p,defaultValue:d,error:f,onBlur:A,onClick:b,onChange:x,onFocus:E,required:R,value:S}),V=g?void 0:null!=N?N:"text",Z=be({},e,{disabled:L,error:U,focused:W,formControlContext:_,multiline:g,type:V}),H=(e=>{const{disabled:t,error:r,focused:n,formControlContext:o,multiline:i,startAdornment:s,endAdornment:a}=e;return Je({root:["root",t&&"disabled",r&&"error",n&&"focused",Boolean(o)&&"formControl",i&&"multiline",Boolean(s)&&"adornedStart",Boolean(a)&&"adornedEnd"],input:["input",t&&"disabled",i&&"multiline"]},cn(En))})(Z),z={"aria-describedby":i,"aria-label":s,"aria-labelledby":a,autoComplete:l,autoFocus:c,id:m,onKeyDown:v,onKeyUp:w,name:y,placeholder:C,readOnly:k,type:V},Y=null!=(r=O.root)?r:"div",G=pn({elementType:Y,getSlotProps:B,externalSlotProps:F.root,externalForwardedProps:D,additionalProps:{ref:t},ownerState:Z,className:[H.root,u]}),X=g?null!=(n=O.textarea)?n:"textarea":null!=(o=O.input)?o:"input",J=pn({elementType:X,getSlotProps:e=>P(be({},z,e)),externalSlotProps:F.input,additionalProps:be({rows:g?M:void 0},g&&!sn(X)&&{minRows:M||I,maxRows:M||j}),ownerState:Z,className:H.input});return"production"!==process.env.NODE_ENV&&g&&M&&(I||j)&&console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."),ne.exports.jsxs(Y,be({},G,{children:[T,ne.exports.jsx(X,be({},J)),h]}))}));"production"!==process.env.NODE_ENV&&(Sn.propTypes={"aria-describedby":j.exports.string,"aria-label":j.exports.string,"aria-labelledby":j.exports.string,autoComplete:j.exports.string,autoFocus:j.exports.bool,className:j.exports.string,defaultValue:j.exports.any,disabled:j.exports.bool,endAdornment:j.exports.node,error:j.exports.bool,id:j.exports.string,inputRef:j.exports.oneOfType([j.exports.func,j.exports.shape({current:j.exports.object})]),maxRows:j.exports.number,minRows:j.exports.number,multiline:j.exports.bool,name:j.exports.string,onBlur:j.exports.func,onChange:j.exports.func,onClick:j.exports.func,onFocus:j.exports.func,onKeyDown:j.exports.func,onKeyUp:j.exports.func,placeholder:j.exports.string,readOnly:j.exports.bool,required:j.exports.bool,rows:j.exports.number,slotProps:j.exports.shape({input:j.exports.oneOfType([j.exports.func,j.exports.object]),root:j.exports.oneOfType([j.exports.func,j.exports.object])}),slots:j.exports.shape({input:j.exports.elementType,root:j.exports.elementType,textarea:j.exports.elementType}),startAdornment:j.exports.node,type:j.exports.oneOf(["button","checkbox","color","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"]),value:j.exports.any});var Nn=Sn;function Mn(e){var t,n,o=e.fullWidth,i=e.height,s=e.suffixGap,a=e.error,l=e.sx,c=Yr(e,["fullWidth","height","suffixGap","error","sx"]);return ne.exports.jsx(Sr,zr({component:"div",sx:r.merge(zr(zr(zr((t={position:"relative",display:o?"flex":"inline-flex",alignItems:"center",border:"1px solid",borderColor:a?"error.main":"border.main",borderRadius:8,backgroundColor:"background.input"},t["&.".concat(An.disabled)]={color:"text.disabled",cursor:"default"},t.height=i,t),o&&{width:"100%"}),{"& > *:not(input):not(.MuiSelect-select):first-of-type":{ml:s,whiteSpace:"nowrap"},"& > *:not(input):last-child":{mr:s,whiteSpace:"nowrap"}}),a?{}:(n={},n["&.".concat(An.focused)]={borderColor:"text.secondary"},n)),l)},c))}var Fn=_r(Sr)((function(e){var t=e.theme,r="{\n color: ".concat(t.palette.text.placeholder,";\n font-size: 14px;\n font-weight: 500;\n opacity: 1;\n }");return"\n font: inherit;\n font-size: 16px;\n font-weight: 600;\n line-height: 19px;\n padding: ".concat(t.spacing(14,16),";\n &::-webkit-outer-spin-button {\n -webkit-appearance: none;\n }\n &::-webkit-inner-spin-button {\n -webkit-appearance: none;\n }\n height: 100%;\n width: 100%;\n border: none;\n color: ").concat(t.palette.text.primary,";\n background-color: transparent;\n &::-webkit-input-placeholder ").concat(r,";\n &::-moz-placeholder ").concat(r,";\n &:-ms-input-placeholder ").concat(r,";\n &::-ms-input-placeholder ").concat(r,";\n &:focus {\n outline: 0;\n }\n &:invalid {\n box-shadow: none;\n }\n &::-webkit-search-decoration {\n -webkit-appearance: none;\n }\n &.").concat(An.disabled," {\n opacity: 1;\n -webkit-text-fill-color: ").concat(t.palette.text.disabled,";\n }\n ")})),On=n.forwardRef((function(e,t){var r=e.fullWidth,o=e.error,i=e.errorMsg,s=e.sx,a=e.suffix,l=e.prefix,c=e.height,u=e.suffixGap,d=void 0===u?16:u,p=e.dataTestId,h=e.inputSx,f=Yr(e,["fullWidth","error","errorMsg","sx","suffix","prefix","height","suffixGap","dataTestId","inputSx"]),m=n.useCallback((function(e){return ne.exports.jsx(Mn,zr({fullWidth:r,height:c,suffixGap:d,error:o,sx:s,"data-testid":p},e))}),[r,c,d,o,p,JSON.stringify(s)]);return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Nn,zr({slots:{root:m,input:Fn},startAdornment:l,endAdornment:a,slotProps:{input:{component:"input",sx:h}}},f,{ref:t})),i?ne.exports.jsx(Sr,zr({sx:{typography:"body2",color:"error.main",mt:6}},{children:i})):""]})})),In=n.forwardRef((function(e,t){var n=e.weak,o=e.color,i=e.sx,s=Yr(e,["weak","color","sx"]),a=n?"text.primary":"text.secondary",l=n?"text.secondary":"text.primary";return o&&(a=o,l=o),ne.exports.jsx(Sr,zr({ref:t,sx:r.merge(zr({color:a,opacity:o&&!n?.5:1},{"&:hover":{color:l,opacity:o&&n?.5:1}}),i)},s))}));function jn(e){var t=e.clearValue,n=e.hideSearchIcon,o=e.height,s=void 0===o?48:o,a=e.inputSx,l=Yr(e,["clearValue","hideSearchIcon","height","inputSx"]),c=kr(),u=l.value;return ne.exports.jsx(On,zr({prefix:n?null:ne.exports.jsx(i.Search,{style:{width:24,minWidth:24,height:24,color:c.palette.text.placeholder}}),suffix:u&&t?ne.exports.jsx(In,zr({sx:{width:24,minWidth:24,height:24,mr:12,display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"50%",backgroundColor:"background.tag",cursor:"pointer"},onClick:t},{children:ne.exports.jsx(Sr,{component:i.Error,sx:{width:14,height:14}})})):null},l,{inputSx:r.merge({pl:4},a),height:s}))}var Dn=function(e){var t=e.sx,r=kr();return ne.exports.jsx(Sr,{sx:zr({width:20,color:r.palette.primary.main,animation:"spin 3s linear infinite","@keyframes spin":{"100%":{transform:"rotate(360deg)"}}},t),component:i.Loading})};function Bn(e){return e.substring(2).toLowerCase()}function Pn(e){const{children:t,disableReactTree:r=!1,mouseEvent:n="onClick",onClickAway:o,touchEvent:i="onTouchEnd"}=e,s=T.useRef(!1),a=T.useRef(null),l=T.useRef(!1),c=T.useRef(!1);T.useEffect((()=>(setTimeout((()=>{l.current=!0}),0),()=>{l.current=!1})),[]);const u=_e(t.ref,a),d=We((e=>{const t=c.current;c.current=!1;const n=je(a.current);if(!l.current||!a.current||"clientX"in e&&function(e,t){return t.documentElement.clientWidth<e.clientX||t.documentElement.clientHeight<e.clientY}(e,n))return;if(s.current)return void(s.current=!1);let i;i=e.composedPath?e.composedPath().indexOf(a.current)>-1:!n.documentElement.contains(e.target)||a.current.contains(e.target),i||!r&&t||o(e)})),p=e=>r=>{c.current=!0;const n=t.props[e];n&&n(r)},h={ref:u};return!1!==i&&(h[i]=p(i)),T.useEffect((()=>{if(!1!==i){const e=Bn(i),t=je(a.current),r=()=>{s.current=!0};return t.addEventListener(e,d),t.addEventListener("touchmove",r),()=>{t.removeEventListener(e,d),t.removeEventListener("touchmove",r)}}}),[d,i]),!1!==n&&(h[n]=p(n)),T.useEffect((()=>{if(!1!==n){const e=Bn(n),t=je(a.current);return t.addEventListener(e,d),()=>{t.removeEventListener(e,d)}}}),[d,n]),ne.exports.jsx(T.Fragment,{children:T.cloneElement(t,h)})}"production"!==process.env.NODE_ENV&&(Pn.propTypes={children:Ce.isRequired,disableReactTree:j.exports.bool,mouseEvent:j.exports.oneOf(["onClick","onMouseDown","onMouseUp","onPointerDown","onPointerUp",!1]),onClickAway:j.exports.func.isRequired,touchEvent:j.exports.oneOf(["onTouchEnd","onTouchStart",!1])}),"production"!==process.env.NODE_ENV&&(Pn.propTypes=ke(Pn.propTypes));var Wn="top",_n="bottom",Un="right",Ln="left",Vn=[Wn,_n,Un,Ln],Zn=Vn.reduce((function(e,t){return e.concat([t+"-start",t+"-end"])}),[]),Hn=[].concat(Vn,["auto"]).reduce((function(e,t){return e.concat([t,t+"-start",t+"-end"])}),[]),zn=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function Yn(e){return e?(e.nodeName||"").toLowerCase():null}function Gn(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Xn(e){return e instanceof Gn(e).Element||e instanceof Element}function Jn(e){return e instanceof Gn(e).HTMLElement||e instanceof HTMLElement}function qn(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Gn(e).ShadowRoot||e instanceof ShadowRoot)}var Qn={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var r=t.styles[e]||{},n=t.attributes[e]||{},o=t.elements[e];Jn(o)&&Yn(o)&&(Object.assign(o.style,r),Object.keys(n).forEach((function(e){var t=n[e];!1===t?o.removeAttribute(e):o.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach((function(e){var n=t.elements[e],o=t.attributes[e]||{},i=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:r[e]).reduce((function(e,t){return e[t]="",e}),{});Jn(n)&&Yn(n)&&(Object.assign(n.style,i),Object.keys(o).forEach((function(e){n.removeAttribute(e)})))}))}},requires:["computeStyles"]};function Kn(e){return e.split("-")[0]}var $n=Math.max,eo=Math.min,to=Math.round;function ro(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function no(){return!/^((?!chrome|android).)*safari/i.test(ro())}function oo(e,t,r){void 0===t&&(t=!1),void 0===r&&(r=!1);var n=e.getBoundingClientRect(),o=1,i=1;t&&Jn(e)&&(o=e.offsetWidth>0&&to(n.width)/e.offsetWidth||1,i=e.offsetHeight>0&&to(n.height)/e.offsetHeight||1);var s=(Xn(e)?Gn(e):window).visualViewport,a=!no()&&r,l=(n.left+(a&&s?s.offsetLeft:0))/o,c=(n.top+(a&&s?s.offsetTop:0))/i,u=n.width/o,d=n.height/i;return{width:u,height:d,top:c,right:l+u,bottom:c+d,left:l,x:l,y:c}}function io(e){var t=oo(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function so(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&qn(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function ao(e){return Gn(e).getComputedStyle(e)}function lo(e){return["table","td","th"].indexOf(Yn(e))>=0}function co(e){return((Xn(e)?e.ownerDocument:e.document)||window.document).documentElement}function uo(e){return"html"===Yn(e)?e:e.assignedSlot||e.parentNode||(qn(e)?e.host:null)||co(e)}function po(e){return Jn(e)&&"fixed"!==ao(e).position?e.offsetParent:null}function ho(e){for(var t=Gn(e),r=po(e);r&&lo(r)&&"static"===ao(r).position;)r=po(r);return r&&("html"===Yn(r)||"body"===Yn(r)&&"static"===ao(r).position)?t:r||function(e){var t=/firefox/i.test(ro());if(/Trident/i.test(ro())&&Jn(e)&&"fixed"===ao(e).position)return null;var r=uo(e);for(qn(r)&&(r=r.host);Jn(r)&&["html","body"].indexOf(Yn(r))<0;){var n=ao(r);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return r;r=r.parentNode}return null}(e)||t}function fo(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mo(e,t,r){return $n(e,eo(t,r))}function go(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function yo(e,t){return t.reduce((function(t,r){return t[r]=e,t}),{})}var bo={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,r=e.state,n=e.name,o=e.options,i=r.elements.arrow,s=r.modifiersData.popperOffsets,a=Kn(r.placement),l=fo(a),c=[Ln,Un].indexOf(a)>=0?"height":"width";if(i&&s){var u=function(e,t){return go("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:yo(e,Vn))}(o.padding,r),d=io(i),p="y"===l?Wn:Ln,h="y"===l?_n:Un,f=r.rects.reference[c]+r.rects.reference[l]-s[l]-r.rects.popper[c],m=s[l]-r.rects.reference[l],g=ho(i),y=g?"y"===l?g.clientHeight||0:g.clientWidth||0:0,b=f/2-m/2,x=u[p],v=y-d[c]-u[h],w=y/2-d[c]/2+b,E=mo(x,w,v),A=l;r.modifiersData[n]=((t={})[A]=E,t.centerOffset=E-w,t)}},effect:function(e){var t=e.state,r=e.options.element,n=void 0===r?"[data-popper-arrow]":r;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&so(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function xo(e){return e.split("-")[1]}var vo={top:"auto",right:"auto",bottom:"auto",left:"auto"};function wo(e){var t,r=e.popper,n=e.popperRect,o=e.placement,i=e.variation,s=e.offsets,a=e.position,l=e.gpuAcceleration,c=e.adaptive,u=e.roundOffsets,d=e.isFixed,p=s.x,h=void 0===p?0:p,f=s.y,m=void 0===f?0:f,g="function"==typeof u?u({x:h,y:m}):{x:h,y:m};h=g.x,m=g.y;var y=s.hasOwnProperty("x"),b=s.hasOwnProperty("y"),x=Ln,v=Wn,w=window;if(c){var E=ho(r),A="clientHeight",C="clientWidth";E===Gn(r)&&"static"!==ao(E=co(r)).position&&"absolute"===a&&(A="scrollHeight",C="scrollWidth"),(o===Wn||(o===Ln||o===Un)&&"end"===i)&&(v=_n,m-=(d&&E===w&&w.visualViewport?w.visualViewport.height:E[A])-n.height,m*=l?1:-1),o!==Ln&&(o!==Wn&&o!==_n||"end"!==i)||(x=Un,h-=(d&&E===w&&w.visualViewport?w.visualViewport.width:E[C])-n.width,h*=l?1:-1)}var k,R=Object.assign({position:a},c&&vo),T=!0===u?function(e,t){var r=e.x,n=e.y,o=t.devicePixelRatio||1;return{x:to(r*o)/o||0,y:to(n*o)/o||0}}({x:h,y:m},Gn(r)):{x:h,y:m};return h=T.x,m=T.y,l?Object.assign({},R,((k={})[v]=b?"0":"",k[x]=y?"0":"",k.transform=(w.devicePixelRatio||1)<=1?"translate("+h+"px, "+m+"px)":"translate3d("+h+"px, "+m+"px, 0)",k)):Object.assign({},R,((t={})[v]=b?m+"px":"",t[x]=y?h+"px":"",t.transform="",t))}var Eo={passive:!0},Ao={left:"right",right:"left",bottom:"top",top:"bottom"};function Co(e){return e.replace(/left|right|bottom|top/g,(function(e){return Ao[e]}))}var ko={start:"end",end:"start"};function Ro(e){return e.replace(/start|end/g,(function(e){return ko[e]}))}function To(e){var t=Gn(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function So(e){return oo(co(e)).left+To(e).scrollLeft}function No(e){var t=ao(e),r=t.overflow,n=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+o+n)}function Mo(e){return["html","body","#document"].indexOf(Yn(e))>=0?e.ownerDocument.body:Jn(e)&&No(e)?e:Mo(uo(e))}function Fo(e,t){var r;void 0===t&&(t=[]);var n=Mo(e),o=n===(null==(r=e.ownerDocument)?void 0:r.body),i=Gn(n),s=o?[i].concat(i.visualViewport||[],No(n)?n:[]):n,a=t.concat(s);return o?a:a.concat(Fo(uo(s)))}function Oo(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Io(e,t,r){return"viewport"===t?Oo(function(e,t){var r=Gn(e),n=co(e),o=r.visualViewport,i=n.clientWidth,s=n.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;var c=no();(c||!c&&"fixed"===t)&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a+So(e),y:l}}(e,r)):Xn(t)?function(e,t){var r=oo(e,!1,"fixed"===t);return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}(t,r):Oo(function(e){var t,r=co(e),n=To(e),o=null==(t=e.ownerDocument)?void 0:t.body,i=$n(r.scrollWidth,r.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=$n(r.scrollHeight,r.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),a=-n.scrollLeft+So(e),l=-n.scrollTop;return"rtl"===ao(o||r).direction&&(a+=$n(r.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:l}}(co(e)))}function jo(e){var t,r=e.reference,n=e.element,o=e.placement,i=o?Kn(o):null,s=o?xo(o):null,a=r.x+r.width/2-n.width/2,l=r.y+r.height/2-n.height/2;switch(i){case Wn:t={x:a,y:r.y-n.height};break;case _n:t={x:a,y:r.y+r.height};break;case Un:t={x:r.x+r.width,y:l};break;case Ln:t={x:r.x-n.width,y:l};break;default:t={x:r.x,y:r.y}}var c=i?fo(i):null;if(null!=c){var u="y"===c?"height":"width";switch(s){case"start":t[c]=t[c]-(r[u]/2-n[u]/2);break;case"end":t[c]=t[c]+(r[u]/2-n[u]/2)}}return t}function Do(e,t){void 0===t&&(t={});var r=t,n=r.placement,o=void 0===n?e.placement:n,i=r.strategy,s=void 0===i?e.strategy:i,a=r.boundary,l=void 0===a?"clippingParents":a,c=r.rootBoundary,u=void 0===c?"viewport":c,d=r.elementContext,p=void 0===d?"popper":d,h=r.altBoundary,f=void 0!==h&&h,m=r.padding,g=void 0===m?0:m,y=go("number"!=typeof g?g:yo(g,Vn)),b="popper"===p?"reference":"popper",x=e.rects.popper,v=e.elements[f?b:p],w=function(e,t,r,n){var o="clippingParents"===t?function(e){var t=Fo(uo(e)),r=["absolute","fixed"].indexOf(ao(e).position)>=0&&Jn(e)?ho(e):e;return Xn(r)?t.filter((function(e){return Xn(e)&&so(e,r)&&"body"!==Yn(e)})):[]}(e):[].concat(t),i=[].concat(o,[r]),s=i[0],a=i.reduce((function(t,r){var o=Io(e,r,n);return t.top=$n(o.top,t.top),t.right=eo(o.right,t.right),t.bottom=eo(o.bottom,t.bottom),t.left=$n(o.left,t.left),t}),Io(e,s,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}(Xn(v)?v:v.contextElement||co(e.elements.popper),l,u,s),E=oo(e.elements.reference),A=jo({reference:E,element:x,strategy:"absolute",placement:o}),C=Oo(Object.assign({},x,A)),k="popper"===p?C:E,R={top:w.top-k.top+y.top,bottom:k.bottom-w.bottom+y.bottom,left:w.left-k.left+y.left,right:k.right-w.right+y.right},T=e.modifiersData.offset;if("popper"===p&&T){var S=T[o];Object.keys(R).forEach((function(e){var t=[Un,_n].indexOf(e)>=0?1:-1,r=[Wn,_n].indexOf(e)>=0?"y":"x";R[e]+=S[r]*t}))}return R}var Bo={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var o=r.mainAxis,i=void 0===o||o,s=r.altAxis,a=void 0===s||s,l=r.fallbackPlacements,c=r.padding,u=r.boundary,d=r.rootBoundary,p=r.altBoundary,h=r.flipVariations,f=void 0===h||h,m=r.allowedAutoPlacements,g=t.options.placement,y=Kn(g),b=l||(y!==g&&f?function(e){if("auto"===Kn(e))return[];var t=Co(e);return[Ro(e),t,Ro(t)]}(g):[Co(g)]),x=[g].concat(b).reduce((function(e,r){return e.concat("auto"===Kn(r)?function(e,t){void 0===t&&(t={});var r=t,n=r.placement,o=r.boundary,i=r.rootBoundary,s=r.padding,a=r.flipVariations,l=r.allowedAutoPlacements,c=void 0===l?Hn:l,u=xo(n),d=u?a?Zn:Zn.filter((function(e){return xo(e)===u})):Vn,p=d.filter((function(e){return c.indexOf(e)>=0}));0===p.length&&(p=d);var h=p.reduce((function(t,r){return t[r]=Do(e,{placement:r,boundary:o,rootBoundary:i,padding:s})[Kn(r)],t}),{});return Object.keys(h).sort((function(e,t){return h[e]-h[t]}))}(t,{placement:r,boundary:u,rootBoundary:d,padding:c,flipVariations:f,allowedAutoPlacements:m}):r)}),[]),v=t.rects.reference,w=t.rects.popper,E=new Map,A=!0,C=x[0],k=0;k<x.length;k++){var R=x[k],T=Kn(R),S="start"===xo(R),N=[Wn,_n].indexOf(T)>=0,M=N?"width":"height",F=Do(t,{placement:R,boundary:u,rootBoundary:d,altBoundary:p,padding:c}),O=N?S?Un:Ln:S?_n:Wn;v[M]>w[M]&&(O=Co(O));var I=Co(O),j=[];if(i&&j.push(F[T]<=0),a&&j.push(F[O]<=0,F[I]<=0),j.every((function(e){return e}))){C=R,A=!1;break}E.set(R,j)}if(A)for(var D=function(e){var t=x.find((function(t){var r=E.get(t);if(r)return r.slice(0,e).every((function(e){return e}))}));if(t)return C=t,"break"},B=f?3:1;B>0&&"break"!==D(B);B--);t.placement!==C&&(t.modifiersData[n]._skip=!0,t.placement=C,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function Po(e,t,r){return void 0===r&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function Wo(e){return[Wn,Un,_n,Ln].some((function(t){return e[t]>=0}))}var _o={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,r=e.options,n=e.name,o=r.offset,i=void 0===o?[0,0]:o,s=Hn.reduce((function(e,r){return e[r]=function(e,t,r){var n=Kn(e),o=[Ln,Wn].indexOf(n)>=0?-1:1,i="function"==typeof r?r(Object.assign({},t,{placement:e})):r,s=i[0],a=i[1];return s=s||0,a=(a||0)*o,[Ln,Un].indexOf(n)>=0?{x:a,y:s}:{x:s,y:a}}(r,t.rects,i),e}),{}),a=s[t.placement],l=a.x,c=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[n]=s}},Uo={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name,o=r.mainAxis,i=void 0===o||o,s=r.altAxis,a=void 0!==s&&s,l=r.boundary,c=r.rootBoundary,u=r.altBoundary,d=r.padding,p=r.tether,h=void 0===p||p,f=r.tetherOffset,m=void 0===f?0:f,g=Do(t,{boundary:l,rootBoundary:c,padding:d,altBoundary:u}),y=Kn(t.placement),b=xo(t.placement),x=!b,v=fo(y),w="x"===v?"y":"x",E=t.modifiersData.popperOffsets,A=t.rects.reference,C=t.rects.popper,k="function"==typeof m?m(Object.assign({},t.rects,{placement:t.placement})):m,R="number"==typeof k?{mainAxis:k,altAxis:k}:Object.assign({mainAxis:0,altAxis:0},k),T=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,S={x:0,y:0};if(E){if(i){var N,M="y"===v?Wn:Ln,F="y"===v?_n:Un,O="y"===v?"height":"width",I=E[v],j=I+g[M],D=I-g[F],B=h?-C[O]/2:0,P="start"===b?A[O]:C[O],W="start"===b?-C[O]:-A[O],_=t.elements.arrow,U=h&&_?io(_):{width:0,height:0},L=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},V=L[M],Z=L[F],H=mo(0,A[O],U[O]),z=x?A[O]/2-B-H-V-R.mainAxis:P-H-V-R.mainAxis,Y=x?-A[O]/2+B+H+Z+R.mainAxis:W+H+Z+R.mainAxis,G=t.elements.arrow&&ho(t.elements.arrow),X=G?"y"===v?G.clientTop||0:G.clientLeft||0:0,J=null!=(N=null==T?void 0:T[v])?N:0,q=I+Y-J,Q=mo(h?eo(j,I+z-J-X):j,I,h?$n(D,q):D);E[v]=Q,S[v]=Q-I}if(a){var K,$="x"===v?Wn:Ln,ee="x"===v?_n:Un,te=E[w],re="y"===w?"height":"width",ne=te+g[$],oe=te-g[ee],ie=-1!==[Wn,Ln].indexOf(y),se=null!=(K=null==T?void 0:T[w])?K:0,ae=ie?ne:te-A[re]-C[re]-se+R.altAxis,le=ie?te+A[re]+C[re]-se-R.altAxis:oe,ce=h&&ie?function(e,t,r){var n=mo(e,t,r);return n>r?r:n}(ae,te,le):mo(h?ae:ne,te,h?le:oe);E[w]=ce,S[w]=ce-te}t.modifiersData[n]=S}},requiresIfExists:["offset"]};function Lo(e,t,r){void 0===r&&(r=!1);var n,o,i=Jn(t),s=Jn(t)&&function(e){var t=e.getBoundingClientRect(),r=to(t.width)/e.offsetWidth||1,n=to(t.height)/e.offsetHeight||1;return 1!==r||1!==n}(t),a=co(t),l=oo(e,s,r),c={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(i||!i&&!r)&&(("body"!==Yn(t)||No(a))&&(c=(n=t)!==Gn(n)&&Jn(n)?{scrollLeft:(o=n).scrollLeft,scrollTop:o.scrollTop}:To(n)),Jn(t)?((u=oo(t,!0)).x+=t.clientLeft,u.y+=t.clientTop):a&&(u.x=So(a))),{x:l.left+c.scrollLeft-u.x,y:l.top+c.scrollTop-u.y,width:l.width,height:l.height}}function Vo(e){var t=new Map,r=new Set,n=[];function o(e){r.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!r.has(e)){var n=t.get(e);n&&o(n)}})),n.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){r.has(e.name)||o(e)})),n}var Zo={placement:"bottom",modifiers:[],strategy:"absolute"};function Ho(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some((function(e){return!(e&&"function"==typeof e.getBoundingClientRect)}))}var zo=function(e){void 0===e&&(e={});var t=e,r=t.defaultModifiers,n=void 0===r?[]:r,o=t.defaultOptions,i=void 0===o?Zo:o;return function(e,t,r){void 0===r&&(r=i);var o,s,a={placement:"bottom",orderedModifiers:[],options:Object.assign({},Zo,i),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},l=[],c=!1,u={state:a,setOptions:function(r){var o="function"==typeof r?r(a.options):r;d(),a.options=Object.assign({},i,a.options,o),a.scrollParents={reference:Xn(e)?Fo(e):e.contextElement?Fo(e.contextElement):[],popper:Fo(t)};var s,c,p=function(e){var t=Vo(e);return zn.reduce((function(e,r){return e.concat(t.filter((function(e){return e.phase===r})))}),[])}((s=[].concat(n,a.options.modifiers),c=s.reduce((function(e,t){var r=e[t.name];return e[t.name]=r?Object.assign({},r,t,{options:Object.assign({},r.options,t.options),data:Object.assign({},r.data,t.data)}):t,e}),{}),Object.keys(c).map((function(e){return c[e]}))));return a.orderedModifiers=p.filter((function(e){return e.enabled})),a.orderedModifiers.forEach((function(e){var t=e.name,r=e.options,n=void 0===r?{}:r,o=e.effect;if("function"==typeof o){var i=o({state:a,name:t,instance:u,options:n});l.push(i||function(){})}})),u.update()},forceUpdate:function(){if(!c){var e=a.elements,t=e.reference,r=e.popper;if(Ho(t,r)){a.rects={reference:Lo(t,ho(r),"fixed"===a.options.strategy),popper:io(r)},a.reset=!1,a.placement=a.options.placement,a.orderedModifiers.forEach((function(e){return a.modifiersData[e.name]=Object.assign({},e.data)}));for(var n=0;n<a.orderedModifiers.length;n++)if(!0!==a.reset){var o=a.orderedModifiers[n],i=o.fn,s=o.options,l=void 0===s?{}:s,d=o.name;"function"==typeof i&&(a=i({state:a,options:l,name:d,instance:u})||a)}else a.reset=!1,n=-1}}},update:(o=function(){return new Promise((function(e){u.forceUpdate(),e(a)}))},function(){return s||(s=new Promise((function(e){Promise.resolve().then((function(){s=void 0,e(o())}))}))),s}),destroy:function(){d(),c=!0}};if(!Ho(e,t))return u;function d(){l.forEach((function(e){return e()})),l=[]}return u.setOptions(r).then((function(e){!c&&r.onFirstUpdate&&r.onFirstUpdate(e)})),u}}({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,r=e.instance,n=e.options,o=n.scroll,i=void 0===o||o,s=n.resize,a=void 0===s||s,l=Gn(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&c.forEach((function(e){e.addEventListener("scroll",r.update,Eo)})),a&&l.addEventListener("resize",r.update,Eo),function(){i&&c.forEach((function(e){e.removeEventListener("scroll",r.update,Eo)})),a&&l.removeEventListener("resize",r.update,Eo)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,r=e.name;t.modifiersData[r]=jo({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,r=e.options,n=r.gpuAcceleration,o=void 0===n||n,i=r.adaptive,s=void 0===i||i,a=r.roundOffsets,l=void 0===a||a,c={placement:Kn(t.placement),variation:xo(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,wo(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,wo(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},Qn,_o,Bo,Uo,bo,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,r=e.name,n=t.rects.reference,o=t.rects.popper,i=t.modifiersData.preventOverflow,s=Do(t,{elementContext:"reference"}),a=Do(t,{altBoundary:!0}),l=Po(s,n),c=Po(a,o,i),u=Wo(l),d=Wo(c);t.modifiersData[r]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}}]});const Yo=T.forwardRef((function(e,t){const{children:r,container:n,disablePortal:o=!1}=e,[i,s]=T.useState(null),a=_e(T.isValidElement(r)?r.ref:null,t);if(Pe((()=>{o||s(function(e){return"function"==typeof e?e():e}(n)||document.body)}),[n,o]),Pe((()=>{if(i&&!o)return Be(t,i),()=>{Be(t,null)}}),[t,i,o]),o){if(T.isValidElement(r)){const e={ref:a};return T.cloneElement(r,e)}return ne.exports.jsx(T.Fragment,{children:r})}return ne.exports.jsx(T.Fragment,{children:i?N.createPortal(r,i):i})}));"production"!==process.env.NODE_ENV&&(Yo.propTypes={children:j.exports.node,container:j.exports.oneOfType([Me,j.exports.func]),disablePortal:j.exports.bool}),"production"!==process.env.NODE_ENV&&(Yo.propTypes=ke(Yo.propTypes));var Go=Yo;function Xo(e){return $e("MuiPopper",e)}et("MuiPopper",["root"]);const Jo=["anchorEl","children","direction","disablePortal","modifiers","open","placement","popperOptions","popperRef","slotProps","slots","TransitionProps","ownerState"],qo=["anchorEl","children","container","direction","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","style","transition","slotProps","slots"];function Qo(e){return"function"==typeof e?e():e}function Ko(e){return void 0!==e.nodeType}const $o={},ei=T.forwardRef((function(e,t){var r;const{anchorEl:n,children:o,direction:i,disablePortal:s,modifiers:a,open:l,placement:c,popperOptions:u,popperRef:d,slotProps:p={},slots:h={},TransitionProps:f}=e,m=ur(e,Jo),g=T.useRef(null),y=_e(g,t),b=T.useRef(null),x=_e(b,d),v=T.useRef(x);Pe((()=>{v.current=x}),[x]),T.useImperativeHandle(d,(()=>b.current),[]);const w=function(e,t){if("ltr"===t)return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}(c,i),[E,A]=T.useState(w),[C,k]=T.useState(Qo(n));T.useEffect((()=>{b.current&&b.current.forceUpdate()})),T.useEffect((()=>{n&&k(Qo(n))}),[n]),Pe((()=>{if(!C||!l)return;if("production"!==process.env.NODE_ENV&&C&&Ko(C)&&1===C.nodeType){const e=C.getBoundingClientRect();"test"!==process.env.NODE_ENV&&0===e.top&&0===e.left&&0===e.right&&0===e.bottom&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join("\n"))}let e=[{name:"preventOverflow",options:{altBoundary:s}},{name:"flip",options:{altBoundary:s}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:e})=>{A(e.placement)}}];null!=a&&(e=e.concat(a)),u&&null!=u.modifiers&&(e=e.concat(u.modifiers));const t=zo(C,g.current,be({placement:w},u,{modifiers:e}));return v.current(t),()=>{t.destroy(),v.current(null)}}),[C,s,a,l,u,w]);const R={placement:E};null!==f&&(R.TransitionProps=f);const S=Je({root:["root"]},cn(Xo)),N=null!=(r=h.root)?r:"div",M=pn({elementType:N,externalSlotProps:p.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:y},ownerState:e,className:S.root});return ne.exports.jsx(N,be({},M,{children:"function"==typeof o?o(R):o}))})),ti=T.forwardRef((function(e,t){const{anchorEl:r,children:n,container:o,direction:i="ltr",disablePortal:s=!1,keepMounted:a=!1,modifiers:l,open:c,placement:u="bottom",popperOptions:d=$o,popperRef:p,style:h,transition:f=!1,slotProps:m={},slots:g={}}=e,y=ur(e,qo),[b,x]=T.useState(!0);if(!a&&!c&&(!f||b))return null;let v;if(o)v=o;else if(r){const e=Qo(r);v=e&&Ko(e)?je(e).body:je(null).body}const w=f?{in:c,onEnter:()=>{x(!1)},onExited:()=>{x(!0)}}:void 0;return ne.exports.jsx(Go,{disablePortal:s,container:v,children:ne.exports.jsx(ei,be({anchorEl:r,direction:i,disablePortal:s,modifiers:l,ref:t,open:f?!b:c,placement:u,popperOptions:d,popperRef:p,slotProps:m,slots:g},y,{style:be({position:"fixed",top:0,left:0,display:c||!a||f&&!b?void 0:"none"},h),TransitionProps:w,children:n}))})}));"production"!==process.env.NODE_ENV&&(ti.propTypes={anchorEl:ye(j.exports.oneOfType([Me,j.exports.object,j.exports.func]),(e=>{if(e.open){const t=Qo(e.anchorEl);if(t&&Ko(t)&&1===t.nodeType){const e=t.getBoundingClientRect();if("test"!==process.env.NODE_ENV&&0===e.top&&0===e.left&&0===e.right&&0===e.bottom)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join("\n"))}else if(!t||"function"!=typeof t.getBoundingClientRect||!Ko(t)&&null!=t.contextElement&&1!==t.contextElement.nodeType)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join("\n"))}return null})),children:j.exports.oneOfType([j.exports.node,j.exports.func]),container:j.exports.oneOfType([Me,j.exports.func]),direction:j.exports.oneOf(["ltr","rtl"]),disablePortal:j.exports.bool,keepMounted:j.exports.bool,modifiers:j.exports.arrayOf(j.exports.shape({data:j.exports.object,effect:j.exports.func,enabled:j.exports.bool,fn:j.exports.func,name:j.exports.any,options:j.exports.object,phase:j.exports.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:j.exports.arrayOf(j.exports.string),requiresIfExists:j.exports.arrayOf(j.exports.string)})),open:j.exports.bool.isRequired,placement:j.exports.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:j.exports.shape({modifiers:j.exports.array,onFirstUpdate:j.exports.func,placement:j.exports.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:j.exports.oneOf(["absolute","fixed"])}),popperRef:Fe,slotProps:j.exports.shape({root:j.exports.oneOfType([j.exports.func,j.exports.object])}),slots:j.exports.shape({root:j.exports.elementType}),transition:j.exports.bool});var ri=ti,ni="undefined"!=typeof window?T.useLayoutEffect:T.useEffect;function oi(e,t,r,n,o){var i="undefined"!=typeof window&&void 0!==window.matchMedia,s=Gr(T.useState((function(){return o&&i?r(e).matches:n?n(e).matches:t})),2),a=s[0],l=s[1];return ni((function(){var t=!0;if(i){var n=r(e),o=function(){t&&l(n.matches)};return o(),n.addListener(o),function(){t=!1,n.removeListener(o)}}}),[e,r,i]),a}var ii=T.useSyncExternalStore;function si(e,t,r,n){var o=T.useCallback((function(){return t}),[t]),i=T.useMemo((function(){if(null!==n){var t=n(e).matches;return function(){return t}}return o}),[o,e,n]),s=Gr(T.useMemo((function(){if(null===r)return[o,function(){return function(){}}];var t=r(e);return[function(){return t.matches},function(e){return t.addListener(e),function(){t.removeListener(e)}}]}),[o,r,e]),2),a=s[0],l=s[1];return ii(l,a,i)}function ai(){return{isMobile:function(e,t){void 0===t&&(t={});var r=Ar(),n="undefined"!=typeof window&&void 0!==window.matchMedia,o=Ur({name:"MuiUseMediaQuery",props:t,theme:r||void 0}),i=o.defaultMatches,s=void 0!==i&&i,a=o.matchMedia,l=void 0===a?n?window.matchMedia:null:a,c=o.ssrMatchMedia,u=void 0===c?null:c,d=o.noSsr;"production"!==process.env.NODE_ENV&&null===r&&console.error(["MUI: The `query` argument provided is invalid.","You are providing a function without a theme in the context.","One of the parent elements needs to use a ThemeProvider."].join("\n"));var p=e(r);p=p.replace(/^@media( ?)/m,"");var h=(void 0!==ii?si:oi)(p,s,l,u,d);return"production"!==process.env.NODE_ENV&&T.useDebugValue({query:p,match:h}),h}((function(e){return e.breakpoints.down("tablet")}))}}var li="DODOTooltip-arrow",ci=_r("div")((function(e){var t,r=e.theme;return"\n z-index: ".concat(null===(t=r.zIndex)||void 0===t?void 0:t.tooltip,';\n &[data-popper-placement*="bottom"] .').concat(li," {\n top: 0;\n margin-top: -").concat(8,'px;\n &::before {\n transform-origin: 0 100%;\n }\n }\n &[data-popper-placement*="top"] .').concat(li," {\n bottom: 0;\n margin-bottom: -").concat(8,'px;\n &::before {\n transform-origin: 100% 0;\n }\n }\n &[data-popper-placement*="right"] .').concat(li,' {\n &::before {\n transform-origin: 100% 100%;\n }\n }\n &[data-popper-placement*="left"] .').concat(li," {\n &::before {\n transform-origin: 0 0;\n }\n }\n ")}));function ui(e){var t=e.title,o=e.sx,i=e.maxWidth,s=void 0===i?"auto":i,a=e.popperOptions,l=e.children,c=e.onlyHover,u=e.enterDelay,d=void 0===u?100:u,p=e.leaveDelay,h=void 0===p?0:p,f=Yr(e,["title","sx","maxWidth","popperOptions","children","onlyHover","enterDelay","leaveDelay"]);kr();var m=ai().isMobile,g=n.useRef(!1),y=n.useRef(!1),b=n.useRef(),x=n.useRef(),v=Gr(n.useState(),2),w=v[0],E=v[1],A=Gr(n.useState(),2),C=A[0],k=A[1],R=Gr(n.useState(!1),2),T=R[0],S=R[1],N=m&&!c,M={ref:E};if(N)M.onClick=function(){S(!0)};else{var F=function(){y.current=!0,clearTimeout(x.current),clearTimeout(b.current),b.current=setTimeout((function(){S(!0)}),d)};M.onMouseOut=F,M.onMouseEnter=F,M.onMouseLeave=function(){y.current=!1,clearTimeout(x.current),clearTimeout(b.current),x.current=setTimeout((function(){y.current||g.current||S(!1)}),h)}}return n.useEffect((function(){return function(){S(!1),clearTimeout(x.current),clearTimeout(b.current)}}),[]),ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsxs(ri,zr({open:T,anchorEl:w,slots:{root:ci},popperOptions:r.merge({modifiers:[{name:"offset",options:{offset:[0,8]}},{name:"preventOverflow",options:{padding:20}},{name:"arrow",options:{element:C,padding:4}}]},a)},f,{children:[ne.exports.jsx(Sr,zr({sx:zr({typography:"h6",padding:12,maxWidth:s,fontWeight:500,backgroundColor:"background.paperContrast",borderRadius:8,color:"text.secondary",borderColor:"border.main",borderWidth:1,borderStyle:"solid",whiteSpace:"pre-wrap"},o),onMouseEnter:function(){N||(g.current=!0,clearTimeout(x.current),clearTimeout(b.current))},onMouseLeave:function(){N||(g.current=!1,clearTimeout(x.current),clearTimeout(b.current),x.current=setTimeout((function(){y.current||g.current||S(!1)}),h))},onClick:function(e){return e.stopPropagation()}},{children:t})),ne.exports.jsx(Sr,{ref:k,className:li,sx:{overflow:"hidden",position:"absolute",width:16,height:9,boxSizing:"border-box",color:"background.paperContrast",bottom:0,marginBottom:-8,"&::before":{transformOrigin:"100% 0",content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)",border:"solid 1px",borderColor:"border.main"}}})]})),ne.exports.jsx(Pn,zr({onClickAway:function(){N&&S(!1)}},{children:n.cloneElement(l,M)}))]})}function di(e){var t=e.title,r=e.ml,n=e.mr,o=e.size,s=void 0===o?15:o,a=e.sx,l=e.maxWidth,c=e.container;return e.onlyHover,t?ne.exports.jsx(ui,zr({title:t,placement:"top",container:c,maxWidth:l,onlyHover:!0},{children:ne.exports.jsx(In,{component:i.QuestionBorder,sx:zr({ml:r,mr:n,width:s,height:s},a)})})):null}function pi(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function hi(e){return parseInt(De(e).getComputedStyle(e).paddingRight,10)||0}function fi(e,t,r,n,o){const i=[t,r,...n];[].forEach.call(e.children,(e=>{const t=-1===i.indexOf(e),r=!function(e){const t=-1!==["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName),r="INPUT"===e.tagName&&"hidden"===e.getAttribute("type");return t||r}(e);t&&r&&pi(e,o)}))}function mi(e,t){let r=-1;return e.some(((e,n)=>!!t(e)&&(r=n,!0))),r}const gi=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function yi(e){const t=[],r=[];return Array.from(e.querySelectorAll(gi)).forEach(((e,n)=>{const o=function(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?"true"===e.contentEditable||("AUDIO"===e.nodeName||"VIDEO"===e.nodeName||"DETAILS"===e.nodeName)&&null===e.getAttribute("tabindex")?0:e.tabIndex:t}(e);-1!==o&&function(e){return!(e.disabled||"INPUT"===e.tagName&&"hidden"===e.type||function(e){if("INPUT"!==e.tagName||"radio"!==e.type)return!1;if(!e.name)return!1;const t=t=>e.ownerDocument.querySelector(`input[type="radio"]${t}`);let r=t(`[name="${e.name}"]:checked`);return r||(r=t(`[name="${e.name}"]`)),r!==e}(e))}(e)&&(0===o?t.push(e):r.push({documentOrder:n,tabIndex:o,node:e}))})),r.sort(((e,t)=>e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex)).map((e=>e.node)).concat(t)}function bi(){return!0}function xi(e){const{children:t,disableAutoFocus:r=!1,disableEnforceFocus:n=!1,disableRestoreFocus:o=!1,getTabbable:i=yi,isEnabled:s=bi,open:a}=e,l=T.useRef(!1),c=T.useRef(null),u=T.useRef(null),d=T.useRef(null),p=T.useRef(null),h=T.useRef(!1),f=T.useRef(null),m=_e(t.ref,f),g=T.useRef(null);T.useEffect((()=>{a&&f.current&&(h.current=!r)}),[r,a]),T.useEffect((()=>{if(!a||!f.current)return;const e=je(f.current);return f.current.contains(e.activeElement)||(f.current.hasAttribute("tabIndex")||("production"!==process.env.NODE_ENV&&console.error(["MUI: The modal content node does not accept focus.",'For the benefit of assistive technologies, the tabIndex of the node is being set to "-1".'].join("\n")),f.current.setAttribute("tabIndex","-1")),h.current&&f.current.focus()),()=>{o||(d.current&&d.current.focus&&(l.current=!0,d.current.focus()),d.current=null)}}),[a]),T.useEffect((()=>{if(!a||!f.current)return;const e=je(f.current),t=t=>{const{current:r}=f;if(null!==r)if(e.hasFocus()&&!n&&s()&&!l.current){if(!r.contains(e.activeElement)){if(t&&p.current!==t.target||e.activeElement!==p.current)p.current=null;else if(null!==p.current)return;if(!h.current)return;let n=[];if(e.activeElement!==c.current&&e.activeElement!==u.current||(n=i(f.current)),n.length>0){var o,a;const e=Boolean((null==(o=g.current)?void 0:o.shiftKey)&&"Tab"===(null==(a=g.current)?void 0:a.key)),t=n[0],r=n[n.length-1];"string"!=typeof t&&"string"!=typeof r&&(e?r.focus():t.focus())}else r.focus()}}else l.current=!1},r=t=>{g.current=t,!n&&s()&&"Tab"===t.key&&e.activeElement===f.current&&t.shiftKey&&(l.current=!0,u.current&&u.current.focus())};e.addEventListener("focusin",t),e.addEventListener("keydown",r,!0);const o=setInterval((()=>{e.activeElement&&"BODY"===e.activeElement.tagName&&t(null)}),50);return()=>{clearInterval(o),e.removeEventListener("focusin",t),e.removeEventListener("keydown",r,!0)}}),[r,n,o,s,a,i]);const y=e=>{null===d.current&&(d.current=e.relatedTarget),h.current=!0};return ne.exports.jsxs(T.Fragment,{children:[ne.exports.jsx("div",{tabIndex:a?0:-1,onFocus:y,ref:c,"data-testid":"sentinelStart"}),T.cloneElement(t,{ref:m,onFocus:e=>{null===d.current&&(d.current=e.relatedTarget),h.current=!0,p.current=e.target;const r=t.props.onFocus;r&&r(e)}}),ne.exports.jsx("div",{tabIndex:a?0:-1,onFocus:y,ref:u,"data-testid":"sentinelEnd"})]})}function vi(e){return $e("MuiModal",e)}"production"!==process.env.NODE_ENV&&(xi.propTypes={children:Ce,disableAutoFocus:j.exports.bool,disableEnforceFocus:j.exports.bool,disableRestoreFocus:j.exports.bool,getTabbable:j.exports.func,isEnabled:j.exports.func,open:j.exports.bool.isRequired}),"production"!==process.env.NODE_ENV&&(xi.propTypes=ke(xi.propTypes)),et("MuiModal",["root","hidden","backdrop"]);const wi=["children","closeAfterTransition","container","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","manager","onBackdropClick","onClose","onKeyDown","open","onTransitionEnter","onTransitionExited","slotProps","slots"],Ei=new class{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(e,t){let r=this.modals.indexOf(e);if(-1!==r)return r;r=this.modals.length,this.modals.push(e),e.modalRef&&pi(e.modalRef,!1);const n=function(e){const t=[];return[].forEach.call(e.children,(e=>{"true"===e.getAttribute("aria-hidden")&&t.push(e)})),t}(t);fi(t,e.mount,e.modalRef,n,!0);const o=mi(this.containers,(e=>e.container===t));return-1!==o?(this.containers[o].modals.push(e),r):(this.containers.push({modals:[e],container:t,restore:null,hiddenSiblings:n}),r)}mount(e,t){const r=mi(this.containers,(t=>-1!==t.modals.indexOf(e))),n=this.containers[r];n.restore||(n.restore=function(e,t){const r=[],n=e.container;if(!t.disableScrollLock){if(function(e){const t=je(e);return t.body===e?De(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}(n)){const e=function(e){const t=e.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}(je(n));r.push({value:n.style.paddingRight,property:"padding-right",el:n}),n.style.paddingRight=`${hi(n)+e}px`;const t=je(n).querySelectorAll(".mui-fixed");[].forEach.call(t,(t=>{r.push({value:t.style.paddingRight,property:"padding-right",el:t}),t.style.paddingRight=`${hi(t)+e}px`}))}let e;if(n.parentNode instanceof DocumentFragment)e=je(n).body;else{const t=n.parentElement,r=De(n);e="HTML"===(null==t?void 0:t.nodeName)&&"scroll"===r.getComputedStyle(t).overflowY?t:n}r.push({value:e.style.overflow,property:"overflow",el:e},{value:e.style.overflowX,property:"overflow-x",el:e},{value:e.style.overflowY,property:"overflow-y",el:e}),e.style.overflow="hidden"}return()=>{r.forEach((({value:e,el:t,property:r})=>{e?t.style.setProperty(r,e):t.style.removeProperty(r)}))}}(n,t))}remove(e,t=!0){const r=this.modals.indexOf(e);if(-1===r)return r;const n=mi(this.containers,(t=>-1!==t.modals.indexOf(e))),o=this.containers[n];if(o.modals.splice(o.modals.indexOf(e),1),this.modals.splice(r,1),0===o.modals.length)o.restore&&o.restore(),e.modalRef&&pi(e.modalRef,t),fi(o.container,e.mount,e.modalRef,o.hiddenSiblings,!1),this.containers.splice(n,1);else{const e=o.modals[o.modals.length-1];e.modalRef&&pi(e.modalRef,!1)}return r}isTopModal(e){return this.modals.length>0&&this.modals[this.modals.length-1]===e}},Ai=T.forwardRef((function(e,t){var r,n;const{children:o,closeAfterTransition:i=!1,container:s,disableAutoFocus:a=!1,disableEnforceFocus:l=!1,disableEscapeKeyDown:c=!1,disablePortal:u=!1,disableRestoreFocus:d=!1,disableScrollLock:p=!1,hideBackdrop:h=!1,keepMounted:f=!1,manager:m=Ei,onBackdropClick:g,onClose:y,onKeyDown:b,open:x,onTransitionEnter:v,onTransitionExited:w,slotProps:E={},slots:A={}}=e,C=ur(e,wi),k=m,[R,S]=T.useState(!x),N=T.useRef({}),M=T.useRef(null),F=T.useRef(null),O=_e(F,t),I=function(e){return!!e&&e.props.hasOwnProperty("in")}(o),j=null==(r=e["aria-hidden"])||r,D=()=>(N.current.modalRef=F.current,N.current.mountNode=M.current,N.current),B=()=>{k.mount(D(),{disableScrollLock:p}),F.current&&(F.current.scrollTop=0)},P=We((()=>{const e=function(e){return"function"==typeof e?e():e}(s)||je(M.current).body;k.add(D(),e),F.current&&B()})),W=T.useCallback((()=>k.isTopModal(D())),[k]),_=We((e=>{M.current=e,e&&F.current&&(x&&W()?B():pi(F.current,j))})),U=T.useCallback((()=>{k.remove(D(),j)}),[k,j]);T.useEffect((()=>()=>{U()}),[U]),T.useEffect((()=>{x?P():I&&i||U()}),[x,U,I,i,P]);const L=be({},e,{closeAfterTransition:i,disableAutoFocus:a,disableEnforceFocus:l,disableEscapeKeyDown:c,disablePortal:u,disableRestoreFocus:d,disableScrollLock:p,exited:R,hideBackdrop:h,keepMounted:f}),V=(e=>{const{open:t,exited:r}=e;return Je({root:["root",!t&&r&&"hidden"],backdrop:["backdrop"]},cn(vi))})(L),Z={};void 0===o.props.tabIndex&&(Z.tabIndex="-1"),I&&(Z.onEnter=Ie((()=>{S(!1),v&&v()}),o.props.onEnter),Z.onExited=Ie((()=>{S(!0),w&&w(),i&&U()}),o.props.onExited));const H=null!=(n=A.root)?n:"div",z=pn({elementType:H,externalSlotProps:E.root,externalForwardedProps:C,additionalProps:{ref:O,role:"presentation",onKeyDown:e=>{b&&b(e),"Escape"===e.key&&W()&&(c||(e.stopPropagation(),y&&y(e,"escapeKeyDown")))}},className:V.root,ownerState:L}),Y=A.backdrop,G=pn({elementType:Y,externalSlotProps:E.backdrop,additionalProps:{"aria-hidden":!0,onClick:e=>{e.target===e.currentTarget&&(g&&g(e),y&&y(e,"backdropClick"))},open:x},className:V.backdrop,ownerState:L});return f||x||I&&!R?ne.exports.jsx(Go,{ref:_,container:s,disablePortal:u,children:ne.exports.jsxs(H,be({},z,{children:[!h&&Y?ne.exports.jsx(Y,be({},G)):null,ne.exports.jsx(xi,{disableEnforceFocus:l,disableAutoFocus:a,disableRestoreFocus:d,isEnabled:W,open:x,children:T.cloneElement(o,Z)})]}))}):null}));"production"!==process.env.NODE_ENV&&(Ai.propTypes={children:Ce.isRequired,closeAfterTransition:j.exports.bool,container:j.exports.oneOfType([Me,j.exports.func]),disableAutoFocus:j.exports.bool,disableEnforceFocus:j.exports.bool,disableEscapeKeyDown:j.exports.bool,disablePortal:j.exports.bool,disableRestoreFocus:j.exports.bool,disableScrollLock:j.exports.bool,hideBackdrop:j.exports.bool,keepMounted:j.exports.bool,onBackdropClick:j.exports.func,onClose:j.exports.func,onTransitionEnter:j.exports.func,onTransitionExited:j.exports.func,open:j.exports.bool.isRequired,slotProps:j.exports.shape({backdrop:j.exports.oneOfType([j.exports.func,j.exports.object]),root:j.exports.oneOfType([j.exports.func,j.exports.object])}),slots:j.exports.shape({backdrop:j.exports.elementType,root:j.exports.elementType})});var Ci,ki,Ri=Ai,Ti=n.forwardRef((function(e,t){var r=e.open,n=e.className,o=Yr(e,["open","className"]);return ne.exports.jsx("div",zr({className:hr({"MuiBackdrop-open":r},n),ref:t},o))})),Si=_r(Ri)(Ci||(Ci=Jr(["\n position: absolute;\n z-index: 1300;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-end;\n"],["\n position: absolute;\n z-index: 1300;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-end;\n"]))),Ni=_r(Ti)(ki||(ki=Jr(["\n z-index: -1;\n position: absolute;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n background-color: ",";\n -webkit-tap-highlight-color: transparent;\n"],["\n z-index: -1;\n position: absolute;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n background-color: ",";\n -webkit-tap-highlight-color: transparent;\n"])),(function(e){return e.theme.palette.background.backdrop}));function Mi(e){return ne.exports.jsx(Si,zr({slots:{backdrop:Ni}},e))}var Fi=n.forwardRef((function(e,t){var r=kr(),n=e.size,o=void 0===n?18:n,s=e.sx,a=Yr(e,["size","sx"]);return ne.exports.jsx(Sr,zr({component:"span",sx:zr({position:"relative",cursor:"pointer",userSelect:"none",width:o,height:o,"&:hover > .checkbox-icon":{borderColor:r.palette.text.primary}},s)},{children:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Sr,zr({component:"input",type:"checkbox",ref:t,sx:{cursor:"inherit",position:"absolute",opacity:0,width:"100%",height:"100%",top:0,left:0,m:0,p:0,zIndex:1,"&:checked + .checkbox-icon":{border:"none",backgroundColor:"secondary.main",color:"secondary.contrastText","& svg":{display:"inline-block"}}}},a)),ne.exports.jsx(Sr,zr({component:"span",className:"checkbox-icon",sx:{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:4,width:o,height:o,borderStyle:"solid",borderWidth:1,flex:1,borderColor:r.palette.text.secondary,".Mui-focusVisible &":{outline:"none",outlineOffset:2},"input:disabled ~ &":{borderColor:r.palette.text.disabled}}},{children:ne.exports.jsx(Sr,{component:i.Done,sx:{display:"none",width:"75%",height:"75%"}})}))]})}))}));function Oi(){return Oi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Oi.apply(this,arguments)}function Ii(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}const ji=["preEnter","entering","entered","preExit","exiting","exited","unmounted"],Di=e=>e?6:5,Bi=new Map,Pi=new Map,Wi=(e,t,r,n,o,i)=>{clearTimeout(o);const s=(e=>({_s:e,status:ji[e],isEnter:e<3,isMounted:6!==e,isResolved:2===e||e>4}))(t),a=new Map(n.current);a.set(e,s),r(a),n.current=a,i&&i({key:e,current:s})},_i=["transition","transitionTimeout"],Ui=(e,t)=>!0===e||!(!e||!e[t]),Li=n.createContext({}),Vi=(e,t,r)=>(n,o)=>{const i=t?`${e}__${t}`:e;let s=i;r&&Object.keys(r).forEach((e=>{const t=r[e];t&&(s+=` ${i}--${!0===t?e:`${e}-${t}`}`)}));let a="function"==typeof n?n(o):n;return"string"==typeof a&&(a=a.trim(),a&&(s+=` ${a}`)),s},Zi=(e,t)=>{if(!t)return e;const r=Oi({},e);return Object.keys(t).forEach((n=>{const o=e[n],i=t[n];r[n]="function"==typeof i&&o?(...e)=>{o(...e),i(...e)}:i})),r},Hi=e=>ne.exports.jsx(Li.Provider,Oi({},e)),zi=e=>{do{e=e.parentElement}while(e&&!e.hasAttribute("data-szh-adn"));return e},Yi=(e,t,r)=>e?t>0?t-1:r-1:(t+1)%r,Gi=(e,t)=>{const{activeElement:r}=document;if(!r||!r.hasAttribute("data-szh-adn-btn")||zi(r)!==t.currentTarget)return;const n=t.currentTarget.querySelectorAll("[data-szh-adn-btn]"),{length:o}=n;for(let i=0;i<o;i++)if(n[i]===r){let r=Yi(e,i,o);for(;zi(n[i])!==zi(n[r]);)r=Yi(e,r,o);i!==r&&(t.preventDefault(),n[r].focus());break}},Xi=["providerValue","className"],Ji=n.forwardRef(((e,t)=>{let{providerValue:r,className:n}=e,o=Ii(e,Xi);const{accordionProps:i}={accordionProps:{"data-szh-adn":"",onKeyDown:e=>"ArrowUp"===e.key?Gi(!0,e):"ArrowDown"===e.key&&Gi(!1,e)}};return ne.exports.jsx(Hi,{value:r,children:ne.exports.jsx("div",Oi({},Zi(i,o),{ref:t,className:Vi("szh-accordion")(n)}))})}));Ji.displayName="ControlledAccordion";const qi=["allowMultiple","initialEntered","mountOnEnter","unmountOnExit","transition","transitionTimeout","onStateChange"],Qi=n.forwardRef(((e,t)=>{let{allowMultiple:r,initialEntered:o,mountOnEnter:i,unmountOnExit:s,transition:a,transitionTimeout:l,onStateChange:c}=e,u=Ii(e,qi);const d=((e={})=>{let{transition:t,transitionTimeout:r}=e,o=Ii(e,_i);const i=(({allowMultiple:e,enter:t=!0,exit:r=!0,preEnter:o,preExit:i,timeout:s,initialEntered:a,mountOnEnter:l,unmountOnExit:c,onStateChange:u}={})=>{const[d,p]=n.useState(Bi),h=n.useRef(d),f=n.useRef(Pi),[m,g]=(e=>"object"==typeof e?[e.enter,e.exit]:[e,e])(s),y=n.useCallback(((e,t)=>{const{initialEntered:r=a}=t||{},n=r?2:Di(l);Wi(e,n,p,h),f.current.set(e,{})}),[a,l]),b=n.useCallback((e=>{const t=new Map(h.current);return!!t.delete(e)&&(p(t),h.current=t,f.current.delete(e),!0)}),[]),x=n.useCallback((e=>{const t=h.current.get(e);if(!t)return void("production"!==process.env.NODE_ENV&&console.error(`[React-Transition-State] invalid key: ${e}`));const{timeoutId:r}=f.current.get(e),n=((e,t)=>{switch(e){case 1:case 0:return 2;case 4:case 3:return Di(t)}})(t._s,c);n&&Wi(e,n,p,h,r,u)}),[u,c]),v=n.useCallback(((n,s)=>{const a=h.current.get(n);if(!a)return void("production"!==process.env.NODE_ENV&&console.error(`[React-Transition-State] invalid key: ${n}`));const l=f.current.get(n),d=e=>{switch(Wi(n,e,p,h,l.timeoutId,u),e){case 1:m>=0&&(l.timeoutId=setTimeout((()=>x(n)),m));break;case 4:g>=0&&(l.timeoutId=setTimeout((()=>x(n)),g));break;case 0:case 3:l.timeoutId=setTimeout((()=>d(e+1)),0)}},y=a.isEnter;"boolean"!=typeof s&&(s=!y),s?y||(d(t?o?0:1:2),!e&&h.current.forEach(((e,t)=>t!==n&&v(t,!1)))):y&&d(r?i?3:4:Di(c))}),[u,x,e,t,r,o,i,m,g,c]),w=n.useCallback((t=>{if(e||!1===t)for(const e of h.current.keys())v(e,t)}),[e,v]);return{stateMap:d,toggle:v,toggleAll:w,endTransition:x,setItem:y,deleteItem:b}})(Oi({timeout:r,enter:Ui(t,"enter"),exit:Ui(t,"exit"),preEnter:Ui(t,"preEnter"),preExit:Ui(t,"preExit")},o));return Oi({mountOnEnter:!!o.mountOnEnter,initialEntered:!!o.initialEntered},i)})({allowMultiple:r,initialEntered:o,mountOnEnter:i,unmountOnExit:s,transition:a,transitionTimeout:l,onStateChange:c});return ne.exports.jsx(Ji,Oi({},u,{ref:t,providerValue:d}))}));Qi.displayName="Accordion";let Ki=0;const $i=n.useId||(()=>{const[e,t]=n.useState();return n.useEffect((()=>t(++Ki)),[]),e&&`szh-adn-${e}`}),es="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?n.useLayoutEffect:n.useEffect;function ts(e,t){"function"==typeof e?e(t):e.current=t}function rs(e,t){return n.useMemo((()=>e?t?r=>{ts(e,r),ts(t,r)}:e:t),[e,t])}const ns=["itemKey","initialEntered"],os=["forwardedRef","itemRef","state","toggle","className","disabled","header","headingTag","headingProps","buttonProps","contentProps","panelProps","children"],is=(e,t)=>"function"==typeof e?e(t):e,ss=n.memo((e=>{let{forwardedRef:t,itemRef:r,state:o,toggle:i,className:s,disabled:a,header:l,headingTag:c="h3",headingProps:u,buttonProps:d,contentProps:p,panelProps:h,children:f}=e,m=Ii(e,os);const g={state:o,toggle:i,disabled:a},{buttonProps:y,panelProps:b}=(({state:e,toggle:t,disabled:r})=>{const n=$i(),o=n&&n+"-",i={id:n,"aria-controls":o,"aria-expanded":e.isEnter,onClick:t};return r?i.disabled=!0:i["data-szh-adn-btn"]="",{buttonProps:i,panelProps:{id:o,"aria-labelledby":n,role:"region"}}})(g),[x,v]=(({status:e,isResolved:t})=>{const[r,o]=n.useState(),i=n.useRef(null);return es((()=>{("preEnter"===e||"preExit"===e)&&o(i.current.getBoundingClientRect().height)}),[e]),[{height:"preEnter"===e||"exiting"===e?0:"entering"===e||"preExit"===e?r:void 0,overflow:t?void 0:"hidden"},i]})(o),w=rs(h&&h.ref,v),{status:E,isMounted:A,isEnter:C}=o;return ne.exports.jsxs("div",Oi({},m,{ref:rs(t,r),className:Vi("szh-accordion","item",{status:E,expanded:C})(s,o),children:[ne.exports.jsx(c,Oi({},u,{style:Oi({margin:0},u&&u.style),className:Vi("szh-accordion","item-heading")(u&&u.className,o),children:ne.exports.jsx("button",Oi({},Zi(y,d),{type:"button",className:Vi("szh-accordion","item-btn")(d&&d.className,o),children:is(l,g)}))})),A&&ne.exports.jsx("div",Oi({},p,{style:Oi({display:"exited"===E?"none":void 0},x,p&&p.style),className:Vi("szh-accordion","item-content")(p&&p.className,o),children:ne.exports.jsx("div",Oi({},Zi(b,h),{ref:w,className:Vi("szh-accordion","item-panel")(h&&h.className,o),children:is(f,g)}))}))]}))}));ss.displayName="AccordionItem";const as=(e=>{const t=n.forwardRef(((t,r)=>{let{itemKey:o,initialEntered:i}=t,s=Ii(t,ns);return ne.exports.jsx(e,Oi({forwardedRef:r},s,(({itemKey:e,initialEntered:t,disabled:r}={})=>{const o=n.useRef(null),i=(()=>{const e=n.useContext(Li);if("production"!==process.env.NODE_ENV&&!e.stateMap)throw new Error("[React-Accordion] Cannot find a <AccordionProvider/> above this AccordionItem.");return e})(),s=null!=e?e:o.current,a=((e,t,r)=>{const{stateMap:n,mountOnEnter:o,initialEntered:i}=e,s=null!=r?r:i;return n.get(t)||{status:s?"entered":o?"unmounted":"exited",isMounted:!o,isEnter:s,isResolved:!0}})(i,s,t),{setItem:l,deleteItem:c,toggle:u}=i;return n.useEffect((()=>{if(r)return;const n=null!=e?e:o.current;return l(n,{initialEntered:t}),()=>{c(n)}}),[l,c,e,t,r]),{itemRef:o,state:a,toggle:n.useCallback((e=>u(s,e)),[u,s])}})({itemKey:o,initialEntered:i,disabled:s.disabled})))}));return t.displayName="WithAccordionItem",t})(ss);function ls(e){var t=e.sx,n=e.buttonProps,o=Yr(e,["sx","buttonProps"]);return ne.exports.jsx(Sr,zr({component:as,sx:r.merge({"& button":{p:0,border:"none",width:"100%",backgroundColor:"transparent",cursor:"pointer"}},t),buttonProps:zr({className:function(e){var t=e.isEnter;return"".concat(t?"active":"")}},n)},o))}function cs({input:e,showDecimals:r=4,showPrecisionDecimals:n=2,showIntegerOnly:o=!1,showDecimalsOnly:i=!1,noGroupSeparator:s=!1}){const a=new t.BigNumber(e);if(a.isNaN())return"-";let l=a.dp(r,t.BigNumber.ROUND_DOWN);return l.eq(0)&&(a.gt(0)||a.lt(0))&&(l=a.sd(null!=n?n:r,t.BigNumber.ROUND_DOWN)),o&&(l=l.integerValue(t.BigNumber.ROUND_DOWN)),i&&(l=l.minus(l.integerValue(t.BigNumber.ROUND_DOWN))),s?l.toFormat({decimalSeparator:".",groupSeparator:"",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:"",fractionGroupSize:0}):l.toFormat()}function us({input:e,decimals:r,showPrecisionDecimals:n=2,noGroupSeparator:o}){if(null==e)return"-";const i=new t.BigNumber(e);if(i.isNaN())return"-";return cs({input:i,showDecimals:void 0===r?0:r>6?6:r>4?4:r,showPrecisionDecimals:n,noGroupSeparator:o})}function ds(e){if("number"==typeof e)return ds(new t.BigNumber(e));if(e.isNaN())return"NaN";if(e.isNegative())return`-${ds(e.negated())}`;if(e.isZero())return"0";let r=e.integerValue(t.BigNumber.ROUND_FLOOR),n=e.minus(r),o="";for(;!r.isZero();){o=r.modulo(10).toString().toString()+o,r=r.idiv(10)}if(""===o&&(o="0"),n.isZero())return o;o+=".";let i=0;for(;!n.isZero()&&i<100;){const e=n.times(10),r=e.integerValue(t.BigNumber.ROUND_FLOOR);o+=r.toString(),n=e.minus(r),i+=1}return o}const ps=(e,r)=>{if("string"==typeof e&&!e.match(/[-+]?\d+(.+d+)?/))return e;const n=new t.BigNumber(e);if(r){let e=n.toFixed(r,t.BigNumber.ROUND_DOWN);return o=e,new t.BigNumber(o).isZero()&&(e=ds(n.precision(r,t.BigNumber.ROUND_DOWN))),e}var o;return ds(n)},hs=(e,t)=>{let r=e;const n=r.match("[0-9。.]+");r=n&&n.length>0?n[0]:"",r=r.replace("。",".");let o=0;if(r){const e=r.split("."),t=0===e[0].length?["0"]:[e[0]];e.length>1?t[1]=e.slice(1,e.length).join(""):t[0].length>1&&"0"===t[0][0]&&(t[0]=t[0].slice(1,t[0].length)),t.length>1&&(o=t[1].length),r=t.join(".")}return t>=0&&o>t?ps(r,t):r},fs=(e,r,n)=>{const o=new t.BigNumber(e).times(new t.BigNumber(10).pow(r));return n?o:o.dp(0)};function ms(e){return Number(e.toString().split(".")[0])}let gs=!1,ys=!1;const bs={debug:1,default:2,info:2,warning:3,error:4,off:5};let xs=bs.default,vs=null;const ws=function(){try{const e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((t=>{try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(e){return e.message}return null}();var Es,As;!function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(Es||(Es={})),function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED",e.ACTION_REJECTED="ACTION_REJECTED"}(As||(As={}));const Cs="0123456789abcdef";class ks{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,t){const r=e.toLowerCase();null==bs[r]&&this.throwArgumentError("invalid log level name","logLevel",e),xs>bs[r]||console.log.apply(console,t)}debug(...e){this._log(ks.levels.DEBUG,e)}info(...e){this._log(ks.levels.INFO,e)}warn(...e){this._log(ks.levels.WARNING,e)}makeError(e,t,r){if(ys)return this.makeError("censored error",t,{});t||(t=ks.errors.UNKNOWN_ERROR),r||(r={});const n=[];Object.keys(r).forEach((e=>{const t=r[e];try{if(t instanceof Uint8Array){let r="";for(let e=0;e<t.length;e++)r+=Cs[t[e]>>4],r+=Cs[15&t[e]];n.push(e+"=Uint8Array(0x"+r+")")}else n.push(e+"="+JSON.stringify(t))}catch(t){n.push(e+"="+JSON.stringify(r[e].toString()))}})),n.push(`code=${t}`),n.push(`version=${this.version}`);const o=e;let i="";switch(t){case As.NUMERIC_FAULT:{i="NUMERIC_FAULT";const t=e;switch(t){case"overflow":case"underflow":case"division-by-zero":i+="-"+t;break;case"negative-power":case"negative-width":i+="-unsupported";break;case"unbound-bitwise-result":i+="-unbound-result"}break}case As.CALL_EXCEPTION:case As.INSUFFICIENT_FUNDS:case As.MISSING_NEW:case As.NONCE_EXPIRED:case As.REPLACEMENT_UNDERPRICED:case As.TRANSACTION_REPLACED:case As.UNPREDICTABLE_GAS_LIMIT:i=t}i&&(e+=" [ See: https://links.ethers.org/v5-errors-"+i+" ]"),n.length&&(e+=" ("+n.join(", ")+")");const s=new Error(e);return s.reason=o,s.code=t,Object.keys(r).forEach((function(e){s[e]=r[e]})),s}throwError(e,t,r){throw this.makeError(e,t,r)}throwArgumentError(e,t,r){return this.throwError(e,ks.errors.INVALID_ARGUMENT,{argument:t,value:r})}assert(e,t,r,n){e||this.throwError(t,r,n)}assertArgument(e,t,r,n){e||this.throwArgumentError(t,r,n)}checkNormalize(e){ws&&this.throwError("platform missing String.prototype.normalize",ks.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:ws})}checkSafeUint53(e,t){"number"==typeof e&&(null==t&&(t="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(t,ks.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(t,ks.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,t,r){r=r?": "+r:"",e<t&&this.throwError("missing argument"+r,ks.errors.MISSING_ARGUMENT,{count:e,expectedCount:t}),e>t&&this.throwError("too many arguments"+r,ks.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:t})}checkNew(e,t){e!==Object&&null!=e||this.throwError("missing new",ks.errors.MISSING_NEW,{name:t.name})}checkAbstract(e,t){e===t?this.throwError("cannot instantiate abstract class "+JSON.stringify(t.name)+" directly; use a sub-class",ks.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):e!==Object&&null!=e||this.throwError("missing new",ks.errors.MISSING_NEW,{name:t.name})}static globalLogger(){return vs||(vs=new ks("logger/5.7.0")),vs}static setCensorship(e,t){if(!e&&t&&this.globalLogger().throwError("cannot permanently disable censorship",ks.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),gs){if(!e)return;this.globalLogger().throwError("error censorship permanent",ks.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}ys=!!e,gs=!!t}static setLogLevel(e){const t=bs[e.toLowerCase()];null!=t?xs=t:ks.globalLogger().warn("invalid log level - "+e)}static from(e){return new ks(e)}}ks.errors=As,ks.levels=Es;const Rs=new ks("bytes/5.7.0");function Ts(e){return!!e.toHexString}function Ss(e){return e.slice||(e.slice=function(){const t=Array.prototype.slice.call(arguments);return Ss(new Uint8Array(Array.prototype.slice.apply(e,t)))}),e}function Ns(e){return Ds(e)&&!(e.length%2)||Fs(e)}function Ms(e){return"number"==typeof e&&e==e&&e%1==0}function Fs(e){if(null==e)return!1;if(e.constructor===Uint8Array)return!0;if("string"==typeof e)return!1;if(!Ms(e.length)||e.length<0)return!1;for(let t=0;t<e.length;t++){const r=e[t];if(!Ms(r)||r<0||r>=256)return!1}return!0}function Os(e,t){if(t||(t={}),"number"==typeof e){Rs.checkSafeUint53(e,"invalid arrayify value");const t=[];for(;e;)t.unshift(255&e),e=parseInt(String(e/256));return 0===t.length&&t.push(0),Ss(new Uint8Array(t))}if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),Ts(e)&&(e=e.toHexString()),Ds(e)){let r=e.substring(2);r.length%2&&("left"===t.hexPad?r="0"+r:"right"===t.hexPad?r+="0":Rs.throwArgumentError("hex data is odd-length","value",e));const n=[];for(let e=0;e<r.length;e+=2)n.push(parseInt(r.substring(e,e+2),16));return Ss(new Uint8Array(n))}return Fs(e)?Ss(new Uint8Array(e)):Rs.throwArgumentError("invalid arrayify value","value",e)}function Is(e){const t=e.map((e=>Os(e))),r=t.reduce(((e,t)=>e+t.length),0),n=new Uint8Array(r);return t.reduce(((e,t)=>(n.set(t,e),e+t.length)),0),Ss(n)}function js(e){let t=Os(e);if(0===t.length)return t;let r=0;for(;r<t.length&&0===t[r];)r++;return r&&(t=t.slice(r)),t}function Ds(e,t){return!("string"!=typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&(!t||e.length===2+2*t)}function Bs(e,t){if(t||(t={}),"number"==typeof e){Rs.checkSafeUint53(e,"invalid hexlify value");let t="";for(;e;)t="0123456789abcdef"[15&e]+t,e=Math.floor(e/16);return t.length?(t.length%2&&(t="0"+t),"0x"+t):"0x00"}if("bigint"==typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),Ts(e))return e.toHexString();if(Ds(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":Rs.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(Fs(e)){let t="0x";for(let r=0;r<e.length;r++){let n=e[r];t+="0123456789abcdef"[(240&n)>>4]+"0123456789abcdef"[15&n]}return t}return Rs.throwArgumentError("invalid hexlify value","value",e)}function Ps(e){if("string"!=typeof e)e=Bs(e);else if(!Ds(e)||e.length%2)return null;return(e.length-2)/2}function Ws(e,t,r){return"string"!=typeof e?e=Bs(e):(!Ds(e)||e.length%2)&&Rs.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)}function _s(e){let t="0x";return e.forEach((e=>{t+=Bs(e).substring(2)})),t}function Us(e){const t=function(e){"string"!=typeof e&&(e=Bs(e));Ds(e)||Rs.throwArgumentError("invalid hex string","value",e);e=e.substring(2);let t=0;for(;t<e.length&&"0"===e[t];)t++;return"0x"+e.substring(t)}(Bs(e,{hexPad:"left"}));return"0x"===t?"0x0":t}function Ls(e,t){for("string"!=typeof e?e=Bs(e):Ds(e)||Rs.throwArgumentError("invalid hex string","value",e),e.length>2*t+2&&Rs.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function Vs(e){const t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(Ns(e)){let r=Os(e);64===r.length?(t.v=27+(r[32]>>7),r[32]&=127,t.r=Bs(r.slice(0,32)),t.s=Bs(r.slice(32,64))):65===r.length?(t.r=Bs(r.slice(0,32)),t.s=Bs(r.slice(32,64)),t.v=r[64]):Rs.throwArgumentError("invalid signature string","signature",e),t.v<27&&(0===t.v||1===t.v?t.v+=27:Rs.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=Bs(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){const r=function(e,t){(e=Os(e)).length>t&&Rs.throwArgumentError("value out of range","value",arguments[0]);const r=new Uint8Array(t);return r.set(e,t-e.length),Ss(r)}(Os(t._vs),32);t._vs=Bs(r);const n=r[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=n:t.recoveryParam!==n&&Rs.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),r[0]&=127;const o=Bs(r);null==t.s?t.s=o:t.s!==o&&Rs.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?Rs.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{const r=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==r&&Rs.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&Ds(t.r)?t.r=Ls(t.r,32):Rs.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&Ds(t.s)?t.s=Ls(t.s,32):Rs.throwArgumentError("signature missing or invalid s","signature",e);const r=Os(t.s);r[0]>=128&&Rs.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(r[0]|=128);const n=Bs(r);t._vs&&(Ds(t._vs)||Rs.throwArgumentError("signature invalid _vs","signature",e),t._vs=Ls(t._vs,32)),null==t._vs?t._vs=n:t._vs!==n&&Rs.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t.yParityAndS=t._vs,t.compact=t.r+t.yParityAndS.substring(2),t}var Zs={exports:{}};
|
|
37
|
+
*/function me(e,t){const r=T.default(e,t);return"production"!==process.env.NODE_ENV?(...t)=>{const n="string"==typeof e?`"${e}"`:"component";return 0===t.length?console.error([`MUI: Seems like you called \`styled(${n})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join("\n")):t.some((e=>void 0===e))&&console.error(`MUI: the styled(${n})(...args) API requires all its args to be defined.`),r(...t)}:r}!function(e){"production"===process.env.NODE_ENV?e.exports=function(){if(ce)return de;ce=1;var e,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),h=Symbol.for("react.offscreen");function m(e){if("object"==typeof e&&null!==e){var h=e.$$typeof;switch(h){case t:switch(e=e.type){case n:case i:case o:case u:case d:return e;default:switch(e=e&&e.$$typeof){case l:case a:case c:case f:case p:case s:return e;default:return h}}case r:return h}}}return e=Symbol.for("react.module.reference"),de.ContextConsumer=a,de.ContextProvider=s,de.Element=t,de.ForwardRef=c,de.Fragment=n,de.Lazy=f,de.Memo=p,de.Portal=r,de.Profiler=i,de.StrictMode=o,de.Suspense=u,de.SuspenseList=d,de.isAsyncMode=function(){return!1},de.isConcurrentMode=function(){return!1},de.isContextConsumer=function(e){return m(e)===a},de.isContextProvider=function(e){return m(e)===s},de.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},de.isForwardRef=function(e){return m(e)===c},de.isFragment=function(e){return m(e)===n},de.isLazy=function(e){return m(e)===f},de.isMemo=function(e){return m(e)===p},de.isPortal=function(e){return m(e)===r},de.isProfiler=function(e){return m(e)===i},de.isStrictMode=function(e){return m(e)===o},de.isSuspense=function(e){return m(e)===u},de.isSuspenseList=function(e){return m(e)===d},de.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===n||t===i||t===o||t===u||t===d||t===h||"object"==typeof t&&null!==t&&(t.$$typeof===f||t.$$typeof===p||t.$$typeof===s||t.$$typeof===a||t.$$typeof===c||t.$$typeof===e||void 0!==t.getModuleId)},de.typeOf=m,de}():e.exports=(pe||(pe=1,"production"!==process.env.NODE_ENV&&function(){var e,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),h=Symbol.for("react.offscreen");function m(e){if("object"==typeof e&&null!==e){var h=e.$$typeof;switch(h){case t:var m=e.type;switch(m){case n:case i:case o:case u:case d:return m;default:var g=m&&m.$$typeof;switch(g){case l:case a:case c:case f:case p:case s:return g;default:return h}}case r:return h}}}e=Symbol.for("react.module.reference");var g=a,y=s,b=t,v=c,x=n,w=f,E=p,A=r,k=i,C=o,R=u,S=d,T=!1,N=!1;fe.ContextConsumer=g,fe.ContextProvider=y,fe.Element=b,fe.ForwardRef=v,fe.Fragment=x,fe.Lazy=w,fe.Memo=E,fe.Portal=A,fe.Profiler=k,fe.StrictMode=C,fe.Suspense=R,fe.SuspenseList=S,fe.isAsyncMode=function(e){return T||(T=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1},fe.isConcurrentMode=function(e){return N||(N=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1},fe.isContextConsumer=function(e){return m(e)===a},fe.isContextProvider=function(e){return m(e)===s},fe.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},fe.isForwardRef=function(e){return m(e)===c},fe.isFragment=function(e){return m(e)===n},fe.isLazy=function(e){return m(e)===f},fe.isMemo=function(e){return m(e)===p},fe.isPortal=function(e){return m(e)===r},fe.isProfiler=function(e){return m(e)===i},fe.isStrictMode=function(e){return m(e)===o},fe.isSuspense=function(e){return m(e)===u},fe.isSuspenseList=function(e){return m(e)===d},fe.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===n||t===i||t===o||t===u||t===d||t===h||"object"==typeof t&&null!==t&&(t.$$typeof===f||t.$$typeof===p||t.$$typeof===s||t.$$typeof===a||t.$$typeof===c||t.$$typeof===e||void 0!==t.getModuleId)},fe.typeOf=m}()),fe)}(ue),"production"!==process.env.NODE_ENV&&(he.propTypes={defaultTheme:F.exports.object,styles:F.exports.oneOfType([F.exports.string,F.exports.object,F.exports.func])});var ge="production"!==process.env.NODE_ENV?F.exports.oneOfType([F.exports.number,F.exports.string,F.exports.object,F.exports.array]):{};function ye(e,t){return"production"===process.env.NODE_ENV?()=>null:function(...r){return e(...r)||t(...r)}}function be(){return be=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},be.apply(this,arguments)}function ve(e){return null!==e&&"object"==typeof e&&e.constructor===Object}function xe(e){if(!ve(e))return e;const t={};return Object.keys(e).forEach((r=>{t[r]=xe(e[r])})),t}function we(e,t,r={clone:!0}){const n=r.clone?be({},e):e;return ve(e)&&ve(t)&&Object.keys(t).forEach((o=>{"__proto__"!==o&&(ve(t[o])&&o in e&&ve(e[o])?n[o]=we(e[o],t[o],r):r.clone?n[o]=ve(t[o])?xe(t[o]):t[o]:n[o]=t[o])})),n}function Ee(e,t,r,n,o){const i=e[t],s=o||t;if(null==i||"undefined"==typeof window)return null;let a;const l=i.type;return"function"!=typeof l||function(e){const{prototype:t={}}=e;return Boolean(t.isReactComponent)}(l)||(a="Did you accidentally use a plain function component for an element instead?"),void 0!==a?new Error(`Invalid ${n} \`${s}\` supplied to \`${r}\`. Expected an element that can hold a ref. ${a} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Ae=ye(F.exports.element,Ee);Ae.isRequired=ye(F.exports.element.isRequired,Ee);var ke=Ae;function Ce(e){return"production"===process.env.NODE_ENV?e:be({},e,{"exact-prop: ":t=>{const r=Object.keys(t).filter((t=>!e.hasOwnProperty(t)));return r.length>0?new Error(`The following props are not supported: ${r.map((e=>`\`${e}\``)).join(", ")}. Please remove them.`):null}})}function Re(e){let t="https://mui.com/production-error/?code="+e;for(let e=1;e<arguments.length;e+=1)t+="&args[]="+encodeURIComponent(arguments[e]);return"Minified MUI error #"+e+"; visit "+t+" for the full message."}const Se=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function Te(e,t=""){return e.displayName||e.name||function(e){const t=`${e}`.match(Se);return t&&t[1]||""}(e)||t}function Ne(e,t,r){const n=Te(t);return e.displayName||(""!==n?`${r}(${n})`:r)}function Me(e,t,r,n,o){if("production"===process.env.NODE_ENV)return null;const i=e[t],s=o||t;return null==i?null:i&&1!==i.nodeType?new Error(`Invalid ${n} \`${s}\` supplied to \`${r}\`. Expected an HTMLElement.`):null}var Oe=F.exports.oneOfType([F.exports.func,F.exports.object]);function Ie(e){if("string"!=typeof e)throw new Error("production"!==process.env.NODE_ENV?"MUI: `capitalize(string)` expects a string argument.":Re(7));return e.charAt(0).toUpperCase()+e.slice(1)}function je(...e){return e.reduce(((e,t)=>null==t?e:function(...r){e.apply(this,r),t.apply(this,r)}),(()=>{}))}function Fe(e){return e&&e.ownerDocument||document}function _e(e){return Fe(e).defaultView||window}function Pe(e,t){"function"==typeof e?e(t):e&&(e.current=t)}var Be="undefined"!=typeof window?S.useLayoutEffect:S.useEffect;function We(e){const t=S.useRef(e);return Be((()=>{t.current=e})),S.useCallback(((...e)=>(0,t.current)(...e)),[])}function De(...e){return S.useMemo((()=>e.every((e=>null==e))?null:t=>{e.forEach((e=>{Pe(e,t)}))}),e)}let Le,Ue=!0,Ve=!1;const Ze={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function He(e){e.metaKey||e.altKey||e.ctrlKey||(Ue=!0)}function ze(){Ue=!1}function Ye(){"hidden"===this.visibilityState&&Ve&&(Ue=!0)}function Ge(){const e=S.useCallback((e=>{var t;null!=e&&((t=e.ownerDocument).addEventListener("keydown",He,!0),t.addEventListener("mousedown",ze,!0),t.addEventListener("pointerdown",ze,!0),t.addEventListener("touchstart",ze,!0),t.addEventListener("visibilitychange",Ye,!0))}),[]),t=S.useRef(!1);return{isFocusVisibleRef:t,onFocus:function(e){return!!function(e){const{target:t}=e;try{return t.matches(":focus-visible")}catch(e){}return Ue||function(e){const{type:t,tagName:r}=e;return!("INPUT"!==r||!Ze[t]||e.readOnly)||"TEXTAREA"===r&&!e.readOnly||!!e.isContentEditable}(t)}(e)&&(t.current=!0,!0)},onBlur:function(){return!!t.current&&(Ve=!0,window.clearTimeout(Le),Le=window.setTimeout((()=>{Ve=!1}),100),t.current=!1,!0)},ref:e}}function Xe(e,t){const r=be({},t);return Object.keys(e).forEach((n=>{if(n.toString().match(/^(components|slots)$/))r[n]=be({},e[n],r[n]);else if(n.toString().match(/^(componentsProps|slotProps)$/)){const o=e[n]||{},i=t[n];r[n]={},i&&Object.keys(i)?o&&Object.keys(o)?(r[n]=be({},i),Object.keys(o).forEach((e=>{r[n][e]=Xe(o[e],i[e])}))):r[n]=i:r[n]=o}else void 0===r[n]&&(r[n]=e[n])})),r}function Je(e,t,r){const n={};return Object.keys(e).forEach((o=>{n[o]=e[o].reduce(((e,n)=>{if(n){const o=t(n);""!==o&&e.push(o),r&&r[n]&&e.push(r[n])}return e}),[]).join(" ")})),n}const qe=e=>e;var Qe=(()=>{let e=qe;return{configure(t){e=t},generate:t=>e(t),reset(){e=qe}}})();const Ke={active:"active",checked:"checked",completed:"completed",disabled:"disabled",readOnly:"readOnly",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",required:"required",selected:"selected"};function $e(e,t,r="Mui"){const n=Ke[t];return n?`${r}-${n}`:`${Qe.generate(e)}-${t}`}function et(e,t,r="Mui"){const n={};return t.forEach((t=>{n[t]=$e(e,t,r)})),n}function tt(e,t){return t?we(e,t,{clone:!1}):e}const rt={xs:0,sm:600,md:900,lg:1200,xl:1536},nt={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${rt[e]}px)`};function ot(e,t,r){const n=e.theme||{};if(Array.isArray(t)){const e=n.breakpoints||nt;return t.reduce(((n,o,i)=>(n[e.up(e.keys[i])]=r(t[i]),n)),{})}if("object"==typeof t){const e=n.breakpoints||nt;return Object.keys(t).reduce(((n,o)=>{if(-1!==Object.keys(e.values||rt).indexOf(o))n[e.up(o)]=r(t[o],o);else{const e=o;n[e]=t[e]}return n}),{})}return r(t)}function it(e,t,r=!0){if(!t||"string"!=typeof t)return null;if(e&&e.vars&&r){const r=`vars.${t}`.split(".").reduce(((e,t)=>e&&e[t]?e[t]:null),e);if(null!=r)return r}return t.split(".").reduce(((e,t)=>e&&null!=e[t]?e[t]:null),e)}function st(e,t,r,n=r){let o;return o="function"==typeof e?e(r):Array.isArray(e)?e[r]||n:it(e,r)||n,t&&(o=t(o)),o}function at(e){const{prop:t,cssProperty:r=e.prop,themeKey:n,transform:o}=e,i=e=>{if(null==e[t])return null;const i=e[t],s=it(e.theme,n)||{};return ot(e,i,(e=>{let n=st(s,o,e);return e===n&&"string"==typeof e&&(n=st(s,o,`${t}${"default"===e?"":Ie(e)}`,e)),!1===r?n:{[r]:n}}))};return i.propTypes="production"!==process.env.NODE_ENV?{[t]:ge}:{},i.filterProps=[t],i}function lt(...e){const t=e.reduce(((e,t)=>(t.filterProps.forEach((r=>{e[r]=t})),e)),{}),r=e=>Object.keys(e).reduce(((r,n)=>t[n]?tt(r,t[n](e)):r),{});return r.propTypes="production"!==process.env.NODE_ENV?e.reduce(((e,t)=>Object.assign(e,t.propTypes)),{}):{},r.filterProps=e.reduce(((e,t)=>e.concat(t.filterProps)),[]),r}const ct={m:"margin",p:"padding"},ut={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},dt={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},pt=function(e){const t={};return e=>(void 0===t[e]&&(t[e]=(e=>{if(e.length>2){if(!dt[e])return[e];e=dt[e]}const[t,r]=e.split(""),n=ct[t],o=ut[r]||"";return Array.isArray(o)?o.map((e=>n+e)):[n+o]})(e)),t[e])}(),ft=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],ht=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],mt=[...ft,...ht];function gt(e,t,r,n){var o;const i=null!=(o=it(e,t,!1))?o:r;return"number"==typeof i?e=>"string"==typeof e?e:("production"!==process.env.NODE_ENV&&"number"!=typeof e&&console.error(`MUI: Expected ${n} argument to be a number or a string, got ${e}.`),i*e):Array.isArray(i)?e=>"string"==typeof e?e:("production"!==process.env.NODE_ENV&&(Number.isInteger(e)?e>i.length-1&&console.error([`MUI: The value provided (${e}) overflows.`,`The supported values are: ${JSON.stringify(i)}.`,`${e} > ${i.length-1}, you need to add the missing values.`].join("\n")):console.error([`MUI: The \`theme.${t}\` array type cannot be combined with non integer values.You should either use an integer value that can be used as index, or define the \`theme.${t}\` as a number.`].join("\n"))),i[e]):"function"==typeof i?i:("production"!==process.env.NODE_ENV&&console.error([`MUI: The \`theme.${t}\` value (${i}) is invalid.`,"It should be a number, an array or a function."].join("\n")),()=>{})}function yt(e){return gt(e,"spacing",8,"spacing")}function bt(e,t){if("string"==typeof t||null==t)return t;const r=e(Math.abs(t));return t>=0?r:"number"==typeof r?-r:`-${r}`}function vt(e){return function(e,t){const r=yt(e.theme);return Object.keys(e).map((n=>function(e,t,r,n){if(-1===t.indexOf(r))return null;const o=function(e,t){return r=>e.reduce(((e,n)=>(e[n]=bt(t,r),e)),{})}(pt(r),n);return ot(e,e[r],o)}(e,t,n,r))).reduce(tt,{})}(e,mt)}function xt(e){return"number"!=typeof e?e:`${e}px solid`}"production"===process.env.NODE_ENV||ft.reduce(((e,t)=>(e[t]=ge,e)),{}),"production"===process.env.NODE_ENV||ht.reduce(((e,t)=>(e[t]=ge,e)),{}),vt.propTypes="production"!==process.env.NODE_ENV?mt.reduce(((e,t)=>(e[t]=ge,e)),{}):{},vt.filterProps=mt;const wt=at({prop:"border",themeKey:"borders",transform:xt}),Et=at({prop:"borderTop",themeKey:"borders",transform:xt}),At=at({prop:"borderRight",themeKey:"borders",transform:xt}),kt=at({prop:"borderBottom",themeKey:"borders",transform:xt}),Ct=at({prop:"borderLeft",themeKey:"borders",transform:xt}),Rt=at({prop:"borderColor",themeKey:"palette"}),St=at({prop:"borderTopColor",themeKey:"palette"}),Tt=at({prop:"borderRightColor",themeKey:"palette"}),Nt=at({prop:"borderBottomColor",themeKey:"palette"}),Mt=at({prop:"borderLeftColor",themeKey:"palette"}),Ot=e=>{if(void 0!==e.borderRadius&&null!==e.borderRadius){const t=gt(e.theme,"shape.borderRadius",4,"borderRadius"),r=e=>({borderRadius:bt(t,e)});return ot(e,e.borderRadius,r)}return null};Ot.propTypes="production"!==process.env.NODE_ENV?{borderRadius:ge}:{},Ot.filterProps=["borderRadius"];var It=lt(wt,Et,At,kt,Ct,Rt,St,Tt,Nt,Mt,Ot),jt=lt(at({prop:"displayPrint",cssProperty:!1,transform:e=>({"@media print":{display:e}})}),at({prop:"display"}),at({prop:"overflow"}),at({prop:"textOverflow"}),at({prop:"visibility"}),at({prop:"whiteSpace"})),Ft=lt(at({prop:"flexBasis"}),at({prop:"flexDirection"}),at({prop:"flexWrap"}),at({prop:"justifyContent"}),at({prop:"alignItems"}),at({prop:"alignContent"}),at({prop:"order"}),at({prop:"flex"}),at({prop:"flexGrow"}),at({prop:"flexShrink"}),at({prop:"alignSelf"}),at({prop:"justifyItems"}),at({prop:"justifySelf"}));const _t=e=>{if(void 0!==e.gap&&null!==e.gap){const t=gt(e.theme,"spacing",8,"gap"),r=e=>({gap:bt(t,e)});return ot(e,e.gap,r)}return null};_t.propTypes="production"!==process.env.NODE_ENV?{gap:ge}:{},_t.filterProps=["gap"];const Pt=e=>{if(void 0!==e.columnGap&&null!==e.columnGap){const t=gt(e.theme,"spacing",8,"columnGap"),r=e=>({columnGap:bt(t,e)});return ot(e,e.columnGap,r)}return null};Pt.propTypes="production"!==process.env.NODE_ENV?{columnGap:ge}:{},Pt.filterProps=["columnGap"];const Bt=e=>{if(void 0!==e.rowGap&&null!==e.rowGap){const t=gt(e.theme,"spacing",8,"rowGap"),r=e=>({rowGap:bt(t,e)});return ot(e,e.rowGap,r)}return null};Bt.propTypes="production"!==process.env.NODE_ENV?{rowGap:ge}:{},Bt.filterProps=["rowGap"];var Wt=lt(_t,Pt,Bt,at({prop:"gridColumn"}),at({prop:"gridRow"}),at({prop:"gridAutoFlow"}),at({prop:"gridAutoColumns"}),at({prop:"gridAutoRows"}),at({prop:"gridTemplateColumns"}),at({prop:"gridTemplateRows"}),at({prop:"gridTemplateAreas"}),at({prop:"gridArea"})),Dt=lt(at({prop:"color",themeKey:"palette"}),at({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette"}),at({prop:"backgroundColor",themeKey:"palette"})),Lt=lt(at({prop:"position"}),at({prop:"zIndex",themeKey:"zIndex"}),at({prop:"top"}),at({prop:"right"}),at({prop:"bottom"}),at({prop:"left"})),Ut=at({prop:"boxShadow",themeKey:"shadows"});function Vt(e){return e<=1&&0!==e?100*e+"%":e}const Zt=at({prop:"width",transform:Vt}),Ht=e=>{if(void 0!==e.maxWidth&&null!==e.maxWidth){const t=t=>{var r,n,o;return{maxWidth:(null==(r=e.theme)||null==(n=r.breakpoints)||null==(o=n.values)?void 0:o[t])||rt[t]||Vt(t)}};return ot(e,e.maxWidth,t)}return null};Ht.filterProps=["maxWidth"];const zt=at({prop:"minWidth",transform:Vt}),Yt=at({prop:"height",transform:Vt}),Gt=at({prop:"maxHeight",transform:Vt}),Xt=at({prop:"minHeight",transform:Vt});at({prop:"size",cssProperty:"width",transform:Vt}),at({prop:"size",cssProperty:"height",transform:Vt});var Jt=lt(Zt,Ht,zt,Yt,Gt,Xt,at({prop:"boxSizing"}));const qt=at({prop:"fontFamily",themeKey:"typography"}),Qt=at({prop:"fontSize",themeKey:"typography"}),Kt=at({prop:"fontStyle",themeKey:"typography"}),$t=at({prop:"fontWeight",themeKey:"typography"}),er=at({prop:"letterSpacing"}),tr=at({prop:"textTransform"}),rr=at({prop:"lineHeight"}),nr=at({prop:"textAlign"});var or=lt(at({prop:"typography",cssProperty:!1,themeKey:"typography"}),qt,Qt,Kt,$t,er,rr,nr,tr);const ir={borders:It.filterProps,display:jt.filterProps,flexbox:Ft.filterProps,grid:Wt.filterProps,positions:Lt.filterProps,palette:Dt.filterProps,shadows:Ut.filterProps,sizing:Jt.filterProps,spacing:vt.filterProps,typography:or.filterProps},sr={borders:It,display:jt,flexbox:Ft,grid:Wt,positions:Lt,palette:Dt,shadows:Ut,sizing:Jt,spacing:vt,typography:or},ar=Object.keys(ir).reduce(((e,t)=>(ir[t].forEach((r=>{e[r]=sr[t]})),e)),{}),lr=function(e=sr){const t=Object.keys(e).reduce(((t,r)=>(e[r].filterProps.forEach((n=>{t[n]=e[r]})),t)),{});function r(e,r,n){const o={[e]:r,theme:n},i=t[e];return i?i(o):{[e]:r}}return function e(n){const{sx:o,theme:i={}}=n||{};if(!o)return null;function s(n){let o=n;if("function"==typeof n)o=n(i);else if("object"!=typeof n)return n;if(!o)return null;const s=function(e={}){var t;return(null==e||null==(t=e.keys)?void 0:t.reduce(((t,r)=>(t[e.up(r)]={},t)),{}))||{}}(i.breakpoints),a=Object.keys(s);let l=s;return Object.keys(o).forEach((n=>{const s="function"==typeof(a=o[n])?a(i):a;var a;if(null!=s)if("object"==typeof s)if(t[n])l=tt(l,r(n,s,i));else{const t=ot({theme:i},s,(e=>({[n]:e})));!function(...e){const t=e.reduce(((e,t)=>e.concat(Object.keys(t))),[]),r=new Set(t);return e.every((e=>r.size===Object.keys(e).length))}(t,s)?l=tt(l,t):l[n]=e({sx:s,theme:i})}else l=tt(l,r(n,s,i))})),function(e,t){return e.reduce(((e,t)=>{const r=e[t];return(!r||0===Object.keys(r).length)&&delete e[t],e}),t)}(a,l)}return Array.isArray(o)?o.map(s):s(o)}}();lr.filterProps=["sx"];var cr=lr;function ur(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}const dr=["sx"];function pr(e){var t,r,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(r=pr(e[t]))&&(n&&(n+=" "),n+=r);else for(t in e)e[t]&&(n&&(n+=" "),n+=t);return n}function fr(){for(var e,t,r=0,n="";r<arguments.length;)(e=arguments[r++])&&(t=pr(e))&&(n&&(n+=" "),n+=t);return n}const hr=["values","unit","step"];var mr={borderRadius:4};const gr=["breakpoints","palette","spacing","shape"];function yr(e={},...t){const{breakpoints:r={},palette:n={},spacing:o,shape:i={}}=e,s=ur(e,gr),a=function(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:r="px",step:n=5}=e,o=ur(e,hr),i=(e=>{const t=Object.keys(e).map((t=>({key:t,val:e[t]})))||[];return t.sort(((e,t)=>e.val-t.val)),t.reduce(((e,t)=>be({},e,{[t.key]:t.val})),{})})(t),s=Object.keys(i);function a(e){return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r})`}function l(e){return`@media (max-width:${("number"==typeof t[e]?t[e]:e)-n/100}${r})`}function c(e,o){const i=s.indexOf(o);return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${r}) and (max-width:${(-1!==i&&"number"==typeof t[s[i]]?t[s[i]]:o)-n/100}${r})`}return be({keys:s,values:i,up:a,down:l,between:c,only:function(e){return s.indexOf(e)+1<s.length?c(e,s[s.indexOf(e)+1]):a(e)},not:function(e){const t=s.indexOf(e);return 0===t?a(s[1]):t===s.length-1?l(s[t]):c(e,s[s.indexOf(e)+1]).replace("@media","@media not all and")},unit:r},o)}(r),l=function(e=8){if(e.mui)return e;const t=yt({spacing:e}),r=(...e)=>("production"!==process.env.NODE_ENV&&(e.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${e.length}`)),(0===e.length?[1]:e).map((e=>{const r=t(e);return"number"==typeof r?`${r}px`:r})).join(" "));return r.mui=!0,r}(o);let c=we({breakpoints:a,direction:"ltr",components:{},palette:be({mode:"light"},n),spacing:l,shape:be({},mr,i)},s);return c=t.reduce(((e,t)=>we(e,t)),c),c}const br=S.createContext(null);"production"!==process.env.NODE_ENV&&(br.displayName="ThemeContext");var vr=br;function xr(){const e=S.useContext(vr);return"production"!==process.env.NODE_ENV&&S.useDebugValue(e),e}var wr="function"==typeof Symbol&&Symbol.for?Symbol.for("mui.nested"):"__THEME_NESTED__";function Er(e){const{children:t,theme:r}=e,n=xr();"production"!==process.env.NODE_ENV&&null===n&&"function"==typeof r&&console.error(["MUI: You are providing a theme function prop to the ThemeProvider component:","<ThemeProvider theme={outerTheme => outerTheme} />","","However, no outer theme is present.","Make sure a theme is already injected higher in the React tree or provide a theme object."].join("\n"));const o=S.useMemo((()=>{const e=null===n?r:function(e,t){if("function"==typeof t){const r=t(e);return"production"!==process.env.NODE_ENV&&(r||console.error(["MUI: You should return an object from your theme function, i.e.","<ThemeProvider theme={() => ({})} />"].join("\n"))),r}return be({},e,t)}(n,r);return null!=e&&(e[wr]=null!==n),e}),[r,n]);return ne.exports.jsx(vr.Provider,{value:o,children:t})}function Ar(e=null){const t=xr();return t&&(r=t,0!==Object.keys(r).length)?t:e;var r}"production"!==process.env.NODE_ENV&&(Er.propTypes={children:F.exports.node,theme:F.exports.oneOfType([F.exports.object,F.exports.func]).isRequired}),"production"!==process.env.NODE_ENV&&"production"!==process.env.NODE_ENV&&(Er.propTypes=Ce(Er.propTypes));const kr=yr();function Cr(e=kr){return Ar(e)}const Rr=["className","component"],Sr=function(e={}){const{defaultTheme:t,defaultClassName:r="MuiBox-root",generateClassName:n,styleFunctionSx:o=cr}=e,i=me("div")(o);return S.forwardRef((function(e,o){const s=Cr(t),a=function(e){const{sx:t}=e,r=ur(e,dr),{systemProps:n,otherProps:o}=(e=>{const t={systemProps:{},otherProps:{}};return Object.keys(e).forEach((r=>{ar[r]?t.systemProps[r]=e[r]:t.otherProps[r]=e[r]})),t})(r);let i;return i=Array.isArray(t)?[n,...t]:"function"==typeof t?(...e)=>{const r=t(...e);return ve(r)?be({},n,r):n}:be({},n,t),be({},o,{sx:i})}(e),{className:l,component:c="div"}=a,u=ur(a,Rr);return ne.exports.jsx(i,be({as:c,ref:o,className:fr(l,n?n(r):r),theme:s},u))}))}();"production"!==process.env.NODE_ENV&&(Sr.propTypes={children:F.exports.node,component:F.exports.elementType,sx:F.exports.oneOfType([F.exports.arrayOf(F.exports.oneOfType([F.exports.func,F.exports.object,F.exports.bool])),F.exports.func,F.exports.object])});var Tr=Sr;const Nr=["variant"];function Mr(e){return 0===e.length}function Or(e){const{variant:t}=e,r=ur(e,Nr);let n=t||"";return Object.keys(r).sort().forEach((t=>{n+="color"===t?Mr(n)?e[t]:Ie(e[t]):`${Mr(n)?t:Ie(t)}${Ie(e[t].toString())}`})),n}const Ir=["name","slot","skipVariantsResolver","skipSx","overridesResolver"],jr=["theme"],Fr=["theme"];function _r(e){return 0===Object.keys(e).length}function Pr(e){return"ownerState"!==e&&"theme"!==e&&"sx"!==e&&"as"!==e}const Br=yr(),Wr=function(e={}){const{defaultTheme:t=Br,rootShouldForwardProp:r=Pr,slotShouldForwardProp:n=Pr,styleFunctionSx:o=cr}=e;return(e,i={})=>{const{name:s,slot:a,skipVariantsResolver:l,skipSx:c,overridesResolver:u}=i,d=ur(i,Ir),p=void 0!==l?l:a&&"Root"!==a||!1,f=c||!1;let h;var m;"production"!==process.env.NODE_ENV&&s&&(h=`${s}-${m=a||"Root",m.charAt(0).toLowerCase()+m.slice(1)}`);let g=Pr;"Root"===a?g=r:a&&(g=n);const y=me(e,be({shouldForwardProp:g,label:h},d)),b=(r,...n)=>{const i=n?n.map((e=>"function"==typeof e&&e.__emotion_real!==e?r=>{let{theme:n}=r,o=ur(r,jr);return e(be({theme:_r(n)?t:n},o))}:e)):[];let l=r;s&&u&&i.push((e=>{const r=_r(e.theme)?t:e.theme,n=((e,t)=>t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null)(s,r);if(n){const t={};return Object.entries(n).forEach((([n,o])=>{t[n]="function"==typeof o?o(be({},e,{theme:r})):o})),u(e,t)}return null})),s&&!p&&i.push((e=>{const r=_r(e.theme)?t:e.theme;return((e,t,r,n)=>{var o,i;const{ownerState:s={}}=e,a=[],l=null==r||null==(o=r.components)||null==(i=o[n])?void 0:i.variants;return l&&l.forEach((r=>{let n=!0;Object.keys(r.props).forEach((t=>{s[t]!==r.props[t]&&e[t]!==r.props[t]&&(n=!1)})),n&&a.push(t[Or(r.props)])})),a})(e,((e,t)=>{let r=[];t&&t.components&&t.components[e]&&t.components[e].variants&&(r=t.components[e].variants);const n={};return r.forEach((e=>{const t=Or(e.props);n[t]=e.style})),n})(s,r),r,s)})),f||i.push((e=>{const r=_r(e.theme)?t:e.theme;return o(be({},e,{theme:r}))}));const c=i.length-n.length;if(Array.isArray(r)&&c>0){const e=new Array(c).fill("");l=[...r,...e],l.raw=[...r.raw,...e]}else"function"==typeof r&&r.__emotion_real!==r&&(l=e=>{let{theme:n}=e,o=ur(e,Fr);return r(be({theme:_r(n)?t:n},o))});const d=y(l,...i);if("production"!==process.env.NODE_ENV){let t;s&&(t=`${s}${a||""}`),void 0===t&&(t=`Styled(${function(e){if(null!=e){if("string"==typeof e)return e;if("function"==typeof e)return Te(e,"Component");if("object"==typeof e)switch(e.$$typeof){case ue.exports.ForwardRef:return Ne(e,e.render,"ForwardRef");case ue.exports.Memo:return Ne(e,e.type,"memo");default:return}}}(e)})`),d.displayName=t}return d};return y.withConfig&&(b.withConfig=y.withConfig),b}}();var Dr=Wr;function Lr(e){const{theme:t,name:r,props:n}=e;return t&&t.components&&t.components[r]&&t.components[r].defaultProps?Xe(t.components[r].defaultProps,n):n}function Ur(e){if(e.type)return e;if("#"===e.charAt(0))return Ur(function(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let r=e.match(t);return r&&1===r[0].length&&(r=r.map((e=>e+e))),r?`rgb${4===r.length?"a":""}(${r.map(((e,t)=>t<3?parseInt(e,16):Math.round(parseInt(e,16)/255*1e3)/1e3)).join(", ")})`:""}(e));const t=e.indexOf("("),r=e.substring(0,t);if(-1===["rgb","rgba","hsl","hsla","color"].indexOf(r))throw new Error("production"!==process.env.NODE_ENV?`MUI: Unsupported \`${e}\` color.\nThe following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:Re(9,e));let n,o=e.substring(t+1,e.length-1);if("color"===r){if(o=o.split(" "),n=o.shift(),4===o.length&&"/"===o[3].charAt(0)&&(o[3]=o[3].slice(1)),-1===["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(n))throw new Error("production"!==process.env.NODE_ENV?`MUI: unsupported \`${n}\` color space.\nThe following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:Re(10,n))}else o=o.split(",");return o=o.map((e=>parseFloat(e))),{type:r,values:o,colorSpace:n}}function Vr(e,t){return e=Ur(e),t=function(e,t=0,r=1){return"production"!==process.env.NODE_ENV&&(e<t||e>r)&&console.error(`MUI: The value provided ${e} is out of range [${t}, ${r}].`),Math.min(Math.max(t,e),r)}(t),"rgb"!==e.type&&"hsl"!==e.type||(e.type+="a"),"color"===e.type?e.values[3]=`/${t}`:e.values[3]=t,function(e){const{type:t,colorSpace:r}=e;let{values:n}=e;return-1!==t.indexOf("rgb")?n=n.map(((e,t)=>t<3?parseInt(e,10):e)):-1!==t.indexOf("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),n=-1!==t.indexOf("color")?`${r} ${n.join(" ")}`:`${n.join(", ")}`,`${t}(${n})`}(e)}function Zr(e){const t=Cr();return ne.exports.jsx(o.ThemeContext.Provider,{value:"object"==typeof t?t:{},children:e.children})}function Hr(e){const{children:t,theme:r}=e;return ne.exports.jsx(Er,{theme:r,children:ne.exports.jsx(Zr,{children:t})})}"production"!==process.env.NODE_ENV&&(Zr.propTypes={children:F.exports.node}),"production"!==process.env.NODE_ENV&&(Hr.propTypes={children:F.exports.node,theme:F.exports.oneOfType([F.exports.func,F.exports.object]).isRequired}),"production"!==process.env.NODE_ENV&&"production"!==process.env.NODE_ENV&&(Hr.propTypes=Ce(Hr.propTypes));var zr=function(){return zr=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},zr.apply(this,arguments)};function Yr(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}function Gr(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,o,i=r.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(e){o={error:e}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s}function Xr(e,t,r){if(r||2===arguments.length)for(var n,o=0,i=t.length;o<i;o++)!n&&o in t||(n||(n=Array.prototype.slice.call(t,0,o)),n[o]=t[o]);return e.concat(n||Array.prototype.slice.call(t))}function Jr(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var qr={mode:"dark",primary:{main:"#FFE804"},secondary:{main:"#FFE804",contrastText:"#1A1A1B"},error:{main:"#FF6187",contrastText:"#FFFFFF"},warning:{main:"#EB8D27",contrastText:"#1A1A1B"},success:{main:"#55F9C7",contrastText:"#1A1A1B"},purple:{main:"#BC9CFF",contrastText:"#1A1A1B"},background:{default:"#252831",paper:"#33363F",paperContrast:"#41454F",backdrop:Vr("#000",.9),input:"#252831",tag:Vr("#FFF",.04)},text:{primary:"#FFF",secondary:Vr("#FFF",.5),disabled:Vr("#FFF",.3),placeholder:Vr("#FFF",.3),link:"#FFE804"},border:{main:Vr("#FFF",.1),light:Vr("#FFF",.3),disabled:Vr("#FFF",.1)},hover:{default:Vr("#FFF",.1)}},Qr={mode:"light",primary:{main:"#1A1A1B"},secondary:{main:"#FFE804",contrastText:"#1A1A1B"},error:{main:"#EC5A7D",contrastText:"#FFFFFF"},warning:{main:"#B15600",contrastText:"#1A1A1B"},success:{main:"#2FBA90",contrastText:"#1A1A1B"},purple:{main:"#6851B4",contrastText:"#1A1A1B"},background:{default:"#F9F6E8",paper:"#FFFFFF",paperContrast:"#F6F6F6",backdrop:Vr("#000",.9),input:"#F0F0F0",tag:Vr("#1A1A1B",.04)},text:{primary:"#1A1A1B",secondary:Vr("#1A1A1B",.5),disabled:Vr("#1A1A1B",.3),placeholder:Vr("#1A1A1B",.3),link:"#1A1A1B"},border:{main:Vr("#1A1A1B",.1),light:Vr("#1A1A1B",.3),disabled:Vr("#1A1A1B",.1)},hover:{default:Vr("#1A1A1B",.1)}},Kr=function(e,t,n){var o,i,s,a="light"===e,l=n?function(e){return["zh-CN","ja-JP","ko-KR"].includes(e)?400:500}(n):400,c=a?Qr:qr;(null===(o=null==t?void 0:t.palette)||void 0===o?void 0:o.mode)===e&&(c=t.palette);var u={spacing:1,shape:{borderRadius:1},breakpoints:{values:{mobile:0,tablet:768,laptop:1024,desktop:1200,largeDesktop:1536}},typography:{fontFamily:Xr(Xr(["Manrope"],Gr("ja-JP"===n?["Meiryo"]:[]),!1),["Poppins","Inter","PingFangSC-Regular",'"Microsoft YaHei"',"sans-serif"],!1).join(","),fontSize:16,h1:{fontSize:36,lineHeight:"49px",fontWeight:600},h2:{fontSize:32,fontWeight:600,lineHeight:"44px"},h3:{fontSize:28,fontWeight:600,lineHeight:"38px"},caption:{fontSize:20,fontWeight:600,lineHeight:"28px"},h5:{fontSize:18,lineHeight:"24px",fontWeight:600},body1:{fontSize:16,lineHeight:"22px",fontWeight:l},body2:{fontSize:14,lineHeight:"19px",fontWeight:l},h6:{fontSize:12,lineHeight:"17px",fontWeight:l},button:{fontSize:16,lineHeight:1,fontWeight:600}},components:{MuiCssBaseline:{styleOverrides:{"::-webkit-scrollbar":{width:6,backgroundColor:"transparent"},"::-webkit-scrollbar-thumb":{backgroundColor:null===(i=c.border)||void 0===i?void 0:i.main,borderColor:null===(s=c.border)||void 0===s?void 0:s.main,borderRadius:100}}},MuiTypography:{defaultProps:{variantMapping:{h1:"h2",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"div",caption:"h5",subtitle1:"h5",subtitle2:"h5",body1:"div",body2:"div"}}}},zIndex:{tooltip:1500}};return zr(zr({},r.merge(u,t)),{palette:c})};var $r=function(e,t){var r;return zr({WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",boxSizing:"border-box",WebkitTextSizeAdjust:"100%"},t&&{colorScheme:null===(r=e.palette)||void 0===r?void 0:r.mode})},en=function(e){var t,r,n;return zr({color:null===(t=e.palette)||void 0===t?void 0:t.text.primary,fontFamily:null===(r=e.typography)||void 0===r?void 0:r.fontFamily},(null===(n=e.typography)||void 0===n?void 0:n.body1)||{})},tn=function(e){var t;return zr(zr({},en(e)),{backgroundColor:null===(t=e.palette)||void 0===t?void 0:t.background.default,"@media print":{backgroundColor:"#FFF"}})};function rn(e){var t=function({props:e,name:t,defaultTheme:r}){return Lr({theme:Cr(r),name:t,props:e})}({props:e,name:"DODOCssBaseline"}),r=t.children,n=t.enableColorScheme,o=void 0!==n&&n,i=t.container;return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(he,{styles:function(e){return function(e,t,r){var n,o,i,s,a,l;void 0===t&&(t=!1);var c={html:$r(e,t),"*, *::before, *::after":{boxSizing:"border-box"},"strong, b":{fontWeight:(null===(i=e.typography)||void 0===i?void 0:i.fontWeightBold)||"bolder"},body:zr(zr({margin:0},tn(e)),{"&::backdrop":{backgroundColor:null===(s=e.palette)||void 0===s?void 0:s.background.default}})};r&&(delete c.html,delete c.body,(n={})[r]=zr(zr({},c),en(e)),c=n);var u=null===(l=null===(a=e.components)||void 0===a?void 0:a.MuiCssBaseline)||void 0===l?void 0:l.styleOverrides;if(u){if(r){var d={};Object.keys(u).forEach((function(e){d["*"+e]=u[e]})),(o={})[r]=d,u=o}c=[c,u]}return c}(e,o,i)}}),r]})}function nn(e){return $e("MuiButton",e)}function on(e,t=[]){if(void 0===e)return{};const r={};return Object.keys(e).filter((r=>r.match(/^on[A-Z]/)&&"function"==typeof e[r]&&!t.includes(r))).forEach((t=>{r[t]=e[t]})),r}function sn(e){return"string"==typeof e}et("MuiButton",["root","active","disabled","focusVisible"]);const an={disableDefaultClasses:!1},ln=S.createContext(an);function cn(e){const{disableDefaultClasses:t}=S.useContext(ln);return r=>t?"":e(r)}function un(e){if(void 0===e)return{};const t={};return Object.keys(e).filter((t=>!(t.match(/^on[A-Z]/)&&"function"==typeof e[t]))).forEach((r=>{t[r]=e[r]})),t}const dn=["elementType","externalSlotProps","ownerState"];function pn(e){var t;const{elementType:r,externalSlotProps:n,ownerState:o}=e,i=ur(e,dn),s=function(e,t){return"function"==typeof e?e(t):e}(n,o),{props:a,internalRef:l}=function(e){const{getSlotProps:t,additionalProps:r,externalSlotProps:n,externalForwardedProps:o,className:i}=e;if(!t){const e=fr(null==o?void 0:o.className,null==n?void 0:n.className,i,null==r?void 0:r.className),t=be({},null==r?void 0:r.style,null==o?void 0:o.style,null==n?void 0:n.style),s=be({},r,o,n);return e.length>0&&(s.className=e),Object.keys(t).length>0&&(s.style=t),{props:s,internalRef:void 0}}const s=on(be({},o,n)),a=un(n),l=un(o),c=t(s),u=fr(null==c?void 0:c.className,null==r?void 0:r.className,i,null==o?void 0:o.className,null==n?void 0:n.className),d=be({},null==c?void 0:c.style,null==r?void 0:r.style,null==o?void 0:o.style,null==n?void 0:n.style),p=be({},c,r,l,a);return u.length>0&&(p.className=u),Object.keys(d).length>0&&(p.style=d),{props:p,internalRef:c.ref}}(be({},i,{externalSlotProps:s})),c=function(e,t,r){return void 0===e||sn(e)?t:be({},t,{ownerState:be({},t.ownerState,r)})}(r,be({},a,{ref:De(l,null==s?void 0:s.ref,null==(t=e.additionalProps)?void 0:t.ref)}),o);return c}const fn=["action","children","disabled","focusableWhenDisabled","onFocusVisible","slotProps","slots"],hn=S.forwardRef((function(e,t){var r;const{action:n,children:o,focusableWhenDisabled:i=!1,slotProps:s={},slots:a={}}=e,l=ur(e,fn),c=S.useRef(),{active:u,focusVisible:d,setFocusVisible:p,getRootProps:f}=function(e={}){const{disabled:t=!1,focusableWhenDisabled:r,href:n,rootRef:o,tabIndex:i,to:s,type:a}=e,l=S.useRef(),[c,u]=S.useState(!1),{isFocusVisibleRef:d,onFocus:p,onBlur:f,ref:h}=Ge(),[m,g]=S.useState(!1);t&&!r&&m&&g(!1),S.useEffect((()=>{d.current=m}),[m,d]);const[y,b]=S.useState(""),v=e=>t=>{var r;m&&t.preventDefault(),null==(r=e.onMouseLeave)||r.call(e,t)},x=e=>t=>{var r;f(t),!1===d.current&&g(!1),null==(r=e.onBlur)||r.call(e,t)},w=e=>t=>{var r,n;l.current||(l.current=t.currentTarget),p(t),!0===d.current&&(g(!0),null==(n=e.onFocusVisible)||n.call(e,t)),null==(r=e.onFocus)||r.call(e,t)},E=()=>{const e=l.current;return"BUTTON"===y||"INPUT"===y&&["button","submit","reset"].includes(null==e?void 0:e.type)||"A"===y&&(null==e?void 0:e.href)},A=e=>r=>{var n;t||null==(n=e.onClick)||n.call(e,r)},k=e=>r=>{var n;t||(u(!0),document.addEventListener("mouseup",(()=>{u(!1)}),{once:!0})),null==(n=e.onMouseDown)||n.call(e,r)},C=e=>r=>{var n,o;null==(n=e.onKeyDown)||n.call(e,r),r.defaultMuiPrevented||(r.target!==r.currentTarget||E()||" "!==r.key||r.preventDefault(),r.target!==r.currentTarget||" "!==r.key||t||u(!0),r.target!==r.currentTarget||E()||"Enter"!==r.key||t||(null==(o=e.onClick)||o.call(e,r),r.preventDefault()))},R=e=>r=>{var n,o;r.target===r.currentTarget&&u(!1),null==(n=e.onKeyUp)||n.call(e,r),r.target!==r.currentTarget||E()||t||" "!==r.key||r.defaultMuiPrevented||null==(o=e.onClick)||o.call(e,r)},T=De(S.useCallback((e=>{var t;b(null!=(t=null==e?void 0:e.tagName)?t:"")}),[]),o,h,l),N={};return"BUTTON"===y?(N.type=null!=a?a:"button",r?N["aria-disabled"]=t:N.disabled=t):""!==y&&(n||s||(N.role="button",N.tabIndex=null!=i?i:0),t&&(N["aria-disabled"]=t,N.tabIndex=r?null!=i?i:0:-1)),{getRootProps:(t={})=>{const r=be({},on(e),t);return delete r.onFocusVisible,be({type:a},r,N,{onBlur:x(r),onClick:A(r),onFocus:w(r),onKeyDown:C(r),onKeyUp:R(r),onMouseDown:k(r),onMouseLeave:v(r),ref:T})},focusVisible:m,setFocusVisible:g,active:c,rootRef:T}}(be({},e,{focusableWhenDisabled:i}));S.useImperativeHandle(n,(()=>({focusVisible:()=>{p(!0),c.current.focus()}})),[p]);const h=be({},e,{active:u,focusableWhenDisabled:i,focusVisible:d}),m=(e=>{const{active:t,disabled:r,focusVisible:n}=e;return Je({root:["root",r&&"disabled",n&&"focusVisible",t&&"active"]},cn(nn))})(h),g=l.href||l.to?"a":"button",y=null!=(r=a.root)?r:g,b=pn({elementType:y,getSlotProps:f,externalForwardedProps:l,externalSlotProps:s.root,additionalProps:{ref:t},ownerState:h,className:m.root});return ne.exports.jsx(y,be({},b,{children:o}))}));"production"!==process.env.NODE_ENV&&(hn.propTypes={action:F.exports.oneOfType([F.exports.func,F.exports.shape({current:F.exports.shape({focusVisible:F.exports.func.isRequired})})]),children:F.exports.node,disabled:F.exports.bool,focusableWhenDisabled:F.exports.bool,href:F.exports.string,onFocusVisible:F.exports.func,slotProps:F.exports.shape({root:F.exports.oneOfType([F.exports.func,F.exports.object])}),slots:F.exports.shape({root:F.exports.elementType}),to:F.exports.string});var mn,gn,yn=hn;!function(e){e.contained="contained",e.outlined="outlined",e.dashed="dashed",e.second="second",e.tag="tag"}(mn||(mn={})),function(e){e.small="small",e.middle="middle",e.big="big"}(gn||(gn={}));var bn=function(e,t){var n,o,i,s,a,l=e.fullWidth,c=e.variant,u=e.sx,d=e.danger,p={px:16,py:10,typography:"button",whiteSpace:"nowrap",fontFamily:"inherit",display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},"&[disabled]":{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}};switch(e.size){case gn.small:p.height=36,p.borderRadius=8,p.typography="body2";break;case gn.big:p.height=60,p.borderRadius=16;break;default:p.height=48,p.borderRadius=8}l&&(p.display="flex",p.width="100%");var f="&:not([disabled]):hover";switch(c){case mn.outlined:p=zr(zr({},p),((n={border:"solid 1px ".concat(d?t.palette.error.main:t.palette.primary.main),color:d?"error.main":"primary.main","&[disabled]":{color:"text.disabled",borderColor:"border.disabled"}})[f]={background:Vr(d?t.palette.error.main:t.palette.primary.main,.1)},n));break;case mn.dashed:p=zr(zr({},p),((o={height:p.height-1,border:"dashed 1px ".concat(d?t.palette.error.main:t.palette.border.light),color:d?"error.main":"primary.main","&[disabled]":{backgroundColor:"border.disabled",color:"text.disabled"}})[f]={background:Vr(d?t.palette.error.main:t.palette.border.disabled,.1)},o));break;case mn.second:p=zr(zr({},p),((i={backgroundColor:d?"error.main":t.palette.background.tag,border:"none",color:d?"error.contrastText":"text.primary","&[disabled]":{backgroundColor:"border.disabled",color:"text.disabled"}})[f]={background:d?Vr(t.palette.error.main,.1):Vr(t.palette.border.disabled,.2)},i));break;case mn.tag:p=zr(zr({},p),((s={px:10,py:3,height:"auto",borderRadius:4,typography:"body2",backgroundColor:d?"error.main":"background.tag",border:"none",color:d?"error.contrastText":"primary.main","&[disabled]":{backgroundColor:"border.disabled",color:"text.disabled"}})[f]={background:d?Vr(t.palette.error.main,.1):Vr(t.palette.border.disabled,.2)},s));break;default:p=zr(zr({},p),((a={backgroundColor:d?"error.main":"secondary.main"})[f]={background:"linear-gradient(0deg, rgba(26, 26, 27, 0.1), rgba(26, 26, 27, 0.1)), ".concat(d?t.palette.error.main:(null==u?void 0:u.backgroundColor)||t.palette.secondary.main)},a.color=d?"error.contrastText":"secondary.contrastText",a["&[disabled]"]={backgroundColor:"border.disabled",color:"text.disabled"},a))}return r.merge(p,u)},vn=function(e){var t=e.onClick,r=e.disabled,n=e.children,o=e.component,s=e.to,a=e.isLoading,l=e.fullWidth,c=e.variant,u=e.sx,d=e.danger,p=e.size;e.ref;var f=Yr(e,["onClick","disabled","children","component","to","isLoading","fullWidth","variant","sx","danger","size","ref"]),h=Cr(),m={disabled:r,sx:bn({fullWidth:l,variant:c,sx:u,danger:d,size:p},h),onClick:t,component:o,to:s};return ne.exports.jsx(Tr,zr({},m,f,{component:yn,disabled:!!a||r,className:c||mn.contained},{children:ne.exports.jsxs(ne.exports.Fragment,{children:[a&&ne.exports.jsx(Tr,{component:i.Loading,sx:{mr:8,"& path":{fill:h.palette.text.disabled},animation:"loadingRotate 1.1s infinite linear","@keyframes loadingRotate":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(359deg)"}}}}),n]})}))};vn.Variant=mn,vn.Size=gn;var xn,wn=Dr(yn)(xn||(xn=Jr(["\n margin: 0;\n border: none;\n padding: 0;\n cursor: pointer;\n background: none;\n font-family: inherit;\n &:focus {\n outline: none;\n }\n &:active {\n outline: none;\n }\n"],["\n margin: 0;\n border: none;\n padding: 0;\n cursor: pointer;\n background: none;\n font-family: inherit;\n &:focus {\n outline: none;\n }\n &:active {\n outline: none;\n }\n"])));function En(e){return $e("MuiInput",e)}var An=et("MuiInput",["root","formControl","focused","disabled","error","multiline","input","inputMultiline","inputTypeSearch","adornedStart","adornedEnd"]);const kn=S.createContext(void 0);"production"!==process.env.NODE_ENV&&(kn.displayName="FormControlContext");var Cn=kn;function Rn(e){const{defaultValue:t,disabled:r=!1,error:n=!1,onBlur:o,onChange:i,onFocus:s,required:a=!1,value:l,inputRef:c}=e,u=S.useContext(Cn);let d,p,f,h,m;var g,y,b;if(u){if(d=void 0,p=null!=(g=u.disabled)&&g,f=null!=(y=u.error)&&y,h=null!=(b=u.required)&&b,m=u.value,"production"!==process.env.NODE_ENV){const t=["defaultValue","disabled","error","required","value"].filter((t=>void 0!==e[t]));t.length>0&&console.warn(["MUI: You have set props on an input that is inside a FormControl.","Set these props on a FormControl instead. Otherwise they will be ignored.",`Ignored props: ${t.join(", ")}`].join("\n"))}}else d=t,p=r,f=n,h=a,m=l;const{current:v}=S.useRef(null!=m),x=S.useCallback((e=>{"production"!==process.env.NODE_ENV&&e&&"INPUT"!==e.nodeName&&!e.focus&&console.error(["MUI: You have provided a `slots.input` to the input component","that does not correctly handle the `ref` prop.","Make sure the `ref` prop is called with a HTMLInputElement."].join("\n"))}),[]),w=S.useRef(null),E=De(w,c,x),[A,k]=S.useState(!1);S.useEffect((()=>{!u&&p&&A&&(k(!1),null==o||o())}),[u,p,A,o]);const C=e=>t=>{var r,n;null!=u&&u.disabled?t.stopPropagation():(null==(r=e.onFocus)||r.call(e,t),u&&u.onFocus?null==u||null==(n=u.onFocus)||n.call(u):k(!0))},R=e=>(t,...r)=>{var n,o;if(!v&&null==(t.target||w.current))throw new Error("production"!==process.env.NODE_ENV?"MUI: Expected valid input target. Did you use a custom `slots.input` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info.":Re(17));null==u||null==(n=u.onChange)||n.call(u,t),null==(o=e.onChange)||o.call(e,t,...r)};return{disabled:p,error:f,focused:A,formControlContext:u,getInputProps:(e={})=>{const t=be({},{onBlur:o,onChange:i,onFocus:s},on(e)),r=be({},e,t,{onBlur:(n=t,e=>{var t;null==(t=n.onBlur)||t.call(n,e),u&&u.onBlur?u.onBlur():k(!1)}),onChange:R(t),onFocus:C(t)});var n;return be({},r,{"aria-invalid":f||void 0,defaultValue:d,ref:E,value:m,required:h,disabled:p})},getRootProps:(t={})=>{const r=be({},on(e,["onBlur","onChange","onFocus"]),on(t));return be({},t,r,{onClick:(n=r,e=>{var t;w.current&&e.currentTarget===e.target&&w.current.focus(),null==(t=n.onClick)||t.call(n,e)})});var n},inputRef:E,required:h,value:m}}const Sn=["aria-describedby","aria-label","aria-labelledby","autoComplete","autoFocus","className","defaultValue","disabled","endAdornment","error","id","multiline","name","onClick","onChange","onKeyDown","onKeyUp","onFocus","onBlur","placeholder","readOnly","required","startAdornment","value","type","rows","slotProps","slots","minRows","maxRows"],Tn=S.forwardRef((function(e,t){var r,n,o;const{"aria-describedby":i,"aria-label":s,"aria-labelledby":a,autoComplete:l,autoFocus:c,className:u,defaultValue:d,disabled:p,endAdornment:f,error:h,id:m,multiline:g=!1,name:y,onClick:b,onChange:v,onKeyDown:x,onKeyUp:w,onFocus:E,onBlur:A,placeholder:k,readOnly:C,required:R,startAdornment:S,value:T,type:N,rows:M,slotProps:O={},slots:I={},minRows:j,maxRows:F}=e,_=ur(e,Sn),{getRootProps:P,getInputProps:B,focused:W,formControlContext:D,error:L,disabled:U}=Rn({disabled:p,defaultValue:d,error:h,onBlur:A,onClick:b,onChange:v,onFocus:E,required:R,value:T}),V=g?void 0:null!=N?N:"text",Z=be({},e,{disabled:U,error:L,focused:W,formControlContext:D,multiline:g,type:V}),H=(e=>{const{disabled:t,error:r,focused:n,formControlContext:o,multiline:i,startAdornment:s,endAdornment:a}=e;return Je({root:["root",t&&"disabled",r&&"error",n&&"focused",Boolean(o)&&"formControl",i&&"multiline",Boolean(s)&&"adornedStart",Boolean(a)&&"adornedEnd"],input:["input",t&&"disabled",i&&"multiline"]},cn(En))})(Z),z={"aria-describedby":i,"aria-label":s,"aria-labelledby":a,autoComplete:l,autoFocus:c,id:m,onKeyDown:x,onKeyUp:w,name:y,placeholder:k,readOnly:C,type:V},Y=null!=(r=I.root)?r:"div",G=pn({elementType:Y,getSlotProps:P,externalSlotProps:O.root,externalForwardedProps:_,additionalProps:{ref:t},ownerState:Z,className:[H.root,u]}),X=g?null!=(n=I.textarea)?n:"textarea":null!=(o=I.input)?o:"input",J=pn({elementType:X,getSlotProps:e=>B(be({},z,e)),externalSlotProps:O.input,additionalProps:be({rows:g?M:void 0},g&&!sn(X)&&{minRows:M||j,maxRows:M||F}),ownerState:Z,className:H.input});return"production"!==process.env.NODE_ENV&&g&&M&&(j||F)&&console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."),ne.exports.jsxs(Y,be({},G,{children:[S,ne.exports.jsx(X,be({},J)),f]}))}));"production"!==process.env.NODE_ENV&&(Tn.propTypes={"aria-describedby":F.exports.string,"aria-label":F.exports.string,"aria-labelledby":F.exports.string,autoComplete:F.exports.string,autoFocus:F.exports.bool,className:F.exports.string,defaultValue:F.exports.any,disabled:F.exports.bool,endAdornment:F.exports.node,error:F.exports.bool,id:F.exports.string,inputRef:F.exports.oneOfType([F.exports.func,F.exports.shape({current:F.exports.object})]),maxRows:F.exports.number,minRows:F.exports.number,multiline:F.exports.bool,name:F.exports.string,onBlur:F.exports.func,onChange:F.exports.func,onClick:F.exports.func,onFocus:F.exports.func,onKeyDown:F.exports.func,onKeyUp:F.exports.func,placeholder:F.exports.string,readOnly:F.exports.bool,required:F.exports.bool,rows:F.exports.number,slotProps:F.exports.shape({input:F.exports.oneOfType([F.exports.func,F.exports.object]),root:F.exports.oneOfType([F.exports.func,F.exports.object])}),slots:F.exports.shape({input:F.exports.elementType,root:F.exports.elementType,textarea:F.exports.elementType}),startAdornment:F.exports.node,type:F.exports.oneOf(["button","checkbox","color","date","datetime-local","email","file","hidden","image","month","number","password","radio","range","reset","search","submit","tel","text","time","url","week"]),value:F.exports.any});var Nn=Tn;function Mn(e){var t,n,o=e.fullWidth,i=e.height,s=e.suffixGap,a=e.error,l=e.sx,c=Yr(e,["fullWidth","height","suffixGap","error","sx"]);return ne.exports.jsx(Tr,zr({component:"div",sx:r.merge(zr(zr(zr((t={position:"relative",display:o?"flex":"inline-flex",alignItems:"center",border:"1px solid",borderColor:a?"error.main":"border.main",borderRadius:8,backgroundColor:"background.input"},t["&.".concat(An.disabled)]={color:"text.disabled",cursor:"default"},t.height=i,t),o&&{width:"100%"}),{"& > *:not(input):not(.MuiSelect-select):first-of-type":{ml:s,whiteSpace:"nowrap"},"& > *:not(input):last-child":{mr:s,whiteSpace:"nowrap"}}),a?{}:(n={},n["&.".concat(An.focused)]={borderColor:"text.secondary"},n)),l)},c))}var On=Dr(Tr)((function(e){var t=e.theme,r="{\n color: ".concat(t.palette.text.placeholder,";\n font-size: 14px;\n font-weight: 500;\n opacity: 1;\n }");return"\n font: inherit;\n font-size: 16px;\n font-weight: 600;\n line-height: 19px;\n padding: ".concat(t.spacing(14,16),";\n &::-webkit-outer-spin-button {\n -webkit-appearance: none;\n }\n &::-webkit-inner-spin-button {\n -webkit-appearance: none;\n }\n height: 100%;\n width: 100%;\n border: none;\n color: ").concat(t.palette.text.primary,";\n background-color: transparent;\n &::-webkit-input-placeholder ").concat(r,";\n &::-moz-placeholder ").concat(r,";\n &:-ms-input-placeholder ").concat(r,";\n &::-ms-input-placeholder ").concat(r,";\n &:focus {\n outline: 0;\n }\n &:invalid {\n box-shadow: none;\n }\n &::-webkit-search-decoration {\n -webkit-appearance: none;\n }\n &.").concat(An.disabled," {\n opacity: 1;\n -webkit-text-fill-color: ").concat(t.palette.text.disabled,";\n }\n ")})),In=n.forwardRef((function(e,t){var r=e.fullWidth,o=e.error,i=e.errorMsg,s=e.sx,a=e.suffix,l=e.prefix,c=e.height,u=e.suffixGap,d=void 0===u?16:u,p=e.dataTestId,f=e.inputSx,h=Yr(e,["fullWidth","error","errorMsg","sx","suffix","prefix","height","suffixGap","dataTestId","inputSx"]),m=n.useCallback((function(e){return ne.exports.jsx(Mn,zr({fullWidth:r,height:c,suffixGap:d,error:o,sx:s,"data-testid":p},e))}),[r,c,d,o,p,JSON.stringify(s)]);return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Nn,zr({slots:{root:m,input:On},startAdornment:l,endAdornment:a,slotProps:{input:{component:"input",sx:f}}},h,{ref:t})),i?ne.exports.jsx(Tr,zr({sx:{typography:"body2",color:"error.main",mt:6}},{children:i})):""]})})),jn=n.forwardRef((function(e,t){var n=e.weak,o=e.color,i=e.sx,s=Yr(e,["weak","color","sx"]),a=n?"text.primary":"text.secondary",l=n?"text.secondary":"text.primary";return o&&(a=o,l=o),ne.exports.jsx(Tr,zr({ref:t,sx:r.merge(zr({color:a,opacity:o&&!n?.5:1},{"&:hover":{color:l,opacity:o&&n?.5:1}}),i)},s))}));function Fn(e){var t=e.clearValue,n=e.hideSearchIcon,o=e.height,s=void 0===o?48:o,a=e.inputSx,l=Yr(e,["clearValue","hideSearchIcon","height","inputSx"]),c=Cr(),u=l.value;return ne.exports.jsx(In,zr({prefix:n?null:ne.exports.jsx(i.Search,{style:{width:24,minWidth:24,height:24,color:c.palette.text.placeholder}}),suffix:u&&t?ne.exports.jsx(jn,zr({sx:{width:24,minWidth:24,height:24,mr:12,display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"50%",backgroundColor:"background.tag",cursor:"pointer"},onClick:t},{children:ne.exports.jsx(Tr,{component:i.Error,sx:{width:14,height:14}})})):null},l,{inputSx:r.merge({pl:4},a),height:s}))}var _n=function(e){var t=e.sx,r=Cr();return ne.exports.jsx(Tr,{sx:zr({width:20,color:r.palette.primary.main,animation:"spin 3s linear infinite","@keyframes spin":{"100%":{transform:"rotate(360deg)"}}},t),component:i.Loading})};function Pn(e){return e.substring(2).toLowerCase()}function Bn(e){const{children:t,disableReactTree:r=!1,mouseEvent:n="onClick",onClickAway:o,touchEvent:i="onTouchEnd"}=e,s=S.useRef(!1),a=S.useRef(null),l=S.useRef(!1),c=S.useRef(!1);S.useEffect((()=>(setTimeout((()=>{l.current=!0}),0),()=>{l.current=!1})),[]);const u=De(t.ref,a),d=We((e=>{const t=c.current;c.current=!1;const n=Fe(a.current);if(!l.current||!a.current||"clientX"in e&&function(e,t){return t.documentElement.clientWidth<e.clientX||t.documentElement.clientHeight<e.clientY}(e,n))return;if(s.current)return void(s.current=!1);let i;i=e.composedPath?e.composedPath().indexOf(a.current)>-1:!n.documentElement.contains(e.target)||a.current.contains(e.target),i||!r&&t||o(e)})),p=e=>r=>{c.current=!0;const n=t.props[e];n&&n(r)},f={ref:u};return!1!==i&&(f[i]=p(i)),S.useEffect((()=>{if(!1!==i){const e=Pn(i),t=Fe(a.current),r=()=>{s.current=!0};return t.addEventListener(e,d),t.addEventListener("touchmove",r),()=>{t.removeEventListener(e,d),t.removeEventListener("touchmove",r)}}}),[d,i]),!1!==n&&(f[n]=p(n)),S.useEffect((()=>{if(!1!==n){const e=Pn(n),t=Fe(a.current);return t.addEventListener(e,d),()=>{t.removeEventListener(e,d)}}}),[d,n]),ne.exports.jsx(S.Fragment,{children:S.cloneElement(t,f)})}"production"!==process.env.NODE_ENV&&(Bn.propTypes={children:ke.isRequired,disableReactTree:F.exports.bool,mouseEvent:F.exports.oneOf(["onClick","onMouseDown","onMouseUp","onPointerDown","onPointerUp",!1]),onClickAway:F.exports.func.isRequired,touchEvent:F.exports.oneOf(["onTouchEnd","onTouchStart",!1])}),"production"!==process.env.NODE_ENV&&(Bn.propTypes=Ce(Bn.propTypes));var Wn="top",Dn="bottom",Ln="right",Un="left",Vn=[Wn,Dn,Ln,Un],Zn=Vn.reduce((function(e,t){return e.concat([t+"-start",t+"-end"])}),[]),Hn=[].concat(Vn,["auto"]).reduce((function(e,t){return e.concat([t,t+"-start",t+"-end"])}),[]),zn=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function Yn(e){return e?(e.nodeName||"").toLowerCase():null}function Gn(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Xn(e){return e instanceof Gn(e).Element||e instanceof Element}function Jn(e){return e instanceof Gn(e).HTMLElement||e instanceof HTMLElement}function qn(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Gn(e).ShadowRoot||e instanceof ShadowRoot)}var Qn={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var r=t.styles[e]||{},n=t.attributes[e]||{},o=t.elements[e];Jn(o)&&Yn(o)&&(Object.assign(o.style,r),Object.keys(n).forEach((function(e){var t=n[e];!1===t?o.removeAttribute(e):o.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach((function(e){var n=t.elements[e],o=t.attributes[e]||{},i=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:r[e]).reduce((function(e,t){return e[t]="",e}),{});Jn(n)&&Yn(n)&&(Object.assign(n.style,i),Object.keys(o).forEach((function(e){n.removeAttribute(e)})))}))}},requires:["computeStyles"]};function Kn(e){return e.split("-")[0]}var $n=Math.max,eo=Math.min,to=Math.round;function ro(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function no(){return!/^((?!chrome|android).)*safari/i.test(ro())}function oo(e,t,r){void 0===t&&(t=!1),void 0===r&&(r=!1);var n=e.getBoundingClientRect(),o=1,i=1;t&&Jn(e)&&(o=e.offsetWidth>0&&to(n.width)/e.offsetWidth||1,i=e.offsetHeight>0&&to(n.height)/e.offsetHeight||1);var s=(Xn(e)?Gn(e):window).visualViewport,a=!no()&&r,l=(n.left+(a&&s?s.offsetLeft:0))/o,c=(n.top+(a&&s?s.offsetTop:0))/i,u=n.width/o,d=n.height/i;return{width:u,height:d,top:c,right:l+u,bottom:c+d,left:l,x:l,y:c}}function io(e){var t=oo(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function so(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&qn(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function ao(e){return Gn(e).getComputedStyle(e)}function lo(e){return["table","td","th"].indexOf(Yn(e))>=0}function co(e){return((Xn(e)?e.ownerDocument:e.document)||window.document).documentElement}function uo(e){return"html"===Yn(e)?e:e.assignedSlot||e.parentNode||(qn(e)?e.host:null)||co(e)}function po(e){return Jn(e)&&"fixed"!==ao(e).position?e.offsetParent:null}function fo(e){for(var t=Gn(e),r=po(e);r&&lo(r)&&"static"===ao(r).position;)r=po(r);return r&&("html"===Yn(r)||"body"===Yn(r)&&"static"===ao(r).position)?t:r||function(e){var t=/firefox/i.test(ro());if(/Trident/i.test(ro())&&Jn(e)&&"fixed"===ao(e).position)return null;var r=uo(e);for(qn(r)&&(r=r.host);Jn(r)&&["html","body"].indexOf(Yn(r))<0;){var n=ao(r);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return r;r=r.parentNode}return null}(e)||t}function ho(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function mo(e,t,r){return $n(e,eo(t,r))}function go(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function yo(e,t){return t.reduce((function(t,r){return t[r]=e,t}),{})}var bo={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,r=e.state,n=e.name,o=e.options,i=r.elements.arrow,s=r.modifiersData.popperOffsets,a=Kn(r.placement),l=ho(a),c=[Un,Ln].indexOf(a)>=0?"height":"width";if(i&&s){var u=function(e,t){return go("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:yo(e,Vn))}(o.padding,r),d=io(i),p="y"===l?Wn:Un,f="y"===l?Dn:Ln,h=r.rects.reference[c]+r.rects.reference[l]-s[l]-r.rects.popper[c],m=s[l]-r.rects.reference[l],g=fo(i),y=g?"y"===l?g.clientHeight||0:g.clientWidth||0:0,b=h/2-m/2,v=u[p],x=y-d[c]-u[f],w=y/2-d[c]/2+b,E=mo(v,w,x),A=l;r.modifiersData[n]=((t={})[A]=E,t.centerOffset=E-w,t)}},effect:function(e){var t=e.state,r=e.options.element,n=void 0===r?"[data-popper-arrow]":r;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&so(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function vo(e){return e.split("-")[1]}var xo={top:"auto",right:"auto",bottom:"auto",left:"auto"};function wo(e){var t,r=e.popper,n=e.popperRect,o=e.placement,i=e.variation,s=e.offsets,a=e.position,l=e.gpuAcceleration,c=e.adaptive,u=e.roundOffsets,d=e.isFixed,p=s.x,f=void 0===p?0:p,h=s.y,m=void 0===h?0:h,g="function"==typeof u?u({x:f,y:m}):{x:f,y:m};f=g.x,m=g.y;var y=s.hasOwnProperty("x"),b=s.hasOwnProperty("y"),v=Un,x=Wn,w=window;if(c){var E=fo(r),A="clientHeight",k="clientWidth";E===Gn(r)&&"static"!==ao(E=co(r)).position&&"absolute"===a&&(A="scrollHeight",k="scrollWidth"),(o===Wn||(o===Un||o===Ln)&&"end"===i)&&(x=Dn,m-=(d&&E===w&&w.visualViewport?w.visualViewport.height:E[A])-n.height,m*=l?1:-1),o!==Un&&(o!==Wn&&o!==Dn||"end"!==i)||(v=Ln,f-=(d&&E===w&&w.visualViewport?w.visualViewport.width:E[k])-n.width,f*=l?1:-1)}var C,R=Object.assign({position:a},c&&xo),S=!0===u?function(e,t){var r=e.x,n=e.y,o=t.devicePixelRatio||1;return{x:to(r*o)/o||0,y:to(n*o)/o||0}}({x:f,y:m},Gn(r)):{x:f,y:m};return f=S.x,m=S.y,l?Object.assign({},R,((C={})[x]=b?"0":"",C[v]=y?"0":"",C.transform=(w.devicePixelRatio||1)<=1?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",C)):Object.assign({},R,((t={})[x]=b?m+"px":"",t[v]=y?f+"px":"",t.transform="",t))}var Eo={passive:!0},Ao={left:"right",right:"left",bottom:"top",top:"bottom"};function ko(e){return e.replace(/left|right|bottom|top/g,(function(e){return Ao[e]}))}var Co={start:"end",end:"start"};function Ro(e){return e.replace(/start|end/g,(function(e){return Co[e]}))}function So(e){var t=Gn(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function To(e){return oo(co(e)).left+So(e).scrollLeft}function No(e){var t=ao(e),r=t.overflow,n=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+o+n)}function Mo(e){return["html","body","#document"].indexOf(Yn(e))>=0?e.ownerDocument.body:Jn(e)&&No(e)?e:Mo(uo(e))}function Oo(e,t){var r;void 0===t&&(t=[]);var n=Mo(e),o=n===(null==(r=e.ownerDocument)?void 0:r.body),i=Gn(n),s=o?[i].concat(i.visualViewport||[],No(n)?n:[]):n,a=t.concat(s);return o?a:a.concat(Oo(uo(s)))}function Io(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function jo(e,t,r){return"viewport"===t?Io(function(e,t){var r=Gn(e),n=co(e),o=r.visualViewport,i=n.clientWidth,s=n.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;var c=no();(c||!c&&"fixed"===t)&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a+To(e),y:l}}(e,r)):Xn(t)?function(e,t){var r=oo(e,!1,"fixed"===t);return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}(t,r):Io(function(e){var t,r=co(e),n=So(e),o=null==(t=e.ownerDocument)?void 0:t.body,i=$n(r.scrollWidth,r.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=$n(r.scrollHeight,r.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),a=-n.scrollLeft+To(e),l=-n.scrollTop;return"rtl"===ao(o||r).direction&&(a+=$n(r.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:l}}(co(e)))}function Fo(e){var t,r=e.reference,n=e.element,o=e.placement,i=o?Kn(o):null,s=o?vo(o):null,a=r.x+r.width/2-n.width/2,l=r.y+r.height/2-n.height/2;switch(i){case Wn:t={x:a,y:r.y-n.height};break;case Dn:t={x:a,y:r.y+r.height};break;case Ln:t={x:r.x+r.width,y:l};break;case Un:t={x:r.x-n.width,y:l};break;default:t={x:r.x,y:r.y}}var c=i?ho(i):null;if(null!=c){var u="y"===c?"height":"width";switch(s){case"start":t[c]=t[c]-(r[u]/2-n[u]/2);break;case"end":t[c]=t[c]+(r[u]/2-n[u]/2)}}return t}function _o(e,t){void 0===t&&(t={});var r=t,n=r.placement,o=void 0===n?e.placement:n,i=r.strategy,s=void 0===i?e.strategy:i,a=r.boundary,l=void 0===a?"clippingParents":a,c=r.rootBoundary,u=void 0===c?"viewport":c,d=r.elementContext,p=void 0===d?"popper":d,f=r.altBoundary,h=void 0!==f&&f,m=r.padding,g=void 0===m?0:m,y=go("number"!=typeof g?g:yo(g,Vn)),b="popper"===p?"reference":"popper",v=e.rects.popper,x=e.elements[h?b:p],w=function(e,t,r,n){var o="clippingParents"===t?function(e){var t=Oo(uo(e)),r=["absolute","fixed"].indexOf(ao(e).position)>=0&&Jn(e)?fo(e):e;return Xn(r)?t.filter((function(e){return Xn(e)&&so(e,r)&&"body"!==Yn(e)})):[]}(e):[].concat(t),i=[].concat(o,[r]),s=i[0],a=i.reduce((function(t,r){var o=jo(e,r,n);return t.top=$n(o.top,t.top),t.right=eo(o.right,t.right),t.bottom=eo(o.bottom,t.bottom),t.left=$n(o.left,t.left),t}),jo(e,s,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}(Xn(x)?x:x.contextElement||co(e.elements.popper),l,u,s),E=oo(e.elements.reference),A=Fo({reference:E,element:v,strategy:"absolute",placement:o}),k=Io(Object.assign({},v,A)),C="popper"===p?k:E,R={top:w.top-C.top+y.top,bottom:C.bottom-w.bottom+y.bottom,left:w.left-C.left+y.left,right:C.right-w.right+y.right},S=e.modifiersData.offset;if("popper"===p&&S){var T=S[o];Object.keys(R).forEach((function(e){var t=[Ln,Dn].indexOf(e)>=0?1:-1,r=[Wn,Dn].indexOf(e)>=0?"y":"x";R[e]+=T[r]*t}))}return R}var Po={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var o=r.mainAxis,i=void 0===o||o,s=r.altAxis,a=void 0===s||s,l=r.fallbackPlacements,c=r.padding,u=r.boundary,d=r.rootBoundary,p=r.altBoundary,f=r.flipVariations,h=void 0===f||f,m=r.allowedAutoPlacements,g=t.options.placement,y=Kn(g),b=l||(y!==g&&h?function(e){if("auto"===Kn(e))return[];var t=ko(e);return[Ro(e),t,Ro(t)]}(g):[ko(g)]),v=[g].concat(b).reduce((function(e,r){return e.concat("auto"===Kn(r)?function(e,t){void 0===t&&(t={});var r=t,n=r.placement,o=r.boundary,i=r.rootBoundary,s=r.padding,a=r.flipVariations,l=r.allowedAutoPlacements,c=void 0===l?Hn:l,u=vo(n),d=u?a?Zn:Zn.filter((function(e){return vo(e)===u})):Vn,p=d.filter((function(e){return c.indexOf(e)>=0}));0===p.length&&(p=d);var f=p.reduce((function(t,r){return t[r]=_o(e,{placement:r,boundary:o,rootBoundary:i,padding:s})[Kn(r)],t}),{});return Object.keys(f).sort((function(e,t){return f[e]-f[t]}))}(t,{placement:r,boundary:u,rootBoundary:d,padding:c,flipVariations:h,allowedAutoPlacements:m}):r)}),[]),x=t.rects.reference,w=t.rects.popper,E=new Map,A=!0,k=v[0],C=0;C<v.length;C++){var R=v[C],S=Kn(R),T="start"===vo(R),N=[Wn,Dn].indexOf(S)>=0,M=N?"width":"height",O=_o(t,{placement:R,boundary:u,rootBoundary:d,altBoundary:p,padding:c}),I=N?T?Ln:Un:T?Dn:Wn;x[M]>w[M]&&(I=ko(I));var j=ko(I),F=[];if(i&&F.push(O[S]<=0),a&&F.push(O[I]<=0,O[j]<=0),F.every((function(e){return e}))){k=R,A=!1;break}E.set(R,F)}if(A)for(var _=function(e){var t=v.find((function(t){var r=E.get(t);if(r)return r.slice(0,e).every((function(e){return e}))}));if(t)return k=t,"break"},P=h?3:1;P>0&&"break"!==_(P);P--);t.placement!==k&&(t.modifiersData[n]._skip=!0,t.placement=k,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function Bo(e,t,r){return void 0===r&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function Wo(e){return[Wn,Ln,Dn,Un].some((function(t){return e[t]>=0}))}var Do={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,r=e.options,n=e.name,o=r.offset,i=void 0===o?[0,0]:o,s=Hn.reduce((function(e,r){return e[r]=function(e,t,r){var n=Kn(e),o=[Un,Wn].indexOf(n)>=0?-1:1,i="function"==typeof r?r(Object.assign({},t,{placement:e})):r,s=i[0],a=i[1];return s=s||0,a=(a||0)*o,[Un,Ln].indexOf(n)>=0?{x:a,y:s}:{x:s,y:a}}(r,t.rects,i),e}),{}),a=s[t.placement],l=a.x,c=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[n]=s}},Lo={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name,o=r.mainAxis,i=void 0===o||o,s=r.altAxis,a=void 0!==s&&s,l=r.boundary,c=r.rootBoundary,u=r.altBoundary,d=r.padding,p=r.tether,f=void 0===p||p,h=r.tetherOffset,m=void 0===h?0:h,g=_o(t,{boundary:l,rootBoundary:c,padding:d,altBoundary:u}),y=Kn(t.placement),b=vo(t.placement),v=!b,x=ho(y),w="x"===x?"y":"x",E=t.modifiersData.popperOffsets,A=t.rects.reference,k=t.rects.popper,C="function"==typeof m?m(Object.assign({},t.rects,{placement:t.placement})):m,R="number"==typeof C?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),S=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,T={x:0,y:0};if(E){if(i){var N,M="y"===x?Wn:Un,O="y"===x?Dn:Ln,I="y"===x?"height":"width",j=E[x],F=j+g[M],_=j-g[O],P=f?-k[I]/2:0,B="start"===b?A[I]:k[I],W="start"===b?-k[I]:-A[I],D=t.elements.arrow,L=f&&D?io(D):{width:0,height:0},U=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},V=U[M],Z=U[O],H=mo(0,A[I],L[I]),z=v?A[I]/2-P-H-V-R.mainAxis:B-H-V-R.mainAxis,Y=v?-A[I]/2+P+H+Z+R.mainAxis:W+H+Z+R.mainAxis,G=t.elements.arrow&&fo(t.elements.arrow),X=G?"y"===x?G.clientTop||0:G.clientLeft||0:0,J=null!=(N=null==S?void 0:S[x])?N:0,q=j+Y-J,Q=mo(f?eo(F,j+z-J-X):F,j,f?$n(_,q):_);E[x]=Q,T[x]=Q-j}if(a){var K,$="x"===x?Wn:Un,ee="x"===x?Dn:Ln,te=E[w],re="y"===w?"height":"width",ne=te+g[$],oe=te-g[ee],ie=-1!==[Wn,Un].indexOf(y),se=null!=(K=null==S?void 0:S[w])?K:0,ae=ie?ne:te-A[re]-k[re]-se+R.altAxis,le=ie?te+A[re]+k[re]-se-R.altAxis:oe,ce=f&&ie?function(e,t,r){var n=mo(e,t,r);return n>r?r:n}(ae,te,le):mo(f?ae:ne,te,f?le:oe);E[w]=ce,T[w]=ce-te}t.modifiersData[n]=T}},requiresIfExists:["offset"]};function Uo(e,t,r){void 0===r&&(r=!1);var n,o,i=Jn(t),s=Jn(t)&&function(e){var t=e.getBoundingClientRect(),r=to(t.width)/e.offsetWidth||1,n=to(t.height)/e.offsetHeight||1;return 1!==r||1!==n}(t),a=co(t),l=oo(e,s,r),c={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(i||!i&&!r)&&(("body"!==Yn(t)||No(a))&&(c=(n=t)!==Gn(n)&&Jn(n)?{scrollLeft:(o=n).scrollLeft,scrollTop:o.scrollTop}:So(n)),Jn(t)?((u=oo(t,!0)).x+=t.clientLeft,u.y+=t.clientTop):a&&(u.x=To(a))),{x:l.left+c.scrollLeft-u.x,y:l.top+c.scrollTop-u.y,width:l.width,height:l.height}}function Vo(e){var t=new Map,r=new Set,n=[];function o(e){r.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!r.has(e)){var n=t.get(e);n&&o(n)}})),n.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){r.has(e.name)||o(e)})),n}var Zo={placement:"bottom",modifiers:[],strategy:"absolute"};function Ho(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some((function(e){return!(e&&"function"==typeof e.getBoundingClientRect)}))}var zo=function(e){void 0===e&&(e={});var t=e,r=t.defaultModifiers,n=void 0===r?[]:r,o=t.defaultOptions,i=void 0===o?Zo:o;return function(e,t,r){void 0===r&&(r=i);var o,s,a={placement:"bottom",orderedModifiers:[],options:Object.assign({},Zo,i),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},l=[],c=!1,u={state:a,setOptions:function(r){var o="function"==typeof r?r(a.options):r;d(),a.options=Object.assign({},i,a.options,o),a.scrollParents={reference:Xn(e)?Oo(e):e.contextElement?Oo(e.contextElement):[],popper:Oo(t)};var s,c,p=function(e){var t=Vo(e);return zn.reduce((function(e,r){return e.concat(t.filter((function(e){return e.phase===r})))}),[])}((s=[].concat(n,a.options.modifiers),c=s.reduce((function(e,t){var r=e[t.name];return e[t.name]=r?Object.assign({},r,t,{options:Object.assign({},r.options,t.options),data:Object.assign({},r.data,t.data)}):t,e}),{}),Object.keys(c).map((function(e){return c[e]}))));return a.orderedModifiers=p.filter((function(e){return e.enabled})),a.orderedModifiers.forEach((function(e){var t=e.name,r=e.options,n=void 0===r?{}:r,o=e.effect;if("function"==typeof o){var i=o({state:a,name:t,instance:u,options:n});l.push(i||function(){})}})),u.update()},forceUpdate:function(){if(!c){var e=a.elements,t=e.reference,r=e.popper;if(Ho(t,r)){a.rects={reference:Uo(t,fo(r),"fixed"===a.options.strategy),popper:io(r)},a.reset=!1,a.placement=a.options.placement,a.orderedModifiers.forEach((function(e){return a.modifiersData[e.name]=Object.assign({},e.data)}));for(var n=0;n<a.orderedModifiers.length;n++)if(!0!==a.reset){var o=a.orderedModifiers[n],i=o.fn,s=o.options,l=void 0===s?{}:s,d=o.name;"function"==typeof i&&(a=i({state:a,options:l,name:d,instance:u})||a)}else a.reset=!1,n=-1}}},update:(o=function(){return new Promise((function(e){u.forceUpdate(),e(a)}))},function(){return s||(s=new Promise((function(e){Promise.resolve().then((function(){s=void 0,e(o())}))}))),s}),destroy:function(){d(),c=!0}};if(!Ho(e,t))return u;function d(){l.forEach((function(e){return e()})),l=[]}return u.setOptions(r).then((function(e){!c&&r.onFirstUpdate&&r.onFirstUpdate(e)})),u}}({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,r=e.instance,n=e.options,o=n.scroll,i=void 0===o||o,s=n.resize,a=void 0===s||s,l=Gn(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&c.forEach((function(e){e.addEventListener("scroll",r.update,Eo)})),a&&l.addEventListener("resize",r.update,Eo),function(){i&&c.forEach((function(e){e.removeEventListener("scroll",r.update,Eo)})),a&&l.removeEventListener("resize",r.update,Eo)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,r=e.name;t.modifiersData[r]=Fo({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,r=e.options,n=r.gpuAcceleration,o=void 0===n||n,i=r.adaptive,s=void 0===i||i,a=r.roundOffsets,l=void 0===a||a,c={placement:Kn(t.placement),variation:vo(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,wo(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,wo(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},Qn,Do,Po,Lo,bo,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,r=e.name,n=t.rects.reference,o=t.rects.popper,i=t.modifiersData.preventOverflow,s=_o(t,{elementContext:"reference"}),a=_o(t,{altBoundary:!0}),l=Bo(s,n),c=Bo(a,o,i),u=Wo(l),d=Wo(c);t.modifiersData[r]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}}]});const Yo=S.forwardRef((function(e,t){const{children:r,container:n,disablePortal:o=!1}=e,[i,s]=S.useState(null),a=De(S.isValidElement(r)?r.ref:null,t);if(Be((()=>{o||s(function(e){return"function"==typeof e?e():e}(n)||document.body)}),[n,o]),Be((()=>{if(i&&!o)return Pe(t,i),()=>{Pe(t,null)}}),[t,i,o]),o){if(S.isValidElement(r)){const e={ref:a};return S.cloneElement(r,e)}return ne.exports.jsx(S.Fragment,{children:r})}return ne.exports.jsx(S.Fragment,{children:i?N.createPortal(r,i):i})}));"production"!==process.env.NODE_ENV&&(Yo.propTypes={children:F.exports.node,container:F.exports.oneOfType([Me,F.exports.func]),disablePortal:F.exports.bool}),"production"!==process.env.NODE_ENV&&(Yo.propTypes=Ce(Yo.propTypes));var Go=Yo;function Xo(e){return $e("MuiPopper",e)}et("MuiPopper",["root"]);const Jo=["anchorEl","children","direction","disablePortal","modifiers","open","placement","popperOptions","popperRef","slotProps","slots","TransitionProps","ownerState"],qo=["anchorEl","children","container","direction","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","style","transition","slotProps","slots"];function Qo(e){return"function"==typeof e?e():e}function Ko(e){return void 0!==e.nodeType}const $o={},ei=S.forwardRef((function(e,t){var r;const{anchorEl:n,children:o,direction:i,disablePortal:s,modifiers:a,open:l,placement:c,popperOptions:u,popperRef:d,slotProps:p={},slots:f={},TransitionProps:h}=e,m=ur(e,Jo),g=S.useRef(null),y=De(g,t),b=S.useRef(null),v=De(b,d),x=S.useRef(v);Be((()=>{x.current=v}),[v]),S.useImperativeHandle(d,(()=>b.current),[]);const w=function(e,t){if("ltr"===t)return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}(c,i),[E,A]=S.useState(w),[k,C]=S.useState(Qo(n));S.useEffect((()=>{b.current&&b.current.forceUpdate()})),S.useEffect((()=>{n&&C(Qo(n))}),[n]),Be((()=>{if(!k||!l)return;if("production"!==process.env.NODE_ENV&&k&&Ko(k)&&1===k.nodeType){const e=k.getBoundingClientRect();"test"!==process.env.NODE_ENV&&0===e.top&&0===e.left&&0===e.right&&0===e.bottom&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join("\n"))}let e=[{name:"preventOverflow",options:{altBoundary:s}},{name:"flip",options:{altBoundary:s}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:e})=>{A(e.placement)}}];null!=a&&(e=e.concat(a)),u&&null!=u.modifiers&&(e=e.concat(u.modifiers));const t=zo(k,g.current,be({placement:w},u,{modifiers:e}));return x.current(t),()=>{t.destroy(),x.current(null)}}),[k,s,a,l,u,w]);const R={placement:E};null!==h&&(R.TransitionProps=h);const T=Je({root:["root"]},cn(Xo)),N=null!=(r=f.root)?r:"div",M=pn({elementType:N,externalSlotProps:p.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:y},ownerState:e,className:T.root});return ne.exports.jsx(N,be({},M,{children:"function"==typeof o?o(R):o}))})),ti=S.forwardRef((function(e,t){const{anchorEl:r,children:n,container:o,direction:i="ltr",disablePortal:s=!1,keepMounted:a=!1,modifiers:l,open:c,placement:u="bottom",popperOptions:d=$o,popperRef:p,style:f,transition:h=!1,slotProps:m={},slots:g={}}=e,y=ur(e,qo),[b,v]=S.useState(!0);if(!a&&!c&&(!h||b))return null;let x;if(o)x=o;else if(r){const e=Qo(r);x=e&&Ko(e)?Fe(e).body:Fe(null).body}const w=h?{in:c,onEnter:()=>{v(!1)},onExited:()=>{v(!0)}}:void 0;return ne.exports.jsx(Go,{disablePortal:s,container:x,children:ne.exports.jsx(ei,be({anchorEl:r,direction:i,disablePortal:s,modifiers:l,ref:t,open:h?!b:c,placement:u,popperOptions:d,popperRef:p,slotProps:m,slots:g},y,{style:be({position:"fixed",top:0,left:0,display:c||!a||h&&!b?void 0:"none"},f),TransitionProps:w,children:n}))})}));"production"!==process.env.NODE_ENV&&(ti.propTypes={anchorEl:ye(F.exports.oneOfType([Me,F.exports.object,F.exports.func]),(e=>{if(e.open){const t=Qo(e.anchorEl);if(t&&Ko(t)&&1===t.nodeType){const e=t.getBoundingClientRect();if("test"!==process.env.NODE_ENV&&0===e.top&&0===e.left&&0===e.right&&0===e.bottom)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join("\n"))}else if(!t||"function"!=typeof t.getBoundingClientRect||!Ko(t)&&null!=t.contextElement&&1!==t.contextElement.nodeType)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join("\n"))}return null})),children:F.exports.oneOfType([F.exports.node,F.exports.func]),container:F.exports.oneOfType([Me,F.exports.func]),direction:F.exports.oneOf(["ltr","rtl"]),disablePortal:F.exports.bool,keepMounted:F.exports.bool,modifiers:F.exports.arrayOf(F.exports.shape({data:F.exports.object,effect:F.exports.func,enabled:F.exports.bool,fn:F.exports.func,name:F.exports.any,options:F.exports.object,phase:F.exports.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:F.exports.arrayOf(F.exports.string),requiresIfExists:F.exports.arrayOf(F.exports.string)})),open:F.exports.bool.isRequired,placement:F.exports.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:F.exports.shape({modifiers:F.exports.array,onFirstUpdate:F.exports.func,placement:F.exports.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:F.exports.oneOf(["absolute","fixed"])}),popperRef:Oe,slotProps:F.exports.shape({root:F.exports.oneOfType([F.exports.func,F.exports.object])}),slots:F.exports.shape({root:F.exports.elementType}),transition:F.exports.bool});var ri=ti,ni="undefined"!=typeof window?S.useLayoutEffect:S.useEffect;function oi(e,t,r,n,o){var i="undefined"!=typeof window&&void 0!==window.matchMedia,s=Gr(S.useState((function(){return o&&i?r(e).matches:n?n(e).matches:t})),2),a=s[0],l=s[1];return ni((function(){var t=!0;if(i){var n=r(e),o=function(){t&&l(n.matches)};return o(),n.addListener(o),function(){t=!1,n.removeListener(o)}}}),[e,r,i]),a}var ii=S.useSyncExternalStore;function si(e,t,r,n){var o=S.useCallback((function(){return t}),[t]),i=S.useMemo((function(){if(null!==n){var t=n(e).matches;return function(){return t}}return o}),[o,e,n]),s=Gr(S.useMemo((function(){if(null===r)return[o,function(){return function(){}}];var t=r(e);return[function(){return t.matches},function(e){return t.addListener(e),function(){t.removeListener(e)}}]}),[o,r,e]),2),a=s[0],l=s[1];return ii(l,a,i)}function ai(){return{isMobile:function(e,t){void 0===t&&(t={});var r=Ar(),n="undefined"!=typeof window&&void 0!==window.matchMedia,o=Lr({name:"MuiUseMediaQuery",props:t,theme:r||void 0}),i=o.defaultMatches,s=void 0!==i&&i,a=o.matchMedia,l=void 0===a?n?window.matchMedia:null:a,c=o.ssrMatchMedia,u=void 0===c?null:c,d=o.noSsr;"production"!==process.env.NODE_ENV&&null===r&&console.error(["MUI: The `query` argument provided is invalid.","You are providing a function without a theme in the context.","One of the parent elements needs to use a ThemeProvider."].join("\n"));var p=e(r);p=p.replace(/^@media( ?)/m,"");var f=(void 0!==ii?si:oi)(p,s,l,u,d);return"production"!==process.env.NODE_ENV&&S.useDebugValue({query:p,match:f}),f}((function(e){return e.breakpoints.down("tablet")}))}}var li="DODOTooltip-arrow",ci=Dr("div")((function(e){var t,r=e.theme;return"\n z-index: ".concat(null===(t=r.zIndex)||void 0===t?void 0:t.tooltip,';\n &[data-popper-placement*="bottom"] .').concat(li," {\n top: 0;\n margin-top: -").concat(8,'px;\n &::before {\n transform-origin: 0 100%;\n }\n }\n &[data-popper-placement*="top"] .').concat(li," {\n bottom: 0;\n margin-bottom: -").concat(8,'px;\n &::before {\n transform-origin: 100% 0;\n }\n }\n &[data-popper-placement*="right"] .').concat(li,' {\n &::before {\n transform-origin: 100% 100%;\n }\n }\n &[data-popper-placement*="left"] .').concat(li," {\n &::before {\n transform-origin: 0 0;\n }\n }\n ")}));function ui(e){var t=e.title,o=e.sx,i=e.maxWidth,s=void 0===i?"auto":i,a=e.popperOptions,l=e.children,c=e.onlyHover,u=e.enterDelay,d=void 0===u?100:u,p=e.leaveDelay,f=void 0===p?0:p,h=Yr(e,["title","sx","maxWidth","popperOptions","children","onlyHover","enterDelay","leaveDelay"]);Cr();var m=ai().isMobile,g=n.useRef(!1),y=n.useRef(!1),b=n.useRef(),v=n.useRef(),x=Gr(n.useState(),2),w=x[0],E=x[1],A=Gr(n.useState(),2),k=A[0],C=A[1],R=Gr(n.useState(!1),2),S=R[0],T=R[1],N=m&&!c,M={ref:E};if(N)M.onClick=function(){T(!0)};else{var O=function(){y.current=!0,clearTimeout(v.current),clearTimeout(b.current),b.current=setTimeout((function(){T(!0)}),d)};M.onMouseOut=O,M.onMouseEnter=O,M.onMouseLeave=function(){y.current=!1,clearTimeout(v.current),clearTimeout(b.current),v.current=setTimeout((function(){y.current||g.current||T(!1)}),f)}}return n.useEffect((function(){return function(){T(!1),clearTimeout(v.current),clearTimeout(b.current)}}),[]),ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsxs(ri,zr({open:S,anchorEl:w,slots:{root:ci},popperOptions:r.merge({modifiers:[{name:"offset",options:{offset:[0,8]}},{name:"preventOverflow",options:{padding:20}},{name:"arrow",options:{element:k,padding:4}}]},a)},h,{children:[ne.exports.jsx(Tr,zr({sx:zr({typography:"h6",padding:12,maxWidth:s,fontWeight:500,backgroundColor:"background.paperContrast",borderRadius:8,color:"text.secondary",borderColor:"border.main",borderWidth:1,borderStyle:"solid",whiteSpace:"pre-wrap"},o),onMouseEnter:function(){N||(g.current=!0,clearTimeout(v.current),clearTimeout(b.current))},onMouseLeave:function(){N||(g.current=!1,clearTimeout(v.current),clearTimeout(b.current),v.current=setTimeout((function(){y.current||g.current||T(!1)}),f))},onClick:function(e){return e.stopPropagation()}},{children:t})),ne.exports.jsx(Tr,{ref:C,className:li,sx:{overflow:"hidden",position:"absolute",width:16,height:9,boxSizing:"border-box",color:"background.paperContrast",bottom:0,marginBottom:-8,"&::before":{transformOrigin:"100% 0",content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)",border:"solid 1px",borderColor:"border.main"}}})]})),ne.exports.jsx(Bn,zr({onClickAway:function(){N&&T(!1)}},{children:n.cloneElement(l,M)}))]})}function di(e){var t=e.title,r=e.ml,n=e.mr,o=e.size,s=void 0===o?15:o,a=e.sx,l=e.maxWidth,c=e.container;return e.onlyHover,t?ne.exports.jsx(ui,zr({title:t,placement:"top",container:c,maxWidth:l,onlyHover:!0},{children:ne.exports.jsx(jn,{component:i.QuestionBorder,sx:zr({ml:r,mr:n,width:s,height:s},a)})})):null}function pi(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function fi(e){return parseInt(_e(e).getComputedStyle(e).paddingRight,10)||0}function hi(e,t,r,n,o){const i=[t,r,...n];[].forEach.call(e.children,(e=>{const t=-1===i.indexOf(e),r=!function(e){const t=-1!==["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName),r="INPUT"===e.tagName&&"hidden"===e.getAttribute("type");return t||r}(e);t&&r&&pi(e,o)}))}function mi(e,t){let r=-1;return e.some(((e,n)=>!!t(e)&&(r=n,!0))),r}const gi=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function yi(e){const t=[],r=[];return Array.from(e.querySelectorAll(gi)).forEach(((e,n)=>{const o=function(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?"true"===e.contentEditable||("AUDIO"===e.nodeName||"VIDEO"===e.nodeName||"DETAILS"===e.nodeName)&&null===e.getAttribute("tabindex")?0:e.tabIndex:t}(e);-1!==o&&function(e){return!(e.disabled||"INPUT"===e.tagName&&"hidden"===e.type||function(e){if("INPUT"!==e.tagName||"radio"!==e.type)return!1;if(!e.name)return!1;const t=t=>e.ownerDocument.querySelector(`input[type="radio"]${t}`);let r=t(`[name="${e.name}"]:checked`);return r||(r=t(`[name="${e.name}"]`)),r!==e}(e))}(e)&&(0===o?t.push(e):r.push({documentOrder:n,tabIndex:o,node:e}))})),r.sort(((e,t)=>e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex)).map((e=>e.node)).concat(t)}function bi(){return!0}function vi(e){const{children:t,disableAutoFocus:r=!1,disableEnforceFocus:n=!1,disableRestoreFocus:o=!1,getTabbable:i=yi,isEnabled:s=bi,open:a}=e,l=S.useRef(!1),c=S.useRef(null),u=S.useRef(null),d=S.useRef(null),p=S.useRef(null),f=S.useRef(!1),h=S.useRef(null),m=De(t.ref,h),g=S.useRef(null);S.useEffect((()=>{a&&h.current&&(f.current=!r)}),[r,a]),S.useEffect((()=>{if(!a||!h.current)return;const e=Fe(h.current);return h.current.contains(e.activeElement)||(h.current.hasAttribute("tabIndex")||("production"!==process.env.NODE_ENV&&console.error(["MUI: The modal content node does not accept focus.",'For the benefit of assistive technologies, the tabIndex of the node is being set to "-1".'].join("\n")),h.current.setAttribute("tabIndex","-1")),f.current&&h.current.focus()),()=>{o||(d.current&&d.current.focus&&(l.current=!0,d.current.focus()),d.current=null)}}),[a]),S.useEffect((()=>{if(!a||!h.current)return;const e=Fe(h.current),t=t=>{const{current:r}=h;if(null!==r)if(e.hasFocus()&&!n&&s()&&!l.current){if(!r.contains(e.activeElement)){if(t&&p.current!==t.target||e.activeElement!==p.current)p.current=null;else if(null!==p.current)return;if(!f.current)return;let n=[];if(e.activeElement!==c.current&&e.activeElement!==u.current||(n=i(h.current)),n.length>0){var o,a;const e=Boolean((null==(o=g.current)?void 0:o.shiftKey)&&"Tab"===(null==(a=g.current)?void 0:a.key)),t=n[0],r=n[n.length-1];"string"!=typeof t&&"string"!=typeof r&&(e?r.focus():t.focus())}else r.focus()}}else l.current=!1},r=t=>{g.current=t,!n&&s()&&"Tab"===t.key&&e.activeElement===h.current&&t.shiftKey&&(l.current=!0,u.current&&u.current.focus())};e.addEventListener("focusin",t),e.addEventListener("keydown",r,!0);const o=setInterval((()=>{e.activeElement&&"BODY"===e.activeElement.tagName&&t(null)}),50);return()=>{clearInterval(o),e.removeEventListener("focusin",t),e.removeEventListener("keydown",r,!0)}}),[r,n,o,s,a,i]);const y=e=>{null===d.current&&(d.current=e.relatedTarget),f.current=!0};return ne.exports.jsxs(S.Fragment,{children:[ne.exports.jsx("div",{tabIndex:a?0:-1,onFocus:y,ref:c,"data-testid":"sentinelStart"}),S.cloneElement(t,{ref:m,onFocus:e=>{null===d.current&&(d.current=e.relatedTarget),f.current=!0,p.current=e.target;const r=t.props.onFocus;r&&r(e)}}),ne.exports.jsx("div",{tabIndex:a?0:-1,onFocus:y,ref:u,"data-testid":"sentinelEnd"})]})}function xi(e){return $e("MuiModal",e)}"production"!==process.env.NODE_ENV&&(vi.propTypes={children:ke,disableAutoFocus:F.exports.bool,disableEnforceFocus:F.exports.bool,disableRestoreFocus:F.exports.bool,getTabbable:F.exports.func,isEnabled:F.exports.func,open:F.exports.bool.isRequired}),"production"!==process.env.NODE_ENV&&(vi.propTypes=Ce(vi.propTypes)),et("MuiModal",["root","hidden","backdrop"]);const wi=["children","closeAfterTransition","container","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","manager","onBackdropClick","onClose","onKeyDown","open","onTransitionEnter","onTransitionExited","slotProps","slots"],Ei=new class{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(e,t){let r=this.modals.indexOf(e);if(-1!==r)return r;r=this.modals.length,this.modals.push(e),e.modalRef&&pi(e.modalRef,!1);const n=function(e){const t=[];return[].forEach.call(e.children,(e=>{"true"===e.getAttribute("aria-hidden")&&t.push(e)})),t}(t);hi(t,e.mount,e.modalRef,n,!0);const o=mi(this.containers,(e=>e.container===t));return-1!==o?(this.containers[o].modals.push(e),r):(this.containers.push({modals:[e],container:t,restore:null,hiddenSiblings:n}),r)}mount(e,t){const r=mi(this.containers,(t=>-1!==t.modals.indexOf(e))),n=this.containers[r];n.restore||(n.restore=function(e,t){const r=[],n=e.container;if(!t.disableScrollLock){if(function(e){const t=Fe(e);return t.body===e?_e(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}(n)){const e=function(e){const t=e.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}(Fe(n));r.push({value:n.style.paddingRight,property:"padding-right",el:n}),n.style.paddingRight=`${fi(n)+e}px`;const t=Fe(n).querySelectorAll(".mui-fixed");[].forEach.call(t,(t=>{r.push({value:t.style.paddingRight,property:"padding-right",el:t}),t.style.paddingRight=`${fi(t)+e}px`}))}let e;if(n.parentNode instanceof DocumentFragment)e=Fe(n).body;else{const t=n.parentElement,r=_e(n);e="HTML"===(null==t?void 0:t.nodeName)&&"scroll"===r.getComputedStyle(t).overflowY?t:n}r.push({value:e.style.overflow,property:"overflow",el:e},{value:e.style.overflowX,property:"overflow-x",el:e},{value:e.style.overflowY,property:"overflow-y",el:e}),e.style.overflow="hidden"}return()=>{r.forEach((({value:e,el:t,property:r})=>{e?t.style.setProperty(r,e):t.style.removeProperty(r)}))}}(n,t))}remove(e,t=!0){const r=this.modals.indexOf(e);if(-1===r)return r;const n=mi(this.containers,(t=>-1!==t.modals.indexOf(e))),o=this.containers[n];if(o.modals.splice(o.modals.indexOf(e),1),this.modals.splice(r,1),0===o.modals.length)o.restore&&o.restore(),e.modalRef&&pi(e.modalRef,t),hi(o.container,e.mount,e.modalRef,o.hiddenSiblings,!1),this.containers.splice(n,1);else{const e=o.modals[o.modals.length-1];e.modalRef&&pi(e.modalRef,!1)}return r}isTopModal(e){return this.modals.length>0&&this.modals[this.modals.length-1]===e}},Ai=S.forwardRef((function(e,t){var r,n;const{children:o,closeAfterTransition:i=!1,container:s,disableAutoFocus:a=!1,disableEnforceFocus:l=!1,disableEscapeKeyDown:c=!1,disablePortal:u=!1,disableRestoreFocus:d=!1,disableScrollLock:p=!1,hideBackdrop:f=!1,keepMounted:h=!1,manager:m=Ei,onBackdropClick:g,onClose:y,onKeyDown:b,open:v,onTransitionEnter:x,onTransitionExited:w,slotProps:E={},slots:A={}}=e,k=ur(e,wi),C=m,[R,T]=S.useState(!v),N=S.useRef({}),M=S.useRef(null),O=S.useRef(null),I=De(O,t),j=function(e){return!!e&&e.props.hasOwnProperty("in")}(o),F=null==(r=e["aria-hidden"])||r,_=()=>(N.current.modalRef=O.current,N.current.mountNode=M.current,N.current),P=()=>{C.mount(_(),{disableScrollLock:p}),O.current&&(O.current.scrollTop=0)},B=We((()=>{const e=function(e){return"function"==typeof e?e():e}(s)||Fe(M.current).body;C.add(_(),e),O.current&&P()})),W=S.useCallback((()=>C.isTopModal(_())),[C]),D=We((e=>{M.current=e,e&&O.current&&(v&&W()?P():pi(O.current,F))})),L=S.useCallback((()=>{C.remove(_(),F)}),[C,F]);S.useEffect((()=>()=>{L()}),[L]),S.useEffect((()=>{v?B():j&&i||L()}),[v,L,j,i,B]);const U=be({},e,{closeAfterTransition:i,disableAutoFocus:a,disableEnforceFocus:l,disableEscapeKeyDown:c,disablePortal:u,disableRestoreFocus:d,disableScrollLock:p,exited:R,hideBackdrop:f,keepMounted:h}),V=(e=>{const{open:t,exited:r}=e;return Je({root:["root",!t&&r&&"hidden"],backdrop:["backdrop"]},cn(xi))})(U),Z={};void 0===o.props.tabIndex&&(Z.tabIndex="-1"),j&&(Z.onEnter=je((()=>{T(!1),x&&x()}),o.props.onEnter),Z.onExited=je((()=>{T(!0),w&&w(),i&&L()}),o.props.onExited));const H=null!=(n=A.root)?n:"div",z=pn({elementType:H,externalSlotProps:E.root,externalForwardedProps:k,additionalProps:{ref:I,role:"presentation",onKeyDown:e=>{b&&b(e),"Escape"===e.key&&W()&&(c||(e.stopPropagation(),y&&y(e,"escapeKeyDown")))}},className:V.root,ownerState:U}),Y=A.backdrop,G=pn({elementType:Y,externalSlotProps:E.backdrop,additionalProps:{"aria-hidden":!0,onClick:e=>{e.target===e.currentTarget&&(g&&g(e),y&&y(e,"backdropClick"))},open:v},className:V.backdrop,ownerState:U});return h||v||j&&!R?ne.exports.jsx(Go,{ref:D,container:s,disablePortal:u,children:ne.exports.jsxs(H,be({},z,{children:[!f&&Y?ne.exports.jsx(Y,be({},G)):null,ne.exports.jsx(vi,{disableEnforceFocus:l,disableAutoFocus:a,disableRestoreFocus:d,isEnabled:W,open:v,children:S.cloneElement(o,Z)})]}))}):null}));"production"!==process.env.NODE_ENV&&(Ai.propTypes={children:ke.isRequired,closeAfterTransition:F.exports.bool,container:F.exports.oneOfType([Me,F.exports.func]),disableAutoFocus:F.exports.bool,disableEnforceFocus:F.exports.bool,disableEscapeKeyDown:F.exports.bool,disablePortal:F.exports.bool,disableRestoreFocus:F.exports.bool,disableScrollLock:F.exports.bool,hideBackdrop:F.exports.bool,keepMounted:F.exports.bool,onBackdropClick:F.exports.func,onClose:F.exports.func,onTransitionEnter:F.exports.func,onTransitionExited:F.exports.func,open:F.exports.bool.isRequired,slotProps:F.exports.shape({backdrop:F.exports.oneOfType([F.exports.func,F.exports.object]),root:F.exports.oneOfType([F.exports.func,F.exports.object])}),slots:F.exports.shape({backdrop:F.exports.elementType,root:F.exports.elementType})});var ki,Ci,Ri=Ai,Si=n.forwardRef((function(e,t){var r=e.open,n=e.className,o=Yr(e,["open","className"]);return ne.exports.jsx("div",zr({className:fr({"MuiBackdrop-open":r},n),ref:t},o))})),Ti=Dr(Ri)(ki||(ki=Jr(["\n position: absolute;\n z-index: 1300;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-end;\n"],["\n position: absolute;\n z-index: 1300;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-end;\n"]))),Ni=Dr(Si)(Ci||(Ci=Jr(["\n z-index: -1;\n position: absolute;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n background-color: ",";\n -webkit-tap-highlight-color: transparent;\n"],["\n z-index: -1;\n position: absolute;\n right: 0;\n bottom: 0;\n top: 0;\n left: 0;\n background-color: ",";\n -webkit-tap-highlight-color: transparent;\n"])),(function(e){return e.theme.palette.background.backdrop}));function Mi(e){return ne.exports.jsx(Ti,zr({slots:{backdrop:Ni}},e))}var Oi=n.forwardRef((function(e,t){var r=Cr(),n=e.size,o=void 0===n?18:n,s=e.sx,a=Yr(e,["size","sx"]);return ne.exports.jsx(Tr,zr({component:"span",sx:zr({position:"relative",cursor:"pointer",userSelect:"none",width:o,height:o,"&:hover > .checkbox-icon":{borderColor:r.palette.text.primary}},s)},{children:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Tr,zr({component:"input",type:"checkbox",ref:t,sx:{cursor:"inherit",position:"absolute",opacity:0,width:"100%",height:"100%",top:0,left:0,m:0,p:0,zIndex:1,"&:checked + .checkbox-icon":{border:"none",backgroundColor:"secondary.main",color:"secondary.contrastText","& svg":{display:"inline-block"}}}},a)),ne.exports.jsx(Tr,zr({component:"span",className:"checkbox-icon",sx:{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:4,width:o,height:o,borderStyle:"solid",borderWidth:1,flex:1,borderColor:r.palette.text.secondary,".Mui-focusVisible &":{outline:"none",outlineOffset:2},"input:disabled ~ &":{borderColor:r.palette.text.disabled}}},{children:ne.exports.jsx(Tr,{component:i.Done,sx:{display:"none",width:"75%",height:"75%"}})}))]})}))}));function Ii(){return Ii=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ii.apply(this,arguments)}function ji(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}const Fi=["preEnter","entering","entered","preExit","exiting","exited","unmounted"],_i=e=>e?6:5,Pi=new Map,Bi=new Map,Wi=(e,t,r,n,o,i)=>{clearTimeout(o);const s=(e=>({_s:e,status:Fi[e],isEnter:e<3,isMounted:6!==e,isResolved:2===e||e>4}))(t),a=new Map(n.current);a.set(e,s),r(a),n.current=a,i&&i({key:e,current:s})},Di=["transition","transitionTimeout"],Li=(e,t)=>!0===e||!(!e||!e[t]),Ui=n.createContext({}),Vi=(e,t,r)=>(n,o)=>{const i=t?`${e}__${t}`:e;let s=i;r&&Object.keys(r).forEach((e=>{const t=r[e];t&&(s+=` ${i}--${!0===t?e:`${e}-${t}`}`)}));let a="function"==typeof n?n(o):n;return"string"==typeof a&&(a=a.trim(),a&&(s+=` ${a}`)),s},Zi=(e,t)=>{if(!t)return e;const r=Ii({},e);return Object.keys(t).forEach((n=>{const o=e[n],i=t[n];r[n]="function"==typeof i&&o?(...e)=>{o(...e),i(...e)}:i})),r},Hi=e=>ne.exports.jsx(Ui.Provider,Ii({},e)),zi=e=>{do{e=e.parentElement}while(e&&!e.hasAttribute("data-szh-adn"));return e},Yi=(e,t,r)=>e?t>0?t-1:r-1:(t+1)%r,Gi=(e,t)=>{const{activeElement:r}=document;if(!r||!r.hasAttribute("data-szh-adn-btn")||zi(r)!==t.currentTarget)return;const n=t.currentTarget.querySelectorAll("[data-szh-adn-btn]"),{length:o}=n;for(let i=0;i<o;i++)if(n[i]===r){let r=Yi(e,i,o);for(;zi(n[i])!==zi(n[r]);)r=Yi(e,r,o);i!==r&&(t.preventDefault(),n[r].focus());break}},Xi=["providerValue","className"],Ji=n.forwardRef(((e,t)=>{let{providerValue:r,className:n}=e,o=ji(e,Xi);const{accordionProps:i}={accordionProps:{"data-szh-adn":"",onKeyDown:e=>"ArrowUp"===e.key?Gi(!0,e):"ArrowDown"===e.key&&Gi(!1,e)}};return ne.exports.jsx(Hi,{value:r,children:ne.exports.jsx("div",Ii({},Zi(i,o),{ref:t,className:Vi("szh-accordion")(n)}))})}));Ji.displayName="ControlledAccordion";const qi=["allowMultiple","initialEntered","mountOnEnter","unmountOnExit","transition","transitionTimeout","onStateChange"],Qi=n.forwardRef(((e,t)=>{let{allowMultiple:r,initialEntered:o,mountOnEnter:i,unmountOnExit:s,transition:a,transitionTimeout:l,onStateChange:c}=e,u=ji(e,qi);const d=((e={})=>{let{transition:t,transitionTimeout:r}=e,o=ji(e,Di);const i=(({allowMultiple:e,enter:t=!0,exit:r=!0,preEnter:o,preExit:i,timeout:s,initialEntered:a,mountOnEnter:l,unmountOnExit:c,onStateChange:u}={})=>{const[d,p]=n.useState(Pi),f=n.useRef(d),h=n.useRef(Bi),[m,g]=(e=>"object"==typeof e?[e.enter,e.exit]:[e,e])(s),y=n.useCallback(((e,t)=>{const{initialEntered:r=a}=t||{},n=r?2:_i(l);Wi(e,n,p,f),h.current.set(e,{})}),[a,l]),b=n.useCallback((e=>{const t=new Map(f.current);return!!t.delete(e)&&(p(t),f.current=t,h.current.delete(e),!0)}),[]),v=n.useCallback((e=>{const t=f.current.get(e);if(!t)return void("production"!==process.env.NODE_ENV&&console.error(`[React-Transition-State] invalid key: ${e}`));const{timeoutId:r}=h.current.get(e),n=((e,t)=>{switch(e){case 1:case 0:return 2;case 4:case 3:return _i(t)}})(t._s,c);n&&Wi(e,n,p,f,r,u)}),[u,c]),x=n.useCallback(((n,s)=>{const a=f.current.get(n);if(!a)return void("production"!==process.env.NODE_ENV&&console.error(`[React-Transition-State] invalid key: ${n}`));const l=h.current.get(n),d=e=>{switch(Wi(n,e,p,f,l.timeoutId,u),e){case 1:m>=0&&(l.timeoutId=setTimeout((()=>v(n)),m));break;case 4:g>=0&&(l.timeoutId=setTimeout((()=>v(n)),g));break;case 0:case 3:l.timeoutId=setTimeout((()=>d(e+1)),0)}},y=a.isEnter;"boolean"!=typeof s&&(s=!y),s?y||(d(t?o?0:1:2),!e&&f.current.forEach(((e,t)=>t!==n&&x(t,!1)))):y&&d(r?i?3:4:_i(c))}),[u,v,e,t,r,o,i,m,g,c]),w=n.useCallback((t=>{if(e||!1===t)for(const e of f.current.keys())x(e,t)}),[e,x]);return{stateMap:d,toggle:x,toggleAll:w,endTransition:v,setItem:y,deleteItem:b}})(Ii({timeout:r,enter:Li(t,"enter"),exit:Li(t,"exit"),preEnter:Li(t,"preEnter"),preExit:Li(t,"preExit")},o));return Ii({mountOnEnter:!!o.mountOnEnter,initialEntered:!!o.initialEntered},i)})({allowMultiple:r,initialEntered:o,mountOnEnter:i,unmountOnExit:s,transition:a,transitionTimeout:l,onStateChange:c});return ne.exports.jsx(Ji,Ii({},u,{ref:t,providerValue:d}))}));Qi.displayName="Accordion";let Ki=0;const $i=n.useId||(()=>{const[e,t]=n.useState();return n.useEffect((()=>t(++Ki)),[]),e&&`szh-adn-${e}`}),es="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement?n.useLayoutEffect:n.useEffect;function ts(e,t){"function"==typeof e?e(t):e.current=t}function rs(e,t){return n.useMemo((()=>e?t?r=>{ts(e,r),ts(t,r)}:e:t),[e,t])}const ns=["itemKey","initialEntered"],os=["forwardedRef","itemRef","state","toggle","className","disabled","header","headingTag","headingProps","buttonProps","contentProps","panelProps","children"],is=(e,t)=>"function"==typeof e?e(t):e,ss=n.memo((e=>{let{forwardedRef:t,itemRef:r,state:o,toggle:i,className:s,disabled:a,header:l,headingTag:c="h3",headingProps:u,buttonProps:d,contentProps:p,panelProps:f,children:h}=e,m=ji(e,os);const g={state:o,toggle:i,disabled:a},{buttonProps:y,panelProps:b}=(({state:e,toggle:t,disabled:r})=>{const n=$i(),o=n&&n+"-",i={id:n,"aria-controls":o,"aria-expanded":e.isEnter,onClick:t};return r?i.disabled=!0:i["data-szh-adn-btn"]="",{buttonProps:i,panelProps:{id:o,"aria-labelledby":n,role:"region"}}})(g),[v,x]=(({status:e,isResolved:t})=>{const[r,o]=n.useState(),i=n.useRef(null);return es((()=>{("preEnter"===e||"preExit"===e)&&o(i.current.getBoundingClientRect().height)}),[e]),[{height:"preEnter"===e||"exiting"===e?0:"entering"===e||"preExit"===e?r:void 0,overflow:t?void 0:"hidden"},i]})(o),w=rs(f&&f.ref,x),{status:E,isMounted:A,isEnter:k}=o;return ne.exports.jsxs("div",Ii({},m,{ref:rs(t,r),className:Vi("szh-accordion","item",{status:E,expanded:k})(s,o),children:[ne.exports.jsx(c,Ii({},u,{style:Ii({margin:0},u&&u.style),className:Vi("szh-accordion","item-heading")(u&&u.className,o),children:ne.exports.jsx("button",Ii({},Zi(y,d),{type:"button",className:Vi("szh-accordion","item-btn")(d&&d.className,o),children:is(l,g)}))})),A&&ne.exports.jsx("div",Ii({},p,{style:Ii({display:"exited"===E?"none":void 0},v,p&&p.style),className:Vi("szh-accordion","item-content")(p&&p.className,o),children:ne.exports.jsx("div",Ii({},Zi(b,f),{ref:w,className:Vi("szh-accordion","item-panel")(f&&f.className,o),children:is(h,g)}))}))]}))}));ss.displayName="AccordionItem";const as=(e=>{const t=n.forwardRef(((t,r)=>{let{itemKey:o,initialEntered:i}=t,s=ji(t,ns);return ne.exports.jsx(e,Ii({forwardedRef:r},s,(({itemKey:e,initialEntered:t,disabled:r}={})=>{const o=n.useRef(null),i=(()=>{const e=n.useContext(Ui);if("production"!==process.env.NODE_ENV&&!e.stateMap)throw new Error("[React-Accordion] Cannot find a <AccordionProvider/> above this AccordionItem.");return e})(),s=null!=e?e:o.current,a=((e,t,r)=>{const{stateMap:n,mountOnEnter:o,initialEntered:i}=e,s=null!=r?r:i;return n.get(t)||{status:s?"entered":o?"unmounted":"exited",isMounted:!o,isEnter:s,isResolved:!0}})(i,s,t),{setItem:l,deleteItem:c,toggle:u}=i;return n.useEffect((()=>{if(r)return;const n=null!=e?e:o.current;return l(n,{initialEntered:t}),()=>{c(n)}}),[l,c,e,t,r]),{itemRef:o,state:a,toggle:n.useCallback((e=>u(s,e)),[u,s])}})({itemKey:o,initialEntered:i,disabled:s.disabled})))}));return t.displayName="WithAccordionItem",t})(ss);function ls(e){var t=e.sx,n=e.buttonProps,o=Yr(e,["sx","buttonProps"]);return ne.exports.jsx(Tr,zr({component:as,sx:r.merge({"& button":{p:0,border:"none",width:"100%",backgroundColor:"transparent",cursor:"pointer"}},t),buttonProps:zr({className:function(e){var t=e.isEnter;return"".concat(t?"active":"")}},n)},o))}function cs({input:e,showDecimals:r=4,showPrecisionDecimals:n=2,showIntegerOnly:o=!1,showDecimalsOnly:i=!1,noGroupSeparator:s=!1}){const a=new t.BigNumber(e);if(a.isNaN())return"-";let l=a.dp(r,t.BigNumber.ROUND_DOWN);return l.eq(0)&&(a.gt(0)||a.lt(0))&&(l=a.sd(null!=n?n:r,t.BigNumber.ROUND_DOWN)),o&&(l=l.integerValue(t.BigNumber.ROUND_DOWN)),i&&(l=l.minus(l.integerValue(t.BigNumber.ROUND_DOWN))),s?l.toFormat({decimalSeparator:".",groupSeparator:"",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:"",fractionGroupSize:0}):l.toFormat()}function us({input:e,decimals:r,showPrecisionDecimals:n=2,noGroupSeparator:o}){if(null==e)return"-";const i=new t.BigNumber(e);if(i.isNaN())return"-";return cs({input:i,showDecimals:void 0===r?0:r>6?6:r>4?4:r,showPrecisionDecimals:n,noGroupSeparator:o})}function ds(e){if("number"==typeof e)return ds(new t.BigNumber(e));if(e.isNaN())return"NaN";if(e.isNegative())return`-${ds(e.negated())}`;if(e.isZero())return"0";let r=e.integerValue(t.BigNumber.ROUND_FLOOR),n=e.minus(r),o="";for(;!r.isZero();){o=r.modulo(10).toString().toString()+o,r=r.idiv(10)}if(""===o&&(o="0"),n.isZero())return o;o+=".";let i=0;for(;!n.isZero()&&i<100;){const e=n.times(10),r=e.integerValue(t.BigNumber.ROUND_FLOOR);o+=r.toString(),n=e.minus(r),i+=1}return o}const ps=(e,r)=>{if("string"==typeof e&&!e.match(/[-+]?\d+(.+d+)?/))return e;const n=new t.BigNumber(e);if(r){let e=n.toFixed(r,t.BigNumber.ROUND_DOWN);return o=e,new t.BigNumber(o).isZero()&&(e=ds(n.precision(r,t.BigNumber.ROUND_DOWN))),e}var o;return ds(n)},fs=(e,t)=>{let r=e;const n=r.match("[0-9。.]+");r=n&&n.length>0?n[0]:"",r=r.replace("。",".");let o=0;if(r){const e=r.split("."),t=0===e[0].length?["0"]:[e[0]];e.length>1?t[1]=e.slice(1,e.length).join(""):t[0].length>1&&"0"===t[0][0]&&(t[0]=t[0].slice(1,t[0].length)),t.length>1&&(o=t[1].length),r=t.join(".")}return t>=0&&o>t?ps(r,t):r},hs=(e,r,n)=>{const o=new t.BigNumber(e).times(new t.BigNumber(10).pow(r));return n?o:o.dp(0)};function ms(e){return Number(e.toString().split(".")[0])}let gs=!1,ys=!1;const bs={debug:1,default:2,info:2,warning:3,error:4,off:5};let vs=bs.default,xs=null;const ws=function(){try{const e=[];if(["NFD","NFC","NFKD","NFKC"].forEach((t=>{try{if("test"!=="test".normalize(t))throw new Error("bad normalize")}catch(r){e.push(t)}})),e.length)throw new Error("missing "+e.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(e){return e.message}return null}();var Es,As;!function(e){e.DEBUG="DEBUG",e.INFO="INFO",e.WARNING="WARNING",e.ERROR="ERROR",e.OFF="OFF"}(Es||(Es={})),function(e){e.UNKNOWN_ERROR="UNKNOWN_ERROR",e.NOT_IMPLEMENTED="NOT_IMPLEMENTED",e.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",e.NETWORK_ERROR="NETWORK_ERROR",e.SERVER_ERROR="SERVER_ERROR",e.TIMEOUT="TIMEOUT",e.BUFFER_OVERRUN="BUFFER_OVERRUN",e.NUMERIC_FAULT="NUMERIC_FAULT",e.MISSING_NEW="MISSING_NEW",e.INVALID_ARGUMENT="INVALID_ARGUMENT",e.MISSING_ARGUMENT="MISSING_ARGUMENT",e.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",e.CALL_EXCEPTION="CALL_EXCEPTION",e.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",e.NONCE_EXPIRED="NONCE_EXPIRED",e.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",e.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",e.TRANSACTION_REPLACED="TRANSACTION_REPLACED",e.ACTION_REJECTED="ACTION_REJECTED"}(As||(As={}));const ks="0123456789abcdef";class Cs{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,t){const r=e.toLowerCase();null==bs[r]&&this.throwArgumentError("invalid log level name","logLevel",e),vs>bs[r]||console.log.apply(console,t)}debug(...e){this._log(Cs.levels.DEBUG,e)}info(...e){this._log(Cs.levels.INFO,e)}warn(...e){this._log(Cs.levels.WARNING,e)}makeError(e,t,r){if(ys)return this.makeError("censored error",t,{});t||(t=Cs.errors.UNKNOWN_ERROR),r||(r={});const n=[];Object.keys(r).forEach((e=>{const t=r[e];try{if(t instanceof Uint8Array){let r="";for(let e=0;e<t.length;e++)r+=ks[t[e]>>4],r+=ks[15&t[e]];n.push(e+"=Uint8Array(0x"+r+")")}else n.push(e+"="+JSON.stringify(t))}catch(t){n.push(e+"="+JSON.stringify(r[e].toString()))}})),n.push(`code=${t}`),n.push(`version=${this.version}`);const o=e;let i="";switch(t){case As.NUMERIC_FAULT:{i="NUMERIC_FAULT";const t=e;switch(t){case"overflow":case"underflow":case"division-by-zero":i+="-"+t;break;case"negative-power":case"negative-width":i+="-unsupported";break;case"unbound-bitwise-result":i+="-unbound-result"}break}case As.CALL_EXCEPTION:case As.INSUFFICIENT_FUNDS:case As.MISSING_NEW:case As.NONCE_EXPIRED:case As.REPLACEMENT_UNDERPRICED:case As.TRANSACTION_REPLACED:case As.UNPREDICTABLE_GAS_LIMIT:i=t}i&&(e+=" [ See: https://links.ethers.org/v5-errors-"+i+" ]"),n.length&&(e+=" ("+n.join(", ")+")");const s=new Error(e);return s.reason=o,s.code=t,Object.keys(r).forEach((function(e){s[e]=r[e]})),s}throwError(e,t,r){throw this.makeError(e,t,r)}throwArgumentError(e,t,r){return this.throwError(e,Cs.errors.INVALID_ARGUMENT,{argument:t,value:r})}assert(e,t,r,n){e||this.throwError(t,r,n)}assertArgument(e,t,r,n){e||this.throwArgumentError(t,r,n)}checkNormalize(e){ws&&this.throwError("platform missing String.prototype.normalize",Cs.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:ws})}checkSafeUint53(e,t){"number"==typeof e&&(null==t&&(t="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(t,Cs.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(t,Cs.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,t,r){r=r?": "+r:"",e<t&&this.throwError("missing argument"+r,Cs.errors.MISSING_ARGUMENT,{count:e,expectedCount:t}),e>t&&this.throwError("too many arguments"+r,Cs.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:t})}checkNew(e,t){e!==Object&&null!=e||this.throwError("missing new",Cs.errors.MISSING_NEW,{name:t.name})}checkAbstract(e,t){e===t?this.throwError("cannot instantiate abstract class "+JSON.stringify(t.name)+" directly; use a sub-class",Cs.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):e!==Object&&null!=e||this.throwError("missing new",Cs.errors.MISSING_NEW,{name:t.name})}static globalLogger(){return xs||(xs=new Cs("logger/5.7.0")),xs}static setCensorship(e,t){if(!e&&t&&this.globalLogger().throwError("cannot permanently disable censorship",Cs.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),gs){if(!e)return;this.globalLogger().throwError("error censorship permanent",Cs.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}ys=!!e,gs=!!t}static setLogLevel(e){const t=bs[e.toLowerCase()];null!=t?vs=t:Cs.globalLogger().warn("invalid log level - "+e)}static from(e){return new Cs(e)}}Cs.errors=As,Cs.levels=Es;const Rs=new Cs("bytes/5.7.0");function Ss(e){return!!e.toHexString}function Ts(e){return e.slice||(e.slice=function(){const t=Array.prototype.slice.call(arguments);return Ts(new Uint8Array(Array.prototype.slice.apply(e,t)))}),e}function Ns(e){return _s(e)&&!(e.length%2)||Os(e)}function Ms(e){return"number"==typeof e&&e==e&&e%1==0}function Os(e){if(null==e)return!1;if(e.constructor===Uint8Array)return!0;if("string"==typeof e)return!1;if(!Ms(e.length)||e.length<0)return!1;for(let t=0;t<e.length;t++){const r=e[t];if(!Ms(r)||r<0||r>=256)return!1}return!0}function Is(e,t){if(t||(t={}),"number"==typeof e){Rs.checkSafeUint53(e,"invalid arrayify value");const t=[];for(;e;)t.unshift(255&e),e=parseInt(String(e/256));return 0===t.length&&t.push(0),Ts(new Uint8Array(t))}if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),Ss(e)&&(e=e.toHexString()),_s(e)){let r=e.substring(2);r.length%2&&("left"===t.hexPad?r="0"+r:"right"===t.hexPad?r+="0":Rs.throwArgumentError("hex data is odd-length","value",e));const n=[];for(let e=0;e<r.length;e+=2)n.push(parseInt(r.substring(e,e+2),16));return Ts(new Uint8Array(n))}return Os(e)?Ts(new Uint8Array(e)):Rs.throwArgumentError("invalid arrayify value","value",e)}function js(e){const t=e.map((e=>Is(e))),r=t.reduce(((e,t)=>e+t.length),0),n=new Uint8Array(r);return t.reduce(((e,t)=>(n.set(t,e),e+t.length)),0),Ts(n)}function Fs(e){let t=Is(e);if(0===t.length)return t;let r=0;for(;r<t.length&&0===t[r];)r++;return r&&(t=t.slice(r)),t}function _s(e,t){return!("string"!=typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&(!t||e.length===2+2*t)}function Ps(e,t){if(t||(t={}),"number"==typeof e){Rs.checkSafeUint53(e,"invalid hexlify value");let t="";for(;e;)t="0123456789abcdef"[15&e]+t,e=Math.floor(e/16);return t.length?(t.length%2&&(t="0"+t),"0x"+t):"0x00"}if("bigint"==typeof e)return(e=e.toString(16)).length%2?"0x0"+e:"0x"+e;if(t.allowMissingPrefix&&"string"==typeof e&&"0x"!==e.substring(0,2)&&(e="0x"+e),Ss(e))return e.toHexString();if(_s(e))return e.length%2&&("left"===t.hexPad?e="0x0"+e.substring(2):"right"===t.hexPad?e+="0":Rs.throwArgumentError("hex data is odd-length","value",e)),e.toLowerCase();if(Os(e)){let t="0x";for(let r=0;r<e.length;r++){let n=e[r];t+="0123456789abcdef"[(240&n)>>4]+"0123456789abcdef"[15&n]}return t}return Rs.throwArgumentError("invalid hexlify value","value",e)}function Bs(e){if("string"!=typeof e)e=Ps(e);else if(!_s(e)||e.length%2)return null;return(e.length-2)/2}function Ws(e,t,r){return"string"!=typeof e?e=Ps(e):(!_s(e)||e.length%2)&&Rs.throwArgumentError("invalid hexData","value",e),t=2+2*t,null!=r?"0x"+e.substring(t,2+2*r):"0x"+e.substring(t)}function Ds(e){let t="0x";return e.forEach((e=>{t+=Ps(e).substring(2)})),t}function Ls(e){const t=function(e){"string"!=typeof e&&(e=Ps(e));_s(e)||Rs.throwArgumentError("invalid hex string","value",e);e=e.substring(2);let t=0;for(;t<e.length&&"0"===e[t];)t++;return"0x"+e.substring(t)}(Ps(e,{hexPad:"left"}));return"0x"===t?"0x0":t}function Us(e,t){for("string"!=typeof e?e=Ps(e):_s(e)||Rs.throwArgumentError("invalid hex string","value",e),e.length>2*t+2&&Rs.throwArgumentError("value out of range","value",arguments[1]);e.length<2*t+2;)e="0x0"+e.substring(2);return e}function Vs(e){const t={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(Ns(e)){let r=Is(e);64===r.length?(t.v=27+(r[32]>>7),r[32]&=127,t.r=Ps(r.slice(0,32)),t.s=Ps(r.slice(32,64))):65===r.length?(t.r=Ps(r.slice(0,32)),t.s=Ps(r.slice(32,64)),t.v=r[64]):Rs.throwArgumentError("invalid signature string","signature",e),t.v<27&&(0===t.v||1===t.v?t.v+=27:Rs.throwArgumentError("signature invalid v byte","signature",e)),t.recoveryParam=1-t.v%2,t.recoveryParam&&(r[32]|=128),t._vs=Ps(r.slice(32,64))}else{if(t.r=e.r,t.s=e.s,t.v=e.v,t.recoveryParam=e.recoveryParam,t._vs=e._vs,null!=t._vs){const r=function(e,t){(e=Is(e)).length>t&&Rs.throwArgumentError("value out of range","value",arguments[0]);const r=new Uint8Array(t);return r.set(e,t-e.length),Ts(r)}(Is(t._vs),32);t._vs=Ps(r);const n=r[0]>=128?1:0;null==t.recoveryParam?t.recoveryParam=n:t.recoveryParam!==n&&Rs.throwArgumentError("signature recoveryParam mismatch _vs","signature",e),r[0]&=127;const o=Ps(r);null==t.s?t.s=o:t.s!==o&&Rs.throwArgumentError("signature v mismatch _vs","signature",e)}if(null==t.recoveryParam)null==t.v?Rs.throwArgumentError("signature missing v and recoveryParam","signature",e):0===t.v||1===t.v?t.recoveryParam=t.v:t.recoveryParam=1-t.v%2;else if(null==t.v)t.v=27+t.recoveryParam;else{const r=0===t.v||1===t.v?t.v:1-t.v%2;t.recoveryParam!==r&&Rs.throwArgumentError("signature recoveryParam mismatch v","signature",e)}null!=t.r&&_s(t.r)?t.r=Us(t.r,32):Rs.throwArgumentError("signature missing or invalid r","signature",e),null!=t.s&&_s(t.s)?t.s=Us(t.s,32):Rs.throwArgumentError("signature missing or invalid s","signature",e);const r=Is(t.s);r[0]>=128&&Rs.throwArgumentError("signature s out of range","signature",e),t.recoveryParam&&(r[0]|=128);const n=Ps(r);t._vs&&(_s(t._vs)||Rs.throwArgumentError("signature invalid _vs","signature",e),t._vs=Us(t._vs,32)),null==t._vs?t._vs=n:t._vs!==n&&Rs.throwArgumentError("signature _vs mismatch v and s","signature",e)}return t.yParityAndS=t._vs,t.compact=t.r+t.yParityAndS.substring(2),t}var Zs={exports:{}};
|
|
38
38
|
/**
|
|
39
39
|
* [js-sha3]{@link https://github.com/emn178/js-sha3}
|
|
40
40
|
*
|
|
@@ -42,4 +42,4 @@ object-assign
|
|
|
42
42
|
* @author Chen, Yi-Cyuan [emn178@gmail.com]
|
|
43
43
|
* @copyright Chen, Yi-Cyuan 2015-2018
|
|
44
44
|
* @license MIT
|
|
45
|
-
*/!function(e){!function(){var t="input is invalid type",r="object"==typeof window,n=r?window:{};n.JS_SHA3_NO_WINDOW&&(r=!1);var o=!r&&"object"==typeof self;!n.JS_SHA3_NO_NODE_JS&&"object"==typeof process&&process.versions&&process.versions.node?n=I:o&&(n=self);var i=!n.JS_SHA3_NO_COMMON_JS&&e.exports,s=!n.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,a="0123456789abcdef".split(""),l=[4,1024,262144,67108864],c=[0,8,16,24],u=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],d=[224,256,384,512],p=[128,256],h=["hex","buffer","arrayBuffer","array","digest"],f={128:168,256:136};!n.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!s||!n.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"==typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var m=function(e,t,r){return function(n){return new M(e,t,e).update(n)[r]()}},g=function(e,t,r){return function(n,o){return new M(e,t,o).update(n)[r]()}},y=function(e,t,r){return function(t,n,o,i){return E["cshake"+e].update(t,n,o,i)[r]()}},b=function(e,t,r){return function(t,n,o,i){return E["kmac"+e].update(t,n,o,i)[r]()}},x=function(e,t,r,n){for(var o=0;o<h.length;++o){var i=h[o];e[i]=t(r,n,i)}return e},v=function(e,t){var r=m(e,t,"hex");return r.create=function(){return new M(e,t,e)},r.update=function(e){return r.create().update(e)},x(r,m,e,t)},w=[{name:"keccak",padding:[1,256,65536,16777216],bits:d,createMethod:v},{name:"sha3",padding:[6,1536,393216,100663296],bits:d,createMethod:v},{name:"shake",padding:[31,7936,2031616,520093696],bits:p,createMethod:function(e,t){var r=g(e,t,"hex");return r.create=function(r){return new M(e,t,r)},r.update=function(e,t){return r.create(t).update(e)},x(r,g,e,t)}},{name:"cshake",padding:l,bits:p,createMethod:function(e,t){var r=f[e],n=y(e,0,"hex");return n.create=function(n,o,i){return o||i?new M(e,t,n).bytepad([o,i],r):E["shake"+e].create(n)},n.update=function(e,t,r,o){return n.create(t,r,o).update(e)},x(n,y,e,t)}},{name:"kmac",padding:l,bits:p,createMethod:function(e,t){var r=f[e],n=b(e,0,"hex");return n.create=function(n,o,i){return new F(e,t,o).bytepad(["KMAC",i],r).bytepad([n],r)},n.update=function(e,t,r,o){return n.create(e,r,o).update(t)},x(n,b,e,t)}}],E={},A=[],C=0;C<w.length;++C)for(var k=w[C],R=k.bits,T=0;T<R.length;++T){var S=k.name+"_"+R[T];if(A.push(S),E[S]=k.createMethod(R[T],k.padding),"sha3"!==k.name){var N=k.name+R[T];A.push(N),E[N]=E[S]}}function M(e,t,r){this.blocks=[],this.s=[],this.padding=t,this.outputBits=r,this.reset=!0,this.finalized=!1,this.block=0,this.start=0,this.blockCount=1600-(e<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function F(e,t,r){M.call(this,e,t,r)}M.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var r,n=typeof e;if("string"!==n){if("object"!==n)throw new Error(t);if(null===e)throw new Error(t);if(s&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||s&&ArrayBuffer.isView(e)))throw new Error(t);r=!0}for(var o,i,a=this.blocks,l=this.byteCount,u=e.length,d=this.blockCount,p=0,h=this.s;p<u;){if(this.reset)for(this.reset=!1,a[0]=this.block,o=1;o<d+1;++o)a[o]=0;if(r)for(o=this.start;p<u&&o<l;++p)a[o>>2]|=e[p]<<c[3&o++];else for(o=this.start;p<u&&o<l;++p)(i=e.charCodeAt(p))<128?a[o>>2]|=i<<c[3&o++]:i<2048?(a[o>>2]|=(192|i>>6)<<c[3&o++],a[o>>2]|=(128|63&i)<<c[3&o++]):i<55296||i>=57344?(a[o>>2]|=(224|i>>12)<<c[3&o++],a[o>>2]|=(128|i>>6&63)<<c[3&o++],a[o>>2]|=(128|63&i)<<c[3&o++]):(i=65536+((1023&i)<<10|1023&e.charCodeAt(++p)),a[o>>2]|=(240|i>>18)<<c[3&o++],a[o>>2]|=(128|i>>12&63)<<c[3&o++],a[o>>2]|=(128|i>>6&63)<<c[3&o++],a[o>>2]|=(128|63&i)<<c[3&o++]);if(this.lastByteIndex=o,o>=l){for(this.start=o-l,this.block=a[d],o=0;o<d;++o)h[o]^=a[o];O(h),this.reset=!0}else this.start=o}return this},M.prototype.encode=function(e,t){var r=255&e,n=1,o=[r];for(r=255&(e>>=8);r>0;)o.unshift(r),r=255&(e>>=8),++n;return t?o.push(n):o.unshift(n),this.update(o),o.length},M.prototype.encodeString=function(e){var r,n=typeof e;if("string"!==n){if("object"!==n)throw new Error(t);if(null===e)throw new Error(t);if(s&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||s&&ArrayBuffer.isView(e)))throw new Error(t);r=!0}var o=0,i=e.length;if(r)o=i;else for(var a=0;a<e.length;++a){var l=e.charCodeAt(a);l<128?o+=1:l<2048?o+=2:l<55296||l>=57344?o+=3:(l=65536+((1023&l)<<10|1023&e.charCodeAt(++a)),o+=4)}return o+=this.encode(8*o),this.update(e),o},M.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n<e.length;++n)r+=this.encodeString(e[n]);var o=t-r%t,i=[];return i.length=o,this.update(i),this},M.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var e=this.blocks,t=this.lastByteIndex,r=this.blockCount,n=this.s;if(e[t>>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t<r+1;++t)e[t]=0;for(e[r-1]|=2147483648,t=0;t<r;++t)n[t]^=e[t];O(n)}},M.prototype.toString=M.prototype.hex=function(){this.finalize();for(var e,t=this.blockCount,r=this.s,n=this.outputBlocks,o=this.extraBytes,i=0,s=0,l="";s<n;){for(i=0;i<t&&s<n;++i,++s)e=r[i],l+=a[e>>4&15]+a[15&e]+a[e>>12&15]+a[e>>8&15]+a[e>>20&15]+a[e>>16&15]+a[e>>28&15]+a[e>>24&15];s%t==0&&(O(r),i=0)}return o&&(e=r[i],l+=a[e>>4&15]+a[15&e],o>1&&(l+=a[e>>12&15]+a[e>>8&15]),o>2&&(l+=a[e>>20&15]+a[e>>16&15])),l},M.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,o=this.extraBytes,i=0,s=0,a=this.outputBits>>3;e=o?new ArrayBuffer(n+1<<2):new ArrayBuffer(a);for(var l=new Uint32Array(e);s<n;){for(i=0;i<t&&s<n;++i,++s)l[s]=r[i];s%t==0&&O(r)}return o&&(l[i]=r[i],e=e.slice(0,a)),e},M.prototype.buffer=M.prototype.arrayBuffer,M.prototype.digest=M.prototype.array=function(){this.finalize();for(var e,t,r=this.blockCount,n=this.s,o=this.outputBlocks,i=this.extraBytes,s=0,a=0,l=[];a<o;){for(s=0;s<r&&a<o;++s,++a)e=a<<2,t=n[s],l[e]=255&t,l[e+1]=t>>8&255,l[e+2]=t>>16&255,l[e+3]=t>>24&255;a%r==0&&O(n)}return i&&(e=a<<2,t=n[s],l[e]=255&t,i>1&&(l[e+1]=t>>8&255),i>2&&(l[e+2]=t>>16&255)),l},F.prototype=new M,F.prototype.finalize=function(){return this.encode(this.outputBits,!0),M.prototype.finalize.call(this)};var O=function(e){var t,r,n,o,i,s,a,l,c,d,p,h,f,m,g,y,b,x,v,w,E,A,C,k,R,T,S,N,M,F,O,I,j,D,B,P,W,_,U,L,V,Z,H,z,Y,G,X,J,q,Q,K,$,ee,te,re,ne,oe,ie,se,ae,le,ce,ue;for(n=0;n<48;n+=2)o=e[0]^e[10]^e[20]^e[30]^e[40],i=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],a=e[3]^e[13]^e[23]^e[33]^e[43],l=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],d=e[6]^e[16]^e[26]^e[36]^e[46],p=e[7]^e[17]^e[27]^e[37]^e[47],t=(h=e[8]^e[18]^e[28]^e[38]^e[48])^(s<<1|a>>>31),r=(f=e[9]^e[19]^e[29]^e[39]^e[49])^(a<<1|s>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=o^(l<<1|c>>>31),r=i^(c<<1|l>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=s^(d<<1|p>>>31),r=a^(p<<1|d>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=l^(h<<1|f>>>31),r=c^(f<<1|h>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=d^(o<<1|i>>>31),r=p^(i<<1|o>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],g=e[1],G=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,N=e[20]<<3|e[21]>>>29,M=e[21]<<3|e[20]>>>29,ae=e[31]<<9|e[30]>>>23,le=e[30]<<9|e[31]>>>23,Z=e[40]<<18|e[41]>>>14,H=e[41]<<18|e[40]>>>14,D=e[2]<<1|e[3]>>>31,B=e[3]<<1|e[2]>>>31,y=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,J=e[22]<<10|e[23]>>>22,q=e[23]<<10|e[22]>>>22,F=e[33]<<13|e[32]>>>19,O=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,ue=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,P=e[14]<<6|e[15]>>>26,W=e[15]<<6|e[14]>>>26,x=e[25]<<11|e[24]>>>21,v=e[24]<<11|e[25]>>>21,Q=e[34]<<15|e[35]>>>17,K=e[35]<<15|e[34]>>>17,I=e[45]<<29|e[44]>>>3,j=e[44]<<29|e[45]>>>3,k=e[6]<<28|e[7]>>>4,R=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,oe=e[16]<<23|e[17]>>>9,_=e[26]<<25|e[27]>>>7,U=e[27]<<25|e[26]>>>7,w=e[36]<<21|e[37]>>>11,E=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,z=e[8]<<27|e[9]>>>5,Y=e[9]<<27|e[8]>>>5,T=e[18]<<20|e[19]>>>12,S=e[19]<<20|e[18]>>>12,ie=e[29]<<7|e[28]>>>25,se=e[28]<<7|e[29]>>>25,L=e[38]<<8|e[39]>>>24,V=e[39]<<8|e[38]>>>24,A=e[48]<<14|e[49]>>>18,C=e[49]<<14|e[48]>>>18,e[0]=m^~y&x,e[1]=g^~b&v,e[10]=k^~T&N,e[11]=R^~S&M,e[20]=D^~P&_,e[21]=B^~W&U,e[30]=z^~G&J,e[31]=Y^~X&q,e[40]=te^~ne&ie,e[41]=re^~oe&se,e[2]=y^~x&w,e[3]=b^~v&E,e[12]=T^~N&F,e[13]=S^~M&O,e[22]=P^~_&L,e[23]=W^~U&V,e[32]=G^~J&Q,e[33]=X^~q&K,e[42]=ne^~ie&ae,e[43]=oe^~se&le,e[4]=x^~w&A,e[5]=v^~E&C,e[14]=N^~F&I,e[15]=M^~O&j,e[24]=_^~L&Z,e[25]=U^~V&H,e[34]=J^~Q&$,e[35]=q^~K&ee,e[44]=ie^~ae&ce,e[45]=se^~le&ue,e[6]=w^~A&m,e[7]=E^~C&g,e[16]=F^~I&k,e[17]=O^~j&R,e[26]=L^~Z&D,e[27]=V^~H&B,e[36]=Q^~$&z,e[37]=K^~ee&Y,e[46]=ae^~ce&te,e[47]=le^~ue&re,e[8]=A^~m&y,e[9]=C^~g&b,e[18]=I^~k&T,e[19]=j^~R&S,e[28]=Z^~D&P,e[29]=H^~B&W,e[38]=$^~z&G,e[39]=ee^~Y&X,e[48]=ce^~te&ne,e[49]=ue^~re&oe,e[0]^=u[n],e[1]^=u[n+1]};if(i)e.exports=E;else for(C=0;C<A.length;++C)n[A[C]]=E[A[C]]}()}(Zs);var Hs=Zs.exports;function zs(e){return"0x"+Hs.keccak_256(Os(e))}const Ys=new ks("rlp/5.7.0");function Gs(e){const t=[];for(;e;)t.unshift(255&e),e>>=8;return t}function Xs(e,t,r){let n=0;for(let o=0;o<r;o++)n=256*n+e[t+o];return n}function Js(e){if(Array.isArray(e)){let t=[];if(e.forEach((function(e){t=t.concat(Js(e))})),t.length<=55)return t.unshift(192+t.length),t;const r=Gs(t.length);return r.unshift(247+r.length),r.concat(t)}Ns(e)||Ys.throwArgumentError("RLP object must be BytesLike","object",e);const t=Array.prototype.slice.call(Os(e));if(1===t.length&&t[0]<=127)return t;if(t.length<=55)return t.unshift(128+t.length),t;const r=Gs(t.length);return r.unshift(183+r.length),r.concat(t)}function qs(e){return Bs(Js(e))}function Qs(e,t,r,n){const o=[];for(;r<t+1+n;){const i=Ks(e,r);o.push(i.result),(r+=i.consumed)>t+1+n&&Ys.throwError("child data too short",ks.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:o}}function Ks(e,t){if(0===e.length&&Ys.throwError("data too short",ks.errors.BUFFER_OVERRUN,{}),e[t]>=248){const r=e[t]-247;t+1+r>e.length&&Ys.throwError("data short segment too short",ks.errors.BUFFER_OVERRUN,{});const n=Xs(e,t+1,r);return t+1+r+n>e.length&&Ys.throwError("data long segment too short",ks.errors.BUFFER_OVERRUN,{}),Qs(e,t,t+1+r,r+n)}if(e[t]>=192){const r=e[t]-192;return t+1+r>e.length&&Ys.throwError("data array too short",ks.errors.BUFFER_OVERRUN,{}),Qs(e,t,t+1,r)}if(e[t]>=184){const r=e[t]-183;t+1+r>e.length&&Ys.throwError("data array too short",ks.errors.BUFFER_OVERRUN,{});const n=Xs(e,t+1,r);t+1+r+n>e.length&&Ys.throwError("data array too short",ks.errors.BUFFER_OVERRUN,{});return{consumed:1+r+n,result:Bs(e.slice(t+1+r,t+1+r+n))}}if(e[t]>=128){const r=e[t]-128;t+1+r>e.length&&Ys.throwError("data too short",ks.errors.BUFFER_OVERRUN,{});return{consumed:1+r,result:Bs(e.slice(t+1,t+1+r))}}return{consumed:1,result:Bs(e[t])}}function $s(e){const t=Os(e),r=Ks(t,0);return r.consumed!==t.length&&Ys.throwArgumentError("invalid rlp data","data",e),r.result}const ea=new ks("address/5.7.0");function ta(e){Ds(e,20)||ea.throwArgumentError("invalid address","address",e);const t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40);for(let e=0;e<40;e++)r[e]=t[e].charCodeAt(0);const n=Os(zs(r));for(let e=0;e<40;e+=2)n[e>>1]>>4>=8&&(t[e]=t[e].toUpperCase()),(15&n[e>>1])>=8&&(t[e+1]=t[e+1].toUpperCase());return"0x"+t.join("")}const ra={};for(let e=0;e<10;e++)ra[String(e)]=String(e);for(let e=0;e<26;e++)ra[String.fromCharCode(65+e)]=String(10+e);const na=Math.floor(function(e){return Math.log10?Math.log10(e):Math.log(e)/Math.LN10}(9007199254740991));function oa(e){let t=null;if("string"!=typeof e&&ea.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=ta(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&ea.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==function(e){let t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((e=>ra[e])).join("");for(;t.length>=na;){let e=t.substring(0,na);t=parseInt(e,10)%97+t.substring(e.length)}let r=String(98-parseInt(t,10)%97);for(;r.length<2;)r="0"+r;return r}(e)&&ea.throwArgumentError("bad icap checksum","address",e),t=y._base36To16(e.substring(4));t.length<40;)t="0"+t;t=ta("0x"+t)}else ea.throwArgumentError("invalid address","address",e);return t}var ia;!function(e){e[e.MAINNET=1]="MAINNET",e[e.GOERLI=5]="GOERLI",e[e.BSC=56]="BSC",e[e.POLYGON=137]="POLYGON",e[e.ARBITRUM_ONE=42161]="ARBITRUM_ONE",e[e.AURORA=1313161554]="AURORA",e[e.OKCHAIN=66]="OKCHAIN",e[e.OPTIMISM=10]="OPTIMISM",e[e.AVALANCHE=43114]="AVALANCHE",e[e.CONFLUX=1030]="CONFLUX"}(ia||(ia={}));const sa={[ia.MAINNET]:["https://rpc.ankr.com/eth","https://eth-mainnet.public.blastapi.io","https://eth-rpc.gateway.pokt.network","https://main-rpc.linkpool.io"],[ia.GOERLI]:["https://goerli.optimism.io/"],[ia.BSC]:["https://bsc-dataseed1.binance.org","https://bsc-dataseed2.binance.org","https://bsc-dataseed3.binance.org","https://bsc-dataseed4.binance.org","https://bsc-dataseed1.defibit.io","https://bsc-dataseed2.defibit.io","https://bsc-dataseed3.defibit.io","https://bsc-dataseed4.defibit.io","https://bsc-dataseed1.ninicoin.io","https://bsc-dataseed2.ninicoin.io","https://bsc-dataseed3.ninicoin.io","https://bsc-dataseed4.ninicoin.io","https://bsc-dataseed.binance.org","https://rpc.ankr.com/bsc","https://bscrpc.com","https://bsc.mytokenpocket.vip","https://binance.nodereal.io","https://rpc-bsc.bnb48.club"],[ia.POLYGON]:["https://polygon-rpc.com","https://rpc-mainnet.matic.network","https://matic-mainnet.chainstacklabs.com","https://rpc-mainnet.maticvigil.com","https://rpc-mainnet.matic.quiknode.pro","https://matic-mainnet-full-rpc.bwarelabs.com","https://matic-mainnet-archive-rpc.bwarelabs.com","https://poly-rpc.gateway.pokt.network","https://rpc.ankr.com/polygon","https://polygon-mainnet.public.blastapi.io"],[ia.ARBITRUM_ONE]:["https://arb1.arbitrum.io/rpc","https://rpc.ankr.com/arbitrum"],[ia.AURORA]:["https://mainnet.aurora.dev/"],[ia.OKCHAIN]:["https://exchainrpc.okex.org","https://okc-mainnet.gateway.pokt.network/v1/lb/6275309bea1b320039c893ff"],[ia.OPTIMISM]:["https://mainnet.optimism.io","https://optimism-mainnet.public.blastapi.io"],[ia.AVALANCHE]:["https://api.avax.network/ext/bc/C/rpc","https://rpc.ankr.com/avalanche","https://ava-mainnet.public.blastapi.io/ext/bc/C/rpc"],[ia.CONFLUX]:["https://evm.confluxrpc.com","https://conflux-espace-public.unifra.io"]},aa={symbol:"ETH",address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ether",decimals:18,showDecimals:4,wrappedTokenSymbol:"WETH"},la={[ia.MAINNET]:Object.assign(Object.assign({},aa),{wrappedTokenAddress:"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2"}),[ia.GOERLI]:Object.assign(Object.assign({},aa),{wrappedTokenAddress:"0xB4FBF271143F4FBf7B91A5ded31805e42b2208d6"}),[ia.OPTIMISM]:Object.assign(Object.assign({},aa),{wrappedTokenAddress:"0x4200000000000000000000000000000000000006"}),[ia.CONFLUX]:Object.assign(Object.assign({},aa),{symbol:"CFX",name:"CFX",wrappedTokenSymbol:"WCFX",wrappedTokenAddress:"0x14b2d3bc65e74dae1030eafd8ac30c533c976a9b"}),[ia.BSC]:Object.assign(Object.assign({},aa),{symbol:"BNB",name:"BNB",wrappedTokenSymbol:"WBNB",wrappedTokenAddress:"0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c"}),[ia.OKCHAIN]:Object.assign(Object.assign({},aa),{symbol:"OKT",name:"OKT",wrappedTokenSymbol:"WOKT",wrappedTokenAddress:"0x8F8526dbfd6E38E3D8307702cA8469Bae6C56C15"}),[ia.POLYGON]:Object.assign(Object.assign({},aa),{symbol:"MATIC",name:"MATIC",showDecimals:6,wrappedTokenSymbol:"WMATIC",wrappedTokenAddress:"0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270"}),[ia.ARBITRUM_ONE]:Object.assign(Object.assign({},aa),{name:"Ethereum",showDecimals:6,wrappedTokenAddress:"0x82aF49447D8a07e3bd95BD0d56f35241523fBab1"}),[ia.AURORA]:Object.assign(Object.assign({},aa),{name:"Ethereum",showDecimals:6,wrappedTokenAddress:"0xC9BdeEd33CD01541e1eeD10f90519d2C06Fe3feB"}),[ia.AVALANCHE]:Object.assign(Object.assign({},aa),{symbol:"AVAX",name:"Avalanche",showDecimals:6,wrappedTokenSymbol:"WAVAX",wrappedTokenAddress:"0xB31f66AA3C1e785363F0875A1B74E27b85FD66c7"})},ca={[ia.MAINNET]:"ethereum",[ia.GOERLI]:"goerli",[ia.OPTIMISM]:"optimism",[ia.CONFLUX]:"cfx",[ia.BSC]:"bsc",[ia.OKCHAIN]:"okex-chain",[ia.POLYGON]:"polygon",[ia.ARBITRUM_ONE]:"arbitrum",[ia.AURORA]:"aurora",[ia.AVALANCHE]:"avalanche"},ua={[ia.MAINNET]:"etherscan.io",[ia.GOERLI]:"goerli.etherscan.io",[ia.OPTIMISM]:"optimistic.etherscan.io",[ia.CONFLUX]:"snowtrace.io",[ia.BSC]:"bscscan.com",[ia.OKCHAIN]:"www.oklink.com/okexchain",[ia.POLYGON]:"polygonscan.com",[ia.ARBITRUM_ONE]:"arbiscan.io",[ia.AURORA]:"aurorascan.dev",[ia.AVALANCHE]:"snowtrace.io"},da=(e,t)=>{if(0===e.length||0===t.length)return!1;if(t.length===e.length)return e.toLowerCase()===t.toLowerCase();const r=e.substring(2,e.length).toLowerCase(),n=t.substring(2,t.length).toLowerCase();return r.length>n.length?r.endsWith(n):n.endsWith(r)};function pa(e,t){return`https://${ua[t||1]}${e?`/${e}`:""}`}const ha=e=>{const t={isMainnet:1===e,isRinkeby:4===e,isGor:5===e};return Object.assign(Object.assign({},t),{isETH:t.isMainnet||t.isRinkeby||t.isGor})};function fa(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}function ma(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))}const ga=(e,t)=>r=>ma(void 0,void 0,void 0,(function*(){r({type:"SET_ETH_BALANCE",payload:{[e]:t}})})),ya=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_ACCOUNT_BALANCES",payload:e})})),ba=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_BALANCE_LOADINGS",payload:e})}));var xa=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const va=new ks("properties/5.7.0");function wa(e,t,r){Object.defineProperty(e,t,{enumerable:!0,value:r,writable:!1})}function Ea(e,t){for(let r=0;r<32;r++){if(e[t])return e[t];if(!e.prototype||"object"!=typeof e.prototype)break;e=Object.getPrototypeOf(e.prototype).constructor}return null}function Aa(e){return xa(this,void 0,void 0,(function*(){const t=Object.keys(e).map((t=>{const r=e[t];return Promise.resolve(r).then((e=>({key:t,value:e})))}));return(yield Promise.all(t)).reduce(((e,t)=>(e[t.key]=t.value,e)),{})}))}function Ca(e){const t={};for(const r in e)t[r]=e[r];return t}const ka={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function Ra(e){if(null==e||ka[typeof e])return!0;if(Array.isArray(e)||"object"==typeof e){if(!Object.isFrozen(e))return!1;const t=Object.keys(e);for(let r=0;r<t.length;r++){let n=null;try{n=e[t[r]]}catch(e){continue}if(!Ra(n))return!1}return!0}return va.throwArgumentError("Cannot deepCopy "+typeof e,"object",e)}function Ta(e){if(Ra(e))return e;if(Array.isArray(e))return Object.freeze(e.map((e=>Sa(e))));if("object"==typeof e){const t={};for(const r in e){const n=e[r];void 0!==n&&wa(t,r,Sa(n))}return t}return va.throwArgumentError("Cannot deepCopy "+typeof e,"object",e)}function Sa(e){return Ta(e)}class Na{constructor(e){for(const t in e)this[t]=Sa(e[t])}}var Ma=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Fa=new ks("abstract-provider/5.7.0");class Oa extends Na{static isForkEvent(e){return!(!e||!e._isForkEvent)}}class Ia{constructor(){Fa.checkAbstract(new.target,Ia),wa(this,"_isProvider",!0)}getFeeData(){return Ma(this,void 0,void 0,(function*(){const{block:e,gasPrice:t}=yield Aa({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch((e=>null))});let r=null,n=null,o=null;return e&&e.baseFeePerGas&&(r=e.baseFeePerGas,o=y.BigNumber.from("1500000000"),n=e.baseFeePerGas.mul(2).add(o)),{lastBaseFeePerGas:r,maxFeePerGas:n,maxPriorityFeePerGas:o,gasPrice:t}}))}addListener(e,t){return this.on(e,t)}removeListener(e,t){return this.off(e,t)}static isProvider(e){return!(!e||!e._isProvider)}}const ja=new ks("networks/5.7.1");function Da(e){const t=function(t,r){null==r&&(r={});const n=[];if(t.InfuraProvider&&"-"!==r.infura)try{n.push(new t.InfuraProvider(e,r.infura))}catch(e){}if(t.EtherscanProvider&&"-"!==r.etherscan)try{n.push(new t.EtherscanProvider(e,r.etherscan))}catch(e){}if(t.AlchemyProvider&&"-"!==r.alchemy)try{n.push(new t.AlchemyProvider(e,r.alchemy))}catch(e){}if(t.PocketProvider&&"-"!==r.pocket){const o=["goerli","ropsten","rinkeby","sepolia"];try{const i=new t.PocketProvider(e,r.pocket);i.network&&-1===o.indexOf(i.network.name)&&n.push(i)}catch(e){}}if(t.CloudflareProvider&&"-"!==r.cloudflare)try{n.push(new t.CloudflareProvider(e))}catch(e){}if(t.AnkrProvider&&"-"!==r.ankr)try{const o=["ropsten"],i=new t.AnkrProvider(e,r.ankr);i.network&&-1===o.indexOf(i.network.name)&&n.push(i)}catch(e){}if(0===n.length)return null;if(t.FallbackProvider){let o=1;return null!=r.quorum?o=r.quorum:"homestead"===e&&(o=2),new t.FallbackProvider(n,o)}return n[0]};return t.renetwork=function(e){return Da(e)},t}function Ba(e,t){const r=function(r,n){return r.JsonRpcProvider?new r.JsonRpcProvider(e,t):null};return r.renetwork=function(t){return Ba(e,t)},r}const Pa={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:Da("homestead")},Wa={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:Da("ropsten")},_a={chainId:63,name:"classicMordor",_defaultProvider:Ba("https://www.ethercluster.com/mordor","classicMordor")},Ua={unspecified:{chainId:0,name:"unspecified"},homestead:Pa,mainnet:Pa,morden:{chainId:2,name:"morden"},ropsten:Wa,testnet:Wa,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:Da("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:Da("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:Da("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:Da("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Ba("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:_a,classicTestnet:_a,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Ba("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:Da("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:Da("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function La(e){e=atob(e);const t=[];for(let r=0;r<e.length;r++)t.push(e.charCodeAt(r));return Os(t)}function Va(e){e=Os(e);let t="";for(let r=0;r<e.length;r++)t+=String.fromCharCode(e[r]);return btoa(t)}class Za{constructor(e){wa(this,"alphabet",e),wa(this,"base",e.length),wa(this,"_alphabetMap",{}),wa(this,"_leader",e.charAt(0));for(let t=0;t<e.length;t++)this._alphabetMap[e.charAt(t)]=t}encode(e){let t=Os(e);if(0===t.length)return"";let r=[0];for(let e=0;e<t.length;++e){let n=t[e];for(let e=0;e<r.length;++e)n+=r[e]<<8,r[e]=n%this.base,n=n/this.base|0;for(;n>0;)r.push(n%this.base),n=n/this.base|0}let n="";for(let e=0;0===t[e]&&e<t.length-1;++e)n+=this._leader;for(let e=r.length-1;e>=0;--e)n+=this.alphabet[r[e]];return n}decode(e){if("string"!=typeof e)throw new TypeError("Expected String");let t=[];if(0===e.length)return new Uint8Array(t);t.push(0);for(let r=0;r<e.length;r++){let n=this._alphabetMap[e[r]];if(void 0===n)throw new Error("Non-base"+this.base+" character");let o=n;for(let e=0;e<t.length;++e)o+=t[e]*this.base,t[e]=255&o,o>>=8;for(;o>0;)t.push(255&o),o>>=8}for(let r=0;e[r]===this._leader&&r<e.length-1;++r)t.push(0);return Os(new Uint8Array(t.reverse()))}}new Za("abcdefghijklmnopqrstuvwxyz234567");const Ha=new Za("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),za="0x0000000000000000000000000000000000000000",Ya=y.BigNumber.from(-1),Ga=y.BigNumber.from(0),Xa=y.BigNumber.from(1),Ja=y.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),qa=new ks("strings/5.7.0");var Qa,Ka;function $a(e,t,r,n,o){if(e===Ka.BAD_PREFIX||e===Ka.UNEXPECTED_CONTINUE){let e=0;for(let n=t+1;n<r.length&&r[n]>>6==2;n++)e++;return e}return e===Ka.OVERRUN?r.length-t-1:0}!function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(Qa||(Qa={})),function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(Ka||(Ka={}));const el=Object.freeze({error:function(e,t,r,n,o){return qa.throwArgumentError(`invalid codepoint at offset ${t}; ${e}`,"bytes",r)},ignore:$a,replace:function(e,t,r,n,o){return e===Ka.OVERLONG?(n.push(o),0):(n.push(65533),$a(e,t,r))}});function tl(e,t){null==t&&(t=el.error),e=Os(e);const r=[];let n=0;for(;n<e.length;){const o=e[n++];if(o>>7==0){r.push(o);continue}let i=null,s=null;if(192==(224&o))i=1,s=127;else if(224==(240&o))i=2,s=2047;else{if(240!=(248&o)){n+=t(128==(192&o)?Ka.UNEXPECTED_CONTINUE:Ka.BAD_PREFIX,n-1,e,r);continue}i=3,s=65535}if(n-1+i>=e.length){n+=t(Ka.OVERRUN,n-1,e,r);continue}let a=o&(1<<8-i-1)-1;for(let o=0;o<i;o++){let o=e[n];if(128!=(192&o)){n+=t(Ka.MISSING_CONTINUE,n,e,r),a=null;break}a=a<<6|63&o,n++}null!==a&&(a>1114111?n+=t(Ka.OUT_OF_RANGE,n-1-i,e,r,a):a>=55296&&a<=57343?n+=t(Ka.UTF16_SURROGATE,n-1-i,e,r,a):a<=s?n+=t(Ka.OVERLONG,n-1-i,e,r,a):r.push(a))}return r}function rl(e,t=Qa.current){t!=Qa.current&&(qa.checkNormalize(),e=e.normalize(t));let r=[];for(let t=0;t<e.length;t++){const n=e.charCodeAt(t);if(n<128)r.push(n);else if(n<2048)r.push(n>>6|192),r.push(63&n|128);else if(55296==(64512&n)){t++;const o=e.charCodeAt(t);if(t>=e.length||56320!=(64512&o))throw new Error("invalid utf-8 string");const i=65536+((1023&n)<<10)+(1023&o);r.push(i>>18|240),r.push(i>>12&63|128),r.push(i>>6&63|128),r.push(63&i|128)}else r.push(n>>12|224),r.push(n>>6&63|128),r.push(63&n|128)}return Os(r)}function nl(e,t){return tl(e,t).map((e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e))))).join("")}function ol(e){return zs(rl(e))}function il(e,t){null==t&&(t=1);const r=[],n=r.forEach,o=function(e,t){n.call(e,(function(e){t>0&&Array.isArray(e)?o(e,t-1):r.push(e)}))};return o(e,t),r}function sl(e){return function(e){let t=0;return()=>e[t++]}(function(e){let t=0;function r(){return e[t++]<<8|e[t++]}let n=r(),o=1,i=[0,1];for(let e=1;e<n;e++)i.push(o+=r());let s=r(),a=t;t+=s;let l=0,c=0;function u(){return 0==l&&(c=c<<8|e[t++],l=8),c>>--l&1}const d=Math.pow(2,31),p=d>>>1,h=p>>1,f=d-1;let m=0;for(let e=0;e<31;e++)m=m<<1|u();let g=[],y=0,b=d;for(;;){let e=Math.floor(((m-y+1)*o-1)/b),t=0,r=n;for(;r-t>1;){let n=t+r>>>1;e<i[n]?r=n:t=n}if(0==t)break;g.push(t);let s=y+Math.floor(b*i[t]/o),a=y+Math.floor(b*i[t+1]/o)-1;for(;0==((s^a)&p);)m=m<<1&f|u(),s=s<<1&f,a=a<<1&f|1;for(;s&~a&h;)m=m&p|m<<1&f>>>1|u(),s=s<<1^p,a=(a^p)<<1|p|1;y=s,b=1+a-s}let x=n-4;return g.map((t=>{switch(t-x){case 3:return x+65792+(e[a++]<<16|e[a++]<<8|e[a++]);case 2:return x+256+(e[a++]<<8|e[a++]);case 1:return x+e[a++];default:return t-1}}))}(e))}function al(e){return 1&e?~e>>1:e>>1}function ll(e,t){let r=Array(e);for(let n=0,o=-1;n<e;n++)r[n]=o+=1+t();return r}function cl(e,t){let r=Array(e);for(let n=0,o=0;n<e;n++)r[n]=o+=al(t());return r}function ul(e,t){let r=ll(e(),e),n=e(),o=ll(n,e),i=function(e,t){let r=Array(e);for(let n=0;n<e;n++)r[n]=1+t();return r}(n,e);for(let e=0;e<n;e++)for(let t=0;t<i[e];t++)r.push(o[e]+t);return t?r.map((e=>t[e])):r}function dl(e,t,r){let n=Array(e).fill(void 0).map((()=>[]));for(let o=0;o<t;o++)cl(e,r).forEach(((e,t)=>n[t].push(e)));return n}function pl(e,t){let r=1+t(),n=t(),o=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(r)}return t}(t);return il(dl(o.length,1+e,t).map(((e,t)=>{const i=e[0],s=e.slice(1);return Array(o[t]).fill(void 0).map(((e,t)=>{let o=t*n;return[i+t*r,s.map((e=>e+o))]}))})))}function hl(e,t){return dl(1+t(),1+e,t).map((e=>[e[0],e.slice(1)]))}const fl=sl(La("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA==")),ml=new Set(ul(fl)),gl=new Set(ul(fl)),yl=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(pl(r,e))}for(;;){let r=e()-1;if(r<0)break;t.push(hl(r,e))}return function(e){const t={};for(let r=0;r<e.length;r++){const n=e[r];t[n[0]]=n[1]}return t}(il(t))}(fl),bl=function(e){let t=ul(e).sort(((e,t)=>e-t));return function r(){let n=[];for(;;){let o=ul(e,t);if(0==o.length)break;n.push({set:new Set(o),node:r()})}n.sort(((e,t)=>t.set.size-e.set.size));let o=e(),i=o%3;o=o/3|0;let s=!!(1&o);return o>>=1,{branches:n,valid:i,fe0f:s,save:1==o,check:2==o}}()}(fl);function xl(e){return function(e,t=Qa.current){return tl(rl(e,t))}(e)}function vl(e){return e.filter((e=>65039!=e))}function wl(e){for(let t of e.split(".")){let e=xl(t);try{for(let t=e.lastIndexOf(95)-1;t>=0;t--)if(95!==e[t])throw new Error("underscore only allowed at start");if(e.length>=4&&e.every((e=>e<128))&&45===e[2]&&45===e[3])throw new Error("invalid label extension")}catch(e){throw new Error(`Invalid label "${t}": ${e.message}`)}}return e}function El(e){return wl(function(e,t){let r=xl(e).reverse(),n=[];for(;r.length;){let e=Al(r);if(e){n.push(...t(e));continue}let o=r.pop();if(ml.has(o)){n.push(o);continue}if(gl.has(o))continue;let i=yl[o];if(!i)throw new Error(`Disallowed codepoint: 0x${o.toString(16).toUpperCase()}`);n.push(...i)}return wl(function(e){return e.normalize("NFC")}(String.fromCodePoint(...n)))}(e,vl))}function Al(e,t){var r;let n,o,i=bl,s=[],a=e.length;for(t&&(t.length=0);a;){let l=e[--a];if(i=null===(r=i.branches.find((e=>e.set.has(l))))||void 0===r?void 0:r.node,!i)break;if(i.save)o=l;else if(i.check&&l===o)break;s.push(l),i.fe0f&&(s.push(65039),a>0&&65039==e[a-1]&&a--),i.valid&&(n=s.slice(),2==i.valid&&n.splice(1,1),t&&t.push(...e.slice(a).reverse()),e.length=a)}return n}const Cl=new ks("hash/5.7.0"),kl=new Uint8Array(32);function Rl(e){if(0===e.length)throw new Error("invalid ENS name; empty component");return e}function Tl(e){const t=rl(El(e)),r=[];if(0===e.length)return r;let n=0;for(let e=0;e<t.length;e++){46===t[e]&&(r.push(Rl(t.slice(n,e))),n=e+1)}if(n>=t.length)throw new Error("invalid ENS name; empty component");return r.push(Rl(t.slice(n))),r}function Sl(e){"string"!=typeof e&&Cl.throwArgumentError("invalid ENS name; not a string","name",e);let t=kl;const r=Tl(e);for(;r.length;)t=zs(Is([t,zs(r.pop())]));return Bs(t)}kl.fill(0);var Nl=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Ml=new ks("hash/5.7.0"),Fl=new Uint8Array(32);Fl.fill(0);const Ol=y.BigNumber.from(-1),Il=y.BigNumber.from(0),jl=y.BigNumber.from(1),Dl=y.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");const Bl=Ls(jl.toHexString(),32),Pl=Ls(Il.toHexString(),32),Wl={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},_l=["name","version","chainId","verifyingContract","salt"];function Ul(e){return function(t){return"string"!=typeof t&&Ml.throwArgumentError(`invalid domain value for ${JSON.stringify(e)}`,`domain.${e}`,t),t}}const Ll={name:Ul("name"),version:Ul("version"),chainId:function(e){try{return y.BigNumber.from(e).toString()}catch(e){}return Ml.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",e)},verifyingContract:function(e){try{return oa(e).toLowerCase()}catch(e){}return Ml.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){try{const t=Os(e);if(32!==t.length)throw new Error("bad length");return Bs(t)}catch(e){}return Ml.throwArgumentError('invalid domain value "salt"',"domain.salt",e)}};function Vl(e){{const t=e.match(/^(u?)int(\d*)$/);if(t){const r=""===t[1],n=parseInt(t[2]||"256");(n%8!=0||n>256||t[2]&&t[2]!==String(n))&&Ml.throwArgumentError("invalid numeric width","type",e);const o=Dl.mask(r?n-1:n),i=r?o.add(jl).mul(Ol):Il;return function(t){const r=y.BigNumber.from(t);return(r.lt(i)||r.gt(o))&&Ml.throwArgumentError(`value out-of-bounds for ${e}`,"value",t),Ls(r.toTwos(256).toHexString(),32)}}}{const t=e.match(/^bytes(\d+)$/);if(t){const r=parseInt(t[1]);return(0===r||r>32||t[1]!==String(r))&&Ml.throwArgumentError("invalid bytes width","type",e),function(t){return Os(t).length!==r&&Ml.throwArgumentError(`invalid length for ${e}`,"value",t),function(e){const t=Os(e),r=t.length%32;return r?_s([t,Fl.slice(r)]):Bs(t)}(t)}}}switch(e){case"address":return function(e){return Ls(oa(e),32)};case"bool":return function(e){return e?Bl:Pl};case"bytes":return function(e){return zs(e)};case"string":return function(e){return ol(e)}}return null}function Zl(e,t){return`${e}(${t.map((({name:e,type:t})=>t+" "+e)).join(",")})`}class Hl{constructor(e){wa(this,"types",Object.freeze(Sa(e))),wa(this,"_encoderCache",{}),wa(this,"_types",{});const t={},r={},n={};Object.keys(e).forEach((e=>{t[e]={},r[e]=[],n[e]={}}));for(const n in e){const o={};e[n].forEach((i=>{o[i.name]&&Ml.throwArgumentError(`duplicate variable name ${JSON.stringify(i.name)} in ${JSON.stringify(n)}`,"types",e),o[i.name]=!0;const s=i.type.match(/^([^\x5b]*)(\x5b|$)/)[1];s===n&&Ml.throwArgumentError(`circular type reference to ${JSON.stringify(s)}`,"types",e);Vl(s)||(r[s]||Ml.throwArgumentError(`unknown type ${JSON.stringify(s)}`,"types",e),r[s].push(n),t[n][s]=!0)}))}const o=Object.keys(r).filter((e=>0===r[e].length));0===o.length?Ml.throwArgumentError("missing primary type","types",e):o.length>1&&Ml.throwArgumentError(`ambiguous primary types or unused types: ${o.map((e=>JSON.stringify(e))).join(", ")}`,"types",e),wa(this,"primaryType",o[0]),function o(i,s){s[i]&&Ml.throwArgumentError(`circular type reference to ${JSON.stringify(i)}`,"types",e),s[i]=!0,Object.keys(t[i]).forEach((e=>{r[e]&&(o(e,s),Object.keys(s).forEach((t=>{n[t][e]=!0})))})),delete s[i]}(this.primaryType,{});for(const t in n){const r=Object.keys(n[t]);r.sort(),this._types[t]=Zl(t,e[t])+r.map((t=>Zl(t,e[t]))).join("")}}getEncoder(e){let t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}_getEncoder(e){{const t=Vl(e);if(t)return t}const t=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(t){const e=t[1],r=this.getEncoder(e),n=parseInt(t[3]);return t=>{n>=0&&t.length!==n&&Ml.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t);let o=t.map(r);return this._types[e]&&(o=o.map(zs)),zs(_s(o))}}const r=this.types[e];if(r){const t=ol(this._types[e]);return e=>{const n=r.map((({name:t,type:r})=>{const n=this.getEncoder(r)(e[t]);return this._types[r]?zs(n):n}));return n.unshift(t),_s(n)}}return Ml.throwArgumentError(`unknown type: ${e}`,"type",e)}encodeType(e){const t=this._types[e];return t||Ml.throwArgumentError(`unknown type: ${JSON.stringify(e)}`,"name",e),t}encodeData(e,t){return this.getEncoder(e)(t)}hashStruct(e,t){return zs(this.encodeData(e,t))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,t,r){if(Vl(e))return r(e,t);const n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){const e=n[1],o=parseInt(n[3]);return o>=0&&t.length!==o&&Ml.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((t=>this._visit(e,t,r)))}const o=this.types[e];return o?o.reduce(((e,{name:n,type:o})=>(e[n]=this._visit(o,t[n],r),e)),{}):Ml.throwArgumentError(`unknown type: ${e}`,"type",e)}visit(e,t){return this._visit(this.primaryType,e,t)}static from(e){return new Hl(e)}static getPrimaryType(e){return Hl.from(e).primaryType}static hashStruct(e,t,r){return Hl.from(t).hashStruct(e,r)}static hashDomain(e){const t=[];for(const r in e){const n=Wl[r];n||Ml.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(r)}`,"domain",e),t.push({name:r,type:n})}return t.sort(((e,t)=>_l.indexOf(e.name)-_l.indexOf(t.name))),Hl.hashStruct("EIP712Domain",{EIP712Domain:t},e)}static encode(e,t,r){return _s(["0x1901",Hl.hashDomain(e),Hl.from(t).hash(r)])}static hash(e,t,r){return zs(Hl.encode(e,t,r))}static resolveNames(e,t,r,n){return Nl(this,void 0,void 0,(function*(){e=Ca(e);const o={};e.verifyingContract&&!Ds(e.verifyingContract,20)&&(o[e.verifyingContract]="0x");const i=Hl.from(t);i.visit(r,((e,t)=>("address"!==e||Ds(t,20)||(o[t]="0x"),t)));for(const e in o)o[e]=yield n(e);return e.verifyingContract&&o[e.verifyingContract]&&(e.verifyingContract=o[e.verifyingContract]),r=i.visit(r,((e,t)=>"address"===e&&o[t]?o[t]:t)),{domain:e,value:r}}))}static getPayload(e,t,r){Hl.hashDomain(e);const n={},o=[];_l.forEach((t=>{const r=e[t];null!=r&&(n[t]=Ll[t](r),o.push({name:t,type:Wl[t]}))}));const i=Hl.from(t),s=Ca(t);return s.EIP712Domain?Ml.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",t):s.EIP712Domain=o,i.encode(r),{types:s,domain:n,primaryType:i.primaryType,message:i.visit(r,((e,t)=>{if(e.match(/^bytes(\d*)/))return Bs(Os(t));if(e.match(/^u?int/))return y.BigNumber.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!=typeof t&&Ml.throwArgumentError("invalid string","value",t),t}return Ml.throwArgumentError("unsupported type","type",e)}))}}}var zl={},Yl={},Gl=Xl;function Xl(e,t){if(!e)throw new Error(t||"Assertion failed")}Xl.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var Jl,ql={exports:{}},Ql={exports:{}};!function(e){try{var t=require("util");if("function"!=typeof t.inherits)throw"";e.exports=t.inherits}catch(t){e.exports=(Jl||(Jl=1,"function"==typeof Object.create?Ql.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:Ql.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}),Ql.exports)}}(ql);var Kl=Gl,$l=ql.exports;function ec(e,t){return 55296==(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1)))}function tc(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function rc(e){return 1===e.length?"0"+e:e}function nc(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}Yl.inherits=$l,Yl.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),o=0;o<e.length;o+=2)r.push(parseInt(e[o]+e[o+1],16))}else for(var n=0,o=0;o<e.length;o++){var i=e.charCodeAt(o);i<128?r[n++]=i:i<2048?(r[n++]=i>>6|192,r[n++]=63&i|128):ec(e,o)?(i=65536+((1023&i)<<10)+(1023&e.charCodeAt(++o)),r[n++]=i>>18|240,r[n++]=i>>12&63|128,r[n++]=i>>6&63|128,r[n++]=63&i|128):(r[n++]=i>>12|224,r[n++]=i>>6&63|128,r[n++]=63&i|128)}else for(o=0;o<e.length;o++)r[o]=0|e[o];return r},Yl.toHex=function(e){for(var t="",r=0;r<e.length;r++)t+=rc(e[r].toString(16));return t},Yl.htonl=tc,Yl.toHex32=function(e,t){for(var r="",n=0;n<e.length;n++){var o=e[n];"little"===t&&(o=tc(o)),r+=nc(o.toString(16))}return r},Yl.zero2=rc,Yl.zero8=nc,Yl.join32=function(e,t,r,n){var o=r-t;Kl(o%4==0);for(var i=new Array(o/4),s=0,a=t;s<i.length;s++,a+=4){var l;l="big"===n?e[a]<<24|e[a+1]<<16|e[a+2]<<8|e[a+3]:e[a+3]<<24|e[a+2]<<16|e[a+1]<<8|e[a],i[s]=l>>>0}return i},Yl.split32=function(e,t){for(var r=new Array(4*e.length),n=0,o=0;n<e.length;n++,o+=4){var i=e[n];"big"===t?(r[o]=i>>>24,r[o+1]=i>>>16&255,r[o+2]=i>>>8&255,r[o+3]=255&i):(r[o+3]=i>>>24,r[o+2]=i>>>16&255,r[o+1]=i>>>8&255,r[o]=255&i)}return r},Yl.rotr32=function(e,t){return e>>>t|e<<32-t},Yl.rotl32=function(e,t){return e<<t|e>>>32-t},Yl.sum32=function(e,t){return e+t>>>0},Yl.sum32_3=function(e,t,r){return e+t+r>>>0},Yl.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},Yl.sum32_5=function(e,t,r,n,o){return e+t+r+n+o>>>0},Yl.sum64=function(e,t,r,n){var o=e[t],i=n+e[t+1]>>>0,s=(i<n?1:0)+r+o;e[t]=s>>>0,e[t+1]=i},Yl.sum64_hi=function(e,t,r,n){return(t+n>>>0<t?1:0)+e+r>>>0},Yl.sum64_lo=function(e,t,r,n){return t+n>>>0},Yl.sum64_4_hi=function(e,t,r,n,o,i,s,a){var l=0,c=t;return l+=(c=c+n>>>0)<t?1:0,l+=(c=c+i>>>0)<i?1:0,e+r+o+s+(l+=(c=c+a>>>0)<a?1:0)>>>0},Yl.sum64_4_lo=function(e,t,r,n,o,i,s,a){return t+n+i+a>>>0},Yl.sum64_5_hi=function(e,t,r,n,o,i,s,a,l,c){var u=0,d=t;return u+=(d=d+n>>>0)<t?1:0,u+=(d=d+i>>>0)<i?1:0,u+=(d=d+a>>>0)<a?1:0,e+r+o+s+l+(u+=(d=d+c>>>0)<c?1:0)>>>0},Yl.sum64_5_lo=function(e,t,r,n,o,i,s,a,l,c){return t+n+i+a+c>>>0},Yl.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},Yl.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},Yl.shr64_hi=function(e,t,r){return e>>>r},Yl.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0};var oc={},ic=Yl,sc=Gl;function ac(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}oc.BlockHash=ac,ac.prototype.update=function(e,t){if(e=ic.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=ic.join32(e,0,e.length-r,this.endian);for(var n=0;n<e.length;n+=this._delta32)this._update(e,n,n+this._delta32)}return this},ac.prototype.digest=function(e){return this.update(this._pad()),sc(null===this.pending),this._digest(e)},ac.prototype._pad=function(){var e=this.pendingTotal,t=this._delta8,r=t-(e+this.padLength)%t,n=new Array(r+this.padLength);n[0]=128;for(var o=1;o<r;o++)n[o]=0;if(e<<=3,"big"===this.endian){for(var i=8;i<this.padLength;i++)n[o++]=0;n[o++]=0,n[o++]=0,n[o++]=0,n[o++]=0,n[o++]=e>>>24&255,n[o++]=e>>>16&255,n[o++]=e>>>8&255,n[o++]=255&e}else for(n[o++]=255&e,n[o++]=e>>>8&255,n[o++]=e>>>16&255,n[o++]=e>>>24&255,n[o++]=0,n[o++]=0,n[o++]=0,n[o++]=0,i=8;i<this.padLength;i++)n[o++]=0;return n};var lc={},cc={},uc=Yl.rotr32;function dc(e,t,r){return e&t^~e&r}function pc(e,t,r){return e&t^e&r^t&r}function hc(e,t,r){return e^t^r}cc.ft_1=function(e,t,r,n){return 0===e?dc(t,r,n):1===e||3===e?hc(t,r,n):2===e?pc(t,r,n):void 0},cc.ch32=dc,cc.maj32=pc,cc.p32=hc,cc.s0_256=function(e){return uc(e,2)^uc(e,13)^uc(e,22)},cc.s1_256=function(e){return uc(e,6)^uc(e,11)^uc(e,25)},cc.g0_256=function(e){return uc(e,7)^uc(e,18)^e>>>3},cc.g1_256=function(e){return uc(e,17)^uc(e,19)^e>>>10};var fc=Yl,mc=oc,gc=cc,yc=fc.rotl32,bc=fc.sum32,xc=fc.sum32_5,vc=gc.ft_1,wc=mc.BlockHash,Ec=[1518500249,1859775393,2400959708,3395469782];function Ac(){if(!(this instanceof Ac))return new Ac;wc.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}fc.inherits(Ac,wc);var Cc=Ac;Ac.blockSize=512,Ac.outSize=160,Ac.hmacStrength=80,Ac.padLength=64,Ac.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=yc(r[n-3]^r[n-8]^r[n-14]^r[n-16],1);var o=this.h[0],i=this.h[1],s=this.h[2],a=this.h[3],l=this.h[4];for(n=0;n<r.length;n++){var c=~~(n/20),u=xc(yc(o,5),vc(c,i,s,a),l,r[n],Ec[c]);l=a,a=s,s=yc(i,30),i=o,o=u}this.h[0]=bc(this.h[0],o),this.h[1]=bc(this.h[1],i),this.h[2]=bc(this.h[2],s),this.h[3]=bc(this.h[3],a),this.h[4]=bc(this.h[4],l)},Ac.prototype._digest=function(e){return"hex"===e?fc.toHex32(this.h,"big"):fc.split32(this.h,"big")};var kc=Yl,Rc=oc,Tc=cc,Sc=Gl,Nc=kc.sum32,Mc=kc.sum32_4,Fc=kc.sum32_5,Oc=Tc.ch32,Ic=Tc.maj32,jc=Tc.s0_256,Dc=Tc.s1_256,Bc=Tc.g0_256,Pc=Tc.g1_256,Wc=Rc.BlockHash,_c=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function Uc(){if(!(this instanceof Uc))return new Uc;Wc.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=_c,this.W=new Array(64)}kc.inherits(Uc,Wc);var Lc=Uc;Uc.blockSize=512,Uc.outSize=256,Uc.hmacStrength=192,Uc.padLength=64,Uc.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=Mc(Pc(r[n-2]),r[n-7],Bc(r[n-15]),r[n-16]);var o=this.h[0],i=this.h[1],s=this.h[2],a=this.h[3],l=this.h[4],c=this.h[5],u=this.h[6],d=this.h[7];for(Sc(this.k.length===r.length),n=0;n<r.length;n++){var p=Fc(d,Dc(l),Oc(l,c,u),this.k[n],r[n]),h=Nc(jc(o),Ic(o,i,s));d=u,u=c,c=l,l=Nc(a,p),a=s,s=i,i=o,o=Nc(p,h)}this.h[0]=Nc(this.h[0],o),this.h[1]=Nc(this.h[1],i),this.h[2]=Nc(this.h[2],s),this.h[3]=Nc(this.h[3],a),this.h[4]=Nc(this.h[4],l),this.h[5]=Nc(this.h[5],c),this.h[6]=Nc(this.h[6],u),this.h[7]=Nc(this.h[7],d)},Uc.prototype._digest=function(e){return"hex"===e?kc.toHex32(this.h,"big"):kc.split32(this.h,"big")};var Vc=Yl,Zc=Lc;function Hc(){if(!(this instanceof Hc))return new Hc;Zc.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}Vc.inherits(Hc,Zc);var zc=Hc;Hc.blockSize=512,Hc.outSize=224,Hc.hmacStrength=192,Hc.padLength=64,Hc.prototype._digest=function(e){return"hex"===e?Vc.toHex32(this.h.slice(0,7),"big"):Vc.split32(this.h.slice(0,7),"big")};var Yc=Yl,Gc=oc,Xc=Gl,Jc=Yc.rotr64_hi,qc=Yc.rotr64_lo,Qc=Yc.shr64_hi,Kc=Yc.shr64_lo,$c=Yc.sum64,eu=Yc.sum64_hi,tu=Yc.sum64_lo,ru=Yc.sum64_4_hi,nu=Yc.sum64_4_lo,ou=Yc.sum64_5_hi,iu=Yc.sum64_5_lo,su=Gc.BlockHash,au=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function lu(){if(!(this instanceof lu))return new lu;su.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=au,this.W=new Array(160)}Yc.inherits(lu,su);var cu=lu;function uu(e,t,r,n,o){var i=e&r^~e&o;return i<0&&(i+=4294967296),i}function du(e,t,r,n,o,i){var s=t&n^~t&i;return s<0&&(s+=4294967296),s}function pu(e,t,r,n,o){var i=e&r^e&o^r&o;return i<0&&(i+=4294967296),i}function hu(e,t,r,n,o,i){var s=t&n^t&i^n&i;return s<0&&(s+=4294967296),s}function fu(e,t){var r=Jc(e,t,28)^Jc(t,e,2)^Jc(t,e,7);return r<0&&(r+=4294967296),r}function mu(e,t){var r=qc(e,t,28)^qc(t,e,2)^qc(t,e,7);return r<0&&(r+=4294967296),r}function gu(e,t){var r=Jc(e,t,14)^Jc(e,t,18)^Jc(t,e,9);return r<0&&(r+=4294967296),r}function yu(e,t){var r=qc(e,t,14)^qc(e,t,18)^qc(t,e,9);return r<0&&(r+=4294967296),r}function bu(e,t){var r=Jc(e,t,1)^Jc(e,t,8)^Qc(e,t,7);return r<0&&(r+=4294967296),r}function xu(e,t){var r=qc(e,t,1)^qc(e,t,8)^Kc(e,t,7);return r<0&&(r+=4294967296),r}function vu(e,t){var r=Jc(e,t,19)^Jc(t,e,29)^Qc(e,t,6);return r<0&&(r+=4294967296),r}function wu(e,t){var r=qc(e,t,19)^qc(t,e,29)^Kc(e,t,6);return r<0&&(r+=4294967296),r}lu.blockSize=1024,lu.outSize=512,lu.hmacStrength=192,lu.padLength=128,lu.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n<r.length;n+=2){var o=vu(r[n-4],r[n-3]),i=wu(r[n-4],r[n-3]),s=r[n-14],a=r[n-13],l=bu(r[n-30],r[n-29]),c=xu(r[n-30],r[n-29]),u=r[n-32],d=r[n-31];r[n]=ru(o,i,s,a,l,c,u,d),r[n+1]=nu(o,i,s,a,l,c,u,d)}},lu.prototype._update=function(e,t){this._prepareBlock(e,t);var r=this.W,n=this.h[0],o=this.h[1],i=this.h[2],s=this.h[3],a=this.h[4],l=this.h[5],c=this.h[6],u=this.h[7],d=this.h[8],p=this.h[9],h=this.h[10],f=this.h[11],m=this.h[12],g=this.h[13],y=this.h[14],b=this.h[15];Xc(this.k.length===r.length);for(var x=0;x<r.length;x+=2){var v=y,w=b,E=gu(d,p),A=yu(d,p),C=uu(d,p,h,f,m),k=du(d,p,h,f,m,g),R=this.k[x],T=this.k[x+1],S=r[x],N=r[x+1],M=ou(v,w,E,A,C,k,R,T,S,N),F=iu(v,w,E,A,C,k,R,T,S,N);v=fu(n,o),w=mu(n,o),E=pu(n,o,i,s,a),A=hu(n,o,i,s,a,l);var O=eu(v,w,E,A),I=tu(v,w,E,A);y=m,b=g,m=h,g=f,h=d,f=p,d=eu(c,u,M,F),p=tu(u,u,M,F),c=a,u=l,a=i,l=s,i=n,s=o,n=eu(M,F,O,I),o=tu(M,F,O,I)}$c(this.h,0,n,o),$c(this.h,2,i,s),$c(this.h,4,a,l),$c(this.h,6,c,u),$c(this.h,8,d,p),$c(this.h,10,h,f),$c(this.h,12,m,g),$c(this.h,14,y,b)},lu.prototype._digest=function(e){return"hex"===e?Yc.toHex32(this.h,"big"):Yc.split32(this.h,"big")};var Eu=Yl,Au=cu;function Cu(){if(!(this instanceof Cu))return new Cu;Au.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}Eu.inherits(Cu,Au);var ku=Cu;Cu.blockSize=1024,Cu.outSize=384,Cu.hmacStrength=192,Cu.padLength=128,Cu.prototype._digest=function(e){return"hex"===e?Eu.toHex32(this.h.slice(0,12),"big"):Eu.split32(this.h.slice(0,12),"big")},lc.sha1=Cc,lc.sha224=zc,lc.sha256=Lc,lc.sha384=ku,lc.sha512=cu;var Ru={},Tu=Yl,Su=oc,Nu=Tu.rotl32,Mu=Tu.sum32,Fu=Tu.sum32_3,Ou=Tu.sum32_4,Iu=Su.BlockHash;function ju(){if(!(this instanceof ju))return new ju;Iu.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function Du(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function Bu(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function Pu(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}Tu.inherits(ju,Iu),Ru.ripemd160=ju,ju.blockSize=512,ju.outSize=160,ju.hmacStrength=192,ju.padLength=64,ju.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],o=this.h[2],i=this.h[3],s=this.h[4],a=r,l=n,c=o,u=i,d=s,p=0;p<80;p++){var h=Mu(Nu(Ou(r,Du(p,n,o,i),e[Wu[p]+t],Bu(p)),Uu[p]),s);r=s,s=i,i=Nu(o,10),o=n,n=h,h=Mu(Nu(Ou(a,Du(79-p,l,c,u),e[_u[p]+t],Pu(p)),Lu[p]),d),a=d,d=u,u=Nu(c,10),c=l,l=h}h=Fu(this.h[1],o,u),this.h[1]=Fu(this.h[2],i,d),this.h[2]=Fu(this.h[3],s,a),this.h[3]=Fu(this.h[4],r,l),this.h[4]=Fu(this.h[0],n,c),this.h[0]=h},ju.prototype._digest=function(e){return"hex"===e?Tu.toHex32(this.h,"little"):Tu.split32(this.h,"little")};var Wu=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],_u=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],Uu=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],Lu=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],Vu=Yl,Zu=Gl;function Hu(e,t,r){if(!(this instanceof Hu))return new Hu(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(Vu.toArray(t,r))}var zu=Hu;Hu.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),Zu(e.length<=this.blockSize);for(var t=e.length;t<this.blockSize;t++)e.push(0);for(t=0;t<e.length;t++)e[t]^=54;for(this.inner=(new this.Hash).update(e),t=0;t<e.length;t++)e[t]^=106;this.outer=(new this.Hash).update(e)},Hu.prototype.update=function(e,t){return this.inner.update(e,t),this},Hu.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)},function(e){var t=zl;t.utils=Yl,t.common=oc,t.sha=lc,t.ripemd=Ru,t.hmac=zu,t.sha1=t.sha.sha1,t.sha256=t.sha.sha256,t.sha224=t.sha.sha224,t.sha384=t.sha.sha384,t.sha512=t.sha.sha512,t.ripemd160=t.ripemd.ripemd160}();var Yu=zl;function Gu(e){return"0x"+Yu.sha256().update(Os(e)).digest("hex")}new ks("sha2/5.7.0");var Xu=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};function Ju(e,t){return Xu(this,void 0,void 0,(function*(){null==t&&(t={});const r={method:t.method||"GET",headers:t.headers||{},body:t.body||void 0};if(!0!==t.skipFetchSetup&&(r.mode="cors",r.cache="no-cache",r.credentials="same-origin",r.redirect="follow",r.referrer="client"),null!=t.fetchOptions){const e=t.fetchOptions;e.mode&&(r.mode=e.mode),e.cache&&(r.cache=e.cache),e.credentials&&(r.credentials=e.credentials),e.redirect&&(r.redirect=e.redirect),e.referrer&&(r.referrer=e.referrer)}const n=yield fetch(e,r),o=yield n.arrayBuffer(),i={};return n.headers.forEach?n.headers.forEach(((e,t)=>{i[t.toLowerCase()]=e})):n.headers.keys().forEach((e=>{i[e.toLowerCase()]=n.headers.get(e)})),{headers:i,statusCode:n.status,statusMessage:n.statusText,body:Os(new Uint8Array(o))}}))}var qu=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Qu=new ks("web/5.7.1");function Ku(e){return new Promise((t=>{setTimeout(t,e)}))}function $u(e,t){if(null==e)return null;if("string"==typeof e)return e;if(Ns(e)){if(t&&("text"===t.split("/")[0]||"application/json"===t.split(";")[0].trim()))try{return nl(e)}catch(e){}return Bs(e)}return e}function ed(e,t,r){let n=null;if(null!=t){n=rl(t);const r="string"==typeof e?{url:e}:Ca(e);if(r.headers){0!==Object.keys(r.headers).filter((e=>"content-type"===e.toLowerCase())).length||(r.headers=Ca(r.headers),r.headers["content-type"]="application/json")}else r.headers={"content-type":"application/json"};e=r}return function(e,t,r){const n="object"==typeof e&&null!=e.throttleLimit?e.throttleLimit:12;Qu.assertArgument(n>0&&n%1==0,"invalid connection throttle limit","connection.throttleLimit",n);const o="object"==typeof e?e.throttleCallback:null,i="object"==typeof e&&"number"==typeof e.throttleSlotInterval?e.throttleSlotInterval:100;Qu.assertArgument(i>0&&i%1==0,"invalid connection throttle slot interval","connection.throttleSlotInterval",i);const s="object"==typeof e&&!!e.errorPassThrough,a={};let l=null;const c={method:"GET"};let u=!1,d=12e4;if("string"==typeof e)l=e;else if("object"==typeof e){if(null!=e&&null!=e.url||Qu.throwArgumentError("missing URL","connection.url",e),l=e.url,"number"==typeof e.timeout&&e.timeout>0&&(d=e.timeout),e.headers)for(const t in e.headers)a[t.toLowerCase()]={key:t,value:String(e.headers[t])},["if-none-match","if-modified-since"].indexOf(t.toLowerCase())>=0&&(u=!0);if(c.allowGzip=!!e.allowGzip,null!=e.user&&null!=e.password){"https:"!==l.substring(0,6)&&!0!==e.allowInsecureAuthentication&&Qu.throwError("basic authentication requires a secure https url",ks.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:e.user,password:"[REDACTED]"});const t=e.user+":"+e.password;a.authorization={key:"Authorization",value:"Basic "+Va(rl(t))}}null!=e.skipFetchSetup&&(c.skipFetchSetup=!!e.skipFetchSetup),null!=e.fetchOptions&&(c.fetchOptions=Ca(e.fetchOptions))}const p=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),h=l?l.match(p):null;if(h)try{const e={statusCode:200,statusMessage:"OK",headers:{"content-type":h[1]||"text/plain"},body:h[2]?La(h[3]):(f=h[3],rl(f.replace(/%([0-9a-f][0-9a-f])/gi,((e,t)=>String.fromCharCode(parseInt(t,16))))))};let t=e.body;return r&&(t=r(e.body,e)),Promise.resolve(t)}catch(e){Qu.throwError("processing response error",ks.errors.SERVER_ERROR,{body:$u(h[1],h[2]),error:e,requestBody:null,requestMethod:"GET",url:l})}var f;t&&(c.method="POST",c.body=t,null==a["content-type"]&&(a["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==a["content-length"]&&(a["content-length"]={key:"Content-Length",value:String(t.length)}));const m={};Object.keys(a).forEach((e=>{const t=a[e];m[t.key]=t.value})),c.headers=m;const g=function(){let e=null;return{promise:new Promise((function(t,r){d&&(e=setTimeout((()=>{null!=e&&(e=null,r(Qu.makeError("timeout",ks.errors.TIMEOUT,{requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,timeout:d,url:l})))}),d))})),cancel:function(){null!=e&&(clearTimeout(e),e=null)}}}(),y=function(){return qu(this,void 0,void 0,(function*(){for(let e=0;e<n;e++){let t=null;try{if(t=yield Ju(l,c),e<n)if(301===t.statusCode||302===t.statusCode){const e=t.headers.location||"";if("GET"===c.method&&e.match(/^https:/)){l=t.headers.location;continue}}else if(429===t.statusCode){let r=!0;if(o&&(r=yield o(e,l)),r){let r=0;const n=t.headers["retry-after"];r="string"==typeof n&&n.match(/^[1-9][0-9]*$/)?1e3*parseInt(n):i*parseInt(String(Math.random()*Math.pow(2,e))),yield Ku(r);continue}}}catch(e){t=e.response,null==t&&(g.cancel(),Qu.throwError("missing response",ks.errors.SERVER_ERROR,{requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,serverError:e,url:l}))}let a=t.body;if(u&&304===t.statusCode?a=null:!s&&(t.statusCode<200||t.statusCode>=300)&&(g.cancel(),Qu.throwError("bad response",ks.errors.SERVER_ERROR,{status:t.statusCode,headers:t.headers,body:$u(a,t.headers?t.headers["content-type"]:null),requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,url:l})),r)try{const e=yield r(a,t);return g.cancel(),e}catch(r){if(r.throttleRetry&&e<n){let t=!0;if(o&&(t=yield o(e,l)),t){const t=i*parseInt(String(Math.random()*Math.pow(2,e)));yield Ku(t);continue}}g.cancel(),Qu.throwError("processing response error",ks.errors.SERVER_ERROR,{body:$u(a,t.headers?t.headers["content-type"]:null),error:r,requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,url:l})}return g.cancel(),a}return Qu.throwError("failed response",ks.errors.SERVER_ERROR,{requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,url:l})}))}();return Promise.race([g.promise,y])}(e,n,((e,t)=>{let n=null;if(null!=e)try{n=JSON.parse(nl(e))}catch(t){Qu.throwError("invalid JSON",ks.errors.SERVER_ERROR,{body:e,error:t})}return r&&(n=r(n,t)),n}))}function td(e,t){return t||(t={}),null==(t=Ca(t)).floor&&(t.floor=0),null==t.ceiling&&(t.ceiling=1e4),null==t.interval&&(t.interval=250),new Promise((function(r,n){let o=null,i=!1;const s=()=>!i&&(i=!0,o&&clearTimeout(o),!0);t.timeout&&(o=setTimeout((()=>{s()&&n(new Error("timeout"))}),t.timeout));const a=t.retryLimit;let l=0;!function o(){return e().then((function(e){if(void 0!==e)s()&&r(e);else if(t.oncePoll)t.oncePoll.once("poll",o);else if(t.onceBlock)t.onceBlock.once("block",o);else if(!i){if(l++,l>a)return void(s()&&n(new Error("retry limit reached")));let e=t.interval*parseInt(String(Math.random()*Math.pow(2,l)));e<t.floor&&(e=t.floor),e>t.ceiling&&(e=t.ceiling),setTimeout(o,e)}return null}),(function(e){s()&&n(e)}))}()}))}for(var rd="qpzry9x8gf2tvdw0s3jn54khce6mua7l",nd={},od=0;od<rd.length;od++){var id=rd.charAt(od);if(void 0!==nd[id])throw new TypeError(id+" is ambiguous");nd[id]=od}function sd(e){var t=e>>25;return(33554431&e)<<5^996825010&-(t>>0&1)^642813549&-(t>>1&1)^513874426&-(t>>2&1)^1027748829&-(t>>3&1)^705979059&-(t>>4&1)}function ad(e){for(var t=1,r=0;r<e.length;++r){var n=e.charCodeAt(r);if(n<33||n>126)return"Invalid prefix ("+e+")";t=sd(t)^n>>5}for(t=sd(t),r=0;r<e.length;++r){var o=e.charCodeAt(r);t=sd(t)^31&o}return t}function ld(e,t){if(t=t||90,e.length<8)return e+" too short";if(e.length>t)return"Exceeds length limit";var r=e.toLowerCase(),n=e.toUpperCase();if(e!==r&&e!==n)return"Mixed-case string "+e;var o=(e=r).lastIndexOf("1");if(-1===o)return"No separator character for "+e;if(0===o)return"Missing prefix for "+e;var i=e.slice(0,o),s=e.slice(o+1);if(s.length<6)return"Data too short";var a=ad(i);if("string"==typeof a)return a;for(var l=[],c=0;c<s.length;++c){var u=s.charAt(c),d=nd[u];if(void 0===d)return"Unknown character "+u;a=sd(a)^d,c+6>=s.length||l.push(d)}return 1!==a?"Invalid checksum for "+e:{prefix:i,words:l}}function cd(e,t,r,n){for(var o=0,i=0,s=(1<<r)-1,a=[],l=0;l<e.length;++l)for(o=o<<t|e[l],i+=t;i>=r;)i-=r,a.push(o>>i&s);if(n)i>0&&a.push(o<<r-i&s);else{if(i>=t)return"Excess padding";if(o<<r-i&s)return"Non-zero padding"}return a}var ud={decodeUnsafe:function(){var e=ld.apply(null,arguments);if("object"==typeof e)return e},decode:function(e){var t=ld.apply(null,arguments);if("object"==typeof t)return t;throw new Error(t)},encode:function(e,t,r){if(r=r||90,e.length+7+t.length>r)throw new TypeError("Exceeds length limit");var n=ad(e=e.toLowerCase());if("string"==typeof n)throw new Error(n);for(var o=e+"1",i=0;i<t.length;++i){var s=t[i];if(s>>5!=0)throw new Error("Non 5-bit word");n=sd(n)^s,o+=rd.charAt(s)}for(i=0;i<6;++i)n=sd(n);for(n^=1,i=0;i<6;++i){o+=rd.charAt(n>>5*(5-i)&31)}return o},toWordsUnsafe:function(e){var t=cd(e,8,5,!0);if(Array.isArray(t))return t},toWords:function(e){var t=cd(e,8,5,!0);if(Array.isArray(t))return t;throw new Error(t)},fromWordsUnsafe:function(e){var t=cd(e,5,8,!1);if(Array.isArray(t))return t},fromWords:function(e){var t=cd(e,5,8,!1);if(Array.isArray(t))return t;throw new Error(t)}};const dd="providers/5.7.2";var pd={exports:{}};!function(e,t){function r(e,t){if(!e)throw new Error(t||"Assertion failed")}function n(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var i;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{i="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:require("buffer").Buffer}catch(e){}function s(e,t){var n=e.charCodeAt(t);return n>=48&&n<=57?n-48:n>=65&&n<=70?n-55:n>=97&&n<=102?n-87:void r(!1,"Invalid character in "+e)}function a(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function l(e,t,n,o){for(var i=0,s=0,a=Math.min(e.length,n),l=t;l<a;l++){var c=e.charCodeAt(l)-48;i*=o,s=c>=49?c-49+10:c>=17?c-17+10:c,r(c>=0&&s<o,"Invalid character"),i+=s}return i}function c(e,t){e.words=t.words,e.length=t.length,e.negative=t.negative,e.red=t.red}if(o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,n){if("number"==typeof e)return this._initNumber(e,t,n);if("object"==typeof e)return this._initArray(e,t,n);"hex"===t&&(t=16),r(t===(0|t)&&t>=2&&t<=36);var o=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(o++,this.negative=1),o<e.length&&(16===t?this._parseHex(e,o,n):(this._parseBase(e,t,o),"le"===n&&this._initArray(this.toArray(),t,n)))},o.prototype._initNumber=function(e,t,n){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(r(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===n&&this._initArray(this.toArray(),t,n)},o.prototype._initArray=function(e,t,n){if(r("number"==typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var o=0;o<this.length;o++)this.words[o]=0;var i,s,a=0;if("be"===n)for(o=e.length-1,i=0;o>=0;o-=3)s=e[o]|e[o-1]<<8|e[o-2]<<16,this.words[i]|=s<<a&67108863,this.words[i+1]=s>>>26-a&67108863,(a+=24)>=26&&(a-=26,i++);else if("le"===n)for(o=0,i=0;o<e.length;o+=3)s=e[o]|e[o+1]<<8|e[o+2]<<16,this.words[i]|=s<<a&67108863,this.words[i+1]=s>>>26-a&67108863,(a+=24)>=26&&(a-=26,i++);return this._strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var o,i=0,s=0;if("be"===r)for(n=e.length-1;n>=t;n-=2)o=a(e,t,n)<<i,this.words[s]|=67108863&o,i>=18?(i-=18,s+=1,this.words[s]|=o>>>26):i+=8;else for(n=(e.length-t)%2==0?t+1:t;n<e.length;n+=2)o=a(e,t,n)<<i,this.words[s]|=67108863&o,i>=18?(i-=18,s+=1,this.words[s]|=o>>>26):i+=8;this._strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,o=1;o<=67108863;o*=t)n++;n--,o=o/t|0;for(var i=e.length-r,s=i%n,a=Math.min(i,i-s)+r,c=0,u=r;u<a;u+=n)c=l(e,u,u+n,t),this.imuln(o),this.words[0]+c<67108864?this.words[0]+=c:this._iaddn(c);if(0!==s){var d=1;for(c=l(e,u,e.length,t),u=0;u<s;u++)d*=t;this.imuln(d),this.words[0]+c<67108864?this.words[0]+=c:this._iaddn(c)}this._strip()},o.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},o.prototype._move=function(e){c(e,this)},o.prototype.clone=function(){var e=new o(null);return this.copy(e),e},o.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},o.prototype._strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{o.prototype[Symbol.for("nodejs.util.inspect.custom")]=u}catch(e){o.prototype.inspect=u}else o.prototype.inspect=u;function u(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],p=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],h=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function f(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var o=0|e.words[0],i=0|t.words[0],s=o*i,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var c=1;c<n;c++){for(var u=l>>>26,d=67108863&l,p=Math.min(c,t.length-1),h=Math.max(0,c-e.length+1);h<=p;h++){var f=c-h|0;u+=(s=(o=0|e.words[f])*(i=0|t.words[h])+d)/67108864|0,d=67108863&s}r.words[c]=0|d,l=0|u}return 0!==l?r.words[c]=0|l:r.length--,r._strip()}o.prototype.toString=function(e,t){var n;if(t=0|t||1,16===(e=e||10)||"hex"===e){n="";for(var o=0,i=0,s=0;s<this.length;s++){var a=this.words[s],l=(16777215&(a<<o|i)).toString(16);i=a>>>24-o&16777215,(o+=2)>=26&&(o-=26,s--),n=0!==i||s!==this.length-1?d[6-l.length]+l+n:l+n}for(0!==i&&(n=i.toString(16)+n);n.length%t!=0;)n="0"+n;return 0!==this.negative&&(n="-"+n),n}if(e===(0|e)&&e>=2&&e<=36){var c=p[e],u=h[e];n="";var f=this.clone();for(f.negative=0;!f.isZero();){var m=f.modrn(u).toString(e);n=(f=f.idivn(u)).isZero()?m+n:d[c-m.length]+m+n}for(this.isZero()&&(n="0"+n);n.length%t!=0;)n="0"+n;return 0!==this.negative&&(n="-"+n),n}r(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16,2)},i&&(o.prototype.toBuffer=function(e,t){return this.toArrayLike(i,e,t)}),o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,n){this._strip();var o=this.byteLength(),i=n||Math.max(1,o);r(o<=i,"byte array longer than desired length"),r(i>0,"Requested array length <= 0");var s=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,i);return this["_toArrayLike"+("le"===t?"LE":"BE")](s,o),s},o.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,o=0,i=0;o<this.length;o++){var s=this.words[o]<<i|n;e[r++]=255&s,r<e.length&&(e[r++]=s>>8&255),r<e.length&&(e[r++]=s>>16&255),6===i?(r<e.length&&(e[r++]=s>>24&255),n=0,i=0):(n=s>>>24,i+=2)}if(r<e.length)for(e[r++]=n;r<e.length;)e[r++]=0},o.prototype._toArrayLikeBE=function(e,t){for(var r=e.length-1,n=0,o=0,i=0;o<this.length;o++){var s=this.words[o]<<i|n;e[r--]=255&s,r>=0&&(e[r--]=s>>8&255),r>=0&&(e[r--]=s>>16&255),6===i?(r>=0&&(e[r--]=s>>24&255),n=0,i=0):(n=s>>>24,i+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var r=this._zeroBits(this.words[t]);if(e+=r,26!==r)break}return e},o.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},o.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},o.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},o.prototype.isNeg=function(){return 0!==this.negative},o.prototype.neg=function(){return this.clone().ineg()},o.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},o.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this._strip()},o.prototype.ior=function(e){return r(0==(this.negative|e.negative)),this.iuor(e)},o.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;r<t.length;r++)this.words[r]=this.words[r]&e.words[r];return this.length=t.length,this._strip()},o.prototype.iand=function(e){return r(0==(this.negative|e.negative)),this.iuand(e)},o.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;n<r.length;n++)this.words[n]=t.words[n]^r.words[n];if(this!==t)for(;n<t.length;n++)this.words[n]=t.words[n];return this.length=t.length,this._strip()},o.prototype.ixor=function(e){return r(0==(this.negative|e.negative)),this.iuxor(e)},o.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){r("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),n=e%26;this._expand(t),n>0&&t--;for(var o=0;o<t;o++)this.words[o]=67108863&~this.words[o];return n>0&&(this.words[o]=~this.words[o]&67108863>>26-n),this._strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){r("number"==typeof e&&e>=0);var n=e/26|0,o=e%26;return this._expand(n+1),this.words[n]=t?this.words[n]|1<<o:this.words[n]&~(1<<o),this._strip()},o.prototype.iadd=function(e){var t,r,n;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(r=this,n=e):(r=e,n=this);for(var o=0,i=0;i<n.length;i++)t=(0|r.words[i])+(0|n.words[i])+o,this.words[i]=67108863&t,o=t>>>26;for(;0!==o&&i<r.length;i++)t=(0|r.words[i])+o,this.words[i]=67108863&t,o=t>>>26;if(this.length=r.length,0!==o)this.words[this.length]=o,this.length++;else if(r!==this)for(;i<r.length;i++)this.words[i]=r.words[i];return this},o.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,o=this.cmp(e);if(0===o)return this.negative=0,this.length=1,this.words[0]=0,this;o>0?(r=this,n=e):(r=e,n=this);for(var i=0,s=0;s<n.length;s++)i=(t=(0|r.words[s])-(0|n.words[s])+i)>>26,this.words[s]=67108863&t;for(;0!==i&&s<r.length;s++)i=(t=(0|r.words[s])+i)>>26,this.words[s]=67108863&t;if(0===i&&s<r.length&&r!==this)for(;s<r.length;s++)this.words[s]=r.words[s];return this.length=Math.max(this.length,s),r!==this&&(this.negative=1),this._strip()},o.prototype.sub=function(e){return this.clone().isub(e)};var m=function(e,t,r){var n,o,i,s=e.words,a=t.words,l=r.words,c=0,u=0|s[0],d=8191&u,p=u>>>13,h=0|s[1],f=8191&h,m=h>>>13,g=0|s[2],y=8191&g,b=g>>>13,x=0|s[3],v=8191&x,w=x>>>13,E=0|s[4],A=8191&E,C=E>>>13,k=0|s[5],R=8191&k,T=k>>>13,S=0|s[6],N=8191&S,M=S>>>13,F=0|s[7],O=8191&F,I=F>>>13,j=0|s[8],D=8191&j,B=j>>>13,P=0|s[9],W=8191&P,_=P>>>13,U=0|a[0],L=8191&U,V=U>>>13,Z=0|a[1],H=8191&Z,z=Z>>>13,Y=0|a[2],G=8191&Y,X=Y>>>13,J=0|a[3],q=8191&J,Q=J>>>13,K=0|a[4],$=8191&K,ee=K>>>13,te=0|a[5],re=8191&te,ne=te>>>13,oe=0|a[6],ie=8191&oe,se=oe>>>13,ae=0|a[7],le=8191&ae,ce=ae>>>13,ue=0|a[8],de=8191&ue,pe=ue>>>13,he=0|a[9],fe=8191&he,me=he>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(c+(n=Math.imul(d,L))|0)+((8191&(o=(o=Math.imul(d,V))+Math.imul(p,L)|0))<<13)|0;c=((i=Math.imul(p,V))+(o>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(f,L),o=(o=Math.imul(f,V))+Math.imul(m,L)|0,i=Math.imul(m,V);var ye=(c+(n=n+Math.imul(d,H)|0)|0)+((8191&(o=(o=o+Math.imul(d,z)|0)+Math.imul(p,H)|0))<<13)|0;c=((i=i+Math.imul(p,z)|0)+(o>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(y,L),o=(o=Math.imul(y,V))+Math.imul(b,L)|0,i=Math.imul(b,V),n=n+Math.imul(f,H)|0,o=(o=o+Math.imul(f,z)|0)+Math.imul(m,H)|0,i=i+Math.imul(m,z)|0;var be=(c+(n=n+Math.imul(d,G)|0)|0)+((8191&(o=(o=o+Math.imul(d,X)|0)+Math.imul(p,G)|0))<<13)|0;c=((i=i+Math.imul(p,X)|0)+(o>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(v,L),o=(o=Math.imul(v,V))+Math.imul(w,L)|0,i=Math.imul(w,V),n=n+Math.imul(y,H)|0,o=(o=o+Math.imul(y,z)|0)+Math.imul(b,H)|0,i=i+Math.imul(b,z)|0,n=n+Math.imul(f,G)|0,o=(o=o+Math.imul(f,X)|0)+Math.imul(m,G)|0,i=i+Math.imul(m,X)|0;var xe=(c+(n=n+Math.imul(d,q)|0)|0)+((8191&(o=(o=o+Math.imul(d,Q)|0)+Math.imul(p,q)|0))<<13)|0;c=((i=i+Math.imul(p,Q)|0)+(o>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(A,L),o=(o=Math.imul(A,V))+Math.imul(C,L)|0,i=Math.imul(C,V),n=n+Math.imul(v,H)|0,o=(o=o+Math.imul(v,z)|0)+Math.imul(w,H)|0,i=i+Math.imul(w,z)|0,n=n+Math.imul(y,G)|0,o=(o=o+Math.imul(y,X)|0)+Math.imul(b,G)|0,i=i+Math.imul(b,X)|0,n=n+Math.imul(f,q)|0,o=(o=o+Math.imul(f,Q)|0)+Math.imul(m,q)|0,i=i+Math.imul(m,Q)|0;var ve=(c+(n=n+Math.imul(d,$)|0)|0)+((8191&(o=(o=o+Math.imul(d,ee)|0)+Math.imul(p,$)|0))<<13)|0;c=((i=i+Math.imul(p,ee)|0)+(o>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(R,L),o=(o=Math.imul(R,V))+Math.imul(T,L)|0,i=Math.imul(T,V),n=n+Math.imul(A,H)|0,o=(o=o+Math.imul(A,z)|0)+Math.imul(C,H)|0,i=i+Math.imul(C,z)|0,n=n+Math.imul(v,G)|0,o=(o=o+Math.imul(v,X)|0)+Math.imul(w,G)|0,i=i+Math.imul(w,X)|0,n=n+Math.imul(y,q)|0,o=(o=o+Math.imul(y,Q)|0)+Math.imul(b,q)|0,i=i+Math.imul(b,Q)|0,n=n+Math.imul(f,$)|0,o=(o=o+Math.imul(f,ee)|0)+Math.imul(m,$)|0,i=i+Math.imul(m,ee)|0;var we=(c+(n=n+Math.imul(d,re)|0)|0)+((8191&(o=(o=o+Math.imul(d,ne)|0)+Math.imul(p,re)|0))<<13)|0;c=((i=i+Math.imul(p,ne)|0)+(o>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(N,L),o=(o=Math.imul(N,V))+Math.imul(M,L)|0,i=Math.imul(M,V),n=n+Math.imul(R,H)|0,o=(o=o+Math.imul(R,z)|0)+Math.imul(T,H)|0,i=i+Math.imul(T,z)|0,n=n+Math.imul(A,G)|0,o=(o=o+Math.imul(A,X)|0)+Math.imul(C,G)|0,i=i+Math.imul(C,X)|0,n=n+Math.imul(v,q)|0,o=(o=o+Math.imul(v,Q)|0)+Math.imul(w,q)|0,i=i+Math.imul(w,Q)|0,n=n+Math.imul(y,$)|0,o=(o=o+Math.imul(y,ee)|0)+Math.imul(b,$)|0,i=i+Math.imul(b,ee)|0,n=n+Math.imul(f,re)|0,o=(o=o+Math.imul(f,ne)|0)+Math.imul(m,re)|0,i=i+Math.imul(m,ne)|0;var Ee=(c+(n=n+Math.imul(d,ie)|0)|0)+((8191&(o=(o=o+Math.imul(d,se)|0)+Math.imul(p,ie)|0))<<13)|0;c=((i=i+Math.imul(p,se)|0)+(o>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(O,L),o=(o=Math.imul(O,V))+Math.imul(I,L)|0,i=Math.imul(I,V),n=n+Math.imul(N,H)|0,o=(o=o+Math.imul(N,z)|0)+Math.imul(M,H)|0,i=i+Math.imul(M,z)|0,n=n+Math.imul(R,G)|0,o=(o=o+Math.imul(R,X)|0)+Math.imul(T,G)|0,i=i+Math.imul(T,X)|0,n=n+Math.imul(A,q)|0,o=(o=o+Math.imul(A,Q)|0)+Math.imul(C,q)|0,i=i+Math.imul(C,Q)|0,n=n+Math.imul(v,$)|0,o=(o=o+Math.imul(v,ee)|0)+Math.imul(w,$)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(y,re)|0,o=(o=o+Math.imul(y,ne)|0)+Math.imul(b,re)|0,i=i+Math.imul(b,ne)|0,n=n+Math.imul(f,ie)|0,o=(o=o+Math.imul(f,se)|0)+Math.imul(m,ie)|0,i=i+Math.imul(m,se)|0;var Ae=(c+(n=n+Math.imul(d,le)|0)|0)+((8191&(o=(o=o+Math.imul(d,ce)|0)+Math.imul(p,le)|0))<<13)|0;c=((i=i+Math.imul(p,ce)|0)+(o>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(D,L),o=(o=Math.imul(D,V))+Math.imul(B,L)|0,i=Math.imul(B,V),n=n+Math.imul(O,H)|0,o=(o=o+Math.imul(O,z)|0)+Math.imul(I,H)|0,i=i+Math.imul(I,z)|0,n=n+Math.imul(N,G)|0,o=(o=o+Math.imul(N,X)|0)+Math.imul(M,G)|0,i=i+Math.imul(M,X)|0,n=n+Math.imul(R,q)|0,o=(o=o+Math.imul(R,Q)|0)+Math.imul(T,q)|0,i=i+Math.imul(T,Q)|0,n=n+Math.imul(A,$)|0,o=(o=o+Math.imul(A,ee)|0)+Math.imul(C,$)|0,i=i+Math.imul(C,ee)|0,n=n+Math.imul(v,re)|0,o=(o=o+Math.imul(v,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(y,ie)|0,o=(o=o+Math.imul(y,se)|0)+Math.imul(b,ie)|0,i=i+Math.imul(b,se)|0,n=n+Math.imul(f,le)|0,o=(o=o+Math.imul(f,ce)|0)+Math.imul(m,le)|0,i=i+Math.imul(m,ce)|0;var Ce=(c+(n=n+Math.imul(d,de)|0)|0)+((8191&(o=(o=o+Math.imul(d,pe)|0)+Math.imul(p,de)|0))<<13)|0;c=((i=i+Math.imul(p,pe)|0)+(o>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(W,L),o=(o=Math.imul(W,V))+Math.imul(_,L)|0,i=Math.imul(_,V),n=n+Math.imul(D,H)|0,o=(o=o+Math.imul(D,z)|0)+Math.imul(B,H)|0,i=i+Math.imul(B,z)|0,n=n+Math.imul(O,G)|0,o=(o=o+Math.imul(O,X)|0)+Math.imul(I,G)|0,i=i+Math.imul(I,X)|0,n=n+Math.imul(N,q)|0,o=(o=o+Math.imul(N,Q)|0)+Math.imul(M,q)|0,i=i+Math.imul(M,Q)|0,n=n+Math.imul(R,$)|0,o=(o=o+Math.imul(R,ee)|0)+Math.imul(T,$)|0,i=i+Math.imul(T,ee)|0,n=n+Math.imul(A,re)|0,o=(o=o+Math.imul(A,ne)|0)+Math.imul(C,re)|0,i=i+Math.imul(C,ne)|0,n=n+Math.imul(v,ie)|0,o=(o=o+Math.imul(v,se)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,se)|0,n=n+Math.imul(y,le)|0,o=(o=o+Math.imul(y,ce)|0)+Math.imul(b,le)|0,i=i+Math.imul(b,ce)|0,n=n+Math.imul(f,de)|0,o=(o=o+Math.imul(f,pe)|0)+Math.imul(m,de)|0,i=i+Math.imul(m,pe)|0;var ke=(c+(n=n+Math.imul(d,fe)|0)|0)+((8191&(o=(o=o+Math.imul(d,me)|0)+Math.imul(p,fe)|0))<<13)|0;c=((i=i+Math.imul(p,me)|0)+(o>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(W,H),o=(o=Math.imul(W,z))+Math.imul(_,H)|0,i=Math.imul(_,z),n=n+Math.imul(D,G)|0,o=(o=o+Math.imul(D,X)|0)+Math.imul(B,G)|0,i=i+Math.imul(B,X)|0,n=n+Math.imul(O,q)|0,o=(o=o+Math.imul(O,Q)|0)+Math.imul(I,q)|0,i=i+Math.imul(I,Q)|0,n=n+Math.imul(N,$)|0,o=(o=o+Math.imul(N,ee)|0)+Math.imul(M,$)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(R,re)|0,o=(o=o+Math.imul(R,ne)|0)+Math.imul(T,re)|0,i=i+Math.imul(T,ne)|0,n=n+Math.imul(A,ie)|0,o=(o=o+Math.imul(A,se)|0)+Math.imul(C,ie)|0,i=i+Math.imul(C,se)|0,n=n+Math.imul(v,le)|0,o=(o=o+Math.imul(v,ce)|0)+Math.imul(w,le)|0,i=i+Math.imul(w,ce)|0,n=n+Math.imul(y,de)|0,o=(o=o+Math.imul(y,pe)|0)+Math.imul(b,de)|0,i=i+Math.imul(b,pe)|0;var Re=(c+(n=n+Math.imul(f,fe)|0)|0)+((8191&(o=(o=o+Math.imul(f,me)|0)+Math.imul(m,fe)|0))<<13)|0;c=((i=i+Math.imul(m,me)|0)+(o>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(W,G),o=(o=Math.imul(W,X))+Math.imul(_,G)|0,i=Math.imul(_,X),n=n+Math.imul(D,q)|0,o=(o=o+Math.imul(D,Q)|0)+Math.imul(B,q)|0,i=i+Math.imul(B,Q)|0,n=n+Math.imul(O,$)|0,o=(o=o+Math.imul(O,ee)|0)+Math.imul(I,$)|0,i=i+Math.imul(I,ee)|0,n=n+Math.imul(N,re)|0,o=(o=o+Math.imul(N,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(R,ie)|0,o=(o=o+Math.imul(R,se)|0)+Math.imul(T,ie)|0,i=i+Math.imul(T,se)|0,n=n+Math.imul(A,le)|0,o=(o=o+Math.imul(A,ce)|0)+Math.imul(C,le)|0,i=i+Math.imul(C,ce)|0,n=n+Math.imul(v,de)|0,o=(o=o+Math.imul(v,pe)|0)+Math.imul(w,de)|0,i=i+Math.imul(w,pe)|0;var Te=(c+(n=n+Math.imul(y,fe)|0)|0)+((8191&(o=(o=o+Math.imul(y,me)|0)+Math.imul(b,fe)|0))<<13)|0;c=((i=i+Math.imul(b,me)|0)+(o>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(W,q),o=(o=Math.imul(W,Q))+Math.imul(_,q)|0,i=Math.imul(_,Q),n=n+Math.imul(D,$)|0,o=(o=o+Math.imul(D,ee)|0)+Math.imul(B,$)|0,i=i+Math.imul(B,ee)|0,n=n+Math.imul(O,re)|0,o=(o=o+Math.imul(O,ne)|0)+Math.imul(I,re)|0,i=i+Math.imul(I,ne)|0,n=n+Math.imul(N,ie)|0,o=(o=o+Math.imul(N,se)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,se)|0,n=n+Math.imul(R,le)|0,o=(o=o+Math.imul(R,ce)|0)+Math.imul(T,le)|0,i=i+Math.imul(T,ce)|0,n=n+Math.imul(A,de)|0,o=(o=o+Math.imul(A,pe)|0)+Math.imul(C,de)|0,i=i+Math.imul(C,pe)|0;var Se=(c+(n=n+Math.imul(v,fe)|0)|0)+((8191&(o=(o=o+Math.imul(v,me)|0)+Math.imul(w,fe)|0))<<13)|0;c=((i=i+Math.imul(w,me)|0)+(o>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(W,$),o=(o=Math.imul(W,ee))+Math.imul(_,$)|0,i=Math.imul(_,ee),n=n+Math.imul(D,re)|0,o=(o=o+Math.imul(D,ne)|0)+Math.imul(B,re)|0,i=i+Math.imul(B,ne)|0,n=n+Math.imul(O,ie)|0,o=(o=o+Math.imul(O,se)|0)+Math.imul(I,ie)|0,i=i+Math.imul(I,se)|0,n=n+Math.imul(N,le)|0,o=(o=o+Math.imul(N,ce)|0)+Math.imul(M,le)|0,i=i+Math.imul(M,ce)|0,n=n+Math.imul(R,de)|0,o=(o=o+Math.imul(R,pe)|0)+Math.imul(T,de)|0,i=i+Math.imul(T,pe)|0;var Ne=(c+(n=n+Math.imul(A,fe)|0)|0)+((8191&(o=(o=o+Math.imul(A,me)|0)+Math.imul(C,fe)|0))<<13)|0;c=((i=i+Math.imul(C,me)|0)+(o>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,n=Math.imul(W,re),o=(o=Math.imul(W,ne))+Math.imul(_,re)|0,i=Math.imul(_,ne),n=n+Math.imul(D,ie)|0,o=(o=o+Math.imul(D,se)|0)+Math.imul(B,ie)|0,i=i+Math.imul(B,se)|0,n=n+Math.imul(O,le)|0,o=(o=o+Math.imul(O,ce)|0)+Math.imul(I,le)|0,i=i+Math.imul(I,ce)|0,n=n+Math.imul(N,de)|0,o=(o=o+Math.imul(N,pe)|0)+Math.imul(M,de)|0,i=i+Math.imul(M,pe)|0;var Me=(c+(n=n+Math.imul(R,fe)|0)|0)+((8191&(o=(o=o+Math.imul(R,me)|0)+Math.imul(T,fe)|0))<<13)|0;c=((i=i+Math.imul(T,me)|0)+(o>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(W,ie),o=(o=Math.imul(W,se))+Math.imul(_,ie)|0,i=Math.imul(_,se),n=n+Math.imul(D,le)|0,o=(o=o+Math.imul(D,ce)|0)+Math.imul(B,le)|0,i=i+Math.imul(B,ce)|0,n=n+Math.imul(O,de)|0,o=(o=o+Math.imul(O,pe)|0)+Math.imul(I,de)|0,i=i+Math.imul(I,pe)|0;var Fe=(c+(n=n+Math.imul(N,fe)|0)|0)+((8191&(o=(o=o+Math.imul(N,me)|0)+Math.imul(M,fe)|0))<<13)|0;c=((i=i+Math.imul(M,me)|0)+(o>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,n=Math.imul(W,le),o=(o=Math.imul(W,ce))+Math.imul(_,le)|0,i=Math.imul(_,ce),n=n+Math.imul(D,de)|0,o=(o=o+Math.imul(D,pe)|0)+Math.imul(B,de)|0,i=i+Math.imul(B,pe)|0;var Oe=(c+(n=n+Math.imul(O,fe)|0)|0)+((8191&(o=(o=o+Math.imul(O,me)|0)+Math.imul(I,fe)|0))<<13)|0;c=((i=i+Math.imul(I,me)|0)+(o>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(W,de),o=(o=Math.imul(W,pe))+Math.imul(_,de)|0,i=Math.imul(_,pe);var Ie=(c+(n=n+Math.imul(D,fe)|0)|0)+((8191&(o=(o=o+Math.imul(D,me)|0)+Math.imul(B,fe)|0))<<13)|0;c=((i=i+Math.imul(B,me)|0)+(o>>>13)|0)+(Ie>>>26)|0,Ie&=67108863;var je=(c+(n=Math.imul(W,fe))|0)+((8191&(o=(o=Math.imul(W,me))+Math.imul(_,fe)|0))<<13)|0;return c=((i=Math.imul(_,me))+(o>>>13)|0)+(je>>>26)|0,je&=67108863,l[0]=ge,l[1]=ye,l[2]=be,l[3]=xe,l[4]=ve,l[5]=we,l[6]=Ee,l[7]=Ae,l[8]=Ce,l[9]=ke,l[10]=Re,l[11]=Te,l[12]=Se,l[13]=Ne,l[14]=Me,l[15]=Fe,l[16]=Oe,l[17]=Ie,l[18]=je,0!==c&&(l[19]=c,r.length++),r};function g(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,o=0,i=0;i<r.length-1;i++){var s=o;o=0;for(var a=67108863&n,l=Math.min(i,t.length-1),c=Math.max(0,i-e.length+1);c<=l;c++){var u=i-c,d=(0|e.words[u])*(0|t.words[c]),p=67108863&d;a=67108863&(p=p+a|0),o+=(s=(s=s+(d/67108864|0)|0)+(p>>>26)|0)>>>26,s&=67108863}r.words[i]=a,n=s,s=o}return 0!==n?r.words[i]=n:r.length--,r._strip()}function y(e,t,r){return g(e,t,r)}Math.imul||(m=f),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?m(this,e,t):r<63?f(this,e,t):r<1024?g(this,e,t):y(this,e,t)},o.prototype.mul=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},o.prototype.mulf=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),y(this,e,t)},o.prototype.imul=function(e){return this.clone().mulTo(e,this)},o.prototype.imuln=function(e){var t=e<0;t&&(e=-e),r("number"==typeof e),r(e<67108864);for(var n=0,o=0;o<this.length;o++){var i=(0|this.words[o])*e,s=(67108863&i)+(67108863&n);n>>=26,n+=i/67108864|0,n+=s>>>26,this.words[o]=67108863&s}return 0!==n&&(this.words[o]=n,this.length++),t?this.ineg():this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r<t.length;r++){var n=r/26|0,o=r%26;t[r]=e.words[n]>>>o&1}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n<t.length&&0===t[n];n++,r=r.sqr());if(++n<t.length)for(var i=r.sqr();n<t.length;n++,i=i.sqr())0!==t[n]&&(r=r.mul(i));return r},o.prototype.iushln=function(e){r("number"==typeof e&&e>=0);var t,n=e%26,o=(e-n)/26,i=67108863>>>26-n<<26-n;if(0!==n){var s=0;for(t=0;t<this.length;t++){var a=this.words[t]&i,l=(0|this.words[t])-a<<n;this.words[t]=l|s,s=a>>>26-n}s&&(this.words[t]=s,this.length++)}if(0!==o){for(t=this.length-1;t>=0;t--)this.words[t+o]=this.words[t];for(t=0;t<o;t++)this.words[t]=0;this.length+=o}return this._strip()},o.prototype.ishln=function(e){return r(0===this.negative),this.iushln(e)},o.prototype.iushrn=function(e,t,n){var o;r("number"==typeof e&&e>=0),o=t?(t-t%26)/26:0;var i=e%26,s=Math.min((e-i)/26,this.length),a=67108863^67108863>>>i<<i,l=n;if(o-=s,o=Math.max(0,o),l){for(var c=0;c<s;c++)l.words[c]=this.words[c];l.length=s}if(0===s);else if(this.length>s)for(this.length-=s,c=0;c<this.length;c++)this.words[c]=this.words[c+s];else this.words[0]=0,this.length=1;var u=0;for(c=this.length-1;c>=0&&(0!==u||c>=o);c--){var d=0|this.words[c];this.words[c]=u<<26-i|d>>>i,u=d&a}return l&&0!==u&&(l.words[l.length++]=u),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(e,t,n){return r(0===this.negative),this.iushrn(e,t,n)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){r("number"==typeof e&&e>=0);var t=e%26,n=(e-t)/26,o=1<<t;return!(this.length<=n||!(this.words[n]&o))},o.prototype.imaskn=function(e){r("number"==typeof e&&e>=0);var t=e%26,n=(e-t)/26;if(r(0===this.negative,"imaskn works only with positive numbers"),this.length<=n)return this;if(0!==t&&n++,this.length=Math.min(n,this.length),0!==t){var o=67108863^67108863>>>t<<t;this.words[this.length-1]&=o}return this._strip()},o.prototype.maskn=function(e){return this.clone().imaskn(e)},o.prototype.iaddn=function(e){return r("number"==typeof e),r(e<67108864),e<0?this.isubn(-e):0!==this.negative?1===this.length&&(0|this.words[0])<=e?(this.words[0]=e-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(e),this.negative=1,this):this._iaddn(e)},o.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&this.words[t]>=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(r("number"==typeof e),r(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this._strip()},o.prototype.addn=function(e){return this.clone().iaddn(e)},o.prototype.subn=function(e){return this.clone().isubn(e)},o.prototype.iabs=function(){return this.negative=0,this},o.prototype.abs=function(){return this.clone().iabs()},o.prototype._ishlnsubmul=function(e,t,n){var o,i,s=e.length+n;this._expand(s);var a=0;for(o=0;o<e.length;o++){i=(0|this.words[o+n])+a;var l=(0|e.words[o])*t;a=((i-=67108863&l)>>26)-(l/67108864|0),this.words[o+n]=67108863&i}for(;o<this.length-n;o++)a=(i=(0|this.words[o+n])+a)>>26,this.words[o+n]=67108863&i;if(0===a)return this._strip();for(r(-1===a),a=0,o=0;o<this.length;o++)a=(i=-(0|this.words[o])+a)>>26,this.words[o]=67108863&i;return this.negative=1,this._strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,s=0|i.words[i.length-1];0!=(r=26-this._countBits(s))&&(i=i.ushln(r),n.iushln(r),s=0|i.words[i.length-1]);var a,l=n.length-i.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var c=0;c<a.length;c++)a.words[c]=0}var u=n.clone()._ishlnsubmul(i,1,l);0===u.negative&&(n=u,a&&(a.words[l]=1));for(var d=l-1;d>=0;d--){var p=67108864*(0|n.words[i.length+d])+(0|n.words[i.length+d-1]);for(p=Math.min(p/s|0,67108863),n._ishlnsubmul(i,p,d);0!==n.negative;)p--,n.negative=0,n._ishlnsubmul(i,1,d),n.isZero()||(n.negative^=1);a&&(a.words[d]=p)}return a&&a._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:a||null,mod:n}},o.prototype.divmod=function(e,t,n){return r(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(i=a.div.neg()),"div"!==t&&(s=a.mod.neg(),n&&0!==s.negative&&s.iadd(e)),{div:i,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(i=a.div.neg()),{div:i,mod:a.mod}):0!=(this.negative&e.negative)?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),n&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modrn(e.words[0]))}:this._wordDiv(e,t);var i,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),o=e.andln(1),i=r.cmp(n);return i<0||1===o&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modrn=function(e){var t=e<0;t&&(e=-e),r(e<=67108863);for(var n=(1<<26)%e,o=0,i=this.length-1;i>=0;i--)o=(n*o+(0|this.words[i]))%e;return t?-o:o},o.prototype.modn=function(e){return this.modrn(e)},o.prototype.idivn=function(e){var t=e<0;t&&(e=-e),r(e<=67108863);for(var n=0,o=this.length-1;o>=0;o--){var i=(0|this.words[o])+67108864*n;this.words[o]=i/e|0,n=i%e}return this._strip(),t?this.ineg():this},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){r(0===e.negative),r(!e.isZero());var t=this,n=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),s=new o(0),a=new o(0),l=new o(1),c=0;t.isEven()&&n.isEven();)t.iushrn(1),n.iushrn(1),++c;for(var u=n.clone(),d=t.clone();!t.isZero();){for(var p=0,h=1;0==(t.words[0]&h)&&p<26;++p,h<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(i.isOdd()||s.isOdd())&&(i.iadd(u),s.isub(d)),i.iushrn(1),s.iushrn(1);for(var f=0,m=1;0==(n.words[0]&m)&&f<26;++f,m<<=1);if(f>0)for(n.iushrn(f);f-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(u),l.isub(d)),a.iushrn(1),l.iushrn(1);t.cmp(n)>=0?(t.isub(n),i.isub(a),s.isub(l)):(n.isub(t),a.isub(i),l.isub(s))}return{a:a,b:l,gcd:n.iushln(c)}},o.prototype._invmp=function(e){r(0===e.negative),r(!e.isZero());var t=this,n=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,s=new o(1),a=new o(0),l=n.clone();t.cmpn(1)>0&&n.cmpn(1)>0;){for(var c=0,u=1;0==(t.words[0]&u)&&c<26;++c,u<<=1);if(c>0)for(t.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var d=0,p=1;0==(n.words[0]&p)&&d<26;++d,p<<=1);if(d>0)for(n.iushrn(d);d-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(n)>=0?(t.isub(n),s.isub(a)):(n.isub(t),a.isub(s))}return(i=0===t.cmpn(1)?s:a).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var o=t.cmp(r);if(o<0){var i=t;t=r,r=i}else if(0===o||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){r("number"==typeof e);var t=e%26,n=(e-t)/26,o=1<<t;if(this.length<=n)return this._expand(n+1),this.words[n]|=o,this;for(var i=o,s=n;0!==i&&s<this.length;s++){var a=0|this.words[s];i=(a+=i)>>>26,a&=67108863,this.words[s]=a}return 0!==i&&(this.words[s]=i,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,n=e<0;if(0!==this.negative&&!n)return-1;if(0===this.negative&&n)return 1;if(this._strip(),this.length>1)t=1;else{n&&(e=-e),r(e<=67108863,"Number is too big");var o=0|this.words[0];t=o===e?0:o<e?-1:1}return 0!==this.negative?0|-t:t},o.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},o.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,r=this.length-1;r>=0;r--){var n=0|this.words[r],o=0|e.words[r];if(n!==o){n<o?t=-1:n>o&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new C(e)},o.prototype.toRed=function(e){return r(!this.red,"Already a number in reduction context"),r(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return r(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return r(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var b={k256:null,p224:null,p192:null,p25519:null};function x(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){x.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){x.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function E(){x.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function A(){x.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function C(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else r(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function k(e){C.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}x.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},x.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t<this.n?-1:r.ucmp(this.p);return 0===n?(r.words[0]=0,r.length=1):n>0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},x.prototype.split=function(e,t){e.iushrn(this.n,0,t)},x.prototype.imulK=function(e){return e.imul(this.k)},n(v,x),v.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),o=0;o<n;o++)t.words[o]=e.words[o];if(t.length=n,e.length<=9)return e.words[0]=0,void(e.length=1);var i=e.words[9];for(t.words[t.length++]=i&r,o=10;o<e.length;o++){var s=0|e.words[o];e.words[o-10]=(s&r)<<4|i>>>22,i=s}i>>>=22,e.words[o-10]=i,0===i&&e.length>10?e.length-=10:e.length-=9},v.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r<e.length;r++){var n=0|e.words[r];t+=977*n,e.words[r]=67108863&t,t=64*n+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},n(w,x),n(E,x),n(A,x),A.prototype.imulK=function(e){for(var t=0,r=0;r<e.length;r++){var n=19*(0|e.words[r])+t,o=67108863&n;n>>>=26,e.words[r]=o,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(b[e])return b[e];var t;if("k256"===e)t=new v;else if("p224"===e)t=new w;else if("p192"===e)t=new E;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new A}return b[e]=t,t},C.prototype._verify1=function(e){r(0===e.negative,"red works only with positives"),r(e.red,"red works only with red numbers")},C.prototype._verify2=function(e,t){r(0==(e.negative|t.negative),"red works only with positives"),r(e.red&&e.red===t.red,"red works only with red numbers")},C.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(c(e,e.umod(this.m)._forceRed(this)),e)},C.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},C.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},C.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},C.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},C.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},C.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},C.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},C.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},C.prototype.isqr=function(e){return this.imul(e,e.clone())},C.prototype.sqr=function(e){return this.mul(e,e)},C.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(r(t%2==1),3===t){var n=this.m.add(new o(1)).iushrn(2);return this.pow(e,n)}for(var i=this.m.subn(1),s=0;!i.isZero()&&0===i.andln(1);)s++,i.iushrn(1);r(!i.isZero());var a=new o(1).toRed(this),l=a.redNeg(),c=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new o(2*u*u).toRed(this);0!==this.pow(u,c).cmp(l);)u.redIAdd(l);for(var d=this.pow(u,i),p=this.pow(e,i.addn(1).iushrn(1)),h=this.pow(e,i),f=s;0!==h.cmp(a);){for(var m=h,g=0;0!==m.cmp(a);g++)m=m.redSqr();r(g<f);var y=this.pow(d,new o(1).iushln(f-g-1));p=p.redMul(y),d=y.redSqr(),h=h.redMul(d),f=g}return p},C.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},C.prototype.pow=function(e,t){if(t.isZero())return new o(1).toRed(this);if(0===t.cmpn(1))return e.clone();var r=new Array(16);r[0]=new o(1).toRed(this),r[1]=e;for(var n=2;n<r.length;n++)r[n]=this.mul(r[n-1],e);var i=r[0],s=0,a=0,l=t.bitLength()%26;for(0===l&&(l=26),n=t.length-1;n>=0;n--){for(var c=t.words[n],u=l-1;u>=0;u--){var d=c>>u&1;i!==r[0]&&(i=this.sqr(i)),0!==d||0!==s?(s<<=1,s|=d,(4==++a||0===n&&0===u)&&(i=this.mul(i,r[s]),a=0,s=0)):a=0}l=26}return i},C.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},C.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new k(e)},n(k,C),k.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},k.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},k.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),o=r.isub(n).iushrn(this.shift),i=o;return o.cmp(this.m)>=0?i=o.isub(this.m):o.cmpn(0)<0&&(i=o.iadd(this.m)),i._forceRed(this)},k.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),s=i;return i.cmp(this.m)>=0?s=i.isub(this.m):i.cmpn(0)<0&&(s=i.iadd(this.m)),s._forceRed(this)},k.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(pd,I);var hd=pd.exports;function fd(e,t,r){return r={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&r.path)}},e(r,r.exports),r.exports}var md=gd;function gd(e,t){if(!e)throw new Error(t||"Assertion failed")}gd.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var yd=fd((function(e,t){var r=t;function n(e){return 1===e.length?"0"+e:e}function o(e){for(var t="",r=0;r<e.length;r++)t+=n(e[r].toString(16));return t}r.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"!=typeof e){for(var n=0;n<e.length;n++)r[n]=0|e[n];return r}if("hex"===t){(e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e);for(n=0;n<e.length;n+=2)r.push(parseInt(e[n]+e[n+1],16))}else for(n=0;n<e.length;n++){var o=e.charCodeAt(n),i=o>>8,s=255&o;i?r.push(i,s):r.push(s)}return r},r.zero2=n,r.toHex=o,r.encode=function(e,t){return"hex"===t?o(e):e}})),bd=fd((function(e,t){var r=t;r.assert=md,r.toArray=yd.toArray,r.zero2=yd.zero2,r.toHex=yd.toHex,r.encode=yd.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var o=1<<t+1,i=e.clone(),s=0;s<n.length;s++){var a,l=i.andln(o-1);i.isOdd()?(a=l>(o>>1)-1?(o>>1)-l:l,i.isubn(a)):a=0,n[s]=a,i.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,o=0,i=0;e.cmpn(-o)>0||t.cmpn(-i)>0;){var s,a,l=e.andln(3)+o&3,c=t.andln(3)+i&3;3===l&&(l=-1),3===c&&(c=-1),s=0==(1&l)?0:3!==(n=e.andln(7)+o&7)&&5!==n||2!==c?l:-l,r[0].push(s),a=0==(1&c)?0:3!==(n=t.andln(7)+i&7)&&5!==n||2!==l?c:-c,r[1].push(a),2*o===s+1&&(o=1-o),2*i===a+1&&(i=1-i),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"==typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new hd(e,"hex","le")}})),xd=bd.getNAF,vd=bd.getJSF,wd=bd.assert;function Ed(e,t){this.type=e,this.p=new hd(t.p,16),this.red=t.prime?hd.red(t.prime):hd.mont(this.p),this.zero=new hd(0).toRed(this.red),this.one=new hd(1).toRed(this.red),this.two=new hd(2).toRed(this.red),this.n=t.n&&new hd(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var Ad=Ed;function Cd(e,t){this.curve=e,this.type=t,this.precomputed=null}Ed.prototype.point=function(){throw new Error("Not implemented")},Ed.prototype.validate=function(){throw new Error("Not implemented")},Ed.prototype._fixedNafMul=function(e,t){wd(e.precomputed);var r=e._getDoubles(),n=xd(t,1,this._bitLength),o=(1<<r.step+1)-(r.step%2==0?2:1);o/=3;var i,s,a=[];for(i=0;i<n.length;i+=r.step){s=0;for(var l=i+r.step-1;l>=i;l--)s=(s<<1)+n[l];a.push(s)}for(var c=this.jpoint(null,null,null),u=this.jpoint(null,null,null),d=o;d>0;d--){for(i=0;i<a.length;i++)(s=a[i])===d?u=u.mixedAdd(r.points[i]):s===-d&&(u=u.mixedAdd(r.points[i].neg()));c=c.add(u)}return c.toP()},Ed.prototype._wnafMul=function(e,t){var r=4,n=e._getNAFPoints(r);r=n.wnd;for(var o=n.points,i=xd(t,r,this._bitLength),s=this.jpoint(null,null,null),a=i.length-1;a>=0;a--){for(var l=0;a>=0&&0===i[a];a--)l++;if(a>=0&&l++,s=s.dblp(l),a<0)break;var c=i[a];wd(0!==c),s="affine"===e.type?c>0?s.mixedAdd(o[c-1>>1]):s.mixedAdd(o[-c-1>>1].neg()):c>0?s.add(o[c-1>>1]):s.add(o[-c-1>>1].neg())}return"affine"===e.type?s.toP():s},Ed.prototype._wnafMulAdd=function(e,t,r,n,o){var i,s,a,l=this._wnafT1,c=this._wnafT2,u=this._wnafT3,d=0;for(i=0;i<n;i++){var p=(a=t[i])._getNAFPoints(e);l[i]=p.wnd,c[i]=p.points}for(i=n-1;i>=1;i-=2){var h=i-1,f=i;if(1===l[h]&&1===l[f]){var m=[t[h],null,null,t[f]];0===t[h].y.cmp(t[f].y)?(m[1]=t[h].add(t[f]),m[2]=t[h].toJ().mixedAdd(t[f].neg())):0===t[h].y.cmp(t[f].y.redNeg())?(m[1]=t[h].toJ().mixedAdd(t[f]),m[2]=t[h].add(t[f].neg())):(m[1]=t[h].toJ().mixedAdd(t[f]),m[2]=t[h].toJ().mixedAdd(t[f].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],y=vd(r[h],r[f]);for(d=Math.max(y[0].length,d),u[h]=new Array(d),u[f]=new Array(d),s=0;s<d;s++){var b=0|y[0][s],x=0|y[1][s];u[h][s]=g[3*(b+1)+(x+1)],u[f][s]=0,c[h]=m}}else u[h]=xd(r[h],l[h],this._bitLength),u[f]=xd(r[f],l[f],this._bitLength),d=Math.max(u[h].length,d),d=Math.max(u[f].length,d)}var v=this.jpoint(null,null,null),w=this._wnafT4;for(i=d;i>=0;i--){for(var E=0;i>=0;){var A=!0;for(s=0;s<n;s++)w[s]=0|u[s][i],0!==w[s]&&(A=!1);if(!A)break;E++,i--}if(i>=0&&E++,v=v.dblp(E),i<0)break;for(s=0;s<n;s++){var C=w[s];0!==C&&(C>0?a=c[s][C-1>>1]:C<0&&(a=c[s][-C-1>>1].neg()),v="affine"===a.type?v.mixedAdd(a):v.add(a))}}for(i=0;i<n;i++)c[i]=null;return o?v:v.toP()},Ed.BasePoint=Cd,Cd.prototype.eq=function(){throw new Error("Not implemented")},Cd.prototype.validate=function(){return this.curve.validate(this)},Ed.prototype.decodePoint=function(e,t){e=bd.toArray(e,t);var r=this.p.byteLength();if((4===e[0]||6===e[0]||7===e[0])&&e.length-1==2*r)return 6===e[0]?wd(e[e.length-1]%2==0):7===e[0]&&wd(e[e.length-1]%2==1),this.point(e.slice(1,1+r),e.slice(1+r,1+2*r));if((2===e[0]||3===e[0])&&e.length-1===r)return this.pointFromX(e.slice(1,1+r),3===e[0]);throw new Error("Unknown point format")},Cd.prototype.encodeCompressed=function(e){return this.encode(e,!0)},Cd.prototype._encode=function(e){var t=this.curve.p.byteLength(),r=this.getX().toArray("be",t);return e?[this.getY().isEven()?2:3].concat(r):[4].concat(r,this.getY().toArray("be",t))},Cd.prototype.encode=function(e,t){return bd.encode(this._encode(t),e)},Cd.prototype.precompute=function(e){if(this.precomputed)return this;var t={doubles:null,naf:null,beta:null};return t.naf=this._getNAFPoints(8),t.doubles=this._getDoubles(4,e),t.beta=this._getBeta(),this.precomputed=t,this},Cd.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var t=this.precomputed.doubles;return!!t&&t.points.length>=Math.ceil((e.bitLength()+1)/t.step)},Cd.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,o=0;o<t;o+=e){for(var i=0;i<e;i++)n=n.dbl();r.push(n)}return{step:e,points:r}},Cd.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var t=[this],r=(1<<e)-1,n=1===r?null:this.dbl(),o=1;o<r;o++)t[o]=t[o-1].add(n);return{wnd:e,points:t}},Cd.prototype._getBeta=function(){return null},Cd.prototype.dblp=function(e){for(var t=this,r=0;r<e;r++)t=t.dbl();return t};var kd=fd((function(e){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}})),Rd=bd.assert;function Td(e){Ad.call(this,"short",e),this.a=new hd(e.a,16).toRed(this.red),this.b=new hd(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}kd(Td,Ad);var Sd=Td;function Nd(e,t,r,n){Ad.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new hd(t,16),this.y=new hd(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function Md(e,t,r,n){Ad.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new hd(0)):(this.x=new hd(t,16),this.y=new hd(r,16),this.z=new hd(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}Td.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new hd(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new hd(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],Rd(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new hd(e.a,16),b:new hd(e.b,16)}})):this._getEndoBasis(r)}}},Td.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:hd.mont(e),r=new hd(2).toRed(t).redInvm(),n=r.redNeg(),o=new hd(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(o).fromRed(),n.redSub(o).fromRed()]},Td.prototype._getEndoBasis=function(e){for(var t,r,n,o,i,s,a,l,c,u=this.n.ushrn(Math.floor(this.n.bitLength()/2)),d=e,p=this.n.clone(),h=new hd(1),f=new hd(0),m=new hd(0),g=new hd(1),y=0;0!==d.cmpn(0);){var b=p.div(d);l=p.sub(b.mul(d)),c=m.sub(b.mul(h));var x=g.sub(b.mul(f));if(!n&&l.cmp(u)<0)t=a.neg(),r=h,n=l.neg(),o=c;else if(n&&2==++y)break;a=l,p=d,d=l,m=h,h=c,g=f,f=x}i=l.neg(),s=c;var v=n.sqr().add(o.sqr());return i.sqr().add(s.sqr()).cmp(v)>=0&&(i=t,s=r),n.negative&&(n=n.neg(),o=o.neg()),i.negative&&(i=i.neg(),s=s.neg()),[{a:n,b:o},{a:i,b:s}]},Td.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],o=n.b.mul(e).divRound(this.n),i=r.b.neg().mul(e).divRound(this.n),s=o.mul(r.a),a=i.mul(n.a),l=o.mul(r.b),c=i.mul(n.b);return{k1:e.sub(s).sub(a),k2:l.add(c).neg()}},Td.prototype.pointFromX=function(e,t){(e=new hd(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=n.fromRed().isOdd();return(t&&!o||!t&&o)&&(n=n.redNeg()),this.point(e,n)},Td.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),o=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(o).cmpn(0)},Td.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,o=this._endoWnafT2,i=0;i<e.length;i++){var s=this._endoSplit(t[i]),a=e[i],l=a._getBeta();s.k1.negative&&(s.k1.ineg(),a=a.neg(!0)),s.k2.negative&&(s.k2.ineg(),l=l.neg(!0)),n[2*i]=a,n[2*i+1]=l,o[2*i]=s.k1,o[2*i+1]=s.k2}for(var c=this._wnafMulAdd(1,n,o,2*i,r),u=0;u<2*i;u++)n[u]=null,o[u]=null;return c},kd(Nd,Ad.BasePoint),Td.prototype.point=function(e,t,r){return new Nd(this,e,t,r)},Td.prototype.pointFromJSON=function(e,t){return Nd.fromJSON(this,e,t)},Nd.prototype._getBeta=function(){if(this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var t=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var r=this.curve,n=function(e){return r.point(e.x.redMul(r.endo.beta),e.y)};e.beta=t,t.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(n)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(n)}}}return t}},Nd.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},Nd.fromJSON=function(e,t,r){"string"==typeof t&&(t=JSON.parse(t));var n=e.point(t[0],t[1],r);if(!t[2])return n;function o(t){return e.point(t[0],t[1],r)}var i=t[2];return n.precomputed={beta:null,doubles:i.doubles&&{step:i.doubles.step,points:[n].concat(i.doubles.points.map(o))},naf:i.naf&&{wnd:i.naf.wnd,points:[n].concat(i.naf.points.map(o))}},n},Nd.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},Nd.prototype.isInfinity=function(){return this.inf},Nd.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},Nd.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),o=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),i=o.redSqr().redISub(this.x.redAdd(this.x)),s=o.redMul(this.x.redSub(i)).redISub(this.y);return this.curve.point(i,s)},Nd.prototype.getX=function(){return this.x.fromRed()},Nd.prototype.getY=function(){return this.y.fromRed()},Nd.prototype.mul=function(e){return e=new hd(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},Nd.prototype.mulAdd=function(e,t,r){var n=[this,t],o=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,o):this.curve._wnafMulAdd(1,n,o,2)},Nd.prototype.jmulAdd=function(e,t,r){var n=[this,t],o=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,o,!0):this.curve._wnafMulAdd(1,n,o,2,!0)},Nd.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},Nd.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},Nd.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},kd(Md,Ad.BasePoint),Td.prototype.jpoint=function(e,t,r){return new Md(this,e,t,r)},Md.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},Md.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},Md.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),o=e.x.redMul(r),i=this.y.redMul(t.redMul(e.z)),s=e.y.redMul(r.redMul(this.z)),a=n.redSub(o),l=i.redSub(s);if(0===a.cmpn(0))return 0!==l.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=a.redSqr(),u=c.redMul(a),d=n.redMul(c),p=l.redSqr().redIAdd(u).redISub(d).redISub(d),h=l.redMul(d.redISub(p)).redISub(i.redMul(u)),f=this.z.redMul(e.z).redMul(a);return this.curve.jpoint(p,h,f)},Md.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),o=this.y,i=e.y.redMul(t).redMul(this.z),s=r.redSub(n),a=o.redSub(i);if(0===s.cmpn(0))return 0!==a.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var l=s.redSqr(),c=l.redMul(s),u=r.redMul(l),d=a.redSqr().redIAdd(c).redISub(u).redISub(u),p=a.redMul(u.redISub(d)).redISub(o.redMul(c)),h=this.z.redMul(s);return this.curve.jpoint(d,p,h)},Md.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t<e;t++)r=r.dbl();return r}var n=this.curve.a,o=this.curve.tinv,i=this.x,s=this.y,a=this.z,l=a.redSqr().redSqr(),c=s.redAdd(s);for(t=0;t<e;t++){var u=i.redSqr(),d=c.redSqr(),p=d.redSqr(),h=u.redAdd(u).redIAdd(u).redIAdd(n.redMul(l)),f=i.redMul(d),m=h.redSqr().redISub(f.redAdd(f)),g=f.redISub(m),y=h.redMul(g);y=y.redIAdd(y).redISub(p);var b=c.redMul(a);t+1<e&&(l=l.redMul(p)),i=m,a=b,c=y}return this.curve.jpoint(i,c.redMul(o),a)},Md.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},Md.prototype._zeroDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),o=this.y.redSqr(),i=o.redSqr(),s=this.x.redAdd(o).redSqr().redISub(n).redISub(i);s=s.redIAdd(s);var a=n.redAdd(n).redIAdd(n),l=a.redSqr().redISub(s).redISub(s),c=i.redIAdd(i);c=(c=c.redIAdd(c)).redIAdd(c),e=l,t=a.redMul(s.redISub(l)).redISub(c),r=this.y.redAdd(this.y)}else{var u=this.x.redSqr(),d=this.y.redSqr(),p=d.redSqr(),h=this.x.redAdd(d).redSqr().redISub(u).redISub(p);h=h.redIAdd(h);var f=u.redAdd(u).redIAdd(u),m=f.redSqr(),g=p.redIAdd(p);g=(g=g.redIAdd(g)).redIAdd(g),e=m.redISub(h).redISub(h),t=f.redMul(h.redISub(e)).redISub(g),r=(r=this.y.redMul(this.z)).redIAdd(r)}return this.curve.jpoint(e,t,r)},Md.prototype._threeDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),o=this.y.redSqr(),i=o.redSqr(),s=this.x.redAdd(o).redSqr().redISub(n).redISub(i);s=s.redIAdd(s);var a=n.redAdd(n).redIAdd(n).redIAdd(this.curve.a),l=a.redSqr().redISub(s).redISub(s);e=l;var c=i.redIAdd(i);c=(c=c.redIAdd(c)).redIAdd(c),t=a.redMul(s.redISub(l)).redISub(c),r=this.y.redAdd(this.y)}else{var u=this.z.redSqr(),d=this.y.redSqr(),p=this.x.redMul(d),h=this.x.redSub(u).redMul(this.x.redAdd(u));h=h.redAdd(h).redIAdd(h);var f=p.redIAdd(p),m=(f=f.redIAdd(f)).redAdd(f);e=h.redSqr().redISub(m),r=this.y.redAdd(this.z).redSqr().redISub(d).redISub(u);var g=d.redSqr();g=(g=(g=g.redIAdd(g)).redIAdd(g)).redIAdd(g),t=h.redMul(f.redISub(e)).redISub(g)}return this.curve.jpoint(e,t,r)},Md.prototype._dbl=function(){var e=this.curve.a,t=this.x,r=this.y,n=this.z,o=n.redSqr().redSqr(),i=t.redSqr(),s=r.redSqr(),a=i.redAdd(i).redIAdd(i).redIAdd(e.redMul(o)),l=t.redAdd(t),c=(l=l.redIAdd(l)).redMul(s),u=a.redSqr().redISub(c.redAdd(c)),d=c.redISub(u),p=s.redSqr();p=(p=(p=p.redIAdd(p)).redIAdd(p)).redIAdd(p);var h=a.redMul(d).redISub(p),f=r.redAdd(r).redMul(n);return this.curve.jpoint(u,h,f)},Md.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr(),n=t.redSqr(),o=e.redAdd(e).redIAdd(e),i=o.redSqr(),s=this.x.redAdd(t).redSqr().redISub(e).redISub(n),a=(s=(s=(s=s.redIAdd(s)).redAdd(s).redIAdd(s)).redISub(i)).redSqr(),l=n.redIAdd(n);l=(l=(l=l.redIAdd(l)).redIAdd(l)).redIAdd(l);var c=o.redIAdd(s).redSqr().redISub(i).redISub(a).redISub(l),u=t.redMul(c);u=(u=u.redIAdd(u)).redIAdd(u);var d=this.x.redMul(a).redISub(u);d=(d=d.redIAdd(d)).redIAdd(d);var p=this.y.redMul(c.redMul(l.redISub(c)).redISub(s.redMul(a)));p=(p=(p=p.redIAdd(p)).redIAdd(p)).redIAdd(p);var h=this.z.redAdd(s).redSqr().redISub(r).redISub(a);return this.curve.jpoint(d,p,h)},Md.prototype.mul=function(e,t){return e=new hd(e,t),this.curve._wnafMul(this,e)},Md.prototype.eq=function(e){if("affine"===e.type)return this.eq(e.toJ());if(this===e)return!0;var t=this.z.redSqr(),r=e.z.redSqr();if(0!==this.x.redMul(r).redISub(e.x.redMul(t)).cmpn(0))return!1;var n=t.redMul(this.z),o=r.redMul(e.z);return 0===this.y.redMul(o).redISub(e.y.redMul(n)).cmpn(0)},Md.prototype.eqXToP=function(e){var t=this.z.redSqr(),r=e.toRed(this.curve.red).redMul(t);if(0===this.x.cmp(r))return!0;for(var n=e.clone(),o=this.curve.redN.redMul(t);;){if(n.iadd(this.curve.n),n.cmp(this.curve.p)>=0)return!1;if(r.redIAdd(o),0===this.x.cmp(r))return!0}},Md.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},Md.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var Fd=fd((function(e,t){var r=t;r.base=Ad,r.short=Sd,r.mont=null,r.edwards=null})),Od=fd((function(e,t){var r,n=t,o=bd.assert;function i(e){"short"===e.type?this.curve=new Fd.short(e):"edwards"===e.type?this.curve=new Fd.edwards(e):this.curve=new Fd.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,o(this.g.validate(),"Invalid curve"),o(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function s(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new i(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=i,s("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:Yu.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),s("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:Yu.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),s("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:Yu.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),s("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:Yu.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),s("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:Yu.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),s("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:Yu.sha256,gRed:!1,g:["9"]}),s("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:Yu.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(e){r=void 0}s("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:Yu.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function Id(e){if(!(this instanceof Id))return new Id(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=yd.toArray(e.entropy,e.entropyEnc||"hex"),r=yd.toArray(e.nonce,e.nonceEnc||"hex"),n=yd.toArray(e.pers,e.persEnc||"hex");md(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var jd=Id;Id.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var o=0;o<this.V.length;o++)this.K[o]=0,this.V[o]=1;this._update(n),this._reseed=1,this.reseedInterval=281474976710656},Id.prototype._hmac=function(){return new Yu.hmac(this.hash,this.K)},Id.prototype._update=function(e){var t=this._hmac().update(this.V).update([0]);e&&(t=t.update(e)),this.K=t.digest(),this.V=this._hmac().update(this.V).digest(),e&&(this.K=this._hmac().update(this.V).update([1]).update(e).digest(),this.V=this._hmac().update(this.V).digest())},Id.prototype.reseed=function(e,t,r,n){"string"!=typeof t&&(n=r,r=t,t=null),e=yd.toArray(e,t),r=yd.toArray(r,n),md(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},Id.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=yd.toArray(r,n||"hex"),this._update(r));for(var o=[];o.length<e;)this.V=this._hmac().update(this.V).digest(),o=o.concat(this.V);var i=o.slice(0,e);return this._update(r),this._reseed++,yd.encode(i,t)};var Dd=bd.assert;function Bd(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}var Pd=Bd;Bd.fromPublic=function(e,t,r){return t instanceof Bd?t:new Bd(e,{pub:t,pubEnc:r})},Bd.fromPrivate=function(e,t,r){return t instanceof Bd?t:new Bd(e,{priv:t,privEnc:r})},Bd.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},Bd.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},Bd.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},Bd.prototype._importPrivate=function(e,t){this.priv=new hd(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},Bd.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?Dd(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||Dd(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},Bd.prototype.derive=function(e){return e.validate()||Dd(e.validate(),"public point not validated"),e.mul(this.priv).getX()},Bd.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},Bd.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},Bd.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"};var Wd=bd.assert;function _d(e,t){if(e instanceof _d)return e;this._importDER(e,t)||(Wd(e.r&&e.s,"Signature without r or s"),this.r=new hd(e.r,16),this.s=new hd(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var Ud=_d;function Ld(){this.place=0}function Vd(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var o=0,i=0,s=t.place;i<n;i++,s++)o<<=8,o|=e[s],o>>>=0;return!(o<=127)&&(t.place=s,o)}function Zd(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t<r;)t++;return 0===t?e:e.slice(t)}function Hd(e,t){if(t<128)e.push(t);else{var r=1+(Math.log(t)/Math.LN2>>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}_d.prototype._importDER=function(e,t){e=bd.toArray(e,t);var r=new Ld;if(48!==e[r.place++])return!1;var n=Vd(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var o=Vd(e,r);if(!1===o)return!1;var i=e.slice(r.place,o+r.place);if(r.place+=o,2!==e[r.place++])return!1;var s=Vd(e,r);if(!1===s)return!1;if(e.length!==s+r.place)return!1;var a=e.slice(r.place,s+r.place);if(0===i[0]){if(!(128&i[1]))return!1;i=i.slice(1)}if(0===a[0]){if(!(128&a[1]))return!1;a=a.slice(1)}return this.r=new hd(i),this.s=new hd(a),this.recoveryParam=null,!0},_d.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=Zd(t),r=Zd(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];Hd(n,t.length),(n=n.concat(t)).push(2),Hd(n,r.length);var o=n.concat(r),i=[48];return Hd(i,o.length),i=i.concat(o),bd.encode(i,e)};var zd=function(){throw new Error("unsupported")},Yd=bd.assert;function Gd(e){if(!(this instanceof Gd))return new Gd(e);"string"==typeof e&&(Yd(Object.prototype.hasOwnProperty.call(Od,e),"Unknown curve "+e),e=Od[e]),e instanceof Od.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var Xd=Gd;Gd.prototype.keyPair=function(e){return new Pd(this,e)},Gd.prototype.keyFromPrivate=function(e,t){return Pd.fromPrivate(this,e,t)},Gd.prototype.keyFromPublic=function(e,t){return Pd.fromPublic(this,e,t)},Gd.prototype.genKeyPair=function(e){e||(e={});for(var t=new jd({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||zd(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new hd(2));;){var o=new hd(t.generate(r));if(!(o.cmp(n)>0))return o.iaddn(1),this.keyFromPrivate(o)}},Gd.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},Gd.prototype.sign=function(e,t,r,n){"object"==typeof r&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new hd(e,16));for(var o=this.n.byteLength(),i=t.getPrivate().toArray("be",o),s=e.toArray("be",o),a=new jd({hash:this.hash,entropy:i,nonce:s,pers:n.pers,persEnc:n.persEnc||"utf8"}),l=this.n.sub(new hd(1)),c=0;;c++){var u=n.k?n.k(c):new hd(a.generate(this.n.byteLength()));if(!((u=this._truncateToN(u,!0)).cmpn(1)<=0||u.cmp(l)>=0)){var d=this.g.mul(u);if(!d.isInfinity()){var p=d.getX(),h=p.umod(this.n);if(0!==h.cmpn(0)){var f=u.invm(this.n).mul(h.mul(t.getPrivate()).iadd(e));if(0!==(f=f.umod(this.n)).cmpn(0)){var m=(d.getY().isOdd()?1:0)|(0!==p.cmp(h)?2:0);return n.canonical&&f.cmp(this.nh)>0&&(f=this.n.sub(f),m^=1),new Ud({r:h,s:f,recoveryParam:m})}}}}}},Gd.prototype.verify=function(e,t,r,n){e=this._truncateToN(new hd(e,16)),r=this.keyFromPublic(r,n);var o=(t=new Ud(t,"hex")).r,i=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;var s,a=i.invm(this.n),l=a.mul(e).umod(this.n),c=a.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(l,r.getPublic(),c)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(l,r.getPublic(),c)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},Gd.prototype.recoverPubKey=function(e,t,r,n){Yd((3&r)===r,"The recovery param is more than two bits"),t=new Ud(t,n);var o=this.n,i=new hd(e),s=t.r,a=t.s,l=1&r,c=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&c)throw new Error("Unable to find sencond key candinate");s=c?this.curve.pointFromX(s.add(this.curve.n),l):this.curve.pointFromX(s,l);var u=t.r.invm(o),d=o.sub(i).mul(u).umod(o),p=a.mul(u).umod(o);return this.g.mulAdd(d,s,p)},Gd.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new Ud(t,n)).recoveryParam)return t.recoveryParam;for(var o=0;o<4;o++){var i;try{i=this.recoverPubKey(e,t,o)}catch(e){continue}if(i.eq(r))return o}throw new Error("Unable to find valid recovery factor")};var Jd=fd((function(e,t){var r=t;r.version="6.5.4",r.utils=bd,r.rand=function(){throw new Error("unsupported")},r.curve=Fd,r.curves=Od,r.ec=Xd,r.eddsa=null})).ec;const qd=new ks("signing-key/5.7.0");let Qd=null;function Kd(){return Qd||(Qd=new Jd("secp256k1")),Qd}class $d{constructor(e){wa(this,"curve","secp256k1"),wa(this,"privateKey",Bs(e)),32!==Ps(this.privateKey)&&qd.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");const t=Kd().keyFromPrivate(Os(this.privateKey));wa(this,"publicKey","0x"+t.getPublic(!1,"hex")),wa(this,"compressedPublicKey","0x"+t.getPublic(!0,"hex")),wa(this,"_isSigningKey",!0)}_addPoint(e){const t=Kd().keyFromPublic(Os(this.publicKey)),r=Kd().keyFromPublic(Os(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}signDigest(e){const t=Kd().keyFromPrivate(Os(this.privateKey)),r=Os(e);32!==r.length&&qd.throwArgumentError("bad digest length","digest",e);const n=t.sign(r,{canonical:!0});return Vs({recoveryParam:n.recoveryParam,r:Ls("0x"+n.r.toString(16),32),s:Ls("0x"+n.s.toString(16),32)})}computeSharedSecret(e){const t=Kd().keyFromPrivate(Os(this.privateKey)),r=Kd().keyFromPublic(Os(ep(e)));return Ls("0x"+t.derive(r.getPublic()).toString(16),32)}static isSigningKey(e){return!(!e||!e._isSigningKey)}}function ep(e,t){const r=Os(e);if(32===r.length){const e=new $d(r);return t?"0x"+Kd().keyFromPrivate(r).getPublic(!0,"hex"):e.publicKey}return 33===r.length?t?Bs(r):"0x"+Kd().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+Kd().keyFromPublic(r).getPublic(!0,"hex"):Bs(r):qd.throwArgumentError("invalid public or private key","key","[REDACTED]")}const tp=new ks("transactions/5.7.0");var rp;function np(e){return"0x"===e?null:oa(e)}function op(e){return"0x"===e?Ga:y.BigNumber.from(e)}function ip(e,t){return function(e){return oa(Ws(zs(Ws(ep(e),1)),12))}(function(e,t){const r=Vs(t),n={r:Os(r.r),s:Os(r.s)};return"0x"+Kd().recoverPubKey(Os(e),n,r.recoveryParam).encode("hex",!1)}(Os(e),t))}function sp(e,t){const r=js(y.BigNumber.from(e).toHexString());return r.length>32&&tp.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function ap(e,t){return{address:oa(e),storageKeys:(t||[]).map(((t,r)=>(32!==Ps(t)&&tp.throwArgumentError("invalid access list storageKey",`accessList[${e}:${r}]`,t),t.toLowerCase())))}}function lp(e){if(Array.isArray(e))return e.map(((e,t)=>Array.isArray(e)?(e.length>2&&tp.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${t}]`,e),ap(e[0],e[1])):ap(e.address,e.storageKeys)));const t=Object.keys(e).map((t=>{const r=e[t].reduce(((e,t)=>(e[t]=!0,e)),{});return ap(t,Object.keys(r).sort())}));return t.sort(((e,t)=>e.address.localeCompare(t.address))),t}function cp(e){return lp(e).map((e=>[e.address,e.storageKeys]))}function up(e,t){if(null!=e.gasPrice){const t=y.BigNumber.from(e.gasPrice),r=y.BigNumber.from(e.maxFeePerGas||0);t.eq(r)||tp.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:t,maxFeePerGas:r})}const r=[sp(e.chainId||0,"chainId"),sp(e.nonce||0,"nonce"),sp(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),sp(e.maxFeePerGas||0,"maxFeePerGas"),sp(e.gasLimit||0,"gasLimit"),null!=e.to?oa(e.to):"0x",sp(e.value||0,"value"),e.data||"0x",cp(e.accessList||[])];if(t){const e=Vs(t);r.push(sp(e.recoveryParam,"recoveryParam")),r.push(js(e.r)),r.push(js(e.s))}return _s(["0x02",qs(r)])}function dp(e,t){const r=[sp(e.chainId||0,"chainId"),sp(e.nonce||0,"nonce"),sp(e.gasPrice||0,"gasPrice"),sp(e.gasLimit||0,"gasLimit"),null!=e.to?oa(e.to):"0x",sp(e.value||0,"value"),e.data||"0x",cp(e.accessList||[])];if(t){const e=Vs(t);r.push(sp(e.recoveryParam,"recoveryParam")),r.push(js(e.r)),r.push(js(e.s))}return _s(["0x01",qs(r)])}function pp(e,t,r){try{const r=op(t[0]).toNumber();if(0!==r&&1!==r)throw new Error("bad recid");e.v=r}catch(e){tp.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=Ls(t[1],32),e.s=Ls(t[2],32);try{const t=zs(r(e));e.from=ip(t,{r:e.r,s:e.s,recoveryParam:e.v})}catch(e){}}function hp(e){const t=Os(e);if(t[0]>127)return function(e){const t=$s(e);9!==t.length&&6!==t.length&&tp.throwArgumentError("invalid raw transaction","rawTransaction",e);const r={nonce:op(t[0]).toNumber(),gasPrice:op(t[1]),gasLimit:op(t[2]),to:np(t[3]),value:op(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=y.BigNumber.from(t[6]).toNumber()}catch(e){return r}if(r.r=Ls(t[7],32),r.s=Ls(t[8],32),y.BigNumber.from(r.r).isZero()&&y.BigNumber.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);let n=r.v-27;const o=t.slice(0,6);0!==r.chainId&&(o.push(Bs(r.chainId)),o.push("0x"),o.push("0x"),n-=2*r.chainId+8);const i=zs(qs(o));try{r.from=ip(i,{r:Bs(r.r),s:Bs(r.s),recoveryParam:n})}catch(e){}r.hash=zs(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){const t=$s(e.slice(1));8!==t.length&&11!==t.length&&tp.throwArgumentError("invalid component count for transaction type: 1","payload",Bs(e));const r={type:1,chainId:op(t[0]).toNumber(),nonce:op(t[1]).toNumber(),gasPrice:op(t[2]),gasLimit:op(t[3]),to:np(t[4]),value:op(t[5]),data:t[6],accessList:lp(t[7])};return 8===t.length||(r.hash=zs(e),pp(r,t.slice(8),dp)),r}(t);case 2:return function(e){const t=$s(e.slice(1));9!==t.length&&12!==t.length&&tp.throwArgumentError("invalid component count for transaction type: 2","payload",Bs(e));const r=op(t[2]),n=op(t[3]),o={type:2,chainId:op(t[0]).toNumber(),nonce:op(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:op(t[4]),to:np(t[5]),value:op(t[6]),data:t[7],accessList:lp(t[8])};return 9===t.length||(o.hash=zs(e),pp(o,t.slice(9),up)),o}(t)}return tp.throwError(`unsupported transaction type: ${t[0]}`,ks.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})}!function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(rp||(rp={}));const fp=new ks(dd);class mp{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){const e={},t=this.address.bind(this),r=this.bigNumber.bind(this),n=this.blockTag.bind(this),o=this.data.bind(this),i=this.hash.bind(this),s=this.hex.bind(this),a=this.number.bind(this),l=this.type.bind(this);return e.transaction={hash:i,type:l,accessList:mp.allowNull(this.accessList.bind(this),null),blockHash:mp.allowNull(i,null),blockNumber:mp.allowNull(a,null),transactionIndex:mp.allowNull(a,null),confirmations:mp.allowNull(a,null),from:t,gasPrice:mp.allowNull(r),maxPriorityFeePerGas:mp.allowNull(r),maxFeePerGas:mp.allowNull(r),gasLimit:r,to:mp.allowNull(t,null),value:r,nonce:a,data:o,r:mp.allowNull(this.uint256),s:mp.allowNull(this.uint256),v:mp.allowNull(a),creates:mp.allowNull(t,null),raw:mp.allowNull(o)},e.transactionRequest={from:mp.allowNull(t),nonce:mp.allowNull(a),gasLimit:mp.allowNull(r),gasPrice:mp.allowNull(r),maxPriorityFeePerGas:mp.allowNull(r),maxFeePerGas:mp.allowNull(r),to:mp.allowNull(t),value:mp.allowNull(r),data:mp.allowNull((e=>this.data(e,!0))),type:mp.allowNull(a),accessList:mp.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:a,blockNumber:a,transactionHash:i,address:t,topics:mp.arrayOf(i),data:o,logIndex:a,blockHash:i},e.receipt={to:mp.allowNull(this.address,null),from:mp.allowNull(this.address,null),contractAddress:mp.allowNull(t,null),transactionIndex:a,root:mp.allowNull(s),gasUsed:r,logsBloom:mp.allowNull(o),blockHash:i,transactionHash:i,logs:mp.arrayOf(this.receiptLog.bind(this)),blockNumber:a,confirmations:mp.allowNull(a,null),cumulativeGasUsed:r,effectiveGasPrice:mp.allowNull(r),status:mp.allowNull(a),type:l},e.block={hash:mp.allowNull(i),parentHash:i,number:a,timestamp:a,nonce:mp.allowNull(s),difficulty:this.difficulty.bind(this),gasLimit:r,gasUsed:r,miner:mp.allowNull(t),extraData:o,transactions:mp.allowNull(mp.arrayOf(i)),baseFeePerGas:mp.allowNull(r)},e.blockWithTransactions=Ca(e.block),e.blockWithTransactions.transactions=mp.allowNull(mp.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:mp.allowNull(n,void 0),toBlock:mp.allowNull(n,void 0),blockHash:mp.allowNull(i,void 0),address:mp.allowNull(t,void 0),topics:mp.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:mp.allowNull(a),blockHash:mp.allowNull(i),transactionIndex:a,removed:mp.allowNull(this.boolean.bind(this)),address:t,data:mp.allowFalsish(o,"0x"),topics:mp.arrayOf(i),transactionHash:i,logIndex:a},e}accessList(e){return lp(e||[])}number(e){return"0x"===e?0:y.BigNumber.from(e).toNumber()}type(e){return"0x"===e||null==e?0:y.BigNumber.from(e).toNumber()}bigNumber(e){return y.BigNumber.from(e)}boolean(e){if("boolean"==typeof e)return e;if("string"==typeof e){if("true"===(e=e.toLowerCase()))return!0;if("false"===e)return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return"string"==typeof e&&(t||"0x"===e.substring(0,2)||(e="0x"+e),Ds(e))?e.toLowerCase():fp.throwArgumentError("invalid hash","value",e)}data(e,t){const r=this.hex(e,t);if(r.length%2!=0)throw new Error("invalid data; odd-length - "+e);return r}address(e){return oa(e)}callAddress(e){if(!Ds(e,32))return null;const t=oa(Ws(e,12));return t===za?null:t}contractAddress(e){return function(e){let t=null;try{t=oa(e.from)}catch(t){ea.throwArgumentError("missing from address","transaction",e)}return oa(Ws(zs(qs([t,js(Os(y.BigNumber.from(e.nonce).toHexString()))])),12))}(e)}blockTag(e){if(null==e)return"latest";if("earliest"===e)return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if("number"==typeof e||Ds(e))return Us(e);throw new Error("invalid blockTag")}hash(e,t){const r=this.hex(e,t);return 32!==Ps(r)?fp.throwArgumentError("invalid hash","value",e):r}difficulty(e){if(null==e)return null;const t=y.BigNumber.from(e);try{return t.toNumber()}catch(e){}return null}uint256(e){if(!Ds(e))throw new Error("invalid uint256");return Ls(e,32)}_block(e,t){null!=e.author&&null==e.miner&&(e.miner=e.author);const r=null!=e._difficulty?e._difficulty:e.difficulty,n=mp.check(t,e);return n._difficulty=null==r?null:y.BigNumber.from(r),n}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return mp.check(this.formats.transactionRequest,e)}transactionResponse(e){null!=e.gas&&null==e.gasLimit&&(e.gasLimit=e.gas),e.to&&y.BigNumber.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),null!=e.input&&null==e.data&&(e.data=e.input),null==e.to&&null==e.creates&&(e.creates=this.contractAddress(e)),1!==e.type&&2!==e.type||null!=e.accessList||(e.accessList=[]);const t=mp.check(this.formats.transaction,e);if(null!=e.chainId){let r=e.chainId;Ds(r)&&(r=y.BigNumber.from(r).toNumber()),t.chainId=r}else{let r=e.networkId;null==r&&null==t.v&&(r=e.chainId),Ds(r)&&(r=y.BigNumber.from(r).toNumber()),"number"!=typeof r&&null!=t.v&&(r=(t.v-35)/2,r<0&&(r=0),r=parseInt(r)),"number"!=typeof r&&(r=0),t.chainId=r}return t.blockHash&&"x"===t.blockHash.replace(/0/g,"")&&(t.blockHash=null),t}transaction(e){return hp(e)}receiptLog(e){return mp.check(this.formats.receiptLog,e)}receipt(e){const t=mp.check(this.formats.receipt,e);if(null!=t.root)if(t.root.length<=4){const e=y.BigNumber.from(t.root).toNumber();0===e||1===e?(null!=t.status&&t.status!==e&&fp.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=e,delete t.root):fp.throwArgumentError("invalid alt-root-status","value.root",t.root)}else 66!==t.root.length&&fp.throwArgumentError("invalid root hash","value.root",t.root);return null!=t.status&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map((e=>this.topics(e))):null!=e?this.hash(e,!0):null}filter(e){return mp.check(this.formats.filter,e)}filterLog(e){return mp.check(this.formats.filterLog,e)}static check(e,t){const r={};for(const n in e)try{const o=e[n](t[n]);void 0!==o&&(r[n]=o)}catch(e){throw e.checkKey=n,e.checkValue=t[n],e}return r}static allowNull(e,t){return function(r){return null==r?t:e(r)}}static allowFalsish(e,t){return function(r){return r?e(r):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");const r=[];return t.forEach((function(t){r.push(e(t))})),r}}}var gp=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const yp=new ks(dd);function bp(e){return null==e?"null":(32!==Ps(e)&&yp.throwArgumentError("invalid topic","topic",e),e.toLowerCase())}function xp(e){for(e=e.slice();e.length>0&&null==e[e.length-1];)e.pop();return e.map((e=>{if(Array.isArray(e)){const t={};e.forEach((e=>{t[bp(e)]=!0}));const r=Object.keys(t);return r.sort(),r.join("|")}return bp(e)})).join("&")}function vp(e){if("string"==typeof e){if(32===Ps(e=e.toLowerCase()))return"tx:"+e;if(-1===e.indexOf(":"))return e}else{if(Array.isArray(e))return"filter:*:"+xp(e);if(Oa.isForkEvent(e))throw yp.warn("not implemented"),new Error("not implemented");if(e&&"object"==typeof e)return"filter:"+(e.address||"*")+":"+xp(e.topics||[])}throw new Error("invalid event - "+e)}function wp(){return(new Date).getTime()}function Ep(e){return new Promise((t=>{setTimeout(t,e)}))}const Ap=["block","network","pending","poll"];class Cp{constructor(e,t,r){wa(this,"tag",e),wa(this,"listener",t),wa(this,"once",r),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){const e=this.tag.split(":");return"tx"!==e[0]?null:e[1]}get filter(){const e=this.tag.split(":");if("filter"!==e[0])return null;const t=e[1],r=""===(n=e[2])?[]:n.split(/&/g).map((e=>{if(""===e)return[];const t=e.split("|").map((e=>"null"===e?null:e));return 1===t.length?t[0]:t}));var n;const o={};return r.length>0&&(o.topics=r),t&&"*"!==t&&(o.address=t),o}pollable(){return this.tag.indexOf(":")>=0||Ap.indexOf(this.tag)>=0}}const kp={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Rp(e){return Ls(y.BigNumber.from(e).toHexString(),32)}function Tp(e){return Ha.encode(Is([e,Ws(Gu(Gu(e)),0,4)]))}const Sp=new RegExp("^(ipfs)://(.*)$","i"),Np=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Sp,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Mp(e,t){try{return nl(Fp(e,t))}catch(e){}return null}function Fp(e,t){if("0x"===e)return null;const r=y.BigNumber.from(Ws(e,t,t+32)).toNumber(),n=y.BigNumber.from(Ws(e,r,r+32)).toNumber();return Ws(e,r+32,r+32+n)}function Op(e){return e.match(/^ipfs:\/\/ipfs\//i)?e=e.substring(12):e.match(/^ipfs:\/\//i)?e=e.substring(7):yp.throwArgumentError("unsupported IPFS format","link",e),`https://gateway.ipfs.io/ipfs/${e}`}function Ip(e){const t=Os(e);if(t.length>32)throw new Error("internal; should not happen");const r=new Uint8Array(32);return r.set(t,32-t.length),r}function jp(e){if(e.length%32==0)return e;const t=new Uint8Array(32*Math.ceil(e.length/32));return t.set(e),t}function Dp(e){const t=[];let r=0;for(let n=0;n<e.length;n++)t.push(null),r+=32;for(let n=0;n<e.length;n++){const o=Os(e[n]);t[n]=Ip(r),t.push(Ip(o.length)),t.push(jp(o)),r+=32+32*Math.ceil(o.length/32)}return _s(t)}class Bp{constructor(e,t,r,n){wa(this,"provider",e),wa(this,"name",r),wa(this,"address",e.formatter.address(t)),wa(this,"_resolvedAddress",n)}supportsWildcard(){return this._supportsEip2544||(this._supportsEip2544=this.provider.call({to:this.address,data:"0x01ffc9a79061b92300000000000000000000000000000000000000000000000000000000"}).then((e=>y.BigNumber.from(e).eq(1))).catch((e=>{if(e.code===ks.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e}))),this._supportsEip2544}_fetch(e,t){return gp(this,void 0,void 0,(function*(){const r={to:this.address,ccipReadEnabled:!0,data:_s([e,Sl(this.name),t||"0x"])};let n=!1;var o;(yield this.supportsWildcard())&&(n=!0,r.data=_s(["0x9061b923",Dp([(o=this.name,Bs(Is(Tl(o).map((e=>{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"),r.data])]));try{let e=yield this.provider.call(r);return Os(e).length%32==4&&yp.throwError("resolver threw error",ks.errors.CALL_EXCEPTION,{transaction:r,data:e}),n&&(e=Fp(e,0)),e}catch(e){if(e.code===ks.errors.CALL_EXCEPTION)return null;throw e}}))}_fetchBytes(e,t){return gp(this,void 0,void 0,(function*(){const r=yield this._fetch(e,t);return null!=r?Fp(r,0):null}))}_getAddress(e,t){const r=kp[String(e)];if(null==r&&yp.throwError(`unsupported coin type: ${e}`,ks.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),"eth"===r.ilk)return this.provider.formatter.address(t);const n=Os(t);if(null!=r.p2pkh){const e=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Tp(Is([[r.p2pkh],"0x"+e[2]]))}}if(null!=r.p2sh){const e=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Tp(Is([[r.p2sh],"0x"+e[2]]))}}if(null!=r.prefix){const e=n[1];let t=n[0];if(0===t?20!==e&&32!==e&&(t=-1):t=-1,t>=0&&n.length===2+e&&e>=1&&e<=75){const e=ud.toWords(n.slice(2));return e.unshift(t),ud.encode(r.prefix,e)}}return null}getAddress(e){return gp(this,void 0,void 0,(function*(){if(null==e&&(e=60),60===e)try{const e=yield this._fetch("0x3b3b57de");return"0x"===e||"0x0000000000000000000000000000000000000000000000000000000000000000"===e?null:this.provider.formatter.callAddress(e)}catch(e){if(e.code===ks.errors.CALL_EXCEPTION)return null;throw e}const t=yield this._fetchBytes("0xf1cb7e06",Rp(e));if(null==t||"0x"===t)return null;const r=this._getAddress(e,t);return null==r&&yp.throwError("invalid or unsupported coin data",ks.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),r}))}getAvatar(){return gp(this,void 0,void 0,(function*(){const e=[{type:"name",content:this.name}];try{const t=yield this.getText("avatar");if(null==t)return null;for(let r=0;r<Np.length;r++){const n=t.match(Np[r]);if(null==n)continue;const o=n[1].toLowerCase();switch(o){case"https":return e.push({type:"url",content:t}),{linkage:e,url:t};case"data":return e.push({type:"data",content:t}),{linkage:e,url:t};case"ipfs":return e.push({type:"ipfs",content:t}),{linkage:e,url:Op(t)};case"erc721":case"erc1155":{const r="erc721"===o?"0xc87b56dd":"0x0e89341c";e.push({type:o,content:t});const i=this._resolvedAddress||(yield this.getAddress()),s=(n[2]||"").split("/");if(2!==s.length)return null;const a=yield this.provider.formatter.address(s[0]),l=Ls(y.BigNumber.from(s[1]).toHexString(),32);if("erc721"===o){const t=this.provider.formatter.callAddress(yield this.provider.call({to:a,data:_s(["0x6352211e",l])}));if(i!==t)return null;e.push({type:"owner",content:t})}else if("erc1155"===o){const t=y.BigNumber.from(yield this.provider.call({to:a,data:_s(["0x00fdd58e",Ls(i,32),l])}));if(t.isZero())return null;e.push({type:"balance",content:t.toString()})}const c={to:this.provider.formatter.address(s[0]),data:_s([r,l])};let u=Mp(yield this.provider.call(c),0);if(null==u)return null;e.push({type:"metadata-url-base",content:u}),"erc1155"===o&&(u=u.replace("{id}",l.substring(2)),e.push({type:"metadata-url-expanded",content:u})),u.match(/^ipfs:/i)&&(u=Op(u)),e.push({type:"metadata-url",content:u});const d=yield ed(u);if(!d)return null;e.push({type:"metadata",content:JSON.stringify(d)});let p=d.image;if("string"!=typeof p)return null;if(p.match(/^(https:\/\/|data:)/i));else{if(null==p.match(Sp))return null;e.push({type:"url-ipfs",content:p}),p=Op(p)}return e.push({type:"url",content:p}),{linkage:e,url:p}}}}}catch(e){}return null}))}getContentHash(){return gp(this,void 0,void 0,(function*(){const e=yield this._fetchBytes("0xbc1c58d1");if(null==e||"0x"===e)return null;const t=e.match(/^0xe3010170(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(t){const e=parseInt(t[3],16);if(t[4].length===2*e)return"ipfs://"+Ha.encode("0x"+t[1])}const r=e.match(/^0xe5010172(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(r){const e=parseInt(r[3],16);if(r[4].length===2*e)return"ipns://"+Ha.encode("0x"+r[1])}const n=e.match(/^0xe40101fa011b20([0-9a-f]*)$/);if(n&&64===n[1].length)return"bzz://"+n[1];const o=e.match(/^0x90b2c605([0-9a-f]*)$/);if(o&&68===o[1].length){const e={"=":"","+":"-","/":"_"};return"sia://"+Va("0x"+o[1]).replace(/[=+\/]/g,(t=>e[t]))}return yp.throwError("invalid or unsupported content hash data",ks.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})}))}getText(e){return gp(this,void 0,void 0,(function*(){let t=rl(e);t=Is([Rp(64),Rp(t.length),t]),t.length%32!=0&&(t=Is([t,Ls("0x",32-e.length%32)]));const r=yield this._fetchBytes("0x59d1d43c",Bs(t));return null==r||"0x"===r?null:nl(r)}))}}let Pp=null,Wp=1;class _p extends Ia{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),wa(this,"anyNetwork","any"===e),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch((e=>{})),this._ready().catch((e=>{}));else{const t=Ea(new.target,"getNetwork")(e);t?(wa(this,"_network",t),this.emit("network",t,null)):yp.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return gp(this,void 0,void 0,(function*(){if(null==this._network){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch(e){}null==e&&(e=yield this.detectNetwork()),e||yp.throwError("no network detected",ks.errors.UNKNOWN_ERROR,{}),null==this._network&&(this.anyNetwork?this._network=e:wa(this,"_network",e),this.emit("network",e,null))}return this._network}))}get ready(){return td((()=>this._ready().then((e=>e),(e=>{if(e.code!==ks.errors.NETWORK_ERROR||"noNetwork"!==e.event)throw e}))))}static getFormatter(){return null==Pp&&(Pp=new mp),Pp}static getNetwork(e){return function(e){if(null==e)return null;if("number"==typeof e){for(const t in Ua){const r=Ua[t];if(r.chainId===e)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:e,name:"unknown"}}if("string"==typeof e){const t=Ua[e];return null==t?null:{name:t.name,chainId:t.chainId,ensAddress:t.ensAddress,_defaultProvider:t._defaultProvider||null}}const t=Ua[e.name];if(!t)return"number"!=typeof e.chainId&&ja.throwArgumentError("invalid network chainId","network",e),e;0!==e.chainId&&e.chainId!==t.chainId&&ja.throwArgumentError("network chainId mismatch","network",e);let r=e._defaultProvider||null;var n;return null==r&&t._defaultProvider&&(r=(n=t._defaultProvider)&&"function"==typeof n.renetwork?t._defaultProvider.renetwork(e):t._defaultProvider),{name:e.name,chainId:t.chainId,ensAddress:e.ensAddress||t.ensAddress||null,_defaultProvider:r}}(null==e?"homestead":e)}ccipReadFetch(e,t,r){return gp(this,void 0,void 0,(function*(){if(this.disableCcipRead||0===r.length)return null;const n=e.to.toLowerCase(),o=t.toLowerCase(),i=[];for(let e=0;e<r.length;e++){const t=r[e],s=t.replace("{sender}",n).replace("{data}",o),a=t.indexOf("{data}")>=0?null:JSON.stringify({data:o,sender:n}),l=yield ed({url:s,errorPassThrough:!0},a,((e,t)=>(e.status=t.statusCode,e)));if(l.data)return l.data;const c=l.message||"unknown error";if(l.status>=400&&l.status<500)return yp.throwError(`response not found during CCIP fetch: ${c}`,ks.errors.SERVER_ERROR,{url:t,errorMessage:c});i.push(c)}return yp.throwError(`error encountered during CCIP fetch: ${i.map((e=>JSON.stringify(e))).join(", ")}`,ks.errors.SERVER_ERROR,{urls:r,errorMessages:i})}))}_getInternalBlockNumber(e){return gp(this,void 0,void 0,(function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){const t=this._internalBlockNumber;try{const r=yield t;if(wp()-r.respTime<=e)return r.blockNumber;break}catch(e){if(this._internalBlockNumber===t)break}}const t=wp(),r=Aa({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then((e=>null),(e=>e))}).then((({blockNumber:e,networkError:n})=>{if(n)throw this._internalBlockNumber===r&&(this._internalBlockNumber=null),n;const o=wp();return(e=y.BigNumber.from(e).toNumber())<this._maxInternalBlockNumber&&(e=this._maxInternalBlockNumber),this._maxInternalBlockNumber=e,this._setFastBlockNumber(e),{blockNumber:e,reqTime:t,respTime:o}}));return this._internalBlockNumber=r,r.catch((e=>{this._internalBlockNumber===r&&(this._internalBlockNumber=null)})),(yield r).blockNumber}))}poll(){return gp(this,void 0,void 0,(function*(){const e=Wp++,t=[];let r=null;try{r=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(e){return void this.emit("error",e)}if(this._setFastBlockNumber(r),this.emit("poll",e,r),r!==this._lastBlockNumber){if(-2===this._emitted.block&&(this._emitted.block=r-1),Math.abs(this._emitted.block-r)>1e3)yp.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${r})`),this.emit("error",yp.makeError("network block skew detected",ks.errors.NETWORK_ERROR,{blockNumber:r,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",r);else for(let e=this._emitted.block+1;e<=r;e++)this.emit("block",e);this._emitted.block!==r&&(this._emitted.block=r,Object.keys(this._emitted).forEach((e=>{if("block"===e)return;const t=this._emitted[e];"pending"!==t&&r-t>12&&delete this._emitted[e]}))),-2===this._lastBlockNumber&&(this._lastBlockNumber=r-1),this._events.forEach((e=>{switch(e.type){case"tx":{const r=e.hash;let n=this.getTransactionReceipt(r).then((e=>e&&null!=e.blockNumber?(this._emitted["t:"+r]=e.blockNumber,this.emit(r,e),null):null)).catch((e=>{this.emit("error",e)}));t.push(n);break}case"filter":if(!e._inflight){e._inflight=!0,-2===e._lastBlockNumber&&(e._lastBlockNumber=r-1);const n=e.filter;n.fromBlock=e._lastBlockNumber+1,n.toBlock=r;const o=n.toBlock-this._maxFilterBlockRange;o>n.fromBlock&&(n.fromBlock=o),n.fromBlock<0&&(n.fromBlock=0);const i=this.getLogs(n).then((t=>{e._inflight=!1,0!==t.length&&t.forEach((t=>{t.blockNumber>e._lastBlockNumber&&(e._lastBlockNumber=t.blockNumber),this._emitted["b:"+t.blockHash]=t.blockNumber,this._emitted["t:"+t.transactionHash]=t.blockNumber,this.emit(n,t)}))})).catch((t=>{this.emit("error",t),e._inflight=!1}));t.push(i)}}})),this._lastBlockNumber=r,Promise.all(t).then((()=>{this.emit("didPoll",e)})).catch((e=>{this.emit("error",e)}))}else this.emit("didPoll",e)}))}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return gp(this,void 0,void 0,(function*(){return yp.throwError("provider does not support network detection",ks.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})}))}getNetwork(){return gp(this,void 0,void 0,(function*(){const e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield Ep(0),this._network;const r=yp.makeError("underlying network changed",ks.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",r),r}return e}))}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then((e=>{this._setFastBlockNumber(e)}),(e=>{})),null!=this._fastBlockNumber?this._fastBlockNumber:-1}get polling(){return null!=this._poller}set polling(e){e&&!this._poller?(this._poller=setInterval((()=>{this.poll()}),this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout((()=>{this.poll(),this._bootstrapPoll=setTimeout((()=>{this._poller||this.poll(),this._bootstrapPoll=null}),this.pollingInterval)}),0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if("number"!=typeof e||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval((()=>{this.poll()}),this._pollingInterval))}_getFastBlockNumber(){const e=wp();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then((e=>((null==this._fastBlockNumber||e>this._fastBlockNumber)&&(this._fastBlockNumber=e),this._fastBlockNumber)))),this._fastBlockNumberPromise}_setFastBlockNumber(e){null!=this._fastBlockNumber&&e<this._fastBlockNumber||(this._fastQueryDate=wp(),(null==this._fastBlockNumber||e>this._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,r){return gp(this,void 0,void 0,(function*(){return this._waitForTransaction(e,null==t?1:t,r||0,null)}))}_waitForTransaction(e,t,r,n){return gp(this,void 0,void 0,(function*(){const o=yield this.getTransactionReceipt(e);return(o?o.confirmations:0)>=t?o:new Promise(((o,i)=>{const s=[];let a=!1;const l=function(){return!!a||(a=!0,s.forEach((e=>{e()})),!1)},c=e=>{e.confirmations<t||l()||o(e)};if(this.on(e,c),s.push((()=>{this.removeListener(e,c)})),n){let r=n.startBlock,o=null;const c=s=>gp(this,void 0,void 0,(function*(){a||(yield Ep(1e3),this.getTransactionCount(n.from).then((u=>gp(this,void 0,void 0,(function*(){if(!a){if(u<=n.nonce)r=s;else{{const t=yield this.getTransaction(e);if(t&&null!=t.blockNumber)return}for(null==o&&(o=r-3,o<n.startBlock&&(o=n.startBlock));o<=s;){if(a)return;const r=yield this.getBlockWithTransactions(o);for(let o=0;o<r.transactions.length;o++){const s=r.transactions[o];if(s.hash===e)return;if(s.from===n.from&&s.nonce===n.nonce){if(a)return;const r=yield this.waitForTransaction(s.hash,t);if(l())return;let o="replaced";return s.data===n.data&&s.to===n.to&&s.value.eq(n.value)?o="repriced":"0x"===s.data&&s.from===s.to&&s.value.isZero()&&(o="cancelled"),void i(yp.makeError("transaction was replaced",ks.errors.TRANSACTION_REPLACED,{cancelled:"replaced"===o||"cancelled"===o,reason:o,replacement:this._wrapTransaction(s),hash:e,receipt:r}))}}o++}}a||this.once("block",c)}}))),(e=>{a||this.once("block",c)})))}));if(a)return;this.once("block",c),s.push((()=>{this.removeListener("block",c)}))}if("number"==typeof r&&r>0){const e=setTimeout((()=>{l()||i(yp.makeError("timeout exceeded",ks.errors.TIMEOUT,{timeout:r}))}),r);e.unref&&e.unref(),s.push((()=>{clearTimeout(e)}))}}))}))}getBlockNumber(){return gp(this,void 0,void 0,(function*(){return this._getInternalBlockNumber(0)}))}getGasPrice(){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const e=yield this.perform("getGasPrice",{});try{return y.BigNumber.from(e)}catch(t){return yp.throwError("bad result from backend",ks.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}}))}getBalance(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getBalance",r);try{return y.BigNumber.from(n)}catch(e){return yp.throwError("bad result from backend",ks.errors.SERVER_ERROR,{method:"getBalance",params:r,result:n,error:e})}}))}getTransactionCount(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getTransactionCount",r);try{return y.BigNumber.from(n).toNumber()}catch(e){return yp.throwError("bad result from backend",ks.errors.SERVER_ERROR,{method:"getTransactionCount",params:r,result:n,error:e})}}))}getCode(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getCode",r);try{return Bs(n)}catch(e){return yp.throwError("bad result from backend",ks.errors.SERVER_ERROR,{method:"getCode",params:r,result:n,error:e})}}))}getStorageAt(e,t,r){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const n=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(r),position:Promise.resolve(t).then((e=>Us(e)))}),o=yield this.perform("getStorageAt",n);try{return Bs(o)}catch(e){return yp.throwError("bad result from backend",ks.errors.SERVER_ERROR,{method:"getStorageAt",params:n,result:o,error:e})}}))}_wrapTransaction(e,t,r){if(null!=t&&32!==Ps(t))throw new Error("invalid response - sendTransaction");const n=e;return null!=t&&e.hash!==t&&yp.throwError("Transaction hash mismatch from Provider.sendTransaction.",ks.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),n.wait=(t,n)=>gp(this,void 0,void 0,(function*(){let o;null==t&&(t=1),null==n&&(n=0),0!==t&&null!=r&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:r});const i=yield this._waitForTransaction(e.hash,t,n,o);return null==i&&0===t?null:(this._emitted["t:"+e.hash]=i.blockNumber,0===i.status&&yp.throwError("transaction failed",ks.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:i}),i)})),n}sendTransaction(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Promise.resolve(e).then((e=>Bs(e))),r=this.formatter.transaction(e);null==r.confirmations&&(r.confirmations=0);const n=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{const e=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(r,e,n)}catch(e){throw e.transaction=r,e.transactionHash=r.hash,e}}))}_getTransactionRequest(e){return gp(this,void 0,void 0,(function*(){const t=yield e,r={};return["from","to"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?this._getAddress(e):null)))})),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?y.BigNumber.from(e):null)))})),["type"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>null!=e?e:null)))})),t.accessList&&(r.accessList=this.formatter.accessList(t.accessList)),["data"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?Bs(e):null)))})),this.formatter.transactionRequest(yield Aa(r))}))}_getFilter(e){return gp(this,void 0,void 0,(function*(){e=yield e;const t={};return null!=e.address&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach((r=>{null!=e[r]&&(t[r]=e[r])})),["fromBlock","toBlock"].forEach((r=>{null!=e[r]&&(t[r]=this._getBlockTag(e[r]))})),this.formatter.filter(yield Aa(t))}))}_call(e,t,r){return gp(this,void 0,void 0,(function*(){r>=10&&yp.throwError("CCIP read exceeded maximum redirections",ks.errors.SERVER_ERROR,{redirects:r,transaction:e});const n=e.to,o=yield this.perform("call",{transaction:e,blockTag:t});if(r>=0&&"latest"===t&&null!=n&&"0x556f1830"===o.substring(0,10)&&Ps(o)%32==4)try{const i=Ws(o,4),s=Ws(i,0,32);y.BigNumber.from(s).eq(n)||yp.throwError("CCIP Read sender did not match",ks.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});const a=[],l=y.BigNumber.from(Ws(i,32,64)).toNumber(),c=y.BigNumber.from(Ws(i,l,l+32)).toNumber(),u=Ws(i,l+32);for(let t=0;t<c;t++){const r=Mp(u,32*t);null==r&&yp.throwError("CCIP Read contained corrupt URL string",ks.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o}),a.push(r)}const d=Fp(i,64);y.BigNumber.from(Ws(i,100,128)).isZero()||yp.throwError("CCIP Read callback selector included junk",ks.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});const p=Ws(i,96,100),h=Fp(i,128),f=yield this.ccipReadFetch(e,d,a);null==f&&yp.throwError("CCIP Read disabled or provided no URLs",ks.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});const m={to:n,data:_s([p,Dp([f,h])])};return this._call(m,t,r+1)}catch(e){if(e.code===ks.errors.SERVER_ERROR)throw e}try{return Bs(o)}catch(r){return yp.throwError("bad result from backend",ks.errors.SERVER_ERROR,{method:"call",params:{transaction:e,blockTag:t},result:o,error:r})}}))}call(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({transaction:this._getTransactionRequest(e),blockTag:this._getBlockTag(t),ccipReadEnabled:Promise.resolve(e.ccipReadEnabled)});return this._call(r.transaction,r.blockTag,r.ccipReadEnabled?0:-1)}))}estimateGas(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Aa({transaction:this._getTransactionRequest(e)}),r=yield this.perform("estimateGas",t);try{return y.BigNumber.from(r)}catch(e){return yp.throwError("bad result from backend",ks.errors.SERVER_ERROR,{method:"estimateGas",params:t,result:r,error:e})}}))}_getAddress(e){return gp(this,void 0,void 0,(function*(){"string"!=typeof(e=yield e)&&yp.throwArgumentError("invalid address or ENS name","name",e);const t=yield this.resolveName(e);return null==t&&yp.throwError("ENS name not configured",ks.errors.UNSUPPORTED_OPERATION,{operation:`resolveName(${JSON.stringify(e)})`}),t}))}_getBlock(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;let r=-128;const n={includeTransactions:!!t};if(Ds(e,32))n.blockHash=e;else try{n.blockTag=yield this._getBlockTag(e),Ds(n.blockTag)&&(r=parseInt(n.blockTag.substring(2),16))}catch(t){yp.throwArgumentError("invalid block hash or block tag","blockHashOrBlockTag",e)}return td((()=>gp(this,void 0,void 0,(function*(){const e=yield this.perform("getBlock",n);if(null==e)return null!=n.blockHash&&null==this._emitted["b:"+n.blockHash]||null!=n.blockTag&&r>this._emitted.block?null:void 0;if(t){let t=null;for(let r=0;r<e.transactions.length;r++){const n=e.transactions[r];if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){null==t&&(t=yield this._getInternalBlockNumber(100+2*this.pollingInterval));let e=t-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}}const r=this.formatter.blockWithTransactions(e);return r.transactions=r.transactions.map((e=>this._wrapTransaction(e))),r}return this.formatter.block(e)}))),{oncePoll:this})}))}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return td((()=>gp(this,void 0,void 0,(function*(){const r=yield this.perform("getTransaction",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;const n=this.formatter.transactionResponse(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return this._wrapTransaction(n)}))),{oncePoll:this})}))}getTransactionReceipt(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return td((()=>gp(this,void 0,void 0,(function*(){const r=yield this.perform("getTransactionReceipt",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;if(null==r.blockHash)return;const n=this.formatter.receipt(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return n}))),{oncePoll:this})}))}getLogs(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Aa({filter:this._getFilter(e)}),r=yield this.perform("getLogs",t);return r.forEach((e=>{null==e.removed&&(e.removed=!1)})),mp.arrayOf(this.formatter.filterLog.bind(this.formatter))(r)}))}getEtherPrice(){return gp(this,void 0,void 0,(function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})}))}_getBlockTag(e){return gp(this,void 0,void 0,(function*(){if("number"==typeof(e=yield e)&&e<0){e%1&&yp.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)}))}getResolver(e){return gp(this,void 0,void 0,(function*(){let t=e;for(;;){if(""===t||"."===t)return null;if("eth"!==e&&"eth"===t)return null;const r=yield this._getResolver(t,"getResolver");if(null!=r){const n=new Bp(this,r,e);return t===e||(yield n.supportsWildcard())?n:null}t=t.split(".").slice(1).join(".")}}))}_getResolver(e,t){return gp(this,void 0,void 0,(function*(){null==t&&(t="ENS");const r=yield this.getNetwork();r.ensAddress||yp.throwError("network does not support ENS",ks.errors.UNSUPPORTED_OPERATION,{operation:t,network:r.name});try{const t=yield this.call({to:r.ensAddress,data:"0x0178b8bf"+Sl(e).substring(2)});return this.formatter.callAddress(t)}catch(e){}return null}))}resolveName(e){return gp(this,void 0,void 0,(function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(t){if(Ds(e))throw t}"string"!=typeof e&&yp.throwArgumentError("invalid ENS name","name",e);const t=yield this.getResolver(e);return t?yield t.getAddress():null}))}lookupAddress(e){return gp(this,void 0,void 0,(function*(){e=yield e;const t=(e=this.formatter.address(e)).substring(2).toLowerCase()+".addr.reverse",r=yield this._getResolver(t,"lookupAddress");if(null==r)return null;const n=Mp(yield this.call({to:r,data:"0x691f3431"+Sl(t).substring(2)}),0);return(yield this.resolveName(n))!=e?null:n}))}getAvatar(e){return gp(this,void 0,void 0,(function*(){let t=null;if(Ds(e)){const r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(r,"getAvatar");if(!n)return null;t=new Bp(this,n,r);try{const e=yield t.getAvatar();if(e)return e.url}catch(e){if(e.code!==ks.errors.CALL_EXCEPTION)throw e}try{const e=Mp(yield this.call({to:n,data:"0x691f3431"+Sl(r).substring(2)}),0);t=yield this.getResolver(e)}catch(e){if(e.code!==ks.errors.CALL_EXCEPTION)throw e;return null}}else if(t=yield this.getResolver(e),!t)return null;const r=yield t.getAvatar();return null==r?null:r.url}))}perform(e,t){return yp.throwError(e+" not implemented",ks.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_stopEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_addEventListener(e,t,r){const n=new Cp(vp(e),t,r);return this._events.push(n),this._startEvent(n),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let r=!1,n=[],o=vp(e);return this._events=this._events.filter((e=>e.tag!==o||(setTimeout((()=>{e.listener.apply(this,t)}),0),r=!0,!e.once||(n.push(e),!1)))),n.forEach((e=>{this._stopEvent(e)})),r}listenerCount(e){if(!e)return this._events.length;let t=vp(e);return this._events.filter((e=>e.tag===t)).length}listeners(e){if(null==e)return this._events.map((e=>e.listener));let t=vp(e);return this._events.filter((e=>e.tag===t)).map((e=>e.listener))}off(e,t){if(null==t)return this.removeAllListeners(e);const r=[];let n=!1,o=vp(e);return this._events=this._events.filter((e=>e.tag!==o||e.listener!=t||(!!n||(n=!0,r.push(e),!1)))),r.forEach((e=>{this._stopEvent(e)})),this}removeAllListeners(e){let t=[];if(null==e)t=this._events,this._events=[];else{const r=vp(e);this._events=this._events.filter((e=>e.tag!==r||(t.push(e),!1)))}return t.forEach((e=>{this._stopEvent(e)})),this}}var Up=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Lp=new ks("abstract-signer/5.7.0"),Vp=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],Zp=[ks.errors.INSUFFICIENT_FUNDS,ks.errors.NONCE_EXPIRED,ks.errors.REPLACEMENT_UNDERPRICED];class Hp{constructor(){Lp.checkAbstract(new.target,Hp),wa(this,"_isSigner",!0)}getBalance(e){return Up(this,void 0,void 0,(function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),e)}))}getTransactionCount(e){return Up(this,void 0,void 0,(function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),e)}))}estimateGas(e){return Up(this,void 0,void 0,(function*(){this._checkProvider("estimateGas");const t=yield Aa(this.checkTransaction(e));return yield this.provider.estimateGas(t)}))}call(e,t){return Up(this,void 0,void 0,(function*(){this._checkProvider("call");const r=yield Aa(this.checkTransaction(e));return yield this.provider.call(r,t)}))}sendTransaction(e){return Up(this,void 0,void 0,(function*(){this._checkProvider("sendTransaction");const t=yield this.populateTransaction(e),r=yield this.signTransaction(t);return yield this.provider.sendTransaction(r)}))}getChainId(){return Up(this,void 0,void 0,(function*(){this._checkProvider("getChainId");return(yield this.provider.getNetwork()).chainId}))}getGasPrice(){return Up(this,void 0,void 0,(function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()}))}getFeeData(){return Up(this,void 0,void 0,(function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()}))}resolveName(e){return Up(this,void 0,void 0,(function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(e)}))}checkTransaction(e){for(const t in e)-1===Vp.indexOf(t)&&Lp.throwArgumentError("invalid transaction key: "+t,"transaction",e);const t=Ca(e);return null==t.from?t.from=this.getAddress():t.from=Promise.all([Promise.resolve(t.from),this.getAddress()]).then((t=>(t[0].toLowerCase()!==t[1].toLowerCase()&&Lp.throwArgumentError("from address mismatch","transaction",e),t[0]))),t}populateTransaction(e){return Up(this,void 0,void 0,(function*(){const t=yield Aa(this.checkTransaction(e));null!=t.to&&(t.to=Promise.resolve(t.to).then((e=>Up(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.resolveName(e);return null==t&&Lp.throwArgumentError("provided ENS name resolves to null","tx.to",e),t})))),t.to.catch((e=>{})));const r=null!=t.maxFeePerGas||null!=t.maxPriorityFeePerGas;if(null==t.gasPrice||2!==t.type&&!r?0!==t.type&&1!==t.type||!r||Lp.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",e):Lp.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",e),2!==t.type&&null!=t.type||null==t.maxFeePerGas||null==t.maxPriorityFeePerGas)if(0===t.type||1===t.type)null==t.gasPrice&&(t.gasPrice=this.getGasPrice());else{const e=yield this.getFeeData();if(null==t.type)if(null!=e.maxFeePerGas&&null!=e.maxPriorityFeePerGas)if(t.type=2,null!=t.gasPrice){const e=t.gasPrice;delete t.gasPrice,t.maxFeePerGas=e,t.maxPriorityFeePerGas=e}else null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas);else null!=e.gasPrice?(r&&Lp.throwError("network does not support EIP-1559",ks.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),null==t.gasPrice&&(t.gasPrice=e.gasPrice),t.type=0):Lp.throwError("failed to get consistent fee data",ks.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"});else 2===t.type&&(null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas))}else t.type=2;return null==t.nonce&&(t.nonce=this.getTransactionCount("pending")),null==t.gasLimit&&(t.gasLimit=this.estimateGas(t).catch((e=>{if(Zp.indexOf(e.code)>=0)throw e;return Lp.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ks.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,tx:t})}))),null==t.chainId?t.chainId=this.getChainId():t.chainId=Promise.all([Promise.resolve(t.chainId),this.getChainId()]).then((t=>(0!==t[1]&&t[0]!==t[1]&&Lp.throwArgumentError("chainId address mismatch","transaction",e),t[0]))),yield Aa(t)}))}_checkProvider(e){this.provider||Lp.throwError("missing provider",ks.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}static isSigner(e){return!(!e||!e._isSigner)}}var zp=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Yp=new ks(dd),Gp=["call","estimateGas"];function Xp(e,t){if(null==e)return null;if("string"==typeof e.message&&e.message.match("reverted")){const r=Ds(e.data)?e.data:null;if(!t||r)return{message:e.message,data:r}}if("object"==typeof e){for(const r in e){const n=Xp(e[r],t);if(n)return n}return null}if("string"==typeof e)try{return Xp(JSON.parse(e),t)}catch(e){}return null}function Jp(e,t,r){const n=r.transaction||r.signedTransaction;if("call"===e){const e=Xp(t,!0);if(e)return e.data;Yp.throwError("missing revert data in call exception; Transaction reverted without a reason string",ks.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:t})}if("estimateGas"===e){let r=Xp(t.body,!1);null==r&&(r=Xp(t,!1)),r&&Yp.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ks.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:e,transaction:n,error:t})}let o=t.message;throw t.code===ks.errors.SERVER_ERROR&&t.error&&"string"==typeof t.error.message?o=t.error.message:"string"==typeof t.body?o=t.body:"string"==typeof t.responseText&&(o=t.responseText),o=(o||"").toLowerCase(),o.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Yp.throwError("insufficient funds for intrinsic transaction cost",ks.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:n}),o.match(/nonce (is )?too low/i)&&Yp.throwError("nonce has already been used",ks.errors.NONCE_EXPIRED,{error:t,method:e,transaction:n}),o.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Yp.throwError("replacement fee too low",ks.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:n}),o.match(/only replay-protected/i)&&Yp.throwError("legacy pre-eip-155 transactions not supported",ks.errors.UNSUPPORTED_OPERATION,{error:t,method:e,transaction:n}),Gp.indexOf(e)>=0&&o.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Yp.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ks.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:n}),t}function qp(e){return new Promise((function(t){setTimeout(t,e)}))}function Qp(e){if(e.error){const t=new Error(e.error.message);throw t.code=e.error.code,t.data=e.error.data,t}return e.result}function Kp(e){return e?e.toLowerCase():e}const $p={};class eh extends Hp{constructor(e,t,r){if(super(),e!==$p)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");wa(this,"provider",t),null==r&&(r=0),"string"==typeof r?(wa(this,"_address",this.provider.formatter.address(r)),wa(this,"_index",null)):"number"==typeof r?(wa(this,"_index",r),wa(this,"_address",null)):Yp.throwArgumentError("invalid address or index","addressOrIndex",r)}connect(e){return Yp.throwError("cannot alter JSON-RPC Signer connection",ks.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new th($p,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then((e=>(e.length<=this._index&&Yp.throwError("unknown account #"+this._index,ks.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index]))))}sendUncheckedTransaction(e){e=Ca(e);const t=this.getAddress().then((e=>(e&&(e=e.toLowerCase()),e)));if(null==e.gasLimit){const r=Ca(e);r.from=t,e.gasLimit=this.provider.estimateGas(r)}return null!=e.to&&(e.to=Promise.resolve(e.to).then((e=>zp(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.provider.resolveName(e);return null==t&&Yp.throwArgumentError("provided ENS name resolves to null","tx.to",e),t}))))),Aa({tx:Aa(e),sender:t}).then((({tx:t,sender:r})=>{null!=t.from?t.from.toLowerCase()!==r&&Yp.throwArgumentError("from address mismatch","transaction",e):t.from=r;const n=this.provider.constructor.hexlifyTransaction(t,{from:!0});return this.provider.send("eth_sendTransaction",[n]).then((e=>e),(e=>("string"==typeof e.message&&e.message.match(/user denied/i)&&Yp.throwError("user rejected transaction",ks.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:t}),Jp("sendTransaction",e,n))))}))}signTransaction(e){return Yp.throwError("signing transactions is unsupported",ks.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return zp(this,void 0,void 0,(function*(){const t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),r=yield this.sendUncheckedTransaction(e);try{return yield td((()=>zp(this,void 0,void 0,(function*(){const e=yield this.provider.getTransaction(r);if(null!==e)return this.provider._wrapTransaction(e,r,t)}))),{oncePoll:this.provider})}catch(e){throw e.transactionHash=r,e}}))}signMessage(e){return zp(this,void 0,void 0,(function*(){const t="string"==typeof e?rl(e):e,r=yield this.getAddress();try{return yield this.provider.send("personal_sign",[Bs(t),r.toLowerCase()])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&Yp.throwError("user rejected signing",ks.errors.ACTION_REJECTED,{action:"signMessage",from:r,messageData:e}),t}}))}_legacySignMessage(e){return zp(this,void 0,void 0,(function*(){const t="string"==typeof e?rl(e):e,r=yield this.getAddress();try{return yield this.provider.send("eth_sign",[r.toLowerCase(),Bs(t)])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&Yp.throwError("user rejected signing",ks.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:r,messageData:e}),t}}))}_signTypedData(e,t,r){return zp(this,void 0,void 0,(function*(){const n=yield Hl.resolveNames(e,t,r,(e=>this.provider.resolveName(e))),o=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[o.toLowerCase(),JSON.stringify(Hl.getPayload(n.domain,t,n.value))])}catch(e){throw"string"==typeof e.message&&e.message.match(/user denied/i)&&Yp.throwError("user rejected signing",ks.errors.ACTION_REJECTED,{action:"_signTypedData",from:o,messageData:{domain:n.domain,types:t,value:n.value}}),e}}))}unlock(e){return zp(this,void 0,void 0,(function*(){const t=this.provider,r=yield this.getAddress();return t.send("personal_unlockAccount",[r.toLowerCase(),e,null])}))}}class th extends eh{sendTransaction(e){return this.sendUncheckedTransaction(e).then((e=>({hash:e,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:t=>this.provider.waitForTransaction(e,t)})))}}const rh={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0};class nh extends _p{constructor(e,t){let r=t;null==r&&(r=new Promise(((e,t)=>{setTimeout((()=>{this.detectNetwork().then((t=>{e(t)}),(e=>{t(e)}))}),0)}))),super(r),e||(e=Ea(this.constructor,"defaultUrl")()),wa(this,"connection","string"==typeof e?Object.freeze({url:e}):Object.freeze(Ca(e))),this._nextId=42}get _cache(){return null==this._eventLoopCache&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout((()=>{this._cache.detectNetwork=null}),0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return zp(this,void 0,void 0,(function*(){yield qp(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch(t){try{e=yield this.send("net_version",[])}catch(e){}}if(null!=e){const t=Ea(this.constructor,"getNetwork");try{return t(y.BigNumber.from(e).toNumber())}catch(t){return Yp.throwError("could not detect network",ks.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:t})}}return Yp.throwError("could not detect network",ks.errors.NETWORK_ERROR,{event:"noNetwork"})}))}getSigner(e){return new eh($p,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then((e=>e.map((e=>this.formatter.address(e)))))}send(e,t){const r={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:Sa(r),provider:this});const n=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(n&&this._cache[e])return this._cache[e];const o=ed(this.connection,JSON.stringify(r),Qp).then((e=>(this.emit("debug",{action:"response",request:r,response:e,provider:this}),e)),(e=>{throw this.emit("debug",{action:"response",error:e,request:r,provider:this}),e}));return n&&(this._cache[e]=o,setTimeout((()=>{this._cache[e]=null}),0)),o}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[Kp(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[Kp(t.address),t.blockTag]];case"getCode":return["eth_getCode",[Kp(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[Kp(t.address),Ls(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":return["eth_call",[Ea(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0}),t.blockTag]];case"estimateGas":return["eth_estimateGas",[Ea(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0})]];case"getLogs":return t.filter&&null!=t.filter.address&&(t.filter.address=Kp(t.filter.address)),["eth_getLogs",[t.filter]]}return null}perform(e,t){return zp(this,void 0,void 0,(function*(){if("call"===e||"estimateGas"===e){const e=t.transaction;if(e&&null!=e.type&&y.BigNumber.from(e.type).isZero()&&null==e.maxFeePerGas&&null==e.maxPriorityFeePerGas){const r=yield this.getFeeData();null==r.maxFeePerGas&&null==r.maxPriorityFeePerGas&&((t=Ca(t)).transaction=Ca(e),delete t.transaction.type)}}const r=this.prepareRequest(e,t);null==r&&Yp.throwError(e+" not implemented",ks.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(r[0],r[1])}catch(r){return Jp(e,r,t)}}))}_startEvent(e){"pending"===e.tag&&this._startPending(),super._startEvent(e)}_startPending(){if(null!=this._pendingFilter)return;const e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then((function(r){return function n(){e.send("eth_getFilterChanges",[r]).then((function(r){if(e._pendingFilter!=t)return null;let n=Promise.resolve();return r.forEach((function(t){e._emitted["t:"+t.toLowerCase()]="pending",n=n.then((function(){return e.getTransaction(t).then((function(t){return e.emit("pending",t),null}))}))})),n.then((function(){return qp(1e3)}))})).then((function(){if(e._pendingFilter==t)return setTimeout((function(){n()}),0),null;e.send("eth_uninstallFilter",[r])})).catch((e=>{}))}(),r})).catch((e=>{}))}_stopEvent(e){"pending"===e.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){const r=Ca(rh);if(t)for(const e in t)t[e]&&(r[e]=!0);var n,o;o=r,(n=e)&&"object"==typeof n||va.throwArgumentError("invalid object","object",n),Object.keys(n).forEach((e=>{o[e]||va.throwArgumentError("invalid object key - "+e,"transaction:"+e,n)}));const i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach((function(t){if(null==e[t])return;const r=Us(y.BigNumber.from(e[t]));"gasLimit"===t&&(t="gas"),i[t]=r})),["from","to","data"].forEach((function(t){null!=e[t]&&(i[t]=Bs(e[t]))})),e.accessList&&(i.accessList=lp(e.accessList)),i}}function oh(e){return Number.parseInt(e,16)}new ks(dd);class ih extends f.Connector{constructor(e,t){super(e),this.customProvider=t,t.on("connect",(({chainId:e})=>{this.actions.update({chainId:oh(e)})})).on("disconnect",(e=>{var t;null===(t=this.onError)||void 0===t||t.call(this,e),this.actions.resetState()})).on("chainChanged",(e=>{this.actions.update({chainId:oh(e)})})).on("accountsChanged",(e=>{this.actions.update({accounts:e})}))}activate(){return ma(this,void 0,void 0,(function*(){this.actions.startActivation();const e=this.customProvider;try{const[{chainId:t},r]=yield Promise.all([e.getNetwork(),e.listAccounts()]);this.actions.update({chainId:t,accounts:r})}catch(e){throw this.actions.resetState(),e}}))}}function sh([e,t]){return[e,t]}var ah;function lh(){return lh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},lh.apply(this,arguments)}var ch,uh;function dh(){return dh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},dh.apply(this,arguments)}var ph;!function(e){e.INTEGRATOR="integrator",e.METAMASK="metamask",e.WALLET_CONNECT="walletConnect"}(ph||(ph={}));const hh={[ph.METAMASK]:{name:"MetaMask",type:ph.METAMASK,icon:function(e){return T.createElement("svg",lh({height:355,viewBox:"0 0 397 355",width:397,xmlns:"http://www.w3.org/2000/svg"},e),ah||(ah=T.createElement("g",{fill:"none",fillRule:"evenodd",transform:"translate(-1 -1)"},T.createElement("path",{d:"m114.622644 327.195472 52.004717 13.810198v-18.05949l4.245283-4.249292h29.716982v21.246459 14.872523h-31.839624l-39.268868-16.997169z",fill:"#cdbdb2"}),T.createElement("path",{d:"m199.528305 327.195472 50.943397 13.810198v-18.05949l4.245283-4.249292h29.716981v21.246459 14.872523h-31.839623l-39.268868-16.997169z",fill:"#cdbdb2",transform:"matrix(-1 0 0 1 483.96227 0)"}),T.createElement("path",{d:"m170.872644 287.889523-4.245283 35.056657 5.306604-4.249292h55.18868l6.367925 4.249292-4.245284-35.056657-8.490565-5.311615-42.452832 1.062323z",fill:"#393939"}),T.createElement("path",{d:"m142.216984 50.9915022 25.471698 59.4900858 11.674528 173.158643h41.391511l12.735849-173.158643 23.349056-59.4900858z",fill:"#f89c35"}),T.createElement("path",{d:"m30.7783023 181.657226-29.71698153 86.048161 74.29245393-4.249293h47.7594343v-37.181303l-2.122641-76.487253-10.613208 8.498583z",fill:"#f89d35"}),T.createElement("path",{d:"m87.0283032 191.218134 87.0283028 2.124646-9.551886 44.617563-41.391511-10.623229z",fill:"#d87c30"}),T.createElement("path",{d:"m87.0283032 192.280457 36.0849058 33.994334v33.994334z",fill:"#ea8d3a"}),T.createElement("path",{d:"m123.113209 227.337114 42.452831 10.623229 13.79717 45.679888-9.551886 5.311615-46.698115-27.620398z",fill:"#f89d35"}),T.createElement("path",{d:"m123.113209 261.331448-8.490565 65.864024 56.25-39.305949z",fill:"#eb8f35"}),T.createElement("path",{d:"m174.056606 193.34278 5.306604 90.297451-15.919812-46.211049z",fill:"#ea8e3a"}),T.createElement("path",{d:"m74.2924539 262.393771 48.8207551-1.062323-8.490565 65.864024z",fill:"#d87c30"}),T.createElement("path",{d:"m24.4103777 355.878193 90.2122663-28.682721-40.3301901-64.801701-73.23113313 5.311616z",fill:"#eb8f35"}),T.createElement("path",{d:"m167.688682 110.481588-45.636793 38.243627-35.0235858 42.492919 87.0283028 3.186969z",fill:"#e8821e"}),T.createElement("path",{d:"m114.622644 327.195472 56.25-39.305949-4.245283 33.994334v19.121813l-38.207548-7.43626z",fill:"#dfcec3"}),T.createElement("path",{d:"m229.245286 327.195472 55.18868-39.305949-4.245283 33.994334v19.121813l-38.207548-7.43626z",fill:"#dfcec3",transform:"matrix(-1 0 0 1 513.679252 0)"}),T.createElement("path",{d:"m132.665096 212.464593-11.674528 24.433427 41.39151-10.623229z",fill:"#393939",transform:"matrix(-1 0 0 1 283.372646 0)"}),T.createElement("path",{d:"m23.349057 1.06232296 144.339625 109.41926504-24.410378-59.4900858z",fill:"#e88f35"}),T.createElement("path",{d:"m23.349057 1.06232296-19.10377392 58.42776294 10.61320772 63.7393781-7.42924541 4.249292 10.61320771 9.560906-8.49056617 7.436261 11.67452847 10.623229-7.4292454 6.373938 16.9811323 21.246459 79.5990577-24.433428c38.915096-31.161473 58.018869-47.096318 57.311322-47.804533-.707548-.708215-48.820756-37.1813036-144.339625-109.41926504z",fill:"#8e5a30"}),T.createElement("g",{transform:"matrix(-1 0 0 1 399.056611 0)"},T.createElement("path",{d:"m30.7783023 181.657226-29.71698153 86.048161 74.29245393-4.249293h47.7594343v-37.181303l-2.122641-76.487253-10.613208 8.498583z",fill:"#f89d35"}),T.createElement("path",{d:"m87.0283032 191.218134 87.0283028 2.124646-9.551886 44.617563-41.391511-10.623229z",fill:"#d87c30"}),T.createElement("path",{d:"m87.0283032 192.280457 36.0849058 33.994334v33.994334z",fill:"#ea8d3a"}),T.createElement("path",{d:"m123.113209 227.337114 42.452831 10.623229 13.79717 45.679888-9.551886 5.311615-46.698115-27.620398z",fill:"#f89d35"}),T.createElement("path",{d:"m123.113209 261.331448-8.490565 65.864024 55.18868-38.243626z",fill:"#eb8f35"}),T.createElement("path",{d:"m174.056606 193.34278 5.306604 90.297451-15.919812-46.211049z",fill:"#ea8e3a"}),T.createElement("path",{d:"m74.2924539 262.393771 48.8207551-1.062323-8.490565 65.864024z",fill:"#d87c30"}),T.createElement("path",{d:"m24.4103777 355.878193 90.2122663-28.682721-40.3301901-64.801701-73.23113313 5.311616z",fill:"#eb8f35"}),T.createElement("path",{d:"m167.688682 110.481588-45.636793 38.243627-35.0235858 42.492919 87.0283028 3.186969z",fill:"#e8821e"}),T.createElement("path",{d:"m132.665096 212.464593-11.674528 24.433427 41.39151-10.623229z",fill:"#393939",transform:"matrix(-1 0 0 1 283.372646 0)"}),T.createElement("path",{d:"m23.349057 1.06232296 144.339625 109.41926504-24.410378-59.4900858z",fill:"#e88f35"}),T.createElement("path",{d:"m23.349057 1.06232296-19.10377392 58.42776294 10.61320772 63.7393781-7.42924541 4.249292 10.61320771 9.560906-8.49056617 7.436261 11.67452847 10.623229-7.4292454 6.373938 16.9811323 21.246459 79.5990577-24.433428c38.915096-31.161473 58.018869-47.096318 57.311322-47.804533-.707548-.708215-48.820756-37.1813036-144.339625-109.41926504z",fill:"#8e5a30"})))))},link:"https://metamask.io"},[ph.WALLET_CONNECT]:{name:"WalletConnect",type:ph.WALLET_CONNECT,icon:function(e){return T.createElement("svg",dh({height:512,viewBox:"0 0 512 512",width:512,xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),ch||(ch=T.createElement("radialGradient",{id:"a",cx:"0%",cy:"50%",r:"100%"},T.createElement("stop",{offset:0,stopColor:"#5d9df6"}),T.createElement("stop",{offset:1,stopColor:"#006fff"}))),uh||(uh=T.createElement("g",{fill:"none",fillRule:"evenodd"},T.createElement("path",{d:"m256 0c141.384896 0 256 114.615104 256 256s-114.615104 256-256 256-256-114.615104-256-256 114.615104-256 256-256z",fill:"url(#a)"}),T.createElement("path",{d:"m64.6917558 37.7088298c51.5328072-50.2784397 135.0839942-50.2784397 186.6167992 0l6.202057 6.0510906c2.57664 2.5139218 2.57664 6.5897948 0 9.1037177l-21.215998 20.6995759c-1.288321 1.2569619-3.3771 1.2569619-4.665421 0l-8.534766-8.3270205c-35.950573-35.0754962-94.237969-35.0754962-130.188544 0l-9.1400282 8.9175519c-1.2883217 1.2569609-3.3771016 1.2569609-4.6654208 0l-21.2159973-20.6995759c-2.5766403-2.5139229-2.5766403-6.5897958 0-9.1037177zm230.4934852 42.8089117 18.882279 18.4227262c2.576627 2.5139103 2.576642 6.5897593.000032 9.1036863l-85.141498 83.070358c-2.576623 2.513941-6.754182 2.513969-9.33084.000066-.00001-.00001-.000023-.000023-.000033-.000034l-60.428256-58.957451c-.64416-.628481-1.68855-.628481-2.33271 0-.000004.000004-.000008.000007-.000012.000011l-60.4269683 58.957408c-2.5766141 2.513947-6.7541746 2.51399-9.3308408.000092-.0000151-.000014-.0000309-.000029-.0000467-.000046l-85.14386774-83.071463c-2.57663928-2.513921-2.57663928-6.589795 0-9.1037163l18.88231264-18.4226955c2.5766393-2.5139222 6.7541993-2.5139222 9.3308397 0l60.4291347 58.9582758c.6441608.62848 1.6885495.62848 2.3327103 0 .0000095-.000009.0000182-.000018.0000277-.000025l60.4261065-58.9582508c2.576581-2.51398 6.754142-2.5140743 9.33084-.0002103.000037.0000354.000072.0000709.000107.0001063l60.429056 58.9583548c.644159.628479 1.688549.628479 2.332709 0l60.428079-58.9571925c2.57664-2.5139231 6.754199-2.5139231 9.330839 0z",fill:"#fff",fillRule:"nonzero",transform:"translate(98 160)"}))))}}},fh={};function mh({provider:e,jsonRpcUrlMap:t,defaultChainId:r}){const o=console.error,i=n.useMemo((()=>function(e,t){if(t){if(nh.isProvider(t))return sh(u.initializeConnector((e=>new ih(e,t))));if(nh.isProvider(t.provider))throw new Error("Eip1193Bridge is experimental: pass your ethers Provider directly");return sh(u.initializeConnector((r=>new d.EIP1193({actions:r,provider:t,onError:e}))))}}(o,e)),[o,e]),s=n.useMemo((()=>function(e){return sh(u.initializeConnector((t=>new h.MetaMask({actions:t,onError:e}))))}(o)),[o]),a=n.useMemo((()=>t?Object.assign(Object.assign({},sa),t):sa),[t]),l=n.useMemo((()=>function(e,t,r,n){return sh(u.initializeConnector((o=>new p.WalletConnect({actions:o,options:{rpcMap:t,projectId:"59e050d1f27ed617e65bb9637c9498d6",chains:r?[r]:[],showQrModal:e},onError:n,defaultChainId:r}))))}(!0,a,r,o)),[a,r,o]);return i&&(fh[ph.INTEGRATOR]=i),fh[ph.METAMASK]=s,fh[ph.WALLET_CONNECT]=l,Object.values(fh)}const gh={colorMode:"dark",slippage:3..toString(),ddl:20};var yh=(e=gh,t)=>{switch(t.type){case"SET_COLOR_MODE":return Object.assign(Object.assign({},e),{colorMode:t.payload});case"SET_SLIPPAGE":return Object.assign(Object.assign({},e),{slippage:t.payload});case"SET_TRANSACTION_DDL":return Object.assign(Object.assign({},e),{ddl:t.payload});default:return e}};const bh={chainId:ia.MAINNET,latestBlockNumber:0};var xh=(e=bh,t)=>{switch(t.type){case"SET_CHAIN_ID":return Object.assign(Object.assign({},e),{chainId:t.payload});case"SET_BLOCK_NUMBER":return Object.assign(Object.assign({},e),{latestBlockNumber:t.payload});default:return e}};const vh={tokenList:[],popularTokenList:[],ethBalance:{},accountBalances:{},balanceLoadings:{},slippageWithTokens:[]};var wh,Eh=(e=vh,t)=>{switch(t.type){case"SET_TOKEN_LIST":return Object.assign(Object.assign({},e),{tokenList:t.payload});case"SET_POPULAR_TOKEN_LIST":return Object.assign(Object.assign({},e),{popularTokenList:t.payload});case"SET_SLIPPAGE_WITH_TOKENS":return Object.assign(Object.assign({},e),{slippageWithTokens:t.payload});case"SET_ETH_BALANCE":return Object.assign(Object.assign({},e),{ethBalance:Object.assign(Object.assign({},e.ethBalance),t.payload)});case"SET_DEFAULT_FROM_TOKEN":return Object.assign(Object.assign({},e),{defaultFromToken:t.payload});case"SET_DEFAULT_TO_TOKEN":return Object.assign(Object.assign({},e),{defaultToToken:t.payload});case"SET_ACCOUNT_BALANCES":return Object.assign(Object.assign({},e),{accountBalances:Object.assign(Object.assign({},e.accountBalances),t.payload)});case"SET_ACCOUNT_ALLOWANCES":const r=Object.assign({},e.accountBalances);return Object.keys(r).map((e=>{r[e].tokenAllowances=t.payload})),Object.assign(Object.assign({},e),{accountBalances:r});case"SET_BALANCE_LOADINGS":return Object.assign(Object.assign({},e),{balanceLoadings:Object.assign(Object.assign({},e.balanceLoadings),t.payload)});default:return e}};!function(e){e.Initial="Initial",e.Pending="Pending",e.ApproveSuccess="ApproveSuccess",e.TxSuccess="TxSuccess",e.Failed="Failed"}(wh||(wh={}));const Ah={height:void 0,width:void 0,apikey:"",feeRate:0,rebateTo:"",isReverseRouting:!1,contractStatus:wh.Initial,autoConnectLoading:void 0};var Ch=(e=Ah,t)=>{switch(t.type){case"SET_GLOBAL_PROPS":return Object.assign(Object.assign({},e),t.payload);case"SET_AUTO_CONNECT_LOADING":return Object.assign(Object.assign({},e),{autoConnectLoading:t.payload});default:return e}};const kh={settings:gh,wallet:bh,globals:Ah,token:vh},Rh=g.combineReducers({settings:yh,wallet:xh,token:Eh,globals:Ch}),Th=m.configureStore({reducer:Rh,middleware:e=>e({serializableCheck:{ignoredActions:["SET_ACCOUNT_BALANCES","SET_ETH_BALANCE"],ignoredPaths:["token.accountBalances","token.ethBalance"]}}),preloadedState:kh}),Sh=e=>(null!=e?e:Th.getState()).wallet.chainId,Nh=e=>(null!=e?e:Th.getState()).wallet.latestBlockNumber;function Mh(){const{chainId:e}=u.useWeb3React(),t=l.useSelector(Sh);return n.useMemo((()=>e||t||1),[e,t])}var Fh=[{chainId:1,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ether",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/prKmKP8yDTuPMHTCZ_DcxG8BqsuHNO8w5KDmJWmPodg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vOUVaWU1ER2ZVN3g2N3ZBZThqWkUxZzA0RExUaFhaV0JIb09wZFhpeXhHRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNNeVgyTnZhVzV0WVhKclpYUmpZWEJmWTI5dFgzTjBZWFJwWTE5cGJXZGZZMjlwYm5OZk5qUjROalJmTVRBeU4xOHhNekkyTjJGbE5EY3dMbkJ1WncucG5n.webp"},{chainId:1,address:"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",name:"USD Coin",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/sQ5dF3FkjjQUsmfqFFE5cKq-cthh4u0wUooBE5Epf-k/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTDlEVElLa2dONG5mRkNTSF9GMUdXU3JiZkJDa2JZRTkwbmFDS0dIWnRsby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMM1Z6WkdOZlpXVTFNbUV4WldReVlpOTFjMlJqWDJWbE5USmhNV1ZrTW1JdWNHNW4ucG5n.webp"},{chainId:1,address:"0x4Fabb145d64652a948d72533023f6E7A623C7C53",name:"Binance USD",decimals:18,symbol:"BUSD",logoURI:"https://cmp.dodoex.io/xZmadzpVOnpuq2jNG_5EGKeqMET0LU_gmfnp4VxkcxI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vSHQwWXZKMGNnU0lGTFM0aHExTV9jOXVITV9fMHpXaHBKSGVOQU5neTBuby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMkoxYzJSZk4ySTJOalJpWWpReVpDOWlkWE5rWHpkaU5qWTBZbUkwTW1RdWNHNW4ucG5n.webp"},{chainId:1,address:"0x6b175474e89094c44da98b954eedeac495271d0f",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/h2lbKBfBJ2LNSTNCuwjsBkshT4eXzDDmAV0lhWS0llA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUnVJNWt2eHBwalI4TTZsenFZZVAyTTB4eVFMUGJ0S1hONDdWVTN1dUszZy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmWmpBNU5qUmpPVFUxT1M1d2JtYy5wbmc.webp"},{chainId:1,address:"0x43dfc4159d86f3a37a5a4b3d4580b888ad7d4ddd",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/PGIGjN4ix9pInoESO_mCmajbMpygApWZyGKaE6vyJFk/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8veFJDQ0hnQXBuaENRTFZNUXAwdTdwd0pSQzIxRHJ4cFY0b2Z0bndaYnRmMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk5UaGxZelEyTlRFelpTOUVUMFJQWHpVNFpXTTBOalV4TTJVdWMzWm4uc3Zn.webp"},{chainId:1,address:"0xdac17f958d2ee523a2206206994597c13d831ec7",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:1,address:"0x2260fac5e5542a773aa44fbcfedf7c193bc2c599",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:1,address:"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",name:"Wrapped Ether",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/mI69kq-S-tNT1W57qYizPd5r2WNFzpAq5y6NhOcrTkY/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vVEZhSVNLVVZIWThLTVhyTkVmZDRXRUJmMGJoSHRweHY3Q1hDT0dKbGY2by9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmT0dVeFpEaG1PVEEyWlM1d2JtYy5wbmc.webp"},{chainId:5,symbol:"USDC",address:"0xC4106029d03c33731Ca01Ba59b5A6368c660E596",name:"USDC",decimals:6,logoURI:""},{chainId:5,symbol:"USDT",address:"0xed8a325D87D3b6edED04FB992A1482231647EE5e",name:"USDT Token",decimals:6,logoURI:""},{chainId:5,symbol:"WETH",address:"0xB4FBF271143F4FBf7B91A5ded31805e42b2208d6",name:"Wrapped Ether",decimals:18,logoURI:""},{chainId:5,symbol:"ETH",address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ether",decimals:18,logoURI:""},{chainId:56,address:"0xe9e7cea3dedca5984780bafc599bd69add087d56",name:"BUSD Token",decimals:18,symbol:"BUSD",logoURI:"https://cmp.dodoex.io/BvxyffA5gsLB4bLmlOVkfu7AVami78-VcW_6_i8I6kc/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vbC1Sa25meFB3ZXlCOGVYSWJ2b04wdHczLTlzckZOckxfRHdTTnRLSHVRRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDJOa2JsOXRaV1JwWVY5a2IyUnZaWGhmYVc5ZlluVnpaRjgyTXpsbFlqZzNZV0V4WDJKMWMyUmZOak01WldJNE4yRmhNVjlsT1dVMVlXRTBOemxtTG5OMlp3LnN2Zw.webp"},{chainId:56,address:"0x55d398326f99059ff775485246999027b3197955",name:"Tether USD",decimals:18,symbol:"USDT",logoURI:"https://cmp.dodoex.io/QOl7CvP_WSmTUOMthbxQsNKjDj0s5kSjup69dW_-UeA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTjdQU3RXV2ZGaGNTVzM1QlE2TEJIaF9keVROUEJqa1RLTXRwTll5cEhSWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDJOa2JsOXRaV1JwWVY5a2IyUnZaWGhmYVc5ZmRYTmtkRjh4TlRZME1XWmpaRFF3WDNWelpIUmZNVFUyTkRGbVkyUTBNRjlqWmpJMVpUYzVZVE5qTG5OMlp3LnN2Zw.webp"},{chainId:56,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"BNB",decimals:18,symbol:"BNB",logoURI:"https://cmp.dodoex.io/BWNSMMqu68bSFJsr9vsiCV09IonH3yuAkR9gQxaipBw/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZDhvazF4akd3bU9GUXUtMVdzNEVRLVBNRnJYMW9DLXlmYTc3OGJUUkx0US9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpPUWw5alpEUTVNalE0TXpJMkwwSk9RbDlqWkRRNU1qUTRNekkyTG5CdVp3LnBuZw.webp"},{chainId:56,address:"0x7130d2a12b9bcbfae4f2634d864a1ee1ce3ead9c",name:"BTCB Token",decimals:18,symbol:"BTCB",logoURI:"https://cmp.dodoex.io/fZG0z_RZ1U73_LuuC3RGrrZvNR-bgrCUjkwvaro-PCY/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZ1NXN0RuYWNkMnc2YWxSQnFmcENqTHNDZWJhc2VtQTc0dDJlTEdDZjhfNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmWmpJNVlXRmpZamxoTVM1d2JtYy5wbmc.webp"},{chainId:56,address:"0x1af3f329e8be154074d8769d1ffa4ee058b1dbc3",name:"Dai Token",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/bhz9Vtma8hPb_-GnhwqQkhfTQ5PwKcR1Qbzn7aBKlfs/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZW04OHB4YXNDdEg0Nl9BcjhVandzZWR2SFBFUUtjVWVkc0FmV2lvenB2Yy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmWVRoaFptSmxaRFppWkM1d2JtYy5wbmc.webp"},{chainId:56,address:"0x67ee3Cb086F8a16f34beE3ca72FAD36F7Db929e2",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/PGIGjN4ix9pInoESO_mCmajbMpygApWZyGKaE6vyJFk/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8veFJDQ0hnQXBuaENRTFZNUXAwdTdwd0pSQzIxRHJ4cFY0b2Z0bndaYnRmMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk5UaGxZelEyTlRFelpTOUVUMFJQWHpVNFpXTTBOalV4TTJVdWMzWm4uc3Zn.webp"},{chainId:56,address:"0x2170ed0880ac9a755fd29b2688956bd959f933f8",name:"Ethereum Token",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:56,address:"0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d",name:"Binance-Peg USD Coin",decimals:18,symbol:"USDC",logoURI:"https://cmp.dodoex.io/sQ5dF3FkjjQUsmfqFFE5cKq-cthh4u0wUooBE5Epf-k/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTDlEVElLa2dONG5mRkNTSF9GMUdXU3JiZkJDa2JZRTkwbmFDS0dIWnRsby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMM1Z6WkdOZlpXVTFNbUV4WldReVlpOTFjMlJqWDJWbE5USmhNV1ZrTW1JdWNHNW4ucG5n.webp"},{chainId:56,address:"0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c",name:"Wrapped BNB",decimals:18,symbol:"WBNB",logoURI:"https://cmp.dodoex.io/-Pua5rc9k9iW4yuF5ajLVKzMkRhBq06D8HiEZ5gjezA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMDZOWTdBTmdOYWdFOHpXYUMtX2IzYXVPOUxsTEp6QlpLTUR3VlM5eW9DQS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmT1dRellXTmtZMlEzTnk1d2JtYy5wbmc.webp"},{chainId:137,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"MATIC",decimals:18,symbol:"MATIC",logoURI:"https://cmp.dodoex.io/cQFrEB6yGIqMkh_6Pie8VR3kIStL58IS-y8FbroHVwA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vc2VNUUk2dkpoaXljeldrczJaWWdGdk8zSEoxSWFIa053LXZYeXFneER4US9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMekZmTWpkbE56TXlNRE13TWk4eFh6STNaVGN6TWpBek1ESXVjRzVuLnBuZw.webp"},{chainId:137,address:"0xe4bf2864ebec7b7fdf6eeca9bacae7cdfdaffe78",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/KEPetVp3nQkB6BZ_cb05trEfBbGxFEg92UnF8NZsEzM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vVE5wTlRseEJGbFRDalM1ZFh3SWJ3Mm1hZ3NPUFFkZ3Z1UEhuZDZrNWdyMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk4yUTBaamxtTldOaU15OUVUMFJQWHpka05HWTVaalZqWWpNdWNHNW4ucG5n.webp"},{chainId:137,address:"0x8f3Cf7ad23Cd3CaDbD9735AFf958023239c6A063",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/hdRkGay_hj0t1OzN5C3c30cmch26tJhHUSroffg7ciY/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vOHd3UndQOG9DTTdBcF9NOW11bGVOQWRqYjhBOXpvX2FYUE5pVTNBYUtzYy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhnMlgwSXhOelUwTnpSZlJUZzVNRGswWDBNME5GOUVZVGs0WWprMU5GOUZaV1JsWDBGRFh6UTVOVEkzTVdRd1gwWmZiRzluYjE4MFpXSXdNVE0zTVRZeExuQnVady5wbmc.webp"},{chainId:137,address:"0x7ceB23fD6bC0adD59E62ac25578270cFf1b9f619",name:"Ether",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/WAobi4MZtLSxB59wgpyNlXLI44ZwlBh55qiGS2wLSGU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vSUVnUUx3TjRMU2dKRDJTM3RmSFlHcmxZbFZQNGlJeFcxeEZVOUwwUExRNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoZlF6QXlZV0ZmUVRNNVlqSXlNMTlHUlY4NFgwUXdYMEV3WlRWZlF6UmZSakkzWlY5QlJGODVNRGd6WDBNM05UWmZRMk15WDJ4dloyOWZZelk0WXprelpHRXlNQzV3Ym1jLnBuZw.webp"},{chainId:137,address:"0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174",name:"USD Coin",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/er3iAGv39hCC7F8AydW_AteD3hnZj9HI2XcAaruHeqA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vVE9WUWtzN3JQWU5OZWdmNTRuNC1Za1NGTFYyLXVGZmlJRFVYem85aVMzOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoZlFUQmlPRFk1T1RGak5qSXhPR0l6Tm1NeFpERTVYMFEwWVRKbE9WOUZZakJqWDBVek5qQTJaVjlDTkRoZmJHOW5iMTlpTmpGbE5EVmtNbVF6TG5CdVp3LnBuZw.webp"},{chainId:137,address:"0xc2132D05D31c914a87C6611C10748AEb04B58e8F",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/WeK6L9_RjWUfAsnMuOAdyXIZVE3JK_H3lZU5vk2m7Tg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTFJ0aEt6X2VrSXdmTEh6NnAycW5rSkRFeUk1RXZrODlXQ0J2VW43MUJLNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoa1gwRkRYekUzWDBZNU5UaGZSREpsWlRVeU0yRXlNakEyTWpBMk9UazBOVGszWDBNeE0xOUVPRE14WldNM1gyeHZaMjlmWXpCbU9XVTFaamxoTmk1d2JtYy5wbmc.webp"},{chainId:137,address:"0x1BFD67037B42Cf73acF2047067bd4F2C47D9BfD6",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/_KjvB9pCVqbIIv_UnQvRWpjySBHiFnuHNSXUm_52UZM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZDQ4OVYzTW1NMi1qaFJueEQ2Y3MyY1gydXdGS2tkRHpiRGZsbkZhTTJxOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhneU1qWXdYMFpCUTE4MVgwVTFOVFF5WVRjM00xOUJZVFEwWmw5Q1gwTm1aVjlFWmpkZlF6RTVNMkpqTWw5RE5UazVYMnh2WjI5Zk5HTmpORE0zTlRneFppNXdibWMucG5n.webp"},{chainId:137,address:"0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270",name:"Wrapped MATIC",decimals:18,symbol:"WMATIC",logoURI:"https://cmp.dodoex.io/HfZVSaAES3QRplSybW2uoKmYf6pVTRaxufn95_Qto_A/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMERhZEZTUUVFX0d4YlBoMHY3Wk1Hb1FwaWtOQm1vaWFyZTFlaFdJbU44dy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMjFoZEdsalgyVmlOekZtTkdFMU9XRXZiV0YwYVdOZlpXSTNNV1kwWVRVNVlTNTNaV0p3LndlYnA.webp"},{chainId:42161,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"ETH",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:42161,address:"0x82aF49447D8a07e3bd95BD0d56f35241523fBab1",name:"Wrapped Ether",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/6VmZGvbENd4TM1VK0rsYrfznRtG-GwxP-zCy2qyc9bM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWnJZUDB0ZHVTLUdDNE5FTThmRmV1RHhVWklPNUZpWnpqdkdBc0lfNlBQMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh5TW1GbU4yVTVOVFJpTDFkRlZFaGZhV052Ymw4eU1tRm1OMlU1TlRSaUxuQnVady5wbmc.webp"},{chainId:42161,address:"0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/XNbyKKzPthXfYOku9oXt5xzqM1JOWzxmbTLq2kkSvaU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWHprMUxKSzJ2V1BYVmN3TmVvVDRfR3NNdnBOVXFmTmliXzgybFZSVUNkWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmYzNWemFHbHpkMkZ3WDJsamIyNXpYMjFoYzNSbGNsOTBiMnRsYmw5a1lXbGZPRGhrT0dNeE5HRTBZaTVxY0djLmpwZw.webp"},{chainId:42161,address:"0x69Eb4FA4a2fbd498C257C57Ea8b7655a2559A581",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/6U51l5aajoRrCaO6cpbrclQ2olWNDzuShggOCfoktCA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8va3RkSlhwQ3dsQVZtZXNPb1dvQV95SG9IazBnV3UxUExienBKa1AxYnlJdy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk5tTmtPVEV4WXprNE15OUVUMFJQWHpaalpEa3hNV001T0RNdWNHNW4ucG5n.webp"},{chainId:42161,address:"0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8",name:"USD Coin (Arb1)",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/EaCi6KUTS-dinU-wGdG2IcundJ0fJfsOw97FRI2vaB8/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdEVMaUx0Y1FaTVlBb3hkeExLdnRrZ2ltdVB5dmZRdUQ5U1BxU1c1bDZsMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZmFXTnZibDh5WlRFeU5tSTRaRFV5TDFWVFJFTmZhV052Ymw4eVpURXlObUk0WkRVeUxuQnVady5wbmc.webp"},{chainId:42161,address:"0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:42161,address:"0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:66,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"OKT",decimals:18,symbol:"OKT",logoURI:"https://cmp.dodoex.io/pcltGNcIp7DP33nj3YxxBpuFEekNcOW3pwq9tjSrpY4/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTzJHSDJYTndRancwbXMzQXNidG5xNzRkVEROVld3QWFOU1dXU2ZnU01QTS9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6RTVOalF5T1RCZk1qQXlNakExTWpBd056STNORFl3TWpJdWMzWm4uc3Zn.webp"},{chainId:66,address:"0x382bB369d343125BfB2117af9c149795C6C65C50",name:"USDT",decimals:18,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:66,address:"0x218c3c3D49d0E7B37aff0D8bB079de36Ae61A4c0",name:"BNB",decimals:18,symbol:"BNB",logoURI:"https://cmp.dodoex.io/BWNSMMqu68bSFJsr9vsiCV09IonH3yuAkR9gQxaipBw/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZDhvazF4akd3bU9GUXUtMVdzNEVRLVBNRnJYMW9DLXlmYTc3OGJUUkx0US9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpPUWw5alpEUTVNalE0TXpJMkwwSk9RbDlqWkRRNU1qUTRNekkyTG5CdVp3LnBuZw.webp"},{chainId:66,address:"0x54e4622DC504176b3BB432dCCAf504569699a7fF",name:"BTCK",decimals:18,symbol:"BTCK",logoURI:"https://cmp.dodoex.io/L3kcNUKg94qnX8OPFlEvHKqWybnJD8SA9HTne3PW-Rg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vNU1MQTB3Q3V6eEs4Q3ZMV0RqempuOVhzalBTWE1zbUpWZ0RRN1RPMG9FWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpVUTB0Zk1HWmlaRGRsTWpnNU5pOUNWRU5MWHpCbVltUTNaVEk0T1RZdWNHNW4ucG5n.webp"},{chainId:66,address:"0x332730a4F6E03D9C55829435f10360E13cfA41Ff",name:"BUSD",decimals:18,symbol:"BUSD",logoURI:"https://cmp.dodoex.io/-aEkA13gC6lOFoRyGeSy2BotE5YY3WUmcSlPa9Rpddc/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaXVmSjhaNHFJYzlMMDgtNHpxRUMxWl94WVlqRkEtT3BqS1FJbmQyeHpHUS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpWVTBSZk1XTTJNRFpqTjJZeE55OUNWVk5FWHpGak5qQTJZemRtTVRjdWNHNW4ucG5n.webp"},{chainId:66,address:"0x21cDE7E32a6CAF4742d00d44B07279e7596d26B9",name:"DAIK",decimals:18,symbol:"DAIK",logoURI:"https://cmp.dodoex.io/LOb-sXupURNN9HA0zBSfLfpZlx52N9qRSDUyzk3cg0A/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vck5pZzMtWU5TOUl4T3ZHX19taTFRSU9WYTZsczdZNXViRVhGcTJJVGplby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJCU1V0Zk5ESTVNV1l4WlRoa1pTOUVRVWxMWHpReU9URm1NV1U0WkdVdWNHNW4ucG5n.webp"},{chainId:66,address:"0xEF71CA2EE68F45B9Ad6F72fbdb33d707b872315C",name:"ETHK",decimals:18,symbol:"ETHK",logoURI:"https://cmp.dodoex.io/IwBclhMMQLOo79RdRo6-HnUiXxshO_hSi02YK3L6MFI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcFBSd192aEx2MHh3WkRHU2k3eGYyYVJiQjlocVhfU2tacUdGc3RJR0pYRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFZVU0V0Zk1UQTVNamMzTW1VMU9DOUZWRWhMWHpFd09USTNOekpsTlRndWNHNW4ucG5n.webp"},{chainId:66,address:"0xc946DAf81b08146B1C7A8Da2A851Ddf2B3EAaf85",name:"USDC",decimals:18,symbol:"USDC",logoURI:"https://cmp.dodoex.io/bXLFjIP5_obFZS9jvWA1bZc2b2Vsw4-tqcvj10aPUpU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcXhZT0hTcDYzemNTaDVHRVV1SFlya3JGS2s1MW9zLVUycG42bjNXV2pYay9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZk1UTTFZak13TkRkaVpDOVZVMFJEWHpFek5XSXpNRFEzWW1RdWNHNW4ucG5n.webp"},{chainId:66,address:"0xdCAC52E001f5bd413aa6ea83956438F29098166b",name:"USDK",decimals:18,symbol:"USDK",logoURI:"https://cmp.dodoex.io/X-_D75ZOpI-yC70WjdgC8wiqcssfRIALEv0eUfD3HiE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vd290dHEzaWdkTDVzQlhSR2VFZkhQLTNpZHhDZzV0V3VGQmE3YjNrNUZITS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkV0Zk56aGpZekV6TW1OaVpDOVZVMFJMWHpjNFkyTXhNekpqWW1RdWNHNW4ucG5n.webp"},{chainId:66,address:"0x506f731F7656e2FB34b587B912808f2a7aB640BD",name:"WBTCK",decimals:18,symbol:"WBTCK",logoURI:"https://cmp.dodoex.io/7Gb1gYkvjWESf9ungWe4YKOrr5GY5UILmTwU_U95kCA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vOTQ4NWZpU2NmUzBNc2V1YVZXWXo2Z1RuNVVidXJvZkxmN1VGSWhMdndjTS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOTFgyVXlZamRpWVRJNU16TXZWMEpVUTB0ZlpUSmlOMkpoTWprek15NXdibWMucG5n.webp"},{chainId:1313161554,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ethereum",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/WAobi4MZtLSxB59wgpyNlXLI44ZwlBh55qiGS2wLSGU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vSUVnUUx3TjRMU2dKRDJTM3RmSFlHcmxZbFZQNGlJeFcxeEZVOUwwUExRNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoZlF6QXlZV0ZmUVRNNVlqSXlNMTlHUlY4NFgwUXdYMEV3WlRWZlF6UmZSakkzWlY5QlJGODVNRGd6WDBNM05UWmZRMk15WDJ4dloyOWZZelk0WXprelpHRXlNQzV3Ym1jLnBuZw.webp"},{chainId:1313161554,address:"0xC9BdeEd33CD01541e1eeD10f90519d2C06Fe3feB",name:"Wrapped Ethereum",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:1313161554,address:"0x8BEc47865aDe3B172A928df8f990Bc7f2A3b9f79",name:"Aurora",decimals:18,symbol:"Aurora",logoURI:"https://cmp.dodoex.io/2C2jfpO2-VYuwlga3SdtP5I6eJNJXIYq3LvPU4aFuiU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcHFWVWlJOEQ4VU5iUEZYRElvUnA3cFhEZFc4dmx4dWEtTmxubmxlam1PMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMkYxY205eVlWOHlOVEprWlRFeE56YzBMMkYxY205eVlWOHlOVEprWlRFeE56YzBMbmRsWW5BLndlYnA.webp"},{chainId:1313161554,address:"0xe3520349F477A5F6EB06107066048508498A291b",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/XNbyKKzPthXfYOku9oXt5xzqM1JOWzxmbTLq2kkSvaU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWHprMUxKSzJ2V1BYVmN3TmVvVDRfR3NNdnBOVXFmTmliXzgybFZSVUNkWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmYzNWemFHbHpkMkZ3WDJsamIyNXpYMjFoYzNSbGNsOTBiMnRsYmw5a1lXbGZPRGhrT0dNeE5HRTBZaTVxY0djLmpwZw.webp"},{chainId:1313161554,address:"0xe301eD8C7630C9678c39E4E45193D1e7Dfb914f7",name:"DODO Bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/SEcMDWMmtHb3GFW5l7fTKYurpTqALHdZI3D6qzad1rs/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vQXRNMzllUjhRQzhYTl8tem5HU0pSLS1lV0tPUW91V3p2ci0zQ014WlJTSS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMekl3TUhneU1EQmZNVjh3WWpReFl6VTJZV1UxTHpJd01IZ3lNREJmTVY4d1lqUXhZelUyWVdVMUxuQnVady5wbmc.webp"},{chainId:1313161554,address:"0xB12BFcA5A55806AaF64E99521918A4bf0fC40802",name:"USD Coin",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/EaCi6KUTS-dinU-wGdG2IcundJ0fJfsOw97FRI2vaB8/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdEVMaUx0Y1FaTVlBb3hkeExLdnRrZ2ltdVB5dmZRdUQ5U1BxU1c1bDZsMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZmFXTnZibDh5WlRFeU5tSTRaRFV5TDFWVFJFTmZhV052Ymw4eVpURXlObUk0WkRVeUxuQnVady5wbmc.webp"},{chainId:1313161554,address:"0x4988a896b1227218e4A686fdE5EabdcAbd91571f",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:1313161554,address:"0xF4eB217Ba2454613b15dBdea6e5f22276410e89e",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:43114,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Avalanche",decimals:18,symbol:"AVAX",logoURI:"https://cmp.dodoex.io/yBkeC0v6hqQP-wNBxAq_C_D6JTYUc4Q86Wh6WIciESI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcmpNamFFdHJ5WUZxNks3TkpxYkRWczlEZF80aHp4ZUo3YnB0eGgtVERDYy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMjEzWDI1ZlRqaHRNRjgwTURCNE5EQXdYems0WlRKaU5EQm1PRGN2YlhkZmJsOU9PRzB3WHpRd01IZzBNREJmT1RobE1tSTBNR1k0Tnk1cWNHYy5qcGc.webp"},{chainId:43114,address:"0xB31f66AA3C1e785363F0875A1B74E27b85FD66c7",name:"Wrapped AVAX",decimals:18,symbol:"WAVAX",logoURI:"https://cmp.dodoex.io/yBkeC0v6hqQP-wNBxAq_C_D6JTYUc4Q86Wh6WIciESI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcmpNamFFdHJ5WUZxNks3TkpxYkRWczlEZF80aHp4ZUo3YnB0eGgtVERDYy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMjEzWDI1ZlRqaHRNRjgwTURCNE5EQXdYems0WlRKaU5EQm1PRGN2YlhkZmJsOU9PRzB3WHpRd01IZzBNREJmT1RobE1tSTBNR1k0Tnk1cWNHYy5qcGc.webp"},{chainId:43114,address:"0x19860CCB0A68fd4213aB9D8266F7bBf05A8dDe98",name:"Binance USD",decimals:18,symbol:"BUSD.e",logoURI:"https://cmp.dodoex.io/-aEkA13gC6lOFoRyGeSy2BotE5YY3WUmcSlPa9Rpddc/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaXVmSjhaNHFJYzlMMDgtNHpxRUMxWl94WVlqRkEtT3BqS1FJbmQyeHpHUS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpWVTBSZk1XTTJNRFpqTjJZeE55OUNWVk5FWHpGak5qQTJZemRtTVRjdWNHNW4ucG5n.webp"},{chainId:43114,address:"0xd586E7F844cEa2F87f50152665BCbc2C279D8d70",name:"Dai Stablecoin",decimals:18,symbol:"DAI.e",logoURI:"https://cmp.dodoex.io/XNbyKKzPthXfYOku9oXt5xzqM1JOWzxmbTLq2kkSvaU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWHprMUxKSzJ2V1BYVmN3TmVvVDRfR3NNdnBOVXFmTmliXzgybFZSVUNkWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmYzNWemFHbHpkMkZ3WDJsamIyNXpYMjFoYzNSbGNsOTBiMnRsYmw5a1lXbGZPRGhrT0dNeE5HRTBZaTVxY0djLmpwZw.webp"},{chainId:43114,address:"0xA7D7079b0FEaD91F3e65f86E8915Cb59c1a4C664",name:"USD Coin",decimals:6,symbol:"USDC.e",logoURI:"https://cmp.dodoex.io/bXLFjIP5_obFZS9jvWA1bZc2b2Vsw4-tqcvj10aPUpU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcXhZT0hTcDYzemNTaDVHRVV1SFlya3JGS2s1MW9zLVUycG42bjNXV2pYay9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZk1UTTFZak13TkRkaVpDOVZVMFJEWHpFek5XSXpNRFEzWW1RdWNHNW4ucG5n.webp"},{chainId:43114,address:"0xc7198437980c041c805A1EDcbA50c1Ce5db95118",name:"Tether USD",decimals:6,symbol:"USDT.e ",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:43114,address:"0x50b7545627a5162F82A992c33b87aDc75187B218",name:"Wrapped BTC",decimals:8,symbol:"WBTC.e",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:43114,address:"0x49D5c2BdFfac6CE2BFdB6640F4F80f226bc10bAB",name:"Wrapped Ether",decimals:18,symbol:"WETH.e",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:10,address:"0x4200000000000000000000000000000000000006",name:"WETH",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/f9SbZq39ynUZS5ueKvAwzLmKUfcZvYpKDaysT3dkcvM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vc2NkVzJUWjladmRiX3BVSjZ3b2YzeHRvYk94YUw3bEV5RmhhemhJUFhlMC9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6RXdNamd3TkRaZk1qQXlNakEwTWpJd01UQXpORGc1TURVdWNHNW4ucG5n.webp"},{chainId:10,address:"0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1",name:"DAI",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/04gwZiu2K_9fdb2zLwzsX1nONCbBWrZOvTyOoEFhx3g/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaDJCcmdhUmZxUzBLZDBEOVpZbEUteEtNMVdzeFFtRzBEWVpKOGJCaWN4US9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6SXlNRFUwTVRsZk1qQXlNakEwTWpJd01UQTBNak00TlRVdWFuQm4uanBn.webp"},{chainId:10,address:"0x7F5c764cBc14f9669B88837ca1490cCa17c31607",name:"USDC",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/XbtxsPIscM6p5ClHbLO0JumFHA9U23eON8-MDh-Plkg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaG1nM3hRa1BUTUtkcUNFVnd0LXU4S2lwTW5od1JCdGhLYWxENW9vSWlTZy9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6UXlNRFEyTkRaZk1qQXlNakEwTWpJd01UQTFNekF4TmpVdWNHNW4ucG5n.webp"},{chainId:10,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"ETH",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/bcyoORJ04NyP1HhYUZ9RrTZ-MEOFeNnMcrr__JZ6Ruw/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vV1lHaU9IVFVnVWs4Q3Z3WmNyN0hWX2w4SlNrQjRVQUh1UXpzaWd4U3Nmay9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6VTVPREk0T1Y4eU1ESXlNRFF5TWpBeU1qTTBNelk0TlM1d2JtYy5wbmc.webp"}];function Oh({tokenList:e,popularTokenList:t}){const o=l.useDispatch(),{account:i}=u.useWeb3React(),s=Mh();n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){let n=[];n=r.isArray(e)?e:r.unionBy(t,Fh,(e=>e.address.toLowerCase())),o((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_TOKEN_LIST",payload:e})})))(n))}))})()}),[e,o,t]),n.useEffect((()=>{o(ya({}))}),[i,s]),n.useEffect((()=>{o((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_POPULAR_TOKEN_LIST",payload:e})})))(null!=t?t:[]))}),[t,o])}const Ih=e=>(null!=e?e:Th.getState()).token.tokenList,jh=e=>(null!=e?e:Th.getState()).token.accountBalances,Dh=e=>(null!=e?e:Th.getState()).token.ethBalance,Bh=e=>(null!=e?e:Th.getState()).token.defaultFromToken,Ph=e=>(null!=e?e:Th.getState()).token.defaultToToken,Wh=e=>(null!=e?e:Th.getState()).token.balanceLoadings;function _h(){const{account:e,chainId:t}=u.useWeb3React(),r=l.useSelector(jh),o=l.useSelector(Dh),i=n.useMemo((()=>la[t||1]),[t]),s=n.useCallback((n=>{var s;if(!e||!n)return null;if(i&&n.symbol===i.symbol&&da(n.address,i.address)){const e=o[null!=t?t:1];return!e||(null==e?void 0:e.isNaN())?null:e}if(i&&n.chainId&&n.chainId!==t&&da(n.address,i.address)){const e=o[n.chainId];return!e||(null==e?void 0:e.isNaN())?null:e}const a=null===(s=r[n.address.toLocaleLowerCase()])||void 0===s?void 0:s.tokenBalances;return!a||(null==a?void 0:a.isNaN())?null:a}),[r,o,e]);return s}const Uh=e=>(null!=e?e:Th.getState()).globals,Lh=e=>(null!=e?e:Th.getState()).globals.autoConnectLoading;var Vh=[{constant:!0,inputs:[],name:"getCurrentBlockTimestamp",outputs:[{name:"timestamp",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{components:[{name:"target",type:"address"},{name:"callData",type:"bytes"}],name:"calls",type:"tuple[]"}],name:"aggregate",outputs:[{name:"blockNumber",type:"uint256"},{name:"returnData",type:"bytes[]"}],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!0,inputs:[],name:"getLastBlockHash",outputs:[{name:"blockHash",type:"bytes32"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"addr",type:"address"}],name:"getEthBalance",outputs:[{name:"balance",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[],name:"getCurrentBlockDifficulty",outputs:[{name:"difficulty",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[],name:"getCurrentBlockGasLimit",outputs:[{name:"gaslimit",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[],name:"getCurrentBlockCoinbase",outputs:[{name:"coinbase",type:"address"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"blockNumber",type:"uint256"}],name:"getBlockHash",outputs:[{name:"blockHash",type:"bytes32"}],payable:!1,stateMutability:"view",type:"function"}],Zh={[ia.MAINNET]:{MULTI_CALL:"0xeefba1e63905ef1d7acba5a8513c70307c1ce441",DODO_APPROVE:"0xCB859eA579b28e02B87A1FDE08d087ab9dbE5149",ERC20_HELPER:"0xD9ef2d1583e8Aa196123e773BE38B539a4d149df"},[ia.GOERLI]:{MULTI_CALL:"0x696E25A5e2AEd1C55E6d6Cfa0532Bbda9020165d",DODO_APPROVE:"0xC9143e54021f4a6d33b9b89DBB9F458AaEdd56FB",ERC20_HELPER:"0x24549FC74B3076A962624A26370ed556c467F74C"},[ia.BSC]:{MULTI_CALL:"0x1Ee38d535d541c55C9dae27B12edf090C608E6Fb",DODO_APPROVE:"0xa128Ba44B2738A558A1fdC06d6303d52D3Cef8c1",ERC20_HELPER:"0x566651Ad34f6306872FaC5fB95bbF4C9beE8D8F2"},[ia.POLYGON]:{MULTI_CALL:"0xc9eD9B18e447e600238fe50e944B9062B664DEa4",DODO_APPROVE:"0x292E6b2e054e1157df71C1C9510265CA8C0c7672",ERC20_HELPER:"0xfd24312Ec7871A6D1a31e454D5AbB16c6c25a9b3"},[ia.ARBITRUM_ONE]:{MULTI_CALL:"0xF718F2bd590E5621e53f7b89398e52f7Acced8ca",DODO_APPROVE:"0xA867241cDC8d3b0C07C85cC06F25a0cD3b5474d8",ERC20_HELPER:"0x7C062B9C584fA6eC2504270790D38240A2c5fE72"},[ia.AURORA]:{MULTI_CALL:"0x989DcAA95801C527C5B73AA65d3962dF9aCe1b0C",DODO_APPROVE:"0x335aC99bb3E51BDbF22025f092Ebc1Cf2c5cC619",ERC20_HELPER:"0xE8C9A78725D0451FA19878D5f8A3dC0D55FECF25"},[ia.OKCHAIN]:{MULTI_CALL:"0x5e84190a270333aCe5B9202a3F4ceBf11b81bB01",DODO_APPROVE:"0x7737fd30535c69545deeEa54AB8Dd590ccaEBD3c",ERC20_HELPER:"0x4775b1858f1e417C9609D455C3Ad8751ec01daC4"},[ia.OPTIMISM]:{MULTI_CALL:"0xb98Ac2fEFc8b73aeAE33D02BB00c26E12afCa9Df",DODO_APPROVE:"0xa492d6eABcdc3E204676f15B950bBdD448080364",ERC20_HELPER:"0x42E456ea0dd7538ea103fBb1d0388D14C97bB5b2"},[ia.AVALANCHE]:{MULTI_CALL:"0x97f0153E7F5749640aDF3Ff9CFC518b79D6Fe53b",DODO_APPROVE:"0xCFea63e3DE31De53D68780Dd65675F169439e470",ERC20_HELPER:"0xC3528D128CC227fd60793007b5e3FdF7c2945282"},[ia.CONFLUX]:{MULTI_CALL:"0x696e25a5e2aed1c55e6d6cfa0532bbda9020165d",DODO_APPROVE:"0x5BaF16d57620Cb361F622232F3cb4090e35F3da2",ERC20_HELPER:"0x24549FC74B3076A962624A26370ed556c467F74C"}};const Hh=new ks("abi/5.7.0"),zh={};let Yh={calldata:!0,memory:!0,storage:!0},Gh={calldata:!0,memory:!0};function Xh(e,t){if("bytes"===e||"string"===e){if(Yh[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&Gh[t])return!0;return(Yh[t]||"payable"===t)&&Hh.throwArgumentError("invalid modifier","name",t),!1}function Jh(e,t){for(let r in t)wa(e,r,t[r])}const qh=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),Qh=new RegExp(/^(.*)\[([0-9]*)\]$/);class Kh{constructor(e,t){e!==zh&&Hh.throwError("use fromString",ks.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),Jh(this,t);let r=this.type.match(Qh);Jh(this,r?{arrayLength:parseInt(r[2]||"-1"),arrayChildren:Kh.fromObject({type:r[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}format(e){if(e||(e=qh.sighash),qh[e]||Hh.throwArgumentError("invalid format type","format",e),e===qh.json){let t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((t=>JSON.parse(t.format(e))))),JSON.stringify(t)}let t="";return"array"===this.baseType?(t+=this.arrayChildren.format(e),t+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==qh.sighash&&(t+=this.type),t+="("+this.components.map((t=>t.format(e))).join(e===qh.full?", ":",")+")"):t+=this.type,e!==qh.sighash&&(!0===this.indexed&&(t+=" indexed"),e===qh.full&&this.name&&(t+=" "+this.name)),t}static from(e,t){return"string"==typeof e?Kh.fromString(e,t):Kh.fromObject(e)}static fromObject(e){return Kh.isParamType(e)?e:new Kh(zh,{name:e.name||null,type:uf(e.type),indexed:null==e.indexed?null:!!e.indexed,components:e.components?e.components.map(Kh.fromObject):null})}static fromString(e,t){return r=function(e,t){let r=e;function n(t){Hh.throwArgumentError(`unexpected character at position ${t}`,"param",e)}function o(e){let r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");let i={type:"",name:"",state:{allowType:!0}},s=i;for(let r=0;r<e.length;r++){let i=e[r];switch(i){case"(":s.state.allowType&&""===s.type?s.type="tuple":s.state.allowParams||n(r),s.state.allowType=!1,s.type=uf(s.type),s.components=[o(s)],s=s.components[0];break;case")":delete s.state,"indexed"===s.name&&(t||n(r),s.indexed=!0,s.name=""),Xh(s.type,s.name)&&(s.name=""),s.type=uf(s.type);let e=s;s=s.parent,s||n(r),delete e.parent,s.state.allowParams=!1,s.state.allowName=!0,s.state.allowArray=!0;break;case",":delete s.state,"indexed"===s.name&&(t||n(r),s.indexed=!0,s.name=""),Xh(s.type,s.name)&&(s.name=""),s.type=uf(s.type);let a=o(s.parent);s.parent.components.push(a),delete s.parent,s=a;break;case" ":s.state.allowType&&""!==s.type&&(s.type=uf(s.type),delete s.state.allowType,s.state.allowName=!0,s.state.allowParams=!0),s.state.allowName&&""!==s.name&&("indexed"===s.name?(t||n(r),s.indexed&&n(r),s.indexed=!0,s.name=""):Xh(s.type,s.name)?s.name="":s.state.allowName=!1);break;case"[":s.state.allowArray||n(r),s.type+=i,s.state.allowArray=!1,s.state.allowName=!1,s.state.readArray=!0;break;case"]":s.state.readArray||n(r),s.type+=i,s.state.readArray=!1,s.state.allowArray=!0,s.state.allowName=!0;break;default:s.state.allowType?(s.type+=i,s.state.allowParams=!0,s.state.allowArray=!0):s.state.allowName?(s.name+=i,delete s.state.allowArray):s.state.readArray?s.type+=i:n(r)}}return s.parent&&Hh.throwArgumentError("unexpected eof","param",e),delete i.state,"indexed"===s.name?(t||n(r.length-7),s.indexed&&n(r.length-7),s.indexed=!0,s.name=""):Xh(s.type,s.name)&&(s.name=""),i.type=uf(i.type),i}(e,!!t),Kh.fromObject({name:r.name,type:r.type,indexed:r.indexed,components:r.components});var r}static isParamType(e){return!(null==e||!e._isParamType)}}function $h(e,t){return function(e){e=e.trim();let t=[],r="",n=0;for(let o=0;o<e.length;o++){let i=e[o];","===i&&0===n?(t.push(r),r=""):(r+=i,"("===i?n++:")"===i&&(n--,-1===n&&Hh.throwArgumentError("unbalanced parenthesis","value",e)))}r&&t.push(r);return t}(e).map((e=>Kh.fromString(e,t)))}class ef{constructor(e,t){e!==zh&&Hh.throwError("use a static from method",ks.errors.UNSUPPORTED_OPERATION,{operation:"new Fragment()"}),Jh(this,t),this._isFragment=!0,Object.freeze(this)}static from(e){return ef.isFragment(e)?e:"string"==typeof e?ef.fromString(e):ef.fromObject(e)}static fromObject(e){if(ef.isFragment(e))return e;switch(e.type){case"function":return af.fromObject(e);case"event":return tf.fromObject(e);case"constructor":return sf.fromObject(e);case"error":return cf.fromObject(e);case"fallback":case"receive":return null}return Hh.throwArgumentError("invalid fragment object","value",e)}static fromString(e){return"event"===(e=(e=(e=e.replace(/\s/g," ")).replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," ")).trim()).split(" ")[0]?tf.fromString(e.substring(5).trim()):"function"===e.split(" ")[0]?af.fromString(e.substring(8).trim()):"constructor"===e.split("(")[0].trim()?sf.fromString(e.trim()):"error"===e.split(" ")[0]?cf.fromString(e.substring(5).trim()):Hh.throwArgumentError("unsupported fragment","value",e)}static isFragment(e){return!(!e||!e._isFragment)}}class tf extends ef{format(e){if(e||(e=qh.sighash),qh[e]||Hh.throwArgumentError("invalid format type","format",e),e===qh.json)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==qh.sighash&&(t+="event "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===qh.full?", ":",")+") ",e!==qh.sighash&&this.anonymous&&(t+="anonymous "),t.trim()}static from(e){return"string"==typeof e?tf.fromString(e):tf.fromObject(e)}static fromObject(e){if(tf.isEventFragment(e))return e;"event"!==e.type&&Hh.throwArgumentError("invalid event object","value",e);const t={name:pf(e.name),anonymous:e.anonymous,inputs:e.inputs?e.inputs.map(Kh.fromObject):[],type:"event"};return new tf(zh,t)}static fromString(e){let t=e.match(hf);t||Hh.throwArgumentError("invalid event string","value",e);let r=!1;return t[3].split(" ").forEach((e=>{switch(e.trim()){case"anonymous":r=!0;break;case"":break;default:Hh.warn("unknown modifier: "+e)}})),tf.fromObject({name:t[1].trim(),anonymous:r,inputs:$h(t[2],!0),type:"event"})}static isEventFragment(e){return e&&e._isFragment&&"event"===e.type}}function rf(e,t){t.gas=null;let r=e.split("@");return 1!==r.length?(r.length>2&&Hh.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||Hh.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=y.BigNumber.from(r[1]),r[0]):e}function nf(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((e=>{switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function of(e){let t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&Hh.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&Hh.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||Hh.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&Hh.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&Hh.throwArgumentError("unable to determine stateMutability","value",e),t}class sf extends ef{format(e){if(e||(e=qh.sighash),qh[e]||Hh.throwArgumentError("invalid format type","format",e),e===qh.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});e===qh.sighash&&Hh.throwError("cannot format a constructor for sighash",ks.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});let t="constructor("+this.inputs.map((t=>t.format(e))).join(e===qh.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}static from(e){return"string"==typeof e?sf.fromString(e):sf.fromObject(e)}static fromObject(e){if(sf.isConstructorFragment(e))return e;"constructor"!==e.type&&Hh.throwArgumentError("invalid constructor object","value",e);let t=of(e);t.constant&&Hh.throwArgumentError("constructor cannot be constant","value",e);const r={name:null,type:e.type,inputs:e.inputs?e.inputs.map(Kh.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?y.BigNumber.from(e.gas):null};return new sf(zh,r)}static fromString(e){let t={type:"constructor"},r=(e=rf(e,t)).match(hf);return r&&"constructor"===r[1].trim()||Hh.throwArgumentError("invalid constructor string","value",e),t.inputs=$h(r[2].trim(),!1),nf(r[3].trim(),t),sf.fromObject(t)}static isConstructorFragment(e){return e&&e._isFragment&&"constructor"===e.type}}class af extends sf{format(e){if(e||(e=qh.sighash),qh[e]||Hh.throwArgumentError("invalid format type","format",e),e===qh.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e)))),outputs:this.outputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==qh.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===qh.full?", ":",")+") ",e!==qh.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((t=>t.format(e))).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}static from(e){return"string"==typeof e?af.fromString(e):af.fromObject(e)}static fromObject(e){if(af.isFunctionFragment(e))return e;"function"!==e.type&&Hh.throwArgumentError("invalid function object","value",e);let t=of(e);const r={type:e.type,name:pf(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map(Kh.fromObject):[],outputs:e.outputs?e.outputs.map(Kh.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?y.BigNumber.from(e.gas):null};return new af(zh,r)}static fromString(e){let t={type:"function"},r=(e=rf(e,t)).split(" returns ");r.length>2&&Hh.throwArgumentError("invalid function string","value",e);let n=r[0].match(hf);if(n||Hh.throwArgumentError("invalid function signature","value",e),t.name=n[1].trim(),t.name&&pf(t.name),t.inputs=$h(n[2],!1),nf(n[3].trim(),t),r.length>1){let n=r[1].match(hf);""==n[1].trim()&&""==n[3].trim()||Hh.throwArgumentError("unexpected tokens","value",e),t.outputs=$h(n[2],!1)}else t.outputs=[];return af.fromObject(t)}static isFunctionFragment(e){return e&&e._isFragment&&"function"===e.type}}function lf(e){const t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||Hh.throwArgumentError(`cannot specify user defined ${t} error`,"fragment",e),e}class cf extends ef{format(e){if(e||(e=qh.sighash),qh[e]||Hh.throwArgumentError("invalid format type","format",e),e===qh.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==qh.sighash&&(t+="error "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===qh.full?", ":",")+") ",t.trim()}static from(e){return"string"==typeof e?cf.fromString(e):cf.fromObject(e)}static fromObject(e){if(cf.isErrorFragment(e))return e;"error"!==e.type&&Hh.throwArgumentError("invalid error object","value",e);const t={type:e.type,name:pf(e.name),inputs:e.inputs?e.inputs.map(Kh.fromObject):[]};return lf(new cf(zh,t))}static fromString(e){let t={type:"error"},r=e.match(hf);return r||Hh.throwArgumentError("invalid error signature","value",e),t.name=r[1].trim(),t.name&&pf(t.name),t.inputs=$h(r[2],!1),lf(cf.fromObject(t))}static isErrorFragment(e){return e&&e._isFragment&&"error"===e.type}}function uf(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}const df=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function pf(e){return e&&e.match(df)||Hh.throwArgumentError(`invalid identifier "${e}"`,"value",e),e}const hf=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");const ff=new ks("abi/5.7.0");class mf{constructor(e,t,r,n){this.name=e,this.type=t,this.localName=r,this.dynamic=n}_throwError(e,t){ff.throwArgumentError(e,this.localName,t)}}class gf{constructor(e){wa(this,"wordSize",e||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(e)}get data(){return _s(this._data)}get length(){return this._dataLength}_writeData(e){return this._data.push(e),this._dataLength+=e.length,e.length}appendWriter(e){return this._writeData(Is(e._data))}writeBytes(e){let t=Os(e);const r=t.length%this.wordSize;return r&&(t=Is([t,this._padding.slice(r)])),this._writeData(t)}_getValue(e){let t=Os(y.BigNumber.from(e));return t.length>this.wordSize&&ff.throwError("value out-of-bounds",ks.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=Is([this._padding.slice(t.length%this.wordSize),t])),t}writeValue(e){return this._writeData(this._getValue(e))}writeUpdatableValue(){const e=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,t=>{this._data[e]=this._getValue(t)}}}class yf{constructor(e,t,r,n){wa(this,"_data",Os(e)),wa(this,"wordSize",t||32),wa(this,"_coerceFunc",r),wa(this,"allowLoose",n),this._offset=0}get data(){return Bs(this._data)}get consumed(){return this._offset}static coerce(e,t){let r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}coerce(e,t){return this._coerceFunc?this._coerceFunc(e,t):yf.coerce(e,t)}_peekBytes(e,t,r){let n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:ff.throwError("data out-of-bounds",ks.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}subReader(e){return new yf(this._data.slice(this._offset+e),this.wordSize,this._coerceFunc,this.allowLoose)}readBytes(e,t){let r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}readValue(){return y.BigNumber.from(this.readBytes(this.wordSize))}}class bf extends mf{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,t){try{t=oa(t)}catch(e){this._throwError(e.message,t)}return e.writeValue(t)}decode(e){return oa(Ls(e.readValue().toHexString(),20))}}class xf extends mf{constructor(e){super(e.name,e.type,void 0,e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,t){return this.coder.encode(e,t)}decode(e){return this.coder.decode(e)}}const vf=new ks("abi/5.7.0");function wf(e,t,r){let n=null;if(Array.isArray(r))n=r;else if(r&&"object"==typeof r){let e={};n=t.map((t=>{const n=t.localName;return n||vf.throwError("cannot encode object for signature with missing names",ks.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]&&vf.throwError("cannot encode object for signature with duplicate names",ks.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]=!0,r[n]}))}else vf.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&vf.throwArgumentError("types/value length mismatch","tuple",r);let o=new gf(e.wordSize),i=new gf(e.wordSize),s=[];t.forEach(((e,t)=>{let r=n[t];if(e.dynamic){let t=i.length;e.encode(i,r);let n=o.writeUpdatableValue();s.push((e=>{n(e+t)}))}else e.encode(o,r)})),s.forEach((e=>{e(o.length)}));let a=e.appendWriter(o);return a+=e.appendWriter(i),a}function Ef(e,t){let r=[],n=e.subReader(0);t.forEach((t=>{let o=null;if(t.dynamic){let r=e.readValue(),i=n.subReader(r.toNumber());try{o=t.decode(i)}catch(e){if(e.code===ks.errors.BUFFER_OVERRUN)throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}}else try{o=t.decode(e)}catch(e){if(e.code===ks.errors.BUFFER_OVERRUN)throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}null!=o&&r.push(o)}));const o=t.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach(((e,t)=>{let n=e.localName;if(!n||1!==o[n])return;if("length"===n&&(n="_length"),null!=r[n])return;const i=r[t];i instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:()=>{throw i}}):r[n]=i}));for(let e=0;e<r.length;e++){const t=r[e];t instanceof Error&&Object.defineProperty(r,e,{enumerable:!0,get:()=>{throw t}})}return Object.freeze(r)}class Af extends mf{constructor(e,t,r){super("array",e.type+"["+(t>=0?t:"")+"]",r,-1===t||e.dynamic),this.coder=e,this.length=t}defaultValue(){const e=this.coder.defaultValue(),t=[];for(let r=0;r<this.length;r++)t.push(e);return t}encode(e,t){Array.isArray(t)||this._throwError("expected array value",t);let r=this.length;-1===r&&(r=t.length,e.writeValue(t.length)),vf.checkArgumentCount(t.length,r,"coder array"+(this.localName?" "+this.localName:""));let n=[];for(let e=0;e<t.length;e++)n.push(this.coder);return wf(e,n,t)}decode(e){let t=this.length;-1===t&&(t=e.readValue().toNumber(),32*t>e._data.length&&vf.throwError("insufficient data length",ks.errors.BUFFER_OVERRUN,{length:e._data.length,count:t}));let r=[];for(let e=0;e<t;e++)r.push(new xf(this.coder));return e.coerce(this.name,Ef(e,r))}}class Cf extends mf{constructor(e){super("bool","bool",e,!1)}defaultValue(){return!1}encode(e,t){return e.writeValue(t?1:0)}decode(e){return e.coerce(this.type,!e.readValue().isZero())}}class kf extends mf{constructor(e,t){super(e,e,t,!0)}defaultValue(){return"0x"}encode(e,t){t=Os(t);let r=e.writeValue(t.length);return r+=e.writeBytes(t),r}decode(e){return e.readBytes(e.readValue().toNumber(),!0)}}class Rf extends kf{constructor(e){super("bytes",e)}decode(e){return e.coerce(this.name,Bs(super.decode(e)))}}class Tf extends mf{constructor(e,t){let r="bytes"+String(e);super(r,r,t,!1),this.size=e}defaultValue(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+2*this.size)}encode(e,t){let r=Os(t);return r.length!==this.size&&this._throwError("incorrect data length",t),e.writeBytes(r)}decode(e){return e.coerce(this.name,Bs(e.readBytes(this.size)))}}class Sf extends mf{constructor(e){super("null","",e,!1)}defaultValue(){return null}encode(e,t){return null!=t&&this._throwError("not null",t),e.writeBytes([])}decode(e){return e.readBytes(0),e.coerce(this.name,null)}}class Nf extends mf{constructor(e,t,r){const n=(t?"int":"uint")+8*e;super(n,n,r,!1),this.size=e,this.signed=t}defaultValue(){return 0}encode(e,t){let r=y.BigNumber.from(t),n=Ja.mask(8*e.wordSize);if(this.signed){let e=n.mask(8*this.size-1);(r.gt(e)||r.lt(e.add(Xa).mul(Ya)))&&this._throwError("value out-of-bounds",t)}else(r.lt(Ga)||r.gt(n.mask(8*this.size)))&&this._throwError("value out-of-bounds",t);return r=r.toTwos(8*this.size).mask(8*this.size),this.signed&&(r=r.fromTwos(8*this.size).toTwos(8*e.wordSize)),e.writeValue(r)}decode(e){let t=e.readValue().mask(8*this.size);return this.signed&&(t=t.fromTwos(8*this.size)),e.coerce(this.name,t)}}class Mf extends kf{constructor(e){super("string",e)}defaultValue(){return""}encode(e,t){return super.encode(e,rl(t))}decode(e){return nl(super.decode(e))}}class Ff extends mf{constructor(e,t){let r=!1;const n=[];e.forEach((e=>{e.dynamic&&(r=!0),n.push(e.type)}));super("tuple","tuple("+n.join(",")+")",t,r),this.coders=e}defaultValue(){const e=[];this.coders.forEach((t=>{e.push(t.defaultValue())}));const t=this.coders.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach(((r,n)=>{let o=r.localName;o&&1===t[o]&&("length"===o&&(o="_length"),null==e[o]&&(e[o]=e[n]))})),Object.freeze(e)}encode(e,t){return wf(e,this.coders,t)}decode(e){return e.coerce(this.name,Ef(e,this.coders))}}const Of=new ks("abi/5.7.0"),If=new RegExp(/^bytes([0-9]*)$/),jf=new RegExp(/^(u?int)([0-9]*)$/);const Df=new class{constructor(e){wa(this,"coerceFunc",e||null)}_getCoder(e){switch(e.baseType){case"address":return new bf(e.name);case"bool":return new Cf(e.name);case"string":return new Mf(e.name);case"bytes":return new Rf(e.name);case"array":return new Af(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new Ff((e.components||[]).map((e=>this._getCoder(e))),e.name);case"":return new Sf(e.name)}let t=e.type.match(jf);if(t){let r=parseInt(t[2]||"256");return(0===r||r>256||r%8!=0)&&Of.throwArgumentError("invalid "+t[1]+" bit length","param",e),new Nf(r/8,"int"===t[1],e.name)}if(t=e.type.match(If),t){let r=parseInt(t[1]);return(0===r||r>32)&&Of.throwArgumentError("invalid bytes length","param",e),new Tf(r,e.name)}return Of.throwArgumentError("invalid type","type",e.type)}_getWordSize(){return 32}_getReader(e,t){return new yf(e,this._getWordSize(),this.coerceFunc,t)}_getWriter(){return new gf(this._getWordSize())}getDefaultValue(e){const t=e.map((e=>this._getCoder(Kh.from(e))));return new Ff(t,"_").defaultValue()}encode(e,t){e.length!==t.length&&Of.throwError("types/values length mismatch",ks.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});const r=e.map((e=>this._getCoder(Kh.from(e)))),n=new Ff(r,"_"),o=this._getWriter();return n.encode(o,t),o.data}decode(e,t,r){const n=e.map((e=>this._getCoder(Kh.from(e))));return new Ff(n,"_").decode(this._getReader(Os(t),r))}},Bf=new ks("abi/5.7.0");class Pf extends Na{}class Wf extends Na{}class _f extends Na{}class Uf extends Na{static isIndexed(e){return!(!e||!e._isIndexed)}}const Lf={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function Vf(e,t){const r=new Error(`deferred error during ABI decoding triggered accessing ${e}`);return r.error=t,r}class Zf{constructor(e){let t=[];t="string"==typeof e?JSON.parse(e):e,wa(this,"fragments",t.map((e=>ef.from(e))).filter((e=>null!=e))),wa(this,"_abiCoder",Ea(new.target,"getAbiCoder")()),wa(this,"functions",{}),wa(this,"errors",{}),wa(this,"events",{}),wa(this,"structs",{}),this.fragments.forEach((e=>{let t=null;switch(e.type){case"constructor":return this.deploy?void Bf.warn("duplicate definition - constructor"):void wa(this,"deploy",e);case"function":t=this.functions;break;case"event":t=this.events;break;case"error":t=this.errors;break;default:return}let r=e.format();t[r]?Bf.warn("duplicate definition - "+r):t[r]=e})),this.deploy||wa(this,"deploy",sf.from({payable:!1,type:"constructor"})),wa(this,"_isInterface",!0)}format(e){e||(e=qh.full),e===qh.sighash&&Bf.throwArgumentError("interface does not support formatting sighash","format",e);const t=this.fragments.map((t=>t.format(e)));return e===qh.json?JSON.stringify(t.map((e=>JSON.parse(e)))):t}static getAbiCoder(){return Df}static getAddress(e){return oa(e)}static getSighash(e){return Ws(ol(e.format()),0,4)}static getEventTopic(e){return ol(e.format())}getFunction(e){if(Ds(e)){for(const t in this.functions)if(e===this.getSighash(t))return this.functions[t];Bf.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.functions).filter((e=>e.split("(")[0]===t));return 0===r.length?Bf.throwArgumentError("no matching function","name",t):r.length>1&&Bf.throwArgumentError("multiple matching functions","name",t),this.functions[r[0]]}const t=this.functions[af.fromString(e).format()];return t||Bf.throwArgumentError("no matching function","signature",e),t}getEvent(e){if(Ds(e)){const t=e.toLowerCase();for(const e in this.events)if(t===this.getEventTopic(e))return this.events[e];Bf.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.events).filter((e=>e.split("(")[0]===t));return 0===r.length?Bf.throwArgumentError("no matching event","name",t):r.length>1&&Bf.throwArgumentError("multiple matching events","name",t),this.events[r[0]]}const t=this.events[tf.fromString(e).format()];return t||Bf.throwArgumentError("no matching event","signature",e),t}getError(e){if(Ds(e)){const t=Ea(this.constructor,"getSighash");for(const r in this.errors){if(e===t(this.errors[r]))return this.errors[r]}Bf.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.errors).filter((e=>e.split("(")[0]===t));return 0===r.length?Bf.throwArgumentError("no matching error","name",t):r.length>1&&Bf.throwArgumentError("multiple matching errors","name",t),this.errors[r[0]]}const t=this.errors[af.fromString(e).format()];return t||Bf.throwArgumentError("no matching error","signature",e),t}getSighash(e){if("string"==typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(e){throw t}}return Ea(this.constructor,"getSighash")(e)}getEventTopic(e){return"string"==typeof e&&(e=this.getEvent(e)),Ea(this.constructor,"getEventTopic")(e)}_decodeParams(e,t){return this._abiCoder.decode(e,t)}_encodeParams(e,t){return this._abiCoder.encode(e,t)}encodeDeploy(e){return this._encodeParams(this.deploy.inputs,e||[])}decodeErrorResult(e,t){"string"==typeof e&&(e=this.getError(e));const r=Os(t);return Bs(r.slice(0,4))!==this.getSighash(e)&&Bf.throwArgumentError(`data signature does not match error ${e.name}.`,"data",Bs(r)),this._decodeParams(e.inputs,r.slice(4))}encodeErrorResult(e,t){return"string"==typeof e&&(e=this.getError(e)),Bs(Is([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionData(e,t){"string"==typeof e&&(e=this.getFunction(e));const r=Os(t);return Bs(r.slice(0,4))!==this.getSighash(e)&&Bf.throwArgumentError(`data signature does not match function ${e.name}.`,"data",Bs(r)),this._decodeParams(e.inputs,r.slice(4))}encodeFunctionData(e,t){return"string"==typeof e&&(e=this.getFunction(e)),Bs(Is([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionResult(e,t){"string"==typeof e&&(e=this.getFunction(e));let r=Os(t),n=null,o="",i=null,s=null,a=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(e){}break;case 4:{const e=Bs(r.slice(0,4)),t=Lf[e];if(t)i=this._abiCoder.decode(t.inputs,r.slice(4)),s=t.name,a=t.signature,t.reason&&(n=i[0]),"Error"===s?o=`; VM Exception while processing transaction: reverted with reason string ${JSON.stringify(i[0])}`:"Panic"===s&&(o=`; VM Exception while processing transaction: reverted with panic code ${i[0]}`);else try{const t=this.getError(e);i=this._abiCoder.decode(t.inputs,r.slice(4)),s=t.name,a=t.format()}catch(e){}break}}return Bf.throwError("call revert exception"+o,ks.errors.CALL_EXCEPTION,{method:e.format(),data:Bs(t),errorArgs:i,errorName:s,errorSignature:a,reason:n})}encodeFunctionResult(e,t){return"string"==typeof e&&(e=this.getFunction(e)),Bs(this._abiCoder.encode(e.outputs,t||[]))}encodeFilterTopics(e,t){"string"==typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&Bf.throwError("too many arguments for "+e.format(),ks.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});let r=[];e.anonymous||r.push(this.getEventTopic(e));const n=(e,t)=>"string"===e.type?ol(t):"bytes"===e.type?zs(Bs(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=y.BigNumber.from(t).toHexString()),"address"===e.type&&this._abiCoder.encode(["address"],[t]),Ls(Bs(t),32));for(t.forEach(((t,o)=>{let i=e.inputs[o];i.indexed?null==t?r.push(null):"array"===i.baseType||"tuple"===i.baseType?Bf.throwArgumentError("filtering with tuples or arrays not supported","contract."+i.name,t):Array.isArray(t)?r.push(t.map((e=>n(i,e)))):r.push(n(i,t)):null!=t&&Bf.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+i.name,t)}));r.length&&null===r[r.length-1];)r.pop();return r}encodeEventLog(e,t){"string"==typeof e&&(e=this.getEvent(e));const r=[],n=[],o=[];return e.anonymous||r.push(this.getEventTopic(e)),t.length!==e.inputs.length&&Bf.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach(((e,i)=>{const s=t[i];if(e.indexed)if("string"===e.type)r.push(ol(s));else if("bytes"===e.type)r.push(zs(s));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");r.push(this._abiCoder.encode([e.type],[s]))}else n.push(e),o.push(s)})),{data:this._abiCoder.encode(n,o),topics:r}}decodeEventLog(e,t,r){if("string"==typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){let t=this.getEventTopic(e);Ds(r[0],32)&&r[0].toLowerCase()===t||Bf.throwError("fragment/topic mismatch",ks.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:t,value:r[0]}),r=r.slice(1)}let n=[],o=[],i=[];e.inputs.forEach(((e,t)=>{e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(n.push(Kh.fromObject({type:"bytes32",name:e.name})),i.push(!0)):(n.push(e),i.push(!1)):(o.push(e),i.push(!1))}));let s=null!=r?this._abiCoder.decode(n,Is(r)):null,a=this._abiCoder.decode(o,t,!0),l=[],c=0,u=0;e.inputs.forEach(((e,t)=>{if(e.indexed)if(null==s)l[t]=new Uf({_isIndexed:!0,hash:null});else if(i[t])l[t]=new Uf({_isIndexed:!0,hash:s[u++]});else try{l[t]=s[u++]}catch(e){l[t]=e}else try{l[t]=a[c++]}catch(e){l[t]=e}if(e.name&&null==l[e.name]){const r=l[t];r instanceof Error?Object.defineProperty(l,e.name,{enumerable:!0,get:()=>{throw Vf(`property ${JSON.stringify(e.name)}`,r)}}):l[e.name]=r}}));for(let e=0;e<l.length;e++){const t=l[e];t instanceof Error&&Object.defineProperty(l,e,{enumerable:!0,get:()=>{throw Vf(`index ${e}`,t)}})}return Object.freeze(l)}parseTransaction(e){let t=this.getFunction(e.data.substring(0,10).toLowerCase());return t?new Wf({args:this._abiCoder.decode(t.inputs,"0x"+e.data.substring(10)),functionFragment:t,name:t.name,signature:t.format(),sighash:this.getSighash(t),value:y.BigNumber.from(e.value||"0")}):null}parseLog(e){let t=this.getEvent(e.topics[0]);return!t||t.anonymous?null:new Pf({eventFragment:t,name:t.name,signature:t.format(),topic:this.getEventTopic(t),args:this.decodeEventLog(t,e.data,e.topics)})}parseError(e){const t=Bs(e);let r=this.getError(t.substring(0,10).toLowerCase());return r?new _f({args:this._abiCoder.decode(r.inputs,"0x"+t.substring(10)),errorFragment:r,name:r.name,signature:r.format(),sighash:this.getSighash(r)}):null}static isInterface(e){return!(!e||!e._isInterface)}}function Hf(e,t,...r){return ma(this,void 0,void 0,(function*(){const n=[];for(const e of r)for(const t of e)t.callData&&n.push(t.callData);const o=yield function(e,t,r){return ma(this,void 0,void 0,(function*(){const n=yield zf(e,t,r),o=new Map;for(const{req:e,resp:t}of n)o.set(e,t);return e.map((e=>({req:e,resp:o.get(e)})))}))}(n,e,t),i=new Map;for(const{req:e,resp:t}of o)i.set(e,null==t?void 0:t.result);return r.map((e=>e.filter((e=>!e.callData||i.get(e.callData))).map(((e,t)=>e.processor(e.callData?i.get(e.callData):null,t)))))}))}function zf(e,t,n){return ma(this,void 0,void 0,(function*(){let o=[e];e.length>800&&(o=r.chunk(e,800));let i=[];const s=o.map((e=>ma(this,void 0,void 0,(function*(){const r=e.map((e=>[e.to,e.data])),o={data:t.interface.encodeFunctionData("aggregate",[r]),to:n};let s;try{s=yield t.provider.call(o)}catch(r){const o=e.length;if(o>20){const r=Math.floor(o/2),[s,a]=yield Promise.all([zf(e.slice(0,r),t,n),zf(e.slice(r,o),t,n)]);i=[...i,...s,...a]}else{const e="[sendCallReqs] error";console.error(e,r)}}if(void 0===s)throw new Error("Unexpected batch result");const[a,l]=Df.decode(["uint256","bytes[]"],s);if(e.length!==l.length)throw new Error("Unexpected length mismatch");return l.map(((t,r)=>({resp:{result:t},req:e[r]})))}))));return(yield Promise.allSettled(s)).filter((e=>"fulfilled"===e.status)).forEach((({value:e})=>{i=[...i,...e]})),i}))}function Yf(e,t,r,n){if(!function(e){try{return oa(e)}catch(e){return!1}}(e)||e===za)throw Error(`Invalid 'address' parameter '${e}'.`);return new b.Contract(e,t,function(e,t){return t?function(e,t){return e.getSigner(t).connectUnchecked()}(e,t):e}(r,n))}function Gf(e){const{provider:t,account:r,chainId:o}=u.useWeb3React(),[i,s]=n.useState(!1),a=n.useMemo((()=>Zh[null!=e?e:o]),[o,e]),c=l.useSelector(Uh).jsonRpcUrlMap,d=n.useCallback(((n,i)=>{if(e&&e!==o){const t=Object.assign(Object.assign({},sa),c)[e],r=new nh(null==t?void 0:t[0]);return new b.Contract(n,i,r)}if(t)return Yf(n,i,t,r)}),[t,r,e,c]),p=n.useCallback((e=>{if(!a)return;const{MULTI_CALL:t}=a,r=d(t,Vh);return(()=>ma(this,void 0,void 0,(function*(){if(r){s(!0);try{const[n]=yield Hf(r,t,e);return n}catch(e){console.error("Contract: useMultiContract is error",e)}s(!1)}})))()}),[a,d]);return{getContract:d,contractConfig:a,call:p,loading:i}}var Xf=[{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"user",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"isERC20",outputs:[{internalType:"bool",name:"isOk",type:"bool"},{internalType:"string",name:"symbol",type:"string"},{internalType:"string",name:"name",type:"string"},{internalType:"uint256",name:"decimals",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"allownance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"user",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"judgeERC20",outputs:[{internalType:"string",name:"symbol",type:"string"},{internalType:"string",name:"name",type:"string"},{internalType:"uint256",name:"decimals",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"allownance",type:"uint256"}],stateMutability:"view",type:"function"}];function Jf({tokenList:e,addresses:t,blockNumber:r,chainId:o,skip:i}){const{account:s}=u.useWeb3React(),a=l.useDispatch(),c=n.useMemo((()=>[...(null==e?void 0:e.map((e=>e.address)))||[],...t||[]].map((e=>e.toLocaleLowerCase()))),[e,JSON.stringify(t)]),{getContract:d,contractConfig:p,call:h}=Gf(o),[f,m]=n.useState(),g=n.useMemo((()=>{if(!s||!c.length||!p)return;const{DODO_APPROVE:e,ERC20_HELPER:t}=p,r=d(t,Xf);if(!r)return;return c.map((n=>({callData:{data:r.interface.encodeFunctionData("isERC20",[n,s,e]),to:t},processor:e=>{const t=new Zf(Xf).decodeFunctionResult("isERC20",e),{balance:r,isOk:o}=t,i=parseInt(t.decimals),s=new k.default(10).pow(i),a=new k.default(t.allownance.toString()).div(s);return o?{address:n,decimals:i,symbol:t.symbol,name:t.name,balance:new k.default(r.toString()).div(s),allowance:a}:{address:n,balance:new k.default(0),allowance:new k.default(0)}}})))}),[s,d,JSON.stringify(c)]);return n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){if(!g||i)return;let e={};c.forEach((t=>{e[t]=!0})),a(ba(e));const t=yield h(g),r={};t&&(t.forEach((e=>{e.address.toLocaleLowerCase()!=="0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE".toLocaleLowerCase()&&(r[e.address.toLocaleLowerCase()]={tokenBalances:e.balance,tokenAllowances:e.allowance})})),a(ya(r))),m(t),c.forEach((t=>{e[t]=!1})),a(ba(e))}))})()}),[g,r,i]),{data:f}}function qf(e){const{provider:t,account:r,chainId:o}=u.useWeb3React(),i=l.useDispatch(),s=l.useSelector(Nh),a=l.useSelector(Uh).jsonRpcUrlMap;n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){if(t&&r)if(e&&e!==o){const t=Object.assign(Object.assign({},sa),a)[e],n=new nh(null==t?void 0:t[0]),o=yield n.getBalance(r);o&&i(ga(e,new k.default(o.toString()).div(1e18)))}else{const e=yield t.getBalance(r);i(ga(null!=o?o:1,new k.default(e.toString()).div(1e18)))}}))})()}),[t,r,i,s,e])}function Qf(){const{provider:e,chainId:t}=u.useWeb3React(),r=l.useDispatch(),o=n.useCallback((()=>ma(this,void 0,void 0,(function*(){if(!e||!t)return;const n=yield e.getBlockNumber();r((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_BLOCK_NUMBER",payload:e})})))(n))}))),[e,t]);return{updateBlockNumber:o}}var Kf,$f=[{constant:!0,inputs:[],name:"totalSupply",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{name:"_to",type:"address"},{name:"_value",type:"uint256"}],name:"transfer",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!1,inputs:[{name:"guy",type:"address"},{name:"wad",type:"uint256"}],name:"approve",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!0,inputs:[],name:"symbol",outputs:[{name:"",type:"string"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"_owner",type:"address"}],name:"balanceOf",outputs:[{name:"balance",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"_owner",type:"address"},{name:"_spender",type:"address"}],name:"allowance",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"}];function em(e,t,r,n=0){if(r&&(e=e.toLocaleLowerCase(),t=t.toLocaleLowerCase()),e===t)return Kf.fully+n;const o=e.indexOf(t);return 0===o?Kf.prefix+n:o>0?Kf.other+n:Kf.none}!function(e){e[e.fully=1]="fully",e[e.prefix=2]="prefix",e[e.other=3]="other",e[e.none=0]="none"}(Kf||(Kf={}));function tm({value:e,onChange:t,occupiedAddrs:r,hiddenAddrs:o,showAddrs:i,side:s,chainId:a,visible:c,defaultLoadBalance:u}){const[d,p]=n.useState(""),h=l.useSelector(Ih),f=Mh(),m=n.useMemo((()=>null!=a?a:f),[a,f]),g=_h(),y=n.useMemo((()=>{const e=h.filter((e=>e.chainId===m));return e}),[h,m]),b=l.useSelector((e=>((e,t)=>(null!=t?t:Th.getState()).token.popularTokenList.filter((({chainId:t})=>e===t)))(m,e))),x=n.useMemo((()=>(null==Fh?void 0:Fh.filter((e=>e.chainId===m)))||[]),[Fh,m]),v=n.useMemo((()=>new Set(o?o.map((e=>e.toLowerCase())):void 0)),[o]),w=n.useMemo((()=>i?new Set(i.map((e=>e.toLowerCase()))):void 0),[i]),E=n.useCallback((e=>e.filter((e=>{if(e.chainId!==m)return!1;let t=!0;return t=w?w.has(e.address.toLowerCase()):!v.has(e.address.toLowerCase()),t&&s&&(t=!e.side||e.side===s),t}))),[w,m,v]),A=n.useMemo((()=>E(b)),[b,E]),C=n.useCallback((t=>{if(null===t)return null;const n=[];d?t.forEach((e=>{const t=((e,t,{matchAddress:r}={})=>{if(!t)return 0;const n=t.toLocaleLowerCase();let o=0;r&&e.address.toLocaleLowerCase()===n&&(o=1),o||(o=em(e.symbol.toLocaleLowerCase(),n,!1,1));if(o)e.name.toLocaleLowerCase()===n&&(o=Kf.fully+1);else{let t=em(e.name.toLocaleLowerCase(),n,!1,10);t=t===Kf.fully+10?Kf.fully+1:t,o=t}return o})(e,d,{matchAddress:!0});t&&n.push({sort:t,token:e})})):t.forEach((e=>{n.push({sort:0,token:e})}));const o=[];return n.sort(((t,n)=>{const o=t.token,i=n.token;if(e){if(o.address===e.address)return-1;if(i.address===e.address)return 1}if(null==r?void 0:r.includes(o.address))return-1;if(null==r?void 0:r.includes(i.address))return 1;const s=g&&g(o)||new k.default(0),a=g&&g(i)||new k.default(0),l=A.map((e=>e.address));if(null==l?void 0:l.includes(o.address))return-1;if(null==l?void 0:l.includes(i.address))return 1;if(!s.eq(a))return s.gt(a)?-1:1;if(t.sort!==n.sort)return t.sort>n.sort?1:-1;const c=x.map((e=>e.address));return(null==c?void 0:c.includes(o.address))?-1:(null==c?void 0:c.includes(i.address))?1:o.symbol.localeCompare(i.symbol)})).some((e=>!!(d&&o.length>21)||(o.push(e.token),!1))),o}),[d,g,r,e,A,x]),R=n.useCallback((e=>{const n=e.address.toLowerCase();t(e,!!(null==r?void 0:r.some((e=>e.toLowerCase()===n))))}),[t,r]),T=n.useMemo((()=>{const e=E(y),t=new Set;return e.forEach((e=>{t.add(e.address)})),A.forEach((r=>{t.has(r.address)||e.push(r)})),C(e)||[]}),[y,E,C,A]);return function({chainId:e,value:t,tokenList:r,popularTokenList:o,visible:i,defaultLoadBalance:s}){const a=l.useSelector(Lh),c=l.useSelector(Nh),u=n.useMemo((()=>{if(void 0===a||a)return[];const t=new Set;return r.forEach((r=>{r.chainId===e&&t.add(r.address)})),null==o||o.forEach((r=>{r.chainId===e&&t.add(r.address)})),Array.from(t)}),[r,o,e,a]),d=n.useMemo((()=>t?[t.address]:[]),[t]),p=n.useMemo((()=>{var r;return null!==(r=null==t?void 0:t.chainId)&&void 0!==r?r:e}),[null==t?void 0:t.chainId,e]);Jf({addresses:u,chainId:e,skip:!1===i&&!s}),qf(e),Jf({addresses:d,chainId:p,blockNumber:c})}({chainId:m,tokenList:T,popularTokenList:A,value:e,visible:c,defaultLoadBalance:u}),{filter:d,setFilter:p,showTokenList:T,onSelectToken:R,popularTokenList:A}}var rm,nm;function om(){return om=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},om.apply(this,arguments)}var im,sm,am,lm,cm,um=function(e){return T.createElement("svg",om({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),rm||(rm=T.createElement("g",{clipPath:"url(#clip0_5431_179637)"},T.createElement("path",{d:"M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z",fill:"#F2F4F7"}),T.createElement("path",{d:"M12.3735 3V9.6525L17.9963 12.165L12.3735 3Z",fill:"#343434"}),T.createElement("path",{d:"M12.3735 3L6.75 12.165L12.3735 9.6525V3Z",fill:"#8C8C8C"}),T.createElement("path",{d:"M12.3735 16.4759V20.9962L18 13.2119L12.3735 16.4759Z",fill:"#3C3C3B"}),T.createElement("path",{d:"M12.3735 20.9962V16.4752L6.75 13.2119L12.3735 20.9962Z",fill:"#8C8C8C"}),T.createElement("path",{d:"M12.3735 15.4298L17.9963 12.1651L12.3735 9.65405V15.4298Z",fill:"#141414"}),T.createElement("path",{d:"M6.75 12.1651L12.3735 15.4298V9.65405L6.75 12.1651Z",fill:"#393939"}))),nm||(nm=T.createElement("defs",null,T.createElement("clipPath",{id:"clip0_5431_179637"},T.createElement("rect",{width:24,height:24,fill:"white"})))))};function dm(){return dm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},dm.apply(this,arguments)}var pm,hm;function fm(){return fm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},fm.apply(this,arguments)}var mm,gm,ym;function bm(){return bm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},bm.apply(this,arguments)}var xm,vm;function wm(){return wm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},wm.apply(this,arguments)}var Em,Am;function Cm(){return Cm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Cm.apply(this,arguments)}var km;function Rm(){return Rm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Rm.apply(this,arguments)}var Tm,Sm;function Nm(){return Nm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Nm.apply(this,arguments)}var Mm;function Fm(){return Fm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Fm.apply(this,arguments)}const Om={[ia.MAINNET]:{chainId:ia.MAINNET,logo:um,name:"Ethereum"},[ia.GOERLI]:{chainId:ia.GOERLI,logo:um,name:"Goerli",mainnet:ia.MAINNET},[ia.ARBITRUM_ONE]:{chainId:ia.ARBITRUM_ONE,logo:function(e){return T.createElement("svg",dm({height:"692pt",viewBox:"0 0 619 692",width:"619pt",xmlns:"http://www.w3.org/2000/svg"},e),im||(im=T.createElement("path",{d:"m280.46 17.3c18.85-10.03 43.1-9.37 61.23 1.99 78.77 45.29 157.52 90.59 236.28 135.88 17.98 10.27 30.16 30.12 30.76 50.87v275.89c.49 19.03-8.56 38.11-23.76 49.6-83.95 48.66-167.91 97.29-251.9 145.88-14.93 5.88-32.32 5.81-47.05-.66-10.1-5.39-19.93-11.25-29.88-16.91-25.72-14.85-51.49-29.62-77.2-44.49 7.13-11.82 13.88-23.88 21.17-35.61 34.11 19.55 68.15 39.21 102.24 58.77 5.43 2.44 12.28 2.51 17.36-.81 28.11-16.31 56.23-32.61 84.36-48.89 28.58-16.52 57.15-33.07 85.69-49.67 7.92-4.6 15.84-9.2 23.78-13.77 14.97-8.59 29.86-17.33 44.83-25.93 5.77-3.22 8.74-10.05 8.75-16.47-.04-14.36.09-28.73-.07-43.09.18-76.95.01-153.9.09-230.85.24-7.26-3.78-14.44-10.07-18.06-79.37-45.64-158.72-91.3-238.08-136.94-6.26-3.47-14.38-3.15-20.42.66-78.73 45.56-157.48 91.1-236.15 136.78-6.59 3.53-10.68 11.06-10.31 18.5.21 73.45.1 146.9.48 220.34-12.68 20.02-25.84 39.75-38.67 59.68-.95 1.49-1.95 2.96-3.1 4.31-.23-95.74-.02-191.5-.1-287.25.31-22.52 14.44-43.97 34.72-53.61 78.35-45.36 156.61-90.87 235.02-136.14z",fill:"#8cbfdf"})),sm||(sm=T.createElement("path",{d:"m298.57 54.69c6.04-3.81 14.16-4.13 20.42-.66 79.36 45.64 158.71 91.3 238.08 136.94 6.29 3.62 10.31 10.8 10.07 18.06-.08 76.95.09 153.9-.09 230.85-6.25-8.84-11.77-18.21-17.74-27.25-38.11-59.38-76.26-118.73-114.34-178.12l-.71.13c-16.14 27.89-32.81 55.48-48.94 83.38 42.77 69.1 85.49 138.23 128.22 207.35-7.94 4.57-15.86 9.17-23.78 13.77-40.35-63.61-80.71-127.22-121.07-190.83l-.73-.41c-19.01 31.61-37.43 63.61-56.36 95.28 4.29 7.87 9.61 15.25 14.3 22.94 26.05 40.9 52.13 81.79 78.17 122.69-28.13 16.28-56.25 32.58-84.36 48.89-5.08 3.32-11.93 3.25-17.36.81-34.09-19.56-68.13-39.22-102.24-58.77 73.38-124.27 146.6-248.63 219.92-372.94l-.41-.3c-25.22.18-50.45.2-75.67.29-7.21.39-14.55-.37-21.69.39-73.43 121.29-146.88 242.57-220.46 363.77-8.47-4.83-16.92-9.69-25.34-14.61 19.61-32.21 39.88-64.05 59.74-96.12 51.98-83.37 103.96-166.73 155.94-250.1.66-1.19 1.78-2.22 1.79-3.66-13.31-.19-26.61-.72-39.92-.97-20.59.3-41.98 3.68-59.65 14.9-6.98 4.5-13.13 10.36-17.61 17.37-41.35 64.21-82.86 128.31-124.16 192.55-.38-73.44-.27-146.89-.48-220.34-.37-7.44 3.72-14.97 10.31-18.5 78.67-45.68 157.42-91.22 236.15-136.78z",fill:"#2b374d"})),am||(am=T.createElement("path",{d:"m194.36 220.39c17.67-11.22 39.06-14.6 59.65-14.9 13.31.25 26.61.78 39.92.97-.01 1.44-1.13 2.47-1.79 3.66-51.98 83.37-103.96 166.73-155.94 250.1-19.86 32.07-40.13 63.91-59.74 96.12-13.05-7.52-26.09-15.05-39.14-22.57-9.44-4.83-16.23-13.58-21.12-22.76-2.5-5.29-4.79-10.85-5.38-16.71 1.15-1.35 2.15-2.82 3.1-4.31 12.83-19.93 25.99-39.66 38.67-59.68 41.3-64.24 82.81-128.34 124.16-192.55 4.48-7.01 10.63-12.87 17.61-17.37z",fill:"#fff"})),lm||(lm=T.createElement("path",{d:"m343.95 206.79c25.22-.09 50.45-.11 75.67-.29l.41.3c-73.32 124.31-146.54 248.67-219.92 372.94-7.29 11.73-14.04 23.79-21.17 35.61-25.73-14.78-51.42-29.61-77.14-44.4 73.58-121.2 147.03-242.48 220.46-363.77 7.14-.76 14.48 0 21.69-.39z",fill:"#fff"})),cm||(cm=T.createElement("g",{fill:"#00a2f7"},T.createElement("path",{d:"m434.26 234.64.71-.13c38.08 59.39 76.23 118.74 114.34 178.12 5.97 9.04 11.49 18.41 17.74 27.25.16 14.36.03 28.73.07 43.09-.01 6.42-2.98 13.25-8.75 16.47-14.97 8.6-29.86 17.34-44.83 25.93-42.73-69.12-85.45-138.25-128.22-207.35 16.13-27.9 32.8-55.49 48.94-83.38z"}),T.createElement("path",{d:"m311.6 443.18c18.93-31.67 37.35-63.67 56.36-95.28l.73.41c40.36 63.61 80.72 127.22 121.07 190.83-28.54 16.6-57.11 33.15-85.69 49.67-26.04-40.9-52.12-81.79-78.17-122.69-4.69-7.69-10.01-15.07-14.3-22.94z"}))))},name:"Arbitrum"},[ia.POLYGON]:{chainId:ia.POLYGON,logo:function(e){return T.createElement("svg",fm({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),pm||(pm=T.createElement("defs",null,T.createElement("circle",{id:"path-1",cx:12,cy:12,r:12}))),hm||(hm=T.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},T.createElement("g",{transform:"translate(-223.000000, -266.000000)"},T.createElement("g",{transform:"translate(18.000000, 132.000000)"},T.createElement("g",{transform:"translate(20.000000, 41.000000)"},T.createElement("g",{transform:"translate(156.000000, 82.000000)"},T.createElement("g",{transform:"translate(29.000000, 11.000000)"},T.createElement("mask",{id:"mask-2",fill:"white"},T.createElement("use",{xlinkHref:"#path-1"})),T.createElement("g",null),T.createElement("g",{mask:"url(#mask-2)"},T.createElement("circle",{fill:"#8247E5",fillRule:"nonzero",cx:12,cy:12,r:12}),T.createElement("path",{d:"M8.01148,5.30068 C8.25312,5.16644 8.54688,5.16644 8.78852,5.30068 L12.38852,7.30068 C12.64248,7.44176 12.8,7.70948 12.8,8 L12.8,9.30068 L11.2,10.2 L11.2,8.47072 L8.4,6.91516 L5.6,8.47072 L5.6,11.52928 L8.4,13.08484 L15.21148,9.30068 C15.45312,9.16644 15.74688,9.16644 15.98852,9.30068 L19.58852,11.30068 C19.84248,11.44176 20,11.70948 20,12 L20,16 C20,16.29052 19.84248,16.55824 19.58852,16.69932 L15.98852,18.69932 C15.74688,18.83356 15.45312,18.83356 15.21148,18.69932 L11.61148,16.69932 C11.35752,16.55824 11.2,16.29052 11.2,16 L11.2,14.69932 L12.8,13.8 L12.8,15.52928 L15.6,17.08484 L18.4,15.52928 L18.4,12.47072 L15.6,10.91516 L8.78852,14.69932 C8.54688,14.83356 8.25312,14.83356 8.01148,14.69932 L4.41148,12.69932 C4.15752,12.55824 4,12.29052 4,12 L4,8 C4,7.70948 4.15752,7.44176 4.41148,7.30068 L8.01148,5.30068 Z",fill:"#FFFFFF"}))))))))))},name:"Polygon"},[ia.BSC]:{chainId:ia.BSC,logo:function(e){return T.createElement("svg",bm({xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:"7.5in",height:"7.5in",style:{shapeRendering:"geometricPrecision",textRendering:"geometricPrecision",imageRendering:"optimizeQuality",fillRule:"evenodd",clipRule:"evenodd"},viewBox:"0 0 7500 7500"},e),mm||(mm=T.createElement("defs",null,T.createElement("style",{type:"text/css"},".fil0 {fill:none}\n .fil1 {fill:#f0b90b}\n .fil2 {fill:#fff}"))),gm||(gm=T.createElement("g",{id:"Layer_x0020_1"},T.createElement("metadata",{id:"CorelCorpID_0Corel-Layer"}),T.createElement("rect",{className:"fil0",width:7500,height:7500}),T.createElement("g",{id:"_2419820813232"},T.createElement("circle",{className:"fil1",cx:3750,cy:3750,r:3500}),T.createElement("g",null,T.createElement("path",{className:"fil2",d:"M2779 3351l971 -971 971 972 565 -565 -1536 -1537 -1536 1536 565 565 0 0zm-1529 399l565 -565 565 565 -565 565 -565 -565zm1529 399l971 971 971 -972 566 565 0 0 -1537 1537 -1536 -1536 -1 -1 566 -564 0 0zm2341 -399l565 -565 565 565 -565 565 -565 -565z"})),T.createElement("g",null,T.createElement("path",{className:"fil2",d:"M4380 3750l0 0 -630 -632 -466 467 0 0 -54 54 -111 111 -1 1 1 1 630 630 631 -631 0 0 0 0 0 -1zm0 0l0 0 0 0z"}))))),ym||(ym=T.createElement("style",{xmlns:""},"#yddContainer{display:block;font-family:Microsoft YaHei;position:relative;width:100%;height:100%;top:-4px;left:-4px;font-size:12px;border:1px solid}#yddTop{display:block;height:22px}#yddTopBorderlr{display:block;position:static;height:17px;padding:2px 28px;line-height:17px;font-size:12px;color:#5079bb;font-weight:bold;border-style:none solid;border-width:1px}#yddTopBorderlr .ydd-sp{position:absolute;top:2px;height:0;overflow:hidden}.ydd-icon{left:5px;width:17px;padding:0px 0px 0px 0px;padding-top:17px;background-position:-16px -44px}.ydd-close{right:5px;width:16px;padding-top:16px;background-position:left -44px}#yddKeyTitle{float:left;text-decoration:none}#yddMiddle{display:block;margin-bottom:10px}.ydd-tabs{display:block;margin:5px 0;padding:0 5px;height:18px;border-bottom:1px solid}.ydd-tab{display:block;float:left;height:18px;margin:0 5px -1px 0;padding:0 4px;line-height:18px;border:1px solid;border-bottom:none}.ydd-trans-container{display:block;line-height:160%}.ydd-trans-container a{text-decoration:none;}#yddBottom{position:absolute;bottom:0;left:0;width:100%;height:22px;line-height:22px;overflow:hidden;background-position:left -22px}.ydd-padding010{padding:0 10px}#yddWrapper{color:#252525;z-index:10001;background:url(chrome-extension://eopjamdnofihpioajgfdikhhbobonhbb/ab20.png);}#yddContainer{background:#fff;border-color:#4b7598}#yddTopBorderlr{border-color:#f0f8fc}#yddWrapper .ydd-sp{background-image:url(chrome-extension://eopjamdnofihpioajgfdikhhbobonhbb/ydd-sprite.png)}#yddWrapper a,#yddWrapper a:hover,#yddWrapper a:visited{color:#50799b}#yddWrapper .ydd-tabs{color:#959595}.ydd-tabs,.ydd-tab{background:#fff;border-color:#d5e7f3}#yddBottom{color:#363636}#yddWrapper{min-width:250px;max-width:400px;}")))},name:"BNBChain"},[ia.OPTIMISM]:{chainId:ia.OPTIMISM,logo:function(e){return T.createElement("svg",wm({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),xm||(xm=T.createElement("defs",null,T.createElement("circle",{id:"path-1",cx:12,cy:12,r:12}))),vm||(vm=T.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},T.createElement("g",{transform:"translate(-223.000000, -266.000000)"},T.createElement("g",{transform:"translate(18.000000, 132.000000)"},T.createElement("g",{transform:"translate(20.000000, 41.000000)"},T.createElement("g",{transform:"translate(156.000000, 82.000000)"},T.createElement("g",{transform:"translate(29.000000, 11.000000)"},T.createElement("mask",{id:"mask-2",fill:"white"},T.createElement("use",{xlinkHref:"#path-1"})),T.createElement("g",null),T.createElement("g",{id:"optimism.caeb9392",mask:"url(#mask-2)",fillRule:"nonzero"},T.createElement("circle",{fill:"#FF0420",cx:12,cy:12,r:12}),T.createElement("path",{d:"M7.85495544,16 C7.01608475,16 6.32880363,15.7925669 5.7930557,15.37776 C5.2643519,14.9555511 5,14.3555763 5,13.5777763 C5,13.4148143 5.01763849,13.2147832 5.05285911,12.9777422 C5.14454543,12.4444444 5.27494626,11.8036699 5.44411795,11.0555371 C5.92345653,9.01851235 7.16063019,8 9.15558257,8 C9.69837462,8 10.1847573,8.09628495 10.614787,8.28885484 C11.0448167,8.47402275 11.3831601,8.75553483 11.6298735,9.13333185 C11.8765869,9.50366768 12,9.94814173 12,10.4666356 C12,10.6221956 11.9823615,10.8184961 11.9470845,11.0555371 C11.8413663,11.7147869 11.7144594,12.3555615 11.5664201,12.9777422 C11.3197066,13.9925832 10.8932272,14.7518486 10.2869817,15.2555385 C9.68073613,15.7518264 8.8700983,16 7.85495544,16 Z M8.00299476,14.3999882 C8.39780384,14.3999882 8.73259699,14.2777667 9.00754325,14.0333237 C9.28953364,13.7888807 9.49043207,13.4148143 9.61023853,12.9111244 C9.7723661,12.2148054 9.89577916,11.6073694 9.98036501,11.0888756 C10.0085415,10.9333156 10.0226298,10.7740842 10.0226298,10.611063 C10.0226298,9.93700916 9.68778026,9.59995263 9.01813761,9.59995263 C8.62332853,9.59995263 8.28498515,9.72217411 8.00299476,9.96661707 C7.72810485,10.2111193 7.53070031,10.5851857 7.41089384,11.0888756 C7.28398689,11.5851635 7.15707995,12.1925995 7.03022936,12.9111244 C7.00199651,13.0592232 6.98790826,13.2147832 6.98790826,13.3777452 C6.98790826,14.0592602 7.32630799,14.3999882 8.00299476,14.3999882 Z",fill:"#FFFFFF"}),T.createElement("path",{d:"M12.2418282,16 C12.1556269,16 12.0889713,15.9733226 12.0419867,15.9199677 C12.0027701,15.8589994 11.9910553,15.7904787 12.0067168,15.7142835 L13.6288783,8.28571646 C13.6445399,8.20190792 13.6876405,8.13332623 13.7581802,8.07997137 C13.8287198,8.02667743 13.9031435,8 13.981514,8 L17.1083126,8 C17.9781556,8 18.675596,8.1752305 19.2006341,8.52569149 C19.7335656,8.87621339 20,9.38284087 20,10.0456958 C20,10.2361531 19.9765077,10.4342848 19.9294603,10.6399689 C19.7335656,11.5161823 19.3378293,12.1638104 18.7422516,12.5828531 C18.1545047,13.0018957 17.347308,13.2114171 16.3207242,13.2114171 L14.7338326,13.2114171 L14.1931329,15.7142835 C14.1774087,15.7980921 14.1343081,15.8666129 14.0638311,15.9199677 C13.9932915,15.9733226 13.9188051,16 13.8404973,16 L12.2418282,16 Z M16.4030414,11.6342817 C16.732122,11.6342817 17.0181647,11.546636 17.2611068,11.3714055 C17.5118797,11.196175 17.6764513,10.9447494 17.7548217,10.6171287 C17.7783141,10.4875787 17.7900916,10.3733165 17.7900916,10.2742811 C17.7900916,10.0533092 17.7234986,9.8856921 17.5902501,9.77142988 C17.4570016,9.64949333 17.2297837,9.58858596 16.9084712,9.58858596 L15.497866,9.58858596 L15.0511984,11.6342817 L16.4030414,11.6342817 Z",fill:"#FFFFFF"}))))))))))},name:"Optimism"},[ia.AVALANCHE]:{chainId:ia.AVALANCHE,logo:function(e){return T.createElement("svg",Cm({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),Em||(Em=T.createElement("defs",null,T.createElement("circle",{id:"path-1",cx:12,cy:12,r:12}))),Am||(Am=T.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},T.createElement("g",null,T.createElement("mask",{fill:"white"},T.createElement("use",{xlinkHref:"#path-1"})),T.createElement("use",{fill:"#E84142",xlinkHref:"#path-1"}),T.createElement("g",{mask:"url(#mask-2)",fill:"#FFFFFF",fillRule:"nonzero"},T.createElement("g",{transform:"translate(5.000000, 5.000000)"},T.createElement("path",{d:"M3.51363108,13 L1.15960067,13 C0.664946832,13 0.420612287,13 0.271614013,12.9001615 C0.110719232,12.7911601 0.0123723422,12.6101909 0.000457589205,12.410743 C-0.00848303711,12.226815 0.113693358,12.0023407 0.358027903,11.5534302 L6.1704203,0.83471072 C6.41774722,0.379558003 6.54289774,0.1519721 6.70083664,0.0678061674 C6.87067205,-0.0226020558 7.07329583,-0.0226020558 7.24314949,0.0678061674 C7.40108839,0.1519721 7.52623891,0.379558003 7.77354758,0.83471072 L8.96845316,3.01699266 C9.23960959,3.51267254 9.37667486,3.76207783 9.43628512,4.0239486 C9.50182538,4.30763877 9.50182538,4.60692511 9.43628512,4.89061527 C9.37667486,5.15248605 9.24258371,5.40189134 8.97142729,5.89757122 L5.91831288,11.5440764 C5.64418233,12.0459985 5.50711706,12.2985154 5.31640802,12.4885903 C5.11079187,12.6943759 4.86348319,12.8440382 4.59230852,12.9282232 C4.34499985,13 4.06787693,13 3.51363108,13 Z"}),T.createElement("path",{d:"M12.8314423,13 L9.45829001,13 C8.96066205,13 8.710361,13 8.5643551,12.9003524 C8.40344207,12.7911601 8.30511343,12.6071366 8.29319868,12.4077078 C8.28425805,12.2237606 8.40940857,11.9993054 8.65970962,11.5472643 L10.3432113,8.52326579 C10.5906295,8.07746696 10.7157982,7.85612335 10.8707083,7.77193833 C11.0405802,7.6815301 11.2401933,7.6815301 11.4100652,7.77193833 C11.5680771,7.85612335 11.690144,8.07746696 11.9404816,8.52015419 L13.6300775,11.5441527 C13.8802326,11.9961938 14.0085032,12.220649 13.9995625,12.4045771 C13.9906219,12.6040822 13.8891732,12.7881057 13.7284244,12.8971072 C13.5793531,13 13.3290156,13 12.8314423,13 Z"})))))))},name:"Avalanche"},[ia.AURORA]:{chainId:ia.AURORA,logo:function(e){return T.createElement("svg",Rm({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),km||(km=T.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},T.createElement("g",{id:"aurora-avatar-grn",fillRule:"nonzero"},T.createElement("path",{d:"M12,0 L12,0 C18.625,0 24,5.375 24,12 L24,12 C24,18.625 18.625,24 12,24 L12,24 C5.375,24 0,18.625 0,12 L0,12 C0,5.375 5.375,0 12,0 Z",id:"\\u8DEF\\u5F84",fill:"#70D44B"}),T.createElement("path",{d:"M12,4.9 C12.6333333,4.9 13.2083333,5.25833333 13.4916667,5.825 L18.175,15.2 C18.5833333,16.025 18.25,17.025 17.425,17.4333333 C17.1916667,17.55 16.9416667,17.6083333 16.6833333,17.6083333 L7.31666667,17.6083333 C6.4,17.6083333 5.65,16.8583333 5.65,15.9416667 C5.65,15.6833333 5.70833333,15.425 5.825,15.2 L10.5083333,5.825 C10.7916667,5.25 11.3666667,4.89166667 12,4.9 M12,3.75 C10.9333333,3.75 9.95833333,4.35 9.48333333,5.30833333 L4.8,14.6833333 C4.10833333,16.075 4.66666667,17.7583333 6.05833333,18.4583333 C6.45,18.65 6.88333333,18.7583333 7.31666667,18.7583333 L16.6916667,18.7583333 C18.2416667,18.7583333 19.5083333,17.5 19.5083333,15.95 C19.5083333,15.5166667 19.4083333,15.0833333 19.2083333,14.6916667 L14.5166667,5.30833333 C14.0416667,4.35 13.0666667,3.75 12,3.75 Z",id:"\\u5F62\\u72B6",fill:"#FFFFFF"})))))},name:"Aurora"},[ia.OKCHAIN]:{chainId:ia.OKCHAIN,logo:function(e){return T.createElement("svg",Nm({width:72,height:72,viewBox:"0 0 72 72",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),Tm||(Tm=T.createElement("circle",{cx:36,cy:36,r:36,fill:"black"})),Sm||(Sm=T.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M29.2 18H18.8C18.3582 18 18 18.3582 18 18.8V29.2C18 29.6418 18.3582 30 18.8 30H29.2C29.6418 30 30 29.6418 30 29.2V18.8C30 18.3582 29.6418 18 29.2 18ZM41.2052 30H30.8052C30.3633 30 30.0051 30.3582 30.0051 30.8V41.2C30.0051 41.6418 30.3633 41.9999 30.8052 41.9999H41.2052C41.647 41.9999 42.0051 41.6418 42.0051 41.2V30.8C42.0051 30.3582 41.647 30 41.2052 30ZM42.8 18H53.2C53.6418 18 54 18.3582 54 18.8V29.2C54 29.6418 53.6418 30 53.2 30H42.8C42.3582 30 42 29.6418 42 29.2V18.8C42 18.3582 42.3582 18 42.8 18ZM29.2 42H18.8C18.3582 42 18 42.3582 18 42.8V53.2C18 53.6418 18.3582 54 18.8 54H29.2C29.6418 54 30 53.6418 30 53.2V42.8C30 42.3582 29.6418 42 29.2 42ZM42.8 42H53.2C53.6418 42 54 42.3582 54 42.8V53.2C54 53.6418 53.6418 54 53.2 54H42.8C42.3582 54 42 53.6418 42 53.2V42.8C42 42.3582 42.3582 42 42.8 42Z",fill:"white"})))},name:"OKTC"},[ia.CONFLUX]:{chainId:ia.CONFLUX,logo:function(e){return T.createElement("svg",Fm({width:"199px",height:"245px",viewBox:"0 0 199 245",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),Mm||(Mm=T.createElement("g",{id:"Page-1",stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},T.createElement("g",{id:"Conflux_Logo_Mark_Color",transform:"translate(0.000000, -0.000000)",fillRule:"nonzero"},T.createElement("polygon",{id:"Path",fill:"#1A1A1A",points:"151.057838 145.949662 98.7961863 198.210803 69.7103803 169.125338 121.972032 116.863685 98.7291726 93.6209957 22.9712333 169.376384 98.5203077 244.923077 174.276376 169.167689"}),T.createElement("polygon",{id:"Path",fill:"#38A1DB",points:"197.693744 98.7101231 98.9858316 9.56888949e-05 0 98.9860017 0.31563441 145.252991 98.5658906 47.0051607 197.528761 145.971262"})))))},name:"Conflux eSpace"}};function Im({width:e=24,height:t=24,marginRight:r=8,url:o,zIndex:i,cross:s,address:a,token:c,sx:d,chainId:p}){const[h,f]=n.useState(!1),[m,g]=n.useState(""),[y,b]=n.useState(""),[x,v]=n.useState(!1),w=n.useCallback((()=>f(!0)),[]);let E=function(e){const t=l.useSelector(Ih),{chainId:r}=u.useWeb3React();return n.useMemo((()=>{if(!e)return;let n=t.find((({address:t,chainId:n})=>n===r&&t===e));return n||(n=t.find((({address:t})=>t===e))),n}),[e,t,r])}(a);c&&(E=c);const A=a||(null==E?void 0:E.address),C=null==E?void 0:E.symbol,k=null==C?void 0:C.charAt(0).toUpperCase(),R=n.useMemo((()=>{const e=null==E?void 0:E.logoURI;return o||e||""}),[o,E]);return n.useEffect((()=>{v(!1)}),[A,R]),n.useEffect((()=>{s&&(R?function(e,t){const r=new XMLHttpRequest;let n;r.onload=function(){const e=new FileReader;e.onloadend=function(){t(e.result)},e.readAsDataURL(r.response)},r.onerror=function(){t()};try{n=new URL(e)}catch(e){}finally{r.open("GET",n||e),r.responseType="blob",r.send()}}(R,(e=>{g(e)})):g(""))}),[R,s]),n.useEffect((()=>{try{let t=A;if(t&&t.length<15&&(t=t.padEnd(15,"0")),t){const r=new F.default(t,{size:e,format:"svg",margin:.2,background:[255,234,4,255]}).toString();b(`data:image/svg+xml;base64,${r}`)}}catch(e){console.error("generate Identicon error: ",e)}}),[A,e]),ne.exports.jsxs(Sr,{sx:Object.assign({position:"relative",display:"flex",alignItems:"center",justifyContent:"center",minWidth:e,width:e,height:t,marginRight:r,zIndex:i,border:"solid 1px",borderColor:"border.main",borderRadius:"50%"},d||{}),style:{width:e,height:t},children:[!h&&ne.exports.jsx(Sr,{sx:{typography:"ht",height:"100%",width:"100%",borderRadius:"50%",border:"transparent 2px solid",borderColor:"text.primary",color:"text.primary",display:"flex",alignItems:"center",justifyContent:"center"},children:k}),ne.exports.jsx(Sr,{component:"img",src:!(s?m:R)||x?y:s?m:R,onLoad:w,onError:e=>{const t=e.target;A&&y&&v(!0),t.onerror=null},sx:{position:"absolute",top:"0",bottom:"0",left:"0",right:"0",borderRadius:"50%",overflow:"hidden",width:"100%",height:"100%"}}),p&&Om[p]?ne.exports.jsx(Sr,{sx:{position:"absolute",right:0,bottom:-1,width:12,height:12,transform:"translateX(50%)",border:"solid 1px",borderColor:"border.main",borderRadius:"50%"},children:ne.exports.jsx(Sr,{component:Om[p].logo,sx:{display:"block",width:"100%",height:"100%"}})}):""]})}function jm({token:t,onClick:r,showChainLogo:n}){var o,s;const a=kr();return ne.exports.jsxs(Sr,{component:wn,sx:{display:"flex",alignItems:"center",color:a.palette.text.primary,typography:"h5",fontWeight:600},onClick:e=>{r&&r(e)},"data-testid":"swap-select-token-btn",children:[(null==t?void 0:t.address)?ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Im,{url:null==t?void 0:t.logoURI,address:null!==(o=null==t?void 0:t.address)&&void 0!==o?o:"",marginRight:6,chainId:n?null==t?void 0:t.chainId:void 0}),ne.exports.jsx(Sr,{children:null!==(s=null==t?void 0:t.symbol)&&void 0!==s?s:"-"})]}):ne.exports.jsx(e.Trans,{id:"SELECT TOKEN"}),ne.exports.jsx(Sr,{sx:{ml:7,width:12,transform:"rotateX(180deg)"},component:i.CaretUp})]})}function Dm({onClick:t,balance:r,decimals:n,address:o,showMaxBtn:i}){const{palette:s}=kr();return ne.exports.jsxs(Sr,{sx:{display:"flex",typography:"body2",color:s.text.secondary},children:[ne.exports.jsx(e.Trans,{id:"Balance:"})," ",o?us({input:r,decimals:Math.min(n||4,4)}):"-",i&&r&&r.gt(0)&&ne.exports.jsx(Sr,{component:wn,sx:{ml:6,color:(null==r?void 0:r.gt(0))?s.primary.main:s.text.disabled,cursor:o&&t?"pointer":"unset"},onClick:()=>t&&t(r?r.toString():""),children:ne.exports.jsx(e.Trans,{id:"Max"})})]})}function Bm({readOnly:e,sx:t,value:r,decimals:o,onChange:s,suffix:a,withClear:l,onFocus:c,placeholder:u}){const d=kr(),p=n.useMemo((()=>a||(l&&r&&s?ne.exports.jsx(Sr,{component:wn,sx:{ml:5,width:18,height:18,borderRadius:"50%",backgroundColor:"border.main",display:"flex",justifyContent:"center",alignItems:"center",flexShrink:0},onClick:()=>{s&&s("")},children:ne.exports.jsx(Sr,{component:i.Error,sx:{width:12,color:"text.secondary"}})}):void 0)),[s,a,d.palette.text.primary,r,l]);return ne.exports.jsxs(Sr,{sx:Object.assign({mt:12,display:"flex",justifyContent:"space-between",alignItems:"center"},t),"data-testid":"number-input-wrapper",children:[ne.exports.jsx(On,{fullWidth:!0,value:r,readOnly:e,placeholder:u||"0.00",onFocus:c,onChange:e=>{const t=e.target.value,r=0===t.length?"":hs(t,o);s&&s(r)},sx:{width:"inherit",border:"none","& .MuiInput-input":{fontSize:24,border:"none",outline:"none",height:24,padding:0,color:"text.primary","&::placeholder":{fontSize:24,color:"text.disabled"}}}}),!e&&r&&p]})}function Pm({open:e,onClose:t,afterClose:r,title:n,rightSlot:o,canBack:s=!0,children:a,height:l,testId:c}){return ne.exports.jsxs(Sr,{sx:{position:"absolute",top:e?0:"100%",transition:"top 300ms",zIndex:1,left:0,right:0,bottom:0,display:"flex",flexDirection:"column",backgroundColor:"background.paper",borderRadius:16,height:l},"data-testid":c,"data-active":e?"1":"0",children:[n?ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",p:20},children:[ne.exports.jsx(Sr,{sx:{display:"flex",alignItems:"center",typography:"caption"},children:n}),o,!o&&s&&ne.exports.jsx(Sr,{component:i.Error,sx:{color:"text.secondary",cursor:"pointer"},onClick:()=>{t&&t(),setTimeout((()=>r&&r()),300)}})]}):"",a]})}function Wm({token:e,disabled:t,style:r,onClick:n}){const o=kr(),s=_h(),{account:a}=u.useWeb3React(),l=s(e),c=l?cs({input:l}):"";return ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",typography:"body2",px:6,py:5,borderRadius:8,cursor:t?"auto":"pointer",opacity:t?.5:1,"&:hover":{backgroundColor:"hover.default"}},style:r,onClick:()=>{t||n()},"data-testid":"token-picker-item",children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Im,{token:e}),ne.exports.jsxs(Sr,{children:[ne.exports.jsx(Sr,{sx:{fontWeight:600,textAlign:"left"},children:e.symbol}),a&&ne.exports.jsx(Sr,{sx:{mt:4,textAlign:"left"},children:(null==l?void 0:l.gte(0))?c:ne.exports.jsx(Sr,{component:i.Loading,width:18,sx:{"& path":{fill:o.palette.text.disabled},animation:"loadingRotate 1.1s infinite linear","@keyframes loadingRotate":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(359deg)"}}}})})]})]}),ne.exports.jsx(Sr,{sx:{color:"text.secondary",textAlign:"right"},children:e.name})]})}function _m({chain:t,active:r,onClick:n}){return ne.exports.jsx(ui,{title:t.name,placement:"top",onlyHover:!0,children:ne.exports.jsxs(Sr,{sx:Object.assign({display:"flex",alignItems:"center",p:8,borderRadius:8,cursor:"pointer"},r?{backgroundColor:"secondary.main",color:"secondary.contrastText"}:{border:"1px solid",borderColor:"border.main","&:hover":{backgroundColor:"hover.default"}}),onClick:n,children:[ne.exports.jsx(Sr,{component:t.logo,sx:{width:24,height:24}}),r?ne.exports.jsxs(Sr,{sx:{ml:8},children:[ne.exports.jsx(e.Trans,{id:"on"}),` ${t.name}`]}):""]})},t.chainId)}function Um({value:e,onChange:t,occupiedAddrs:r,hiddenAddrs:o,showAddrs:i,visible:s,side:a,defaultLoadBalance:l}){const{chainList:c,selectChainId:d,setSelectChainId:p}=function(){const{chainId:e}=u.useWeb3React(),[t,r]=n.useState(e),o=n.useMemo((()=>{const t={};let r;return Object.entries(Om).forEach((([n,o])=>{if(o.mainnet){if(e!==o.chainId)return;r=o.mainnet}t[n]=Object.assign({},o)})),void 0!==r&&delete t[r],Object.values(t)}),[e]);return n.useEffect((()=>{void 0===t&&r(e)}),[e]),{chainList:o,selectChainId:n.useMemo((()=>null!=t?t:1),[t]),setSelectChainId:r}}(),{showTokenList:h,filter:f,setFilter:m,onSelectToken:g,popularTokenList:y}=tm({value:e,onChange:t,occupiedAddrs:r,hiddenAddrs:o,showAddrs:i,side:a,chainId:d,visible:s,defaultLoadBalance:l}),b=n.useRef(null),[w,E]=n.useState(0),A=n.useRef(s);n.useEffect((()=>{!A.current&&s&&(null==e?void 0:e.chainId)!==d&&p(null==e?void 0:e.chainId),A.current=s}),[e,s]),n.useEffect((()=>{s&&b.current&&E(b.current.offsetHeight-16)}),[b,s]);const C=n.useCallback((({index:t,style:r})=>{const n=h[t];return n?ne.exports.jsx(Wm,{token:n,disabled:!!e&&e.address===n.address,style:r,onClick:()=>g(n)},n.address+n.chainId):null}),[h,y,e]);return ne.exports.jsxs(Sr,{sx:{display:"flex",flexDirection:"column",px:20,flex:1},children:[ne.exports.jsx(jn,{fullWidth:!0,height:48,value:f,onChange:e=>m(e.target.value),clearValue:()=>m(""),placeholder:x.i18n._("Enter the token symbol or address")}),ne.exports.jsx(Sr,{sx:{position:"relative",display:"flex",gap:8,flexWrap:"wrap",pt:16,pb:32,"&::after":{content:'""',position:"absolute",bottom:16,left:0,right:0,height:"1px",backgroundColor:"border.main"}},children:c.map((e=>ne.exports.jsx(_m,{chain:e,active:e.chainId===d,onClick:()=>{p(e.chainId)}},e.chainId)))}),ne.exports.jsx(Sr,{sx:{pb:16,flex:1,minHeight:64},ref:b,children:ne.exports.jsx(v.FixedSizeList,{height:w,itemCount:h.length,itemSize:52,width:"100%",className:"token-list",children:C},y.length)})]})}function Lm({open:t,value:r,onClose:n,occupiedAddrs:o,onTokenChange:i,side:s,defaultLoadBalance:a}){const{height:c}=l.useSelector(Uh);return ne.exports.jsx(Pm,{height:c,open:t,onClose:n,title:ne.exports.jsx(e.Trans,{id:"Select a token"}),testId:"token-picker-wrapper",children:ne.exports.jsx(Um,{value:r,visible:t,onChange:i,occupiedAddrs:o,side:s,defaultLoadBalance:a})})}function Vm(e){const{provider:t}=u.useWeb3React(),r=n.useMemo((()=>{var r;if(e&&(null===(r=null==t?void 0:t.provider)||void 0===r?void 0:r.isMetaMask))return()=>function({chainId:e,provider:t}){var r,n,o;return ma(this,void 0,void 0,(function*(){if(!t)return!1;const i=`0x${e.toString(16)}`;try{return yield t.request({method:"wallet_switchEthereumChain",params:[{chainId:i}]}),!0}catch(s){const{code:a}=s,l=la[e];if(!l)throw new Error(`Chain ${e} does not exist`);const c={chainId:i,chainName:null===(r=Om[e])||void 0===r?void 0:r.name,rpcUrls:[...sa[e],...null!==(o=null===(n=Th.getState().globals.jsonRpcUrlMap)||void 0===n?void 0:n[e])&&void 0!==o?o:[]],nativeCurrency:{name:l.name,symbol:l.symbol,decimals:l.decimals},blockExplorerUrls:[`https://${ua[e]}/`]};if(4902===a||-32603===a)try{return yield t.request({method:"wallet_addEthereumChain",params:[c]}),!0}catch(t){console.error(`[failed to add ${e}]: `,c,t)}console.error(`[failed to switch ${e}]: `,c,s)}return!1}))}({chainId:e,provider:null==t?void 0:t.provider})}),[e]);return r}const Zm=(e,t)=>{const r=String(e).split("."),n=!r[1],o=Number(r[0])==e,i=o&&r[0].slice(-1),s=o&&r[0].slice(-2);return t?1==i&&11!=s?"one":2==i&&12!=s?"two":3==i&&13!=s?"few":"other":1==e&&n?"one":"other"},Hm={"en-US":Zm,"zh-CN":(e,t)=>"other",pseudo:Zm};function zm({locale:t,children:r}){return n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){yield function(e="en-US"){return ma(this,void 0,void 0,(function*(){x.i18n.loadLocaleData(e,{plurals:()=>Hm[e]});try{const r=yield(t=`./locales/${e}.js`,Promise.resolve().then((function(){return A(require(t))})));x.i18n.load(e,r.messages||r.default.messages)}catch(e){}var t;x.i18n.activate(e)}))}(t)}))})()}),[t]),ne.exports.jsx(e.I18nProvider,{i18n:x.i18n,children:r})}var Ym,Gm,Xm,Jm;!function(e){e[e.Running=0]="Running",e[e.Success=1]="Success",e[e.Failed=2]="Failed",e[e.Warning=3]="Warning"}(Ym||(Ym={})),function(e){e.Canceled="canceled",e.Failed="failed",e.Success="success",e.Submitted="submitted"}(Gm||(Gm={})),function(e){e[e.Failed=0]="Failed",e[e.Success=1]="Success"}(Xm||(Xm={})),function(e){e[e.Failed=0]="Failed",e[e.Success=1]="Success",e[e.Warning=2]="Warning"}(Jm||(Jm={}));const qm=(e,t)=>ma(void 0,void 0,void 0,(function*(){const{value:r,from:n,to:o,data:i}=e,s={from:n,to:o,value:r,data:i};r&&!/^0x0*$/.test(r)||delete s.value;try{return(yield t.estimateGas(s)).add(5e4)}catch(e){t.call(s).then((e=>{if("test"!==process.env.NODE_ENV)throw new Error("Unexpected issue with estimating the gas. Please try again.")})).catch((e=>{if("test"!==process.env.NODE_ENV)throw e}))}return null})),Qm=(e,t)=>ma(void 0,void 0,void 0,(function*(){try{return yield t.getSigner().sendTransaction(e)}catch(e){throw 4001===(null==e?void 0:e.code)?new Error(x.i18n._("Transaction rejected.")):e}}));var Km,$m;!function(e){e.Approval="APPROVAL",e.TX="TX",e.TypedSign="TypedSign"}(Km||(Km={})),function(e){e.Normal="Normal",e.Privacy="Privacy",e.LimitOrder="LimitOrder",e.RFQ="RFQ"}($m||($m={}));const eg=new k.default(2).pow(256).minus(1),tg=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_GLOBAL_PROPS",payload:e})})),rg=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_AUTO_CONNECT_LOADING",payload:e})}));function ng({onTxFail:e,onTxSubmit:t,onTxSuccess:r}={}){const{account:o,provider:i}=u.useWeb3React(),s=Mh(),[a,c]=n.useState(!1),[d,p]=n.useState(new Map),h=l.useDispatch(),[f,m]=n.useState(null),[g,y]=n.useState(""),[b,v]=n.useState(null),[w,E]=n.useState(!1),[A,C]=n.useState(),{updateBlockNumber:R}=Qf(),T=n.useCallback(((n,a,l,u=!1,d,f,g,b)=>ma(this,void 0,void 0,(function*(){if(y(""),m(""),!o||!i)throw new Error("Submission: Cannot execute step when the wallet is disconnected");let w,A,T;C((()=>g)),c(!1);try{if(c(!0),a.opcode===Km.Approval)T=yield((e,t,r,n,o,i)=>ma(void 0,void 0,void 0,(function*(){const s=Yf(e,$f,o,i).interface.encodeFunctionData("approve",[r,n.toFixed()]),a={from:t,to:e,data:s,value:`0x${new k.default("0").toString(16)}`,gasLimit:void 0},l=yield qm(a,o);return l&&(a.gasLimit=l),yield Qm(a,o)})))(a.token.address,o,a.contract,a.amt||eg,i,o),w=T.hash,y(w);else{if(a.opcode!==Km.TX)throw new Error(`Op ${a.opcode} not implemented!`);if(""===a.to)throw new Error("Submission: malformed to");if(0===a.data.length)throw new Error("Submission: malformed data");if(0===a.data.indexOf("0x")&&a.data.length<=2)throw new Error("Submission: malformed data");if(A={value:a.value,data:a.data,to:a.to,gasLimit:a.gasLimit,from:o,chainId:s},!A.gasLimit)try{const e=yield qm(A,i);e&&(A.gasLimit=e)}catch(e){console.debug(e)}if(T=yield Qm(A,i),w=T.hash,y(w),!w)throw new Error(`Unexpected tx: ${w}`)}}catch(t){if(c(!1),v({spec:a,brief:n,subtitle:l}),console.error(t),t.message){h(tg({contractStatus:wh.Failed}));const r={error:t.message,brief:n};f&&Object.assign(r,f),e&&e(t,f),m(function(e,t){var r;const n=null===(r=la[e])||void 0===r?void 0:r.symbol,o=[{error:"insufficient",msg:x.i18n._("Insufficient funds - Please retry after depositing more {EtherTokenSymbol} into your wallet",{EtherTokenSymbol:n})},{error:["External Swap execution Failed","Return amount is not enough"],msg:x.i18n._("Price impact exceeds the slippage tolerance you set. Try increasing the slippage tolerance.")},{error:"SafeERC20: low-level call failed",msg:x.i18n._("SafeERC20: low-level call failed. Please contact the DODO team.")},{error:["User denied","cancel","User rejected","user rejected"],msg:x.i18n._("User denied transaction signature.")},{error:["Cannot set properties of undefined (setting 'loadingDefauIts'){\"originalError\":{",'[ethjs-query]while formatting outputs from RPC\'["value":["code":-32000,"message":"header not found"))'],msg:x.i18n._("RPC node data exception")},{error:['execution reverted:FORCESTOP ["originalError"'],msg:x.i18n._("ForceStop exception")},{error:["replacement transaction underpriced","Gasprice too low","transaction underprice"],msg:x.i18n._("Gas price is too low, please adjust in your wallet and try again")},{error:["MINT_INVALID"],msg:x.i18n._("No ForceStop access")},{error:["NOT_PHASE_EXE"],msg:x.i18n._("Unable to SETTLE during the cooling-off period")},{error:["params specify an EIP-1559transaction but the currentnetwork does not support"],msg:x.i18n._("Wallet incompatibility")},{error:["ALREADY_SETTLED"],msg:x.i18n._("This CP has been settled by other addrs")},{error:["create RFQ order failed]:LESS_THAN_FEE_LIMIT"],msg:x.i18n._("Service update, please wait and try again")}];let i="";return o.some((e=>Array.isArray(e.error)?e.error.some((r=>t.indexOf(r)>-1&&(i=e.msg,!0))):t.indexOf(e.error)>-1&&(i=e.msg,!0))),i||t}(s,t.message))}return Gm.Failed}v({spec:a,brief:n,subtitle:l}),E(!1),c(!1);const S=Object.assign(Object.assign(Object.assign(Object.assign({brief:n},a),A),{tx:w,subtitle:l}),f);h(tg({contractStatus:wh.Pending})),t&&t(w,S),d&&d();const N={brief:n,spec:a,tx:w,subtitle:l};if(p((e=>e.set(w,[N,Ym.Running]))),u)return Gm.Submitted;if(d&&d(),null==T?void 0:T.wait){const e=yield T.wait(1);if(E(!0),e.status===Xm.Success)return"TX"===S.opcode&&h(tg({contractStatus:wh.TxSuccess})),"APPROVAL"===S.opcode&&h(tg({contractStatus:wh.ApproveSuccess})),b&&b(w,r),r&&r(w,S),yield R(),p((e=>e.set(w,[N,Ym.Success]))),Gm.Success}return yield R(),E(!0),p((e=>e.set(w,[N,Ym.Failed]))),Gm.Failed}))),[o,s,c,i,R]),S=n.useMemo((()=>({execute:T,requests:d,setShowing:v,waitingSubmit:a})),[T,d,v]),N=n.useCallback((()=>{v(null),A&&(A(),C(void 0))}),[A]);return{showing:b,showingDone:w,transactionTx:g,errorMessage:f,setErrorMessage:m,closeShowing:N,ctxVal:S,requests:d}}function og(){const{requests:e}=sg(),t=[];return null==e||e.forEach((function([e,r]){r===Ym.Running&&t.push(e)})),{runningRequests:t,isInflight:t.length>0}}const ig=n.createContext({execute:()=>Promise.resolve(Gm.Canceled),requests:void 0,waitingSubmit:!1});function sg(){return n.useContext(ig)}var ag;function lg(){return lg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},lg.apply(this,arguments)}var cg=function(e){return T.createElement("svg",lg({width:"33px",height:"33px",viewBox:"0 0 33 33",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),ag||(ag=T.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd",strokeLinecap:"round",strokeLinejoin:"round"},T.createElement("g",{transform:"translate(-186.000000, -375.000000)",stroke:"currentColor",strokeWidth:4},T.createElement("g",{transform:"translate(18.000000, 291.000000)"},T.createElement("g",{transform:"translate(40.000000, 83.000000)"},T.createElement("path",{d:"M159,32 C159,15.9837423 146.016258,3 130,3"})))))))};function ug({showingDone:e,errorMessage:t}){return t?ne.exports.jsx(Sr,{component:i.ErrorWarn,sx:{width:64,height:64,color:"error.main"}}):e?ne.exports.jsx(Sr,{component:i.DoneBorder,sx:{width:64,height:64,color:"success.main"}}):ne.exports.jsx(Sr,{sx:{mx:"auto",border:e=>{var t;return`6px solid ${null===(t=e.palette)||void 0===t?void 0:t.background.input}`},borderRadius:"50%",width:"64px",height:"64px",position:"relative",animation:"loadingRotate 1.1s infinite linear","@keyframes loadingRotate":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(359deg)"}}},children:ne.exports.jsx(Sr,{component:cg,sx:{position:"absolute",top:"-6px",right:"-6px",color:"primary.main"}})})}function dg({showingDone:e,showing:t}){return ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:[ne.exports.jsx(Sr,{sx:{mt:60},children:e?x.i18n._("{0} confirmed",{0:null==t?void 0:t.brief}):x.i18n._("{0} pending",{0:null==t?void 0:t.brief})}),(null==t?void 0:t.subtitle)?ne.exports.jsx(Sr,{sx:{mt:20,typography:"body2"},children:null==t?void 0:t.subtitle}):""]})}function pg({isStarted:t,isEnded:r,tx:o}){const[s,a]=n.useState(0),{chainId:l}=u.useWeb3React(),c=n.useMemo((()=>`https://${ua[l||1]}/tx/${o}`),[o,l]),d=n.useMemo((()=>{const e=Math.floor(s/60),t=s%60;return e?`${e}m ${t}s`:`${t}s`}),[s]),p=n.useRef();return n.useEffect((()=>(t&&(a(0),clearInterval(p.current),p.current=setInterval((()=>{a((e=>e+1))}),1e3)),()=>{clearInterval(p.current)})),[t]),n.useEffect((()=>{clearInterval(p.current)}),[r]),ne.exports.jsxs(Sr,{sx:{mt:20,pt:20,display:"flex",justifyContent:"space-between",alignItems:"center",typography:"body2",color:"text.secondary",border:"solid 1px transparent",borderTopColor:"border.main"},children:[ne.exports.jsxs(Sr,{children:[ne.exports.jsx(e.Trans,{id:"Transaction Time:"}),d]}),ne.exports.jsxs(In,{sx:{display:"flex",alignItems:"center",cursor:"pointer"},component:"a",href:c,target:"_blank",rel:"noopener noreferrer",children:[ne.exports.jsx(e.Trans,{id:"Tx"}),ne.exports.jsx(Sr,{component:i.ArrowTopRightBorder,sx:{width:16,height:16,ml:6}})]})]})}function hg(t){var{children:r}=t,n=fa(t,["children"]);const{ctxVal:o,showing:i,closeShowing:s,showingDone:a,errorMessage:c,transactionTx:u}=ng(n),d=l.useDispatch();return ne.exports.jsxs(ig.Provider,{value:o,children:[r,ne.exports.jsx(Pm,{open:!!i,onClose:s,children:ne.exports.jsxs(Sr,{sx:{display:"flex",flexDirection:"column",justifyContent:"space-between",px:20,pb:20,flex:1,overflowY:"auto"},children:[ne.exports.jsxs(Sr,{children:[ne.exports.jsx(Sr,{sx:{textAlign:"center",pt:60},children:ne.exports.jsx(ug,{showingDone:a,errorMessage:c})}),c?ne.exports.jsxs(Sr,{sx:{textAlign:"center",mt:60},children:[ne.exports.jsx(Sr,{children:ne.exports.jsx(e.Trans,{id:"Something went wrong."})}),ne.exports.jsx(Sr,{sx:{color:"text.secondary",mt:12,typography:"body2",wordBreak:"break-all"},children:c})]}):ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(dg,{showingDone:a,showing:i}),ne.exports.jsx(pg,{isStarted:!!i,isEnded:a,tx:u})]})]}),ne.exports.jsx(xn,{fullWidth:!0,size:xn.Size.big,onClick:()=>{d(tg({contractStatus:wh.Initial})),s()},sx:{mt:20},children:c?ne.exports.jsx(e.Trans,{id:"Dismiss"}):ne.exports.jsx(e.Trans,{id:"Close"})})]})})]})}const fg=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_SLIPPAGE",payload:e})}));function mg({width:e,height:t,feeRate:r,rebateTo:o,colorMode:i,apikey:s,defaultChainId:a,defaultToToken:c,defaultFromToken:u,jsonRpcUrlMap:d}){const p=l.useDispatch();n.useEffect((()=>{i&&p((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_COLOR_MODE",payload:e})})))(i))}),[i]),n.useEffect((()=>{var e;a&&p((e=a,t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_CHAIN_ID",payload:e})}))))}),[a]),n.useEffect((()=>{p(tg({height:t}))}),[t]),n.useEffect((()=>{p(tg({width:e}))}),[e]),n.useEffect((()=>{s&&p(tg({apikey:s}))}),[s]),n.useEffect((()=>{r&&p(tg({feeRate:r}))}),[r]),n.useEffect((()=>{o&&p(tg({rebateTo:o}))}),[o]),n.useEffect((()=>{u&&p((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_DEFAULT_FROM_TOKEN",payload:e})})))(u))}),[u]),n.useEffect((()=>{c&&p((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_DEFAULT_TO_TOKEN",payload:e})})))(c))}),[c]),n.useEffect((()=>{d&&p(tg({jsonRpcUrlMap:d}))}),[d])}const gg="https://api.dodoex.io/cross-chain/widget",yg=`${gg}/routes`,bg=`${gg}/transaction/encode`,xg=`${gg}/order/create`;function vg({refetch:e,interval:t}){let r;n.useEffect((()=>(e(),clearTimeout(r),r=setInterval((()=>{e()}),null!=t?t:15e3),()=>clearTimeout(r))),[e])}function wg({fromToken:e,toToken:t,chainId:r}){const[o,i]=n.useState(!1),{apikey:s}=l.useSelector(Uh),[a,c]=n.useState(""),[u,d]=n.useState(""),p=n.useCallback((()=>{if(!r||!e||!t)return;i(!0);const n=[e,t];O.default.post("https://api.dodoex.io/frontend-price-api/current/batch",{networks:n.map((()=>(e=>ca[e]||ca[ia.MAINNET])(r))),addresses:n.map((e=>e.address)),symbols:n.map((e=>e.symbol)),isCache:!0},{headers:{apikey:s}}).then((r=>{var n;i(!1);const o=null===(n=r.data)||void 0===n?void 0:n.data;o&&(c(o.find((t=>t.address===e.address)).price),d(o.find((e=>e.address===t.address)).price))})).catch((e=>{i(!1),console.error(e)}))}),[r,e,t,s]);return vg({refetch:p}),{loading:o,refetch:p,toFiatPrice:u,fromFiatPrice:a}}const Eg=e=>(null!=e?e:Th.getState()).settings.slippage,Ag=e=>(null!=e?e:Th.getState()).settings.ddl,Cg="0x0000000000000000000000000000000000000000";var kg;function Rg({toToken:e,fromToken:t,fromAmount:r,toAmount:o,marginAmount:i}){const{account:s,chainId:a,provider:c}=u.useWeb3React(),d=l.useSelector(Sh),p=n.useMemo((()=>a||d),[a,d]),h=l.useSelector(Eg)||3,f=l.useSelector(Ag)||20,{feeRate:m,rebateTo:g,apikey:b,isReverseRouting:v}=l.useSelector(Uh),w=n.useMemo((()=>Math.floor(Date.now()/1e3)+60*f),[f]),[E,A]=n.useState(kg.Initial),[C,k]=n.useState(null),[R,T]=n.useState(""),[S,N]=n.useState(null),[M,F]=n.useState(null),[I,j]=n.useState(null),[D,B]=n.useState(y.BigNumber.from(0)),[P,W]=n.useState(null),[_,U]=n.useState(null),[L,V]=n.useState(""),[Z,H]=n.useState(""),[z,Y]=n.useState(""),[G,X]=n.useState(0),J=n.useCallback((()=>ma(this,void 0,void 0,(function*(){if(!p||!t||!e||t.chainId!==e.chainId)return void A(kg.Initial);if(!v&&!r)return;if(v&&!o)return;A(kg.Loading);const n={chainId:p,deadLine:w,apikey:b,slippage:h,source:"dodoV2AndMixWasm",toTokenAddress:e.address,toTokenDecimals:e.decimals,fromTokenAddress:t.address,fromTokenDecimals:t.decimals,userAddr:s||Cg};v?n.toAmount=y.parseFixed(String(o||1),e.decimals).toString():n.fromAmount=y.parseFixed(String(r||1),t.decimals).toString(),g&&m&&(n.rebateTo=g,n.fee=m);try{const e=(yield O.default.get("https://api.dodoex.io/route-service/v2/widget/getdodoroute",{params:n})).data.data;if((null==e?void 0:e.resAmount)?(A(kg.Success),k(e.resAmount),j(e.priceImpact),W(e.resPricePerFromToken),U(e.resPricePerToToken),N(e.baseFeeAmount),F(e.additionalFeeAmount),V(e.to),H(e.data),T(e.value),Y(e.useSource),X(e.duration)):A(kg.Failed),!s||!c)return;const t=yield qm({from:s,to:e.to,value:e.value,data:e.data},c);t&&B(t)}catch(e){A(kg.Failed),console.error(e)}}))),[w,s,p,e,m,h,g,t,c,r,o,b,v]);vg({refetch:J});const q=n.useMemo((()=>{const e=v?o:r;return E!==kg.Loading&&e?C:null}),[E,v,o,r,C]),Q=function(){const{chainId:e,account:t}=u.useWeb3React(),r=sg(),o=n.useCallback((({to:e,data:n,useSource:o,duration:i,ddl:s,gasLimit:a,subtitle:l,value:c})=>{const u=60*s,d=c;o&&"weth"!==o.toLowerCase()&&a&&a.lt(3e4)&&console.debug("Warning: GasLimit less than the minimum!");const p={from:t,to:e,data:n,value:d,route:o,duration:i,ddlSecRel:u,gasLimit:a};r.execute(x.i18n._("Swap"),Object.assign({opcode:Km.TX},p),l)}),[t,e]);return o}(),K=n.useCallback((e=>{t&&(v?C:r)&&Q({to:L,data:Z,useSource:z,duration:G,ddl:f,value:R,subtitle:e})}),[L,f,Z,G,z,t,r,D,C,R,v]);return{status:E,refetch:J,priceImpact:I,executeSwap:K,baseFeeAmount:S,resAmount:q,additionalFeeAmount:M,resPricePerToToken:_,resPricePerFromToken:P}}!function(e){e.Initial="Initial",e.Loading="Loading",e.Failed="Failed",e.Success="Success"}(kg||(kg={}));function Tg(e){Oh(e),qf(),Qf();const{provider:t,connector:r}=u.useWeb3React(),o=l.useDispatch();n.useEffect((()=>{o(rg(!0));(()=>{ma(this,void 0,void 0,(function*(){const t=e.defaultChainId;try{(null==r?void 0:r.connectEagerly)?yield r.connectEagerly(t):yield r.activate(t)}finally{o(rg(!1))}}))})()}),[r]),n.useEffect((()=>{const e=null==t?void 0:t.provider;e&&e.once&&e.on("chainChanged",(()=>ma(this,void 0,void 0,(function*(){o(rg(!0));try{(null==r?void 0:r.connectEagerly)?yield r.connectEagerly():yield r.activate()}finally{o(rg(!1))}}))))}),[t]);const i=e.width||375,s=e.height||494;return mg(Object.assign(Object.assign({},e),{width:i,height:s})),ne.exports.jsx(Sr,{sx:{width:i,height:s,overflow:"hidden",position:"relative",display:"flex",flexDirection:"column",minWidth:335,minHeight:494,borderRadius:16,backgroundColor:"background.paper"},className:"dodo-widget-container",children:ne.exports.jsx(hg,{...e,children:e.children})})}function Sg(e){const t=function(e){for(var t=void 0===e?{}:e,n=t.mode,o=void 0===n?"light":n,i=t.lang,s=t.theme,a=[],l=1;l<arguments.length;l++)a[l-1]=arguments[l];var c=Kr(o,s,i);return yr(c=a.reduce((function(e,t){return r.merge(e,t)}),c))}({mode:e.colorMode,theme:e.theme,lang:e.locale||"en-US"}),o=n.useMemo((()=>e.defaultChainId||1),[e.defaultChainId]),i=mh({provider:e.provider,jsonRpcUrlMap:e.jsonRpcUrlMap,defaultChainId:o}),s=`${i.length}+${e.jsonRpcUrlMap?Object.entries(e.jsonRpcUrlMap):""}+${e.defaultChainId}+${o}`;return ne.exports.jsx(l.Provider,{store:Th,children:ne.exports.jsx(zm,{locale:e.locale,children:ne.exports.jsx(Hr,{theme:t,children:ne.exports.jsxs(u.Web3ReactProvider,{connectors:i,lookupENS:!1,children:[ne.exports.jsx(rn,{container:".dodo-widget-container"}),ne.exports.jsx(Tg,{...e})]},s)})})})}function Ng({chainId:t,open:r,onClose:o}){var i,s;const a=kr(),[l,c]=n.useState(!1),{chainId:d}=u.useWeb3React(),[p,h]=n.useState("1"===localStorage.getItem("DODO_WIDGET_AUTO_SWITCH_NETWORK")),f=Vm(t);n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){if(r)if(d&&t&&t!==d&&f){if(p)return yield f(),void o();c(!0)}else o();else l&&c(!1)}))})()}),[r]);const m=t&&null!==(s=null===(i=Om[t])||void 0===i?void 0:i.name)&&void 0!==s?s:"";return ne.exports.jsx(Mi,{open:l,onClose:o,container:document.querySelector(".dodo-widget-container"),children:ne.exports.jsxs(Sr,{sx:{backgroundColor:"background.paper",display:"flex",width:"100%",flexDirection:"column",justifyContent:"center",alignItems:"center",p:a.spacing(20,16),gap:20,borderRadius:a.spacing(16,16,0,0),outline:0},children:[ne.exports.jsxs(Sr,{sx:{typography:"caption",textAlign:"center"},children:[ne.exports.jsx(e.Trans,{id:"This token is on"})," ",m,ne.exports.jsx(e.Trans,{id:"."}),ne.exports.jsx("br",{}),ne.exports.jsx(e.Trans,{id:"Are you sure swapping to another chain?"})]}),ne.exports.jsxs(Sr,{component:"label",sx:{display:"flex",alignItems:"center",gap:8,typography:"h6",cursor:"pointer"},children:[ne.exports.jsx(Fi,{sx:{top:-1},checked:p,onChange:e=>{const{checked:t}=e.target;var r;r=t,localStorage.setItem("DODO_WIDGET_AUTO_SWITCH_NETWORK",r?"1":"0"),h(t)}}),ne.exports.jsx(e.Trans,{id:"Auto switch network"})]}),ne.exports.jsxs(Sr,{sx:{display:"grid",width:"100%",gridTemplateColumns:"repeat(2, 1fr)",gap:8},children:[ne.exports.jsx(xn,{variant:xn.Variant.second,onClick:o,children:ne.exports.jsx(e.Trans,{id:"Cancel"})}),ne.exports.jsx(xn,{variant:xn.Variant.outlined,onClick:()=>ma(this,void 0,void 0,(function*(){f&&(yield f()),o()})),children:ne.exports.jsx(e.Trans,{id:"Confirm"})})]})]})})}function Mg({sx:e,amt:t,token:r,readOnly:o,showMaxBtn:i,onMaxClick:s,fiatPriceTxt:a,occupiedAddrs:l,onInputFocus:c,onTokenClick:u,onInputChange:d,onTokenChange:p,side:h,showChainLogo:f,onlyCurrentChain:m,defaultLoadBalance:g}){const[y,b]=n.useState(!1),x=kr(),v=_h(),[w,E]=n.useState(!1),A=r?v(r):null;return n.useEffect((()=>{r&&m&&b(!0)}),[r,m]),ne.exports.jsxs(Sr,{sx:Object.assign({width:"100%",minHeight:133,padding:20,borderRadius:12,overflow:"hidden",display:"flex",flexDirection:"column",justifyContent:"space-between",backgroundColor:x.palette.background.input},e),children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[ne.exports.jsx(jm,{token:r,showChainLogo:f,onClick:()=>E(!0)}),ne.exports.jsx(Dm,{balance:A,onClick:s,showMaxBtn:i,address:null==r?void 0:r.address,decimals:null==r?void 0:r.decimals})]}),ne.exports.jsx(Bm,{value:t,onFocus:c,onChange:d,readOnly:o,withClear:!0}),ne.exports.jsx(Sr,{sx:{mt:4,typography:"body2",color:x.palette.text.secondary},children:a}),ne.exports.jsx(Lm,{value:r,open:w,side:h,occupiedAddrs:l,defaultLoadBalance:g,onClose:()=>{E(!1),u&&u()},onTokenChange:(e,t)=>{E(!1),setTimeout((()=>{p(e,t)}),300)}}),ne.exports.jsx(Ng,{chainId:null==r?void 0:r.chainId,open:y,onClose:()=>b(!1)})]})}function Fg(e){const{width:t}=l.useSelector(Uh),r=n.useMemo((()=>{let e="";return"number"==typeof t?e=`${t}px`:t&&(e=t),e?`calc(${e} - 40px)`:"auto"}),[t]);return ne.exports.jsx(di,{container:document.querySelector(".dodo-widget-container"),maxWidth:r,...e})}function Og({onClick:e}){const t=kr();return ne.exports.jsx(In,{sx:{width:"100%",position:"relative"},onClick:e,children:ne.exports.jsx(Sr,{component:wn,sx:{width:36,height:36,borderRadius:"50%",backgroundColor:t.palette.background.input,border:`4px solid ${t.palette.background.paper}`,display:"flex",alignItems:"center",justifyContent:"center",position:"absolute",left:"50%",top:"50%",transform:"translate(-50%, -50%) rotate(-90deg)"},children:ne.exports.jsx(Sr,{component:i.ArrowBack,sx:{width:18,color:"text.secondary"}})})})}function Ig({open:t,execute:r,onClose:o,toToken:s,fromToken:a,fromAmount:c,toAmount:u,priceImpact:d,clearFromAmt:p,clearToAmt:h,baseFeeAmount:f,curToFiatPrice:m,curFromFiatPrice:g,pricePerFromToken:y,additionalFeeAmount:b}){var x,v;const w=kr(),E=l.useSelector(Eg),A=l.useDispatch(),{contractStatus:C}=l.useSelector(Uh),R=n.useMemo((()=>new k.default(d).gt(15)),[d]),[T,S]=n.useState(!1),[N,M]=n.useState(!1);return n.useEffect((()=>{C!==wh.Pending&&o(),C===wh.TxSuccess&&(h(),p())}),[C]),n.useEffect((()=>{S(!1)}),[m]),ne.exports.jsx(Pm,{open:t,onClose:()=>{A(tg({contractStatus:wh.Initial})),o()},title:ne.exports.jsx(e.Trans,{id:"Swap summary"}),children:ne.exports.jsxs(Sr,{sx:{margin:20,display:"flex",height:"100%",flexDirection:"column",borderTop:`1px solid ${w.palette.border.main}`},children:[ne.exports.jsxs(Sr,{sx:{py:20,display:"flex",typography:"body2",alignItems:"center",justifyContent:"center",flexDirection:"column",borderBottom:`1px solid ${w.palette.border.main}`},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsxs(Sr,{children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:[ne.exports.jsx(Im,{width:16,height:16,url:null==a?void 0:a.logoURI,address:null!==(x=null==a?void 0:a.address)&&void 0!==x?x:"",marginRight:6}),ne.exports.jsx(Sr,{children:`${us({input:c,decimals:null==a?void 0:a.decimals})} ${null==a?void 0:a.symbol}`})]}),ne.exports.jsx(Sr,{sx:{mt:4,typography:"h6",color:w.palette.text.secondary},children:g?`$${cs({input:g,showDecimals:1})}`:"-"})]}),ne.exports.jsx(Sr,{sx:{width:16,mx:16},component:i.DoubleRight}),ne.exports.jsxs(Sr,{children:[ne.exports.jsxs(Sr,{sx:{display:"flex"},children:[ne.exports.jsx(Im,{width:16,height:16,marginRight:6,url:null==s?void 0:s.logoURI,address:null!==(v=null==s?void 0:s.address)&&void 0!==v?v:""}),ne.exports.jsx(Sr,{children:`${us({input:u,decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsx(Sr,{sx:{typography:"h6",mt:4,color:w.palette.text.secondary},children:m?`$${cs({input:m,showDecimals:1})}(${d}%)`:"-"})]})]}),ne.exports.jsx(Sr,{sx:{mt:12,typography:"h6"},children:`1 ${null==a?void 0:a.symbol} = ${us({input:new k.default(u).dividedBy(new k.default(c)),decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsxs(Sr,{sx:{py:15,typography:"body2",borderBottom:`1px solid ${w.palette.border.main}`},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",color:w.palette.text.secondary},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Sr,{sx:{width:16,mr:7},component:i.DetailBorder}),ne.exports.jsx(e.Trans,{id:"Swap Detail"})]}),ne.exports.jsx(Sr,{component:wn,children:ne.exports.jsx(Sr,{onClick:()=>M(!N),sx:{width:10,color:"text.secondary",transform:N?"rotateX(0deg)":"rotateX(180deg)"},component:i.CaretUp})})]}),ne.exports.jsxs(Sr,{sx:{mt:16,display:N?"initial":"none"},children:[ne.exports.jsxs(Sr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Basic Fee"}),ne.exports.jsx(Fg,{title:ne.exports.jsx(e.Trans,{id:"Estimated service provider fees"}),ml:5})]}),ne.exports.jsx(Sr,{children:`${us({input:f,decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsxs(Sr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Additional Fee"}),ne.exports.jsx(Fg,{title:ne.exports.jsx(e.Trans,{id:"Additional routing fees set by the Widget user"}),ml:5})]}),ne.exports.jsx(Sr,{children:`${us({input:b,decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsxs(Sr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Price Impact"}),ne.exports.jsx(Fg,{title:ne.exports.jsx(e.Trans,{id:"Due to the market condition, market price and estimated price may have a slight difference"}),ml:5})]}),ne.exports.jsx(Sr,{children:`${d}%`})]}),ne.exports.jsxs(Sr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Slippage"}),ne.exports.jsx(Fg,{title:ne.exports.jsx(e.Trans,{id:"High slippage tolerance will increase the success rate of transaction, but might not get the best quote."}),ml:5})]}),ne.exports.jsx(Sr,{children:E})]})]})]}),ne.exports.jsx(Sr,{sx:{flex:1}}),R&&ne.exports.jsxs(Sr,{sx:{mb:14,display:"flex",cursor:"pointer",justifyContent:"center",alignItems:"center",typography:"h6"},onClick:()=>S(!T),children:[ne.exports.jsx(Sr,{sx:{mr:4,width:18,height:18,alignItems:"center"},children:T?ne.exports.jsx(Sr,{sx:{width:"100%",height:"100%",borderRadius:4,display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"secondary.main"},children:ne.exports.jsx(Sr,{component:i.Done,sx:{width:14,color:"#1a1a1b"}})}):ne.exports.jsx(Sr,{sx:{width:"100%",height:"100%",borderRadius:4,border:`1px solid ${w.palette.text.secondary}`}})}),ne.exports.jsx(Sr,{children:ne.exports.jsx(e.Trans,{components:{0:ne.exports.jsx(Sr,{component:"span",sx:{color:"error.main"}})},values:{priceImpact:d},id:"Price impact reaches <0>{priceImpact}</0>%, accept the quote"})})]}),ne.exports.jsx(xn,{isLoading:C==wh.Pending,disabled:R&&!T,fullWidth:!0,onClick:()=>{r(),A(tg({contractStatus:wh.Pending}))},children:C==wh.Pending?ne.exports.jsx(e.Trans,{id:"Confirming"}):ne.exports.jsx(e.Trans,{id:"Confirm swap"})})]})})}function jg(e){var{sx:r,maxVal:n,decimals:o=2,onInputChange:i}=e,s=fa(e,["sx","maxVal","decimals","onInputChange"]);return kr(),ne.exports.jsx(On,{...s,onChange:e=>{const r=0===e.target.value.length?null:hs(e.target.value,o),s=n&&r&&new t.BigNumber(r).gt(n)?n.toString():r;console.log("finalVal:",s),i&&i(s)}})}function Dg({open:t,onClose:r,isBridge:o}){const i=kr(),s=l.useDispatch(),a=l.useSelector(Eg),c=l.useSelector(Ag),u=n.useMemo((()=>Number(a)>=50),[a]),d=o?.5:3;return ne.exports.jsx(Pm,{open:t,onClose:r,title:ne.exports.jsx(e.Trans,{id:"Settings"}),children:ne.exports.jsxs(Sr,{sx:{mx:20},children:[ne.exports.jsxs(Sr,{sx:{py:20,borderTop:`1px solid ${i.palette.border.main}`},children:[ne.exports.jsxs(Sr,{sx:{mb:16,display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Slippage Tolerance"}),ne.exports.jsx(Fg,{title:ne.exports.jsx(e.Trans,{id:"Attention: High slippage tolerance will increase the success rate of transaction, but might not get the best quote."}),ml:7})]}),ne.exports.jsxs(Sr,{sx:{display:"flex",flexDirection:"column"},children:[ne.exports.jsx(jg,{fullWidth:!0,maxVal:100,value:a,placeholder:d.toString(),onInputChange:e=>{s(fg(e))},suffix:ne.exports.jsx(Sr,{sx:{color:"text.disabled"},children:"%"}),height:36}),u&&ne.exports.jsx(Sr,{sx:{typography:"h6",mt:6,color:"error.main"},children:ne.exports.jsx(e.Trans,{id:"Maximum slippage do not exceed 50%"})})]})]}),o?"":ne.exports.jsxs(Sr,{sx:{py:20,borderTop:`1px solid ${i.palette.border.main}`},children:[ne.exports.jsxs(Sr,{sx:{mb:16,display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Transaction Deadline"}),ne.exports.jsx(Fg,{title:ne.exports.jsx(e.Trans,{id:"If your transaction time exceeds the deadline, your transaction will be rescinded."}),ml:7})]}),ne.exports.jsx(jg,{value:c,fullWidth:!0,height:36,placeholder:x.i18n._("{DEFAULT_SWAP_DDL} minutes",{DEFAULT_SWAP_DDL:20}),onInputChange:e=>{s((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_TRANSACTION_DDL",payload:e})})))(e?Math.max(Number(e),1):""))}})]})]})})}function Bg({toToken:t,fromToken:r,priceStatus:o,pricePerToToken:s,pricePerFromToken:a}){const[l,c]=n.useState("-"),[u,d]=n.useState(null),[p,h]=n.useState("-"),[f,m]=n.useState(null);n.useEffect((()=>{c(null==r?void 0:r.symbol),h(null==t?void 0:t.symbol),d(s),m(a)}),[r,t,s,a]);const g=n.useCallback((()=>{c(p),h(l),d(f),m(u)}),[l,u,p,f]);return ne.exports.jsx(Sr,{sx:{display:"flex",justifyContent:"center",alignItems:"center"},children:{[kg.Initial]:"-",[kg.Loading]:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Dn,{sx:{mr:5}}),ne.exports.jsx(e.Trans,{id:"Fetching best price..."})]}),[kg.Failed]:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Sr,{component:i.Warn,sx:{width:15,mr:5,color:"warning.main"}}),ne.exports.jsx(e.Trans,{id:"Quote not available"})]}),[kg.Success]:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Sr,{sx:{typography:"body2"},children:`1 ${l} = ${cs({input:f,showDecimals:4})} ${p}`}),ne.exports.jsx(Sr,{component:wn,sx:{width:18,height:18,ml:6,borderRadius:"50%",backgroundColor:"border.main",display:"flex",justifyContent:"center",alignItems:"center"},children:ne.exports.jsx(Sr,{sx:{width:16,color:"text.secondary"},onClick:g,component:i.Switch})})]})}[o]})}function Pg({open:t,onClose:r}){const n=l.useSelector(Uh).defaultChainId;return ne.exports.jsx(Pm,{title:ne.exports.jsx(e.Trans,{id:"Connect to your wallet"}),open:t,onClose:r,children:ne.exports.jsx(Sr,{sx:{mx:20,pb:20,border:"1px solid transparent",borderTopColor:"border.main"},children:Object.values(hh).map((t=>ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",flexDirection:"column",mt:20,p:20,backgroundColor:"background.tag",borderRadius:12,cursor:"pointer","&:hover":{backgroundColor:"hover.default"}},onClick:()=>{!function(e,t,r){var n;const o=fh[e];if(!o)throw new Error(`Unknown wallet type: ${e}`);const[i]=o;null===(n=i.activate(t))||void 0===n||n.catch((e=>{4001!==e.code?r(e):i.connectEagerly?i.connectEagerly(t):i.activate(t)}))}(t.type,n,(e=>{console.error(e)}))},children:[ne.exports.jsx(Sr,{component:t.icon,sx:{width:32,height:32}}),ne.exports.jsx(Sr,{sx:{mt:8,typography:"caption"},children:t.name}),ne.exports.jsx(Sr,{sx:{mt:4,typography:"body2",color:"text.secondary"},children:ne.exports.jsx(e.Trans,{id:"Connect to your {0} Wallet",values:{0:t.name}})})]},t.type)))})})}function Wg(){const{connector:t}=u.useWeb3React(),[r,o]=n.useState(!1);return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(xn,{size:xn.Size.middle,fullWidth:!0,onClick:()=>{t.deactivate?t.deactivate():t.resetState(),o(!0)},"data-testid":"connect-wallet-btn",children:ne.exports.jsx(e.Trans,{id:"Connect to a wallet"})}),ne.exports.jsx(Pg,{open:r,onClose:()=>o(!1)})]})}var _g,Ug;function Lg({chainId:e,account:t,token:r,proxyContractAddress:o}){const[i,s]=n.useState(!1),[a,c]=n.useState(!1),[u,d]=n.useState(null),p=l.useSelector(Uh).jsonRpcUrlMap,h=l.useSelector(Nh),f=n.useCallback((()=>ma(this,void 0,void 0,(function*(){if(!t||!e||!r)return;s(!0);const n=Object.assign(Object.assign({},sa),p)[e],i=new nh(null==n?void 0:n[0]);try{const n=yield function({account:e,tokenAddress:t,tokenDecimals:r,chainId:n,approveAddress:o,provider:i}){return ma(this,void 0,void 0,(function*(){if(!e||!t)return;const s=Zh[n],{DODO_APPROVE:a}=s,l=null!=o?o:a,c=new b.Contract(t,$f,i),u=yield c.allowance(e,l),d=new k.default(10).pow(r);return new k.default(u.toString()).div(d)}))}({account:t,chainId:e,tokenAddress:r.address,tokenDecimals:r.decimals,approveAddress:o,provider:i});c(!1),d(null!=n?n:null)}catch(e){console.error(e),c(!0)}finally{s(!1)}}))),[e,r,p,o,t]);return n.useEffect((()=>{f()}),[f,h]),{allowance:u,loading:i,error:a,refetch:f}}!function(e){e.All="all"}(_g||(_g={})),function(e){e.Loading="Loading",e.Insufficient="ApprovalInsufficient",e.Approving="Approving",e.Sufficient="Sufficient",e.Unchecked="Unchecked"}(Ug||(Ug={}));const Vg=({account:e,chainId:t,offset:r,contractAddress:o})=>{var i;const s=l.useSelector(Sh),a=n.useMemo((()=>{var e;return Zh[null!==(e=t)&&void 0!==e?e:s]}),[t]),{isETH:c}=n.useMemo((()=>ha(t)),[t]),{DODO_APPROVE:d}=a||{},p=null!==(i=null!=o?o:d)&&void 0!==i?i:null,h=function(e){const{account:t}=u.useWeb3React(),r=l.useSelector(Sh),o=l.useSelector(jh),i=n.useMemo((()=>la[r]),[r]),s=n.useMemo((()=>Zh[r]),[r]),a=n.useCallback((r=>{var n;if(!t||!e)return null;if(r.symbol===i.symbol&&da(r.address,i.address))return new k.default(eg);const{DODO_APPROVE:a}=s||{};if(e!==a)return null;const l=null===(n=null==o?void 0:o[r.address.toLowerCase()])||void 0===n?void 0:n.tokenAllowances;return null!=l?l:null}),[t,e,i.symbol,i.address,o,s]);return a}(p),[f,m]=n.useState(),{allowance:g}=Lg({chainId:t,account:e,token:f,proxyContractAddress:p}),y=_h(),{runningRequests:b}=og(),v=l.useSelector(Wh),w=n.useMemo((()=>{var e;return null===(e=la[null!=t?t:s])||void 0===e?void 0:e.address}),[t]),E=n.useCallback(((t,n,o)=>{if(!t)return Ug.Loading;const i=!!(null==b?void 0:b.find((e=>e.spec.opcode===Km.Approval&&e.spec.token.address===(null==t?void 0:t.address)))),s=null!=o?o:t?y(t):null;let a=t?h(t):null;const l=new k.default(null!=n?n:0);if(!e)return Ug.Unchecked;if(!s||l.minus(null!=r?r:0).gt(s))return Ug.Unchecked;if(l.isZero())return Ug.Unchecked;return t.address===w?Ug.Sufficient:i?Ug.Approving:((null==f?void 0:f.address)===t.address&&g&&(a=g),a?a&&l.minus(null!=r?r:0).gt(a)?Ug.Insufficient:Ug.Sufficient:(p===d||f&&f.address===t.address||m(t),Ug.Loading))}),[y,h,e,r,p,t,v,b,w,f,null==g?void 0:g.toString()]),A=n.useCallback((e=>{const t=e?h(e):null;return("USDT"===(null==e?void 0:e.symbol)||(null==e?void 0:e.address.toLowerCase())==="0x6426e6017968377529487E0ef0aA4E7759724e05".toLowerCase())&&null!==t&&t.gt(0)}),[h]),C=sg(),R=l.useDispatch(),T=n.useCallback(((t,r)=>ma(void 0,void 0,void 0,(function*(){if(!p||!e||!t)return;const n=(e=>{let t=e.symbol;return t.indexOf("DLP_")>-1&&(t=t.replace("DLP_","")),t.indexOf("DLP")>-1&&(t=t.replace("DLP","LP")),t})(t),o=r?new k.default(0):void 0,i=r?x.i18n._("Reset"):x.i18n._("Approve");var s;(yield C.execute(`${i} ${n}`,{opcode:Km.Approval,token:t,contract:p,amt:o}))===Gm.Success&&R((s=null!=o?o:eg,e=>ma(void 0,void 0,void 0,(function*(){e({type:"SET_ACCOUNT_ALLOWANCES",payload:s})}))))}))),[p,e,t,C,R]),S=n.useCallback((e=>{const t=new k.default(0);if(!e)return t.toString();const r=y(e);if(!r)return t.toString();let n=r;const o=c?.1:.02;return w===(null==e?void 0:e.address)&&(n=r.gt(o)?r.minus(o):t),n.toString()}),[t,y,c]);return{getApprovalState:E,getPendingRest:A,getMaxBalance:S,submitApprove:T}};var Zg;!function(e){e.Initial="Initial",e.Loading="Loading",e.Failed="Failed",e.Success="Success"}(Zg||(Zg={}));const Hg=[{id:"cBridge",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2234%22%20height%3D%2234%22%20viewBox%3D%220%200%2034%2034%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Crect%20x%3D%221%22%20y%3D%221%22%20width%3D%2232%22%20height%3D%2232%22%20rx%3D%228%22%20fill%3D%22white%22%20stroke%3D%22%2333363F%22%2F%3E%3Cg%20clip-path%3D%22url%28%23clip0_37_1169%29%22%3E%3Cpath%20d%3D%22M10.9221%2022C13.0882%2022%2014.8442%2021.2006%2014.8442%2020.2144C14.8442%2019.2283%2013.0882%2018.4288%2010.9221%2018.4288C8.75599%2018.4288%207%2019.2283%207%2020.2144C7%2021.2006%208.75599%2022%2010.9221%2022Z%22%20fill%3D%22%23444444%22%2F%3E%3Cpath%20d%3D%22M23.5587%2022C25.7248%2022%2027.4808%2021.2006%2027.4808%2020.2144C27.4808%2019.2283%2025.7248%2018.4288%2023.5587%2018.4288C21.3926%2018.4288%2019.6366%2019.2283%2019.6366%2020.2144C19.6366%2021.2006%2021.3926%2022%2023.5587%2022Z%22%20fill%3D%22%23DDDDDD%22%2F%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M9.88456%2020.2144C9.84901%2020.2146%209.81379%2020.2076%209.78098%2020.1939C9.74818%2020.1802%209.71844%2020.1601%209.69353%2020.1347C9.66862%2020.1094%209.64903%2020.0793%209.63593%2020.0462C9.62283%2020.0132%209.61648%2019.9779%209.61725%2019.9423C9.7509%2015.5317%2013.1124%2012%2017.2394%2012C21.3663%2012%2024.7278%2015.5317%2024.8615%2019.9423C24.8622%2019.9779%2024.8559%2020.0132%2024.8428%2020.0462C24.8297%2020.0793%2024.8101%2020.1094%2024.7852%2020.1347C24.7603%2020.1601%2024.7306%2020.1802%2024.6977%2020.1939C24.6649%2020.2076%2024.6297%2020.2146%2024.5942%2020.2144H22.0874C22.0152%2020.2135%2021.946%2020.1848%2021.8943%2020.1344C21.8426%2020.0839%2021.8123%2020.0155%2021.8096%2019.9433C21.6894%2017.1106%2019.6894%2014.8567%2017.2403%2014.8567C14.7913%2014.8567%2012.7913%2017.1106%2012.6711%2019.9433C12.6684%2020.0155%2012.638%2020.0839%2012.5863%2020.1344C12.5346%2020.1848%2012.4655%2020.2135%2012.3932%2020.2144H9.88456Z%22%20fill%3D%22%23FF957E%22%2F%3E%3C%2Fg%3E%3Cdefs%3E%3CclipPath%20id%3D%22clip0_37_1169%22%3E%3Crect%20width%3D%2220.4808%22%20height%3D%2210%22%20fill%3D%22white%22%20transform%3D%22translate%287%2012%29%22%2F%3E%3C%2FclipPath%3E%3C%2Fdefs%3E%3C%2Fsvg%3E",name:"cBridge"},{id:"stargate",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2232%22%20height%3D%2232%22%20viewBox%3D%220%200%2032%2032%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M0.5%208C0.5%203.85786%203.85786%200.5%208%200.5H24C28.1421%200.5%2031.5%203.85786%2031.5%208V24C31.5%2028.1421%2028.1421%2031.5%2024%2031.5H8C3.85786%2031.5%200.5%2028.1421%200.5%2024V8Z%22%20fill%3D%22black%22%20stroke%3D%22black%22%2F%3E%3Cpath%20d%3D%22M17.5867%208.63649L18.0125%209.63382C18.8482%2011.592%2020.4079%2013.1518%2022.3662%2013.9875L23.3635%2014.4133C23.6245%2014.5246%2023.8365%2014.6842%2024%2014.8743C23.5033%2011.3132%2020.6868%208.49629%2017.1257%208C17.3154%208.16317%2017.4754%208.37546%2017.5867%208.63649Z%22%20fill%3D%22%23999999%22%2F%3E%3Cpath%20d%3D%22M8.63649%2014.4133L9.63382%2013.9875C11.592%2013.1518%2013.1518%2011.592%2013.9879%209.63382L14.4133%208.63649C14.525%208.37546%2014.6846%208.16317%2014.8743%208C11.3132%208.49629%208.49667%2011.3132%208%2014.8743C8.16357%2014.6842%208.37548%2014.5246%208.63649%2014.4133Z%22%20fill%3D%22%23999999%22%2F%3E%3Cpath%20d%3D%22M23.3635%2017.5863L22.3662%2018.0121C20.4079%2018.8479%2018.8482%2020.408%2018.0125%2022.3662L17.5867%2023.3632C17.4754%2023.6242%2017.3154%2023.8365%2017.1257%2024C20.6868%2023.5034%2023.5033%2020.6865%2024%2017.1253C23.8365%2017.3154%2023.6245%2017.475%2023.3635%2017.5863Z%22%20fill%3D%22%23999999%22%2F%3E%3Cpath%20d%3D%22M14.4133%2023.3632L13.9879%2022.3662C13.1518%2020.408%2011.592%2018.8479%209.63382%2018.0121L8.63649%2017.5863C8.37548%2017.475%208.16357%2017.3154%208%2017.1253C8.49667%2020.6865%2011.3132%2023.5034%2014.8743%2024C14.6846%2023.8365%2014.525%2023.6242%2014.4133%2023.3632Z%22%20fill%3D%22%23999999%22%2F%3E%3Cpath%20d%3D%22M12.3715%2015.2177L12.863%2015.0078C13.8278%2014.5959%2014.5966%2013.8275%2015.0086%2012.8626L15.2181%2012.3711C15.512%2011.6827%2016.4879%2011.6827%2016.7818%2012.3711L16.9913%2012.8626C17.4032%2013.8275%2018.172%2014.5959%2019.1369%2015.0078L19.6284%2015.2177C20.3168%2015.5116%2020.3168%2016.4872%2019.6284%2016.7811L19.1369%2016.991C18.172%2017.4029%2017.4032%2018.1713%2016.9913%2019.1366L16.7818%2019.6276C16.4879%2020.3161%2015.512%2020.3161%2015.2181%2019.6276L15.0086%2019.1366C14.5966%2018.1713%2013.8278%2017.4029%2012.863%2016.991L12.3715%2016.7811C11.6831%2016.4872%2011.6831%2015.5116%2012.3715%2015.2177Z%22%20fill%3D%22%23F2F2F2%22%2F%3E%3C%2Fsvg%3E",name:"Stargate"},{id:"connext",logoURI:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHgAAAB4CAYAAAA5ZDbSAAAAIGNIUk0AAHomAACAhAAA+gAAAIDoAAB1MAAA6mAAADqYAAAXcJy6UTwAAAAGYktHRAD/AP8A/6C9p5MAAAAJcEhZcwAAAWgAAAFoAHNUKykAABaOSURBVHja7Z1bcFvXee9/+4orARAkRFISSUmUJdm6WBJTJzJlWVFi59iWk8ZnJnXTKtPaqd3YTR565syJ3XamL2nShyR2O51e4nSauJ4kapLjdjrT9MiSIl/jiyRfKImURPEm8SLeQIAAiI299zoPAMGLKPEiEhuU8Z/5DyA9AN9aP35r7bXWtzckIYRgGZRIJHjttdc4deoUra2ttLa2MjAwwMjICIlEAsMwluNri1a6ruPz+SgvLycSibBlyxY2b97M7t272bt3Lz6fb3m+WCyhenp6xHe/+13R1NQkNE0TQMnzsKZpYu/eveJ73/ue6O3tXUokYkkAHzt2TDz44INCURTHO2ulW1EU8dBDD4njx487D/jIkSPi7rvvdrxTblU3NTWJo0ePFh5wT0+POHTokOMd8HHxwYMHRVdXV2EA/+QnPxGBQMDxRn/cHAwGxeHDh5cPcCqVEk8++aTjDf24+6mnnhLj4+NLCzgej4v77rvP8caVnPX+/ftFNBpdGsD9/f1i586djjeq5OnetWuX6O/vvznAo6OjYvfu3Y43puTZvX37djEyMrI4wKlUSuzfv9/xRpR8Yx84cOCGc/J1AT/xxBOOB1/y/Pz0008vDPDPfvYzx4MueWF+6aWX5gf48uXLpXXuCnQwGBQ9PT1zA/7Sl77keLAlL85f/vKXbwz4yJEjjgdZ8s155iHFNMBNTU2OB1jyzXnPnj2zAz527JjjwZW8ND5x4sS1gB988EHHAyt5aXzw4MHpgPv6+oSqqo4HVvLSWFVV0dfXJ4QQQgZ48cUXMU2Tkm4NmabJT3/6UwBkgJdfftnpmEpaYv3yl78EQBobGxPhcPhjV+V4q0vXdYaHh5Fff/31EtxbUIZh8OabbyKfPHnS6VhKWiadOnUKubW11ek4Slomtba2lgDfymppaUHu6+tzOo6Slkn9/f3I8Xjc6ThKWibFYjEkXddF6Sr61pTL5UIiu71V0i0q2ekASlpelQDf4lKdDmChckfWUbb+t1BknXjnKRK955wOqai1cgDLCtWffoyqpkN4QnWopowdG2Hg1Mt0vf73pGOl5d5sWjGAq+97ktqH/jfe8DoUE9QMqIFaAoEG3Ho5F499h1Ssx+kwi04K8JdOBzGXvPU7qP38/yFQtwPJEMgZgZLJvuqyi1DlNjTFS7TvA0xjzOlwi0or4iIrsGkPnkgDkgmyJZAtkCyQLcCw0RUf6+98jDvu/iaestVOh1tUWhFDtKK6UVCRzSxUJQc3Dzlj49b8bNz2GHJGcObtvyaV6L3p79UkD5u1/dQpd5KyRrhgvsFlu9np7lhY37EChmjVXUb4tn14/BHkjEA2QTGzoCde5YzAJbkIh7LD9cjAB2Qyix+uA0o19/v+lIOeZ9imfJbbuYc72EdQROgRraRJOt0t89KKAJwe6sRffQeBqh2oQkM2xTWAFXMSckVgG7riY2jo/UVBliWVT3l+ny94/5KIiOCy3PgtP1X2WjbSSESu5jJniTPidNfM3RanA5iPJEVHVX0oQkEyRX6Ynhiqp5qMjVvxc8fGx/nEtj/D56lZ8PdFlPVs1/8HQeHBNAELhAXChqAU4tP67/AVz19Qq2xyumvmVNFnsOIuY8ODf05N4++gK/589sqzZPDM4Tri34ZL9jM48gGGOf9TsxplC5/Uf5ewqIapIwQ2kppG12Ctq45KvZIuq4VRe9jpbrp+/1HEgBV3gHUPfJO6fX+M21OBbNjXhTr9/yRkE9zoRLzbcMlersY+nDfkgFzFdvU+qkTtJGBboCgmipZB0gxcumCtezWVegWd5gWiVnFCLlrAmj9M/QPfpPaeJ3G7w1m4N8jamYAVC6RMDrJnKy7Jx9X4RxjW3JAzYpw10hbukO5CmCDboMgWipZB0TLIWgbUNC4d1npqqHSV02lcJGoW35xclIA1fwX1Dz3D2nuewO0unzVzVQtUS0axpRlX1dLk+zxkF1Xurbjx0j/2Eek5IGdIMWYPEhG3UWevAwSyOglXUQ1kNZvJug61vmoq3SE6xi8RNaNOd980FR1g1R+m/uAzrLnnq7jdoemZOyVrVSFjp8awkjE0W0e11dz8PB1wdk4Gt3BRpW/FJXnpS344J+QRcYWr9iUirKdOWY/Q0nnIipoFPRVyna+KVZ4wXeNdDBvFk8lFBVj1lVP38LOzw52SpaotIxk2Fz/4J86d/lvcWjlh/20o1oxsnrpONsEjXFRrW1GFTk/qNIZ947XsIF30cYGwUk293oCkjSOpRhbuxHCtmkiqga4L6spWUe0N05HqYigddbo7gSICrPrKqfv8s6y5949wuULXvaDShIyUtmj74AXOvPPXDPS9zWi0lZB3PeXehizkmevj3HspB7lG3UbGStCdehcb64ZxDdJND+ep1CKsdzeANo6sTgA28+8lNY2mC+oCldT4y2kf62YoPep0txYHYNVXTu0XnmHN/idxuYLXvaDSbBnJMGl7/4c0v/1tEvEuAJLJHqKjLQTd6wh7GiYzecp8PfEHIpngE24qpPUMGm1czcxdNjwkeugRbVTqlazzrstmsWoga2ZuTs5msqwaaJqgLhimpizEpdhlhsZjjvat44BVf5ja336W1Z9+An02uLn3mi1DOgv3zG++QyLWOe1zEskeorFWQq56KlyTkNVZ/lCkjEQ5YcYyQ7SkXkFgzxnnkN1Lj9VORK9kva8OSTOQNSMLdiKbtexwremCumA5NYEgl2K9DKacg+woYC24itpHnqVm/1fR9Sxc+TrDMmmTS6df4OwscCc0lrrCSPwCIVcdla6G/Hp4tqHebUkMGd2cTx8jLRLzinfQ6uOK2U6lK8wGfx2Sms5dbGWHakU183OyptvUh8pZHSjjUqyfgaQz5cmOAdaCVaz54rPU7H8sD3facDoxvNoyGCbtJ1/g7FvfITHaecPPjY9fYThxnpBWR0TfiDrzwiu3TlYtaE2d4P3xl+ech6dq0LzK5Uwnq9xhNgTW5obrSciT7000zaY+HGR10E/bSD8DycKfVTsCWA2uYu0jz1K9/w/R9QByxs5n1tQMVm0Z2bBpf+8HnH3z2yRiXfP6/Hj6CsPJ8wTV1VRpm9AsCSm3+aGaEm4LusfPcmzsb+i3zi84/sHMAF3pTiKeIBsDq5FUAykHV8mDNpGUDLpuU18RpMLn5nTvZcaMdEH7uuCAFY+fNf/zGaoPfDULd+rV8tTMFVm4HSd/yNnX/2recCcUM65wNdmMZWUIyqsJSkHclgQmtKXe4lexb9Oc/tW85t/ZNGgM0pXqotITZGN5zeTyKZe9smqiqCaSaqLrgtqwH1m2ea2jo5DdXXjA1Qe/weoH/gTdXY5sWPltxZnrXNmw6Dj5z5x97VskFwh3QmOZfi4n36NvvJmeVDPtqXd5P/F/eX3sn2hJH8Pm5h5bMWgM05G8TMQbYFO4GknNICnmZBZrJrJqgZLB64GqgJuLw4N0Dhdu+VTQOxv8W5poeOoH+Ktvz2ZuhqzNyVfNkpHGTTrf/WfOvfotkqOLgzubZEnBFvOfb+erLaF1/Mn23+b+9duwlXQum438GllWTRTNxJbT/Oe5czz1b/9dqC4v3HmwJkHkM4/hiWxAzp3pzrRiy5DO0Pne0sMFlgUuQEu0g78780uO95xG1wSSYiIpFrJiISkWUm63xe2C7WvCrA54C9HlQAEBh2rW4dvwCVTFhWTaswMWcOWjf6Plte8sOdzl1rnhLn509ggd8V50jTzcScjZRga9ChtXrypYXAUDXFa7Bc1dniuckybB2tlXFZmx3gtcevsfSIy0F6wDllIXor28238+l8U5sLKFnLMkm+iaTUV5qGAxFayqUiurQJX0fGVk3rl/qxIMXPh/xAdaCtb4ZZFsZ8EymblTYUuShaxpBQunYIBNSyDb0qxDs2yBLIGVTiDsTMEav9SqD4W5a20tlmTkMnYCrJ0brm0yIsNIcrxgMRVsiI4PDyAZmfyQPHOIxoDqtfvxBdcVrPFLqRp/kEe3fYLbIhXYkoGkmNn5V54yVCs2o+lxzvcMFSyuggGOdrdAYvRawPk7FASR6ru4fefX8QfqC9YBS6FKr5/Hd+/lC7dvx5YyIE8OyxMXWYpqM24ZnOoe4nLfQMFiKxhgY7ibZHczjJvXGaqzS6fbbv8Ddjb+GWVl6wrWCTejiLeMJ3fv4/d2/BYel4SQzcn5Vp64yLKRFUH70Cg/fvMiFHAaKuhOlp1JU7l+L249dG3xugmyKVBtmUj5Tlyyn+HhjzCM6BJ8s0SttJVG6WHulD5DvXI7mqwxKgYXdNAwUxFvGX+0616+svOT+D0ytpRGVqzciZKZf6/rNkOpBP944hz/frq7UN0NFBhw8mob/vINhFZtR5P07F2Cs9Q0a0JhVXAXLrmMoZGPSGeii/5OGZWd8oM8Iv8Fn5P+mE8pD7FL28dG11Z8qocB+wpJsfCjvEpPGU/s2s+hOz+Fzy1jy+ncHrSFrGRfpdyJ0mg6xY/eauXvj7eQsRa3971YFXgvWpAYuEigYjOBQAOqrUxm8rRsFmi2TFVgFy7Zx2D0Q9KZxe3f3iEf4HeVb7NT7EVDQ6jj6LpgjWsNd3juxK95uWy2Ebfn//mV3jIe37mfr+zYg98jY8npHNQc4Fz2appNLJ3ix2+18PwrZ4ilCr9CKPhhQyY5TGqkk7Ly2yjz1WUPFsyZmSwhZ0CzJar9u3FJfgbjzYwvMJN1PDyk/i/28BCWzeQBvWZgq0k8ukKDdwMB3UeHcYG4NXflRaUnwON37ucrO+7G71Gw5PSUg/7JDNY1QcxI8qPftPLcKx8xknDmUVWOnAenRrtJRjsJBhvwe2tRLTmfyWoO8ESxnGZL1Pga8cgBBuNnSJnzv4OgQqqliUdZJ27DlicrIZXc2S1aGrcusd5fS1D3cWn8IvEblNNWegI8tmM/h7Y3UeZRseTxyYxVTeTcHrSu28QzKX78mxaee+VDRpLOPYfMsYqORLSDsZFLBIMbKfNmn7mRr2uedlsoqLbEGs8uPHKQgbHm+UOWYKv4NBulHYh80XpmWhE76gTktYRcPi6l2ojNcotLpSfA49sPcGhbE2UeBUtK56FOzLly7uw3lkny47fP8b0jHxBNOfuQOUdrshKxTsZG2wmVbSTgmcjkGTVUOciKLbHGvROvFORqspnkPO4FyjBOmRRmk3IXft0L6vj0LNayZ7ZZyLChbDUhl4+LyXZiU247jXgCPLb9Mxzaek9+WJ56sD8x5+qaTcxI8eLbZ/nuKx8QcxguFEFV5Visg7FYO+X+jQRctdfWUE1Azg3da1078RKib/zMvCAP0k2ZEqBBvx2XLiGpaRTNmFHXbCIpaXQXNARXE3b7OD/WTiyTIOIJ8ti2+/j9rXuzmZuDK6kmijI59+q6IGYkePGds3z/6PtFAReKADBAPN5BPN5B2LeRoF6LZk+phpy6TraykGu1O/ESzEKe49ZNgyT9dFCuhqlz12dPetR0Hq6SuwUlm8kGLh02hFYRdLuJmTE+3/BJDm3dh9+tXDvnThTX6TajRpJ/fe8szx19n9EigQtFAhggPtZBPNFJuWcDQb1uMpNnrpNzmVynZCH3GmdIzAE5Loa5bF8grJWz1rMWXWMa5PydCmoOsktQH6rgk6tv467VGwh6tSnr3BlzrmYzmk7w0ntneP74aaKpwhbVzaWiAQwQS7QTS3YS9mwgpNVNH66nFq5boJkS9cqd+EU5PZmPSIgbQx61B+m2LlCph6n1rsalA6qRXeJoE9BykBUDtwsifi8el4QtG/kCusnMzV4tjxpjvHTyDM//+jTRZHHBhSIDDDCazEKucDUQUmuvm8lSrrZ5vbyDMXOYdvNtrDmK6KLWEF2ZNipd5dT6anLDtZG/os7XNGsmspIBZaIcdmrmmvntx1EjyUsnm/mbE6eKEi4UIWCAaKqd0VQnlXoDYbV2lkyW8sUCHhPSVopL1jvExeDcn20N05FuI+Iup95fjabbk8Xrmjll2J6AmblmravrNnEjwUsnP+K5EyeLblieqqIEDBAdbyea6qBS20hYnjFcT7mDUDMhZg1w1jzKiJjfowyj5gjt45eIeMpZF6hC0wTMKFqXZ7xXcpBVzWI0k+Anp5v5/q/fITZePBdUs6loAQOMpDsYTrcT0RqokOtRTQnZlCafspPL4AuZdzhl/QeJBTzWKJqJ0pa8RMQboj4YwaULUIzcPGxN3p2gmvmtSFWzyGDw72fO8a0jbzCWLv7qk6IGDDBidDCcbiMk11Ap1eGylfw9TC4Txk2D45l/pNk+ilhgiXc0E6Mt0ckqb5B1wQp0l42kZK7dxJgArNokrRTH2i7x6sXLTnfNvFT0gAFGMp1cSb+PKhQ8IoTLciGbgrg5xInMC7xq/QtJFnfaNGLEaIt3E/GVsT5Uge4SMBvkXHV+0Kfg0uDdrj6GEoWrrVqsVgRggDFrgJbxo/SbLYxavVzOfMjrmR/xa/MFYtxcCcxIOk5b/DKr/GWsLw+j54dra8pe8+RcbEsZzg+McLa3eJ7FcT2tiIeRTsgUaZrTv6KZXy35Z1+M9vK3p/8TRctw/8bNuDSByBXOycpEXXOuOlIVKCviGYEr5FGGhdLFaB/Pv/dfvNLVjIWBqk7ehpKtiswWz12NJzjXF3U63HmpBHiGLgxf5ftvHeFoxzlsKYNLB0W1UTWBrgsGEgn+q7mDD7sLV/p6M1oxc3AhNZxKcn7wKmUejaBHQ1Is0naa7miUf32nlX84cRajwLVVi1Xph7FuILemsq+hll21ETJ2ht909PJm28r68Y8S4FtcpTn4Fpes67rTMZS0THK5XMh+v9/pOEpaJpWVlSGXlZU5HUdJy6RAIIBcU7Pw3zQoaWWouroaedOm4v9hiZIWp82bNyNv3rzZ6ThKWiZt3rwZubGx0ek4SlomNTY2IiUSCVFeXo5hFHfpSUkLk67rjIyMIHu9Xu666y6n4ylpibVnzx68Xm92J+uLX/yi0/GUtMR65JFHsm+EEKKvr0+oqirI7kuXvMKtqqro6+sTQgghA1RVVfG5z33O6T+6kpZIDzzwAFVVVdl/iJyOHz/u+F9eyUvjV199dQKryAMWQoi9e/c6HlzJN+d77713KtLpgI8ePep4gCUv3pIkiRMnTlwfsBBCPProo44HWvLifOjQoZk4rwXc09MjgsGg48GWvDCHQiHR29s7N2AhhDh8+LDjAZe8MP/85z+fDeXsgIUQ4mtf+5rjQZc8P3/jG9+4HsbrAx4fHxcHDhxwPPiSb+zPfvazIp1OLxywEELEYjGxe/duxxtR8uzesWOHiEajN0J4Y8BCCNHf3y927drleGNKnu7GxkbR398/F765AQshRDweF/fff7/jjSo56wMHDojR0dH5oJsf4Ik5+emnn3a8cR93f/3rX7/hnLtowBM6fPhwaZ3sgEOhkPjFL36xUFwLByyEEL29veLQoUNCkiTHG/5x8MGDB0V3d/diUC0O8ISOHz8u7rnnHsc74Fb1vn37rtlbLijgCZ04cUIcPHiwVDSwBFZVVTz88MPTjvwcBzyh/v5+8dxzz4l9+/YJl8vleGetFLtcLnHvvfeK559/fl5Ln4VIEkIIlkHJZJI33niDkydPcv78eVpaWujv7ycajTI2Nvaxq+LUdR2/308oFKKqqootW7awadMmGhsbaWpqwutdnl8k/f/IRvf6JXfwogAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMy0wNy0wM1QxMTowMDowOSswMDowMIMTiSsAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjMtMDctMDNUMTE6MDA6MDkrMDA6MDDyTjGXAAAAKHRFWHRkYXRlOnRpbWVzdGFtcAAyMDIzLTA3LTAzVDExOjEyOjA5KzAwOjAwYCAftQAAAABJRU5ErkJggg==",name:"Connext"},{id:"synapse",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2232%22%20height%3D%2232%22%20viewBox%3D%220%200%2032%2032%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cmask%20id%3D%22mask0_419_48383%22%20style%3D%22mask-type%3Aalpha%22%20maskUnits%3D%22userSpaceOnUse%22%20x%3D%220%22%20y%3D%220%22%20width%3D%2232%22%20height%3D%2232%22%3E%3Cpath%20d%3D%22M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z%22%20fill%3D%22black%22%2F%3E%3C%2Fmask%3E%3Cg%20mask%3D%22url%28%23mask0_419_48383%29%22%3E%3Cpath%20d%3D%22M0%208C0%203.58172%203.58172%200%208%200H24C28.4183%200%2032%203.58172%2032%208V24C32%2028.4183%2028.4183%2032%2024%2032H8C3.58172%2032%200%2028.4183%200%2024V8Z%22%20fill%3D%22%23121826%22%2F%3E%3Cpath%20d%3D%22M15.9794%207C15.5251%207%2015.1568%207.36058%2015.1568%207.80538C15.1568%208.25017%2015.5251%208.61075%2015.9794%208.61075C16.4337%208.61075%2016.802%208.25017%2016.802%207.80538C16.802%207.36058%2016.4337%207%2015.9794%207Z%22%20fill%3D%22url%28%23paint0_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M15.9794%207.44297C16.1839%207.44297%2016.3496%207.60522%2016.3496%207.80537C16.3496%208.00551%2016.1839%208.16776%2015.9794%208.16776C15.775%208.16776%2015.6093%208.00551%2015.6093%207.80537C15.6093%207.60522%2015.775%207.44293%2015.9794%207.44293V7.44297ZM12.4422%209.13423C11.9879%209.13423%2011.6196%209.49481%2011.6196%209.93961C11.6196%2010.3844%2011.9878%2010.7449%2012.4422%2010.7449C12.8965%2010.7449%2013.2648%2010.3844%2013.2648%209.93961C13.2648%209.49481%2012.8965%209.13423%2012.4422%209.13423ZM19.599%209.17448C19.1446%209.17448%2018.7764%209.53506%2018.7764%209.97986C18.7764%2010.4247%2019.1446%2010.7852%2019.599%2010.7852C20.0533%2010.7852%2020.4216%2010.4247%2020.4216%209.97986C20.4216%209.53506%2020.0533%209.17448%2019.599%209.17448V9.17448Z%22%20fill%3D%22url%28%23paint1_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M12.4422%209.57715C12.6466%209.57715%2012.8124%209.7394%2012.8124%209.93958C12.8124%2010.1397%2012.6466%2010.302%2012.4422%2010.302C12.2377%2010.302%2012.072%2010.1397%2012.072%209.93958C12.072%209.7394%2012.2377%209.57715%2012.4422%209.57715ZM19.599%209.6174C19.8034%209.6174%2019.9691%209.77965%2019.9691%209.97984C19.9691%2010.18%2019.8034%2010.3422%2019.599%2010.3422C19.3945%2010.3422%2019.2288%2010.18%2019.2288%209.97984C19.2288%209.77969%2019.3945%209.6174%2019.599%209.6174V9.6174ZM15.9794%2010.9866C15.457%2010.9866%2015.0334%2011.4012%2015.0334%2011.9127C15.0334%2012.4242%2015.457%2012.8389%2015.9794%2012.8389C16.5019%2012.8389%2016.9255%2012.4242%2016.9255%2011.9127C16.9255%2011.4012%2016.5019%2010.9866%2015.9794%2010.9866ZM8.8226%2011.1074C8.3683%2011.1074%208%2011.4679%208%2011.9127C8%2012.3575%208.3683%2012.7181%208.8226%2012.7181C9.27695%2012.7181%209.64525%2012.3575%209.64525%2011.9127C9.64525%2011.4679%209.27695%2011.1074%208.8226%2011.1074ZM23.1774%2011.1074C22.723%2011.1074%2022.3548%2011.4679%2022.3548%2011.9127C22.3548%2012.3575%2022.723%2012.7181%2023.1774%2012.7181C23.6317%2012.7181%2024%2012.3575%2024%2011.9127C24%2011.4679%2023.6317%2011.1074%2023.1774%2011.1074V11.1074Z%22%20fill%3D%22url%28%23paint2_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M15.9794%2011.4295C16.252%2011.4295%2016.473%2011.6458%2016.473%2011.9127C16.473%2012.1796%2016.252%2012.3959%2015.9794%2012.3959C15.7068%2012.3959%2015.4859%2012.1796%2015.4859%2011.9127C15.4859%2011.6458%2015.7068%2011.4295%2015.9794%2011.4295V11.4295ZM8.82261%2011.5503C9.02706%2011.5503%209.19281%2011.7126%209.19281%2011.9127C9.19281%2012.1129%209.02706%2012.2751%208.82261%2012.2751C8.61817%2012.2751%208.45245%2012.1129%208.45245%2011.9127C8.45245%2011.7126%208.61817%2011.5503%208.82261%2011.5503V11.5503ZM23.1774%2011.5503C23.3818%2011.5503%2023.5476%2011.7126%2023.5476%2011.9127C23.5476%2012.1129%2023.3818%2012.2751%2023.1774%2012.2751C22.973%2012.2751%2022.8072%2012.1129%2022.8072%2011.9127C22.8072%2011.7126%2022.973%2011.5503%2023.1774%2011.5503ZM12.3188%2013C11.7963%2013%2011.3727%2013.4146%2011.3727%2013.9261C11.3727%2014.4377%2011.7963%2014.8523%2012.3188%2014.8523C12.8412%2014.8523%2013.2648%2014.4377%2013.2648%2013.9261C13.2648%2013.4146%2012.8412%2013%2012.3188%2013ZM19.599%2013C19.0765%2013%2018.653%2013.4146%2018.653%2013.9261C18.653%2014.4377%2019.0765%2014.8523%2019.599%2014.8523C20.1214%2014.8523%2020.545%2014.4377%2020.545%2013.9261C20.545%2013.4146%2020.1214%2013%2019.599%2013Z%22%20fill%3D%22url%28%23paint3_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M12.3187%2013.443C12.5913%2013.443%2012.8123%2013.6593%2012.8123%2013.9262C12.8123%2014.1931%2012.5913%2014.4094%2012.3187%2014.4094C12.0461%2014.4094%2011.8252%2014.1931%2011.8252%2013.9262C11.8252%2013.6593%2012.0461%2013.443%2012.3187%2013.443ZM19.599%2013.443C19.8715%2013.443%2020.0925%2013.6593%2020.0925%2013.9262C20.0925%2014.1931%2019.8715%2014.4094%2019.599%2014.4094C19.3264%2014.4094%2019.1054%2014.1931%2019.1054%2013.9262C19.1054%2013.6593%2019.3264%2013.443%2019.599%2013.443Z%22%20fill%3D%22url%28%23paint4_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M8.8226%2015.1745C8.3683%2015.1745%208%2015.5351%208%2015.9799C8%2016.4247%208.3683%2016.7853%208.8226%2016.7853C9.27695%2016.7853%209.64525%2016.4247%209.64525%2015.9799C9.64525%2015.5351%209.27695%2015.1745%208.8226%2015.1745ZM23.1774%2015.1745C22.723%2015.1745%2022.3548%2015.5351%2022.3548%2015.9799C22.3548%2016.4247%2022.723%2016.7853%2023.1774%2016.7853C23.6317%2016.7853%2024%2016.4247%2024%2015.9799C24%2015.5351%2023.6317%2015.1745%2023.1774%2015.1745ZM16.0206%2015.2953C16.4067%2015.2953%2016.7198%2015.6018%2016.7198%2015.9799C16.7198%2016.358%2016.4067%2016.6645%2016.0206%2016.6645C15.6344%2016.6645%2015.3214%2016.358%2015.3214%2015.9799C15.3214%2015.6018%2015.6344%2015.2953%2016.0206%2015.2953Z%22%20fill%3D%22url%28%23paint5_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M8.82261%2015.6174C9.02706%2015.6174%209.19281%2015.7797%209.19281%2015.9798C9.19281%2016.18%209.02706%2016.3423%208.82261%2016.3423C8.61817%2016.3423%208.45245%2016.18%208.45245%2015.9798C8.45245%2015.7797%208.61817%2015.6174%208.82261%2015.6174V15.6174ZM23.1774%2015.6174C23.3818%2015.6174%2023.5476%2015.7797%2023.5476%2015.9798C23.5476%2016.18%2023.3818%2016.3423%2023.1774%2016.3423C22.973%2016.3423%2022.8072%2016.18%2022.8072%2015.9798C22.8072%2015.7797%2022.973%2015.6174%2023.1774%2015.6174ZM12.4422%2017.0671C11.9197%2017.0671%2011.4961%2017.4818%2011.4961%2017.9933C11.4961%2018.5048%2011.9197%2018.9194%2012.4422%2018.9194C12.9646%2018.9194%2013.3882%2018.5048%2013.3882%2017.9933C13.3882%2017.4818%2012.9646%2017.0671%2012.4422%2017.0671V17.0671ZM19.599%2017.0671C19.0765%2017.0671%2018.653%2017.4818%2018.653%2017.9933C18.653%2018.5048%2019.0765%2018.9194%2019.599%2018.9194C20.1214%2018.9194%2020.545%2018.5048%2020.545%2017.9933C20.545%2017.4818%2020.1214%2017.0671%2019.599%2017.0671V17.0671Z%22%20fill%3D%22url%28%23paint6_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M12.4422%2017.5101C12.7148%2017.5101%2012.9357%2017.7264%2012.9357%2017.9933C12.9357%2018.2602%2012.7148%2018.4765%2012.4422%2018.4765C12.1696%2018.4765%2011.9486%2018.2602%2011.9486%2017.9933C11.9486%2017.7264%2012.1696%2017.5101%2012.4422%2017.5101V17.5101ZM19.599%2017.5101C19.8716%2017.5101%2020.0925%2017.7264%2020.0925%2017.9933C20.0925%2018.2602%2019.8716%2018.4765%2019.599%2018.4765C19.3264%2018.4765%2019.1054%2018.2602%2019.1054%2017.9933C19.1054%2017.7264%2019.3264%2017.5101%2019.599%2017.5101V17.5101ZM15.9794%2019.0805C15.457%2019.0805%2015.0334%2019.4952%2015.0334%2020.0067C15.0334%2020.5182%2015.457%2020.9329%2015.9794%2020.9329C16.5019%2020.9329%2016.9255%2020.5182%2016.9255%2020.0067C16.9255%2019.4952%2016.5019%2019.0805%2015.9794%2019.0805ZM8.8226%2019.2416C8.3683%2019.2416%208%2019.6022%208%2020.047C8%2020.4918%208.3683%2020.8524%208.8226%2020.8524C9.27695%2020.8524%209.64525%2020.4918%209.64525%2020.047C9.64525%2019.6022%209.27695%2019.2416%208.8226%2019.2416ZM23.1774%2019.2416C22.723%2019.2416%2022.3548%2019.6022%2022.3548%2020.047C22.3548%2020.4918%2022.723%2020.8524%2023.1774%2020.8524C23.6317%2020.8524%2024%2020.4918%2024%2020.047C24%2019.6022%2023.6317%2019.2416%2023.1774%2019.2416Z%22%20fill%3D%22url%28%23paint7_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M15.9794%2019.5235C16.252%2019.5235%2016.473%2019.7398%2016.473%2020.0067C16.473%2020.2736%2016.252%2020.4899%2015.9794%2020.4899C15.7068%2020.4899%2015.4859%2020.2736%2015.4859%2020.0067C15.4859%2019.7398%2015.7068%2019.5235%2015.9794%2019.5235ZM8.82261%2019.6845C9.02706%2019.6845%209.19281%2019.8468%209.19281%2020.047C9.19281%2020.2471%209.02706%2020.4094%208.82261%2020.4094C8.61817%2020.4094%208.45245%2020.2471%208.45245%2020.047C8.45245%2019.8468%208.61817%2019.6845%208.82261%2019.6845V19.6845ZM23.1774%2019.6845C23.3818%2019.6845%2023.5476%2019.8468%2023.5476%2020.047C23.5476%2020.2471%2023.3818%2020.4094%2023.1774%2020.4094C22.973%2020.4094%2022.8072%2020.2471%2022.8072%2020.047C22.8072%2019.8468%2022.973%2019.6845%2023.1774%2019.6845ZM12.4422%2021.255C11.9879%2021.255%2011.6196%2021.6156%2011.6196%2022.0604C11.6196%2022.5052%2011.9878%2022.8658%2012.4422%2022.8658C12.8965%2022.8658%2013.2648%2022.5052%2013.2648%2022.0604C13.2648%2021.6156%2012.8965%2021.255%2012.4422%2021.255ZM19.599%2021.2953C19.1446%2021.2953%2018.7763%2021.6559%2018.7763%2022.1007C18.7763%2022.5455%2019.1446%2022.9061%2019.599%2022.9061C20.0533%2022.9061%2020.4216%2022.5455%2020.4216%2022.1007C20.4216%2021.6559%2020.0533%2021.2953%2019.599%2021.2953Z%22%20fill%3D%22url%28%23paint8_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M12.4422%2021.698C12.6466%2021.698%2012.8124%2021.8602%2012.8124%2022.0604C12.8124%2022.2606%2012.6466%2022.4228%2012.4422%2022.4228C12.2377%2022.4228%2012.072%2022.2606%2012.072%2022.0604C12.072%2021.8602%2012.2377%2021.698%2012.4422%2021.698ZM19.599%2021.7383C19.8035%2021.7383%2019.9692%2021.9005%2019.9692%2022.1007C19.9692%2022.3008%2019.8035%2022.4631%2019.599%2022.4631C19.3946%2022.4631%2019.2288%2022.3008%2019.2288%2022.1007C19.2288%2021.9005%2019.3946%2021.7383%2019.599%2021.7383ZM15.9795%2023.3893C15.5251%2023.3893%2015.1568%2023.7498%2015.1568%2024.1946C15.1568%2024.6394%2015.5251%2025%2015.9795%2025C16.4338%2025%2016.8021%2024.6394%2016.8021%2024.1946C16.8021%2023.7498%2016.4338%2023.3893%2015.9795%2023.3893V23.3893Z%22%20fill%3D%22url%28%23paint9_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M15.9794%2023.8322C16.1838%2023.8322%2016.3496%2023.9945%2016.3496%2024.1946C16.3496%2024.3948%2016.1838%2024.5571%2015.9794%2024.5571C15.775%2024.5571%2015.6092%2024.3948%2015.6092%2024.1946C15.6092%2023.9945%2015.775%2023.8322%2015.9794%2023.8322ZM19.2699%2013.7972L16.3496%2015.5288L16.5848%2015.9075L19.5051%2014.176L19.2699%2013.7972V13.7972ZM12.6761%2013.7576L12.4331%2014.1313L15.3945%2015.9837L15.6375%2015.6099L12.6761%2013.7576V13.7576ZM11.8843%2013.9551L9.16962%2015.6061L9.40873%2015.9824L12.1234%2014.3314L11.8843%2013.9551ZM22.9113%2015.8855L19.9909%2017.617L20.2262%2017.9958L23.1465%2016.2643L22.9113%2015.8855ZM15.5077%2016.0466L12.5874%2017.7781L12.8226%2018.1569L15.7429%2016.4254L15.5077%2016.0466V16.0466ZM16.5437%2015.9944L16.3007%2016.3681L19.2622%2018.2205L19.5051%2017.8467L16.5437%2015.9944V15.9944Z%22%20fill%3D%22url%28%23paint10_radial_419_48383%29%22%2F%3E%3Cpath%20d%3D%22M20.0758%2013.8205L19.8328%2014.1942L22.7943%2016.0466L23.0373%2015.6728L20.0758%2013.8205ZM9.16191%2015.9308L8.91895%2016.3045L11.8804%2018.1569L12.1234%2017.7832L9.16191%2015.9308V15.9308Z%22%20fill%3D%22url%28%23paint11_radial_419_48383%29%22%2F%3E%3C%2Fg%3E%3Cdefs%3E%3CradialGradient%20id%3D%22paint0_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2815.9999%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint1_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint2_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint3_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint4_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2815.9999%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint5_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint6_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint7_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint8_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint9_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2816%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint10_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2815.9999%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3CradialGradient%20id%3D%22paint11_radial_419_48383%22%20cx%3D%220%22%20cy%3D%220%22%20r%3D%221%22%20gradientUnits%3D%22userSpaceOnUse%22%20gradientTransform%3D%22translate%2815.9999%2016.0001%29%20scale%287.99998%207.83228%29%22%3E%3Cstop%20stop-color%3D%22%23FF00FF%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23734CE2%22%2F%3E%3C%2FradialGradient%3E%3C%2Fdefs%3E%3C%2Fsvg%3E",name:"Synapse"},{id:"swft",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M14.0802%202.71222C14.0802%202.71222%2012.9826%201.61464%2011.6884%201.51537C10.3941%201.4161%209.89405%201.81505%209.99332%202.214C10.0926%202.61295%2010.5421%202.66165%2011.1396%202.2627C11.7371%201.86375%2013.0332%201.96489%2014.0802%202.71222Z%22%20fill%3D%22%230999FF%22%2F%3E%3Cpath%20d%3D%22M13.5408%202.87517C13.5408%202.87517%2012.668%202.33013%2011.8176%202.45936C10.9673%202.5886%2010.6938%202.92012%2010.8268%203.16174C10.9598%203.40336%2011.2482%203.36964%2011.576%203.02314C11.9038%202.67663%2012.7523%202.54927%2013.5408%202.87517Z%22%20fill%3D%22%230999FF%22%2F%3E%3Cpath%20d%3D%22M12.2597%202.99879C12.6341%202.88498%2013.0346%202.89022%2013.4059%203.01377C12.8628%202.91825%2012.3439%203.13364%2012.1866%203.39399C12.0293%203.65434%2011.8476%203.71615%2011.7352%203.58129C11.6228%203.44644%2011.7408%203.1992%2012.2597%202.99879Z%22%20fill%3D%22%230999FF%22%2F%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M19.7592%206.10048C17.8075%205.65096%2017.1089%205.82703%2016.1218%206.25033C15.425%206.5575%2015.6236%207.84238%2016.0225%208.93996C16.4215%2010.0375%2017.2194%2013.8248%2015.425%2015.8176C13.9914%2017.4099%2012.8137%2017.6032%2010.5679%2017.972C10.0027%2018.0648%209.36998%2018.1687%208.6485%2018.3087C5.05982%2019.0055%204.86128%2021.697%204.86128%2021.697C3.17126%2012.5314%207.83234%2010.1212%2010.1284%208.93399C10.4049%208.79097%2010.6472%208.6657%2010.8399%208.5485C11.9352%207.87375%2012.0384%206.61486%2012.0958%205.91511C12.1082%205.7641%2012.1184%205.63913%2012.136%205.55169C12.1467%205.49883%2012.1573%205.4355%2012.1694%205.36375C12.2698%204.76704%2012.4681%203.58853%2013.5783%203.01003C16.9703%201.41797%2019.7592%206.10048%2019.7592%206.10048ZM10.8009%2015.8525C11.5854%2015.8693%2012.9238%2015.898%2013.6045%2014.5964C14.3724%2013.1261%2013.5221%2011.8075%2012.3084%2011.3917C11.0946%2010.9759%209.25161%2011.5509%208.04352%2013.2366C6.83543%2014.9223%206.68934%2016.9826%206.68934%2016.9826C6.7545%2016.9197%206.81451%2016.8522%206.87696%2016.782C7.13404%2016.4929%207.4325%2016.1574%208.302%2015.8982C8.96656%2015.7001%209.67011%2015.7718%2010.1431%2015.82C10.3006%2015.836%2010.4326%2015.8495%2010.529%2015.8495C10.6088%2015.8484%2010.7003%2015.8504%2010.8009%2015.8525ZM18.5642%205.503C18.5642%205.503%2016.62%205.24639%2015.8727%205.9956C15.8727%205.9956%2016.472%204.30989%2018.5642%205.503Z%22%20fill%3D%22%230999FF%22%2F%3E%3C%2Fsvg%3E",name:"Swft"},{id:"hyphen",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2225%22%20viewBox%3D%220%200%2024%2025%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M10.2675%2016.7858V15.0715C10.2675%2014.5915%2010.6618%2014.2143%2011.1247%2014.2143H12.839C13.319%2014.2143%2013.6961%2014.5915%2013.6961%2015.0715V20.2143C13.6961%2020.6943%2013.319%2021.0715%2012.839%2021.0715H4.26755C3.78755%2021.0715%203.4104%2020.6943%203.4104%2020.2143V8.21433C3.4104%207.73433%203.03326%207.35719%202.55326%207.35719H2.05612C1.30183%207.35719%200.907546%206.43148%201.45612%205.90005L4.52469%202.81433C4.60378%202.73295%204.69838%202.66825%204.80291%202.62407C4.90745%202.57989%205.01978%202.55713%205.13326%202.55713C5.24674%202.55713%205.35908%202.57989%205.46361%202.62407C5.56814%202.66825%205.66275%202.73295%205.74183%202.81433L8.79326%205.90005C9.34183%206.43148%208.96469%207.35719%208.19326%207.35719H7.69612C7.21612%207.35719%206.83897%207.73433%206.83897%208.21433V16.7858C6.83897%2017.2658%207.21612%2017.6429%207.69612%2017.6429H9.4104C9.8904%2017.6429%2010.2675%2017.2658%2010.2675%2016.7858Z%22%20fill%3D%22%23615CCD%22%2F%3E%3Cpath%20d%3D%22M20.5533%2016.7858C20.5533%2017.2658%2020.9304%2017.6429%2021.4104%2017.6429H21.9247C22.679%2017.6429%2023.0561%2018.5686%2022.5247%2019.1001L19.4561%2022.1686C19.1133%2022.5115%2018.5818%2022.5115%2018.239%2022.1686L15.1704%2019.1001C14.6218%2018.5686%2014.999%2017.6429%2015.7704%2017.6429H16.2676C16.7476%2017.6429%2017.1247%2017.2658%2017.1247%2016.7858V8.21436C17.1247%207.73436%2016.7476%207.35721%2016.2676%207.35721H14.5533C14.0733%207.35721%2013.6961%207.73436%2013.6961%208.21436V9.92864C13.6961%2010.4086%2013.319%2010.7858%2012.839%2010.7858H11.1247C10.6447%2010.7858%2010.2676%2010.4086%2010.2676%209.92864V4.78578C10.2676%204.30578%2010.6447%203.92864%2011.1247%203.92864H19.6961C20.1761%203.92864%2020.5533%204.30578%2020.5533%204.78578V16.7858Z%22%20fill%3D%22%23615CCD%22%2F%3E%3C%2Fsvg%3E",name:"Hyphen"},{id:"lifi",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2225%22%20viewBox%3D%220%200%2024%2025%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%3E%3Crect%20y%3D%220.5%22%20width%3D%2224%22%20height%3D%2224%22%20rx%3D%224%22%20fill%3D%22white%22%2F%3E%3Crect%20x%3D%227.5%22%20y%3D%226.5%22%20width%3D%228.72727%22%20height%3D%2212%22%20fill%3D%22url%28%23pattern0%29%22%2F%3E%3Cdefs%3E%3Cpattern%20id%3D%22pattern0%22%20patternContentUnits%3D%22objectBoundingBox%22%20width%3D%221%22%20height%3D%221%22%3E%3Cuse%20xlink%3Ahref%3D%22%23image0_1105_25179%22%20transform%3D%22translate%28-0.958333%20-0.393939%29%20scale%280.0208333%200.0151515%29%22%2F%3E%3C%2Fpattern%3E%3Cimage%20id%3D%22image0_1105_25179%22%20width%3D%22252%22%20height%3D%22124%22%20xlink%3Ahref%3D%22data%3Aimage%2Fpng%3Bbase64%2CiVBORw0KGgoAAAANSUhEUgAAAPwAAAB8CAYAAABNG92%2FAAAMbGlDQ1BJQ0MgUHJvZmlsZQAASImVlwdcU0kTwPeVJCQkBAhEQEroTRDpRUoILYKAVMFGSAIJJcaEIGJHj1Pw7CKKFT0V8dDTE5BDRezlUOz9sKCinId6KIrKtymg533l901%2B%2B94%2Fs7Mzs%2FP2lQWA3seTSvNQXQDyJQWyhMhQ1vi0dBbpCSACBP7owIPHl0vZ8fExAMrg%2Be%2Fy9jq0hHLFRenrn%2F3%2FVfQFQjkfAGQi5EyBnJ8PuQUAfANfKisAgKjUW08vkCp5HmQDGUwQ8molZ6t5l5Iz1dyssklK4EC%2BBIAWlceTZQOgcxfqWYX8bOhH5yNkN4lALAGAPgJyEF%2FEE0BW5j4iP3%2BqkishO0B7KWSYD%2FDN%2FMpn9t%2F8Zw755%2FGyh1g9L5VohYnl0jzejP%2BzNP9b8vMUgzHsYKOKZFEJyvnDGt7MnRqtZCrkbklmbJyy1pD7xAJ13QFAKSJFVLLaHjXlyzmwfoAJ2U3AC4uGbAo5QpIXG6PRZ2aJI7iQ4WpBi8QF3CTIRpAXCeXhiRqbLbKpCZpYaH2WjMPW6M%2FwZKq4ylj3FbnJbI3%2F1yIhV%2BMf0ykWJaVCpkC2KRSnxELWgewqz02M1tiMLhZxYgdtZIoEZf42kBOEkshQtX%2BsMEsWkaCxL8uXD84X2yISc2M1vL9AlBSlrg92gs9T5Q%2Fngl0SStjJg36E8vExg3MRCMPC1XPHngklyYkaP33SgtAE9VicIs2L19jjVsK8SKXeCrKnvDBRMxZPKYCLU%2B0fz5IWxCep88SLc3hj4tX54MtBDOCAMMACCtgywVSQA8Rt3Q3d8J%2B6JwLwgAxkAyFw0WgGR6SqeiTwmAiKwR%2BQhEA%2BNC5U1SsEhVD%2FaUirPrqALFVvoWpELngCOR9Egzz4X6EaJRmKlgIeQ434H9F5sPFhvnmwKfv%2FvX5Q%2B0XDhpoYjUYxGJFFH7QkhhPDiFHECKIjboIH4QF4DDyGwOaO%2B%2BJ%2Bg%2FP4Yk94QmgnPCRcI3QQbk0Rl8i%2ByXIs6ID%2BIzS1yPy6Frgd9OmFh%2BKB0Dv0jDNxE%2BCCe8I4bDwYRvaCWo4mb2VVWN%2F4%2FtsMvroaGjuyGxklDyOHkB2%2BHanjpOM15EVZ66%2Fro841c6jenKGeb%2BNzvqq%2BAJ6jv7XEFmEHsNPYMews1ow1ABZ2FGvELmCHlTy0uh6rVtdgtARVPrnQj%2Fgf8QavrLKScrdaty63j%2Bq%2BAmFRgfLG40yVzpCJs0UFLDZ8OwhZXAnfdQTL3c3dHQDlu0b9%2BHrDVL1DEOa5L7oSOgCj3w8MDDR%2F0cXYAvBLKbz9n3zROVTDx8R8AM6U8xWyQrUOVx4I8ClBh3eaMTAH1sABzscdeIMAEALCwRgQB5JAGpgMsxfBdS4D08EsMB%2BUgnKwHKwB68FmsA3sAj%2BB%2FaABNINj4BQ4Dy6Ba%2BAOXD2d4AXoAW9BP4IgJISGMBBjxAKxRZwRd8QXCULCkRgkAUlDMpBsRIIokFnIAqQcWYmsR7YiNcjPyCHkGHIWaUduIQ%2BQLuQ18gHFUCpqgJqhduhI1Bdlo9FoEjoJzUanocXoQnQpWolWo3vQevQYeh69hnagL9BeDGDaGBOzxFwwX4yDxWHpWBYmw%2BZgZVgFVo3VYU3wOl%2FBOrBu7D1OxBk4C3eBKzgKT8b5%2BDR8Dr4EX4%2FvwuvxE%2FgV%2FAHeg38m0AimBGeCP4FLGE%2FIJkwnlBIqCDsIBwkn4b3USXhLJBKZRHuiD7wX04g5xJnEJcSNxL3EFmI78RGxl0QiGZOcSYGkOBKPVEAqJa0j7SEdJV0mdZL6tLS1LLTctSK00rUkWiVaFVq7tY5oXdZ6qtVP1iXbkv3JcWQBeQZ5GXk7uYl8kdxJ7qfoUewpgZQkSg5lPqWSUkc5SblLeaOtrW2l7ac9TlusPU%2B7Unuf9hntB9rvqfpUJyqHOpGqoC6l7qS2UG9R39BoNDtaCC2dVkBbSquhHafdp%2FXpMHRcdbg6Ap25OlU69TqXdV7SyXRbOps%2BmV5Mr6AfoF%2Bkd%2BuSde10Obo83Tm6VbqHdG%2Fo9uox9Ebpxenl6y3R2613Vu%2BZPknfTj9cX6C%2FUH%2Bb%2FnH9RwyMYc3gMPiMBYztjJOMTgOigb0B1yDHoNzgJ4M2gx5DfUNPwxTDIsMqw8OGHUyMacfkMvOYy5j7mdeZH4aZDWMPEw5bPKxu2OVh74yGG4UYCY3KjPYaXTP6YMwyDjfONV5h3GB8zwQ3cTIZZzLdZJPJSZPu4QbDA4bzh5cN3z%2F8tilq6mSaYDrTdJvpBdNeM3OzSDOp2Tqz42bd5kzzEPMc89XmR8y7LBgWQRZii9UWRy2eswxZbFYeq5J1gtVjaWoZZamw3GrZZtlvZW%2BVbFVitdfqnjXF2tc6y3q1dat1j42FzVibWTa1Nrdtyba%2BtiLbtbanbd%2FZ2dul2n1v12D3zN7InmtfbF9rf9eB5hDsMM2h2uGqI9HR1zHXcaPjJSfUyctJ5FTldNEZdfZ2FjtvdG4fQRjhN0IyonrEDReqC9ul0KXW5YEr0zXGtcS1wfXlSJuR6SNXjDw98rObl1ue23a3O6P0R40ZVTKqadRrdyd3vnuV%2B1UPmkeEx1yPRo9Xns6eQs9Nnje9GF5jvb73avX65O3jLfOu8%2B7ysfHJ8Nngc8PXwDfed4nvGT%2BCX6jfXL9mv%2Ff%2B3v4F%2Fvv9%2FwxwCcgN2B3wbLT9aOHo7aMfBVoF8gK3BnYEsYIygrYEdQRbBvOCq4MfhliHCEJ2hDxlO7Jz2HvYL0PdQmWhB0Pfcfw5szktYVhYZFhZWFu4fnhy%2BPrw%2BxFWEdkRtRE9kV6RMyNboghR0VErom5wzbh8bg23Z4zPmNljTkRToxOj10c%2FjHGKkcU0jUXHjhm7auzdWNtYSWxDHIjjxq2KuxdvHz8t%2FtdxxHHx46rGPUkYlTAr4XQiI3FK4u7Et0mhScuS7iQ7JCuSW1PoKRNTalLepYalrkztGD9y%2FOzx59NM0sRpjemk9JT0Hem9E8InrJnQOdFrYunE65PsJxVNOjvZZHLe5MNT6FN4Uw5kEDJSM3ZnfOTF8ap5vZnczA2ZPXwOfy3%2FhSBEsFrQJQwUrhQ%2BzQrMWpn1LDswe1V2lyhYVCHqFnPE68WvcqJyNue8y43L3Zk7kJeatzdfKz8j%2F5BEX5IrOTHVfGrR1Haps7RU2jHNf9qaaT2yaNkOOSKfJG8sMIAf9RcUDorvFA8KgwqrCvump0w%2FUKRXJCm6MMNpxuIZT4sjin%2Bcic%2Fkz2ydZTlr%2FqwHs9mzt85B5mTOaZ1rPXfh3M55kfN2zafMz53%2FW4lbycqSvxakLmhaaLZw3sJH30V%2BV1uqUyorvfF9wPebF%2BGLxIvaFnssXrf4c5mg7Fy5W3lF%2Bccl%2FCXnfhj1Q%2BUPA0uzlrYt8162aTlxuWT59RXBK3at1FtZvPLRqrGr6lezVpet%2FmvNlDVnKzwrNq%2BlrFWs7aiMqWxcZ7Nu%2BbqP60Xrr1WFVu3dYLph8YZ3GwUbL28K2VS32Wxz%2BeYPW8Rbbm6N3FpfbVddsY24rXDbk%2B0p20%2F%2F6PtjzQ6THeU7Pu2U7OzYlbDrRI1PTc1u093LatFaRW3Xnol7Lv0U9lNjnUvd1r3MveX7wD7Fvuc%2FZ%2Fx8fX%2F0%2FtYDvgfqfrH9ZcNBxsGyeqR%2BRn1Pg6ihozGtsf3QmEOtTQFNB391%2FXVns2Vz1WHDw8uOUI4sPDJwtPhob4u0pftY9rFHrVNa7xwff%2FzqiXEn2k5GnzxzKuLU8dPs00fPBJ5pPut%2F9tA533MN573P11%2FwunDwN6%2FfDrZ5t9Vf9LnYeMnvUlP76PYjl4MvH7sSduXUVe7V89dir7VfT75%2B88bEGx03BTef3cq79ep24e3%2BO%2FPuEu6W3dO9V3Hf9H71746%2F7%2B3w7jj8IOzBhYeJD%2B884j968Vj%2B%2BGPnwie0JxVPLZ7WPHN%2F1twV0XXp%2BYTnnS%2BkL%2Fq7S%2F%2FQ%2B2PDS4eXv%2FwZ8ueFnvE9na9krwZeL3lj%2FGbnX55%2FtfbG995%2Fm%2F%2B2%2F11Zn3Hfrve%2B709%2FSP3wtH%2F6R9LHyk%2BOn5o%2BR3%2B%2BO5A%2FMCDlyXiqTwEMNjQrC4DXOwGgpQHAgPs2ygT1XlAliHr%2FqiLwn1i9X1SJNwB18KT8jOe0ALAPNnvItHkAKD%2Fhk0IA6uEx1DQiz%2FJwV%2Fuiwp0QoW9g4I0ZAKQmAD7JBgb6Nw4MfNoOk70FQMs09R5UKUS4Z9jiqaTLzKJ54BtR70%2B%2FmuO3Z6DMQDX8b%2Bd%2FAU%2F6jzXPsPu0AAAAbGVYSWZNTQAqAAAACAAEARoABQAAAAEAAAA%2BARsABQAAAAEAAABGASgAAwAAAAEAAgAAh2kABAAAAAEAAABOAAAAAAAAAJAAAAABAAAAkAAAAAEAAqACAAQAAAABAAAA%2FKADAAQAAAABAAAAfAAAAABezPYPAAAACXBIWXMAABYlAAAWJQFJUiTwAAAH8UlEQVR4Ae2d0U3cQBRFTYT4hQ7gi19IBUkqIFQQ6AAaIKQCoAPSQVJBkg6ggkAH8IOEhJRwEZOMVsZrrz3GM%2FeMZO2ud3bsd967%2B7zjmdmlP4%2BlokAAAhYE3lhYiZEQgMATAQRPIEDAiACCN3I2pkIAwRMDEDAigOCNnI2pEEDwxAAEjAggeCNnYyoEEDwxAAEjAgjeyNmYCgEETwxAwIgAgjdyNqZCAMETAxAwIoDgjZyNqRBA8MQABIwIIHgjZ2MqBBA8MQABIwII3sjZmAoBBE8MQMCIAII3cjamQgDBEwMQMCKA4I2cjakQQPDEAASMCCB4I2djKgQQPDEAASMCCN7I2ZgKAQSfMAaurq6qr1%2B%2FVvv7%2B9Xbt2%2BrpaWl6vz8POERaRoCzQSW%2BKupZkBd3r24uKguLy%2Brnz9%2FPm0S%2FGzZ2Niofv%2F%2BPbub1xAYhQCC74FZAv%2F169c%2Fgd%2Fc3LRqjb%2Fza4WJSgkILCdos9gmY3FL7G0FXiwQDMuOAIJvcFkscF2mUyCQOwEE%2F%2BxBZetY4MrgFAiURsBW8OpQk8AlbGVvBF5aaGNPHQEbwQeBS9za6nrQ6wCxDwIlESha8LoH%2Fu3btyeB08FWUthiy6IEihW8BrhowAsFAhD4T6DYkXZra2v%2FreQZBCDwRKDogTca1XZ9fT05VzPwZnIusTmhYjO8PHh8fGzjSAyFQBsCRWd4AZhilifDtwlN6qQgUHSGF7C9vb0U3BZuc3V1deHP8kEI9CVQvOAPDg6qKYlsal9AfQOIz%2BdFoHjBq7deon%2FN8u7du%2Brz58%2FVjx8%2FqtPT06Snojn3L20acDR02dzcfPF4R0dHgxxOfTEv2TTE%2Frq%2BHo3haGp7EMNeoZFi78PHLCV4Ce329jbeneS5ribev39fbW9vPz3qOQUCUyFgIfiQ5b98%2BTI49yBwCVubhE6BwFQJWAhe8IfK8uvr60%2FCDgLXXQAKBHIhYCP4RbP81tbWv8wtkSPwXEKb86wjYCN4Gf%2Fx48dq3mV9EHjI4EMM0Q1z7TUF99OnT3xp1EUi%2B0YhYCX4OqLqQQ%2Fi1uMQJZ6KK5HHc%2B01qYdFLIeg%2FL8N3QHpU4bye59zGOuzNoKX6OLZc8q06rkfIoOr7Xgxjaa59k3vjeX00o5Td1utNBuHsqdYwQcR6t6ztng%2BvMTeZ334WNyzbQ%2FlGNqBQAoCRQheYo7Xg5cIm0rXjBCvdTev7abj8h4EXptA1oKX0HWZrlVtupSmnvbQwSZha4t%2Ff3c5BnUhMEUCWQte99a7ir3OCRK2hlJK3Ai8jhD7SiGQteAl0r5FXxi7u7t9m%2BHzEMiCQNaCH4Jw6sksQ5wjbTQT%2BPDhQ3OFhndPTk6shkPbC15j39UpR8mXgH6SLVriuzeLtpHT597kdLIpzvW1p86msIk2IfASAXvBq8de9%2BUpEHAgYC94ObnrfXmHwMDGMgkg%2BEe%2FKsvv7OyU6WGsgkBEwL7TLrDQb%2Fnv37%2BHl8kep7S%2BXjIjR264z%2BSZpkFYI5sxyuEQ%2FDNmzZjSzLnUPfaaoksZlgA%2FydrztLukb8qwqQMnzNBr7x5qQmBYAnYZvmnu89BZPsViGsO6n9bcCFgJXuvRzRtZpyy%2F6MiteDENDegZYq69W0Bib1oCWQteGVTTYptKLMKm7B7aUB1d9s9b0lp14qWo27QdjuH%2BeHd39yKC5eXlamVl5cX3eaMfgawFr0UsJLQgTmXwWIR6vkjRHxDMFglcxwrbom3Ptjvm68PDw15XHUONOxfLh4eHWtPv7%2B9r97NzGAJZC16i01hojaXW7RVtfYu%2BROLx1bo%2Fr8v8HAU%2By6Lv1N%2BYy2zbvM6DQNaCD4iVdfuUsGSVpsrqyyMU%2FWQYYr59aI9HCLw2gSIE3wWislTb5bC4Z96FLHVzIFC84MOS0bqcVfbuclkbZ%2FscnMk5QmAegeIEL0GHRSf1vM%2By0GpHnx%2Bib2CeI3gfAmMQyF7wQdzKxikysjrs%2BixpPYYTOQYE2hJY%2BvNY2laeWj1NeDk7O0t%2BWvqnGLJ8cswcYAQCWQu%2B7n55CmZ9%2F7gixTnRJgQWIYDgW1Ijy7cERbVJE3gz6bOb0MnptzwFArkTIMN38CBZvgMsqk6SABm%2Bg1vmzbTr0BRVIfAqBMjwHbBruquyPNNeO0Cj6qQIkOE7uEPDcsnyHYBRdXIEEHxHl6QY3NPxFKgOgYUJIPgO6DR7jgzfARhVJ0cg%2B6G1KYnGq%2BVoPjy%2F3VPSpu0xCCD4Z8olrGgzRsBwjLwJ2Apel%2BfK2mHJKsbK5x3InH07AjaCD5fnQeRcnrcLEGqVRSBrwesyPCxgGbslvjwPAo%2Ff5zkEXAlkPfBGPeZaiZXLc9fwxe6uBLIWfFdjqQ8BdwLch3ePAOy3IoDgrdyNse4EELx7BGC%2FFQEEb%2BVujHUngODdIwD7rQggeCt3Y6w7AQTvHgHYb0UAwVu5G2PdCSB49wjAfisCCN7K3RjrTgDBu0cA9lsRQPBW7sZYdwII3j0CsN%2BKAIK3cjfGuhNA8O4RgP1WBBC8lbsx1p0AgnePAOy3IoDgrdyNse4EELx7BGC%2FFQEEb%2BVujHUngODdIwD7rQggeCt3Y6w7AQTvHgHYb0UAwVu5G2PdCSB49wjAfisCCN7K3RjrTgDBu0cA9lsRQPBW7sZYdwII3j0CsN%2BKAIK3cjfGuhNA8O4RgP1WBBC8lbsx1p0AgnePAOy3IvAXd0VRjJTy4H0AAAAASUVORK5CYII%3D%22%2F%3E%3C%2Fdefs%3E%3C%2Fsvg%3E",name:"LIFI"},{id:"nabox",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2225%22%20viewBox%3D%220%200%2024%2025%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M1.5%207.23999V18.418L4.73651%2020.2838V12.2876L7.96146%2014.1503V22.1412L11.199%2024.007V12.8279L1.5%207.23999Z%22%20fill%3D%22%232AC98B%22%2F%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M8.85179%206.21724L12.0946%204.31675L16.1237%206.67449L12.883%208.56657L8.85179%206.21724ZM12.0988%200.5L2.32306%206.21934L12.8651%2012.4001V24.5L16.0627%2022.6374V10.3966L19.294%208.50455V20.7348L22.5389%2018.8248V6.60827L12.0988%200.5Z%22%20fill%3D%22%232AC98B%22%2F%3E%3C%2Fsvg%3E",name:"Nabox"},{id:"bungee",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2225%22%20viewBox%3D%220%200%2024%2025%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cg%20clip-path%3D%22url%28%23clip0_1106_26400%29%22%3E%3Cpath%20d%3D%22M24%204.5C24%202.29086%2022.2091%200.5%2020%200.5H4C1.79086%200.5%200%202.29086%200%204.5V20.5C0%2022.7091%201.79086%2024.5%204%2024.5H20C22.2091%2024.5%2024%2022.7091%2024%2020.5V4.5Z%22%20fill%3D%22%23FEA700%22%2F%3E%3Cpath%20d%3D%22M3.26157%2014.6479C4.44801%2014.6479%205.40958%2013.6862%205.40958%2012.4999C5.40958%2011.3137%204.44779%2010.3519%203.26157%2010.3519C2.07824%2010.3519%201.1189%2011.3088%201.11401%2012.491V12.509C1.1189%2013.691%202.07824%2014.6479%203.26157%2014.6479Z%22%20fill%3D%22%23ED1E7F%22%2F%3E%3Cpath%20d%3D%22M20.7367%2014.6477C21.923%2014.6477%2022.8847%2013.686%2022.8847%2012.4997C22.8847%2011.3134%2021.923%2010.3517%2020.7367%2010.3517C19.5504%2010.3517%2018.5887%2011.3134%2018.5887%2012.4997C18.5887%2013.686%2019.5504%2014.6477%2020.7367%2014.6477Z%22%20fill%3D%22%234CB85D%22%2F%3E%3Cpath%20d%3D%22M9.59911%2015.9941C10.2391%2015.9941%2010.8329%2015.7967%2011.3251%2015.4612V15.9438H12.672V12.9378C12.672%2012.9314%2012.6726%2012.9252%2012.6726%2012.9187V12.0794C12.6726%2011.1272%2013.4471%2010.3527%2014.3993%2010.3527C15.3535%2010.3527%2016.126%2011.1272%2016.126%2012.0794V15.9438H17.4747V12.0794C17.4747%2010.3825%2016.0982%209.00586%2014.3993%209.00586C13.7591%209.00586%2013.1646%209.20338%2012.6722%209.53919V9.05539H11.3253V12.9307C11.3189%2013.8792%2010.5475%2014.6454%209.5993%2014.6454C8.6453%2014.6454%207.87264%2013.873%207.87264%2012.9187V9.05607H6.52399V12.9187C6.52375%2014.6176%207.90019%2015.9941%209.59911%2015.9941Z%22%20fill%3D%22black%22%2F%3E%3C%2Fg%3E%3Cdefs%3E%3CclipPath%20id%3D%22clip0_1106_26400%22%3E%3Crect%20width%3D%2224%22%20height%3D%2224%22%20fill%3D%22white%22%20transform%3D%22translate%280%200.5%29%22%2F%3E%3C%2FclipPath%3E%3C%2Fdefs%3E%3C%2Fsvg%3E",name:"Bungee"},{id:"squid",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cg%20clip-path%3D%22url%28%23clip0_6759_209574%29%22%3E%3Cpath%20d%3D%22M23.7182%2011.278C23.2776%2012.8519%2022.2417%2014.5477%2020.9174%2015.1962C16.7933%2017.2151%2014.6496%2012.8533%2014.9088%209.67381C15.0643%207.76437%2015.6835%206.24613%2015.2064%204.69333C15.0542%204.19797%2014.7307%203.73957%2014.2008%203.49141C12.7469%202.81029%2011.3241%203.74677%2010.6627%204.73893C9.94895%205.80885%209.61391%207.14757%209.70463%208.37109C9.79151%209.54997%2010.1995%2010.3228%2010.8149%2011.3783C11.6371%2012.7885%2012.5126%2013.7044%2012.8477%2014.7872C13.0637%2015.4852%2013.1865%2016.6117%2012.1944%2016.7063C11.1465%2016.8066%2011.1993%2015.4328%2011.1845%2014.7436C11.1398%2012.6488%209.80927%2011.8943%208.80751%209.48133C8.22239%208.07205%207.99439%206.58165%208.33663%205.11045C8.81807%203.04021%209.99119%201.37125%2012.1061%200.793809C13.7971%200.332049%2015.7555%200.710769%2016.8259%202.19157C18.0984%203.95221%2017.8502%206.02917%2017.3328%207.87477C16.3752%2011.289%2017.2305%2012.9167%2018.0288%2013.3424C19.5403%2014.1484%2021.1262%2013.2354%2021.8299%2012.2677C22.5921%2011.2194%2023.0467%209.30709%2022.9747%208.08309C22.9473%207.61557%2022.9061%207.21333%2022.8432%206.85237%22%20fill%3D%22white%22%2F%3E%3Cpath%20d%3D%22M0%2012.0001C0%2012.8756%200.09456%2013.7291%200.27264%2014.5513C0.2544%2013.9316%200.31536%2013.3182%200.47568%2012.746C0.91632%2011.1721%201.95216%209.47627%203.27648%208.82779C7.40064%206.80891%209.54432%2011.1707%209.28512%2014.3502C9.1296%2016.2596%208.5104%2017.7779%208.98752%2019.3307C9.13968%2019.826%209.4632%2020.2844%209.99312%2020.5326C11.447%2021.2137%2012.8698%2020.2772%2013.5312%2019.2851C14.245%2018.2151%2014.58%2016.8764%2014.4893%2015.6529C14.4024%2014.474%2013.9944%2013.7012%2013.3795%2012.6457C12.5573%2011.2355%2011.6818%2010.3196%2011.3467%209.23675C11.1307%208.53883%2011.0078%207.41227%2012%207.31771C13.0478%207.21739%2012.995%208.59115%2013.0099%209.28043C13.0546%2011.3751%2014.3851%2012.1297%2015.3869%2014.5427C15.972%2015.9519%2016.2%2017.4423%2015.8578%2018.9135C15.3763%2020.9838%2014.2032%2022.6527%2012.0883%2023.2302C10.3973%2023.6919%208.43888%2023.3132%207.36848%2021.8324C6.096%2020.0718%206.34416%2017.9948%206.8616%2016.1492C7.8192%2012.735%206.96384%2011.1073%206.1656%2010.6815C4.65408%209.87611%203.06816%2010.7886%202.36448%2011.7563C1.60224%2012.8046%201.14768%2014.7169%201.21968%2015.9409C1.26432%2016.7003%201.34592%2017.2878%201.49664%2017.8062%22%20fill%3D%22white%22%2F%3E%3Cpath%20d%3D%22M12%2024C18.6274%2024%2024%2018.6274%2024%2012C24%205.37258%2018.6274%200%2012%200C5.37258%200%200%205.37258%200%2012C0%2018.6274%205.37258%2024%2012%2024Z%22%20fill%3D%22%23E6FA36%22%2F%3E%3Cpath%20d%3D%22M15.8578%2018.914C16.2%2017.4428%2015.972%2015.9524%2015.3869%2014.5432C14.3851%2012.1302%2013.0541%2011.3752%2013.0099%209.28092C12.9955%208.59164%2013.0479%207.21788%2012%207.3182C11.0079%207.41324%2011.1307%208.5398%2011.3467%209.23772C11.6818%2010.3206%2012.5578%2011.2364%2013.3795%2012.6467C13.9949%2013.7022%2014.4024%2014.475%2014.4893%2015.6539C14.5795%2016.8774%2014.245%2018.2161%2013.5312%2019.286C12.8693%2020.2782%2011.4471%2021.2147%209.99313%2020.5336C9.46321%2020.2854%209.13969%2019.8265%208.98753%2019.3316C8.51089%2017.7784%209.12961%2016.2606%209.28513%2014.3512C9.54433%2011.1716%207.40017%206.80988%203.27649%208.82876C1.95217%209.47724%200.916332%2011.1726%200.475692%2012.747C0.315372%2013.3196%200.254412%2013.9326%200.272652%2014.5523C0.523212%2015.7081%200.939852%2016.802%201.49665%2017.8076C1.34593%2017.2888%201.26433%2016.7017%201.21969%2015.9424C1.14769%2014.7188%201.60273%2012.806%202.36449%2011.7577C3.06769%2010.79%204.65409%209.87708%206.16561%2010.683C6.96385%2011.1088%207.81921%2012.7364%206.86161%2016.1507C6.34369%2017.9968%206.09553%2020.0732%207.36849%2021.8339C8.43889%2023.3147%2010.3973%2023.6934%2012.0883%2023.2316C14.2032%2022.6532%2015.3768%2020.9843%2015.8578%2018.914Z%22%20fill%3D%22black%22%2F%3E%3Cpath%20d%3D%22M23.7182%2011.2782C23.8008%2010.984%2023.8565%2010.6787%2023.8891%2010.3676C23.8891%2010.3691%2023.8896%2010.37%2023.8896%2010.371C23.7206%209.12732%2023.3616%207.94412%2022.8422%206.85164C22.9051%207.21308%2022.9464%207.61484%2022.9737%208.08236C23.0457%209.30588%2022.5907%2011.2187%2021.8289%2012.267C21.1257%2013.2347%2019.5393%2014.1476%2018.0278%2013.3417C17.2296%2012.916%2016.3742%2011.2883%2017.3318%207.87404C17.8497%206.02796%2018.0979%203.95148%2016.8249%202.19084C15.7545%200.710036%2013.7961%200.331317%2012.1051%200.793076C9.99021%201.37052%208.81661%203.03948%208.33565%205.10972C7.99341%206.58092%208.22141%208.07132%208.80653%209.4806C9.80829%2011.8936%2011.1393%2012.6486%2011.1835%2014.7428C11.1979%2015.4321%2011.1456%2016.8059%2012.1934%2016.7056C13.1856%2016.6105%2013.0627%2015.484%2012.8467%2014.7865C12.5117%2013.7036%2011.6356%2012.7878%2010.8139%2011.3776C10.1985%2010.322%209.79101%209.54924%209.70365%208.37036C9.61341%207.14684%209.94797%205.80812%2010.6617%204.7382C11.3236%203.74604%2012.7459%202.80956%2014.1998%203.49068C14.7297%203.73884%2015.0532%204.19772%2015.2054%204.6926C15.682%206.24588%2015.0633%207.76364%2014.9078%209.67308C14.6486%2012.8526%2016.7928%2017.2144%2020.9165%2015.1955C22.2413%2014.548%2023.2776%2012.8521%2023.7182%2011.2782Z%22%20fill%3D%22black%22%2F%3E%3C%2Fg%3E%3Cdefs%3E%3CclipPath%20id%3D%22clip0_6759_209574%22%3E%3Crect%20width%3D%2224%22%20height%3D%2224%22%20fill%3D%22white%22%2F%3E%3C%2FclipPath%3E%3C%2Fdefs%3E%3C%2Fsvg%3E",name:"Squid"},{id:"across",logoURI:"data:image/svg+xml,%3Csvg%20width%3D%2232%22%20height%3D%2232%22%20viewBox%3D%220%200%2032%2032%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%20%20%3Crect%20width%3D%2232%22%20height%3D%2232%22%20rx%3D%2216%22%20fill%3D%22%236CF9D8%22%3E%3C%2Frect%3E%20%20%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20%20%20%20d%3D%22M6.95021%208.41988L8.50949%206.8606L14.7408%2013.0919C14.3626%2013.253%2014.0083%2013.4879%2013.6998%2013.7964C13.4609%2014.0353%2013.2662%2014.3017%2013.1157%2014.5853L6.95021%208.41988ZM12.9982%2017.4399L6.85803%2023.5801L8.41732%2025.1394L14.495%2019.0617C14.209%2018.9107%2013.9405%2018.7149%2013.6998%2018.4742C13.3932%2018.1675%2013.1593%2017.8156%2012.9982%2017.4399ZM17.5887%2019.0584L23.5826%2025.0522L25.1418%2023.493L19.0822%2017.4333C18.921%2017.8114%2018.6862%2018.1657%2018.3777%2018.4742C18.1388%2018.7131%2017.8724%2018.9079%2017.5887%2019.0584ZM18.9652%2014.5916L25.0497%208.50706L23.4904%206.94778L17.3434%2013.0947C17.7191%2013.2558%2018.071%2013.4897%2018.3777%2013.7964C18.6184%2014.037%2018.8142%2014.3055%2018.9652%2014.5916Z%22%20%20%20%20fill%3D%22%232D2E33%22%3E%3C%2Fpath%3E%3C%2Fsvg%3E",name:"Across"}];function zg({routeTagList:t}){const r=kr(),n={typography:"h6",borderRadius:4,px:8,py:4,ml:8};return ne.exports.jsx(ne.exports.Fragment,{children:t.map((t=>"no-approve"===t.type?ne.exports.jsxs(Sr,{sx:Object.assign(Object.assign({},n),{color:r.palette.text.primary,backgroundColor:r.palette.background.paperContrast,display:"flex",alignItems:"center"}),children:[ne.exports.jsx(i.Lock,{style:{color:r.palette.text.primary,width:14,height:14}}),ne.exports.jsx("span",{style:{marginLeft:4},children:ne.exports.jsx(e.Trans,{id:"Unapproved"})})]},t.type):"best-price"===t.type?ne.exports.jsx(Sr,{sx:Object.assign(Object.assign({},n),{color:r.palette.success.main,backgroundColor:Vr(r.palette.success.main,.1)}),children:ne.exports.jsx(e.Trans,{id:"Best offer"})},t.type):null))})}function Yg(e,t){let r=x.i18n._("s");return t||(r=e>=2?x.i18n._("Seconds"):x.i18n._("Second")),r}function Gg(e,t){let r="";return r=e>=2?t?x.i18n._("Mins"):x.i18n._("Minutes"):t?x.i18n._("Min"):x.i18n._("Minute"),r}function Xg(e){return e>=2?x.i18n._("Hours"):x.i18n._("Hour")}function Jg({start:e,end:t,showSecondUnit:r}){if(!e||!t)return null;const n=t-e,o=1e3,i=6e4,s=36e5,a=24*s;let l="",c="";if(n<i){const e=n/o;l=`${ms(e)} ${Yg(e,r)}`}else if(n<s){const e=n/i;l=`${ms(e)} ${Gg(e,r)}`;const t=n%i/o;c=`${ms(t)} ${Yg(t,r)}`}else if(n<a){const e=n/s;l=`${ms(e)} ${Xg(e)}`;const t=n%s/i;c=`${ms(t)} ${Gg(t)}`}else{const e=n/a;l=`${ms(e)} ${function(e){return e>=2?x.i18n._("Days"):x.i18n._("Day")}(e)}`;const t=n%a/s;c=`${ms(t)} ${Xg(t)}`}return r?`${l}${c}`.replaceAll(" ","").toLowerCase():l}function qg({chainId:t,token:r,amount:o}){var i;const s=kr(),a=n.useMemo((()=>Om[t]),[t]);return ne.exports.jsxs(Sr,{sx:{display:"flex",flexDirection:"column"},children:[ne.exports.jsxs(Sr,{sx:{mb:8,display:"flex",alignItems:"flex-end",alignSelf:"center"},children:[ne.exports.jsx(Im,{address:null!==(i=null==r?void 0:r.address)&&void 0!==i?i:"",marginRight:0,width:28,height:28,url:null==r?void 0:r.logoURI}),a?ne.exports.jsx(Sr,{component:a.logo,sx:{width:12,height:12,position:"relative",left:-6}}):""]}),ne.exports.jsxs(Sr,{sx:{color:s.palette.text.primary,typography:"body1",fontWeight:600,width:"100%",wordBreak:"break-word",textAlign:"center"},children:[us({input:o,decimals:null==r?void 0:r.decimals})," ",null==r?void 0:r.symbol]}),ne.exports.jsxs(Sr,{sx:{color:s.palette.text.secondary,typography:"h6",alignSelf:"center"},children:[ne.exports.jsx(e.Trans,{id:"on"})," ",a.name]})]})}function Qg({children:e}){const t=kr();return ne.exports.jsxs(Sr,{sx:{position:"relative",width:"calc(100% - 16px)",mx:"auto"},children:[ne.exports.jsx(Sr,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"100%",borderTopColor:t.palette.text.primary,borderTopWidth:1,borderTopStyle:"dashed","&:before":{content:'""',position:"absolute",left:0,top:-.5,backgroundColor:t.palette.text.primary,width:6,height:6,borderRadius:"50%",transform:"translate(-50%, -50%)"},"&:after":{display:{tablet:"block"},content:'""',position:"absolute",right:-1,top:-.5,width:0,height:0,transform:"translate(0, -50%)",borderTop:"4px solid transparent",borderBottom:"4px solid transparent",borderLeft:`6px solid ${t.palette.text.primary}`}}}),ne.exports.jsx(Sr,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"},children:e})]})}function Kg({size:e="medium",toolDetails:t,nameMarginLeft:r=4,logoMarginLeft:n=0,nameSx:o}){const i=kr();if(!t||!t.logoURI||!t.name)return null;const{logoURI:s,name:a}=t;return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Sr,{component:"img",src:s,alt:a,sx:{marginLeft:n,width:"large"===e?24:16,height:"large"===e?24:16}}),ne.exports.jsx(Sr,{sx:Object.assign({color:i.palette.text.primary,fontWeight:600,marginLeft:r,typography:{mobile:"small"===e?"h6":"medium"===e?"body2":"caption",tablet:"small"===e||"medium"===e?"body2":"caption"}},o),children:a})]})}function $g({fromToken:t,toToken:r,fromChainId:o,toChainId:s,fromAmount:a,fromTokenBalance:l,toTokenAmount:c,toolDetails:d,product:p,executionDuration:h,feeUSD:f,selected:m,setSelected:g,spenderContractAddress:y,isBestPrice:b}){const x=kr(),{account:v}=u.useWeb3React(),w=Hg.find((e=>e.id===p)),{getApprovalState:E}=Vg({account:v,chainId:o,contractAddress:y}),A=n.useMemo((()=>t&&a&&l?E(t,a,l):Ug.Loading),[t,a,l,E]),C=n.useMemo((()=>{const e=[];return b&&e.push({type:"best-price"}),A===Ug.Approving||A===Ug.Insufficient?[...e,{type:"no-approve"}]:e}),[A,b]);return ne.exports.jsxs(Sr,{sx:Object.assign({borderRadius:16,py:16,px:12,backgroundColor:x.palette.background.tag,cursor:"pointer","&:hover":{backgroundColor:"hover.default"},outline:0},m?{borderWidth:1,borderStyle:"solid",borderColor:x.palette.primary.main}:{}),onClick:g,children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:[ne.exports.jsx(Sr,{component:"img",src:null==w?void 0:w.logoURI,alt:null==w?void 0:w.name,sx:{width:16,height:16}}),ne.exports.jsx(Sr,{sx:{marginLeft:4},children:null==w?void 0:w.name}),ne.exports.jsx(zg,{routeTagList:C})]}),ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",mt:8,pb:8,borderStyle:"dashed",borderWidth:x.spacing(0,0,1,0),borderColor:x.palette.border.main},children:[ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Estimated transaction time"}),children:ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${x.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.Time,{style:{color:x.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Sr,{sx:{ml:4,lineHeight:1},children:null!==h?Jg({start:Date.now(),end:Date.now()+1e3*h}):"-"})]})}),ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Fee includes: Bridge fees + Swap fees. Gas fee not included."}),children:ne.exports.jsxs(Sr,{sx:{ml:8,display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${x.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.GasFee,{style:{color:x.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Sr,{sx:{ml:4,lineHeight:1},children:null!==f?`$${us({input:f,decimals:6})}`:"-"})]})})]}),ne.exports.jsxs(Sr,{sx:{display:"grid",gridTemplateColumns:"36% 28% 36%",mt:8},children:[ne.exports.jsx(qg,{token:t,chainId:o,amount:a}),ne.exports.jsx(Qg,{children:ne.exports.jsx(Sr,{sx:{display:"flex",px:3,py:3,backgroundColor:x.palette.background.paperContrast,border:`1px solid ${x.palette.border.main}`,borderRadius:"50%",alignItems:"center",width:24,height:24,overflow:"hidden"},children:ne.exports.jsx(Kg,{size:"medium",toolDetails:d,nameMarginLeft:8})})}),ne.exports.jsx(qg,{token:r,chainId:s,amount:c})]})]})}function ey({open:t,onClose:r,selectedRouteId:o,setSelectRouteId:i,bridgeRouteList:s}){const a=kr(),l=_h(),c=n.useMemo((()=>{if(!(null==s?void 0:s.length))return null;const{fromToken:e}=s[0];return l(e)}),[s,l]);return ne.exports.jsx(Pm,{open:t,onClose:r,title:ne.exports.jsx(e.Trans,{id:"Select Bridge"}),children:ne.exports.jsx(Sr,{sx:{position:"relative",display:"flex",flexDirection:"column",gap:12,py:20,px:16,flex:1,overflowY:"auto",overflowX:"hidden","&::before":{content:'""',position:"absolute",top:0,width:1,height:"1px",backgroundColor:a.palette.border.main}},children:null==s?void 0:s.map(((e,t)=>ne.exports.jsx($g,{fromChainId:e.fromChainId,toChainId:e.toChainId,fromToken:e.fromToken,toToken:e.toToken,fromAmount:e.fromAmount,fromTokenBalance:c,toTokenAmount:e.toTokenAmount,toolDetails:e.step.toolDetails,spenderContractAddress:e.spenderContractAddress,selected:o===e.id,setSelected:()=>{i(e.id),r()},isBestPrice:0===t,product:e.product,executionDuration:e.executionDuration,feeUSD:e.feeUSD},e.key)))})})}function ty({route:t,onClick:r}){var n,o;const s=kr();if(!t)return null;const{product:a,executionDuration:l,feeUSD:c,fromAmount:u,fromToken:d,fromChainId:p,toTokenAmount:h,toToken:f,toChainId:m}=t,g=Hg.find((e=>e.id===a)),y=Om[p],b=Om[m];return ne.exports.jsxs(Sr,{sx:{px:16,py:8,width:"100%",backgroundColor:"background.tag",borderRadius:12,cursor:"pointer","&:hover":{backgroundColor:"hover.default"}},onClick:r,children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:[ne.exports.jsx(Sr,{component:"img",src:null==g?void 0:g.logoURI,alt:null==g?void 0:g.name,sx:{width:16,height:16}}),ne.exports.jsx(Sr,{sx:{marginLeft:4,typography:"body2",fontWeight:600},children:null==g?void 0:g.name}),ne.exports.jsx(Sr,{sx:{display:"block",mx:8,width:"1px",height:12,backgroundColor:s.palette.border.main}}),ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",typography:"body2",fontWeight:600},children:[us({input:u,decimals:null==d?void 0:d.decimals}),ne.exports.jsxs(Sr,{sx:{ml:4,display:"flex",alignItems:"flex-end",alignSelf:"center",width:18,height:18},children:[ne.exports.jsx(Im,{address:null!==(n=null==d?void 0:d.address)&&void 0!==n?n:"",marginRight:0,width:18,height:18,url:null==d?void 0:d.logoURI}),y?ne.exports.jsx(Sr,{component:y.logo,sx:{position:"relative",left:-6,width:10,height:10,flexShrink:0}}):""]})]})," = ",ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",typography:"body2",fontWeight:600},children:[us({input:h,decimals:null==f?void 0:f.decimals}),ne.exports.jsxs(Sr,{sx:{ml:4,display:"flex",alignItems:"flex-end",alignSelf:"center",width:18,height:18},children:[ne.exports.jsx(Im,{address:null!==(o=null==f?void 0:f.address)&&void 0!==o?o:"",marginRight:0,width:18,height:18,url:null==f?void 0:f.logoURI}),b?ne.exports.jsx(Sr,{component:b.logo,sx:{width:10,height:10,position:"relative",left:-6,flexShrink:0}}):""]})]})]}),ne.exports.jsx(Sr,{component:i.ArrowRight,sx:{width:18,height:18}})]}),ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",mt:8},children:[ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Estimated transaction time"}),children:ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${s.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.Time,{style:{color:s.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Sr,{sx:{ml:4,lineHeight:1},children:null!==l?Jg({start:Date.now(),end:Date.now()+1e3*l}):"-"})]})}),ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Fee includes: Bridge fees + Swap fees. Gas fee not included."}),children:ne.exports.jsxs(Sr,{sx:{ml:8,display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${s.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.GasFee,{style:{color:s.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Sr,{sx:{ml:4,lineHeight:1},children:null!==c?`$${us({input:c,decimals:6})}`:"-"})]})})]})]})}function ry(){const{provider:e}=u.useWeb3React(),[r,o]=n.useState(),[i,s]=n.useState(!1),[a,c]=n.useState(""),{apikey:d}=l.useSelector(Uh),p=n.useCallback((({selectedRoute:r,fromEtherTokenBalance:n,goNext:i})=>ma(this,void 0,void 0,(function*(){var a,l;if(!r||!e||!n)return;const{encodeParams:u}=r;if(u){c(""),s(!0);try{const{fromToken:f,fromAmount:m,product:g}=r,y={product:g,encodeParams:u},b=(yield O.default.post(`${bg}?apikey=${d}`,{data:y})).data.data,{data:v,to:w,value:E,from:A,chainId:C}=b;if(!(v&&w&&E&&A&&C))throw new Error("cross_chain_swap_transactionEncode is null");const k=la[C],R=(p=E,h=18,new t.BigNumber(p).div(new t.BigNumber(10).pow(h))),T=k&&f.address.toLowerCase()===k.address.toLowerCase(),S=R.minus(T?m:0);if(!R.isNaN()&&R.gt(0)&&n.lt(R))return c(x.i18n._("Insufficient cross-chain fees, need at least {0} {1}",{0:us({input:S,decimals:null!==(a=null==k?void 0:k.decimals)&&void 0!==a?a:18}),1:null!==(l=null==k?void 0:k.symbol)&&void 0!==l?l:"-"})),void s(!1);if(!(yield qm({from:A,to:w,value:E,data:v},e)))throw new Error("failed to estimate gas");o({data:v,to:w,value:E,from:A,chainId:C}),i()}catch(e){console.error("[failed to construct transaction request]: ",e);const{message:t}=e;c(t)}var p,h;s(!1)}}))),[o,s,e]);return{apikey:d,sendRouteLoading:i,sendRouteError:a,setSendRouteError:c,bridgeOrderTxRequest:r,handleClickSend:p}}function ny({route:e,bridgeOrderTxRequest:t}){const{chainId:r,account:o}=u.useWeb3React(),s=sg(),{apikey:a}=l.useSelector(Uh);return n.useCallback((()=>{if(t&&e)try{const{fromToken:r,toToken:n,fromAmount:o,toTokenAmount:l,fromChainId:c,toChainId:u,toAddress:d,slippage:p,roundedRouteCostTime:h}=e,f=us({input:o,decimals:r.decimals}),m=us({input:l,decimals:n.decimals}),g=ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Im,{token:r,sx:{width:16,height:16,mr:6},chainId:r.chainId}),`${f} ${null==r?void 0:r.symbol}`,ne.exports.jsx(Sr,{component:i.DoubleRight,sx:{width:12,height:12,mx:16}}),ne.exports.jsx(Im,{token:n,sx:{width:16,height:16,mr:6}}),`${m} ${null==n?void 0:n.symbol}`]}),y=(t,r)=>ma(this,void 0,void 0,(function*(){const n=yield function({apikey:e,tx:t,route:r}){return ma(this,void 0,void 0,(function*(){const{fromChainId:n,toChainId:o,fromAmount:i,fromToken:s,toToken:a,fromAddress:l,toAddress:c,slippage:u,product:d,step:p,sourceRoute:h,productParams:f}=r,{toAmount:m}=h,g={fromChainId:n,fromAmount:fs(i,s.decimals).toString(),fromTokenAddress:s.address,toChainId:o,toAmount:m,toTokenAddress:a.address,fromAddress:l,toAddress:c,slippage:u,hash:t,product:d,extend:{lifiBridge:p.tool,route:h,productParams:f}},y=(yield O.default.post(`${xg}?apikey=${e}`,{data:g})).data.data;return null==y?void 0:y.id}))}({apikey:a,tx:t,route:e});r&&r(t,{orderId:n})})),b={fromChainId:c,toChainId:u,fromTokenAddress:r.address,toTokenAddress:n.address,fromTokenSymbol:r.symbol,toTokenSymbol:n.symbol,fromTokenAmount:o,toTokenAmount:l.toString(),slippage:p,sendAccount:d,roundedRouteCostTime:h};return s.execute(x.i18n._("Bridge"),Object.assign({opcode:Km.TX},t),g,!1,void 0,Object.assign(Object.assign(Object.assign({},t),{fromToken:r,toToken:n,pay:f,receive:m}),b),void 0,y)}catch(e){console.error(e)}}),[o,r,e,t,a])}function oy({chainId:e,address:t,children:r}){const n=kr();return ne.exports.jsxs(Sr,{component:"a",href:pa(`tx/${t}`,e),target:"_blank",rel:"noopener noreferrer",sx:{color:n.palette.text.secondary,"&:hover":{color:n.palette.text.primary},display:"flex",alignItems:"center",typography:"body2"},children:[r,ne.exports.jsx(Sr,{component:"svg",viewBox:"0 0 16 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",sx:{marginLeft:6,width:16,height:17},children:ne.exports.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M3.33333 3.83333V13.1667H12.6667V8.5H14V13.1667C14 13.9 13.4 14.5 12.6667 14.5H3.33333C2.59333 14.5 2 13.9 2 13.1667V3.83333C2 3.1 2.59333 2.5 3.33333 2.5H8V3.83333H3.33333ZM9.33333 3.83333V2.5H14V7.16667H12.6667V4.77333L6.11333 11.3267L5.17333 10.3867L11.7267 3.83333H9.33333Z",fill:"currentColor"})})]})}function iy({fromChainId:t,toChainId:r,fromTokenAmount:o,toTokenAmount:i,fromTokenDecimals:s,fromTokenSymbol:a,toTokenDecimals:l,toTokenSymbol:c,fromHash:u,toHash:d,toolDetails:p}){const h=kr(),[f,m]=n.useMemo((()=>[Om[t],Om[r]]),[t,r]);return ne.exports.jsxs(Sr,{sx:{borderLeft:`1px dashed ${h.palette.text.primary}`,opacity:d?1:.5,pb:24},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"flex-start",flexWrap:{mobile:"wrap",tablet:"nowrap"}},children:[ne.exports.jsx(Sr,{component:"img",src:p.logoURI,alt:p.name,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:{mobile:h.palette.background.paper,tablet:h.palette.background.paper},alignSelf:"flex-start"}}),ne.exports.jsx(Sr,{sx:{ml:8,typography:"body1"},children:p.name}),ne.exports.jsxs(Sr,{sx:{typography:"body2",marginLeft:"auto",display:"flex",alignItems:"center",justifyContent:"flex-end",width:{mobile:"100%",tablet:"auto"},mt:{mobile:8,tablet:0}},children:[us({input:o,decimals:s})," ",a,ne.exports.jsx("span",{style:{marginLeft:4,color:h.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"On"})}),ne.exports.jsx(Sr,{component:null==f?void 0:f.logo,sx:{marginLeft:4,width:18,height:18}}),ne.exports.jsx("span",{style:{marginLeft:4,marginRight:4,color:h.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"To"})}),us({input:i,decimals:l})," ",c,ne.exports.jsx("span",{style:{marginLeft:4,color:h.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"On"})}),ne.exports.jsx(Sr,{component:null==m?void 0:m.logo,sx:{marginLeft:4,width:18,height:18}})]})]}),ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-end",mt:{mobile:8,tablet:5}},children:[ne.exports.jsx(oy,{chainId:t,address:u,children:ne.exports.jsx(e.Trans,{id:"Source"})}),ne.exports.jsx(Sr,{sx:{width:16}}),ne.exports.jsx(oy,{chainId:r,address:d,children:ne.exports.jsx(e.Trans,{id:"Destination"})})]})]})}function sy({chainId:t,fromTokenAmount:r,toTokenAmount:o,fromTokenDecimals:i,fromTokenSymbol:s,toTokenDecimals:a,toTokenSymbol:l,hash:c,toolDetails:u}){const d=kr(),p=n.useMemo((()=>Om[t]),[t]);return ne.exports.jsxs(Sr,{sx:{borderLeft:`1px dashed ${d.palette.text.primary}`,opacity:c?1:.5,pb:24},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"flex-start",flexWrap:{mobile:"wrap",tablet:"nowrap"}},children:[ne.exports.jsx(Sr,{component:"img",src:u.logoURI,alt:u.name,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:d.palette.background.paper,alignSelf:"flex-start"}}),ne.exports.jsx(Sr,{sx:{ml:8,typography:"body1"},children:u.name}),ne.exports.jsxs(Sr,{sx:{typography:"body2",marginLeft:"auto",display:"flex",alignItems:"center",justifyContent:"flex-end",width:{mobile:"100%",tablet:"auto"},mt:{mobile:8,tablet:0}},children:[us({input:r,decimals:i})," ",s,ne.exports.jsx("span",{style:{marginLeft:4,marginRight:4,color:d.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"For"})}),us({input:o,decimals:a})," ",l,ne.exports.jsxs(Sr,{sx:{alignItems:"center",display:{mobile:"none",tablet:"flex"}},children:[ne.exports.jsx("span",{style:{marginLeft:4,color:d.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"on"})}),ne.exports.jsx(Sr,{component:null==p?void 0:p.logo,sx:{marginLeft:4,width:18,height:18}}),ne.exports.jsx(Sr,{component:"span",sx:{ml:4},children:p.name})]})]})]}),ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-end",typography:"body2",mt:{mobile:8,tablet:5}},children:[ne.exports.jsxs(Sr,{sx:{alignItems:"center",display:{mobile:"flex",tablet:"none"}},children:[ne.exports.jsx("span",{style:{color:d.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"on"})}),ne.exports.jsx(Sr,{component:null==p?void 0:p.logo,sx:{marginLeft:4,width:18,height:18}}),ne.exports.jsx(Sr,{component:"span",sx:{ml:4,mr:8},children:p.name})]}),ne.exports.jsx(oy,{chainId:t,address:c,children:ne.exports.jsx(e.Trans,{id:"Tx"})})]})]})}function ay({marginTop:e=20,route:t}){const r=kr(),{fromChainId:o,toChainId:i}=t,{step:{includedSteps:s}}=t,[a,l]=n.useMemo((()=>[Om[o],Om[i]]),[o,i]);return ne.exports.jsxs(Sr,{sx:{mt:e,pl:10},children:[ne.exports.jsx(Sr,{sx:{borderLeft:`1px dashed ${r.palette.text.primary}`,opacity:1,pb:24},children:ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"flex-start"},children:[ne.exports.jsx(Sr,{component:null==a?void 0:a.logo,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:r.palette.background.paper}}),ne.exports.jsx(Sr,{sx:{ml:8,typography:"body1"},children:a.name})]})}),s.map(((e,t)=>{const{toolDetails:r,type:n,estimate:o}=e;return"swap"===n?ne.exports.jsx(sy,{chainId:o.fromToken.chainId,fromTokenAmount:o.fromTokenAmount,toTokenAmount:o.toTokenAmount,fromTokenDecimals:o.fromToken.decimals,fromTokenSymbol:o.fromToken.symbol,toTokenDecimals:o.toToken.decimals,toTokenSymbol:o.toToken.symbol,hash:null,toolDetails:r},t):"cross"===n?ne.exports.jsx(iy,{fromChainId:o.fromToken.chainId,toChainId:o.toToken.chainId,fromTokenAmount:o.fromTokenAmount,toTokenAmount:o.toTokenAmount,fromTokenDecimals:o.fromToken.decimals,fromTokenSymbol:o.fromToken.symbol,toTokenDecimals:o.toToken.decimals,toTokenSymbol:o.toToken.symbol,fromHash:null,toHash:null,toolDetails:r},t):null})),ne.exports.jsx(Sr,{sx:{opacity:.5,pb:0},children:ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"flex-start"},children:[ne.exports.jsx(Sr,{component:null==l?void 0:l.logo,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:r.palette.background.paper}}),ne.exports.jsx(Sr,{sx:{ml:8,typography:"body1"},children:l.name})]})})]})}function ly({route:t}){const r=kr(),o=Om[t.fromChainId],s=n.useMemo((()=>pa(`address/${t.fromAddress}`,t.fromChainId)),[t.fromAddress,t.fromChainId]);return ne.exports.jsxs(Sr,{children:[ne.exports.jsx(Sr,{sx:{py:12,borderStyle:"solid",borderWidth:r.spacing(1,0,0),borderColor:r.palette.border.main},children:ne.exports.jsx(Qi,{children:ne.exports.jsx(ls,{initialEntered:!0,sx:{"& button.active svg":{transform:"rotate(0)"}},header:ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",typography:"body2"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Sr,{component:i.DetailBorder,sx:{mr:6,width:18,height:18}}),ne.exports.jsx(e.Trans,{id:"Detail"})]}),ne.exports.jsx(Sr,{component:i.CaretUp,sx:{width:12,height:12,color:"text.secondary",transform:"rotate(180deg)",transition:"transform 0.2s linear"}})]}),children:ne.exports.jsxs(Sr,{sx:{mt:16},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsx(Sr,{sx:{typography:"body2",color:"text.secondary",flexShrink:0},children:ne.exports.jsx(e.Trans,{id:"Send to:"})}),ne.exports.jsxs(Sr,{sx:{display:"flex",justifyContent:"flex-end",alignItems:"center"},children:[o?ne.exports.jsx(Sr,{component:o.logo,sx:{width:18,height:18}}):"",ne.exports.jsx(Sr,{sx:{display:"inline-block",mx:6,width:"1px",height:12,backgroundColor:"border.main"}}),ne.exports.jsx(Sr,{sx:{typography:"body2",fontWeight:600},children:(a=t.fromAddress,a.length<=10?a:`${a.slice(0,6)}...${a.slice(a.length-4,a.length)}`)}),ne.exports.jsx(In,{component:"a",href:s,target:"_blank",rel:"noopener noreferrer",sx:{ml:6,width:18,height:18,color:"text.secondary"},children:ne.exports.jsx(Sr,{component:i.ArrowTopRightBorder,sx:{width:18,height:18}})})]})]}),t.feeUSD?ne.exports.jsxs(Sr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsx(Sr,{sx:{display:"flex",alignItems:"center",typography:"body2",color:"text.secondary",flexShrink:0},children:ne.exports.jsx(e.Trans,{id:"Fee"})}),ne.exports.jsxs(Sr,{sx:{typography:"body2"},children:["$",cs({input:t.feeUSD})]})]}):"",ne.exports.jsxs(Sr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",typography:"body2",color:"text.secondary",flexShrink:0},children:[ne.exports.jsx(e.Trans,{id:"Slippage"}),ne.exports.jsx(Fg,{onlyHover:!0,title:ne.exports.jsx(e.Trans,{id:"Attention: High slippage tolerance will increase the success rate of transaction, but might not get the best quote."}),ml:6})]}),ne.exports.jsxs(Sr,{sx:{typography:"body2"},children:[100*t.slippage,"%"]})]})]})})})}),ne.exports.jsx(Sr,{sx:{py:12,borderStyle:"solid",borderWidth:r.spacing(1,0,0),borderColor:r.palette.border.main},children:ne.exports.jsx(Qi,{children:ne.exports.jsx(ls,{initialEntered:!0,sx:{"& button.active svg":{transform:"rotate(0)"}},header:ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",typography:"body2"},children:[ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Sr,{component:i.DetailBorder,sx:{mr:6,width:18,height:18}}),ne.exports.jsx(e.Trans,{id:"Estimated Time"})]}),ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[t.executionDuration?Jg({start:Date.now(),end:Date.now()+1e3*t.executionDuration}):"-",ne.exports.jsx(Sr,{component:i.CaretUp,sx:{ml:6,width:12,height:12,color:"text.secondary",transform:"rotate(180deg)",transition:"transform 0.2s linear"}})]})]}),children:ne.exports.jsx(ay,{route:t})})})})]});var a}function cy({open:t,onClose:r,route:o,bridgeOrderTxRequest:i,clearToAmt:s,clearFromAmt:a}){const c=kr(),{contractStatus:u}=l.useSelector(Uh),d=l.useDispatch(),p=ny({route:o,bridgeOrderTxRequest:i});return n.useEffect((()=>{u!==wh.Pending&&r(),u===wh.TxSuccess&&(s(),a())}),[u]),ne.exports.jsx(Pm,{title:ne.exports.jsx(e.Trans,{id:"Bridge Summary"}),open:t,onClose:()=>{d(tg({contractStatus:wh.Initial})),r()},children:ne.exports.jsxs(ne.exports.Fragment,{children:[o?ne.exports.jsxs(Sr,{sx:{px:16,pb:20,flex:1,overflowY:"auto"},children:[ne.exports.jsxs(Sr,{sx:{display:"grid",gridTemplateColumns:"36% 28% 36%",py:20,borderStyle:"solid",borderWidth:c.spacing(1,0,0),borderColor:c.palette.border.main},children:[ne.exports.jsx(qg,{token:o.fromToken,chainId:o.fromChainId,amount:o.fromAmount}),ne.exports.jsx(Qg,{children:ne.exports.jsx(Sr,{sx:{display:"flex",px:3,py:3,backgroundColor:c.palette.background.paperContrast,border:`1px solid ${c.palette.border.main}`,borderRadius:"50%",alignItems:"center",width:24,height:24,overflow:"hidden"},children:ne.exports.jsx(Kg,{size:"medium",toolDetails:o.step.toolDetails,nameMarginLeft:8})})}),ne.exports.jsx(qg,{token:o.toToken,chainId:o.toChainId,amount:o.toTokenAmount})]}),ne.exports.jsx(ly,{route:o})]}):"",ne.exports.jsx(Sr,{sx:{px:16,py:20},children:ne.exports.jsx(xn,{fullWidth:!0,isLoading:u==wh.Pending,disabled:!o,onClick:()=>{p(),d(tg({contractStatus:wh.Pending}))},children:u==wh.Pending?ne.exports.jsx(e.Trans,{id:"Confirming"}):ne.exports.jsx(e.Trans,{id:"Confirm Bridge"})})})]})})}function uy({message:t,onClose:r}){return ne.exports.jsx(Pm,{open:!!t,onClose:r,children:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsxs(Sr,{sx:{flex:1,textAlign:"center"},children:[ne.exports.jsx(Sr,{component:i.ErrorWarn,sx:{mt:60,width:64,height:64,color:"error.main"}}),t?ne.exports.jsxs(Sr,{sx:{textAlign:"center",mt:60},children:[ne.exports.jsx(Sr,{children:ne.exports.jsx(e.Trans,{id:"Something went wrong."})}),ne.exports.jsx(Sr,{sx:{color:"text.secondary",mt:12,typography:"body2",wordBreak:"break-all"},children:t})]}):""]}),ne.exports.jsx(Sr,{sx:{px:16,py:20},children:ne.exports.jsx(xn,{onClick:r,fullWidth:!0,children:ne.exports.jsx(e.Trans,{id:"Dismiss"})})})]})})}function dy(){var t,o,s;const a=kr(),{isInflight:c}=og(),{chainId:d,account:p}=u.useWeb3React(),h=l.useDispatch(),{isReverseRouting:f}=l.useSelector(Uh),m=l.useSelector(Sh),g=l.useSelector(Ph),b=l.useSelector(Bh),{isETH:x}=n.useMemo((()=>ha(d)),[d]),v=n.useMemo((()=>{var e;return null===(e=la[null!=d?d:m])||void 0===e?void 0:e.address}),[d]),[w,E]=n.useState(""),[A,C]=n.useState(""),[R,T]=n.useState(""),[S,N]=n.useState(""),M=n.useMemo((()=>r.debounce((e=>T(e)),1e3)),[]),F=n.useMemo((()=>r.debounce((e=>N(e)),1e3)),[]),[I,j]=n.useState(null),[D,B]=n.useState(null),[P,W]=n.useState(!1),[_,U]=n.useState(!1),L=n.useMemo((()=>!(!(null==I?void 0:I.chainId)||!(null==D?void 0:D.chainId)||I.chainId===D.chainId)),[I,D]),{toFiatPrice:V,fromFiatPrice:Z}=wg({chainId:d,toToken:D,fromToken:I}),H=_h(),z=n.useMemo((()=>I?H(I):null),[I,H]),Y=n.useMemo((()=>{const e=null==I?void 0:I.chainId;if(!L||!e)return null;const t=la[e];return t?H(Object.assign(Object.assign({},t),{chainId:e})):null}),[L,null==I?void 0:I.chainId,H]),{marginAmount:G}=function({token:e,fiatPrice:t}){return{marginAmount:n.useMemo((()=>{var r;const n=null!==(r=null==e?void 0:e.decimals)&&void 0!==r?r:6,o=null!=t?new k.default(500).div(t):new k.default(0),i=fs(o,n);return(i.lt(new k.default(1).times(new k.default(10).pow(n-3)))?new k.default(0):i).toString(10)}),[null==e?void 0:e.decimals,t])}}({token:f?D:I,fiatPrice:f?V:Z}),{resAmount:X,priceImpact:J,executeSwap:q,baseFeeAmount:Q,additionalFeeAmount:K,resPricePerToToken:$,resPricePerFromToken:ee,status:te}=Rg({toToken:D,fromToken:I,marginAmount:G,fromAmount:R,toAmount:S}),{bridgeRouteList:re,status:oe}=function({toToken:e,fromToken:t,fromAmount:r}){const{account:o,provider:i}=u.useWeb3React(),s=l.useSelector(Eg)||.5,{apikey:a}=l.useSelector(Uh),[c,d]=n.useState(Zg.Initial),[p,h]=n.useState([]),f=n.useCallback((()=>ma(this,void 0,void 0,(function*(){var n;const l=null==t?void 0:t.chainId,c=null==e?void 0:e.chainId;if(!(l&&c&&l!==c&&t&&e&&r))return void d(Zg.Initial);d(Zg.Loading);const u=t.address,p=e.address,f=o||Cg,m=o||Cg,g=Number(s),b={fromAddress:f,fromAmount:y.parseFixed(String(r||1),t.decimals).toString(),fromChainId:l,fromTokenAddress:u,toAddress:m,toChainId:c,toTokenAddress:p,options:{slippage:g},products:["lifi","hyphen","nabox","bungee","swft","stargate","connext","squid","across"]};try{const s=Date.now(),u=(yield O.default.post(`${yg}?apikey=${a}`,{data:b})).data.data,p=[];if((null===(n=null==u?void 0:u.routes)||void 0===n?void 0:n.length)&&u.routes.forEach(((n,o)=>{if(n){const{toAmount:i,feeUSD:a,executionDuration:u,product:d,step:h,encodeParams:y,productParams:b}=n;if(h&&null!==i){const n=new k.default(i);if(!n.isNaN()&&n.gt(0)){const{tool:x,toolDetails:v,type:w,includedSteps:E,approvalAddress:A}=h;if(E&&E.length>0&&x&&v&&v.name&&v.logoURI&&w&&A){const h=[];if(E.forEach((e=>{e&&e.id&&e.type&&e.tool&&e.toolDetails&&e.toolDetails.name&&e.toolDetails.logoURI&&e.estimate&&e.estimate.fromAmount&&e.estimate.fromToken&&e.estimate.fromToken.decimals&&e.estimate.toAmount&&e.estimate.toToken&&e.estimate.toToken.decimals&&h.push({id:e.id,tool:e.tool,toolDetails:{name:e.toolDetails.name,logoURI:e.toolDetails.logoURI},type:e.type,estimate:{fromToken:e.estimate.fromToken,toToken:e.estimate.toToken,fromTokenAmount:new k.default(e.estimate.fromAmount).div(`1e${e.estimate.fromToken.decimals}`),toTokenAmount:new k.default(e.estimate.toAmount).div(`1e${e.estimate.toToken.decimals}`)}})})),h.length>0){const C={key:`${d}-${i}-${a}-${o}`,id:d,fromChainId:l,toChainId:c,fromToken:t,toToken:e,fromAmount:r,toTokenAmount:n.div(`1e${e.decimals}`),fromAddress:f,toAddress:m,product:d,slippage:g,roundedRouteCostTime:(Date.now()-s)/1e3,spenderContractAddress:null!=A?A:"0x",feeUSD:a,executionDuration:u,step:{tool:x,toolDetails:{name:v.name,logoURI:v.logoURI},type:w,includedSteps:h},encodeParams:y,productParams:b,sourceRoute:{toAmount:i,feeUSD:a,executionDuration:u,step:{tool:x,toolDetails:v,type:w,approvalAddress:A,includedSteps:E}}};p.push(C)}}}}}})),h(p),p.length?d(Zg.Success):d(Zg.Failed),!o||!i)return}catch(e){d(Zg.Failed),console.error(e)}}))),[o,e,s,t,i,r,a]);return vg({refetch:f}),{status:c,refetch:f,bridgeRouteList:n.useMemo((()=>r?p:[]),[c,r,p])}}({toToken:D,fromToken:I,fromAmount:R}),[ie,se]=n.useState(!1),[ae,le]=n.useState(""),ce=n.useMemo((()=>!ae&&re.length?re[0].id:ae),[ae,re]),ue=n.useMemo((()=>re.find((e=>e.id===ce))),[re,ce]);n.useEffect((()=>{!ue&&ae&&le("")}),[ue]);const{sendRouteLoading:de,sendRouteError:pe,setSendRouteError:he,bridgeOrderTxRequest:fe,handleClickSend:me}=ry(),[ge,ye]=n.useState(!1),be=function(e){const t=n.useRef(!1),[r,o]=n.useState(!1),i=l.useDispatch();return n.useEffect((()=>{if(!t.current)return void(t.current=!0);i(fg((e?.5:3).toString())),o(!0);const r=setTimeout((()=>{o(!1)}),3e3);return()=>{clearTimeout(r)}}),[e]),r}(L),{getApprovalState:xe,submitApprove:ve,getPendingRest:we,getMaxBalance:Ee}=Vg({account:p,chainId:null!==(t=null==I?void 0:I.chainId)&&void 0!==t?t:d,contractAddress:null==ue?void 0:ue.spenderContractAddress}),Ae=n.useMemo((()=>we(f?D:I)),[null==I?void 0:I.address,null==D?void 0:D.address,we,f]),Ce=n.useCallback((e=>{const t=e.toString();E(t),M(t)}),[E,M]),ke=n.useCallback((e=>{const t=e.toString();C(t),F(t)}),[C,F]),Re=l.useSelector(Ih),Te=()=>{let e=null;I||b&&b.chainId===d||Re.some((t=>!(t.chainId!==d||t.side&&"from"!==t.side)&&(e=t,j(t),!0))),D||g&&g.chainId===d||Re.some((t=>!(t.chainId!==d||e&&e.address===t.address||t.side&&"to"!==t.side)&&(B(t),!0)))},Se=n.useRef(d);n.useEffect((()=>{void 0===Se.current&&d&&(Se.current=d,d&&(B(null),j(null),f?ke(""):Ce("")),b&&b.chainId===d&&(j(b),b.amount&&(h(tg({isReverseRouting:!1})),Ce(b.amount))),g&&g.chainId===d&&(B(g),g.amount&&b&&!b.amount&&(h(tg({isReverseRouting:!0})),ke(g.amount))),Te())}),[g,b,d,Ce,ke]),n.useEffect((()=>{Te()}),[Re]);const Ne=n.useCallback((()=>{Ce(""),ke(""),j(D),B(I),le("")}),[j,D,B,I,Ce,ke,le]),Me=n.useCallback((e=>f?ke(Ee(D)):Ce(Ee(I))),[Ce,ke,Ee,I,D,f]),Fe=n.useMemo((()=>(100*Number(J)).toFixed(2)),[J]),Oe=n.useMemo((()=>{const e=f?X:R;return e&&Z?new k.default(Z).multipliedBy(e):null}),[Z,R,f,X]),Ie=n.useMemo((()=>{var e;if(!V)return null;if(L)return(null===(e=null==ue?void 0:ue.toTokenAmount)||void 0===e?void 0:e.gt(0))?ue.toTokenAmount.multipliedBy(V):null;const t=f?S:X;return t?new k.default(V).multipliedBy(t):null}),[V,S,f,X,ue,L]),je=n.useMemo((()=>ne.exports.jsxs(Sr,{sx:{display:"flex",fontWeight:600,typography:"body2",alignItems:"center",justifyContent:"center"},children:[ne.exports.jsx(Fg,{title:ne.exports.jsx(e.Trans,{id:"Due to the market condition, market price and estimated price may have a slight difference"}),mr:8}),ne.exports.jsxs(Sr,{sx:{display:"flex"},children:[ne.exports.jsx(e.Trans,{id:"Current price impact"}),ne.exports.jsxs(Sr,{sx:{color:a.palette.error.main,ml:4},children:[Fe,"%"]})]})]})),[Fe]),De=n.useMemo((()=>ne.exports.jsx(Bg,{toToken:D,fromToken:I,priceStatus:te,pricePerToToken:$,pricePerFromToken:ee})),[D,I,te,$,ee]),Be=n.useMemo((()=>!ia[d||1]),[d]),Pe=n.useMemo((()=>d&&!!(null==I?void 0:I.chainId)&&(null==I?void 0:I.chainId)!==d),[d,null==I?void 0:I.chainId]),We=n.useMemo((()=>Pe?ne.exports.jsxs(Sr,{sx:{textAlign:"center"},children:[ne.exports.jsx(Sr,{component:i.Warn,sx:{position:"relative",top:2,mr:6,width:16,height:16,color:"warning.main"}}),ne.exports.jsx(e.Trans,{id:"The current network is inconsistent with the wallet - please switch in wallet"})]}):te===kg.Loading||L&&oe===kg.Loading?ne.exports.jsx(Sr,{sx:{display:"flex",justifyContent:"center",alignItems:"center"},children:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Dn,{sx:{mr:5}}),ne.exports.jsx(e.Trans,{id:"Fetching best price..."})]})}):Be?ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Sr,{component:i.Warn,sx:{mr:6,width:16,color:"warning.main"}}),ne.exports.jsx(e.Trans,{id:"Unsupported network - switch to trade"})]}):!L&&w&&new k.default(Fe).gt(15)?je:L&&re.length?ne.exports.jsx(ty,{route:ue,onClick:()=>se(!0)}):De),[te,De,w,je,Fe,Be,L,oe,re,ue,Pe]),_e=n.useMemo((()=>f?new k.default(A).gt(0)?us({input:X,decimals:null==I?void 0:I.decimals}):"-":w),[w,A,X,I,f]),Ue=n.useMemo((()=>{var e;return f?A:L?(null===(e=null==ue?void 0:ue.toTokenAmount)||void 0===e?void 0:e.gt(0))&&oe!==kg.Loading?us({input:ue.toTokenAmount,decimals:null==D?void 0:D.decimals}):"-":new k.default(w).gt(0)?us({input:X,decimals:null==D?void 0:D.decimals}):"-"}),[w,A,X,D,f,ue,L,oe]),Le=n.useMemo((()=>{const t=xe(I,f?X||0:R),r=t===Ug.Approving,n=t===Ug.Insufficient&&!Ae,o=x?.1:.02,i=v===(null==I?void 0:I.address),s=new k.default(z||0);if(!p)return ne.exports.jsx(Wg,{});if(c)return ne.exports.jsx(xn,{fullWidth:!0,isLoading:!0,disabled:!0,children:ne.exports.jsx(e.Trans,{id:"Transaction Pending"})});if(!I||!D)return ne.exports.jsx(xn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-select-token-btn",children:ne.exports.jsx(e.Trans,{id:"Select Tokens"})});if(n)return ne.exports.jsx(xn,{fullWidth:!0,disabled:r,onClick:()=>ve(I),children:r?ne.exports.jsx(e.Trans,{id:"Approving"}):ne.exports.jsx(e.Trans,{id:"Approve"})});if(!new k.default(f?S:R).gt(0))return ne.exports.jsx(xn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-enter-amount-btn",children:ne.exports.jsx(e.Trans,{id:"Enter an amount"})});if(L?oe===kg.Loading||t===Ug.Loading:te===kg.Loading)return ne.exports.jsx(xn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-fetch-price-btn",children:ne.exports.jsx(e.Trans,{id:"Fetching Price..."})});let a=!1;return a=L?!re.length||oe===kg.Failed:!X||te===kg.Failed,a?ne.exports.jsx(xn,{fullWidth:!0,disabled:!0,children:ne.exports.jsx(e.Trans,{id:"Quote not available"})}):s.lt(f?null!=X?X:0:R)||i&&s.lte(o)?ne.exports.jsx(xn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-insufficient-balance-btn",children:ne.exports.jsx(e.Trans,{id:"Insufficient balance"})}):L?ne.exports.jsx(xn,{fullWidth:!0,onClick:()=>me({selectedRoute:ue,fromEtherTokenBalance:Y,goNext:()=>ye(!0)}),"data-testid":"swap-review-btn",isLoading:de,children:ne.exports.jsx(e.Trans,{id:"Review Bridge"})}):ne.exports.jsx(xn,{fullWidth:!0,onClick:()=>W(!0),"data-testid":"swap-review-btn",children:ne.exports.jsx(e.Trans,{id:"Review Swap"})})}),[x,p,S,R,D,X,I,c,q,Ae,ve,te,z,xe,v,f,L,oe,re,de,Y]),Ve=n.useMemo((()=>I&&D?ne.exports.jsxs(Sr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Im,{token:I,sx:{width:16,height:16,mr:6},chainId:I.chainId}),`${us({input:f?X:R,decimals:null==I?void 0:I.decimals})} ${null==I?void 0:I.symbol}`,ne.exports.jsx(Sr,{component:i.DoubleRight,sx:{width:12,height:12,mx:16}}),ne.exports.jsx(Im,{token:D,sx:{width:16,height:16,mr:6},chainId:D.chainId}),`${us({input:f?S:X,decimals:null==D?void 0:D.decimals})} ${null==D?void 0:D.symbol}`]}):ne.exports.jsx(Sr,{})),[I,D,R,S,X,f]);return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsxs(Sr,{sx:{display:"flex",justifyContent:"space-between",typography:"caption",margin:20},children:[ne.exports.jsx(e.Trans,{id:"Swap"}),ne.exports.jsx(ui,{open:be,title:L?ne.exports.jsx(e.Trans,{id:"The setting has been switched to bridge mode"}):ne.exports.jsx(e.Trans,{id:"The setting has been switched to swap mode"}),placement:"bottom-end",children:ne.exports.jsx(Sr,{component:wn,children:ne.exports.jsx(Sr,{component:i.Setting,onClick:()=>U(!0),sx:{width:19,height:19,color:"text.primary",cursor:"pointer"}})})})]}),ne.exports.jsxs(Sr,{sx:{flex:1,padding:"0 20px 20px",overflowY:"auto"},children:[ne.exports.jsxs(Sr,{children:[ne.exports.jsx(Mg,{sx:{mb:4},token:I,side:"from",amt:_e,defaultLoadBalance:!0,onlyCurrentChain:!0,onMaxClick:Me,onInputChange:Ce,onInputFocus:()=>{f&&Ce(""),h(tg({isReverseRouting:!1}))},showMaxBtn:!f&&!w,occupiedAddrs:[null!==(o=null==D?void 0:D.address)&&void 0!==o?o:""],fiatPriceTxt:Oe?`$${cs({input:Oe,showDecimals:1})}`:"-",onTokenChange:(e,t)=>{if(t)return Ne();Ce(""),ke(""),j(e),le("")},readOnly:f,showChainLogo:!0}),ne.exports.jsx(Og,{onClick:Ne}),ne.exports.jsx(Mg,{token:D,side:"to",amt:Ue,onInputChange:ke,onInputFocus:()=>{f||ke(""),h(tg({isReverseRouting:!0}))},occupiedAddrs:[null!==(s=null==I?void 0:I.address)&&void 0!==s?s:""],fiatPriceTxt:Ie?`$${cs({input:Ie,showDecimals:1})}(${Fe}%)`:"-",onTokenChange:(e,t)=>{if(t)return Ne();Ce(""),ke(""),B(e),le("")},readOnly:L||!f,showChainLogo:!0}),ne.exports.jsx(Sr,{sx:{py:12,display:"flex",typography:"body2",alignItems:"center",justifyContent:"center",flexWrap:"wrap"},children:We})]}),Le,ne.exports.jsxs(Sr,{sx:{mt:13,display:"flex",typography:"h6",cursor:"pointer",justifyContent:"center",alignItems:"center",color:a.palette.text.disabled},onClick:()=>window.open("https://app.dodoex.io"),children:[ne.exports.jsx(Sr,{sx:{width:24,typography:"body2",transform:"translate(1px, 2px)","& path":{fill:a.palette.text.disabled}},component:i.Dodo}),ne.exports.jsx(e.Trans,{id:"Powered by DODO protocol"})]})]}),ne.exports.jsx(Ig,{toToken:D,fromToken:I,fromAmount:f?X:R,toAmount:f?S:X,open:P,baseFeeAmount:Q,priceImpact:Fe,additionalFeeAmount:K,curToFiatPrice:Ie,execute:()=>q(Ve),clearFromAmt:()=>Ce(""),clearToAmt:()=>ke(""),curFromFiatPrice:Oe,pricePerFromToken:ee,onClose:()=>W(!1)}),ne.exports.jsx(Dg,{open:_,onClose:()=>U(!1),isBridge:L}),ne.exports.jsx(ey,{open:ie,onClose:()=>se(!1),selectedRouteId:ce,setSelectRouteId:le,bridgeRouteList:re}),ne.exports.jsx(cy,{open:ge,onClose:()=>ye(!1),route:ue,bridgeOrderTxRequest:fe,clearFromAmt:()=>Ce(""),clearToAmt:()=>ke("")}),ne.exports.jsx(uy,{message:pe,onClose:()=>he("")})]})}var py,hy=M.default;if("production"===process.env.NODE_ENV)py=hy.createRoot,hy.hydrateRoot;else{var fy=hy.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;py=function(e,t){fy.usingClientEntryPoint=!0;try{return hy.createRoot(e,t)}finally{fy.usingClientEntryPoint=!1}}}exports.InitSwapWidget=function(e){const t=document.getElementById("dodo-swap-widget");py(t).render(ne.exports.jsx(Sg,{...e,children:ne.exports.jsx(dy,{})}))},exports.SwapWidget=function(e){return ne.exports.jsx(Sg,{...e,children:ne.exports.jsx(dy,{})})};
|
|
45
|
+
*/!function(e){!function(){var t="input is invalid type",r="object"==typeof window,n=r?window:{};n.JS_SHA3_NO_WINDOW&&(r=!1);var o=!r&&"object"==typeof self;!n.JS_SHA3_NO_NODE_JS&&"object"==typeof process&&process.versions&&process.versions.node?n=j:o&&(n=self);var i=!n.JS_SHA3_NO_COMMON_JS&&e.exports,s=!n.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,a="0123456789abcdef".split(""),l=[4,1024,262144,67108864],c=[0,8,16,24],u=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],d=[224,256,384,512],p=[128,256],f=["hex","buffer","arrayBuffer","array","digest"],h={128:168,256:136};!n.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!s||!n.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"==typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var m=function(e,t,r){return function(n){return new M(e,t,e).update(n)[r]()}},g=function(e,t,r){return function(n,o){return new M(e,t,o).update(n)[r]()}},y=function(e,t,r){return function(t,n,o,i){return E["cshake"+e].update(t,n,o,i)[r]()}},b=function(e,t,r){return function(t,n,o,i){return E["kmac"+e].update(t,n,o,i)[r]()}},v=function(e,t,r,n){for(var o=0;o<f.length;++o){var i=f[o];e[i]=t(r,n,i)}return e},x=function(e,t){var r=m(e,t,"hex");return r.create=function(){return new M(e,t,e)},r.update=function(e){return r.create().update(e)},v(r,m,e,t)},w=[{name:"keccak",padding:[1,256,65536,16777216],bits:d,createMethod:x},{name:"sha3",padding:[6,1536,393216,100663296],bits:d,createMethod:x},{name:"shake",padding:[31,7936,2031616,520093696],bits:p,createMethod:function(e,t){var r=g(e,t,"hex");return r.create=function(r){return new M(e,t,r)},r.update=function(e,t){return r.create(t).update(e)},v(r,g,e,t)}},{name:"cshake",padding:l,bits:p,createMethod:function(e,t){var r=h[e],n=y(e,0,"hex");return n.create=function(n,o,i){return o||i?new M(e,t,n).bytepad([o,i],r):E["shake"+e].create(n)},n.update=function(e,t,r,o){return n.create(t,r,o).update(e)},v(n,y,e,t)}},{name:"kmac",padding:l,bits:p,createMethod:function(e,t){var r=h[e],n=b(e,0,"hex");return n.create=function(n,o,i){return new O(e,t,o).bytepad(["KMAC",i],r).bytepad([n],r)},n.update=function(e,t,r,o){return n.create(e,r,o).update(t)},v(n,b,e,t)}}],E={},A=[],k=0;k<w.length;++k)for(var C=w[k],R=C.bits,S=0;S<R.length;++S){var T=C.name+"_"+R[S];if(A.push(T),E[T]=C.createMethod(R[S],C.padding),"sha3"!==C.name){var N=C.name+R[S];A.push(N),E[N]=E[T]}}function M(e,t,r){this.blocks=[],this.s=[],this.padding=t,this.outputBits=r,this.reset=!0,this.finalized=!1,this.block=0,this.start=0,this.blockCount=1600-(e<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=r>>5,this.extraBytes=(31&r)>>3;for(var n=0;n<50;++n)this.s[n]=0}function O(e,t,r){M.call(this,e,t,r)}M.prototype.update=function(e){if(this.finalized)throw new Error("finalize already called");var r,n=typeof e;if("string"!==n){if("object"!==n)throw new Error(t);if(null===e)throw new Error(t);if(s&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||s&&ArrayBuffer.isView(e)))throw new Error(t);r=!0}for(var o,i,a=this.blocks,l=this.byteCount,u=e.length,d=this.blockCount,p=0,f=this.s;p<u;){if(this.reset)for(this.reset=!1,a[0]=this.block,o=1;o<d+1;++o)a[o]=0;if(r)for(o=this.start;p<u&&o<l;++p)a[o>>2]|=e[p]<<c[3&o++];else for(o=this.start;p<u&&o<l;++p)(i=e.charCodeAt(p))<128?a[o>>2]|=i<<c[3&o++]:i<2048?(a[o>>2]|=(192|i>>6)<<c[3&o++],a[o>>2]|=(128|63&i)<<c[3&o++]):i<55296||i>=57344?(a[o>>2]|=(224|i>>12)<<c[3&o++],a[o>>2]|=(128|i>>6&63)<<c[3&o++],a[o>>2]|=(128|63&i)<<c[3&o++]):(i=65536+((1023&i)<<10|1023&e.charCodeAt(++p)),a[o>>2]|=(240|i>>18)<<c[3&o++],a[o>>2]|=(128|i>>12&63)<<c[3&o++],a[o>>2]|=(128|i>>6&63)<<c[3&o++],a[o>>2]|=(128|63&i)<<c[3&o++]);if(this.lastByteIndex=o,o>=l){for(this.start=o-l,this.block=a[d],o=0;o<d;++o)f[o]^=a[o];I(f),this.reset=!0}else this.start=o}return this},M.prototype.encode=function(e,t){var r=255&e,n=1,o=[r];for(r=255&(e>>=8);r>0;)o.unshift(r),r=255&(e>>=8),++n;return t?o.push(n):o.unshift(n),this.update(o),o.length},M.prototype.encodeString=function(e){var r,n=typeof e;if("string"!==n){if("object"!==n)throw new Error(t);if(null===e)throw new Error(t);if(s&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||s&&ArrayBuffer.isView(e)))throw new Error(t);r=!0}var o=0,i=e.length;if(r)o=i;else for(var a=0;a<e.length;++a){var l=e.charCodeAt(a);l<128?o+=1:l<2048?o+=2:l<55296||l>=57344?o+=3:(l=65536+((1023&l)<<10|1023&e.charCodeAt(++a)),o+=4)}return o+=this.encode(8*o),this.update(e),o},M.prototype.bytepad=function(e,t){for(var r=this.encode(t),n=0;n<e.length;++n)r+=this.encodeString(e[n]);var o=t-r%t,i=[];return i.length=o,this.update(i),this},M.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var e=this.blocks,t=this.lastByteIndex,r=this.blockCount,n=this.s;if(e[t>>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[r],t=1;t<r+1;++t)e[t]=0;for(e[r-1]|=2147483648,t=0;t<r;++t)n[t]^=e[t];I(n)}},M.prototype.toString=M.prototype.hex=function(){this.finalize();for(var e,t=this.blockCount,r=this.s,n=this.outputBlocks,o=this.extraBytes,i=0,s=0,l="";s<n;){for(i=0;i<t&&s<n;++i,++s)e=r[i],l+=a[e>>4&15]+a[15&e]+a[e>>12&15]+a[e>>8&15]+a[e>>20&15]+a[e>>16&15]+a[e>>28&15]+a[e>>24&15];s%t==0&&(I(r),i=0)}return o&&(e=r[i],l+=a[e>>4&15]+a[15&e],o>1&&(l+=a[e>>12&15]+a[e>>8&15]),o>2&&(l+=a[e>>20&15]+a[e>>16&15])),l},M.prototype.arrayBuffer=function(){this.finalize();var e,t=this.blockCount,r=this.s,n=this.outputBlocks,o=this.extraBytes,i=0,s=0,a=this.outputBits>>3;e=o?new ArrayBuffer(n+1<<2):new ArrayBuffer(a);for(var l=new Uint32Array(e);s<n;){for(i=0;i<t&&s<n;++i,++s)l[s]=r[i];s%t==0&&I(r)}return o&&(l[i]=r[i],e=e.slice(0,a)),e},M.prototype.buffer=M.prototype.arrayBuffer,M.prototype.digest=M.prototype.array=function(){this.finalize();for(var e,t,r=this.blockCount,n=this.s,o=this.outputBlocks,i=this.extraBytes,s=0,a=0,l=[];a<o;){for(s=0;s<r&&a<o;++s,++a)e=a<<2,t=n[s],l[e]=255&t,l[e+1]=t>>8&255,l[e+2]=t>>16&255,l[e+3]=t>>24&255;a%r==0&&I(n)}return i&&(e=a<<2,t=n[s],l[e]=255&t,i>1&&(l[e+1]=t>>8&255),i>2&&(l[e+2]=t>>16&255)),l},O.prototype=new M,O.prototype.finalize=function(){return this.encode(this.outputBits,!0),M.prototype.finalize.call(this)};var I=function(e){var t,r,n,o,i,s,a,l,c,d,p,f,h,m,g,y,b,v,x,w,E,A,k,C,R,S,T,N,M,O,I,j,F,_,P,B,W,D,L,U,V,Z,H,z,Y,G,X,J,q,Q,K,$,ee,te,re,ne,oe,ie,se,ae,le,ce,ue;for(n=0;n<48;n+=2)o=e[0]^e[10]^e[20]^e[30]^e[40],i=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],a=e[3]^e[13]^e[23]^e[33]^e[43],l=e[4]^e[14]^e[24]^e[34]^e[44],c=e[5]^e[15]^e[25]^e[35]^e[45],d=e[6]^e[16]^e[26]^e[36]^e[46],p=e[7]^e[17]^e[27]^e[37]^e[47],t=(f=e[8]^e[18]^e[28]^e[38]^e[48])^(s<<1|a>>>31),r=(h=e[9]^e[19]^e[29]^e[39]^e[49])^(a<<1|s>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=o^(l<<1|c>>>31),r=i^(c<<1|l>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=s^(d<<1|p>>>31),r=a^(p<<1|d>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=l^(f<<1|h>>>31),r=c^(h<<1|f>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=d^(o<<1|i>>>31),r=p^(i<<1|o>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,m=e[0],g=e[1],G=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,N=e[20]<<3|e[21]>>>29,M=e[21]<<3|e[20]>>>29,ae=e[31]<<9|e[30]>>>23,le=e[30]<<9|e[31]>>>23,Z=e[40]<<18|e[41]>>>14,H=e[41]<<18|e[40]>>>14,_=e[2]<<1|e[3]>>>31,P=e[3]<<1|e[2]>>>31,y=e[13]<<12|e[12]>>>20,b=e[12]<<12|e[13]>>>20,J=e[22]<<10|e[23]>>>22,q=e[23]<<10|e[22]>>>22,O=e[33]<<13|e[32]>>>19,I=e[32]<<13|e[33]>>>19,ce=e[42]<<2|e[43]>>>30,ue=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,re=e[4]<<30|e[5]>>>2,B=e[14]<<6|e[15]>>>26,W=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,x=e[24]<<11|e[25]>>>21,Q=e[34]<<15|e[35]>>>17,K=e[35]<<15|e[34]>>>17,j=e[45]<<29|e[44]>>>3,F=e[44]<<29|e[45]>>>3,C=e[6]<<28|e[7]>>>4,R=e[7]<<28|e[6]>>>4,ne=e[17]<<23|e[16]>>>9,oe=e[16]<<23|e[17]>>>9,D=e[26]<<25|e[27]>>>7,L=e[27]<<25|e[26]>>>7,w=e[36]<<21|e[37]>>>11,E=e[37]<<21|e[36]>>>11,$=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,z=e[8]<<27|e[9]>>>5,Y=e[9]<<27|e[8]>>>5,S=e[18]<<20|e[19]>>>12,T=e[19]<<20|e[18]>>>12,ie=e[29]<<7|e[28]>>>25,se=e[28]<<7|e[29]>>>25,U=e[38]<<8|e[39]>>>24,V=e[39]<<8|e[38]>>>24,A=e[48]<<14|e[49]>>>18,k=e[49]<<14|e[48]>>>18,e[0]=m^~y&v,e[1]=g^~b&x,e[10]=C^~S&N,e[11]=R^~T&M,e[20]=_^~B&D,e[21]=P^~W&L,e[30]=z^~G&J,e[31]=Y^~X&q,e[40]=te^~ne&ie,e[41]=re^~oe&se,e[2]=y^~v&w,e[3]=b^~x&E,e[12]=S^~N&O,e[13]=T^~M&I,e[22]=B^~D&U,e[23]=W^~L&V,e[32]=G^~J&Q,e[33]=X^~q&K,e[42]=ne^~ie&ae,e[43]=oe^~se&le,e[4]=v^~w&A,e[5]=x^~E&k,e[14]=N^~O&j,e[15]=M^~I&F,e[24]=D^~U&Z,e[25]=L^~V&H,e[34]=J^~Q&$,e[35]=q^~K&ee,e[44]=ie^~ae&ce,e[45]=se^~le&ue,e[6]=w^~A&m,e[7]=E^~k&g,e[16]=O^~j&C,e[17]=I^~F&R,e[26]=U^~Z&_,e[27]=V^~H&P,e[36]=Q^~$&z,e[37]=K^~ee&Y,e[46]=ae^~ce&te,e[47]=le^~ue&re,e[8]=A^~m&y,e[9]=k^~g&b,e[18]=j^~C&S,e[19]=F^~R&T,e[28]=Z^~_&B,e[29]=H^~P&W,e[38]=$^~z&G,e[39]=ee^~Y&X,e[48]=ce^~te&ne,e[49]=ue^~re&oe,e[0]^=u[n],e[1]^=u[n+1]};if(i)e.exports=E;else for(k=0;k<A.length;++k)n[A[k]]=E[A[k]]}()}(Zs);var Hs=Zs.exports;function zs(e){return"0x"+Hs.keccak_256(Is(e))}const Ys=new Cs("rlp/5.7.0");function Gs(e){const t=[];for(;e;)t.unshift(255&e),e>>=8;return t}function Xs(e,t,r){let n=0;for(let o=0;o<r;o++)n=256*n+e[t+o];return n}function Js(e){if(Array.isArray(e)){let t=[];if(e.forEach((function(e){t=t.concat(Js(e))})),t.length<=55)return t.unshift(192+t.length),t;const r=Gs(t.length);return r.unshift(247+r.length),r.concat(t)}Ns(e)||Ys.throwArgumentError("RLP object must be BytesLike","object",e);const t=Array.prototype.slice.call(Is(e));if(1===t.length&&t[0]<=127)return t;if(t.length<=55)return t.unshift(128+t.length),t;const r=Gs(t.length);return r.unshift(183+r.length),r.concat(t)}function qs(e){return Ps(Js(e))}function Qs(e,t,r,n){const o=[];for(;r<t+1+n;){const i=Ks(e,r);o.push(i.result),(r+=i.consumed)>t+1+n&&Ys.throwError("child data too short",Cs.errors.BUFFER_OVERRUN,{})}return{consumed:1+n,result:o}}function Ks(e,t){if(0===e.length&&Ys.throwError("data too short",Cs.errors.BUFFER_OVERRUN,{}),e[t]>=248){const r=e[t]-247;t+1+r>e.length&&Ys.throwError("data short segment too short",Cs.errors.BUFFER_OVERRUN,{});const n=Xs(e,t+1,r);return t+1+r+n>e.length&&Ys.throwError("data long segment too short",Cs.errors.BUFFER_OVERRUN,{}),Qs(e,t,t+1+r,r+n)}if(e[t]>=192){const r=e[t]-192;return t+1+r>e.length&&Ys.throwError("data array too short",Cs.errors.BUFFER_OVERRUN,{}),Qs(e,t,t+1,r)}if(e[t]>=184){const r=e[t]-183;t+1+r>e.length&&Ys.throwError("data array too short",Cs.errors.BUFFER_OVERRUN,{});const n=Xs(e,t+1,r);t+1+r+n>e.length&&Ys.throwError("data array too short",Cs.errors.BUFFER_OVERRUN,{});return{consumed:1+r+n,result:Ps(e.slice(t+1+r,t+1+r+n))}}if(e[t]>=128){const r=e[t]-128;t+1+r>e.length&&Ys.throwError("data too short",Cs.errors.BUFFER_OVERRUN,{});return{consumed:1+r,result:Ps(e.slice(t+1,t+1+r))}}return{consumed:1,result:Ps(e[t])}}function $s(e){const t=Is(e),r=Ks(t,0);return r.consumed!==t.length&&Ys.throwArgumentError("invalid rlp data","data",e),r.result}const ea=new Cs("address/5.7.0");function ta(e){_s(e,20)||ea.throwArgumentError("invalid address","address",e);const t=(e=e.toLowerCase()).substring(2).split(""),r=new Uint8Array(40);for(let e=0;e<40;e++)r[e]=t[e].charCodeAt(0);const n=Is(zs(r));for(let e=0;e<40;e+=2)n[e>>1]>>4>=8&&(t[e]=t[e].toUpperCase()),(15&n[e>>1])>=8&&(t[e+1]=t[e+1].toUpperCase());return"0x"+t.join("")}const ra={};for(let e=0;e<10;e++)ra[String(e)]=String(e);for(let e=0;e<26;e++)ra[String.fromCharCode(65+e)]=String(10+e);const na=Math.floor(function(e){return Math.log10?Math.log10(e):Math.log(e)/Math.LN10}(9007199254740991));function oa(e){let t=null;if("string"!=typeof e&&ea.throwArgumentError("invalid address","address",e),e.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==e.substring(0,2)&&(e="0x"+e),t=ta(e),e.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&t!==e&&ea.throwArgumentError("bad address checksum","address",e);else if(e.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(e.substring(2,4)!==function(e){let t=(e=(e=e.toUpperCase()).substring(4)+e.substring(0,2)+"00").split("").map((e=>ra[e])).join("");for(;t.length>=na;){let e=t.substring(0,na);t=parseInt(e,10)%97+t.substring(e.length)}let r=String(98-parseInt(t,10)%97);for(;r.length<2;)r="0"+r;return r}(e)&&ea.throwArgumentError("bad icap checksum","address",e),t=y._base36To16(e.substring(4));t.length<40;)t="0"+t;t=ta("0x"+t)}else ea.throwArgumentError("invalid address","address",e);return t}var ia;!function(e){e[e.MAINNET=1]="MAINNET",e[e.GOERLI=5]="GOERLI",e[e.BSC=56]="BSC",e[e.POLYGON=137]="POLYGON",e[e.ARBITRUM_ONE=42161]="ARBITRUM_ONE",e[e.AURORA=1313161554]="AURORA",e[e.OKCHAIN=66]="OKCHAIN",e[e.OPTIMISM=10]="OPTIMISM",e[e.AVALANCHE=43114]="AVALANCHE",e[e.CONFLUX=1030]="CONFLUX"}(ia||(ia={}));const sa={[ia.MAINNET]:["https://rpc.ankr.com/eth","https://eth-mainnet.public.blastapi.io","https://eth-rpc.gateway.pokt.network","https://main-rpc.linkpool.io"],[ia.GOERLI]:["https://goerli.optimism.io/"],[ia.BSC]:["https://bsc-dataseed1.binance.org","https://bsc-dataseed2.binance.org","https://bsc-dataseed3.binance.org","https://bsc-dataseed4.binance.org","https://bsc-dataseed1.defibit.io","https://bsc-dataseed2.defibit.io","https://bsc-dataseed3.defibit.io","https://bsc-dataseed4.defibit.io","https://bsc-dataseed1.ninicoin.io","https://bsc-dataseed2.ninicoin.io","https://bsc-dataseed3.ninicoin.io","https://bsc-dataseed4.ninicoin.io","https://bsc-dataseed.binance.org","https://rpc.ankr.com/bsc","https://bscrpc.com","https://bsc.mytokenpocket.vip","https://binance.nodereal.io","https://rpc-bsc.bnb48.club"],[ia.POLYGON]:["https://polygon-rpc.com","https://rpc-mainnet.matic.network","https://matic-mainnet.chainstacklabs.com","https://rpc-mainnet.maticvigil.com","https://rpc-mainnet.matic.quiknode.pro","https://matic-mainnet-full-rpc.bwarelabs.com","https://matic-mainnet-archive-rpc.bwarelabs.com","https://poly-rpc.gateway.pokt.network","https://rpc.ankr.com/polygon","https://polygon-mainnet.public.blastapi.io"],[ia.ARBITRUM_ONE]:["https://arb1.arbitrum.io/rpc","https://rpc.ankr.com/arbitrum"],[ia.AURORA]:["https://mainnet.aurora.dev/"],[ia.OKCHAIN]:["https://exchainrpc.okex.org","https://okc-mainnet.gateway.pokt.network/v1/lb/6275309bea1b320039c893ff"],[ia.OPTIMISM]:["https://mainnet.optimism.io","https://optimism-mainnet.public.blastapi.io"],[ia.AVALANCHE]:["https://api.avax.network/ext/bc/C/rpc","https://rpc.ankr.com/avalanche","https://ava-mainnet.public.blastapi.io/ext/bc/C/rpc"],[ia.CONFLUX]:["https://evm.confluxrpc.com","https://conflux-espace-public.unifra.io"]},aa={symbol:"ETH",address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ether",decimals:18,showDecimals:4,wrappedTokenSymbol:"WETH"},la={[ia.MAINNET]:Object.assign(Object.assign({},aa),{wrappedTokenAddress:"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2"}),[ia.GOERLI]:Object.assign(Object.assign({},aa),{wrappedTokenAddress:"0xB4FBF271143F4FBf7B91A5ded31805e42b2208d6"}),[ia.OPTIMISM]:Object.assign(Object.assign({},aa),{wrappedTokenAddress:"0x4200000000000000000000000000000000000006"}),[ia.CONFLUX]:Object.assign(Object.assign({},aa),{symbol:"CFX",name:"CFX",wrappedTokenSymbol:"WCFX",wrappedTokenAddress:"0x14b2d3bc65e74dae1030eafd8ac30c533c976a9b"}),[ia.BSC]:Object.assign(Object.assign({},aa),{symbol:"BNB",name:"BNB",wrappedTokenSymbol:"WBNB",wrappedTokenAddress:"0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c"}),[ia.OKCHAIN]:Object.assign(Object.assign({},aa),{symbol:"OKT",name:"OKT",wrappedTokenSymbol:"WOKT",wrappedTokenAddress:"0x8F8526dbfd6E38E3D8307702cA8469Bae6C56C15"}),[ia.POLYGON]:Object.assign(Object.assign({},aa),{symbol:"MATIC",name:"MATIC",showDecimals:6,wrappedTokenSymbol:"WMATIC",wrappedTokenAddress:"0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270"}),[ia.ARBITRUM_ONE]:Object.assign(Object.assign({},aa),{name:"Ethereum",showDecimals:6,wrappedTokenAddress:"0x82aF49447D8a07e3bd95BD0d56f35241523fBab1"}),[ia.AURORA]:Object.assign(Object.assign({},aa),{name:"Ethereum",showDecimals:6,wrappedTokenAddress:"0xC9BdeEd33CD01541e1eeD10f90519d2C06Fe3feB"}),[ia.AVALANCHE]:Object.assign(Object.assign({},aa),{symbol:"AVAX",name:"Avalanche",showDecimals:6,wrappedTokenSymbol:"WAVAX",wrappedTokenAddress:"0xB31f66AA3C1e785363F0875A1B74E27b85FD66c7"})},ca={[ia.MAINNET]:"ethereum",[ia.GOERLI]:"goerli",[ia.OPTIMISM]:"optimism",[ia.CONFLUX]:"cfx",[ia.BSC]:"bsc",[ia.OKCHAIN]:"okex-chain",[ia.POLYGON]:"polygon",[ia.ARBITRUM_ONE]:"arbitrum",[ia.AURORA]:"aurora",[ia.AVALANCHE]:"avalanche"},ua={[ia.MAINNET]:"etherscan.io",[ia.GOERLI]:"goerli.etherscan.io",[ia.OPTIMISM]:"optimistic.etherscan.io",[ia.CONFLUX]:"snowtrace.io",[ia.BSC]:"bscscan.com",[ia.OKCHAIN]:"www.oklink.com/okexchain",[ia.POLYGON]:"polygonscan.com",[ia.ARBITRUM_ONE]:"arbiscan.io",[ia.AURORA]:"aurorascan.dev",[ia.AVALANCHE]:"snowtrace.io"},da=(e,t)=>{if(0===e.length||0===t.length)return!1;if(t.length===e.length)return e.toLowerCase()===t.toLowerCase();const r=e.substring(2,e.length).toLowerCase(),n=t.substring(2,t.length).toLowerCase();return r.length>n.length?r.endsWith(n):n.endsWith(r)};function pa(e,t){return`https://${ua[t||1]}${e?`/${e}`:""}`}const fa=e=>{const t={isMainnet:1===e,isRinkeby:4===e,isGor:5===e};return Object.assign(Object.assign({},t),{isETH:t.isMainnet||t.isRinkeby||t.isGor})};function ha(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}function ma(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))}const ga=(e,t)=>r=>ma(void 0,void 0,void 0,(function*(){r({type:"SET_ETH_BALANCE",payload:{[e]:t}})})),ya=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_ACCOUNT_BALANCES",payload:e})})),ba=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_BALANCE_LOADINGS",payload:e})}));var va=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const xa=new Cs("properties/5.7.0");function wa(e,t,r){Object.defineProperty(e,t,{enumerable:!0,value:r,writable:!1})}function Ea(e,t){for(let r=0;r<32;r++){if(e[t])return e[t];if(!e.prototype||"object"!=typeof e.prototype)break;e=Object.getPrototypeOf(e.prototype).constructor}return null}function Aa(e){return va(this,void 0,void 0,(function*(){const t=Object.keys(e).map((t=>{const r=e[t];return Promise.resolve(r).then((e=>({key:t,value:e})))}));return(yield Promise.all(t)).reduce(((e,t)=>(e[t.key]=t.value,e)),{})}))}function ka(e){const t={};for(const r in e)t[r]=e[r];return t}const Ca={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function Ra(e){if(null==e||Ca[typeof e])return!0;if(Array.isArray(e)||"object"==typeof e){if(!Object.isFrozen(e))return!1;const t=Object.keys(e);for(let r=0;r<t.length;r++){let n=null;try{n=e[t[r]]}catch(e){continue}if(!Ra(n))return!1}return!0}return xa.throwArgumentError("Cannot deepCopy "+typeof e,"object",e)}function Sa(e){if(Ra(e))return e;if(Array.isArray(e))return Object.freeze(e.map((e=>Ta(e))));if("object"==typeof e){const t={};for(const r in e){const n=e[r];void 0!==n&&wa(t,r,Ta(n))}return t}return xa.throwArgumentError("Cannot deepCopy "+typeof e,"object",e)}function Ta(e){return Sa(e)}class Na{constructor(e){for(const t in e)this[t]=Ta(e[t])}}var Ma=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Oa=new Cs("abstract-provider/5.7.0");class Ia extends Na{static isForkEvent(e){return!(!e||!e._isForkEvent)}}class ja{constructor(){Oa.checkAbstract(new.target,ja),wa(this,"_isProvider",!0)}getFeeData(){return Ma(this,void 0,void 0,(function*(){const{block:e,gasPrice:t}=yield Aa({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch((e=>null))});let r=null,n=null,o=null;return e&&e.baseFeePerGas&&(r=e.baseFeePerGas,o=y.BigNumber.from("1500000000"),n=e.baseFeePerGas.mul(2).add(o)),{lastBaseFeePerGas:r,maxFeePerGas:n,maxPriorityFeePerGas:o,gasPrice:t}}))}addListener(e,t){return this.on(e,t)}removeListener(e,t){return this.off(e,t)}static isProvider(e){return!(!e||!e._isProvider)}}const Fa=new Cs("networks/5.7.1");function _a(e){const t=function(t,r){null==r&&(r={});const n=[];if(t.InfuraProvider&&"-"!==r.infura)try{n.push(new t.InfuraProvider(e,r.infura))}catch(e){}if(t.EtherscanProvider&&"-"!==r.etherscan)try{n.push(new t.EtherscanProvider(e,r.etherscan))}catch(e){}if(t.AlchemyProvider&&"-"!==r.alchemy)try{n.push(new t.AlchemyProvider(e,r.alchemy))}catch(e){}if(t.PocketProvider&&"-"!==r.pocket){const o=["goerli","ropsten","rinkeby","sepolia"];try{const i=new t.PocketProvider(e,r.pocket);i.network&&-1===o.indexOf(i.network.name)&&n.push(i)}catch(e){}}if(t.CloudflareProvider&&"-"!==r.cloudflare)try{n.push(new t.CloudflareProvider(e))}catch(e){}if(t.AnkrProvider&&"-"!==r.ankr)try{const o=["ropsten"],i=new t.AnkrProvider(e,r.ankr);i.network&&-1===o.indexOf(i.network.name)&&n.push(i)}catch(e){}if(0===n.length)return null;if(t.FallbackProvider){let o=1;return null!=r.quorum?o=r.quorum:"homestead"===e&&(o=2),new t.FallbackProvider(n,o)}return n[0]};return t.renetwork=function(e){return _a(e)},t}function Pa(e,t){const r=function(r,n){return r.JsonRpcProvider?new r.JsonRpcProvider(e,t):null};return r.renetwork=function(t){return Pa(e,t)},r}const Ba={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:_a("homestead")},Wa={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:_a("ropsten")},Da={chainId:63,name:"classicMordor",_defaultProvider:Pa("https://www.ethercluster.com/mordor","classicMordor")},La={unspecified:{chainId:0,name:"unspecified"},homestead:Ba,mainnet:Ba,morden:{chainId:2,name:"morden"},ropsten:Wa,testnet:Wa,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:_a("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:_a("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:_a("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:_a("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:Pa("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:Da,classicTestnet:Da,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:Pa("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:_a("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:_a("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function Ua(e){e=atob(e);const t=[];for(let r=0;r<e.length;r++)t.push(e.charCodeAt(r));return Is(t)}function Va(e){e=Is(e);let t="";for(let r=0;r<e.length;r++)t+=String.fromCharCode(e[r]);return btoa(t)}class Za{constructor(e){wa(this,"alphabet",e),wa(this,"base",e.length),wa(this,"_alphabetMap",{}),wa(this,"_leader",e.charAt(0));for(let t=0;t<e.length;t++)this._alphabetMap[e.charAt(t)]=t}encode(e){let t=Is(e);if(0===t.length)return"";let r=[0];for(let e=0;e<t.length;++e){let n=t[e];for(let e=0;e<r.length;++e)n+=r[e]<<8,r[e]=n%this.base,n=n/this.base|0;for(;n>0;)r.push(n%this.base),n=n/this.base|0}let n="";for(let e=0;0===t[e]&&e<t.length-1;++e)n+=this._leader;for(let e=r.length-1;e>=0;--e)n+=this.alphabet[r[e]];return n}decode(e){if("string"!=typeof e)throw new TypeError("Expected String");let t=[];if(0===e.length)return new Uint8Array(t);t.push(0);for(let r=0;r<e.length;r++){let n=this._alphabetMap[e[r]];if(void 0===n)throw new Error("Non-base"+this.base+" character");let o=n;for(let e=0;e<t.length;++e)o+=t[e]*this.base,t[e]=255&o,o>>=8;for(;o>0;)t.push(255&o),o>>=8}for(let r=0;e[r]===this._leader&&r<e.length-1;++r)t.push(0);return Is(new Uint8Array(t.reverse()))}}new Za("abcdefghijklmnopqrstuvwxyz234567");const Ha=new Za("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),za="0x0000000000000000000000000000000000000000",Ya=y.BigNumber.from(-1),Ga=y.BigNumber.from(0),Xa=y.BigNumber.from(1),Ja=y.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),qa=new Cs("strings/5.7.0");var Qa,Ka;function $a(e,t,r,n,o){if(e===Ka.BAD_PREFIX||e===Ka.UNEXPECTED_CONTINUE){let e=0;for(let n=t+1;n<r.length&&r[n]>>6==2;n++)e++;return e}return e===Ka.OVERRUN?r.length-t-1:0}!function(e){e.current="",e.NFC="NFC",e.NFD="NFD",e.NFKC="NFKC",e.NFKD="NFKD"}(Qa||(Qa={})),function(e){e.UNEXPECTED_CONTINUE="unexpected continuation byte",e.BAD_PREFIX="bad codepoint prefix",e.OVERRUN="string overrun",e.MISSING_CONTINUE="missing continuation byte",e.OUT_OF_RANGE="out of UTF-8 range",e.UTF16_SURROGATE="UTF-16 surrogate",e.OVERLONG="overlong representation"}(Ka||(Ka={}));const el=Object.freeze({error:function(e,t,r,n,o){return qa.throwArgumentError(`invalid codepoint at offset ${t}; ${e}`,"bytes",r)},ignore:$a,replace:function(e,t,r,n,o){return e===Ka.OVERLONG?(n.push(o),0):(n.push(65533),$a(e,t,r))}});function tl(e,t){null==t&&(t=el.error),e=Is(e);const r=[];let n=0;for(;n<e.length;){const o=e[n++];if(o>>7==0){r.push(o);continue}let i=null,s=null;if(192==(224&o))i=1,s=127;else if(224==(240&o))i=2,s=2047;else{if(240!=(248&o)){n+=t(128==(192&o)?Ka.UNEXPECTED_CONTINUE:Ka.BAD_PREFIX,n-1,e,r);continue}i=3,s=65535}if(n-1+i>=e.length){n+=t(Ka.OVERRUN,n-1,e,r);continue}let a=o&(1<<8-i-1)-1;for(let o=0;o<i;o++){let o=e[n];if(128!=(192&o)){n+=t(Ka.MISSING_CONTINUE,n,e,r),a=null;break}a=a<<6|63&o,n++}null!==a&&(a>1114111?n+=t(Ka.OUT_OF_RANGE,n-1-i,e,r,a):a>=55296&&a<=57343?n+=t(Ka.UTF16_SURROGATE,n-1-i,e,r,a):a<=s?n+=t(Ka.OVERLONG,n-1-i,e,r,a):r.push(a))}return r}function rl(e,t=Qa.current){t!=Qa.current&&(qa.checkNormalize(),e=e.normalize(t));let r=[];for(let t=0;t<e.length;t++){const n=e.charCodeAt(t);if(n<128)r.push(n);else if(n<2048)r.push(n>>6|192),r.push(63&n|128);else if(55296==(64512&n)){t++;const o=e.charCodeAt(t);if(t>=e.length||56320!=(64512&o))throw new Error("invalid utf-8 string");const i=65536+((1023&n)<<10)+(1023&o);r.push(i>>18|240),r.push(i>>12&63|128),r.push(i>>6&63|128),r.push(63&i|128)}else r.push(n>>12|224),r.push(n>>6&63|128),r.push(63&n|128)}return Is(r)}function nl(e,t){return tl(e,t).map((e=>e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(55296+(e>>10&1023),56320+(1023&e))))).join("")}function ol(e){return zs(rl(e))}function il(e,t){null==t&&(t=1);const r=[],n=r.forEach,o=function(e,t){n.call(e,(function(e){t>0&&Array.isArray(e)?o(e,t-1):r.push(e)}))};return o(e,t),r}function sl(e){return function(e){let t=0;return()=>e[t++]}(function(e){let t=0;function r(){return e[t++]<<8|e[t++]}let n=r(),o=1,i=[0,1];for(let e=1;e<n;e++)i.push(o+=r());let s=r(),a=t;t+=s;let l=0,c=0;function u(){return 0==l&&(c=c<<8|e[t++],l=8),c>>--l&1}const d=Math.pow(2,31),p=d>>>1,f=p>>1,h=d-1;let m=0;for(let e=0;e<31;e++)m=m<<1|u();let g=[],y=0,b=d;for(;;){let e=Math.floor(((m-y+1)*o-1)/b),t=0,r=n;for(;r-t>1;){let n=t+r>>>1;e<i[n]?r=n:t=n}if(0==t)break;g.push(t);let s=y+Math.floor(b*i[t]/o),a=y+Math.floor(b*i[t+1]/o)-1;for(;0==((s^a)&p);)m=m<<1&h|u(),s=s<<1&h,a=a<<1&h|1;for(;s&~a&f;)m=m&p|m<<1&h>>>1|u(),s=s<<1^p,a=(a^p)<<1|p|1;y=s,b=1+a-s}let v=n-4;return g.map((t=>{switch(t-v){case 3:return v+65792+(e[a++]<<16|e[a++]<<8|e[a++]);case 2:return v+256+(e[a++]<<8|e[a++]);case 1:return v+e[a++];default:return t-1}}))}(e))}function al(e){return 1&e?~e>>1:e>>1}function ll(e,t){let r=Array(e);for(let n=0,o=-1;n<e;n++)r[n]=o+=1+t();return r}function cl(e,t){let r=Array(e);for(let n=0,o=0;n<e;n++)r[n]=o+=al(t());return r}function ul(e,t){let r=ll(e(),e),n=e(),o=ll(n,e),i=function(e,t){let r=Array(e);for(let n=0;n<e;n++)r[n]=1+t();return r}(n,e);for(let e=0;e<n;e++)for(let t=0;t<i[e];t++)r.push(o[e]+t);return t?r.map((e=>t[e])):r}function dl(e,t,r){let n=Array(e).fill(void 0).map((()=>[]));for(let o=0;o<t;o++)cl(e,r).forEach(((e,t)=>n[t].push(e)));return n}function pl(e,t){let r=1+t(),n=t(),o=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(r)}return t}(t);return il(dl(o.length,1+e,t).map(((e,t)=>{const i=e[0],s=e.slice(1);return Array(o[t]).fill(void 0).map(((e,t)=>{let o=t*n;return[i+t*r,s.map((e=>e+o))]}))})))}function fl(e,t){return dl(1+t(),1+e,t).map((e=>[e[0],e.slice(1)]))}const hl=sl(Ua("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA==")),ml=new Set(ul(hl)),gl=new Set(ul(hl)),yl=function(e){let t=[];for(;;){let r=e();if(0==r)break;t.push(pl(r,e))}for(;;){let r=e()-1;if(r<0)break;t.push(fl(r,e))}return function(e){const t={};for(let r=0;r<e.length;r++){const n=e[r];t[n[0]]=n[1]}return t}(il(t))}(hl),bl=function(e){let t=ul(e).sort(((e,t)=>e-t));return function r(){let n=[];for(;;){let o=ul(e,t);if(0==o.length)break;n.push({set:new Set(o),node:r()})}n.sort(((e,t)=>t.set.size-e.set.size));let o=e(),i=o%3;o=o/3|0;let s=!!(1&o);return o>>=1,{branches:n,valid:i,fe0f:s,save:1==o,check:2==o}}()}(hl);function vl(e){return function(e,t=Qa.current){return tl(rl(e,t))}(e)}function xl(e){return e.filter((e=>65039!=e))}function wl(e){for(let t of e.split(".")){let e=vl(t);try{for(let t=e.lastIndexOf(95)-1;t>=0;t--)if(95!==e[t])throw new Error("underscore only allowed at start");if(e.length>=4&&e.every((e=>e<128))&&45===e[2]&&45===e[3])throw new Error("invalid label extension")}catch(e){throw new Error(`Invalid label "${t}": ${e.message}`)}}return e}function El(e){return wl(function(e,t){let r=vl(e).reverse(),n=[];for(;r.length;){let e=Al(r);if(e){n.push(...t(e));continue}let o=r.pop();if(ml.has(o)){n.push(o);continue}if(gl.has(o))continue;let i=yl[o];if(!i)throw new Error(`Disallowed codepoint: 0x${o.toString(16).toUpperCase()}`);n.push(...i)}return wl(function(e){return e.normalize("NFC")}(String.fromCodePoint(...n)))}(e,xl))}function Al(e,t){var r;let n,o,i=bl,s=[],a=e.length;for(t&&(t.length=0);a;){let l=e[--a];if(i=null===(r=i.branches.find((e=>e.set.has(l))))||void 0===r?void 0:r.node,!i)break;if(i.save)o=l;else if(i.check&&l===o)break;s.push(l),i.fe0f&&(s.push(65039),a>0&&65039==e[a-1]&&a--),i.valid&&(n=s.slice(),2==i.valid&&n.splice(1,1),t&&t.push(...e.slice(a).reverse()),e.length=a)}return n}const kl=new Cs("hash/5.7.0"),Cl=new Uint8Array(32);function Rl(e){if(0===e.length)throw new Error("invalid ENS name; empty component");return e}function Sl(e){const t=rl(El(e)),r=[];if(0===e.length)return r;let n=0;for(let e=0;e<t.length;e++){46===t[e]&&(r.push(Rl(t.slice(n,e))),n=e+1)}if(n>=t.length)throw new Error("invalid ENS name; empty component");return r.push(Rl(t.slice(n))),r}function Tl(e){"string"!=typeof e&&kl.throwArgumentError("invalid ENS name; not a string","name",e);let t=Cl;const r=Sl(e);for(;r.length;)t=zs(js([t,zs(r.pop())]));return Ps(t)}Cl.fill(0);var Nl=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Ml=new Cs("hash/5.7.0"),Ol=new Uint8Array(32);Ol.fill(0);const Il=y.BigNumber.from(-1),jl=y.BigNumber.from(0),Fl=y.BigNumber.from(1),_l=y.BigNumber.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");const Pl=Us(Fl.toHexString(),32),Bl=Us(jl.toHexString(),32),Wl={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},Dl=["name","version","chainId","verifyingContract","salt"];function Ll(e){return function(t){return"string"!=typeof t&&Ml.throwArgumentError(`invalid domain value for ${JSON.stringify(e)}`,`domain.${e}`,t),t}}const Ul={name:Ll("name"),version:Ll("version"),chainId:function(e){try{return y.BigNumber.from(e).toString()}catch(e){}return Ml.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",e)},verifyingContract:function(e){try{return oa(e).toLowerCase()}catch(e){}return Ml.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",e)},salt:function(e){try{const t=Is(e);if(32!==t.length)throw new Error("bad length");return Ps(t)}catch(e){}return Ml.throwArgumentError('invalid domain value "salt"',"domain.salt",e)}};function Vl(e){{const t=e.match(/^(u?)int(\d*)$/);if(t){const r=""===t[1],n=parseInt(t[2]||"256");(n%8!=0||n>256||t[2]&&t[2]!==String(n))&&Ml.throwArgumentError("invalid numeric width","type",e);const o=_l.mask(r?n-1:n),i=r?o.add(Fl).mul(Il):jl;return function(t){const r=y.BigNumber.from(t);return(r.lt(i)||r.gt(o))&&Ml.throwArgumentError(`value out-of-bounds for ${e}`,"value",t),Us(r.toTwos(256).toHexString(),32)}}}{const t=e.match(/^bytes(\d+)$/);if(t){const r=parseInt(t[1]);return(0===r||r>32||t[1]!==String(r))&&Ml.throwArgumentError("invalid bytes width","type",e),function(t){return Is(t).length!==r&&Ml.throwArgumentError(`invalid length for ${e}`,"value",t),function(e){const t=Is(e),r=t.length%32;return r?Ds([t,Ol.slice(r)]):Ps(t)}(t)}}}switch(e){case"address":return function(e){return Us(oa(e),32)};case"bool":return function(e){return e?Pl:Bl};case"bytes":return function(e){return zs(e)};case"string":return function(e){return ol(e)}}return null}function Zl(e,t){return`${e}(${t.map((({name:e,type:t})=>t+" "+e)).join(",")})`}class Hl{constructor(e){wa(this,"types",Object.freeze(Ta(e))),wa(this,"_encoderCache",{}),wa(this,"_types",{});const t={},r={},n={};Object.keys(e).forEach((e=>{t[e]={},r[e]=[],n[e]={}}));for(const n in e){const o={};e[n].forEach((i=>{o[i.name]&&Ml.throwArgumentError(`duplicate variable name ${JSON.stringify(i.name)} in ${JSON.stringify(n)}`,"types",e),o[i.name]=!0;const s=i.type.match(/^([^\x5b]*)(\x5b|$)/)[1];s===n&&Ml.throwArgumentError(`circular type reference to ${JSON.stringify(s)}`,"types",e);Vl(s)||(r[s]||Ml.throwArgumentError(`unknown type ${JSON.stringify(s)}`,"types",e),r[s].push(n),t[n][s]=!0)}))}const o=Object.keys(r).filter((e=>0===r[e].length));0===o.length?Ml.throwArgumentError("missing primary type","types",e):o.length>1&&Ml.throwArgumentError(`ambiguous primary types or unused types: ${o.map((e=>JSON.stringify(e))).join(", ")}`,"types",e),wa(this,"primaryType",o[0]),function o(i,s){s[i]&&Ml.throwArgumentError(`circular type reference to ${JSON.stringify(i)}`,"types",e),s[i]=!0,Object.keys(t[i]).forEach((e=>{r[e]&&(o(e,s),Object.keys(s).forEach((t=>{n[t][e]=!0})))})),delete s[i]}(this.primaryType,{});for(const t in n){const r=Object.keys(n[t]);r.sort(),this._types[t]=Zl(t,e[t])+r.map((t=>Zl(t,e[t]))).join("")}}getEncoder(e){let t=this._encoderCache[e];return t||(t=this._encoderCache[e]=this._getEncoder(e)),t}_getEncoder(e){{const t=Vl(e);if(t)return t}const t=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(t){const e=t[1],r=this.getEncoder(e),n=parseInt(t[3]);return t=>{n>=0&&t.length!==n&&Ml.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t);let o=t.map(r);return this._types[e]&&(o=o.map(zs)),zs(Ds(o))}}const r=this.types[e];if(r){const t=ol(this._types[e]);return e=>{const n=r.map((({name:t,type:r})=>{const n=this.getEncoder(r)(e[t]);return this._types[r]?zs(n):n}));return n.unshift(t),Ds(n)}}return Ml.throwArgumentError(`unknown type: ${e}`,"type",e)}encodeType(e){const t=this._types[e];return t||Ml.throwArgumentError(`unknown type: ${JSON.stringify(e)}`,"name",e),t}encodeData(e,t){return this.getEncoder(e)(t)}hashStruct(e,t){return zs(this.encodeData(e,t))}encode(e){return this.encodeData(this.primaryType,e)}hash(e){return this.hashStruct(this.primaryType,e)}_visit(e,t,r){if(Vl(e))return r(e,t);const n=e.match(/^(.*)(\x5b(\d*)\x5d)$/);if(n){const e=n[1],o=parseInt(n[3]);return o>=0&&t.length!==o&&Ml.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",t),t.map((t=>this._visit(e,t,r)))}const o=this.types[e];return o?o.reduce(((e,{name:n,type:o})=>(e[n]=this._visit(o,t[n],r),e)),{}):Ml.throwArgumentError(`unknown type: ${e}`,"type",e)}visit(e,t){return this._visit(this.primaryType,e,t)}static from(e){return new Hl(e)}static getPrimaryType(e){return Hl.from(e).primaryType}static hashStruct(e,t,r){return Hl.from(t).hashStruct(e,r)}static hashDomain(e){const t=[];for(const r in e){const n=Wl[r];n||Ml.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(r)}`,"domain",e),t.push({name:r,type:n})}return t.sort(((e,t)=>Dl.indexOf(e.name)-Dl.indexOf(t.name))),Hl.hashStruct("EIP712Domain",{EIP712Domain:t},e)}static encode(e,t,r){return Ds(["0x1901",Hl.hashDomain(e),Hl.from(t).hash(r)])}static hash(e,t,r){return zs(Hl.encode(e,t,r))}static resolveNames(e,t,r,n){return Nl(this,void 0,void 0,(function*(){e=ka(e);const o={};e.verifyingContract&&!_s(e.verifyingContract,20)&&(o[e.verifyingContract]="0x");const i=Hl.from(t);i.visit(r,((e,t)=>("address"!==e||_s(t,20)||(o[t]="0x"),t)));for(const e in o)o[e]=yield n(e);return e.verifyingContract&&o[e.verifyingContract]&&(e.verifyingContract=o[e.verifyingContract]),r=i.visit(r,((e,t)=>"address"===e&&o[t]?o[t]:t)),{domain:e,value:r}}))}static getPayload(e,t,r){Hl.hashDomain(e);const n={},o=[];Dl.forEach((t=>{const r=e[t];null!=r&&(n[t]=Ul[t](r),o.push({name:t,type:Wl[t]}))}));const i=Hl.from(t),s=ka(t);return s.EIP712Domain?Ml.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",t):s.EIP712Domain=o,i.encode(r),{types:s,domain:n,primaryType:i.primaryType,message:i.visit(r,((e,t)=>{if(e.match(/^bytes(\d*)/))return Ps(Is(t));if(e.match(/^u?int/))return y.BigNumber.from(t).toString();switch(e){case"address":return t.toLowerCase();case"bool":return!!t;case"string":return"string"!=typeof t&&Ml.throwArgumentError("invalid string","value",t),t}return Ml.throwArgumentError("unsupported type","type",e)}))}}}var zl={},Yl={},Gl=Xl;function Xl(e,t){if(!e)throw new Error(t||"Assertion failed")}Xl.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var Jl,ql={exports:{}},Ql={exports:{}};!function(e){try{var t=require("util");if("function"!=typeof t.inherits)throw"";e.exports=t.inherits}catch(t){e.exports=(Jl||(Jl=1,"function"==typeof Object.create?Ql.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:Ql.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}),Ql.exports)}}(ql);var Kl=Gl,$l=ql.exports;function ec(e,t){return 55296==(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1)))}function tc(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function rc(e){return 1===e.length?"0"+e:e}function nc(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}Yl.inherits=$l,Yl.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),o=0;o<e.length;o+=2)r.push(parseInt(e[o]+e[o+1],16))}else for(var n=0,o=0;o<e.length;o++){var i=e.charCodeAt(o);i<128?r[n++]=i:i<2048?(r[n++]=i>>6|192,r[n++]=63&i|128):ec(e,o)?(i=65536+((1023&i)<<10)+(1023&e.charCodeAt(++o)),r[n++]=i>>18|240,r[n++]=i>>12&63|128,r[n++]=i>>6&63|128,r[n++]=63&i|128):(r[n++]=i>>12|224,r[n++]=i>>6&63|128,r[n++]=63&i|128)}else for(o=0;o<e.length;o++)r[o]=0|e[o];return r},Yl.toHex=function(e){for(var t="",r=0;r<e.length;r++)t+=rc(e[r].toString(16));return t},Yl.htonl=tc,Yl.toHex32=function(e,t){for(var r="",n=0;n<e.length;n++){var o=e[n];"little"===t&&(o=tc(o)),r+=nc(o.toString(16))}return r},Yl.zero2=rc,Yl.zero8=nc,Yl.join32=function(e,t,r,n){var o=r-t;Kl(o%4==0);for(var i=new Array(o/4),s=0,a=t;s<i.length;s++,a+=4){var l;l="big"===n?e[a]<<24|e[a+1]<<16|e[a+2]<<8|e[a+3]:e[a+3]<<24|e[a+2]<<16|e[a+1]<<8|e[a],i[s]=l>>>0}return i},Yl.split32=function(e,t){for(var r=new Array(4*e.length),n=0,o=0;n<e.length;n++,o+=4){var i=e[n];"big"===t?(r[o]=i>>>24,r[o+1]=i>>>16&255,r[o+2]=i>>>8&255,r[o+3]=255&i):(r[o+3]=i>>>24,r[o+2]=i>>>16&255,r[o+1]=i>>>8&255,r[o]=255&i)}return r},Yl.rotr32=function(e,t){return e>>>t|e<<32-t},Yl.rotl32=function(e,t){return e<<t|e>>>32-t},Yl.sum32=function(e,t){return e+t>>>0},Yl.sum32_3=function(e,t,r){return e+t+r>>>0},Yl.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},Yl.sum32_5=function(e,t,r,n,o){return e+t+r+n+o>>>0},Yl.sum64=function(e,t,r,n){var o=e[t],i=n+e[t+1]>>>0,s=(i<n?1:0)+r+o;e[t]=s>>>0,e[t+1]=i},Yl.sum64_hi=function(e,t,r,n){return(t+n>>>0<t?1:0)+e+r>>>0},Yl.sum64_lo=function(e,t,r,n){return t+n>>>0},Yl.sum64_4_hi=function(e,t,r,n,o,i,s,a){var l=0,c=t;return l+=(c=c+n>>>0)<t?1:0,l+=(c=c+i>>>0)<i?1:0,e+r+o+s+(l+=(c=c+a>>>0)<a?1:0)>>>0},Yl.sum64_4_lo=function(e,t,r,n,o,i,s,a){return t+n+i+a>>>0},Yl.sum64_5_hi=function(e,t,r,n,o,i,s,a,l,c){var u=0,d=t;return u+=(d=d+n>>>0)<t?1:0,u+=(d=d+i>>>0)<i?1:0,u+=(d=d+a>>>0)<a?1:0,e+r+o+s+l+(u+=(d=d+c>>>0)<c?1:0)>>>0},Yl.sum64_5_lo=function(e,t,r,n,o,i,s,a,l,c){return t+n+i+a+c>>>0},Yl.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},Yl.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},Yl.shr64_hi=function(e,t,r){return e>>>r},Yl.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0};var oc={},ic=Yl,sc=Gl;function ac(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}oc.BlockHash=ac,ac.prototype.update=function(e,t){if(e=ic.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=ic.join32(e,0,e.length-r,this.endian);for(var n=0;n<e.length;n+=this._delta32)this._update(e,n,n+this._delta32)}return this},ac.prototype.digest=function(e){return this.update(this._pad()),sc(null===this.pending),this._digest(e)},ac.prototype._pad=function(){var e=this.pendingTotal,t=this._delta8,r=t-(e+this.padLength)%t,n=new Array(r+this.padLength);n[0]=128;for(var o=1;o<r;o++)n[o]=0;if(e<<=3,"big"===this.endian){for(var i=8;i<this.padLength;i++)n[o++]=0;n[o++]=0,n[o++]=0,n[o++]=0,n[o++]=0,n[o++]=e>>>24&255,n[o++]=e>>>16&255,n[o++]=e>>>8&255,n[o++]=255&e}else for(n[o++]=255&e,n[o++]=e>>>8&255,n[o++]=e>>>16&255,n[o++]=e>>>24&255,n[o++]=0,n[o++]=0,n[o++]=0,n[o++]=0,i=8;i<this.padLength;i++)n[o++]=0;return n};var lc={},cc={},uc=Yl.rotr32;function dc(e,t,r){return e&t^~e&r}function pc(e,t,r){return e&t^e&r^t&r}function fc(e,t,r){return e^t^r}cc.ft_1=function(e,t,r,n){return 0===e?dc(t,r,n):1===e||3===e?fc(t,r,n):2===e?pc(t,r,n):void 0},cc.ch32=dc,cc.maj32=pc,cc.p32=fc,cc.s0_256=function(e){return uc(e,2)^uc(e,13)^uc(e,22)},cc.s1_256=function(e){return uc(e,6)^uc(e,11)^uc(e,25)},cc.g0_256=function(e){return uc(e,7)^uc(e,18)^e>>>3},cc.g1_256=function(e){return uc(e,17)^uc(e,19)^e>>>10};var hc=Yl,mc=oc,gc=cc,yc=hc.rotl32,bc=hc.sum32,vc=hc.sum32_5,xc=gc.ft_1,wc=mc.BlockHash,Ec=[1518500249,1859775393,2400959708,3395469782];function Ac(){if(!(this instanceof Ac))return new Ac;wc.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}hc.inherits(Ac,wc);var kc=Ac;Ac.blockSize=512,Ac.outSize=160,Ac.hmacStrength=80,Ac.padLength=64,Ac.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=yc(r[n-3]^r[n-8]^r[n-14]^r[n-16],1);var o=this.h[0],i=this.h[1],s=this.h[2],a=this.h[3],l=this.h[4];for(n=0;n<r.length;n++){var c=~~(n/20),u=vc(yc(o,5),xc(c,i,s,a),l,r[n],Ec[c]);l=a,a=s,s=yc(i,30),i=o,o=u}this.h[0]=bc(this.h[0],o),this.h[1]=bc(this.h[1],i),this.h[2]=bc(this.h[2],s),this.h[3]=bc(this.h[3],a),this.h[4]=bc(this.h[4],l)},Ac.prototype._digest=function(e){return"hex"===e?hc.toHex32(this.h,"big"):hc.split32(this.h,"big")};var Cc=Yl,Rc=oc,Sc=cc,Tc=Gl,Nc=Cc.sum32,Mc=Cc.sum32_4,Oc=Cc.sum32_5,Ic=Sc.ch32,jc=Sc.maj32,Fc=Sc.s0_256,_c=Sc.s1_256,Pc=Sc.g0_256,Bc=Sc.g1_256,Wc=Rc.BlockHash,Dc=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function Lc(){if(!(this instanceof Lc))return new Lc;Wc.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=Dc,this.W=new Array(64)}Cc.inherits(Lc,Wc);var Uc=Lc;Lc.blockSize=512,Lc.outSize=256,Lc.hmacStrength=192,Lc.padLength=64,Lc.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=Mc(Bc(r[n-2]),r[n-7],Pc(r[n-15]),r[n-16]);var o=this.h[0],i=this.h[1],s=this.h[2],a=this.h[3],l=this.h[4],c=this.h[5],u=this.h[6],d=this.h[7];for(Tc(this.k.length===r.length),n=0;n<r.length;n++){var p=Oc(d,_c(l),Ic(l,c,u),this.k[n],r[n]),f=Nc(Fc(o),jc(o,i,s));d=u,u=c,c=l,l=Nc(a,p),a=s,s=i,i=o,o=Nc(p,f)}this.h[0]=Nc(this.h[0],o),this.h[1]=Nc(this.h[1],i),this.h[2]=Nc(this.h[2],s),this.h[3]=Nc(this.h[3],a),this.h[4]=Nc(this.h[4],l),this.h[5]=Nc(this.h[5],c),this.h[6]=Nc(this.h[6],u),this.h[7]=Nc(this.h[7],d)},Lc.prototype._digest=function(e){return"hex"===e?Cc.toHex32(this.h,"big"):Cc.split32(this.h,"big")};var Vc=Yl,Zc=Uc;function Hc(){if(!(this instanceof Hc))return new Hc;Zc.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}Vc.inherits(Hc,Zc);var zc=Hc;Hc.blockSize=512,Hc.outSize=224,Hc.hmacStrength=192,Hc.padLength=64,Hc.prototype._digest=function(e){return"hex"===e?Vc.toHex32(this.h.slice(0,7),"big"):Vc.split32(this.h.slice(0,7),"big")};var Yc=Yl,Gc=oc,Xc=Gl,Jc=Yc.rotr64_hi,qc=Yc.rotr64_lo,Qc=Yc.shr64_hi,Kc=Yc.shr64_lo,$c=Yc.sum64,eu=Yc.sum64_hi,tu=Yc.sum64_lo,ru=Yc.sum64_4_hi,nu=Yc.sum64_4_lo,ou=Yc.sum64_5_hi,iu=Yc.sum64_5_lo,su=Gc.BlockHash,au=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function lu(){if(!(this instanceof lu))return new lu;su.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=au,this.W=new Array(160)}Yc.inherits(lu,su);var cu=lu;function uu(e,t,r,n,o){var i=e&r^~e&o;return i<0&&(i+=4294967296),i}function du(e,t,r,n,o,i){var s=t&n^~t&i;return s<0&&(s+=4294967296),s}function pu(e,t,r,n,o){var i=e&r^e&o^r&o;return i<0&&(i+=4294967296),i}function fu(e,t,r,n,o,i){var s=t&n^t&i^n&i;return s<0&&(s+=4294967296),s}function hu(e,t){var r=Jc(e,t,28)^Jc(t,e,2)^Jc(t,e,7);return r<0&&(r+=4294967296),r}function mu(e,t){var r=qc(e,t,28)^qc(t,e,2)^qc(t,e,7);return r<0&&(r+=4294967296),r}function gu(e,t){var r=Jc(e,t,14)^Jc(e,t,18)^Jc(t,e,9);return r<0&&(r+=4294967296),r}function yu(e,t){var r=qc(e,t,14)^qc(e,t,18)^qc(t,e,9);return r<0&&(r+=4294967296),r}function bu(e,t){var r=Jc(e,t,1)^Jc(e,t,8)^Qc(e,t,7);return r<0&&(r+=4294967296),r}function vu(e,t){var r=qc(e,t,1)^qc(e,t,8)^Kc(e,t,7);return r<0&&(r+=4294967296),r}function xu(e,t){var r=Jc(e,t,19)^Jc(t,e,29)^Qc(e,t,6);return r<0&&(r+=4294967296),r}function wu(e,t){var r=qc(e,t,19)^qc(t,e,29)^Kc(e,t,6);return r<0&&(r+=4294967296),r}lu.blockSize=1024,lu.outSize=512,lu.hmacStrength=192,lu.padLength=128,lu.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n<r.length;n+=2){var o=xu(r[n-4],r[n-3]),i=wu(r[n-4],r[n-3]),s=r[n-14],a=r[n-13],l=bu(r[n-30],r[n-29]),c=vu(r[n-30],r[n-29]),u=r[n-32],d=r[n-31];r[n]=ru(o,i,s,a,l,c,u,d),r[n+1]=nu(o,i,s,a,l,c,u,d)}},lu.prototype._update=function(e,t){this._prepareBlock(e,t);var r=this.W,n=this.h[0],o=this.h[1],i=this.h[2],s=this.h[3],a=this.h[4],l=this.h[5],c=this.h[6],u=this.h[7],d=this.h[8],p=this.h[9],f=this.h[10],h=this.h[11],m=this.h[12],g=this.h[13],y=this.h[14],b=this.h[15];Xc(this.k.length===r.length);for(var v=0;v<r.length;v+=2){var x=y,w=b,E=gu(d,p),A=yu(d,p),k=uu(d,p,f,h,m),C=du(d,p,f,h,m,g),R=this.k[v],S=this.k[v+1],T=r[v],N=r[v+1],M=ou(x,w,E,A,k,C,R,S,T,N),O=iu(x,w,E,A,k,C,R,S,T,N);x=hu(n,o),w=mu(n,o),E=pu(n,o,i,s,a),A=fu(n,o,i,s,a,l);var I=eu(x,w,E,A),j=tu(x,w,E,A);y=m,b=g,m=f,g=h,f=d,h=p,d=eu(c,u,M,O),p=tu(u,u,M,O),c=a,u=l,a=i,l=s,i=n,s=o,n=eu(M,O,I,j),o=tu(M,O,I,j)}$c(this.h,0,n,o),$c(this.h,2,i,s),$c(this.h,4,a,l),$c(this.h,6,c,u),$c(this.h,8,d,p),$c(this.h,10,f,h),$c(this.h,12,m,g),$c(this.h,14,y,b)},lu.prototype._digest=function(e){return"hex"===e?Yc.toHex32(this.h,"big"):Yc.split32(this.h,"big")};var Eu=Yl,Au=cu;function ku(){if(!(this instanceof ku))return new ku;Au.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}Eu.inherits(ku,Au);var Cu=ku;ku.blockSize=1024,ku.outSize=384,ku.hmacStrength=192,ku.padLength=128,ku.prototype._digest=function(e){return"hex"===e?Eu.toHex32(this.h.slice(0,12),"big"):Eu.split32(this.h.slice(0,12),"big")},lc.sha1=kc,lc.sha224=zc,lc.sha256=Uc,lc.sha384=Cu,lc.sha512=cu;var Ru={},Su=Yl,Tu=oc,Nu=Su.rotl32,Mu=Su.sum32,Ou=Su.sum32_3,Iu=Su.sum32_4,ju=Tu.BlockHash;function Fu(){if(!(this instanceof Fu))return new Fu;ju.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function _u(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function Pu(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function Bu(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}Su.inherits(Fu,ju),Ru.ripemd160=Fu,Fu.blockSize=512,Fu.outSize=160,Fu.hmacStrength=192,Fu.padLength=64,Fu.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],o=this.h[2],i=this.h[3],s=this.h[4],a=r,l=n,c=o,u=i,d=s,p=0;p<80;p++){var f=Mu(Nu(Iu(r,_u(p,n,o,i),e[Wu[p]+t],Pu(p)),Lu[p]),s);r=s,s=i,i=Nu(o,10),o=n,n=f,f=Mu(Nu(Iu(a,_u(79-p,l,c,u),e[Du[p]+t],Bu(p)),Uu[p]),d),a=d,d=u,u=Nu(c,10),c=l,l=f}f=Ou(this.h[1],o,u),this.h[1]=Ou(this.h[2],i,d),this.h[2]=Ou(this.h[3],s,a),this.h[3]=Ou(this.h[4],r,l),this.h[4]=Ou(this.h[0],n,c),this.h[0]=f},Fu.prototype._digest=function(e){return"hex"===e?Su.toHex32(this.h,"little"):Su.split32(this.h,"little")};var Wu=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],Du=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],Lu=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],Uu=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],Vu=Yl,Zu=Gl;function Hu(e,t,r){if(!(this instanceof Hu))return new Hu(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(Vu.toArray(t,r))}var zu=Hu;Hu.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),Zu(e.length<=this.blockSize);for(var t=e.length;t<this.blockSize;t++)e.push(0);for(t=0;t<e.length;t++)e[t]^=54;for(this.inner=(new this.Hash).update(e),t=0;t<e.length;t++)e[t]^=106;this.outer=(new this.Hash).update(e)},Hu.prototype.update=function(e,t){return this.inner.update(e,t),this},Hu.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)},function(e){var t=zl;t.utils=Yl,t.common=oc,t.sha=lc,t.ripemd=Ru,t.hmac=zu,t.sha1=t.sha.sha1,t.sha256=t.sha.sha256,t.sha224=t.sha.sha224,t.sha384=t.sha.sha384,t.sha512=t.sha.sha512,t.ripemd160=t.ripemd.ripemd160}();var Yu=zl;function Gu(e){return"0x"+Yu.sha256().update(Is(e)).digest("hex")}new Cs("sha2/5.7.0");var Xu=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};function Ju(e,t){return Xu(this,void 0,void 0,(function*(){null==t&&(t={});const r={method:t.method||"GET",headers:t.headers||{},body:t.body||void 0};if(!0!==t.skipFetchSetup&&(r.mode="cors",r.cache="no-cache",r.credentials="same-origin",r.redirect="follow",r.referrer="client"),null!=t.fetchOptions){const e=t.fetchOptions;e.mode&&(r.mode=e.mode),e.cache&&(r.cache=e.cache),e.credentials&&(r.credentials=e.credentials),e.redirect&&(r.redirect=e.redirect),e.referrer&&(r.referrer=e.referrer)}const n=yield fetch(e,r),o=yield n.arrayBuffer(),i={};return n.headers.forEach?n.headers.forEach(((e,t)=>{i[t.toLowerCase()]=e})):n.headers.keys().forEach((e=>{i[e.toLowerCase()]=n.headers.get(e)})),{headers:i,statusCode:n.status,statusMessage:n.statusText,body:Is(new Uint8Array(o))}}))}var qu=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Qu=new Cs("web/5.7.1");function Ku(e){return new Promise((t=>{setTimeout(t,e)}))}function $u(e,t){if(null==e)return null;if("string"==typeof e)return e;if(Ns(e)){if(t&&("text"===t.split("/")[0]||"application/json"===t.split(";")[0].trim()))try{return nl(e)}catch(e){}return Ps(e)}return e}function ed(e,t,r){let n=null;if(null!=t){n=rl(t);const r="string"==typeof e?{url:e}:ka(e);if(r.headers){0!==Object.keys(r.headers).filter((e=>"content-type"===e.toLowerCase())).length||(r.headers=ka(r.headers),r.headers["content-type"]="application/json")}else r.headers={"content-type":"application/json"};e=r}return function(e,t,r){const n="object"==typeof e&&null!=e.throttleLimit?e.throttleLimit:12;Qu.assertArgument(n>0&&n%1==0,"invalid connection throttle limit","connection.throttleLimit",n);const o="object"==typeof e?e.throttleCallback:null,i="object"==typeof e&&"number"==typeof e.throttleSlotInterval?e.throttleSlotInterval:100;Qu.assertArgument(i>0&&i%1==0,"invalid connection throttle slot interval","connection.throttleSlotInterval",i);const s="object"==typeof e&&!!e.errorPassThrough,a={};let l=null;const c={method:"GET"};let u=!1,d=12e4;if("string"==typeof e)l=e;else if("object"==typeof e){if(null!=e&&null!=e.url||Qu.throwArgumentError("missing URL","connection.url",e),l=e.url,"number"==typeof e.timeout&&e.timeout>0&&(d=e.timeout),e.headers)for(const t in e.headers)a[t.toLowerCase()]={key:t,value:String(e.headers[t])},["if-none-match","if-modified-since"].indexOf(t.toLowerCase())>=0&&(u=!0);if(c.allowGzip=!!e.allowGzip,null!=e.user&&null!=e.password){"https:"!==l.substring(0,6)&&!0!==e.allowInsecureAuthentication&&Qu.throwError("basic authentication requires a secure https url",Cs.errors.INVALID_ARGUMENT,{argument:"url",url:l,user:e.user,password:"[REDACTED]"});const t=e.user+":"+e.password;a.authorization={key:"Authorization",value:"Basic "+Va(rl(t))}}null!=e.skipFetchSetup&&(c.skipFetchSetup=!!e.skipFetchSetup),null!=e.fetchOptions&&(c.fetchOptions=ka(e.fetchOptions))}const p=new RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),f=l?l.match(p):null;if(f)try{const e={statusCode:200,statusMessage:"OK",headers:{"content-type":f[1]||"text/plain"},body:f[2]?Ua(f[3]):(h=f[3],rl(h.replace(/%([0-9a-f][0-9a-f])/gi,((e,t)=>String.fromCharCode(parseInt(t,16))))))};let t=e.body;return r&&(t=r(e.body,e)),Promise.resolve(t)}catch(e){Qu.throwError("processing response error",Cs.errors.SERVER_ERROR,{body:$u(f[1],f[2]),error:e,requestBody:null,requestMethod:"GET",url:l})}var h;t&&(c.method="POST",c.body=t,null==a["content-type"]&&(a["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==a["content-length"]&&(a["content-length"]={key:"Content-Length",value:String(t.length)}));const m={};Object.keys(a).forEach((e=>{const t=a[e];m[t.key]=t.value})),c.headers=m;const g=function(){let e=null;return{promise:new Promise((function(t,r){d&&(e=setTimeout((()=>{null!=e&&(e=null,r(Qu.makeError("timeout",Cs.errors.TIMEOUT,{requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,timeout:d,url:l})))}),d))})),cancel:function(){null!=e&&(clearTimeout(e),e=null)}}}(),y=function(){return qu(this,void 0,void 0,(function*(){for(let e=0;e<n;e++){let t=null;try{if(t=yield Ju(l,c),e<n)if(301===t.statusCode||302===t.statusCode){const e=t.headers.location||"";if("GET"===c.method&&e.match(/^https:/)){l=t.headers.location;continue}}else if(429===t.statusCode){let r=!0;if(o&&(r=yield o(e,l)),r){let r=0;const n=t.headers["retry-after"];r="string"==typeof n&&n.match(/^[1-9][0-9]*$/)?1e3*parseInt(n):i*parseInt(String(Math.random()*Math.pow(2,e))),yield Ku(r);continue}}}catch(e){t=e.response,null==t&&(g.cancel(),Qu.throwError("missing response",Cs.errors.SERVER_ERROR,{requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,serverError:e,url:l}))}let a=t.body;if(u&&304===t.statusCode?a=null:!s&&(t.statusCode<200||t.statusCode>=300)&&(g.cancel(),Qu.throwError("bad response",Cs.errors.SERVER_ERROR,{status:t.statusCode,headers:t.headers,body:$u(a,t.headers?t.headers["content-type"]:null),requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,url:l})),r)try{const e=yield r(a,t);return g.cancel(),e}catch(r){if(r.throttleRetry&&e<n){let t=!0;if(o&&(t=yield o(e,l)),t){const t=i*parseInt(String(Math.random()*Math.pow(2,e)));yield Ku(t);continue}}g.cancel(),Qu.throwError("processing response error",Cs.errors.SERVER_ERROR,{body:$u(a,t.headers?t.headers["content-type"]:null),error:r,requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,url:l})}return g.cancel(),a}return Qu.throwError("failed response",Cs.errors.SERVER_ERROR,{requestBody:$u(c.body,m["content-type"]),requestMethod:c.method,url:l})}))}();return Promise.race([g.promise,y])}(e,n,((e,t)=>{let n=null;if(null!=e)try{n=JSON.parse(nl(e))}catch(t){Qu.throwError("invalid JSON",Cs.errors.SERVER_ERROR,{body:e,error:t})}return r&&(n=r(n,t)),n}))}function td(e,t){return t||(t={}),null==(t=ka(t)).floor&&(t.floor=0),null==t.ceiling&&(t.ceiling=1e4),null==t.interval&&(t.interval=250),new Promise((function(r,n){let o=null,i=!1;const s=()=>!i&&(i=!0,o&&clearTimeout(o),!0);t.timeout&&(o=setTimeout((()=>{s()&&n(new Error("timeout"))}),t.timeout));const a=t.retryLimit;let l=0;!function o(){return e().then((function(e){if(void 0!==e)s()&&r(e);else if(t.oncePoll)t.oncePoll.once("poll",o);else if(t.onceBlock)t.onceBlock.once("block",o);else if(!i){if(l++,l>a)return void(s()&&n(new Error("retry limit reached")));let e=t.interval*parseInt(String(Math.random()*Math.pow(2,l)));e<t.floor&&(e=t.floor),e>t.ceiling&&(e=t.ceiling),setTimeout(o,e)}return null}),(function(e){s()&&n(e)}))}()}))}for(var rd="qpzry9x8gf2tvdw0s3jn54khce6mua7l",nd={},od=0;od<rd.length;od++){var id=rd.charAt(od);if(void 0!==nd[id])throw new TypeError(id+" is ambiguous");nd[id]=od}function sd(e){var t=e>>25;return(33554431&e)<<5^996825010&-(t>>0&1)^642813549&-(t>>1&1)^513874426&-(t>>2&1)^1027748829&-(t>>3&1)^705979059&-(t>>4&1)}function ad(e){for(var t=1,r=0;r<e.length;++r){var n=e.charCodeAt(r);if(n<33||n>126)return"Invalid prefix ("+e+")";t=sd(t)^n>>5}for(t=sd(t),r=0;r<e.length;++r){var o=e.charCodeAt(r);t=sd(t)^31&o}return t}function ld(e,t){if(t=t||90,e.length<8)return e+" too short";if(e.length>t)return"Exceeds length limit";var r=e.toLowerCase(),n=e.toUpperCase();if(e!==r&&e!==n)return"Mixed-case string "+e;var o=(e=r).lastIndexOf("1");if(-1===o)return"No separator character for "+e;if(0===o)return"Missing prefix for "+e;var i=e.slice(0,o),s=e.slice(o+1);if(s.length<6)return"Data too short";var a=ad(i);if("string"==typeof a)return a;for(var l=[],c=0;c<s.length;++c){var u=s.charAt(c),d=nd[u];if(void 0===d)return"Unknown character "+u;a=sd(a)^d,c+6>=s.length||l.push(d)}return 1!==a?"Invalid checksum for "+e:{prefix:i,words:l}}function cd(e,t,r,n){for(var o=0,i=0,s=(1<<r)-1,a=[],l=0;l<e.length;++l)for(o=o<<t|e[l],i+=t;i>=r;)i-=r,a.push(o>>i&s);if(n)i>0&&a.push(o<<r-i&s);else{if(i>=t)return"Excess padding";if(o<<r-i&s)return"Non-zero padding"}return a}var ud={decodeUnsafe:function(){var e=ld.apply(null,arguments);if("object"==typeof e)return e},decode:function(e){var t=ld.apply(null,arguments);if("object"==typeof t)return t;throw new Error(t)},encode:function(e,t,r){if(r=r||90,e.length+7+t.length>r)throw new TypeError("Exceeds length limit");var n=ad(e=e.toLowerCase());if("string"==typeof n)throw new Error(n);for(var o=e+"1",i=0;i<t.length;++i){var s=t[i];if(s>>5!=0)throw new Error("Non 5-bit word");n=sd(n)^s,o+=rd.charAt(s)}for(i=0;i<6;++i)n=sd(n);for(n^=1,i=0;i<6;++i){o+=rd.charAt(n>>5*(5-i)&31)}return o},toWordsUnsafe:function(e){var t=cd(e,8,5,!0);if(Array.isArray(t))return t},toWords:function(e){var t=cd(e,8,5,!0);if(Array.isArray(t))return t;throw new Error(t)},fromWordsUnsafe:function(e){var t=cd(e,5,8,!1);if(Array.isArray(t))return t},fromWords:function(e){var t=cd(e,5,8,!1);if(Array.isArray(t))return t;throw new Error(t)}};const dd="providers/5.7.2";var pd={exports:{}};!function(e,t){function r(e,t){if(!e)throw new Error(t||"Assertion failed")}function n(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var i;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{i="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:require("buffer").Buffer}catch(e){}function s(e,t){var n=e.charCodeAt(t);return n>=48&&n<=57?n-48:n>=65&&n<=70?n-55:n>=97&&n<=102?n-87:void r(!1,"Invalid character in "+e)}function a(e,t,r){var n=s(e,r);return r-1>=t&&(n|=s(e,r-1)<<4),n}function l(e,t,n,o){for(var i=0,s=0,a=Math.min(e.length,n),l=t;l<a;l++){var c=e.charCodeAt(l)-48;i*=o,s=c>=49?c-49+10:c>=17?c-17+10:c,r(c>=0&&s<o,"Invalid character"),i+=s}return i}function c(e,t){e.words=t.words,e.length=t.length,e.negative=t.negative,e.red=t.red}if(o.isBN=function(e){return e instanceof o||null!==e&&"object"==typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,n){if("number"==typeof e)return this._initNumber(e,t,n);if("object"==typeof e)return this._initArray(e,t,n);"hex"===t&&(t=16),r(t===(0|t)&&t>=2&&t<=36);var o=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(o++,this.negative=1),o<e.length&&(16===t?this._parseHex(e,o,n):(this._parseBase(e,t,o),"le"===n&&this._initArray(this.toArray(),t,n)))},o.prototype._initNumber=function(e,t,n){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(r(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===n&&this._initArray(this.toArray(),t,n)},o.prototype._initArray=function(e,t,n){if(r("number"==typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var o=0;o<this.length;o++)this.words[o]=0;var i,s,a=0;if("be"===n)for(o=e.length-1,i=0;o>=0;o-=3)s=e[o]|e[o-1]<<8|e[o-2]<<16,this.words[i]|=s<<a&67108863,this.words[i+1]=s>>>26-a&67108863,(a+=24)>=26&&(a-=26,i++);else if("le"===n)for(o=0,i=0;o<e.length;o+=3)s=e[o]|e[o+1]<<8|e[o+2]<<16,this.words[i]|=s<<a&67108863,this.words[i+1]=s>>>26-a&67108863,(a+=24)>=26&&(a-=26,i++);return this._strip()},o.prototype._parseHex=function(e,t,r){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var o,i=0,s=0;if("be"===r)for(n=e.length-1;n>=t;n-=2)o=a(e,t,n)<<i,this.words[s]|=67108863&o,i>=18?(i-=18,s+=1,this.words[s]|=o>>>26):i+=8;else for(n=(e.length-t)%2==0?t+1:t;n<e.length;n+=2)o=a(e,t,n)<<i,this.words[s]|=67108863&o,i>=18?(i-=18,s+=1,this.words[s]|=o>>>26):i+=8;this._strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,o=1;o<=67108863;o*=t)n++;n--,o=o/t|0;for(var i=e.length-r,s=i%n,a=Math.min(i,i-s)+r,c=0,u=r;u<a;u+=n)c=l(e,u,u+n,t),this.imuln(o),this.words[0]+c<67108864?this.words[0]+=c:this._iaddn(c);if(0!==s){var d=1;for(c=l(e,u,e.length,t),u=0;u<s;u++)d*=t;this.imuln(d),this.words[0]+c<67108864?this.words[0]+=c:this._iaddn(c)}this._strip()},o.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},o.prototype._move=function(e){c(e,this)},o.prototype.clone=function(){var e=new o(null);return this.copy(e),e},o.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},o.prototype._strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{o.prototype[Symbol.for("nodejs.util.inspect.custom")]=u}catch(e){o.prototype.inspect=u}else o.prototype.inspect=u;function u(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],p=[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],f=[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 h(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var o=0|e.words[0],i=0|t.words[0],s=o*i,a=67108863&s,l=s/67108864|0;r.words[0]=a;for(var c=1;c<n;c++){for(var u=l>>>26,d=67108863&l,p=Math.min(c,t.length-1),f=Math.max(0,c-e.length+1);f<=p;f++){var h=c-f|0;u+=(s=(o=0|e.words[h])*(i=0|t.words[f])+d)/67108864|0,d=67108863&s}r.words[c]=0|d,l=0|u}return 0!==l?r.words[c]=0|l:r.length--,r._strip()}o.prototype.toString=function(e,t){var n;if(t=0|t||1,16===(e=e||10)||"hex"===e){n="";for(var o=0,i=0,s=0;s<this.length;s++){var a=this.words[s],l=(16777215&(a<<o|i)).toString(16);i=a>>>24-o&16777215,(o+=2)>=26&&(o-=26,s--),n=0!==i||s!==this.length-1?d[6-l.length]+l+n:l+n}for(0!==i&&(n=i.toString(16)+n);n.length%t!=0;)n="0"+n;return 0!==this.negative&&(n="-"+n),n}if(e===(0|e)&&e>=2&&e<=36){var c=p[e],u=f[e];n="";var h=this.clone();for(h.negative=0;!h.isZero();){var m=h.modrn(u).toString(e);n=(h=h.idivn(u)).isZero()?m+n:d[c-m.length]+m+n}for(this.isZero()&&(n="0"+n);n.length%t!=0;)n="0"+n;return 0!==this.negative&&(n="-"+n),n}r(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16,2)},i&&(o.prototype.toBuffer=function(e,t){return this.toArrayLike(i,e,t)}),o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,n){this._strip();var o=this.byteLength(),i=n||Math.max(1,o);r(o<=i,"byte array longer than desired length"),r(i>0,"Requested array length <= 0");var s=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,i);return this["_toArrayLike"+("le"===t?"LE":"BE")](s,o),s},o.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,o=0,i=0;o<this.length;o++){var s=this.words[o]<<i|n;e[r++]=255&s,r<e.length&&(e[r++]=s>>8&255),r<e.length&&(e[r++]=s>>16&255),6===i?(r<e.length&&(e[r++]=s>>24&255),n=0,i=0):(n=s>>>24,i+=2)}if(r<e.length)for(e[r++]=n;r<e.length;)e[r++]=0},o.prototype._toArrayLikeBE=function(e,t){for(var r=e.length-1,n=0,o=0,i=0;o<this.length;o++){var s=this.words[o]<<i|n;e[r--]=255&s,r>=0&&(e[r--]=s>>8&255),r>=0&&(e[r--]=s>>16&255),6===i?(r>=0&&(e[r--]=s>>24&255),n=0,i=0):(n=s>>>24,i+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var r=this._zeroBits(this.words[t]);if(e+=r,26!==r)break}return e},o.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},o.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},o.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},o.prototype.isNeg=function(){return 0!==this.negative},o.prototype.neg=function(){return this.clone().ineg()},o.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},o.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this._strip()},o.prototype.ior=function(e){return r(0==(this.negative|e.negative)),this.iuor(e)},o.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;r<t.length;r++)this.words[r]=this.words[r]&e.words[r];return this.length=t.length,this._strip()},o.prototype.iand=function(e){return r(0==(this.negative|e.negative)),this.iuand(e)},o.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;n<r.length;n++)this.words[n]=t.words[n]^r.words[n];if(this!==t)for(;n<t.length;n++)this.words[n]=t.words[n];return this.length=t.length,this._strip()},o.prototype.ixor=function(e){return r(0==(this.negative|e.negative)),this.iuxor(e)},o.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){r("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),n=e%26;this._expand(t),n>0&&t--;for(var o=0;o<t;o++)this.words[o]=67108863&~this.words[o];return n>0&&(this.words[o]=~this.words[o]&67108863>>26-n),this._strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){r("number"==typeof e&&e>=0);var n=e/26|0,o=e%26;return this._expand(n+1),this.words[n]=t?this.words[n]|1<<o:this.words[n]&~(1<<o),this._strip()},o.prototype.iadd=function(e){var t,r,n;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(r=this,n=e):(r=e,n=this);for(var o=0,i=0;i<n.length;i++)t=(0|r.words[i])+(0|n.words[i])+o,this.words[i]=67108863&t,o=t>>>26;for(;0!==o&&i<r.length;i++)t=(0|r.words[i])+o,this.words[i]=67108863&t,o=t>>>26;if(this.length=r.length,0!==o)this.words[this.length]=o,this.length++;else if(r!==this)for(;i<r.length;i++)this.words[i]=r.words[i];return this},o.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},o.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,o=this.cmp(e);if(0===o)return this.negative=0,this.length=1,this.words[0]=0,this;o>0?(r=this,n=e):(r=e,n=this);for(var i=0,s=0;s<n.length;s++)i=(t=(0|r.words[s])-(0|n.words[s])+i)>>26,this.words[s]=67108863&t;for(;0!==i&&s<r.length;s++)i=(t=(0|r.words[s])+i)>>26,this.words[s]=67108863&t;if(0===i&&s<r.length&&r!==this)for(;s<r.length;s++)this.words[s]=r.words[s];return this.length=Math.max(this.length,s),r!==this&&(this.negative=1),this._strip()},o.prototype.sub=function(e){return this.clone().isub(e)};var m=function(e,t,r){var n,o,i,s=e.words,a=t.words,l=r.words,c=0,u=0|s[0],d=8191&u,p=u>>>13,f=0|s[1],h=8191&f,m=f>>>13,g=0|s[2],y=8191&g,b=g>>>13,v=0|s[3],x=8191&v,w=v>>>13,E=0|s[4],A=8191&E,k=E>>>13,C=0|s[5],R=8191&C,S=C>>>13,T=0|s[6],N=8191&T,M=T>>>13,O=0|s[7],I=8191&O,j=O>>>13,F=0|s[8],_=8191&F,P=F>>>13,B=0|s[9],W=8191&B,D=B>>>13,L=0|a[0],U=8191&L,V=L>>>13,Z=0|a[1],H=8191&Z,z=Z>>>13,Y=0|a[2],G=8191&Y,X=Y>>>13,J=0|a[3],q=8191&J,Q=J>>>13,K=0|a[4],$=8191&K,ee=K>>>13,te=0|a[5],re=8191&te,ne=te>>>13,oe=0|a[6],ie=8191&oe,se=oe>>>13,ae=0|a[7],le=8191&ae,ce=ae>>>13,ue=0|a[8],de=8191&ue,pe=ue>>>13,fe=0|a[9],he=8191&fe,me=fe>>>13;r.negative=e.negative^t.negative,r.length=19;var ge=(c+(n=Math.imul(d,U))|0)+((8191&(o=(o=Math.imul(d,V))+Math.imul(p,U)|0))<<13)|0;c=((i=Math.imul(p,V))+(o>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(h,U),o=(o=Math.imul(h,V))+Math.imul(m,U)|0,i=Math.imul(m,V);var ye=(c+(n=n+Math.imul(d,H)|0)|0)+((8191&(o=(o=o+Math.imul(d,z)|0)+Math.imul(p,H)|0))<<13)|0;c=((i=i+Math.imul(p,z)|0)+(o>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(y,U),o=(o=Math.imul(y,V))+Math.imul(b,U)|0,i=Math.imul(b,V),n=n+Math.imul(h,H)|0,o=(o=o+Math.imul(h,z)|0)+Math.imul(m,H)|0,i=i+Math.imul(m,z)|0;var be=(c+(n=n+Math.imul(d,G)|0)|0)+((8191&(o=(o=o+Math.imul(d,X)|0)+Math.imul(p,G)|0))<<13)|0;c=((i=i+Math.imul(p,X)|0)+(o>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(x,U),o=(o=Math.imul(x,V))+Math.imul(w,U)|0,i=Math.imul(w,V),n=n+Math.imul(y,H)|0,o=(o=o+Math.imul(y,z)|0)+Math.imul(b,H)|0,i=i+Math.imul(b,z)|0,n=n+Math.imul(h,G)|0,o=(o=o+Math.imul(h,X)|0)+Math.imul(m,G)|0,i=i+Math.imul(m,X)|0;var ve=(c+(n=n+Math.imul(d,q)|0)|0)+((8191&(o=(o=o+Math.imul(d,Q)|0)+Math.imul(p,q)|0))<<13)|0;c=((i=i+Math.imul(p,Q)|0)+(o>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(A,U),o=(o=Math.imul(A,V))+Math.imul(k,U)|0,i=Math.imul(k,V),n=n+Math.imul(x,H)|0,o=(o=o+Math.imul(x,z)|0)+Math.imul(w,H)|0,i=i+Math.imul(w,z)|0,n=n+Math.imul(y,G)|0,o=(o=o+Math.imul(y,X)|0)+Math.imul(b,G)|0,i=i+Math.imul(b,X)|0,n=n+Math.imul(h,q)|0,o=(o=o+Math.imul(h,Q)|0)+Math.imul(m,q)|0,i=i+Math.imul(m,Q)|0;var xe=(c+(n=n+Math.imul(d,$)|0)|0)+((8191&(o=(o=o+Math.imul(d,ee)|0)+Math.imul(p,$)|0))<<13)|0;c=((i=i+Math.imul(p,ee)|0)+(o>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(R,U),o=(o=Math.imul(R,V))+Math.imul(S,U)|0,i=Math.imul(S,V),n=n+Math.imul(A,H)|0,o=(o=o+Math.imul(A,z)|0)+Math.imul(k,H)|0,i=i+Math.imul(k,z)|0,n=n+Math.imul(x,G)|0,o=(o=o+Math.imul(x,X)|0)+Math.imul(w,G)|0,i=i+Math.imul(w,X)|0,n=n+Math.imul(y,q)|0,o=(o=o+Math.imul(y,Q)|0)+Math.imul(b,q)|0,i=i+Math.imul(b,Q)|0,n=n+Math.imul(h,$)|0,o=(o=o+Math.imul(h,ee)|0)+Math.imul(m,$)|0,i=i+Math.imul(m,ee)|0;var we=(c+(n=n+Math.imul(d,re)|0)|0)+((8191&(o=(o=o+Math.imul(d,ne)|0)+Math.imul(p,re)|0))<<13)|0;c=((i=i+Math.imul(p,ne)|0)+(o>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(N,U),o=(o=Math.imul(N,V))+Math.imul(M,U)|0,i=Math.imul(M,V),n=n+Math.imul(R,H)|0,o=(o=o+Math.imul(R,z)|0)+Math.imul(S,H)|0,i=i+Math.imul(S,z)|0,n=n+Math.imul(A,G)|0,o=(o=o+Math.imul(A,X)|0)+Math.imul(k,G)|0,i=i+Math.imul(k,X)|0,n=n+Math.imul(x,q)|0,o=(o=o+Math.imul(x,Q)|0)+Math.imul(w,q)|0,i=i+Math.imul(w,Q)|0,n=n+Math.imul(y,$)|0,o=(o=o+Math.imul(y,ee)|0)+Math.imul(b,$)|0,i=i+Math.imul(b,ee)|0,n=n+Math.imul(h,re)|0,o=(o=o+Math.imul(h,ne)|0)+Math.imul(m,re)|0,i=i+Math.imul(m,ne)|0;var Ee=(c+(n=n+Math.imul(d,ie)|0)|0)+((8191&(o=(o=o+Math.imul(d,se)|0)+Math.imul(p,ie)|0))<<13)|0;c=((i=i+Math.imul(p,se)|0)+(o>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(I,U),o=(o=Math.imul(I,V))+Math.imul(j,U)|0,i=Math.imul(j,V),n=n+Math.imul(N,H)|0,o=(o=o+Math.imul(N,z)|0)+Math.imul(M,H)|0,i=i+Math.imul(M,z)|0,n=n+Math.imul(R,G)|0,o=(o=o+Math.imul(R,X)|0)+Math.imul(S,G)|0,i=i+Math.imul(S,X)|0,n=n+Math.imul(A,q)|0,o=(o=o+Math.imul(A,Q)|0)+Math.imul(k,q)|0,i=i+Math.imul(k,Q)|0,n=n+Math.imul(x,$)|0,o=(o=o+Math.imul(x,ee)|0)+Math.imul(w,$)|0,i=i+Math.imul(w,ee)|0,n=n+Math.imul(y,re)|0,o=(o=o+Math.imul(y,ne)|0)+Math.imul(b,re)|0,i=i+Math.imul(b,ne)|0,n=n+Math.imul(h,ie)|0,o=(o=o+Math.imul(h,se)|0)+Math.imul(m,ie)|0,i=i+Math.imul(m,se)|0;var Ae=(c+(n=n+Math.imul(d,le)|0)|0)+((8191&(o=(o=o+Math.imul(d,ce)|0)+Math.imul(p,le)|0))<<13)|0;c=((i=i+Math.imul(p,ce)|0)+(o>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(_,U),o=(o=Math.imul(_,V))+Math.imul(P,U)|0,i=Math.imul(P,V),n=n+Math.imul(I,H)|0,o=(o=o+Math.imul(I,z)|0)+Math.imul(j,H)|0,i=i+Math.imul(j,z)|0,n=n+Math.imul(N,G)|0,o=(o=o+Math.imul(N,X)|0)+Math.imul(M,G)|0,i=i+Math.imul(M,X)|0,n=n+Math.imul(R,q)|0,o=(o=o+Math.imul(R,Q)|0)+Math.imul(S,q)|0,i=i+Math.imul(S,Q)|0,n=n+Math.imul(A,$)|0,o=(o=o+Math.imul(A,ee)|0)+Math.imul(k,$)|0,i=i+Math.imul(k,ee)|0,n=n+Math.imul(x,re)|0,o=(o=o+Math.imul(x,ne)|0)+Math.imul(w,re)|0,i=i+Math.imul(w,ne)|0,n=n+Math.imul(y,ie)|0,o=(o=o+Math.imul(y,se)|0)+Math.imul(b,ie)|0,i=i+Math.imul(b,se)|0,n=n+Math.imul(h,le)|0,o=(o=o+Math.imul(h,ce)|0)+Math.imul(m,le)|0,i=i+Math.imul(m,ce)|0;var ke=(c+(n=n+Math.imul(d,de)|0)|0)+((8191&(o=(o=o+Math.imul(d,pe)|0)+Math.imul(p,de)|0))<<13)|0;c=((i=i+Math.imul(p,pe)|0)+(o>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(W,U),o=(o=Math.imul(W,V))+Math.imul(D,U)|0,i=Math.imul(D,V),n=n+Math.imul(_,H)|0,o=(o=o+Math.imul(_,z)|0)+Math.imul(P,H)|0,i=i+Math.imul(P,z)|0,n=n+Math.imul(I,G)|0,o=(o=o+Math.imul(I,X)|0)+Math.imul(j,G)|0,i=i+Math.imul(j,X)|0,n=n+Math.imul(N,q)|0,o=(o=o+Math.imul(N,Q)|0)+Math.imul(M,q)|0,i=i+Math.imul(M,Q)|0,n=n+Math.imul(R,$)|0,o=(o=o+Math.imul(R,ee)|0)+Math.imul(S,$)|0,i=i+Math.imul(S,ee)|0,n=n+Math.imul(A,re)|0,o=(o=o+Math.imul(A,ne)|0)+Math.imul(k,re)|0,i=i+Math.imul(k,ne)|0,n=n+Math.imul(x,ie)|0,o=(o=o+Math.imul(x,se)|0)+Math.imul(w,ie)|0,i=i+Math.imul(w,se)|0,n=n+Math.imul(y,le)|0,o=(o=o+Math.imul(y,ce)|0)+Math.imul(b,le)|0,i=i+Math.imul(b,ce)|0,n=n+Math.imul(h,de)|0,o=(o=o+Math.imul(h,pe)|0)+Math.imul(m,de)|0,i=i+Math.imul(m,pe)|0;var Ce=(c+(n=n+Math.imul(d,he)|0)|0)+((8191&(o=(o=o+Math.imul(d,me)|0)+Math.imul(p,he)|0))<<13)|0;c=((i=i+Math.imul(p,me)|0)+(o>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(W,H),o=(o=Math.imul(W,z))+Math.imul(D,H)|0,i=Math.imul(D,z),n=n+Math.imul(_,G)|0,o=(o=o+Math.imul(_,X)|0)+Math.imul(P,G)|0,i=i+Math.imul(P,X)|0,n=n+Math.imul(I,q)|0,o=(o=o+Math.imul(I,Q)|0)+Math.imul(j,q)|0,i=i+Math.imul(j,Q)|0,n=n+Math.imul(N,$)|0,o=(o=o+Math.imul(N,ee)|0)+Math.imul(M,$)|0,i=i+Math.imul(M,ee)|0,n=n+Math.imul(R,re)|0,o=(o=o+Math.imul(R,ne)|0)+Math.imul(S,re)|0,i=i+Math.imul(S,ne)|0,n=n+Math.imul(A,ie)|0,o=(o=o+Math.imul(A,se)|0)+Math.imul(k,ie)|0,i=i+Math.imul(k,se)|0,n=n+Math.imul(x,le)|0,o=(o=o+Math.imul(x,ce)|0)+Math.imul(w,le)|0,i=i+Math.imul(w,ce)|0,n=n+Math.imul(y,de)|0,o=(o=o+Math.imul(y,pe)|0)+Math.imul(b,de)|0,i=i+Math.imul(b,pe)|0;var Re=(c+(n=n+Math.imul(h,he)|0)|0)+((8191&(o=(o=o+Math.imul(h,me)|0)+Math.imul(m,he)|0))<<13)|0;c=((i=i+Math.imul(m,me)|0)+(o>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(W,G),o=(o=Math.imul(W,X))+Math.imul(D,G)|0,i=Math.imul(D,X),n=n+Math.imul(_,q)|0,o=(o=o+Math.imul(_,Q)|0)+Math.imul(P,q)|0,i=i+Math.imul(P,Q)|0,n=n+Math.imul(I,$)|0,o=(o=o+Math.imul(I,ee)|0)+Math.imul(j,$)|0,i=i+Math.imul(j,ee)|0,n=n+Math.imul(N,re)|0,o=(o=o+Math.imul(N,ne)|0)+Math.imul(M,re)|0,i=i+Math.imul(M,ne)|0,n=n+Math.imul(R,ie)|0,o=(o=o+Math.imul(R,se)|0)+Math.imul(S,ie)|0,i=i+Math.imul(S,se)|0,n=n+Math.imul(A,le)|0,o=(o=o+Math.imul(A,ce)|0)+Math.imul(k,le)|0,i=i+Math.imul(k,ce)|0,n=n+Math.imul(x,de)|0,o=(o=o+Math.imul(x,pe)|0)+Math.imul(w,de)|0,i=i+Math.imul(w,pe)|0;var Se=(c+(n=n+Math.imul(y,he)|0)|0)+((8191&(o=(o=o+Math.imul(y,me)|0)+Math.imul(b,he)|0))<<13)|0;c=((i=i+Math.imul(b,me)|0)+(o>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(W,q),o=(o=Math.imul(W,Q))+Math.imul(D,q)|0,i=Math.imul(D,Q),n=n+Math.imul(_,$)|0,o=(o=o+Math.imul(_,ee)|0)+Math.imul(P,$)|0,i=i+Math.imul(P,ee)|0,n=n+Math.imul(I,re)|0,o=(o=o+Math.imul(I,ne)|0)+Math.imul(j,re)|0,i=i+Math.imul(j,ne)|0,n=n+Math.imul(N,ie)|0,o=(o=o+Math.imul(N,se)|0)+Math.imul(M,ie)|0,i=i+Math.imul(M,se)|0,n=n+Math.imul(R,le)|0,o=(o=o+Math.imul(R,ce)|0)+Math.imul(S,le)|0,i=i+Math.imul(S,ce)|0,n=n+Math.imul(A,de)|0,o=(o=o+Math.imul(A,pe)|0)+Math.imul(k,de)|0,i=i+Math.imul(k,pe)|0;var Te=(c+(n=n+Math.imul(x,he)|0)|0)+((8191&(o=(o=o+Math.imul(x,me)|0)+Math.imul(w,he)|0))<<13)|0;c=((i=i+Math.imul(w,me)|0)+(o>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(W,$),o=(o=Math.imul(W,ee))+Math.imul(D,$)|0,i=Math.imul(D,ee),n=n+Math.imul(_,re)|0,o=(o=o+Math.imul(_,ne)|0)+Math.imul(P,re)|0,i=i+Math.imul(P,ne)|0,n=n+Math.imul(I,ie)|0,o=(o=o+Math.imul(I,se)|0)+Math.imul(j,ie)|0,i=i+Math.imul(j,se)|0,n=n+Math.imul(N,le)|0,o=(o=o+Math.imul(N,ce)|0)+Math.imul(M,le)|0,i=i+Math.imul(M,ce)|0,n=n+Math.imul(R,de)|0,o=(o=o+Math.imul(R,pe)|0)+Math.imul(S,de)|0,i=i+Math.imul(S,pe)|0;var Ne=(c+(n=n+Math.imul(A,he)|0)|0)+((8191&(o=(o=o+Math.imul(A,me)|0)+Math.imul(k,he)|0))<<13)|0;c=((i=i+Math.imul(k,me)|0)+(o>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,n=Math.imul(W,re),o=(o=Math.imul(W,ne))+Math.imul(D,re)|0,i=Math.imul(D,ne),n=n+Math.imul(_,ie)|0,o=(o=o+Math.imul(_,se)|0)+Math.imul(P,ie)|0,i=i+Math.imul(P,se)|0,n=n+Math.imul(I,le)|0,o=(o=o+Math.imul(I,ce)|0)+Math.imul(j,le)|0,i=i+Math.imul(j,ce)|0,n=n+Math.imul(N,de)|0,o=(o=o+Math.imul(N,pe)|0)+Math.imul(M,de)|0,i=i+Math.imul(M,pe)|0;var Me=(c+(n=n+Math.imul(R,he)|0)|0)+((8191&(o=(o=o+Math.imul(R,me)|0)+Math.imul(S,he)|0))<<13)|0;c=((i=i+Math.imul(S,me)|0)+(o>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(W,ie),o=(o=Math.imul(W,se))+Math.imul(D,ie)|0,i=Math.imul(D,se),n=n+Math.imul(_,le)|0,o=(o=o+Math.imul(_,ce)|0)+Math.imul(P,le)|0,i=i+Math.imul(P,ce)|0,n=n+Math.imul(I,de)|0,o=(o=o+Math.imul(I,pe)|0)+Math.imul(j,de)|0,i=i+Math.imul(j,pe)|0;var Oe=(c+(n=n+Math.imul(N,he)|0)|0)+((8191&(o=(o=o+Math.imul(N,me)|0)+Math.imul(M,he)|0))<<13)|0;c=((i=i+Math.imul(M,me)|0)+(o>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(W,le),o=(o=Math.imul(W,ce))+Math.imul(D,le)|0,i=Math.imul(D,ce),n=n+Math.imul(_,de)|0,o=(o=o+Math.imul(_,pe)|0)+Math.imul(P,de)|0,i=i+Math.imul(P,pe)|0;var Ie=(c+(n=n+Math.imul(I,he)|0)|0)+((8191&(o=(o=o+Math.imul(I,me)|0)+Math.imul(j,he)|0))<<13)|0;c=((i=i+Math.imul(j,me)|0)+(o>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(W,de),o=(o=Math.imul(W,pe))+Math.imul(D,de)|0,i=Math.imul(D,pe);var je=(c+(n=n+Math.imul(_,he)|0)|0)+((8191&(o=(o=o+Math.imul(_,me)|0)+Math.imul(P,he)|0))<<13)|0;c=((i=i+Math.imul(P,me)|0)+(o>>>13)|0)+(je>>>26)|0,je&=67108863;var Fe=(c+(n=Math.imul(W,he))|0)+((8191&(o=(o=Math.imul(W,me))+Math.imul(D,he)|0))<<13)|0;return c=((i=Math.imul(D,me))+(o>>>13)|0)+(Fe>>>26)|0,Fe&=67108863,l[0]=ge,l[1]=ye,l[2]=be,l[3]=ve,l[4]=xe,l[5]=we,l[6]=Ee,l[7]=Ae,l[8]=ke,l[9]=Ce,l[10]=Re,l[11]=Se,l[12]=Te,l[13]=Ne,l[14]=Me,l[15]=Oe,l[16]=Ie,l[17]=je,l[18]=Fe,0!==c&&(l[19]=c,r.length++),r};function g(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,o=0,i=0;i<r.length-1;i++){var s=o;o=0;for(var a=67108863&n,l=Math.min(i,t.length-1),c=Math.max(0,i-e.length+1);c<=l;c++){var u=i-c,d=(0|e.words[u])*(0|t.words[c]),p=67108863&d;a=67108863&(p=p+a|0),o+=(s=(s=s+(d/67108864|0)|0)+(p>>>26)|0)>>>26,s&=67108863}r.words[i]=a,n=s,s=o}return 0!==n?r.words[i]=n:r.length--,r._strip()}function y(e,t,r){return g(e,t,r)}Math.imul||(m=h),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?m(this,e,t):r<63?h(this,e,t):r<1024?g(this,e,t):y(this,e,t)},o.prototype.mul=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},o.prototype.mulf=function(e){var t=new o(null);return t.words=new Array(this.length+e.length),y(this,e,t)},o.prototype.imul=function(e){return this.clone().mulTo(e,this)},o.prototype.imuln=function(e){var t=e<0;t&&(e=-e),r("number"==typeof e),r(e<67108864);for(var n=0,o=0;o<this.length;o++){var i=(0|this.words[o])*e,s=(67108863&i)+(67108863&n);n>>=26,n+=i/67108864|0,n+=s>>>26,this.words[o]=67108863&s}return 0!==n&&(this.words[o]=n,this.length++),t?this.ineg():this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r<t.length;r++){var n=r/26|0,o=r%26;t[r]=e.words[n]>>>o&1}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n<t.length&&0===t[n];n++,r=r.sqr());if(++n<t.length)for(var i=r.sqr();n<t.length;n++,i=i.sqr())0!==t[n]&&(r=r.mul(i));return r},o.prototype.iushln=function(e){r("number"==typeof e&&e>=0);var t,n=e%26,o=(e-n)/26,i=67108863>>>26-n<<26-n;if(0!==n){var s=0;for(t=0;t<this.length;t++){var a=this.words[t]&i,l=(0|this.words[t])-a<<n;this.words[t]=l|s,s=a>>>26-n}s&&(this.words[t]=s,this.length++)}if(0!==o){for(t=this.length-1;t>=0;t--)this.words[t+o]=this.words[t];for(t=0;t<o;t++)this.words[t]=0;this.length+=o}return this._strip()},o.prototype.ishln=function(e){return r(0===this.negative),this.iushln(e)},o.prototype.iushrn=function(e,t,n){var o;r("number"==typeof e&&e>=0),o=t?(t-t%26)/26:0;var i=e%26,s=Math.min((e-i)/26,this.length),a=67108863^67108863>>>i<<i,l=n;if(o-=s,o=Math.max(0,o),l){for(var c=0;c<s;c++)l.words[c]=this.words[c];l.length=s}if(0===s);else if(this.length>s)for(this.length-=s,c=0;c<this.length;c++)this.words[c]=this.words[c+s];else this.words[0]=0,this.length=1;var u=0;for(c=this.length-1;c>=0&&(0!==u||c>=o);c--){var d=0|this.words[c];this.words[c]=u<<26-i|d>>>i,u=d&a}return l&&0!==u&&(l.words[l.length++]=u),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(e,t,n){return r(0===this.negative),this.iushrn(e,t,n)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){r("number"==typeof e&&e>=0);var t=e%26,n=(e-t)/26,o=1<<t;return!(this.length<=n||!(this.words[n]&o))},o.prototype.imaskn=function(e){r("number"==typeof e&&e>=0);var t=e%26,n=(e-t)/26;if(r(0===this.negative,"imaskn works only with positive numbers"),this.length<=n)return this;if(0!==t&&n++,this.length=Math.min(n,this.length),0!==t){var o=67108863^67108863>>>t<<t;this.words[this.length-1]&=o}return this._strip()},o.prototype.maskn=function(e){return this.clone().imaskn(e)},o.prototype.iaddn=function(e){return r("number"==typeof e),r(e<67108864),e<0?this.isubn(-e):0!==this.negative?1===this.length&&(0|this.words[0])<=e?(this.words[0]=e-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(e),this.negative=1,this):this._iaddn(e)},o.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&this.words[t]>=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},o.prototype.isubn=function(e){if(r("number"==typeof e),r(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this._strip()},o.prototype.addn=function(e){return this.clone().iaddn(e)},o.prototype.subn=function(e){return this.clone().isubn(e)},o.prototype.iabs=function(){return this.negative=0,this},o.prototype.abs=function(){return this.clone().iabs()},o.prototype._ishlnsubmul=function(e,t,n){var o,i,s=e.length+n;this._expand(s);var a=0;for(o=0;o<e.length;o++){i=(0|this.words[o+n])+a;var l=(0|e.words[o])*t;a=((i-=67108863&l)>>26)-(l/67108864|0),this.words[o+n]=67108863&i}for(;o<this.length-n;o++)a=(i=(0|this.words[o+n])+a)>>26,this.words[o+n]=67108863&i;if(0===a)return this._strip();for(r(-1===a),a=0,o=0;o<this.length;o++)a=(i=-(0|this.words[o])+a)>>26,this.words[o]=67108863&i;return this.negative=1,this._strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,s=0|i.words[i.length-1];0!=(r=26-this._countBits(s))&&(i=i.ushln(r),n.iushln(r),s=0|i.words[i.length-1]);var a,l=n.length-i.length;if("mod"!==t){(a=new o(null)).length=l+1,a.words=new Array(a.length);for(var c=0;c<a.length;c++)a.words[c]=0}var u=n.clone()._ishlnsubmul(i,1,l);0===u.negative&&(n=u,a&&(a.words[l]=1));for(var d=l-1;d>=0;d--){var p=67108864*(0|n.words[i.length+d])+(0|n.words[i.length+d-1]);for(p=Math.min(p/s|0,67108863),n._ishlnsubmul(i,p,d);0!==n.negative;)p--,n.negative=0,n._ishlnsubmul(i,1,d),n.isZero()||(n.negative^=1);a&&(a.words[d]=p)}return a&&a._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:a||null,mod:n}},o.prototype.divmod=function(e,t,n){return r(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(i=a.div.neg()),"div"!==t&&(s=a.mod.neg(),n&&0!==s.negative&&s.iadd(e)),{div:i,mod:s}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(i=a.div.neg()),{div:i,mod:a.mod}):0!=(this.negative&e.negative)?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(s=a.mod.neg(),n&&0!==s.negative&&s.isub(e)),{div:a.div,mod:s}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modrn(e.words[0]))}:this._wordDiv(e,t);var i,s,a},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),o=e.andln(1),i=r.cmp(n);return i<0||1===o&&0===i?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},o.prototype.modrn=function(e){var t=e<0;t&&(e=-e),r(e<=67108863);for(var n=(1<<26)%e,o=0,i=this.length-1;i>=0;i--)o=(n*o+(0|this.words[i]))%e;return t?-o:o},o.prototype.modn=function(e){return this.modrn(e)},o.prototype.idivn=function(e){var t=e<0;t&&(e=-e),r(e<=67108863);for(var n=0,o=this.length-1;o>=0;o--){var i=(0|this.words[o])+67108864*n;this.words[o]=i/e|0,n=i%e}return this._strip(),t?this.ineg():this},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){r(0===e.negative),r(!e.isZero());var t=this,n=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),s=new o(0),a=new o(0),l=new o(1),c=0;t.isEven()&&n.isEven();)t.iushrn(1),n.iushrn(1),++c;for(var u=n.clone(),d=t.clone();!t.isZero();){for(var p=0,f=1;0==(t.words[0]&f)&&p<26;++p,f<<=1);if(p>0)for(t.iushrn(p);p-- >0;)(i.isOdd()||s.isOdd())&&(i.iadd(u),s.isub(d)),i.iushrn(1),s.iushrn(1);for(var h=0,m=1;0==(n.words[0]&m)&&h<26;++h,m<<=1);if(h>0)for(n.iushrn(h);h-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(u),l.isub(d)),a.iushrn(1),l.iushrn(1);t.cmp(n)>=0?(t.isub(n),i.isub(a),s.isub(l)):(n.isub(t),a.isub(i),l.isub(s))}return{a:a,b:l,gcd:n.iushln(c)}},o.prototype._invmp=function(e){r(0===e.negative),r(!e.isZero());var t=this,n=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,s=new o(1),a=new o(0),l=n.clone();t.cmpn(1)>0&&n.cmpn(1)>0;){for(var c=0,u=1;0==(t.words[0]&u)&&c<26;++c,u<<=1);if(c>0)for(t.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var d=0,p=1;0==(n.words[0]&p)&&d<26;++d,p<<=1);if(d>0)for(n.iushrn(d);d-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(n)>=0?(t.isub(n),s.isub(a)):(n.isub(t),a.isub(s))}return(i=0===t.cmpn(1)?s:a).cmpn(0)<0&&i.iadd(e),i},o.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var o=t.cmp(r);if(o<0){var i=t;t=r,r=i}else if(0===o||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0==(1&this.words[0])},o.prototype.isOdd=function(){return 1==(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){r("number"==typeof e);var t=e%26,n=(e-t)/26,o=1<<t;if(this.length<=n)return this._expand(n+1),this.words[n]|=o,this;for(var i=o,s=n;0!==i&&s<this.length;s++){var a=0|this.words[s];i=(a+=i)>>>26,a&=67108863,this.words[s]=a}return 0!==i&&(this.words[s]=i,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(e){var t,n=e<0;if(0!==this.negative&&!n)return-1;if(0===this.negative&&n)return 1;if(this._strip(),this.length>1)t=1;else{n&&(e=-e),r(e<=67108863,"Number is too big");var o=0|this.words[0];t=o===e?0:o<e?-1:1}return 0!==this.negative?0|-t:t},o.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},o.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,r=this.length-1;r>=0;r--){var n=0|this.words[r],o=0|e.words[r];if(n!==o){n<o?t=-1:n>o&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new k(e)},o.prototype.toRed=function(e){return r(!this.red,"Already a number in reduction context"),r(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return r(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return r(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var b={k256:null,p224:null,p192:null,p25519:null};function v(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function x(){v.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){v.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function E(){v.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function A(){v.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function k(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else r(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function C(e){k.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}v.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},v.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t<this.n?-1:r.ucmp(this.p);return 0===n?(r.words[0]=0,r.length=1):n>0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},v.prototype.split=function(e,t){e.iushrn(this.n,0,t)},v.prototype.imulK=function(e){return e.imul(this.k)},n(x,v),x.prototype.split=function(e,t){for(var r=4194303,n=Math.min(e.length,9),o=0;o<n;o++)t.words[o]=e.words[o];if(t.length=n,e.length<=9)return e.words[0]=0,void(e.length=1);var i=e.words[9];for(t.words[t.length++]=i&r,o=10;o<e.length;o++){var s=0|e.words[o];e.words[o-10]=(s&r)<<4|i>>>22,i=s}i>>>=22,e.words[o-10]=i,0===i&&e.length>10?e.length-=10:e.length-=9},x.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r<e.length;r++){var n=0|e.words[r];t+=977*n,e.words[r]=67108863&t,t=64*n+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},n(w,v),n(E,v),n(A,v),A.prototype.imulK=function(e){for(var t=0,r=0;r<e.length;r++){var n=19*(0|e.words[r])+t,o=67108863&n;n>>>=26,e.words[r]=o,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(b[e])return b[e];var t;if("k256"===e)t=new x;else if("p224"===e)t=new w;else if("p192"===e)t=new E;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new A}return b[e]=t,t},k.prototype._verify1=function(e){r(0===e.negative,"red works only with positives"),r(e.red,"red works only with red numbers")},k.prototype._verify2=function(e,t){r(0==(e.negative|t.negative),"red works only with positives"),r(e.red&&e.red===t.red,"red works only with red numbers")},k.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(c(e,e.umod(this.m)._forceRed(this)),e)},k.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},k.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},k.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},k.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},k.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},k.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},k.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},k.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},k.prototype.isqr=function(e){return this.imul(e,e.clone())},k.prototype.sqr=function(e){return this.mul(e,e)},k.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(r(t%2==1),3===t){var n=this.m.add(new o(1)).iushrn(2);return this.pow(e,n)}for(var i=this.m.subn(1),s=0;!i.isZero()&&0===i.andln(1);)s++,i.iushrn(1);r(!i.isZero());var a=new o(1).toRed(this),l=a.redNeg(),c=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new o(2*u*u).toRed(this);0!==this.pow(u,c).cmp(l);)u.redIAdd(l);for(var d=this.pow(u,i),p=this.pow(e,i.addn(1).iushrn(1)),f=this.pow(e,i),h=s;0!==f.cmp(a);){for(var m=f,g=0;0!==m.cmp(a);g++)m=m.redSqr();r(g<h);var y=this.pow(d,new o(1).iushln(h-g-1));p=p.redMul(y),d=y.redSqr(),f=f.redMul(d),h=g}return p},k.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},k.prototype.pow=function(e,t){if(t.isZero())return new o(1).toRed(this);if(0===t.cmpn(1))return e.clone();var r=new Array(16);r[0]=new o(1).toRed(this),r[1]=e;for(var n=2;n<r.length;n++)r[n]=this.mul(r[n-1],e);var i=r[0],s=0,a=0,l=t.bitLength()%26;for(0===l&&(l=26),n=t.length-1;n>=0;n--){for(var c=t.words[n],u=l-1;u>=0;u--){var d=c>>u&1;i!==r[0]&&(i=this.sqr(i)),0!==d||0!==s?(s<<=1,s|=d,(4==++a||0===n&&0===u)&&(i=this.mul(i,r[s]),a=0,s=0)):a=0}l=26}return i},k.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},k.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new C(e)},n(C,k),C.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},C.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},C.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),o=r.isub(n).iushrn(this.shift),i=o;return o.cmp(this.m)>=0?i=o.isub(this.m):o.cmpn(0)<0&&(i=o.iadd(this.m)),i._forceRed(this)},C.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),s=i;return i.cmp(this.m)>=0?s=i.isub(this.m):i.cmpn(0)<0&&(s=i.iadd(this.m)),s._forceRed(this)},C.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(pd,j);var fd=pd.exports;function hd(e,t,r){return r={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&r.path)}},e(r,r.exports),r.exports}var md=gd;function gd(e,t){if(!e)throw new Error(t||"Assertion failed")}gd.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)};var yd=hd((function(e,t){var r=t;function n(e){return 1===e.length?"0"+e:e}function o(e){for(var t="",r=0;r<e.length;r++)t+=n(e[r].toString(16));return t}r.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"!=typeof e){for(var n=0;n<e.length;n++)r[n]=0|e[n];return r}if("hex"===t){(e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e);for(n=0;n<e.length;n+=2)r.push(parseInt(e[n]+e[n+1],16))}else for(n=0;n<e.length;n++){var o=e.charCodeAt(n),i=o>>8,s=255&o;i?r.push(i,s):r.push(s)}return r},r.zero2=n,r.toHex=o,r.encode=function(e,t){return"hex"===t?o(e):e}})),bd=hd((function(e,t){var r=t;r.assert=md,r.toArray=yd.toArray,r.zero2=yd.zero2,r.toHex=yd.toHex,r.encode=yd.encode,r.getNAF=function(e,t,r){var n=new Array(Math.max(e.bitLength(),r)+1);n.fill(0);for(var o=1<<t+1,i=e.clone(),s=0;s<n.length;s++){var a,l=i.andln(o-1);i.isOdd()?(a=l>(o>>1)-1?(o>>1)-l:l,i.isubn(a)):a=0,n[s]=a,i.iushrn(1)}return n},r.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n,o=0,i=0;e.cmpn(-o)>0||t.cmpn(-i)>0;){var s,a,l=e.andln(3)+o&3,c=t.andln(3)+i&3;3===l&&(l=-1),3===c&&(c=-1),s=0==(1&l)?0:3!==(n=e.andln(7)+o&7)&&5!==n||2!==c?l:-l,r[0].push(s),a=0==(1&c)?0:3!==(n=t.andln(7)+i&7)&&5!==n||2!==l?c:-c,r[1].push(a),2*o===s+1&&(o=1-o),2*i===a+1&&(i=1-i),e.iushrn(1),t.iushrn(1)}return r},r.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},r.parseBytes=function(e){return"string"==typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new fd(e,"hex","le")}})),vd=bd.getNAF,xd=bd.getJSF,wd=bd.assert;function Ed(e,t){this.type=e,this.p=new fd(t.p,16),this.red=t.prime?fd.red(t.prime):fd.mont(this.p),this.zero=new fd(0).toRed(this.red),this.one=new fd(1).toRed(this.red),this.two=new fd(2).toRed(this.red),this.n=t.n&&new fd(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}var Ad=Ed;function kd(e,t){this.curve=e,this.type=t,this.precomputed=null}Ed.prototype.point=function(){throw new Error("Not implemented")},Ed.prototype.validate=function(){throw new Error("Not implemented")},Ed.prototype._fixedNafMul=function(e,t){wd(e.precomputed);var r=e._getDoubles(),n=vd(t,1,this._bitLength),o=(1<<r.step+1)-(r.step%2==0?2:1);o/=3;var i,s,a=[];for(i=0;i<n.length;i+=r.step){s=0;for(var l=i+r.step-1;l>=i;l--)s=(s<<1)+n[l];a.push(s)}for(var c=this.jpoint(null,null,null),u=this.jpoint(null,null,null),d=o;d>0;d--){for(i=0;i<a.length;i++)(s=a[i])===d?u=u.mixedAdd(r.points[i]):s===-d&&(u=u.mixedAdd(r.points[i].neg()));c=c.add(u)}return c.toP()},Ed.prototype._wnafMul=function(e,t){var r=4,n=e._getNAFPoints(r);r=n.wnd;for(var o=n.points,i=vd(t,r,this._bitLength),s=this.jpoint(null,null,null),a=i.length-1;a>=0;a--){for(var l=0;a>=0&&0===i[a];a--)l++;if(a>=0&&l++,s=s.dblp(l),a<0)break;var c=i[a];wd(0!==c),s="affine"===e.type?c>0?s.mixedAdd(o[c-1>>1]):s.mixedAdd(o[-c-1>>1].neg()):c>0?s.add(o[c-1>>1]):s.add(o[-c-1>>1].neg())}return"affine"===e.type?s.toP():s},Ed.prototype._wnafMulAdd=function(e,t,r,n,o){var i,s,a,l=this._wnafT1,c=this._wnafT2,u=this._wnafT3,d=0;for(i=0;i<n;i++){var p=(a=t[i])._getNAFPoints(e);l[i]=p.wnd,c[i]=p.points}for(i=n-1;i>=1;i-=2){var f=i-1,h=i;if(1===l[f]&&1===l[h]){var m=[t[f],null,null,t[h]];0===t[f].y.cmp(t[h].y)?(m[1]=t[f].add(t[h]),m[2]=t[f].toJ().mixedAdd(t[h].neg())):0===t[f].y.cmp(t[h].y.redNeg())?(m[1]=t[f].toJ().mixedAdd(t[h]),m[2]=t[f].add(t[h].neg())):(m[1]=t[f].toJ().mixedAdd(t[h]),m[2]=t[f].toJ().mixedAdd(t[h].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],y=xd(r[f],r[h]);for(d=Math.max(y[0].length,d),u[f]=new Array(d),u[h]=new Array(d),s=0;s<d;s++){var b=0|y[0][s],v=0|y[1][s];u[f][s]=g[3*(b+1)+(v+1)],u[h][s]=0,c[f]=m}}else u[f]=vd(r[f],l[f],this._bitLength),u[h]=vd(r[h],l[h],this._bitLength),d=Math.max(u[f].length,d),d=Math.max(u[h].length,d)}var x=this.jpoint(null,null,null),w=this._wnafT4;for(i=d;i>=0;i--){for(var E=0;i>=0;){var A=!0;for(s=0;s<n;s++)w[s]=0|u[s][i],0!==w[s]&&(A=!1);if(!A)break;E++,i--}if(i>=0&&E++,x=x.dblp(E),i<0)break;for(s=0;s<n;s++){var k=w[s];0!==k&&(k>0?a=c[s][k-1>>1]:k<0&&(a=c[s][-k-1>>1].neg()),x="affine"===a.type?x.mixedAdd(a):x.add(a))}}for(i=0;i<n;i++)c[i]=null;return o?x:x.toP()},Ed.BasePoint=kd,kd.prototype.eq=function(){throw new Error("Not implemented")},kd.prototype.validate=function(){return this.curve.validate(this)},Ed.prototype.decodePoint=function(e,t){e=bd.toArray(e,t);var r=this.p.byteLength();if((4===e[0]||6===e[0]||7===e[0])&&e.length-1==2*r)return 6===e[0]?wd(e[e.length-1]%2==0):7===e[0]&&wd(e[e.length-1]%2==1),this.point(e.slice(1,1+r),e.slice(1+r,1+2*r));if((2===e[0]||3===e[0])&&e.length-1===r)return this.pointFromX(e.slice(1,1+r),3===e[0]);throw new Error("Unknown point format")},kd.prototype.encodeCompressed=function(e){return this.encode(e,!0)},kd.prototype._encode=function(e){var t=this.curve.p.byteLength(),r=this.getX().toArray("be",t);return e?[this.getY().isEven()?2:3].concat(r):[4].concat(r,this.getY().toArray("be",t))},kd.prototype.encode=function(e,t){return bd.encode(this._encode(t),e)},kd.prototype.precompute=function(e){if(this.precomputed)return this;var t={doubles:null,naf:null,beta:null};return t.naf=this._getNAFPoints(8),t.doubles=this._getDoubles(4,e),t.beta=this._getBeta(),this.precomputed=t,this},kd.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var t=this.precomputed.doubles;return!!t&&t.points.length>=Math.ceil((e.bitLength()+1)/t.step)},kd.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,o=0;o<t;o+=e){for(var i=0;i<e;i++)n=n.dbl();r.push(n)}return{step:e,points:r}},kd.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var t=[this],r=(1<<e)-1,n=1===r?null:this.dbl(),o=1;o<r;o++)t[o]=t[o-1].add(n);return{wnd:e,points:t}},kd.prototype._getBeta=function(){return null},kd.prototype.dblp=function(e){for(var t=this,r=0;r<e;r++)t=t.dbl();return t};var Cd=hd((function(e){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}})),Rd=bd.assert;function Sd(e){Ad.call(this,"short",e),this.a=new fd(e.a,16).toRed(this.red),this.b=new fd(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}Cd(Sd,Ad);var Td=Sd;function Nd(e,t,r,n){Ad.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new fd(t,16),this.y=new fd(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function Md(e,t,r,n){Ad.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new fd(0)):(this.x=new fd(t,16),this.y=new fd(r,16),this.z=new fd(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}Sd.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new fd(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new fd(e.lambda,16);else{var o=this._getEndoRoots(this.n);0===this.g.mul(o[0]).x.cmp(this.g.x.redMul(t))?r=o[0]:(r=o[1],Rd(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map((function(e){return{a:new fd(e.a,16),b:new fd(e.b,16)}})):this._getEndoBasis(r)}}},Sd.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:fd.mont(e),r=new fd(2).toRed(t).redInvm(),n=r.redNeg(),o=new fd(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(o).fromRed(),n.redSub(o).fromRed()]},Sd.prototype._getEndoBasis=function(e){for(var t,r,n,o,i,s,a,l,c,u=this.n.ushrn(Math.floor(this.n.bitLength()/2)),d=e,p=this.n.clone(),f=new fd(1),h=new fd(0),m=new fd(0),g=new fd(1),y=0;0!==d.cmpn(0);){var b=p.div(d);l=p.sub(b.mul(d)),c=m.sub(b.mul(f));var v=g.sub(b.mul(h));if(!n&&l.cmp(u)<0)t=a.neg(),r=f,n=l.neg(),o=c;else if(n&&2==++y)break;a=l,p=d,d=l,m=f,f=c,g=h,h=v}i=l.neg(),s=c;var x=n.sqr().add(o.sqr());return i.sqr().add(s.sqr()).cmp(x)>=0&&(i=t,s=r),n.negative&&(n=n.neg(),o=o.neg()),i.negative&&(i=i.neg(),s=s.neg()),[{a:n,b:o},{a:i,b:s}]},Sd.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],o=n.b.mul(e).divRound(this.n),i=r.b.neg().mul(e).divRound(this.n),s=o.mul(r.a),a=i.mul(n.a),l=o.mul(r.b),c=i.mul(n.b);return{k1:e.sub(s).sub(a),k2:l.add(c).neg()}},Sd.prototype.pointFromX=function(e,t){(e=new fd(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=n.fromRed().isOdd();return(t&&!o||!t&&o)&&(n=n.redNeg()),this.point(e,n)},Sd.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),o=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(o).cmpn(0)},Sd.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,o=this._endoWnafT2,i=0;i<e.length;i++){var s=this._endoSplit(t[i]),a=e[i],l=a._getBeta();s.k1.negative&&(s.k1.ineg(),a=a.neg(!0)),s.k2.negative&&(s.k2.ineg(),l=l.neg(!0)),n[2*i]=a,n[2*i+1]=l,o[2*i]=s.k1,o[2*i+1]=s.k2}for(var c=this._wnafMulAdd(1,n,o,2*i,r),u=0;u<2*i;u++)n[u]=null,o[u]=null;return c},Cd(Nd,Ad.BasePoint),Sd.prototype.point=function(e,t,r){return new Nd(this,e,t,r)},Sd.prototype.pointFromJSON=function(e,t){return Nd.fromJSON(this,e,t)},Nd.prototype._getBeta=function(){if(this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var t=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var r=this.curve,n=function(e){return r.point(e.x.redMul(r.endo.beta),e.y)};e.beta=t,t.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(n)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(n)}}}return t}},Nd.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},Nd.fromJSON=function(e,t,r){"string"==typeof t&&(t=JSON.parse(t));var n=e.point(t[0],t[1],r);if(!t[2])return n;function o(t){return e.point(t[0],t[1],r)}var i=t[2];return n.precomputed={beta:null,doubles:i.doubles&&{step:i.doubles.step,points:[n].concat(i.doubles.points.map(o))},naf:i.naf&&{wnd:i.naf.wnd,points:[n].concat(i.naf.points.map(o))}},n},Nd.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},Nd.prototype.isInfinity=function(){return this.inf},Nd.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},Nd.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),o=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),i=o.redSqr().redISub(this.x.redAdd(this.x)),s=o.redMul(this.x.redSub(i)).redISub(this.y);return this.curve.point(i,s)},Nd.prototype.getX=function(){return this.x.fromRed()},Nd.prototype.getY=function(){return this.y.fromRed()},Nd.prototype.mul=function(e){return e=new fd(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},Nd.prototype.mulAdd=function(e,t,r){var n=[this,t],o=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,o):this.curve._wnafMulAdd(1,n,o,2)},Nd.prototype.jmulAdd=function(e,t,r){var n=[this,t],o=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,o,!0):this.curve._wnafMulAdd(1,n,o,2,!0)},Nd.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},Nd.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},Nd.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},Cd(Md,Ad.BasePoint),Sd.prototype.jpoint=function(e,t,r){return new Md(this,e,t,r)},Md.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},Md.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},Md.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),o=e.x.redMul(r),i=this.y.redMul(t.redMul(e.z)),s=e.y.redMul(r.redMul(this.z)),a=n.redSub(o),l=i.redSub(s);if(0===a.cmpn(0))return 0!==l.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=a.redSqr(),u=c.redMul(a),d=n.redMul(c),p=l.redSqr().redIAdd(u).redISub(d).redISub(d),f=l.redMul(d.redISub(p)).redISub(i.redMul(u)),h=this.z.redMul(e.z).redMul(a);return this.curve.jpoint(p,f,h)},Md.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),o=this.y,i=e.y.redMul(t).redMul(this.z),s=r.redSub(n),a=o.redSub(i);if(0===s.cmpn(0))return 0!==a.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var l=s.redSqr(),c=l.redMul(s),u=r.redMul(l),d=a.redSqr().redIAdd(c).redISub(u).redISub(u),p=a.redMul(u.redISub(d)).redISub(o.redMul(c)),f=this.z.redMul(s);return this.curve.jpoint(d,p,f)},Md.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var r=this;for(t=0;t<e;t++)r=r.dbl();return r}var n=this.curve.a,o=this.curve.tinv,i=this.x,s=this.y,a=this.z,l=a.redSqr().redSqr(),c=s.redAdd(s);for(t=0;t<e;t++){var u=i.redSqr(),d=c.redSqr(),p=d.redSqr(),f=u.redAdd(u).redIAdd(u).redIAdd(n.redMul(l)),h=i.redMul(d),m=f.redSqr().redISub(h.redAdd(h)),g=h.redISub(m),y=f.redMul(g);y=y.redIAdd(y).redISub(p);var b=c.redMul(a);t+1<e&&(l=l.redMul(p)),i=m,a=b,c=y}return this.curve.jpoint(i,c.redMul(o),a)},Md.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},Md.prototype._zeroDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),o=this.y.redSqr(),i=o.redSqr(),s=this.x.redAdd(o).redSqr().redISub(n).redISub(i);s=s.redIAdd(s);var a=n.redAdd(n).redIAdd(n),l=a.redSqr().redISub(s).redISub(s),c=i.redIAdd(i);c=(c=c.redIAdd(c)).redIAdd(c),e=l,t=a.redMul(s.redISub(l)).redISub(c),r=this.y.redAdd(this.y)}else{var u=this.x.redSqr(),d=this.y.redSqr(),p=d.redSqr(),f=this.x.redAdd(d).redSqr().redISub(u).redISub(p);f=f.redIAdd(f);var h=u.redAdd(u).redIAdd(u),m=h.redSqr(),g=p.redIAdd(p);g=(g=g.redIAdd(g)).redIAdd(g),e=m.redISub(f).redISub(f),t=h.redMul(f.redISub(e)).redISub(g),r=(r=this.y.redMul(this.z)).redIAdd(r)}return this.curve.jpoint(e,t,r)},Md.prototype._threeDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),o=this.y.redSqr(),i=o.redSqr(),s=this.x.redAdd(o).redSqr().redISub(n).redISub(i);s=s.redIAdd(s);var a=n.redAdd(n).redIAdd(n).redIAdd(this.curve.a),l=a.redSqr().redISub(s).redISub(s);e=l;var c=i.redIAdd(i);c=(c=c.redIAdd(c)).redIAdd(c),t=a.redMul(s.redISub(l)).redISub(c),r=this.y.redAdd(this.y)}else{var u=this.z.redSqr(),d=this.y.redSqr(),p=this.x.redMul(d),f=this.x.redSub(u).redMul(this.x.redAdd(u));f=f.redAdd(f).redIAdd(f);var h=p.redIAdd(p),m=(h=h.redIAdd(h)).redAdd(h);e=f.redSqr().redISub(m),r=this.y.redAdd(this.z).redSqr().redISub(d).redISub(u);var g=d.redSqr();g=(g=(g=g.redIAdd(g)).redIAdd(g)).redIAdd(g),t=f.redMul(h.redISub(e)).redISub(g)}return this.curve.jpoint(e,t,r)},Md.prototype._dbl=function(){var e=this.curve.a,t=this.x,r=this.y,n=this.z,o=n.redSqr().redSqr(),i=t.redSqr(),s=r.redSqr(),a=i.redAdd(i).redIAdd(i).redIAdd(e.redMul(o)),l=t.redAdd(t),c=(l=l.redIAdd(l)).redMul(s),u=a.redSqr().redISub(c.redAdd(c)),d=c.redISub(u),p=s.redSqr();p=(p=(p=p.redIAdd(p)).redIAdd(p)).redIAdd(p);var f=a.redMul(d).redISub(p),h=r.redAdd(r).redMul(n);return this.curve.jpoint(u,f,h)},Md.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr(),n=t.redSqr(),o=e.redAdd(e).redIAdd(e),i=o.redSqr(),s=this.x.redAdd(t).redSqr().redISub(e).redISub(n),a=(s=(s=(s=s.redIAdd(s)).redAdd(s).redIAdd(s)).redISub(i)).redSqr(),l=n.redIAdd(n);l=(l=(l=l.redIAdd(l)).redIAdd(l)).redIAdd(l);var c=o.redIAdd(s).redSqr().redISub(i).redISub(a).redISub(l),u=t.redMul(c);u=(u=u.redIAdd(u)).redIAdd(u);var d=this.x.redMul(a).redISub(u);d=(d=d.redIAdd(d)).redIAdd(d);var p=this.y.redMul(c.redMul(l.redISub(c)).redISub(s.redMul(a)));p=(p=(p=p.redIAdd(p)).redIAdd(p)).redIAdd(p);var f=this.z.redAdd(s).redSqr().redISub(r).redISub(a);return this.curve.jpoint(d,p,f)},Md.prototype.mul=function(e,t){return e=new fd(e,t),this.curve._wnafMul(this,e)},Md.prototype.eq=function(e){if("affine"===e.type)return this.eq(e.toJ());if(this===e)return!0;var t=this.z.redSqr(),r=e.z.redSqr();if(0!==this.x.redMul(r).redISub(e.x.redMul(t)).cmpn(0))return!1;var n=t.redMul(this.z),o=r.redMul(e.z);return 0===this.y.redMul(o).redISub(e.y.redMul(n)).cmpn(0)},Md.prototype.eqXToP=function(e){var t=this.z.redSqr(),r=e.toRed(this.curve.red).redMul(t);if(0===this.x.cmp(r))return!0;for(var n=e.clone(),o=this.curve.redN.redMul(t);;){if(n.iadd(this.curve.n),n.cmp(this.curve.p)>=0)return!1;if(r.redIAdd(o),0===this.x.cmp(r))return!0}},Md.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},Md.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var Od=hd((function(e,t){var r=t;r.base=Ad,r.short=Td,r.mont=null,r.edwards=null})),Id=hd((function(e,t){var r,n=t,o=bd.assert;function i(e){"short"===e.type?this.curve=new Od.short(e):"edwards"===e.type?this.curve=new Od.edwards(e):this.curve=new Od.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,o(this.g.validate(),"Invalid curve"),o(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function s(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var r=new i(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=i,s("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:Yu.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),s("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:Yu.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),s("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:Yu.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),s("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:Yu.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),s("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:Yu.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),s("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:Yu.sha256,gRed:!1,g:["9"]}),s("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:Yu.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=null.crash()}catch(e){r=void 0}s("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:Yu.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})}));function jd(e){if(!(this instanceof jd))return new jd(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=yd.toArray(e.entropy,e.entropyEnc||"hex"),r=yd.toArray(e.nonce,e.nonceEnc||"hex"),n=yd.toArray(e.pers,e.persEnc||"hex");md(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}var Fd=jd;jd.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var o=0;o<this.V.length;o++)this.K[o]=0,this.V[o]=1;this._update(n),this._reseed=1,this.reseedInterval=281474976710656},jd.prototype._hmac=function(){return new Yu.hmac(this.hash,this.K)},jd.prototype._update=function(e){var t=this._hmac().update(this.V).update([0]);e&&(t=t.update(e)),this.K=t.digest(),this.V=this._hmac().update(this.V).digest(),e&&(this.K=this._hmac().update(this.V).update([1]).update(e).digest(),this.V=this._hmac().update(this.V).digest())},jd.prototype.reseed=function(e,t,r,n){"string"!=typeof t&&(n=r,r=t,t=null),e=yd.toArray(e,t),r=yd.toArray(r,n),md(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},jd.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=yd.toArray(r,n||"hex"),this._update(r));for(var o=[];o.length<e;)this.V=this._hmac().update(this.V).digest(),o=o.concat(this.V);var i=o.slice(0,e);return this._update(r),this._reseed++,yd.encode(i,t)};var _d=bd.assert;function Pd(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}var Bd=Pd;Pd.fromPublic=function(e,t,r){return t instanceof Pd?t:new Pd(e,{pub:t,pubEnc:r})},Pd.fromPrivate=function(e,t,r){return t instanceof Pd?t:new Pd(e,{priv:t,privEnc:r})},Pd.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},Pd.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},Pd.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},Pd.prototype._importPrivate=function(e,t){this.priv=new fd(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},Pd.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?_d(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||_d(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},Pd.prototype.derive=function(e){return e.validate()||_d(e.validate(),"public point not validated"),e.mul(this.priv).getX()},Pd.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},Pd.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},Pd.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"};var Wd=bd.assert;function Dd(e,t){if(e instanceof Dd)return e;this._importDER(e,t)||(Wd(e.r&&e.s,"Signature without r or s"),this.r=new fd(e.r,16),this.s=new fd(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}var Ld=Dd;function Ud(){this.place=0}function Vd(e,t){var r=e[t.place++];if(!(128&r))return r;var n=15&r;if(0===n||n>4)return!1;for(var o=0,i=0,s=t.place;i<n;i++,s++)o<<=8,o|=e[s],o>>>=0;return!(o<=127)&&(t.place=s,o)}function Zd(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t<r;)t++;return 0===t?e:e.slice(t)}function Hd(e,t){if(t<128)e.push(t);else{var r=1+(Math.log(t)/Math.LN2>>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}Dd.prototype._importDER=function(e,t){e=bd.toArray(e,t);var r=new Ud;if(48!==e[r.place++])return!1;var n=Vd(e,r);if(!1===n)return!1;if(n+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var o=Vd(e,r);if(!1===o)return!1;var i=e.slice(r.place,o+r.place);if(r.place+=o,2!==e[r.place++])return!1;var s=Vd(e,r);if(!1===s)return!1;if(e.length!==s+r.place)return!1;var a=e.slice(r.place,s+r.place);if(0===i[0]){if(!(128&i[1]))return!1;i=i.slice(1)}if(0===a[0]){if(!(128&a[1]))return!1;a=a.slice(1)}return this.r=new fd(i),this.s=new fd(a),this.recoveryParam=null,!0},Dd.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=Zd(t),r=Zd(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];Hd(n,t.length),(n=n.concat(t)).push(2),Hd(n,r.length);var o=n.concat(r),i=[48];return Hd(i,o.length),i=i.concat(o),bd.encode(i,e)};var zd=function(){throw new Error("unsupported")},Yd=bd.assert;function Gd(e){if(!(this instanceof Gd))return new Gd(e);"string"==typeof e&&(Yd(Object.prototype.hasOwnProperty.call(Id,e),"Unknown curve "+e),e=Id[e]),e instanceof Id.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}var Xd=Gd;Gd.prototype.keyPair=function(e){return new Bd(this,e)},Gd.prototype.keyFromPrivate=function(e,t){return Bd.fromPrivate(this,e,t)},Gd.prototype.keyFromPublic=function(e,t){return Bd.fromPublic(this,e,t)},Gd.prototype.genKeyPair=function(e){e||(e={});for(var t=new Fd({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||zd(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new fd(2));;){var o=new fd(t.generate(r));if(!(o.cmp(n)>0))return o.iaddn(1),this.keyFromPrivate(o)}},Gd.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},Gd.prototype.sign=function(e,t,r,n){"object"==typeof r&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new fd(e,16));for(var o=this.n.byteLength(),i=t.getPrivate().toArray("be",o),s=e.toArray("be",o),a=new Fd({hash:this.hash,entropy:i,nonce:s,pers:n.pers,persEnc:n.persEnc||"utf8"}),l=this.n.sub(new fd(1)),c=0;;c++){var u=n.k?n.k(c):new fd(a.generate(this.n.byteLength()));if(!((u=this._truncateToN(u,!0)).cmpn(1)<=0||u.cmp(l)>=0)){var d=this.g.mul(u);if(!d.isInfinity()){var p=d.getX(),f=p.umod(this.n);if(0!==f.cmpn(0)){var h=u.invm(this.n).mul(f.mul(t.getPrivate()).iadd(e));if(0!==(h=h.umod(this.n)).cmpn(0)){var m=(d.getY().isOdd()?1:0)|(0!==p.cmp(f)?2:0);return n.canonical&&h.cmp(this.nh)>0&&(h=this.n.sub(h),m^=1),new Ld({r:f,s:h,recoveryParam:m})}}}}}},Gd.prototype.verify=function(e,t,r,n){e=this._truncateToN(new fd(e,16)),r=this.keyFromPublic(r,n);var o=(t=new Ld(t,"hex")).r,i=t.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(i.cmpn(1)<0||i.cmp(this.n)>=0)return!1;var s,a=i.invm(this.n),l=a.mul(e).umod(this.n),c=a.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(l,r.getPublic(),c)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(l,r.getPublic(),c)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},Gd.prototype.recoverPubKey=function(e,t,r,n){Yd((3&r)===r,"The recovery param is more than two bits"),t=new Ld(t,n);var o=this.n,i=new fd(e),s=t.r,a=t.s,l=1&r,c=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&c)throw new Error("Unable to find sencond key candinate");s=c?this.curve.pointFromX(s.add(this.curve.n),l):this.curve.pointFromX(s,l);var u=t.r.invm(o),d=o.sub(i).mul(u).umod(o),p=a.mul(u).umod(o);return this.g.mulAdd(d,s,p)},Gd.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new Ld(t,n)).recoveryParam)return t.recoveryParam;for(var o=0;o<4;o++){var i;try{i=this.recoverPubKey(e,t,o)}catch(e){continue}if(i.eq(r))return o}throw new Error("Unable to find valid recovery factor")};var Jd=hd((function(e,t){var r=t;r.version="6.5.4",r.utils=bd,r.rand=function(){throw new Error("unsupported")},r.curve=Od,r.curves=Id,r.ec=Xd,r.eddsa=null})).ec;const qd=new Cs("signing-key/5.7.0");let Qd=null;function Kd(){return Qd||(Qd=new Jd("secp256k1")),Qd}class $d{constructor(e){wa(this,"curve","secp256k1"),wa(this,"privateKey",Ps(e)),32!==Bs(this.privateKey)&&qd.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");const t=Kd().keyFromPrivate(Is(this.privateKey));wa(this,"publicKey","0x"+t.getPublic(!1,"hex")),wa(this,"compressedPublicKey","0x"+t.getPublic(!0,"hex")),wa(this,"_isSigningKey",!0)}_addPoint(e){const t=Kd().keyFromPublic(Is(this.publicKey)),r=Kd().keyFromPublic(Is(e));return"0x"+t.pub.add(r.pub).encodeCompressed("hex")}signDigest(e){const t=Kd().keyFromPrivate(Is(this.privateKey)),r=Is(e);32!==r.length&&qd.throwArgumentError("bad digest length","digest",e);const n=t.sign(r,{canonical:!0});return Vs({recoveryParam:n.recoveryParam,r:Us("0x"+n.r.toString(16),32),s:Us("0x"+n.s.toString(16),32)})}computeSharedSecret(e){const t=Kd().keyFromPrivate(Is(this.privateKey)),r=Kd().keyFromPublic(Is(ep(e)));return Us("0x"+t.derive(r.getPublic()).toString(16),32)}static isSigningKey(e){return!(!e||!e._isSigningKey)}}function ep(e,t){const r=Is(e);if(32===r.length){const e=new $d(r);return t?"0x"+Kd().keyFromPrivate(r).getPublic(!0,"hex"):e.publicKey}return 33===r.length?t?Ps(r):"0x"+Kd().keyFromPublic(r).getPublic(!1,"hex"):65===r.length?t?"0x"+Kd().keyFromPublic(r).getPublic(!0,"hex"):Ps(r):qd.throwArgumentError("invalid public or private key","key","[REDACTED]")}const tp=new Cs("transactions/5.7.0");var rp;function np(e){return"0x"===e?null:oa(e)}function op(e){return"0x"===e?Ga:y.BigNumber.from(e)}function ip(e,t){return function(e){return oa(Ws(zs(Ws(ep(e),1)),12))}(function(e,t){const r=Vs(t),n={r:Is(r.r),s:Is(r.s)};return"0x"+Kd().recoverPubKey(Is(e),n,r.recoveryParam).encode("hex",!1)}(Is(e),t))}function sp(e,t){const r=Fs(y.BigNumber.from(e).toHexString());return r.length>32&&tp.throwArgumentError("invalid length for "+t,"transaction:"+t,e),r}function ap(e,t){return{address:oa(e),storageKeys:(t||[]).map(((t,r)=>(32!==Bs(t)&&tp.throwArgumentError("invalid access list storageKey",`accessList[${e}:${r}]`,t),t.toLowerCase())))}}function lp(e){if(Array.isArray(e))return e.map(((e,t)=>Array.isArray(e)?(e.length>2&&tp.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${t}]`,e),ap(e[0],e[1])):ap(e.address,e.storageKeys)));const t=Object.keys(e).map((t=>{const r=e[t].reduce(((e,t)=>(e[t]=!0,e)),{});return ap(t,Object.keys(r).sort())}));return t.sort(((e,t)=>e.address.localeCompare(t.address))),t}function cp(e){return lp(e).map((e=>[e.address,e.storageKeys]))}function up(e,t){if(null!=e.gasPrice){const t=y.BigNumber.from(e.gasPrice),r=y.BigNumber.from(e.maxFeePerGas||0);t.eq(r)||tp.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:t,maxFeePerGas:r})}const r=[sp(e.chainId||0,"chainId"),sp(e.nonce||0,"nonce"),sp(e.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),sp(e.maxFeePerGas||0,"maxFeePerGas"),sp(e.gasLimit||0,"gasLimit"),null!=e.to?oa(e.to):"0x",sp(e.value||0,"value"),e.data||"0x",cp(e.accessList||[])];if(t){const e=Vs(t);r.push(sp(e.recoveryParam,"recoveryParam")),r.push(Fs(e.r)),r.push(Fs(e.s))}return Ds(["0x02",qs(r)])}function dp(e,t){const r=[sp(e.chainId||0,"chainId"),sp(e.nonce||0,"nonce"),sp(e.gasPrice||0,"gasPrice"),sp(e.gasLimit||0,"gasLimit"),null!=e.to?oa(e.to):"0x",sp(e.value||0,"value"),e.data||"0x",cp(e.accessList||[])];if(t){const e=Vs(t);r.push(sp(e.recoveryParam,"recoveryParam")),r.push(Fs(e.r)),r.push(Fs(e.s))}return Ds(["0x01",qs(r)])}function pp(e,t,r){try{const r=op(t[0]).toNumber();if(0!==r&&1!==r)throw new Error("bad recid");e.v=r}catch(e){tp.throwArgumentError("invalid v for transaction type: 1","v",t[0])}e.r=Us(t[1],32),e.s=Us(t[2],32);try{const t=zs(r(e));e.from=ip(t,{r:e.r,s:e.s,recoveryParam:e.v})}catch(e){}}function fp(e){const t=Is(e);if(t[0]>127)return function(e){const t=$s(e);9!==t.length&&6!==t.length&&tp.throwArgumentError("invalid raw transaction","rawTransaction",e);const r={nonce:op(t[0]).toNumber(),gasPrice:op(t[1]),gasLimit:op(t[2]),to:np(t[3]),value:op(t[4]),data:t[5],chainId:0};if(6===t.length)return r;try{r.v=y.BigNumber.from(t[6]).toNumber()}catch(e){return r}if(r.r=Us(t[7],32),r.s=Us(t[8],32),y.BigNumber.from(r.r).isZero()&&y.BigNumber.from(r.s).isZero())r.chainId=r.v,r.v=0;else{r.chainId=Math.floor((r.v-35)/2),r.chainId<0&&(r.chainId=0);let n=r.v-27;const o=t.slice(0,6);0!==r.chainId&&(o.push(Ps(r.chainId)),o.push("0x"),o.push("0x"),n-=2*r.chainId+8);const i=zs(qs(o));try{r.from=ip(i,{r:Ps(r.r),s:Ps(r.s),recoveryParam:n})}catch(e){}r.hash=zs(e)}return r.type=null,r}(t);switch(t[0]){case 1:return function(e){const t=$s(e.slice(1));8!==t.length&&11!==t.length&&tp.throwArgumentError("invalid component count for transaction type: 1","payload",Ps(e));const r={type:1,chainId:op(t[0]).toNumber(),nonce:op(t[1]).toNumber(),gasPrice:op(t[2]),gasLimit:op(t[3]),to:np(t[4]),value:op(t[5]),data:t[6],accessList:lp(t[7])};return 8===t.length||(r.hash=zs(e),pp(r,t.slice(8),dp)),r}(t);case 2:return function(e){const t=$s(e.slice(1));9!==t.length&&12!==t.length&&tp.throwArgumentError("invalid component count for transaction type: 2","payload",Ps(e));const r=op(t[2]),n=op(t[3]),o={type:2,chainId:op(t[0]).toNumber(),nonce:op(t[1]).toNumber(),maxPriorityFeePerGas:r,maxFeePerGas:n,gasPrice:null,gasLimit:op(t[4]),to:np(t[5]),value:op(t[6]),data:t[7],accessList:lp(t[8])};return 9===t.length||(o.hash=zs(e),pp(o,t.slice(9),up)),o}(t)}return tp.throwError(`unsupported transaction type: ${t[0]}`,Cs.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:t[0]})}!function(e){e[e.legacy=0]="legacy",e[e.eip2930=1]="eip2930",e[e.eip1559=2]="eip1559"}(rp||(rp={}));const hp=new Cs(dd);class mp{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){const e={},t=this.address.bind(this),r=this.bigNumber.bind(this),n=this.blockTag.bind(this),o=this.data.bind(this),i=this.hash.bind(this),s=this.hex.bind(this),a=this.number.bind(this),l=this.type.bind(this);return e.transaction={hash:i,type:l,accessList:mp.allowNull(this.accessList.bind(this),null),blockHash:mp.allowNull(i,null),blockNumber:mp.allowNull(a,null),transactionIndex:mp.allowNull(a,null),confirmations:mp.allowNull(a,null),from:t,gasPrice:mp.allowNull(r),maxPriorityFeePerGas:mp.allowNull(r),maxFeePerGas:mp.allowNull(r),gasLimit:r,to:mp.allowNull(t,null),value:r,nonce:a,data:o,r:mp.allowNull(this.uint256),s:mp.allowNull(this.uint256),v:mp.allowNull(a),creates:mp.allowNull(t,null),raw:mp.allowNull(o)},e.transactionRequest={from:mp.allowNull(t),nonce:mp.allowNull(a),gasLimit:mp.allowNull(r),gasPrice:mp.allowNull(r),maxPriorityFeePerGas:mp.allowNull(r),maxFeePerGas:mp.allowNull(r),to:mp.allowNull(t),value:mp.allowNull(r),data:mp.allowNull((e=>this.data(e,!0))),type:mp.allowNull(a),accessList:mp.allowNull(this.accessList.bind(this),null)},e.receiptLog={transactionIndex:a,blockNumber:a,transactionHash:i,address:t,topics:mp.arrayOf(i),data:o,logIndex:a,blockHash:i},e.receipt={to:mp.allowNull(this.address,null),from:mp.allowNull(this.address,null),contractAddress:mp.allowNull(t,null),transactionIndex:a,root:mp.allowNull(s),gasUsed:r,logsBloom:mp.allowNull(o),blockHash:i,transactionHash:i,logs:mp.arrayOf(this.receiptLog.bind(this)),blockNumber:a,confirmations:mp.allowNull(a,null),cumulativeGasUsed:r,effectiveGasPrice:mp.allowNull(r),status:mp.allowNull(a),type:l},e.block={hash:mp.allowNull(i),parentHash:i,number:a,timestamp:a,nonce:mp.allowNull(s),difficulty:this.difficulty.bind(this),gasLimit:r,gasUsed:r,miner:mp.allowNull(t),extraData:o,transactions:mp.allowNull(mp.arrayOf(i)),baseFeePerGas:mp.allowNull(r)},e.blockWithTransactions=ka(e.block),e.blockWithTransactions.transactions=mp.allowNull(mp.arrayOf(this.transactionResponse.bind(this))),e.filter={fromBlock:mp.allowNull(n,void 0),toBlock:mp.allowNull(n,void 0),blockHash:mp.allowNull(i,void 0),address:mp.allowNull(t,void 0),topics:mp.allowNull(this.topics.bind(this),void 0)},e.filterLog={blockNumber:mp.allowNull(a),blockHash:mp.allowNull(i),transactionIndex:a,removed:mp.allowNull(this.boolean.bind(this)),address:t,data:mp.allowFalsish(o,"0x"),topics:mp.arrayOf(i),transactionHash:i,logIndex:a},e}accessList(e){return lp(e||[])}number(e){return"0x"===e?0:y.BigNumber.from(e).toNumber()}type(e){return"0x"===e||null==e?0:y.BigNumber.from(e).toNumber()}bigNumber(e){return y.BigNumber.from(e)}boolean(e){if("boolean"==typeof e)return e;if("string"==typeof e){if("true"===(e=e.toLowerCase()))return!0;if("false"===e)return!1}throw new Error("invalid boolean - "+e)}hex(e,t){return"string"==typeof e&&(t||"0x"===e.substring(0,2)||(e="0x"+e),_s(e))?e.toLowerCase():hp.throwArgumentError("invalid hash","value",e)}data(e,t){const r=this.hex(e,t);if(r.length%2!=0)throw new Error("invalid data; odd-length - "+e);return r}address(e){return oa(e)}callAddress(e){if(!_s(e,32))return null;const t=oa(Ws(e,12));return t===za?null:t}contractAddress(e){return function(e){let t=null;try{t=oa(e.from)}catch(t){ea.throwArgumentError("missing from address","transaction",e)}return oa(Ws(zs(qs([t,Fs(Is(y.BigNumber.from(e.nonce).toHexString()))])),12))}(e)}blockTag(e){if(null==e)return"latest";if("earliest"===e)return"0x0";switch(e){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return e}if("number"==typeof e||_s(e))return Ls(e);throw new Error("invalid blockTag")}hash(e,t){const r=this.hex(e,t);return 32!==Bs(r)?hp.throwArgumentError("invalid hash","value",e):r}difficulty(e){if(null==e)return null;const t=y.BigNumber.from(e);try{return t.toNumber()}catch(e){}return null}uint256(e){if(!_s(e))throw new Error("invalid uint256");return Us(e,32)}_block(e,t){null!=e.author&&null==e.miner&&(e.miner=e.author);const r=null!=e._difficulty?e._difficulty:e.difficulty,n=mp.check(t,e);return n._difficulty=null==r?null:y.BigNumber.from(r),n}block(e){return this._block(e,this.formats.block)}blockWithTransactions(e){return this._block(e,this.formats.blockWithTransactions)}transactionRequest(e){return mp.check(this.formats.transactionRequest,e)}transactionResponse(e){null!=e.gas&&null==e.gasLimit&&(e.gasLimit=e.gas),e.to&&y.BigNumber.from(e.to).isZero()&&(e.to="0x0000000000000000000000000000000000000000"),null!=e.input&&null==e.data&&(e.data=e.input),null==e.to&&null==e.creates&&(e.creates=this.contractAddress(e)),1!==e.type&&2!==e.type||null!=e.accessList||(e.accessList=[]);const t=mp.check(this.formats.transaction,e);if(null!=e.chainId){let r=e.chainId;_s(r)&&(r=y.BigNumber.from(r).toNumber()),t.chainId=r}else{let r=e.networkId;null==r&&null==t.v&&(r=e.chainId),_s(r)&&(r=y.BigNumber.from(r).toNumber()),"number"!=typeof r&&null!=t.v&&(r=(t.v-35)/2,r<0&&(r=0),r=parseInt(r)),"number"!=typeof r&&(r=0),t.chainId=r}return t.blockHash&&"x"===t.blockHash.replace(/0/g,"")&&(t.blockHash=null),t}transaction(e){return fp(e)}receiptLog(e){return mp.check(this.formats.receiptLog,e)}receipt(e){const t=mp.check(this.formats.receipt,e);if(null!=t.root)if(t.root.length<=4){const e=y.BigNumber.from(t.root).toNumber();0===e||1===e?(null!=t.status&&t.status!==e&&hp.throwArgumentError("alt-root-status/status mismatch","value",{root:t.root,status:t.status}),t.status=e,delete t.root):hp.throwArgumentError("invalid alt-root-status","value.root",t.root)}else 66!==t.root.length&&hp.throwArgumentError("invalid root hash","value.root",t.root);return null!=t.status&&(t.byzantium=!0),t}topics(e){return Array.isArray(e)?e.map((e=>this.topics(e))):null!=e?this.hash(e,!0):null}filter(e){return mp.check(this.formats.filter,e)}filterLog(e){return mp.check(this.formats.filterLog,e)}static check(e,t){const r={};for(const n in e)try{const o=e[n](t[n]);void 0!==o&&(r[n]=o)}catch(e){throw e.checkKey=n,e.checkValue=t[n],e}return r}static allowNull(e,t){return function(r){return null==r?t:e(r)}}static allowFalsish(e,t){return function(r){return r?e(r):t}}static arrayOf(e){return function(t){if(!Array.isArray(t))throw new Error("not an array");const r=[];return t.forEach((function(t){r.push(e(t))})),r}}}var gp=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const yp=new Cs(dd);function bp(e){return null==e?"null":(32!==Bs(e)&&yp.throwArgumentError("invalid topic","topic",e),e.toLowerCase())}function vp(e){for(e=e.slice();e.length>0&&null==e[e.length-1];)e.pop();return e.map((e=>{if(Array.isArray(e)){const t={};e.forEach((e=>{t[bp(e)]=!0}));const r=Object.keys(t);return r.sort(),r.join("|")}return bp(e)})).join("&")}function xp(e){if("string"==typeof e){if(32===Bs(e=e.toLowerCase()))return"tx:"+e;if(-1===e.indexOf(":"))return e}else{if(Array.isArray(e))return"filter:*:"+vp(e);if(Ia.isForkEvent(e))throw yp.warn("not implemented"),new Error("not implemented");if(e&&"object"==typeof e)return"filter:"+(e.address||"*")+":"+vp(e.topics||[])}throw new Error("invalid event - "+e)}function wp(){return(new Date).getTime()}function Ep(e){return new Promise((t=>{setTimeout(t,e)}))}const Ap=["block","network","pending","poll"];class kp{constructor(e,t,r){wa(this,"tag",e),wa(this,"listener",t),wa(this,"once",r),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){const e=this.tag.split(":");return"tx"!==e[0]?null:e[1]}get filter(){const e=this.tag.split(":");if("filter"!==e[0])return null;const t=e[1],r=""===(n=e[2])?[]:n.split(/&/g).map((e=>{if(""===e)return[];const t=e.split("|").map((e=>"null"===e?null:e));return 1===t.length?t[0]:t}));var n;const o={};return r.length>0&&(o.topics=r),t&&"*"!==t&&(o.address=t),o}pollable(){return this.tag.indexOf(":")>=0||Ap.indexOf(this.tag)>=0}}const Cp={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function Rp(e){return Us(y.BigNumber.from(e).toHexString(),32)}function Sp(e){return Ha.encode(js([e,Ws(Gu(Gu(e)),0,4)]))}const Tp=new RegExp("^(ipfs)://(.*)$","i"),Np=[new RegExp("^(https)://(.*)$","i"),new RegExp("^(data):(.*)$","i"),Tp,new RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function Mp(e,t){try{return nl(Op(e,t))}catch(e){}return null}function Op(e,t){if("0x"===e)return null;const r=y.BigNumber.from(Ws(e,t,t+32)).toNumber(),n=y.BigNumber.from(Ws(e,r,r+32)).toNumber();return Ws(e,r+32,r+32+n)}function Ip(e){return e.match(/^ipfs:\/\/ipfs\//i)?e=e.substring(12):e.match(/^ipfs:\/\//i)?e=e.substring(7):yp.throwArgumentError("unsupported IPFS format","link",e),`https://gateway.ipfs.io/ipfs/${e}`}function jp(e){const t=Is(e);if(t.length>32)throw new Error("internal; should not happen");const r=new Uint8Array(32);return r.set(t,32-t.length),r}function Fp(e){if(e.length%32==0)return e;const t=new Uint8Array(32*Math.ceil(e.length/32));return t.set(e),t}function _p(e){const t=[];let r=0;for(let n=0;n<e.length;n++)t.push(null),r+=32;for(let n=0;n<e.length;n++){const o=Is(e[n]);t[n]=jp(r),t.push(jp(o.length)),t.push(Fp(o)),r+=32+32*Math.ceil(o.length/32)}return Ds(t)}class Pp{constructor(e,t,r,n){wa(this,"provider",e),wa(this,"name",r),wa(this,"address",e.formatter.address(t)),wa(this,"_resolvedAddress",n)}supportsWildcard(){return this._supportsEip2544||(this._supportsEip2544=this.provider.call({to:this.address,data:"0x01ffc9a79061b92300000000000000000000000000000000000000000000000000000000"}).then((e=>y.BigNumber.from(e).eq(1))).catch((e=>{if(e.code===Cs.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,e}))),this._supportsEip2544}_fetch(e,t){return gp(this,void 0,void 0,(function*(){const r={to:this.address,ccipReadEnabled:!0,data:Ds([e,Tl(this.name),t||"0x"])};let n=!1;var o;(yield this.supportsWildcard())&&(n=!0,r.data=Ds(["0x9061b923",_p([(o=this.name,Ps(js(Sl(o).map((e=>{if(e.length>63)throw new Error("invalid DNS encoded entry; length exceeds 63 bytes");const t=new Uint8Array(e.length+1);return t.set(e,1),t[0]=t.length-1,t}))))+"00"),r.data])]));try{let e=yield this.provider.call(r);return Is(e).length%32==4&&yp.throwError("resolver threw error",Cs.errors.CALL_EXCEPTION,{transaction:r,data:e}),n&&(e=Op(e,0)),e}catch(e){if(e.code===Cs.errors.CALL_EXCEPTION)return null;throw e}}))}_fetchBytes(e,t){return gp(this,void 0,void 0,(function*(){const r=yield this._fetch(e,t);return null!=r?Op(r,0):null}))}_getAddress(e,t){const r=Cp[String(e)];if(null==r&&yp.throwError(`unsupported coin type: ${e}`,Cs.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`}),"eth"===r.ilk)return this.provider.formatter.address(t);const n=Is(t);if(null!=r.p2pkh){const e=t.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Sp(js([[r.p2pkh],"0x"+e[2]]))}}if(null!=r.p2sh){const e=t.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(e){const t=parseInt(e[1],16);if(e[2].length===2*t&&t>=1&&t<=75)return Sp(js([[r.p2sh],"0x"+e[2]]))}}if(null!=r.prefix){const e=n[1];let t=n[0];if(0===t?20!==e&&32!==e&&(t=-1):t=-1,t>=0&&n.length===2+e&&e>=1&&e<=75){const e=ud.toWords(n.slice(2));return e.unshift(t),ud.encode(r.prefix,e)}}return null}getAddress(e){return gp(this,void 0,void 0,(function*(){if(null==e&&(e=60),60===e)try{const e=yield this._fetch("0x3b3b57de");return"0x"===e||"0x0000000000000000000000000000000000000000000000000000000000000000"===e?null:this.provider.formatter.callAddress(e)}catch(e){if(e.code===Cs.errors.CALL_EXCEPTION)return null;throw e}const t=yield this._fetchBytes("0xf1cb7e06",Rp(e));if(null==t||"0x"===t)return null;const r=this._getAddress(e,t);return null==r&&yp.throwError("invalid or unsupported coin data",Cs.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${e})`,coinType:e,data:t}),r}))}getAvatar(){return gp(this,void 0,void 0,(function*(){const e=[{type:"name",content:this.name}];try{const t=yield this.getText("avatar");if(null==t)return null;for(let r=0;r<Np.length;r++){const n=t.match(Np[r]);if(null==n)continue;const o=n[1].toLowerCase();switch(o){case"https":return e.push({type:"url",content:t}),{linkage:e,url:t};case"data":return e.push({type:"data",content:t}),{linkage:e,url:t};case"ipfs":return e.push({type:"ipfs",content:t}),{linkage:e,url:Ip(t)};case"erc721":case"erc1155":{const r="erc721"===o?"0xc87b56dd":"0x0e89341c";e.push({type:o,content:t});const i=this._resolvedAddress||(yield this.getAddress()),s=(n[2]||"").split("/");if(2!==s.length)return null;const a=yield this.provider.formatter.address(s[0]),l=Us(y.BigNumber.from(s[1]).toHexString(),32);if("erc721"===o){const t=this.provider.formatter.callAddress(yield this.provider.call({to:a,data:Ds(["0x6352211e",l])}));if(i!==t)return null;e.push({type:"owner",content:t})}else if("erc1155"===o){const t=y.BigNumber.from(yield this.provider.call({to:a,data:Ds(["0x00fdd58e",Us(i,32),l])}));if(t.isZero())return null;e.push({type:"balance",content:t.toString()})}const c={to:this.provider.formatter.address(s[0]),data:Ds([r,l])};let u=Mp(yield this.provider.call(c),0);if(null==u)return null;e.push({type:"metadata-url-base",content:u}),"erc1155"===o&&(u=u.replace("{id}",l.substring(2)),e.push({type:"metadata-url-expanded",content:u})),u.match(/^ipfs:/i)&&(u=Ip(u)),e.push({type:"metadata-url",content:u});const d=yield ed(u);if(!d)return null;e.push({type:"metadata",content:JSON.stringify(d)});let p=d.image;if("string"!=typeof p)return null;if(p.match(/^(https:\/\/|data:)/i));else{if(null==p.match(Tp))return null;e.push({type:"url-ipfs",content:p}),p=Ip(p)}return e.push({type:"url",content:p}),{linkage:e,url:p}}}}}catch(e){}return null}))}getContentHash(){return gp(this,void 0,void 0,(function*(){const e=yield this._fetchBytes("0xbc1c58d1");if(null==e||"0x"===e)return null;const t=e.match(/^0xe3010170(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(t){const e=parseInt(t[3],16);if(t[4].length===2*e)return"ipfs://"+Ha.encode("0x"+t[1])}const r=e.match(/^0xe5010172(([0-9a-f][0-9a-f])([0-9a-f][0-9a-f])([0-9a-f]*))$/);if(r){const e=parseInt(r[3],16);if(r[4].length===2*e)return"ipns://"+Ha.encode("0x"+r[1])}const n=e.match(/^0xe40101fa011b20([0-9a-f]*)$/);if(n&&64===n[1].length)return"bzz://"+n[1];const o=e.match(/^0x90b2c605([0-9a-f]*)$/);if(o&&68===o[1].length){const e={"=":"","+":"-","/":"_"};return"sia://"+Va("0x"+o[1]).replace(/[=+\/]/g,(t=>e[t]))}return yp.throwError("invalid or unsupported content hash data",Cs.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:e})}))}getText(e){return gp(this,void 0,void 0,(function*(){let t=rl(e);t=js([Rp(64),Rp(t.length),t]),t.length%32!=0&&(t=js([t,Us("0x",32-e.length%32)]));const r=yield this._fetchBytes("0x59d1d43c",Ps(t));return null==r||"0x"===r?null:nl(r)}))}}let Bp=null,Wp=1;class Dp extends ja{constructor(e){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),wa(this,"anyNetwork","any"===e),this.anyNetwork&&(e=this.detectNetwork()),e instanceof Promise)this._networkPromise=e,e.catch((e=>{})),this._ready().catch((e=>{}));else{const t=Ea(new.target,"getNetwork")(e);t?(wa(this,"_network",t),this.emit("network",t,null)):yp.throwArgumentError("invalid network","network",e)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return gp(this,void 0,void 0,(function*(){if(null==this._network){let e=null;if(this._networkPromise)try{e=yield this._networkPromise}catch(e){}null==e&&(e=yield this.detectNetwork()),e||yp.throwError("no network detected",Cs.errors.UNKNOWN_ERROR,{}),null==this._network&&(this.anyNetwork?this._network=e:wa(this,"_network",e),this.emit("network",e,null))}return this._network}))}get ready(){return td((()=>this._ready().then((e=>e),(e=>{if(e.code!==Cs.errors.NETWORK_ERROR||"noNetwork"!==e.event)throw e}))))}static getFormatter(){return null==Bp&&(Bp=new mp),Bp}static getNetwork(e){return function(e){if(null==e)return null;if("number"==typeof e){for(const t in La){const r=La[t];if(r.chainId===e)return{name:r.name,chainId:r.chainId,ensAddress:r.ensAddress||null,_defaultProvider:r._defaultProvider||null}}return{chainId:e,name:"unknown"}}if("string"==typeof e){const t=La[e];return null==t?null:{name:t.name,chainId:t.chainId,ensAddress:t.ensAddress,_defaultProvider:t._defaultProvider||null}}const t=La[e.name];if(!t)return"number"!=typeof e.chainId&&Fa.throwArgumentError("invalid network chainId","network",e),e;0!==e.chainId&&e.chainId!==t.chainId&&Fa.throwArgumentError("network chainId mismatch","network",e);let r=e._defaultProvider||null;var n;return null==r&&t._defaultProvider&&(r=(n=t._defaultProvider)&&"function"==typeof n.renetwork?t._defaultProvider.renetwork(e):t._defaultProvider),{name:e.name,chainId:t.chainId,ensAddress:e.ensAddress||t.ensAddress||null,_defaultProvider:r}}(null==e?"homestead":e)}ccipReadFetch(e,t,r){return gp(this,void 0,void 0,(function*(){if(this.disableCcipRead||0===r.length)return null;const n=e.to.toLowerCase(),o=t.toLowerCase(),i=[];for(let e=0;e<r.length;e++){const t=r[e],s=t.replace("{sender}",n).replace("{data}",o),a=t.indexOf("{data}")>=0?null:JSON.stringify({data:o,sender:n}),l=yield ed({url:s,errorPassThrough:!0},a,((e,t)=>(e.status=t.statusCode,e)));if(l.data)return l.data;const c=l.message||"unknown error";if(l.status>=400&&l.status<500)return yp.throwError(`response not found during CCIP fetch: ${c}`,Cs.errors.SERVER_ERROR,{url:t,errorMessage:c});i.push(c)}return yp.throwError(`error encountered during CCIP fetch: ${i.map((e=>JSON.stringify(e))).join(", ")}`,Cs.errors.SERVER_ERROR,{urls:r,errorMessages:i})}))}_getInternalBlockNumber(e){return gp(this,void 0,void 0,(function*(){if(yield this._ready(),e>0)for(;this._internalBlockNumber;){const t=this._internalBlockNumber;try{const r=yield t;if(wp()-r.respTime<=e)return r.blockNumber;break}catch(e){if(this._internalBlockNumber===t)break}}const t=wp(),r=Aa({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then((e=>null),(e=>e))}).then((({blockNumber:e,networkError:n})=>{if(n)throw this._internalBlockNumber===r&&(this._internalBlockNumber=null),n;const o=wp();return(e=y.BigNumber.from(e).toNumber())<this._maxInternalBlockNumber&&(e=this._maxInternalBlockNumber),this._maxInternalBlockNumber=e,this._setFastBlockNumber(e),{blockNumber:e,reqTime:t,respTime:o}}));return this._internalBlockNumber=r,r.catch((e=>{this._internalBlockNumber===r&&(this._internalBlockNumber=null)})),(yield r).blockNumber}))}poll(){return gp(this,void 0,void 0,(function*(){const e=Wp++,t=[];let r=null;try{r=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(e){return void this.emit("error",e)}if(this._setFastBlockNumber(r),this.emit("poll",e,r),r!==this._lastBlockNumber){if(-2===this._emitted.block&&(this._emitted.block=r-1),Math.abs(this._emitted.block-r)>1e3)yp.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${r})`),this.emit("error",yp.makeError("network block skew detected",Cs.errors.NETWORK_ERROR,{blockNumber:r,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",r);else for(let e=this._emitted.block+1;e<=r;e++)this.emit("block",e);this._emitted.block!==r&&(this._emitted.block=r,Object.keys(this._emitted).forEach((e=>{if("block"===e)return;const t=this._emitted[e];"pending"!==t&&r-t>12&&delete this._emitted[e]}))),-2===this._lastBlockNumber&&(this._lastBlockNumber=r-1),this._events.forEach((e=>{switch(e.type){case"tx":{const r=e.hash;let n=this.getTransactionReceipt(r).then((e=>e&&null!=e.blockNumber?(this._emitted["t:"+r]=e.blockNumber,this.emit(r,e),null):null)).catch((e=>{this.emit("error",e)}));t.push(n);break}case"filter":if(!e._inflight){e._inflight=!0,-2===e._lastBlockNumber&&(e._lastBlockNumber=r-1);const n=e.filter;n.fromBlock=e._lastBlockNumber+1,n.toBlock=r;const o=n.toBlock-this._maxFilterBlockRange;o>n.fromBlock&&(n.fromBlock=o),n.fromBlock<0&&(n.fromBlock=0);const i=this.getLogs(n).then((t=>{e._inflight=!1,0!==t.length&&t.forEach((t=>{t.blockNumber>e._lastBlockNumber&&(e._lastBlockNumber=t.blockNumber),this._emitted["b:"+t.blockHash]=t.blockNumber,this._emitted["t:"+t.transactionHash]=t.blockNumber,this.emit(n,t)}))})).catch((t=>{this.emit("error",t),e._inflight=!1}));t.push(i)}}})),this._lastBlockNumber=r,Promise.all(t).then((()=>{this.emit("didPoll",e)})).catch((e=>{this.emit("error",e)}))}else this.emit("didPoll",e)}))}resetEventsBlock(e){this._lastBlockNumber=e-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return gp(this,void 0,void 0,(function*(){return yp.throwError("provider does not support network detection",Cs.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})}))}getNetwork(){return gp(this,void 0,void 0,(function*(){const e=yield this._ready(),t=yield this.detectNetwork();if(e.chainId!==t.chainId){if(this.anyNetwork)return this._network=t,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",t,e),yield Ep(0),this._network;const r=yp.makeError("underlying network changed",Cs.errors.NETWORK_ERROR,{event:"changed",network:e,detectedNetwork:t});throw this.emit("error",r),r}return e}))}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then((e=>{this._setFastBlockNumber(e)}),(e=>{})),null!=this._fastBlockNumber?this._fastBlockNumber:-1}get polling(){return null!=this._poller}set polling(e){e&&!this._poller?(this._poller=setInterval((()=>{this.poll()}),this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout((()=>{this.poll(),this._bootstrapPoll=setTimeout((()=>{this._poller||this.poll(),this._bootstrapPoll=null}),this.pollingInterval)}),0))):!e&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(e){if("number"!=typeof e||e<=0||parseInt(String(e))!=e)throw new Error("invalid polling interval");this._pollingInterval=e,this._poller&&(clearInterval(this._poller),this._poller=setInterval((()=>{this.poll()}),this._pollingInterval))}_getFastBlockNumber(){const e=wp();return e-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=e,this._fastBlockNumberPromise=this.getBlockNumber().then((e=>((null==this._fastBlockNumber||e>this._fastBlockNumber)&&(this._fastBlockNumber=e),this._fastBlockNumber)))),this._fastBlockNumberPromise}_setFastBlockNumber(e){null!=this._fastBlockNumber&&e<this._fastBlockNumber||(this._fastQueryDate=wp(),(null==this._fastBlockNumber||e>this._fastBlockNumber)&&(this._fastBlockNumber=e,this._fastBlockNumberPromise=Promise.resolve(e)))}waitForTransaction(e,t,r){return gp(this,void 0,void 0,(function*(){return this._waitForTransaction(e,null==t?1:t,r||0,null)}))}_waitForTransaction(e,t,r,n){return gp(this,void 0,void 0,(function*(){const o=yield this.getTransactionReceipt(e);return(o?o.confirmations:0)>=t?o:new Promise(((o,i)=>{const s=[];let a=!1;const l=function(){return!!a||(a=!0,s.forEach((e=>{e()})),!1)},c=e=>{e.confirmations<t||l()||o(e)};if(this.on(e,c),s.push((()=>{this.removeListener(e,c)})),n){let r=n.startBlock,o=null;const c=s=>gp(this,void 0,void 0,(function*(){a||(yield Ep(1e3),this.getTransactionCount(n.from).then((u=>gp(this,void 0,void 0,(function*(){if(!a){if(u<=n.nonce)r=s;else{{const t=yield this.getTransaction(e);if(t&&null!=t.blockNumber)return}for(null==o&&(o=r-3,o<n.startBlock&&(o=n.startBlock));o<=s;){if(a)return;const r=yield this.getBlockWithTransactions(o);for(let o=0;o<r.transactions.length;o++){const s=r.transactions[o];if(s.hash===e)return;if(s.from===n.from&&s.nonce===n.nonce){if(a)return;const r=yield this.waitForTransaction(s.hash,t);if(l())return;let o="replaced";return s.data===n.data&&s.to===n.to&&s.value.eq(n.value)?o="repriced":"0x"===s.data&&s.from===s.to&&s.value.isZero()&&(o="cancelled"),void i(yp.makeError("transaction was replaced",Cs.errors.TRANSACTION_REPLACED,{cancelled:"replaced"===o||"cancelled"===o,reason:o,replacement:this._wrapTransaction(s),hash:e,receipt:r}))}}o++}}a||this.once("block",c)}}))),(e=>{a||this.once("block",c)})))}));if(a)return;this.once("block",c),s.push((()=>{this.removeListener("block",c)}))}if("number"==typeof r&&r>0){const e=setTimeout((()=>{l()||i(yp.makeError("timeout exceeded",Cs.errors.TIMEOUT,{timeout:r}))}),r);e.unref&&e.unref(),s.push((()=>{clearTimeout(e)}))}}))}))}getBlockNumber(){return gp(this,void 0,void 0,(function*(){return this._getInternalBlockNumber(0)}))}getGasPrice(){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const e=yield this.perform("getGasPrice",{});try{return y.BigNumber.from(e)}catch(t){return yp.throwError("bad result from backend",Cs.errors.SERVER_ERROR,{method:"getGasPrice",result:e,error:t})}}))}getBalance(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getBalance",r);try{return y.BigNumber.from(n)}catch(e){return yp.throwError("bad result from backend",Cs.errors.SERVER_ERROR,{method:"getBalance",params:r,result:n,error:e})}}))}getTransactionCount(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getTransactionCount",r);try{return y.BigNumber.from(n).toNumber()}catch(e){return yp.throwError("bad result from backend",Cs.errors.SERVER_ERROR,{method:"getTransactionCount",params:r,result:n,error:e})}}))}getCode(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(t)}),n=yield this.perform("getCode",r);try{return Ps(n)}catch(e){return yp.throwError("bad result from backend",Cs.errors.SERVER_ERROR,{method:"getCode",params:r,result:n,error:e})}}))}getStorageAt(e,t,r){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const n=yield Aa({address:this._getAddress(e),blockTag:this._getBlockTag(r),position:Promise.resolve(t).then((e=>Ls(e)))}),o=yield this.perform("getStorageAt",n);try{return Ps(o)}catch(e){return yp.throwError("bad result from backend",Cs.errors.SERVER_ERROR,{method:"getStorageAt",params:n,result:o,error:e})}}))}_wrapTransaction(e,t,r){if(null!=t&&32!==Bs(t))throw new Error("invalid response - sendTransaction");const n=e;return null!=t&&e.hash!==t&&yp.throwError("Transaction hash mismatch from Provider.sendTransaction.",Cs.errors.UNKNOWN_ERROR,{expectedHash:e.hash,returnedHash:t}),n.wait=(t,n)=>gp(this,void 0,void 0,(function*(){let o;null==t&&(t=1),null==n&&(n=0),0!==t&&null!=r&&(o={data:e.data,from:e.from,nonce:e.nonce,to:e.to,value:e.value,startBlock:r});const i=yield this._waitForTransaction(e.hash,t,n,o);return null==i&&0===t?null:(this._emitted["t:"+e.hash]=i.blockNumber,0===i.status&&yp.throwError("transaction failed",Cs.errors.CALL_EXCEPTION,{transactionHash:e.hash,transaction:e,receipt:i}),i)})),n}sendTransaction(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Promise.resolve(e).then((e=>Ps(e))),r=this.formatter.transaction(e);null==r.confirmations&&(r.confirmations=0);const n=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{const e=yield this.perform("sendTransaction",{signedTransaction:t});return this._wrapTransaction(r,e,n)}catch(e){throw e.transaction=r,e.transactionHash=r.hash,e}}))}_getTransactionRequest(e){return gp(this,void 0,void 0,(function*(){const t=yield e,r={};return["from","to"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?this._getAddress(e):null)))})),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?y.BigNumber.from(e):null)))})),["type"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>null!=e?e:null)))})),t.accessList&&(r.accessList=this.formatter.accessList(t.accessList)),["data"].forEach((e=>{null!=t[e]&&(r[e]=Promise.resolve(t[e]).then((e=>e?Ps(e):null)))})),this.formatter.transactionRequest(yield Aa(r))}))}_getFilter(e){return gp(this,void 0,void 0,(function*(){e=yield e;const t={};return null!=e.address&&(t.address=this._getAddress(e.address)),["blockHash","topics"].forEach((r=>{null!=e[r]&&(t[r]=e[r])})),["fromBlock","toBlock"].forEach((r=>{null!=e[r]&&(t[r]=this._getBlockTag(e[r]))})),this.formatter.filter(yield Aa(t))}))}_call(e,t,r){return gp(this,void 0,void 0,(function*(){r>=10&&yp.throwError("CCIP read exceeded maximum redirections",Cs.errors.SERVER_ERROR,{redirects:r,transaction:e});const n=e.to,o=yield this.perform("call",{transaction:e,blockTag:t});if(r>=0&&"latest"===t&&null!=n&&"0x556f1830"===o.substring(0,10)&&Bs(o)%32==4)try{const i=Ws(o,4),s=Ws(i,0,32);y.BigNumber.from(s).eq(n)||yp.throwError("CCIP Read sender did not match",Cs.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});const a=[],l=y.BigNumber.from(Ws(i,32,64)).toNumber(),c=y.BigNumber.from(Ws(i,l,l+32)).toNumber(),u=Ws(i,l+32);for(let t=0;t<c;t++){const r=Mp(u,32*t);null==r&&yp.throwError("CCIP Read contained corrupt URL string",Cs.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o}),a.push(r)}const d=Op(i,64);y.BigNumber.from(Ws(i,100,128)).isZero()||yp.throwError("CCIP Read callback selector included junk",Cs.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});const p=Ws(i,96,100),f=Op(i,128),h=yield this.ccipReadFetch(e,d,a);null==h&&yp.throwError("CCIP Read disabled or provided no URLs",Cs.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:e,data:o});const m={to:n,data:Ds([p,_p([h,f])])};return this._call(m,t,r+1)}catch(e){if(e.code===Cs.errors.SERVER_ERROR)throw e}try{return Ps(o)}catch(r){return yp.throwError("bad result from backend",Cs.errors.SERVER_ERROR,{method:"call",params:{transaction:e,blockTag:t},result:o,error:r})}}))}call(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const r=yield Aa({transaction:this._getTransactionRequest(e),blockTag:this._getBlockTag(t),ccipReadEnabled:Promise.resolve(e.ccipReadEnabled)});return this._call(r.transaction,r.blockTag,r.ccipReadEnabled?0:-1)}))}estimateGas(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Aa({transaction:this._getTransactionRequest(e)}),r=yield this.perform("estimateGas",t);try{return y.BigNumber.from(r)}catch(e){return yp.throwError("bad result from backend",Cs.errors.SERVER_ERROR,{method:"estimateGas",params:t,result:r,error:e})}}))}_getAddress(e){return gp(this,void 0,void 0,(function*(){"string"!=typeof(e=yield e)&&yp.throwArgumentError("invalid address or ENS name","name",e);const t=yield this.resolveName(e);return null==t&&yp.throwError("ENS name not configured",Cs.errors.UNSUPPORTED_OPERATION,{operation:`resolveName(${JSON.stringify(e)})`}),t}))}_getBlock(e,t){return gp(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;let r=-128;const n={includeTransactions:!!t};if(_s(e,32))n.blockHash=e;else try{n.blockTag=yield this._getBlockTag(e),_s(n.blockTag)&&(r=parseInt(n.blockTag.substring(2),16))}catch(t){yp.throwArgumentError("invalid block hash or block tag","blockHashOrBlockTag",e)}return td((()=>gp(this,void 0,void 0,(function*(){const e=yield this.perform("getBlock",n);if(null==e)return null!=n.blockHash&&null==this._emitted["b:"+n.blockHash]||null!=n.blockTag&&r>this._emitted.block?null:void 0;if(t){let t=null;for(let r=0;r<e.transactions.length;r++){const n=e.transactions[r];if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){null==t&&(t=yield this._getInternalBlockNumber(100+2*this.pollingInterval));let e=t-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}}const r=this.formatter.blockWithTransactions(e);return r.transactions=r.transactions.map((e=>this._wrapTransaction(e))),r}return this.formatter.block(e)}))),{oncePoll:this})}))}getBlock(e){return this._getBlock(e,!1)}getBlockWithTransactions(e){return this._getBlock(e,!0)}getTransaction(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return td((()=>gp(this,void 0,void 0,(function*(){const r=yield this.perform("getTransaction",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;const n=this.formatter.transactionResponse(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return this._wrapTransaction(n)}))),{oncePoll:this})}))}getTransactionReceipt(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork(),e=yield e;const t={transactionHash:this.formatter.hash(e,!0)};return td((()=>gp(this,void 0,void 0,(function*(){const r=yield this.perform("getTransactionReceipt",t);if(null==r)return null==this._emitted["t:"+e]?null:void 0;if(null==r.blockHash)return;const n=this.formatter.receipt(r);if(null==n.blockNumber)n.confirmations=0;else if(null==n.confirmations){let e=(yield this._getInternalBlockNumber(100+2*this.pollingInterval))-n.blockNumber+1;e<=0&&(e=1),n.confirmations=e}return n}))),{oncePoll:this})}))}getLogs(e){return gp(this,void 0,void 0,(function*(){yield this.getNetwork();const t=yield Aa({filter:this._getFilter(e)}),r=yield this.perform("getLogs",t);return r.forEach((e=>{null==e.removed&&(e.removed=!1)})),mp.arrayOf(this.formatter.filterLog.bind(this.formatter))(r)}))}getEtherPrice(){return gp(this,void 0,void 0,(function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})}))}_getBlockTag(e){return gp(this,void 0,void 0,(function*(){if("number"==typeof(e=yield e)&&e<0){e%1&&yp.throwArgumentError("invalid BlockTag","blockTag",e);let t=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return t+=e,t<0&&(t=0),this.formatter.blockTag(t)}return this.formatter.blockTag(e)}))}getResolver(e){return gp(this,void 0,void 0,(function*(){let t=e;for(;;){if(""===t||"."===t)return null;if("eth"!==e&&"eth"===t)return null;const r=yield this._getResolver(t,"getResolver");if(null!=r){const n=new Pp(this,r,e);return t===e||(yield n.supportsWildcard())?n:null}t=t.split(".").slice(1).join(".")}}))}_getResolver(e,t){return gp(this,void 0,void 0,(function*(){null==t&&(t="ENS");const r=yield this.getNetwork();r.ensAddress||yp.throwError("network does not support ENS",Cs.errors.UNSUPPORTED_OPERATION,{operation:t,network:r.name});try{const t=yield this.call({to:r.ensAddress,data:"0x0178b8bf"+Tl(e).substring(2)});return this.formatter.callAddress(t)}catch(e){}return null}))}resolveName(e){return gp(this,void 0,void 0,(function*(){e=yield e;try{return Promise.resolve(this.formatter.address(e))}catch(t){if(_s(e))throw t}"string"!=typeof e&&yp.throwArgumentError("invalid ENS name","name",e);const t=yield this.getResolver(e);return t?yield t.getAddress():null}))}lookupAddress(e){return gp(this,void 0,void 0,(function*(){e=yield e;const t=(e=this.formatter.address(e)).substring(2).toLowerCase()+".addr.reverse",r=yield this._getResolver(t,"lookupAddress");if(null==r)return null;const n=Mp(yield this.call({to:r,data:"0x691f3431"+Tl(t).substring(2)}),0);return(yield this.resolveName(n))!=e?null:n}))}getAvatar(e){return gp(this,void 0,void 0,(function*(){let t=null;if(_s(e)){const r=this.formatter.address(e).substring(2).toLowerCase()+".addr.reverse",n=yield this._getResolver(r,"getAvatar");if(!n)return null;t=new Pp(this,n,r);try{const e=yield t.getAvatar();if(e)return e.url}catch(e){if(e.code!==Cs.errors.CALL_EXCEPTION)throw e}try{const e=Mp(yield this.call({to:n,data:"0x691f3431"+Tl(r).substring(2)}),0);t=yield this.getResolver(e)}catch(e){if(e.code!==Cs.errors.CALL_EXCEPTION)throw e;return null}}else if(t=yield this.getResolver(e),!t)return null;const r=yield t.getAvatar();return null==r?null:r.url}))}perform(e,t){return yp.throwError(e+" not implemented",Cs.errors.NOT_IMPLEMENTED,{operation:e})}_startEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_stopEvent(e){this.polling=this._events.filter((e=>e.pollable())).length>0}_addEventListener(e,t,r){const n=new kp(xp(e),t,r);return this._events.push(n),this._startEvent(n),this}on(e,t){return this._addEventListener(e,t,!1)}once(e,t){return this._addEventListener(e,t,!0)}emit(e,...t){let r=!1,n=[],o=xp(e);return this._events=this._events.filter((e=>e.tag!==o||(setTimeout((()=>{e.listener.apply(this,t)}),0),r=!0,!e.once||(n.push(e),!1)))),n.forEach((e=>{this._stopEvent(e)})),r}listenerCount(e){if(!e)return this._events.length;let t=xp(e);return this._events.filter((e=>e.tag===t)).length}listeners(e){if(null==e)return this._events.map((e=>e.listener));let t=xp(e);return this._events.filter((e=>e.tag===t)).map((e=>e.listener))}off(e,t){if(null==t)return this.removeAllListeners(e);const r=[];let n=!1,o=xp(e);return this._events=this._events.filter((e=>e.tag!==o||e.listener!=t||(!!n||(n=!0,r.push(e),!1)))),r.forEach((e=>{this._stopEvent(e)})),this}removeAllListeners(e){let t=[];if(null==e)t=this._events,this._events=[];else{const r=xp(e);this._events=this._events.filter((e=>e.tag!==r||(t.push(e),!1)))}return t.forEach((e=>{this._stopEvent(e)})),this}}var Lp=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Up=new Cs("abstract-signer/5.7.0"),Vp=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],Zp=[Cs.errors.INSUFFICIENT_FUNDS,Cs.errors.NONCE_EXPIRED,Cs.errors.REPLACEMENT_UNDERPRICED];class Hp{constructor(){Up.checkAbstract(new.target,Hp),wa(this,"_isSigner",!0)}getBalance(e){return Lp(this,void 0,void 0,(function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),e)}))}getTransactionCount(e){return Lp(this,void 0,void 0,(function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),e)}))}estimateGas(e){return Lp(this,void 0,void 0,(function*(){this._checkProvider("estimateGas");const t=yield Aa(this.checkTransaction(e));return yield this.provider.estimateGas(t)}))}call(e,t){return Lp(this,void 0,void 0,(function*(){this._checkProvider("call");const r=yield Aa(this.checkTransaction(e));return yield this.provider.call(r,t)}))}sendTransaction(e){return Lp(this,void 0,void 0,(function*(){this._checkProvider("sendTransaction");const t=yield this.populateTransaction(e),r=yield this.signTransaction(t);return yield this.provider.sendTransaction(r)}))}getChainId(){return Lp(this,void 0,void 0,(function*(){this._checkProvider("getChainId");return(yield this.provider.getNetwork()).chainId}))}getGasPrice(){return Lp(this,void 0,void 0,(function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()}))}getFeeData(){return Lp(this,void 0,void 0,(function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()}))}resolveName(e){return Lp(this,void 0,void 0,(function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(e)}))}checkTransaction(e){for(const t in e)-1===Vp.indexOf(t)&&Up.throwArgumentError("invalid transaction key: "+t,"transaction",e);const t=ka(e);return null==t.from?t.from=this.getAddress():t.from=Promise.all([Promise.resolve(t.from),this.getAddress()]).then((t=>(t[0].toLowerCase()!==t[1].toLowerCase()&&Up.throwArgumentError("from address mismatch","transaction",e),t[0]))),t}populateTransaction(e){return Lp(this,void 0,void 0,(function*(){const t=yield Aa(this.checkTransaction(e));null!=t.to&&(t.to=Promise.resolve(t.to).then((e=>Lp(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.resolveName(e);return null==t&&Up.throwArgumentError("provided ENS name resolves to null","tx.to",e),t})))),t.to.catch((e=>{})));const r=null!=t.maxFeePerGas||null!=t.maxPriorityFeePerGas;if(null==t.gasPrice||2!==t.type&&!r?0!==t.type&&1!==t.type||!r||Up.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",e):Up.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",e),2!==t.type&&null!=t.type||null==t.maxFeePerGas||null==t.maxPriorityFeePerGas)if(0===t.type||1===t.type)null==t.gasPrice&&(t.gasPrice=this.getGasPrice());else{const e=yield this.getFeeData();if(null==t.type)if(null!=e.maxFeePerGas&&null!=e.maxPriorityFeePerGas)if(t.type=2,null!=t.gasPrice){const e=t.gasPrice;delete t.gasPrice,t.maxFeePerGas=e,t.maxPriorityFeePerGas=e}else null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas);else null!=e.gasPrice?(r&&Up.throwError("network does not support EIP-1559",Cs.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),null==t.gasPrice&&(t.gasPrice=e.gasPrice),t.type=0):Up.throwError("failed to get consistent fee data",Cs.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"});else 2===t.type&&(null==t.maxFeePerGas&&(t.maxFeePerGas=e.maxFeePerGas),null==t.maxPriorityFeePerGas&&(t.maxPriorityFeePerGas=e.maxPriorityFeePerGas))}else t.type=2;return null==t.nonce&&(t.nonce=this.getTransactionCount("pending")),null==t.gasLimit&&(t.gasLimit=this.estimateGas(t).catch((e=>{if(Zp.indexOf(e.code)>=0)throw e;return Up.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",Cs.errors.UNPREDICTABLE_GAS_LIMIT,{error:e,tx:t})}))),null==t.chainId?t.chainId=this.getChainId():t.chainId=Promise.all([Promise.resolve(t.chainId),this.getChainId()]).then((t=>(0!==t[1]&&t[0]!==t[1]&&Up.throwArgumentError("chainId address mismatch","transaction",e),t[0]))),yield Aa(t)}))}_checkProvider(e){this.provider||Up.throwError("missing provider",Cs.errors.UNSUPPORTED_OPERATION,{operation:e||"_checkProvider"})}static isSigner(e){return!(!e||!e._isSigner)}}var zp=function(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{l(n.next(e))}catch(e){i(e)}}function a(e){try{l(n.throw(e))}catch(e){i(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}l((n=n.apply(e,t||[])).next())}))};const Yp=new Cs(dd),Gp=["call","estimateGas"];function Xp(e,t){if(null==e)return null;if("string"==typeof e.message&&e.message.match("reverted")){const r=_s(e.data)?e.data:null;if(!t||r)return{message:e.message,data:r}}if("object"==typeof e){for(const r in e){const n=Xp(e[r],t);if(n)return n}return null}if("string"==typeof e)try{return Xp(JSON.parse(e),t)}catch(e){}return null}function Jp(e,t,r){const n=r.transaction||r.signedTransaction;if("call"===e){const e=Xp(t,!0);if(e)return e.data;Yp.throwError("missing revert data in call exception; Transaction reverted without a reason string",Cs.errors.CALL_EXCEPTION,{data:"0x",transaction:n,error:t})}if("estimateGas"===e){let r=Xp(t.body,!1);null==r&&(r=Xp(t,!1)),r&&Yp.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",Cs.errors.UNPREDICTABLE_GAS_LIMIT,{reason:r.message,method:e,transaction:n,error:t})}let o=t.message;throw t.code===Cs.errors.SERVER_ERROR&&t.error&&"string"==typeof t.error.message?o=t.error.message:"string"==typeof t.body?o=t.body:"string"==typeof t.responseText&&(o=t.responseText),o=(o||"").toLowerCase(),o.match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&Yp.throwError("insufficient funds for intrinsic transaction cost",Cs.errors.INSUFFICIENT_FUNDS,{error:t,method:e,transaction:n}),o.match(/nonce (is )?too low/i)&&Yp.throwError("nonce has already been used",Cs.errors.NONCE_EXPIRED,{error:t,method:e,transaction:n}),o.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&Yp.throwError("replacement fee too low",Cs.errors.REPLACEMENT_UNDERPRICED,{error:t,method:e,transaction:n}),o.match(/only replay-protected/i)&&Yp.throwError("legacy pre-eip-155 transactions not supported",Cs.errors.UNSUPPORTED_OPERATION,{error:t,method:e,transaction:n}),Gp.indexOf(e)>=0&&o.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&Yp.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",Cs.errors.UNPREDICTABLE_GAS_LIMIT,{error:t,method:e,transaction:n}),t}function qp(e){return new Promise((function(t){setTimeout(t,e)}))}function Qp(e){if(e.error){const t=new Error(e.error.message);throw t.code=e.error.code,t.data=e.error.data,t}return e.result}function Kp(e){return e?e.toLowerCase():e}const $p={};class ef extends Hp{constructor(e,t,r){if(super(),e!==$p)throw new Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");wa(this,"provider",t),null==r&&(r=0),"string"==typeof r?(wa(this,"_address",this.provider.formatter.address(r)),wa(this,"_index",null)):"number"==typeof r?(wa(this,"_index",r),wa(this,"_address",null)):Yp.throwArgumentError("invalid address or index","addressOrIndex",r)}connect(e){return Yp.throwError("cannot alter JSON-RPC Signer connection",Cs.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new tf($p,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then((e=>(e.length<=this._index&&Yp.throwError("unknown account #"+this._index,Cs.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(e[this._index]))))}sendUncheckedTransaction(e){e=ka(e);const t=this.getAddress().then((e=>(e&&(e=e.toLowerCase()),e)));if(null==e.gasLimit){const r=ka(e);r.from=t,e.gasLimit=this.provider.estimateGas(r)}return null!=e.to&&(e.to=Promise.resolve(e.to).then((e=>zp(this,void 0,void 0,(function*(){if(null==e)return null;const t=yield this.provider.resolveName(e);return null==t&&Yp.throwArgumentError("provided ENS name resolves to null","tx.to",e),t}))))),Aa({tx:Aa(e),sender:t}).then((({tx:t,sender:r})=>{null!=t.from?t.from.toLowerCase()!==r&&Yp.throwArgumentError("from address mismatch","transaction",e):t.from=r;const n=this.provider.constructor.hexlifyTransaction(t,{from:!0});return this.provider.send("eth_sendTransaction",[n]).then((e=>e),(e=>("string"==typeof e.message&&e.message.match(/user denied/i)&&Yp.throwError("user rejected transaction",Cs.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:t}),Jp("sendTransaction",e,n))))}))}signTransaction(e){return Yp.throwError("signing transactions is unsupported",Cs.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(e){return zp(this,void 0,void 0,(function*(){const t=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),r=yield this.sendUncheckedTransaction(e);try{return yield td((()=>zp(this,void 0,void 0,(function*(){const e=yield this.provider.getTransaction(r);if(null!==e)return this.provider._wrapTransaction(e,r,t)}))),{oncePoll:this.provider})}catch(e){throw e.transactionHash=r,e}}))}signMessage(e){return zp(this,void 0,void 0,(function*(){const t="string"==typeof e?rl(e):e,r=yield this.getAddress();try{return yield this.provider.send("personal_sign",[Ps(t),r.toLowerCase()])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&Yp.throwError("user rejected signing",Cs.errors.ACTION_REJECTED,{action:"signMessage",from:r,messageData:e}),t}}))}_legacySignMessage(e){return zp(this,void 0,void 0,(function*(){const t="string"==typeof e?rl(e):e,r=yield this.getAddress();try{return yield this.provider.send("eth_sign",[r.toLowerCase(),Ps(t)])}catch(t){throw"string"==typeof t.message&&t.message.match(/user denied/i)&&Yp.throwError("user rejected signing",Cs.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:r,messageData:e}),t}}))}_signTypedData(e,t,r){return zp(this,void 0,void 0,(function*(){const n=yield Hl.resolveNames(e,t,r,(e=>this.provider.resolveName(e))),o=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[o.toLowerCase(),JSON.stringify(Hl.getPayload(n.domain,t,n.value))])}catch(e){throw"string"==typeof e.message&&e.message.match(/user denied/i)&&Yp.throwError("user rejected signing",Cs.errors.ACTION_REJECTED,{action:"_signTypedData",from:o,messageData:{domain:n.domain,types:t,value:n.value}}),e}}))}unlock(e){return zp(this,void 0,void 0,(function*(){const t=this.provider,r=yield this.getAddress();return t.send("personal_unlockAccount",[r.toLowerCase(),e,null])}))}}class tf extends ef{sendTransaction(e){return this.sendUncheckedTransaction(e).then((e=>({hash:e,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:t=>this.provider.waitForTransaction(e,t)})))}}const rf={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0};class nf extends Dp{constructor(e,t){let r=t;null==r&&(r=new Promise(((e,t)=>{setTimeout((()=>{this.detectNetwork().then((t=>{e(t)}),(e=>{t(e)}))}),0)}))),super(r),e||(e=Ea(this.constructor,"defaultUrl")()),wa(this,"connection","string"==typeof e?Object.freeze({url:e}):Object.freeze(ka(e))),this._nextId=42}get _cache(){return null==this._eventLoopCache&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout((()=>{this._cache.detectNetwork=null}),0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return zp(this,void 0,void 0,(function*(){yield qp(0);let e=null;try{e=yield this.send("eth_chainId",[])}catch(t){try{e=yield this.send("net_version",[])}catch(e){}}if(null!=e){const t=Ea(this.constructor,"getNetwork");try{return t(y.BigNumber.from(e).toNumber())}catch(t){return Yp.throwError("could not detect network",Cs.errors.NETWORK_ERROR,{chainId:e,event:"invalidNetwork",serverError:t})}}return Yp.throwError("could not detect network",Cs.errors.NETWORK_ERROR,{event:"noNetwork"})}))}getSigner(e){return new ef($p,this,e)}getUncheckedSigner(e){return this.getSigner(e).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then((e=>e.map((e=>this.formatter.address(e)))))}send(e,t){const r={method:e,params:t,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:Ta(r),provider:this});const n=["eth_chainId","eth_blockNumber"].indexOf(e)>=0;if(n&&this._cache[e])return this._cache[e];const o=ed(this.connection,JSON.stringify(r),Qp).then((e=>(this.emit("debug",{action:"response",request:r,response:e,provider:this}),e)),(e=>{throw this.emit("debug",{action:"response",error:e,request:r,provider:this}),e}));return n&&(this._cache[e]=o,setTimeout((()=>{this._cache[e]=null}),0)),o}prepareRequest(e,t){switch(e){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[Kp(t.address),t.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[Kp(t.address),t.blockTag]];case"getCode":return["eth_getCode",[Kp(t.address),t.blockTag]];case"getStorageAt":return["eth_getStorageAt",[Kp(t.address),Us(t.position,32),t.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[t.signedTransaction]];case"getBlock":return t.blockTag?["eth_getBlockByNumber",[t.blockTag,!!t.includeTransactions]]:t.blockHash?["eth_getBlockByHash",[t.blockHash,!!t.includeTransactions]]:null;case"getTransaction":return["eth_getTransactionByHash",[t.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[t.transactionHash]];case"call":return["eth_call",[Ea(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0}),t.blockTag]];case"estimateGas":return["eth_estimateGas",[Ea(this.constructor,"hexlifyTransaction")(t.transaction,{from:!0})]];case"getLogs":return t.filter&&null!=t.filter.address&&(t.filter.address=Kp(t.filter.address)),["eth_getLogs",[t.filter]]}return null}perform(e,t){return zp(this,void 0,void 0,(function*(){if("call"===e||"estimateGas"===e){const e=t.transaction;if(e&&null!=e.type&&y.BigNumber.from(e.type).isZero()&&null==e.maxFeePerGas&&null==e.maxPriorityFeePerGas){const r=yield this.getFeeData();null==r.maxFeePerGas&&null==r.maxPriorityFeePerGas&&((t=ka(t)).transaction=ka(e),delete t.transaction.type)}}const r=this.prepareRequest(e,t);null==r&&Yp.throwError(e+" not implemented",Cs.errors.NOT_IMPLEMENTED,{operation:e});try{return yield this.send(r[0],r[1])}catch(r){return Jp(e,r,t)}}))}_startEvent(e){"pending"===e.tag&&this._startPending(),super._startEvent(e)}_startPending(){if(null!=this._pendingFilter)return;const e=this,t=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=t,t.then((function(r){return function n(){e.send("eth_getFilterChanges",[r]).then((function(r){if(e._pendingFilter!=t)return null;let n=Promise.resolve();return r.forEach((function(t){e._emitted["t:"+t.toLowerCase()]="pending",n=n.then((function(){return e.getTransaction(t).then((function(t){return e.emit("pending",t),null}))}))})),n.then((function(){return qp(1e3)}))})).then((function(){if(e._pendingFilter==t)return setTimeout((function(){n()}),0),null;e.send("eth_uninstallFilter",[r])})).catch((e=>{}))}(),r})).catch((e=>{}))}_stopEvent(e){"pending"===e.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),super._stopEvent(e)}static hexlifyTransaction(e,t){const r=ka(rf);if(t)for(const e in t)t[e]&&(r[e]=!0);var n,o;o=r,(n=e)&&"object"==typeof n||xa.throwArgumentError("invalid object","object",n),Object.keys(n).forEach((e=>{o[e]||xa.throwArgumentError("invalid object key - "+e,"transaction:"+e,n)}));const i={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach((function(t){if(null==e[t])return;const r=Ls(y.BigNumber.from(e[t]));"gasLimit"===t&&(t="gas"),i[t]=r})),["from","to","data"].forEach((function(t){null!=e[t]&&(i[t]=Ps(e[t]))})),e.accessList&&(i.accessList=lp(e.accessList)),i}}function of(e){return Number.parseInt(e,16)}new Cs(dd);class sf extends h.Connector{constructor(e,t){super(e),this.customProvider=t,t.on("connect",(({chainId:e})=>{this.actions.update({chainId:of(e)})})).on("disconnect",(e=>{var t;null===(t=this.onError)||void 0===t||t.call(this,e),this.actions.resetState()})).on("chainChanged",(e=>{this.actions.update({chainId:of(e)})})).on("accountsChanged",(e=>{this.actions.update({accounts:e})}))}activate(){return ma(this,void 0,void 0,(function*(){this.actions.startActivation();const e=this.customProvider;try{const[{chainId:t},r]=yield Promise.all([e.getNetwork(),e.listAccounts()]);this.actions.update({chainId:t,accounts:r})}catch(e){throw this.actions.resetState(),e}}))}}function af([e,t]){return[e,t]}var lf;function cf(){return cf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},cf.apply(this,arguments)}var uf,df;function pf(){return pf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},pf.apply(this,arguments)}var ff;!function(e){e.INTEGRATOR="integrator",e.METAMASK="metamask",e.WALLET_CONNECT="walletConnect"}(ff||(ff={}));const hf={[ff.METAMASK]:{name:"MetaMask",type:ff.METAMASK,icon:function(e){return S.createElement("svg",cf({height:355,viewBox:"0 0 397 355",width:397,xmlns:"http://www.w3.org/2000/svg"},e),lf||(lf=S.createElement("g",{fill:"none",fillRule:"evenodd",transform:"translate(-1 -1)"},S.createElement("path",{d:"m114.622644 327.195472 52.004717 13.810198v-18.05949l4.245283-4.249292h29.716982v21.246459 14.872523h-31.839624l-39.268868-16.997169z",fill:"#cdbdb2"}),S.createElement("path",{d:"m199.528305 327.195472 50.943397 13.810198v-18.05949l4.245283-4.249292h29.716981v21.246459 14.872523h-31.839623l-39.268868-16.997169z",fill:"#cdbdb2",transform:"matrix(-1 0 0 1 483.96227 0)"}),S.createElement("path",{d:"m170.872644 287.889523-4.245283 35.056657 5.306604-4.249292h55.18868l6.367925 4.249292-4.245284-35.056657-8.490565-5.311615-42.452832 1.062323z",fill:"#393939"}),S.createElement("path",{d:"m142.216984 50.9915022 25.471698 59.4900858 11.674528 173.158643h41.391511l12.735849-173.158643 23.349056-59.4900858z",fill:"#f89c35"}),S.createElement("path",{d:"m30.7783023 181.657226-29.71698153 86.048161 74.29245393-4.249293h47.7594343v-37.181303l-2.122641-76.487253-10.613208 8.498583z",fill:"#f89d35"}),S.createElement("path",{d:"m87.0283032 191.218134 87.0283028 2.124646-9.551886 44.617563-41.391511-10.623229z",fill:"#d87c30"}),S.createElement("path",{d:"m87.0283032 192.280457 36.0849058 33.994334v33.994334z",fill:"#ea8d3a"}),S.createElement("path",{d:"m123.113209 227.337114 42.452831 10.623229 13.79717 45.679888-9.551886 5.311615-46.698115-27.620398z",fill:"#f89d35"}),S.createElement("path",{d:"m123.113209 261.331448-8.490565 65.864024 56.25-39.305949z",fill:"#eb8f35"}),S.createElement("path",{d:"m174.056606 193.34278 5.306604 90.297451-15.919812-46.211049z",fill:"#ea8e3a"}),S.createElement("path",{d:"m74.2924539 262.393771 48.8207551-1.062323-8.490565 65.864024z",fill:"#d87c30"}),S.createElement("path",{d:"m24.4103777 355.878193 90.2122663-28.682721-40.3301901-64.801701-73.23113313 5.311616z",fill:"#eb8f35"}),S.createElement("path",{d:"m167.688682 110.481588-45.636793 38.243627-35.0235858 42.492919 87.0283028 3.186969z",fill:"#e8821e"}),S.createElement("path",{d:"m114.622644 327.195472 56.25-39.305949-4.245283 33.994334v19.121813l-38.207548-7.43626z",fill:"#dfcec3"}),S.createElement("path",{d:"m229.245286 327.195472 55.18868-39.305949-4.245283 33.994334v19.121813l-38.207548-7.43626z",fill:"#dfcec3",transform:"matrix(-1 0 0 1 513.679252 0)"}),S.createElement("path",{d:"m132.665096 212.464593-11.674528 24.433427 41.39151-10.623229z",fill:"#393939",transform:"matrix(-1 0 0 1 283.372646 0)"}),S.createElement("path",{d:"m23.349057 1.06232296 144.339625 109.41926504-24.410378-59.4900858z",fill:"#e88f35"}),S.createElement("path",{d:"m23.349057 1.06232296-19.10377392 58.42776294 10.61320772 63.7393781-7.42924541 4.249292 10.61320771 9.560906-8.49056617 7.436261 11.67452847 10.623229-7.4292454 6.373938 16.9811323 21.246459 79.5990577-24.433428c38.915096-31.161473 58.018869-47.096318 57.311322-47.804533-.707548-.708215-48.820756-37.1813036-144.339625-109.41926504z",fill:"#8e5a30"}),S.createElement("g",{transform:"matrix(-1 0 0 1 399.056611 0)"},S.createElement("path",{d:"m30.7783023 181.657226-29.71698153 86.048161 74.29245393-4.249293h47.7594343v-37.181303l-2.122641-76.487253-10.613208 8.498583z",fill:"#f89d35"}),S.createElement("path",{d:"m87.0283032 191.218134 87.0283028 2.124646-9.551886 44.617563-41.391511-10.623229z",fill:"#d87c30"}),S.createElement("path",{d:"m87.0283032 192.280457 36.0849058 33.994334v33.994334z",fill:"#ea8d3a"}),S.createElement("path",{d:"m123.113209 227.337114 42.452831 10.623229 13.79717 45.679888-9.551886 5.311615-46.698115-27.620398z",fill:"#f89d35"}),S.createElement("path",{d:"m123.113209 261.331448-8.490565 65.864024 55.18868-38.243626z",fill:"#eb8f35"}),S.createElement("path",{d:"m174.056606 193.34278 5.306604 90.297451-15.919812-46.211049z",fill:"#ea8e3a"}),S.createElement("path",{d:"m74.2924539 262.393771 48.8207551-1.062323-8.490565 65.864024z",fill:"#d87c30"}),S.createElement("path",{d:"m24.4103777 355.878193 90.2122663-28.682721-40.3301901-64.801701-73.23113313 5.311616z",fill:"#eb8f35"}),S.createElement("path",{d:"m167.688682 110.481588-45.636793 38.243627-35.0235858 42.492919 87.0283028 3.186969z",fill:"#e8821e"}),S.createElement("path",{d:"m132.665096 212.464593-11.674528 24.433427 41.39151-10.623229z",fill:"#393939",transform:"matrix(-1 0 0 1 283.372646 0)"}),S.createElement("path",{d:"m23.349057 1.06232296 144.339625 109.41926504-24.410378-59.4900858z",fill:"#e88f35"}),S.createElement("path",{d:"m23.349057 1.06232296-19.10377392 58.42776294 10.61320772 63.7393781-7.42924541 4.249292 10.61320771 9.560906-8.49056617 7.436261 11.67452847 10.623229-7.4292454 6.373938 16.9811323 21.246459 79.5990577-24.433428c38.915096-31.161473 58.018869-47.096318 57.311322-47.804533-.707548-.708215-48.820756-37.1813036-144.339625-109.41926504z",fill:"#8e5a30"})))))},link:"https://metamask.io"},[ff.WALLET_CONNECT]:{name:"WalletConnect",type:ff.WALLET_CONNECT,icon:function(e){return S.createElement("svg",pf({height:512,viewBox:"0 0 512 512",width:512,xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),uf||(uf=S.createElement("radialGradient",{id:"a",cx:"0%",cy:"50%",r:"100%"},S.createElement("stop",{offset:0,stopColor:"#5d9df6"}),S.createElement("stop",{offset:1,stopColor:"#006fff"}))),df||(df=S.createElement("g",{fill:"none",fillRule:"evenodd"},S.createElement("path",{d:"m256 0c141.384896 0 256 114.615104 256 256s-114.615104 256-256 256-256-114.615104-256-256 114.615104-256 256-256z",fill:"url(#a)"}),S.createElement("path",{d:"m64.6917558 37.7088298c51.5328072-50.2784397 135.0839942-50.2784397 186.6167992 0l6.202057 6.0510906c2.57664 2.5139218 2.57664 6.5897948 0 9.1037177l-21.215998 20.6995759c-1.288321 1.2569619-3.3771 1.2569619-4.665421 0l-8.534766-8.3270205c-35.950573-35.0754962-94.237969-35.0754962-130.188544 0l-9.1400282 8.9175519c-1.2883217 1.2569609-3.3771016 1.2569609-4.6654208 0l-21.2159973-20.6995759c-2.5766403-2.5139229-2.5766403-6.5897958 0-9.1037177zm230.4934852 42.8089117 18.882279 18.4227262c2.576627 2.5139103 2.576642 6.5897593.000032 9.1036863l-85.141498 83.070358c-2.576623 2.513941-6.754182 2.513969-9.33084.000066-.00001-.00001-.000023-.000023-.000033-.000034l-60.428256-58.957451c-.64416-.628481-1.68855-.628481-2.33271 0-.000004.000004-.000008.000007-.000012.000011l-60.4269683 58.957408c-2.5766141 2.513947-6.7541746 2.51399-9.3308408.000092-.0000151-.000014-.0000309-.000029-.0000467-.000046l-85.14386774-83.071463c-2.57663928-2.513921-2.57663928-6.589795 0-9.1037163l18.88231264-18.4226955c2.5766393-2.5139222 6.7541993-2.5139222 9.3308397 0l60.4291347 58.9582758c.6441608.62848 1.6885495.62848 2.3327103 0 .0000095-.000009.0000182-.000018.0000277-.000025l60.4261065-58.9582508c2.576581-2.51398 6.754142-2.5140743 9.33084-.0002103.000037.0000354.000072.0000709.000107.0001063l60.429056 58.9583548c.644159.628479 1.688549.628479 2.332709 0l60.428079-58.9571925c2.57664-2.5139231 6.754199-2.5139231 9.330839 0z",fill:"#fff",fillRule:"nonzero",transform:"translate(98 160)"}))))}}},mf={};function gf({provider:e,jsonRpcUrlMap:t,defaultChainId:r}){const o=console.error,i=n.useMemo((()=>function(e,t){if(t){if(nf.isProvider(t))return af(u.initializeConnector((e=>new sf(e,t))));if(nf.isProvider(t.provider))throw new Error("Eip1193Bridge is experimental: pass your ethers Provider directly");return af(u.initializeConnector((r=>new d.EIP1193({actions:r,provider:t,onError:e}))))}}(o,e)),[o,e]),s=n.useMemo((()=>function(e){return af(u.initializeConnector((t=>new f.MetaMask({actions:t,onError:e}))))}(o)),[o]),a=n.useMemo((()=>t?Object.assign(Object.assign({},sa),t):sa),[t]),l=n.useMemo((()=>function(e,t,r,n){return af(u.initializeConnector((o=>new p.WalletConnect({actions:o,options:{rpcMap:t,projectId:"59e050d1f27ed617e65bb9637c9498d6",chains:r?[r]:[],showQrModal:e},onError:n,defaultChainId:r}))))}(!0,a,r,o)),[a,r,o]);return i&&(mf[ff.INTEGRATOR]=i),mf[ff.METAMASK]=s,mf[ff.WALLET_CONNECT]=l,Object.values(mf)}const yf={colorMode:"dark",slippage:null,ddl:20};var bf=(e=yf,t)=>{switch(t.type){case"SET_COLOR_MODE":return Object.assign(Object.assign({},e),{colorMode:t.payload});case"SET_SLIPPAGE":return Object.assign(Object.assign({},e),{slippage:t.payload});case"SET_TRANSACTION_DDL":return Object.assign(Object.assign({},e),{ddl:t.payload});default:return e}};const vf={chainId:ia.MAINNET,latestBlockNumber:0};var xf=(e=vf,t)=>{switch(t.type){case"SET_CHAIN_ID":return Object.assign(Object.assign({},e),{chainId:t.payload});case"SET_BLOCK_NUMBER":return Object.assign(Object.assign({},e),{latestBlockNumber:t.payload});default:return e}};const wf={tokenList:[],popularTokenList:[],ethBalance:{},accountBalances:{},balanceLoadings:{},slippageWithTokens:[]};var Ef,Af=(e=wf,t)=>{switch(t.type){case"SET_TOKEN_LIST":return Object.assign(Object.assign({},e),{tokenList:t.payload});case"SET_POPULAR_TOKEN_LIST":return Object.assign(Object.assign({},e),{popularTokenList:t.payload});case"SET_SLIPPAGE_WITH_TOKENS":return Object.assign(Object.assign({},e),{slippageWithTokens:t.payload});case"SET_ETH_BALANCE":return Object.assign(Object.assign({},e),{ethBalance:Object.assign(Object.assign({},e.ethBalance),t.payload)});case"SET_DEFAULT_FROM_TOKEN":return Object.assign(Object.assign({},e),{defaultFromToken:t.payload});case"SET_DEFAULT_TO_TOKEN":return Object.assign(Object.assign({},e),{defaultToToken:t.payload});case"SET_ACCOUNT_BALANCES":return Object.assign(Object.assign({},e),{accountBalances:Object.assign(Object.assign({},e.accountBalances),t.payload)});case"SET_ACCOUNT_ALLOWANCES":const r=Object.assign({},e.accountBalances);return Object.keys(r).map((e=>{r[e].tokenAllowances=t.payload})),Object.assign(Object.assign({},e),{accountBalances:r});case"SET_BALANCE_LOADINGS":return Object.assign(Object.assign({},e),{balanceLoadings:Object.assign(Object.assign({},e.balanceLoadings),t.payload)});default:return e}};!function(e){e.Initial="Initial",e.Pending="Pending",e.ApproveSuccess="ApproveSuccess",e.TxSuccess="TxSuccess",e.Failed="Failed"}(Ef||(Ef={}));const kf={height:void 0,width:void 0,apikey:"",feeRate:0,rebateTo:"",isReverseRouting:!1,contractStatus:Ef.Initial,autoConnectLoading:void 0};var Cf=(e=kf,t)=>{switch(t.type){case"SET_GLOBAL_PROPS":return Object.assign(Object.assign({},e),t.payload);case"SET_AUTO_CONNECT_LOADING":return Object.assign(Object.assign({},e),{autoConnectLoading:t.payload});default:return e}};const Rf={settings:yf,wallet:vf,globals:kf,token:wf},Sf=g.combineReducers({settings:bf,wallet:xf,token:Af,globals:Cf}),Tf=m.configureStore({reducer:Sf,middleware:e=>e({serializableCheck:{ignoredActions:["SET_ACCOUNT_BALANCES","SET_ETH_BALANCE"],ignoredPaths:["token.accountBalances","token.ethBalance"]}}),preloadedState:Rf}),Nf=e=>(null!=e?e:Tf.getState()).wallet.chainId,Mf=e=>(null!=e?e:Tf.getState()).wallet.latestBlockNumber;function Of(){const{chainId:e}=u.useWeb3React(),t=l.useSelector(Nf);return n.useMemo((()=>e||t||1),[e,t])}var If=[{chainId:1,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ether",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/prKmKP8yDTuPMHTCZ_DcxG8BqsuHNO8w5KDmJWmPodg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vOUVaWU1ER2ZVN3g2N3ZBZThqWkUxZzA0RExUaFhaV0JIb09wZFhpeXhHRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNNeVgyTnZhVzV0WVhKclpYUmpZWEJmWTI5dFgzTjBZWFJwWTE5cGJXZGZZMjlwYm5OZk5qUjROalJmTVRBeU4xOHhNekkyTjJGbE5EY3dMbkJ1WncucG5n.webp"},{chainId:1,address:"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48",name:"USD Coin",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/sQ5dF3FkjjQUsmfqFFE5cKq-cthh4u0wUooBE5Epf-k/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTDlEVElLa2dONG5mRkNTSF9GMUdXU3JiZkJDa2JZRTkwbmFDS0dIWnRsby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMM1Z6WkdOZlpXVTFNbUV4WldReVlpOTFjMlJqWDJWbE5USmhNV1ZrTW1JdWNHNW4ucG5n.webp"},{chainId:1,address:"0x4Fabb145d64652a948d72533023f6E7A623C7C53",name:"Binance USD",decimals:18,symbol:"BUSD",logoURI:"https://cmp.dodoex.io/xZmadzpVOnpuq2jNG_5EGKeqMET0LU_gmfnp4VxkcxI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vSHQwWXZKMGNnU0lGTFM0aHExTV9jOXVITV9fMHpXaHBKSGVOQU5neTBuby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMkoxYzJSZk4ySTJOalJpWWpReVpDOWlkWE5rWHpkaU5qWTBZbUkwTW1RdWNHNW4ucG5n.webp"},{chainId:1,address:"0x6b175474e89094c44da98b954eedeac495271d0f",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/h2lbKBfBJ2LNSTNCuwjsBkshT4eXzDDmAV0lhWS0llA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUnVJNWt2eHBwalI4TTZsenFZZVAyTTB4eVFMUGJ0S1hONDdWVTN1dUszZy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmWmpBNU5qUmpPVFUxT1M1d2JtYy5wbmc.webp"},{chainId:1,address:"0x43dfc4159d86f3a37a5a4b3d4580b888ad7d4ddd",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/PGIGjN4ix9pInoESO_mCmajbMpygApWZyGKaE6vyJFk/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8veFJDQ0hnQXBuaENRTFZNUXAwdTdwd0pSQzIxRHJ4cFY0b2Z0bndaYnRmMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk5UaGxZelEyTlRFelpTOUVUMFJQWHpVNFpXTTBOalV4TTJVdWMzWm4uc3Zn.webp"},{chainId:1,address:"0xdac17f958d2ee523a2206206994597c13d831ec7",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:1,address:"0x2260fac5e5542a773aa44fbcfedf7c193bc2c599",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:1,address:"0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",name:"Wrapped Ether",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/mI69kq-S-tNT1W57qYizPd5r2WNFzpAq5y6NhOcrTkY/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vVEZhSVNLVVZIWThLTVhyTkVmZDRXRUJmMGJoSHRweHY3Q1hDT0dKbGY2by9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmT0dVeFpEaG1PVEEyWlM1d2JtYy5wbmc.webp"},{chainId:5,symbol:"USDC",address:"0xC4106029d03c33731Ca01Ba59b5A6368c660E596",name:"USDC",decimals:6,logoURI:""},{chainId:5,symbol:"USDT",address:"0xed8a325D87D3b6edED04FB992A1482231647EE5e",name:"USDT Token",decimals:6,logoURI:""},{chainId:5,symbol:"WETH",address:"0xB4FBF271143F4FBf7B91A5ded31805e42b2208d6",name:"Wrapped Ether",decimals:18,logoURI:""},{chainId:5,symbol:"ETH",address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ether",decimals:18,logoURI:""},{chainId:56,address:"0xe9e7cea3dedca5984780bafc599bd69add087d56",name:"BUSD Token",decimals:18,symbol:"BUSD",logoURI:"https://cmp.dodoex.io/BvxyffA5gsLB4bLmlOVkfu7AVami78-VcW_6_i8I6kc/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vbC1Sa25meFB3ZXlCOGVYSWJ2b04wdHczLTlzckZOckxfRHdTTnRLSHVRRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDJOa2JsOXRaV1JwWVY5a2IyUnZaWGhmYVc5ZlluVnpaRjgyTXpsbFlqZzNZV0V4WDJKMWMyUmZOak01WldJNE4yRmhNVjlsT1dVMVlXRTBOemxtTG5OMlp3LnN2Zw.webp"},{chainId:56,address:"0x55d398326f99059ff775485246999027b3197955",name:"Tether USD",decimals:18,symbol:"USDT",logoURI:"https://cmp.dodoex.io/QOl7CvP_WSmTUOMthbxQsNKjDj0s5kSjup69dW_-UeA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTjdQU3RXV2ZGaGNTVzM1QlE2TEJIaF9keVROUEJqa1RLTXRwTll5cEhSWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDJOa2JsOXRaV1JwWVY5a2IyUnZaWGhmYVc5ZmRYTmtkRjh4TlRZME1XWmpaRFF3WDNWelpIUmZNVFUyTkRGbVkyUTBNRjlqWmpJMVpUYzVZVE5qTG5OMlp3LnN2Zw.webp"},{chainId:56,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"BNB",decimals:18,symbol:"BNB",logoURI:"https://cmp.dodoex.io/BWNSMMqu68bSFJsr9vsiCV09IonH3yuAkR9gQxaipBw/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZDhvazF4akd3bU9GUXUtMVdzNEVRLVBNRnJYMW9DLXlmYTc3OGJUUkx0US9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpPUWw5alpEUTVNalE0TXpJMkwwSk9RbDlqWkRRNU1qUTRNekkyTG5CdVp3LnBuZw.webp"},{chainId:56,address:"0x7130d2a12b9bcbfae4f2634d864a1ee1ce3ead9c",name:"BTCB Token",decimals:18,symbol:"BTCB",logoURI:"https://cmp.dodoex.io/fZG0z_RZ1U73_LuuC3RGrrZvNR-bgrCUjkwvaro-PCY/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZ1NXN0RuYWNkMnc2YWxSQnFmcENqTHNDZWJhc2VtQTc0dDJlTEdDZjhfNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmWmpJNVlXRmpZamxoTVM1d2JtYy5wbmc.webp"},{chainId:56,address:"0x1af3f329e8be154074d8769d1ffa4ee058b1dbc3",name:"Dai Token",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/bhz9Vtma8hPb_-GnhwqQkhfTQ5PwKcR1Qbzn7aBKlfs/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZW04OHB4YXNDdEg0Nl9BcjhVandzZWR2SFBFUUtjVWVkc0FmV2lvenB2Yy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmWVRoaFptSmxaRFppWkM1d2JtYy5wbmc.webp"},{chainId:56,address:"0x67ee3Cb086F8a16f34beE3ca72FAD36F7Db929e2",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/PGIGjN4ix9pInoESO_mCmajbMpygApWZyGKaE6vyJFk/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8veFJDQ0hnQXBuaENRTFZNUXAwdTdwd0pSQzIxRHJ4cFY0b2Z0bndaYnRmMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk5UaGxZelEyTlRFelpTOUVUMFJQWHpVNFpXTTBOalV4TTJVdWMzWm4uc3Zn.webp"},{chainId:56,address:"0x2170ed0880ac9a755fd29b2688956bd959f933f8",name:"Ethereum Token",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:56,address:"0x8ac76a51cc950d9822d68b83fe1ad97b32cd580d",name:"Binance-Peg USD Coin",decimals:18,symbol:"USDC",logoURI:"https://cmp.dodoex.io/sQ5dF3FkjjQUsmfqFFE5cKq-cthh4u0wUooBE5Epf-k/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTDlEVElLa2dONG5mRkNTSF9GMUdXU3JiZkJDa2JZRTkwbmFDS0dIWnRsby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMM1Z6WkdOZlpXVTFNbUV4WldReVlpOTFjMlJqWDJWbE5USmhNV1ZrTW1JdWNHNW4ucG5n.webp"},{chainId:56,address:"0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c",name:"Wrapped BNB",decimals:18,symbol:"WBNB",logoURI:"https://cmp.dodoex.io/-Pua5rc9k9iW4yuF5ajLVKzMkRhBq06D8HiEZ5gjezA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMDZOWTdBTmdOYWdFOHpXYUMtX2IzYXVPOUxsTEp6QlpLTUR3VlM5eW9DQS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyeHZaMjlmT1dRellXTmtZMlEzTnk1d2JtYy5wbmc.webp"},{chainId:137,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"MATIC",decimals:18,symbol:"MATIC",logoURI:"https://cmp.dodoex.io/cQFrEB6yGIqMkh_6Pie8VR3kIStL58IS-y8FbroHVwA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vc2VNUUk2dkpoaXljeldrczJaWWdGdk8zSEoxSWFIa053LXZYeXFneER4US9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMekZmTWpkbE56TXlNRE13TWk4eFh6STNaVGN6TWpBek1ESXVjRzVuLnBuZw.webp"},{chainId:137,address:"0xe4bf2864ebec7b7fdf6eeca9bacae7cdfdaffe78",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/KEPetVp3nQkB6BZ_cb05trEfBbGxFEg92UnF8NZsEzM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vVE5wTlRseEJGbFRDalM1ZFh3SWJ3Mm1hZ3NPUFFkZ3Z1UEhuZDZrNWdyMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk4yUTBaamxtTldOaU15OUVUMFJQWHpka05HWTVaalZqWWpNdWNHNW4ucG5n.webp"},{chainId:137,address:"0x8f3Cf7ad23Cd3CaDbD9735AFf958023239c6A063",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/hdRkGay_hj0t1OzN5C3c30cmch26tJhHUSroffg7ciY/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vOHd3UndQOG9DTTdBcF9NOW11bGVOQWRqYjhBOXpvX2FYUE5pVTNBYUtzYy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhnMlgwSXhOelUwTnpSZlJUZzVNRGswWDBNME5GOUVZVGs0WWprMU5GOUZaV1JsWDBGRFh6UTVOVEkzTVdRd1gwWmZiRzluYjE4MFpXSXdNVE0zTVRZeExuQnVady5wbmc.webp"},{chainId:137,address:"0x7ceB23fD6bC0adD59E62ac25578270cFf1b9f619",name:"Ether",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/WAobi4MZtLSxB59wgpyNlXLI44ZwlBh55qiGS2wLSGU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vSUVnUUx3TjRMU2dKRDJTM3RmSFlHcmxZbFZQNGlJeFcxeEZVOUwwUExRNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoZlF6QXlZV0ZmUVRNNVlqSXlNMTlHUlY4NFgwUXdYMEV3WlRWZlF6UmZSakkzWlY5QlJGODVNRGd6WDBNM05UWmZRMk15WDJ4dloyOWZZelk0WXprelpHRXlNQzV3Ym1jLnBuZw.webp"},{chainId:137,address:"0x2791Bca1f2de4661ED88A30C99A7a9449Aa84174",name:"USD Coin",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/er3iAGv39hCC7F8AydW_AteD3hnZj9HI2XcAaruHeqA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vVE9WUWtzN3JQWU5OZWdmNTRuNC1Za1NGTFYyLXVGZmlJRFVYem85aVMzOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoZlFUQmlPRFk1T1RGak5qSXhPR0l6Tm1NeFpERTVYMFEwWVRKbE9WOUZZakJqWDBVek5qQTJaVjlDTkRoZmJHOW5iMTlpTmpGbE5EVmtNbVF6TG5CdVp3LnBuZw.webp"},{chainId:137,address:"0xc2132D05D31c914a87C6611C10748AEb04B58e8F",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/WeK6L9_RjWUfAsnMuOAdyXIZVE3JK_H3lZU5vk2m7Tg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTFJ0aEt6X2VrSXdmTEh6NnAycW5rSkRFeUk1RXZrODlXQ0J2VW43MUJLNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoa1gwRkRYekUzWDBZNU5UaGZSREpsWlRVeU0yRXlNakEyTWpBMk9UazBOVGszWDBNeE0xOUVPRE14WldNM1gyeHZaMjlmWXpCbU9XVTFaamxoTmk1d2JtYy5wbmc.webp"},{chainId:137,address:"0x1BFD67037B42Cf73acF2047067bd4F2C47D9BfD6",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/_KjvB9pCVqbIIv_UnQvRWpjySBHiFnuHNSXUm_52UZM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZDQ4OVYzTW1NMi1qaFJueEQ2Y3MyY1gydXdGS2tkRHpiRGZsbkZhTTJxOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhneU1qWXdYMFpCUTE4MVgwVTFOVFF5WVRjM00xOUJZVFEwWmw5Q1gwTm1aVjlFWmpkZlF6RTVNMkpqTWw5RE5UazVYMnh2WjI5Zk5HTmpORE0zTlRneFppNXdibWMucG5n.webp"},{chainId:137,address:"0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270",name:"Wrapped MATIC",decimals:18,symbol:"WMATIC",logoURI:"https://cmp.dodoex.io/HfZVSaAES3QRplSybW2uoKmYf6pVTRaxufn95_Qto_A/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMERhZEZTUUVFX0d4YlBoMHY3Wk1Hb1FwaWtOQm1vaWFyZTFlaFdJbU44dy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMjFoZEdsalgyVmlOekZtTkdFMU9XRXZiV0YwYVdOZlpXSTNNV1kwWVRVNVlTNTNaV0p3LndlYnA.webp"},{chainId:42161,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"ETH",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:42161,address:"0x82aF49447D8a07e3bd95BD0d56f35241523fBab1",name:"Wrapped Ether",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/6VmZGvbENd4TM1VK0rsYrfznRtG-GwxP-zCy2qyc9bM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWnJZUDB0ZHVTLUdDNE5FTThmRmV1RHhVWklPNUZpWnpqdkdBc0lfNlBQMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh5TW1GbU4yVTVOVFJpTDFkRlZFaGZhV052Ymw4eU1tRm1OMlU1TlRSaUxuQnVady5wbmc.webp"},{chainId:42161,address:"0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/XNbyKKzPthXfYOku9oXt5xzqM1JOWzxmbTLq2kkSvaU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWHprMUxKSzJ2V1BYVmN3TmVvVDRfR3NNdnBOVXFmTmliXzgybFZSVUNkWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmYzNWemFHbHpkMkZ3WDJsamIyNXpYMjFoYzNSbGNsOTBiMnRsYmw5a1lXbGZPRGhrT0dNeE5HRTBZaTVxY0djLmpwZw.webp"},{chainId:42161,address:"0x69Eb4FA4a2fbd498C257C57Ea8b7655a2559A581",name:"DODO bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/6U51l5aajoRrCaO6cpbrclQ2olWNDzuShggOCfoktCA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8va3RkSlhwQ3dsQVZtZXNPb1dvQV95SG9IazBnV3UxUExienBKa1AxYnlJdy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJQUkU5Zk5tTmtPVEV4WXprNE15OUVUMFJQWHpaalpEa3hNV001T0RNdWNHNW4ucG5n.webp"},{chainId:42161,address:"0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8",name:"USD Coin (Arb1)",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/EaCi6KUTS-dinU-wGdG2IcundJ0fJfsOw97FRI2vaB8/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdEVMaUx0Y1FaTVlBb3hkeExLdnRrZ2ltdVB5dmZRdUQ5U1BxU1c1bDZsMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZmFXTnZibDh5WlRFeU5tSTRaRFV5TDFWVFJFTmZhV052Ymw4eVpURXlObUk0WkRVeUxuQnVady5wbmc.webp"},{chainId:42161,address:"0xFd086bC7CD5C481DCC9C85ebE478A1C0b69FCbb9",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:42161,address:"0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:66,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"OKT",decimals:18,symbol:"OKT",logoURI:"https://cmp.dodoex.io/pcltGNcIp7DP33nj3YxxBpuFEekNcOW3pwq9tjSrpY4/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vTzJHSDJYTndRancwbXMzQXNidG5xNzRkVEROVld3QWFOU1dXU2ZnU01QTS9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6RTVOalF5T1RCZk1qQXlNakExTWpBd056STNORFl3TWpJdWMzWm4uc3Zn.webp"},{chainId:66,address:"0x382bB369d343125BfB2117af9c149795C6C65C50",name:"USDT",decimals:18,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:66,address:"0x218c3c3D49d0E7B37aff0D8bB079de36Ae61A4c0",name:"BNB",decimals:18,symbol:"BNB",logoURI:"https://cmp.dodoex.io/BWNSMMqu68bSFJsr9vsiCV09IonH3yuAkR9gQxaipBw/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vZDhvazF4akd3bU9GUXUtMVdzNEVRLVBNRnJYMW9DLXlmYTc3OGJUUkx0US9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpPUWw5alpEUTVNalE0TXpJMkwwSk9RbDlqWkRRNU1qUTRNekkyTG5CdVp3LnBuZw.webp"},{chainId:66,address:"0x54e4622DC504176b3BB432dCCAf504569699a7fF",name:"BTCK",decimals:18,symbol:"BTCK",logoURI:"https://cmp.dodoex.io/L3kcNUKg94qnX8OPFlEvHKqWybnJD8SA9HTne3PW-Rg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vNU1MQTB3Q3V6eEs4Q3ZMV0RqempuOVhzalBTWE1zbUpWZ0RRN1RPMG9FWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpVUTB0Zk1HWmlaRGRsTWpnNU5pOUNWRU5MWHpCbVltUTNaVEk0T1RZdWNHNW4ucG5n.webp"},{chainId:66,address:"0x332730a4F6E03D9C55829435f10360E13cfA41Ff",name:"BUSD",decimals:18,symbol:"BUSD",logoURI:"https://cmp.dodoex.io/-aEkA13gC6lOFoRyGeSy2BotE5YY3WUmcSlPa9Rpddc/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaXVmSjhaNHFJYzlMMDgtNHpxRUMxWl94WVlqRkEtT3BqS1FJbmQyeHpHUS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpWVTBSZk1XTTJNRFpqTjJZeE55OUNWVk5FWHpGak5qQTJZemRtTVRjdWNHNW4ucG5n.webp"},{chainId:66,address:"0x21cDE7E32a6CAF4742d00d44B07279e7596d26B9",name:"DAIK",decimals:18,symbol:"DAIK",logoURI:"https://cmp.dodoex.io/LOb-sXupURNN9HA0zBSfLfpZlx52N9qRSDUyzk3cg0A/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vck5pZzMtWU5TOUl4T3ZHX19taTFRSU9WYTZsczdZNXViRVhGcTJJVGplby9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFJCU1V0Zk5ESTVNV1l4WlRoa1pTOUVRVWxMWHpReU9URm1NV1U0WkdVdWNHNW4ucG5n.webp"},{chainId:66,address:"0xEF71CA2EE68F45B9Ad6F72fbdb33d707b872315C",name:"ETHK",decimals:18,symbol:"ETHK",logoURI:"https://cmp.dodoex.io/IwBclhMMQLOo79RdRo6-HnUiXxshO_hSi02YK3L6MFI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcFBSd192aEx2MHh3WkRHU2k3eGYyYVJiQjlocVhfU2tacUdGc3RJR0pYRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMFZVU0V0Zk1UQTVNamMzTW1VMU9DOUZWRWhMWHpFd09USTNOekpsTlRndWNHNW4ucG5n.webp"},{chainId:66,address:"0xc946DAf81b08146B1C7A8Da2A851Ddf2B3EAaf85",name:"USDC",decimals:18,symbol:"USDC",logoURI:"https://cmp.dodoex.io/bXLFjIP5_obFZS9jvWA1bZc2b2Vsw4-tqcvj10aPUpU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcXhZT0hTcDYzemNTaDVHRVV1SFlya3JGS2s1MW9zLVUycG42bjNXV2pYay9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZk1UTTFZak13TkRkaVpDOVZVMFJEWHpFek5XSXpNRFEzWW1RdWNHNW4ucG5n.webp"},{chainId:66,address:"0xdCAC52E001f5bd413aa6ea83956438F29098166b",name:"USDK",decimals:18,symbol:"USDK",logoURI:"https://cmp.dodoex.io/X-_D75ZOpI-yC70WjdgC8wiqcssfRIALEv0eUfD3HiE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vd290dHEzaWdkTDVzQlhSR2VFZkhQLTNpZHhDZzV0V3VGQmE3YjNrNUZITS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkV0Zk56aGpZekV6TW1OaVpDOVZVMFJMWHpjNFkyTXhNekpqWW1RdWNHNW4ucG5n.webp"},{chainId:66,address:"0x506f731F7656e2FB34b587B912808f2a7aB640BD",name:"WBTCK",decimals:18,symbol:"WBTCK",logoURI:"https://cmp.dodoex.io/7Gb1gYkvjWESf9ungWe4YKOrr5GY5UILmTwU_U95kCA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vOTQ4NWZpU2NmUzBNc2V1YVZXWXo2Z1RuNVVidXJvZkxmN1VGSWhMdndjTS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOTFgyVXlZamRpWVRJNU16TXZWMEpVUTB0ZlpUSmlOMkpoTWprek15NXdibWMucG5n.webp"},{chainId:1313161554,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Ethereum",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/WAobi4MZtLSxB59wgpyNlXLI44ZwlBh55qiGS2wLSGU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vSUVnUUx3TjRMU2dKRDJTM3RmSFlHcmxZbFZQNGlJeFcxeEZVOUwwUExRNC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmZEhKMWMzUjNZV3hzWlhSZllYTnpaWFJ6WDIxaGMzUmxjbDlpYkc5amEyTm9ZV2x1YzE5bGRHaGxjbVYxYlY5aGMzTmxkSE5mTUhoZlF6QXlZV0ZmUVRNNVlqSXlNMTlHUlY4NFgwUXdYMEV3WlRWZlF6UmZSakkzWlY5QlJGODVNRGd6WDBNM05UWmZRMk15WDJ4dloyOWZZelk0WXprelpHRXlNQzV3Ym1jLnBuZw.webp"},{chainId:1313161554,address:"0xC9BdeEd33CD01541e1eeD10f90519d2C06Fe3feB",name:"Wrapped Ethereum",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:1313161554,address:"0x8BEc47865aDe3B172A928df8f990Bc7f2A3b9f79",name:"Aurora",decimals:18,symbol:"Aurora",logoURI:"https://cmp.dodoex.io/2C2jfpO2-VYuwlga3SdtP5I6eJNJXIYq3LvPU4aFuiU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcHFWVWlJOEQ4VU5iUEZYRElvUnA3cFhEZFc4dmx4dWEtTmxubmxlam1PMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMkYxY205eVlWOHlOVEprWlRFeE56YzBMMkYxY205eVlWOHlOVEprWlRFeE56YzBMbmRsWW5BLndlYnA.webp"},{chainId:1313161554,address:"0xe3520349F477A5F6EB06107066048508498A291b",name:"Dai Stablecoin",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/XNbyKKzPthXfYOku9oXt5xzqM1JOWzxmbTLq2kkSvaU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWHprMUxKSzJ2V1BYVmN3TmVvVDRfR3NNdnBOVXFmTmliXzgybFZSVUNkWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmYzNWemFHbHpkMkZ3WDJsamIyNXpYMjFoYzNSbGNsOTBiMnRsYmw5a1lXbGZPRGhrT0dNeE5HRTBZaTVxY0djLmpwZw.webp"},{chainId:1313161554,address:"0xe301eD8C7630C9678c39E4E45193D1e7Dfb914f7",name:"DODO Bird",decimals:18,symbol:"DODO",logoURI:"https://cmp.dodoex.io/SEcMDWMmtHb3GFW5l7fTKYurpTqALHdZI3D6qzad1rs/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vQXRNMzllUjhRQzhYTl8tem5HU0pSLS1lV0tPUW91V3p2ci0zQ014WlJTSS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMekl3TUhneU1EQmZNVjh3WWpReFl6VTJZV1UxTHpJd01IZ3lNREJmTVY4d1lqUXhZelUyWVdVMUxuQnVady5wbmc.webp"},{chainId:1313161554,address:"0xB12BFcA5A55806AaF64E99521918A4bf0fC40802",name:"USD Coin",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/EaCi6KUTS-dinU-wGdG2IcundJ0fJfsOw97FRI2vaB8/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdEVMaUx0Y1FaTVlBb3hkeExLdnRrZ2ltdVB5dmZRdUQ5U1BxU1c1bDZsMC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZmFXTnZibDh5WlRFeU5tSTRaRFV5TDFWVFJFTmZhV052Ymw4eVpURXlObUk0WkRVeUxuQnVady5wbmc.webp"},{chainId:1313161554,address:"0x4988a896b1227218e4A686fdE5EabdcAbd91571f",name:"Tether USD",decimals:6,symbol:"USDT",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:1313161554,address:"0xF4eB217Ba2454613b15dBdea6e5f22276410e89e",name:"Wrapped BTC",decimals:8,symbol:"WBTC",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:43114,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"Avalanche",decimals:18,symbol:"AVAX",logoURI:"https://cmp.dodoex.io/yBkeC0v6hqQP-wNBxAq_C_D6JTYUc4Q86Wh6WIciESI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcmpNamFFdHJ5WUZxNks3TkpxYkRWczlEZF80aHp4ZUo3YnB0eGgtVERDYy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMjEzWDI1ZlRqaHRNRjgwTURCNE5EQXdYems0WlRKaU5EQm1PRGN2YlhkZmJsOU9PRzB3WHpRd01IZzBNREJmT1RobE1tSTBNR1k0Tnk1cWNHYy5qcGc.webp"},{chainId:43114,address:"0xB31f66AA3C1e785363F0875A1B74E27b85FD66c7",name:"Wrapped AVAX",decimals:18,symbol:"WAVAX",logoURI:"https://cmp.dodoex.io/yBkeC0v6hqQP-wNBxAq_C_D6JTYUc4Q86Wh6WIciESI/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcmpNamFFdHJ5WUZxNks3TkpxYkRWczlEZF80aHp4ZUo3YnB0eGgtVERDYy9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMjEzWDI1ZlRqaHRNRjgwTURCNE5EQXdYems0WlRKaU5EQm1PRGN2YlhkZmJsOU9PRzB3WHpRd01IZzBNREJmT1RobE1tSTBNR1k0Tnk1cWNHYy5qcGc.webp"},{chainId:43114,address:"0x19860CCB0A68fd4213aB9D8266F7bBf05A8dDe98",name:"Binance USD",decimals:18,symbol:"BUSD.e",logoURI:"https://cmp.dodoex.io/-aEkA13gC6lOFoRyGeSy2BotE5YY3WUmcSlPa9Rpddc/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaXVmSjhaNHFJYzlMMDgtNHpxRUMxWl94WVlqRkEtT3BqS1FJbmQyeHpHUS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMEpWVTBSZk1XTTJNRFpqTjJZeE55OUNWVk5FWHpGak5qQTJZemRtTVRjdWNHNW4ucG5n.webp"},{chainId:43114,address:"0xd586E7F844cEa2F87f50152665BCbc2C279D8d70",name:"Dai Stablecoin",decimals:18,symbol:"DAI.e",logoURI:"https://cmp.dodoex.io/XNbyKKzPthXfYOku9oXt5xzqM1JOWzxmbTLq2kkSvaU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vWHprMUxKSzJ2V1BYVmN3TmVvVDRfR3NNdnBOVXFmTmliXzgybFZSVUNkWS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMlZ5WXpJd0wyaDBkSEJ6WDNKaGQxOW5hWFJvZFdKMWMyVnlZMjl1ZEdWdWRGOWpiMjFmYzNWemFHbHpkMkZ3WDJsamIyNXpYMjFoYzNSbGNsOTBiMnRsYmw5a1lXbGZPRGhrT0dNeE5HRTBZaTVxY0djLmpwZw.webp"},{chainId:43114,address:"0xA7D7079b0FEaD91F3e65f86E8915Cb59c1a4C664",name:"USD Coin",decimals:6,symbol:"USDC.e",logoURI:"https://cmp.dodoex.io/bXLFjIP5_obFZS9jvWA1bZc2b2Vsw4-tqcvj10aPUpU/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vcXhZT0hTcDYzemNTaDVHRVV1SFlya3JGS2s1MW9zLVUycG42bjNXV2pYay9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkVOZk1UTTFZak13TkRkaVpDOVZVMFJEWHpFek5XSXpNRFEzWW1RdWNHNW4ucG5n.webp"},{chainId:43114,address:"0xc7198437980c041c805A1EDcbA50c1Ce5db95118",name:"Tether USD",decimals:6,symbol:"USDT.e ",logoURI:"https://cmp.dodoex.io/MGklrG5AImwUllGWDPMAHY0qLfdJQn4bj3iPFWSeohA/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vUEM3a3JPb252bWl4U3VRaFEwY29pVy1sczFYN25WS1lLNVluekQ2R2lxRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMVZUUkZSZlpUaGlOekZpTldZeU9TOVZVMFJVWDJVNFlqY3hZalZtTWprdWNHNW4ucG5n.webp"},{chainId:43114,address:"0x50b7545627a5162F82A992c33b87aDc75187B218",name:"Wrapped BTC",decimals:8,symbol:"WBTC.e",logoURI:"https://cmp.dodoex.io/n4n7ccBom2tgcZNN0jBv9YiTq5qGMjX6PHO0YGlpzZo/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vMElrSkQzVEc2SkFQdG1DV24tNnhfa0ozS3lXYXlVVHRhZ19PQmF0TFEwRS9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRDVkVOZmFXTnZibDgzWW1JelpUQTRaak14TDFkQ1ZFTmZhV052Ymw4M1ltSXpaVEE0WmpNeExuQnVady5wbmc.webp"},{chainId:43114,address:"0x49D5c2BdFfac6CE2BFdB6640F4F80f226bc10bAB",name:"Wrapped Ether",decimals:18,symbol:"WETH.e",logoURI:"https://cmp.dodoex.io/KWYmKxU_OCS1PmzuEO0xjdr1Yn08SjGBkyqSI8hxlpE/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vdkkyZF9rdFdyUzQyM0FqZlBLbkxRYloyRGVzTkpacmNTSlZNb1dYRnkyOC9hSFIwY0hNNkx5OWpaRzR0YldWa2FXRXVaRzlrYjJWNExtbHZMMWRGVkVoZmFXTnZibDh6TVRjd1pqTTBORGcxTDFkRlZFaGZhV052Ymw4ek1UY3daak0wTkRnMUxuQnVady5wbmc.webp"},{chainId:10,address:"0x4200000000000000000000000000000000000006",name:"WETH",decimals:18,symbol:"WETH",logoURI:"https://cmp.dodoex.io/f9SbZq39ynUZS5ueKvAwzLmKUfcZvYpKDaysT3dkcvM/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vc2NkVzJUWjladmRiX3BVSjZ3b2YzeHRvYk94YUw3bEV5RmhhemhJUFhlMC9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6RXdNamd3TkRaZk1qQXlNakEwTWpJd01UQXpORGc1TURVdWNHNW4ucG5n.webp"},{chainId:10,address:"0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1",name:"DAI",decimals:18,symbol:"DAI",logoURI:"https://cmp.dodoex.io/04gwZiu2K_9fdb2zLwzsX1nONCbBWrZOvTyOoEFhx3g/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaDJCcmdhUmZxUzBLZDBEOVpZbEUteEtNMVdzeFFtRzBEWVpKOGJCaWN4US9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6SXlNRFUwTVRsZk1qQXlNakEwTWpJd01UQTBNak00TlRVdWFuQm4uanBn.webp"},{chainId:10,address:"0x7F5c764cBc14f9669B88837ca1490cCa17c31607",name:"USDC",decimals:6,symbol:"USDC",logoURI:"https://cmp.dodoex.io/XbtxsPIscM6p5ClHbLO0JumFHA9U23eON8-MDh-Plkg/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vaG1nM3hRa1BUTUtkcUNFVnd0LXU4S2lwTW5od1JCdGhLYWxENW9vSWlTZy9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6UXlNRFEyTkRaZk1qQXlNakEwTWpJd01UQTFNekF4TmpVdWNHNW4ucG5n.webp"},{chainId:10,address:"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE",name:"ETH",decimals:18,symbol:"ETH",logoURI:"https://cmp.dodoex.io/bcyoORJ04NyP1HhYUZ9RrTZ-MEOFeNnMcrr__JZ6Ruw/rs:fit:96:96:0/g:no/aHR0cHM6Ly9pbWFnZS1wcm94eS5kb2RvZXguaW8vV1lHaU9IVFVnVWs4Q3Z3WmNyN0hWX2w4SlNrQjRVQUh1UXpzaWd4U3Nmay9hSFIwY0hNNkx5OXpkRzl5WVdkbExtZHZiMmRzWldGd2FYTXVZMjl0TDJSdlpHOHRiV1ZrYVdFdGMzUmhaMmx1Wnk5MWNHeHZZV1JmYVcxblh6VTVPREk0T1Y4eU1ESXlNRFF5TWpBeU1qTTBNelk0TlM1d2JtYy5wbmc.webp"}];function jf({tokenList:e,popularTokenList:t}){const o=l.useDispatch(),{account:i}=u.useWeb3React(),s=Of();n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){let n=[];n=r.isArray(e)?e:r.unionBy(t,If,(e=>e.address.toLowerCase())),o((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_TOKEN_LIST",payload:e})})))(n))}))})()}),[e,o,t]),n.useEffect((()=>{o(ya({}))}),[i,s]),n.useEffect((()=>{o((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_POPULAR_TOKEN_LIST",payload:e})})))(null!=t?t:[]))}),[t,o])}const Ff=e=>(null!=e?e:Tf.getState()).token.tokenList,_f=e=>(null!=e?e:Tf.getState()).token.accountBalances,Pf=e=>(null!=e?e:Tf.getState()).token.ethBalance,Bf=e=>(null!=e?e:Tf.getState()).token.defaultFromToken,Wf=e=>(null!=e?e:Tf.getState()).token.defaultToToken,Df=e=>(null!=e?e:Tf.getState()).token.balanceLoadings;function Lf(){const{account:e,chainId:t}=u.useWeb3React(),r=l.useSelector(_f),o=l.useSelector(Pf),i=n.useMemo((()=>la[t||1]),[t]),s=n.useCallback((n=>{var s;if(!e||!n)return null;if(i&&n.symbol===i.symbol&&da(n.address,i.address)){const e=o[null!=t?t:1];return!e||(null==e?void 0:e.isNaN())?null:e}if(i&&n.chainId&&n.chainId!==t&&da(n.address,i.address)){const e=o[n.chainId];return!e||(null==e?void 0:e.isNaN())?null:e}const a=null===(s=r[n.address.toLocaleLowerCase()])||void 0===s?void 0:s.tokenBalances;return!a||(null==a?void 0:a.isNaN())?null:a}),[r,o,e]);return s}const Uf=e=>(null!=e?e:Tf.getState()).globals,Vf=e=>(null!=e?e:Tf.getState()).globals.autoConnectLoading;var Zf=[{constant:!0,inputs:[],name:"getCurrentBlockTimestamp",outputs:[{name:"timestamp",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{components:[{name:"target",type:"address"},{name:"callData",type:"bytes"}],name:"calls",type:"tuple[]"}],name:"aggregate",outputs:[{name:"blockNumber",type:"uint256"},{name:"returnData",type:"bytes[]"}],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!0,inputs:[],name:"getLastBlockHash",outputs:[{name:"blockHash",type:"bytes32"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"addr",type:"address"}],name:"getEthBalance",outputs:[{name:"balance",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[],name:"getCurrentBlockDifficulty",outputs:[{name:"difficulty",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[],name:"getCurrentBlockGasLimit",outputs:[{name:"gaslimit",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[],name:"getCurrentBlockCoinbase",outputs:[{name:"coinbase",type:"address"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"blockNumber",type:"uint256"}],name:"getBlockHash",outputs:[{name:"blockHash",type:"bytes32"}],payable:!1,stateMutability:"view",type:"function"}],Hf={[ia.MAINNET]:{MULTI_CALL:"0xeefba1e63905ef1d7acba5a8513c70307c1ce441",DODO_APPROVE:"0xCB859eA579b28e02B87A1FDE08d087ab9dbE5149",ERC20_HELPER:"0xD9ef2d1583e8Aa196123e773BE38B539a4d149df"},[ia.GOERLI]:{MULTI_CALL:"0x696E25A5e2AEd1C55E6d6Cfa0532Bbda9020165d",DODO_APPROVE:"0xC9143e54021f4a6d33b9b89DBB9F458AaEdd56FB",ERC20_HELPER:"0x24549FC74B3076A962624A26370ed556c467F74C"},[ia.BSC]:{MULTI_CALL:"0x1Ee38d535d541c55C9dae27B12edf090C608E6Fb",DODO_APPROVE:"0xa128Ba44B2738A558A1fdC06d6303d52D3Cef8c1",ERC20_HELPER:"0x566651Ad34f6306872FaC5fB95bbF4C9beE8D8F2"},[ia.POLYGON]:{MULTI_CALL:"0xc9eD9B18e447e600238fe50e944B9062B664DEa4",DODO_APPROVE:"0x292E6b2e054e1157df71C1C9510265CA8C0c7672",ERC20_HELPER:"0xfd24312Ec7871A6D1a31e454D5AbB16c6c25a9b3"},[ia.ARBITRUM_ONE]:{MULTI_CALL:"0xF718F2bd590E5621e53f7b89398e52f7Acced8ca",DODO_APPROVE:"0xA867241cDC8d3b0C07C85cC06F25a0cD3b5474d8",ERC20_HELPER:"0x7C062B9C584fA6eC2504270790D38240A2c5fE72"},[ia.AURORA]:{MULTI_CALL:"0x989DcAA95801C527C5B73AA65d3962dF9aCe1b0C",DODO_APPROVE:"0x335aC99bb3E51BDbF22025f092Ebc1Cf2c5cC619",ERC20_HELPER:"0xE8C9A78725D0451FA19878D5f8A3dC0D55FECF25"},[ia.OKCHAIN]:{MULTI_CALL:"0x5e84190a270333aCe5B9202a3F4ceBf11b81bB01",DODO_APPROVE:"0x7737fd30535c69545deeEa54AB8Dd590ccaEBD3c",ERC20_HELPER:"0x4775b1858f1e417C9609D455C3Ad8751ec01daC4"},[ia.OPTIMISM]:{MULTI_CALL:"0xb98Ac2fEFc8b73aeAE33D02BB00c26E12afCa9Df",DODO_APPROVE:"0xa492d6eABcdc3E204676f15B950bBdD448080364",ERC20_HELPER:"0x42E456ea0dd7538ea103fBb1d0388D14C97bB5b2"},[ia.AVALANCHE]:{MULTI_CALL:"0x97f0153E7F5749640aDF3Ff9CFC518b79D6Fe53b",DODO_APPROVE:"0xCFea63e3DE31De53D68780Dd65675F169439e470",ERC20_HELPER:"0xC3528D128CC227fd60793007b5e3FdF7c2945282"},[ia.CONFLUX]:{MULTI_CALL:"0x696e25a5e2aed1c55e6d6cfa0532bbda9020165d",DODO_APPROVE:"0x5BaF16d57620Cb361F622232F3cb4090e35F3da2",ERC20_HELPER:"0x24549FC74B3076A962624A26370ed556c467F74C"}};const zf=new Cs("abi/5.7.0"),Yf={};let Gf={calldata:!0,memory:!0,storage:!0},Xf={calldata:!0,memory:!0};function Jf(e,t){if("bytes"===e||"string"===e){if(Gf[t])return!0}else if("address"===e){if("payable"===t)return!0}else if((e.indexOf("[")>=0||"tuple"===e)&&Xf[t])return!0;return(Gf[t]||"payable"===t)&&zf.throwArgumentError("invalid modifier","name",t),!1}function qf(e,t){for(let r in t)wa(e,r,t[r])}const Qf=Object.freeze({sighash:"sighash",minimal:"minimal",full:"full",json:"json"}),Kf=new RegExp(/^(.*)\[([0-9]*)\]$/);class $f{constructor(e,t){e!==Yf&&zf.throwError("use fromString",Cs.errors.UNSUPPORTED_OPERATION,{operation:"new ParamType()"}),qf(this,t);let r=this.type.match(Kf);qf(this,r?{arrayLength:parseInt(r[2]||"-1"),arrayChildren:$f.fromObject({type:r[1],components:this.components}),baseType:"array"}:{arrayLength:null,arrayChildren:null,baseType:null!=this.components?"tuple":this.type}),this._isParamType=!0,Object.freeze(this)}format(e){if(e||(e=Qf.sighash),Qf[e]||zf.throwArgumentError("invalid format type","format",e),e===Qf.json){let t={type:"tuple"===this.baseType?"tuple":this.type,name:this.name||void 0};return"boolean"==typeof this.indexed&&(t.indexed=this.indexed),this.components&&(t.components=this.components.map((t=>JSON.parse(t.format(e))))),JSON.stringify(t)}let t="";return"array"===this.baseType?(t+=this.arrayChildren.format(e),t+="["+(this.arrayLength<0?"":String(this.arrayLength))+"]"):"tuple"===this.baseType?(e!==Qf.sighash&&(t+=this.type),t+="("+this.components.map((t=>t.format(e))).join(e===Qf.full?", ":",")+")"):t+=this.type,e!==Qf.sighash&&(!0===this.indexed&&(t+=" indexed"),e===Qf.full&&this.name&&(t+=" "+this.name)),t}static from(e,t){return"string"==typeof e?$f.fromString(e,t):$f.fromObject(e)}static fromObject(e){return $f.isParamType(e)?e:new $f(Yf,{name:e.name||null,type:uh(e.type),indexed:null==e.indexed?null:!!e.indexed,components:e.components?e.components.map($f.fromObject):null})}static fromString(e,t){return r=function(e,t){let r=e;function n(t){zf.throwArgumentError(`unexpected character at position ${t}`,"param",e)}function o(e){let r={type:"",name:"",parent:e,state:{allowType:!0}};return t&&(r.indexed=!1),r}e=e.replace(/\s/g," ");let i={type:"",name:"",state:{allowType:!0}},s=i;for(let r=0;r<e.length;r++){let i=e[r];switch(i){case"(":s.state.allowType&&""===s.type?s.type="tuple":s.state.allowParams||n(r),s.state.allowType=!1,s.type=uh(s.type),s.components=[o(s)],s=s.components[0];break;case")":delete s.state,"indexed"===s.name&&(t||n(r),s.indexed=!0,s.name=""),Jf(s.type,s.name)&&(s.name=""),s.type=uh(s.type);let e=s;s=s.parent,s||n(r),delete e.parent,s.state.allowParams=!1,s.state.allowName=!0,s.state.allowArray=!0;break;case",":delete s.state,"indexed"===s.name&&(t||n(r),s.indexed=!0,s.name=""),Jf(s.type,s.name)&&(s.name=""),s.type=uh(s.type);let a=o(s.parent);s.parent.components.push(a),delete s.parent,s=a;break;case" ":s.state.allowType&&""!==s.type&&(s.type=uh(s.type),delete s.state.allowType,s.state.allowName=!0,s.state.allowParams=!0),s.state.allowName&&""!==s.name&&("indexed"===s.name?(t||n(r),s.indexed&&n(r),s.indexed=!0,s.name=""):Jf(s.type,s.name)?s.name="":s.state.allowName=!1);break;case"[":s.state.allowArray||n(r),s.type+=i,s.state.allowArray=!1,s.state.allowName=!1,s.state.readArray=!0;break;case"]":s.state.readArray||n(r),s.type+=i,s.state.readArray=!1,s.state.allowArray=!0,s.state.allowName=!0;break;default:s.state.allowType?(s.type+=i,s.state.allowParams=!0,s.state.allowArray=!0):s.state.allowName?(s.name+=i,delete s.state.allowArray):s.state.readArray?s.type+=i:n(r)}}return s.parent&&zf.throwArgumentError("unexpected eof","param",e),delete i.state,"indexed"===s.name?(t||n(r.length-7),s.indexed&&n(r.length-7),s.indexed=!0,s.name=""):Jf(s.type,s.name)&&(s.name=""),i.type=uh(i.type),i}(e,!!t),$f.fromObject({name:r.name,type:r.type,indexed:r.indexed,components:r.components});var r}static isParamType(e){return!(null==e||!e._isParamType)}}function eh(e,t){return function(e){e=e.trim();let t=[],r="",n=0;for(let o=0;o<e.length;o++){let i=e[o];","===i&&0===n?(t.push(r),r=""):(r+=i,"("===i?n++:")"===i&&(n--,-1===n&&zf.throwArgumentError("unbalanced parenthesis","value",e)))}r&&t.push(r);return t}(e).map((e=>$f.fromString(e,t)))}class th{constructor(e,t){e!==Yf&&zf.throwError("use a static from method",Cs.errors.UNSUPPORTED_OPERATION,{operation:"new Fragment()"}),qf(this,t),this._isFragment=!0,Object.freeze(this)}static from(e){return th.isFragment(e)?e:"string"==typeof e?th.fromString(e):th.fromObject(e)}static fromObject(e){if(th.isFragment(e))return e;switch(e.type){case"function":return ah.fromObject(e);case"event":return rh.fromObject(e);case"constructor":return sh.fromObject(e);case"error":return ch.fromObject(e);case"fallback":case"receive":return null}return zf.throwArgumentError("invalid fragment object","value",e)}static fromString(e){return"event"===(e=(e=(e=e.replace(/\s/g," ")).replace(/\(/g," (").replace(/\)/g,") ").replace(/\s+/g," ")).trim()).split(" ")[0]?rh.fromString(e.substring(5).trim()):"function"===e.split(" ")[0]?ah.fromString(e.substring(8).trim()):"constructor"===e.split("(")[0].trim()?sh.fromString(e.trim()):"error"===e.split(" ")[0]?ch.fromString(e.substring(5).trim()):zf.throwArgumentError("unsupported fragment","value",e)}static isFragment(e){return!(!e||!e._isFragment)}}class rh extends th{format(e){if(e||(e=Qf.sighash),Qf[e]||zf.throwArgumentError("invalid format type","format",e),e===Qf.json)return JSON.stringify({type:"event",anonymous:this.anonymous,name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Qf.sighash&&(t+="event "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Qf.full?", ":",")+") ",e!==Qf.sighash&&this.anonymous&&(t+="anonymous "),t.trim()}static from(e){return"string"==typeof e?rh.fromString(e):rh.fromObject(e)}static fromObject(e){if(rh.isEventFragment(e))return e;"event"!==e.type&&zf.throwArgumentError("invalid event object","value",e);const t={name:ph(e.name),anonymous:e.anonymous,inputs:e.inputs?e.inputs.map($f.fromObject):[],type:"event"};return new rh(Yf,t)}static fromString(e){let t=e.match(fh);t||zf.throwArgumentError("invalid event string","value",e);let r=!1;return t[3].split(" ").forEach((e=>{switch(e.trim()){case"anonymous":r=!0;break;case"":break;default:zf.warn("unknown modifier: "+e)}})),rh.fromObject({name:t[1].trim(),anonymous:r,inputs:eh(t[2],!0),type:"event"})}static isEventFragment(e){return e&&e._isFragment&&"event"===e.type}}function nh(e,t){t.gas=null;let r=e.split("@");return 1!==r.length?(r.length>2&&zf.throwArgumentError("invalid human-readable ABI signature","value",e),r[1].match(/^[0-9]+$/)||zf.throwArgumentError("invalid human-readable ABI signature gas","value",e),t.gas=y.BigNumber.from(r[1]),r[0]):e}function oh(e,t){t.constant=!1,t.payable=!1,t.stateMutability="nonpayable",e.split(" ").forEach((e=>{switch(e.trim()){case"constant":t.constant=!0;break;case"payable":t.payable=!0,t.stateMutability="payable";break;case"nonpayable":t.payable=!1,t.stateMutability="nonpayable";break;case"pure":t.constant=!0,t.stateMutability="pure";break;case"view":t.constant=!0,t.stateMutability="view";break;case"external":case"public":case"":break;default:console.log("unknown modifier: "+e)}}))}function ih(e){let t={constant:!1,payable:!0,stateMutability:"payable"};return null!=e.stateMutability?(t.stateMutability=e.stateMutability,t.constant="view"===t.stateMutability||"pure"===t.stateMutability,null!=e.constant&&!!e.constant!==t.constant&&zf.throwArgumentError("cannot have constant function with mutability "+t.stateMutability,"value",e),t.payable="payable"===t.stateMutability,null!=e.payable&&!!e.payable!==t.payable&&zf.throwArgumentError("cannot have payable function with mutability "+t.stateMutability,"value",e)):null!=e.payable?(t.payable=!!e.payable,null!=e.constant||t.payable||"constructor"===e.type||zf.throwArgumentError("unable to determine stateMutability","value",e),t.constant=!!e.constant,t.constant?t.stateMutability="view":t.stateMutability=t.payable?"payable":"nonpayable",t.payable&&t.constant&&zf.throwArgumentError("cannot have constant payable function","value",e)):null!=e.constant?(t.constant=!!e.constant,t.payable=!t.constant,t.stateMutability=t.constant?"view":"payable"):"constructor"!==e.type&&zf.throwArgumentError("unable to determine stateMutability","value",e),t}class sh extends th{format(e){if(e||(e=Qf.sighash),Qf[e]||zf.throwArgumentError("invalid format type","format",e),e===Qf.json)return JSON.stringify({type:"constructor",stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});e===Qf.sighash&&zf.throwError("cannot format a constructor for sighash",Cs.errors.UNSUPPORTED_OPERATION,{operation:"format(sighash)"});let t="constructor("+this.inputs.map((t=>t.format(e))).join(e===Qf.full?", ":",")+") ";return this.stateMutability&&"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "),t.trim()}static from(e){return"string"==typeof e?sh.fromString(e):sh.fromObject(e)}static fromObject(e){if(sh.isConstructorFragment(e))return e;"constructor"!==e.type&&zf.throwArgumentError("invalid constructor object","value",e);let t=ih(e);t.constant&&zf.throwArgumentError("constructor cannot be constant","value",e);const r={name:null,type:e.type,inputs:e.inputs?e.inputs.map($f.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?y.BigNumber.from(e.gas):null};return new sh(Yf,r)}static fromString(e){let t={type:"constructor"},r=(e=nh(e,t)).match(fh);return r&&"constructor"===r[1].trim()||zf.throwArgumentError("invalid constructor string","value",e),t.inputs=eh(r[2].trim(),!1),oh(r[3].trim(),t),sh.fromObject(t)}static isConstructorFragment(e){return e&&e._isFragment&&"constructor"===e.type}}class ah extends sh{format(e){if(e||(e=Qf.sighash),Qf[e]||zf.throwArgumentError("invalid format type","format",e),e===Qf.json)return JSON.stringify({type:"function",name:this.name,constant:this.constant,stateMutability:"nonpayable"!==this.stateMutability?this.stateMutability:void 0,payable:this.payable,gas:this.gas?this.gas.toNumber():void 0,inputs:this.inputs.map((t=>JSON.parse(t.format(e)))),outputs:this.outputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Qf.sighash&&(t+="function "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Qf.full?", ":",")+") ",e!==Qf.sighash&&(this.stateMutability?"nonpayable"!==this.stateMutability&&(t+=this.stateMutability+" "):this.constant&&(t+="view "),this.outputs&&this.outputs.length&&(t+="returns ("+this.outputs.map((t=>t.format(e))).join(", ")+") "),null!=this.gas&&(t+="@"+this.gas.toString()+" ")),t.trim()}static from(e){return"string"==typeof e?ah.fromString(e):ah.fromObject(e)}static fromObject(e){if(ah.isFunctionFragment(e))return e;"function"!==e.type&&zf.throwArgumentError("invalid function object","value",e);let t=ih(e);const r={type:e.type,name:ph(e.name),constant:t.constant,inputs:e.inputs?e.inputs.map($f.fromObject):[],outputs:e.outputs?e.outputs.map($f.fromObject):[],payable:t.payable,stateMutability:t.stateMutability,gas:e.gas?y.BigNumber.from(e.gas):null};return new ah(Yf,r)}static fromString(e){let t={type:"function"},r=(e=nh(e,t)).split(" returns ");r.length>2&&zf.throwArgumentError("invalid function string","value",e);let n=r[0].match(fh);if(n||zf.throwArgumentError("invalid function signature","value",e),t.name=n[1].trim(),t.name&&ph(t.name),t.inputs=eh(n[2],!1),oh(n[3].trim(),t),r.length>1){let n=r[1].match(fh);""==n[1].trim()&&""==n[3].trim()||zf.throwArgumentError("unexpected tokens","value",e),t.outputs=eh(n[2],!1)}else t.outputs=[];return ah.fromObject(t)}static isFunctionFragment(e){return e&&e._isFragment&&"function"===e.type}}function lh(e){const t=e.format();return"Error(string)"!==t&&"Panic(uint256)"!==t||zf.throwArgumentError(`cannot specify user defined ${t} error`,"fragment",e),e}class ch extends th{format(e){if(e||(e=Qf.sighash),Qf[e]||zf.throwArgumentError("invalid format type","format",e),e===Qf.json)return JSON.stringify({type:"error",name:this.name,inputs:this.inputs.map((t=>JSON.parse(t.format(e))))});let t="";return e!==Qf.sighash&&(t+="error "),t+=this.name+"("+this.inputs.map((t=>t.format(e))).join(e===Qf.full?", ":",")+") ",t.trim()}static from(e){return"string"==typeof e?ch.fromString(e):ch.fromObject(e)}static fromObject(e){if(ch.isErrorFragment(e))return e;"error"!==e.type&&zf.throwArgumentError("invalid error object","value",e);const t={type:e.type,name:ph(e.name),inputs:e.inputs?e.inputs.map($f.fromObject):[]};return lh(new ch(Yf,t))}static fromString(e){let t={type:"error"},r=e.match(fh);return r||zf.throwArgumentError("invalid error signature","value",e),t.name=r[1].trim(),t.name&&ph(t.name),t.inputs=eh(r[2],!1),lh(ch.fromObject(t))}static isErrorFragment(e){return e&&e._isFragment&&"error"===e.type}}function uh(e){return e.match(/^uint($|[^1-9])/)?e="uint256"+e.substring(4):e.match(/^int($|[^1-9])/)&&(e="int256"+e.substring(3)),e}const dh=new RegExp("^[a-zA-Z$_][a-zA-Z0-9$_]*$");function ph(e){return e&&e.match(dh)||zf.throwArgumentError(`invalid identifier "${e}"`,"value",e),e}const fh=new RegExp("^([^)(]*)\\((.*)\\)([^)(]*)$");const hh=new Cs("abi/5.7.0");class mh{constructor(e,t,r,n){this.name=e,this.type=t,this.localName=r,this.dynamic=n}_throwError(e,t){hh.throwArgumentError(e,this.localName,t)}}class gh{constructor(e){wa(this,"wordSize",e||32),this._data=[],this._dataLength=0,this._padding=new Uint8Array(e)}get data(){return Ds(this._data)}get length(){return this._dataLength}_writeData(e){return this._data.push(e),this._dataLength+=e.length,e.length}appendWriter(e){return this._writeData(js(e._data))}writeBytes(e){let t=Is(e);const r=t.length%this.wordSize;return r&&(t=js([t,this._padding.slice(r)])),this._writeData(t)}_getValue(e){let t=Is(y.BigNumber.from(e));return t.length>this.wordSize&&hh.throwError("value out-of-bounds",Cs.errors.BUFFER_OVERRUN,{length:this.wordSize,offset:t.length}),t.length%this.wordSize&&(t=js([this._padding.slice(t.length%this.wordSize),t])),t}writeValue(e){return this._writeData(this._getValue(e))}writeUpdatableValue(){const e=this._data.length;return this._data.push(this._padding),this._dataLength+=this.wordSize,t=>{this._data[e]=this._getValue(t)}}}class yh{constructor(e,t,r,n){wa(this,"_data",Is(e)),wa(this,"wordSize",t||32),wa(this,"_coerceFunc",r),wa(this,"allowLoose",n),this._offset=0}get data(){return Ps(this._data)}get consumed(){return this._offset}static coerce(e,t){let r=e.match("^u?int([0-9]+)$");return r&&parseInt(r[1])<=48&&(t=t.toNumber()),t}coerce(e,t){return this._coerceFunc?this._coerceFunc(e,t):yh.coerce(e,t)}_peekBytes(e,t,r){let n=Math.ceil(t/this.wordSize)*this.wordSize;return this._offset+n>this._data.length&&(this.allowLoose&&r&&this._offset+t<=this._data.length?n=t:hh.throwError("data out-of-bounds",Cs.errors.BUFFER_OVERRUN,{length:this._data.length,offset:this._offset+n})),this._data.slice(this._offset,this._offset+n)}subReader(e){return new yh(this._data.slice(this._offset+e),this.wordSize,this._coerceFunc,this.allowLoose)}readBytes(e,t){let r=this._peekBytes(0,e,!!t);return this._offset+=r.length,r.slice(0,e)}readValue(){return y.BigNumber.from(this.readBytes(this.wordSize))}}class bh extends mh{constructor(e){super("address","address",e,!1)}defaultValue(){return"0x0000000000000000000000000000000000000000"}encode(e,t){try{t=oa(t)}catch(e){this._throwError(e.message,t)}return e.writeValue(t)}decode(e){return oa(Us(e.readValue().toHexString(),20))}}class vh extends mh{constructor(e){super(e.name,e.type,void 0,e.dynamic),this.coder=e}defaultValue(){return this.coder.defaultValue()}encode(e,t){return this.coder.encode(e,t)}decode(e){return this.coder.decode(e)}}const xh=new Cs("abi/5.7.0");function wh(e,t,r){let n=null;if(Array.isArray(r))n=r;else if(r&&"object"==typeof r){let e={};n=t.map((t=>{const n=t.localName;return n||xh.throwError("cannot encode object for signature with missing names",Cs.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]&&xh.throwError("cannot encode object for signature with duplicate names",Cs.errors.INVALID_ARGUMENT,{argument:"values",coder:t,value:r}),e[n]=!0,r[n]}))}else xh.throwArgumentError("invalid tuple value","tuple",r);t.length!==n.length&&xh.throwArgumentError("types/value length mismatch","tuple",r);let o=new gh(e.wordSize),i=new gh(e.wordSize),s=[];t.forEach(((e,t)=>{let r=n[t];if(e.dynamic){let t=i.length;e.encode(i,r);let n=o.writeUpdatableValue();s.push((e=>{n(e+t)}))}else e.encode(o,r)})),s.forEach((e=>{e(o.length)}));let a=e.appendWriter(o);return a+=e.appendWriter(i),a}function Eh(e,t){let r=[],n=e.subReader(0);t.forEach((t=>{let o=null;if(t.dynamic){let r=e.readValue(),i=n.subReader(r.toNumber());try{o=t.decode(i)}catch(e){if(e.code===Cs.errors.BUFFER_OVERRUN)throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}}else try{o=t.decode(e)}catch(e){if(e.code===Cs.errors.BUFFER_OVERRUN)throw e;o=e,o.baseType=t.name,o.name=t.localName,o.type=t.type}null!=o&&r.push(o)}));const o=t.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});t.forEach(((e,t)=>{let n=e.localName;if(!n||1!==o[n])return;if("length"===n&&(n="_length"),null!=r[n])return;const i=r[t];i instanceof Error?Object.defineProperty(r,n,{enumerable:!0,get:()=>{throw i}}):r[n]=i}));for(let e=0;e<r.length;e++){const t=r[e];t instanceof Error&&Object.defineProperty(r,e,{enumerable:!0,get:()=>{throw t}})}return Object.freeze(r)}class Ah extends mh{constructor(e,t,r){super("array",e.type+"["+(t>=0?t:"")+"]",r,-1===t||e.dynamic),this.coder=e,this.length=t}defaultValue(){const e=this.coder.defaultValue(),t=[];for(let r=0;r<this.length;r++)t.push(e);return t}encode(e,t){Array.isArray(t)||this._throwError("expected array value",t);let r=this.length;-1===r&&(r=t.length,e.writeValue(t.length)),xh.checkArgumentCount(t.length,r,"coder array"+(this.localName?" "+this.localName:""));let n=[];for(let e=0;e<t.length;e++)n.push(this.coder);return wh(e,n,t)}decode(e){let t=this.length;-1===t&&(t=e.readValue().toNumber(),32*t>e._data.length&&xh.throwError("insufficient data length",Cs.errors.BUFFER_OVERRUN,{length:e._data.length,count:t}));let r=[];for(let e=0;e<t;e++)r.push(new vh(this.coder));return e.coerce(this.name,Eh(e,r))}}class kh extends mh{constructor(e){super("bool","bool",e,!1)}defaultValue(){return!1}encode(e,t){return e.writeValue(t?1:0)}decode(e){return e.coerce(this.type,!e.readValue().isZero())}}class Ch extends mh{constructor(e,t){super(e,e,t,!0)}defaultValue(){return"0x"}encode(e,t){t=Is(t);let r=e.writeValue(t.length);return r+=e.writeBytes(t),r}decode(e){return e.readBytes(e.readValue().toNumber(),!0)}}class Rh extends Ch{constructor(e){super("bytes",e)}decode(e){return e.coerce(this.name,Ps(super.decode(e)))}}class Sh extends mh{constructor(e,t){let r="bytes"+String(e);super(r,r,t,!1),this.size=e}defaultValue(){return"0x0000000000000000000000000000000000000000000000000000000000000000".substring(0,2+2*this.size)}encode(e,t){let r=Is(t);return r.length!==this.size&&this._throwError("incorrect data length",t),e.writeBytes(r)}decode(e){return e.coerce(this.name,Ps(e.readBytes(this.size)))}}class Th extends mh{constructor(e){super("null","",e,!1)}defaultValue(){return null}encode(e,t){return null!=t&&this._throwError("not null",t),e.writeBytes([])}decode(e){return e.readBytes(0),e.coerce(this.name,null)}}class Nh extends mh{constructor(e,t,r){const n=(t?"int":"uint")+8*e;super(n,n,r,!1),this.size=e,this.signed=t}defaultValue(){return 0}encode(e,t){let r=y.BigNumber.from(t),n=Ja.mask(8*e.wordSize);if(this.signed){let e=n.mask(8*this.size-1);(r.gt(e)||r.lt(e.add(Xa).mul(Ya)))&&this._throwError("value out-of-bounds",t)}else(r.lt(Ga)||r.gt(n.mask(8*this.size)))&&this._throwError("value out-of-bounds",t);return r=r.toTwos(8*this.size).mask(8*this.size),this.signed&&(r=r.fromTwos(8*this.size).toTwos(8*e.wordSize)),e.writeValue(r)}decode(e){let t=e.readValue().mask(8*this.size);return this.signed&&(t=t.fromTwos(8*this.size)),e.coerce(this.name,t)}}class Mh extends Ch{constructor(e){super("string",e)}defaultValue(){return""}encode(e,t){return super.encode(e,rl(t))}decode(e){return nl(super.decode(e))}}class Oh extends mh{constructor(e,t){let r=!1;const n=[];e.forEach((e=>{e.dynamic&&(r=!0),n.push(e.type)}));super("tuple","tuple("+n.join(",")+")",t,r),this.coders=e}defaultValue(){const e=[];this.coders.forEach((t=>{e.push(t.defaultValue())}));const t=this.coders.reduce(((e,t)=>{const r=t.localName;return r&&(e[r]||(e[r]=0),e[r]++),e}),{});return this.coders.forEach(((r,n)=>{let o=r.localName;o&&1===t[o]&&("length"===o&&(o="_length"),null==e[o]&&(e[o]=e[n]))})),Object.freeze(e)}encode(e,t){return wh(e,this.coders,t)}decode(e){return e.coerce(this.name,Eh(e,this.coders))}}const Ih=new Cs("abi/5.7.0"),jh=new RegExp(/^bytes([0-9]*)$/),Fh=new RegExp(/^(u?int)([0-9]*)$/);const _h=new class{constructor(e){wa(this,"coerceFunc",e||null)}_getCoder(e){switch(e.baseType){case"address":return new bh(e.name);case"bool":return new kh(e.name);case"string":return new Mh(e.name);case"bytes":return new Rh(e.name);case"array":return new Ah(this._getCoder(e.arrayChildren),e.arrayLength,e.name);case"tuple":return new Oh((e.components||[]).map((e=>this._getCoder(e))),e.name);case"":return new Th(e.name)}let t=e.type.match(Fh);if(t){let r=parseInt(t[2]||"256");return(0===r||r>256||r%8!=0)&&Ih.throwArgumentError("invalid "+t[1]+" bit length","param",e),new Nh(r/8,"int"===t[1],e.name)}if(t=e.type.match(jh),t){let r=parseInt(t[1]);return(0===r||r>32)&&Ih.throwArgumentError("invalid bytes length","param",e),new Sh(r,e.name)}return Ih.throwArgumentError("invalid type","type",e.type)}_getWordSize(){return 32}_getReader(e,t){return new yh(e,this._getWordSize(),this.coerceFunc,t)}_getWriter(){return new gh(this._getWordSize())}getDefaultValue(e){const t=e.map((e=>this._getCoder($f.from(e))));return new Oh(t,"_").defaultValue()}encode(e,t){e.length!==t.length&&Ih.throwError("types/values length mismatch",Cs.errors.INVALID_ARGUMENT,{count:{types:e.length,values:t.length},value:{types:e,values:t}});const r=e.map((e=>this._getCoder($f.from(e)))),n=new Oh(r,"_"),o=this._getWriter();return n.encode(o,t),o.data}decode(e,t,r){const n=e.map((e=>this._getCoder($f.from(e))));return new Oh(n,"_").decode(this._getReader(Is(t),r))}},Ph=new Cs("abi/5.7.0");class Bh extends Na{}class Wh extends Na{}class Dh extends Na{}class Lh extends Na{static isIndexed(e){return!(!e||!e._isIndexed)}}const Uh={"0x08c379a0":{signature:"Error(string)",name:"Error",inputs:["string"],reason:!0},"0x4e487b71":{signature:"Panic(uint256)",name:"Panic",inputs:["uint256"]}};function Vh(e,t){const r=new Error(`deferred error during ABI decoding triggered accessing ${e}`);return r.error=t,r}class Zh{constructor(e){let t=[];t="string"==typeof e?JSON.parse(e):e,wa(this,"fragments",t.map((e=>th.from(e))).filter((e=>null!=e))),wa(this,"_abiCoder",Ea(new.target,"getAbiCoder")()),wa(this,"functions",{}),wa(this,"errors",{}),wa(this,"events",{}),wa(this,"structs",{}),this.fragments.forEach((e=>{let t=null;switch(e.type){case"constructor":return this.deploy?void Ph.warn("duplicate definition - constructor"):void wa(this,"deploy",e);case"function":t=this.functions;break;case"event":t=this.events;break;case"error":t=this.errors;break;default:return}let r=e.format();t[r]?Ph.warn("duplicate definition - "+r):t[r]=e})),this.deploy||wa(this,"deploy",sh.from({payable:!1,type:"constructor"})),wa(this,"_isInterface",!0)}format(e){e||(e=Qf.full),e===Qf.sighash&&Ph.throwArgumentError("interface does not support formatting sighash","format",e);const t=this.fragments.map((t=>t.format(e)));return e===Qf.json?JSON.stringify(t.map((e=>JSON.parse(e)))):t}static getAbiCoder(){return _h}static getAddress(e){return oa(e)}static getSighash(e){return Ws(ol(e.format()),0,4)}static getEventTopic(e){return ol(e.format())}getFunction(e){if(_s(e)){for(const t in this.functions)if(e===this.getSighash(t))return this.functions[t];Ph.throwArgumentError("no matching function","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.functions).filter((e=>e.split("(")[0]===t));return 0===r.length?Ph.throwArgumentError("no matching function","name",t):r.length>1&&Ph.throwArgumentError("multiple matching functions","name",t),this.functions[r[0]]}const t=this.functions[ah.fromString(e).format()];return t||Ph.throwArgumentError("no matching function","signature",e),t}getEvent(e){if(_s(e)){const t=e.toLowerCase();for(const e in this.events)if(t===this.getEventTopic(e))return this.events[e];Ph.throwArgumentError("no matching event","topichash",t)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.events).filter((e=>e.split("(")[0]===t));return 0===r.length?Ph.throwArgumentError("no matching event","name",t):r.length>1&&Ph.throwArgumentError("multiple matching events","name",t),this.events[r[0]]}const t=this.events[rh.fromString(e).format()];return t||Ph.throwArgumentError("no matching event","signature",e),t}getError(e){if(_s(e)){const t=Ea(this.constructor,"getSighash");for(const r in this.errors){if(e===t(this.errors[r]))return this.errors[r]}Ph.throwArgumentError("no matching error","sighash",e)}if(-1===e.indexOf("(")){const t=e.trim(),r=Object.keys(this.errors).filter((e=>e.split("(")[0]===t));return 0===r.length?Ph.throwArgumentError("no matching error","name",t):r.length>1&&Ph.throwArgumentError("multiple matching errors","name",t),this.errors[r[0]]}const t=this.errors[ah.fromString(e).format()];return t||Ph.throwArgumentError("no matching error","signature",e),t}getSighash(e){if("string"==typeof e)try{e=this.getFunction(e)}catch(t){try{e=this.getError(e)}catch(e){throw t}}return Ea(this.constructor,"getSighash")(e)}getEventTopic(e){return"string"==typeof e&&(e=this.getEvent(e)),Ea(this.constructor,"getEventTopic")(e)}_decodeParams(e,t){return this._abiCoder.decode(e,t)}_encodeParams(e,t){return this._abiCoder.encode(e,t)}encodeDeploy(e){return this._encodeParams(this.deploy.inputs,e||[])}decodeErrorResult(e,t){"string"==typeof e&&(e=this.getError(e));const r=Is(t);return Ps(r.slice(0,4))!==this.getSighash(e)&&Ph.throwArgumentError(`data signature does not match error ${e.name}.`,"data",Ps(r)),this._decodeParams(e.inputs,r.slice(4))}encodeErrorResult(e,t){return"string"==typeof e&&(e=this.getError(e)),Ps(js([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionData(e,t){"string"==typeof e&&(e=this.getFunction(e));const r=Is(t);return Ps(r.slice(0,4))!==this.getSighash(e)&&Ph.throwArgumentError(`data signature does not match function ${e.name}.`,"data",Ps(r)),this._decodeParams(e.inputs,r.slice(4))}encodeFunctionData(e,t){return"string"==typeof e&&(e=this.getFunction(e)),Ps(js([this.getSighash(e),this._encodeParams(e.inputs,t||[])]))}decodeFunctionResult(e,t){"string"==typeof e&&(e=this.getFunction(e));let r=Is(t),n=null,o="",i=null,s=null,a=null;switch(r.length%this._abiCoder._getWordSize()){case 0:try{return this._abiCoder.decode(e.outputs,r)}catch(e){}break;case 4:{const e=Ps(r.slice(0,4)),t=Uh[e];if(t)i=this._abiCoder.decode(t.inputs,r.slice(4)),s=t.name,a=t.signature,t.reason&&(n=i[0]),"Error"===s?o=`; VM Exception while processing transaction: reverted with reason string ${JSON.stringify(i[0])}`:"Panic"===s&&(o=`; VM Exception while processing transaction: reverted with panic code ${i[0]}`);else try{const t=this.getError(e);i=this._abiCoder.decode(t.inputs,r.slice(4)),s=t.name,a=t.format()}catch(e){}break}}return Ph.throwError("call revert exception"+o,Cs.errors.CALL_EXCEPTION,{method:e.format(),data:Ps(t),errorArgs:i,errorName:s,errorSignature:a,reason:n})}encodeFunctionResult(e,t){return"string"==typeof e&&(e=this.getFunction(e)),Ps(this._abiCoder.encode(e.outputs,t||[]))}encodeFilterTopics(e,t){"string"==typeof e&&(e=this.getEvent(e)),t.length>e.inputs.length&&Ph.throwError("too many arguments for "+e.format(),Cs.errors.UNEXPECTED_ARGUMENT,{argument:"values",value:t});let r=[];e.anonymous||r.push(this.getEventTopic(e));const n=(e,t)=>"string"===e.type?ol(t):"bytes"===e.type?zs(Ps(t)):("bool"===e.type&&"boolean"==typeof t&&(t=t?"0x01":"0x00"),e.type.match(/^u?int/)&&(t=y.BigNumber.from(t).toHexString()),"address"===e.type&&this._abiCoder.encode(["address"],[t]),Us(Ps(t),32));for(t.forEach(((t,o)=>{let i=e.inputs[o];i.indexed?null==t?r.push(null):"array"===i.baseType||"tuple"===i.baseType?Ph.throwArgumentError("filtering with tuples or arrays not supported","contract."+i.name,t):Array.isArray(t)?r.push(t.map((e=>n(i,e)))):r.push(n(i,t)):null!=t&&Ph.throwArgumentError("cannot filter non-indexed parameters; must be null","contract."+i.name,t)}));r.length&&null===r[r.length-1];)r.pop();return r}encodeEventLog(e,t){"string"==typeof e&&(e=this.getEvent(e));const r=[],n=[],o=[];return e.anonymous||r.push(this.getEventTopic(e)),t.length!==e.inputs.length&&Ph.throwArgumentError("event arguments/values mismatch","values",t),e.inputs.forEach(((e,i)=>{const s=t[i];if(e.indexed)if("string"===e.type)r.push(ol(s));else if("bytes"===e.type)r.push(zs(s));else{if("tuple"===e.baseType||"array"===e.baseType)throw new Error("not implemented");r.push(this._abiCoder.encode([e.type],[s]))}else n.push(e),o.push(s)})),{data:this._abiCoder.encode(n,o),topics:r}}decodeEventLog(e,t,r){if("string"==typeof e&&(e=this.getEvent(e)),null!=r&&!e.anonymous){let t=this.getEventTopic(e);_s(r[0],32)&&r[0].toLowerCase()===t||Ph.throwError("fragment/topic mismatch",Cs.errors.INVALID_ARGUMENT,{argument:"topics[0]",expected:t,value:r[0]}),r=r.slice(1)}let n=[],o=[],i=[];e.inputs.forEach(((e,t)=>{e.indexed?"string"===e.type||"bytes"===e.type||"tuple"===e.baseType||"array"===e.baseType?(n.push($f.fromObject({type:"bytes32",name:e.name})),i.push(!0)):(n.push(e),i.push(!1)):(o.push(e),i.push(!1))}));let s=null!=r?this._abiCoder.decode(n,js(r)):null,a=this._abiCoder.decode(o,t,!0),l=[],c=0,u=0;e.inputs.forEach(((e,t)=>{if(e.indexed)if(null==s)l[t]=new Lh({_isIndexed:!0,hash:null});else if(i[t])l[t]=new Lh({_isIndexed:!0,hash:s[u++]});else try{l[t]=s[u++]}catch(e){l[t]=e}else try{l[t]=a[c++]}catch(e){l[t]=e}if(e.name&&null==l[e.name]){const r=l[t];r instanceof Error?Object.defineProperty(l,e.name,{enumerable:!0,get:()=>{throw Vh(`property ${JSON.stringify(e.name)}`,r)}}):l[e.name]=r}}));for(let e=0;e<l.length;e++){const t=l[e];t instanceof Error&&Object.defineProperty(l,e,{enumerable:!0,get:()=>{throw Vh(`index ${e}`,t)}})}return Object.freeze(l)}parseTransaction(e){let t=this.getFunction(e.data.substring(0,10).toLowerCase());return t?new Wh({args:this._abiCoder.decode(t.inputs,"0x"+e.data.substring(10)),functionFragment:t,name:t.name,signature:t.format(),sighash:this.getSighash(t),value:y.BigNumber.from(e.value||"0")}):null}parseLog(e){let t=this.getEvent(e.topics[0]);return!t||t.anonymous?null:new Bh({eventFragment:t,name:t.name,signature:t.format(),topic:this.getEventTopic(t),args:this.decodeEventLog(t,e.data,e.topics)})}parseError(e){const t=Ps(e);let r=this.getError(t.substring(0,10).toLowerCase());return r?new Dh({args:this._abiCoder.decode(r.inputs,"0x"+t.substring(10)),errorFragment:r,name:r.name,signature:r.format(),sighash:this.getSighash(r)}):null}static isInterface(e){return!(!e||!e._isInterface)}}function Hh(e,t,...r){return ma(this,void 0,void 0,(function*(){const n=[];for(const e of r)for(const t of e)t.callData&&n.push(t.callData);const o=yield function(e,t,r){return ma(this,void 0,void 0,(function*(){const n=yield zh(e,t,r),o=new Map;for(const{req:e,resp:t}of n)o.set(e,t);return e.map((e=>({req:e,resp:o.get(e)})))}))}(n,e,t),i=new Map;for(const{req:e,resp:t}of o)i.set(e,null==t?void 0:t.result);return r.map((e=>e.filter((e=>!e.callData||i.get(e.callData))).map(((e,t)=>e.processor(e.callData?i.get(e.callData):null,t)))))}))}function zh(e,t,n){return ma(this,void 0,void 0,(function*(){let o=[e];e.length>800&&(o=r.chunk(e,800));let i=[];const s=o.map((e=>ma(this,void 0,void 0,(function*(){const r=e.map((e=>[e.to,e.data])),o={data:t.interface.encodeFunctionData("aggregate",[r]),to:n};let s;try{s=yield t.provider.call(o)}catch(r){const o=e.length;if(o>20){const r=Math.floor(o/2),[s,a]=yield Promise.all([zh(e.slice(0,r),t,n),zh(e.slice(r,o),t,n)]);i=[...i,...s,...a]}else{const e="[sendCallReqs] error";console.error(e,r)}}if(void 0===s)throw new Error("Unexpected batch result");const[a,l]=_h.decode(["uint256","bytes[]"],s);if(e.length!==l.length)throw new Error("Unexpected length mismatch");return l.map(((t,r)=>({resp:{result:t},req:e[r]})))}))));return(yield Promise.allSettled(s)).filter((e=>"fulfilled"===e.status)).forEach((({value:e})=>{i=[...i,...e]})),i}))}function Yh(e,t,r,n){if(!function(e){try{return oa(e)}catch(e){return!1}}(e)||e===za)throw Error(`Invalid 'address' parameter '${e}'.`);return new b.Contract(e,t,function(e,t){return t?function(e,t){return e.getSigner(t).connectUnchecked()}(e,t):e}(r,n))}function Gh(e){const{provider:t,account:r,chainId:o}=u.useWeb3React(),[i,s]=n.useState(!1),a=n.useMemo((()=>Hf[null!=e?e:o]),[o,e]),c=l.useSelector(Uf).jsonRpcUrlMap,d=n.useCallback(((n,i)=>{if(e&&e!==o){const t=Object.assign(Object.assign({},sa),c)[e],r=new nf(null==t?void 0:t[0]);return new b.Contract(n,i,r)}if(t)return Yh(n,i,t,r)}),[t,r,e,c]),p=n.useCallback((e=>{if(!a)return;const{MULTI_CALL:t}=a,r=d(t,Zf);return(()=>ma(this,void 0,void 0,(function*(){if(r){s(!0);try{const[n]=yield Hh(r,t,e);return n}catch(e){console.error("Contract: useMultiContract is error",e)}s(!1)}})))()}),[a,d]);return{getContract:d,contractConfig:a,call:p,loading:i}}var Xh=[{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"user",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"isERC20",outputs:[{internalType:"bool",name:"isOk",type:"bool"},{internalType:"string",name:"symbol",type:"string"},{internalType:"string",name:"name",type:"string"},{internalType:"uint256",name:"decimals",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"allownance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"token",type:"address"},{internalType:"address",name:"user",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"judgeERC20",outputs:[{internalType:"string",name:"symbol",type:"string"},{internalType:"string",name:"name",type:"string"},{internalType:"uint256",name:"decimals",type:"uint256"},{internalType:"uint256",name:"balance",type:"uint256"},{internalType:"uint256",name:"allownance",type:"uint256"}],stateMutability:"view",type:"function"}];function Jh({tokenList:e,addresses:t,blockNumber:r,chainId:o,skip:i}){const{account:s}=u.useWeb3React(),a=l.useDispatch(),c=n.useMemo((()=>[...(null==e?void 0:e.map((e=>e.address)))||[],...t||[]].map((e=>e.toLocaleLowerCase()))),[e,JSON.stringify(t)]),{getContract:d,contractConfig:p,call:f}=Gh(o),[h,m]=n.useState(),g=n.useMemo((()=>{if(!s||!c.length||!p)return;const{DODO_APPROVE:e,ERC20_HELPER:t}=p,r=d(t,Xh);if(!r)return;return c.map((n=>({callData:{data:r.interface.encodeFunctionData("isERC20",[n,s,e]),to:t},processor:e=>{const t=new Zh(Xh).decodeFunctionResult("isERC20",e),{balance:r,isOk:o}=t,i=parseInt(t.decimals),s=new C.default(10).pow(i),a=new C.default(t.allownance.toString()).div(s);return o?{address:n,decimals:i,symbol:t.symbol,name:t.name,balance:new C.default(r.toString()).div(s),allowance:a}:{address:n,balance:new C.default(0),allowance:new C.default(0)}}})))}),[s,d,JSON.stringify(c)]);return n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){if(!g||i)return;let e={};c.forEach((t=>{e[t]=!0})),a(ba(e));const t=yield f(g),r={};t&&(t.forEach((e=>{e.address.toLocaleLowerCase()!=="0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE".toLocaleLowerCase()&&(r[e.address.toLocaleLowerCase()]={tokenBalances:e.balance,tokenAllowances:e.allowance})})),a(ya(r))),m(t),c.forEach((t=>{e[t]=!1})),a(ba(e))}))})()}),[g,r,i]),{data:h}}function qh(e){const{provider:t,account:r,chainId:o}=u.useWeb3React(),i=l.useDispatch(),s=l.useSelector(Mf),a=l.useSelector(Uf).jsonRpcUrlMap;n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){if(t&&r)if(e&&e!==o){const t=Object.assign(Object.assign({},sa),a)[e],n=new nf(null==t?void 0:t[0]),o=yield n.getBalance(r);o&&i(ga(e,new C.default(o.toString()).div(1e18)))}else{const e=yield t.getBalance(r);i(ga(null!=o?o:1,new C.default(e.toString()).div(1e18)))}}))})()}),[t,r,i,s,e])}function Qh(){const{provider:e,chainId:t}=u.useWeb3React(),r=l.useDispatch(),o=n.useCallback((()=>ma(this,void 0,void 0,(function*(){if(!e||!t)return;const n=yield e.getBlockNumber();r((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_BLOCK_NUMBER",payload:e})})))(n))}))),[e,t]);return{updateBlockNumber:o}}var Kh,$h=[{constant:!0,inputs:[],name:"totalSupply",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!1,inputs:[{name:"_to",type:"address"},{name:"_value",type:"uint256"}],name:"transfer",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!1,inputs:[{name:"guy",type:"address"},{name:"wad",type:"uint256"}],name:"approve",outputs:[{name:"",type:"bool"}],payable:!1,stateMutability:"nonpayable",type:"function"},{constant:!0,inputs:[],name:"symbol",outputs:[{name:"",type:"string"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"_owner",type:"address"}],name:"balanceOf",outputs:[{name:"balance",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"},{constant:!0,inputs:[{name:"_owner",type:"address"},{name:"_spender",type:"address"}],name:"allowance",outputs:[{name:"",type:"uint256"}],payable:!1,stateMutability:"view",type:"function"}];function em(e,t,r,n=0){if(r&&(e=e.toLocaleLowerCase(),t=t.toLocaleLowerCase()),e===t)return Kh.fully+n;const o=e.indexOf(t);return 0===o?Kh.prefix+n:o>0?Kh.other+n:Kh.none}!function(e){e[e.fully=1]="fully",e[e.prefix=2]="prefix",e[e.other=3]="other",e[e.none=0]="none"}(Kh||(Kh={}));function tm({value:e,onChange:t,occupiedAddrs:r,hiddenAddrs:o,showAddrs:i,side:s,chainId:a,visible:c,defaultLoadBalance:u}){const[d,p]=n.useState(""),f=l.useSelector(Ff),h=Of(),m=n.useMemo((()=>null!=a?a:h),[a,h]),g=Lf(),y=n.useMemo((()=>{const e=f.filter((e=>e.chainId===m));return e}),[f,m]),b=l.useSelector((e=>((e,t)=>(null!=t?t:Tf.getState()).token.popularTokenList.filter((({chainId:t})=>e===t)))(m,e))),v=n.useMemo((()=>(null==If?void 0:If.filter((e=>e.chainId===m)))||[]),[If,m]),x=n.useMemo((()=>new Set(o?o.map((e=>e.toLowerCase())):void 0)),[o]),w=n.useMemo((()=>i?new Set(i.map((e=>e.toLowerCase()))):void 0),[i]),E=n.useCallback((e=>e.filter((e=>{if(e.chainId!==m)return!1;let t=!0;return t=w?w.has(e.address.toLowerCase()):!x.has(e.address.toLowerCase()),t&&s&&(t=!e.side||e.side===s),t}))),[w,m,x]),A=n.useMemo((()=>E(b)),[b,E]),k=n.useCallback((t=>{if(null===t)return null;const n=[];d?t.forEach((e=>{const t=((e,t,{matchAddress:r}={})=>{if(!t)return 0;const n=t.toLocaleLowerCase();let o=0;r&&e.address.toLocaleLowerCase()===n&&(o=1),o||(o=em(e.symbol.toLocaleLowerCase(),n,!1,1));if(o)e.name.toLocaleLowerCase()===n&&(o=Kh.fully+1);else{let t=em(e.name.toLocaleLowerCase(),n,!1,10);t=t===Kh.fully+10?Kh.fully+1:t,o=t}return o})(e,d,{matchAddress:!0});t&&n.push({sort:t,token:e})})):t.forEach((e=>{n.push({sort:0,token:e})}));const o=[];return n.sort(((t,n)=>{const o=t.token,i=n.token;if(e){if(o.address===e.address)return-1;if(i.address===e.address)return 1}if(null==r?void 0:r.includes(o.address))return-1;if(null==r?void 0:r.includes(i.address))return 1;const s=g&&g(o)||new C.default(0),a=g&&g(i)||new C.default(0),l=A.map((e=>e.address));if(null==l?void 0:l.includes(o.address))return-1;if(null==l?void 0:l.includes(i.address))return 1;if(!s.eq(a))return s.gt(a)?-1:1;if(t.sort!==n.sort)return t.sort>n.sort?1:-1;const c=v.map((e=>e.address));return(null==c?void 0:c.includes(o.address))?-1:(null==c?void 0:c.includes(i.address))?1:o.symbol.localeCompare(i.symbol)})).some((e=>!!(d&&o.length>21)||(o.push(e.token),!1))),o}),[d,g,r,e,A,v]),R=n.useCallback((e=>{const n=e.address.toLowerCase();t(e,!!(null==r?void 0:r.some((e=>e.toLowerCase()===n))))}),[t,r]),S=n.useMemo((()=>{const e=E(y),t=new Set;return e.forEach((e=>{t.add(e.address)})),A.forEach((r=>{t.has(r.address)||e.push(r)})),k(e)||[]}),[y,E,k,A]);return function({chainId:e,value:t,tokenList:r,popularTokenList:o,visible:i,defaultLoadBalance:s}){const a=l.useSelector(Vf),c=l.useSelector(Mf),u=n.useMemo((()=>{if(void 0===a||a)return[];const t=new Set;return r.forEach((r=>{r.chainId===e&&t.add(r.address)})),null==o||o.forEach((r=>{r.chainId===e&&t.add(r.address)})),Array.from(t)}),[r,o,e,a]),d=n.useMemo((()=>t?[t.address]:[]),[t]),p=n.useMemo((()=>{var r;return null!==(r=null==t?void 0:t.chainId)&&void 0!==r?r:e}),[null==t?void 0:t.chainId,e]);Jh({addresses:u,chainId:e,skip:!1===i&&!s}),qh(e),Jh({addresses:d,chainId:p,blockNumber:c})}({chainId:m,tokenList:S,popularTokenList:A,value:e,visible:c,defaultLoadBalance:u}),{filter:d,setFilter:p,showTokenList:S,onSelectToken:R,popularTokenList:A}}var rm,nm;function om(){return om=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},om.apply(this,arguments)}var im,sm,am,lm,cm,um=function(e){return S.createElement("svg",om({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),rm||(rm=S.createElement("g",{clipPath:"url(#clip0_5431_179637)"},S.createElement("path",{d:"M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z",fill:"#F2F4F7"}),S.createElement("path",{d:"M12.3735 3V9.6525L17.9963 12.165L12.3735 3Z",fill:"#343434"}),S.createElement("path",{d:"M12.3735 3L6.75 12.165L12.3735 9.6525V3Z",fill:"#8C8C8C"}),S.createElement("path",{d:"M12.3735 16.4759V20.9962L18 13.2119L12.3735 16.4759Z",fill:"#3C3C3B"}),S.createElement("path",{d:"M12.3735 20.9962V16.4752L6.75 13.2119L12.3735 20.9962Z",fill:"#8C8C8C"}),S.createElement("path",{d:"M12.3735 15.4298L17.9963 12.1651L12.3735 9.65405V15.4298Z",fill:"#141414"}),S.createElement("path",{d:"M6.75 12.1651L12.3735 15.4298V9.65405L6.75 12.1651Z",fill:"#393939"}))),nm||(nm=S.createElement("defs",null,S.createElement("clipPath",{id:"clip0_5431_179637"},S.createElement("rect",{width:24,height:24,fill:"white"})))))};function dm(){return dm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},dm.apply(this,arguments)}var pm,fm;function hm(){return hm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},hm.apply(this,arguments)}var mm,gm,ym;function bm(){return bm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},bm.apply(this,arguments)}var vm,xm;function wm(){return wm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},wm.apply(this,arguments)}var Em,Am;function km(){return km=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},km.apply(this,arguments)}var Cm;function Rm(){return Rm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Rm.apply(this,arguments)}var Sm,Tm;function Nm(){return Nm=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Nm.apply(this,arguments)}var Mm;function Om(){return Om=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Om.apply(this,arguments)}const Im={[ia.MAINNET]:{chainId:ia.MAINNET,logo:um,name:"Ethereum"},[ia.GOERLI]:{chainId:ia.GOERLI,logo:um,name:"Goerli",mainnet:ia.MAINNET},[ia.ARBITRUM_ONE]:{chainId:ia.ARBITRUM_ONE,logo:function(e){return S.createElement("svg",dm({height:"692pt",viewBox:"0 0 619 692",width:"619pt",xmlns:"http://www.w3.org/2000/svg"},e),im||(im=S.createElement("path",{d:"m280.46 17.3c18.85-10.03 43.1-9.37 61.23 1.99 78.77 45.29 157.52 90.59 236.28 135.88 17.98 10.27 30.16 30.12 30.76 50.87v275.89c.49 19.03-8.56 38.11-23.76 49.6-83.95 48.66-167.91 97.29-251.9 145.88-14.93 5.88-32.32 5.81-47.05-.66-10.1-5.39-19.93-11.25-29.88-16.91-25.72-14.85-51.49-29.62-77.2-44.49 7.13-11.82 13.88-23.88 21.17-35.61 34.11 19.55 68.15 39.21 102.24 58.77 5.43 2.44 12.28 2.51 17.36-.81 28.11-16.31 56.23-32.61 84.36-48.89 28.58-16.52 57.15-33.07 85.69-49.67 7.92-4.6 15.84-9.2 23.78-13.77 14.97-8.59 29.86-17.33 44.83-25.93 5.77-3.22 8.74-10.05 8.75-16.47-.04-14.36.09-28.73-.07-43.09.18-76.95.01-153.9.09-230.85.24-7.26-3.78-14.44-10.07-18.06-79.37-45.64-158.72-91.3-238.08-136.94-6.26-3.47-14.38-3.15-20.42.66-78.73 45.56-157.48 91.1-236.15 136.78-6.59 3.53-10.68 11.06-10.31 18.5.21 73.45.1 146.9.48 220.34-12.68 20.02-25.84 39.75-38.67 59.68-.95 1.49-1.95 2.96-3.1 4.31-.23-95.74-.02-191.5-.1-287.25.31-22.52 14.44-43.97 34.72-53.61 78.35-45.36 156.61-90.87 235.02-136.14z",fill:"#8cbfdf"})),sm||(sm=S.createElement("path",{d:"m298.57 54.69c6.04-3.81 14.16-4.13 20.42-.66 79.36 45.64 158.71 91.3 238.08 136.94 6.29 3.62 10.31 10.8 10.07 18.06-.08 76.95.09 153.9-.09 230.85-6.25-8.84-11.77-18.21-17.74-27.25-38.11-59.38-76.26-118.73-114.34-178.12l-.71.13c-16.14 27.89-32.81 55.48-48.94 83.38 42.77 69.1 85.49 138.23 128.22 207.35-7.94 4.57-15.86 9.17-23.78 13.77-40.35-63.61-80.71-127.22-121.07-190.83l-.73-.41c-19.01 31.61-37.43 63.61-56.36 95.28 4.29 7.87 9.61 15.25 14.3 22.94 26.05 40.9 52.13 81.79 78.17 122.69-28.13 16.28-56.25 32.58-84.36 48.89-5.08 3.32-11.93 3.25-17.36.81-34.09-19.56-68.13-39.22-102.24-58.77 73.38-124.27 146.6-248.63 219.92-372.94l-.41-.3c-25.22.18-50.45.2-75.67.29-7.21.39-14.55-.37-21.69.39-73.43 121.29-146.88 242.57-220.46 363.77-8.47-4.83-16.92-9.69-25.34-14.61 19.61-32.21 39.88-64.05 59.74-96.12 51.98-83.37 103.96-166.73 155.94-250.1.66-1.19 1.78-2.22 1.79-3.66-13.31-.19-26.61-.72-39.92-.97-20.59.3-41.98 3.68-59.65 14.9-6.98 4.5-13.13 10.36-17.61 17.37-41.35 64.21-82.86 128.31-124.16 192.55-.38-73.44-.27-146.89-.48-220.34-.37-7.44 3.72-14.97 10.31-18.5 78.67-45.68 157.42-91.22 236.15-136.78z",fill:"#2b374d"})),am||(am=S.createElement("path",{d:"m194.36 220.39c17.67-11.22 39.06-14.6 59.65-14.9 13.31.25 26.61.78 39.92.97-.01 1.44-1.13 2.47-1.79 3.66-51.98 83.37-103.96 166.73-155.94 250.1-19.86 32.07-40.13 63.91-59.74 96.12-13.05-7.52-26.09-15.05-39.14-22.57-9.44-4.83-16.23-13.58-21.12-22.76-2.5-5.29-4.79-10.85-5.38-16.71 1.15-1.35 2.15-2.82 3.1-4.31 12.83-19.93 25.99-39.66 38.67-59.68 41.3-64.24 82.81-128.34 124.16-192.55 4.48-7.01 10.63-12.87 17.61-17.37z",fill:"#fff"})),lm||(lm=S.createElement("path",{d:"m343.95 206.79c25.22-.09 50.45-.11 75.67-.29l.41.3c-73.32 124.31-146.54 248.67-219.92 372.94-7.29 11.73-14.04 23.79-21.17 35.61-25.73-14.78-51.42-29.61-77.14-44.4 73.58-121.2 147.03-242.48 220.46-363.77 7.14-.76 14.48 0 21.69-.39z",fill:"#fff"})),cm||(cm=S.createElement("g",{fill:"#00a2f7"},S.createElement("path",{d:"m434.26 234.64.71-.13c38.08 59.39 76.23 118.74 114.34 178.12 5.97 9.04 11.49 18.41 17.74 27.25.16 14.36.03 28.73.07 43.09-.01 6.42-2.98 13.25-8.75 16.47-14.97 8.6-29.86 17.34-44.83 25.93-42.73-69.12-85.45-138.25-128.22-207.35 16.13-27.9 32.8-55.49 48.94-83.38z"}),S.createElement("path",{d:"m311.6 443.18c18.93-31.67 37.35-63.67 56.36-95.28l.73.41c40.36 63.61 80.72 127.22 121.07 190.83-28.54 16.6-57.11 33.15-85.69 49.67-26.04-40.9-52.12-81.79-78.17-122.69-4.69-7.69-10.01-15.07-14.3-22.94z"}))))},name:"Arbitrum"},[ia.POLYGON]:{chainId:ia.POLYGON,logo:function(e){return S.createElement("svg",hm({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),pm||(pm=S.createElement("defs",null,S.createElement("circle",{id:"path-1",cx:12,cy:12,r:12}))),fm||(fm=S.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},S.createElement("g",{transform:"translate(-223.000000, -266.000000)"},S.createElement("g",{transform:"translate(18.000000, 132.000000)"},S.createElement("g",{transform:"translate(20.000000, 41.000000)"},S.createElement("g",{transform:"translate(156.000000, 82.000000)"},S.createElement("g",{transform:"translate(29.000000, 11.000000)"},S.createElement("mask",{id:"mask-2",fill:"white"},S.createElement("use",{xlinkHref:"#path-1"})),S.createElement("g",null),S.createElement("g",{mask:"url(#mask-2)"},S.createElement("circle",{fill:"#8247E5",fillRule:"nonzero",cx:12,cy:12,r:12}),S.createElement("path",{d:"M8.01148,5.30068 C8.25312,5.16644 8.54688,5.16644 8.78852,5.30068 L12.38852,7.30068 C12.64248,7.44176 12.8,7.70948 12.8,8 L12.8,9.30068 L11.2,10.2 L11.2,8.47072 L8.4,6.91516 L5.6,8.47072 L5.6,11.52928 L8.4,13.08484 L15.21148,9.30068 C15.45312,9.16644 15.74688,9.16644 15.98852,9.30068 L19.58852,11.30068 C19.84248,11.44176 20,11.70948 20,12 L20,16 C20,16.29052 19.84248,16.55824 19.58852,16.69932 L15.98852,18.69932 C15.74688,18.83356 15.45312,18.83356 15.21148,18.69932 L11.61148,16.69932 C11.35752,16.55824 11.2,16.29052 11.2,16 L11.2,14.69932 L12.8,13.8 L12.8,15.52928 L15.6,17.08484 L18.4,15.52928 L18.4,12.47072 L15.6,10.91516 L8.78852,14.69932 C8.54688,14.83356 8.25312,14.83356 8.01148,14.69932 L4.41148,12.69932 C4.15752,12.55824 4,12.29052 4,12 L4,8 C4,7.70948 4.15752,7.44176 4.41148,7.30068 L8.01148,5.30068 Z",fill:"#FFFFFF"}))))))))))},name:"Polygon"},[ia.BSC]:{chainId:ia.BSC,logo:function(e){return S.createElement("svg",bm({xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:"7.5in",height:"7.5in",style:{shapeRendering:"geometricPrecision",textRendering:"geometricPrecision",imageRendering:"optimizeQuality",fillRule:"evenodd",clipRule:"evenodd"},viewBox:"0 0 7500 7500"},e),mm||(mm=S.createElement("defs",null,S.createElement("style",{type:"text/css"},".fil0 {fill:none}\n .fil1 {fill:#f0b90b}\n .fil2 {fill:#fff}"))),gm||(gm=S.createElement("g",{id:"Layer_x0020_1"},S.createElement("metadata",{id:"CorelCorpID_0Corel-Layer"}),S.createElement("rect",{className:"fil0",width:7500,height:7500}),S.createElement("g",{id:"_2419820813232"},S.createElement("circle",{className:"fil1",cx:3750,cy:3750,r:3500}),S.createElement("g",null,S.createElement("path",{className:"fil2",d:"M2779 3351l971 -971 971 972 565 -565 -1536 -1537 -1536 1536 565 565 0 0zm-1529 399l565 -565 565 565 -565 565 -565 -565zm1529 399l971 971 971 -972 566 565 0 0 -1537 1537 -1536 -1536 -1 -1 566 -564 0 0zm2341 -399l565 -565 565 565 -565 565 -565 -565z"})),S.createElement("g",null,S.createElement("path",{className:"fil2",d:"M4380 3750l0 0 -630 -632 -466 467 0 0 -54 54 -111 111 -1 1 1 1 630 630 631 -631 0 0 0 0 0 -1zm0 0l0 0 0 0z"}))))),ym||(ym=S.createElement("style",{xmlns:""},"#yddContainer{display:block;font-family:Microsoft YaHei;position:relative;width:100%;height:100%;top:-4px;left:-4px;font-size:12px;border:1px solid}#yddTop{display:block;height:22px}#yddTopBorderlr{display:block;position:static;height:17px;padding:2px 28px;line-height:17px;font-size:12px;color:#5079bb;font-weight:bold;border-style:none solid;border-width:1px}#yddTopBorderlr .ydd-sp{position:absolute;top:2px;height:0;overflow:hidden}.ydd-icon{left:5px;width:17px;padding:0px 0px 0px 0px;padding-top:17px;background-position:-16px -44px}.ydd-close{right:5px;width:16px;padding-top:16px;background-position:left -44px}#yddKeyTitle{float:left;text-decoration:none}#yddMiddle{display:block;margin-bottom:10px}.ydd-tabs{display:block;margin:5px 0;padding:0 5px;height:18px;border-bottom:1px solid}.ydd-tab{display:block;float:left;height:18px;margin:0 5px -1px 0;padding:0 4px;line-height:18px;border:1px solid;border-bottom:none}.ydd-trans-container{display:block;line-height:160%}.ydd-trans-container a{text-decoration:none;}#yddBottom{position:absolute;bottom:0;left:0;width:100%;height:22px;line-height:22px;overflow:hidden;background-position:left -22px}.ydd-padding010{padding:0 10px}#yddWrapper{color:#252525;z-index:10001;background:url(chrome-extension://eopjamdnofihpioajgfdikhhbobonhbb/ab20.png);}#yddContainer{background:#fff;border-color:#4b7598}#yddTopBorderlr{border-color:#f0f8fc}#yddWrapper .ydd-sp{background-image:url(chrome-extension://eopjamdnofihpioajgfdikhhbobonhbb/ydd-sprite.png)}#yddWrapper a,#yddWrapper a:hover,#yddWrapper a:visited{color:#50799b}#yddWrapper .ydd-tabs{color:#959595}.ydd-tabs,.ydd-tab{background:#fff;border-color:#d5e7f3}#yddBottom{color:#363636}#yddWrapper{min-width:250px;max-width:400px;}")))},name:"BNBChain"},[ia.OPTIMISM]:{chainId:ia.OPTIMISM,logo:function(e){return S.createElement("svg",wm({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),vm||(vm=S.createElement("defs",null,S.createElement("circle",{id:"path-1",cx:12,cy:12,r:12}))),xm||(xm=S.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},S.createElement("g",{transform:"translate(-223.000000, -266.000000)"},S.createElement("g",{transform:"translate(18.000000, 132.000000)"},S.createElement("g",{transform:"translate(20.000000, 41.000000)"},S.createElement("g",{transform:"translate(156.000000, 82.000000)"},S.createElement("g",{transform:"translate(29.000000, 11.000000)"},S.createElement("mask",{id:"mask-2",fill:"white"},S.createElement("use",{xlinkHref:"#path-1"})),S.createElement("g",null),S.createElement("g",{id:"optimism.caeb9392",mask:"url(#mask-2)",fillRule:"nonzero"},S.createElement("circle",{fill:"#FF0420",cx:12,cy:12,r:12}),S.createElement("path",{d:"M7.85495544,16 C7.01608475,16 6.32880363,15.7925669 5.7930557,15.37776 C5.2643519,14.9555511 5,14.3555763 5,13.5777763 C5,13.4148143 5.01763849,13.2147832 5.05285911,12.9777422 C5.14454543,12.4444444 5.27494626,11.8036699 5.44411795,11.0555371 C5.92345653,9.01851235 7.16063019,8 9.15558257,8 C9.69837462,8 10.1847573,8.09628495 10.614787,8.28885484 C11.0448167,8.47402275 11.3831601,8.75553483 11.6298735,9.13333185 C11.8765869,9.50366768 12,9.94814173 12,10.4666356 C12,10.6221956 11.9823615,10.8184961 11.9470845,11.0555371 C11.8413663,11.7147869 11.7144594,12.3555615 11.5664201,12.9777422 C11.3197066,13.9925832 10.8932272,14.7518486 10.2869817,15.2555385 C9.68073613,15.7518264 8.8700983,16 7.85495544,16 Z M8.00299476,14.3999882 C8.39780384,14.3999882 8.73259699,14.2777667 9.00754325,14.0333237 C9.28953364,13.7888807 9.49043207,13.4148143 9.61023853,12.9111244 C9.7723661,12.2148054 9.89577916,11.6073694 9.98036501,11.0888756 C10.0085415,10.9333156 10.0226298,10.7740842 10.0226298,10.611063 C10.0226298,9.93700916 9.68778026,9.59995263 9.01813761,9.59995263 C8.62332853,9.59995263 8.28498515,9.72217411 8.00299476,9.96661707 C7.72810485,10.2111193 7.53070031,10.5851857 7.41089384,11.0888756 C7.28398689,11.5851635 7.15707995,12.1925995 7.03022936,12.9111244 C7.00199651,13.0592232 6.98790826,13.2147832 6.98790826,13.3777452 C6.98790826,14.0592602 7.32630799,14.3999882 8.00299476,14.3999882 Z",fill:"#FFFFFF"}),S.createElement("path",{d:"M12.2418282,16 C12.1556269,16 12.0889713,15.9733226 12.0419867,15.9199677 C12.0027701,15.8589994 11.9910553,15.7904787 12.0067168,15.7142835 L13.6288783,8.28571646 C13.6445399,8.20190792 13.6876405,8.13332623 13.7581802,8.07997137 C13.8287198,8.02667743 13.9031435,8 13.981514,8 L17.1083126,8 C17.9781556,8 18.675596,8.1752305 19.2006341,8.52569149 C19.7335656,8.87621339 20,9.38284087 20,10.0456958 C20,10.2361531 19.9765077,10.4342848 19.9294603,10.6399689 C19.7335656,11.5161823 19.3378293,12.1638104 18.7422516,12.5828531 C18.1545047,13.0018957 17.347308,13.2114171 16.3207242,13.2114171 L14.7338326,13.2114171 L14.1931329,15.7142835 C14.1774087,15.7980921 14.1343081,15.8666129 14.0638311,15.9199677 C13.9932915,15.9733226 13.9188051,16 13.8404973,16 L12.2418282,16 Z M16.4030414,11.6342817 C16.732122,11.6342817 17.0181647,11.546636 17.2611068,11.3714055 C17.5118797,11.196175 17.6764513,10.9447494 17.7548217,10.6171287 C17.7783141,10.4875787 17.7900916,10.3733165 17.7900916,10.2742811 C17.7900916,10.0533092 17.7234986,9.8856921 17.5902501,9.77142988 C17.4570016,9.64949333 17.2297837,9.58858596 16.9084712,9.58858596 L15.497866,9.58858596 L15.0511984,11.6342817 L16.4030414,11.6342817 Z",fill:"#FFFFFF"}))))))))))},name:"Optimism"},[ia.AVALANCHE]:{chainId:ia.AVALANCHE,logo:function(e){return S.createElement("svg",km({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),Em||(Em=S.createElement("defs",null,S.createElement("circle",{id:"path-1",cx:12,cy:12,r:12}))),Am||(Am=S.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},S.createElement("g",null,S.createElement("mask",{fill:"white"},S.createElement("use",{xlinkHref:"#path-1"})),S.createElement("use",{fill:"#E84142",xlinkHref:"#path-1"}),S.createElement("g",{mask:"url(#mask-2)",fill:"#FFFFFF",fillRule:"nonzero"},S.createElement("g",{transform:"translate(5.000000, 5.000000)"},S.createElement("path",{d:"M3.51363108,13 L1.15960067,13 C0.664946832,13 0.420612287,13 0.271614013,12.9001615 C0.110719232,12.7911601 0.0123723422,12.6101909 0.000457589205,12.410743 C-0.00848303711,12.226815 0.113693358,12.0023407 0.358027903,11.5534302 L6.1704203,0.83471072 C6.41774722,0.379558003 6.54289774,0.1519721 6.70083664,0.0678061674 C6.87067205,-0.0226020558 7.07329583,-0.0226020558 7.24314949,0.0678061674 C7.40108839,0.1519721 7.52623891,0.379558003 7.77354758,0.83471072 L8.96845316,3.01699266 C9.23960959,3.51267254 9.37667486,3.76207783 9.43628512,4.0239486 C9.50182538,4.30763877 9.50182538,4.60692511 9.43628512,4.89061527 C9.37667486,5.15248605 9.24258371,5.40189134 8.97142729,5.89757122 L5.91831288,11.5440764 C5.64418233,12.0459985 5.50711706,12.2985154 5.31640802,12.4885903 C5.11079187,12.6943759 4.86348319,12.8440382 4.59230852,12.9282232 C4.34499985,13 4.06787693,13 3.51363108,13 Z"}),S.createElement("path",{d:"M12.8314423,13 L9.45829001,13 C8.96066205,13 8.710361,13 8.5643551,12.9003524 C8.40344207,12.7911601 8.30511343,12.6071366 8.29319868,12.4077078 C8.28425805,12.2237606 8.40940857,11.9993054 8.65970962,11.5472643 L10.3432113,8.52326579 C10.5906295,8.07746696 10.7157982,7.85612335 10.8707083,7.77193833 C11.0405802,7.6815301 11.2401933,7.6815301 11.4100652,7.77193833 C11.5680771,7.85612335 11.690144,8.07746696 11.9404816,8.52015419 L13.6300775,11.5441527 C13.8802326,11.9961938 14.0085032,12.220649 13.9995625,12.4045771 C13.9906219,12.6040822 13.8891732,12.7881057 13.7284244,12.8971072 C13.5793531,13 13.3290156,13 12.8314423,13 Z"})))))))},name:"Avalanche"},[ia.AURORA]:{chainId:ia.AURORA,logo:function(e){return S.createElement("svg",Rm({width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),Cm||(Cm=S.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},S.createElement("g",{id:"aurora-avatar-grn",fillRule:"nonzero"},S.createElement("path",{d:"M12,0 L12,0 C18.625,0 24,5.375 24,12 L24,12 C24,18.625 18.625,24 12,24 L12,24 C5.375,24 0,18.625 0,12 L0,12 C0,5.375 5.375,0 12,0 Z",id:"\\u8DEF\\u5F84",fill:"#70D44B"}),S.createElement("path",{d:"M12,4.9 C12.6333333,4.9 13.2083333,5.25833333 13.4916667,5.825 L18.175,15.2 C18.5833333,16.025 18.25,17.025 17.425,17.4333333 C17.1916667,17.55 16.9416667,17.6083333 16.6833333,17.6083333 L7.31666667,17.6083333 C6.4,17.6083333 5.65,16.8583333 5.65,15.9416667 C5.65,15.6833333 5.70833333,15.425 5.825,15.2 L10.5083333,5.825 C10.7916667,5.25 11.3666667,4.89166667 12,4.9 M12,3.75 C10.9333333,3.75 9.95833333,4.35 9.48333333,5.30833333 L4.8,14.6833333 C4.10833333,16.075 4.66666667,17.7583333 6.05833333,18.4583333 C6.45,18.65 6.88333333,18.7583333 7.31666667,18.7583333 L16.6916667,18.7583333 C18.2416667,18.7583333 19.5083333,17.5 19.5083333,15.95 C19.5083333,15.5166667 19.4083333,15.0833333 19.2083333,14.6916667 L14.5166667,5.30833333 C14.0416667,4.35 13.0666667,3.75 12,3.75 Z",id:"\\u5F62\\u72B6",fill:"#FFFFFF"})))))},name:"Aurora"},[ia.OKCHAIN]:{chainId:ia.OKCHAIN,logo:function(e){return S.createElement("svg",Nm({width:72,height:72,viewBox:"0 0 72 72",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),Sm||(Sm=S.createElement("circle",{cx:36,cy:36,r:36,fill:"black"})),Tm||(Tm=S.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M29.2 18H18.8C18.3582 18 18 18.3582 18 18.8V29.2C18 29.6418 18.3582 30 18.8 30H29.2C29.6418 30 30 29.6418 30 29.2V18.8C30 18.3582 29.6418 18 29.2 18ZM41.2052 30H30.8052C30.3633 30 30.0051 30.3582 30.0051 30.8V41.2C30.0051 41.6418 30.3633 41.9999 30.8052 41.9999H41.2052C41.647 41.9999 42.0051 41.6418 42.0051 41.2V30.8C42.0051 30.3582 41.647 30 41.2052 30ZM42.8 18H53.2C53.6418 18 54 18.3582 54 18.8V29.2C54 29.6418 53.6418 30 53.2 30H42.8C42.3582 30 42 29.6418 42 29.2V18.8C42 18.3582 42.3582 18 42.8 18ZM29.2 42H18.8C18.3582 42 18 42.3582 18 42.8V53.2C18 53.6418 18.3582 54 18.8 54H29.2C29.6418 54 30 53.6418 30 53.2V42.8C30 42.3582 29.6418 42 29.2 42ZM42.8 42H53.2C53.6418 42 54 42.3582 54 42.8V53.2C54 53.6418 53.6418 54 53.2 54H42.8C42.3582 54 42 53.6418 42 53.2V42.8C42 42.3582 42.3582 42 42.8 42Z",fill:"white"})))},name:"OKTC"},[ia.CONFLUX]:{chainId:ia.CONFLUX,logo:function(e){return S.createElement("svg",Om({width:"199px",height:"245px",viewBox:"0 0 199 245",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),Mm||(Mm=S.createElement("g",{id:"Page-1",stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd"},S.createElement("g",{id:"Conflux_Logo_Mark_Color",transform:"translate(0.000000, -0.000000)",fillRule:"nonzero"},S.createElement("polygon",{id:"Path",fill:"#1A1A1A",points:"151.057838 145.949662 98.7961863 198.210803 69.7103803 169.125338 121.972032 116.863685 98.7291726 93.6209957 22.9712333 169.376384 98.5203077 244.923077 174.276376 169.167689"}),S.createElement("polygon",{id:"Path",fill:"#38A1DB",points:"197.693744 98.7101231 98.9858316 9.56888949e-05 0 98.9860017 0.31563441 145.252991 98.5658906 47.0051607 197.528761 145.971262"})))))},name:"Conflux eSpace"}};function jm({width:e=24,height:t=24,marginRight:r=8,url:o,zIndex:i,cross:s,address:a,token:c,sx:d,chainId:p}){const[f,h]=n.useState(!1),[m,g]=n.useState(""),[y,b]=n.useState(""),[v,x]=n.useState(!1),w=n.useCallback((()=>h(!0)),[]);let E=function(e){const t=l.useSelector(Ff),{chainId:r}=u.useWeb3React();return n.useMemo((()=>{if(!e)return;let n=t.find((({address:t,chainId:n})=>n===r&&t===e));return n||(n=t.find((({address:t})=>t===e))),n}),[e,t,r])}(a);c&&(E=c);const A=a||(null==E?void 0:E.address),k=null==E?void 0:E.symbol,C=null==k?void 0:k.charAt(0).toUpperCase(),R=n.useMemo((()=>{const e=null==E?void 0:E.logoURI;return o||e||""}),[o,E]);return n.useEffect((()=>{x(!1)}),[A,R]),n.useEffect((()=>{s&&(R?function(e,t){const r=new XMLHttpRequest;let n;r.onload=function(){const e=new FileReader;e.onloadend=function(){t(e.result)},e.readAsDataURL(r.response)},r.onerror=function(){t()};try{n=new URL(e)}catch(e){}finally{r.open("GET",n||e),r.responseType="blob",r.send()}}(R,(e=>{g(e)})):g(""))}),[R,s]),n.useEffect((()=>{try{let t=A;if(t&&t.length<15&&(t=t.padEnd(15,"0")),t){const r=new O.default(t,{size:e,format:"svg",margin:.2,background:[255,234,4,255]}).toString();b(`data:image/svg+xml;base64,${r}`)}}catch(e){console.error("generate Identicon error: ",e)}}),[A,e]),ne.exports.jsxs(Tr,{sx:Object.assign({position:"relative",display:"flex",alignItems:"center",justifyContent:"center",minWidth:e,width:e,height:t,marginRight:r,zIndex:i,border:"solid 1px",borderColor:"border.main",borderRadius:"50%"},d||{}),style:{width:e,height:t},children:[!f&&ne.exports.jsx(Tr,{sx:{typography:"ht",height:"100%",width:"100%",borderRadius:"50%",border:"transparent 2px solid",borderColor:"text.primary",color:"text.primary",display:"flex",alignItems:"center",justifyContent:"center"},children:C}),ne.exports.jsx(Tr,{component:"img",src:!(s?m:R)||v?y:s?m:R,onLoad:w,onError:e=>{const t=e.target;A&&y&&x(!0),t.onerror=null},sx:{position:"absolute",top:"0",bottom:"0",left:"0",right:"0",borderRadius:"50%",overflow:"hidden",width:"100%",height:"100%"}}),p&&Im[p]?ne.exports.jsx(Tr,{sx:{position:"absolute",right:0,bottom:-1,width:12,height:12,transform:"translateX(50%)",border:"solid 1px",borderColor:"border.main",borderRadius:"50%"},children:ne.exports.jsx(Tr,{component:Im[p].logo,sx:{display:"block",width:"100%",height:"100%"}})}):""]})}function Fm({token:t,onClick:r,showChainLogo:n}){var o,s;const a=Cr();return ne.exports.jsxs(Tr,{component:wn,sx:{display:"flex",alignItems:"center",color:a.palette.text.primary,typography:"h5",fontWeight:600},onClick:e=>{r&&r(e)},"data-testid":"swap-select-token-btn",children:[(null==t?void 0:t.address)?ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(jm,{url:null==t?void 0:t.logoURI,address:null!==(o=null==t?void 0:t.address)&&void 0!==o?o:"",marginRight:6,chainId:n?null==t?void 0:t.chainId:void 0}),ne.exports.jsx(Tr,{children:null!==(s=null==t?void 0:t.symbol)&&void 0!==s?s:"-"})]}):ne.exports.jsx(e.Trans,{id:"SELECT TOKEN"}),ne.exports.jsx(Tr,{sx:{ml:7,width:12,transform:"rotateX(180deg)"},component:i.CaretUp})]})}function _m({onClick:t,balance:r,decimals:n,address:o,showMaxBtn:i}){const{palette:s}=Cr();return ne.exports.jsxs(Tr,{sx:{display:"flex",typography:"body2",color:s.text.secondary},children:[ne.exports.jsx(e.Trans,{id:"Balance:"})," ",o?us({input:r,decimals:Math.min(n||4,4)}):"-",i&&r&&r.gt(0)&&ne.exports.jsx(Tr,{component:wn,sx:{ml:6,color:(null==r?void 0:r.gt(0))?s.primary.main:s.text.disabled,cursor:o&&t?"pointer":"unset"},onClick:()=>t&&t(r?r.toString():""),children:ne.exports.jsx(e.Trans,{id:"Max"})})]})}function Pm({readOnly:e,sx:t,value:r,decimals:o,onChange:s,suffix:a,withClear:l,onFocus:c,placeholder:u}){const d=Cr(),p=n.useMemo((()=>a||(l&&r&&s?ne.exports.jsx(Tr,{component:wn,sx:{ml:5,width:18,height:18,borderRadius:"50%",backgroundColor:"border.main",display:"flex",justifyContent:"center",alignItems:"center",flexShrink:0},onClick:()=>{s&&s("")},children:ne.exports.jsx(Tr,{component:i.Error,sx:{width:12,color:"text.secondary"}})}):void 0)),[s,a,d.palette.text.primary,r,l]);return ne.exports.jsxs(Tr,{sx:Object.assign({mt:12,display:"flex",justifyContent:"space-between",alignItems:"center"},t),"data-testid":"number-input-wrapper",children:[ne.exports.jsx(In,{fullWidth:!0,value:r,readOnly:e,placeholder:u||"0.00",onFocus:c,onChange:e=>{const t=e.target.value,r=0===t.length?"":fs(t,o);s&&s(r)},sx:{width:"inherit",border:"none","& .MuiInput-input":{fontSize:24,border:"none",outline:"none",height:24,padding:0,color:"text.primary","&::placeholder":{fontSize:24,color:"text.disabled"}}}}),!e&&r&&p]})}function Bm({open:e,onClose:t,afterClose:r,title:n,rightSlot:o,canBack:s=!0,children:a,height:l,testId:c}){return ne.exports.jsxs(Tr,{sx:{position:"absolute",top:e?0:"100%",transition:"top 300ms",zIndex:1,left:0,right:0,bottom:0,display:"flex",flexDirection:"column",backgroundColor:"background.paper",borderRadius:16,height:l},"data-testid":c,"data-active":e?"1":"0",children:[n?ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",p:20},children:[ne.exports.jsx(Tr,{sx:{display:"flex",alignItems:"center",typography:"caption"},children:n}),o,!o&&s&&ne.exports.jsx(Tr,{component:i.Error,sx:{color:"text.secondary",cursor:"pointer"},onClick:()=>{t&&t(),setTimeout((()=>r&&r()),300)}})]}):"",a]})}function Wm({token:e,disabled:t,style:r,onClick:n}){const o=Cr(),s=Lf(),{account:a}=u.useWeb3React(),l=s(e),c=l?cs({input:l}):"";return ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",typography:"body2",px:6,py:5,borderRadius:8,cursor:t?"auto":"pointer",opacity:t?.5:1,"&:hover":{backgroundColor:"hover.default"}},style:r,onClick:()=>{t||n()},"data-testid":"token-picker-item",children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(jm,{token:e}),ne.exports.jsxs(Tr,{children:[ne.exports.jsx(Tr,{sx:{fontWeight:600,textAlign:"left"},children:e.symbol}),a&&ne.exports.jsx(Tr,{sx:{mt:4,textAlign:"left"},children:(null==l?void 0:l.gte(0))?c:ne.exports.jsx(Tr,{component:i.Loading,width:18,sx:{"& path":{fill:o.palette.text.disabled},animation:"loadingRotate 1.1s infinite linear","@keyframes loadingRotate":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(359deg)"}}}})})]})]}),ne.exports.jsx(Tr,{sx:{color:"text.secondary",textAlign:"right"},children:e.name})]})}function Dm({chain:t,active:r,onClick:n}){return ne.exports.jsx(ui,{title:t.name,placement:"top",onlyHover:!0,children:ne.exports.jsxs(Tr,{sx:Object.assign({display:"flex",alignItems:"center",p:8,borderRadius:8,cursor:"pointer"},r?{backgroundColor:"secondary.main",color:"secondary.contrastText"}:{border:"1px solid",borderColor:"border.main","&:hover":{backgroundColor:"hover.default"}}),onClick:n,children:[ne.exports.jsx(Tr,{component:t.logo,sx:{width:24,height:24}}),r?ne.exports.jsxs(Tr,{sx:{ml:8},children:[ne.exports.jsx(e.Trans,{id:"on"}),` ${t.name}`]}):""]})},t.chainId)}function Lm({value:e,onChange:t,occupiedAddrs:r,hiddenAddrs:o,showAddrs:i,visible:s,side:a,defaultLoadBalance:l}){const{chainList:c,selectChainId:d,setSelectChainId:p}=function(){const{chainId:e}=u.useWeb3React(),[t,r]=n.useState(e),o=n.useMemo((()=>{const t={};let r;return Object.entries(Im).forEach((([n,o])=>{if(o.mainnet){if(e!==o.chainId)return;r=o.mainnet}t[n]=Object.assign({},o)})),void 0!==r&&delete t[r],Object.values(t)}),[e]);return n.useEffect((()=>{void 0===t&&r(e)}),[e]),{chainList:o,selectChainId:n.useMemo((()=>null!=t?t:1),[t]),setSelectChainId:r}}(),{showTokenList:f,filter:h,setFilter:m,onSelectToken:g,popularTokenList:y}=tm({value:e,onChange:t,occupiedAddrs:r,hiddenAddrs:o,showAddrs:i,side:a,chainId:d,visible:s,defaultLoadBalance:l}),b=n.useRef(null),[w,E]=n.useState(0),A=n.useRef(s);n.useEffect((()=>{!A.current&&s&&(null==e?void 0:e.chainId)!==d&&p(null==e?void 0:e.chainId),A.current=s}),[e,s]),n.useEffect((()=>{s&&b.current&&E(b.current.offsetHeight-16)}),[b,s]);const k=n.useCallback((({index:t,style:r})=>{const n=f[t];return n?ne.exports.jsx(Wm,{token:n,disabled:!!e&&e.address===n.address,style:r,onClick:()=>g(n)},n.address+n.chainId):null}),[f,y,e]);return ne.exports.jsxs(Tr,{sx:{display:"flex",flexDirection:"column",px:20,flex:1},children:[ne.exports.jsx(Fn,{fullWidth:!0,height:48,value:h,onChange:e=>m(e.target.value),clearValue:()=>m(""),placeholder:v.i18n._("Enter the token symbol or address")}),ne.exports.jsx(Tr,{sx:{position:"relative",display:"flex",gap:8,flexWrap:"wrap",pt:16,pb:32,"&::after":{content:'""',position:"absolute",bottom:16,left:0,right:0,height:"1px",backgroundColor:"border.main"}},children:c.map((e=>ne.exports.jsx(Dm,{chain:e,active:e.chainId===d,onClick:()=>{p(e.chainId)}},e.chainId)))}),ne.exports.jsx(Tr,{sx:{pb:16,flex:1,minHeight:64},ref:b,children:ne.exports.jsx(x.FixedSizeList,{height:w,itemCount:f.length,itemSize:52,width:"100%",className:"token-list",children:k},y.length)})]})}function Um({open:t,value:r,onClose:n,occupiedAddrs:o,onTokenChange:i,side:s,defaultLoadBalance:a}){const{height:c}=l.useSelector(Uf);return ne.exports.jsx(Bm,{height:c,open:t,onClose:n,title:ne.exports.jsx(e.Trans,{id:"Select a token"}),testId:"token-picker-wrapper",children:ne.exports.jsx(Lm,{value:r,visible:t,onChange:i,occupiedAddrs:o,side:s,defaultLoadBalance:a})})}function Vm(e,t){localStorage.setItem("from"===e?"DODO_WIDGET_LAST_FROM_TOKEN":"DODO_WIDGET_LAST_TO_TOKEN",t?JSON.stringify(t):"")}function Zm(e){const{provider:t}=u.useWeb3React(),r=n.useMemo((()=>{var r;if(e&&(null===(r=null==t?void 0:t.provider)||void 0===r?void 0:r.isMetaMask))return()=>function({chainId:e,provider:t}){var r,n,o;return ma(this,void 0,void 0,(function*(){if(!t)return!1;const i=`0x${e.toString(16)}`;try{return yield t.request({method:"wallet_switchEthereumChain",params:[{chainId:i}]}),!0}catch(s){const{code:a}=s,l=la[e];if(!l)throw new Error(`Chain ${e} does not exist`);const c={chainId:i,chainName:null===(r=Im[e])||void 0===r?void 0:r.name,rpcUrls:[...sa[e],...null!==(o=null===(n=Tf.getState().globals.jsonRpcUrlMap)||void 0===n?void 0:n[e])&&void 0!==o?o:[]],nativeCurrency:{name:l.name,symbol:l.symbol,decimals:l.decimals},blockExplorerUrls:[`https://${ua[e]}/`]};if(4902===a||-32603===a)try{return yield t.request({method:"wallet_addEthereumChain",params:[c]}),!0}catch(t){console.error(`[failed to add ${e}]: `,c,t)}console.error(`[failed to switch ${e}]: `,c,s)}return!1}))}({chainId:e,provider:null==t?void 0:t.provider})}),[e]);return r}const Hm=(e,t)=>{const r=String(e).split("."),n=!r[1],o=Number(r[0])==e,i=o&&r[0].slice(-1),s=o&&r[0].slice(-2);return t?1==i&&11!=s?"one":2==i&&12!=s?"two":3==i&&13!=s?"few":"other":1==e&&n?"one":"other"},zm={"en-US":Hm,"zh-CN":(e,t)=>"other",pseudo:Hm};function Ym({locale:t,children:r}){return n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){yield function(e="en-US"){return ma(this,void 0,void 0,(function*(){v.i18n.loadLocaleData(e,{plurals:()=>zm[e]});try{const r=yield(t=`./locales/${e}.js`,Promise.resolve().then((function(){return A(require(t))})));v.i18n.load(e,r.messages||r.default.messages)}catch(e){}var t;v.i18n.activate(e)}))}(t)}))})()}),[t]),ne.exports.jsx(e.I18nProvider,{i18n:v.i18n,children:r})}var Gm,Xm,Jm,qm;!function(e){e[e.Running=0]="Running",e[e.Success=1]="Success",e[e.Failed=2]="Failed",e[e.Warning=3]="Warning"}(Gm||(Gm={})),function(e){e.Canceled="canceled",e.Failed="failed",e.Success="success",e.Submitted="submitted"}(Xm||(Xm={})),function(e){e[e.Failed=0]="Failed",e[e.Success=1]="Success"}(Jm||(Jm={})),function(e){e[e.Failed=0]="Failed",e[e.Success=1]="Success",e[e.Warning=2]="Warning"}(qm||(qm={}));const Qm=(e,t)=>ma(void 0,void 0,void 0,(function*(){const{value:r,from:n,to:o,data:i}=e,s={from:n,to:o,value:r,data:i};r&&!/^0x0*$/.test(r)||delete s.value;try{return(yield t.estimateGas(s)).add(5e4)}catch(e){t.call(s).then((e=>{if("test"!==process.env.NODE_ENV)throw new Error("Unexpected issue with estimating the gas. Please try again.")})).catch((e=>{if("test"!==process.env.NODE_ENV)throw e}))}return null})),Km=(e,t)=>ma(void 0,void 0,void 0,(function*(){try{return yield t.getSigner().sendTransaction(e)}catch(e){throw 4001===(null==e?void 0:e.code)?new Error(v.i18n._("Transaction rejected.")):e}}));var $m,eg;!function(e){e.Approval="APPROVAL",e.TX="TX",e.TypedSign="TypedSign"}($m||($m={})),function(e){e.Normal="Normal",e.Privacy="Privacy",e.LimitOrder="LimitOrder",e.RFQ="RFQ"}(eg||(eg={}));const tg=new C.default(2).pow(256).minus(1),rg=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_GLOBAL_PROPS",payload:e})})),ng=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_AUTO_CONNECT_LOADING",payload:e})}));function og({onTxFail:e,onTxSubmit:t,onTxSuccess:r}={}){const{account:o,provider:i}=u.useWeb3React(),s=Of(),[a,c]=n.useState(!1),[d,p]=n.useState(new Map),f=l.useDispatch(),[h,m]=n.useState(null),[g,y]=n.useState(""),[b,x]=n.useState(null),[w,E]=n.useState(!1),[A,k]=n.useState(),{updateBlockNumber:R}=Qh(),S=n.useCallback(((n,a,l,u=!1,d,h,g,b)=>ma(this,void 0,void 0,(function*(){if(y(""),m(""),!o||!i)throw new Error("Submission: Cannot execute step when the wallet is disconnected");let w,A,S;k((()=>g)),c(!1);try{if(c(!0),a.opcode===$m.Approval)S=yield((e,t,r,n,o,i)=>ma(void 0,void 0,void 0,(function*(){const s=Yh(e,$h,o,i).interface.encodeFunctionData("approve",[r,n.toFixed()]),a={from:t,to:e,data:s,value:`0x${new C.default("0").toString(16)}`,gasLimit:void 0},l=yield Qm(a,o);return l&&(a.gasLimit=l),yield Km(a,o)})))(a.token.address,o,a.contract,a.amt||tg,i,o),w=S.hash,y(w);else{if(a.opcode!==$m.TX)throw new Error(`Op ${a.opcode} not implemented!`);if(""===a.to)throw new Error("Submission: malformed to");if(0===a.data.length)throw new Error("Submission: malformed data");if(0===a.data.indexOf("0x")&&a.data.length<=2)throw new Error("Submission: malformed data");if(A={value:a.value,data:a.data,to:a.to,gasLimit:a.gasLimit,from:o,chainId:s},!A.gasLimit)try{const e=yield Qm(A,i);e&&(A.gasLimit=e)}catch(e){console.debug(e)}if(S=yield Km(A,i),w=S.hash,y(w),!w)throw new Error(`Unexpected tx: ${w}`)}}catch(t){if(c(!1),x({spec:a,brief:n,subtitle:l}),console.error(t),t.message){f(rg({contractStatus:Ef.Failed}));const r={error:t.message,brief:n};h&&Object.assign(r,h),e&&e(t,h),m(function(e,t){var r;const n=null===(r=la[e])||void 0===r?void 0:r.symbol,o=[{error:"insufficient",msg:v.i18n._("Insufficient funds - Please retry after depositing more {EtherTokenSymbol} into your wallet",{EtherTokenSymbol:n})},{error:["External Swap execution Failed","Return amount is not enough"],msg:v.i18n._("Price impact exceeds the slippage tolerance you set. Try increasing the slippage tolerance.")},{error:"SafeERC20: low-level call failed",msg:v.i18n._("SafeERC20: low-level call failed. Please contact the DODO team.")},{error:["User denied","cancel","User rejected","user rejected"],msg:v.i18n._("User denied transaction signature.")},{error:["Cannot set properties of undefined (setting 'loadingDefauIts'){\"originalError\":{",'[ethjs-query]while formatting outputs from RPC\'["value":["code":-32000,"message":"header not found"))'],msg:v.i18n._("RPC node data exception")},{error:['execution reverted:FORCESTOP ["originalError"'],msg:v.i18n._("ForceStop exception")},{error:["replacement transaction underpriced","Gasprice too low","transaction underprice"],msg:v.i18n._("Gas price is too low, please adjust in your wallet and try again")},{error:["MINT_INVALID"],msg:v.i18n._("No ForceStop access")},{error:["NOT_PHASE_EXE"],msg:v.i18n._("Unable to SETTLE during the cooling-off period")},{error:["params specify an EIP-1559transaction but the currentnetwork does not support"],msg:v.i18n._("Wallet incompatibility")},{error:["ALREADY_SETTLED"],msg:v.i18n._("This CP has been settled by other addrs")},{error:["create RFQ order failed]:LESS_THAN_FEE_LIMIT"],msg:v.i18n._("Service update, please wait and try again")}];let i="";return o.some((e=>Array.isArray(e.error)?e.error.some((r=>t.indexOf(r)>-1&&(i=e.msg,!0))):t.indexOf(e.error)>-1&&(i=e.msg,!0))),i||t}(s,t.message))}return Xm.Failed}x({spec:a,brief:n,subtitle:l}),E(!1),c(!1);const T=Object.assign(Object.assign(Object.assign(Object.assign({brief:n},a),A),{tx:w,subtitle:l}),h);f(rg({contractStatus:Ef.Pending})),t&&t(w,T),d&&d();const N={brief:n,spec:a,tx:w,subtitle:l};if(p((e=>e.set(w,[N,Gm.Running]))),u)return Xm.Submitted;if(d&&d(),null==S?void 0:S.wait){const e=yield S.wait(1);if(E(!0),e.status===Jm.Success)return"TX"===T.opcode&&f(rg({contractStatus:Ef.TxSuccess})),"APPROVAL"===T.opcode&&f(rg({contractStatus:Ef.ApproveSuccess})),b&&b(w,r),r&&r(w,T),yield R(),p((e=>e.set(w,[N,Gm.Success]))),Xm.Success}return yield R(),E(!0),p((e=>e.set(w,[N,Gm.Failed]))),Xm.Failed}))),[o,s,c,i,R]),T=n.useMemo((()=>({execute:S,requests:d,setShowing:x,waitingSubmit:a})),[S,d,x]),N=n.useCallback((()=>{x(null),A&&(A(),k(void 0))}),[A]);return{showing:b,showingDone:w,transactionTx:g,errorMessage:h,setErrorMessage:m,closeShowing:N,ctxVal:T,requests:d}}function ig(){const{requests:e}=ag(),t=[];return null==e||e.forEach((function([e,r]){r===Gm.Running&&t.push(e)})),{runningRequests:t,isInflight:t.length>0}}const sg=n.createContext({execute:()=>Promise.resolve(Xm.Canceled),requests:void 0,waitingSubmit:!1});function ag(){return n.useContext(sg)}var lg;function cg(){return cg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},cg.apply(this,arguments)}var ug=function(e){return S.createElement("svg",cg({width:"33px",height:"33px",viewBox:"0 0 33 33",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),lg||(lg=S.createElement("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd",strokeLinecap:"round",strokeLinejoin:"round"},S.createElement("g",{transform:"translate(-186.000000, -375.000000)",stroke:"currentColor",strokeWidth:4},S.createElement("g",{transform:"translate(18.000000, 291.000000)"},S.createElement("g",{transform:"translate(40.000000, 83.000000)"},S.createElement("path",{d:"M159,32 C159,15.9837423 146.016258,3 130,3"})))))))};function dg({showingDone:e,errorMessage:t}){return t?ne.exports.jsx(Tr,{component:i.ErrorWarn,sx:{width:64,height:64,color:"error.main"}}):e?ne.exports.jsx(Tr,{component:i.DoneBorder,sx:{width:64,height:64,color:"success.main"}}):ne.exports.jsx(Tr,{sx:{mx:"auto",border:e=>{var t;return`6px solid ${null===(t=e.palette)||void 0===t?void 0:t.background.input}`},borderRadius:"50%",width:"64px",height:"64px",position:"relative",animation:"loadingRotate 1.1s infinite linear","@keyframes loadingRotate":{"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(359deg)"}}},children:ne.exports.jsx(Tr,{component:ug,sx:{position:"absolute",top:"-6px",right:"-6px",color:"primary.main"}})})}function pg({showingDone:e,showing:t}){return ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:[ne.exports.jsx(Tr,{sx:{mt:60},children:e?v.i18n._("{0} confirmed",{0:null==t?void 0:t.brief}):v.i18n._("{0} pending",{0:null==t?void 0:t.brief})}),(null==t?void 0:t.subtitle)?ne.exports.jsx(Tr,{sx:{mt:20,typography:"body2"},children:null==t?void 0:t.subtitle}):""]})}function fg({isStarted:t,isEnded:r,tx:o}){const[s,a]=n.useState(0),{chainId:l}=u.useWeb3React(),c=n.useMemo((()=>`https://${ua[l||1]}/tx/${o}`),[o,l]),d=n.useMemo((()=>{const e=Math.floor(s/60),t=s%60;return e?`${e}m ${t}s`:`${t}s`}),[s]),p=n.useRef();return n.useEffect((()=>(t&&(a(0),clearInterval(p.current),p.current=setInterval((()=>{a((e=>e+1))}),1e3)),()=>{clearInterval(p.current)})),[t]),n.useEffect((()=>{clearInterval(p.current)}),[r]),ne.exports.jsxs(Tr,{sx:{mt:20,pt:20,display:"flex",justifyContent:"space-between",alignItems:"center",typography:"body2",color:"text.secondary",border:"solid 1px transparent",borderTopColor:"border.main"},children:[ne.exports.jsxs(Tr,{children:[ne.exports.jsx(e.Trans,{id:"Transaction Time:"}),d]}),ne.exports.jsxs(jn,{sx:{display:"flex",alignItems:"center",cursor:"pointer"},component:"a",href:c,target:"_blank",rel:"noopener noreferrer",children:[ne.exports.jsx(e.Trans,{id:"Tx"}),ne.exports.jsx(Tr,{component:i.ArrowTopRightBorder,sx:{width:16,height:16,ml:6}})]})]})}function hg(t){var{children:r}=t,n=ha(t,["children"]);const{ctxVal:o,showing:i,closeShowing:s,showingDone:a,errorMessage:c,transactionTx:u}=og(n),d=l.useDispatch();return ne.exports.jsxs(sg.Provider,{value:o,children:[r,ne.exports.jsx(Bm,{open:!!i,onClose:s,children:ne.exports.jsxs(Tr,{sx:{display:"flex",flexDirection:"column",justifyContent:"space-between",px:20,pb:20,flex:1,overflowY:"auto"},children:[ne.exports.jsxs(Tr,{children:[ne.exports.jsx(Tr,{sx:{textAlign:"center",pt:60},children:ne.exports.jsx(dg,{showingDone:a,errorMessage:c})}),c?ne.exports.jsxs(Tr,{sx:{textAlign:"center",mt:60},children:[ne.exports.jsx(Tr,{children:ne.exports.jsx(e.Trans,{id:"Something went wrong."})}),ne.exports.jsx(Tr,{sx:{color:"text.secondary",mt:12,typography:"body2",wordBreak:"break-all"},children:c})]}):ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(pg,{showingDone:a,showing:i}),ne.exports.jsx(fg,{isStarted:!!i,isEnded:a,tx:u})]})]}),ne.exports.jsx(vn,{fullWidth:!0,size:vn.Size.big,onClick:()=>{d(rg({contractStatus:Ef.Initial})),s()},sx:{mt:20},children:c?ne.exports.jsx(e.Trans,{id:"Dismiss"}):ne.exports.jsx(e.Trans,{id:"Close"})})]})})]})}const mg=e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_SLIPPAGE",payload:e})}));function gg({width:e,height:t,feeRate:r,rebateTo:o,colorMode:i,apikey:s,defaultChainId:a,defaultToToken:c,defaultFromToken:u,jsonRpcUrlMap:d,swapSlippage:p,bridgeSlippage:f,apiServices:h}){const m=l.useDispatch();n.useEffect((()=>{i&&m((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_COLOR_MODE",payload:e})})))(i))}),[i]),n.useEffect((()=>{var e;a&&m((e=a,t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_CHAIN_ID",payload:e})}))))}),[a]),n.useEffect((()=>{m(rg({height:t}))}),[t]),n.useEffect((()=>{m(rg({width:e}))}),[e]),n.useEffect((()=>{s&&m(rg({apikey:s}))}),[s]),n.useEffect((()=>{r&&m(rg({feeRate:r}))}),[r]),n.useEffect((()=>{o&&m(rg({rebateTo:o}))}),[o]),n.useEffect((()=>{p&&m(rg({swapSlippage:p}))}),[p]),n.useEffect((()=>{f&&m(rg({bridgeSlippage:f}))}),[f]),n.useEffect((()=>{h&&m(rg({apiServices:h}))}),[h]),n.useEffect((()=>{u&&m((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_DEFAULT_FROM_TOKEN",payload:e})})))(u))}),[u]),n.useEffect((()=>{c&&m((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_DEFAULT_TO_TOKEN",payload:e})})))(c))}),[c]),n.useEffect((()=>{d&&m(rg({jsonRpcUrlMap:d}))}),[d])}var yg;!function(e){e.routePrice="routePrice",e.fiatPrice="fiatPrice",e.bridgeRoutePrice="bridgeRoutePrice",e.bridgeEncode="bridgeEncode",e.bridgeCreateRoute="bridgeCreateRoute"}(yg||(yg={}));const bg="https://api.dodoex.io/cross-chain/widget",vg="https://api.dodoex.io/frontend-price-api",xg=`${bg}/routes`,wg=`${bg}/transaction/encode`,Eg=`${bg}/order/create`;function Ag({refetch:e,interval:t}){let r;n.useEffect((()=>(e(),clearTimeout(r),r=setInterval((()=>{e()}),null!=t?t:15e3),()=>clearTimeout(r))),[e])}function kg({fromToken:e,toToken:t,chainId:r}){const[o,i]=n.useState(!1),{apikey:s}=l.useSelector(Uf),[a,c]=n.useState(""),[u,d]=n.useState(""),p=n.useCallback((()=>{if(!r||!e||!t)return;i(!0);const n=[e,t];I.default.post(`${vg}/current/batch`,{networks:n.map((()=>(e=>ca[e]||ca[ia.MAINNET])(r))),addresses:n.map((e=>e.address)),symbols:n.map((e=>e.symbol)),isCache:!0},s?{headers:{apikey:s}}:void 0).then((r=>{var n;i(!1);const o=null===(n=r.data)||void 0===n?void 0:n.data;o&&(c(o.find((t=>t.address===e.address)).price),d(o.find((e=>e.address===t.address)).price))})).catch((e=>{i(!1),console.error(e)}))}),[r,e,t,s]);return Ag({refetch:p}),{loading:o,refetch:p,toFiatPrice:u,fromFiatPrice:a}}const Cg=e=>(null!=e?e:Tf.getState()).settings.slippage,Rg=e=>(null!=e?e:Tf.getState()).settings.ddl,Sg="0x0000000000000000000000000000000000000000";function Tg(e){const t=l.useSelector(Uf);return n.useMemo((()=>{var r,n;return e?null!==(r=t.bridgeSlippage)&&void 0!==r?r:.5:null!==(n=t.swapSlippage)&&void 0!==n?n:.2}),[t.swapSlippage,t.bridgeSlippage,e])}function Ng(e){const t=l.useSelector(Uf);return n.useMemo((()=>function(e,t={}){var r,n,o,i,s;switch(e){case yg.routePrice:return null!==(r=t.routePrice)&&void 0!==r?r:"https://api.dodoex.io/route-service/v2/widget/getdodoroute";case yg.fiatPrice:return null!==(n=t.fiatPrice)&&void 0!==n?n:vg;case yg.bridgeRoutePrice:return null!==(o=t.bridgeRoutePrice)&&void 0!==o?o:xg;case yg.bridgeEncode:return null!==(i=t.bridgeEncode)&&void 0!==i?i:wg;case yg.bridgeCreateRoute:return null!==(s=t.bridgeCreateRoute)&&void 0!==s?s:Eg;default:throw new Error(`Invalid key = ${e}`)}}(e,t.apiServices)),[t.apiServices,e])}var Mg;function Og({toToken:e,fromToken:t,fromAmount:r,toAmount:o,marginAmount:i}){const{account:s,chainId:a,provider:c}=u.useWeb3React(),d=l.useSelector(Nf),p=n.useMemo((()=>a||d),[a,d]),f=Tg(!1),h=l.useSelector(Cg)||f,m=l.useSelector(Rg)||20,{feeRate:g,rebateTo:b,apikey:x,isReverseRouting:w}=l.useSelector(Uf),E=n.useMemo((()=>Math.floor(Date.now()/1e3)+60*m),[m]),[A,k]=n.useState(Mg.Initial),[C,R]=n.useState(null),[S,T]=n.useState(""),[N,M]=n.useState(null),[O,j]=n.useState(null),[F,_]=n.useState(null),[P,B]=n.useState(y.BigNumber.from(0)),[W,D]=n.useState(null),[L,U]=n.useState(null),[V,Z]=n.useState(""),[H,z]=n.useState(""),[Y,G]=n.useState(""),[X,J]=n.useState(0),q=Ng(yg.routePrice),Q=n.useCallback((()=>ma(this,void 0,void 0,(function*(){if(!p||!t||!e||t.chainId!==e.chainId)return void k(Mg.Initial);if(!w&&!r)return;if(w&&!o)return;k(Mg.Loading);const n={chainId:p,deadLine:E,apikey:x,slippage:h,source:"dodoV2AndMixWasm",toTokenAddress:e.address,toTokenDecimals:e.decimals,fromTokenAddress:t.address,fromTokenDecimals:t.decimals,userAddr:s||Sg};w?n.toAmount=y.parseFixed(String(o||1),e.decimals).toString():n.fromAmount=y.parseFixed(String(r||1),t.decimals).toString(),b&&g&&(n.rebateTo=b,n.fee=g);try{const e=(yield I.default.get(q,{params:n})).data.data;if((null==e?void 0:e.resAmount)?(k(Mg.Success),R(e.resAmount),_(e.priceImpact),D(e.resPricePerFromToken),U(e.resPricePerToToken),M(e.baseFeeAmount),j(e.additionalFeeAmount),Z(e.to),z(e.data),T(e.value),G(e.useSource),J(e.duration)):k(Mg.Failed),!s||!c)return;const t=yield Qm({from:s,to:e.to,value:e.value,data:e.data},c);t&&B(t)}catch(e){k(Mg.Failed),console.error(e)}}))),[E,s,p,e,g,h,b,t,c,r,o,x,w,q]);Ag({refetch:Q});const K=n.useMemo((()=>{const e=w?o:r;return A!==Mg.Loading&&e?C:null}),[A,w,o,r,C]),$=function(){const{chainId:e,account:t}=u.useWeb3React(),r=ag(),o=n.useCallback((({to:e,data:n,useSource:o,duration:i,ddl:s,gasLimit:a,subtitle:l,value:c})=>{const u=60*s,d=c;o&&"weth"!==o.toLowerCase()&&a&&a.lt(3e4)&&console.debug("Warning: GasLimit less than the minimum!");const p={from:t,to:e,data:n,value:d,route:o,duration:i,ddlSecRel:u,gasLimit:a};r.execute(v.i18n._("Swap"),Object.assign({opcode:$m.TX},p),l)}),[t,e]);return o}(),ee=n.useCallback((e=>{t&&(w?C:r)&&$({to:V,data:H,useSource:Y,duration:X,ddl:m,value:S,subtitle:e})}),[V,m,H,X,Y,t,r,P,C,S,w]);return{status:A,refetch:Q,priceImpact:F,executeSwap:ee,baseFeeAmount:N,resAmount:K,additionalFeeAmount:O,resPricePerToToken:L,resPricePerFromToken:W}}!function(e){e.Initial="Initial",e.Loading="Loading",e.Failed="Failed",e.Success="Success"}(Mg||(Mg={}));function Ig(e){jf(e),qh(),Qh();const{provider:t,connector:r}=u.useWeb3React(),o=l.useDispatch();n.useEffect((()=>{o(ng(!0));(()=>{ma(this,void 0,void 0,(function*(){const t=e.defaultChainId;try{(null==r?void 0:r.connectEagerly)?yield r.connectEagerly(t):yield r.activate(t)}finally{o(ng(!1))}}))})()}),[r]),n.useEffect((()=>{e.onProviderChanged&&e.onProviderChanged(t);const n=null==t?void 0:t.provider,i=()=>ma(this,void 0,void 0,(function*(){o(ng(!0));try{(null==r?void 0:r.connectEagerly)?yield r.connectEagerly():yield r.activate()}finally{o(ng(!1))}}));return(null==n?void 0:n.on)&&n.on("chainChanged",i),()=>{(null==n?void 0:n.removeListener)&&n.removeListener("chainChanged",i)}}),[t]);const i=e.width||375,s=e.height||494;return gg(Object.assign(Object.assign({},e),{width:i,height:s})),ne.exports.jsx(Tr,{sx:{width:i,height:s,overflow:"hidden",position:"relative",display:"flex",flexDirection:"column",minWidth:335,minHeight:494,borderRadius:16,backgroundColor:"background.paper"},className:"dodo-widget-container",children:ne.exports.jsx(hg,{...e,children:e.children})})}function jg(e){const t=function(e){for(var t=void 0===e?{}:e,n=t.mode,o=void 0===n?"light":n,i=t.lang,s=t.theme,a=[],l=1;l<arguments.length;l++)a[l-1]=arguments[l];var c=Kr(o,s,i);return yr(c=a.reduce((function(e,t){return r.merge(e,t)}),c))}({mode:e.colorMode,theme:e.theme,lang:e.locale||"en-US"}),o=n.useMemo((()=>e.defaultChainId||1),[e.defaultChainId]);if(!e.apikey&&!e.apiServices)throw new Error("apikey and apiServices must have a.");const i=gf({provider:e.provider,jsonRpcUrlMap:e.jsonRpcUrlMap,defaultChainId:o}),s=`${i.length}+${e.jsonRpcUrlMap?Object.entries(e.jsonRpcUrlMap):""}+${e.defaultChainId}+${o}`;return ne.exports.jsx(l.Provider,{store:Tf,children:ne.exports.jsx(Ym,{locale:e.locale,children:ne.exports.jsx(Hr,{theme:t,children:ne.exports.jsxs(u.Web3ReactProvider,{connectors:i,lookupENS:!1,children:[ne.exports.jsx(rn,{container:".dodo-widget-container"}),ne.exports.jsx(Ig,{...e})]},s)})})})}function Fg({chainId:t,open:r,onClose:o}){var i,s;const a=Cr(),[l,c]=n.useState(!1),{chainId:d}=u.useWeb3React(),[p,f]=n.useState("1"===localStorage.getItem("DODO_WIDGET_AUTO_SWITCH_NETWORK")),h=Zm(t);n.useEffect((()=>{(()=>{ma(this,void 0,void 0,(function*(){if(r)if(d&&t&&t!==d&&h){if(p)return yield h(),void o();c(!0)}else o();else l&&c(!1)}))})()}),[r]);const m=t&&null!==(s=null===(i=Im[t])||void 0===i?void 0:i.name)&&void 0!==s?s:"";return ne.exports.jsx(Mi,{open:l,onClose:o,container:document.querySelector(".dodo-widget-container"),children:ne.exports.jsxs(Tr,{sx:{backgroundColor:"background.paper",display:"flex",width:"100%",flexDirection:"column",justifyContent:"center",alignItems:"center",p:a.spacing(20,16),gap:20,borderRadius:a.spacing(16,16,0,0),outline:0},children:[ne.exports.jsxs(Tr,{sx:{typography:"caption",textAlign:"center"},children:[ne.exports.jsx(e.Trans,{id:"This token is on"})," ",m,ne.exports.jsx(e.Trans,{id:"."}),ne.exports.jsx("br",{}),ne.exports.jsx(e.Trans,{id:"Are you sure swapping to another chain?"})]}),ne.exports.jsxs(Tr,{component:"label",sx:{display:"flex",alignItems:"center",gap:8,typography:"h6",cursor:"pointer"},children:[ne.exports.jsx(Oi,{sx:{top:-1},checked:p,onChange:e=>{const{checked:t}=e.target;var r;r=t,localStorage.setItem("DODO_WIDGET_AUTO_SWITCH_NETWORK",r?"1":"0"),f(t)}}),ne.exports.jsx(e.Trans,{id:"Auto switch network"})]}),ne.exports.jsxs(Tr,{sx:{display:"grid",width:"100%",gridTemplateColumns:"repeat(2, 1fr)",gap:8},children:[ne.exports.jsx(vn,{variant:vn.Variant.second,onClick:o,children:ne.exports.jsx(e.Trans,{id:"Cancel"})}),ne.exports.jsx(vn,{variant:vn.Variant.outlined,onClick:()=>ma(this,void 0,void 0,(function*(){h&&(yield h()),o()})),children:ne.exports.jsx(e.Trans,{id:"Confirm"})})]})]})})}function _g({sx:e,amt:t,token:r,readOnly:o,showMaxBtn:i,onMaxClick:s,fiatPriceTxt:a,occupiedAddrs:l,onInputFocus:c,onTokenClick:u,onInputChange:d,onTokenChange:p,side:f,showChainLogo:h,onlyCurrentChain:m,defaultLoadBalance:g}){const[y,b]=n.useState(!1),v=Cr(),x=Lf(),[w,E]=n.useState(!1),A=r?x(r):null;return n.useEffect((()=>{r&&m&&b(!0)}),[r,m]),ne.exports.jsxs(Tr,{sx:Object.assign({width:"100%",minHeight:133,padding:20,borderRadius:12,overflow:"hidden",display:"flex",flexDirection:"column",justifyContent:"space-between",backgroundColor:v.palette.background.input},e),children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[ne.exports.jsx(Fm,{token:r,showChainLogo:h,onClick:()=>E(!0)}),ne.exports.jsx(_m,{balance:A,onClick:s,showMaxBtn:i,address:null==r?void 0:r.address,decimals:null==r?void 0:r.decimals})]}),ne.exports.jsx(Pm,{value:t,onFocus:c,onChange:d,readOnly:o,withClear:!0}),ne.exports.jsx(Tr,{sx:{mt:4,typography:"body2",color:v.palette.text.secondary},children:a}),ne.exports.jsx(Um,{value:r,open:w,side:f,occupiedAddrs:l,defaultLoadBalance:g,onClose:()=>{E(!1),u&&u()},onTokenChange:(e,t)=>{E(!1),setTimeout((()=>{p(e,t)}),300)}}),ne.exports.jsx(Fg,{chainId:null==r?void 0:r.chainId,open:y,onClose:()=>b(!1)})]})}function Pg(e){const{width:t}=l.useSelector(Uf),r=n.useMemo((()=>{let e="";return"number"==typeof t?e=`${t}px`:t&&(e=t),e?`calc(${e} - 40px)`:"auto"}),[t]);return ne.exports.jsx(di,{container:document.querySelector(".dodo-widget-container"),maxWidth:r,...e})}function Bg({onClick:e}){const t=Cr();return ne.exports.jsx(jn,{sx:{width:"100%",position:"relative"},onClick:e,children:ne.exports.jsx(Tr,{component:wn,sx:{width:36,height:36,borderRadius:"50%",backgroundColor:t.palette.background.input,border:`4px solid ${t.palette.background.paper}`,display:"flex",alignItems:"center",justifyContent:"center",position:"absolute",left:"50%",top:"50%",transform:"translate(-50%, -50%) rotate(-90deg)"},children:ne.exports.jsx(Tr,{component:i.ArrowBack,sx:{width:18,color:"text.secondary"}})})})}function Wg({open:t,execute:r,onClose:o,toToken:s,fromToken:a,fromAmount:c,toAmount:u,priceImpact:d,clearFromAmt:p,clearToAmt:f,baseFeeAmount:h,curToFiatPrice:m,curFromFiatPrice:g,pricePerFromToken:y,additionalFeeAmount:b}){var v,x;const w=Cr(),E=l.useSelector(Cg),A=l.useDispatch(),{contractStatus:k}=l.useSelector(Uf),R=n.useMemo((()=>new C.default(d).gt(15)),[d]),[S,T]=n.useState(!1),[N,M]=n.useState(!1);return n.useEffect((()=>{k!==Ef.Pending&&o(),k===Ef.TxSuccess&&(f(),p())}),[k]),n.useEffect((()=>{T(!1)}),[m]),ne.exports.jsx(Bm,{open:t,onClose:()=>{A(rg({contractStatus:Ef.Initial})),o()},title:ne.exports.jsx(e.Trans,{id:"Swap summary"}),children:ne.exports.jsxs(Tr,{sx:{margin:20,display:"flex",height:"100%",flexDirection:"column",borderTop:`1px solid ${w.palette.border.main}`},children:[ne.exports.jsxs(Tr,{sx:{py:20,display:"flex",typography:"body2",alignItems:"center",justifyContent:"center",flexDirection:"column",borderBottom:`1px solid ${w.palette.border.main}`},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsxs(Tr,{children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:[ne.exports.jsx(jm,{width:16,height:16,url:null==a?void 0:a.logoURI,address:null!==(v=null==a?void 0:a.address)&&void 0!==v?v:"",marginRight:6}),ne.exports.jsx(Tr,{children:`${us({input:c,decimals:null==a?void 0:a.decimals})} ${null==a?void 0:a.symbol}`})]}),ne.exports.jsx(Tr,{sx:{mt:4,typography:"h6",color:w.palette.text.secondary},children:g?`$${cs({input:g,showDecimals:1})}`:"-"})]}),ne.exports.jsx(Tr,{sx:{width:16,mx:16},component:i.DoubleRight}),ne.exports.jsxs(Tr,{children:[ne.exports.jsxs(Tr,{sx:{display:"flex"},children:[ne.exports.jsx(jm,{width:16,height:16,marginRight:6,url:null==s?void 0:s.logoURI,address:null!==(x=null==s?void 0:s.address)&&void 0!==x?x:""}),ne.exports.jsx(Tr,{children:`${us({input:u,decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsx(Tr,{sx:{typography:"h6",mt:4,color:w.palette.text.secondary},children:m?`$${cs({input:m,showDecimals:1})}(${d}%)`:"-"})]})]}),ne.exports.jsx(Tr,{sx:{mt:12,typography:"h6"},children:`1 ${null==a?void 0:a.symbol} = ${us({input:new C.default(u).dividedBy(new C.default(c)),decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsxs(Tr,{sx:{py:15,typography:"body2",borderBottom:`1px solid ${w.palette.border.main}`},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center",color:w.palette.text.secondary},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Tr,{sx:{width:16,mr:7},component:i.DetailBorder}),ne.exports.jsx(e.Trans,{id:"Swap Detail"})]}),ne.exports.jsx(Tr,{component:wn,children:ne.exports.jsx(Tr,{onClick:()=>M(!N),sx:{width:10,color:"text.secondary",transform:N?"rotateX(0deg)":"rotateX(180deg)"},component:i.CaretUp})})]}),ne.exports.jsxs(Tr,{sx:{mt:16,display:N?"initial":"none"},children:[ne.exports.jsxs(Tr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Basic Fee"}),ne.exports.jsx(Pg,{title:ne.exports.jsx(e.Trans,{id:"Estimated service provider fees"}),ml:5})]}),ne.exports.jsx(Tr,{children:`${us({input:h,decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsxs(Tr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Additional Fee"}),ne.exports.jsx(Pg,{title:ne.exports.jsx(e.Trans,{id:"Additional routing fees set by the Widget user"}),ml:5})]}),ne.exports.jsx(Tr,{children:`${us({input:b,decimals:null==s?void 0:s.decimals})} ${null==s?void 0:s.symbol}`})]}),ne.exports.jsxs(Tr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Price Impact"}),ne.exports.jsx(Pg,{title:ne.exports.jsx(e.Trans,{id:"Due to the market condition, market price and estimated price may have a slight difference"}),ml:5})]}),ne.exports.jsx(Tr,{children:`${d}%`})]}),ne.exports.jsxs(Tr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Slippage"}),ne.exports.jsx(Pg,{title:ne.exports.jsx(e.Trans,{id:"High slippage tolerance will increase the success rate of transaction, but might not get the best quote."}),ml:5})]}),ne.exports.jsx(Tr,{children:E})]})]})]}),ne.exports.jsx(Tr,{sx:{flex:1}}),R&&ne.exports.jsxs(Tr,{sx:{mb:14,display:"flex",cursor:"pointer",justifyContent:"center",alignItems:"center",typography:"h6"},onClick:()=>T(!S),children:[ne.exports.jsx(Tr,{sx:{mr:4,width:18,height:18,alignItems:"center"},children:S?ne.exports.jsx(Tr,{sx:{width:"100%",height:"100%",borderRadius:4,display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"secondary.main"},children:ne.exports.jsx(Tr,{component:i.Done,sx:{width:14,color:"#1a1a1b"}})}):ne.exports.jsx(Tr,{sx:{width:"100%",height:"100%",borderRadius:4,border:`1px solid ${w.palette.text.secondary}`}})}),ne.exports.jsx(Tr,{children:ne.exports.jsx(e.Trans,{components:{0:ne.exports.jsx(Tr,{component:"span",sx:{color:"error.main"}})},values:{priceImpact:d},id:"Price impact reaches <0>{priceImpact}</0>%, accept the quote"})})]}),ne.exports.jsx(vn,{isLoading:k==Ef.Pending,disabled:R&&!S,fullWidth:!0,onClick:()=>{r(),A(rg({contractStatus:Ef.Pending}))},children:k==Ef.Pending?ne.exports.jsx(e.Trans,{id:"Confirming"}):ne.exports.jsx(e.Trans,{id:"Confirm swap"})})]})})}function Dg(e){var{sx:r,maxVal:n,decimals:o=2,onInputChange:i}=e,s=ha(e,["sx","maxVal","decimals","onInputChange"]);return Cr(),ne.exports.jsx(In,{...s,onChange:e=>{const r=0===e.target.value.length?null:fs(e.target.value,o),s=n&&r&&new t.BigNumber(r).gt(n)?n.toString():r;console.log("finalVal:",s),i&&i(s)}})}function Lg({open:t,onClose:r,isBridge:o}){const i=Cr(),s=l.useDispatch(),a=l.useSelector(Cg),c=l.useSelector(Rg),u=n.useMemo((()=>Number(a)>=50),[a]),d=Tg(o);return ne.exports.jsx(Bm,{open:t,onClose:r,title:ne.exports.jsx(e.Trans,{id:"Settings"}),children:ne.exports.jsxs(Tr,{sx:{mx:20},children:[ne.exports.jsxs(Tr,{sx:{py:20,borderTop:`1px solid ${i.palette.border.main}`},children:[ne.exports.jsxs(Tr,{sx:{mb:16,display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Slippage Tolerance"}),ne.exports.jsx(Pg,{title:ne.exports.jsx(e.Trans,{id:"Attention: High slippage tolerance will increase the success rate of transaction, but might not get the best quote."}),ml:7})]}),ne.exports.jsxs(Tr,{sx:{display:"flex",flexDirection:"column"},children:[ne.exports.jsx(Dg,{fullWidth:!0,maxVal:100,value:null!=a?a:"",placeholder:d.toString(),onInputChange:e=>{!function(e,t){null===t?localStorage.removeItem(e?"DODO_WIDGET_SLIPPAGE_BRIDGE":"DODO_WIDGET_SLIPPAGE_SWAP"):localStorage.setItem(e?"DODO_WIDGET_SLIPPAGE_BRIDGE":"DODO_WIDGET_SLIPPAGE_SWAP",String(t))}(!!o,e),s(mg(e))},suffix:ne.exports.jsx(Tr,{sx:{color:"text.disabled"},children:"%"}),height:36}),u&&ne.exports.jsx(Tr,{sx:{typography:"h6",mt:6,color:"error.main"},children:ne.exports.jsx(e.Trans,{id:"Maximum slippage do not exceed 50%"})})]})]}),o?"":ne.exports.jsxs(Tr,{sx:{py:20,borderTop:`1px solid ${i.palette.border.main}`},children:[ne.exports.jsxs(Tr,{sx:{mb:16,display:"flex",alignItems:"center"},children:[ne.exports.jsx(e.Trans,{id:"Transaction Deadline"}),ne.exports.jsx(Pg,{title:ne.exports.jsx(e.Trans,{id:"If your transaction time exceeds the deadline, your transaction will be rescinded."}),ml:7})]}),ne.exports.jsx(Dg,{value:c,fullWidth:!0,height:36,placeholder:v.i18n._("{DEFAULT_SWAP_DDL} minutes",{DEFAULT_SWAP_DDL:20}),onInputChange:e=>{s((e=>t=>ma(void 0,void 0,void 0,(function*(){t({type:"SET_TRANSACTION_DDL",payload:e})})))(e?Math.max(Number(e),1):""))}})]})]})})}function Ug({toToken:t,fromToken:r,priceStatus:o,pricePerToToken:s,pricePerFromToken:a}){const[l,c]=n.useState("-"),[u,d]=n.useState(null),[p,f]=n.useState("-"),[h,m]=n.useState(null);n.useEffect((()=>{c(null==r?void 0:r.symbol),f(null==t?void 0:t.symbol),d(s),m(a)}),[r,t,s,a]);const g=n.useCallback((()=>{c(p),f(l),d(h),m(u)}),[l,u,p,h]);return ne.exports.jsx(Tr,{sx:{display:"flex",justifyContent:"center",alignItems:"center"},children:{[Mg.Initial]:"-",[Mg.Loading]:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(_n,{sx:{mr:5}}),ne.exports.jsx(e.Trans,{id:"Fetching best price..."})]}),[Mg.Failed]:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Tr,{component:i.Warn,sx:{width:15,mr:5,color:"warning.main"}}),ne.exports.jsx(e.Trans,{id:"Quote not available"})]}),[Mg.Success]:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Tr,{sx:{typography:"body2"},children:`1 ${l} = ${cs({input:h,showDecimals:4})} ${p}`}),ne.exports.jsx(Tr,{component:wn,sx:{width:18,height:18,ml:6,borderRadius:"50%",backgroundColor:"border.main",display:"flex",justifyContent:"center",alignItems:"center"},children:ne.exports.jsx(Tr,{sx:{width:16,color:"text.secondary"},onClick:g,component:i.Switch})})]})}[o]})}function Vg({open:t,onClose:r}){const n=l.useSelector(Uf).defaultChainId;return ne.exports.jsx(Bm,{title:ne.exports.jsx(e.Trans,{id:"Connect to your wallet"}),open:t,onClose:r,children:ne.exports.jsx(Tr,{sx:{mx:20,pb:20,border:"1px solid transparent",borderTopColor:"border.main"},children:Object.values(hf).map((t=>ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",flexDirection:"column",mt:20,p:20,backgroundColor:"background.tag",borderRadius:12,cursor:"pointer","&:hover":{backgroundColor:"hover.default"}},onClick:()=>{!function(e,t,r){var n;const o=mf[e];if(!o)throw new Error(`Unknown wallet type: ${e}`);const[i]=o;null===(n=i.activate(t))||void 0===n||n.catch((e=>{4001!==e.code?r(e):i.connectEagerly?i.connectEagerly(t):i.activate(t)}))}(t.type,n,(e=>{console.error(e)}))},children:[ne.exports.jsx(Tr,{component:t.icon,sx:{width:32,height:32}}),ne.exports.jsx(Tr,{sx:{mt:8,typography:"caption"},children:t.name}),ne.exports.jsx(Tr,{sx:{mt:4,typography:"body2",color:"text.secondary"},children:ne.exports.jsx(e.Trans,{id:"Connect to your {0} Wallet",values:{0:t.name}})})]},t.type)))})})}function Zg(){const{connector:t}=u.useWeb3React(),[r,o]=n.useState(!1);return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(vn,{size:vn.Size.middle,fullWidth:!0,onClick:()=>{t.deactivate?t.deactivate():t.resetState(),o(!0)},"data-testid":"connect-wallet-btn",children:ne.exports.jsx(e.Trans,{id:"Connect to a wallet"})}),ne.exports.jsx(Vg,{open:r,onClose:()=>o(!1)})]})}var Hg,zg;function Yg({chainId:e,account:t,token:r,proxyContractAddress:o}){const[i,s]=n.useState(!1),[a,c]=n.useState(!1),[u,d]=n.useState(null),p=l.useSelector(Uf).jsonRpcUrlMap,f=l.useSelector(Mf),h=n.useCallback((()=>ma(this,void 0,void 0,(function*(){if(!t||!e||!r)return;s(!0);const n=Object.assign(Object.assign({},sa),p)[e],i=new nf(null==n?void 0:n[0]);try{const n=yield function({account:e,tokenAddress:t,tokenDecimals:r,chainId:n,approveAddress:o,provider:i}){return ma(this,void 0,void 0,(function*(){if(!e||!t)return;const s=Hf[n],{DODO_APPROVE:a}=s,l=null!=o?o:a,c=new b.Contract(t,$h,i),u=yield c.allowance(e,l),d=new C.default(10).pow(r);return new C.default(u.toString()).div(d)}))}({account:t,chainId:e,tokenAddress:r.address,tokenDecimals:r.decimals,approveAddress:o,provider:i});c(!1),d(null!=n?n:null)}catch(e){console.error(e),c(!0)}finally{s(!1)}}))),[e,r,p,o,t]);return n.useEffect((()=>{h()}),[h,f]),{allowance:u,loading:i,error:a,refetch:h}}!function(e){e.All="all"}(Hg||(Hg={})),function(e){e.Loading="Loading",e.Insufficient="ApprovalInsufficient",e.Approving="Approving",e.Sufficient="Sufficient",e.Unchecked="Unchecked"}(zg||(zg={}));const Gg=({account:e,chainId:t,offset:r,contractAddress:o})=>{var i;const s=l.useSelector(Nf),a=n.useMemo((()=>{var e;return Hf[null!==(e=t)&&void 0!==e?e:s]}),[t]),{isETH:c}=n.useMemo((()=>fa(t)),[t]),{DODO_APPROVE:d}=a||{},p=null!==(i=null!=o?o:d)&&void 0!==i?i:null,f=function(e){const{account:t}=u.useWeb3React(),r=l.useSelector(Nf),o=l.useSelector(_f),i=n.useMemo((()=>la[r]),[r]),s=n.useMemo((()=>Hf[r]),[r]),a=n.useCallback((r=>{var n;if(!t||!e)return null;if(r.symbol===i.symbol&&da(r.address,i.address))return new C.default(tg);const{DODO_APPROVE:a}=s||{};if(e!==a)return null;const l=null===(n=null==o?void 0:o[r.address.toLowerCase()])||void 0===n?void 0:n.tokenAllowances;return null!=l?l:null}),[t,e,i.symbol,i.address,o,s]);return a}(p),[h,m]=n.useState(),{allowance:g}=Yg({chainId:t,account:e,token:h,proxyContractAddress:p}),y=Lf(),{runningRequests:b}=ig(),x=l.useSelector(Df),w=n.useMemo((()=>{var e;return null===(e=la[null!=t?t:s])||void 0===e?void 0:e.address}),[t]),E=n.useCallback(((t,n,o)=>{if(!t)return zg.Loading;const i=!!(null==b?void 0:b.find((e=>e.spec.opcode===$m.Approval&&e.spec.token.address===(null==t?void 0:t.address)))),s=null!=o?o:t?y(t):null;let a=t?f(t):null;const l=new C.default(null!=n?n:0);if(!e)return zg.Unchecked;if(!s||l.minus(null!=r?r:0).gt(s))return zg.Unchecked;if(l.isZero())return zg.Unchecked;return t.address===w?zg.Sufficient:i?zg.Approving:((null==h?void 0:h.address)===t.address&&g&&(a=g),a?a&&l.minus(null!=r?r:0).gt(a)?zg.Insufficient:zg.Sufficient:(p===d||h&&h.address===t.address||m(t),zg.Loading))}),[y,f,e,r,p,t,x,b,w,h,null==g?void 0:g.toString()]),A=n.useCallback((e=>{const t=e?f(e):null;return("USDT"===(null==e?void 0:e.symbol)||(null==e?void 0:e.address.toLowerCase())==="0x6426e6017968377529487E0ef0aA4E7759724e05".toLowerCase())&&null!==t&&t.gt(0)}),[f]),k=ag(),R=l.useDispatch(),S=n.useCallback(((t,r)=>ma(void 0,void 0,void 0,(function*(){if(!p||!e||!t)return;const n=(e=>{let t=e.symbol;return t.indexOf("DLP_")>-1&&(t=t.replace("DLP_","")),t.indexOf("DLP")>-1&&(t=t.replace("DLP","LP")),t})(t),o=r?new C.default(0):void 0,i=r?v.i18n._("Reset"):v.i18n._("Approve");var s;(yield k.execute(`${i} ${n}`,{opcode:$m.Approval,token:t,contract:p,amt:o}))===Xm.Success&&R((s=null!=o?o:tg,e=>ma(void 0,void 0,void 0,(function*(){e({type:"SET_ACCOUNT_ALLOWANCES",payload:s})}))))}))),[p,e,t,k,R]),T=n.useCallback((e=>{const t=new C.default(0);if(!e)return t.toString();const r=y(e);if(!r)return t.toString();let n=r;const o=c?.1:.02;return w===(null==e?void 0:e.address)&&(n=r.gt(o)?r.minus(o):t),n.toString()}),[t,y,c]);return{getApprovalState:E,getPendingRest:A,getMaxBalance:T,submitApprove:S}};var Xg,Jg,qg;function Qg(){return Qg=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Qg.apply(this,arguments)}!function(e){e.Initial="Initial",e.Loading="Loading",e.Failed="Failed",e.Success="Success"}(Xg||(Xg={}));var Kg,$g;function ey(){return ey=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ey.apply(this,arguments)}var ty,ry;function ny(){return ny=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ny.apply(this,arguments)}var oy,iy,sy;function ay(){return ay=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ay.apply(this,arguments)}var ly,cy;function uy(){return uy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},uy.apply(this,arguments)}var dy,py,fy,hy;function my(){return my=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},my.apply(this,arguments)}var gy,yy,by;function vy(){return vy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},vy.apply(this,arguments)}var xy,wy,Ey,Ay,ky,Cy;function Ry(){return Ry=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ry.apply(this,arguments)}var Sy,Ty;function Ny(){return Ny=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ny.apply(this,arguments)}var My,Oy,Iy,jy,Fy,_y;function Py(){return Py=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Py.apply(this,arguments)}var By,Wy,Dy;function Ly(){return Ly=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ly.apply(this,arguments)}const Uy=[{id:"cBridge",logoURI:function(e){return S.createElement("svg",vy({width:34,height:34,viewBox:"0 0 34 34",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),gy||(gy=S.createElement("rect",{x:1,y:1,width:32,height:32,rx:8,fill:"white",stroke:"#33363F"})),yy||(yy=S.createElement("g",{clipPath:"url(#clip0_37_1169)"},S.createElement("path",{d:"M10.9221 22C13.0882 22 14.8442 21.2006 14.8442 20.2144C14.8442 19.2283 13.0882 18.4288 10.9221 18.4288C8.75599 18.4288 7 19.2283 7 20.2144C7 21.2006 8.75599 22 10.9221 22Z",fill:"#444444"}),S.createElement("path",{d:"M23.5587 22C25.7248 22 27.4808 21.2006 27.4808 20.2144C27.4808 19.2283 25.7248 18.4288 23.5587 18.4288C21.3926 18.4288 19.6366 19.2283 19.6366 20.2144C19.6366 21.2006 21.3926 22 23.5587 22Z",fill:"#DDDDDD"}),S.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.88456 20.2144C9.84901 20.2146 9.81379 20.2076 9.78098 20.1939C9.74818 20.1802 9.71844 20.1601 9.69353 20.1347C9.66862 20.1094 9.64903 20.0793 9.63593 20.0462C9.62283 20.0132 9.61648 19.9779 9.61725 19.9423C9.7509 15.5317 13.1124 12 17.2394 12C21.3663 12 24.7278 15.5317 24.8615 19.9423C24.8622 19.9779 24.8559 20.0132 24.8428 20.0462C24.8297 20.0793 24.8101 20.1094 24.7852 20.1347C24.7603 20.1601 24.7306 20.1802 24.6977 20.1939C24.6649 20.2076 24.6297 20.2146 24.5942 20.2144H22.0874C22.0152 20.2135 21.946 20.1848 21.8943 20.1344C21.8426 20.0839 21.8123 20.0155 21.8096 19.9433C21.6894 17.1106 19.6894 14.8567 17.2403 14.8567C14.7913 14.8567 12.7913 17.1106 12.6711 19.9433C12.6684 20.0155 12.638 20.0839 12.5863 20.1344C12.5346 20.1848 12.4655 20.2135 12.3932 20.2144H9.88456Z",fill:"#FF957E"}))),by||(by=S.createElement("defs",null,S.createElement("clipPath",{id:"clip0_37_1169"},S.createElement("rect",{width:20.4808,height:10,fill:"white",transform:"translate(7 12)"})))))},name:"cBridge"},{id:"stargate",logoURI:function(e){return S.createElement("svg",Py({width:32,height:32,viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),My||(My=S.createElement("path",{d:"M0.5 8C0.5 3.85786 3.85786 0.5 8 0.5H24C28.1421 0.5 31.5 3.85786 31.5 8V24C31.5 28.1421 28.1421 31.5 24 31.5H8C3.85786 31.5 0.5 28.1421 0.5 24V8Z",fill:"black",stroke:"black"})),Oy||(Oy=S.createElement("path",{d:"M17.5867 8.63649L18.0125 9.63382C18.8482 11.592 20.4079 13.1518 22.3662 13.9875L23.3635 14.4133C23.6245 14.5246 23.8365 14.6842 24 14.8743C23.5033 11.3132 20.6868 8.49629 17.1257 8C17.3154 8.16317 17.4754 8.37546 17.5867 8.63649Z",fill:"#999999"})),Iy||(Iy=S.createElement("path",{d:"M8.63649 14.4133L9.63382 13.9875C11.592 13.1518 13.1518 11.592 13.9879 9.63382L14.4133 8.63649C14.525 8.37546 14.6846 8.16317 14.8743 8C11.3132 8.49629 8.49667 11.3132 8 14.8743C8.16357 14.6842 8.37548 14.5246 8.63649 14.4133Z",fill:"#999999"})),jy||(jy=S.createElement("path",{d:"M23.3635 17.5863L22.3662 18.0121C20.4079 18.8479 18.8482 20.408 18.0125 22.3662L17.5867 23.3632C17.4754 23.6242 17.3154 23.8365 17.1257 24C20.6868 23.5034 23.5033 20.6865 24 17.1253C23.8365 17.3154 23.6245 17.475 23.3635 17.5863Z",fill:"#999999"})),Fy||(Fy=S.createElement("path",{d:"M14.4133 23.3632L13.9879 22.3662C13.1518 20.408 11.592 18.8479 9.63382 18.0121L8.63649 17.5863C8.37548 17.475 8.16357 17.3154 8 17.1253C8.49667 20.6865 11.3132 23.5034 14.8743 24C14.6846 23.8365 14.525 23.6242 14.4133 23.3632Z",fill:"#999999"})),_y||(_y=S.createElement("path",{d:"M12.3715 15.2177L12.863 15.0078C13.8278 14.5959 14.5966 13.8275 15.0086 12.8626L15.2181 12.3711C15.512 11.6827 16.4879 11.6827 16.7818 12.3711L16.9913 12.8626C17.4032 13.8275 18.172 14.5959 19.1369 15.0078L19.6284 15.2177C20.3168 15.5116 20.3168 16.4872 19.6284 16.7811L19.1369 16.991C18.172 17.4029 17.4032 18.1713 16.9913 19.1366L16.7818 19.6276C16.4879 20.3161 15.512 20.3161 15.2181 19.6276L15.0086 19.1366C14.5966 18.1713 13.8278 17.4029 12.863 16.991L12.3715 16.7811C11.6831 16.4872 11.6831 15.5116 12.3715 15.2177Z",fill:"#F2F2F2"})))},name:"Stargate"},{id:"connext",logoURI:function(e){return S.createElement("svg",Ry({width:32,height:32,viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),xy||(xy=S.createElement("rect",{width:32,height:32,rx:8,fill:"black"})),wy||(wy=S.createElement("path",{d:"M13.0566 9.12524C13.0566 9.12524 12.31 9.87191 11.4353 10.7466L7.90996 14.2399C6.46996 15.7066 7.0353 17.1999 8.03796 18.2026L10.918 21.0826C11.174 21.3386 12.1766 22.3946 12.9766 21.5732C13.4406 21.1092 13.3393 20.3892 13.078 20.1066L9.76063 16.8159C9.16863 16.2239 9.4513 15.6852 10.0433 15.1199L12.8753 12.2879L14.6513 14.0639C15.27 14.6826 16.038 14.9119 16.6833 14.2719C17.3286 13.6266 16.9393 13.0132 16.3206 12.3946L14.3633 10.4372L13.0566 9.12524Z",fill:"url(#paint0_linear_5431_181414)"})),Ey||(Ey=S.createElement("path",{d:"M13.2112 9.25332C12.7472 8.78932 12.0805 8.53332 11.4352 9.17865C10.7898 9.82399 11.1258 10.544 11.5365 10.9547",fill:"url(#paint1_linear_5431_181414)"})),Ay||(Ay=S.createElement("path",{d:"M18.9218 22.8638C18.9218 22.8638 19.6685 22.1171 20.5432 21.2424L24.0685 17.7171C25.5352 16.2504 24.9698 14.7571 23.9405 13.7544L21.0605 10.9011C20.8045 10.6451 19.8018 9.5891 19.0018 10.4104C18.5378 10.8744 18.6392 11.5944 18.9005 11.8771L22.2178 15.1678C22.8098 15.7598 22.5272 16.2984 21.9352 16.8638L19.1032 19.6958L17.3272 17.9198C16.7085 17.3011 15.9405 17.0718 15.2952 17.7118C14.6498 18.3518 15.0392 18.9704 15.6578 19.5891L17.6152 21.5464L18.9218 22.8638Z",fill:"url(#paint2_linear_5431_181414)"})),ky||(ky=S.createElement("path",{d:"M18.7671 22.7306C19.2311 23.1946 19.8978 23.4772 20.5431 22.8319C21.1884 22.1866 20.8524 21.4666 20.4418 21.0559",fill:"url(#paint3_linear_5431_181414)"})),Cy||(Cy=S.createElement("defs",null,S.createElement("linearGradient",{id:"paint0_linear_5431_181414",x1:7.86029,y1:12.5047,x2:23.8117,y2:22.7959,gradientUnits:"userSpaceOnUse"},S.createElement("stop",{stopColor:"#29C1FC"}),S.createElement("stop",{offset:.5022,stopColor:"#AB00FF"}),S.createElement("stop",{offset:.5082,stopColor:"#AC03FC"}),S.createElement("stop",{offset:.6406,stopColor:"#C840B8"}),S.createElement("stop",{offset:.7601,stopColor:"#DE7082"}),S.createElement("stop",{offset:.8629,stopColor:"#EE935B"}),S.createElement("stop",{offset:.9448,stopColor:"#F7A844"}),S.createElement("stop",{offset:.9956,stopColor:"#FBB03B"})),S.createElement("linearGradient",{id:"paint1_linear_5431_181414",x1:10.2949,y1:8.73084,x2:26.2463,y2:19.0221,gradientUnits:"userSpaceOnUse"},S.createElement("stop",{stopColor:"#29C1FC"}),S.createElement("stop",{offset:.5022,stopColor:"#AB00FF"}),S.createElement("stop",{offset:.5082,stopColor:"#AC03FC"}),S.createElement("stop",{offset:.6406,stopColor:"#C840B8"}),S.createElement("stop",{offset:.7601,stopColor:"#DE7082"}),S.createElement("stop",{offset:.8629,stopColor:"#EE935B"}),S.createElement("stop",{offset:.9448,stopColor:"#F7A844"}),S.createElement("stop",{offset:.9956,stopColor:"#FBB03B"})),S.createElement("linearGradient",{id:"paint2_linear_5431_181414",x1:9.46092,y1:10.0213,x2:25.4123,y2:20.3125,gradientUnits:"userSpaceOnUse"},S.createElement("stop",{stopColor:"#29C1FC"}),S.createElement("stop",{offset:.5022,stopColor:"#AB00FF"}),S.createElement("stop",{offset:.5082,stopColor:"#AC03FC"}),S.createElement("stop",{offset:.6406,stopColor:"#C840B8"}),S.createElement("stop",{offset:.7601,stopColor:"#DE7082"}),S.createElement("stop",{offset:.8629,stopColor:"#EE935B"}),S.createElement("stop",{offset:.9448,stopColor:"#F7A844"}),S.createElement("stop",{offset:.9956,stopColor:"#FBB03B"})),S.createElement("linearGradient",{id:"paint3_linear_5431_181414",x1:7.01942,y1:13.8057,x2:22.9708,y2:24.0969,gradientUnits:"userSpaceOnUse"},S.createElement("stop",{stopColor:"#29C1FC"}),S.createElement("stop",{offset:.5022,stopColor:"#AB00FF"}),S.createElement("stop",{offset:.5082,stopColor:"#AC03FC"}),S.createElement("stop",{offset:.6406,stopColor:"#C840B8"}),S.createElement("stop",{offset:.7601,stopColor:"#DE7082"}),S.createElement("stop",{offset:.8629,stopColor:"#EE935B"}),S.createElement("stop",{offset:.9448,stopColor:"#F7A844"}),S.createElement("stop",{offset:.9956,stopColor:"#FBB03B"})))))},name:"Connext"},{id:"synapse",logoURI:function(e){return S.createElement("svg",Ly({width:32,height:32,viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),S.createElement("mask",{id:"mask0_419_48383",style:{maskType:"alpha"},maskUnits:"userSpaceOnUse",x:0,y:0,width:32,height:32},By||(By=S.createElement("path",{d:"M0 8C0 3.58172 3.58172 0 8 0H24C28.4183 0 32 3.58172 32 8V24C32 28.4183 28.4183 32 24 32H8C3.58172 32 0 28.4183 0 24V8Z",fill:"black"}))),Wy||(Wy=S.createElement("g",{mask:"url(#mask0_419_48383)"},S.createElement("path",{d:"M0 8C0 3.58172 3.58172 0 8 0H24C28.4183 0 32 3.58172 32 8V24C32 28.4183 28.4183 32 24 32H8C3.58172 32 0 28.4183 0 24V8Z",fill:"#121826"}),S.createElement("path",{d:"M15.9794 7C15.5251 7 15.1568 7.36058 15.1568 7.80538C15.1568 8.25017 15.5251 8.61075 15.9794 8.61075C16.4337 8.61075 16.802 8.25017 16.802 7.80538C16.802 7.36058 16.4337 7 15.9794 7Z",fill:"url(#paint0_radial_419_48383)"}),S.createElement("path",{d:"M15.9794 7.44297C16.1839 7.44297 16.3496 7.60522 16.3496 7.80537C16.3496 8.00551 16.1839 8.16776 15.9794 8.16776C15.775 8.16776 15.6093 8.00551 15.6093 7.80537C15.6093 7.60522 15.775 7.44293 15.9794 7.44293V7.44297ZM12.4422 9.13423C11.9879 9.13423 11.6196 9.49481 11.6196 9.93961C11.6196 10.3844 11.9878 10.7449 12.4422 10.7449C12.8965 10.7449 13.2648 10.3844 13.2648 9.93961C13.2648 9.49481 12.8965 9.13423 12.4422 9.13423ZM19.599 9.17448C19.1446 9.17448 18.7764 9.53506 18.7764 9.97986C18.7764 10.4247 19.1446 10.7852 19.599 10.7852C20.0533 10.7852 20.4216 10.4247 20.4216 9.97986C20.4216 9.53506 20.0533 9.17448 19.599 9.17448V9.17448Z",fill:"url(#paint1_radial_419_48383)"}),S.createElement("path",{d:"M12.4422 9.57715C12.6466 9.57715 12.8124 9.7394 12.8124 9.93958C12.8124 10.1397 12.6466 10.302 12.4422 10.302C12.2377 10.302 12.072 10.1397 12.072 9.93958C12.072 9.7394 12.2377 9.57715 12.4422 9.57715ZM19.599 9.6174C19.8034 9.6174 19.9691 9.77965 19.9691 9.97984C19.9691 10.18 19.8034 10.3422 19.599 10.3422C19.3945 10.3422 19.2288 10.18 19.2288 9.97984C19.2288 9.77969 19.3945 9.6174 19.599 9.6174V9.6174ZM15.9794 10.9866C15.457 10.9866 15.0334 11.4012 15.0334 11.9127C15.0334 12.4242 15.457 12.8389 15.9794 12.8389C16.5019 12.8389 16.9255 12.4242 16.9255 11.9127C16.9255 11.4012 16.5019 10.9866 15.9794 10.9866ZM8.8226 11.1074C8.3683 11.1074 8 11.4679 8 11.9127C8 12.3575 8.3683 12.7181 8.8226 12.7181C9.27695 12.7181 9.64525 12.3575 9.64525 11.9127C9.64525 11.4679 9.27695 11.1074 8.8226 11.1074ZM23.1774 11.1074C22.723 11.1074 22.3548 11.4679 22.3548 11.9127C22.3548 12.3575 22.723 12.7181 23.1774 12.7181C23.6317 12.7181 24 12.3575 24 11.9127C24 11.4679 23.6317 11.1074 23.1774 11.1074V11.1074Z",fill:"url(#paint2_radial_419_48383)"}),S.createElement("path",{d:"M15.9794 11.4295C16.252 11.4295 16.473 11.6458 16.473 11.9127C16.473 12.1796 16.252 12.3959 15.9794 12.3959C15.7068 12.3959 15.4859 12.1796 15.4859 11.9127C15.4859 11.6458 15.7068 11.4295 15.9794 11.4295V11.4295ZM8.82261 11.5503C9.02706 11.5503 9.19281 11.7126 9.19281 11.9127C9.19281 12.1129 9.02706 12.2751 8.82261 12.2751C8.61817 12.2751 8.45245 12.1129 8.45245 11.9127C8.45245 11.7126 8.61817 11.5503 8.82261 11.5503V11.5503ZM23.1774 11.5503C23.3818 11.5503 23.5476 11.7126 23.5476 11.9127C23.5476 12.1129 23.3818 12.2751 23.1774 12.2751C22.973 12.2751 22.8072 12.1129 22.8072 11.9127C22.8072 11.7126 22.973 11.5503 23.1774 11.5503ZM12.3188 13C11.7963 13 11.3727 13.4146 11.3727 13.9261C11.3727 14.4377 11.7963 14.8523 12.3188 14.8523C12.8412 14.8523 13.2648 14.4377 13.2648 13.9261C13.2648 13.4146 12.8412 13 12.3188 13ZM19.599 13C19.0765 13 18.653 13.4146 18.653 13.9261C18.653 14.4377 19.0765 14.8523 19.599 14.8523C20.1214 14.8523 20.545 14.4377 20.545 13.9261C20.545 13.4146 20.1214 13 19.599 13Z",fill:"url(#paint3_radial_419_48383)"}),S.createElement("path",{d:"M12.3187 13.443C12.5913 13.443 12.8123 13.6593 12.8123 13.9262C12.8123 14.1931 12.5913 14.4094 12.3187 14.4094C12.0461 14.4094 11.8252 14.1931 11.8252 13.9262C11.8252 13.6593 12.0461 13.443 12.3187 13.443ZM19.599 13.443C19.8715 13.443 20.0925 13.6593 20.0925 13.9262C20.0925 14.1931 19.8715 14.4094 19.599 14.4094C19.3264 14.4094 19.1054 14.1931 19.1054 13.9262C19.1054 13.6593 19.3264 13.443 19.599 13.443Z",fill:"url(#paint4_radial_419_48383)"}),S.createElement("path",{d:"M8.8226 15.1745C8.3683 15.1745 8 15.5351 8 15.9799C8 16.4247 8.3683 16.7853 8.8226 16.7853C9.27695 16.7853 9.64525 16.4247 9.64525 15.9799C9.64525 15.5351 9.27695 15.1745 8.8226 15.1745ZM23.1774 15.1745C22.723 15.1745 22.3548 15.5351 22.3548 15.9799C22.3548 16.4247 22.723 16.7853 23.1774 16.7853C23.6317 16.7853 24 16.4247 24 15.9799C24 15.5351 23.6317 15.1745 23.1774 15.1745ZM16.0206 15.2953C16.4067 15.2953 16.7198 15.6018 16.7198 15.9799C16.7198 16.358 16.4067 16.6645 16.0206 16.6645C15.6344 16.6645 15.3214 16.358 15.3214 15.9799C15.3214 15.6018 15.6344 15.2953 16.0206 15.2953Z",fill:"url(#paint5_radial_419_48383)"}),S.createElement("path",{d:"M8.82261 15.6174C9.02706 15.6174 9.19281 15.7797 9.19281 15.9798C9.19281 16.18 9.02706 16.3423 8.82261 16.3423C8.61817 16.3423 8.45245 16.18 8.45245 15.9798C8.45245 15.7797 8.61817 15.6174 8.82261 15.6174V15.6174ZM23.1774 15.6174C23.3818 15.6174 23.5476 15.7797 23.5476 15.9798C23.5476 16.18 23.3818 16.3423 23.1774 16.3423C22.973 16.3423 22.8072 16.18 22.8072 15.9798C22.8072 15.7797 22.973 15.6174 23.1774 15.6174ZM12.4422 17.0671C11.9197 17.0671 11.4961 17.4818 11.4961 17.9933C11.4961 18.5048 11.9197 18.9194 12.4422 18.9194C12.9646 18.9194 13.3882 18.5048 13.3882 17.9933C13.3882 17.4818 12.9646 17.0671 12.4422 17.0671V17.0671ZM19.599 17.0671C19.0765 17.0671 18.653 17.4818 18.653 17.9933C18.653 18.5048 19.0765 18.9194 19.599 18.9194C20.1214 18.9194 20.545 18.5048 20.545 17.9933C20.545 17.4818 20.1214 17.0671 19.599 17.0671V17.0671Z",fill:"url(#paint6_radial_419_48383)"}),S.createElement("path",{d:"M12.4422 17.5101C12.7148 17.5101 12.9357 17.7264 12.9357 17.9933C12.9357 18.2602 12.7148 18.4765 12.4422 18.4765C12.1696 18.4765 11.9486 18.2602 11.9486 17.9933C11.9486 17.7264 12.1696 17.5101 12.4422 17.5101V17.5101ZM19.599 17.5101C19.8716 17.5101 20.0925 17.7264 20.0925 17.9933C20.0925 18.2602 19.8716 18.4765 19.599 18.4765C19.3264 18.4765 19.1054 18.2602 19.1054 17.9933C19.1054 17.7264 19.3264 17.5101 19.599 17.5101V17.5101ZM15.9794 19.0805C15.457 19.0805 15.0334 19.4952 15.0334 20.0067C15.0334 20.5182 15.457 20.9329 15.9794 20.9329C16.5019 20.9329 16.9255 20.5182 16.9255 20.0067C16.9255 19.4952 16.5019 19.0805 15.9794 19.0805ZM8.8226 19.2416C8.3683 19.2416 8 19.6022 8 20.047C8 20.4918 8.3683 20.8524 8.8226 20.8524C9.27695 20.8524 9.64525 20.4918 9.64525 20.047C9.64525 19.6022 9.27695 19.2416 8.8226 19.2416ZM23.1774 19.2416C22.723 19.2416 22.3548 19.6022 22.3548 20.047C22.3548 20.4918 22.723 20.8524 23.1774 20.8524C23.6317 20.8524 24 20.4918 24 20.047C24 19.6022 23.6317 19.2416 23.1774 19.2416Z",fill:"url(#paint7_radial_419_48383)"}),S.createElement("path",{d:"M15.9794 19.5235C16.252 19.5235 16.473 19.7398 16.473 20.0067C16.473 20.2736 16.252 20.4899 15.9794 20.4899C15.7068 20.4899 15.4859 20.2736 15.4859 20.0067C15.4859 19.7398 15.7068 19.5235 15.9794 19.5235ZM8.82261 19.6845C9.02706 19.6845 9.19281 19.8468 9.19281 20.047C9.19281 20.2471 9.02706 20.4094 8.82261 20.4094C8.61817 20.4094 8.45245 20.2471 8.45245 20.047C8.45245 19.8468 8.61817 19.6845 8.82261 19.6845V19.6845ZM23.1774 19.6845C23.3818 19.6845 23.5476 19.8468 23.5476 20.047C23.5476 20.2471 23.3818 20.4094 23.1774 20.4094C22.973 20.4094 22.8072 20.2471 22.8072 20.047C22.8072 19.8468 22.973 19.6845 23.1774 19.6845ZM12.4422 21.255C11.9879 21.255 11.6196 21.6156 11.6196 22.0604C11.6196 22.5052 11.9878 22.8658 12.4422 22.8658C12.8965 22.8658 13.2648 22.5052 13.2648 22.0604C13.2648 21.6156 12.8965 21.255 12.4422 21.255ZM19.599 21.2953C19.1446 21.2953 18.7763 21.6559 18.7763 22.1007C18.7763 22.5455 19.1446 22.9061 19.599 22.9061C20.0533 22.9061 20.4216 22.5455 20.4216 22.1007C20.4216 21.6559 20.0533 21.2953 19.599 21.2953Z",fill:"url(#paint8_radial_419_48383)"}),S.createElement("path",{d:"M12.4422 21.698C12.6466 21.698 12.8124 21.8602 12.8124 22.0604C12.8124 22.2606 12.6466 22.4228 12.4422 22.4228C12.2377 22.4228 12.072 22.2606 12.072 22.0604C12.072 21.8602 12.2377 21.698 12.4422 21.698ZM19.599 21.7383C19.8035 21.7383 19.9692 21.9005 19.9692 22.1007C19.9692 22.3008 19.8035 22.4631 19.599 22.4631C19.3946 22.4631 19.2288 22.3008 19.2288 22.1007C19.2288 21.9005 19.3946 21.7383 19.599 21.7383ZM15.9795 23.3893C15.5251 23.3893 15.1568 23.7498 15.1568 24.1946C15.1568 24.6394 15.5251 25 15.9795 25C16.4338 25 16.8021 24.6394 16.8021 24.1946C16.8021 23.7498 16.4338 23.3893 15.9795 23.3893V23.3893Z",fill:"url(#paint9_radial_419_48383)"}),S.createElement("path",{d:"M15.9794 23.8322C16.1838 23.8322 16.3496 23.9945 16.3496 24.1946C16.3496 24.3948 16.1838 24.5571 15.9794 24.5571C15.775 24.5571 15.6092 24.3948 15.6092 24.1946C15.6092 23.9945 15.775 23.8322 15.9794 23.8322ZM19.2699 13.7972L16.3496 15.5288L16.5848 15.9075L19.5051 14.176L19.2699 13.7972V13.7972ZM12.6761 13.7576L12.4331 14.1313L15.3945 15.9837L15.6375 15.6099L12.6761 13.7576V13.7576ZM11.8843 13.9551L9.16962 15.6061L9.40873 15.9824L12.1234 14.3314L11.8843 13.9551ZM22.9113 15.8855L19.9909 17.617L20.2262 17.9958L23.1465 16.2643L22.9113 15.8855ZM15.5077 16.0466L12.5874 17.7781L12.8226 18.1569L15.7429 16.4254L15.5077 16.0466V16.0466ZM16.5437 15.9944L16.3007 16.3681L19.2622 18.2205L19.5051 17.8467L16.5437 15.9944V15.9944Z",fill:"url(#paint10_radial_419_48383)"}),S.createElement("path",{d:"M20.0758 13.8205L19.8328 14.1942L22.7943 16.0466L23.0373 15.6728L20.0758 13.8205ZM9.16191 15.9308L8.91895 16.3045L11.8804 18.1569L12.1234 17.7832L9.16191 15.9308V15.9308Z",fill:"url(#paint11_radial_419_48383)"}))),Dy||(Dy=S.createElement("defs",null,S.createElement("radialGradient",{id:"paint0_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(15.9999 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint1_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint2_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint3_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint4_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(15.9999 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint5_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint6_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint7_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint8_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint9_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(16 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint10_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(15.9999 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})),S.createElement("radialGradient",{id:"paint11_radial_419_48383",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(15.9999 16.0001) scale(7.99998 7.83228)"},S.createElement("stop",{stopColor:"#FF00FF"}),S.createElement("stop",{offset:1,stopColor:"#734CE2"})))))},name:"Synapse"},{id:"swft",logoURI:function(e){return S.createElement("svg",my({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),dy||(dy=S.createElement("path",{d:"M14.0802 2.71222C14.0802 2.71222 12.9826 1.61464 11.6884 1.51537C10.3941 1.4161 9.89405 1.81505 9.99332 2.214C10.0926 2.61295 10.5421 2.66165 11.1396 2.2627C11.7371 1.86375 13.0332 1.96489 14.0802 2.71222Z",fill:"#0999FF"})),py||(py=S.createElement("path",{d:"M13.5408 2.87517C13.5408 2.87517 12.668 2.33013 11.8176 2.45936C10.9673 2.5886 10.6938 2.92012 10.8268 3.16174C10.9598 3.40336 11.2482 3.36964 11.576 3.02314C11.9038 2.67663 12.7523 2.54927 13.5408 2.87517Z",fill:"#0999FF"})),fy||(fy=S.createElement("path",{d:"M12.2597 2.99879C12.6341 2.88498 13.0346 2.89022 13.4059 3.01377C12.8628 2.91825 12.3439 3.13364 12.1866 3.39399C12.0293 3.65434 11.8476 3.71615 11.7352 3.58129C11.6228 3.44644 11.7408 3.1992 12.2597 2.99879Z",fill:"#0999FF"})),hy||(hy=S.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M19.7592 6.10048C17.8075 5.65096 17.1089 5.82703 16.1218 6.25033C15.425 6.5575 15.6236 7.84238 16.0225 8.93996C16.4215 10.0375 17.2194 13.8248 15.425 15.8176C13.9914 17.4099 12.8137 17.6032 10.5679 17.972C10.0027 18.0648 9.36998 18.1687 8.6485 18.3087C5.05982 19.0055 4.86128 21.697 4.86128 21.697C3.17126 12.5314 7.83234 10.1212 10.1284 8.93399C10.4049 8.79097 10.6472 8.6657 10.8399 8.5485C11.9352 7.87375 12.0384 6.61486 12.0958 5.91511C12.1082 5.7641 12.1184 5.63913 12.136 5.55169C12.1467 5.49883 12.1573 5.4355 12.1694 5.36375C12.2698 4.76704 12.4681 3.58853 13.5783 3.01003C16.9703 1.41797 19.7592 6.10048 19.7592 6.10048ZM10.8009 15.8525C11.5854 15.8693 12.9238 15.898 13.6045 14.5964C14.3724 13.1261 13.5221 11.8075 12.3084 11.3917C11.0946 10.9759 9.25161 11.5509 8.04352 13.2366C6.83543 14.9223 6.68934 16.9826 6.68934 16.9826C6.7545 16.9197 6.81451 16.8522 6.87696 16.782C7.13404 16.4929 7.4325 16.1574 8.302 15.8982C8.96656 15.7001 9.67011 15.7718 10.1431 15.82C10.3006 15.836 10.4326 15.8495 10.529 15.8495C10.6088 15.8484 10.7003 15.8504 10.8009 15.8525ZM18.5642 5.503C18.5642 5.503 16.62 5.24639 15.8727 5.9956C15.8727 5.9956 16.472 4.30989 18.5642 5.503Z",fill:"#0999FF"})))},name:"Swft"},{id:"hyphen",logoURI:function(e){return S.createElement("svg",ny({width:24,height:25,viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),ty||(ty=S.createElement("path",{d:"M10.2675 16.7858V15.0715C10.2675 14.5915 10.6618 14.2143 11.1247 14.2143H12.839C13.319 14.2143 13.6961 14.5915 13.6961 15.0715V20.2143C13.6961 20.6943 13.319 21.0715 12.839 21.0715H4.26755C3.78755 21.0715 3.4104 20.6943 3.4104 20.2143V8.21433C3.4104 7.73433 3.03326 7.35719 2.55326 7.35719H2.05612C1.30183 7.35719 0.907546 6.43148 1.45612 5.90005L4.52469 2.81433C4.60378 2.73295 4.69838 2.66825 4.80291 2.62407C4.90745 2.57989 5.01978 2.55713 5.13326 2.55713C5.24674 2.55713 5.35908 2.57989 5.46361 2.62407C5.56814 2.66825 5.66275 2.73295 5.74183 2.81433L8.79326 5.90005C9.34183 6.43148 8.96469 7.35719 8.19326 7.35719H7.69612C7.21612 7.35719 6.83897 7.73433 6.83897 8.21433V16.7858C6.83897 17.2658 7.21612 17.6429 7.69612 17.6429H9.4104C9.8904 17.6429 10.2675 17.2658 10.2675 16.7858Z",fill:"#615CCD"})),ry||(ry=S.createElement("path",{d:"M20.5533 16.7858C20.5533 17.2658 20.9304 17.6429 21.4104 17.6429H21.9247C22.679 17.6429 23.0561 18.5686 22.5247 19.1001L19.4561 22.1686C19.1133 22.5115 18.5818 22.5115 18.239 22.1686L15.1704 19.1001C14.6218 18.5686 14.999 17.6429 15.7704 17.6429H16.2676C16.7476 17.6429 17.1247 17.2658 17.1247 16.7858V8.21436C17.1247 7.73436 16.7476 7.35721 16.2676 7.35721H14.5533C14.0733 7.35721 13.6961 7.73436 13.6961 8.21436V9.92864C13.6961 10.4086 13.319 10.7858 12.839 10.7858H11.1247C10.6447 10.7858 10.2676 10.4086 10.2676 9.92864V4.78578C10.2676 4.30578 10.6447 3.92864 11.1247 3.92864H19.6961C20.1761 3.92864 20.5533 4.30578 20.5533 4.78578V16.7858Z",fill:"#615CCD"})))},name:"Hyphen"},{id:"lifi",logoURI:function(e){return S.createElement("svg",ay({width:24,height:25,viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink"},e),oy||(oy=S.createElement("rect",{y:.5,width:24,height:24,rx:4,fill:"white"})),iy||(iy=S.createElement("rect",{x:7.5,y:6.5,width:8.72727,height:12,fill:"url(#pattern0)"})),sy||(sy=S.createElement("defs",null,S.createElement("pattern",{id:"pattern0",patternContentUnits:"objectBoundingBox",width:1,height:1},S.createElement("use",{xlinkHref:"#image0_1105_25179",transform:"translate(-0.958333 -0.393939) scale(0.0208333 0.0151515)"})),S.createElement("image",{id:"image0_1105_25179",width:252,height:124,xlinkHref:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAPwAAAB8CAYAAABNG92/AAAMbGlDQ1BJQ0MgUHJvZmlsZQAASImVlwdcU0kTwPeVJCQkBAhEQEroTRDpRUoILYKAVMFGSAIJJcaEIGJHj1Pw7CKKFT0V8dDTE5BDRezlUOz9sKCinId6KIrKtymg533l901++94/s7Mzs/P2lQWA3seTSvNQXQDyJQWyhMhQ1vi0dBbpCSACBP7owIPHl0vZ8fExAMrg+e/y9jq0hHLFRenrn/3/VfQFQjkfAGQi5EyBnJ8PuQUAfANfKisAgKjUW08vkCp5HmQDGUwQ8molZ6t5l5Iz1dyssklK4EC+BIAWlceTZQOgcxfqWYX8bOhH5yNkN4lALAGAPgJyEF/EE0BW5j4iP3+qkishO0B7KWSYD/DN/Mpn9t/8Zw755/Gyh1g9L5VohYnl0jzejP+zNP9b8vMUgzHsYKOKZFEJyvnDGt7MnRqtZCrkbklmbJyy1pD7xAJ13QFAKSJFVLLaHjXlyzmwfoAJ2U3AC4uGbAo5QpIXG6PRZ2aJI7iQ4WpBi8QF3CTIRpAXCeXhiRqbLbKpCZpYaH2WjMPW6M/wZKq4ylj3FbnJbI3/1yIhV+Mf0ykWJaVCpkC2KRSnxELWgewqz02M1tiMLhZxYgdtZIoEZf42kBOEkshQtX+sMEsWkaCxL8uXD84X2yISc2M1vL9AlBSlrg92gs9T5Q/ngl0SStjJg36E8vExg3MRCMPC1XPHngklyYkaP33SgtAE9VicIs2L19jjVsK8SKXeCrKnvDBRMxZPKYCLU+0fz5IWxCep88SLc3hj4tX54MtBDOCAMMACCtgywVSQA8Rt3Q3d8J+6JwLwgAxkAyFw0WgGR6SqeiTwmAiKwR+QhEA+NC5U1SsEhVD/aUirPrqALFVvoWpELngCOR9Egzz4X6EaJRmKlgIeQ434H9F5sPFhvnmwKfv/vX5Q+0XDhpoYjUYxGJFFH7QkhhPDiFHECKIjboIH4QF4DDyGwOaO++J+g/P4Yk94QmgnPCRcI3QQbk0Rl8i+yXIs6ID+IzS1yPy6Frgd9OmFh+KB0Dv0jDNxE+CCe8I4bDwYRvaCWo4mb2VVWN/4/tsMvroaGjuyGxklDyOHkB2+HanjpOM15EVZ66/ro841c6jenKGeb+Nzvqq+AJ6jv7XEFmEHsNPYMews1ow1ABZ2FGvELmCHlTy0uh6rVtdgtARVPrnQj/gf8QavrLKScrdaty63j+q+AmFRgfLG40yVzpCJs0UFLDZ8OwhZXAnfdQTL3c3dHQDlu0b9+HrDVL1DEOa5L7oSOgCj3w8MDDR/0cXYAvBLKbz9n3zROVTDx8R8AM6U8xWyQrUOVx4I8ClBh3eaMTAH1sABzscdeIMAEALCwRgQB5JAGpgMsxfBdS4D08EsMB+UgnKwHKwB68FmsA3sAj+B/aABNINj4BQ4Dy6Ba+AOXD2d4AXoAW9BP4IgJISGMBBjxAKxRZwRd8QXCULCkRgkAUlDMpBsRIIokFnIAqQcWYmsR7YiNcjPyCHkGHIWaUduIQ+QLuQ18gHFUCpqgJqhduhI1Bdlo9FoEjoJzUanocXoQnQpWolWo3vQevQYeh69hnagL9BeDGDaGBOzxFwwX4yDxWHpWBYmw+ZgZVgFVo3VYU3wOl/BOrBu7D1OxBk4C3eBKzgKT8b5+DR8Dr4EX4/vwuvxE/gV/AHeg38m0AimBGeCP4FLGE/IJkwnlBIqCDsIBwkn4b3USXhLJBKZRHuiD7wX04g5xJnEJcSNxL3EFmI78RGxl0QiGZOcSYGkOBKPVEAqJa0j7SEdJV0mdZL6tLS1LLTctSK00rUkWiVaFVq7tY5oXdZ6qtVP1iXbkv3JcWQBeQZ5GXk7uYl8kdxJ7qfoUewpgZQkSg5lPqWSUkc5SblLeaOtrW2l7ac9TlusPU+7Unuf9hntB9rvqfpUJyqHOpGqoC6l7qS2UG9R39BoNDtaCC2dVkBbSquhHafdp/XpMHRcdbg6Ap25OlU69TqXdV7SyXRbOps+mV5Mr6AfoF+kd+uSde10Obo83Tm6VbqHdG/o9uox9Ebpxenl6y3R2613Vu+ZPknfTj9cX6C/UH+b/nH9RwyMYc3gMPiMBYztjJOMTgOigb0B1yDHoNzgJ4M2gx5DfUNPwxTDIsMqw8OGHUyMacfkMvOYy5j7mdeZH4aZDWMPEw5bPKxu2OVh74yGG4UYCY3KjPYaXTP6YMwyDjfONV5h3GB8zwQ3cTIZZzLdZJPJSZPu4QbDA4bzh5cN3z/8tilq6mSaYDrTdJvpBdNeM3OzSDOp2Tqz42bd5kzzEPMc89XmR8y7LBgWQRZii9UWRy2eswxZbFYeq5J1gtVjaWoZZamw3GrZZtlvZW+VbFVitdfqnjXF2tc6y3q1dat1j42FzVibWTa1Nrdtyba+tiLbtbanbd/Z2dul2n1v12D3zN7InmtfbF9rf9eB5hDsMM2h2uGqI9HR1zHXcaPjJSfUyctJ5FTldNEZdfZ2FjtvdG4fQRjhN0IyonrEDReqC9ul0KXW5YEr0zXGtcS1wfXlSJuR6SNXjDw98rObl1ue23a3O6P0R40ZVTKqadRrdyd3vnuV+1UPmkeEx1yPRo9Xns6eQs9Nnje9GF5jvb73avX65O3jLfOu8+7ysfHJ8Nngc8PXwDfed4nvGT+CX6jfXL9mv/f+3v4F/vv9/wxwCcgN2B3wbLT9aOHo7aMfBVoF8gK3BnYEsYIygrYEdQRbBvOCq4MfhliHCEJ2hDxlO7Jz2HvYL0PdQmWhB0Pfcfw5szktYVhYZFhZWFu4fnhy+Prw+xFWEdkRtRE9kV6RMyNboghR0VErom5wzbh8bg23Z4zPmNljTkRToxOj10c/jHGKkcU0jUXHjhm7auzdWNtYSWxDHIjjxq2KuxdvHz8t/tdxxHHx46rGPUkYlTAr4XQiI3FK4u7Et0mhScuS7iQ7JCuSW1PoKRNTalLepYalrkztGD9y/Ozx59NM0sRpjemk9JT0Hem9E8InrJnQOdFrYunE65PsJxVNOjvZZHLe5MNT6FN4Uw5kEDJSM3ZnfOTF8ap5vZnczA2ZPXwOfy3/hSBEsFrQJQwUrhQ+zQrMWpn1LDswe1V2lyhYVCHqFnPE68WvcqJyNue8y43L3Zk7kJeatzdfKz8j/5BEX5IrOTHVfGrR1Haps7RU2jHNf9qaaT2yaNkOOSKfJG8sMIAf9RcUDorvFA8KgwqrCvump0w/UKRXJCm6MMNpxuIZT4sjin+cic/kz2ydZTlr/qwHs9mzt85B5mTOaZ1rPXfh3M55kfN2zafMz53/W4lbycqSvxakLmhaaLZw3sJH30V+V1uqUyorvfF9wPebF+GLxIvaFnssXrf4c5mg7Fy5W3lF+ccl/CXnfhj1Q+UPA0uzlrYt8162aTlxuWT59RXBK3at1FtZvPLRqrGr6lezVpet/mvNlDVnKzwrNq+lrFWs7aiMqWxcZ7Nu+bqP60Xrr1WFVu3dYLph8YZ3GwUbL28K2VS32Wxz+eYPW8Rbbm6N3FpfbVddsY24rXDbk+0p20//6PtjzQ6THeU7Pu2U7OzYlbDrRI1PTc1u093LatFaRW3Xnol7Lv0U9lNjnUvd1r3MveX7wD7Fvuc/Z/x8fX/0/tYDvgfqfrH9ZcNBxsGyeqR+Rn1Pg6ihozGtsf3QmEOtTQFNB391/XVns2Vz1WHDw8uOUI4sPDJwtPhob4u0pftY9rFHrVNa7xwff/zqiXEn2k5GnzxzKuLU8dPs00fPBJ5pPut/9tA533MN573P11/wunDwN6/fDrZ5t9Vf9LnYeMnvUlP76PYjl4MvH7sSduXUVe7V89dir7VfT75+88bEGx03BTef3cq79ep24e3+O/PuEu6W3dO9V3Hf9H71746/7+3w7jj8IOzBhYeJD+884j968Vj++GPnwie0JxVPLZ7WPHN/1twV0XXp+YTnnS+kL/q7S//Q+2PDS4eXv/wZ8ueFnvE9na9krwZeL3lj/GbnX55/tfbG995/m/+2/11Zn3Hfrve+709/SP3wtH/6R9LHyk+On5o+R3++O5A/MCDlyXiqTwEMNjQrC4DXOwGgpQHAgPs2ygT1XlAliHr/qiLwn1i9X1SJNwB18KT8jOe0ALAPNnvItHkAKD/hk0IA6uEx1DQiz/JwV/uiwp0QoW9g4I0ZAKQmAD7JBgb6Nw4MfNoOk70FQMs09R5UKUS4Z9jiqaTLzKJ54BtR70+/muO3Z6DMQDX8b+d/AU/6jzXPsPu0AAAAbGVYSWZNTQAqAAAACAAEARoABQAAAAEAAAA+ARsABQAAAAEAAABGASgAAwAAAAEAAgAAh2kABAAAAAEAAABOAAAAAAAAAJAAAAABAAAAkAAAAAEAAqACAAQAAAABAAAA/KADAAQAAAABAAAAfAAAAABezPYPAAAACXBIWXMAABYlAAAWJQFJUiTwAAAH8UlEQVR4Ae2d0U3cQBRFTYT4hQ7gi19IBUkqIFQQ6AAaIKQCoAPSQVJBkg6ggkAH8IOEhJRwEZOMVsZrrz3GM/eMZO2ud3bsd967+7zjmdmlP4+lokAAAhYE3lhYiZEQgMATAQRPIEDAiACCN3I2pkIAwRMDEDAigOCNnI2pEEDwxAAEjAggeCNnYyoEEDwxAAEjAgjeyNmYCgEETwxAwIgAgjdyNqZCAMETAxAwIoDgjZyNqRBA8MQABIwIIHgjZ2MqBBA8MQABIwII3sjZmAoBBE8MQMCIAII3cjamQgDBEwMQMCKA4I2cjakQQPDEAASMCCB4I2djKgQQPDEAASMCCN7I2ZgKAQSfMAaurq6qr1+/Vvv7+9Xbt2+rpaWl6vz8POERaRoCzQSW+KupZkBd3r24uKguLy+rnz9/Pm0S/GzZ2Niofv/+Pbub1xAYhQCC74FZAv/169c/gd/c3LRqjb/za4WJSgkILCdos9gmY3FL7G0FXiwQDMuOAIJvcFkscF2mUyCQOwEE/+xBZetY4MrgFAiURsBW8OpQk8AlbGVvBF5aaGNPHQEbwQeBS9za6nrQ6wCxDwIlESha8LoH/u3btyeB08FWUthiy6IEihW8BrhowAsFAhD4T6DYkXZra2v/reQZBCDwRKDogTca1XZ9fT05VzPwZnIusTmhYjO8PHh8fGzjSAyFQBsCRWd4AZhilifDtwlN6qQgUHSGF7C9vb0U3BZuc3V1deHP8kEI9CVQvOAPDg6qKYlsal9AfQOIz+dFoHjBq7deon/N8u7du+rz58/Vjx8/qtPT06Snojn3L20acDR02dzcfPF4R0dHgxxOfTEv2TTE/rq+Ho3haGp7EMNeoZFi78PHLCV4Ce329jbeneS5ribev39fbW9vPz3qOQUCUyFgIfiQ5b98+TI49yBwCVubhE6BwFQJWAhe8IfK8uvr60/CDgLXXQAKBHIhYCP4RbP81tbWv8wtkSPwXEKb86wjYCN4Gf/x48dq3mV9EHjI4EMM0Q1z7TUF99OnT3xp1EUi+0YhYCX4OqLqQQ/i1uMQJZ6KK5HHc+01qYdFLIeg/L8N3QHpU4bye59zGOuzNoKX6OLZc8q06rkfIoOr7Xgxjaa59k3vjeX00o5Td1utNBuHsqdYwQcR6t6ztng+vMTeZ334WNyzbQ/lGNqBQAoCRQheYo7Xg5cIm0rXjBCvdTev7abj8h4EXptA1oKX0HWZrlVtupSmnvbQwSZha4t/f3c5BnUhMEUCWQte99a7ir3OCRK2hlJK3Ai8jhD7SiGQteAl0r5FXxi7u7t9m+HzEMiCQNaCH4Jw6sksQ5wjbTQT+PDhQ3OFhndPTk6shkPbC15j39UpR8mXgH6SLVriuzeLtpHT597kdLIpzvW1p86msIk2IfASAXvBq8de9+UpEHAgYC94ObnrfXmHwMDGMgkg+Ee/Ksvv7OyU6WGsgkBEwL7TLrDQb/nv37+Hl8kep7S+XjIjR264z+SZpkFYI5sxyuEQ/DNmzZjSzLnUPfaaoksZlgA/ydrztLukb8qwqQMnzNBr7x5qQmBYAnYZvmnu89BZPsViGsO6n9bcCFgJXuvRzRtZpyy/6MiteDENDegZYq69W0Bib1oCWQteGVTTYptKLMKm7B7aUB1d9s9b0lp14qWo27QdjuH+eHd39yKC5eXlamVl5cX3eaMfgawFr0UsJLQgTmXwWIR6vkjRHxDMFglcxwrbom3Ptjvm68PDw15XHUONOxfLh4eHWtPv7+9r97NzGAJZC16i01hojaXW7RVtfYu+ROLx1bo/r8v8HAU+y6Lv1N+Yy2zbvM6DQNaCD4iVdfuUsGSVpsrqyyMU/WQYYr59aI9HCLw2gSIE3wWislTb5bC4Z96FLHVzIFC84MOS0bqcVfbuclkbZ/scnMk5QmAegeIEL0GHRSf1vM+y0GpHnx+ib2CeI3gfAmMQyF7wQdzKxikysjrs+ixpPYYTOQYE2hJY+vNY2laeWj1NeDk7O0t+WvqnGLJ8cswcYAQCWQu+7n55CmZ9/7gixTnRJgQWIYDgW1Ijy7cERbVJE3gz6bOb0MnptzwFArkTIMN38CBZvgMsqk6SABm+g1vmzbTr0BRVIfAqBMjwHbBruquyPNNeO0Cj6qQIkOE7uEPDcsnyHYBRdXIEEHxHl6QY3NPxFKgOgYUJIPgO6DR7jgzfARhVJ0cg+6G1KYnGq+VoPjy/3VPSpu0xCCD4Z8olrGgzRsBwjLwJ2Apel+fK2mHJKsbK5x3InH07AjaCD5fnQeRcnrcLEGqVRSBrwesyPCxgGbslvjwPAo/f5zkEXAlkPfBGPeZaiZXLc9fwxe6uBLIWfFdjqQ8BdwLch3ePAOy3IoDgrdyNse4EELx7BGC/FQEEb+VujHUngODdIwD7rQggeCt3Y6w7AQTvHgHYb0UAwVu5G2PdCSB49wjAfisCCN7K3RjrTgDBu0cA9lsRQPBW7sZYdwII3j0CsN+KAIK3cjfGuhNA8O4RgP1WBBC8lbsx1p0AgnePAOy3IoDgrdyNse4EELx7BGC/FQEEb+VujHUngODdIwD7rQggeCt3Y6w7AQTvHgHYb0UAwVu5G2PdCSB49wjAfisCCN7K3RjrTgDBu0cA9lsRQPBW7sZYdwII3j0CsN+KAIK3cjfGuhNA8O4RgP1WBBC8lbsx1p0AgnePAOy3IvAXd0VRjJTy4H0AAAAASUVORK5CYII="}))))},name:"LIFI"},{id:"nabox",logoURI:function(e){return S.createElement("svg",uy({width:24,height:25,viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),ly||(ly=S.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M1.5 7.23999V18.418L4.73651 20.2838V12.2876L7.96146 14.1503V22.1412L11.199 24.007V12.8279L1.5 7.23999Z",fill:"#2AC98B"})),cy||(cy=S.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8.85179 6.21724L12.0946 4.31675L16.1237 6.67449L12.883 8.56657L8.85179 6.21724ZM12.0988 0.5L2.32306 6.21934L12.8651 12.4001V24.5L16.0627 22.6374V10.3966L19.294 8.50455V20.7348L22.5389 18.8248V6.60827L12.0988 0.5Z",fill:"#2AC98B"})))},name:"Nabox"},{id:"bungee",logoURI:function(e){return S.createElement("svg",ey({width:24,height:25,viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),Kg||(Kg=S.createElement("g",{clipPath:"url(#clip0_1106_26400)"},S.createElement("path",{d:"M24 4.5C24 2.29086 22.2091 0.5 20 0.5H4C1.79086 0.5 0 2.29086 0 4.5V20.5C0 22.7091 1.79086 24.5 4 24.5H20C22.2091 24.5 24 22.7091 24 20.5V4.5Z",fill:"#FEA700"}),S.createElement("path",{d:"M3.26157 14.6479C4.44801 14.6479 5.40958 13.6862 5.40958 12.4999C5.40958 11.3137 4.44779 10.3519 3.26157 10.3519C2.07824 10.3519 1.1189 11.3088 1.11401 12.491V12.509C1.1189 13.691 2.07824 14.6479 3.26157 14.6479Z",fill:"#ED1E7F"}),S.createElement("path",{d:"M20.7367 14.6477C21.923 14.6477 22.8847 13.686 22.8847 12.4997C22.8847 11.3134 21.923 10.3517 20.7367 10.3517C19.5504 10.3517 18.5887 11.3134 18.5887 12.4997C18.5887 13.686 19.5504 14.6477 20.7367 14.6477Z",fill:"#4CB85D"}),S.createElement("path",{d:"M9.59911 15.9941C10.2391 15.9941 10.8329 15.7967 11.3251 15.4612V15.9438H12.672V12.9378C12.672 12.9314 12.6726 12.9252 12.6726 12.9187V12.0794C12.6726 11.1272 13.4471 10.3527 14.3993 10.3527C15.3535 10.3527 16.126 11.1272 16.126 12.0794V15.9438H17.4747V12.0794C17.4747 10.3825 16.0982 9.00586 14.3993 9.00586C13.7591 9.00586 13.1646 9.20338 12.6722 9.53919V9.05539H11.3253V12.9307C11.3189 13.8792 10.5475 14.6454 9.5993 14.6454C8.6453 14.6454 7.87264 13.873 7.87264 12.9187V9.05607H6.52399V12.9187C6.52375 14.6176 7.90019 15.9941 9.59911 15.9941Z",fill:"black"}))),$g||($g=S.createElement("defs",null,S.createElement("clipPath",{id:"clip0_1106_26400"},S.createElement("rect",{width:24,height:24,fill:"white",transform:"translate(0 0.5)"})))))},name:"Bungee"},{id:"squid",logoURI:function(e){return S.createElement("svg",Ny({width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),Sy||(Sy=S.createElement("g",{clipPath:"url(#clip0_6759_209574)"},S.createElement("path",{d:"M23.7182 11.278C23.2776 12.8519 22.2417 14.5477 20.9174 15.1962C16.7933 17.2151 14.6496 12.8533 14.9088 9.67381C15.0643 7.76437 15.6835 6.24613 15.2064 4.69333C15.0542 4.19797 14.7307 3.73957 14.2008 3.49141C12.7469 2.81029 11.3241 3.74677 10.6627 4.73893C9.94895 5.80885 9.61391 7.14757 9.70463 8.37109C9.79151 9.54997 10.1995 10.3228 10.8149 11.3783C11.6371 12.7885 12.5126 13.7044 12.8477 14.7872C13.0637 15.4852 13.1865 16.6117 12.1944 16.7063C11.1465 16.8066 11.1993 15.4328 11.1845 14.7436C11.1398 12.6488 9.80927 11.8943 8.80751 9.48133C8.22239 8.07205 7.99439 6.58165 8.33663 5.11045C8.81807 3.04021 9.99119 1.37125 12.1061 0.793809C13.7971 0.332049 15.7555 0.710769 16.8259 2.19157C18.0984 3.95221 17.8502 6.02917 17.3328 7.87477C16.3752 11.289 17.2305 12.9167 18.0288 13.3424C19.5403 14.1484 21.1262 13.2354 21.8299 12.2677C22.5921 11.2194 23.0467 9.30709 22.9747 8.08309C22.9473 7.61557 22.9061 7.21333 22.8432 6.85237",fill:"white"}),S.createElement("path",{d:"M0 12.0001C0 12.8756 0.09456 13.7291 0.27264 14.5513C0.2544 13.9316 0.31536 13.3182 0.47568 12.746C0.91632 11.1721 1.95216 9.47627 3.27648 8.82779C7.40064 6.80891 9.54432 11.1707 9.28512 14.3502C9.1296 16.2596 8.5104 17.7779 8.98752 19.3307C9.13968 19.826 9.4632 20.2844 9.99312 20.5326C11.447 21.2137 12.8698 20.2772 13.5312 19.2851C14.245 18.2151 14.58 16.8764 14.4893 15.6529C14.4024 14.474 13.9944 13.7012 13.3795 12.6457C12.5573 11.2355 11.6818 10.3196 11.3467 9.23675C11.1307 8.53883 11.0078 7.41227 12 7.31771C13.0478 7.21739 12.995 8.59115 13.0099 9.28043C13.0546 11.3751 14.3851 12.1297 15.3869 14.5427C15.972 15.9519 16.2 17.4423 15.8578 18.9135C15.3763 20.9838 14.2032 22.6527 12.0883 23.2302C10.3973 23.6919 8.43888 23.3132 7.36848 21.8324C6.096 20.0718 6.34416 17.9948 6.8616 16.1492C7.8192 12.735 6.96384 11.1073 6.1656 10.6815C4.65408 9.87611 3.06816 10.7886 2.36448 11.7563C1.60224 12.8046 1.14768 14.7169 1.21968 15.9409C1.26432 16.7003 1.34592 17.2878 1.49664 17.8062",fill:"white"}),S.createElement("path",{d:"M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z",fill:"#E6FA36"}),S.createElement("path",{d:"M15.8578 18.914C16.2 17.4428 15.972 15.9524 15.3869 14.5432C14.3851 12.1302 13.0541 11.3752 13.0099 9.28092C12.9955 8.59164 13.0479 7.21788 12 7.3182C11.0079 7.41324 11.1307 8.5398 11.3467 9.23772C11.6818 10.3206 12.5578 11.2364 13.3795 12.6467C13.9949 13.7022 14.4024 14.475 14.4893 15.6539C14.5795 16.8774 14.245 18.2161 13.5312 19.286C12.8693 20.2782 11.4471 21.2147 9.99313 20.5336C9.46321 20.2854 9.13969 19.8265 8.98753 19.3316C8.51089 17.7784 9.12961 16.2606 9.28513 14.3512C9.54433 11.1716 7.40017 6.80988 3.27649 8.82876C1.95217 9.47724 0.916332 11.1726 0.475692 12.747C0.315372 13.3196 0.254412 13.9326 0.272652 14.5523C0.523212 15.7081 0.939852 16.802 1.49665 17.8076C1.34593 17.2888 1.26433 16.7017 1.21969 15.9424C1.14769 14.7188 1.60273 12.806 2.36449 11.7577C3.06769 10.79 4.65409 9.87708 6.16561 10.683C6.96385 11.1088 7.81921 12.7364 6.86161 16.1507C6.34369 17.9968 6.09553 20.0732 7.36849 21.8339C8.43889 23.3147 10.3973 23.6934 12.0883 23.2316C14.2032 22.6532 15.3768 20.9843 15.8578 18.914Z",fill:"black"}),S.createElement("path",{d:"M23.7182 11.2782C23.8008 10.984 23.8565 10.6787 23.8891 10.3676C23.8891 10.3691 23.8896 10.37 23.8896 10.371C23.7206 9.12732 23.3616 7.94412 22.8422 6.85164C22.9051 7.21308 22.9464 7.61484 22.9737 8.08236C23.0457 9.30588 22.5907 11.2187 21.8289 12.267C21.1257 13.2347 19.5393 14.1476 18.0278 13.3417C17.2296 12.916 16.3742 11.2883 17.3318 7.87404C17.8497 6.02796 18.0979 3.95148 16.8249 2.19084C15.7545 0.710036 13.7961 0.331317 12.1051 0.793076C9.99021 1.37052 8.81661 3.03948 8.33565 5.10972C7.99341 6.58092 8.22141 8.07132 8.80653 9.4806C9.80829 11.8936 11.1393 12.6486 11.1835 14.7428C11.1979 15.4321 11.1456 16.8059 12.1934 16.7056C13.1856 16.6105 13.0627 15.484 12.8467 14.7865C12.5117 13.7036 11.6356 12.7878 10.8139 11.3776C10.1985 10.322 9.79101 9.54924 9.70365 8.37036C9.61341 7.14684 9.94797 5.80812 10.6617 4.7382C11.3236 3.74604 12.7459 2.80956 14.1998 3.49068C14.7297 3.73884 15.0532 4.19772 15.2054 4.6926C15.682 6.24588 15.0633 7.76364 14.9078 9.67308C14.6486 12.8526 16.7928 17.2144 20.9165 15.1955C22.2413 14.548 23.2776 12.8521 23.7182 11.2782Z",fill:"black"}))),Ty||(Ty=S.createElement("defs",null,S.createElement("clipPath",{id:"clip0_6759_209574"},S.createElement("rect",{width:24,height:24,fill:"white"})))))},name:"Squid"},{id:"across",logoURI:function(e){return S.createElement("svg",Qg({width:32,height:32,viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),Jg||(Jg=S.createElement("rect",{width:32,height:32,rx:16,fill:"#6CF9D8"})),qg||(qg=S.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M6.95021 8.41988L8.50949 6.8606L14.7408 13.0919C14.3626 13.253 14.0083 13.4879 13.6998 13.7964C13.4609 14.0353 13.2662 14.3017 13.1157 14.5853L6.95021 8.41988ZM12.9982 17.4399L6.85803 23.5801L8.41732 25.1394L14.495 19.0617C14.209 18.9107 13.9405 18.7149 13.6998 18.4742C13.3932 18.1675 13.1593 17.8156 12.9982 17.4399ZM17.5887 19.0584L23.5826 25.0522L25.1418 23.493L19.0822 17.4333C18.921 17.8114 18.6862 18.1657 18.3777 18.4742C18.1388 18.7131 17.8724 18.9079 17.5887 19.0584ZM18.9652 14.5916L25.0497 8.50706L23.4904 6.94778L17.3434 13.0947C17.7191 13.2558 18.071 13.4897 18.3777 13.7964C18.6184 14.037 18.8142 14.3055 18.9652 14.5916Z",fill:"#2D2E33"})))},name:"Across"}];function Vy({routeTagList:t}){const r=Cr(),n={typography:"h6",borderRadius:4,px:8,py:4,ml:8};return ne.exports.jsx(ne.exports.Fragment,{children:t.map((t=>"no-approve"===t.type?ne.exports.jsxs(Tr,{sx:Object.assign(Object.assign({},n),{color:r.palette.text.primary,backgroundColor:r.palette.background.paperContrast,display:"flex",alignItems:"center"}),children:[ne.exports.jsx(i.Lock,{style:{color:r.palette.text.primary,width:14,height:14}}),ne.exports.jsx("span",{style:{marginLeft:4},children:ne.exports.jsx(e.Trans,{id:"Unapproved"})})]},t.type):"best-price"===t.type?ne.exports.jsx(Tr,{sx:Object.assign(Object.assign({},n),{color:r.palette.success.main,backgroundColor:Vr(r.palette.success.main,.1)}),children:ne.exports.jsx(e.Trans,{id:"Best offer"})},t.type):null))})}function Zy(e,t){let r=v.i18n._("s");return t||(r=e>=2?v.i18n._("Seconds"):v.i18n._("Second")),r}function Hy(e,t){let r="";return r=e>=2?t?v.i18n._("Mins"):v.i18n._("Minutes"):t?v.i18n._("Min"):v.i18n._("Minute"),r}function zy(e){return e>=2?v.i18n._("Hours"):v.i18n._("Hour")}function Yy({start:e,end:t,showSecondUnit:r}){if(!e||!t)return null;const n=t-e,o=1e3,i=6e4,s=36e5,a=24*s;let l="",c="";if(n<i){const e=n/o;l=`${ms(e)} ${Zy(e,r)}`}else if(n<s){const e=n/i;l=`${ms(e)} ${Hy(e,r)}`;const t=n%i/o;c=`${ms(t)} ${Zy(t,r)}`}else if(n<a){const e=n/s;l=`${ms(e)} ${zy(e)}`;const t=n%s/i;c=`${ms(t)} ${Hy(t)}`}else{const e=n/a;l=`${ms(e)} ${function(e){return e>=2?v.i18n._("Days"):v.i18n._("Day")}(e)}`;const t=n%a/s;c=`${ms(t)} ${zy(t)}`}return r?`${l}${c}`.replaceAll(" ","").toLowerCase():l}function Gy({chainId:t,token:r,amount:o}){var i;const s=Cr(),a=n.useMemo((()=>Im[t]),[t]);return ne.exports.jsxs(Tr,{sx:{display:"flex",flexDirection:"column"},children:[ne.exports.jsxs(Tr,{sx:{mb:8,display:"flex",alignItems:"flex-end",alignSelf:"center"},children:[ne.exports.jsx(jm,{address:null!==(i=null==r?void 0:r.address)&&void 0!==i?i:"",marginRight:0,width:28,height:28,url:null==r?void 0:r.logoURI}),a?ne.exports.jsx(Tr,{component:a.logo,sx:{width:12,height:12,position:"relative",left:-6}}):""]}),ne.exports.jsxs(Tr,{sx:{color:s.palette.text.primary,typography:"body1",fontWeight:600,width:"100%",wordBreak:"break-word",textAlign:"center"},children:[us({input:o,decimals:null==r?void 0:r.decimals})," ",null==r?void 0:r.symbol]}),ne.exports.jsxs(Tr,{sx:{color:s.palette.text.secondary,typography:"h6",alignSelf:"center"},children:[ne.exports.jsx(e.Trans,{id:"on"})," ",a.name]})]})}function Xy({children:e}){const t=Cr();return ne.exports.jsxs(Tr,{sx:{position:"relative",width:"calc(100% - 16px)",mx:"auto"},children:[ne.exports.jsx(Tr,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"100%",borderTopColor:t.palette.text.primary,borderTopWidth:1,borderTopStyle:"dashed","&:before":{content:'""',position:"absolute",left:0,top:-.5,backgroundColor:t.palette.text.primary,width:6,height:6,borderRadius:"50%",transform:"translate(-50%, -50%)"},"&:after":{display:{tablet:"block"},content:'""',position:"absolute",right:-1,top:-.5,width:0,height:0,transform:"translate(0, -50%)",borderTop:"4px solid transparent",borderBottom:"4px solid transparent",borderLeft:`6px solid ${t.palette.text.primary}`}}}),ne.exports.jsx(Tr,{sx:{position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)"},children:e})]})}function Jy({size:e="medium",toolDetails:t,nameMarginLeft:r=4,logoMarginLeft:n=0,nameSx:o}){const i=Cr();if(!t||!t.logoURI||!t.name)return null;const{logoURI:s,name:a}=t;return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Tr,{component:"img",src:s,alt:a,sx:{marginLeft:n,width:"large"===e?24:16,height:"large"===e?24:16}}),ne.exports.jsx(Tr,{sx:Object.assign({color:i.palette.text.primary,fontWeight:600,marginLeft:r,typography:{mobile:"small"===e?"h6":"medium"===e?"body2":"caption",tablet:"small"===e||"medium"===e?"body2":"caption"}},o),children:a})]})}function qy({fromToken:t,toToken:r,fromChainId:o,toChainId:s,fromAmount:a,fromTokenBalance:l,toTokenAmount:c,toolDetails:d,product:p,executionDuration:f,feeUSD:h,selected:m,setSelected:g,spenderContractAddress:y,isBestPrice:b}){const v=Cr(),{account:x}=u.useWeb3React(),w=Uy.find((e=>e.id===p)),{getApprovalState:E}=Gg({account:x,chainId:o,contractAddress:y}),A=n.useMemo((()=>t&&a&&l?E(t,a,l):zg.Loading),[t,a,l,E]),k=n.useMemo((()=>{const e=[];return b&&e.push({type:"best-price"}),A===zg.Approving||A===zg.Insufficient?[...e,{type:"no-approve"}]:e}),[A,b]);return ne.exports.jsxs(Tr,{sx:Object.assign({borderRadius:16,py:16,px:12,backgroundColor:v.palette.background.tag,cursor:"pointer","&:hover":{backgroundColor:"hover.default"},outline:0},m?{borderWidth:1,borderStyle:"solid",borderColor:v.palette.primary.main}:{}),onClick:g,children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:[ne.exports.jsx(Tr,{component:null==w?void 0:w.logoURI,sx:{width:16,height:16}}),ne.exports.jsx(Tr,{sx:{marginLeft:4},children:null==w?void 0:w.name}),ne.exports.jsx(Vy,{routeTagList:k})]}),ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",mt:8,pb:8,borderStyle:"dashed",borderWidth:v.spacing(0,0,1,0),borderColor:v.palette.border.main},children:[ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Estimated transaction time"}),children:ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${v.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.Time,{style:{color:v.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Tr,{sx:{ml:4,lineHeight:1},children:null!==f?Yy({start:Date.now(),end:Date.now()+1e3*f}):"-"})]})}),ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Fee includes: Bridge fees + Swap fees. Gas fee not included."}),children:ne.exports.jsxs(Tr,{sx:{ml:8,display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${v.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.GasFee,{style:{color:v.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Tr,{sx:{ml:4,lineHeight:1},children:null!==h?`$${us({input:h,decimals:6})}`:"-"})]})})]}),ne.exports.jsxs(Tr,{sx:{display:"grid",gridTemplateColumns:"36% 28% 36%",mt:8},children:[ne.exports.jsx(Gy,{token:t,chainId:o,amount:a}),ne.exports.jsx(Xy,{children:ne.exports.jsx(Tr,{sx:{display:"flex",px:3,py:3,backgroundColor:v.palette.background.paperContrast,border:`1px solid ${v.palette.border.main}`,borderRadius:"50%",alignItems:"center",width:24,height:24,overflow:"hidden"},children:ne.exports.jsx(Jy,{size:"medium",toolDetails:d,nameMarginLeft:8})})}),ne.exports.jsx(Gy,{token:r,chainId:s,amount:c})]})]})}function Qy({open:t,onClose:r,selectedRouteId:o,setSelectRouteId:i,bridgeRouteList:s}){const a=Cr(),l=Lf(),c=n.useMemo((()=>{if(!(null==s?void 0:s.length))return null;const{fromToken:e}=s[0];return l(e)}),[s,l]);return ne.exports.jsx(Bm,{open:t,onClose:r,title:ne.exports.jsx(e.Trans,{id:"Select Bridge"}),children:ne.exports.jsx(Tr,{sx:{position:"relative",display:"flex",flexDirection:"column",gap:12,py:20,px:16,flex:1,overflowY:"auto",overflowX:"hidden","&::before":{content:'""',position:"absolute",top:0,width:1,height:"1px",backgroundColor:a.palette.border.main}},children:null==s?void 0:s.map(((e,t)=>ne.exports.jsx(qy,{fromChainId:e.fromChainId,toChainId:e.toChainId,fromToken:e.fromToken,toToken:e.toToken,fromAmount:e.fromAmount,fromTokenBalance:c,toTokenAmount:e.toTokenAmount,toolDetails:e.step.toolDetails,spenderContractAddress:e.spenderContractAddress,selected:o===e.id,setSelected:()=>{i(e.id),r()},isBestPrice:0===t,product:e.product,executionDuration:e.executionDuration,feeUSD:e.feeUSD},e.key)))})})}function Ky({route:t,onClick:r}){var n,o;const s=Cr();if(!t)return null;const{product:a,executionDuration:l,feeUSD:c,fromAmount:u,fromToken:d,fromChainId:p,toTokenAmount:f,toToken:h,toChainId:m}=t,g=Uy.find((e=>e.id===a)),y=Im[p],b=Im[m];return ne.exports.jsxs(Tr,{sx:{px:16,py:8,width:"100%",backgroundColor:"background.tag",borderRadius:12,cursor:"pointer","&:hover":{backgroundColor:"hover.default"}},onClick:r,children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",flexWrap:"wrap"},children:[ne.exports.jsx(Tr,{component:null==g?void 0:g.logoURI,sx:{width:16,height:16}}),ne.exports.jsx(Tr,{sx:{marginLeft:4,typography:"body2",fontWeight:600},children:null==g?void 0:g.name}),ne.exports.jsx(Tr,{sx:{display:"block",mx:8,width:"1px",height:12,backgroundColor:s.palette.border.main}}),ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",typography:"body2",fontWeight:600},children:[us({input:u,decimals:null==d?void 0:d.decimals}),ne.exports.jsxs(Tr,{sx:{ml:4,display:"flex",alignItems:"flex-end",alignSelf:"center",width:18,height:18},children:[ne.exports.jsx(jm,{address:null!==(n=null==d?void 0:d.address)&&void 0!==n?n:"",marginRight:0,width:18,height:18,url:null==d?void 0:d.logoURI}),y?ne.exports.jsx(Tr,{component:y.logo,sx:{position:"relative",left:-6,width:10,height:10,flexShrink:0}}):""]})]})," = ",ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",typography:"body2",fontWeight:600},children:[us({input:f,decimals:null==h?void 0:h.decimals}),ne.exports.jsxs(Tr,{sx:{ml:4,display:"flex",alignItems:"flex-end",alignSelf:"center",width:18,height:18},children:[ne.exports.jsx(jm,{address:null!==(o=null==h?void 0:h.address)&&void 0!==o?o:"",marginRight:0,width:18,height:18,url:null==h?void 0:h.logoURI}),b?ne.exports.jsx(Tr,{component:b.logo,sx:{width:10,height:10,position:"relative",left:-6,flexShrink:0}}):""]})]})]}),ne.exports.jsx(Tr,{component:i.ArrowRight,sx:{width:18,height:18}})]}),ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",mt:8},children:[ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Estimated transaction time"}),children:ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${s.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.Time,{style:{color:s.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Tr,{sx:{ml:4,lineHeight:1},children:null!==l?Yy({start:Date.now(),end:Date.now()+1e3*l}):"-"})]})}),ne.exports.jsx(ui,{onlyHover:!0,placement:"top",title:ne.exports.jsx(e.Trans,{id:"Fee includes: Bridge fees + Swap fees. Gas fee not included."}),children:ne.exports.jsxs(Tr,{sx:{ml:8,display:"flex",alignItems:"center",px:8,py:4,border:`solid 1px ${s.palette.border.main}`,borderRadius:4,typography:"h6"},children:[ne.exports.jsx(i.GasFee,{style:{color:s.palette.text.secondary,width:14,height:14}}),ne.exports.jsx(Tr,{sx:{ml:4,lineHeight:1},children:null!==c?`$${us({input:c,decimals:6})}`:"-"})]})})]})]})}function $y(){const{provider:e}=u.useWeb3React(),[r,o]=n.useState(),[i,s]=n.useState(!1),[a,c]=n.useState(""),{apikey:d}=l.useSelector(Uf),p=n.useCallback((({selectedRoute:r,fromEtherTokenBalance:n,goNext:i})=>ma(this,void 0,void 0,(function*(){var a,l;if(!r||!e||!n)return;const{encodeParams:u}=r;if(u){c(""),s(!0);try{const{fromToken:h,fromAmount:m,product:g}=r,y={product:g,encodeParams:u},b=(yield I.default.post(`${wg}${d?`?apikey=${d}`:""}`,{data:y})).data.data,{data:x,to:w,value:E,from:A,chainId:k}=b;if(!(x&&w&&E&&A&&k))throw new Error("cross_chain_swap_transactionEncode is null");const C=la[k],R=(p=E,f=18,new t.BigNumber(p).div(new t.BigNumber(10).pow(f))),S=C&&h.address.toLowerCase()===C.address.toLowerCase(),T=R.minus(S?m:0);if(!R.isNaN()&&R.gt(0)&&n.lt(R))return c(v.i18n._("Insufficient cross-chain fees, need at least {0} {1}",{0:us({input:T,decimals:null!==(a=null==C?void 0:C.decimals)&&void 0!==a?a:18}),1:null!==(l=null==C?void 0:C.symbol)&&void 0!==l?l:"-"})),void s(!1);if(!(yield Qm({from:A,to:w,value:E,data:x},e)))throw new Error("failed to estimate gas");o({data:x,to:w,value:E,from:A,chainId:k}),i()}catch(e){console.error("[failed to construct transaction request]: ",e);const{message:t}=e;c(t)}var p,f;s(!1)}}))),[o,s,e]);return{apikey:d,sendRouteLoading:i,sendRouteError:a,setSendRouteError:c,bridgeOrderTxRequest:r,handleClickSend:p}}function eb({route:e,bridgeOrderTxRequest:t}){const{chainId:r,account:o}=u.useWeb3React(),s=ag(),{apikey:a}=l.useSelector(Uf);return n.useCallback((()=>{if(t&&e)try{const{fromToken:r,toToken:n,fromAmount:o,toTokenAmount:l,fromChainId:c,toChainId:u,toAddress:d,slippage:p,roundedRouteCostTime:f}=e,h=us({input:o,decimals:r.decimals}),m=us({input:l,decimals:n.decimals}),g=ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(jm,{token:r,sx:{width:16,height:16,mr:6},chainId:r.chainId}),`${h} ${null==r?void 0:r.symbol}`,ne.exports.jsx(Tr,{component:i.DoubleRight,sx:{width:12,height:12,mx:16}}),ne.exports.jsx(jm,{token:n,sx:{width:16,height:16,mr:6}}),`${m} ${null==n?void 0:n.symbol}`]}),y=(t,r)=>ma(this,void 0,void 0,(function*(){const n=yield function({apikey:e,tx:t,route:r}){return ma(this,void 0,void 0,(function*(){const{fromChainId:n,toChainId:o,fromAmount:i,fromToken:s,toToken:a,fromAddress:l,toAddress:c,slippage:u,product:d,step:p,sourceRoute:f,productParams:h}=r,{toAmount:m}=f,g={fromChainId:n,fromAmount:hs(i,s.decimals).toString(),fromTokenAddress:s.address,toChainId:o,toAmount:m,toTokenAddress:a.address,fromAddress:l,toAddress:c,slippage:u,hash:t,product:d,extend:{lifiBridge:p.tool,route:f,productParams:h}},y=(yield I.default.post(`${Eg}${e?`?apikey=${e}`:""}`,{data:g})).data.data;return null==y?void 0:y.id}))}({apikey:a,tx:t,route:e});r&&r(t,{orderId:n})})),b={fromChainId:c,toChainId:u,fromTokenAddress:r.address,toTokenAddress:n.address,fromTokenSymbol:r.symbol,toTokenSymbol:n.symbol,fromTokenAmount:o,toTokenAmount:l.toString(),slippage:p,sendAccount:d,roundedRouteCostTime:f};return s.execute(v.i18n._("Bridge"),Object.assign({opcode:$m.TX},t),g,!1,void 0,Object.assign(Object.assign(Object.assign({},t),{fromToken:r,toToken:n,pay:h,receive:m}),b),void 0,y)}catch(e){console.error(e)}}),[o,r,e,t,a])}function tb({chainId:e,address:t,children:r}){const n=Cr();return ne.exports.jsxs(Tr,{component:"a",href:pa(`tx/${t}`,e),target:"_blank",rel:"noopener noreferrer",sx:{color:n.palette.text.secondary,"&:hover":{color:n.palette.text.primary},display:"flex",alignItems:"center",typography:"body2"},children:[r,ne.exports.jsx(Tr,{component:"svg",viewBox:"0 0 16 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",sx:{marginLeft:6,width:16,height:17},children:ne.exports.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M3.33333 3.83333V13.1667H12.6667V8.5H14V13.1667C14 13.9 13.4 14.5 12.6667 14.5H3.33333C2.59333 14.5 2 13.9 2 13.1667V3.83333C2 3.1 2.59333 2.5 3.33333 2.5H8V3.83333H3.33333ZM9.33333 3.83333V2.5H14V7.16667H12.6667V4.77333L6.11333 11.3267L5.17333 10.3867L11.7267 3.83333H9.33333Z",fill:"currentColor"})})]})}function rb({fromChainId:t,toChainId:r,fromTokenAmount:o,toTokenAmount:i,fromTokenDecimals:s,fromTokenSymbol:a,toTokenDecimals:l,toTokenSymbol:c,fromHash:u,toHash:d,toolDetails:p}){const f=Cr(),[h,m]=n.useMemo((()=>[Im[t],Im[r]]),[t,r]);return ne.exports.jsxs(Tr,{sx:{borderLeft:`1px dashed ${f.palette.text.primary}`,opacity:d?1:.5,pb:24},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"flex-start",flexWrap:{mobile:"wrap",tablet:"nowrap"}},children:[ne.exports.jsx(Tr,{component:"img",src:p.logoURI,alt:p.name,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:{mobile:f.palette.background.paper,tablet:f.palette.background.paper},alignSelf:"flex-start"}}),ne.exports.jsx(Tr,{sx:{ml:8,typography:"body1"},children:p.name}),ne.exports.jsxs(Tr,{sx:{typography:"body2",marginLeft:"auto",display:"flex",alignItems:"center",justifyContent:"flex-end",width:{mobile:"100%",tablet:"auto"},mt:{mobile:8,tablet:0}},children:[us({input:o,decimals:s})," ",a,ne.exports.jsx("span",{style:{marginLeft:4,color:f.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"On"})}),ne.exports.jsx(Tr,{component:null==h?void 0:h.logo,sx:{marginLeft:4,width:18,height:18}}),ne.exports.jsx("span",{style:{marginLeft:4,marginRight:4,color:f.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"To"})}),us({input:i,decimals:l})," ",c,ne.exports.jsx("span",{style:{marginLeft:4,color:f.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"On"})}),ne.exports.jsx(Tr,{component:null==m?void 0:m.logo,sx:{marginLeft:4,width:18,height:18}})]})]}),ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-end",mt:{mobile:8,tablet:5}},children:[ne.exports.jsx(tb,{chainId:t,address:u,children:ne.exports.jsx(e.Trans,{id:"Source"})}),ne.exports.jsx(Tr,{sx:{width:16}}),ne.exports.jsx(tb,{chainId:r,address:d,children:ne.exports.jsx(e.Trans,{id:"Destination"})})]})]})}function nb({chainId:t,fromTokenAmount:r,toTokenAmount:o,fromTokenDecimals:i,fromTokenSymbol:s,toTokenDecimals:a,toTokenSymbol:l,hash:c,toolDetails:u}){const d=Cr(),p=n.useMemo((()=>Im[t]),[t]);return ne.exports.jsxs(Tr,{sx:{borderLeft:`1px dashed ${d.palette.text.primary}`,opacity:c?1:.5,pb:24},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"flex-start",flexWrap:{mobile:"wrap",tablet:"nowrap"}},children:[ne.exports.jsx(Tr,{component:"img",src:u.logoURI,alt:u.name,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:d.palette.background.paper,alignSelf:"flex-start"}}),ne.exports.jsx(Tr,{sx:{ml:8,typography:"body1"},children:u.name}),ne.exports.jsxs(Tr,{sx:{typography:"body2",marginLeft:"auto",display:"flex",alignItems:"center",justifyContent:"flex-end",width:{mobile:"100%",tablet:"auto"},mt:{mobile:8,tablet:0}},children:[us({input:r,decimals:i})," ",s,ne.exports.jsx("span",{style:{marginLeft:4,marginRight:4,color:d.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"For"})}),us({input:o,decimals:a})," ",l,ne.exports.jsxs(Tr,{sx:{alignItems:"center",display:{mobile:"none",tablet:"flex"}},children:[ne.exports.jsx("span",{style:{marginLeft:4,color:d.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"on"})}),ne.exports.jsx(Tr,{component:null==p?void 0:p.logo,sx:{marginLeft:4,width:18,height:18}}),ne.exports.jsx(Tr,{component:"span",sx:{ml:4},children:p.name})]})]})]}),ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"flex-end",typography:"body2",mt:{mobile:8,tablet:5}},children:[ne.exports.jsxs(Tr,{sx:{alignItems:"center",display:{mobile:"flex",tablet:"none"}},children:[ne.exports.jsx("span",{style:{color:d.palette.text.secondary},children:ne.exports.jsx(e.Trans,{id:"on"})}),ne.exports.jsx(Tr,{component:null==p?void 0:p.logo,sx:{marginLeft:4,width:18,height:18}}),ne.exports.jsx(Tr,{component:"span",sx:{ml:4,mr:8},children:p.name})]}),ne.exports.jsx(tb,{chainId:t,address:c,children:ne.exports.jsx(e.Trans,{id:"Tx"})})]})]})}function ob({marginTop:e=20,route:t}){const r=Cr(),{fromChainId:o,toChainId:i}=t,{step:{includedSteps:s}}=t,[a,l]=n.useMemo((()=>[Im[o],Im[i]]),[o,i]);return ne.exports.jsxs(Tr,{sx:{mt:e,pl:10},children:[ne.exports.jsx(Tr,{sx:{borderLeft:`1px dashed ${r.palette.text.primary}`,opacity:1,pb:24},children:ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"flex-start"},children:[ne.exports.jsx(Tr,{component:null==a?void 0:a.logo,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:r.palette.background.paper}}),ne.exports.jsx(Tr,{sx:{ml:8,typography:"body1"},children:a.name})]})}),s.map(((e,t)=>{const{toolDetails:r,type:n,estimate:o}=e;return"swap"===n?ne.exports.jsx(nb,{chainId:o.fromToken.chainId,fromTokenAmount:o.fromTokenAmount,toTokenAmount:o.toTokenAmount,fromTokenDecimals:o.fromToken.decimals,fromTokenSymbol:o.fromToken.symbol,toTokenDecimals:o.toToken.decimals,toTokenSymbol:o.toToken.symbol,hash:null,toolDetails:r},t):"cross"===n?ne.exports.jsx(rb,{fromChainId:o.fromToken.chainId,toChainId:o.toToken.chainId,fromTokenAmount:o.fromTokenAmount,toTokenAmount:o.toTokenAmount,fromTokenDecimals:o.fromToken.decimals,fromTokenSymbol:o.fromToken.symbol,toTokenDecimals:o.toToken.decimals,toTokenSymbol:o.toToken.symbol,fromHash:null,toHash:null,toolDetails:r},t):null})),ne.exports.jsx(Tr,{sx:{opacity:.5,pb:0},children:ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"flex-start"},children:[ne.exports.jsx(Tr,{component:null==l?void 0:l.logo,sx:{width:20,height:20,marginLeft:-10.5,pt:1,backgroundColor:r.palette.background.paper}}),ne.exports.jsx(Tr,{sx:{ml:8,typography:"body1"},children:l.name})]})})]})}function ib({route:t}){const r=Cr(),o=Im[t.fromChainId],s=n.useMemo((()=>pa(`address/${t.fromAddress}`,t.fromChainId)),[t.fromAddress,t.fromChainId]);return ne.exports.jsxs(Tr,{children:[ne.exports.jsx(Tr,{sx:{py:12,borderStyle:"solid",borderWidth:r.spacing(1,0,0),borderColor:r.palette.border.main},children:ne.exports.jsx(Qi,{children:ne.exports.jsx(ls,{initialEntered:!0,sx:{"& button.active svg":{transform:"rotate(0)"}},header:ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",typography:"body2"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Tr,{component:i.DetailBorder,sx:{mr:6,width:18,height:18}}),ne.exports.jsx(e.Trans,{id:"Detail"})]}),ne.exports.jsx(Tr,{component:i.CaretUp,sx:{width:12,height:12,color:"text.secondary",transform:"rotate(180deg)",transition:"transform 0.2s linear"}})]}),children:ne.exports.jsxs(Tr,{sx:{mt:16},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsx(Tr,{sx:{typography:"body2",color:"text.secondary",flexShrink:0},children:ne.exports.jsx(e.Trans,{id:"Send to:"})}),ne.exports.jsxs(Tr,{sx:{display:"flex",justifyContent:"flex-end",alignItems:"center"},children:[o?ne.exports.jsx(Tr,{component:o.logo,sx:{width:18,height:18}}):"",ne.exports.jsx(Tr,{sx:{display:"inline-block",mx:6,width:"1px",height:12,backgroundColor:"border.main"}}),ne.exports.jsx(Tr,{sx:{typography:"body2",fontWeight:600},children:(a=t.fromAddress,a.length<=10?a:`${a.slice(0,6)}...${a.slice(a.length-4,a.length)}`)}),ne.exports.jsx(jn,{component:"a",href:s,target:"_blank",rel:"noopener noreferrer",sx:{ml:6,width:18,height:18,color:"text.secondary"},children:ne.exports.jsx(Tr,{component:i.ArrowTopRightBorder,sx:{width:18,height:18}})})]})]}),t.feeUSD?ne.exports.jsxs(Tr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsx(Tr,{sx:{display:"flex",alignItems:"center",typography:"body2",color:"text.secondary",flexShrink:0},children:ne.exports.jsx(e.Trans,{id:"Fee"})}),ne.exports.jsxs(Tr,{sx:{typography:"body2"},children:["$",cs({input:t.feeUSD})]})]}):"",ne.exports.jsxs(Tr,{sx:{mt:8,display:"flex",justifyContent:"space-between",alignItems:"center"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",typography:"body2",color:"text.secondary",flexShrink:0},children:[ne.exports.jsx(e.Trans,{id:"Slippage"}),ne.exports.jsx(Pg,{onlyHover:!0,title:ne.exports.jsx(e.Trans,{id:"Attention: High slippage tolerance will increase the success rate of transaction, but might not get the best quote."}),ml:6})]}),ne.exports.jsxs(Tr,{sx:{typography:"body2"},children:[100*t.slippage,"%"]})]})]})})})}),ne.exports.jsx(Tr,{sx:{py:12,borderStyle:"solid",borderWidth:r.spacing(1,0,0),borderColor:r.palette.border.main},children:ne.exports.jsx(Qi,{children:ne.exports.jsx(ls,{initialEntered:!0,sx:{"& button.active svg":{transform:"rotate(0)"}},header:ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center",justifyContent:"space-between",typography:"body2"},children:[ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(Tr,{component:i.DetailBorder,sx:{mr:6,width:18,height:18}}),ne.exports.jsx(e.Trans,{id:"Estimated Time"})]}),ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[t.executionDuration?Yy({start:Date.now(),end:Date.now()+1e3*t.executionDuration}):"-",ne.exports.jsx(Tr,{component:i.CaretUp,sx:{ml:6,width:12,height:12,color:"text.secondary",transform:"rotate(180deg)",transition:"transform 0.2s linear"}})]})]}),children:ne.exports.jsx(ob,{route:t})})})})]});var a}function sb({open:t,onClose:r,route:o,bridgeOrderTxRequest:i,clearToAmt:s,clearFromAmt:a}){const c=Cr(),{contractStatus:u}=l.useSelector(Uf),d=l.useDispatch(),p=eb({route:o,bridgeOrderTxRequest:i});return n.useEffect((()=>{u!==Ef.Pending&&r(),u===Ef.TxSuccess&&(s(),a())}),[u]),ne.exports.jsx(Bm,{title:ne.exports.jsx(e.Trans,{id:"Bridge Summary"}),open:t,onClose:()=>{d(rg({contractStatus:Ef.Initial})),r()},children:ne.exports.jsxs(ne.exports.Fragment,{children:[o?ne.exports.jsxs(Tr,{sx:{px:16,pb:20,flex:1,overflowY:"auto"},children:[ne.exports.jsxs(Tr,{sx:{display:"grid",gridTemplateColumns:"36% 28% 36%",py:20,borderStyle:"solid",borderWidth:c.spacing(1,0,0),borderColor:c.palette.border.main},children:[ne.exports.jsx(Gy,{token:o.fromToken,chainId:o.fromChainId,amount:o.fromAmount}),ne.exports.jsx(Xy,{children:ne.exports.jsx(Tr,{sx:{display:"flex",px:3,py:3,backgroundColor:c.palette.background.paperContrast,border:`1px solid ${c.palette.border.main}`,borderRadius:"50%",alignItems:"center",width:24,height:24,overflow:"hidden"},children:ne.exports.jsx(Jy,{size:"medium",toolDetails:o.step.toolDetails,nameMarginLeft:8})})}),ne.exports.jsx(Gy,{token:o.toToken,chainId:o.toChainId,amount:o.toTokenAmount})]}),ne.exports.jsx(ib,{route:o})]}):"",ne.exports.jsx(Tr,{sx:{px:16,py:20},children:ne.exports.jsx(vn,{fullWidth:!0,isLoading:u==Ef.Pending,disabled:!o,onClick:()=>{p(),d(rg({contractStatus:Ef.Pending}))},children:u==Ef.Pending?ne.exports.jsx(e.Trans,{id:"Confirming"}):ne.exports.jsx(e.Trans,{id:"Confirm Bridge"})})})]})})}function ab({message:t,onClose:r}){return ne.exports.jsx(Bm,{open:!!t,onClose:r,children:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsxs(Tr,{sx:{flex:1,textAlign:"center"},children:[ne.exports.jsx(Tr,{component:i.ErrorWarn,sx:{mt:60,width:64,height:64,color:"error.main"}}),t?ne.exports.jsxs(Tr,{sx:{textAlign:"center",mt:60},children:[ne.exports.jsx(Tr,{children:ne.exports.jsx(e.Trans,{id:"Something went wrong."})}),ne.exports.jsx(Tr,{sx:{color:"text.secondary",mt:12,typography:"body2",wordBreak:"break-all"},children:t})]}):""]}),ne.exports.jsx(Tr,{sx:{px:16,py:20},children:ne.exports.jsx(vn,{onClick:r,fullWidth:!0,children:ne.exports.jsx(e.Trans,{id:"Dismiss"})})})]})})}function lb(e){const t=n.useRef(!1),[r,o]=n.useState(!1),i=l.useDispatch();return n.useEffect((()=>{if(void 0===e)return;const r=function(e){const t=localStorage.getItem(e?"DODO_WIDGET_SLIPPAGE_BRIDGE":"DODO_WIDGET_SLIPPAGE_SWAP");return t?Number(t):null}(e);if(!t.current)return i(mg(r?r.toString():null)),void(t.current=!0);i(mg(r?r.toString():null)),o(!0);const n=setTimeout((()=>{o(!1)}),3e3);return()=>{clearTimeout(n)}}),[e]),r}function cb({side:e,defaultToken:t,tokenList:r,occupyToken:n}){var o,i;let s,a=null;const l=r.filter((t=>!t.side||t.side===e));if(l.length){let r=function(e){const t=localStorage.getItem("from"===e?"DODO_WIDGET_LAST_FROM_TOKEN":"DODO_WIDGET_LAST_TO_TOKEN");if(!t)return null;try{return JSON.parse(t)}catch(e){return console.error(e),null}}(e);!r&&t&&(r=Object.assign({},t),s=t.amount),r&&(a=null!==(o=l.find((e=>e.address===(null==r?void 0:r.address)&&e.chainId===r.chainId)))&&void 0!==o?o:null),a||(n?a=null!==(i=l.find((e=>e.address!==n.address)))&&void 0!==i?i:null:[a]=l)}return{findToken:a,setDefaultAmount:s}}function ub({fromToken:e,toToken:t,setFromToken:r,setToToken:o,updateFromAmt:i,updateToAmt:s}){const a=l.useSelector(Ff),c=l.useSelector(Bf),u=l.useSelector(Wf),d=l.useDispatch();n.useEffect((()=>{(()=>{let n,l=null;if(!e){const e=cb({side:"from",defaultToken:c,tokenList:a});l=e.findToken,n=e.setDefaultAmount,l&&(r(l),void 0!==n&&(d(rg({isReverseRouting:!1})),i(n)))}if(!t){const{findToken:e,setDefaultAmount:t}=cb({side:"to",defaultToken:u,tokenList:a,occupyToken:l});e&&(o(e),void 0===n&&void 0!==t&&(d(rg({isReverseRouting:!0})),s(t)))}})()}),[a,c,u])}function db(){var t,o,s;const a=Cr(),{isInflight:c}=ig(),{chainId:d,account:p}=u.useWeb3React(),f=l.useDispatch(),{isReverseRouting:h}=l.useSelector(Uf),m=l.useSelector(Nf),{isETH:g}=n.useMemo((()=>fa(d)),[d]),b=n.useMemo((()=>{var e;return null===(e=la[null!=d?d:m])||void 0===e?void 0:e.address}),[d]),[v,x]=n.useState(""),[w,E]=n.useState(""),[A,k]=n.useState(""),[R,S]=n.useState(""),T=n.useMemo((()=>r.debounce((e=>k(e)),1e3)),[]),N=n.useMemo((()=>r.debounce((e=>S(e)),1e3)),[]),[M,O]=n.useState(null),[j,F]=n.useState(null),[_,P]=n.useState(!1),[B,W]=n.useState(!1),D=n.useMemo((()=>{if(M&&j)return!(!(null==M?void 0:M.chainId)||!(null==j?void 0:j.chainId)||M.chainId===j.chainId)}),[M,j]),{toFiatPrice:L,fromFiatPrice:U}=kg({chainId:d,toToken:j,fromToken:M}),V=Lf(),Z=n.useMemo((()=>M?V(M):null),[M,V]),H=n.useMemo((()=>{const e=null==M?void 0:M.chainId;if(!D||!e)return null;const t=la[e];return t?V(Object.assign(Object.assign({},t),{chainId:e})):null}),[D,null==M?void 0:M.chainId,V]),{marginAmount:z}=function({token:e,fiatPrice:t}){return{marginAmount:n.useMemo((()=>{var r;const n=null!==(r=null==e?void 0:e.decimals)&&void 0!==r?r:6,o=null!=t?new C.default(500).div(t):new C.default(0),i=hs(o,n);return(i.lt(new C.default(1).times(new C.default(10).pow(n-3)))?new C.default(0):i).toString(10)}),[null==e?void 0:e.decimals,t])}}({token:h?j:M,fiatPrice:h?L:U}),{resAmount:Y,priceImpact:G,executeSwap:X,baseFeeAmount:J,additionalFeeAmount:q,resPricePerToToken:Q,resPricePerFromToken:K,status:$}=Og({toToken:j,fromToken:M,marginAmount:z,fromAmount:A,toAmount:R}),{bridgeRouteList:ee,status:te}=function({toToken:e,fromToken:t,fromAmount:r}){const{account:o,provider:i}=u.useWeb3React(),s=Tg(!0),a=l.useSelector(Cg)||s,{apikey:c}=l.useSelector(Uf),[d,p]=n.useState(Xg.Initial),[f,h]=n.useState([]),m=n.useCallback((()=>ma(this,void 0,void 0,(function*(){var n;const s=null==t?void 0:t.chainId,l=null==e?void 0:e.chainId;if(!(s&&l&&s!==l&&t&&e&&r))return void p(Xg.Initial);p(Xg.Loading);const u=t.address,d=e.address,f=o||Sg,m=o||Sg,g=Number(a)/100,b={fromAddress:f,fromAmount:y.parseFixed(String(r||1),t.decimals).toString(),fromChainId:s,fromTokenAddress:u,toAddress:m,toChainId:l,toTokenAddress:d,options:{slippage:g},products:["lifi","hyphen","nabox","bungee","swft","stargate","connext","squid","across"]};try{const a=Date.now(),u=(yield I.default.post(`${xg}${c?`?apikey=${c}`:""}`,{data:b})).data.data,d=[];if((null===(n=null==u?void 0:u.routes)||void 0===n?void 0:n.length)&&u.routes.forEach(((n,o)=>{if(n){const{toAmount:i,feeUSD:c,executionDuration:u,product:p,step:h,encodeParams:y,productParams:b}=n;if(h&&null!==i){const n=new C.default(i);if(!n.isNaN()&&n.gt(0)){const{tool:v,toolDetails:x,type:w,includedSteps:E,approvalAddress:A}=h;if(E&&E.length>0&&v&&x&&x.name&&x.logoURI&&w&&A){const h=[];if(E.forEach((e=>{e&&e.id&&e.type&&e.tool&&e.toolDetails&&e.toolDetails.name&&e.toolDetails.logoURI&&e.estimate&&e.estimate.fromAmount&&e.estimate.fromToken&&e.estimate.fromToken.decimals&&e.estimate.toAmount&&e.estimate.toToken&&e.estimate.toToken.decimals&&h.push({id:e.id,tool:e.tool,toolDetails:{name:e.toolDetails.name,logoURI:e.toolDetails.logoURI},type:e.type,estimate:{fromToken:e.estimate.fromToken,toToken:e.estimate.toToken,fromTokenAmount:new C.default(e.estimate.fromAmount).div(`1e${e.estimate.fromToken.decimals}`),toTokenAmount:new C.default(e.estimate.toAmount).div(`1e${e.estimate.toToken.decimals}`)}})})),h.length>0){const k={key:`${p}-${i}-${c}-${o}`,id:p,fromChainId:s,toChainId:l,fromToken:t,toToken:e,fromAmount:r,toTokenAmount:n.div(`1e${e.decimals}`),fromAddress:f,toAddress:m,product:p,slippage:g,roundedRouteCostTime:(Date.now()-a)/1e3,spenderContractAddress:null!=A?A:"0x",feeUSD:c,executionDuration:u,step:{tool:v,toolDetails:{name:x.name,logoURI:x.logoURI},type:w,includedSteps:h},encodeParams:y,productParams:b,sourceRoute:{toAmount:i,feeUSD:c,executionDuration:u,step:{tool:v,toolDetails:x,type:w,approvalAddress:A,includedSteps:E}}};d.push(k)}}}}}})),h(d),d.length?p(Xg.Success):p(Xg.Failed),!o||!i)return}catch(e){p(Xg.Failed),console.error(e)}}))),[o,e,a,t,i,r,c]);return Ag({refetch:m}),{status:d,refetch:m,bridgeRouteList:n.useMemo((()=>r?f:[]),[d,r,f])}}({toToken:j,fromToken:M,fromAmount:A}),[re,oe]=n.useState(!1),[ie,se]=n.useState(""),ae=n.useMemo((()=>!ie&&ee.length?ee[0].id:ie),[ie,ee]),le=n.useMemo((()=>ee.find((e=>e.id===ae))),[ee,ae]);n.useEffect((()=>{!le&&ie&&se("")}),[le]);const{sendRouteLoading:ce,sendRouteError:ue,setSendRouteError:de,bridgeOrderTxRequest:pe,handleClickSend:fe}=$y(),[he,me]=n.useState(!1),ge=lb(D),{getApprovalState:ye,submitApprove:be,getPendingRest:ve,getMaxBalance:xe}=Gg({account:p,chainId:null!==(t=null==M?void 0:M.chainId)&&void 0!==t?t:d,contractAddress:null==le?void 0:le.spenderContractAddress}),we=n.useMemo((()=>ve(h?j:M)),[null==M?void 0:M.address,null==j?void 0:j.address,ve,h]),Ee=n.useCallback((e=>{const t=e.toString();x(t),T(t)}),[x,T]),Ae=n.useCallback((e=>{const t=e.toString();E(t),N(t)}),[E,N]);ub({fromToken:M,toToken:j,setFromToken:O,setToToken:F,updateFromAmt:Ee,updateToAmt:Ae});const ke=n.useCallback((()=>{Ee(""),Ae(""),O(j),F(M),Vm("from",j),Vm("to",M),se("")}),[O,j,F,M,Ee,Ae,se]),Ce=n.useCallback((e=>h?Ae(xe(j)):Ee(xe(M))),[Ee,Ae,xe,M,j,h]),Re=n.useMemo((()=>(100*Number(G)).toFixed(2)),[G]),Se=n.useMemo((()=>{const e=h?Y:A;return e&&U?new C.default(U).multipliedBy(e):null}),[U,A,h,Y]),Te=n.useMemo((()=>{var e;if(!L||void 0===D)return null;if(D)return(null===(e=null==le?void 0:le.toTokenAmount)||void 0===e?void 0:e.gt(0))?le.toTokenAmount.multipliedBy(L):null;const t=h?R:Y;return t?new C.default(L).multipliedBy(t):null}),[L,R,h,Y,le,D]),Ne=n.useMemo((()=>ne.exports.jsxs(Tr,{sx:{display:"flex",fontWeight:600,typography:"body2",alignItems:"center",justifyContent:"center"},children:[ne.exports.jsx(Pg,{title:ne.exports.jsx(e.Trans,{id:"Due to the market condition, market price and estimated price may have a slight difference"}),mr:8}),ne.exports.jsxs(Tr,{sx:{display:"flex"},children:[ne.exports.jsx(e.Trans,{id:"Current price impact"}),ne.exports.jsxs(Tr,{sx:{color:a.palette.error.main,ml:4},children:[Re,"%"]})]})]})),[Re]),Me=n.useMemo((()=>ne.exports.jsx(Ug,{toToken:j,fromToken:M,priceStatus:$,pricePerToToken:Q,pricePerFromToken:K})),[j,M,$,Q,K]),Oe=n.useMemo((()=>!ia[d||1]),[d]),Ie=n.useMemo((()=>d&&!!(null==M?void 0:M.chainId)&&(null==M?void 0:M.chainId)!==d),[d,null==M?void 0:M.chainId]),je=n.useMemo((()=>Ie?ne.exports.jsxs(Tr,{sx:{textAlign:"center"},children:[ne.exports.jsx(Tr,{component:i.Warn,sx:{position:"relative",top:2,mr:6,width:16,height:16,color:"warning.main"}}),ne.exports.jsx(e.Trans,{id:"The current network is inconsistent with the wallet - please switch in wallet"})]}):$===Mg.Loading||D&&te===Mg.Loading?ne.exports.jsx(Tr,{sx:{display:"flex",justifyContent:"center",alignItems:"center"},children:ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(_n,{sx:{mr:5}}),ne.exports.jsx(e.Trans,{id:"Fetching best price..."})]})}):Oe?ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsx(Tr,{component:i.Warn,sx:{mr:6,width:16,color:"warning.main"}}),ne.exports.jsx(e.Trans,{id:"Unsupported network - switch to trade"})]}):!D&&v&&new C.default(Re).gt(15)?Ne:D&&ee.length?ne.exports.jsx(Ky,{route:le,onClick:()=>oe(!0)}):Me),[$,Me,v,Ne,Re,Oe,D,te,ee,le,Ie]),Fe=n.useMemo((()=>h?new C.default(w).gt(0)?us({input:Y,decimals:null==M?void 0:M.decimals}):"-":v),[v,w,Y,M,h]),_e=n.useMemo((()=>{var e;return h?w:D?(null===(e=null==le?void 0:le.toTokenAmount)||void 0===e?void 0:e.gt(0))&&te!==Mg.Loading?us({input:le.toTokenAmount,decimals:null==j?void 0:j.decimals}):"-":new C.default(v).gt(0)?us({input:Y,decimals:null==j?void 0:j.decimals}):"-"}),[v,w,Y,j,h,le,D,te]),Pe=n.useMemo((()=>{const t=ye(M,h?Y||0:A),r=t===zg.Approving,n=t===zg.Insufficient&&!we,o=g?.1:.02,i=b===(null==M?void 0:M.address),s=new C.default(Z||0);if(!p)return ne.exports.jsx(Zg,{});if(c)return ne.exports.jsx(vn,{fullWidth:!0,isLoading:!0,disabled:!0,children:ne.exports.jsx(e.Trans,{id:"Transaction Pending"})});if(!M||!j)return ne.exports.jsx(vn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-select-token-btn",children:ne.exports.jsx(e.Trans,{id:"Select Tokens"})});if(n)return ne.exports.jsx(vn,{fullWidth:!0,disabled:r,onClick:()=>be(M),children:r?ne.exports.jsx(e.Trans,{id:"Approving"}):ne.exports.jsx(e.Trans,{id:"Approve"})});if(!new C.default(h?R:A).gt(0))return ne.exports.jsx(vn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-enter-amount-btn",children:ne.exports.jsx(e.Trans,{id:"Enter an amount"})});if(D?te===Mg.Loading||t===zg.Loading:$===Mg.Loading)return ne.exports.jsx(vn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-fetch-price-btn",children:ne.exports.jsx(e.Trans,{id:"Fetching Price..."})});let a=!1;return a=D?!ee.length||te===Mg.Failed:!Y||$===Mg.Failed,a?ne.exports.jsx(vn,{fullWidth:!0,disabled:!0,children:ne.exports.jsx(e.Trans,{id:"Quote not available"})}):s.lt(h?null!=Y?Y:0:A)||i&&s.lte(o)?ne.exports.jsx(vn,{fullWidth:!0,disabled:!0,"data-testid":"swap-alert-insufficient-balance-btn",children:ne.exports.jsx(e.Trans,{id:"Insufficient balance"})}):D?ne.exports.jsx(vn,{fullWidth:!0,onClick:()=>fe({selectedRoute:le,fromEtherTokenBalance:H,goNext:()=>me(!0)}),"data-testid":"swap-review-btn",isLoading:ce,children:ne.exports.jsx(e.Trans,{id:"Review Bridge"})}):ne.exports.jsx(vn,{fullWidth:!0,onClick:()=>P(!0),"data-testid":"swap-review-btn",children:ne.exports.jsx(e.Trans,{id:"Review Swap"})})}),[g,p,R,A,j,Y,M,c,X,we,be,$,Z,ye,b,h,D,te,ee,ce,H]),Be=n.useMemo((()=>M&&j?ne.exports.jsxs(Tr,{sx:{display:"flex",alignItems:"center"},children:[ne.exports.jsx(jm,{token:M,sx:{width:16,height:16,mr:6},chainId:M.chainId}),`${us({input:h?Y:A,decimals:null==M?void 0:M.decimals})} ${null==M?void 0:M.symbol}`,ne.exports.jsx(Tr,{component:i.DoubleRight,sx:{width:12,height:12,mx:16}}),ne.exports.jsx(jm,{token:j,sx:{width:16,height:16,mr:6},chainId:j.chainId}),`${us({input:h?R:Y,decimals:null==j?void 0:j.decimals})} ${null==j?void 0:j.symbol}`]}):ne.exports.jsx(Tr,{})),[M,j,A,R,Y,h]);return ne.exports.jsxs(ne.exports.Fragment,{children:[ne.exports.jsxs(Tr,{sx:{display:"flex",justifyContent:"space-between",typography:"caption",margin:20},children:[ne.exports.jsx(e.Trans,{id:"Swap"}),ne.exports.jsx(ui,{open:ge,title:D?ne.exports.jsx(e.Trans,{id:"The setting has been switched to bridge mode"}):ne.exports.jsx(e.Trans,{id:"The setting has been switched to swap mode"}),placement:"bottom-end",children:ne.exports.jsx(Tr,{component:wn,children:ne.exports.jsx(Tr,{component:i.Setting,onClick:()=>W(!0),sx:{width:19,height:19,color:"text.primary",cursor:"pointer"}})})})]}),ne.exports.jsxs(Tr,{sx:{flex:1,padding:"0 20px 20px",overflowY:"auto"},children:[ne.exports.jsxs(Tr,{children:[ne.exports.jsx(_g,{sx:{mb:4},token:M,side:"from",amt:Fe,defaultLoadBalance:!0,onlyCurrentChain:!0,onMaxClick:Ce,onInputChange:Ee,onInputFocus:()=>{h&&Ee(""),f(rg({isReverseRouting:!1}))},showMaxBtn:!h&&!v,occupiedAddrs:[null!==(o=null==j?void 0:j.address)&&void 0!==o?o:""],fiatPriceTxt:Se?`$${cs({input:Se,showDecimals:1})}`:"-",onTokenChange:(e,t)=>{if(t)return ke();Ee(""),Ae(""),O(e),se(""),Vm("from",e)},readOnly:h,showChainLogo:!0}),ne.exports.jsx(Bg,{onClick:ke}),ne.exports.jsx(_g,{token:j,side:"to",amt:_e,onInputChange:Ae,onInputFocus:()=>{h||Ae(""),f(rg({isReverseRouting:!0}))},occupiedAddrs:[null!==(s=null==M?void 0:M.address)&&void 0!==s?s:""],fiatPriceTxt:Te?`$${cs({input:Te,showDecimals:1})}(${Re}%)`:"-",onTokenChange:(e,t)=>{if(t)return ke();Ee(""),Ae(""),F(e),se(""),Vm("to",e)},readOnly:D||!h,showChainLogo:!0}),ne.exports.jsx(Tr,{sx:{py:12,display:"flex",typography:"body2",alignItems:"center",justifyContent:"center",flexWrap:"wrap"},children:je})]}),Pe,ne.exports.jsxs(Tr,{sx:{mt:13,display:"flex",typography:"h6",cursor:"pointer",justifyContent:"center",alignItems:"center",color:a.palette.text.disabled},onClick:()=>window.open("https://app.dodoex.io"),children:[ne.exports.jsx(Tr,{sx:{width:24,typography:"body2",transform:"translate(1px, 2px)","& path":{fill:a.palette.text.disabled}},component:i.Dodo}),ne.exports.jsx(e.Trans,{id:"Powered by DODO protocol"})]})]}),ne.exports.jsx(Wg,{toToken:j,fromToken:M,fromAmount:h?Y:A,toAmount:h?R:Y,open:_,baseFeeAmount:J,priceImpact:Re,additionalFeeAmount:q,curToFiatPrice:Te,execute:()=>X(Be),clearFromAmt:()=>Ee(""),clearToAmt:()=>Ae(""),curFromFiatPrice:Se,pricePerFromToken:K,onClose:()=>P(!1)}),ne.exports.jsx(Lg,{open:B,onClose:()=>W(!1),isBridge:D}),ne.exports.jsx(Qy,{open:re,onClose:()=>oe(!1),selectedRouteId:ae,setSelectRouteId:se,bridgeRouteList:ee}),ne.exports.jsx(sb,{open:he,onClose:()=>me(!1),route:le,bridgeOrderTxRequest:pe,clearFromAmt:()=>Ee(""),clearToAmt:()=>Ae("")}),ne.exports.jsx(ab,{message:ue,onClose:()=>de("")})]})}var pb,fb=M.default;if("production"===process.env.NODE_ENV)pb=fb.createRoot,fb.hydrateRoot;else{var hb=fb.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;pb=function(e,t){hb.usingClientEntryPoint=!0;try{return fb.createRoot(e,t)}finally{hb.usingClientEntryPoint=!1}}}exports.InitSwapWidget=function(e){const t=document.getElementById("dodo-swap-widget");pb(t).render(ne.exports.jsx(jg,{...e,children:ne.exports.jsx(db,{})}))},exports.SwapWidget=function(e){return ne.exports.jsx(jg,{...e,children:ne.exports.jsx(db,{})})};
|