@antseed/payments 0.1.33 → 0.1.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (99) hide show
  1. package/dist/routes.js +1 -0
  2. package/dist/routes.js.map +1 -1
  3. package/dist/server.d.ts +6 -0
  4. package/dist/server.js +11 -0
  5. package/dist/server.js.map +1 -1
  6. package/dist/web/assets/{add-b5eUbGsB.js → add-DeqPaHlT.js} +1 -1
  7. package/dist/web/assets/{all-wallets-spzdqP60.js → all-wallets-BW8hOjoV.js} +1 -1
  8. package/dist/web/assets/{app-store-CVlXCB-3.js → app-store-Cf8UW5sB.js} +1 -1
  9. package/dist/web/assets/{apple-CjRtWDjq.js → apple-DupwNPad.js} +1 -1
  10. package/dist/web/assets/{arrow-bottom-JQPHzb7Y.js → arrow-bottom-Ovs8TVHh.js} +1 -1
  11. package/dist/web/assets/{arrow-bottom-circle-BeYQVn01.js → arrow-bottom-circle-B6MMRWsl.js} +1 -1
  12. package/dist/web/assets/{arrow-left-D8H3Dui1.js → arrow-left-D1G7DnRa.js} +1 -1
  13. package/dist/web/assets/{arrow-right-X1YbMMjr.js → arrow-right-U_HRMVvB.js} +1 -1
  14. package/dist/web/assets/{arrow-top-BD68mDkR.js → arrow-top-DvQ3Ht7G.js} +1 -1
  15. package/dist/web/assets/{bank-DEO8YfFr.js → bank-B1LXzEuV.js} +1 -1
  16. package/dist/web/assets/{basic-DbF6H7kc.js → basic-Pz0-lHcI.js} +1 -1
  17. package/dist/web/assets/{browser-DAwyk9lT.js → browser-COLYvZKb.js} +1 -1
  18. package/dist/web/assets/{card-CFV9woii.js → card-DTeUxKNS.js} +1 -1
  19. package/dist/web/assets/{ccip-FxIeBDYn.js → ccip-BPhSwP5T.js} +1 -1
  20. package/dist/web/assets/{checkmark-DVsZYWVg.js → checkmark-BCawWdRa.js} +1 -1
  21. package/dist/web/assets/{checkmark-bold-fggxu47q.js → checkmark-bold-7KAW-Hhd.js} +1 -1
  22. package/dist/web/assets/{chevron-bottom-CWMoDBjh.js → chevron-bottom-DJTn3wQP.js} +1 -1
  23. package/dist/web/assets/{chevron-left-CHKC1EJw.js → chevron-left-cNneey1w.js} +1 -1
  24. package/dist/web/assets/{chevron-right-suzjMOYh.js → chevron-right-E7p_sYMZ.js} +1 -1
  25. package/dist/web/assets/{chevron-top-Cz9NIhGe.js → chevron-top-BjFvP_Oa.js} +1 -1
  26. package/dist/web/assets/{chrome-store-DCiYwogo.js → chrome-store-Hr7ooy6S.js} +1 -1
  27. package/dist/web/assets/{clock-D-UleqXc.js → clock-Bbk2CxM4.js} +1 -1
  28. package/dist/web/assets/{close-CUWFvMvD.js → close-BOLPNamb.js} +1 -1
  29. package/dist/web/assets/{coinPlaceholder-ByDBysmx.js → coinPlaceholder-CD1o7LoA.js} +1 -1
  30. package/dist/web/assets/{compass-D0vR3PeW.js → compass-CalZEVfy.js} +1 -1
  31. package/dist/web/assets/{copy-BEe2PAzY.js → copy-MiGxmGE-.js} +1 -1
  32. package/dist/web/assets/core-B_7kgyir.js +908 -0
  33. package/dist/web/assets/{cursor-BPYWVX0N.js → cursor-Boi8BXS8.js} +1 -1
  34. package/dist/web/assets/{cursor-transparent-B1g-isg8.js → cursor-transparent-B0eU1zkK.js} +1 -1
  35. package/dist/web/assets/{desktop-CVkueCr8.js → desktop-D7vCwE2G.js} +1 -1
  36. package/dist/web/assets/{disconnect-DCD8iFMj.js → disconnect-Djf1UKCF.js} +1 -1
  37. package/dist/web/assets/{discord-tYJOMCUi.js → discord-_3NhMqWp.js} +1 -1
  38. package/dist/web/assets/{etherscan-CsTp5yFx.js → etherscan-Cr-tOHg0.js} +1 -1
  39. package/dist/web/assets/{exclamation-triangle-BM-2My2-.js → exclamation-triangle-U8MhVBIv.js} +1 -1
  40. package/dist/web/assets/{extension-DFBb3Mox.js → extension-TuKfjrSZ.js} +1 -1
  41. package/dist/web/assets/{external-link-CO4bl2xc.js → external-link-CJNOA6Uz.js} +1 -1
  42. package/dist/web/assets/{facebook-OjPFO_7I.js → facebook-DfEbJQRA.js} +1 -1
  43. package/dist/web/assets/{farcaster-ijWFbhnk.js → farcaster-BoW2peK7.js} +1 -1
  44. package/dist/web/assets/{filters-mIUtMUio.js → filters-D8rNKEaD.js} +1 -1
  45. package/dist/web/assets/{github-BAxPsZUD.js → github-CpP2AyVx.js} +1 -1
  46. package/dist/web/assets/{google-uX1s9M5J.js → google-CfzqprgI.js} +1 -1
  47. package/dist/web/assets/{help-circle-C87wQGoN.js → help-circle-DGtXMihI.js} +1 -1
  48. package/dist/web/assets/{id-CbOu_mWn.js → id-DaXrJ4sz.js} +1 -1
  49. package/dist/web/assets/{image-Dwx-pJ8w.js → image-CV4FLR6O.js} +1 -1
  50. package/dist/web/assets/index-BVb37feY.css +1 -0
  51. package/dist/web/assets/index-BiFc_StH.js +1730 -0
  52. package/dist/web/assets/{index-CN6n0s2n.js → index-CLk5YWTF.js} +1 -1
  53. package/dist/web/assets/{index-CGRcANai.js → index-Cl1YA1io.js} +1 -1
  54. package/dist/web/assets/{index-D4ijtQZo.js → index-Dm7CHRPu.js} +1 -1
  55. package/dist/web/assets/{index-nd7d8GFN.js → index-lLN6rM85.js} +6 -6
  56. package/dist/web/assets/{index.es-Bi6GZ2Ae.js → index.es-BQAuGrNS.js} +4 -4
  57. package/dist/web/assets/{info-BrkIlgVw.js → info-Bc_FTJrY.js} +1 -1
  58. package/dist/web/assets/{info-circle-EhA-EnCJ.js → info-circle-D7qv7bDA.js} +1 -1
  59. package/dist/web/assets/{lightbulb-CAs4IIQW.js → lightbulb-DB-i_l-v.js} +1 -1
  60. package/dist/web/assets/{mail-BF7ydn2w.js → mail-DGf5T4WA.js} +1 -1
  61. package/dist/web/assets/{metamask-sdk-BpagOCqf.js → metamask-sdk-q0htPLh7.js} +1 -1
  62. package/dist/web/assets/{mobile-lNCIhoC7.js → mobile-CZX0wU5G.js} +1 -1
  63. package/dist/web/assets/{more-CTVwJRfr.js → more-D1VHrlzV.js} +1 -1
  64. package/dist/web/assets/{network-placeholder-Dov3DZg1.js → network-placeholder-CfbcX6Le.js} +1 -1
  65. package/dist/web/assets/{nftPlaceholder-D1Ly6S3Y.js → nftPlaceholder-D0fPEogi.js} +1 -1
  66. package/dist/web/assets/{off-D1g0aA8-.js → off-BHW23iaI.js} +1 -1
  67. package/dist/web/assets/{play-store-B1a8Ha9g.js → play-store-DHETjUNs.js} +1 -1
  68. package/dist/web/assets/{plus-CEWqVjK9.js → plus-DlrQ4yxI.js} +1 -1
  69. package/dist/web/assets/{qr-code-BehrRTcm.js → qr-code-DMyooG0k.js} +1 -1
  70. package/dist/web/assets/{recycle-horizontal-bRYOFz9H.js → recycle-horizontal-CTU0L1BQ.js} +1 -1
  71. package/dist/web/assets/{refresh-iGF8E0Zl.js → refresh-8vDPwfkZ.js} +1 -1
  72. package/dist/web/assets/{reown-logo-BqhHkTy5.js → reown-logo-BmxuulvZ.js} +1 -1
  73. package/dist/web/assets/{search-DqcZbb1N.js → search-CcecU-rw.js} +1 -1
  74. package/dist/web/assets/{secp256k1-DROQc2Ly.js → secp256k1-CRff5k1J.js} +1 -1
  75. package/dist/web/assets/secp256k1-Cb4vPU9D.js +1 -0
  76. package/dist/web/assets/{send-DgI-7XGq.js → send-BRAk9RO9.js} +1 -1
  77. package/dist/web/assets/{swapHorizontal-BKHFKOSu.js → swapHorizontal-ChxZdwvx.js} +1 -1
  78. package/dist/web/assets/{swapHorizontalBold-CVKLJvLX.js → swapHorizontalBold-CQ0r5Qqx.js} +1 -1
  79. package/dist/web/assets/{swapHorizontalMedium-Ct5kmNFN.js → swapHorizontalMedium-B7QjF5YD.js} +1 -1
  80. package/dist/web/assets/{swapHorizontalRoundedBold-Cj6Que7y.js → swapHorizontalRoundedBold-BL0lyDxV.js} +1 -1
  81. package/dist/web/assets/{swapVertical-zf33-Qe0.js → swapVertical-Bvq0cYSG.js} +1 -1
  82. package/dist/web/assets/{telegram-CGzAgQwY.js → telegram-DDq2XzDz.js} +1 -1
  83. package/dist/web/assets/{three-dots-9XMov5-i.js → three-dots-50_Mf5SB.js} +1 -1
  84. package/dist/web/assets/{twitch-BxwNoMXF.js → twitch-B4BbEem_.js} +1 -1
  85. package/dist/web/assets/{twitterIcon-BDz4fn6Z.js → twitterIcon-BRDrQZD5.js} +1 -1
  86. package/dist/web/assets/{verify-DofFcLzG.js → verify-CBKvQyc4.js} +1 -1
  87. package/dist/web/assets/{verify-filled-CTBi66z3.js → verify-filled-BZrvtMOc.js} +1 -1
  88. package/dist/web/assets/{w3m-modal-CfsVIiht.js → w3m-modal-CjIFCkxD.js} +15 -15
  89. package/dist/web/assets/{wallet-BvvPOVqU.js → wallet-CaO-FyJW.js} +1 -1
  90. package/dist/web/assets/{wallet-placeholder-DUE81xyj.js → wallet-placeholder-DYZDkOSX.js} +1 -1
  91. package/dist/web/assets/{walletconnect-YT2TSgRf.js → walletconnect-DP8wF-GJ.js} +1 -1
  92. package/dist/web/assets/{warning-circle-DEfN0XLJ.js → warning-circle-C-9GvoCR.js} +1 -1
  93. package/dist/web/assets/{x-GWKGsVuE.js → x-Ut1DjSUM.js} +1 -1
  94. package/dist/web/index.html +2 -2
  95. package/package.json +2 -2
  96. package/dist/web/assets/core-DskrtHUx.js +0 -908
  97. package/dist/web/assets/index-C_cAC3Jq.css +0 -1
  98. package/dist/web/assets/index-DKt8pI_J.js +0 -1730
  99. package/dist/web/assets/secp256k1-BIqAbId2.js +0 -1
@@ -1,1730 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-CGRcANai.js","assets/index-kzlEvkEN.js","assets/index-D4ijtQZo.js","assets/events-DQ172AOg.js","assets/index.es-Bi6GZ2Ae.js"])))=>i.map(i=>d[i]);
2
- var Ok=Object.defineProperty;var _w=e=>{throw TypeError(e)};var Rk=(e,t,n)=>t in e?Ok(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var Qo=(e,t,n)=>Rk(e,typeof t!="symbol"?t+"":t,n),_0=(e,t,n)=>t.has(e)||_w("Cannot "+n);var L=(e,t,n)=>(_0(e,t,"read from private field"),n?n.call(e):t.get(e)),Ae=(e,t,n)=>t.has(e)?_w("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),he=(e,t,n,r)=>(_0(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),Re=(e,t,n)=>(_0(e,t,"access private method"),n);var vd=(e,t,n,r)=>({set _(s){he(e,t,s,n)},get _(){return L(e,t,r)}});(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const a of s)if(a.type==="childList")for(const c of a.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&r(c)}).observe(document,{childList:!0,subtree:!0});function n(s){const a={};return s.integrity&&(a.integrity=s.integrity),s.referrerPolicy&&(a.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?a.credentials="include":s.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function r(s){if(s.ep)return;s.ep=!0;const a=n(s);fetch(s.href,a)}})();var Sz=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function K2(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function jz(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var s=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,s.get?s:{enumerable:!0,get:function(){return e[r]}})}),n}var T0={exports:{}},Tc={},O0={exports:{}},Me={};/**
3
- * @license React
4
- * react.production.min.js
5
- *
6
- * Copyright (c) Facebook, Inc. and its affiliates.
7
- *
8
- * This source code is licensed under the MIT license found in the
9
- * LICENSE file in the root directory of this source tree.
10
- */var Tw;function Mk(){if(Tw)return Me;Tw=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),c=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.iterator;function m(F){return F===null||typeof F!="object"?null:(F=p&&F[p]||F["@@iterator"],typeof F=="function"?F:null)}var y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},v=Object.assign,w={};function C(F,X,pe){this.props=F,this.context=X,this.refs=w,this.updater=pe||y}C.prototype.isReactComponent={},C.prototype.setState=function(F,X){if(typeof F!="object"&&typeof F!="function"&&F!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,F,X,"setState")},C.prototype.forceUpdate=function(F){this.updater.enqueueForceUpdate(this,F,"forceUpdate")};function A(){}A.prototype=C.prototype;function I(F,X,pe){this.props=F,this.context=X,this.refs=w,this.updater=pe||y}var S=I.prototype=new A;S.constructor=I,v(S,C.prototype),S.isPureReactComponent=!0;var j=Array.isArray,N=Object.prototype.hasOwnProperty,T={current:null},B={key:!0,ref:!0,__self:!0,__source:!0};function O(F,X,pe){var ne,oe={},fe=null,ge=null;if(X!=null)for(ne in X.ref!==void 0&&(ge=X.ref),X.key!==void 0&&(fe=""+X.key),X)N.call(X,ne)&&!B.hasOwnProperty(ne)&&(oe[ne]=X[ne]);var Ie=arguments.length-2;if(Ie===1)oe.children=pe;else if(1<Ie){for(var Be=Array(Ie),Le=0;Le<Ie;Le++)Be[Le]=arguments[Le+2];oe.children=Be}if(F&&F.defaultProps)for(ne in Ie=F.defaultProps,Ie)oe[ne]===void 0&&(oe[ne]=Ie[ne]);return{$$typeof:e,type:F,key:fe,ref:ge,props:oe,_owner:T.current}}function R(F,X){return{$$typeof:e,type:F.type,key:X,ref:F.ref,props:F.props,_owner:F._owner}}function W(F){return typeof F=="object"&&F!==null&&F.$$typeof===e}function H(F){var X={"=":"=0",":":"=2"};return"$"+F.replace(/[=:]/g,function(pe){return X[pe]})}var K=/\/+/g;function Q(F,X){return typeof F=="object"&&F!==null&&F.key!=null?H(""+F.key):X.toString(36)}function ae(F,X,pe,ne,oe){var fe=typeof F;(fe==="undefined"||fe==="boolean")&&(F=null);var ge=!1;if(F===null)ge=!0;else switch(fe){case"string":case"number":ge=!0;break;case"object":switch(F.$$typeof){case e:case t:ge=!0}}if(ge)return ge=F,oe=oe(ge),F=ne===""?"."+Q(ge,0):ne,j(oe)?(pe="",F!=null&&(pe=F.replace(K,"$&/")+"/"),ae(oe,X,pe,"",function(Le){return Le})):oe!=null&&(W(oe)&&(oe=R(oe,pe+(!oe.key||ge&&ge.key===oe.key?"":(""+oe.key).replace(K,"$&/")+"/")+F)),X.push(oe)),1;if(ge=0,ne=ne===""?".":ne+":",j(F))for(var Ie=0;Ie<F.length;Ie++){fe=F[Ie];var Be=ne+Q(fe,Ie);ge+=ae(fe,X,pe,Be,oe)}else if(Be=m(F),typeof Be=="function")for(F=Be.call(F),Ie=0;!(fe=F.next()).done;)fe=fe.value,Be=ne+Q(fe,Ie++),ge+=ae(fe,X,pe,Be,oe);else if(fe==="object")throw X=String(F),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(F).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.");return ge}function q(F,X,pe){if(F==null)return F;var ne=[],oe=0;return ae(F,ne,"","",function(fe){return X.call(pe,fe,oe++)}),ne}function ee(F){if(F._status===-1){var X=F._result;X=X(),X.then(function(pe){(F._status===0||F._status===-1)&&(F._status=1,F._result=pe)},function(pe){(F._status===0||F._status===-1)&&(F._status=2,F._result=pe)}),F._status===-1&&(F._status=0,F._result=X)}if(F._status===1)return F._result.default;throw F._result}var te={current:null},U={transition:null},Y={ReactCurrentDispatcher:te,ReactCurrentBatchConfig:U,ReactCurrentOwner:T};function Z(){throw Error("act(...) is not supported in production builds of React.")}return Me.Children={map:q,forEach:function(F,X,pe){q(F,function(){X.apply(this,arguments)},pe)},count:function(F){var X=0;return q(F,function(){X++}),X},toArray:function(F){return q(F,function(X){return X})||[]},only:function(F){if(!W(F))throw Error("React.Children.only expected to receive a single React element child.");return F}},Me.Component=C,Me.Fragment=n,Me.Profiler=s,Me.PureComponent=I,Me.StrictMode=r,Me.Suspense=d,Me.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Y,Me.act=Z,Me.cloneElement=function(F,X,pe){if(F==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+F+".");var ne=v({},F.props),oe=F.key,fe=F.ref,ge=F._owner;if(X!=null){if(X.ref!==void 0&&(fe=X.ref,ge=T.current),X.key!==void 0&&(oe=""+X.key),F.type&&F.type.defaultProps)var Ie=F.type.defaultProps;for(Be in X)N.call(X,Be)&&!B.hasOwnProperty(Be)&&(ne[Be]=X[Be]===void 0&&Ie!==void 0?Ie[Be]:X[Be])}var Be=arguments.length-2;if(Be===1)ne.children=pe;else if(1<Be){Ie=Array(Be);for(var Le=0;Le<Be;Le++)Ie[Le]=arguments[Le+2];ne.children=Ie}return{$$typeof:e,type:F.type,key:oe,ref:fe,props:ne,_owner:ge}},Me.createContext=function(F){return F={$$typeof:c,_currentValue:F,_currentValue2:F,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},F.Provider={$$typeof:a,_context:F},F.Consumer=F},Me.createElement=O,Me.createFactory=function(F){var X=O.bind(null,F);return X.type=F,X},Me.createRef=function(){return{current:null}},Me.forwardRef=function(F){return{$$typeof:l,render:F}},Me.isValidElement=W,Me.lazy=function(F){return{$$typeof:h,_payload:{_status:-1,_result:F},_init:ee}},Me.memo=function(F,X){return{$$typeof:f,type:F,compare:X===void 0?null:X}},Me.startTransition=function(F){var X=U.transition;U.transition={};try{F()}finally{U.transition=X}},Me.unstable_act=Z,Me.useCallback=function(F,X){return te.current.useCallback(F,X)},Me.useContext=function(F){return te.current.useContext(F)},Me.useDebugValue=function(){},Me.useDeferredValue=function(F){return te.current.useDeferredValue(F)},Me.useEffect=function(F,X){return te.current.useEffect(F,X)},Me.useId=function(){return te.current.useId()},Me.useImperativeHandle=function(F,X,pe){return te.current.useImperativeHandle(F,X,pe)},Me.useInsertionEffect=function(F,X){return te.current.useInsertionEffect(F,X)},Me.useLayoutEffect=function(F,X){return te.current.useLayoutEffect(F,X)},Me.useMemo=function(F,X){return te.current.useMemo(F,X)},Me.useReducer=function(F,X,pe){return te.current.useReducer(F,X,pe)},Me.useRef=function(F){return te.current.useRef(F)},Me.useState=function(F){return te.current.useState(F)},Me.useSyncExternalStore=function(F,X,pe){return te.current.useSyncExternalStore(F,X,pe)},Me.useTransition=function(){return te.current.useTransition()},Me.version="18.3.1",Me}var Ow;function zl(){return Ow||(Ow=1,O0.exports=Mk()),O0.exports}/**
11
- * @license React
12
- * react-jsx-runtime.production.min.js
13
- *
14
- * Copyright (c) Facebook, Inc. and its affiliates.
15
- *
16
- * This source code is licensed under the MIT license found in the
17
- * LICENSE file in the root directory of this source tree.
18
- */var Rw;function Dk(){if(Rw)return Tc;Rw=1;var e=zl(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,s=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function c(l,d,f){var h,p={},m=null,y=null;f!==void 0&&(m=""+f),d.key!==void 0&&(m=""+d.key),d.ref!==void 0&&(y=d.ref);for(h in d)r.call(d,h)&&!a.hasOwnProperty(h)&&(p[h]=d[h]);if(l&&l.defaultProps)for(h in d=l.defaultProps,d)p[h]===void 0&&(p[h]=d[h]);return{$$typeof:t,type:l,key:m,ref:y,props:p,_owner:s.current}}return Tc.Fragment=n,Tc.jsx=c,Tc.jsxs=c,Tc}var Mw;function Fk(){return Mw||(Mw=1,T0.exports=Dk()),T0.exports}var b=Fk(),wd={},R0={exports:{}},yn={},M0={exports:{}},D0={};/**
19
- * @license React
20
- * scheduler.production.min.js
21
- *
22
- * Copyright (c) Facebook, Inc. and its affiliates.
23
- *
24
- * This source code is licensed under the MIT license found in the
25
- * LICENSE file in the root directory of this source tree.
26
- */var Dw;function Lk(){return Dw||(Dw=1,(function(e){function t(U,Y){var Z=U.length;U.push(Y);e:for(;0<Z;){var F=Z-1>>>1,X=U[F];if(0<s(X,Y))U[F]=Y,U[Z]=X,Z=F;else break e}}function n(U){return U.length===0?null:U[0]}function r(U){if(U.length===0)return null;var Y=U[0],Z=U.pop();if(Z!==Y){U[0]=Z;e:for(var F=0,X=U.length,pe=X>>>1;F<pe;){var ne=2*(F+1)-1,oe=U[ne],fe=ne+1,ge=U[fe];if(0>s(oe,Z))fe<X&&0>s(ge,oe)?(U[F]=ge,U[fe]=Z,F=fe):(U[F]=oe,U[ne]=Z,F=ne);else if(fe<X&&0>s(ge,Z))U[F]=ge,U[fe]=Z,F=fe;else break e}}return Y}function s(U,Y){var Z=U.sortIndex-Y.sortIndex;return Z!==0?Z:U.id-Y.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var c=Date,l=c.now();e.unstable_now=function(){return c.now()-l}}var d=[],f=[],h=1,p=null,m=3,y=!1,v=!1,w=!1,C=typeof setTimeout=="function"?setTimeout:null,A=typeof clearTimeout=="function"?clearTimeout:null,I=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function S(U){for(var Y=n(f);Y!==null;){if(Y.callback===null)r(f);else if(Y.startTime<=U)r(f),Y.sortIndex=Y.expirationTime,t(d,Y);else break;Y=n(f)}}function j(U){if(w=!1,S(U),!v)if(n(d)!==null)v=!0,ee(N);else{var Y=n(f);Y!==null&&te(j,Y.startTime-U)}}function N(U,Y){v=!1,w&&(w=!1,A(O),O=-1),y=!0;var Z=m;try{for(S(Y),p=n(d);p!==null&&(!(p.expirationTime>Y)||U&&!H());){var F=p.callback;if(typeof F=="function"){p.callback=null,m=p.priorityLevel;var X=F(p.expirationTime<=Y);Y=e.unstable_now(),typeof X=="function"?p.callback=X:p===n(d)&&r(d),S(Y)}else r(d);p=n(d)}if(p!==null)var pe=!0;else{var ne=n(f);ne!==null&&te(j,ne.startTime-Y),pe=!1}return pe}finally{p=null,m=Z,y=!1}}var T=!1,B=null,O=-1,R=5,W=-1;function H(){return!(e.unstable_now()-W<R)}function K(){if(B!==null){var U=e.unstable_now();W=U;var Y=!0;try{Y=B(!0,U)}finally{Y?Q():(T=!1,B=null)}}else T=!1}var Q;if(typeof I=="function")Q=function(){I(K)};else if(typeof MessageChannel<"u"){var ae=new MessageChannel,q=ae.port2;ae.port1.onmessage=K,Q=function(){q.postMessage(null)}}else Q=function(){C(K,0)};function ee(U){B=U,T||(T=!0,Q())}function te(U,Y){O=C(function(){U(e.unstable_now())},Y)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(U){U.callback=null},e.unstable_continueExecution=function(){v||y||(v=!0,ee(N))},e.unstable_forceFrameRate=function(U){0>U||125<U?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):R=0<U?Math.floor(1e3/U):5},e.unstable_getCurrentPriorityLevel=function(){return m},e.unstable_getFirstCallbackNode=function(){return n(d)},e.unstable_next=function(U){switch(m){case 1:case 2:case 3:var Y=3;break;default:Y=m}var Z=m;m=Y;try{return U()}finally{m=Z}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(U,Y){switch(U){case 1:case 2:case 3:case 4:case 5:break;default:U=3}var Z=m;m=U;try{return Y()}finally{m=Z}},e.unstable_scheduleCallback=function(U,Y,Z){var F=e.unstable_now();switch(typeof Z=="object"&&Z!==null?(Z=Z.delay,Z=typeof Z=="number"&&0<Z?F+Z:F):Z=F,U){case 1:var X=-1;break;case 2:X=250;break;case 5:X=1073741823;break;case 4:X=1e4;break;default:X=5e3}return X=Z+X,U={id:h++,callback:Y,priorityLevel:U,startTime:Z,expirationTime:X,sortIndex:-1},Z>F?(U.sortIndex=Z,t(f,U),n(d)===null&&U===n(f)&&(w?(A(O),O=-1):w=!0,te(j,Z-F))):(U.sortIndex=X,t(d,U),v||y||(v=!0,ee(N))),U},e.unstable_shouldYield=H,e.unstable_wrapCallback=function(U){var Y=m;return function(){var Z=m;m=Y;try{return U.apply(this,arguments)}finally{m=Z}}}})(D0)),D0}var Fw;function Uk(){return Fw||(Fw=1,M0.exports=Lk()),M0.exports}/**
27
- * @license React
28
- * react-dom.production.min.js
29
- *
30
- * Copyright (c) Facebook, Inc. and its affiliates.
31
- *
32
- * This source code is licensed under the MIT license found in the
33
- * LICENSE file in the root directory of this source tree.
34
- */var Lw;function zk(){if(Lw)return yn;Lw=1;var e=zl(),t=Uk();function n(o){for(var i="https://reactjs.org/docs/error-decoder.html?invariant="+o,u=1;u<arguments.length;u++)i+="&args[]="+encodeURIComponent(arguments[u]);return"Minified React error #"+o+"; visit "+i+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,s={};function a(o,i){c(o,i),c(o+"Capture",i)}function c(o,i){for(s[o]=i,o=0;o<i.length;o++)r.add(i[o])}var l=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),d=Object.prototype.hasOwnProperty,f=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,h={},p={};function m(o){return d.call(p,o)?!0:d.call(h,o)?!1:f.test(o)?p[o]=!0:(h[o]=!0,!1)}function y(o,i,u,g){if(u!==null&&u.type===0)return!1;switch(typeof i){case"function":case"symbol":return!0;case"boolean":return g?!1:u!==null?!u.acceptsBooleans:(o=o.toLowerCase().slice(0,5),o!=="data-"&&o!=="aria-");default:return!1}}function v(o,i,u,g){if(i===null||typeof i>"u"||y(o,i,u,g))return!0;if(g)return!1;if(u!==null)switch(u.type){case 3:return!i;case 4:return i===!1;case 5:return isNaN(i);case 6:return isNaN(i)||1>i}return!1}function w(o,i,u,g,x,E,_){this.acceptsBooleans=i===2||i===3||i===4,this.attributeName=g,this.attributeNamespace=x,this.mustUseProperty=u,this.propertyName=o,this.type=i,this.sanitizeURL=E,this.removeEmptyString=_}var C={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(o){C[o]=new w(o,0,!1,o,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(o){var i=o[0];C[i]=new w(i,1,!1,o[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(o){C[o]=new w(o,2,!1,o.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(o){C[o]=new w(o,2,!1,o,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(o){C[o]=new w(o,3,!1,o.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(o){C[o]=new w(o,3,!0,o,null,!1,!1)}),["capture","download"].forEach(function(o){C[o]=new w(o,4,!1,o,null,!1,!1)}),["cols","rows","size","span"].forEach(function(o){C[o]=new w(o,6,!1,o,null,!1,!1)}),["rowSpan","start"].forEach(function(o){C[o]=new w(o,5,!1,o.toLowerCase(),null,!1,!1)});var A=/[\-:]([a-z])/g;function I(o){return o[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(o){var i=o.replace(A,I);C[i]=new w(i,1,!1,o,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(o){var i=o.replace(A,I);C[i]=new w(i,1,!1,o,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(o){var i=o.replace(A,I);C[i]=new w(i,1,!1,o,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(o){C[o]=new w(o,1,!1,o.toLowerCase(),null,!1,!1)}),C.xlinkHref=new w("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(o){C[o]=new w(o,1,!1,o.toLowerCase(),null,!0,!0)});function S(o,i,u,g){var x=C.hasOwnProperty(i)?C[i]:null;(x!==null?x.type!==0:g||!(2<i.length)||i[0]!=="o"&&i[0]!=="O"||i[1]!=="n"&&i[1]!=="N")&&(v(i,u,x,g)&&(u=null),g||x===null?m(i)&&(u===null?o.removeAttribute(i):o.setAttribute(i,""+u)):x.mustUseProperty?o[x.propertyName]=u===null?x.type===3?!1:"":u:(i=x.attributeName,g=x.attributeNamespace,u===null?o.removeAttribute(i):(x=x.type,u=x===3||x===4&&u===!0?"":""+u,g?o.setAttributeNS(g,i,u):o.setAttribute(i,u))))}var j=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,N=Symbol.for("react.element"),T=Symbol.for("react.portal"),B=Symbol.for("react.fragment"),O=Symbol.for("react.strict_mode"),R=Symbol.for("react.profiler"),W=Symbol.for("react.provider"),H=Symbol.for("react.context"),K=Symbol.for("react.forward_ref"),Q=Symbol.for("react.suspense"),ae=Symbol.for("react.suspense_list"),q=Symbol.for("react.memo"),ee=Symbol.for("react.lazy"),te=Symbol.for("react.offscreen"),U=Symbol.iterator;function Y(o){return o===null||typeof o!="object"?null:(o=U&&o[U]||o["@@iterator"],typeof o=="function"?o:null)}var Z=Object.assign,F;function X(o){if(F===void 0)try{throw Error()}catch(u){var i=u.stack.trim().match(/\n( *(at )?)/);F=i&&i[1]||""}return`
35
- `+F+o}var pe=!1;function ne(o,i){if(!o||pe)return"";pe=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(i)if(i=function(){throw Error()},Object.defineProperty(i.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(i,[])}catch(J){var g=J}Reflect.construct(o,[],i)}else{try{i.call()}catch(J){g=J}o.call(i.prototype)}else{try{throw Error()}catch(J){g=J}o()}}catch(J){if(J&&g&&typeof J.stack=="string"){for(var x=J.stack.split(`
36
- `),E=g.stack.split(`
37
- `),_=x.length-1,M=E.length-1;1<=_&&0<=M&&x[_]!==E[M];)M--;for(;1<=_&&0<=M;_--,M--)if(x[_]!==E[M]){if(_!==1||M!==1)do if(_--,M--,0>M||x[_]!==E[M]){var z=`
38
- `+x[_].replace(" at new "," at ");return o.displayName&&z.includes("<anonymous>")&&(z=z.replace("<anonymous>",o.displayName)),z}while(1<=_&&0<=M);break}}}finally{pe=!1,Error.prepareStackTrace=u}return(o=o?o.displayName||o.name:"")?X(o):""}function oe(o){switch(o.tag){case 5:return X(o.type);case 16:return X("Lazy");case 13:return X("Suspense");case 19:return X("SuspenseList");case 0:case 2:case 15:return o=ne(o.type,!1),o;case 11:return o=ne(o.type.render,!1),o;case 1:return o=ne(o.type,!0),o;default:return""}}function fe(o){if(o==null)return null;if(typeof o=="function")return o.displayName||o.name||null;if(typeof o=="string")return o;switch(o){case B:return"Fragment";case T:return"Portal";case R:return"Profiler";case O:return"StrictMode";case Q:return"Suspense";case ae:return"SuspenseList"}if(typeof o=="object")switch(o.$$typeof){case H:return(o.displayName||"Context")+".Consumer";case W:return(o._context.displayName||"Context")+".Provider";case K:var i=o.render;return o=o.displayName,o||(o=i.displayName||i.name||"",o=o!==""?"ForwardRef("+o+")":"ForwardRef"),o;case q:return i=o.displayName||null,i!==null?i:fe(o.type)||"Memo";case ee:i=o._payload,o=o._init;try{return fe(o(i))}catch{}}return null}function ge(o){var i=o.type;switch(o.tag){case 24:return"Cache";case 9:return(i.displayName||"Context")+".Consumer";case 10:return(i._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return o=i.render,o=o.displayName||o.name||"",i.displayName||(o!==""?"ForwardRef("+o+")":"ForwardRef");case 7:return"Fragment";case 5:return i;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return fe(i);case 8:return i===O?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof i=="function")return i.displayName||i.name||null;if(typeof i=="string")return i}return null}function Ie(o){switch(typeof o){case"boolean":case"number":case"string":case"undefined":return o;case"object":return o;default:return""}}function Be(o){var i=o.type;return(o=o.nodeName)&&o.toLowerCase()==="input"&&(i==="checkbox"||i==="radio")}function Le(o){var i=Be(o)?"checked":"value",u=Object.getOwnPropertyDescriptor(o.constructor.prototype,i),g=""+o[i];if(!o.hasOwnProperty(i)&&typeof u<"u"&&typeof u.get=="function"&&typeof u.set=="function"){var x=u.get,E=u.set;return Object.defineProperty(o,i,{configurable:!0,get:function(){return x.call(this)},set:function(_){g=""+_,E.call(this,_)}}),Object.defineProperty(o,i,{enumerable:u.enumerable}),{getValue:function(){return g},setValue:function(_){g=""+_},stopTracking:function(){o._valueTracker=null,delete o[i]}}}}function _e(o){o._valueTracker||(o._valueTracker=Le(o))}function Te(o){if(!o)return!1;var i=o._valueTracker;if(!i)return!0;var u=i.getValue(),g="";return o&&(g=Be(o)?o.checked?"true":"false":o.value),o=g,o!==u?(i.setValue(o),!0):!1}function dt(o){if(o=o||(typeof document<"u"?document:void 0),typeof o>"u")return null;try{return o.activeElement||o.body}catch{return o.body}}function tt(o,i){var u=i.checked;return Z({},i,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:u??o._wrapperState.initialChecked})}function ft(o,i){var u=i.defaultValue==null?"":i.defaultValue,g=i.checked!=null?i.checked:i.defaultChecked;u=Ie(i.value!=null?i.value:u),o._wrapperState={initialChecked:g,initialValue:u,controlled:i.type==="checkbox"||i.type==="radio"?i.checked!=null:i.value!=null}}function ze(o,i){i=i.checked,i!=null&&S(o,"checked",i,!1)}function ht(o,i){ze(o,i);var u=Ie(i.value),g=i.type;if(u!=null)g==="number"?(u===0&&o.value===""||o.value!=u)&&(o.value=""+u):o.value!==""+u&&(o.value=""+u);else if(g==="submit"||g==="reset"){o.removeAttribute("value");return}i.hasOwnProperty("value")?gt(o,i.type,u):i.hasOwnProperty("defaultValue")&&gt(o,i.type,Ie(i.defaultValue)),i.checked==null&&i.defaultChecked!=null&&(o.defaultChecked=!!i.defaultChecked)}function Ze(o,i,u){if(i.hasOwnProperty("value")||i.hasOwnProperty("defaultValue")){var g=i.type;if(!(g!=="submit"&&g!=="reset"||i.value!==void 0&&i.value!==null))return;i=""+o._wrapperState.initialValue,u||i===o.value||(o.value=i),o.defaultValue=i}u=o.name,u!==""&&(o.name=""),o.defaultChecked=!!o._wrapperState.initialChecked,u!==""&&(o.name=u)}function gt(o,i,u){(i!=="number"||dt(o.ownerDocument)!==o)&&(u==null?o.defaultValue=""+o._wrapperState.initialValue:o.defaultValue!==""+u&&(o.defaultValue=""+u))}var It=Array.isArray;function qn(o,i,u,g){if(o=o.options,i){i={};for(var x=0;x<u.length;x++)i["$"+u[x]]=!0;for(u=0;u<o.length;u++)x=i.hasOwnProperty("$"+o[u].value),o[u].selected!==x&&(o[u].selected=x),x&&g&&(o[u].defaultSelected=!0)}else{for(u=""+Ie(u),i=null,x=0;x<o.length;x++){if(o[x].value===u){o[x].selected=!0,g&&(o[x].defaultSelected=!0);return}i!==null||o[x].disabled||(i=o[x])}i!==null&&(i.selected=!0)}}function Sr(o,i){if(i.dangerouslySetInnerHTML!=null)throw Error(n(91));return Z({},i,{value:void 0,defaultValue:void 0,children:""+o._wrapperState.initialValue})}function ir(o,i){var u=i.value;if(u==null){if(u=i.children,i=i.defaultValue,u!=null){if(i!=null)throw Error(n(92));if(It(u)){if(1<u.length)throw Error(n(93));u=u[0]}i=u}i==null&&(i=""),u=i}o._wrapperState={initialValue:Ie(u)}}function Xt(o,i){var u=Ie(i.value),g=Ie(i.defaultValue);u!=null&&(u=""+u,u!==o.value&&(o.value=u),i.defaultValue==null&&o.defaultValue!==u&&(o.defaultValue=u)),g!=null&&(o.defaultValue=""+g)}function bs(o){var i=o.textContent;i===o._wrapperState.initialValue&&i!==""&&i!==null&&(o.value=i)}function xs(o){switch(o){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Nn(o,i){return o==null||o==="http://www.w3.org/1999/xhtml"?xs(i):o==="http://www.w3.org/2000/svg"&&i==="foreignObject"?"http://www.w3.org/1999/xhtml":o}var Mt,Pn=(function(o){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(i,u,g,x){MSApp.execUnsafeLocalFunction(function(){return o(i,u,g,x)})}:o})(function(o,i){if(o.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in o)o.innerHTML=i;else{for(Mt=Mt||document.createElement("div"),Mt.innerHTML="<svg>"+i.valueOf().toString()+"</svg>",i=Mt.firstChild;o.firstChild;)o.removeChild(o.firstChild);for(;i.firstChild;)o.appendChild(i.firstChild)}});function dn(o,i){if(i){var u=o.firstChild;if(u&&u===o.lastChild&&u.nodeType===3){u.nodeValue=i;return}}o.textContent=i}var Oe={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Ue=["Webkit","ms","Moz","O"];Object.keys(Oe).forEach(function(o){Ue.forEach(function(i){i=i+o.charAt(0).toUpperCase()+o.substring(1),Oe[i]=Oe[o]})});function Ne(o,i,u){return i==null||typeof i=="boolean"||i===""?"":u||typeof i!="number"||i===0||Oe.hasOwnProperty(o)&&Oe[o]?(""+i).trim():i+"px"}function He(o,i){o=o.style;for(var u in i)if(i.hasOwnProperty(u)){var g=u.indexOf("--")===0,x=Ne(u,i[u],g);u==="float"&&(u="cssFloat"),g?o.setProperty(u,x):o[u]=x}}var Bn=Z({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function at(o,i){if(i){if(Bn[o]&&(i.children!=null||i.dangerouslySetInnerHTML!=null))throw Error(n(137,o));if(i.dangerouslySetInnerHTML!=null){if(i.children!=null)throw Error(n(60));if(typeof i.dangerouslySetInnerHTML!="object"||!("__html"in i.dangerouslySetInnerHTML))throw Error(n(61))}if(i.style!=null&&typeof i.style!="object")throw Error(n(62))}}function Fe(o,i){if(o.indexOf("-")===-1)return typeof i.is=="string";switch(o){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var ke=null;function Wt(o){return o=o.target||o.srcElement||window,o.correspondingUseElement&&(o=o.correspondingUseElement),o.nodeType===3?o.parentNode:o}var jr=null,ar=null,So=null;function Ja(o){if(o=vc(o)){if(typeof jr!="function")throw Error(n(280));var i=o.stateNode;i&&(i=Tu(i),jr(o.stateNode,o.type,i))}}function _n(o){ar?So?So.push(o):So=[o]:ar=o}function ki(){if(ar){var o=ar,i=So;if(So=ar=null,Ja(o),i)for(o=0;o<i.length;o++)Ja(i[o])}}function lu(o,i){return o(i)}function uu(){}var Za=!1;function Ve(o,i,u){if(Za)return o(i,u);Za=!0;try{return lu(o,i,u)}finally{Za=!1,(ar!==null||So!==null)&&(uu(),ki())}}function $t(o,i){var u=o.stateNode;if(u===null)return null;var g=Tu(u);if(g===null)return null;u=g[i];e:switch(i){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(g=!g.disabled)||(o=o.type,g=!(o==="button"||o==="input"||o==="select"||o==="textarea")),o=!g;break e;default:o=!1}if(o)return null;if(u&&typeof u!="function")throw Error(n(231,i,typeof u));return u}var jo=!1;if(l)try{var Ir={};Object.defineProperty(Ir,"passive",{get:function(){jo=!0}}),window.addEventListener("test",Ir,Ir),window.removeEventListener("test",Ir,Ir)}catch{jo=!1}function Cs(o,i,u,g,x,E,_,M,z){var J=Array.prototype.slice.call(arguments,3);try{i.apply(u,J)}catch(ie){this.onError(ie)}}var Xa=!1,du=null,fu=!1,Jf=null,zE={onError:function(o){Xa=!0,du=o}};function WE(o,i,u,g,x,E,_,M,z){Xa=!1,du=null,Cs.apply(zE,arguments)}function $E(o,i,u,g,x,E,_,M,z){if(WE.apply(this,arguments),Xa){if(Xa){var J=du;Xa=!1,du=null}else throw Error(n(198));fu||(fu=!0,Jf=J)}}function Es(o){var i=o,u=o;if(o.alternate)for(;i.return;)i=i.return;else{o=i;do i=o,(i.flags&4098)!==0&&(u=i.return),o=i.return;while(o)}return i.tag===3?u:null}function ty(o){if(o.tag===13){var i=o.memoizedState;if(i===null&&(o=o.alternate,o!==null&&(i=o.memoizedState)),i!==null)return i.dehydrated}return null}function ny(o){if(Es(o)!==o)throw Error(n(188))}function qE(o){var i=o.alternate;if(!i){if(i=Es(o),i===null)throw Error(n(188));return i!==o?null:o}for(var u=o,g=i;;){var x=u.return;if(x===null)break;var E=x.alternate;if(E===null){if(g=x.return,g!==null){u=g;continue}break}if(x.child===E.child){for(E=x.child;E;){if(E===u)return ny(x),o;if(E===g)return ny(x),i;E=E.sibling}throw Error(n(188))}if(u.return!==g.return)u=x,g=E;else{for(var _=!1,M=x.child;M;){if(M===u){_=!0,u=x,g=E;break}if(M===g){_=!0,g=x,u=E;break}M=M.sibling}if(!_){for(M=E.child;M;){if(M===u){_=!0,u=E,g=x;break}if(M===g){_=!0,g=E,u=x;break}M=M.sibling}if(!_)throw Error(n(189))}}if(u.alternate!==g)throw Error(n(190))}if(u.tag!==3)throw Error(n(188));return u.stateNode.current===u?o:i}function ry(o){return o=qE(o),o!==null?oy(o):null}function oy(o){if(o.tag===5||o.tag===6)return o;for(o=o.child;o!==null;){var i=oy(o);if(i!==null)return i;o=o.sibling}return null}var sy=t.unstable_scheduleCallback,iy=t.unstable_cancelCallback,HE=t.unstable_shouldYield,VE=t.unstable_requestPaint,pt=t.unstable_now,QE=t.unstable_getCurrentPriorityLevel,Zf=t.unstable_ImmediatePriority,ay=t.unstable_UserBlockingPriority,hu=t.unstable_NormalPriority,GE=t.unstable_LowPriority,cy=t.unstable_IdlePriority,pu=null,Nr=null;function KE(o){if(Nr&&typeof Nr.onCommitFiberRoot=="function")try{Nr.onCommitFiberRoot(pu,o,void 0,(o.current.flags&128)===128)}catch{}}var cr=Math.clz32?Math.clz32:ZE,YE=Math.log,JE=Math.LN2;function ZE(o){return o>>>=0,o===0?32:31-(YE(o)/JE|0)|0}var mu=64,gu=4194304;function ec(o){switch(o&-o){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return o&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return o&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return o}}function yu(o,i){var u=o.pendingLanes;if(u===0)return 0;var g=0,x=o.suspendedLanes,E=o.pingedLanes,_=u&268435455;if(_!==0){var M=_&~x;M!==0?g=ec(M):(E&=_,E!==0&&(g=ec(E)))}else _=u&~x,_!==0?g=ec(_):E!==0&&(g=ec(E));if(g===0)return 0;if(i!==0&&i!==g&&(i&x)===0&&(x=g&-g,E=i&-i,x>=E||x===16&&(E&4194240)!==0))return i;if((g&4)!==0&&(g|=u&16),i=o.entangledLanes,i!==0)for(o=o.entanglements,i&=g;0<i;)u=31-cr(i),x=1<<u,g|=o[u],i&=~x;return g}function XE(o,i){switch(o){case 1:case 2:case 4:return i+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return i+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function eA(o,i){for(var u=o.suspendedLanes,g=o.pingedLanes,x=o.expirationTimes,E=o.pendingLanes;0<E;){var _=31-cr(E),M=1<<_,z=x[_];z===-1?((M&u)===0||(M&g)!==0)&&(x[_]=XE(M,i)):z<=i&&(o.expiredLanes|=M),E&=~M}}function Xf(o){return o=o.pendingLanes&-1073741825,o!==0?o:o&1073741824?1073741824:0}function ly(){var o=mu;return mu<<=1,(mu&4194240)===0&&(mu=64),o}function eh(o){for(var i=[],u=0;31>u;u++)i.push(o);return i}function tc(o,i,u){o.pendingLanes|=i,i!==536870912&&(o.suspendedLanes=0,o.pingedLanes=0),o=o.eventTimes,i=31-cr(i),o[i]=u}function tA(o,i){var u=o.pendingLanes&~i;o.pendingLanes=i,o.suspendedLanes=0,o.pingedLanes=0,o.expiredLanes&=i,o.mutableReadLanes&=i,o.entangledLanes&=i,i=o.entanglements;var g=o.eventTimes;for(o=o.expirationTimes;0<u;){var x=31-cr(u),E=1<<x;i[x]=0,g[x]=-1,o[x]=-1,u&=~E}}function th(o,i){var u=o.entangledLanes|=i;for(o=o.entanglements;u;){var g=31-cr(u),x=1<<g;x&i|o[g]&i&&(o[g]|=i),u&=~x}}var Ye=0;function uy(o){return o&=-o,1<o?4<o?(o&268435455)!==0?16:536870912:4:1}var dy,nh,fy,hy,py,rh=!1,vu=[],Io=null,No=null,Po=null,nc=new Map,rc=new Map,Bo=[],nA="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function my(o,i){switch(o){case"focusin":case"focusout":Io=null;break;case"dragenter":case"dragleave":No=null;break;case"mouseover":case"mouseout":Po=null;break;case"pointerover":case"pointerout":nc.delete(i.pointerId);break;case"gotpointercapture":case"lostpointercapture":rc.delete(i.pointerId)}}function oc(o,i,u,g,x,E){return o===null||o.nativeEvent!==E?(o={blockedOn:i,domEventName:u,eventSystemFlags:g,nativeEvent:E,targetContainers:[x]},i!==null&&(i=vc(i),i!==null&&nh(i)),o):(o.eventSystemFlags|=g,i=o.targetContainers,x!==null&&i.indexOf(x)===-1&&i.push(x),o)}function rA(o,i,u,g,x){switch(i){case"focusin":return Io=oc(Io,o,i,u,g,x),!0;case"dragenter":return No=oc(No,o,i,u,g,x),!0;case"mouseover":return Po=oc(Po,o,i,u,g,x),!0;case"pointerover":var E=x.pointerId;return nc.set(E,oc(nc.get(E)||null,o,i,u,g,x)),!0;case"gotpointercapture":return E=x.pointerId,rc.set(E,oc(rc.get(E)||null,o,i,u,g,x)),!0}return!1}function gy(o){var i=As(o.target);if(i!==null){var u=Es(i);if(u!==null){if(i=u.tag,i===13){if(i=ty(u),i!==null){o.blockedOn=i,py(o.priority,function(){fy(u)});return}}else if(i===3&&u.stateNode.current.memoizedState.isDehydrated){o.blockedOn=u.tag===3?u.stateNode.containerInfo:null;return}}}o.blockedOn=null}function wu(o){if(o.blockedOn!==null)return!1;for(var i=o.targetContainers;0<i.length;){var u=sh(o.domEventName,o.eventSystemFlags,i[0],o.nativeEvent);if(u===null){u=o.nativeEvent;var g=new u.constructor(u.type,u);ke=g,u.target.dispatchEvent(g),ke=null}else return i=vc(u),i!==null&&nh(i),o.blockedOn=u,!1;i.shift()}return!0}function yy(o,i,u){wu(o)&&u.delete(i)}function oA(){rh=!1,Io!==null&&wu(Io)&&(Io=null),No!==null&&wu(No)&&(No=null),Po!==null&&wu(Po)&&(Po=null),nc.forEach(yy),rc.forEach(yy)}function sc(o,i){o.blockedOn===i&&(o.blockedOn=null,rh||(rh=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,oA)))}function ic(o){function i(x){return sc(x,o)}if(0<vu.length){sc(vu[0],o);for(var u=1;u<vu.length;u++){var g=vu[u];g.blockedOn===o&&(g.blockedOn=null)}}for(Io!==null&&sc(Io,o),No!==null&&sc(No,o),Po!==null&&sc(Po,o),nc.forEach(i),rc.forEach(i),u=0;u<Bo.length;u++)g=Bo[u],g.blockedOn===o&&(g.blockedOn=null);for(;0<Bo.length&&(u=Bo[0],u.blockedOn===null);)gy(u),u.blockedOn===null&&Bo.shift()}var Si=j.ReactCurrentBatchConfig,bu=!0;function sA(o,i,u,g){var x=Ye,E=Si.transition;Si.transition=null;try{Ye=1,oh(o,i,u,g)}finally{Ye=x,Si.transition=E}}function iA(o,i,u,g){var x=Ye,E=Si.transition;Si.transition=null;try{Ye=4,oh(o,i,u,g)}finally{Ye=x,Si.transition=E}}function oh(o,i,u,g){if(bu){var x=sh(o,i,u,g);if(x===null)Ch(o,i,g,xu,u),my(o,g);else if(rA(x,o,i,u,g))g.stopPropagation();else if(my(o,g),i&4&&-1<nA.indexOf(o)){for(;x!==null;){var E=vc(x);if(E!==null&&dy(E),E=sh(o,i,u,g),E===null&&Ch(o,i,g,xu,u),E===x)break;x=E}x!==null&&g.stopPropagation()}else Ch(o,i,g,null,u)}}var xu=null;function sh(o,i,u,g){if(xu=null,o=Wt(g),o=As(o),o!==null)if(i=Es(o),i===null)o=null;else if(u=i.tag,u===13){if(o=ty(i),o!==null)return o;o=null}else if(u===3){if(i.stateNode.current.memoizedState.isDehydrated)return i.tag===3?i.stateNode.containerInfo:null;o=null}else i!==o&&(o=null);return xu=o,null}function vy(o){switch(o){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(QE()){case Zf:return 1;case ay:return 4;case hu:case GE:return 16;case cy:return 536870912;default:return 16}default:return 16}}var _o=null,ih=null,Cu=null;function wy(){if(Cu)return Cu;var o,i=ih,u=i.length,g,x="value"in _o?_o.value:_o.textContent,E=x.length;for(o=0;o<u&&i[o]===x[o];o++);var _=u-o;for(g=1;g<=_&&i[u-g]===x[E-g];g++);return Cu=x.slice(o,1<g?1-g:void 0)}function Eu(o){var i=o.keyCode;return"charCode"in o?(o=o.charCode,o===0&&i===13&&(o=13)):o=i,o===10&&(o=13),32<=o||o===13?o:0}function Au(){return!0}function by(){return!1}function Tn(o){function i(u,g,x,E,_){this._reactName=u,this._targetInst=x,this.type=g,this.nativeEvent=E,this.target=_,this.currentTarget=null;for(var M in o)o.hasOwnProperty(M)&&(u=o[M],this[M]=u?u(E):E[M]);return this.isDefaultPrevented=(E.defaultPrevented!=null?E.defaultPrevented:E.returnValue===!1)?Au:by,this.isPropagationStopped=by,this}return Z(i.prototype,{preventDefault:function(){this.defaultPrevented=!0;var u=this.nativeEvent;u&&(u.preventDefault?u.preventDefault():typeof u.returnValue!="unknown"&&(u.returnValue=!1),this.isDefaultPrevented=Au)},stopPropagation:function(){var u=this.nativeEvent;u&&(u.stopPropagation?u.stopPropagation():typeof u.cancelBubble!="unknown"&&(u.cancelBubble=!0),this.isPropagationStopped=Au)},persist:function(){},isPersistent:Au}),i}var ji={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(o){return o.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ah=Tn(ji),ac=Z({},ji,{view:0,detail:0}),aA=Tn(ac),ch,lh,cc,ku=Z({},ac,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:dh,button:0,buttons:0,relatedTarget:function(o){return o.relatedTarget===void 0?o.fromElement===o.srcElement?o.toElement:o.fromElement:o.relatedTarget},movementX:function(o){return"movementX"in o?o.movementX:(o!==cc&&(cc&&o.type==="mousemove"?(ch=o.screenX-cc.screenX,lh=o.screenY-cc.screenY):lh=ch=0,cc=o),ch)},movementY:function(o){return"movementY"in o?o.movementY:lh}}),xy=Tn(ku),cA=Z({},ku,{dataTransfer:0}),lA=Tn(cA),uA=Z({},ac,{relatedTarget:0}),uh=Tn(uA),dA=Z({},ji,{animationName:0,elapsedTime:0,pseudoElement:0}),fA=Tn(dA),hA=Z({},ji,{clipboardData:function(o){return"clipboardData"in o?o.clipboardData:window.clipboardData}}),pA=Tn(hA),mA=Z({},ji,{data:0}),Cy=Tn(mA),gA={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},yA={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},vA={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function wA(o){var i=this.nativeEvent;return i.getModifierState?i.getModifierState(o):(o=vA[o])?!!i[o]:!1}function dh(){return wA}var bA=Z({},ac,{key:function(o){if(o.key){var i=gA[o.key]||o.key;if(i!=="Unidentified")return i}return o.type==="keypress"?(o=Eu(o),o===13?"Enter":String.fromCharCode(o)):o.type==="keydown"||o.type==="keyup"?yA[o.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:dh,charCode:function(o){return o.type==="keypress"?Eu(o):0},keyCode:function(o){return o.type==="keydown"||o.type==="keyup"?o.keyCode:0},which:function(o){return o.type==="keypress"?Eu(o):o.type==="keydown"||o.type==="keyup"?o.keyCode:0}}),xA=Tn(bA),CA=Z({},ku,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Ey=Tn(CA),EA=Z({},ac,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:dh}),AA=Tn(EA),kA=Z({},ji,{propertyName:0,elapsedTime:0,pseudoElement:0}),SA=Tn(kA),jA=Z({},ku,{deltaX:function(o){return"deltaX"in o?o.deltaX:"wheelDeltaX"in o?-o.wheelDeltaX:0},deltaY:function(o){return"deltaY"in o?o.deltaY:"wheelDeltaY"in o?-o.wheelDeltaY:"wheelDelta"in o?-o.wheelDelta:0},deltaZ:0,deltaMode:0}),IA=Tn(jA),NA=[9,13,27,32],fh=l&&"CompositionEvent"in window,lc=null;l&&"documentMode"in document&&(lc=document.documentMode);var PA=l&&"TextEvent"in window&&!lc,Ay=l&&(!fh||lc&&8<lc&&11>=lc),ky=" ",Sy=!1;function jy(o,i){switch(o){case"keyup":return NA.indexOf(i.keyCode)!==-1;case"keydown":return i.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Iy(o){return o=o.detail,typeof o=="object"&&"data"in o?o.data:null}var Ii=!1;function BA(o,i){switch(o){case"compositionend":return Iy(i);case"keypress":return i.which!==32?null:(Sy=!0,ky);case"textInput":return o=i.data,o===ky&&Sy?null:o;default:return null}}function _A(o,i){if(Ii)return o==="compositionend"||!fh&&jy(o,i)?(o=wy(),Cu=ih=_o=null,Ii=!1,o):null;switch(o){case"paste":return null;case"keypress":if(!(i.ctrlKey||i.altKey||i.metaKey)||i.ctrlKey&&i.altKey){if(i.char&&1<i.char.length)return i.char;if(i.which)return String.fromCharCode(i.which)}return null;case"compositionend":return Ay&&i.locale!=="ko"?null:i.data;default:return null}}var TA={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Ny(o){var i=o&&o.nodeName&&o.nodeName.toLowerCase();return i==="input"?!!TA[o.type]:i==="textarea"}function Py(o,i,u,g){_n(g),i=Pu(i,"onChange"),0<i.length&&(u=new ah("onChange","change",null,u,g),o.push({event:u,listeners:i}))}var uc=null,dc=null;function OA(o){Gy(o,0)}function Su(o){var i=Ti(o);if(Te(i))return o}function RA(o,i){if(o==="change")return i}var By=!1;if(l){var hh;if(l){var ph="oninput"in document;if(!ph){var _y=document.createElement("div");_y.setAttribute("oninput","return;"),ph=typeof _y.oninput=="function"}hh=ph}else hh=!1;By=hh&&(!document.documentMode||9<document.documentMode)}function Ty(){uc&&(uc.detachEvent("onpropertychange",Oy),dc=uc=null)}function Oy(o){if(o.propertyName==="value"&&Su(dc)){var i=[];Py(i,dc,o,Wt(o)),Ve(OA,i)}}function MA(o,i,u){o==="focusin"?(Ty(),uc=i,dc=u,uc.attachEvent("onpropertychange",Oy)):o==="focusout"&&Ty()}function DA(o){if(o==="selectionchange"||o==="keyup"||o==="keydown")return Su(dc)}function FA(o,i){if(o==="click")return Su(i)}function LA(o,i){if(o==="input"||o==="change")return Su(i)}function UA(o,i){return o===i&&(o!==0||1/o===1/i)||o!==o&&i!==i}var lr=typeof Object.is=="function"?Object.is:UA;function fc(o,i){if(lr(o,i))return!0;if(typeof o!="object"||o===null||typeof i!="object"||i===null)return!1;var u=Object.keys(o),g=Object.keys(i);if(u.length!==g.length)return!1;for(g=0;g<u.length;g++){var x=u[g];if(!d.call(i,x)||!lr(o[x],i[x]))return!1}return!0}function Ry(o){for(;o&&o.firstChild;)o=o.firstChild;return o}function My(o,i){var u=Ry(o);o=0;for(var g;u;){if(u.nodeType===3){if(g=o+u.textContent.length,o<=i&&g>=i)return{node:u,offset:i-o};o=g}e:{for(;u;){if(u.nextSibling){u=u.nextSibling;break e}u=u.parentNode}u=void 0}u=Ry(u)}}function Dy(o,i){return o&&i?o===i?!0:o&&o.nodeType===3?!1:i&&i.nodeType===3?Dy(o,i.parentNode):"contains"in o?o.contains(i):o.compareDocumentPosition?!!(o.compareDocumentPosition(i)&16):!1:!1}function Fy(){for(var o=window,i=dt();i instanceof o.HTMLIFrameElement;){try{var u=typeof i.contentWindow.location.href=="string"}catch{u=!1}if(u)o=i.contentWindow;else break;i=dt(o.document)}return i}function mh(o){var i=o&&o.nodeName&&o.nodeName.toLowerCase();return i&&(i==="input"&&(o.type==="text"||o.type==="search"||o.type==="tel"||o.type==="url"||o.type==="password")||i==="textarea"||o.contentEditable==="true")}function zA(o){var i=Fy(),u=o.focusedElem,g=o.selectionRange;if(i!==u&&u&&u.ownerDocument&&Dy(u.ownerDocument.documentElement,u)){if(g!==null&&mh(u)){if(i=g.start,o=g.end,o===void 0&&(o=i),"selectionStart"in u)u.selectionStart=i,u.selectionEnd=Math.min(o,u.value.length);else if(o=(i=u.ownerDocument||document)&&i.defaultView||window,o.getSelection){o=o.getSelection();var x=u.textContent.length,E=Math.min(g.start,x);g=g.end===void 0?E:Math.min(g.end,x),!o.extend&&E>g&&(x=g,g=E,E=x),x=My(u,E);var _=My(u,g);x&&_&&(o.rangeCount!==1||o.anchorNode!==x.node||o.anchorOffset!==x.offset||o.focusNode!==_.node||o.focusOffset!==_.offset)&&(i=i.createRange(),i.setStart(x.node,x.offset),o.removeAllRanges(),E>g?(o.addRange(i),o.extend(_.node,_.offset)):(i.setEnd(_.node,_.offset),o.addRange(i)))}}for(i=[],o=u;o=o.parentNode;)o.nodeType===1&&i.push({element:o,left:o.scrollLeft,top:o.scrollTop});for(typeof u.focus=="function"&&u.focus(),u=0;u<i.length;u++)o=i[u],o.element.scrollLeft=o.left,o.element.scrollTop=o.top}}var WA=l&&"documentMode"in document&&11>=document.documentMode,Ni=null,gh=null,hc=null,yh=!1;function Ly(o,i,u){var g=u.window===u?u.document:u.nodeType===9?u:u.ownerDocument;yh||Ni==null||Ni!==dt(g)||(g=Ni,"selectionStart"in g&&mh(g)?g={start:g.selectionStart,end:g.selectionEnd}:(g=(g.ownerDocument&&g.ownerDocument.defaultView||window).getSelection(),g={anchorNode:g.anchorNode,anchorOffset:g.anchorOffset,focusNode:g.focusNode,focusOffset:g.focusOffset}),hc&&fc(hc,g)||(hc=g,g=Pu(gh,"onSelect"),0<g.length&&(i=new ah("onSelect","select",null,i,u),o.push({event:i,listeners:g}),i.target=Ni)))}function ju(o,i){var u={};return u[o.toLowerCase()]=i.toLowerCase(),u["Webkit"+o]="webkit"+i,u["Moz"+o]="moz"+i,u}var Pi={animationend:ju("Animation","AnimationEnd"),animationiteration:ju("Animation","AnimationIteration"),animationstart:ju("Animation","AnimationStart"),transitionend:ju("Transition","TransitionEnd")},vh={},Uy={};l&&(Uy=document.createElement("div").style,"AnimationEvent"in window||(delete Pi.animationend.animation,delete Pi.animationiteration.animation,delete Pi.animationstart.animation),"TransitionEvent"in window||delete Pi.transitionend.transition);function Iu(o){if(vh[o])return vh[o];if(!Pi[o])return o;var i=Pi[o],u;for(u in i)if(i.hasOwnProperty(u)&&u in Uy)return vh[o]=i[u];return o}var zy=Iu("animationend"),Wy=Iu("animationiteration"),$y=Iu("animationstart"),qy=Iu("transitionend"),Hy=new Map,Vy="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function To(o,i){Hy.set(o,i),a(i,[o])}for(var wh=0;wh<Vy.length;wh++){var bh=Vy[wh],$A=bh.toLowerCase(),qA=bh[0].toUpperCase()+bh.slice(1);To($A,"on"+qA)}To(zy,"onAnimationEnd"),To(Wy,"onAnimationIteration"),To($y,"onAnimationStart"),To("dblclick","onDoubleClick"),To("focusin","onFocus"),To("focusout","onBlur"),To(qy,"onTransitionEnd"),c("onMouseEnter",["mouseout","mouseover"]),c("onMouseLeave",["mouseout","mouseover"]),c("onPointerEnter",["pointerout","pointerover"]),c("onPointerLeave",["pointerout","pointerover"]),a("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),a("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),a("onBeforeInput",["compositionend","keypress","textInput","paste"]),a("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var pc="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),HA=new Set("cancel close invalid load scroll toggle".split(" ").concat(pc));function Qy(o,i,u){var g=o.type||"unknown-event";o.currentTarget=u,$E(g,i,void 0,o),o.currentTarget=null}function Gy(o,i){i=(i&4)!==0;for(var u=0;u<o.length;u++){var g=o[u],x=g.event;g=g.listeners;e:{var E=void 0;if(i)for(var _=g.length-1;0<=_;_--){var M=g[_],z=M.instance,J=M.currentTarget;if(M=M.listener,z!==E&&x.isPropagationStopped())break e;Qy(x,M,J),E=z}else for(_=0;_<g.length;_++){if(M=g[_],z=M.instance,J=M.currentTarget,M=M.listener,z!==E&&x.isPropagationStopped())break e;Qy(x,M,J),E=z}}}if(fu)throw o=Jf,fu=!1,Jf=null,o}function Xe(o,i){var u=i[Ih];u===void 0&&(u=i[Ih]=new Set);var g=o+"__bubble";u.has(g)||(Ky(i,o,2,!1),u.add(g))}function xh(o,i,u){var g=0;i&&(g|=4),Ky(u,o,g,i)}var Nu="_reactListening"+Math.random().toString(36).slice(2);function mc(o){if(!o[Nu]){o[Nu]=!0,r.forEach(function(u){u!=="selectionchange"&&(HA.has(u)||xh(u,!1,o),xh(u,!0,o))});var i=o.nodeType===9?o:o.ownerDocument;i===null||i[Nu]||(i[Nu]=!0,xh("selectionchange",!1,i))}}function Ky(o,i,u,g){switch(vy(i)){case 1:var x=sA;break;case 4:x=iA;break;default:x=oh}u=x.bind(null,i,u,o),x=void 0,!jo||i!=="touchstart"&&i!=="touchmove"&&i!=="wheel"||(x=!0),g?x!==void 0?o.addEventListener(i,u,{capture:!0,passive:x}):o.addEventListener(i,u,!0):x!==void 0?o.addEventListener(i,u,{passive:x}):o.addEventListener(i,u,!1)}function Ch(o,i,u,g,x){var E=g;if((i&1)===0&&(i&2)===0&&g!==null)e:for(;;){if(g===null)return;var _=g.tag;if(_===3||_===4){var M=g.stateNode.containerInfo;if(M===x||M.nodeType===8&&M.parentNode===x)break;if(_===4)for(_=g.return;_!==null;){var z=_.tag;if((z===3||z===4)&&(z=_.stateNode.containerInfo,z===x||z.nodeType===8&&z.parentNode===x))return;_=_.return}for(;M!==null;){if(_=As(M),_===null)return;if(z=_.tag,z===5||z===6){g=E=_;continue e}M=M.parentNode}}g=g.return}Ve(function(){var J=E,ie=Wt(u),ce=[];e:{var se=Hy.get(o);if(se!==void 0){var me=ah,we=o;switch(o){case"keypress":if(Eu(u)===0)break e;case"keydown":case"keyup":me=xA;break;case"focusin":we="focus",me=uh;break;case"focusout":we="blur",me=uh;break;case"beforeblur":case"afterblur":me=uh;break;case"click":if(u.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":me=xy;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":me=lA;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":me=AA;break;case zy:case Wy:case $y:me=fA;break;case qy:me=SA;break;case"scroll":me=aA;break;case"wheel":me=IA;break;case"copy":case"cut":case"paste":me=pA;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":me=Ey}var be=(i&4)!==0,mt=!be&&o==="scroll",V=be?se!==null?se+"Capture":null:se;be=[];for(var $=J,G;$!==null;){G=$;var ue=G.stateNode;if(G.tag===5&&ue!==null&&(G=ue,V!==null&&(ue=$t($,V),ue!=null&&be.push(gc($,ue,G)))),mt)break;$=$.return}0<be.length&&(se=new me(se,we,null,u,ie),ce.push({event:se,listeners:be}))}}if((i&7)===0){e:{if(se=o==="mouseover"||o==="pointerover",me=o==="mouseout"||o==="pointerout",se&&u!==ke&&(we=u.relatedTarget||u.fromElement)&&(As(we)||we[Yr]))break e;if((me||se)&&(se=ie.window===ie?ie:(se=ie.ownerDocument)?se.defaultView||se.parentWindow:window,me?(we=u.relatedTarget||u.toElement,me=J,we=we?As(we):null,we!==null&&(mt=Es(we),we!==mt||we.tag!==5&&we.tag!==6)&&(we=null)):(me=null,we=J),me!==we)){if(be=xy,ue="onMouseLeave",V="onMouseEnter",$="mouse",(o==="pointerout"||o==="pointerover")&&(be=Ey,ue="onPointerLeave",V="onPointerEnter",$="pointer"),mt=me==null?se:Ti(me),G=we==null?se:Ti(we),se=new be(ue,$+"leave",me,u,ie),se.target=mt,se.relatedTarget=G,ue=null,As(ie)===J&&(be=new be(V,$+"enter",we,u,ie),be.target=G,be.relatedTarget=mt,ue=be),mt=ue,me&&we)t:{for(be=me,V=we,$=0,G=be;G;G=Bi(G))$++;for(G=0,ue=V;ue;ue=Bi(ue))G++;for(;0<$-G;)be=Bi(be),$--;for(;0<G-$;)V=Bi(V),G--;for(;$--;){if(be===V||V!==null&&be===V.alternate)break t;be=Bi(be),V=Bi(V)}be=null}else be=null;me!==null&&Yy(ce,se,me,be,!1),we!==null&&mt!==null&&Yy(ce,mt,we,be,!0)}}e:{if(se=J?Ti(J):window,me=se.nodeName&&se.nodeName.toLowerCase(),me==="select"||me==="input"&&se.type==="file")var Ce=RA;else if(Ny(se))if(By)Ce=LA;else{Ce=DA;var Se=MA}else(me=se.nodeName)&&me.toLowerCase()==="input"&&(se.type==="checkbox"||se.type==="radio")&&(Ce=FA);if(Ce&&(Ce=Ce(o,J))){Py(ce,Ce,u,ie);break e}Se&&Se(o,se,J),o==="focusout"&&(Se=se._wrapperState)&&Se.controlled&&se.type==="number"&&gt(se,"number",se.value)}switch(Se=J?Ti(J):window,o){case"focusin":(Ny(Se)||Se.contentEditable==="true")&&(Ni=Se,gh=J,hc=null);break;case"focusout":hc=gh=Ni=null;break;case"mousedown":yh=!0;break;case"contextmenu":case"mouseup":case"dragend":yh=!1,Ly(ce,u,ie);break;case"selectionchange":if(WA)break;case"keydown":case"keyup":Ly(ce,u,ie)}var je;if(fh)e:{switch(o){case"compositionstart":var Pe="onCompositionStart";break e;case"compositionend":Pe="onCompositionEnd";break e;case"compositionupdate":Pe="onCompositionUpdate";break e}Pe=void 0}else Ii?jy(o,u)&&(Pe="onCompositionEnd"):o==="keydown"&&u.keyCode===229&&(Pe="onCompositionStart");Pe&&(Ay&&u.locale!=="ko"&&(Ii||Pe!=="onCompositionStart"?Pe==="onCompositionEnd"&&Ii&&(je=wy()):(_o=ie,ih="value"in _o?_o.value:_o.textContent,Ii=!0)),Se=Pu(J,Pe),0<Se.length&&(Pe=new Cy(Pe,o,null,u,ie),ce.push({event:Pe,listeners:Se}),je?Pe.data=je:(je=Iy(u),je!==null&&(Pe.data=je)))),(je=PA?BA(o,u):_A(o,u))&&(J=Pu(J,"onBeforeInput"),0<J.length&&(ie=new Cy("onBeforeInput","beforeinput",null,u,ie),ce.push({event:ie,listeners:J}),ie.data=je))}Gy(ce,i)})}function gc(o,i,u){return{instance:o,listener:i,currentTarget:u}}function Pu(o,i){for(var u=i+"Capture",g=[];o!==null;){var x=o,E=x.stateNode;x.tag===5&&E!==null&&(x=E,E=$t(o,u),E!=null&&g.unshift(gc(o,E,x)),E=$t(o,i),E!=null&&g.push(gc(o,E,x))),o=o.return}return g}function Bi(o){if(o===null)return null;do o=o.return;while(o&&o.tag!==5);return o||null}function Yy(o,i,u,g,x){for(var E=i._reactName,_=[];u!==null&&u!==g;){var M=u,z=M.alternate,J=M.stateNode;if(z!==null&&z===g)break;M.tag===5&&J!==null&&(M=J,x?(z=$t(u,E),z!=null&&_.unshift(gc(u,z,M))):x||(z=$t(u,E),z!=null&&_.push(gc(u,z,M)))),u=u.return}_.length!==0&&o.push({event:i,listeners:_})}var VA=/\r\n?/g,QA=/\u0000|\uFFFD/g;function Jy(o){return(typeof o=="string"?o:""+o).replace(VA,`
39
- `).replace(QA,"")}function Bu(o,i,u){if(i=Jy(i),Jy(o)!==i&&u)throw Error(n(425))}function _u(){}var Eh=null,Ah=null;function kh(o,i){return o==="textarea"||o==="noscript"||typeof i.children=="string"||typeof i.children=="number"||typeof i.dangerouslySetInnerHTML=="object"&&i.dangerouslySetInnerHTML!==null&&i.dangerouslySetInnerHTML.__html!=null}var Sh=typeof setTimeout=="function"?setTimeout:void 0,GA=typeof clearTimeout=="function"?clearTimeout:void 0,Zy=typeof Promise=="function"?Promise:void 0,KA=typeof queueMicrotask=="function"?queueMicrotask:typeof Zy<"u"?function(o){return Zy.resolve(null).then(o).catch(YA)}:Sh;function YA(o){setTimeout(function(){throw o})}function jh(o,i){var u=i,g=0;do{var x=u.nextSibling;if(o.removeChild(u),x&&x.nodeType===8)if(u=x.data,u==="/$"){if(g===0){o.removeChild(x),ic(i);return}g--}else u!=="$"&&u!=="$?"&&u!=="$!"||g++;u=x}while(u);ic(i)}function Oo(o){for(;o!=null;o=o.nextSibling){var i=o.nodeType;if(i===1||i===3)break;if(i===8){if(i=o.data,i==="$"||i==="$!"||i==="$?")break;if(i==="/$")return null}}return o}function Xy(o){o=o.previousSibling;for(var i=0;o;){if(o.nodeType===8){var u=o.data;if(u==="$"||u==="$!"||u==="$?"){if(i===0)return o;i--}else u==="/$"&&i++}o=o.previousSibling}return null}var _i=Math.random().toString(36).slice(2),Pr="__reactFiber$"+_i,yc="__reactProps$"+_i,Yr="__reactContainer$"+_i,Ih="__reactEvents$"+_i,JA="__reactListeners$"+_i,ZA="__reactHandles$"+_i;function As(o){var i=o[Pr];if(i)return i;for(var u=o.parentNode;u;){if(i=u[Yr]||u[Pr]){if(u=i.alternate,i.child!==null||u!==null&&u.child!==null)for(o=Xy(o);o!==null;){if(u=o[Pr])return u;o=Xy(o)}return i}o=u,u=o.parentNode}return null}function vc(o){return o=o[Pr]||o[Yr],!o||o.tag!==5&&o.tag!==6&&o.tag!==13&&o.tag!==3?null:o}function Ti(o){if(o.tag===5||o.tag===6)return o.stateNode;throw Error(n(33))}function Tu(o){return o[yc]||null}var Nh=[],Oi=-1;function Ro(o){return{current:o}}function et(o){0>Oi||(o.current=Nh[Oi],Nh[Oi]=null,Oi--)}function Je(o,i){Oi++,Nh[Oi]=o.current,o.current=i}var Mo={},qt=Ro(Mo),fn=Ro(!1),ks=Mo;function Ri(o,i){var u=o.type.contextTypes;if(!u)return Mo;var g=o.stateNode;if(g&&g.__reactInternalMemoizedUnmaskedChildContext===i)return g.__reactInternalMemoizedMaskedChildContext;var x={},E;for(E in u)x[E]=i[E];return g&&(o=o.stateNode,o.__reactInternalMemoizedUnmaskedChildContext=i,o.__reactInternalMemoizedMaskedChildContext=x),x}function hn(o){return o=o.childContextTypes,o!=null}function Ou(){et(fn),et(qt)}function ev(o,i,u){if(qt.current!==Mo)throw Error(n(168));Je(qt,i),Je(fn,u)}function tv(o,i,u){var g=o.stateNode;if(i=i.childContextTypes,typeof g.getChildContext!="function")return u;g=g.getChildContext();for(var x in g)if(!(x in i))throw Error(n(108,ge(o)||"Unknown",x));return Z({},u,g)}function Ru(o){return o=(o=o.stateNode)&&o.__reactInternalMemoizedMergedChildContext||Mo,ks=qt.current,Je(qt,o),Je(fn,fn.current),!0}function nv(o,i,u){var g=o.stateNode;if(!g)throw Error(n(169));u?(o=tv(o,i,ks),g.__reactInternalMemoizedMergedChildContext=o,et(fn),et(qt),Je(qt,o)):et(fn),Je(fn,u)}var Jr=null,Mu=!1,Ph=!1;function rv(o){Jr===null?Jr=[o]:Jr.push(o)}function XA(o){Mu=!0,rv(o)}function Do(){if(!Ph&&Jr!==null){Ph=!0;var o=0,i=Ye;try{var u=Jr;for(Ye=1;o<u.length;o++){var g=u[o];do g=g(!0);while(g!==null)}Jr=null,Mu=!1}catch(x){throw Jr!==null&&(Jr=Jr.slice(o+1)),sy(Zf,Do),x}finally{Ye=i,Ph=!1}}return null}var Mi=[],Di=0,Du=null,Fu=0,Hn=[],Vn=0,Ss=null,Zr=1,Xr="";function js(o,i){Mi[Di++]=Fu,Mi[Di++]=Du,Du=o,Fu=i}function ov(o,i,u){Hn[Vn++]=Zr,Hn[Vn++]=Xr,Hn[Vn++]=Ss,Ss=o;var g=Zr;o=Xr;var x=32-cr(g)-1;g&=~(1<<x),u+=1;var E=32-cr(i)+x;if(30<E){var _=x-x%5;E=(g&(1<<_)-1).toString(32),g>>=_,x-=_,Zr=1<<32-cr(i)+x|u<<x|g,Xr=E+o}else Zr=1<<E|u<<x|g,Xr=o}function Bh(o){o.return!==null&&(js(o,1),ov(o,1,0))}function _h(o){for(;o===Du;)Du=Mi[--Di],Mi[Di]=null,Fu=Mi[--Di],Mi[Di]=null;for(;o===Ss;)Ss=Hn[--Vn],Hn[Vn]=null,Xr=Hn[--Vn],Hn[Vn]=null,Zr=Hn[--Vn],Hn[Vn]=null}var On=null,Rn=null,nt=!1,ur=null;function sv(o,i){var u=Yn(5,null,null,0);u.elementType="DELETED",u.stateNode=i,u.return=o,i=o.deletions,i===null?(o.deletions=[u],o.flags|=16):i.push(u)}function iv(o,i){switch(o.tag){case 5:var u=o.type;return i=i.nodeType!==1||u.toLowerCase()!==i.nodeName.toLowerCase()?null:i,i!==null?(o.stateNode=i,On=o,Rn=Oo(i.firstChild),!0):!1;case 6:return i=o.pendingProps===""||i.nodeType!==3?null:i,i!==null?(o.stateNode=i,On=o,Rn=null,!0):!1;case 13:return i=i.nodeType!==8?null:i,i!==null?(u=Ss!==null?{id:Zr,overflow:Xr}:null,o.memoizedState={dehydrated:i,treeContext:u,retryLane:1073741824},u=Yn(18,null,null,0),u.stateNode=i,u.return=o,o.child=u,On=o,Rn=null,!0):!1;default:return!1}}function Th(o){return(o.mode&1)!==0&&(o.flags&128)===0}function Oh(o){if(nt){var i=Rn;if(i){var u=i;if(!iv(o,i)){if(Th(o))throw Error(n(418));i=Oo(u.nextSibling);var g=On;i&&iv(o,i)?sv(g,u):(o.flags=o.flags&-4097|2,nt=!1,On=o)}}else{if(Th(o))throw Error(n(418));o.flags=o.flags&-4097|2,nt=!1,On=o}}}function av(o){for(o=o.return;o!==null&&o.tag!==5&&o.tag!==3&&o.tag!==13;)o=o.return;On=o}function Lu(o){if(o!==On)return!1;if(!nt)return av(o),nt=!0,!1;var i;if((i=o.tag!==3)&&!(i=o.tag!==5)&&(i=o.type,i=i!=="head"&&i!=="body"&&!kh(o.type,o.memoizedProps)),i&&(i=Rn)){if(Th(o))throw cv(),Error(n(418));for(;i;)sv(o,i),i=Oo(i.nextSibling)}if(av(o),o.tag===13){if(o=o.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(n(317));e:{for(o=o.nextSibling,i=0;o;){if(o.nodeType===8){var u=o.data;if(u==="/$"){if(i===0){Rn=Oo(o.nextSibling);break e}i--}else u!=="$"&&u!=="$!"&&u!=="$?"||i++}o=o.nextSibling}Rn=null}}else Rn=On?Oo(o.stateNode.nextSibling):null;return!0}function cv(){for(var o=Rn;o;)o=Oo(o.nextSibling)}function Fi(){Rn=On=null,nt=!1}function Rh(o){ur===null?ur=[o]:ur.push(o)}var ek=j.ReactCurrentBatchConfig;function wc(o,i,u){if(o=u.ref,o!==null&&typeof o!="function"&&typeof o!="object"){if(u._owner){if(u=u._owner,u){if(u.tag!==1)throw Error(n(309));var g=u.stateNode}if(!g)throw Error(n(147,o));var x=g,E=""+o;return i!==null&&i.ref!==null&&typeof i.ref=="function"&&i.ref._stringRef===E?i.ref:(i=function(_){var M=x.refs;_===null?delete M[E]:M[E]=_},i._stringRef=E,i)}if(typeof o!="string")throw Error(n(284));if(!u._owner)throw Error(n(290,o))}return o}function Uu(o,i){throw o=Object.prototype.toString.call(i),Error(n(31,o==="[object Object]"?"object with keys {"+Object.keys(i).join(", ")+"}":o))}function lv(o){var i=o._init;return i(o._payload)}function uv(o){function i(V,$){if(o){var G=V.deletions;G===null?(V.deletions=[$],V.flags|=16):G.push($)}}function u(V,$){if(!o)return null;for(;$!==null;)i(V,$),$=$.sibling;return null}function g(V,$){for(V=new Map;$!==null;)$.key!==null?V.set($.key,$):V.set($.index,$),$=$.sibling;return V}function x(V,$){return V=Ho(V,$),V.index=0,V.sibling=null,V}function E(V,$,G){return V.index=G,o?(G=V.alternate,G!==null?(G=G.index,G<$?(V.flags|=2,$):G):(V.flags|=2,$)):(V.flags|=1048576,$)}function _(V){return o&&V.alternate===null&&(V.flags|=2),V}function M(V,$,G,ue){return $===null||$.tag!==6?($=S0(G,V.mode,ue),$.return=V,$):($=x($,G),$.return=V,$)}function z(V,$,G,ue){var Ce=G.type;return Ce===B?ie(V,$,G.props.children,ue,G.key):$!==null&&($.elementType===Ce||typeof Ce=="object"&&Ce!==null&&Ce.$$typeof===ee&&lv(Ce)===$.type)?(ue=x($,G.props),ue.ref=wc(V,$,G),ue.return=V,ue):(ue=ud(G.type,G.key,G.props,null,V.mode,ue),ue.ref=wc(V,$,G),ue.return=V,ue)}function J(V,$,G,ue){return $===null||$.tag!==4||$.stateNode.containerInfo!==G.containerInfo||$.stateNode.implementation!==G.implementation?($=j0(G,V.mode,ue),$.return=V,$):($=x($,G.children||[]),$.return=V,$)}function ie(V,$,G,ue,Ce){return $===null||$.tag!==7?($=Rs(G,V.mode,ue,Ce),$.return=V,$):($=x($,G),$.return=V,$)}function ce(V,$,G){if(typeof $=="string"&&$!==""||typeof $=="number")return $=S0(""+$,V.mode,G),$.return=V,$;if(typeof $=="object"&&$!==null){switch($.$$typeof){case N:return G=ud($.type,$.key,$.props,null,V.mode,G),G.ref=wc(V,null,$),G.return=V,G;case T:return $=j0($,V.mode,G),$.return=V,$;case ee:var ue=$._init;return ce(V,ue($._payload),G)}if(It($)||Y($))return $=Rs($,V.mode,G,null),$.return=V,$;Uu(V,$)}return null}function se(V,$,G,ue){var Ce=$!==null?$.key:null;if(typeof G=="string"&&G!==""||typeof G=="number")return Ce!==null?null:M(V,$,""+G,ue);if(typeof G=="object"&&G!==null){switch(G.$$typeof){case N:return G.key===Ce?z(V,$,G,ue):null;case T:return G.key===Ce?J(V,$,G,ue):null;case ee:return Ce=G._init,se(V,$,Ce(G._payload),ue)}if(It(G)||Y(G))return Ce!==null?null:ie(V,$,G,ue,null);Uu(V,G)}return null}function me(V,$,G,ue,Ce){if(typeof ue=="string"&&ue!==""||typeof ue=="number")return V=V.get(G)||null,M($,V,""+ue,Ce);if(typeof ue=="object"&&ue!==null){switch(ue.$$typeof){case N:return V=V.get(ue.key===null?G:ue.key)||null,z($,V,ue,Ce);case T:return V=V.get(ue.key===null?G:ue.key)||null,J($,V,ue,Ce);case ee:var Se=ue._init;return me(V,$,G,Se(ue._payload),Ce)}if(It(ue)||Y(ue))return V=V.get(G)||null,ie($,V,ue,Ce,null);Uu($,ue)}return null}function we(V,$,G,ue){for(var Ce=null,Se=null,je=$,Pe=$=0,Bt=null;je!==null&&Pe<G.length;Pe++){je.index>Pe?(Bt=je,je=null):Bt=je.sibling;var Qe=se(V,je,G[Pe],ue);if(Qe===null){je===null&&(je=Bt);break}o&&je&&Qe.alternate===null&&i(V,je),$=E(Qe,$,Pe),Se===null?Ce=Qe:Se.sibling=Qe,Se=Qe,je=Bt}if(Pe===G.length)return u(V,je),nt&&js(V,Pe),Ce;if(je===null){for(;Pe<G.length;Pe++)je=ce(V,G[Pe],ue),je!==null&&($=E(je,$,Pe),Se===null?Ce=je:Se.sibling=je,Se=je);return nt&&js(V,Pe),Ce}for(je=g(V,je);Pe<G.length;Pe++)Bt=me(je,V,Pe,G[Pe],ue),Bt!==null&&(o&&Bt.alternate!==null&&je.delete(Bt.key===null?Pe:Bt.key),$=E(Bt,$,Pe),Se===null?Ce=Bt:Se.sibling=Bt,Se=Bt);return o&&je.forEach(function(Vo){return i(V,Vo)}),nt&&js(V,Pe),Ce}function be(V,$,G,ue){var Ce=Y(G);if(typeof Ce!="function")throw Error(n(150));if(G=Ce.call(G),G==null)throw Error(n(151));for(var Se=Ce=null,je=$,Pe=$=0,Bt=null,Qe=G.next();je!==null&&!Qe.done;Pe++,Qe=G.next()){je.index>Pe?(Bt=je,je=null):Bt=je.sibling;var Vo=se(V,je,Qe.value,ue);if(Vo===null){je===null&&(je=Bt);break}o&&je&&Vo.alternate===null&&i(V,je),$=E(Vo,$,Pe),Se===null?Ce=Vo:Se.sibling=Vo,Se=Vo,je=Bt}if(Qe.done)return u(V,je),nt&&js(V,Pe),Ce;if(je===null){for(;!Qe.done;Pe++,Qe=G.next())Qe=ce(V,Qe.value,ue),Qe!==null&&($=E(Qe,$,Pe),Se===null?Ce=Qe:Se.sibling=Qe,Se=Qe);return nt&&js(V,Pe),Ce}for(je=g(V,je);!Qe.done;Pe++,Qe=G.next())Qe=me(je,V,Pe,Qe.value,ue),Qe!==null&&(o&&Qe.alternate!==null&&je.delete(Qe.key===null?Pe:Qe.key),$=E(Qe,$,Pe),Se===null?Ce=Qe:Se.sibling=Qe,Se=Qe);return o&&je.forEach(function(Tk){return i(V,Tk)}),nt&&js(V,Pe),Ce}function mt(V,$,G,ue){if(typeof G=="object"&&G!==null&&G.type===B&&G.key===null&&(G=G.props.children),typeof G=="object"&&G!==null){switch(G.$$typeof){case N:e:{for(var Ce=G.key,Se=$;Se!==null;){if(Se.key===Ce){if(Ce=G.type,Ce===B){if(Se.tag===7){u(V,Se.sibling),$=x(Se,G.props.children),$.return=V,V=$;break e}}else if(Se.elementType===Ce||typeof Ce=="object"&&Ce!==null&&Ce.$$typeof===ee&&lv(Ce)===Se.type){u(V,Se.sibling),$=x(Se,G.props),$.ref=wc(V,Se,G),$.return=V,V=$;break e}u(V,Se);break}else i(V,Se);Se=Se.sibling}G.type===B?($=Rs(G.props.children,V.mode,ue,G.key),$.return=V,V=$):(ue=ud(G.type,G.key,G.props,null,V.mode,ue),ue.ref=wc(V,$,G),ue.return=V,V=ue)}return _(V);case T:e:{for(Se=G.key;$!==null;){if($.key===Se)if($.tag===4&&$.stateNode.containerInfo===G.containerInfo&&$.stateNode.implementation===G.implementation){u(V,$.sibling),$=x($,G.children||[]),$.return=V,V=$;break e}else{u(V,$);break}else i(V,$);$=$.sibling}$=j0(G,V.mode,ue),$.return=V,V=$}return _(V);case ee:return Se=G._init,mt(V,$,Se(G._payload),ue)}if(It(G))return we(V,$,G,ue);if(Y(G))return be(V,$,G,ue);Uu(V,G)}return typeof G=="string"&&G!==""||typeof G=="number"?(G=""+G,$!==null&&$.tag===6?(u(V,$.sibling),$=x($,G),$.return=V,V=$):(u(V,$),$=S0(G,V.mode,ue),$.return=V,V=$),_(V)):u(V,$)}return mt}var Li=uv(!0),dv=uv(!1),zu=Ro(null),Wu=null,Ui=null,Mh=null;function Dh(){Mh=Ui=Wu=null}function Fh(o){var i=zu.current;et(zu),o._currentValue=i}function Lh(o,i,u){for(;o!==null;){var g=o.alternate;if((o.childLanes&i)!==i?(o.childLanes|=i,g!==null&&(g.childLanes|=i)):g!==null&&(g.childLanes&i)!==i&&(g.childLanes|=i),o===u)break;o=o.return}}function zi(o,i){Wu=o,Mh=Ui=null,o=o.dependencies,o!==null&&o.firstContext!==null&&((o.lanes&i)!==0&&(pn=!0),o.firstContext=null)}function Qn(o){var i=o._currentValue;if(Mh!==o)if(o={context:o,memoizedValue:i,next:null},Ui===null){if(Wu===null)throw Error(n(308));Ui=o,Wu.dependencies={lanes:0,firstContext:o}}else Ui=Ui.next=o;return i}var Is=null;function Uh(o){Is===null?Is=[o]:Is.push(o)}function fv(o,i,u,g){var x=i.interleaved;return x===null?(u.next=u,Uh(i)):(u.next=x.next,x.next=u),i.interleaved=u,eo(o,g)}function eo(o,i){o.lanes|=i;var u=o.alternate;for(u!==null&&(u.lanes|=i),u=o,o=o.return;o!==null;)o.childLanes|=i,u=o.alternate,u!==null&&(u.childLanes|=i),u=o,o=o.return;return u.tag===3?u.stateNode:null}var Fo=!1;function zh(o){o.updateQueue={baseState:o.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function hv(o,i){o=o.updateQueue,i.updateQueue===o&&(i.updateQueue={baseState:o.baseState,firstBaseUpdate:o.firstBaseUpdate,lastBaseUpdate:o.lastBaseUpdate,shared:o.shared,effects:o.effects})}function to(o,i){return{eventTime:o,lane:i,tag:0,payload:null,callback:null,next:null}}function Lo(o,i,u){var g=o.updateQueue;if(g===null)return null;if(g=g.shared,(qe&2)!==0){var x=g.pending;return x===null?i.next=i:(i.next=x.next,x.next=i),g.pending=i,eo(o,u)}return x=g.interleaved,x===null?(i.next=i,Uh(g)):(i.next=x.next,x.next=i),g.interleaved=i,eo(o,u)}function $u(o,i,u){if(i=i.updateQueue,i!==null&&(i=i.shared,(u&4194240)!==0)){var g=i.lanes;g&=o.pendingLanes,u|=g,i.lanes=u,th(o,u)}}function pv(o,i){var u=o.updateQueue,g=o.alternate;if(g!==null&&(g=g.updateQueue,u===g)){var x=null,E=null;if(u=u.firstBaseUpdate,u!==null){do{var _={eventTime:u.eventTime,lane:u.lane,tag:u.tag,payload:u.payload,callback:u.callback,next:null};E===null?x=E=_:E=E.next=_,u=u.next}while(u!==null);E===null?x=E=i:E=E.next=i}else x=E=i;u={baseState:g.baseState,firstBaseUpdate:x,lastBaseUpdate:E,shared:g.shared,effects:g.effects},o.updateQueue=u;return}o=u.lastBaseUpdate,o===null?u.firstBaseUpdate=i:o.next=i,u.lastBaseUpdate=i}function qu(o,i,u,g){var x=o.updateQueue;Fo=!1;var E=x.firstBaseUpdate,_=x.lastBaseUpdate,M=x.shared.pending;if(M!==null){x.shared.pending=null;var z=M,J=z.next;z.next=null,_===null?E=J:_.next=J,_=z;var ie=o.alternate;ie!==null&&(ie=ie.updateQueue,M=ie.lastBaseUpdate,M!==_&&(M===null?ie.firstBaseUpdate=J:M.next=J,ie.lastBaseUpdate=z))}if(E!==null){var ce=x.baseState;_=0,ie=J=z=null,M=E;do{var se=M.lane,me=M.eventTime;if((g&se)===se){ie!==null&&(ie=ie.next={eventTime:me,lane:0,tag:M.tag,payload:M.payload,callback:M.callback,next:null});e:{var we=o,be=M;switch(se=i,me=u,be.tag){case 1:if(we=be.payload,typeof we=="function"){ce=we.call(me,ce,se);break e}ce=we;break e;case 3:we.flags=we.flags&-65537|128;case 0:if(we=be.payload,se=typeof we=="function"?we.call(me,ce,se):we,se==null)break e;ce=Z({},ce,se);break e;case 2:Fo=!0}}M.callback!==null&&M.lane!==0&&(o.flags|=64,se=x.effects,se===null?x.effects=[M]:se.push(M))}else me={eventTime:me,lane:se,tag:M.tag,payload:M.payload,callback:M.callback,next:null},ie===null?(J=ie=me,z=ce):ie=ie.next=me,_|=se;if(M=M.next,M===null){if(M=x.shared.pending,M===null)break;se=M,M=se.next,se.next=null,x.lastBaseUpdate=se,x.shared.pending=null}}while(!0);if(ie===null&&(z=ce),x.baseState=z,x.firstBaseUpdate=J,x.lastBaseUpdate=ie,i=x.shared.interleaved,i!==null){x=i;do _|=x.lane,x=x.next;while(x!==i)}else E===null&&(x.shared.lanes=0);Bs|=_,o.lanes=_,o.memoizedState=ce}}function mv(o,i,u){if(o=i.effects,i.effects=null,o!==null)for(i=0;i<o.length;i++){var g=o[i],x=g.callback;if(x!==null){if(g.callback=null,g=u,typeof x!="function")throw Error(n(191,x));x.call(g)}}}var bc={},Br=Ro(bc),xc=Ro(bc),Cc=Ro(bc);function Ns(o){if(o===bc)throw Error(n(174));return o}function Wh(o,i){switch(Je(Cc,i),Je(xc,o),Je(Br,bc),o=i.nodeType,o){case 9:case 11:i=(i=i.documentElement)?i.namespaceURI:Nn(null,"");break;default:o=o===8?i.parentNode:i,i=o.namespaceURI||null,o=o.tagName,i=Nn(i,o)}et(Br),Je(Br,i)}function Wi(){et(Br),et(xc),et(Cc)}function gv(o){Ns(Cc.current);var i=Ns(Br.current),u=Nn(i,o.type);i!==u&&(Je(xc,o),Je(Br,u))}function $h(o){xc.current===o&&(et(Br),et(xc))}var ot=Ro(0);function Hu(o){for(var i=o;i!==null;){if(i.tag===13){var u=i.memoizedState;if(u!==null&&(u=u.dehydrated,u===null||u.data==="$?"||u.data==="$!"))return i}else if(i.tag===19&&i.memoizedProps.revealOrder!==void 0){if((i.flags&128)!==0)return i}else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===o)break;for(;i.sibling===null;){if(i.return===null||i.return===o)return null;i=i.return}i.sibling.return=i.return,i=i.sibling}return null}var qh=[];function Hh(){for(var o=0;o<qh.length;o++)qh[o]._workInProgressVersionPrimary=null;qh.length=0}var Vu=j.ReactCurrentDispatcher,Vh=j.ReactCurrentBatchConfig,Ps=0,st=null,At=null,Nt=null,Qu=!1,Ec=!1,Ac=0,tk=0;function Ht(){throw Error(n(321))}function Qh(o,i){if(i===null)return!1;for(var u=0;u<i.length&&u<o.length;u++)if(!lr(o[u],i[u]))return!1;return!0}function Gh(o,i,u,g,x,E){if(Ps=E,st=i,i.memoizedState=null,i.updateQueue=null,i.lanes=0,Vu.current=o===null||o.memoizedState===null?sk:ik,o=u(g,x),Ec){E=0;do{if(Ec=!1,Ac=0,25<=E)throw Error(n(301));E+=1,Nt=At=null,i.updateQueue=null,Vu.current=ak,o=u(g,x)}while(Ec)}if(Vu.current=Yu,i=At!==null&&At.next!==null,Ps=0,Nt=At=st=null,Qu=!1,i)throw Error(n(300));return o}function Kh(){var o=Ac!==0;return Ac=0,o}function _r(){var o={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Nt===null?st.memoizedState=Nt=o:Nt=Nt.next=o,Nt}function Gn(){if(At===null){var o=st.alternate;o=o!==null?o.memoizedState:null}else o=At.next;var i=Nt===null?st.memoizedState:Nt.next;if(i!==null)Nt=i,At=o;else{if(o===null)throw Error(n(310));At=o,o={memoizedState:At.memoizedState,baseState:At.baseState,baseQueue:At.baseQueue,queue:At.queue,next:null},Nt===null?st.memoizedState=Nt=o:Nt=Nt.next=o}return Nt}function kc(o,i){return typeof i=="function"?i(o):i}function Yh(o){var i=Gn(),u=i.queue;if(u===null)throw Error(n(311));u.lastRenderedReducer=o;var g=At,x=g.baseQueue,E=u.pending;if(E!==null){if(x!==null){var _=x.next;x.next=E.next,E.next=_}g.baseQueue=x=E,u.pending=null}if(x!==null){E=x.next,g=g.baseState;var M=_=null,z=null,J=E;do{var ie=J.lane;if((Ps&ie)===ie)z!==null&&(z=z.next={lane:0,action:J.action,hasEagerState:J.hasEagerState,eagerState:J.eagerState,next:null}),g=J.hasEagerState?J.eagerState:o(g,J.action);else{var ce={lane:ie,action:J.action,hasEagerState:J.hasEagerState,eagerState:J.eagerState,next:null};z===null?(M=z=ce,_=g):z=z.next=ce,st.lanes|=ie,Bs|=ie}J=J.next}while(J!==null&&J!==E);z===null?_=g:z.next=M,lr(g,i.memoizedState)||(pn=!0),i.memoizedState=g,i.baseState=_,i.baseQueue=z,u.lastRenderedState=g}if(o=u.interleaved,o!==null){x=o;do E=x.lane,st.lanes|=E,Bs|=E,x=x.next;while(x!==o)}else x===null&&(u.lanes=0);return[i.memoizedState,u.dispatch]}function Jh(o){var i=Gn(),u=i.queue;if(u===null)throw Error(n(311));u.lastRenderedReducer=o;var g=u.dispatch,x=u.pending,E=i.memoizedState;if(x!==null){u.pending=null;var _=x=x.next;do E=o(E,_.action),_=_.next;while(_!==x);lr(E,i.memoizedState)||(pn=!0),i.memoizedState=E,i.baseQueue===null&&(i.baseState=E),u.lastRenderedState=E}return[E,g]}function yv(){}function vv(o,i){var u=st,g=Gn(),x=i(),E=!lr(g.memoizedState,x);if(E&&(g.memoizedState=x,pn=!0),g=g.queue,Zh(xv.bind(null,u,g,o),[o]),g.getSnapshot!==i||E||Nt!==null&&Nt.memoizedState.tag&1){if(u.flags|=2048,Sc(9,bv.bind(null,u,g,x,i),void 0,null),Pt===null)throw Error(n(349));(Ps&30)!==0||wv(u,i,x)}return x}function wv(o,i,u){o.flags|=16384,o={getSnapshot:i,value:u},i=st.updateQueue,i===null?(i={lastEffect:null,stores:null},st.updateQueue=i,i.stores=[o]):(u=i.stores,u===null?i.stores=[o]:u.push(o))}function bv(o,i,u,g){i.value=u,i.getSnapshot=g,Cv(i)&&Ev(o)}function xv(o,i,u){return u(function(){Cv(i)&&Ev(o)})}function Cv(o){var i=o.getSnapshot;o=o.value;try{var u=i();return!lr(o,u)}catch{return!0}}function Ev(o){var i=eo(o,1);i!==null&&pr(i,o,1,-1)}function Av(o){var i=_r();return typeof o=="function"&&(o=o()),i.memoizedState=i.baseState=o,o={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:kc,lastRenderedState:o},i.queue=o,o=o.dispatch=ok.bind(null,st,o),[i.memoizedState,o]}function Sc(o,i,u,g){return o={tag:o,create:i,destroy:u,deps:g,next:null},i=st.updateQueue,i===null?(i={lastEffect:null,stores:null},st.updateQueue=i,i.lastEffect=o.next=o):(u=i.lastEffect,u===null?i.lastEffect=o.next=o:(g=u.next,u.next=o,o.next=g,i.lastEffect=o)),o}function kv(){return Gn().memoizedState}function Gu(o,i,u,g){var x=_r();st.flags|=o,x.memoizedState=Sc(1|i,u,void 0,g===void 0?null:g)}function Ku(o,i,u,g){var x=Gn();g=g===void 0?null:g;var E=void 0;if(At!==null){var _=At.memoizedState;if(E=_.destroy,g!==null&&Qh(g,_.deps)){x.memoizedState=Sc(i,u,E,g);return}}st.flags|=o,x.memoizedState=Sc(1|i,u,E,g)}function Sv(o,i){return Gu(8390656,8,o,i)}function Zh(o,i){return Ku(2048,8,o,i)}function jv(o,i){return Ku(4,2,o,i)}function Iv(o,i){return Ku(4,4,o,i)}function Nv(o,i){if(typeof i=="function")return o=o(),i(o),function(){i(null)};if(i!=null)return o=o(),i.current=o,function(){i.current=null}}function Pv(o,i,u){return u=u!=null?u.concat([o]):null,Ku(4,4,Nv.bind(null,i,o),u)}function Xh(){}function Bv(o,i){var u=Gn();i=i===void 0?null:i;var g=u.memoizedState;return g!==null&&i!==null&&Qh(i,g[1])?g[0]:(u.memoizedState=[o,i],o)}function _v(o,i){var u=Gn();i=i===void 0?null:i;var g=u.memoizedState;return g!==null&&i!==null&&Qh(i,g[1])?g[0]:(o=o(),u.memoizedState=[o,i],o)}function Tv(o,i,u){return(Ps&21)===0?(o.baseState&&(o.baseState=!1,pn=!0),o.memoizedState=u):(lr(u,i)||(u=ly(),st.lanes|=u,Bs|=u,o.baseState=!0),i)}function nk(o,i){var u=Ye;Ye=u!==0&&4>u?u:4,o(!0);var g=Vh.transition;Vh.transition={};try{o(!1),i()}finally{Ye=u,Vh.transition=g}}function Ov(){return Gn().memoizedState}function rk(o,i,u){var g=$o(o);if(u={lane:g,action:u,hasEagerState:!1,eagerState:null,next:null},Rv(o))Mv(i,u);else if(u=fv(o,i,u,g),u!==null){var x=tn();pr(u,o,g,x),Dv(u,i,g)}}function ok(o,i,u){var g=$o(o),x={lane:g,action:u,hasEagerState:!1,eagerState:null,next:null};if(Rv(o))Mv(i,x);else{var E=o.alternate;if(o.lanes===0&&(E===null||E.lanes===0)&&(E=i.lastRenderedReducer,E!==null))try{var _=i.lastRenderedState,M=E(_,u);if(x.hasEagerState=!0,x.eagerState=M,lr(M,_)){var z=i.interleaved;z===null?(x.next=x,Uh(i)):(x.next=z.next,z.next=x),i.interleaved=x;return}}catch{}finally{}u=fv(o,i,x,g),u!==null&&(x=tn(),pr(u,o,g,x),Dv(u,i,g))}}function Rv(o){var i=o.alternate;return o===st||i!==null&&i===st}function Mv(o,i){Ec=Qu=!0;var u=o.pending;u===null?i.next=i:(i.next=u.next,u.next=i),o.pending=i}function Dv(o,i,u){if((u&4194240)!==0){var g=i.lanes;g&=o.pendingLanes,u|=g,i.lanes=u,th(o,u)}}var Yu={readContext:Qn,useCallback:Ht,useContext:Ht,useEffect:Ht,useImperativeHandle:Ht,useInsertionEffect:Ht,useLayoutEffect:Ht,useMemo:Ht,useReducer:Ht,useRef:Ht,useState:Ht,useDebugValue:Ht,useDeferredValue:Ht,useTransition:Ht,useMutableSource:Ht,useSyncExternalStore:Ht,useId:Ht,unstable_isNewReconciler:!1},sk={readContext:Qn,useCallback:function(o,i){return _r().memoizedState=[o,i===void 0?null:i],o},useContext:Qn,useEffect:Sv,useImperativeHandle:function(o,i,u){return u=u!=null?u.concat([o]):null,Gu(4194308,4,Nv.bind(null,i,o),u)},useLayoutEffect:function(o,i){return Gu(4194308,4,o,i)},useInsertionEffect:function(o,i){return Gu(4,2,o,i)},useMemo:function(o,i){var u=_r();return i=i===void 0?null:i,o=o(),u.memoizedState=[o,i],o},useReducer:function(o,i,u){var g=_r();return i=u!==void 0?u(i):i,g.memoizedState=g.baseState=i,o={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:o,lastRenderedState:i},g.queue=o,o=o.dispatch=rk.bind(null,st,o),[g.memoizedState,o]},useRef:function(o){var i=_r();return o={current:o},i.memoizedState=o},useState:Av,useDebugValue:Xh,useDeferredValue:function(o){return _r().memoizedState=o},useTransition:function(){var o=Av(!1),i=o[0];return o=nk.bind(null,o[1]),_r().memoizedState=o,[i,o]},useMutableSource:function(){},useSyncExternalStore:function(o,i,u){var g=st,x=_r();if(nt){if(u===void 0)throw Error(n(407));u=u()}else{if(u=i(),Pt===null)throw Error(n(349));(Ps&30)!==0||wv(g,i,u)}x.memoizedState=u;var E={value:u,getSnapshot:i};return x.queue=E,Sv(xv.bind(null,g,E,o),[o]),g.flags|=2048,Sc(9,bv.bind(null,g,E,u,i),void 0,null),u},useId:function(){var o=_r(),i=Pt.identifierPrefix;if(nt){var u=Xr,g=Zr;u=(g&~(1<<32-cr(g)-1)).toString(32)+u,i=":"+i+"R"+u,u=Ac++,0<u&&(i+="H"+u.toString(32)),i+=":"}else u=tk++,i=":"+i+"r"+u.toString(32)+":";return o.memoizedState=i},unstable_isNewReconciler:!1},ik={readContext:Qn,useCallback:Bv,useContext:Qn,useEffect:Zh,useImperativeHandle:Pv,useInsertionEffect:jv,useLayoutEffect:Iv,useMemo:_v,useReducer:Yh,useRef:kv,useState:function(){return Yh(kc)},useDebugValue:Xh,useDeferredValue:function(o){var i=Gn();return Tv(i,At.memoizedState,o)},useTransition:function(){var o=Yh(kc)[0],i=Gn().memoizedState;return[o,i]},useMutableSource:yv,useSyncExternalStore:vv,useId:Ov,unstable_isNewReconciler:!1},ak={readContext:Qn,useCallback:Bv,useContext:Qn,useEffect:Zh,useImperativeHandle:Pv,useInsertionEffect:jv,useLayoutEffect:Iv,useMemo:_v,useReducer:Jh,useRef:kv,useState:function(){return Jh(kc)},useDebugValue:Xh,useDeferredValue:function(o){var i=Gn();return At===null?i.memoizedState=o:Tv(i,At.memoizedState,o)},useTransition:function(){var o=Jh(kc)[0],i=Gn().memoizedState;return[o,i]},useMutableSource:yv,useSyncExternalStore:vv,useId:Ov,unstable_isNewReconciler:!1};function dr(o,i){if(o&&o.defaultProps){i=Z({},i),o=o.defaultProps;for(var u in o)i[u]===void 0&&(i[u]=o[u]);return i}return i}function e0(o,i,u,g){i=o.memoizedState,u=u(g,i),u=u==null?i:Z({},i,u),o.memoizedState=u,o.lanes===0&&(o.updateQueue.baseState=u)}var Ju={isMounted:function(o){return(o=o._reactInternals)?Es(o)===o:!1},enqueueSetState:function(o,i,u){o=o._reactInternals;var g=tn(),x=$o(o),E=to(g,x);E.payload=i,u!=null&&(E.callback=u),i=Lo(o,E,x),i!==null&&(pr(i,o,x,g),$u(i,o,x))},enqueueReplaceState:function(o,i,u){o=o._reactInternals;var g=tn(),x=$o(o),E=to(g,x);E.tag=1,E.payload=i,u!=null&&(E.callback=u),i=Lo(o,E,x),i!==null&&(pr(i,o,x,g),$u(i,o,x))},enqueueForceUpdate:function(o,i){o=o._reactInternals;var u=tn(),g=$o(o),x=to(u,g);x.tag=2,i!=null&&(x.callback=i),i=Lo(o,x,g),i!==null&&(pr(i,o,g,u),$u(i,o,g))}};function Fv(o,i,u,g,x,E,_){return o=o.stateNode,typeof o.shouldComponentUpdate=="function"?o.shouldComponentUpdate(g,E,_):i.prototype&&i.prototype.isPureReactComponent?!fc(u,g)||!fc(x,E):!0}function Lv(o,i,u){var g=!1,x=Mo,E=i.contextType;return typeof E=="object"&&E!==null?E=Qn(E):(x=hn(i)?ks:qt.current,g=i.contextTypes,E=(g=g!=null)?Ri(o,x):Mo),i=new i(u,E),o.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=Ju,o.stateNode=i,i._reactInternals=o,g&&(o=o.stateNode,o.__reactInternalMemoizedUnmaskedChildContext=x,o.__reactInternalMemoizedMaskedChildContext=E),i}function Uv(o,i,u,g){o=i.state,typeof i.componentWillReceiveProps=="function"&&i.componentWillReceiveProps(u,g),typeof i.UNSAFE_componentWillReceiveProps=="function"&&i.UNSAFE_componentWillReceiveProps(u,g),i.state!==o&&Ju.enqueueReplaceState(i,i.state,null)}function t0(o,i,u,g){var x=o.stateNode;x.props=u,x.state=o.memoizedState,x.refs={},zh(o);var E=i.contextType;typeof E=="object"&&E!==null?x.context=Qn(E):(E=hn(i)?ks:qt.current,x.context=Ri(o,E)),x.state=o.memoizedState,E=i.getDerivedStateFromProps,typeof E=="function"&&(e0(o,i,E,u),x.state=o.memoizedState),typeof i.getDerivedStateFromProps=="function"||typeof x.getSnapshotBeforeUpdate=="function"||typeof x.UNSAFE_componentWillMount!="function"&&typeof x.componentWillMount!="function"||(i=x.state,typeof x.componentWillMount=="function"&&x.componentWillMount(),typeof x.UNSAFE_componentWillMount=="function"&&x.UNSAFE_componentWillMount(),i!==x.state&&Ju.enqueueReplaceState(x,x.state,null),qu(o,u,x,g),x.state=o.memoizedState),typeof x.componentDidMount=="function"&&(o.flags|=4194308)}function $i(o,i){try{var u="",g=i;do u+=oe(g),g=g.return;while(g);var x=u}catch(E){x=`
40
- Error generating stack: `+E.message+`
41
- `+E.stack}return{value:o,source:i,stack:x,digest:null}}function n0(o,i,u){return{value:o,source:null,stack:u??null,digest:i??null}}function r0(o,i){try{console.error(i.value)}catch(u){setTimeout(function(){throw u})}}var ck=typeof WeakMap=="function"?WeakMap:Map;function zv(o,i,u){u=to(-1,u),u.tag=3,u.payload={element:null};var g=i.value;return u.callback=function(){od||(od=!0,v0=g),r0(o,i)},u}function Wv(o,i,u){u=to(-1,u),u.tag=3;var g=o.type.getDerivedStateFromError;if(typeof g=="function"){var x=i.value;u.payload=function(){return g(x)},u.callback=function(){r0(o,i)}}var E=o.stateNode;return E!==null&&typeof E.componentDidCatch=="function"&&(u.callback=function(){r0(o,i),typeof g!="function"&&(zo===null?zo=new Set([this]):zo.add(this));var _=i.stack;this.componentDidCatch(i.value,{componentStack:_!==null?_:""})}),u}function $v(o,i,u){var g=o.pingCache;if(g===null){g=o.pingCache=new ck;var x=new Set;g.set(i,x)}else x=g.get(i),x===void 0&&(x=new Set,g.set(i,x));x.has(u)||(x.add(u),o=Ck.bind(null,o,i,u),i.then(o,o))}function qv(o){do{var i;if((i=o.tag===13)&&(i=o.memoizedState,i=i!==null?i.dehydrated!==null:!0),i)return o;o=o.return}while(o!==null);return null}function Hv(o,i,u,g,x){return(o.mode&1)===0?(o===i?o.flags|=65536:(o.flags|=128,u.flags|=131072,u.flags&=-52805,u.tag===1&&(u.alternate===null?u.tag=17:(i=to(-1,1),i.tag=2,Lo(u,i,1))),u.lanes|=1),o):(o.flags|=65536,o.lanes=x,o)}var lk=j.ReactCurrentOwner,pn=!1;function en(o,i,u,g){i.child=o===null?dv(i,null,u,g):Li(i,o.child,u,g)}function Vv(o,i,u,g,x){u=u.render;var E=i.ref;return zi(i,x),g=Gh(o,i,u,g,E,x),u=Kh(),o!==null&&!pn?(i.updateQueue=o.updateQueue,i.flags&=-2053,o.lanes&=~x,no(o,i,x)):(nt&&u&&Bh(i),i.flags|=1,en(o,i,g,x),i.child)}function Qv(o,i,u,g,x){if(o===null){var E=u.type;return typeof E=="function"&&!k0(E)&&E.defaultProps===void 0&&u.compare===null&&u.defaultProps===void 0?(i.tag=15,i.type=E,Gv(o,i,E,g,x)):(o=ud(u.type,null,g,i,i.mode,x),o.ref=i.ref,o.return=i,i.child=o)}if(E=o.child,(o.lanes&x)===0){var _=E.memoizedProps;if(u=u.compare,u=u!==null?u:fc,u(_,g)&&o.ref===i.ref)return no(o,i,x)}return i.flags|=1,o=Ho(E,g),o.ref=i.ref,o.return=i,i.child=o}function Gv(o,i,u,g,x){if(o!==null){var E=o.memoizedProps;if(fc(E,g)&&o.ref===i.ref)if(pn=!1,i.pendingProps=g=E,(o.lanes&x)!==0)(o.flags&131072)!==0&&(pn=!0);else return i.lanes=o.lanes,no(o,i,x)}return o0(o,i,u,g,x)}function Kv(o,i,u){var g=i.pendingProps,x=g.children,E=o!==null?o.memoizedState:null;if(g.mode==="hidden")if((i.mode&1)===0)i.memoizedState={baseLanes:0,cachePool:null,transitions:null},Je(Hi,Mn),Mn|=u;else{if((u&1073741824)===0)return o=E!==null?E.baseLanes|u:u,i.lanes=i.childLanes=1073741824,i.memoizedState={baseLanes:o,cachePool:null,transitions:null},i.updateQueue=null,Je(Hi,Mn),Mn|=o,null;i.memoizedState={baseLanes:0,cachePool:null,transitions:null},g=E!==null?E.baseLanes:u,Je(Hi,Mn),Mn|=g}else E!==null?(g=E.baseLanes|u,i.memoizedState=null):g=u,Je(Hi,Mn),Mn|=g;return en(o,i,x,u),i.child}function Yv(o,i){var u=i.ref;(o===null&&u!==null||o!==null&&o.ref!==u)&&(i.flags|=512,i.flags|=2097152)}function o0(o,i,u,g,x){var E=hn(u)?ks:qt.current;return E=Ri(i,E),zi(i,x),u=Gh(o,i,u,g,E,x),g=Kh(),o!==null&&!pn?(i.updateQueue=o.updateQueue,i.flags&=-2053,o.lanes&=~x,no(o,i,x)):(nt&&g&&Bh(i),i.flags|=1,en(o,i,u,x),i.child)}function Jv(o,i,u,g,x){if(hn(u)){var E=!0;Ru(i)}else E=!1;if(zi(i,x),i.stateNode===null)Xu(o,i),Lv(i,u,g),t0(i,u,g,x),g=!0;else if(o===null){var _=i.stateNode,M=i.memoizedProps;_.props=M;var z=_.context,J=u.contextType;typeof J=="object"&&J!==null?J=Qn(J):(J=hn(u)?ks:qt.current,J=Ri(i,J));var ie=u.getDerivedStateFromProps,ce=typeof ie=="function"||typeof _.getSnapshotBeforeUpdate=="function";ce||typeof _.UNSAFE_componentWillReceiveProps!="function"&&typeof _.componentWillReceiveProps!="function"||(M!==g||z!==J)&&Uv(i,_,g,J),Fo=!1;var se=i.memoizedState;_.state=se,qu(i,g,_,x),z=i.memoizedState,M!==g||se!==z||fn.current||Fo?(typeof ie=="function"&&(e0(i,u,ie,g),z=i.memoizedState),(M=Fo||Fv(i,u,M,g,se,z,J))?(ce||typeof _.UNSAFE_componentWillMount!="function"&&typeof _.componentWillMount!="function"||(typeof _.componentWillMount=="function"&&_.componentWillMount(),typeof _.UNSAFE_componentWillMount=="function"&&_.UNSAFE_componentWillMount()),typeof _.componentDidMount=="function"&&(i.flags|=4194308)):(typeof _.componentDidMount=="function"&&(i.flags|=4194308),i.memoizedProps=g,i.memoizedState=z),_.props=g,_.state=z,_.context=J,g=M):(typeof _.componentDidMount=="function"&&(i.flags|=4194308),g=!1)}else{_=i.stateNode,hv(o,i),M=i.memoizedProps,J=i.type===i.elementType?M:dr(i.type,M),_.props=J,ce=i.pendingProps,se=_.context,z=u.contextType,typeof z=="object"&&z!==null?z=Qn(z):(z=hn(u)?ks:qt.current,z=Ri(i,z));var me=u.getDerivedStateFromProps;(ie=typeof me=="function"||typeof _.getSnapshotBeforeUpdate=="function")||typeof _.UNSAFE_componentWillReceiveProps!="function"&&typeof _.componentWillReceiveProps!="function"||(M!==ce||se!==z)&&Uv(i,_,g,z),Fo=!1,se=i.memoizedState,_.state=se,qu(i,g,_,x);var we=i.memoizedState;M!==ce||se!==we||fn.current||Fo?(typeof me=="function"&&(e0(i,u,me,g),we=i.memoizedState),(J=Fo||Fv(i,u,J,g,se,we,z)||!1)?(ie||typeof _.UNSAFE_componentWillUpdate!="function"&&typeof _.componentWillUpdate!="function"||(typeof _.componentWillUpdate=="function"&&_.componentWillUpdate(g,we,z),typeof _.UNSAFE_componentWillUpdate=="function"&&_.UNSAFE_componentWillUpdate(g,we,z)),typeof _.componentDidUpdate=="function"&&(i.flags|=4),typeof _.getSnapshotBeforeUpdate=="function"&&(i.flags|=1024)):(typeof _.componentDidUpdate!="function"||M===o.memoizedProps&&se===o.memoizedState||(i.flags|=4),typeof _.getSnapshotBeforeUpdate!="function"||M===o.memoizedProps&&se===o.memoizedState||(i.flags|=1024),i.memoizedProps=g,i.memoizedState=we),_.props=g,_.state=we,_.context=z,g=J):(typeof _.componentDidUpdate!="function"||M===o.memoizedProps&&se===o.memoizedState||(i.flags|=4),typeof _.getSnapshotBeforeUpdate!="function"||M===o.memoizedProps&&se===o.memoizedState||(i.flags|=1024),g=!1)}return s0(o,i,u,g,E,x)}function s0(o,i,u,g,x,E){Yv(o,i);var _=(i.flags&128)!==0;if(!g&&!_)return x&&nv(i,u,!1),no(o,i,E);g=i.stateNode,lk.current=i;var M=_&&typeof u.getDerivedStateFromError!="function"?null:g.render();return i.flags|=1,o!==null&&_?(i.child=Li(i,o.child,null,E),i.child=Li(i,null,M,E)):en(o,i,M,E),i.memoizedState=g.state,x&&nv(i,u,!0),i.child}function Zv(o){var i=o.stateNode;i.pendingContext?ev(o,i.pendingContext,i.pendingContext!==i.context):i.context&&ev(o,i.context,!1),Wh(o,i.containerInfo)}function Xv(o,i,u,g,x){return Fi(),Rh(x),i.flags|=256,en(o,i,u,g),i.child}var i0={dehydrated:null,treeContext:null,retryLane:0};function a0(o){return{baseLanes:o,cachePool:null,transitions:null}}function ew(o,i,u){var g=i.pendingProps,x=ot.current,E=!1,_=(i.flags&128)!==0,M;if((M=_)||(M=o!==null&&o.memoizedState===null?!1:(x&2)!==0),M?(E=!0,i.flags&=-129):(o===null||o.memoizedState!==null)&&(x|=1),Je(ot,x&1),o===null)return Oh(i),o=i.memoizedState,o!==null&&(o=o.dehydrated,o!==null)?((i.mode&1)===0?i.lanes=1:o.data==="$!"?i.lanes=8:i.lanes=1073741824,null):(_=g.children,o=g.fallback,E?(g=i.mode,E=i.child,_={mode:"hidden",children:_},(g&1)===0&&E!==null?(E.childLanes=0,E.pendingProps=_):E=dd(_,g,0,null),o=Rs(o,g,u,null),E.return=i,o.return=i,E.sibling=o,i.child=E,i.child.memoizedState=a0(u),i.memoizedState=i0,o):c0(i,_));if(x=o.memoizedState,x!==null&&(M=x.dehydrated,M!==null))return uk(o,i,_,g,M,x,u);if(E){E=g.fallback,_=i.mode,x=o.child,M=x.sibling;var z={mode:"hidden",children:g.children};return(_&1)===0&&i.child!==x?(g=i.child,g.childLanes=0,g.pendingProps=z,i.deletions=null):(g=Ho(x,z),g.subtreeFlags=x.subtreeFlags&14680064),M!==null?E=Ho(M,E):(E=Rs(E,_,u,null),E.flags|=2),E.return=i,g.return=i,g.sibling=E,i.child=g,g=E,E=i.child,_=o.child.memoizedState,_=_===null?a0(u):{baseLanes:_.baseLanes|u,cachePool:null,transitions:_.transitions},E.memoizedState=_,E.childLanes=o.childLanes&~u,i.memoizedState=i0,g}return E=o.child,o=E.sibling,g=Ho(E,{mode:"visible",children:g.children}),(i.mode&1)===0&&(g.lanes=u),g.return=i,g.sibling=null,o!==null&&(u=i.deletions,u===null?(i.deletions=[o],i.flags|=16):u.push(o)),i.child=g,i.memoizedState=null,g}function c0(o,i){return i=dd({mode:"visible",children:i},o.mode,0,null),i.return=o,o.child=i}function Zu(o,i,u,g){return g!==null&&Rh(g),Li(i,o.child,null,u),o=c0(i,i.pendingProps.children),o.flags|=2,i.memoizedState=null,o}function uk(o,i,u,g,x,E,_){if(u)return i.flags&256?(i.flags&=-257,g=n0(Error(n(422))),Zu(o,i,_,g)):i.memoizedState!==null?(i.child=o.child,i.flags|=128,null):(E=g.fallback,x=i.mode,g=dd({mode:"visible",children:g.children},x,0,null),E=Rs(E,x,_,null),E.flags|=2,g.return=i,E.return=i,g.sibling=E,i.child=g,(i.mode&1)!==0&&Li(i,o.child,null,_),i.child.memoizedState=a0(_),i.memoizedState=i0,E);if((i.mode&1)===0)return Zu(o,i,_,null);if(x.data==="$!"){if(g=x.nextSibling&&x.nextSibling.dataset,g)var M=g.dgst;return g=M,E=Error(n(419)),g=n0(E,g,void 0),Zu(o,i,_,g)}if(M=(_&o.childLanes)!==0,pn||M){if(g=Pt,g!==null){switch(_&-_){case 4:x=2;break;case 16:x=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:x=32;break;case 536870912:x=268435456;break;default:x=0}x=(x&(g.suspendedLanes|_))!==0?0:x,x!==0&&x!==E.retryLane&&(E.retryLane=x,eo(o,x),pr(g,o,x,-1))}return A0(),g=n0(Error(n(421))),Zu(o,i,_,g)}return x.data==="$?"?(i.flags|=128,i.child=o.child,i=Ek.bind(null,o),x._reactRetry=i,null):(o=E.treeContext,Rn=Oo(x.nextSibling),On=i,nt=!0,ur=null,o!==null&&(Hn[Vn++]=Zr,Hn[Vn++]=Xr,Hn[Vn++]=Ss,Zr=o.id,Xr=o.overflow,Ss=i),i=c0(i,g.children),i.flags|=4096,i)}function tw(o,i,u){o.lanes|=i;var g=o.alternate;g!==null&&(g.lanes|=i),Lh(o.return,i,u)}function l0(o,i,u,g,x){var E=o.memoizedState;E===null?o.memoizedState={isBackwards:i,rendering:null,renderingStartTime:0,last:g,tail:u,tailMode:x}:(E.isBackwards=i,E.rendering=null,E.renderingStartTime=0,E.last=g,E.tail=u,E.tailMode=x)}function nw(o,i,u){var g=i.pendingProps,x=g.revealOrder,E=g.tail;if(en(o,i,g.children,u),g=ot.current,(g&2)!==0)g=g&1|2,i.flags|=128;else{if(o!==null&&(o.flags&128)!==0)e:for(o=i.child;o!==null;){if(o.tag===13)o.memoizedState!==null&&tw(o,u,i);else if(o.tag===19)tw(o,u,i);else if(o.child!==null){o.child.return=o,o=o.child;continue}if(o===i)break e;for(;o.sibling===null;){if(o.return===null||o.return===i)break e;o=o.return}o.sibling.return=o.return,o=o.sibling}g&=1}if(Je(ot,g),(i.mode&1)===0)i.memoizedState=null;else switch(x){case"forwards":for(u=i.child,x=null;u!==null;)o=u.alternate,o!==null&&Hu(o)===null&&(x=u),u=u.sibling;u=x,u===null?(x=i.child,i.child=null):(x=u.sibling,u.sibling=null),l0(i,!1,x,u,E);break;case"backwards":for(u=null,x=i.child,i.child=null;x!==null;){if(o=x.alternate,o!==null&&Hu(o)===null){i.child=x;break}o=x.sibling,x.sibling=u,u=x,x=o}l0(i,!0,u,null,E);break;case"together":l0(i,!1,null,null,void 0);break;default:i.memoizedState=null}return i.child}function Xu(o,i){(i.mode&1)===0&&o!==null&&(o.alternate=null,i.alternate=null,i.flags|=2)}function no(o,i,u){if(o!==null&&(i.dependencies=o.dependencies),Bs|=i.lanes,(u&i.childLanes)===0)return null;if(o!==null&&i.child!==o.child)throw Error(n(153));if(i.child!==null){for(o=i.child,u=Ho(o,o.pendingProps),i.child=u,u.return=i;o.sibling!==null;)o=o.sibling,u=u.sibling=Ho(o,o.pendingProps),u.return=i;u.sibling=null}return i.child}function dk(o,i,u){switch(i.tag){case 3:Zv(i),Fi();break;case 5:gv(i);break;case 1:hn(i.type)&&Ru(i);break;case 4:Wh(i,i.stateNode.containerInfo);break;case 10:var g=i.type._context,x=i.memoizedProps.value;Je(zu,g._currentValue),g._currentValue=x;break;case 13:if(g=i.memoizedState,g!==null)return g.dehydrated!==null?(Je(ot,ot.current&1),i.flags|=128,null):(u&i.child.childLanes)!==0?ew(o,i,u):(Je(ot,ot.current&1),o=no(o,i,u),o!==null?o.sibling:null);Je(ot,ot.current&1);break;case 19:if(g=(u&i.childLanes)!==0,(o.flags&128)!==0){if(g)return nw(o,i,u);i.flags|=128}if(x=i.memoizedState,x!==null&&(x.rendering=null,x.tail=null,x.lastEffect=null),Je(ot,ot.current),g)break;return null;case 22:case 23:return i.lanes=0,Kv(o,i,u)}return no(o,i,u)}var rw,u0,ow,sw;rw=function(o,i){for(var u=i.child;u!==null;){if(u.tag===5||u.tag===6)o.appendChild(u.stateNode);else if(u.tag!==4&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===i)break;for(;u.sibling===null;){if(u.return===null||u.return===i)return;u=u.return}u.sibling.return=u.return,u=u.sibling}},u0=function(){},ow=function(o,i,u,g){var x=o.memoizedProps;if(x!==g){o=i.stateNode,Ns(Br.current);var E=null;switch(u){case"input":x=tt(o,x),g=tt(o,g),E=[];break;case"select":x=Z({},x,{value:void 0}),g=Z({},g,{value:void 0}),E=[];break;case"textarea":x=Sr(o,x),g=Sr(o,g),E=[];break;default:typeof x.onClick!="function"&&typeof g.onClick=="function"&&(o.onclick=_u)}at(u,g);var _;u=null;for(J in x)if(!g.hasOwnProperty(J)&&x.hasOwnProperty(J)&&x[J]!=null)if(J==="style"){var M=x[J];for(_ in M)M.hasOwnProperty(_)&&(u||(u={}),u[_]="")}else J!=="dangerouslySetInnerHTML"&&J!=="children"&&J!=="suppressContentEditableWarning"&&J!=="suppressHydrationWarning"&&J!=="autoFocus"&&(s.hasOwnProperty(J)?E||(E=[]):(E=E||[]).push(J,null));for(J in g){var z=g[J];if(M=x!=null?x[J]:void 0,g.hasOwnProperty(J)&&z!==M&&(z!=null||M!=null))if(J==="style")if(M){for(_ in M)!M.hasOwnProperty(_)||z&&z.hasOwnProperty(_)||(u||(u={}),u[_]="");for(_ in z)z.hasOwnProperty(_)&&M[_]!==z[_]&&(u||(u={}),u[_]=z[_])}else u||(E||(E=[]),E.push(J,u)),u=z;else J==="dangerouslySetInnerHTML"?(z=z?z.__html:void 0,M=M?M.__html:void 0,z!=null&&M!==z&&(E=E||[]).push(J,z)):J==="children"?typeof z!="string"&&typeof z!="number"||(E=E||[]).push(J,""+z):J!=="suppressContentEditableWarning"&&J!=="suppressHydrationWarning"&&(s.hasOwnProperty(J)?(z!=null&&J==="onScroll"&&Xe("scroll",o),E||M===z||(E=[])):(E=E||[]).push(J,z))}u&&(E=E||[]).push("style",u);var J=E;(i.updateQueue=J)&&(i.flags|=4)}},sw=function(o,i,u,g){u!==g&&(i.flags|=4)};function jc(o,i){if(!nt)switch(o.tailMode){case"hidden":i=o.tail;for(var u=null;i!==null;)i.alternate!==null&&(u=i),i=i.sibling;u===null?o.tail=null:u.sibling=null;break;case"collapsed":u=o.tail;for(var g=null;u!==null;)u.alternate!==null&&(g=u),u=u.sibling;g===null?i||o.tail===null?o.tail=null:o.tail.sibling=null:g.sibling=null}}function Vt(o){var i=o.alternate!==null&&o.alternate.child===o.child,u=0,g=0;if(i)for(var x=o.child;x!==null;)u|=x.lanes|x.childLanes,g|=x.subtreeFlags&14680064,g|=x.flags&14680064,x.return=o,x=x.sibling;else for(x=o.child;x!==null;)u|=x.lanes|x.childLanes,g|=x.subtreeFlags,g|=x.flags,x.return=o,x=x.sibling;return o.subtreeFlags|=g,o.childLanes=u,i}function fk(o,i,u){var g=i.pendingProps;switch(_h(i),i.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Vt(i),null;case 1:return hn(i.type)&&Ou(),Vt(i),null;case 3:return g=i.stateNode,Wi(),et(fn),et(qt),Hh(),g.pendingContext&&(g.context=g.pendingContext,g.pendingContext=null),(o===null||o.child===null)&&(Lu(i)?i.flags|=4:o===null||o.memoizedState.isDehydrated&&(i.flags&256)===0||(i.flags|=1024,ur!==null&&(x0(ur),ur=null))),u0(o,i),Vt(i),null;case 5:$h(i);var x=Ns(Cc.current);if(u=i.type,o!==null&&i.stateNode!=null)ow(o,i,u,g,x),o.ref!==i.ref&&(i.flags|=512,i.flags|=2097152);else{if(!g){if(i.stateNode===null)throw Error(n(166));return Vt(i),null}if(o=Ns(Br.current),Lu(i)){g=i.stateNode,u=i.type;var E=i.memoizedProps;switch(g[Pr]=i,g[yc]=E,o=(i.mode&1)!==0,u){case"dialog":Xe("cancel",g),Xe("close",g);break;case"iframe":case"object":case"embed":Xe("load",g);break;case"video":case"audio":for(x=0;x<pc.length;x++)Xe(pc[x],g);break;case"source":Xe("error",g);break;case"img":case"image":case"link":Xe("error",g),Xe("load",g);break;case"details":Xe("toggle",g);break;case"input":ft(g,E),Xe("invalid",g);break;case"select":g._wrapperState={wasMultiple:!!E.multiple},Xe("invalid",g);break;case"textarea":ir(g,E),Xe("invalid",g)}at(u,E),x=null;for(var _ in E)if(E.hasOwnProperty(_)){var M=E[_];_==="children"?typeof M=="string"?g.textContent!==M&&(E.suppressHydrationWarning!==!0&&Bu(g.textContent,M,o),x=["children",M]):typeof M=="number"&&g.textContent!==""+M&&(E.suppressHydrationWarning!==!0&&Bu(g.textContent,M,o),x=["children",""+M]):s.hasOwnProperty(_)&&M!=null&&_==="onScroll"&&Xe("scroll",g)}switch(u){case"input":_e(g),Ze(g,E,!0);break;case"textarea":_e(g),bs(g);break;case"select":case"option":break;default:typeof E.onClick=="function"&&(g.onclick=_u)}g=x,i.updateQueue=g,g!==null&&(i.flags|=4)}else{_=x.nodeType===9?x:x.ownerDocument,o==="http://www.w3.org/1999/xhtml"&&(o=xs(u)),o==="http://www.w3.org/1999/xhtml"?u==="script"?(o=_.createElement("div"),o.innerHTML="<script><\/script>",o=o.removeChild(o.firstChild)):typeof g.is=="string"?o=_.createElement(u,{is:g.is}):(o=_.createElement(u),u==="select"&&(_=o,g.multiple?_.multiple=!0:g.size&&(_.size=g.size))):o=_.createElementNS(o,u),o[Pr]=i,o[yc]=g,rw(o,i,!1,!1),i.stateNode=o;e:{switch(_=Fe(u,g),u){case"dialog":Xe("cancel",o),Xe("close",o),x=g;break;case"iframe":case"object":case"embed":Xe("load",o),x=g;break;case"video":case"audio":for(x=0;x<pc.length;x++)Xe(pc[x],o);x=g;break;case"source":Xe("error",o),x=g;break;case"img":case"image":case"link":Xe("error",o),Xe("load",o),x=g;break;case"details":Xe("toggle",o),x=g;break;case"input":ft(o,g),x=tt(o,g),Xe("invalid",o);break;case"option":x=g;break;case"select":o._wrapperState={wasMultiple:!!g.multiple},x=Z({},g,{value:void 0}),Xe("invalid",o);break;case"textarea":ir(o,g),x=Sr(o,g),Xe("invalid",o);break;default:x=g}at(u,x),M=x;for(E in M)if(M.hasOwnProperty(E)){var z=M[E];E==="style"?He(o,z):E==="dangerouslySetInnerHTML"?(z=z?z.__html:void 0,z!=null&&Pn(o,z)):E==="children"?typeof z=="string"?(u!=="textarea"||z!=="")&&dn(o,z):typeof z=="number"&&dn(o,""+z):E!=="suppressContentEditableWarning"&&E!=="suppressHydrationWarning"&&E!=="autoFocus"&&(s.hasOwnProperty(E)?z!=null&&E==="onScroll"&&Xe("scroll",o):z!=null&&S(o,E,z,_))}switch(u){case"input":_e(o),Ze(o,g,!1);break;case"textarea":_e(o),bs(o);break;case"option":g.value!=null&&o.setAttribute("value",""+Ie(g.value));break;case"select":o.multiple=!!g.multiple,E=g.value,E!=null?qn(o,!!g.multiple,E,!1):g.defaultValue!=null&&qn(o,!!g.multiple,g.defaultValue,!0);break;default:typeof x.onClick=="function"&&(o.onclick=_u)}switch(u){case"button":case"input":case"select":case"textarea":g=!!g.autoFocus;break e;case"img":g=!0;break e;default:g=!1}}g&&(i.flags|=4)}i.ref!==null&&(i.flags|=512,i.flags|=2097152)}return Vt(i),null;case 6:if(o&&i.stateNode!=null)sw(o,i,o.memoizedProps,g);else{if(typeof g!="string"&&i.stateNode===null)throw Error(n(166));if(u=Ns(Cc.current),Ns(Br.current),Lu(i)){if(g=i.stateNode,u=i.memoizedProps,g[Pr]=i,(E=g.nodeValue!==u)&&(o=On,o!==null))switch(o.tag){case 3:Bu(g.nodeValue,u,(o.mode&1)!==0);break;case 5:o.memoizedProps.suppressHydrationWarning!==!0&&Bu(g.nodeValue,u,(o.mode&1)!==0)}E&&(i.flags|=4)}else g=(u.nodeType===9?u:u.ownerDocument).createTextNode(g),g[Pr]=i,i.stateNode=g}return Vt(i),null;case 13:if(et(ot),g=i.memoizedState,o===null||o.memoizedState!==null&&o.memoizedState.dehydrated!==null){if(nt&&Rn!==null&&(i.mode&1)!==0&&(i.flags&128)===0)cv(),Fi(),i.flags|=98560,E=!1;else if(E=Lu(i),g!==null&&g.dehydrated!==null){if(o===null){if(!E)throw Error(n(318));if(E=i.memoizedState,E=E!==null?E.dehydrated:null,!E)throw Error(n(317));E[Pr]=i}else Fi(),(i.flags&128)===0&&(i.memoizedState=null),i.flags|=4;Vt(i),E=!1}else ur!==null&&(x0(ur),ur=null),E=!0;if(!E)return i.flags&65536?i:null}return(i.flags&128)!==0?(i.lanes=u,i):(g=g!==null,g!==(o!==null&&o.memoizedState!==null)&&g&&(i.child.flags|=8192,(i.mode&1)!==0&&(o===null||(ot.current&1)!==0?kt===0&&(kt=3):A0())),i.updateQueue!==null&&(i.flags|=4),Vt(i),null);case 4:return Wi(),u0(o,i),o===null&&mc(i.stateNode.containerInfo),Vt(i),null;case 10:return Fh(i.type._context),Vt(i),null;case 17:return hn(i.type)&&Ou(),Vt(i),null;case 19:if(et(ot),E=i.memoizedState,E===null)return Vt(i),null;if(g=(i.flags&128)!==0,_=E.rendering,_===null)if(g)jc(E,!1);else{if(kt!==0||o!==null&&(o.flags&128)!==0)for(o=i.child;o!==null;){if(_=Hu(o),_!==null){for(i.flags|=128,jc(E,!1),g=_.updateQueue,g!==null&&(i.updateQueue=g,i.flags|=4),i.subtreeFlags=0,g=u,u=i.child;u!==null;)E=u,o=g,E.flags&=14680066,_=E.alternate,_===null?(E.childLanes=0,E.lanes=o,E.child=null,E.subtreeFlags=0,E.memoizedProps=null,E.memoizedState=null,E.updateQueue=null,E.dependencies=null,E.stateNode=null):(E.childLanes=_.childLanes,E.lanes=_.lanes,E.child=_.child,E.subtreeFlags=0,E.deletions=null,E.memoizedProps=_.memoizedProps,E.memoizedState=_.memoizedState,E.updateQueue=_.updateQueue,E.type=_.type,o=_.dependencies,E.dependencies=o===null?null:{lanes:o.lanes,firstContext:o.firstContext}),u=u.sibling;return Je(ot,ot.current&1|2),i.child}o=o.sibling}E.tail!==null&&pt()>Vi&&(i.flags|=128,g=!0,jc(E,!1),i.lanes=4194304)}else{if(!g)if(o=Hu(_),o!==null){if(i.flags|=128,g=!0,u=o.updateQueue,u!==null&&(i.updateQueue=u,i.flags|=4),jc(E,!0),E.tail===null&&E.tailMode==="hidden"&&!_.alternate&&!nt)return Vt(i),null}else 2*pt()-E.renderingStartTime>Vi&&u!==1073741824&&(i.flags|=128,g=!0,jc(E,!1),i.lanes=4194304);E.isBackwards?(_.sibling=i.child,i.child=_):(u=E.last,u!==null?u.sibling=_:i.child=_,E.last=_)}return E.tail!==null?(i=E.tail,E.rendering=i,E.tail=i.sibling,E.renderingStartTime=pt(),i.sibling=null,u=ot.current,Je(ot,g?u&1|2:u&1),i):(Vt(i),null);case 22:case 23:return E0(),g=i.memoizedState!==null,o!==null&&o.memoizedState!==null!==g&&(i.flags|=8192),g&&(i.mode&1)!==0?(Mn&1073741824)!==0&&(Vt(i),i.subtreeFlags&6&&(i.flags|=8192)):Vt(i),null;case 24:return null;case 25:return null}throw Error(n(156,i.tag))}function hk(o,i){switch(_h(i),i.tag){case 1:return hn(i.type)&&Ou(),o=i.flags,o&65536?(i.flags=o&-65537|128,i):null;case 3:return Wi(),et(fn),et(qt),Hh(),o=i.flags,(o&65536)!==0&&(o&128)===0?(i.flags=o&-65537|128,i):null;case 5:return $h(i),null;case 13:if(et(ot),o=i.memoizedState,o!==null&&o.dehydrated!==null){if(i.alternate===null)throw Error(n(340));Fi()}return o=i.flags,o&65536?(i.flags=o&-65537|128,i):null;case 19:return et(ot),null;case 4:return Wi(),null;case 10:return Fh(i.type._context),null;case 22:case 23:return E0(),null;case 24:return null;default:return null}}var ed=!1,Qt=!1,pk=typeof WeakSet=="function"?WeakSet:Set,ve=null;function qi(o,i){var u=o.ref;if(u!==null)if(typeof u=="function")try{u(null)}catch(g){ct(o,i,g)}else u.current=null}function d0(o,i,u){try{u()}catch(g){ct(o,i,g)}}var iw=!1;function mk(o,i){if(Eh=bu,o=Fy(),mh(o)){if("selectionStart"in o)var u={start:o.selectionStart,end:o.selectionEnd};else e:{u=(u=o.ownerDocument)&&u.defaultView||window;var g=u.getSelection&&u.getSelection();if(g&&g.rangeCount!==0){u=g.anchorNode;var x=g.anchorOffset,E=g.focusNode;g=g.focusOffset;try{u.nodeType,E.nodeType}catch{u=null;break e}var _=0,M=-1,z=-1,J=0,ie=0,ce=o,se=null;t:for(;;){for(var me;ce!==u||x!==0&&ce.nodeType!==3||(M=_+x),ce!==E||g!==0&&ce.nodeType!==3||(z=_+g),ce.nodeType===3&&(_+=ce.nodeValue.length),(me=ce.firstChild)!==null;)se=ce,ce=me;for(;;){if(ce===o)break t;if(se===u&&++J===x&&(M=_),se===E&&++ie===g&&(z=_),(me=ce.nextSibling)!==null)break;ce=se,se=ce.parentNode}ce=me}u=M===-1||z===-1?null:{start:M,end:z}}else u=null}u=u||{start:0,end:0}}else u=null;for(Ah={focusedElem:o,selectionRange:u},bu=!1,ve=i;ve!==null;)if(i=ve,o=i.child,(i.subtreeFlags&1028)!==0&&o!==null)o.return=i,ve=o;else for(;ve!==null;){i=ve;try{var we=i.alternate;if((i.flags&1024)!==0)switch(i.tag){case 0:case 11:case 15:break;case 1:if(we!==null){var be=we.memoizedProps,mt=we.memoizedState,V=i.stateNode,$=V.getSnapshotBeforeUpdate(i.elementType===i.type?be:dr(i.type,be),mt);V.__reactInternalSnapshotBeforeUpdate=$}break;case 3:var G=i.stateNode.containerInfo;G.nodeType===1?G.textContent="":G.nodeType===9&&G.documentElement&&G.removeChild(G.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(ue){ct(i,i.return,ue)}if(o=i.sibling,o!==null){o.return=i.return,ve=o;break}ve=i.return}return we=iw,iw=!1,we}function Ic(o,i,u){var g=i.updateQueue;if(g=g!==null?g.lastEffect:null,g!==null){var x=g=g.next;do{if((x.tag&o)===o){var E=x.destroy;x.destroy=void 0,E!==void 0&&d0(i,u,E)}x=x.next}while(x!==g)}}function td(o,i){if(i=i.updateQueue,i=i!==null?i.lastEffect:null,i!==null){var u=i=i.next;do{if((u.tag&o)===o){var g=u.create;u.destroy=g()}u=u.next}while(u!==i)}}function f0(o){var i=o.ref;if(i!==null){var u=o.stateNode;switch(o.tag){case 5:o=u;break;default:o=u}typeof i=="function"?i(o):i.current=o}}function aw(o){var i=o.alternate;i!==null&&(o.alternate=null,aw(i)),o.child=null,o.deletions=null,o.sibling=null,o.tag===5&&(i=o.stateNode,i!==null&&(delete i[Pr],delete i[yc],delete i[Ih],delete i[JA],delete i[ZA])),o.stateNode=null,o.return=null,o.dependencies=null,o.memoizedProps=null,o.memoizedState=null,o.pendingProps=null,o.stateNode=null,o.updateQueue=null}function cw(o){return o.tag===5||o.tag===3||o.tag===4}function lw(o){e:for(;;){for(;o.sibling===null;){if(o.return===null||cw(o.return))return null;o=o.return}for(o.sibling.return=o.return,o=o.sibling;o.tag!==5&&o.tag!==6&&o.tag!==18;){if(o.flags&2||o.child===null||o.tag===4)continue e;o.child.return=o,o=o.child}if(!(o.flags&2))return o.stateNode}}function h0(o,i,u){var g=o.tag;if(g===5||g===6)o=o.stateNode,i?u.nodeType===8?u.parentNode.insertBefore(o,i):u.insertBefore(o,i):(u.nodeType===8?(i=u.parentNode,i.insertBefore(o,u)):(i=u,i.appendChild(o)),u=u._reactRootContainer,u!=null||i.onclick!==null||(i.onclick=_u));else if(g!==4&&(o=o.child,o!==null))for(h0(o,i,u),o=o.sibling;o!==null;)h0(o,i,u),o=o.sibling}function p0(o,i,u){var g=o.tag;if(g===5||g===6)o=o.stateNode,i?u.insertBefore(o,i):u.appendChild(o);else if(g!==4&&(o=o.child,o!==null))for(p0(o,i,u),o=o.sibling;o!==null;)p0(o,i,u),o=o.sibling}var Dt=null,fr=!1;function Uo(o,i,u){for(u=u.child;u!==null;)uw(o,i,u),u=u.sibling}function uw(o,i,u){if(Nr&&typeof Nr.onCommitFiberUnmount=="function")try{Nr.onCommitFiberUnmount(pu,u)}catch{}switch(u.tag){case 5:Qt||qi(u,i);case 6:var g=Dt,x=fr;Dt=null,Uo(o,i,u),Dt=g,fr=x,Dt!==null&&(fr?(o=Dt,u=u.stateNode,o.nodeType===8?o.parentNode.removeChild(u):o.removeChild(u)):Dt.removeChild(u.stateNode));break;case 18:Dt!==null&&(fr?(o=Dt,u=u.stateNode,o.nodeType===8?jh(o.parentNode,u):o.nodeType===1&&jh(o,u),ic(o)):jh(Dt,u.stateNode));break;case 4:g=Dt,x=fr,Dt=u.stateNode.containerInfo,fr=!0,Uo(o,i,u),Dt=g,fr=x;break;case 0:case 11:case 14:case 15:if(!Qt&&(g=u.updateQueue,g!==null&&(g=g.lastEffect,g!==null))){x=g=g.next;do{var E=x,_=E.destroy;E=E.tag,_!==void 0&&((E&2)!==0||(E&4)!==0)&&d0(u,i,_),x=x.next}while(x!==g)}Uo(o,i,u);break;case 1:if(!Qt&&(qi(u,i),g=u.stateNode,typeof g.componentWillUnmount=="function"))try{g.props=u.memoizedProps,g.state=u.memoizedState,g.componentWillUnmount()}catch(M){ct(u,i,M)}Uo(o,i,u);break;case 21:Uo(o,i,u);break;case 22:u.mode&1?(Qt=(g=Qt)||u.memoizedState!==null,Uo(o,i,u),Qt=g):Uo(o,i,u);break;default:Uo(o,i,u)}}function dw(o){var i=o.updateQueue;if(i!==null){o.updateQueue=null;var u=o.stateNode;u===null&&(u=o.stateNode=new pk),i.forEach(function(g){var x=Ak.bind(null,o,g);u.has(g)||(u.add(g),g.then(x,x))})}}function hr(o,i){var u=i.deletions;if(u!==null)for(var g=0;g<u.length;g++){var x=u[g];try{var E=o,_=i,M=_;e:for(;M!==null;){switch(M.tag){case 5:Dt=M.stateNode,fr=!1;break e;case 3:Dt=M.stateNode.containerInfo,fr=!0;break e;case 4:Dt=M.stateNode.containerInfo,fr=!0;break e}M=M.return}if(Dt===null)throw Error(n(160));uw(E,_,x),Dt=null,fr=!1;var z=x.alternate;z!==null&&(z.return=null),x.return=null}catch(J){ct(x,i,J)}}if(i.subtreeFlags&12854)for(i=i.child;i!==null;)fw(i,o),i=i.sibling}function fw(o,i){var u=o.alternate,g=o.flags;switch(o.tag){case 0:case 11:case 14:case 15:if(hr(i,o),Tr(o),g&4){try{Ic(3,o,o.return),td(3,o)}catch(be){ct(o,o.return,be)}try{Ic(5,o,o.return)}catch(be){ct(o,o.return,be)}}break;case 1:hr(i,o),Tr(o),g&512&&u!==null&&qi(u,u.return);break;case 5:if(hr(i,o),Tr(o),g&512&&u!==null&&qi(u,u.return),o.flags&32){var x=o.stateNode;try{dn(x,"")}catch(be){ct(o,o.return,be)}}if(g&4&&(x=o.stateNode,x!=null)){var E=o.memoizedProps,_=u!==null?u.memoizedProps:E,M=o.type,z=o.updateQueue;if(o.updateQueue=null,z!==null)try{M==="input"&&E.type==="radio"&&E.name!=null&&ze(x,E),Fe(M,_);var J=Fe(M,E);for(_=0;_<z.length;_+=2){var ie=z[_],ce=z[_+1];ie==="style"?He(x,ce):ie==="dangerouslySetInnerHTML"?Pn(x,ce):ie==="children"?dn(x,ce):S(x,ie,ce,J)}switch(M){case"input":ht(x,E);break;case"textarea":Xt(x,E);break;case"select":var se=x._wrapperState.wasMultiple;x._wrapperState.wasMultiple=!!E.multiple;var me=E.value;me!=null?qn(x,!!E.multiple,me,!1):se!==!!E.multiple&&(E.defaultValue!=null?qn(x,!!E.multiple,E.defaultValue,!0):qn(x,!!E.multiple,E.multiple?[]:"",!1))}x[yc]=E}catch(be){ct(o,o.return,be)}}break;case 6:if(hr(i,o),Tr(o),g&4){if(o.stateNode===null)throw Error(n(162));x=o.stateNode,E=o.memoizedProps;try{x.nodeValue=E}catch(be){ct(o,o.return,be)}}break;case 3:if(hr(i,o),Tr(o),g&4&&u!==null&&u.memoizedState.isDehydrated)try{ic(i.containerInfo)}catch(be){ct(o,o.return,be)}break;case 4:hr(i,o),Tr(o);break;case 13:hr(i,o),Tr(o),x=o.child,x.flags&8192&&(E=x.memoizedState!==null,x.stateNode.isHidden=E,!E||x.alternate!==null&&x.alternate.memoizedState!==null||(y0=pt())),g&4&&dw(o);break;case 22:if(ie=u!==null&&u.memoizedState!==null,o.mode&1?(Qt=(J=Qt)||ie,hr(i,o),Qt=J):hr(i,o),Tr(o),g&8192){if(J=o.memoizedState!==null,(o.stateNode.isHidden=J)&&!ie&&(o.mode&1)!==0)for(ve=o,ie=o.child;ie!==null;){for(ce=ve=ie;ve!==null;){switch(se=ve,me=se.child,se.tag){case 0:case 11:case 14:case 15:Ic(4,se,se.return);break;case 1:qi(se,se.return);var we=se.stateNode;if(typeof we.componentWillUnmount=="function"){g=se,u=se.return;try{i=g,we.props=i.memoizedProps,we.state=i.memoizedState,we.componentWillUnmount()}catch(be){ct(g,u,be)}}break;case 5:qi(se,se.return);break;case 22:if(se.memoizedState!==null){mw(ce);continue}}me!==null?(me.return=se,ve=me):mw(ce)}ie=ie.sibling}e:for(ie=null,ce=o;;){if(ce.tag===5){if(ie===null){ie=ce;try{x=ce.stateNode,J?(E=x.style,typeof E.setProperty=="function"?E.setProperty("display","none","important"):E.display="none"):(M=ce.stateNode,z=ce.memoizedProps.style,_=z!=null&&z.hasOwnProperty("display")?z.display:null,M.style.display=Ne("display",_))}catch(be){ct(o,o.return,be)}}}else if(ce.tag===6){if(ie===null)try{ce.stateNode.nodeValue=J?"":ce.memoizedProps}catch(be){ct(o,o.return,be)}}else if((ce.tag!==22&&ce.tag!==23||ce.memoizedState===null||ce===o)&&ce.child!==null){ce.child.return=ce,ce=ce.child;continue}if(ce===o)break e;for(;ce.sibling===null;){if(ce.return===null||ce.return===o)break e;ie===ce&&(ie=null),ce=ce.return}ie===ce&&(ie=null),ce.sibling.return=ce.return,ce=ce.sibling}}break;case 19:hr(i,o),Tr(o),g&4&&dw(o);break;case 21:break;default:hr(i,o),Tr(o)}}function Tr(o){var i=o.flags;if(i&2){try{e:{for(var u=o.return;u!==null;){if(cw(u)){var g=u;break e}u=u.return}throw Error(n(160))}switch(g.tag){case 5:var x=g.stateNode;g.flags&32&&(dn(x,""),g.flags&=-33);var E=lw(o);p0(o,E,x);break;case 3:case 4:var _=g.stateNode.containerInfo,M=lw(o);h0(o,M,_);break;default:throw Error(n(161))}}catch(z){ct(o,o.return,z)}o.flags&=-3}i&4096&&(o.flags&=-4097)}function gk(o,i,u){ve=o,hw(o)}function hw(o,i,u){for(var g=(o.mode&1)!==0;ve!==null;){var x=ve,E=x.child;if(x.tag===22&&g){var _=x.memoizedState!==null||ed;if(!_){var M=x.alternate,z=M!==null&&M.memoizedState!==null||Qt;M=ed;var J=Qt;if(ed=_,(Qt=z)&&!J)for(ve=x;ve!==null;)_=ve,z=_.child,_.tag===22&&_.memoizedState!==null?gw(x):z!==null?(z.return=_,ve=z):gw(x);for(;E!==null;)ve=E,hw(E),E=E.sibling;ve=x,ed=M,Qt=J}pw(o)}else(x.subtreeFlags&8772)!==0&&E!==null?(E.return=x,ve=E):pw(o)}}function pw(o){for(;ve!==null;){var i=ve;if((i.flags&8772)!==0){var u=i.alternate;try{if((i.flags&8772)!==0)switch(i.tag){case 0:case 11:case 15:Qt||td(5,i);break;case 1:var g=i.stateNode;if(i.flags&4&&!Qt)if(u===null)g.componentDidMount();else{var x=i.elementType===i.type?u.memoizedProps:dr(i.type,u.memoizedProps);g.componentDidUpdate(x,u.memoizedState,g.__reactInternalSnapshotBeforeUpdate)}var E=i.updateQueue;E!==null&&mv(i,E,g);break;case 3:var _=i.updateQueue;if(_!==null){if(u=null,i.child!==null)switch(i.child.tag){case 5:u=i.child.stateNode;break;case 1:u=i.child.stateNode}mv(i,_,u)}break;case 5:var M=i.stateNode;if(u===null&&i.flags&4){u=M;var z=i.memoizedProps;switch(i.type){case"button":case"input":case"select":case"textarea":z.autoFocus&&u.focus();break;case"img":z.src&&(u.src=z.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(i.memoizedState===null){var J=i.alternate;if(J!==null){var ie=J.memoizedState;if(ie!==null){var ce=ie.dehydrated;ce!==null&&ic(ce)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Qt||i.flags&512&&f0(i)}catch(se){ct(i,i.return,se)}}if(i===o){ve=null;break}if(u=i.sibling,u!==null){u.return=i.return,ve=u;break}ve=i.return}}function mw(o){for(;ve!==null;){var i=ve;if(i===o){ve=null;break}var u=i.sibling;if(u!==null){u.return=i.return,ve=u;break}ve=i.return}}function gw(o){for(;ve!==null;){var i=ve;try{switch(i.tag){case 0:case 11:case 15:var u=i.return;try{td(4,i)}catch(z){ct(i,u,z)}break;case 1:var g=i.stateNode;if(typeof g.componentDidMount=="function"){var x=i.return;try{g.componentDidMount()}catch(z){ct(i,x,z)}}var E=i.return;try{f0(i)}catch(z){ct(i,E,z)}break;case 5:var _=i.return;try{f0(i)}catch(z){ct(i,_,z)}}}catch(z){ct(i,i.return,z)}if(i===o){ve=null;break}var M=i.sibling;if(M!==null){M.return=i.return,ve=M;break}ve=i.return}}var yk=Math.ceil,nd=j.ReactCurrentDispatcher,m0=j.ReactCurrentOwner,Kn=j.ReactCurrentBatchConfig,qe=0,Pt=null,yt=null,Ft=0,Mn=0,Hi=Ro(0),kt=0,Nc=null,Bs=0,rd=0,g0=0,Pc=null,mn=null,y0=0,Vi=1/0,ro=null,od=!1,v0=null,zo=null,sd=!1,Wo=null,id=0,Bc=0,w0=null,ad=-1,cd=0;function tn(){return(qe&6)!==0?pt():ad!==-1?ad:ad=pt()}function $o(o){return(o.mode&1)===0?1:(qe&2)!==0&&Ft!==0?Ft&-Ft:ek.transition!==null?(cd===0&&(cd=ly()),cd):(o=Ye,o!==0||(o=window.event,o=o===void 0?16:vy(o.type)),o)}function pr(o,i,u,g){if(50<Bc)throw Bc=0,w0=null,Error(n(185));tc(o,u,g),((qe&2)===0||o!==Pt)&&(o===Pt&&((qe&2)===0&&(rd|=u),kt===4&&qo(o,Ft)),gn(o,g),u===1&&qe===0&&(i.mode&1)===0&&(Vi=pt()+500,Mu&&Do()))}function gn(o,i){var u=o.callbackNode;eA(o,i);var g=yu(o,o===Pt?Ft:0);if(g===0)u!==null&&iy(u),o.callbackNode=null,o.callbackPriority=0;else if(i=g&-g,o.callbackPriority!==i){if(u!=null&&iy(u),i===1)o.tag===0?XA(vw.bind(null,o)):rv(vw.bind(null,o)),KA(function(){(qe&6)===0&&Do()}),u=null;else{switch(uy(g)){case 1:u=Zf;break;case 4:u=ay;break;case 16:u=hu;break;case 536870912:u=cy;break;default:u=hu}u=Sw(u,yw.bind(null,o))}o.callbackPriority=i,o.callbackNode=u}}function yw(o,i){if(ad=-1,cd=0,(qe&6)!==0)throw Error(n(327));var u=o.callbackNode;if(Qi()&&o.callbackNode!==u)return null;var g=yu(o,o===Pt?Ft:0);if(g===0)return null;if((g&30)!==0||(g&o.expiredLanes)!==0||i)i=ld(o,g);else{i=g;var x=qe;qe|=2;var E=bw();(Pt!==o||Ft!==i)&&(ro=null,Vi=pt()+500,Ts(o,i));do try{bk();break}catch(M){ww(o,M)}while(!0);Dh(),nd.current=E,qe=x,yt!==null?i=0:(Pt=null,Ft=0,i=kt)}if(i!==0){if(i===2&&(x=Xf(o),x!==0&&(g=x,i=b0(o,x))),i===1)throw u=Nc,Ts(o,0),qo(o,g),gn(o,pt()),u;if(i===6)qo(o,g);else{if(x=o.current.alternate,(g&30)===0&&!vk(x)&&(i=ld(o,g),i===2&&(E=Xf(o),E!==0&&(g=E,i=b0(o,E))),i===1))throw u=Nc,Ts(o,0),qo(o,g),gn(o,pt()),u;switch(o.finishedWork=x,o.finishedLanes=g,i){case 0:case 1:throw Error(n(345));case 2:Os(o,mn,ro);break;case 3:if(qo(o,g),(g&130023424)===g&&(i=y0+500-pt(),10<i)){if(yu(o,0)!==0)break;if(x=o.suspendedLanes,(x&g)!==g){tn(),o.pingedLanes|=o.suspendedLanes&x;break}o.timeoutHandle=Sh(Os.bind(null,o,mn,ro),i);break}Os(o,mn,ro);break;case 4:if(qo(o,g),(g&4194240)===g)break;for(i=o.eventTimes,x=-1;0<g;){var _=31-cr(g);E=1<<_,_=i[_],_>x&&(x=_),g&=~E}if(g=x,g=pt()-g,g=(120>g?120:480>g?480:1080>g?1080:1920>g?1920:3e3>g?3e3:4320>g?4320:1960*yk(g/1960))-g,10<g){o.timeoutHandle=Sh(Os.bind(null,o,mn,ro),g);break}Os(o,mn,ro);break;case 5:Os(o,mn,ro);break;default:throw Error(n(329))}}}return gn(o,pt()),o.callbackNode===u?yw.bind(null,o):null}function b0(o,i){var u=Pc;return o.current.memoizedState.isDehydrated&&(Ts(o,i).flags|=256),o=ld(o,i),o!==2&&(i=mn,mn=u,i!==null&&x0(i)),o}function x0(o){mn===null?mn=o:mn.push.apply(mn,o)}function vk(o){for(var i=o;;){if(i.flags&16384){var u=i.updateQueue;if(u!==null&&(u=u.stores,u!==null))for(var g=0;g<u.length;g++){var x=u[g],E=x.getSnapshot;x=x.value;try{if(!lr(E(),x))return!1}catch{return!1}}}if(u=i.child,i.subtreeFlags&16384&&u!==null)u.return=i,i=u;else{if(i===o)break;for(;i.sibling===null;){if(i.return===null||i.return===o)return!0;i=i.return}i.sibling.return=i.return,i=i.sibling}}return!0}function qo(o,i){for(i&=~g0,i&=~rd,o.suspendedLanes|=i,o.pingedLanes&=~i,o=o.expirationTimes;0<i;){var u=31-cr(i),g=1<<u;o[u]=-1,i&=~g}}function vw(o){if((qe&6)!==0)throw Error(n(327));Qi();var i=yu(o,0);if((i&1)===0)return gn(o,pt()),null;var u=ld(o,i);if(o.tag!==0&&u===2){var g=Xf(o);g!==0&&(i=g,u=b0(o,g))}if(u===1)throw u=Nc,Ts(o,0),qo(o,i),gn(o,pt()),u;if(u===6)throw Error(n(345));return o.finishedWork=o.current.alternate,o.finishedLanes=i,Os(o,mn,ro),gn(o,pt()),null}function C0(o,i){var u=qe;qe|=1;try{return o(i)}finally{qe=u,qe===0&&(Vi=pt()+500,Mu&&Do())}}function _s(o){Wo!==null&&Wo.tag===0&&(qe&6)===0&&Qi();var i=qe;qe|=1;var u=Kn.transition,g=Ye;try{if(Kn.transition=null,Ye=1,o)return o()}finally{Ye=g,Kn.transition=u,qe=i,(qe&6)===0&&Do()}}function E0(){Mn=Hi.current,et(Hi)}function Ts(o,i){o.finishedWork=null,o.finishedLanes=0;var u=o.timeoutHandle;if(u!==-1&&(o.timeoutHandle=-1,GA(u)),yt!==null)for(u=yt.return;u!==null;){var g=u;switch(_h(g),g.tag){case 1:g=g.type.childContextTypes,g!=null&&Ou();break;case 3:Wi(),et(fn),et(qt),Hh();break;case 5:$h(g);break;case 4:Wi();break;case 13:et(ot);break;case 19:et(ot);break;case 10:Fh(g.type._context);break;case 22:case 23:E0()}u=u.return}if(Pt=o,yt=o=Ho(o.current,null),Ft=Mn=i,kt=0,Nc=null,g0=rd=Bs=0,mn=Pc=null,Is!==null){for(i=0;i<Is.length;i++)if(u=Is[i],g=u.interleaved,g!==null){u.interleaved=null;var x=g.next,E=u.pending;if(E!==null){var _=E.next;E.next=x,g.next=_}u.pending=g}Is=null}return o}function ww(o,i){do{var u=yt;try{if(Dh(),Vu.current=Yu,Qu){for(var g=st.memoizedState;g!==null;){var x=g.queue;x!==null&&(x.pending=null),g=g.next}Qu=!1}if(Ps=0,Nt=At=st=null,Ec=!1,Ac=0,m0.current=null,u===null||u.return===null){kt=1,Nc=i,yt=null;break}e:{var E=o,_=u.return,M=u,z=i;if(i=Ft,M.flags|=32768,z!==null&&typeof z=="object"&&typeof z.then=="function"){var J=z,ie=M,ce=ie.tag;if((ie.mode&1)===0&&(ce===0||ce===11||ce===15)){var se=ie.alternate;se?(ie.updateQueue=se.updateQueue,ie.memoizedState=se.memoizedState,ie.lanes=se.lanes):(ie.updateQueue=null,ie.memoizedState=null)}var me=qv(_);if(me!==null){me.flags&=-257,Hv(me,_,M,E,i),me.mode&1&&$v(E,J,i),i=me,z=J;var we=i.updateQueue;if(we===null){var be=new Set;be.add(z),i.updateQueue=be}else we.add(z);break e}else{if((i&1)===0){$v(E,J,i),A0();break e}z=Error(n(426))}}else if(nt&&M.mode&1){var mt=qv(_);if(mt!==null){(mt.flags&65536)===0&&(mt.flags|=256),Hv(mt,_,M,E,i),Rh($i(z,M));break e}}E=z=$i(z,M),kt!==4&&(kt=2),Pc===null?Pc=[E]:Pc.push(E),E=_;do{switch(E.tag){case 3:E.flags|=65536,i&=-i,E.lanes|=i;var V=zv(E,z,i);pv(E,V);break e;case 1:M=z;var $=E.type,G=E.stateNode;if((E.flags&128)===0&&(typeof $.getDerivedStateFromError=="function"||G!==null&&typeof G.componentDidCatch=="function"&&(zo===null||!zo.has(G)))){E.flags|=65536,i&=-i,E.lanes|=i;var ue=Wv(E,M,i);pv(E,ue);break e}}E=E.return}while(E!==null)}Cw(u)}catch(Ce){i=Ce,yt===u&&u!==null&&(yt=u=u.return);continue}break}while(!0)}function bw(){var o=nd.current;return nd.current=Yu,o===null?Yu:o}function A0(){(kt===0||kt===3||kt===2)&&(kt=4),Pt===null||(Bs&268435455)===0&&(rd&268435455)===0||qo(Pt,Ft)}function ld(o,i){var u=qe;qe|=2;var g=bw();(Pt!==o||Ft!==i)&&(ro=null,Ts(o,i));do try{wk();break}catch(x){ww(o,x)}while(!0);if(Dh(),qe=u,nd.current=g,yt!==null)throw Error(n(261));return Pt=null,Ft=0,kt}function wk(){for(;yt!==null;)xw(yt)}function bk(){for(;yt!==null&&!HE();)xw(yt)}function xw(o){var i=kw(o.alternate,o,Mn);o.memoizedProps=o.pendingProps,i===null?Cw(o):yt=i,m0.current=null}function Cw(o){var i=o;do{var u=i.alternate;if(o=i.return,(i.flags&32768)===0){if(u=fk(u,i,Mn),u!==null){yt=u;return}}else{if(u=hk(u,i),u!==null){u.flags&=32767,yt=u;return}if(o!==null)o.flags|=32768,o.subtreeFlags=0,o.deletions=null;else{kt=6,yt=null;return}}if(i=i.sibling,i!==null){yt=i;return}yt=i=o}while(i!==null);kt===0&&(kt=5)}function Os(o,i,u){var g=Ye,x=Kn.transition;try{Kn.transition=null,Ye=1,xk(o,i,u,g)}finally{Kn.transition=x,Ye=g}return null}function xk(o,i,u,g){do Qi();while(Wo!==null);if((qe&6)!==0)throw Error(n(327));u=o.finishedWork;var x=o.finishedLanes;if(u===null)return null;if(o.finishedWork=null,o.finishedLanes=0,u===o.current)throw Error(n(177));o.callbackNode=null,o.callbackPriority=0;var E=u.lanes|u.childLanes;if(tA(o,E),o===Pt&&(yt=Pt=null,Ft=0),(u.subtreeFlags&2064)===0&&(u.flags&2064)===0||sd||(sd=!0,Sw(hu,function(){return Qi(),null})),E=(u.flags&15990)!==0,(u.subtreeFlags&15990)!==0||E){E=Kn.transition,Kn.transition=null;var _=Ye;Ye=1;var M=qe;qe|=4,m0.current=null,mk(o,u),fw(u,o),zA(Ah),bu=!!Eh,Ah=Eh=null,o.current=u,gk(u),VE(),qe=M,Ye=_,Kn.transition=E}else o.current=u;if(sd&&(sd=!1,Wo=o,id=x),E=o.pendingLanes,E===0&&(zo=null),KE(u.stateNode),gn(o,pt()),i!==null)for(g=o.onRecoverableError,u=0;u<i.length;u++)x=i[u],g(x.value,{componentStack:x.stack,digest:x.digest});if(od)throw od=!1,o=v0,v0=null,o;return(id&1)!==0&&o.tag!==0&&Qi(),E=o.pendingLanes,(E&1)!==0?o===w0?Bc++:(Bc=0,w0=o):Bc=0,Do(),null}function Qi(){if(Wo!==null){var o=uy(id),i=Kn.transition,u=Ye;try{if(Kn.transition=null,Ye=16>o?16:o,Wo===null)var g=!1;else{if(o=Wo,Wo=null,id=0,(qe&6)!==0)throw Error(n(331));var x=qe;for(qe|=4,ve=o.current;ve!==null;){var E=ve,_=E.child;if((ve.flags&16)!==0){var M=E.deletions;if(M!==null){for(var z=0;z<M.length;z++){var J=M[z];for(ve=J;ve!==null;){var ie=ve;switch(ie.tag){case 0:case 11:case 15:Ic(8,ie,E)}var ce=ie.child;if(ce!==null)ce.return=ie,ve=ce;else for(;ve!==null;){ie=ve;var se=ie.sibling,me=ie.return;if(aw(ie),ie===J){ve=null;break}if(se!==null){se.return=me,ve=se;break}ve=me}}}var we=E.alternate;if(we!==null){var be=we.child;if(be!==null){we.child=null;do{var mt=be.sibling;be.sibling=null,be=mt}while(be!==null)}}ve=E}}if((E.subtreeFlags&2064)!==0&&_!==null)_.return=E,ve=_;else e:for(;ve!==null;){if(E=ve,(E.flags&2048)!==0)switch(E.tag){case 0:case 11:case 15:Ic(9,E,E.return)}var V=E.sibling;if(V!==null){V.return=E.return,ve=V;break e}ve=E.return}}var $=o.current;for(ve=$;ve!==null;){_=ve;var G=_.child;if((_.subtreeFlags&2064)!==0&&G!==null)G.return=_,ve=G;else e:for(_=$;ve!==null;){if(M=ve,(M.flags&2048)!==0)try{switch(M.tag){case 0:case 11:case 15:td(9,M)}}catch(Ce){ct(M,M.return,Ce)}if(M===_){ve=null;break e}var ue=M.sibling;if(ue!==null){ue.return=M.return,ve=ue;break e}ve=M.return}}if(qe=x,Do(),Nr&&typeof Nr.onPostCommitFiberRoot=="function")try{Nr.onPostCommitFiberRoot(pu,o)}catch{}g=!0}return g}finally{Ye=u,Kn.transition=i}}return!1}function Ew(o,i,u){i=$i(u,i),i=zv(o,i,1),o=Lo(o,i,1),i=tn(),o!==null&&(tc(o,1,i),gn(o,i))}function ct(o,i,u){if(o.tag===3)Ew(o,o,u);else for(;i!==null;){if(i.tag===3){Ew(i,o,u);break}else if(i.tag===1){var g=i.stateNode;if(typeof i.type.getDerivedStateFromError=="function"||typeof g.componentDidCatch=="function"&&(zo===null||!zo.has(g))){o=$i(u,o),o=Wv(i,o,1),i=Lo(i,o,1),o=tn(),i!==null&&(tc(i,1,o),gn(i,o));break}}i=i.return}}function Ck(o,i,u){var g=o.pingCache;g!==null&&g.delete(i),i=tn(),o.pingedLanes|=o.suspendedLanes&u,Pt===o&&(Ft&u)===u&&(kt===4||kt===3&&(Ft&130023424)===Ft&&500>pt()-y0?Ts(o,0):g0|=u),gn(o,i)}function Aw(o,i){i===0&&((o.mode&1)===0?i=1:(i=gu,gu<<=1,(gu&130023424)===0&&(gu=4194304)));var u=tn();o=eo(o,i),o!==null&&(tc(o,i,u),gn(o,u))}function Ek(o){var i=o.memoizedState,u=0;i!==null&&(u=i.retryLane),Aw(o,u)}function Ak(o,i){var u=0;switch(o.tag){case 13:var g=o.stateNode,x=o.memoizedState;x!==null&&(u=x.retryLane);break;case 19:g=o.stateNode;break;default:throw Error(n(314))}g!==null&&g.delete(i),Aw(o,u)}var kw;kw=function(o,i,u){if(o!==null)if(o.memoizedProps!==i.pendingProps||fn.current)pn=!0;else{if((o.lanes&u)===0&&(i.flags&128)===0)return pn=!1,dk(o,i,u);pn=(o.flags&131072)!==0}else pn=!1,nt&&(i.flags&1048576)!==0&&ov(i,Fu,i.index);switch(i.lanes=0,i.tag){case 2:var g=i.type;Xu(o,i),o=i.pendingProps;var x=Ri(i,qt.current);zi(i,u),x=Gh(null,i,g,o,x,u);var E=Kh();return i.flags|=1,typeof x=="object"&&x!==null&&typeof x.render=="function"&&x.$$typeof===void 0?(i.tag=1,i.memoizedState=null,i.updateQueue=null,hn(g)?(E=!0,Ru(i)):E=!1,i.memoizedState=x.state!==null&&x.state!==void 0?x.state:null,zh(i),x.updater=Ju,i.stateNode=x,x._reactInternals=i,t0(i,g,o,u),i=s0(null,i,g,!0,E,u)):(i.tag=0,nt&&E&&Bh(i),en(null,i,x,u),i=i.child),i;case 16:g=i.elementType;e:{switch(Xu(o,i),o=i.pendingProps,x=g._init,g=x(g._payload),i.type=g,x=i.tag=Sk(g),o=dr(g,o),x){case 0:i=o0(null,i,g,o,u);break e;case 1:i=Jv(null,i,g,o,u);break e;case 11:i=Vv(null,i,g,o,u);break e;case 14:i=Qv(null,i,g,dr(g.type,o),u);break e}throw Error(n(306,g,""))}return i;case 0:return g=i.type,x=i.pendingProps,x=i.elementType===g?x:dr(g,x),o0(o,i,g,x,u);case 1:return g=i.type,x=i.pendingProps,x=i.elementType===g?x:dr(g,x),Jv(o,i,g,x,u);case 3:e:{if(Zv(i),o===null)throw Error(n(387));g=i.pendingProps,E=i.memoizedState,x=E.element,hv(o,i),qu(i,g,null,u);var _=i.memoizedState;if(g=_.element,E.isDehydrated)if(E={element:g,isDehydrated:!1,cache:_.cache,pendingSuspenseBoundaries:_.pendingSuspenseBoundaries,transitions:_.transitions},i.updateQueue.baseState=E,i.memoizedState=E,i.flags&256){x=$i(Error(n(423)),i),i=Xv(o,i,g,u,x);break e}else if(g!==x){x=$i(Error(n(424)),i),i=Xv(o,i,g,u,x);break e}else for(Rn=Oo(i.stateNode.containerInfo.firstChild),On=i,nt=!0,ur=null,u=dv(i,null,g,u),i.child=u;u;)u.flags=u.flags&-3|4096,u=u.sibling;else{if(Fi(),g===x){i=no(o,i,u);break e}en(o,i,g,u)}i=i.child}return i;case 5:return gv(i),o===null&&Oh(i),g=i.type,x=i.pendingProps,E=o!==null?o.memoizedProps:null,_=x.children,kh(g,x)?_=null:E!==null&&kh(g,E)&&(i.flags|=32),Yv(o,i),en(o,i,_,u),i.child;case 6:return o===null&&Oh(i),null;case 13:return ew(o,i,u);case 4:return Wh(i,i.stateNode.containerInfo),g=i.pendingProps,o===null?i.child=Li(i,null,g,u):en(o,i,g,u),i.child;case 11:return g=i.type,x=i.pendingProps,x=i.elementType===g?x:dr(g,x),Vv(o,i,g,x,u);case 7:return en(o,i,i.pendingProps,u),i.child;case 8:return en(o,i,i.pendingProps.children,u),i.child;case 12:return en(o,i,i.pendingProps.children,u),i.child;case 10:e:{if(g=i.type._context,x=i.pendingProps,E=i.memoizedProps,_=x.value,Je(zu,g._currentValue),g._currentValue=_,E!==null)if(lr(E.value,_)){if(E.children===x.children&&!fn.current){i=no(o,i,u);break e}}else for(E=i.child,E!==null&&(E.return=i);E!==null;){var M=E.dependencies;if(M!==null){_=E.child;for(var z=M.firstContext;z!==null;){if(z.context===g){if(E.tag===1){z=to(-1,u&-u),z.tag=2;var J=E.updateQueue;if(J!==null){J=J.shared;var ie=J.pending;ie===null?z.next=z:(z.next=ie.next,ie.next=z),J.pending=z}}E.lanes|=u,z=E.alternate,z!==null&&(z.lanes|=u),Lh(E.return,u,i),M.lanes|=u;break}z=z.next}}else if(E.tag===10)_=E.type===i.type?null:E.child;else if(E.tag===18){if(_=E.return,_===null)throw Error(n(341));_.lanes|=u,M=_.alternate,M!==null&&(M.lanes|=u),Lh(_,u,i),_=E.sibling}else _=E.child;if(_!==null)_.return=E;else for(_=E;_!==null;){if(_===i){_=null;break}if(E=_.sibling,E!==null){E.return=_.return,_=E;break}_=_.return}E=_}en(o,i,x.children,u),i=i.child}return i;case 9:return x=i.type,g=i.pendingProps.children,zi(i,u),x=Qn(x),g=g(x),i.flags|=1,en(o,i,g,u),i.child;case 14:return g=i.type,x=dr(g,i.pendingProps),x=dr(g.type,x),Qv(o,i,g,x,u);case 15:return Gv(o,i,i.type,i.pendingProps,u);case 17:return g=i.type,x=i.pendingProps,x=i.elementType===g?x:dr(g,x),Xu(o,i),i.tag=1,hn(g)?(o=!0,Ru(i)):o=!1,zi(i,u),Lv(i,g,x),t0(i,g,x,u),s0(null,i,g,!0,o,u);case 19:return nw(o,i,u);case 22:return Kv(o,i,u)}throw Error(n(156,i.tag))};function Sw(o,i){return sy(o,i)}function kk(o,i,u,g){this.tag=o,this.key=u,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=i,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=g,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Yn(o,i,u,g){return new kk(o,i,u,g)}function k0(o){return o=o.prototype,!(!o||!o.isReactComponent)}function Sk(o){if(typeof o=="function")return k0(o)?1:0;if(o!=null){if(o=o.$$typeof,o===K)return 11;if(o===q)return 14}return 2}function Ho(o,i){var u=o.alternate;return u===null?(u=Yn(o.tag,i,o.key,o.mode),u.elementType=o.elementType,u.type=o.type,u.stateNode=o.stateNode,u.alternate=o,o.alternate=u):(u.pendingProps=i,u.type=o.type,u.flags=0,u.subtreeFlags=0,u.deletions=null),u.flags=o.flags&14680064,u.childLanes=o.childLanes,u.lanes=o.lanes,u.child=o.child,u.memoizedProps=o.memoizedProps,u.memoizedState=o.memoizedState,u.updateQueue=o.updateQueue,i=o.dependencies,u.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext},u.sibling=o.sibling,u.index=o.index,u.ref=o.ref,u}function ud(o,i,u,g,x,E){var _=2;if(g=o,typeof o=="function")k0(o)&&(_=1);else if(typeof o=="string")_=5;else e:switch(o){case B:return Rs(u.children,x,E,i);case O:_=8,x|=8;break;case R:return o=Yn(12,u,i,x|2),o.elementType=R,o.lanes=E,o;case Q:return o=Yn(13,u,i,x),o.elementType=Q,o.lanes=E,o;case ae:return o=Yn(19,u,i,x),o.elementType=ae,o.lanes=E,o;case te:return dd(u,x,E,i);default:if(typeof o=="object"&&o!==null)switch(o.$$typeof){case W:_=10;break e;case H:_=9;break e;case K:_=11;break e;case q:_=14;break e;case ee:_=16,g=null;break e}throw Error(n(130,o==null?o:typeof o,""))}return i=Yn(_,u,i,x),i.elementType=o,i.type=g,i.lanes=E,i}function Rs(o,i,u,g){return o=Yn(7,o,g,i),o.lanes=u,o}function dd(o,i,u,g){return o=Yn(22,o,g,i),o.elementType=te,o.lanes=u,o.stateNode={isHidden:!1},o}function S0(o,i,u){return o=Yn(6,o,null,i),o.lanes=u,o}function j0(o,i,u){return i=Yn(4,o.children!==null?o.children:[],o.key,i),i.lanes=u,i.stateNode={containerInfo:o.containerInfo,pendingChildren:null,implementation:o.implementation},i}function jk(o,i,u,g,x){this.tag=i,this.containerInfo=o,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=eh(0),this.expirationTimes=eh(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=eh(0),this.identifierPrefix=g,this.onRecoverableError=x,this.mutableSourceEagerHydrationData=null}function I0(o,i,u,g,x,E,_,M,z){return o=new jk(o,i,u,M,z),i===1?(i=1,E===!0&&(i|=8)):i=0,E=Yn(3,null,null,i),o.current=E,E.stateNode=o,E.memoizedState={element:g,isDehydrated:u,cache:null,transitions:null,pendingSuspenseBoundaries:null},zh(E),o}function Ik(o,i,u){var g=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:T,key:g==null?null:""+g,children:o,containerInfo:i,implementation:u}}function jw(o){if(!o)return Mo;o=o._reactInternals;e:{if(Es(o)!==o||o.tag!==1)throw Error(n(170));var i=o;do{switch(i.tag){case 3:i=i.stateNode.context;break e;case 1:if(hn(i.type)){i=i.stateNode.__reactInternalMemoizedMergedChildContext;break e}}i=i.return}while(i!==null);throw Error(n(171))}if(o.tag===1){var u=o.type;if(hn(u))return tv(o,u,i)}return i}function Iw(o,i,u,g,x,E,_,M,z){return o=I0(u,g,!0,o,x,E,_,M,z),o.context=jw(null),u=o.current,g=tn(),x=$o(u),E=to(g,x),E.callback=i??null,Lo(u,E,x),o.current.lanes=x,tc(o,x,g),gn(o,g),o}function fd(o,i,u,g){var x=i.current,E=tn(),_=$o(x);return u=jw(u),i.context===null?i.context=u:i.pendingContext=u,i=to(E,_),i.payload={element:o},g=g===void 0?null:g,g!==null&&(i.callback=g),o=Lo(x,i,_),o!==null&&(pr(o,x,_,E),$u(o,x,_)),_}function hd(o){if(o=o.current,!o.child)return null;switch(o.child.tag){case 5:return o.child.stateNode;default:return o.child.stateNode}}function Nw(o,i){if(o=o.memoizedState,o!==null&&o.dehydrated!==null){var u=o.retryLane;o.retryLane=u!==0&&u<i?u:i}}function N0(o,i){Nw(o,i),(o=o.alternate)&&Nw(o,i)}function Nk(){return null}var Pw=typeof reportError=="function"?reportError:function(o){console.error(o)};function P0(o){this._internalRoot=o}pd.prototype.render=P0.prototype.render=function(o){var i=this._internalRoot;if(i===null)throw Error(n(409));fd(o,i,null,null)},pd.prototype.unmount=P0.prototype.unmount=function(){var o=this._internalRoot;if(o!==null){this._internalRoot=null;var i=o.containerInfo;_s(function(){fd(null,o,null,null)}),i[Yr]=null}};function pd(o){this._internalRoot=o}pd.prototype.unstable_scheduleHydration=function(o){if(o){var i=hy();o={blockedOn:null,target:o,priority:i};for(var u=0;u<Bo.length&&i!==0&&i<Bo[u].priority;u++);Bo.splice(u,0,o),u===0&&gy(o)}};function B0(o){return!(!o||o.nodeType!==1&&o.nodeType!==9&&o.nodeType!==11)}function md(o){return!(!o||o.nodeType!==1&&o.nodeType!==9&&o.nodeType!==11&&(o.nodeType!==8||o.nodeValue!==" react-mount-point-unstable "))}function Bw(){}function Pk(o,i,u,g,x){if(x){if(typeof g=="function"){var E=g;g=function(){var J=hd(_);E.call(J)}}var _=Iw(i,g,o,0,null,!1,!1,"",Bw);return o._reactRootContainer=_,o[Yr]=_.current,mc(o.nodeType===8?o.parentNode:o),_s(),_}for(;x=o.lastChild;)o.removeChild(x);if(typeof g=="function"){var M=g;g=function(){var J=hd(z);M.call(J)}}var z=I0(o,0,!1,null,null,!1,!1,"",Bw);return o._reactRootContainer=z,o[Yr]=z.current,mc(o.nodeType===8?o.parentNode:o),_s(function(){fd(i,z,u,g)}),z}function gd(o,i,u,g,x){var E=u._reactRootContainer;if(E){var _=E;if(typeof x=="function"){var M=x;x=function(){var z=hd(_);M.call(z)}}fd(i,_,o,x)}else _=Pk(u,i,o,x,g);return hd(_)}dy=function(o){switch(o.tag){case 3:var i=o.stateNode;if(i.current.memoizedState.isDehydrated){var u=ec(i.pendingLanes);u!==0&&(th(i,u|1),gn(i,pt()),(qe&6)===0&&(Vi=pt()+500,Do()))}break;case 13:_s(function(){var g=eo(o,1);if(g!==null){var x=tn();pr(g,o,1,x)}}),N0(o,1)}},nh=function(o){if(o.tag===13){var i=eo(o,134217728);if(i!==null){var u=tn();pr(i,o,134217728,u)}N0(o,134217728)}},fy=function(o){if(o.tag===13){var i=$o(o),u=eo(o,i);if(u!==null){var g=tn();pr(u,o,i,g)}N0(o,i)}},hy=function(){return Ye},py=function(o,i){var u=Ye;try{return Ye=o,i()}finally{Ye=u}},jr=function(o,i,u){switch(i){case"input":if(ht(o,u),i=u.name,u.type==="radio"&&i!=null){for(u=o;u.parentNode;)u=u.parentNode;for(u=u.querySelectorAll("input[name="+JSON.stringify(""+i)+'][type="radio"]'),i=0;i<u.length;i++){var g=u[i];if(g!==o&&g.form===o.form){var x=Tu(g);if(!x)throw Error(n(90));Te(g),ht(g,x)}}}break;case"textarea":Xt(o,u);break;case"select":i=u.value,i!=null&&qn(o,!!u.multiple,i,!1)}},lu=C0,uu=_s;var Bk={usingClientEntryPoint:!1,Events:[vc,Ti,Tu,_n,ki,C0]},_c={findFiberByHostInstance:As,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},_k={bundleType:_c.bundleType,version:_c.version,rendererPackageName:_c.rendererPackageName,rendererConfig:_c.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:j.ReactCurrentDispatcher,findHostInstanceByFiber:function(o){return o=ry(o),o===null?null:o.stateNode},findFiberByHostInstance:_c.findFiberByHostInstance||Nk,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var yd=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!yd.isDisabled&&yd.supportsFiber)try{pu=yd.inject(_k),Nr=yd}catch{}}return yn.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Bk,yn.createPortal=function(o,i){var u=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!B0(i))throw Error(n(200));return Ik(o,i,null,u)},yn.createRoot=function(o,i){if(!B0(o))throw Error(n(299));var u=!1,g="",x=Pw;return i!=null&&(i.unstable_strictMode===!0&&(u=!0),i.identifierPrefix!==void 0&&(g=i.identifierPrefix),i.onRecoverableError!==void 0&&(x=i.onRecoverableError)),i=I0(o,1,!1,null,null,u,!1,g,x),o[Yr]=i.current,mc(o.nodeType===8?o.parentNode:o),new P0(i)},yn.findDOMNode=function(o){if(o==null)return null;if(o.nodeType===1)return o;var i=o._reactInternals;if(i===void 0)throw typeof o.render=="function"?Error(n(188)):(o=Object.keys(o).join(","),Error(n(268,o)));return o=ry(i),o=o===null?null:o.stateNode,o},yn.flushSync=function(o){return _s(o)},yn.hydrate=function(o,i,u){if(!md(i))throw Error(n(200));return gd(null,o,i,!0,u)},yn.hydrateRoot=function(o,i,u){if(!B0(o))throw Error(n(405));var g=u!=null&&u.hydratedSources||null,x=!1,E="",_=Pw;if(u!=null&&(u.unstable_strictMode===!0&&(x=!0),u.identifierPrefix!==void 0&&(E=u.identifierPrefix),u.onRecoverableError!==void 0&&(_=u.onRecoverableError)),i=Iw(i,null,o,1,u??null,x,!1,E,_),o[Yr]=i.current,mc(o),g)for(o=0;o<g.length;o++)u=g[o],x=u._getVersion,x=x(u._source),i.mutableSourceEagerHydrationData==null?i.mutableSourceEagerHydrationData=[u,x]:i.mutableSourceEagerHydrationData.push(u,x);return new pd(i)},yn.render=function(o,i,u){if(!md(i))throw Error(n(200));return gd(null,o,i,!1,u)},yn.unmountComponentAtNode=function(o){if(!md(o))throw Error(n(40));return o._reactRootContainer?(_s(function(){gd(null,null,o,!1,function(){o._reactRootContainer=null,o[Yr]=null})}),!0):!1},yn.unstable_batchedUpdates=C0,yn.unstable_renderSubtreeIntoContainer=function(o,i,u,g){if(!md(u))throw Error(n(200));if(o==null||o._reactInternals===void 0)throw Error(n(38));return gd(o,i,u,!1,g)},yn.version="18.3.1-next-f1338f8080-20240426",yn}var Uw;function Y2(){if(Uw)return R0.exports;Uw=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),R0.exports=zk(),R0.exports}var zw;function Wk(){if(zw)return wd;zw=1;var e=Y2();return wd.createRoot=e.createRoot,wd.hydrateRoot=e.hydrateRoot,wd}var $k=Wk(),P=zl();const k=K2(P),Na=[{inputs:[{components:[{name:"target",type:"address"},{name:"allowFailure",type:"bool"},{name:"callData",type:"bytes"}],name:"calls",type:"tuple[]"}],name:"aggregate3",outputs:[{components:[{name:"success",type:"bool"},{name:"returnData",type:"bytes"}],name:"returnData",type:"tuple[]"}],stateMutability:"view",type:"function"},{inputs:[{name:"addr",type:"address"}],name:"getEthBalance",outputs:[{name:"balance",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"getCurrentBlockTimestamp",outputs:[{internalType:"uint256",name:"timestamp",type:"uint256"}],stateMutability:"view",type:"function"}],Vp=[{name:"query",type:"function",stateMutability:"view",inputs:[{type:"tuple[]",name:"queries",components:[{type:"address",name:"sender"},{type:"string[]",name:"urls"},{type:"bytes",name:"data"}]}],outputs:[{type:"bool[]",name:"failures"},{type:"bytes[]",name:"responses"}]},{name:"HttpError",type:"error",inputs:[{type:"uint16",name:"status"},{type:"string",name:"message"}]}],J2=[{inputs:[{name:"dns",type:"bytes"}],name:"DNSDecodingFailed",type:"error"},{inputs:[{name:"ens",type:"string"}],name:"DNSEncodingFailed",type:"error"},{inputs:[],name:"EmptyAddress",type:"error"},{inputs:[{name:"status",type:"uint16"},{name:"message",type:"string"}],name:"HttpError",type:"error"},{inputs:[],name:"InvalidBatchGatewayResponse",type:"error"},{inputs:[{name:"errorData",type:"bytes"}],name:"ResolverError",type:"error"},{inputs:[{name:"name",type:"bytes"},{name:"resolver",type:"address"}],name:"ResolverNotContract",type:"error"},{inputs:[{name:"name",type:"bytes"}],name:"ResolverNotFound",type:"error"},{inputs:[{name:"primary",type:"string"},{name:"primaryAddress",type:"bytes"}],name:"ReverseAddressMismatch",type:"error"},{inputs:[{internalType:"bytes4",name:"selector",type:"bytes4"}],name:"UnsupportedResolverProfile",type:"error"}],Z2=[...J2,{name:"resolveWithGateways",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"},{name:"gateways",type:"string[]"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]}],qk=[...J2,{name:"reverseWithGateways",type:"function",stateMutability:"view",inputs:[{type:"bytes",name:"reverseName"},{type:"uint256",name:"coinType"},{type:"string[]",name:"gateways"}],outputs:[{type:"string",name:"resolvedName"},{type:"address",name:"resolver"},{type:"address",name:"reverseResolver"}]}],Ww=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],$w=[{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"}],outputs:[{name:"",type:"address"}]},{name:"addr",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"coinType",type:"uint256"}],outputs:[{name:"",type:"bytes"}]}],X2=[{name:"isValidSignature",type:"function",stateMutability:"view",inputs:[{name:"hash",type:"bytes32"},{name:"signature",type:"bytes"}],outputs:[{name:"",type:"bytes4"}]}],qw=[{inputs:[{name:"_signer",type:"address"},{name:"_hash",type:"bytes32"},{name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"},{inputs:[{name:"_signer",type:"address"},{name:"_hash",type:"bytes32"},{name:"_signature",type:"bytes"}],outputs:[{type:"bool"}],stateMutability:"nonpayable",type:"function",name:"isValidSig"}];function wr(e,{includeName:t=!1}={}){if(e.type!=="function"&&e.type!=="event"&&e.type!=="error")throw new o4(e.type);return`${e.name}(${bf(e.inputs,{includeName:t})})`}function bf(e,{includeName:t=!1}={}){return e?e.map(n=>Hk(n,{includeName:t})).join(t?", ":","):""}function Hk(e,{includeName:t}){return e.type.startsWith("tuple")?`(${bf(e.components,{includeName:t})})${e.type.slice(5)}`:e.type+(t&&e.name?` ${e.name}`:"")}function $r(e,{strict:t=!0}={}){return!e||typeof e!="string"?!1:t?/^0x[0-9a-fA-F]*$/.test(e):e.startsWith("0x")}function rt(e){return $r(e,{strict:!1})?Math.ceil((e.length-2)/2):e.length}const e5="2.47.12";let Oc={getDocsUrl:({docsBaseUrl:e,docsPath:t="",docsSlug:n})=>t?`${e??"https://viem.sh"}${t}${n?`#${n}`:""}`:void 0,version:`viem@${e5}`},re=class Qp extends Error{constructor(t,n={}){var l;const r=(()=>{var d;return n.cause instanceof Qp?n.cause.details:(d=n.cause)!=null&&d.message?n.cause.message:n.details})(),s=n.cause instanceof Qp&&n.cause.docsPath||n.docsPath,a=(l=Oc.getDocsUrl)==null?void 0:l.call(Oc,{...n,docsPath:s}),c=[t||"An error occurred.","",...n.metaMessages?[...n.metaMessages,""]:[],...a?[`Docs: ${a}`]:[],...r?[`Details: ${r}`]:[],...Oc.version?[`Version: ${Oc.version}`]:[]].join(`
42
- `);super(c,n.cause?{cause:n.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.details=r,this.docsPath=s,this.metaMessages=n.metaMessages,this.name=n.name??this.name,this.shortMessage=t,this.version=e5}walk(t){return t5(this,t)}};function t5(e,t){return t!=null&&t(e)?e:e&&typeof e=="object"&&"cause"in e&&e.cause!==void 0?t5(e.cause,t):t?null:e}class Vk extends re{constructor({docsPath:t}){super(["A constructor was not found on the ABI.","Make sure you are using the correct ABI and that the constructor exists on it."].join(`
43
- `),{docsPath:t,name:"AbiConstructorNotFoundError"})}}class Hw extends re{constructor({docsPath:t}){super(["Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.","Make sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists."].join(`
44
- `),{docsPath:t,name:"AbiConstructorParamsNotFoundError"})}}class n5 extends re{constructor({data:t,params:n,size:r}){super([`Data size of ${r} bytes is too small for given parameters.`].join(`
45
- `),{metaMessages:[`Params: (${bf(n,{includeName:!0})})`,`Data: ${t} (${r} bytes)`],name:"AbiDecodingDataSizeTooSmallError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=t,this.params=n,this.size=r}}class Wl extends re{constructor({cause:t}={}){super('Cannot decode zero data ("0x") with ABI parameters.',{name:"AbiDecodingZeroDataError",cause:t})}}class Qk extends re{constructor({expectedLength:t,givenLength:n,type:r}){super([`ABI encoding array length mismatch for type ${r}.`,`Expected length: ${t}`,`Given length: ${n}`].join(`
46
- `),{name:"AbiEncodingArrayLengthMismatchError"})}}class Gk extends re{constructor({expectedSize:t,value:n}){super(`Size of bytes "${n}" (bytes${rt(n)}) does not match expected size (bytes${t}).`,{name:"AbiEncodingBytesSizeMismatchError"})}}class Kk extends re{constructor({expectedLength:t,givenLength:n}){super(["ABI encoding params/values length mismatch.",`Expected length (params): ${t}`,`Given length (values): ${n}`].join(`
47
- `),{name:"AbiEncodingLengthMismatchError"})}}class Yk extends re{constructor(t,{docsPath:n}){super([`Arguments (\`args\`) were provided to "${t}", but "${t}" on the ABI does not contain any parameters (\`inputs\`).`,"Cannot encode error result without knowing what the parameter types are.","Make sure you are using the correct ABI and that the inputs exist on it."].join(`
48
- `),{docsPath:n,name:"AbiErrorInputsNotFoundError"})}}class Vw extends re{constructor(t,{docsPath:n}={}){super([`Error ${t?`"${t}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the error exists on it."].join(`
49
- `),{docsPath:n,name:"AbiErrorNotFoundError"})}}class r5 extends re{constructor(t,{docsPath:n,cause:r}){super([`Encoded error signature "${t}" not found on ABI.`,"Make sure you are using the correct ABI and that the error exists on it.",`You can look up the decoded signature here: https://4byte.sourcify.dev/?q=${t}.`].join(`
50
- `),{docsPath:n,name:"AbiErrorSignatureNotFoundError",cause:r}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.signature=t}}class Jk extends re{constructor({docsPath:t}){super("Cannot extract event signature from empty topics.",{docsPath:t,name:"AbiEventSignatureEmptyTopicsError"})}}class Zk extends re{constructor(t,{docsPath:n}){super([`Encoded event signature "${t}" not found on ABI.`,"Make sure you are using the correct ABI and that the event exists on it.",`You can look up the signature here: https://4byte.sourcify.dev/?q=${t}.`].join(`
51
- `),{docsPath:n,name:"AbiEventSignatureNotFoundError"})}}class Qw extends re{constructor(t,{docsPath:n}={}){super([`Event ${t?`"${t}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the event exists on it."].join(`
52
- `),{docsPath:n,name:"AbiEventNotFoundError"})}}class Pa extends re{constructor(t,{docsPath:n}={}){super([`Function ${t?`"${t}" `:""}not found on ABI.`,"Make sure you are using the correct ABI and that the function exists on it."].join(`
53
- `),{docsPath:n,name:"AbiFunctionNotFoundError"})}}class o5 extends re{constructor(t,{docsPath:n}){super([`Function "${t}" does not contain any \`outputs\` on ABI.`,"Cannot decode function result without knowing what the parameter types are.","Make sure you are using the correct ABI and that the function exists on it."].join(`
54
- `),{docsPath:n,name:"AbiFunctionOutputsNotFoundError"})}}class Xk extends re{constructor(t,{docsPath:n}){super([`Encoded function signature "${t}" not found on ABI.`,"Make sure you are using the correct ABI and that the function exists on it.",`You can look up the signature here: https://4byte.sourcify.dev/?q=${t}.`].join(`
55
- `),{docsPath:n,name:"AbiFunctionSignatureNotFoundError"})}}class e4 extends re{constructor(t,n){super("Found ambiguous types in overloaded ABI items.",{metaMessages:[`\`${t.type}\` in \`${wr(t.abiItem)}\`, and`,`\`${n.type}\` in \`${wr(n.abiItem)}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."],name:"AbiItemAmbiguityError"})}}let t4=class extends re{constructor({expectedSize:t,givenSize:n}){super(`Expected bytes${t}, got bytes${n}.`,{name:"BytesSizeMismatchError"})}};class Yd extends re{constructor({abiItem:t,data:n,params:r,size:s}){super([`Data size of ${s} bytes is too small for non-indexed event parameters.`].join(`
56
- `),{metaMessages:[`Params: (${bf(r,{includeName:!0})})`,`Data: ${n} (${s} bytes)`],name:"DecodeLogDataMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"params",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"size",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=t,this.data=n,this.params=r,this.size=s}}class d1 extends re{constructor({abiItem:t,param:n}){super([`Expected a topic for indexed event parameter${n.name?` "${n.name}"`:""} on event "${wr(t,{includeName:!0})}".`].join(`
57
- `),{name:"DecodeLogTopicsMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=t}}class n4 extends re{constructor(t,{docsPath:n}){super([`Type "${t}" is not a valid encoding type.`,"Please provide a valid ABI type."].join(`
58
- `),{docsPath:n,name:"InvalidAbiEncodingType"})}}class r4 extends re{constructor(t,{docsPath:n}){super([`Type "${t}" is not a valid decoding type.`,"Please provide a valid ABI type."].join(`
59
- `),{docsPath:n,name:"InvalidAbiDecodingType"})}}let s5=class extends re{constructor(t){super([`Value "${t}" is not a valid array.`].join(`
60
- `),{name:"InvalidArrayError"})}};class o4 extends re{constructor(t){super([`"${t}" is not a valid definition type.`,'Valid types: "function", "event", "error"'].join(`
61
- `),{name:"InvalidDefinitionTypeError"})}}class Pz extends re{constructor(t){super(`Type "${t}" is not supported for packed encoding.`,{name:"UnsupportedPackedAbiType"})}}let un=class extends re{constructor({address:t}){super(`Address "${t}" is invalid.`,{metaMessages:["- Address must be a hex value of 20 bytes (40 hex characters).","- Address must match its checksum counterpart."],name:"InvalidAddressError"})}},i5=class extends re{constructor({offset:t,position:n,size:r}){super(`Slice ${n==="start"?"starting":"ending"} at offset "${t}" is out-of-bounds (size: ${r}).`,{name:"SliceOffsetOutOfBoundsError"})}},a5=class extends re{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (${t}) exceeds padding size (${n}).`,{name:"SizeExceedsPaddingSizeError"})}};class Gw extends re{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} is expected to be ${n} ${r} long, but is ${t} ${r} long.`,{name:"InvalidBytesLengthError"})}}function Ua(e,{dir:t,size:n=32}={}){return typeof e=="string"?ls(e,{dir:t,size:n}):s4(e,{dir:t,size:n})}function ls(e,{dir:t,size:n=32}={}){if(n===null)return e;const r=e.replace("0x","");if(r.length>n*2)throw new a5({size:Math.ceil(r.length/2),targetSize:n,type:"hex"});return`0x${r[t==="right"?"padEnd":"padStart"](n*2,"0")}`}function s4(e,{dir:t,size:n=32}={}){if(n===null)return e;if(e.length>n)throw new a5({size:e.length,targetSize:n,type:"bytes"});const r=new Uint8Array(n);for(let s=0;s<n;s++){const a=t==="right";r[a?s:n-s-1]=e[a?s:e.length-s-1]}return r}let f1=class extends re{constructor({max:t,min:n,signed:r,size:s,value:a}){super(`Number "${a}" is not in safe ${s?`${s*8}-bit ${r?"signed":"unsigned"} `:""}integer range ${t?`(${n} to ${t})`:`(above ${n})`}`,{name:"IntegerOutOfRangeError"})}},i4=class extends re{constructor(t){super(`Bytes value "${t}" is not a valid boolean. The bytes array must contain a single byte of either a 0 or 1 value.`,{name:"InvalidBytesBooleanError"})}};class a4 extends re{constructor(t){super(`Hex value "${t}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`,{name:"InvalidHexBooleanError"})}}let c4=class extends re{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed ${n} bytes. Given size: ${t} bytes.`,{name:"SizeOverflowError"})}};function Un(e,{dir:t="left"}={}){let n=typeof e=="string"?e.replace("0x",""):e,r=0;for(let s=0;s<n.length-1&&n[t==="left"?s:n.length-s-1].toString()==="0";s++)r++;return n=t==="left"?n.slice(r):n.slice(0,n.length-r),typeof e=="string"?(n.length===1&&t==="right"&&(n=`${n}0`),`0x${n.length%2===1?`0${n}`:n}`):n}function sr(e,{size:t}){if(rt(e)>t)throw new c4({givenSize:rt(e),maxSize:t})}function an(e,t={}){const{signed:n}=t;t.size&&sr(e,{size:t.size});const r=BigInt(e);if(!n)return r;const s=(e.length-2)/2,a=(1n<<BigInt(s)*8n-1n)-1n;return r<=a?r:r-BigInt(`0x${"f".padStart(s*2,"f")}`)-1n}function l4(e,t={}){let n=e;if(t.size&&(sr(n,{size:t.size}),n=Un(n)),Un(n)==="0x00")return!1;if(Un(n)==="0x01")return!0;throw new a4(n)}function br(e,t={}){const n=an(e,t),r=Number(n);if(!Number.isSafeInteger(r))throw new f1({max:`${Number.MAX_SAFE_INTEGER}`,min:`${Number.MIN_SAFE_INTEGER}`,signed:t.signed,size:t.size,value:`${n}n`});return r}function c5(e,t={}){let n=xr(e);return t.size&&(sr(n,{size:t.size}),n=Un(n,{dir:"right"})),new TextDecoder().decode(n)}const u4=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function An(e,t={}){return typeof e=="number"||typeof e=="bigint"?le(e,t):typeof e=="string"?Ba(e,t):typeof e=="boolean"?l5(e,t):bt(e,t)}function l5(e,t={}){const n=`0x${Number(e)}`;return typeof t.size=="number"?(sr(n,{size:t.size}),Ua(n,{size:t.size})):n}function bt(e,t={}){let n="";for(let s=0;s<e.length;s++)n+=u4[e[s]];const r=`0x${n}`;return typeof t.size=="number"?(sr(r,{size:t.size}),Ua(r,{dir:"right",size:t.size})):r}function le(e,t={}){const{signed:n,size:r}=t,s=BigInt(e);let a;r?n?a=(1n<<BigInt(r)*8n-1n)-1n:a=2n**(BigInt(r)*8n)-1n:typeof e=="number"&&(a=BigInt(Number.MAX_SAFE_INTEGER));const c=typeof a=="bigint"&&n?-a-1n:0;if(a&&s>a||s<c){const d=typeof e=="bigint"?"n":"";throw new f1({max:a?`${a}${d}`:void 0,min:`${c}${d}`,signed:n,size:r,value:`${e}${d}`})}const l=`0x${(n&&s<0?(1n<<BigInt(r*8))+BigInt(s):s).toString(16)}`;return r?Ua(l,{size:r}):l}const d4=new TextEncoder;function Ba(e,t={}){const n=d4.encode(e);return bt(n,t)}const f4=new TextEncoder;function za(e,t={}){return typeof e=="number"||typeof e=="bigint"?p4(e,t):typeof e=="boolean"?h4(e,t):$r(e)?xr(e,t):oi(e,t)}function h4(e,t={}){const n=new Uint8Array(1);return n[0]=Number(e),typeof t.size=="number"?(sr(n,{size:t.size}),Ua(n,{size:t.size})):n}const oo={zero:48,nine:57,A:65,F:70,a:97,f:102};function Kw(e){if(e>=oo.zero&&e<=oo.nine)return e-oo.zero;if(e>=oo.A&&e<=oo.F)return e-(oo.A-10);if(e>=oo.a&&e<=oo.f)return e-(oo.a-10)}function xr(e,t={}){let n=e;t.size&&(sr(n,{size:t.size}),n=Ua(n,{dir:"right",size:t.size}));let r=n.slice(2);r.length%2&&(r=`0${r}`);const s=r.length/2,a=new Uint8Array(s);for(let c=0,l=0;c<s;c++){const d=Kw(r.charCodeAt(l++)),f=Kw(r.charCodeAt(l++));if(d===void 0||f===void 0)throw new re(`Invalid byte sequence ("${r[l-2]}${r[l-1]}" in "${r}").`);a[c]=d*16+f}return a}function p4(e,t){const n=le(e,t);return xr(n)}function oi(e,t={}){const n=f4.encode(e);return typeof t.size=="number"?(sr(n,{size:t.size}),Ua(n,{dir:"right",size:t.size})):n}const bd=BigInt(2**32-1),Yw=BigInt(32);function m4(e,t=!1){return t?{h:Number(e&bd),l:Number(e>>Yw&bd)}:{h:Number(e>>Yw&bd)|0,l:Number(e&bd)|0}}function u5(e,t=!1){const n=e.length;let r=new Uint32Array(n),s=new Uint32Array(n);for(let a=0;a<n;a++){const{h:c,l}=m4(e[a],t);[r[a],s[a]]=[c,l]}return[r,s]}const Jw=(e,t,n)=>e>>>n,Zw=(e,t,n)=>e<<32-n|t>>>n,Gi=(e,t,n)=>e>>>n|t<<32-n,Ki=(e,t,n)=>e<<32-n|t>>>n,xd=(e,t,n)=>e<<64-n|t>>>n-32,Cd=(e,t,n)=>e>>>n-32|t<<64-n,g4=(e,t,n)=>e<<n|t>>>32-n,y4=(e,t,n)=>t<<n|e>>>32-n,v4=(e,t,n)=>t<<n-32|e>>>64-n,w4=(e,t,n)=>e<<n-32|t>>>64-n;function so(e,t,n,r){const s=(t>>>0)+(r>>>0);return{h:e+n+(s/2**32|0)|0,l:s|0}}const b4=(e,t,n)=>(e>>>0)+(t>>>0)+(n>>>0),x4=(e,t,n,r)=>t+n+r+(e/2**32|0)|0,C4=(e,t,n,r)=>(e>>>0)+(t>>>0)+(n>>>0)+(r>>>0),E4=(e,t,n,r,s)=>t+n+r+s+(e/2**32|0)|0,A4=(e,t,n,r,s)=>(e>>>0)+(t>>>0)+(n>>>0)+(r>>>0)+(s>>>0),k4=(e,t,n,r,s,a)=>t+n+r+s+a+(e/2**32|0)|0,Yi=typeof globalThis=="object"&&"crypto"in globalThis?globalThis.crypto:void 0;/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */function S4(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"}function Zc(e){if(!Number.isSafeInteger(e)||e<0)throw new Error("positive integer expected, got "+e)}function ds(e,...t){if(!S4(e))throw new Error("Uint8Array expected");if(t.length>0&&!t.includes(e.length))throw new Error("Uint8Array expected of length "+t+", got length="+e.length)}function j4(e){if(typeof e!="function"||typeof e.create!="function")throw new Error("Hash should be wrapped by utils.createHasher");Zc(e.outputLen),Zc(e.blockLen)}function _a(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function d5(e,t){ds(e);const n=t.outputLen;if(e.length<n)throw new Error("digestInto() expects output buffer of length at least "+n)}function I4(e){return new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4))}function fs(...e){for(let t=0;t<e.length;t++)e[t].fill(0)}function F0(e){return new DataView(e.buffer,e.byteOffset,e.byteLength)}function Or(e,t){return e<<32-t|e>>>t}const N4=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;function P4(e){return e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255}function B4(e){for(let t=0;t<e.length;t++)e[t]=P4(e[t]);return e}const Xw=N4?e=>e:B4,f5=typeof Uint8Array.from([]).toHex=="function"&&typeof Uint8Array.fromHex=="function",_4=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function Dz(e){if(ds(e),f5)return e.toHex();let t="";for(let n=0;n<e.length;n++)t+=_4[e[n]];return t}const io={_0:48,_9:57,A:65,F:70,a:97,f:102};function eb(e){if(e>=io._0&&e<=io._9)return e-io._0;if(e>=io.A&&e<=io.F)return e-(io.A-10);if(e>=io.a&&e<=io.f)return e-(io.a-10)}function Fz(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);if(f5)return Uint8Array.fromHex(e);const t=e.length,n=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const r=new Uint8Array(n);for(let s=0,a=0;s<n;s++,a+=2){const c=eb(e.charCodeAt(a)),l=eb(e.charCodeAt(a+1));if(c===void 0||l===void 0){const d=e[a]+e[a+1];throw new Error('hex string expected, got non-hex character "'+d+'" at index '+a)}r[s]=c*16+l}return r}function T4(e){if(typeof e!="string")throw new Error("string expected");return new Uint8Array(new TextEncoder().encode(e))}function xf(e){return typeof e=="string"&&(e=T4(e)),ds(e),e}function O4(...e){let t=0;for(let r=0;r<e.length;r++){const s=e[r];ds(s),t+=s.length}const n=new Uint8Array(t);for(let r=0,s=0;r<e.length;r++){const a=e[r];n.set(a,s),s+=a.length}return n}class h1{}function Cf(e){const t=r=>e().update(xf(r)).digest(),n=e();return t.outputLen=n.outputLen,t.blockLen=n.blockLen,t.create=()=>e(),t}function R4(e=32){if(Yi&&typeof Yi.getRandomValues=="function")return Yi.getRandomValues(new Uint8Array(e));if(Yi&&typeof Yi.randomBytes=="function")return Uint8Array.from(Yi.randomBytes(e));throw new Error("crypto.getRandomValues must be defined")}const M4=BigInt(0),Rc=BigInt(1),D4=BigInt(2),F4=BigInt(7),L4=BigInt(256),U4=BigInt(113),h5=[],p5=[],m5=[];for(let e=0,t=Rc,n=1,r=0;e<24;e++){[n,r]=[r,(2*n+3*r)%5],h5.push(2*(5*r+n)),p5.push((e+1)*(e+2)/2%64);let s=M4;for(let a=0;a<7;a++)t=(t<<Rc^(t>>F4)*U4)%L4,t&D4&&(s^=Rc<<(Rc<<BigInt(a))-Rc);m5.push(s)}const g5=u5(m5,!0),z4=g5[0],W4=g5[1],tb=(e,t,n)=>n>32?v4(e,t,n):g4(e,t,n),nb=(e,t,n)=>n>32?w4(e,t,n):y4(e,t,n);function $4(e,t=24){const n=new Uint32Array(10);for(let r=24-t;r<24;r++){for(let c=0;c<10;c++)n[c]=e[c]^e[c+10]^e[c+20]^e[c+30]^e[c+40];for(let c=0;c<10;c+=2){const l=(c+8)%10,d=(c+2)%10,f=n[d],h=n[d+1],p=tb(f,h,1)^n[l],m=nb(f,h,1)^n[l+1];for(let y=0;y<50;y+=10)e[c+y]^=p,e[c+y+1]^=m}let s=e[2],a=e[3];for(let c=0;c<24;c++){const l=p5[c],d=tb(s,a,l),f=nb(s,a,l),h=h5[c];s=e[h],a=e[h+1],e[h]=d,e[h+1]=f}for(let c=0;c<50;c+=10){for(let l=0;l<10;l++)n[l]=e[c+l];for(let l=0;l<10;l++)e[c+l]^=~n[(l+2)%10]&n[(l+4)%10]}e[0]^=z4[r],e[1]^=W4[r]}fs(n)}class p1 extends h1{constructor(t,n,r,s=!1,a=24){if(super(),this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,this.enableXOF=!1,this.blockLen=t,this.suffix=n,this.outputLen=r,this.enableXOF=s,this.rounds=a,Zc(r),!(0<t&&t<200))throw new Error("only keccak-f1600 function is supported");this.state=new Uint8Array(200),this.state32=I4(this.state)}clone(){return this._cloneInto()}keccak(){Xw(this.state32),$4(this.state32,this.rounds),Xw(this.state32),this.posOut=0,this.pos=0}update(t){_a(this),t=xf(t),ds(t);const{blockLen:n,state:r}=this,s=t.length;for(let a=0;a<s;){const c=Math.min(n-this.pos,s-a);for(let l=0;l<c;l++)r[this.pos++]^=t[a++];this.pos===n&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;const{state:t,suffix:n,pos:r,blockLen:s}=this;t[r]^=n,(n&128)!==0&&r===s-1&&this.keccak(),t[s-1]^=128,this.keccak()}writeInto(t){_a(this,!1),ds(t),this.finish();const n=this.state,{blockLen:r}=this;for(let s=0,a=t.length;s<a;){this.posOut>=r&&this.keccak();const c=Math.min(r-this.posOut,a-s);t.set(n.subarray(this.posOut,this.posOut+c),s),this.posOut+=c,s+=c}return t}xofInto(t){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(t)}xof(t){return Zc(t),this.xofInto(new Uint8Array(t))}digestInto(t){if(d5(t,this),this.finished)throw new Error("digest() was already called");return this.writeInto(t),this.destroy(),t}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,fs(this.state)}_cloneInto(t){const{blockLen:n,suffix:r,outputLen:s,rounds:a,enableXOF:c}=this;return t||(t=new p1(n,r,s,c,a)),t.state32.set(this.state32),t.pos=this.pos,t.posOut=this.posOut,t.finished=this.finished,t.rounds=a,t.suffix=r,t.outputLen=s,t.enableXOF=c,t.destroyed=this.destroyed,t}}const q4=(e,t,n)=>Cf(()=>new p1(t,e,n)),y5=q4(1,136,256/8);function Lt(e,t){const n=t||"hex",r=y5($r(e,{strict:!1})?za(e):e);return n==="bytes"?r:An(r)}let $l=class extends Map{constructor(t){super(),Object.defineProperty(this,"maxSize",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.maxSize=t}get(t){const n=super.get(t);return super.has(t)&&(super.delete(t),super.set(t,n)),n}set(t,n){if(super.has(t)&&super.delete(t),super.set(t,n),this.maxSize&&this.size>this.maxSize){const r=super.keys().next().value;r!==void 0&&super.delete(r)}return this}};const H4=/^0x[a-fA-F0-9]{40}$/,L0=new $l(8192);function xt(e,t){const{strict:n=!0}=t??{},r=`${e}.${n}`;if(L0.has(r))return L0.get(r);const s=H4.test(e)?e.toLowerCase()===e?!0:n?Ef(e)===e:!0:!1;return L0.set(r,s),s}const U0=new $l(8192);function Ef(e,t){if(U0.has(`${e}.${t}`))return U0.get(`${e}.${t}`);const n=t?`${t}${e.toLowerCase()}`:e.substring(2).toLowerCase(),r=Lt(oi(n),"bytes"),s=(t?n.substring(`${t}0x`.length):n).split("");for(let c=0;c<40;c+=2)r[c>>1]>>4>=8&&s[c]&&(s[c]=s[c].toUpperCase()),(r[c>>1]&15)>=8&&s[c+1]&&(s[c+1]=s[c+1].toUpperCase());const a=`0x${s.join("")}`;return U0.set(`${e}.${t}`,a),a}function jt(e,t){if(!xt(e,{strict:!1}))throw new un({address:e});return Ef(e,t)}let rb=class extends re{constructor({offset:t}){super(`Offset \`${t}\` cannot be negative.`,{name:"NegativeOffsetError"})}},v5=class extends re{constructor({length:t,position:n}){super(`Position \`${n}\` is out of bounds (\`0 < position < ${t}\`).`,{name:"PositionOutOfBoundsError"})}},V4=class extends re{constructor({count:t,limit:n}){super(`Recursive read limit of \`${n}\` exceeded (recursive read count: \`${t}\`).`,{name:"RecursiveReadLimitExceededError"})}};const Q4={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,positionReadCount:new Map,recursiveReadCount:0,recursiveReadLimit:Number.POSITIVE_INFINITY,assertReadLimit(){if(this.recursiveReadCount>=this.recursiveReadLimit)throw new V4({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(e){if(e<0||e>this.bytes.length-1)throw new v5({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new rb({offset:e});const t=this.position-e;this.assertPosition(t),this.position=t},getReadCount(e){return this.positionReadCount.get(e||this.position)||0},incrementPosition(e){if(e<0)throw new rb({offset:e});const t=this.position+e;this.assertPosition(t),this.position=t},inspectByte(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectBytes(e,t){const n=t??this.position;return this.assertPosition(n+e-1),this.bytes.subarray(n,n+e)},inspectUint8(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectUint16(e){const t=e??this.position;return this.assertPosition(t+1),this.dataView.getUint16(t)},inspectUint24(e){const t=e??this.position;return this.assertPosition(t+2),(this.dataView.getUint16(t)<<8)+this.dataView.getUint8(t+2)},inspectUint32(e){const t=e??this.position;return this.assertPosition(t+3),this.dataView.getUint32(t)},pushByte(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushBytes(e){this.assertPosition(this.position+e.length-1),this.bytes.set(e,this.position),this.position+=e.length},pushUint8(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushUint16(e){this.assertPosition(this.position+1),this.dataView.setUint16(this.position,e),this.position+=2},pushUint24(e){this.assertPosition(this.position+2),this.dataView.setUint16(this.position,e>>8),this.dataView.setUint8(this.position+2,e&255),this.position+=3},pushUint32(e){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,e),this.position+=4},readByte(){this.assertReadLimit(),this._touch();const e=this.inspectByte();return this.position++,e},readBytes(e,t){this.assertReadLimit(),this._touch();const n=this.inspectBytes(e);return this.position+=t??e,n},readUint8(){this.assertReadLimit(),this._touch();const e=this.inspectUint8();return this.position+=1,e},readUint16(){this.assertReadLimit(),this._touch();const e=this.inspectUint16();return this.position+=2,e},readUint24(){this.assertReadLimit(),this._touch();const e=this.inspectUint24();return this.position+=3,e},readUint32(){this.assertReadLimit(),this._touch();const e=this.inspectUint32();return this.position+=4,e},get remaining(){return this.bytes.length-this.position},setPosition(e){const t=this.position;return this.assertPosition(e),this.position=e,()=>this.position=t},_touch(){if(this.recursiveReadLimit===Number.POSITIVE_INFINITY)return;const e=this.getReadCount();this.positionReadCount.set(this.position,e+1),e>0&&this.recursiveReadCount++}};function m1(e,{recursiveReadLimit:t=8192}={}){const n=Object.create(Q4);return n.bytes=e,n.dataView=new DataView(e.buffer??e,e.byteOffset,e.byteLength),n.positionReadCount=new Map,n.recursiveReadLimit=t,n}function hs(e,t,n,{strict:r}={}){return $r(e,{strict:!1})?G4(e,t,n,{strict:r}):x5(e,t,n,{strict:r})}function w5(e,t){if(typeof t=="number"&&t>0&&t>rt(e)-1)throw new i5({offset:t,position:"start",size:rt(e)})}function b5(e,t,n){if(typeof t=="number"&&typeof n=="number"&&rt(e)!==n-t)throw new i5({offset:n,position:"end",size:rt(e)})}function x5(e,t,n,{strict:r}={}){w5(e,t);const s=e.slice(t,n);return r&&b5(s,t,n),s}function G4(e,t,n,{strict:r}={}){w5(e,t);const s=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return r&&b5(s,t,n),s}function K4(e,t={}){typeof t.size<"u"&&sr(e,{size:t.size});const n=bt(e,t);return an(n,t)}function Y4(e,t={}){let n=e;if(typeof t.size<"u"&&(sr(n,{size:t.size}),n=Un(n)),n.length>1||n[0]>1)throw new i4(n);return!!n[0]}function vo(e,t={}){typeof t.size<"u"&&sr(e,{size:t.size});const n=bt(e,t);return br(n,t)}function J4(e,t={}){let n=e;return typeof t.size<"u"&&(sr(n,{size:t.size}),n=Un(n,{dir:"right"})),new TextDecoder().decode(n)}function rr(e){return typeof e[0]=="string"?Ar(e):Z4(e)}function Z4(e){let t=0;for(const s of e)t+=s.length;const n=new Uint8Array(t);let r=0;for(const s of e)n.set(s,r),r+=s.length;return n}function Ar(e){return`0x${e.reduce((t,n)=>t+n.replace("0x",""),"")}`}const $z=/^(.*)\[([0-9]*)\]$/,X4=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,C5=/^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;function wi(e,t){if(e.length!==t.length)throw new Kk({expectedLength:e.length,givenLength:t.length});const n=eS({params:e,values:t}),r=y1(n);return r.length===0?"0x":r}function eS({params:e,values:t}){const n=[];for(let r=0;r<e.length;r++)n.push(g1({param:e[r],value:t[r]}));return n}function g1({param:e,value:t}){const n=v1(e.type);if(n){const[r,s]=n;return nS(t,{length:r,param:{...e,type:s}})}if(e.type==="tuple")return aS(t,{param:e});if(e.type==="address")return tS(t);if(e.type==="bool")return oS(t);if(e.type.startsWith("uint")||e.type.startsWith("int")){const r=e.type.startsWith("int"),[,,s="256"]=C5.exec(e.type)??[];return sS(t,{signed:r,size:Number(s)})}if(e.type.startsWith("bytes"))return rS(t,{param:e});if(e.type==="string")return iS(t);throw new n4(e.type,{docsPath:"/docs/contract/encodeAbiParameters"})}function y1(e){let t=0;for(let a=0;a<e.length;a++){const{dynamic:c,encoded:l}=e[a];c?t+=32:t+=rt(l)}const n=[],r=[];let s=0;for(let a=0;a<e.length;a++){const{dynamic:c,encoded:l}=e[a];c?(n.push(le(t+s,{size:32})),r.push(l),s+=rt(l)):n.push(l)}return rr([...n,...r])}function tS(e){if(!xt(e))throw new un({address:e});return{dynamic:!1,encoded:ls(e.toLowerCase())}}function nS(e,{length:t,param:n}){const r=t===null;if(!Array.isArray(e))throw new s5(e);if(!r&&e.length!==t)throw new Qk({expectedLength:t,givenLength:e.length,type:`${n.type}[${t}]`});let s=!1;const a=[];for(let c=0;c<e.length;c++){const l=g1({param:n,value:e[c]});l.dynamic&&(s=!0),a.push(l)}if(r||s){const c=y1(a);if(r){const l=le(a.length,{size:32});return{dynamic:!0,encoded:a.length>0?rr([l,c]):l}}if(s)return{dynamic:!0,encoded:c}}return{dynamic:!1,encoded:rr(a.map(({encoded:c})=>c))}}function rS(e,{param:t}){const[,n]=t.type.split("bytes"),r=rt(e);if(!n){let s=e;return r%32!==0&&(s=ls(s,{dir:"right",size:Math.ceil((e.length-2)/2/32)*32})),{dynamic:!0,encoded:rr([ls(le(r,{size:32})),s])}}if(r!==Number.parseInt(n,10))throw new Gk({expectedSize:Number.parseInt(n,10),value:e});return{dynamic:!1,encoded:ls(e,{dir:"right"})}}function oS(e){if(typeof e!="boolean")throw new re(`Invalid boolean value: "${e}" (type: ${typeof e}). Expected: \`true\` or \`false\`.`);return{dynamic:!1,encoded:ls(l5(e))}}function sS(e,{signed:t,size:n=256}){if(typeof n=="number"){const r=2n**(BigInt(n)-(t?1n:0n))-1n,s=t?-r-1n:0n;if(e>r||e<s)throw new f1({max:r.toString(),min:s.toString(),signed:t,size:n/8,value:e.toString()})}return{dynamic:!1,encoded:le(e,{size:32,signed:t})}}function iS(e){const t=Ba(e),n=Math.ceil(rt(t)/32),r=[];for(let s=0;s<n;s++)r.push(ls(hs(t,s*32,(s+1)*32),{dir:"right"}));return{dynamic:!0,encoded:rr([ls(le(rt(t),{size:32})),...r])}}function aS(e,{param:t}){let n=!1;const r=[];for(let s=0;s<t.components.length;s++){const a=t.components[s],c=Array.isArray(e)?s:a.name,l=g1({param:a,value:e[c]});r.push(l),l.dynamic&&(n=!0)}return{dynamic:n,encoded:n?y1(r):rr(r.map(({encoded:s})=>s))}}function v1(e){const t=e.match(/^(.*)\[(\d+)?\]$/);return t?[t[2]?Number(t[2]):null,t[1]]:void 0}function ql(e,t){const n=typeof t=="string"?xr(t):t,r=m1(n);if(rt(n)===0&&e.length>0)throw new Wl;if(rt(t)&&rt(t)<32)throw new n5({data:typeof t=="string"?t:bt(t),params:e,size:rt(t)});let s=0;const a=[];for(let c=0;c<e.length;++c){const l=e[c];r.setPosition(s);const[d,f]=ua(r,l,{staticPosition:0});s+=f,a.push(d)}return a}function ua(e,t,{staticPosition:n}){const r=v1(t.type);if(r){const[s,a]=r;return lS(e,{...t,type:a},{length:s,staticPosition:n})}if(t.type==="tuple")return hS(e,t,{staticPosition:n});if(t.type==="address")return cS(e);if(t.type==="bool")return uS(e);if(t.type.startsWith("bytes"))return dS(e,t,{staticPosition:n});if(t.type.startsWith("uint")||t.type.startsWith("int"))return fS(e,t);if(t.type==="string")return pS(e,{staticPosition:n});throw new r4(t.type,{docsPath:"/docs/contract/decodeAbiParameters"})}const ob=32,Gp=32;function cS(e){const t=e.readBytes(32);return[Ef(bt(x5(t,-20))),32]}function lS(e,t,{length:n,staticPosition:r}){if(!n){const c=vo(e.readBytes(Gp)),l=r+c,d=l+ob;e.setPosition(l);const f=vo(e.readBytes(ob)),h=Xc(t);let p=0;const m=[];for(let y=0;y<f;++y){e.setPosition(d+(h?y*32:p));const[v,w]=ua(e,t,{staticPosition:d});p+=w,m.push(v)}return e.setPosition(r+32),[m,32]}if(Xc(t)){const c=vo(e.readBytes(Gp)),l=r+c,d=[];for(let f=0;f<n;++f){e.setPosition(l+f*32);const[h]=ua(e,t,{staticPosition:l});d.push(h)}return e.setPosition(r+32),[d,32]}let s=0;const a=[];for(let c=0;c<n;++c){const[l,d]=ua(e,t,{staticPosition:r+s});s+=d,a.push(l)}return[a,s]}function uS(e){return[Y4(e.readBytes(32),{size:32}),32]}function dS(e,t,{staticPosition:n}){const[r,s]=t.type.split("bytes");if(!s){const c=vo(e.readBytes(32));e.setPosition(n+c);const l=vo(e.readBytes(32));if(l===0)return e.setPosition(n+32),["0x",32];const d=e.readBytes(l);return e.setPosition(n+32),[bt(d),32]}return[bt(e.readBytes(Number.parseInt(s,10),32)),32]}function fS(e,t){const n=t.type.startsWith("int"),r=Number.parseInt(t.type.split("int")[1]||"256",10),s=e.readBytes(32);return[r>48?K4(s,{signed:n}):vo(s,{signed:n}),32]}function hS(e,t,{staticPosition:n}){const r=t.components.length===0||t.components.some(({name:c})=>!c),s=r?[]:{};let a=0;if(Xc(t)){const c=vo(e.readBytes(Gp)),l=n+c;for(let d=0;d<t.components.length;++d){const f=t.components[d];e.setPosition(l+a);const[h,p]=ua(e,f,{staticPosition:l});a+=p,s[r?d:f==null?void 0:f.name]=h}return e.setPosition(n+32),[s,32]}for(let c=0;c<t.components.length;++c){const l=t.components[c],[d,f]=ua(e,l,{staticPosition:n});s[r?c:l==null?void 0:l.name]=d,a+=f}return[s,a]}function pS(e,{staticPosition:t}){const n=vo(e.readBytes(32)),r=t+n;e.setPosition(r);const s=vo(e.readBytes(32));if(s===0)return e.setPosition(t+32),["",32];const a=e.readBytes(s,32),c=J4(Un(a));return e.setPosition(t+32),[c,32]}function Xc(e){var r;const{type:t}=e;if(t==="string"||t==="bytes"||t.endsWith("[]"))return!0;if(t==="tuple")return(r=e.components)==null?void 0:r.some(Xc);const n=v1(e.type);return!!(n&&Xc({...e,type:n[1]}))}const mS=e=>Lt(za(e));function gS(e){return mS(e)}const yS="1.2.3";let Sn=class Kp extends Error{constructor(t,n={}){var c;const r=n.cause instanceof Kp?n.cause.details:(c=n.cause)!=null&&c.message?n.cause.message:n.details,s=n.cause instanceof Kp&&n.cause.docsPath||n.docsPath,a=[t||"An error occurred.","",...n.metaMessages?[...n.metaMessages,""]:[],...s?[`Docs: https://abitype.dev${s}`]:[],...r?[`Details: ${r}`]:[],`Version: abitype@${yS}`].join(`
62
- `);super(a),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiTypeError"}),n.cause&&(this.cause=n.cause),this.details=r,this.docsPath=s,this.metaMessages=n.metaMessages,this.shortMessage=t}};function Ao(e,t){const n=e.exec(t);return n==null?void 0:n.groups}const E5=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,A5=/^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/,k5=/^\(.+?\).*?$/,sb=/^tuple(?<array>(\[(\d*)\])*)$/;function Yp(e){let t=e.type;if(sb.test(e.type)&&"components"in e){t="(";const n=e.components.length;for(let s=0;s<n;s++){const a=e.components[s];t+=Yp(a),s<n-1&&(t+=", ")}const r=Ao(sb,e.type);return t+=`)${(r==null?void 0:r.array)||""}`,Yp({...e,type:t})}return"indexed"in e&&e.indexed&&(t=`${t} indexed`),e.name?`${t} ${e.name}`:t}function sa(e){let t="";const n=e.length;for(let r=0;r<n;r++){const s=e[r];t+=Yp(s),r!==n-1&&(t+=", ")}return t}function Jd(e){var t;return e.type==="function"?`function ${e.name}(${sa(e.inputs)})${e.stateMutability&&e.stateMutability!=="nonpayable"?` ${e.stateMutability}`:""}${(t=e.outputs)!=null&&t.length?` returns (${sa(e.outputs)})`:""}`:e.type==="event"?`event ${e.name}(${sa(e.inputs)})`:e.type==="error"?`error ${e.name}(${sa(e.inputs)})`:e.type==="constructor"?`constructor(${sa(e.inputs)})${e.stateMutability==="payable"?" payable":""}`:e.type==="fallback"?`fallback() external${e.stateMutability==="payable"?" payable":""}`:"receive() external payable"}const S5=/^error (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;function vS(e){return S5.test(e)}function wS(e){return Ao(S5,e)}const j5=/^event (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;function bS(e){return j5.test(e)}function xS(e){return Ao(j5,e)}const I5=/^function (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)(?: (?<scope>external|public{1}))?(?: (?<stateMutability>pure|view|nonpayable|payable{1}))?(?: returns\s?\((?<returns>.*?)\))?$/;function CS(e){return I5.test(e)}function ES(e){return Ao(I5,e)}const N5=/^struct (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*) \{(?<properties>.*?)\}$/;function Af(e){return N5.test(e)}function AS(e){return Ao(N5,e)}const P5=/^constructor\((?<parameters>.*?)\)(?:\s(?<stateMutability>payable{1}))?$/;function kS(e){return P5.test(e)}function SS(e){return Ao(P5,e)}const B5=/^fallback\(\) external(?:\s(?<stateMutability>payable{1}))?$/;function jS(e){return B5.test(e)}function IS(e){return Ao(B5,e)}const NS=/^receive\(\) external payable$/;function PS(e){return NS.test(e)}const ib=new Set(["memory","indexed","storage","calldata"]),BS=new Set(["indexed"]),Jp=new Set(["calldata","memory","storage"]);class _S extends Sn{constructor({signature:t}){super("Failed to parse ABI item.",{details:`parseAbiItem(${JSON.stringify(t,null,2)})`,docsPath:"/api/human#parseabiitem-1"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiItemError"})}}class TS extends Sn{constructor({type:t}){super("Unknown type.",{metaMessages:[`Type "${t}" is not a valid ABI type. Perhaps you forgot to include a struct signature?`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownTypeError"})}}class OS extends Sn{constructor({type:t}){super("Unknown type.",{metaMessages:[`Type "${t}" is not a valid ABI type.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownSolidityTypeError"})}}class RS extends Sn{constructor({params:t}){super("Failed to parse ABI parameters.",{details:`parseAbiParameters(${JSON.stringify(t,null,2)})`,docsPath:"/api/human#parseabiparameters-1"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiParametersError"})}}class MS extends Sn{constructor({param:t}){super("Invalid ABI parameter.",{details:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParameterError"})}}class DS extends Sn{constructor({param:t,name:n}){super("Invalid ABI parameter.",{details:t,metaMessages:[`"${n}" is a protected Solidity keyword. More info: https://docs.soliditylang.org/en/latest/cheatsheet.html`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SolidityProtectedKeywordError"})}}class FS extends Sn{constructor({param:t,type:n,modifier:r}){super("Invalid ABI parameter.",{details:t,metaMessages:[`Modifier "${r}" not allowed${n?` in "${n}" type`:""}.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidModifierError"})}}class LS extends Sn{constructor({param:t,type:n,modifier:r}){super("Invalid ABI parameter.",{details:t,metaMessages:[`Modifier "${r}" not allowed${n?` in "${n}" type`:""}.`,`Data location can only be specified for array, struct, or mapping types, but "${r}" was given.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidFunctionModifierError"})}}class US extends Sn{constructor({abiParameter:t}){super("Invalid ABI parameter.",{details:JSON.stringify(t,null,2),metaMessages:["ABI parameter type is invalid."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiTypeParameterError"})}}class Wa extends Sn{constructor({signature:t,type:n}){super(`Invalid ${n} signature.`,{details:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSignatureError"})}}class zS extends Sn{constructor({signature:t}){super("Unknown signature.",{details:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownSignatureError"})}}class WS extends Sn{constructor({signature:t}){super("Invalid struct signature.",{details:t,metaMessages:["No properties exist."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidStructSignatureError"})}}class $S extends Sn{constructor({type:t}){super("Circular reference detected.",{metaMessages:[`Struct "${t}" is a circular reference.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"CircularReferenceError"})}}class qS extends Sn{constructor({current:t,depth:n}){super("Unbalanced parentheses.",{metaMessages:[`"${t.trim()}" has too many ${n>0?"opening":"closing"} parentheses.`],details:`Depth "${n}"`}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParenthesisError"})}}function HS(e,t,n){let r="";if(n)for(const s of Object.entries(n)){if(!s)continue;let a="";for(const c of s[1])a+=`[${c.type}${c.name?`:${c.name}`:""}]`;r+=`(${s[0]}{${a}})`}return t?`${t}:${e}${r}`:`${e}${r}`}const z0=new Map([["address",{type:"address"}],["bool",{type:"bool"}],["bytes",{type:"bytes"}],["bytes32",{type:"bytes32"}],["int",{type:"int256"}],["int256",{type:"int256"}],["string",{type:"string"}],["uint",{type:"uint256"}],["uint8",{type:"uint8"}],["uint16",{type:"uint16"}],["uint24",{type:"uint24"}],["uint32",{type:"uint32"}],["uint64",{type:"uint64"}],["uint96",{type:"uint96"}],["uint112",{type:"uint112"}],["uint160",{type:"uint160"}],["uint192",{type:"uint192"}],["uint256",{type:"uint256"}],["address owner",{type:"address",name:"owner"}],["address to",{type:"address",name:"to"}],["bool approved",{type:"bool",name:"approved"}],["bytes _data",{type:"bytes",name:"_data"}],["bytes data",{type:"bytes",name:"data"}],["bytes signature",{type:"bytes",name:"signature"}],["bytes32 hash",{type:"bytes32",name:"hash"}],["bytes32 r",{type:"bytes32",name:"r"}],["bytes32 root",{type:"bytes32",name:"root"}],["bytes32 s",{type:"bytes32",name:"s"}],["string name",{type:"string",name:"name"}],["string symbol",{type:"string",name:"symbol"}],["string tokenURI",{type:"string",name:"tokenURI"}],["uint tokenId",{type:"uint256",name:"tokenId"}],["uint8 v",{type:"uint8",name:"v"}],["uint256 balance",{type:"uint256",name:"balance"}],["uint256 tokenId",{type:"uint256",name:"tokenId"}],["uint256 value",{type:"uint256",name:"value"}],["event:address indexed from",{type:"address",name:"from",indexed:!0}],["event:address indexed to",{type:"address",name:"to",indexed:!0}],["event:uint indexed tokenId",{type:"uint256",name:"tokenId",indexed:!0}],["event:uint256 indexed tokenId",{type:"uint256",name:"tokenId",indexed:!0}]]);function Zp(e,t={}){if(CS(e))return VS(e,t);if(bS(e))return QS(e,t);if(vS(e))return GS(e,t);if(kS(e))return KS(e,t);if(jS(e))return YS(e);if(PS(e))return{type:"receive",stateMutability:"payable"};throw new zS({signature:e})}function VS(e,t={}){const n=ES(e);if(!n)throw new Wa({signature:e,type:"function"});const r=Ln(n.parameters),s=[],a=r.length;for(let l=0;l<a;l++)s.push(Co(r[l],{modifiers:Jp,structs:t,type:"function"}));const c=[];if(n.returns){const l=Ln(n.returns),d=l.length;for(let f=0;f<d;f++)c.push(Co(l[f],{modifiers:Jp,structs:t,type:"function"}))}return{name:n.name,type:"function",stateMutability:n.stateMutability??"nonpayable",inputs:s,outputs:c}}function QS(e,t={}){const n=xS(e);if(!n)throw new Wa({signature:e,type:"event"});const r=Ln(n.parameters),s=[],a=r.length;for(let c=0;c<a;c++)s.push(Co(r[c],{modifiers:BS,structs:t,type:"event"}));return{name:n.name,type:"event",inputs:s}}function GS(e,t={}){const n=wS(e);if(!n)throw new Wa({signature:e,type:"error"});const r=Ln(n.parameters),s=[],a=r.length;for(let c=0;c<a;c++)s.push(Co(r[c],{structs:t,type:"error"}));return{name:n.name,type:"error",inputs:s}}function KS(e,t={}){const n=SS(e);if(!n)throw new Wa({signature:e,type:"constructor"});const r=Ln(n.parameters),s=[],a=r.length;for(let c=0;c<a;c++)s.push(Co(r[c],{structs:t,type:"constructor"}));return{type:"constructor",stateMutability:n.stateMutability??"nonpayable",inputs:s}}function YS(e){const t=IS(e);if(!t)throw new Wa({signature:e,type:"fallback"});return{type:"fallback",stateMutability:t.stateMutability??"nonpayable"}}const JS=/^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*(?:\spayable)?)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,ZS=/^\((?<type>.+?)\)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,XS=/^u?int$/;function Co(e,t){var p,m;const n=HS(e,t==null?void 0:t.type,t==null?void 0:t.structs);if(z0.has(n))return z0.get(n);const r=k5.test(e),s=Ao(r?ZS:JS,e);if(!s)throw new MS({param:e});if(s.name&&t7(s.name))throw new DS({param:e,name:s.name});const a=s.name?{name:s.name}:{},c=s.modifier==="indexed"?{indexed:!0}:{},l=(t==null?void 0:t.structs)??{};let d,f={};if(r){d="tuple";const y=Ln(s.type),v=[],w=y.length;for(let C=0;C<w;C++)v.push(Co(y[C],{structs:l}));f={components:v}}else if(s.type in l)d="tuple",f={components:l[s.type]};else if(XS.test(s.type))d=`${s.type}256`;else if(s.type==="address payable")d="address";else if(d=s.type,(t==null?void 0:t.type)!=="struct"&&!_5(d))throw new OS({type:d});if(s.modifier){if(!((m=(p=t==null?void 0:t.modifiers)==null?void 0:p.has)!=null&&m.call(p,s.modifier)))throw new FS({param:e,type:t==null?void 0:t.type,modifier:s.modifier});if(Jp.has(s.modifier)&&!n7(d,!!s.array))throw new LS({param:e,type:t==null?void 0:t.type,modifier:s.modifier})}const h={type:`${d}${s.array??""}`,...a,...c,...f};return z0.set(n,h),h}function Ln(e,t=[],n="",r=0){const s=e.trim().length;for(let a=0;a<s;a++){const c=e[a],l=e.slice(a+1);switch(c){case",":return r===0?Ln(l,[...t,n.trim()]):Ln(l,t,`${n}${c}`,r);case"(":return Ln(l,t,`${n}${c}`,r+1);case")":return Ln(l,t,`${n}${c}`,r-1);default:return Ln(l,t,`${n}${c}`,r)}}if(n==="")return t;if(r!==0)throw new qS({current:n,depth:r});return t.push(n.trim()),t}function _5(e){return e==="address"||e==="bool"||e==="function"||e==="string"||E5.test(e)||A5.test(e)}const e7=/^(?:after|alias|anonymous|apply|auto|byte|calldata|case|catch|constant|copyof|default|defined|error|event|external|false|final|function|immutable|implements|in|indexed|inline|internal|let|mapping|match|memory|mutable|null|of|override|partial|private|promise|public|pure|reference|relocatable|return|returns|sizeof|static|storage|struct|super|supports|switch|this|true|try|typedef|typeof|var|view|virtual)$/;function t7(e){return e==="address"||e==="bool"||e==="function"||e==="string"||e==="tuple"||E5.test(e)||A5.test(e)||e7.test(e)}function n7(e,t){return t||e==="bytes"||e==="string"||e==="tuple"}function w1(e){const t={},n=e.length;for(let c=0;c<n;c++){const l=e[c];if(!Af(l))continue;const d=AS(l);if(!d)throw new Wa({signature:l,type:"struct"});const f=d.properties.split(";"),h=[],p=f.length;for(let m=0;m<p;m++){const v=f[m].trim();if(!v)continue;const w=Co(v,{type:"struct"});h.push(w)}if(!h.length)throw new WS({signature:l});t[d.name]=h}const r={},s=Object.entries(t),a=s.length;for(let c=0;c<a;c++){const[l,d]=s[c];r[l]=T5(d,t)}return r}const r7=/^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*)(?<array>(?:\[\d*?\])+?)?$/;function T5(e=[],t={},n=new Set){const r=[],s=e.length;for(let a=0;a<s;a++){const c=e[a];if(k5.test(c.type))r.push(c);else{const d=Ao(r7,c.type);if(!(d!=null&&d.type))throw new US({abiParameter:c});const{array:f,type:h}=d;if(h in t){if(n.has(h))throw new $S({type:h});r.push({...c,type:`tuple${f??""}`,components:T5(t[h],t,new Set([...n,h]))})}else if(_5(h))r.push(c);else throw new TS({type:h})}}return r}function Eo(e){const t=w1(e),n=[],r=e.length;for(let s=0;s<r;s++){const a=e[s];Af(a)||n.push(Zp(a,t))}return n}function ab(e){let t;if(typeof e=="string")t=Zp(e);else{const n=w1(e),r=e.length;for(let s=0;s<r;s++){const a=e[s];if(!Af(a)){t=Zp(a,n);break}}}if(!t)throw new _S({signature:e});return t}function cb(e){const t=[];if(typeof e=="string"){const n=Ln(e),r=n.length;for(let s=0;s<r;s++)t.push(Co(n[s],{modifiers:ib}))}else{const n=w1(e),r=e.length;for(let s=0;s<r;s++){const a=e[s];if(Af(a))continue;const c=Ln(a),l=c.length;for(let d=0;d<l;d++)t.push(Co(c[d],{modifiers:ib,structs:n}))}}if(t.length===0)throw new RS({params:e});return t}function o7(e){let t=!0,n="",r=0,s="",a=!1;for(let c=0;c<e.length;c++){const l=e[c];if(["(",")",","].includes(l)&&(t=!0),l==="("&&r++,l===")"&&r--,!!t){if(r===0){if(l===" "&&["event","function",""].includes(s))s="";else if(s+=l,l===")"){a=!0;break}continue}if(l===" "){e[c-1]!==","&&n!==","&&n!==",("&&(n="",t=!1);continue}s+=l,n+=l}}if(!a)throw new re("Unable to normalize signature.");return s}const s7=e=>{const t=typeof e=="string"?e:Jd(e);return o7(t)};function O5(e){return gS(s7(e))}const kf=O5,Hl=e=>hs(O5(e),0,4);function bi(e){const{abi:t,args:n=[],name:r}=e,s=$r(r,{strict:!1}),a=t.filter(l=>s?l.type==="function"?Hl(l)===r:l.type==="event"?kf(l)===r:!1:"name"in l&&l.name===r);if(a.length===0)return;if(a.length===1)return a[0];let c;for(const l of a){if(!("inputs"in l))continue;if(!n||n.length===0){if(!l.inputs||l.inputs.length===0)return l;continue}if(!l.inputs||l.inputs.length===0||l.inputs.length!==n.length)continue;if(n.every((f,h)=>{const p="inputs"in l&&l.inputs[h];return p?Xp(f,p):!1})){if(c&&"inputs"in c&&c.inputs){const f=R5(l.inputs,c.inputs,n);if(f)throw new e4({abiItem:l,type:f[0]},{abiItem:c,type:f[1]})}c=l}}return c||a[0]}function Xp(e,t){const n=typeof e,r=t.type;switch(r){case"address":return xt(e,{strict:!1});case"bool":return n==="boolean";case"function":return n==="string";case"string":return n==="string";default:return r==="tuple"&&"components"in t?Object.values(t.components).every((s,a)=>n==="object"&&Xp(Object.values(e)[a],s)):/^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/.test(r)?n==="number"||n==="bigint":/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(r)?n==="string"||e instanceof Uint8Array:/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(r)?Array.isArray(e)&&e.every(s=>Xp(s,{...t,type:r.replace(/(\[[0-9]{0,}\])$/,"")})):!1}}function R5(e,t,n){for(const r in e){const s=e[r],a=t[r];if(s.type==="tuple"&&a.type==="tuple"&&"components"in s&&"components"in a)return R5(s.components,a.components,n[r]);const c=[s.type,a.type];if(c.includes("address")&&c.includes("bytes20")?!0:c.includes("address")&&c.includes("string")?xt(n[r],{strict:!1}):c.includes("address")&&c.includes("bytes")?xt(n[r],{strict:!1}):!1)return c}}const W0="/docs/contract/decodeFunctionResult";function vs(e){const{abi:t,args:n,functionName:r,data:s}=e;let a=t[0];if(r){const l=bi({abi:t,args:n,name:r});if(!l)throw new Pa(r,{docsPath:W0});a=l}if(a.type!=="function")throw new Pa(void 0,{docsPath:W0});if(!a.outputs)throw new o5(a.name,{docsPath:W0});const c=ql(a.outputs,s);if(c&&c.length>1)return c;if(c&&c.length===1)return c[0]}const lb="/docs/contract/encodeFunctionData";function i7(e){const{abi:t,args:n,functionName:r}=e;let s=t[0];if(r){const a=bi({abi:t,args:n,name:r});if(!a)throw new Pa(r,{docsPath:lb});s=a}if(s.type!=="function")throw new Pa(void 0,{docsPath:lb});return{abi:[s],functionName:Hl(wr(s))}}function $n(e){const{args:t}=e,{abi:n,functionName:r}=(()=>{var l;return e.abi.length===1&&((l=e.functionName)!=null&&l.startsWith("0x"))?e:i7(e)})(),s=n[0],a=r,c="inputs"in s&&s.inputs?wi(s.inputs,t??[]):void 0;return Ar([a,c??"0x"])}class em extends re{constructor({blockNumber:t,chain:n,contract:r}){super(`Chain "${n.name}" does not support contract "${r.name}".`,{metaMessages:["This could be due to any of the following:",...t&&r.blockCreated&&r.blockCreated>t?[`- The contract "${r.name}" was not deployed until block ${r.blockCreated} (current block ${t}).`]:[`- The chain does not have the contract "${r.name}" configured.`]],name:"ChainDoesNotSupportContract"})}}class a7 extends re{constructor({chain:t,currentChainId:n}){super(`The current chain of the wallet (id: ${n}) does not match the target chain for the transaction (id: ${t.id} – ${t.name}).`,{metaMessages:[`Current Chain ID: ${n}`,`Expected Chain ID: ${t.id} – ${t.name}`],name:"ChainMismatchError"})}}class c7 extends re{constructor(){super(["No chain was provided to the request.","Please provide a chain with the `chain` argument on the Action, or by supplying a `chain` to WalletClient."].join(`
63
- `),{name:"ChainNotFoundError"})}}class M5 extends re{constructor(){super("No chain was provided to the Client.",{name:"ClientChainNotConfiguredError"})}}class Sf extends re{constructor({chainId:t}){super(typeof t=="number"?`Chain ID "${t}" is invalid.`:"Chain ID is invalid.",{name:"InvalidChainIdError"})}}function $a({blockNumber:e,chain:t,contract:n}){var s;const r=(s=t==null?void 0:t.contracts)==null?void 0:s[n];if(!r)throw new em({chain:t,contract:{name:n}});if(e&&r.blockCreated&&r.blockCreated>e)throw new em({blockNumber:e,chain:t,contract:{name:n,blockCreated:r.blockCreated}});return r.address}function zt(e){return typeof e=="string"?{address:e,type:"json-rpc"}:e}const l7={1:"An `assert` condition failed.",17:"Arithmetic operation resulted in underflow or overflow.",18:"Division or modulo by zero (e.g. `5 / 0` or `23 % 0`).",33:"Attempted to convert to an invalid type.",34:"Attempted to access a storage byte array that is incorrectly encoded.",49:"Performed `.pop()` on an empty array",50:"Array index is out of bounds.",65:"Allocated too much memory or created an array which is too large.",81:"Attempted to call a zero-initialized variable of internal function type."},D5={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},u7={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"};function d7(e){const{abi:t,data:n,cause:r}=e,s=hs(n,0,4);if(s==="0x")throw new Wl({cause:r});const c=[...t||[],D5,u7].find(l=>l.type==="error"&&s===Hl(wr(l)));if(!c)throw new r5(s,{docsPath:"/docs/contract/decodeErrorResult",cause:r});return{abiItem:c,args:"inputs"in c&&c.inputs&&c.inputs.length>0?ql(c.inputs,hs(n,4)):void 0,errorName:c.name}}const Ut=(e,t,n)=>JSON.stringify(e,(r,s)=>typeof s=="bigint"?s.toString():s,n);function F5({abiItem:e,args:t,includeFunctionName:n=!0,includeName:r=!1}){if("name"in e&&"inputs"in e&&e.inputs)return`${n?e.name:""}(${e.inputs.map((s,a)=>`${r&&s.name?`${s.name}: `:""}${typeof t[a]=="object"?Ut(t[a]):t[a]}`).join(", ")})`}const f7={gwei:9,wei:18},h7={ether:-9,wei:9},p7={ether:-18,gwei:-9};function qr(e,t){let n=e.toString();const r=n.startsWith("-");r&&(n=n.slice(1)),n=n.padStart(t,"0");let[s,a]=[n.slice(0,n.length-t),n.slice(n.length-t)];return a=a.replace(/(0+)$/,""),`${r?"-":""}${s||"0"}${a?`.${a}`:""}`}function b1(e,t="wei"){return qr(e,f7[t])}function kn(e,t="wei"){return qr(e,h7[t])}class m7 extends re{constructor({address:t}){super(`State for account "${t}" is set multiple times.`,{name:"AccountStateConflictError"})}}class g7 extends re{constructor(){super("state and stateDiff are set on the same account.",{name:"StateAssignmentConflictError"})}}function ub(e){return e.reduce((t,{slot:n,value:r})=>`${t} ${n}: ${r}
64
- `,"")}function y7(e){return e.reduce((t,{address:n,...r})=>{let s=`${t} ${n}:
65
- `;return r.nonce&&(s+=` nonce: ${r.nonce}
66
- `),r.balance&&(s+=` balance: ${r.balance}
67
- `),r.code&&(s+=` code: ${r.code}
68
- `),r.state&&(s+=` state:
69
- `,s+=ub(r.state)),r.stateDiff&&(s+=` stateDiff:
70
- `,s+=ub(r.stateDiff)),s},` State Override:
71
- `).slice(0,-1)}function Vl(e){const t=Object.entries(e).map(([r,s])=>s===void 0||s===!1?null:[r,s]).filter(Boolean),n=t.reduce((r,[s])=>Math.max(r,s.length),0);return t.map(([r,s])=>` ${`${r}:`.padEnd(n+1)} ${s}`).join(`
72
- `)}class v7 extends re{constructor({v:t}){super(`Invalid \`v\` value "${t}". Expected 27 or 28.`,{name:"InvalidLegacyVError"})}}class w7 extends re{constructor({transaction:t}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",Vl(t),"}","","To infer the type, either provide:","- a `type` to the Transaction, or","- an EIP-1559 Transaction with `maxFeePerGas`, or","- an EIP-2930 Transaction with `gasPrice` & `accessList`, or","- an EIP-4844 Transaction with `blobs`, `blobVersionedHashes`, `sidecars`, or","- an EIP-7702 Transaction with `authorizationList`, or","- a Legacy Transaction with `gasPrice`"],name:"InvalidSerializableTransactionError"})}}class b7 extends re{constructor({storageKey:t}){super(`Size for storage key "${t}" is invalid. Expected 32 bytes. Got ${Math.floor((t.length-2)/2)} bytes.`,{name:"InvalidStorageKeySizeError"})}}class x7 extends re{constructor(t,{account:n,docsPath:r,chain:s,data:a,gas:c,gasPrice:l,maxFeePerGas:d,maxPriorityFeePerGas:f,nonce:h,to:p,value:m}){var v;const y=Vl({chain:s&&`${s==null?void 0:s.name} (id: ${s==null?void 0:s.id})`,from:n==null?void 0:n.address,to:p,value:typeof m<"u"&&`${b1(m)} ${((v=s==null?void 0:s.nativeCurrency)==null?void 0:v.symbol)||"ETH"}`,data:a,gas:c,gasPrice:typeof l<"u"&&`${kn(l)} gwei`,maxFeePerGas:typeof d<"u"&&`${kn(d)} gwei`,maxPriorityFeePerGas:typeof f<"u"&&`${kn(f)} gwei`,nonce:h});super(t.shortMessage,{cause:t,docsPath:r,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Request Arguments:",y].filter(Boolean),name:"TransactionExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}class L5 extends re{constructor({blockHash:t,blockNumber:n,blockTag:r,hash:s,index:a}){let c="Transaction";r&&a!==void 0&&(c=`Transaction at block time "${r}" at index "${a}"`),t&&a!==void 0&&(c=`Transaction at block hash "${t}" at index "${a}"`),n&&a!==void 0&&(c=`Transaction at block number "${n}" at index "${a}"`),s&&(c=`Transaction with hash "${s}"`),super(`${c} could not be found.`,{name:"TransactionNotFoundError"})}}class U5 extends re{constructor({hash:t}){super(`Transaction receipt with hash "${t}" could not be found. The Transaction may not be processed on a block yet.`,{name:"TransactionReceiptNotFoundError"})}}class C7 extends re{constructor({receipt:t}){super(`Transaction with hash "${t.transactionHash}" reverted.`,{metaMessages:['The receipt marked the transaction as "reverted". This could mean that the function on the contract you are trying to call threw an error.'," ","You can attempt to extract the revert reason by:","- calling the `simulateContract` or `simulateCalls` Action with the `abi` and `functionName` of the contract","- using the `call` Action with raw `data`"],name:"TransactionReceiptRevertedError"}),Object.defineProperty(this,"receipt",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.receipt=t}}class E7 extends re{constructor({hash:t}){super(`Timed out while waiting for transaction with hash "${t}" to be confirmed.`,{name:"WaitForTransactionReceiptTimeoutError"})}}const A7=e=>e,x1=e=>e;class z5 extends re{constructor(t,{account:n,docsPath:r,chain:s,data:a,gas:c,gasPrice:l,maxFeePerGas:d,maxPriorityFeePerGas:f,nonce:h,to:p,value:m,stateOverride:y}){var C;const v=n?zt(n):void 0;let w=Vl({from:v==null?void 0:v.address,to:p,value:typeof m<"u"&&`${b1(m)} ${((C=s==null?void 0:s.nativeCurrency)==null?void 0:C.symbol)||"ETH"}`,data:a,gas:c,gasPrice:typeof l<"u"&&`${kn(l)} gwei`,maxFeePerGas:typeof d<"u"&&`${kn(d)} gwei`,maxPriorityFeePerGas:typeof f<"u"&&`${kn(f)} gwei`,nonce:h});y&&(w+=`
73
- ${y7(y)}`),super(t.shortMessage,{cause:t,docsPath:r,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Raw Call Arguments:",w].filter(Boolean),name:"CallExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}class C1 extends re{constructor(t,{abi:n,args:r,contractAddress:s,docsPath:a,functionName:c,sender:l}){const d=bi({abi:n,args:r,name:c}),f=d?F5({abiItem:d,args:r,includeFunctionName:!1,includeName:!1}):void 0,h=d?wr(d,{includeName:!0}):void 0,p=Vl({address:s&&A7(s),function:h,args:f&&f!=="()"&&`${[...Array((c==null?void 0:c.length)??0).keys()].map(()=>" ").join("")}${f}`,sender:l});super(t.shortMessage||`An unknown error occurred while executing the contract function "${c}".`,{cause:t,docsPath:a,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],p&&"Contract Call:",p].filter(Boolean),name:"ContractFunctionExecutionError"}),Object.defineProperty(this,"abi",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"args",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"contractAddress",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"formattedArgs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"functionName",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sender",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abi=n,this.args=r,this.cause=t,this.contractAddress=s,this.functionName=c,this.sender=l}}class tm extends re{constructor({abi:t,data:n,functionName:r,message:s,cause:a}){let c,l,d,f;if(n&&n!=="0x")try{l=d7({abi:t,data:n,cause:a});const{abiItem:p,errorName:m,args:y}=l;if(m==="Error")f=y[0];else if(m==="Panic"){const[v]=y;f=l7[v]}else{const v=p?wr(p,{includeName:!0}):void 0,w=p&&y?F5({abiItem:p,args:y,includeFunctionName:!1,includeName:!1}):void 0;d=[v?`Error: ${v}`:"",w&&w!=="()"?` ${[...Array((m==null?void 0:m.length)??0).keys()].map(()=>" ").join("")}${w}`:""]}}catch(p){c=p}else s&&(f=s);let h;c instanceof r5&&(h=c.signature,d=[`Unable to decode signature "${h}" as it was not found on the provided ABI.`,"Make sure you are using the correct ABI and that the error exists on it.",`You can look up the decoded signature here: https://4byte.sourcify.dev/?q=${h}.`]),super(f&&f!=="execution reverted"||h?[`The contract function "${r}" reverted with the following ${h?"signature":"reason"}:`,f||h].join(`
74
- `):`The contract function "${r}" reverted.`,{cause:c??a,metaMessages:d,name:"ContractFunctionRevertedError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"raw",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"reason",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=l,this.raw=n,this.reason=f,this.signature=h}}class k7 extends re{constructor({functionName:t,cause:n}){super(`The contract function "${t}" returned no data ("0x").`,{metaMessages:["This could be due to any of the following:",` - The contract does not have the function "${t}",`," - The parameters passed to the contract function may be invalid, or"," - The address is not a contract."],name:"ContractFunctionZeroDataError",cause:n})}}class S7 extends re{constructor({factory:t}){super(`Deployment for counterfactual contract call failed${t?` for factory "${t}".`:""}`,{metaMessages:["Please ensure:","- The `factory` is a valid contract deployment factory (ie. Create2 Factory, ERC-4337 Factory, etc).","- The `factoryData` is a valid encoded function call for contract deployment function on the factory."],name:"CounterfactualDeploymentFailedError"})}}class jf extends re{constructor({data:t,message:n}){super(n||"",{name:"RawContractError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=t}}function E1(e){var n,r,s,a,c,l;if(!(e instanceof re))return!1;const t=e.walk(d=>d instanceof tm);return t instanceof tm?((n=t.data)==null?void 0:n.errorName)==="HttpError"||((r=t.data)==null?void 0:r.errorName)==="ResolverError"||((s=t.data)==null?void 0:s.errorName)==="ResolverNotContract"||((a=t.data)==null?void 0:a.errorName)==="ResolverNotFound"||((c=t.data)==null?void 0:c.errorName)==="ReverseAddressMismatch"||((l=t.data)==null?void 0:l.errorName)==="UnsupportedResolverProfile":!1}function j7(e){const{abi:t,data:n}=e,r=hs(n,0,4),s=t.find(a=>a.type==="function"&&r===Hl(wr(a)));if(!s)throw new Xk(r,{docsPath:"/docs/contract/decodeFunctionData"});return{functionName:s.name,args:"inputs"in s&&s.inputs&&s.inputs.length>0?ql(s.inputs,hs(n,4)):void 0}}const $0="/docs/contract/encodeErrorResult";function db(e){const{abi:t,errorName:n,args:r}=e;let s=t[0];if(n){const d=bi({abi:t,args:r,name:n});if(!d)throw new Vw(n,{docsPath:$0});s=d}if(s.type!=="error")throw new Vw(void 0,{docsPath:$0});const a=wr(s),c=Hl(a);let l="0x";if(r&&r.length>0){if(!s.inputs)throw new Yk(s.name,{docsPath:$0});l=wi(s.inputs,r)}return Ar([c,l])}const q0="/docs/contract/encodeFunctionResult";function I7(e){const{abi:t,functionName:n,result:r}=e;let s=t[0];if(n){const c=bi({abi:t,name:n});if(!c)throw new Pa(n,{docsPath:q0});s=c}if(s.type!=="function")throw new Pa(void 0,{docsPath:q0});if(!s.outputs)throw new o5(s.name,{docsPath:q0});const a=(()=>{if(s.outputs.length===0)return[];if(s.outputs.length===1)return[r];if(Array.isArray(r))return r;throw new s5(r)})();return wi(s.outputs,a)}const If="x-batch-gateway:true";async function N7(e){const{data:t,ccipRequest:n}=e,{args:[r]}=j7({abi:Vp,data:t}),s=[],a=[];return await Promise.all(r.map(async(c,l)=>{try{a[l]=c.urls.includes(If)?await N7({data:c.data,ccipRequest:n}):await n(c),s[l]=!1}catch(d){s[l]=!0,a[l]=P7(d)}})),I7({abi:Vp,functionName:"query",result:[s,a]})}function P7(e){return e.name==="HttpRequestError"&&e.status?db({abi:Vp,errorName:"HttpError",args:[e.status,e.shortMessage]}):db({abi:[D5],errorName:"Error",args:["shortMessage"in e?e.shortMessage:e.message]})}function W5(e){if(e.length!==66||e.indexOf("[")!==0||e.indexOf("]")!==65)return null;const t=`0x${e.slice(1,65)}`;return $r(t)?t:null}function nm(e){let t=new Uint8Array(32).fill(0);if(!e)return bt(t);const n=e.split(".");for(let r=n.length-1;r>=0;r-=1){const s=W5(n[r]),a=s?za(s):Lt(oi(n[r]),"bytes");t=Lt(rr([t,a]),"bytes")}return bt(t)}function B7(e){return`[${e.slice(2)}]`}function _7(e){const t=new Uint8Array(32).fill(0);return e?W5(e)||Lt(oi(e)):bt(t)}function A1(e){const t=e.replace(/^\.|\.$/gm,"");if(t.length===0)return new Uint8Array(1);const n=new Uint8Array(oi(t).byteLength+2);let r=0;const s=t.split(".");for(let a=0;a<s.length;a++){let c=oi(s[a]);c.byteLength>255&&(c=oi(B7(_7(s[a])))),n[r]=c.length,n.set(c,r+1),r+=c.length+1}return n.byteLength!==r+1?n.slice(0,r+1):n}function Ee(e,t,n){const r=e[t.name];if(typeof r=="function")return r;const s=e[n];return typeof s=="function"?s:a=>t(e,a)}class Vc extends re{constructor({body:t,cause:n,details:r,headers:s,status:a,url:c}){super("HTTP request failed.",{cause:n,details:r,metaMessages:[a&&`Status: ${a}`,`URL: ${x1(c)}`,t&&`Request body: ${Ut(t)}`].filter(Boolean),name:"HttpRequestError"}),Object.defineProperty(this,"body",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"headers",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"status",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.body=t,this.headers=s,this.status=a,this.url=c}}class k1 extends re{constructor({body:t,error:n,url:r}){super("RPC Request failed.",{cause:n,details:n.message,metaMessages:[`URL: ${x1(r)}`,`Request body: ${Ut(t)}`],name:"RpcRequestError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.code=n.code,this.data=n.data,this.url=r}}class fb extends re{constructor({body:t,url:n}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${x1(n)}`,`Request body: ${Ut(t)}`],name:"TimeoutError"}),Object.defineProperty(this,"url",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.url=n}}const T7=-1;class jn extends re{constructor(t,{code:n,docsPath:r,metaMessages:s,name:a,shortMessage:c}){super(c,{cause:t,docsPath:r,metaMessages:s||(t==null?void 0:t.metaMessages),name:a||"RpcError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.name=a||t.name,this.code=t instanceof k1?t.code:n??T7}}class In extends jn{constructor(t,n){super(t,n),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=n.data}}class el extends jn{constructor(t){super(t,{code:el.code,name:"ParseRpcError",shortMessage:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."})}}Object.defineProperty(el,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32700});class tl extends jn{constructor(t){super(t,{code:tl.code,name:"InvalidRequestRpcError",shortMessage:"JSON is not a valid request object."})}}Object.defineProperty(tl,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32600});class nl extends jn{constructor(t,{method:n}={}){super(t,{code:nl.code,name:"MethodNotFoundRpcError",shortMessage:`The method${n?` "${n}"`:""} does not exist / is not available.`})}}Object.defineProperty(nl,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32601});class rl extends jn{constructor(t){super(t,{code:rl.code,name:"InvalidParamsRpcError",shortMessage:["Invalid parameters were provided to the RPC method.","Double check you have provided the correct parameters."].join(`
75
- `)})}}Object.defineProperty(rl,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32602});class li extends jn{constructor(t){super(t,{code:li.code,name:"InternalRpcError",shortMessage:"An internal error was received."})}}Object.defineProperty(li,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32603});class ps extends jn{constructor(t){super(t,{code:ps.code,name:"InvalidInputRpcError",shortMessage:["Missing or invalid parameters.","Double check you have provided the correct parameters."].join(`
76
- `)})}}Object.defineProperty(ps,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32e3});class ol extends jn{constructor(t){super(t,{code:ol.code,name:"ResourceNotFoundRpcError",shortMessage:"Requested resource not found."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceNotFoundRpcError"})}}Object.defineProperty(ol,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32001});class Ur extends jn{constructor(t){super(t,{code:Ur.code,name:"ResourceUnavailableRpcError",shortMessage:"Requested resource not available."})}}Object.defineProperty(Ur,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32002});class Ta extends jn{constructor(t){super(t,{code:Ta.code,name:"TransactionRejectedRpcError",shortMessage:"Transaction creation failed."})}}Object.defineProperty(Ta,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32003});class qs extends jn{constructor(t,{method:n}={}){super(t,{code:qs.code,name:"MethodNotSupportedRpcError",shortMessage:`Method${n?` "${n}"`:""} is not supported.`})}}Object.defineProperty(qs,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32004});class Oa extends jn{constructor(t){super(t,{code:Oa.code,name:"LimitExceededRpcError",shortMessage:"Request exceeds defined limit."})}}Object.defineProperty(Oa,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32005});class sl extends jn{constructor(t){super(t,{code:sl.code,name:"JsonRpcVersionUnsupportedError",shortMessage:"Version of JSON-RPC protocol is not supported."})}}Object.defineProperty(sl,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32006});class Ge extends In{constructor(t){super(t,{code:Ge.code,name:"UserRejectedRequestError",shortMessage:"User rejected the request."})}}Object.defineProperty(Ge,"code",{enumerable:!0,configurable:!0,writable:!0,value:4001});class il extends In{constructor(t){super(t,{code:il.code,name:"UnauthorizedProviderError",shortMessage:"The requested method and/or account has not been authorized by the user."})}}Object.defineProperty(il,"code",{enumerable:!0,configurable:!0,writable:!0,value:4100});class al extends In{constructor(t,{method:n}={}){super(t,{code:al.code,name:"UnsupportedProviderMethodError",shortMessage:`The Provider does not support the requested method${n?` " ${n}"`:""}.`})}}Object.defineProperty(al,"code",{enumerable:!0,configurable:!0,writable:!0,value:4200});class cl extends In{constructor(t){super(t,{code:cl.code,name:"ProviderDisconnectedError",shortMessage:"The Provider is disconnected from all chains."})}}Object.defineProperty(cl,"code",{enumerable:!0,configurable:!0,writable:!0,value:4900});class ll extends In{constructor(t){super(t,{code:ll.code,name:"ChainDisconnectedError",shortMessage:"The Provider is not connected to the requested chain."})}}Object.defineProperty(ll,"code",{enumerable:!0,configurable:!0,writable:!0,value:4901});class zn extends In{constructor(t){super(t,{code:zn.code,name:"SwitchChainError",shortMessage:"An error occurred when attempting to switch chain."})}}Object.defineProperty(zn,"code",{enumerable:!0,configurable:!0,writable:!0,value:4902});class ul extends In{constructor(t){super(t,{code:ul.code,name:"UnsupportedNonOptionalCapabilityError",shortMessage:"This Wallet does not support a capability that was not marked as optional."})}}Object.defineProperty(ul,"code",{enumerable:!0,configurable:!0,writable:!0,value:5700});class dl extends In{constructor(t){super(t,{code:dl.code,name:"UnsupportedChainIdError",shortMessage:"This Wallet does not support the requested chain ID."})}}Object.defineProperty(dl,"code",{enumerable:!0,configurable:!0,writable:!0,value:5710});class fl extends In{constructor(t){super(t,{code:fl.code,name:"DuplicateIdError",shortMessage:"There is already a bundle submitted with this ID."})}}Object.defineProperty(fl,"code",{enumerable:!0,configurable:!0,writable:!0,value:5720});class hl extends In{constructor(t){super(t,{code:hl.code,name:"UnknownBundleIdError",shortMessage:"This bundle id is unknown / has not been submitted"})}}Object.defineProperty(hl,"code",{enumerable:!0,configurable:!0,writable:!0,value:5730});class pl extends In{constructor(t){super(t,{code:pl.code,name:"BundleTooLargeError",shortMessage:"The call bundle is too large for the Wallet to process."})}}Object.defineProperty(pl,"code",{enumerable:!0,configurable:!0,writable:!0,value:5740});class ml extends In{constructor(t){super(t,{code:ml.code,name:"AtomicReadyWalletRejectedUpgradeError",shortMessage:"The Wallet can support atomicity after an upgrade, but the user rejected the upgrade."})}}Object.defineProperty(ml,"code",{enumerable:!0,configurable:!0,writable:!0,value:5750});class gl extends In{constructor(t){super(t,{code:gl.code,name:"AtomicityNotSupportedError",shortMessage:"The wallet does not support atomic execution but the request requires it."})}}Object.defineProperty(gl,"code",{enumerable:!0,configurable:!0,writable:!0,value:5760});class Ra extends In{constructor(t){super(t,{code:Ra.code,name:"WalletConnectSessionSettlementError",shortMessage:"WalletConnect session settlement failed."})}}Object.defineProperty(Ra,"code",{enumerable:!0,configurable:!0,writable:!0,value:7e3});class O7 extends jn{constructor(t){super(t,{name:"UnknownRpcError",shortMessage:"An unknown RPC error occurred."})}}const R7=3;function ui(e,{abi:t,address:n,args:r,docsPath:s,functionName:a,sender:c}){const l=e instanceof jf?e:e instanceof re?e.walk(v=>"data"in v)||e.walk():{},{code:d,data:f,details:h,message:p,shortMessage:m}=l,y=e instanceof Wl?new k7({functionName:a,cause:e}):[R7,li.code].includes(d)&&(f||h||p||m)||d===ps.code&&h==="execution reverted"&&f?new tm({abi:t,data:typeof f=="object"?f.data:f,functionName:a,message:l instanceof k1?h:m??p,cause:e}):e;return new C1(y,{abi:t,args:r,contractAddress:n,docsPath:s,functionName:a,sender:c})}const M7="modulepreload",D7=function(e){return"/"+e},hb={},de=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){let c=function(f){return Promise.all(f.map(h=>Promise.resolve(h).then(p=>({status:"fulfilled",value:p}),p=>({status:"rejected",reason:p}))))};document.getElementsByTagName("link");const l=document.querySelector("meta[property=csp-nonce]"),d=(l==null?void 0:l.nonce)||(l==null?void 0:l.getAttribute("nonce"));s=c(n.map(f=>{if(f=D7(f),f in hb)return;hb[f]=!0;const h=f.endsWith(".css"),p=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${f}"]${p}`))return;const m=document.createElement("link");if(m.rel=h?"stylesheet":M7,h||(m.as="script"),m.crossOrigin="",m.href=f,d&&m.setAttribute("nonce",d),document.head.appendChild(m),h)return new Promise((y,v)=>{m.addEventListener("load",y),m.addEventListener("error",()=>v(new Error(`Unable to preload CSS for ${f}`)))})}))}function a(c){const l=new Event("vite:preloadError",{cancelable:!0});if(l.payload=c,window.dispatchEvent(l),!l.defaultPrevented)throw c}return s.then(c=>{for(const l of c||[])l.status==="rejected"&&a(l.reason);return t().catch(a)})};/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const S1=BigInt(0),rm=BigInt(1);function Ql(e){return e instanceof Uint8Array||ArrayBuffer.isView(e)&&e.constructor.name==="Uint8Array"}function j1(e){if(!Ql(e))throw new Error("Uint8Array expected")}function yl(e,t){if(typeof t!="boolean")throw new Error(e+" boolean expected, got "+t)}function Ed(e){const t=e.toString(16);return t.length&1?"0"+t:t}function $5(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);return e===""?S1:BigInt("0x"+e)}const q5=typeof Uint8Array.from([]).toHex=="function"&&typeof Uint8Array.fromHex=="function",F7=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function vl(e){if(j1(e),q5)return e.toHex();let t="";for(let n=0;n<e.length;n++)t+=F7[e[n]];return t}const ao={_0:48,_9:57,A:65,F:70,a:97,f:102};function pb(e){if(e>=ao._0&&e<=ao._9)return e-ao._0;if(e>=ao.A&&e<=ao.F)return e-(ao.A-10);if(e>=ao.a&&e<=ao.f)return e-(ao.a-10)}function Zd(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);if(q5)return Uint8Array.fromHex(e);const t=e.length,n=t/2;if(t%2)throw new Error("hex string expected, got unpadded hex of length "+t);const r=new Uint8Array(n);for(let s=0,a=0;s<n;s++,a+=2){const c=pb(e.charCodeAt(a)),l=pb(e.charCodeAt(a+1));if(c===void 0||l===void 0){const d=e[a]+e[a+1];throw new Error('hex string expected, got non-hex character "'+d+'" at index '+a)}r[s]=c*16+l}return r}function si(e){return $5(vl(e))}function H5(e){return j1(e),$5(vl(Uint8Array.from(e).reverse()))}function Gl(e,t){return Zd(e.toString(16).padStart(t*2,"0"))}function V5(e,t){return Gl(e,t).reverse()}function Zn(e,t,n){let r;if(typeof t=="string")try{r=Zd(t)}catch(a){throw new Error(e+" must be hex string or Uint8Array, cause: "+a)}else if(Ql(t))r=Uint8Array.from(t);else throw new Error(e+" must be hex string or Uint8Array");const s=r.length;if(typeof n=="number"&&s!==n)throw new Error(e+" of length "+n+" expected, got "+s);return r}function Xd(...e){let t=0;for(let r=0;r<e.length;r++){const s=e[r];j1(s),t+=s.length}const n=new Uint8Array(t);for(let r=0,s=0;r<e.length;r++){const a=e[r];n.set(a,s),s+=a.length}return n}const H0=e=>typeof e=="bigint"&&S1<=e;function I1(e,t,n){return H0(e)&&H0(t)&&H0(n)&&t<=e&&e<n}function da(e,t,n,r){if(!I1(t,n,r))throw new Error("expected valid "+e+": "+n+" <= n < "+r+", got "+t)}function L7(e){let t;for(t=0;e>S1;e>>=rm,t+=1);return t}const Nf=e=>(rm<<BigInt(e))-rm,V0=e=>new Uint8Array(e),mb=e=>Uint8Array.from(e);function U7(e,t,n){if(typeof e!="number"||e<2)throw new Error("hashLen must be a number");if(typeof t!="number"||t<2)throw new Error("qByteLen must be a number");if(typeof n!="function")throw new Error("hmacFn must be a function");let r=V0(e),s=V0(e),a=0;const c=()=>{r.fill(1),s.fill(0),a=0},l=(...p)=>n(s,r,...p),d=(p=V0(0))=>{s=l(mb([0]),p),r=l(),p.length!==0&&(s=l(mb([1]),p),r=l())},f=()=>{if(a++>=1e3)throw new Error("drbg: tried 1000 values");let p=0;const m=[];for(;p<t;){r=l();const y=r.slice();m.push(y),p+=r.length}return Xd(...m)};return(p,m)=>{c(),d(p);let y;for(;!(y=m(f()));)d();return c(),y}}const z7={bigint:e=>typeof e=="bigint",function:e=>typeof e=="function",boolean:e=>typeof e=="boolean",string:e=>typeof e=="string",stringOrUint8Array:e=>typeof e=="string"||Ql(e),isSafeInteger:e=>Number.isSafeInteger(e),array:e=>Array.isArray(e),field:(e,t)=>t.Fp.isValid(e),hash:e=>typeof e=="function"&&Number.isSafeInteger(e.outputLen)};function Pf(e,t,n={}){const r=(s,a,c)=>{const l=z7[a];if(typeof l!="function")throw new Error("invalid validator function");const d=e[s];if(!(c&&d===void 0)&&!l(d,e))throw new Error("param "+String(s)+" is invalid. Expected "+a+", got "+d)};for(const[s,a]of Object.entries(t))r(s,a,!1);for(const[s,a]of Object.entries(n))r(s,a,!0);return e}function gb(e){const t=new WeakMap;return(n,...r)=>{const s=t.get(n);if(s!==void 0)return s;const a=e(n,...r);return t.set(n,a),a}}const W7="0.1.1";function $7(){return W7}let De=class lo extends Error{static setStaticOptions(t){lo.prototype.docsOrigin=t.docsOrigin,lo.prototype.showVersion=t.showVersion,lo.prototype.version=t.version}constructor(t,n={}){const r=(()=>{var h;if(n.cause instanceof lo){if(n.cause.details)return n.cause.details;if(n.cause.shortMessage)return n.cause.shortMessage}return n.cause&&"details"in n.cause&&typeof n.cause.details=="string"?n.cause.details:(h=n.cause)!=null&&h.message?n.cause.message:n.details})(),s=n.cause instanceof lo&&n.cause.docsPath||n.docsPath,a=n.docsOrigin??lo.prototype.docsOrigin,c=`${a}${s??""}`,l=!!(n.version??lo.prototype.showVersion),d=n.version??lo.prototype.version,f=[t||"An error occurred.",...n.metaMessages?["",...n.metaMessages]:[],...r||s||l?["",r?`Details: ${r}`:void 0,s?`See: ${c}`:void 0,l?`Version: ${d}`:void 0]:[]].filter(h=>typeof h=="string").join(`
77
- `);super(f,n.cause?{cause:n.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docs",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsOrigin",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showVersion",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.cause=n.cause,this.details=r,this.docs=c,this.docsOrigin=a,this.docsPath=s,this.shortMessage=t,this.showVersion=l,this.version=d}walk(t){return Q5(this,t)}};Object.defineProperty(De,"defaultStaticOptions",{enumerable:!0,configurable:!0,writable:!0,value:{docsOrigin:"https://oxlib.sh",showVersion:!1,version:`ox@${$7()}`}});De.setStaticOptions(De.defaultStaticOptions);function Q5(e,t){return t!=null&&t(e)?e:e&&typeof e=="object"&&"cause"in e&&e.cause?Q5(e.cause,t):t?null:e}function Kl(e,t){if(ca(e)>t)throw new ij({givenSize:ca(e),maxSize:t})}const co={zero:48,nine:57,A:65,F:70,a:97,f:102};function yb(e){if(e>=co.zero&&e<=co.nine)return e-co.zero;if(e>=co.A&&e<=co.F)return e-(co.A-10);if(e>=co.a&&e<=co.f)return e-(co.a-10)}function q7(e,t={}){const{dir:n,size:r=32}=t;if(r===0)return e;if(e.length>r)throw new aj({size:e.length,targetSize:r,type:"Bytes"});const s=new Uint8Array(r);for(let a=0;a<r;a++){const c=n==="right";s[c?a:r-a-1]=e[c?a:e.length-a-1]}return s}function G5(e,t={}){const{dir:n="left"}=t;let r=e,s=0;for(let a=0;a<r.length-1&&r[n==="left"?a:r.length-a-1].toString()==="0";a++)s++;return r=n==="left"?r.slice(s):r.slice(0,r.length-s),r}function Bf(e,t){if(Wn(e)>t)throw new hj({givenSize:Wn(e),maxSize:t})}function H7(e,t){if(typeof t=="number"&&t>0&&t>Wn(e)-1)throw new rx({offset:t,position:"start",size:Wn(e)})}function V7(e,t,n){if(typeof t=="number"&&typeof n=="number"&&Wn(e)!==n-t)throw new rx({offset:n,position:"end",size:Wn(e)})}function K5(e,t={}){const{dir:n,size:r=32}=t;if(r===0)return e;const s=e.replace("0x","");if(s.length>r*2)throw new pj({size:Math.ceil(s.length/2),targetSize:r,type:"Hex"});return`0x${s[n==="right"?"padEnd":"padStart"](r*2,"0")}`}const Q7="#__bigint";function Y5(e,t,n){return JSON.stringify(e,(r,s)=>typeof s=="bigint"?s.toString()+Q7:s,n)}const G7=new TextDecoder,K7=new TextEncoder;function Y7(e){return e instanceof Uint8Array?e:typeof e=="string"?J5(e):J7(e)}function J7(e){return e instanceof Uint8Array?e:new Uint8Array(e)}function J5(e,t={}){const{size:n}=t;let r=e;n&&(Bf(e,n),r=fi(e,n));let s=r.slice(2);s.length%2&&(s=`0${s}`);const a=s.length/2,c=new Uint8Array(a);for(let l=0,d=0;l<a;l++){const f=yb(s.charCodeAt(d++)),h=yb(s.charCodeAt(d++));if(f===void 0||h===void 0)throw new De(`Invalid byte sequence ("${s[d-2]}${s[d-1]}" in "${s}").`);c[l]=f<<4|h}return c}function Z7(e,t={}){const{size:n}=t,r=K7.encode(e);return typeof n=="number"?(Kl(r,n),X7(r,n)):r}function X7(e,t){return q7(e,{dir:"right",size:t})}function ca(e){return e.length}function ej(e,t,n,r={}){const{strict:s}=r;return e.slice(t,n)}function tj(e,t={}){const{size:n}=t;typeof n<"u"&&Kl(e,n);const r=Er(e,t);return ex(r,t)}function nj(e,t={}){const{size:n}=t;let r=e;if(typeof n<"u"&&(Kl(r,n),r=Z5(r)),r.length>1||r[0]>1)throw new sj(r);return!!r[0]}function wo(e,t={}){const{size:n}=t;typeof n<"u"&&Kl(e,n);const r=Er(e,t);return tx(r,t)}function rj(e,t={}){const{size:n}=t;let r=e;return typeof n<"u"&&(Kl(r,n),r=oj(r)),G7.decode(r)}function Z5(e){return G5(e,{dir:"left"})}function oj(e){return G5(e,{dir:"right"})}class sj extends De{constructor(t){super(`Bytes value \`${t}\` is not a valid boolean.`,{metaMessages:["The bytes array must contain a single byte of either a `0` or `1` value."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.InvalidBytesBooleanError"})}}let ij=class extends De{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed \`${n}\` bytes. Given size: \`${t}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeOverflowError"})}},aj=class extends De{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${t}\`) exceeds padding size (\`${n}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Bytes.SizeExceedsPaddingSizeError"})}};const cj=new TextEncoder,lj=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function uj(e,t={}){const{strict:n=!1}=t;if(!e)throw new vb(e);if(typeof e!="string")throw new vb(e);if(n&&!/^0x[0-9a-fA-F]*$/.test(e))throw new wb(e);if(!e.startsWith("0x"))throw new wb(e)}function Cr(...e){return`0x${e.reduce((t,n)=>t+n.replace("0x",""),"")}`}function dj(e){return e instanceof Uint8Array?Er(e):Array.isArray(e)?Er(new Uint8Array(e)):e}function X5(e,t={}){const n=`0x${Number(e)}`;return typeof t.size=="number"?(Bf(n,t.size),di(n,t.size)):n}function Er(e,t={}){let n="";for(let s=0;s<e.length;s++)n+=lj[e[s]];const r=`0x${n}`;return typeof t.size=="number"?(Bf(r,t.size),fi(r,t.size)):r}function sn(e,t={}){const{signed:n,size:r}=t,s=BigInt(e);let a;r?n?a=(1n<<BigInt(r)*8n-1n)-1n:a=2n**(BigInt(r)*8n)-1n:typeof e=="number"&&(a=BigInt(Number.MAX_SAFE_INTEGER));const c=typeof a=="bigint"&&n?-a-1n:0;if(a&&s>a||s<c){const f=typeof e=="bigint"?"n":"";throw new nx({max:a?`${a}${f}`:void 0,min:`${c}${f}`,signed:n,size:r,value:`${e}${f}`})}const d=`0x${(n&&s<0?BigInt.asUintN(r*8,BigInt(s)):s).toString(16)}`;return r?di(d,r):d}function N1(e,t={}){return Er(cj.encode(e),t)}function di(e,t){return K5(e,{dir:"left",size:t})}function fi(e,t){return K5(e,{dir:"right",size:t})}function zr(e,t,n,r={}){const{strict:s}=r;H7(e,t);const a=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return s&&V7(a,t,n),a}function Wn(e){return Math.ceil((e.length-2)/2)}function ex(e,t={}){const{signed:n}=t;t.size&&Bf(e,t.size);const r=BigInt(e);if(!n)return r;const s=(e.length-2)/2,a=(1n<<BigInt(s)*8n)-1n,c=a>>1n;return r<=c?r:r-a-1n}function tx(e,t={}){const{signed:n,size:r}=t;return Number(!n&&!r?e:ex(e,t))}function fj(e,t={}){const{strict:n=!1}=t;try{return uj(e,{strict:n}),!0}catch{return!1}}class nx extends De{constructor({max:t,min:n,signed:r,size:s,value:a}){super(`Number \`${a}\` is not in safe${s?` ${s*8}-bit`:""}${r?" signed":" unsigned"} integer range ${t?`(\`${n}\` to \`${t}\`)`:`(above \`${n}\`)`}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.IntegerOutOfRangeError"})}}class vb extends De{constructor(t){super(`Value \`${typeof t=="object"?Y5(t):t}\` of type \`${typeof t}\` is an invalid hex type.`,{metaMessages:['Hex types must be represented as `"0x${string}"`.']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexTypeError"})}}class wb extends De{constructor(t){super(`Value \`${t}\` is an invalid hex value.`,{metaMessages:['Hex values must start with `"0x"` and contain only hexadecimal characters (0-9, a-f, A-F).']}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.InvalidHexValueError"})}}class hj extends De{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed \`${n}\` bytes. Given size: \`${t}\` bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeOverflowError"})}}class rx extends De{constructor({offset:t,position:n,size:r}){super(`Slice ${n==="start"?"starting":"ending"} at offset \`${t}\` is out-of-bounds (size: \`${r}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SliceOffsetOutOfBoundsError"})}}class pj extends De{constructor({size:t,targetSize:n,type:r}){super(`${r.charAt(0).toUpperCase()}${r.slice(1).toLowerCase()} size (\`${t}\`) exceeds padding size (\`${n}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Hex.SizeExceedsPaddingSizeError"})}}function mj(e){return{address:e.address,amount:sn(e.amount),index:sn(e.index),validatorIndex:sn(e.validatorIndex)}}function ox(e){return{...typeof e.baseFeePerGas=="bigint"&&{baseFeePerGas:sn(e.baseFeePerGas)},...typeof e.blobBaseFee=="bigint"&&{blobBaseFee:sn(e.blobBaseFee)},...typeof e.feeRecipient=="string"&&{feeRecipient:e.feeRecipient},...typeof e.gasLimit=="bigint"&&{gasLimit:sn(e.gasLimit)},...typeof e.number=="bigint"&&{number:sn(e.number)},...typeof e.prevRandao=="bigint"&&{prevRandao:sn(e.prevRandao)},...typeof e.time=="bigint"&&{time:sn(e.time)},...e.withdrawals&&{withdrawals:e.withdrawals.map(mj)}}}const gj="0x82ad56cb",sx="0x608060405234801561001057600080fd5b5060405161018e38038061018e83398101604081905261002f91610124565b6000808351602085016000f59050803b61004857600080fd5b6000808351602085016000855af16040513d6000823e81610067573d81fd5b3d81f35b634e487b7160e01b600052604160045260246000fd5b600082601f83011261009257600080fd5b81516001600160401b038111156100ab576100ab61006b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156100d9576100d961006b565b6040528181528382016020018510156100f157600080fd5b60005b82811015610110576020818601810151838301820152016100f4565b506000918101602001919091529392505050565b6000806040838503121561013757600080fd5b82516001600160401b0381111561014d57600080fd5b61015985828601610081565b602085015190935090506001600160401b0381111561017757600080fd5b61018385828601610081565b915050925092905056fe",yj="0x608060405234801561001057600080fd5b506040516102c03803806102c083398101604081905261002f916101e6565b836001600160a01b03163b6000036100e457600080836001600160a01b03168360405161005c9190610270565b6000604051808303816000865af19150503d8060008114610099576040519150601f19603f3d011682016040523d82523d6000602084013e61009e565b606091505b50915091508115806100b857506001600160a01b0386163b155b156100e1578060405163101bb98d60e01b81526004016100d8919061028c565b60405180910390fd5b50505b6000808451602086016000885af16040513d6000823e81610103573d81fd5b3d81f35b80516001600160a01b038116811461011e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561015457818101518382015260200161013c565b50506000910152565b600082601f83011261016e57600080fd5b81516001600160401b0381111561018757610187610123565b604051601f8201601f19908116603f011681016001600160401b03811182821017156101b5576101b5610123565b6040528181528382016020018510156101cd57600080fd5b6101de826020830160208701610139565b949350505050565b600080600080608085870312156101fc57600080fd5b61020585610107565b60208601519094506001600160401b0381111561022157600080fd5b61022d8782880161015d565b93505061023c60408601610107565b60608601519092506001600160401b0381111561025857600080fd5b6102648782880161015d565b91505092959194509250565b60008251610282818460208701610139565b9190910192915050565b60208152600082518060208401526102ab816040850160208701610139565b601f01601f1916919091016040019291505056fe",vj="0x608060405234801561001057600080fd5b5060405161069438038061069483398101604081905261002f9161051e565b600061003c848484610048565b9050806000526001601ff35b60007f64926492649264926492649264926492649264926492649264926492649264926100748361040c565b036101e7576000606080848060200190518101906100929190610577565b60405192955090935091506000906001600160a01b038516906100b69085906105dd565b6000604051808303816000865af19150503d80600081146100f3576040519150601f19603f3d011682016040523d82523d6000602084013e6100f8565b606091505b50509050876001600160a01b03163b60000361016057806101605760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90610190908b9087906004016105f9565b602060405180830381865afa1580156101ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101d19190610633565b6001600160e01b03191614945050505050610405565b6001600160a01b0384163b1561027a57604051630b135d3f60e11b808252906001600160a01b03861690631626ba7e9061022790879087906004016105f9565b602060405180830381865afa158015610244573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102689190610633565b6001600160e01b031916149050610405565b81516041146102df5760405162461bcd60e51b815260206004820152603a602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e6774680000000000006064820152608401610157565b6102e7610425565b5060208201516040808401518451859392600091859190811061030c5761030c61065d565b016020015160f81c9050601b811480159061032b57508060ff16601c14155b1561038c5760405162461bcd60e51b815260206004820152603b602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c756500000000006064820152608401610157565b60408051600081526020810180835289905260ff83169181019190915260608101849052608081018390526001600160a01b0389169060019060a0016020604051602081039080840390855afa1580156103ea573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149450505050505b9392505050565b600060208251101561041d57600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b038116811461045857600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561048c578181015183820152602001610474565b50506000910152565b600082601f8301126104a657600080fd5b81516001600160401b038111156104bf576104bf61045b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156104ed576104ed61045b565b60405281815283820160200185101561050557600080fd5b610516826020830160208701610471565b949350505050565b60008060006060848603121561053357600080fd5b835161053e81610443565b6020850151604086015191945092506001600160401b0381111561056157600080fd5b61056d86828701610495565b9150509250925092565b60008060006060848603121561058c57600080fd5b835161059781610443565b60208501519093506001600160401b038111156105b357600080fd5b6105bf86828701610495565b604086015190935090506001600160401b0381111561056157600080fd5b600082516105ef818460208701610471565b9190910192915050565b828152604060208201526000825180604084015261061e816060850160208701610471565b601f01601f1916919091016060019392505050565b60006020828403121561064557600080fd5b81516001600160e01b03198116811461040557600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572",P1="0x608060405234801561001057600080fd5b506115b9806100206000396000f3fe6080604052600436106100f35760003560e01c80634d2301cc1161008a578063a8b0574e11610059578063a8b0574e14610325578063bce38bd714610350578063c3077fa914610380578063ee82ac5e146103b2576100f3565b80634d2301cc1461026257806372425d9d1461029f57806382ad56cb146102ca57806386d516e8146102fa576100f3565b80633408e470116100c65780633408e470146101af578063399542e9146101da5780633e64a6961461020c57806342cbb15c14610237576100f3565b80630f28c97d146100f8578063174dea7114610123578063252dba421461015357806327e86d6e14610184575b600080fd5b34801561010457600080fd5b5061010d6103ef565b60405161011a9190610c0a565b60405180910390f35b61013d60048036038101906101389190610c94565b6103f7565b60405161014a9190610e94565b60405180910390f35b61016d60048036038101906101689190610f0c565b610615565b60405161017b92919061101b565b60405180910390f35b34801561019057600080fd5b506101996107ab565b6040516101a69190611064565b60405180910390f35b3480156101bb57600080fd5b506101c46107b7565b6040516101d19190610c0a565b60405180910390f35b6101f460048036038101906101ef91906110ab565b6107bf565b6040516102039392919061110b565b60405180910390f35b34801561021857600080fd5b506102216107e1565b60405161022e9190610c0a565b60405180910390f35b34801561024357600080fd5b5061024c6107e9565b6040516102599190610c0a565b60405180910390f35b34801561026e57600080fd5b50610289600480360381019061028491906111a7565b6107f1565b6040516102969190610c0a565b60405180910390f35b3480156102ab57600080fd5b506102b4610812565b6040516102c19190610c0a565b60405180910390f35b6102e460048036038101906102df919061122a565b61081a565b6040516102f19190610e94565b60405180910390f35b34801561030657600080fd5b5061030f6109e4565b60405161031c9190610c0a565b60405180910390f35b34801561033157600080fd5b5061033a6109ec565b6040516103479190611286565b60405180910390f35b61036a600480360381019061036591906110ab565b6109f4565b6040516103779190610e94565b60405180910390f35b61039a60048036038101906103959190610f0c565b610ba6565b6040516103a99392919061110b565b60405180910390f35b3480156103be57600080fd5b506103d960048036038101906103d491906112cd565b610bca565b6040516103e69190611064565b60405180910390f35b600042905090565b60606000808484905090508067ffffffffffffffff81111561041c5761041b6112fa565b5b60405190808252806020026020018201604052801561045557816020015b610442610bd5565b81526020019060019003908161043a5790505b5092503660005b828110156105c957600085828151811061047957610478611329565b5b6020026020010151905087878381811061049657610495611329565b5b90506020028101906104a89190611367565b925060008360400135905080860195508360000160208101906104cb91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16818580606001906104f2919061138f565b604051610500929190611431565b60006040518083038185875af1925050503d806000811461053d576040519150601f19603f3d011682016040523d82523d6000602084013e610542565b606091505b5083600001846020018290528215151515815250505081516020850135176105bc577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260846000fd5b826001019250505061045c565b5082341461060c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610603906114a7565b60405180910390fd5b50505092915050565b6000606043915060008484905090508067ffffffffffffffff81111561063e5761063d6112fa565b5b60405190808252806020026020018201604052801561067157816020015b606081526020019060019003908161065c5790505b5091503660005b828110156107a157600087878381811061069557610694611329565b5b90506020028101906106a791906114c7565b92508260000160208101906106bc91906111a7565b73ffffffffffffffffffffffffffffffffffffffff168380602001906106e2919061138f565b6040516106f0929190611431565b6000604051808303816000865af19150503d806000811461072d576040519150601f19603f3d011682016040523d82523d6000602084013e610732565b606091505b5086848151811061074657610745611329565b5b60200260200101819052819250505080610795576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161078c9061153b565b60405180910390fd5b81600101915050610678565b5050509250929050565b60006001430340905090565b600046905090565b6000806060439250434091506107d68686866109f4565b905093509350939050565b600048905090565b600043905090565b60008173ffffffffffffffffffffffffffffffffffffffff16319050919050565b600044905090565b606060008383905090508067ffffffffffffffff81111561083e5761083d6112fa565b5b60405190808252806020026020018201604052801561087757816020015b610864610bd5565b81526020019060019003908161085c5790505b5091503660005b828110156109db57600084828151811061089b5761089a611329565b5b602002602001015190508686838181106108b8576108b7611329565b5b90506020028101906108ca919061155b565b92508260000160208101906108df91906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060400190610905919061138f565b604051610913929190611431565b6000604051808303816000865af19150503d8060008114610950576040519150601f19603f3d011682016040523d82523d6000602084013e610955565b606091505b5082600001836020018290528215151515815250505080516020840135176109cf577f08c379a000000000000000000000000000000000000000000000000000000000600052602060045260176024527f4d756c746963616c6c333a2063616c6c206661696c656400000000000000000060445260646000fd5b8160010191505061087e565b50505092915050565b600045905090565b600041905090565b606060008383905090508067ffffffffffffffff811115610a1857610a176112fa565b5b604051908082528060200260200182016040528015610a5157816020015b610a3e610bd5565b815260200190600190039081610a365790505b5091503660005b82811015610b9c576000848281518110610a7557610a74611329565b5b60200260200101519050868683818110610a9257610a91611329565b5b9050602002810190610aa491906114c7565b9250826000016020810190610ab991906111a7565b73ffffffffffffffffffffffffffffffffffffffff16838060200190610adf919061138f565b604051610aed929190611431565b6000604051808303816000865af19150503d8060008114610b2a576040519150601f19603f3d011682016040523d82523d6000602084013e610b2f565b606091505b508260000183602001829052821515151581525050508715610b90578060000151610b8f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b869061153b565b60405180910390fd5b5b81600101915050610a58565b5050509392505050565b6000806060610bb7600186866107bf565b8093508194508295505050509250925092565b600081409050919050565b6040518060400160405280600015158152602001606081525090565b6000819050919050565b610c0481610bf1565b82525050565b6000602082019050610c1f6000830184610bfb565b92915050565b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b60008083601f840112610c5457610c53610c2f565b5b8235905067ffffffffffffffff811115610c7157610c70610c34565b5b602083019150836020820283011115610c8d57610c8c610c39565b5b9250929050565b60008060208385031215610cab57610caa610c25565b5b600083013567ffffffffffffffff811115610cc957610cc8610c2a565b5b610cd585828601610c3e565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b60008115159050919050565b610d2281610d0d565b82525050565b600081519050919050565b600082825260208201905092915050565b60005b83811015610d62578082015181840152602081019050610d47565b83811115610d71576000848401525b50505050565b6000601f19601f8301169050919050565b6000610d9382610d28565b610d9d8185610d33565b9350610dad818560208601610d44565b610db681610d77565b840191505092915050565b6000604083016000830151610dd96000860182610d19565b5060208301518482036020860152610df18282610d88565b9150508091505092915050565b6000610e0a8383610dc1565b905092915050565b6000602082019050919050565b6000610e2a82610ce1565b610e348185610cec565b935083602082028501610e4685610cfd565b8060005b85811015610e825784840389528151610e638582610dfe565b9450610e6e83610e12565b925060208a01995050600181019050610e4a565b50829750879550505050505092915050565b60006020820190508181036000830152610eae8184610e1f565b905092915050565b60008083601f840112610ecc57610ecb610c2f565b5b8235905067ffffffffffffffff811115610ee957610ee8610c34565b5b602083019150836020820283011115610f0557610f04610c39565b5b9250929050565b60008060208385031215610f2357610f22610c25565b5b600083013567ffffffffffffffff811115610f4157610f40610c2a565b5b610f4d85828601610eb6565b92509250509250929050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b6000610f918383610d88565b905092915050565b6000602082019050919050565b6000610fb182610f59565b610fbb8185610f64565b935083602082028501610fcd85610f75565b8060005b858110156110095784840389528151610fea8582610f85565b9450610ff583610f99565b925060208a01995050600181019050610fd1565b50829750879550505050505092915050565b60006040820190506110306000830185610bfb565b81810360208301526110428184610fa6565b90509392505050565b6000819050919050565b61105e8161104b565b82525050565b60006020820190506110796000830184611055565b92915050565b61108881610d0d565b811461109357600080fd5b50565b6000813590506110a58161107f565b92915050565b6000806000604084860312156110c4576110c3610c25565b5b60006110d286828701611096565b935050602084013567ffffffffffffffff8111156110f3576110f2610c2a565b5b6110ff86828701610eb6565b92509250509250925092565b60006060820190506111206000830186610bfb565b61112d6020830185611055565b818103604083015261113f8184610e1f565b9050949350505050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b600061117482611149565b9050919050565b61118481611169565b811461118f57600080fd5b50565b6000813590506111a18161117b565b92915050565b6000602082840312156111bd576111bc610c25565b5b60006111cb84828501611192565b91505092915050565b60008083601f8401126111ea576111e9610c2f565b5b8235905067ffffffffffffffff81111561120757611206610c34565b5b60208301915083602082028301111561122357611222610c39565b5b9250929050565b6000806020838503121561124157611240610c25565b5b600083013567ffffffffffffffff81111561125f5761125e610c2a565b5b61126b858286016111d4565b92509250509250929050565b61128081611169565b82525050565b600060208201905061129b6000830184611277565b92915050565b6112aa81610bf1565b81146112b557600080fd5b50565b6000813590506112c7816112a1565b92915050565b6000602082840312156112e3576112e2610c25565b5b60006112f1848285016112b8565b91505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b60008235600160800383360303811261138357611382611358565b5b80830191505092915050565b600080833560016020038436030381126113ac576113ab611358565b5b80840192508235915067ffffffffffffffff8211156113ce576113cd61135d565b5b6020830192506001820236038313156113ea576113e9611362565b5b509250929050565b600081905092915050565b82818337600083830152505050565b600061141883856113f2565b93506114258385846113fd565b82840190509392505050565b600061143e82848661140c565b91508190509392505050565b600082825260208201905092915050565b7f4d756c746963616c6c333a2076616c7565206d69736d61746368000000000000600082015250565b6000611491601a8361144a565b915061149c8261145b565b602082019050919050565b600060208201905081810360008301526114c081611484565b9050919050565b6000823560016040038336030381126114e3576114e2611358565b5b80830191505092915050565b7f4d756c746963616c6c333a2063616c6c206661696c6564000000000000000000600082015250565b600061152560178361144a565b9150611530826114ef565b602082019050919050565b6000602082019050818103600083015261155481611518565b9050919050565b60008235600160600383360303811261157757611576611358565b5b8083019150509291505056fea264697066735822122020c1bc9aacf8e4a6507193432a895a8e77094f45a1395583f07b24e860ef06cd64736f6c634300080c0033",Q0="/docs/contract/encodeDeployData";function B1(e){const{abi:t,args:n,bytecode:r}=e;if(!n||n.length===0)return r;const s=t.find(c=>"type"in c&&c.type==="constructor");if(!s)throw new Vk({docsPath:Q0});if(!("inputs"in s))throw new Hw({docsPath:Q0});if(!s.inputs||s.inputs.length===0)throw new Hw({docsPath:Q0});const a=wi(s.inputs,n);return Ar([r,a])}class Hs extends re{constructor({cause:t,message:n}={}){var s;const r=(s=n==null?void 0:n.replace("execution reverted: ",""))==null?void 0:s.replace("execution reverted","");super(`Execution reverted ${r?`with reason: ${r}`:"for an unknown reason"}.`,{cause:t,name:"ExecutionRevertedError"})}}Object.defineProperty(Hs,"code",{enumerable:!0,configurable:!0,writable:!0,value:3});Object.defineProperty(Hs,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted|gas required exceeds allowance/});class hi extends re{constructor({cause:t,maxFeePerGas:n}={}){super(`The fee cap (\`maxFeePerGas\`${n?` = ${kn(n)} gwei`:""}) cannot be higher than the maximum allowed value (2^256-1).`,{cause:t,name:"FeeCapTooHighError"})}}Object.defineProperty(hi,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/});class om extends re{constructor({cause:t,maxFeePerGas:n}={}){super(`The fee cap (\`maxFeePerGas\`${n?` = ${kn(n)}`:""} gwei) cannot be lower than the block base fee.`,{cause:t,name:"FeeCapTooLowError"})}}Object.defineProperty(om,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas less than block base fee|fee cap less than block base fee|transaction is outdated/});class sm extends re{constructor({cause:t,nonce:n}={}){super(`Nonce provided for the transaction ${n?`(${n}) `:""}is higher than the next one expected.`,{cause:t,name:"NonceTooHighError"})}}Object.defineProperty(sm,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/});class im extends re{constructor({cause:t,nonce:n}={}){super([`Nonce provided for the transaction ${n?`(${n}) `:""}is lower than the current nonce of the account.`,"Try increasing the nonce or find the latest nonce with `getTransactionCount`."].join(`
78
- `),{cause:t,name:"NonceTooLowError"})}}Object.defineProperty(im,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too low|transaction already imported|already known/});class am extends re{constructor({cause:t,nonce:n}={}){super(`Nonce provided for the transaction ${n?`(${n}) `:""}exceeds the maximum allowed nonce.`,{cause:t,name:"NonceMaxValueError"})}}Object.defineProperty(am,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce has max value/});class cm extends re{constructor({cause:t}={}){super(["The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account."].join(`
79
- `),{cause:t,metaMessages:["This error could arise when the account does not have enough funds to:"," - pay for the total gas fee,"," - pay for the value to send."," ","The cost of the transaction is calculated as `gas * gas fee + value`, where:"," - `gas` is the amount of gas needed for transaction to execute,"," - `gas fee` is the gas fee,"," - `value` is the amount of ether to send to the recipient."],name:"InsufficientFundsError"})}}Object.defineProperty(cm,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds|exceeds transaction sender account balance/});class lm extends re{constructor({cause:t,gas:n}={}){super(`The amount of gas ${n?`(${n}) `:""}provided for the transaction exceeds the limit allowed for the block.`,{cause:t,name:"IntrinsicGasTooHighError"})}}Object.defineProperty(lm,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/});class um extends re{constructor({cause:t,gas:n}={}){super(`The amount of gas ${n?`(${n}) `:""}provided for the transaction is too low.`,{cause:t,name:"IntrinsicGasTooLowError"})}}Object.defineProperty(um,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too low/});class dm extends re{constructor({cause:t}){super("The transaction type is not supported for this chain.",{cause:t,name:"TransactionTypeNotSupportedError"})}}Object.defineProperty(dm,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/});class wl extends re{constructor({cause:t,maxPriorityFeePerGas:n,maxFeePerGas:r}={}){super([`The provided tip (\`maxPriorityFeePerGas\`${n?` = ${kn(n)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${r?` = ${kn(r)} gwei`:""}).`].join(`
80
- `),{cause:t,name:"TipAboveFeeCapError"})}}Object.defineProperty(wl,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max priority fee per gas higher than max fee per gas|tip higher than fee cap/});class Yl extends re{constructor({cause:t}){super(`An error occurred while executing: ${t==null?void 0:t.shortMessage}`,{cause:t,name:"UnknownNodeError"})}}function _f(e,t){const n=(e.details||"").toLowerCase(),r=e instanceof re?e.walk(s=>(s==null?void 0:s.code)===Hs.code):e;return r instanceof re?new Hs({cause:e,message:r.details}):Hs.nodeMessage.test(n)?new Hs({cause:e,message:e.details}):hi.nodeMessage.test(n)?new hi({cause:e,maxFeePerGas:t==null?void 0:t.maxFeePerGas}):om.nodeMessage.test(n)?new om({cause:e,maxFeePerGas:t==null?void 0:t.maxFeePerGas}):sm.nodeMessage.test(n)?new sm({cause:e,nonce:t==null?void 0:t.nonce}):im.nodeMessage.test(n)?new im({cause:e,nonce:t==null?void 0:t.nonce}):am.nodeMessage.test(n)?new am({cause:e,nonce:t==null?void 0:t.nonce}):cm.nodeMessage.test(n)?new cm({cause:e}):lm.nodeMessage.test(n)?new lm({cause:e,gas:t==null?void 0:t.gas}):um.nodeMessage.test(n)?new um({cause:e,gas:t==null?void 0:t.gas}):dm.nodeMessage.test(n)?new dm({cause:e}):wl.nodeMessage.test(n)?new wl({cause:e,maxFeePerGas:t==null?void 0:t.maxFeePerGas,maxPriorityFeePerGas:t==null?void 0:t.maxPriorityFeePerGas}):new Yl({cause:e})}function ix(e,{docsPath:t,...n}){const r=(()=>{const s=_f(e,n);return s instanceof Yl?e:s})();return new z5(r,{docsPath:t,...n})}function Jl(e,{format:t}){if(!t)return{};const n={};function r(a){const c=Object.keys(a);for(const l of c)l in e&&(n[l]=e[l]),a[l]&&typeof a[l]=="object"&&!Array.isArray(a[l])&&r(a[l])}const s=t(e||{});return r(s),n}function _1(e,t){return({exclude:n,format:r})=>({exclude:n,format:(s,a)=>{const c=t(s,a);if(n)for(const l of n)delete c[l];return{...c,...r(s,a)}},type:e})}const wj={legacy:"0x0",eip2930:"0x1",eip1559:"0x2",eip4844:"0x3",eip7702:"0x4"};function qa(e,t){const n={};return typeof e.authorizationList<"u"&&(n.authorizationList=bj(e.authorizationList)),typeof e.accessList<"u"&&(n.accessList=e.accessList),typeof e.blobVersionedHashes<"u"&&(n.blobVersionedHashes=e.blobVersionedHashes),typeof e.blobs<"u"&&(typeof e.blobs[0]!="string"?n.blobs=e.blobs.map(r=>bt(r)):n.blobs=e.blobs),typeof e.data<"u"&&(n.data=e.data),e.account&&(n.from=e.account.address),typeof e.from<"u"&&(n.from=e.from),typeof e.gas<"u"&&(n.gas=le(e.gas)),typeof e.gasPrice<"u"&&(n.gasPrice=le(e.gasPrice)),typeof e.maxFeePerBlobGas<"u"&&(n.maxFeePerBlobGas=le(e.maxFeePerBlobGas)),typeof e.maxFeePerGas<"u"&&(n.maxFeePerGas=le(e.maxFeePerGas)),typeof e.maxPriorityFeePerGas<"u"&&(n.maxPriorityFeePerGas=le(e.maxPriorityFeePerGas)),typeof e.nonce<"u"&&(n.nonce=le(e.nonce)),typeof e.to<"u"&&(n.to=e.to),typeof e.type<"u"&&(n.type=wj[e.type]),typeof e.value<"u"&&(n.value=le(e.value)),n}function bj(e){return e.map(t=>({address:t.address,r:t.r?le(BigInt(t.r)):t.r,s:t.s?le(BigInt(t.s)):t.s,chainId:le(t.chainId),nonce:le(t.nonce),...typeof t.yParity<"u"?{yParity:le(t.yParity)}:{},...typeof t.v<"u"&&typeof t.yParity>"u"?{v:le(t.v)}:{}}))}function ax(){let e=()=>{},t=()=>{};return{promise:new Promise((r,s)=>{e=r,t=s}),resolve:e,reject:t}}const G0=new Map;function cx({fn:e,id:t,shouldSplitBatch:n,wait:r=0,sort:s}){const a=async()=>{const h=d();c();const p=h.map(({args:m})=>m);p.length!==0&&e(p).then(m=>{s&&Array.isArray(m)&&m.sort(s);for(let y=0;y<h.length;y++){const{resolve:v}=h[y];v==null||v([m[y],m])}}).catch(m=>{for(let y=0;y<h.length;y++){const{reject:v}=h[y];v==null||v(m)}})},c=()=>G0.delete(t),l=()=>d().map(({args:h})=>h),d=()=>G0.get(t)||[],f=h=>G0.set(t,[...d(),h]);return{flush:c,async schedule(h){const{promise:p,resolve:m,reject:y}=ax();return(n==null?void 0:n([...l(),h]))&&a(),d().length>0?(f({args:h,resolve:m,reject:y}),p):(f({args:h,resolve:m,reject:y}),setTimeout(a,r),p)}}}function bb(e){if(!(!e||e.length===0))return e.reduce((t,{slot:n,value:r})=>{if(n.length!==66)throw new Gw({size:n.length,targetSize:66,type:"hex"});if(r.length!==66)throw new Gw({size:r.length,targetSize:66,type:"hex"});return t[n]=r,t},{})}function xj(e){const{balance:t,nonce:n,state:r,stateDiff:s,code:a}=e,c={};if(a!==void 0&&(c.code=a),t!==void 0&&(c.balance=le(t)),n!==void 0&&(c.nonce=le(n)),r!==void 0&&(c.state=bb(r)),s!==void 0){if(c.state)throw new g7;c.stateDiff=bb(s)}return c}function T1(e){if(!e)return;const t={};for(const{address:n,...r}of e){if(!xt(n,{strict:!1}))throw new un({address:n});if(t[n])throw new m7({address:n});t[n]=xj(r)}return t}const Tf=2n**256n-1n;function xi(e){const{account:t,maxFeePerGas:n,maxPriorityFeePerGas:r,to:s}=e,a=t?zt(t):void 0;if(a&&!xt(a.address))throw new un({address:a.address});if(s&&!xt(s))throw new un({address:s});if(n&&n>Tf)throw new hi({maxFeePerGas:n});if(r&&n&&r>n)throw new wl({maxFeePerGas:n,maxPriorityFeePerGas:r})}async function Ha(e,t){var Q,ae,q,ee;const{account:n=e.account,authorizationList:r,batch:s=!!((Q=e.batch)!=null&&Q.multicall),blockNumber:a,blockTag:c=e.experimental_blockTag??"latest",accessList:l,blobs:d,blockOverrides:f,code:h,data:p,factory:m,factoryData:y,gas:v,gasPrice:w,maxFeePerBlobGas:C,maxFeePerGas:A,maxPriorityFeePerGas:I,nonce:S,to:j,value:N,stateOverride:T,...B}=t,O=n?zt(n):void 0;if(h&&(m||y))throw new re("Cannot provide both `code` & `factory`/`factoryData` as parameters.");if(h&&j)throw new re("Cannot provide both `code` & `to` as parameters.");const R=h&&p,W=m&&y&&j&&p,H=R||W,K=R?lx({code:h,data:p}):W?Aj({data:p,factory:m,factoryData:y,to:j}):p;try{xi(t);const U=(typeof a=="bigint"?le(a):void 0)||c,Y=f?ox(f):void 0,Z=T1(T),F=(ee=(q=(ae=e.chain)==null?void 0:ae.formatters)==null?void 0:q.transactionRequest)==null?void 0:ee.format,pe=(F||qa)({...Jl(B,{format:F}),accessList:l,account:O,authorizationList:r,blobs:d,data:K,gas:v,gasPrice:w,maxFeePerBlobGas:C,maxFeePerGas:A,maxPriorityFeePerGas:I,nonce:S,to:H?void 0:j,value:N},"call");if(s&&Cj({request:pe})&&!Z&&!Y)try{return await Ej(e,{...pe,blockNumber:a,blockTag:c})}catch(fe){if(!(fe instanceof M5)&&!(fe instanceof em))throw fe}const ne=(()=>{const fe=[pe,U];return Z&&Y?[...fe,Z,Y]:Z?[...fe,Z]:Y?[...fe,{},Y]:fe})(),oe=await e.request({method:"eth_call",params:ne});return oe==="0x"?{data:void 0}:{data:oe}}catch(te){const U=kj(te),{offchainLookup:Y,offchainLookupSignature:Z}=await de(async()=>{const{offchainLookup:F,offchainLookupSignature:X}=await import("./ccip-FxIeBDYn.js");return{offchainLookup:F,offchainLookupSignature:X}},[]);if(e.ccipRead!==!1&&(U==null?void 0:U.slice(0,10))===Z&&j)return{data:await Y(e,{data:U,to:j})};throw H&&(U==null?void 0:U.slice(0,10))==="0x101bb98d"?new S7({factory:m}):ix(te,{...t,account:O,chain:e.chain})}}function Cj({request:e}){const{data:t,to:n,...r}=e;return!(!t||t.startsWith(gj)||!n||Object.values(r).filter(s=>typeof s<"u").length>0)}async function Ej(e,t){var w;const{batchSize:n=1024,deployless:r=!1,wait:s=0}=typeof((w=e.batch)==null?void 0:w.multicall)=="object"?e.batch.multicall:{},{blockNumber:a,blockTag:c=e.experimental_blockTag??"latest",data:l,to:d}=t,f=(()=>{if(r)return null;if(t.multicallAddress)return t.multicallAddress;if(e.chain)return $a({blockNumber:a,chain:e.chain,contract:"multicall3"});throw new M5})(),p=(typeof a=="bigint"?le(a):void 0)||c,{schedule:m}=cx({id:`${e.uid}.${p}`,wait:s,shouldSplitBatch(C){return C.reduce((I,{data:S})=>I+(S.length-2),0)>n*2},fn:async C=>{const A=C.map(j=>({allowFailure:!0,callData:j.data,target:j.to})),I=$n({abi:Na,args:[A],functionName:"aggregate3"}),S=await e.request({method:"eth_call",params:[{...f===null?{data:lx({code:P1,data:I})}:{to:f,data:I}},p]});return vs({abi:Na,args:[A],functionName:"aggregate3",data:S||"0x"})}}),[{returnData:y,success:v}]=await m({data:l,to:d});if(!v)throw new jf({data:y});return y==="0x"?{data:void 0}:{data:y}}function lx(e){const{code:t,data:n}=e;return B1({abi:Eo(["constructor(bytes, bytes)"]),bytecode:sx,args:[t,n]})}function Aj(e){const{data:t,factory:n,factoryData:r,to:s}=e;return B1({abi:Eo(["constructor(address, bytes, address, bytes)"]),bytecode:yj,args:[s,t,n,r]})}function kj(e){var n;if(!(e instanceof re))return;const t=e.walk();return typeof(t==null?void 0:t.data)=="object"?(n=t.data)==null?void 0:n.data:t.data}async function or(e,t){const{abi:n,address:r,args:s,functionName:a,...c}=t,l=$n({abi:n,args:s,functionName:a});try{const{data:d}=await Ee(e,Ha,"call")({...c,data:l,to:r});return vs({abi:n,args:s,functionName:a,data:d||"0x"})}catch(d){throw ui(d,{abi:n,address:r,args:s,docsPath:"/docs/contract/readContract",functionName:a})}}async function Sj(e,t){const{blockNumber:n,blockTag:r,coinType:s,name:a,gatewayUrls:c,strict:l}=t,{chain:d}=e,f=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!d)throw new Error("client chain not configured. universalResolverAddress is required.");return $a({blockNumber:n,chain:d,contract:"ensUniversalResolver"})})(),h=d==null?void 0:d.ensTlds;if(h&&!h.some(m=>a.endsWith(m)))return null;const p=s!=null?[nm(a),BigInt(s)]:[nm(a)];try{const m=$n({abi:$w,functionName:"addr",args:p}),y={address:f,abi:Z2,functionName:"resolveWithGateways",args:[An(A1(a)),m,c??[If]],blockNumber:n,blockTag:r},w=await Ee(e,or,"readContract")(y);if(w[0]==="0x")return null;const C=vs({abi:$w,args:p,functionName:"addr",data:w[0]});return C==="0x"||Un(C)==="0x00"?null:C}catch(m){if(l)throw m;if(E1(m))return null;throw m}}class jj extends re{constructor({data:t}){super("Unable to extract image from metadata. The metadata may be malformed or invalid.",{metaMessages:["- Metadata must be a JSON object with at least an `image`, `image_url` or `image_data` property.","",`Provided data: ${JSON.stringify(t)}`],name:"EnsAvatarInvalidMetadataError"})}}class Mc extends re{constructor({reason:t}){super(`ENS NFT avatar URI is invalid. ${t}`,{name:"EnsAvatarInvalidNftUriError"})}}class O1 extends re{constructor({uri:t}){super(`Unable to resolve ENS avatar URI "${t}". The URI may be malformed, invalid, or does not respond with a valid image.`,{name:"EnsAvatarUriResolutionError"})}}class Ij extends re{constructor({namespace:t}){super(`ENS NFT avatar namespace "${t}" is not supported. Must be "erc721" or "erc1155".`,{name:"EnsAvatarUnsupportedNamespaceError"})}}const Nj=/(?<protocol>https?:\/\/[^/]*|ipfs:\/|ipns:\/|ar:\/)?(?<root>\/)?(?<subpath>ipfs\/|ipns\/)?(?<target>[\w\-.]+)(?<subtarget>\/.*)?/,Pj=/^(Qm[1-9A-HJ-NP-Za-km-z]{44,}|b[A-Za-z2-7]{58,}|B[A-Z2-7]{58,}|z[1-9A-HJ-NP-Za-km-z]{48,}|F[0-9A-F]{50,})(\/(?<target>[\w\-.]+))?(?<subtarget>\/.*)?$/,Bj=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,_j=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function Tj(e){try{const t=await fetch(e,{method:"HEAD"});if(t.status===200){const n=t.headers.get("content-type");return n==null?void 0:n.startsWith("image/")}return!1}catch(t){return typeof t=="object"&&typeof t.response<"u"||!Object.hasOwn(globalThis,"Image")?!1:new Promise(n=>{const r=new Image;r.onload=()=>{n(!0)},r.onerror=()=>{n(!1)},r.src=e})}}function xb(e,t){return e?e.endsWith("/")?e.slice(0,-1):e:t}function ux({uri:e,gatewayUrls:t}){const n=Bj.test(e);if(n)return{uri:e,isOnChain:!0,isEncoded:n};const r=xb(t==null?void 0:t.ipfs,"https://ipfs.io"),s=xb(t==null?void 0:t.arweave,"https://arweave.net"),a=e.match(Nj),{protocol:c,subpath:l,target:d,subtarget:f=""}=(a==null?void 0:a.groups)||{},h=c==="ipns:/"||l==="ipns/",p=c==="ipfs:/"||l==="ipfs/"||Pj.test(e);if(e.startsWith("http")&&!h&&!p){let y=e;return t!=null&&t.arweave&&(y=e.replace(/https:\/\/arweave.net/g,t==null?void 0:t.arweave)),{uri:y,isOnChain:!1,isEncoded:!1}}if((h||p)&&d)return{uri:`${r}/${h?"ipns":"ipfs"}/${d}${f}`,isOnChain:!1,isEncoded:!1};if(c==="ar:/"&&d)return{uri:`${s}/${d}${f||""}`,isOnChain:!1,isEncoded:!1};let m=e.replace(_j,"");if(m.startsWith("<svg")&&(m=`data:image/svg+xml;base64,${btoa(m)}`),m.startsWith("data:")||m.startsWith("{"))return{uri:m,isOnChain:!0,isEncoded:!1};throw new O1({uri:e})}function dx(e){if(typeof e!="object"||!("image"in e)&&!("image_url"in e)&&!("image_data"in e))throw new jj({data:e});return e.image||e.image_url||e.image_data}async function Oj({gatewayUrls:e,uri:t}){try{const n=await fetch(t).then(s=>s.json());return await R1({gatewayUrls:e,uri:dx(n)})}catch{throw new O1({uri:t})}}async function R1({gatewayUrls:e,uri:t}){const{uri:n,isOnChain:r}=ux({uri:t,gatewayUrls:e});if(r||await Tj(n))return n;throw new O1({uri:t})}function Rj(e){let t=e;t.startsWith("did:nft:")&&(t=t.replace("did:nft:","").replace(/_/g,"/"));const[n,r,s]=t.split("/"),[a,c]=n.split(":"),[l,d]=r.split(":");if(!a||a.toLowerCase()!=="eip155")throw new Mc({reason:"Only EIP-155 supported"});if(!c)throw new Mc({reason:"Chain ID not found"});if(!d)throw new Mc({reason:"Contract address not found"});if(!s)throw new Mc({reason:"Token ID not found"});if(!l)throw new Mc({reason:"ERC namespace not found"});return{chainID:Number.parseInt(c,10),namespace:l.toLowerCase(),contractAddress:d,tokenID:s}}async function Mj(e,{nft:t}){if(t.namespace==="erc721")return or(e,{address:t.contractAddress,abi:[{name:"tokenURI",type:"function",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"tokenURI",args:[BigInt(t.tokenID)]});if(t.namespace==="erc1155")return or(e,{address:t.contractAddress,abi:[{name:"uri",type:"function",stateMutability:"view",inputs:[{name:"_id",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"uri",args:[BigInt(t.tokenID)]});throw new Ij({namespace:t.namespace})}async function Dj(e,{gatewayUrls:t,record:n}){return/eip155:/i.test(n)?Fj(e,{gatewayUrls:t,record:n}):R1({uri:n,gatewayUrls:t})}async function Fj(e,{gatewayUrls:t,record:n}){const r=Rj(n),s=await Mj(e,{nft:r}),{uri:a,isOnChain:c,isEncoded:l}=ux({uri:s,gatewayUrls:t});if(c&&(a.includes("data:application/json;base64,")||a.startsWith("{"))){const f=l?atob(a.replace("data:application/json;base64,","")):a,h=JSON.parse(f);return R1({uri:dx(h),gatewayUrls:t})}let d=r.tokenID;return r.namespace==="erc1155"&&(d=d.replace("0x","").padStart(64,"0")),Oj({gatewayUrls:t,uri:a.replace(/(?:0x)?{id}/,d)})}async function fx(e,t){const{blockNumber:n,blockTag:r,key:s,name:a,gatewayUrls:c,strict:l}=t,{chain:d}=e,f=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!d)throw new Error("client chain not configured. universalResolverAddress is required.");return $a({blockNumber:n,chain:d,contract:"ensUniversalResolver"})})(),h=d==null?void 0:d.ensTlds;if(h&&!h.some(p=>a.endsWith(p)))return null;try{const p={address:f,abi:Z2,args:[An(A1(a)),$n({abi:Ww,functionName:"text",args:[nm(a),s]}),c??[If]],functionName:"resolveWithGateways",blockNumber:n,blockTag:r},y=await Ee(e,or,"readContract")(p);if(y[0]==="0x")return null;const v=vs({abi:Ww,functionName:"text",data:y[0]});return v===""?null:v}catch(p){if(l)throw p;if(E1(p))return null;throw p}}async function hx(e,{blockNumber:t,blockTag:n,assetGatewayUrls:r,name:s,gatewayUrls:a,strict:c,universalResolverAddress:l}){const d=await Ee(e,fx,"getEnsText")({blockNumber:t,blockTag:n,key:"avatar",name:s,universalResolverAddress:l,gatewayUrls:a,strict:c});if(!d)return null;try{return await Dj(e,{record:d,gatewayUrls:r})}catch{return null}}async function px(e,t){const{address:n,blockNumber:r,blockTag:s,coinType:a=60n,gatewayUrls:c,strict:l}=t,{chain:d}=e,f=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!d)throw new Error("client chain not configured. universalResolverAddress is required.");return $a({blockNumber:r,chain:d,contract:"ensUniversalResolver"})})();try{const h={address:f,abi:qk,args:[n,a,c??[If]],functionName:"reverseWithGateways",blockNumber:r,blockTag:s},p=Ee(e,or,"readContract"),[m]=await p(h);return m||null}catch(h){if(l)throw h;if(E1(h))return null;throw h}}async function Lj(e,t){const{blockNumber:n,blockTag:r,name:s}=t,{chain:a}=e,c=(()=>{if(t.universalResolverAddress)return t.universalResolverAddress;if(!a)throw new Error("client chain not configured. universalResolverAddress is required.");return $a({blockNumber:n,chain:a,contract:"ensUniversalResolver"})})(),l=a==null?void 0:a.ensTlds;if(l&&!l.some(f=>s.endsWith(f)))throw new Error(`${s} is not a valid ENS TLD (${l==null?void 0:l.join(", ")}) for chain "${a.name}" (id: ${a.id}).`);const[d]=await Ee(e,or,"readContract")({address:c,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"},{type:"uint256"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[An(A1(s))],blockNumber:n,blockTag:r});return d}async function mx(e,t){var C,A,I;const{account:n=e.account,blockNumber:r,blockTag:s="latest",blobs:a,data:c,gas:l,gasPrice:d,maxFeePerBlobGas:f,maxFeePerGas:h,maxPriorityFeePerGas:p,to:m,value:y,...v}=t,w=n?zt(n):void 0;try{xi(t);const j=(typeof r=="bigint"?le(r):void 0)||s,N=(I=(A=(C=e.chain)==null?void 0:C.formatters)==null?void 0:A.transactionRequest)==null?void 0:I.format,B=(N||qa)({...Jl(v,{format:N}),account:w,blobs:a,data:c,gas:l,gasPrice:d,maxFeePerBlobGas:f,maxFeePerGas:h,maxPriorityFeePerGas:p,to:m,value:y},"createAccessList"),O=await e.request({method:"eth_createAccessList",params:[B,j]});return{accessList:O.accessList,gasUsed:BigInt(O.gasUsed)}}catch(S){throw ix(S,{...t,account:w,chain:e.chain})}}function Of(e,{method:t}){var r,s;const n={};return e.transport.type==="fallback"&&((s=(r=e.transport).onResponse)==null||s.call(r,({method:a,response:c,status:l,transport:d})=>{l==="success"&&t===a&&(n[c]=d.request)})),(a=>n[a]||e.request)}async function Uj(e){const t=Of(e,{method:"eth_newBlockFilter"}),n=await e.request({method:"eth_newBlockFilter"});return{id:n,request:t(n),type:"block"}}class zj extends re{constructor(t){super(`Filter type "${t}" is not supported.`,{name:"FilterTypeNotSupportedError"})}}const Cb="/docs/contract/encodeEventTopics";function Zl(e){var d;const{abi:t,eventName:n,args:r}=e;let s=t[0];if(n){const f=bi({abi:t,name:n});if(!f)throw new Qw(n,{docsPath:Cb});s=f}if(s.type!=="event")throw new Qw(void 0,{docsPath:Cb});const a=wr(s),c=kf(a);let l=[];if(r&&"inputs"in s){const f=(d=s.inputs)==null?void 0:d.filter(p=>"indexed"in p&&p.indexed),h=Array.isArray(r)?r:Object.values(r).length>0?(f==null?void 0:f.map(p=>r[p.name]))??[]:[];h.length>0&&(l=(f==null?void 0:f.map((p,m)=>Array.isArray(h[m])?h[m].map((y,v)=>Eb({param:p,value:h[m][v]})):typeof h[m]<"u"&&h[m]!==null?Eb({param:p,value:h[m]}):null))??[])}return[c,...l]}function Eb({param:e,value:t}){if(e.type==="string"||e.type==="bytes")return Lt(za(t));if(e.type==="tuple"||e.type.match(/^(.*)\[(\d+)?\]$/))throw new zj(e.type);return wi([e],[t])}async function gx(e,t){const{address:n,abi:r,args:s,eventName:a,fromBlock:c,strict:l,toBlock:d}=t,f=Of(e,{method:"eth_newFilter"}),h=a?Zl({abi:r,args:s,eventName:a}):void 0,p=await e.request({method:"eth_newFilter",params:[{address:n,fromBlock:typeof c=="bigint"?le(c):c,toBlock:typeof d=="bigint"?le(d):d,topics:h}]});return{abi:r,args:s,eventName:a,id:p,request:f(p),strict:!!l,type:"event"}}async function yx(e,{address:t,args:n,event:r,events:s,fromBlock:a,strict:c,toBlock:l}={}){const d=s??(r?[r]:void 0),f=Of(e,{method:"eth_newFilter"});let h=[];d&&(h=[d.flatMap(y=>Zl({abi:[y],eventName:y.name,args:n}))],r&&(h=h[0]));const p=await e.request({method:"eth_newFilter",params:[{address:t,fromBlock:typeof a=="bigint"?le(a):a,toBlock:typeof l=="bigint"?le(l):l,...h.length?{topics:h}:{}}]});return{abi:d,args:n,eventName:r?r.name:void 0,fromBlock:a,id:p,request:f(p),strict:!!c,toBlock:l,type:"event"}}async function vx(e){const t=Of(e,{method:"eth_newPendingTransactionFilter"}),n=await e.request({method:"eth_newPendingTransactionFilter"});return{id:n,request:t(n),type:"transaction"}}function Wj(e){const t=Lt(`0x${e.substring(4)}`).substring(26);return Ef(`0x${t}`)}async function $j({hash:e,signature:t}){const n=$r(e)?e:An(e),{secp256k1:r}=await de(async()=>{const{secp256k1:c}=await Promise.resolve().then(()=>fN);return{secp256k1:c}},void 0);return`0x${(()=>{if(typeof t=="object"&&"r"in t&&"s"in t){const{r:f,s:h,v:p,yParity:m}=t,y=Number(m??p),v=Ab(y);return new r.Signature(an(f),an(h)).addRecoveryBit(v)}const c=$r(t)?t:An(t);if(rt(c)!==65)throw new Error("invalid signature length");const l=br(`0x${c.slice(130)}`),d=Ab(l);return r.Signature.fromCompact(c.substring(2,130)).addRecoveryBit(d)})().recoverPublicKey(n.substring(2)).toHex(!1)}`}function Ab(e){if(e===0||e===1)return e;if(e===27)return 0;if(e===28)return 1;throw new Error("Invalid yParityOrV value")}async function fm({hash:e,signature:t}){return Wj(await $j({hash:e,signature:t}))}function ms(e,t="hex"){const n=wx(e),r=m1(new Uint8Array(n.length));return n.encode(r),t==="hex"?bt(r.bytes):r.bytes}function wx(e){return Array.isArray(e)?qj(e.map(t=>wx(t))):Hj(e)}function qj(e){const t=e.reduce((s,a)=>s+a.length,0),n=bx(t);return{length:t<=55?1+t:1+n+t,encode(s){t<=55?s.pushByte(192+t):(s.pushByte(247+n),n===1?s.pushUint8(t):n===2?s.pushUint16(t):n===3?s.pushUint24(t):s.pushUint32(t));for(const{encode:a}of e)a(s)}}}function Hj(e){const t=typeof e=="string"?xr(e):e,n=bx(t.length);return{length:t.length===1&&t[0]<128?1:t.length<=55?1+t.length:1+n+t.length,encode(s){t.length===1&&t[0]<128?s.pushBytes(t):t.length<=55?(s.pushByte(128+t.length),s.pushBytes(t)):(s.pushByte(183+n),n===1?s.pushUint8(t.length):n===2?s.pushUint16(t.length):n===3?s.pushUint24(t.length):s.pushUint32(t.length),s.pushBytes(t))}}}function bx(e){if(e<2**8)return 1;if(e<2**16)return 2;if(e<2**24)return 3;if(e<2**32)return 4;throw new re("Length is too large.")}function Vj(e){const{chainId:t,nonce:n,to:r}=e,s=e.contractAddress??e.address,a=Lt(Ar(["0x05",ms([t?le(t):"0x",s,n?le(n):"0x"])]));return r==="bytes"?xr(a):a}async function M1(e){const{authorization:t,signature:n}=e;return fm({hash:Vj(t),signature:n??t})}class Qj extends re{constructor(t,{account:n,docsPath:r,chain:s,data:a,gas:c,gasPrice:l,maxFeePerGas:d,maxPriorityFeePerGas:f,nonce:h,to:p,value:m}){var v;const y=Vl({from:n==null?void 0:n.address,to:p,value:typeof m<"u"&&`${b1(m)} ${((v=s==null?void 0:s.nativeCurrency)==null?void 0:v.symbol)||"ETH"}`,data:a,gas:c,gasPrice:typeof l<"u"&&`${kn(l)} gwei`,maxFeePerGas:typeof d<"u"&&`${kn(d)} gwei`,maxPriorityFeePerGas:typeof f<"u"&&`${kn(f)} gwei`,nonce:h});super(t.shortMessage,{cause:t,docsPath:r,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Estimate Gas Arguments:",y].filter(Boolean),name:"EstimateGasExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}function Gj(e,{docsPath:t,...n}){const r=(()=>{const s=_f(e,n);return s instanceof Yl?e:s})();return new Qj(r,{docsPath:t,...n})}class xx extends re{constructor(){super("`baseFeeMultiplier` must be greater than 1.",{name:"BaseFeeScalarError"})}}class D1 extends re{constructor(){super("Chain does not support EIP-1559 fees.",{name:"Eip1559FeesNotSupportedError"})}}class Kj extends re{constructor({maxPriorityFeePerGas:t}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${kn(t)} gwei).`,{name:"MaxFeePerGasTooLowError"})}}class Cx extends re{constructor({blockHash:t,blockNumber:n}){let r="Block";t&&(r=`Block at hash "${t}"`),n&&(r=`Block at number "${n}"`),super(`${r} could not be found.`,{name:"BlockNotFoundError"})}}const Ex={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559","0x3":"eip4844","0x4":"eip7702"};function Xl(e,t){const n={...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,chainId:e.chainId?br(e.chainId):void 0,gas:e.gas?BigInt(e.gas):void 0,gasPrice:e.gasPrice?BigInt(e.gasPrice):void 0,maxFeePerBlobGas:e.maxFeePerBlobGas?BigInt(e.maxFeePerBlobGas):void 0,maxFeePerGas:e.maxFeePerGas?BigInt(e.maxFeePerGas):void 0,maxPriorityFeePerGas:e.maxPriorityFeePerGas?BigInt(e.maxPriorityFeePerGas):void 0,nonce:e.nonce?br(e.nonce):void 0,to:e.to?e.to:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,type:e.type?Ex[e.type]:void 0,typeHex:e.type?e.type:void 0,value:e.value?BigInt(e.value):void 0,v:e.v?BigInt(e.v):void 0};return e.authorizationList&&(n.authorizationList=Jj(e.authorizationList)),n.yParity=(()=>{if(e.yParity)return Number(e.yParity);if(typeof n.v=="bigint"){if(n.v===0n||n.v===27n)return 0;if(n.v===1n||n.v===28n)return 1;if(n.v>=35n)return n.v%2n===0n?1:0}})(),n.type==="legacy"&&(delete n.accessList,delete n.maxFeePerBlobGas,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas,delete n.yParity),n.type==="eip2930"&&(delete n.maxFeePerBlobGas,delete n.maxFeePerGas,delete n.maxPriorityFeePerGas),n.type==="eip1559"&&delete n.maxFeePerBlobGas,n}const Yj=_1("transaction",Xl);function Jj(e){return e.map(t=>({address:t.address,chainId:Number(t.chainId),nonce:Number(t.nonce),r:t.r,s:t.s,yParity:Number(t.yParity)}))}function F1(e,t){const n=(e.transactions??[]).map(r=>typeof r=="string"?r:Xl(r));return{...e,baseFeePerGas:e.baseFeePerGas?BigInt(e.baseFeePerGas):null,blobGasUsed:e.blobGasUsed?BigInt(e.blobGasUsed):void 0,difficulty:e.difficulty?BigInt(e.difficulty):void 0,excessBlobGas:e.excessBlobGas?BigInt(e.excessBlobGas):void 0,gasLimit:e.gasLimit?BigInt(e.gasLimit):void 0,gasUsed:e.gasUsed?BigInt(e.gasUsed):void 0,hash:e.hash?e.hash:null,logsBloom:e.logsBloom?e.logsBloom:null,nonce:e.nonce?e.nonce:null,number:e.number?BigInt(e.number):null,size:e.size?BigInt(e.size):void 0,timestamp:e.timestamp?BigInt(e.timestamp):void 0,transactions:n,totalDifficulty:e.totalDifficulty?BigInt(e.totalDifficulty):null}}const Zj=_1("block",F1);async function yr(e,{blockHash:t,blockNumber:n,blockTag:r=e.experimental_blockTag??"latest",includeTransactions:s}={}){var f,h,p;const a=s??!1,c=n!==void 0?le(n):void 0;let l=null;if(t?l=await e.request({method:"eth_getBlockByHash",params:[t,a]},{dedupe:!0}):l=await e.request({method:"eth_getBlockByNumber",params:[c||r,a]},{dedupe:!!c}),!l)throw new Cx({blockHash:t,blockNumber:n});return(((p=(h=(f=e.chain)==null?void 0:f.formatters)==null?void 0:h.block)==null?void 0:p.format)||F1)(l,"getBlock")}async function L1(e){const t=await e.request({method:"eth_gasPrice"});return BigInt(t)}async function Xj(e,t){return Ax(e,t)}async function Ax(e,t){var a,c;const{block:n,chain:r=e.chain,request:s}=t||{};try{const l=((a=r==null?void 0:r.fees)==null?void 0:a.maxPriorityFeePerGas)??((c=r==null?void 0:r.fees)==null?void 0:c.defaultPriorityFee);if(typeof l=="function"){const f=n||await Ee(e,yr,"getBlock")({}),h=await l({block:f,client:e,request:s});if(h===null)throw new Error;return h}if(typeof l<"u")return l;const d=await e.request({method:"eth_maxPriorityFeePerGas"});return an(d)}catch{const[l,d]=await Promise.all([n?Promise.resolve(n):Ee(e,yr,"getBlock")({}),Ee(e,L1,"getGasPrice")({})]);if(typeof l.baseFeePerGas!="bigint")throw new D1;const f=d-l.baseFeePerGas;return f<0n?0n:f}}async function eI(e,t){return hm(e,t)}async function hm(e,t){var m,y;const{block:n,chain:r=e.chain,request:s,type:a="eip1559"}=t||{},c=await(async()=>{var v,w;return typeof((v=r==null?void 0:r.fees)==null?void 0:v.baseFeeMultiplier)=="function"?r.fees.baseFeeMultiplier({block:n,client:e,request:s}):((w=r==null?void 0:r.fees)==null?void 0:w.baseFeeMultiplier)??1.2})();if(c<1)throw new xx;const d=10**(((m=c.toString().split(".")[1])==null?void 0:m.length)??0),f=v=>v*BigInt(Math.ceil(c*d))/BigInt(d),h=n||await Ee(e,yr,"getBlock")({});if(typeof((y=r==null?void 0:r.fees)==null?void 0:y.estimateFeesPerGas)=="function"){const v=await r.fees.estimateFeesPerGas({block:n,client:e,multiply:f,request:s,type:a});if(v!==null)return v}if(a==="eip1559"){if(typeof h.baseFeePerGas!="bigint")throw new D1;const v=typeof(s==null?void 0:s.maxPriorityFeePerGas)=="bigint"?s.maxPriorityFeePerGas:await Ax(e,{block:h,chain:r,request:s}),w=f(h.baseFeePerGas);return{maxFeePerGas:(s==null?void 0:s.maxFeePerGas)??w+v,maxPriorityFeePerGas:v}}return{gasPrice:(s==null?void 0:s.gasPrice)??f(await Ee(e,L1,"getGasPrice")({}))}}async function kx(e,{address:t,blockTag:n="latest",blockNumber:r}){const s=await e.request({method:"eth_getTransactionCount",params:[t,typeof r=="bigint"?le(r):n]},{dedupe:!!r});return br(s)}function U1(e){const{kzg:t}=e,n=e.to??(typeof e.blobs[0]=="string"?"hex":"bytes"),r=typeof e.blobs[0]=="string"?e.blobs.map(a=>xr(a)):e.blobs,s=[];for(const a of r)s.push(Uint8Array.from(t.blobToKzgCommitment(a)));return n==="bytes"?s:s.map(a=>bt(a))}function z1(e){const{kzg:t}=e,n=e.to??(typeof e.blobs[0]=="string"?"hex":"bytes"),r=typeof e.blobs[0]=="string"?e.blobs.map(c=>xr(c)):e.blobs,s=typeof e.commitments[0]=="string"?e.commitments.map(c=>xr(c)):e.commitments,a=[];for(let c=0;c<r.length;c++){const l=r[c],d=s[c];a.push(Uint8Array.from(t.computeBlobKzgProof(l,d)))}return n==="bytes"?a:a.map(c=>bt(c))}function tI(e,t,n,r){if(typeof e.setBigUint64=="function")return e.setBigUint64(t,n,r);const s=BigInt(32),a=BigInt(4294967295),c=Number(n>>s&a),l=Number(n&a),d=r?4:0,f=r?0:4;e.setUint32(t+d,c,r),e.setUint32(t+f,l,r)}function nI(e,t,n){return e&t^~e&n}function rI(e,t,n){return e&t^e&n^t&n}class Sx extends h1{constructor(t,n,r,s){super(),this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.blockLen=t,this.outputLen=n,this.padOffset=r,this.isLE=s,this.buffer=new Uint8Array(t),this.view=F0(this.buffer)}update(t){_a(this),t=xf(t),ds(t);const{view:n,buffer:r,blockLen:s}=this,a=t.length;for(let c=0;c<a;){const l=Math.min(s-this.pos,a-c);if(l===s){const d=F0(t);for(;s<=a-c;c+=s)this.process(d,c);continue}r.set(t.subarray(c,c+l),this.pos),this.pos+=l,c+=l,this.pos===s&&(this.process(n,0),this.pos=0)}return this.length+=t.length,this.roundClean(),this}digestInto(t){_a(this),d5(t,this),this.finished=!0;const{buffer:n,view:r,blockLen:s,isLE:a}=this;let{pos:c}=this;n[c++]=128,fs(this.buffer.subarray(c)),this.padOffset>s-c&&(this.process(r,0),c=0);for(let p=c;p<s;p++)n[p]=0;tI(r,s-8,BigInt(this.length*8),a),this.process(r,0);const l=F0(t),d=this.outputLen;if(d%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const f=d/4,h=this.get();if(f>h.length)throw new Error("_sha2: outputLen bigger than state");for(let p=0;p<f;p++)l.setUint32(4*p,h[p],a)}digest(){const{buffer:t,outputLen:n}=this;this.digestInto(t);const r=t.slice(0,n);return this.destroy(),r}_cloneInto(t){t||(t=new this.constructor),t.set(...this.get());const{blockLen:n,buffer:r,length:s,finished:a,destroyed:c,pos:l}=this;return t.destroyed=c,t.finished=a,t.length=s,t.pos=l,s%n&&t.buffer.set(r),t}clone(){return this._cloneInto()}}const Go=Uint32Array.from([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),Gt=Uint32Array.from([3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]),Kt=Uint32Array.from([1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209]),oI=Uint32Array.from([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]),Ko=new Uint32Array(64);class sI extends Sx{constructor(t=32){super(64,t,8,!1),this.A=Go[0]|0,this.B=Go[1]|0,this.C=Go[2]|0,this.D=Go[3]|0,this.E=Go[4]|0,this.F=Go[5]|0,this.G=Go[6]|0,this.H=Go[7]|0}get(){const{A:t,B:n,C:r,D:s,E:a,F:c,G:l,H:d}=this;return[t,n,r,s,a,c,l,d]}set(t,n,r,s,a,c,l,d){this.A=t|0,this.B=n|0,this.C=r|0,this.D=s|0,this.E=a|0,this.F=c|0,this.G=l|0,this.H=d|0}process(t,n){for(let p=0;p<16;p++,n+=4)Ko[p]=t.getUint32(n,!1);for(let p=16;p<64;p++){const m=Ko[p-15],y=Ko[p-2],v=Or(m,7)^Or(m,18)^m>>>3,w=Or(y,17)^Or(y,19)^y>>>10;Ko[p]=w+Ko[p-7]+v+Ko[p-16]|0}let{A:r,B:s,C:a,D:c,E:l,F:d,G:f,H:h}=this;for(let p=0;p<64;p++){const m=Or(l,6)^Or(l,11)^Or(l,25),y=h+m+nI(l,d,f)+oI[p]+Ko[p]|0,w=(Or(r,2)^Or(r,13)^Or(r,22))+rI(r,s,a)|0;h=f,f=d,d=l,l=c+y|0,c=a,a=s,s=r,r=y+w|0}r=r+this.A|0,s=s+this.B|0,a=a+this.C|0,c=c+this.D|0,l=l+this.E|0,d=d+this.F|0,f=f+this.G|0,h=h+this.H|0,this.set(r,s,a,c,l,d,f,h)}roundClean(){fs(Ko)}destroy(){this.set(0,0,0,0,0,0,0,0),fs(this.buffer)}}const jx=u5(["0x428a2f98d728ae22","0x7137449123ef65cd","0xb5c0fbcfec4d3b2f","0xe9b5dba58189dbbc","0x3956c25bf348b538","0x59f111f1b605d019","0x923f82a4af194f9b","0xab1c5ed5da6d8118","0xd807aa98a3030242","0x12835b0145706fbe","0x243185be4ee4b28c","0x550c7dc3d5ffb4e2","0x72be5d74f27b896f","0x80deb1fe3b1696b1","0x9bdc06a725c71235","0xc19bf174cf692694","0xe49b69c19ef14ad2","0xefbe4786384f25e3","0x0fc19dc68b8cd5b5","0x240ca1cc77ac9c65","0x2de92c6f592b0275","0x4a7484aa6ea6e483","0x5cb0a9dcbd41fbd4","0x76f988da831153b5","0x983e5152ee66dfab","0xa831c66d2db43210","0xb00327c898fb213f","0xbf597fc7beef0ee4","0xc6e00bf33da88fc2","0xd5a79147930aa725","0x06ca6351e003826f","0x142929670a0e6e70","0x27b70a8546d22ffc","0x2e1b21385c26c926","0x4d2c6dfc5ac42aed","0x53380d139d95b3df","0x650a73548baf63de","0x766a0abb3c77b2a8","0x81c2c92e47edaee6","0x92722c851482353b","0xa2bfe8a14cf10364","0xa81a664bbc423001","0xc24b8b70d0f89791","0xc76c51a30654be30","0xd192e819d6ef5218","0xd69906245565a910","0xf40e35855771202a","0x106aa07032bbd1b8","0x19a4c116b8d2d0c8","0x1e376c085141ab53","0x2748774cdf8eeb99","0x34b0bcb5e19b48a8","0x391c0cb3c5c95a63","0x4ed8aa4ae3418acb","0x5b9cca4f7763e373","0x682e6ff3d6b2b8a3","0x748f82ee5defb2fc","0x78a5636f43172f60","0x84c87814a1f0ab72","0x8cc702081a6439ec","0x90befffa23631e28","0xa4506cebde82bde9","0xbef9a3f7b2c67915","0xc67178f2e372532b","0xca273eceea26619c","0xd186b8c721c0c207","0xeada7dd6cde0eb1e","0xf57d4f7fee6ed178","0x06f067aa72176fba","0x0a637dc5a2c898a6","0x113f9804bef90dae","0x1b710b35131c471b","0x28db77f523047d84","0x32caab7b40c72493","0x3c9ebe0a15c9bebc","0x431d67c49c100d4c","0x4cc5d4becb3e42b6","0x597f299cfc657e2a","0x5fcb6fab3ad6faec","0x6c44198c4a475817"].map(e=>BigInt(e))),iI=jx[0],aI=jx[1],Yo=new Uint32Array(80),Jo=new Uint32Array(80);class Ix extends Sx{constructor(t=64){super(128,t,16,!1),this.Ah=Kt[0]|0,this.Al=Kt[1]|0,this.Bh=Kt[2]|0,this.Bl=Kt[3]|0,this.Ch=Kt[4]|0,this.Cl=Kt[5]|0,this.Dh=Kt[6]|0,this.Dl=Kt[7]|0,this.Eh=Kt[8]|0,this.El=Kt[9]|0,this.Fh=Kt[10]|0,this.Fl=Kt[11]|0,this.Gh=Kt[12]|0,this.Gl=Kt[13]|0,this.Hh=Kt[14]|0,this.Hl=Kt[15]|0}get(){const{Ah:t,Al:n,Bh:r,Bl:s,Ch:a,Cl:c,Dh:l,Dl:d,Eh:f,El:h,Fh:p,Fl:m,Gh:y,Gl:v,Hh:w,Hl:C}=this;return[t,n,r,s,a,c,l,d,f,h,p,m,y,v,w,C]}set(t,n,r,s,a,c,l,d,f,h,p,m,y,v,w,C){this.Ah=t|0,this.Al=n|0,this.Bh=r|0,this.Bl=s|0,this.Ch=a|0,this.Cl=c|0,this.Dh=l|0,this.Dl=d|0,this.Eh=f|0,this.El=h|0,this.Fh=p|0,this.Fl=m|0,this.Gh=y|0,this.Gl=v|0,this.Hh=w|0,this.Hl=C|0}process(t,n){for(let S=0;S<16;S++,n+=4)Yo[S]=t.getUint32(n),Jo[S]=t.getUint32(n+=4);for(let S=16;S<80;S++){const j=Yo[S-15]|0,N=Jo[S-15]|0,T=Gi(j,N,1)^Gi(j,N,8)^Jw(j,N,7),B=Ki(j,N,1)^Ki(j,N,8)^Zw(j,N,7),O=Yo[S-2]|0,R=Jo[S-2]|0,W=Gi(O,R,19)^xd(O,R,61)^Jw(O,R,6),H=Ki(O,R,19)^Cd(O,R,61)^Zw(O,R,6),K=C4(B,H,Jo[S-7],Jo[S-16]),Q=E4(K,T,W,Yo[S-7],Yo[S-16]);Yo[S]=Q|0,Jo[S]=K|0}let{Ah:r,Al:s,Bh:a,Bl:c,Ch:l,Cl:d,Dh:f,Dl:h,Eh:p,El:m,Fh:y,Fl:v,Gh:w,Gl:C,Hh:A,Hl:I}=this;for(let S=0;S<80;S++){const j=Gi(p,m,14)^Gi(p,m,18)^xd(p,m,41),N=Ki(p,m,14)^Ki(p,m,18)^Cd(p,m,41),T=p&y^~p&w,B=m&v^~m&C,O=A4(I,N,B,aI[S],Jo[S]),R=k4(O,A,j,T,iI[S],Yo[S]),W=O|0,H=Gi(r,s,28)^xd(r,s,34)^xd(r,s,39),K=Ki(r,s,28)^Cd(r,s,34)^Cd(r,s,39),Q=r&a^r&l^a&l,ae=s&c^s&d^c&d;A=w|0,I=C|0,w=y|0,C=v|0,y=p|0,v=m|0,{h:p,l:m}=so(f|0,h|0,R|0,W|0),f=l|0,h=d|0,l=a|0,d=c|0,a=r|0,c=s|0;const q=b4(W,K,ae);r=x4(q,R,H,Q),s=q|0}({h:r,l:s}=so(this.Ah|0,this.Al|0,r|0,s|0)),{h:a,l:c}=so(this.Bh|0,this.Bl|0,a|0,c|0),{h:l,l:d}=so(this.Ch|0,this.Cl|0,l|0,d|0),{h:f,l:h}=so(this.Dh|0,this.Dl|0,f|0,h|0),{h:p,l:m}=so(this.Eh|0,this.El|0,p|0,m|0),{h:y,l:v}=so(this.Fh|0,this.Fl|0,y|0,v|0),{h:w,l:C}=so(this.Gh|0,this.Gl|0,w|0,C|0),{h:A,l:I}=so(this.Hh|0,this.Hl|0,A|0,I|0),this.set(r,s,a,c,l,d,f,h,p,m,y,v,w,C,A,I)}roundClean(){fs(Yo,Jo)}destroy(){fs(this.buffer),this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)}}class cI extends Ix{constructor(){super(48),this.Ah=Gt[0]|0,this.Al=Gt[1]|0,this.Bh=Gt[2]|0,this.Bl=Gt[3]|0,this.Ch=Gt[4]|0,this.Cl=Gt[5]|0,this.Dh=Gt[6]|0,this.Dl=Gt[7]|0,this.Eh=Gt[8]|0,this.El=Gt[9]|0,this.Fh=Gt[10]|0,this.Fl=Gt[11]|0,this.Gh=Gt[12]|0,this.Gl=Gt[13]|0,this.Hh=Gt[14]|0,this.Hl=Gt[15]|0}}const Nx=Cf(()=>new sI),Vz=Cf(()=>new Ix),Qz=Cf(()=>new cI),lI=Nx;function uI(e,t){return lI($r(e,{strict:!1})?za(e):e)}function dI(e){const{commitment:t,version:n=1}=e,r=e.to??(typeof t=="string"?"hex":"bytes"),s=uI(t);return s.set([n],0),r==="bytes"?s:bt(s)}function Px(e){const{commitments:t,version:n}=e,r=e.to??(typeof t[0]=="string"?"hex":"bytes"),s=[];for(const a of t)s.push(dI({commitment:a,to:r,version:n}));return s}const kb=6,Bx=32,W1=4096,_x=Bx*W1,Sb=_x*kb-1-1*W1*kb,Tx=1;class fI extends re{constructor({maxSize:t,size:n}){super("Blob size is too large.",{metaMessages:[`Max: ${t} bytes`,`Given: ${n} bytes`],name:"BlobSizeTooLargeError"})}}class Ox extends re{constructor(){super("Blob data must not be empty.",{name:"EmptyBlobError"})}}class hI extends re{constructor({hash:t,size:n}){super(`Versioned hash "${t}" size is invalid.`,{metaMessages:["Expected: 32",`Received: ${n}`],name:"InvalidVersionedHashSizeError"})}}class pI extends re{constructor({hash:t,version:n}){super(`Versioned hash "${t}" version is invalid.`,{metaMessages:[`Expected: ${Tx}`,`Received: ${n}`],name:"InvalidVersionedHashVersionError"})}}function mI(e){const t=e.to??(typeof e.data=="string"?"hex":"bytes"),n=typeof e.data=="string"?xr(e.data):e.data,r=rt(n);if(!r)throw new Ox;if(r>Sb)throw new fI({maxSize:Sb,size:r});const s=[];let a=!0,c=0;for(;a;){const l=m1(new Uint8Array(_x));let d=0;for(;d<W1;){const f=n.slice(c,c+(Bx-1));if(l.pushByte(0),l.pushBytes(f),f.length<31){l.pushByte(128),a=!1;break}d++,c+=31}s.push(l)}return t==="bytes"?s.map(l=>l.bytes):s.map(l=>bt(l.bytes))}function Rx(e){const{data:t,kzg:n,to:r}=e,s=e.blobs??mI({data:t,to:r}),a=e.commitments??U1({blobs:s,kzg:n,to:r}),c=e.proofs??z1({blobs:s,commitments:a,kzg:n,to:r}),l=[];for(let d=0;d<s.length;d++)l.push({blob:s[d],commitment:a[d],proof:c[d]});return l}function Mx(e){if(e.type)return e.type;if(typeof e.authorizationList<"u")return"eip7702";if(typeof e.blobs<"u"||typeof e.blobVersionedHashes<"u"||typeof e.maxFeePerBlobGas<"u"||typeof e.sidecars<"u")return"eip4844";if(typeof e.maxFeePerGas<"u"||typeof e.maxPriorityFeePerGas<"u")return"eip1559";if(typeof e.gasPrice<"u")return typeof e.accessList<"u"?"eip2930":"legacy";throw new w7({transaction:e})}function Dx(e,{docsPath:t,...n}){const r=(()=>{const s=_f(e,n);return s instanceof Yl?e:s})();return new x7(r,{docsPath:t,...n})}async function Rf(e){const t=await e.request({method:"eth_chainId"},{dedupe:!0});return br(t)}async function Fx(e,t){var O,R,W,H,K;const{account:n=e.account,accessList:r,authorizationList:s,chain:a=e.chain,blobVersionedHashes:c,blobs:l,data:d,gas:f,gasPrice:h,maxFeePerBlobGas:p,maxFeePerGas:m,maxPriorityFeePerGas:y,nonce:v,nonceManager:w,to:C,type:A,value:I,...S}=t,j=await(async()=>{if(!n||!w||typeof v<"u")return v;const Q=zt(n),ae=a?a.id:await Ee(e,Rf,"getChainId")({});return await w.consume({address:Q.address,chainId:ae,client:e})})();xi(t);const N=(R=(O=a==null?void 0:a.formatters)==null?void 0:O.transactionRequest)==null?void 0:R.format,B=(N||qa)({...Jl(S,{format:N}),account:n?zt(n):void 0,accessList:r,authorizationList:s,blobs:l,blobVersionedHashes:c,data:d,gas:f,gasPrice:h,maxFeePerBlobGas:p,maxFeePerGas:m,maxPriorityFeePerGas:y,nonce:j,to:C,type:A,value:I},"fillTransaction");try{const Q=await e.request({method:"eth_fillTransaction",params:[B]}),q=(((H=(W=a==null?void 0:a.formatters)==null?void 0:W.transaction)==null?void 0:H.format)||Xl)(Q.tx);delete q.blockHash,delete q.blockNumber,delete q.r,delete q.s,delete q.transactionIndex,delete q.v,delete q.yParity,q.data=q.input,q.gas&&(q.gas=t.gas??q.gas),q.gasPrice&&(q.gasPrice=t.gasPrice??q.gasPrice),q.maxFeePerBlobGas&&(q.maxFeePerBlobGas=t.maxFeePerBlobGas??q.maxFeePerBlobGas),q.maxFeePerGas&&(q.maxFeePerGas=t.maxFeePerGas??q.maxFeePerGas),q.maxPriorityFeePerGas&&(q.maxPriorityFeePerGas=t.maxPriorityFeePerGas??q.maxPriorityFeePerGas),q.nonce&&(q.nonce=t.nonce??q.nonce);const ee=await(async()=>{var Z,F;if(typeof((Z=a==null?void 0:a.fees)==null?void 0:Z.baseFeeMultiplier)=="function"){const X=await Ee(e,yr,"getBlock")({});return a.fees.baseFeeMultiplier({block:X,client:e,request:t})}return((F=a==null?void 0:a.fees)==null?void 0:F.baseFeeMultiplier)??1.2})();if(ee<1)throw new xx;const U=10**(((K=ee.toString().split(".")[1])==null?void 0:K.length)??0),Y=Z=>Z*BigInt(Math.ceil(ee*U))/BigInt(U);return q.maxFeePerGas&&!t.maxFeePerGas&&(q.maxFeePerGas=Y(q.maxFeePerGas)),q.gasPrice&&!t.gasPrice&&(q.gasPrice=Y(q.gasPrice)),{raw:Q.raw,transaction:{from:B.from,...q}}}catch(Q){throw Dx(Q,{...t,chain:e.chain})}}const Lx=["blobVersionedHashes","chainId","fees","gas","nonce","type"],jb=new Map,K0=new $l(128);async function $1(e,t){var j,N,T;let n=t;n.account??(n.account=e.account),n.parameters??(n.parameters=Lx);const{account:r,chain:s=e.chain,nonceManager:a,parameters:c}=n,l=(()=>{if(typeof(s==null?void 0:s.prepareTransactionRequest)=="function")return{fn:s.prepareTransactionRequest,runAt:["beforeFillTransaction"]};if(Array.isArray(s==null?void 0:s.prepareTransactionRequest))return{fn:s.prepareTransactionRequest[0],runAt:s.prepareTransactionRequest[1].runAt}})();let d;async function f(){return d||(typeof n.chainId<"u"?n.chainId:s?s.id:(d=await Ee(e,Rf,"getChainId")({}),d))}const h=r&&zt(r);let p=n.nonce;if(c.includes("nonce")&&typeof p>"u"&&h&&a){const B=await f();p=await a.consume({address:h.address,chainId:B,client:e})}l!=null&&l.fn&&((j=l.runAt)!=null&&j.includes("beforeFillTransaction"))&&(n=await l.fn({...n,chain:s},{phase:"beforeFillTransaction"}),p??(p=n.nonce));const y=((c.includes("blobVersionedHashes")||c.includes("sidecars"))&&n.kzg&&n.blobs||K0.get(e.uid)===!1||!["fees","gas"].some(O=>c.includes(O))?!1:!!(c.includes("chainId")&&typeof n.chainId!="number"||c.includes("nonce")&&typeof p!="number"||c.includes("fees")&&typeof n.gasPrice!="bigint"&&(typeof n.maxFeePerGas!="bigint"||typeof n.maxPriorityFeePerGas!="bigint")||c.includes("gas")&&typeof n.gas!="bigint"))?await Ee(e,Fx,"fillTransaction")({...n,nonce:p}).then(B=>{const{chainId:O,from:R,gas:W,gasPrice:H,nonce:K,maxFeePerBlobGas:Q,maxFeePerGas:ae,maxPriorityFeePerGas:q,type:ee,...te}=B.transaction;return K0.set(e.uid,!0),{...n,...R?{from:R}:{},...ee&&!n.type?{type:ee}:{},...typeof O<"u"?{chainId:O}:{},...typeof W<"u"?{gas:W}:{},...typeof H<"u"?{gasPrice:H}:{},...typeof K<"u"?{nonce:K}:{},...typeof Q<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxFeePerBlobGas:Q}:{},...typeof ae<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxFeePerGas:ae}:{},...typeof q<"u"&&n.type!=="legacy"&&n.type!=="eip2930"?{maxPriorityFeePerGas:q}:{},..."nonceKey"in te&&typeof te.nonceKey<"u"?{nonceKey:te.nonceKey}:{},..."keyAuthorization"in te&&typeof te.keyAuthorization<"u"&&te.keyAuthorization!==null&&!("keyAuthorization"in n)?{keyAuthorization:te.keyAuthorization}:{},..."feePayerSignature"in te&&typeof te.feePayerSignature<"u"&&te.feePayerSignature!==null?{feePayerSignature:te.feePayerSignature}:{}}}).catch(B=>{var H,K;const O=B;if(O.name!=="TransactionExecutionError")return n;if((H=O.walk)==null?void 0:H.call(O,Q=>Q.name==="ExecutionRevertedError"))throw B;return((K=O.walk)==null?void 0:K.call(O,Q=>{var q;const ae=Q;return ae.name==="MethodNotFoundRpcError"||ae.name==="MethodNotSupportedRpcError"||((q=ae.message)==null?void 0:q.includes("eth_fillTransaction is not available"))}))&&K0.set(e.uid,!1),n}):n;p??(p=y.nonce),n={...y,...h?{from:h==null?void 0:h.address}:{},...p?{nonce:p}:{}};const{blobs:v,gas:w,kzg:C,type:A}=n;l!=null&&l.fn&&((N=l.runAt)!=null&&N.includes("beforeFillParameters"))&&(n=await l.fn({...n,chain:s},{phase:"beforeFillParameters"}));let I;async function S(){return I||(I=await Ee(e,yr,"getBlock")({blockTag:"latest"}),I)}if(c.includes("nonce")&&typeof p>"u"&&h&&!a&&(n.nonce=await Ee(e,kx,"getTransactionCount")({address:h.address,blockTag:"pending"})),(c.includes("blobVersionedHashes")||c.includes("sidecars"))&&v&&C){const B=U1({blobs:v,kzg:C});if(c.includes("blobVersionedHashes")){const O=Px({commitments:B,to:"hex"});n.blobVersionedHashes=O}if(c.includes("sidecars")){const O=z1({blobs:v,commitments:B,kzg:C}),R=Rx({blobs:v,commitments:B,proofs:O,to:"hex"});n.sidecars=R}}if(c.includes("chainId")&&(n.chainId=await f()),(c.includes("fees")||c.includes("type"))&&typeof A>"u")try{n.type=Mx(n)}catch{let B=jb.get(e.uid);if(typeof B>"u"){const O=await S();B=typeof(O==null?void 0:O.baseFeePerGas)=="bigint",jb.set(e.uid,B)}n.type=B?"eip1559":"legacy"}if(c.includes("fees"))if(n.type!=="legacy"&&n.type!=="eip2930"){if(typeof n.maxFeePerGas>"u"||typeof n.maxPriorityFeePerGas>"u"){const B=await S(),{maxFeePerGas:O,maxPriorityFeePerGas:R}=await hm(e,{block:B,chain:s,request:n});if(typeof n.maxPriorityFeePerGas>"u"&&n.maxFeePerGas&&n.maxFeePerGas<R)throw new Kj({maxPriorityFeePerGas:R});n.maxPriorityFeePerGas=R,n.maxFeePerGas=O}}else{if(typeof n.maxFeePerGas<"u"||typeof n.maxPriorityFeePerGas<"u")throw new D1;if(typeof n.gasPrice>"u"){const B=await S(),{gasPrice:O}=await hm(e,{block:B,chain:s,request:n,type:"legacy"});n.gasPrice=O}}return c.includes("gas")&&typeof w>"u"&&(n.gas=await Ee(e,q1,"estimateGas")({...n,account:h,prepare:(h==null?void 0:h.type)==="local"?[]:["blobVersionedHashes"]})),l!=null&&l.fn&&((T=l.runAt)!=null&&T.includes("afterFillParameters"))&&(n=await l.fn({...n,chain:s},{phase:"afterFillParameters"})),xi(n),delete n.parameters,n}async function q1(e,t){var c,l,d;const{account:n=e.account,prepare:r=!0}=t,s=n?zt(n):void 0,a=(()=>{if(Array.isArray(r))return r;if((s==null?void 0:s.type)!=="local")return["blobVersionedHashes"]})();try{const f=await(async()=>{if(t.to)return t.to;if(t.authorizationList&&t.authorizationList.length>0)return await M1({authorization:t.authorizationList[0]}).catch(()=>{throw new re("`to` is required. Could not infer from `authorizationList`")})})(),{accessList:h,authorizationList:p,blobs:m,blobVersionedHashes:y,blockNumber:v,blockTag:w,data:C,gas:A,gasPrice:I,maxFeePerBlobGas:S,maxFeePerGas:j,maxPriorityFeePerGas:N,nonce:T,value:B,stateOverride:O,...R}=r?await $1(e,{...t,parameters:a,to:f}):t;if(A&&t.gas!==A)return A;const H=(typeof v=="bigint"?le(v):void 0)||w,K=T1(O);xi(t);const Q=(d=(l=(c=e.chain)==null?void 0:c.formatters)==null?void 0:l.transactionRequest)==null?void 0:d.format,q=(Q||qa)({...Jl(R,{format:Q}),account:s,accessList:h,authorizationList:p,blobs:m,blobVersionedHashes:y,data:C,gasPrice:I,maxFeePerBlobGas:S,maxFeePerGas:j,maxPriorityFeePerGas:N,nonce:T,to:f,value:B},"estimateGas");return BigInt(await e.request({method:"eth_estimateGas",params:K?[q,H??e.experimental_blockTag??"latest",K]:H?[q,H]:[q]}))}catch(f){throw Gj(f,{...t,account:s,chain:e.chain})}}async function gI(e,t){var f;const{abi:n,address:r,args:s,functionName:a,dataSuffix:c=typeof e.dataSuffix=="string"?e.dataSuffix:(f=e.dataSuffix)==null?void 0:f.value,...l}=t,d=$n({abi:n,args:s,functionName:a});try{return await Ee(e,q1,"estimateGas")({data:`${d}${c?c.replace("0x",""):""}`,to:r,...l})}catch(h){const p=l.account?zt(l.account):void 0;throw ui(h,{abi:n,address:r,args:s,docsPath:"/docs/contract/estimateContractGas",functionName:a,sender:p==null?void 0:p.address})}}async function Ux(e,{address:t,blockNumber:n,blockTag:r=e.experimental_blockTag??"latest"}){var c,l,d;if((c=e.batch)!=null&&c.multicall&&((d=(l=e.chain)==null?void 0:l.contracts)!=null&&d.multicall3)){const f=e.chain.contracts.multicall3.address,h=$n({abi:Na,functionName:"getEthBalance",args:[t]}),{data:p}=await Ee(e,Ha,"call")({to:f,data:h,blockNumber:n,blockTag:r});return vs({abi:Na,functionName:"getEthBalance",args:[t],data:p||"0x"})}const s=typeof n=="bigint"?le(n):void 0,a=await e.request({method:"eth_getBalance",params:[t,s||r]});return BigInt(a)}async function yI(e){const t=await e.request({method:"eth_blobBaseFee"});return BigInt(t)}const vI=new Map,wI=new Map;function bI(e){const t=(s,a)=>({clear:()=>a.delete(s),get:()=>a.get(s),set:c=>a.set(s,c)}),n=t(e,vI),r=t(e,wI);return{clear:()=>{n.clear(),r.clear()},promise:n,response:r}}async function xI(e,{cacheKey:t,cacheTime:n=Number.POSITIVE_INFINITY}){const r=bI(t),s=r.response.get();if(s&&n>0&&Date.now()-s.created.getTime()<n)return s.data;let a=r.promise.get();a||(a=e(),r.promise.set(a));try{const c=await a;return r.response.set({created:new Date,data:c}),c}finally{r.promise.clear()}}const CI=e=>`blockNumber.${e}`;async function eu(e,{cacheTime:t=e.cacheTime}={}){const n=await xI(()=>e.request({method:"eth_blockNumber"}),{cacheKey:CI(e.uid),cacheTime:t});return BigInt(n)}async function EI(e,{blockHash:t,blockNumber:n,blockTag:r="latest"}={}){const s=n!==void 0?le(n):void 0;let a;return t?a=await e.request({method:"eth_getBlockTransactionCountByHash",params:[t]},{dedupe:!0}):a=await e.request({method:"eth_getBlockTransactionCountByNumber",params:[s||r]},{dedupe:!!s}),br(a)}async function ef(e,{address:t,blockNumber:n,blockTag:r="latest"}){const s=n!==void 0?le(n):void 0,a=await e.request({method:"eth_getCode",params:[t,s||r]},{dedupe:!!s});if(a!=="0x")return a}function bl(e,t){if(!xt(e,{strict:!1}))throw new un({address:e});if(!xt(t,{strict:!1}))throw new un({address:t});return e.toLowerCase()===t.toLowerCase()}function Hr(e,{args:t,eventName:n}={}){return{...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,blockTimestamp:e.blockTimestamp?BigInt(e.blockTimestamp):e.blockTimestamp===null?null:void 0,logIndex:e.logIndex?Number(e.logIndex):null,transactionHash:e.transactionHash?e.transactionHash:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,...n?{args:t,eventName:n}:{}}}const Ib="/docs/contract/decodeEventLog";function tf(e){const{abi:t,data:n,strict:r,topics:s}=e,a=r??!0,[c,...l]=s;if(!c)throw new Jk({docsPath:Ib});const d=t.find(A=>A.type==="event"&&c===kf(wr(A)));if(!(d&&"name"in d)||d.type!=="event")throw new Zk(c,{docsPath:Ib});const{name:f,inputs:h}=d,p=h==null?void 0:h.some(A=>!("name"in A&&A.name)),m=p?[]:{},y=h.map((A,I)=>[A,I]).filter(([A])=>"indexed"in A&&A.indexed),v=[];for(let A=0;A<y.length;A++){const[I,S]=y[A],j=l[A];if(!j){if(a)throw new d1({abiItem:d,param:I});v.push([I,S]);continue}m[p?S:I.name||S]=AI({param:I,value:j})}const w=h.filter(A=>!("indexed"in A&&A.indexed)),C=a?w:[...v.map(([A])=>A),...w];if(C.length>0){if(n&&n!=="0x")try{const A=ql(C,n);if(A){let I=0;if(!a)for(const[S,j]of v)m[p?j:S.name||j]=A[I++];if(p)for(let S=0;S<h.length;S++)m[S]===void 0&&I<A.length&&(m[S]=A[I++]);else for(let S=0;S<w.length;S++)m[w[S].name]=A[I++]}}catch(A){if(a)throw A instanceof n5||A instanceof v5?new Yd({abiItem:d,data:n,params:C,size:rt(n)}):A}else if(a)throw new Yd({abiItem:d,data:"0x",params:C,size:0})}return{eventName:f,args:Object.values(m).length>0?m:void 0}}function AI({param:e,value:t}){return e.type==="string"||e.type==="bytes"||e.type==="tuple"||e.type.match(/^(.*)\[(\d+)?\]$/)?t:(ql([e],t)||[])[0]}function H1(e){const{abi:t,args:n,logs:r,strict:s=!0}=e,a=(()=>{if(e.eventName)return Array.isArray(e.eventName)?e.eventName:[e.eventName]})(),c=t.filter(l=>l.type==="event").map(l=>({abi:l,selector:kf(l)}));return r.map(l=>{var m;const d=typeof l.blockNumber=="string"?Hr(l):l,f=c.filter(y=>d.topics[0]===y.selector);if(f.length===0)return null;let h,p;for(const y of f)try{h=tf({...d,abi:[y.abi],strict:!0}),p=y;break}catch{}if(!h&&!s){p=f[0];try{h=tf({data:d.data,topics:d.topics,abi:[p.abi],strict:!1})}catch{const y=(m=p.abi.inputs)==null?void 0:m.some(v=>!("name"in v&&v.name));return{...d,args:y?[]:{},eventName:p.abi.name}}}return!h||!p||a&&!a.includes(h.eventName)||!kI({args:h.args,inputs:p.abi.inputs,matchArgs:n})?null:{...h,...d}}).filter(Boolean)}function kI(e){const{args:t,inputs:n,matchArgs:r}=e;if(!r)return!0;if(!t)return!1;function s(a,c,l){try{return a.type==="address"?bl(c,l):a.type==="string"||a.type==="bytes"?Lt(za(c))===l:c===l}catch{return!1}}return Array.isArray(t)&&Array.isArray(r)?r.every((a,c)=>{if(a==null)return!0;const l=n[c];return l?(Array.isArray(a)?a:[a]).some(f=>s(l,f,t[c])):!1}):typeof t=="object"&&!Array.isArray(t)&&typeof r=="object"&&!Array.isArray(r)?Object.entries(r).every(([a,c])=>{if(c==null)return!0;const l=n.find(f=>f.name===a);return l?(Array.isArray(c)?c:[c]).some(f=>s(l,f,t[a])):!1}):!1}async function V1(e,{address:t,blockHash:n,fromBlock:r,toBlock:s,event:a,events:c,args:l,strict:d}={}){const f=d??!1,h=c??(a?[a]:void 0);let p=[];h&&(p=[h.flatMap(w=>Zl({abi:[w],eventName:w.name,args:c?void 0:l}))],a&&(p=p[0]));let m;n?m=await e.request({method:"eth_getLogs",params:[{address:t,topics:p,blockHash:n}]}):m=await e.request({method:"eth_getLogs",params:[{address:t,topics:p,fromBlock:typeof r=="bigint"?le(r):r,toBlock:typeof s=="bigint"?le(s):s}]});const y=m.map(v=>Hr(v));return h?H1({abi:h,args:l,logs:y,strict:f}):y}async function zx(e,t){const{abi:n,address:r,args:s,blockHash:a,eventName:c,fromBlock:l,toBlock:d,strict:f}=t,h=c?bi({abi:n,name:c}):void 0,p=h?void 0:n.filter(m=>m.type==="event");return Ee(e,V1,"getLogs")({address:r,args:s,blockHash:a,event:h,events:p,fromBlock:l,toBlock:d,strict:f})}async function SI(e,{address:t,blockNumber:n,blockTag:r="latest"}){const s=await ef(e,{address:t,...n!==void 0?{blockNumber:n}:{blockTag:r}});if(s&&rt(s)===23&&s.startsWith("0xef0100"))return jt(hs(s,3,23))}class jI extends re{constructor({address:t}){super(`No EIP-712 domain found on contract "${t}".`,{metaMessages:["Ensure that:",`- The contract is deployed at the address "${t}".`,"- `eip712Domain()` function exists on the contract.","- `eip712Domain()` function matches signature to ERC-5267 specification."],name:"Eip712DomainNotFoundError"})}}async function II(e,t){const{address:n,factory:r,factoryData:s}=t;try{const[a,c,l,d,f,h,p]=await Ee(e,or,"readContract")({abi:NI,address:n,functionName:"eip712Domain",factory:r,factoryData:s});return{domain:{name:c,version:l,chainId:Number(d),verifyingContract:f,salt:h},extensions:p,fields:a}}catch(a){const c=a;throw c.name==="ContractFunctionExecutionError"&&c.cause.name==="ContractFunctionZeroDataError"?new jI({address:n}):c}}const NI=[{inputs:[],name:"eip712Domain",outputs:[{name:"fields",type:"bytes1"},{name:"name",type:"string"},{name:"version",type:"string"},{name:"chainId",type:"uint256"},{name:"verifyingContract",type:"address"},{name:"salt",type:"bytes32"},{name:"extensions",type:"uint256[]"}],stateMutability:"view",type:"function"}];function PI(e){var t;return{baseFeePerGas:e.baseFeePerGas.map(n=>BigInt(n)),gasUsedRatio:e.gasUsedRatio,oldestBlock:BigInt(e.oldestBlock),reward:(t=e.reward)==null?void 0:t.map(n=>n.map(r=>BigInt(r)))}}async function BI(e,{blockCount:t,blockNumber:n,blockTag:r="latest",rewardPercentiles:s}){const a=typeof n=="bigint"?le(n):void 0,c=await e.request({method:"eth_feeHistory",params:[le(t),a||r,s]},{dedupe:!!a});return PI(c)}async function Mf(e,{filter:t}){const n="strict"in t&&t.strict,r=await t.request({method:"eth_getFilterChanges",params:[t.id]});if(typeof r[0]=="string")return r;const s=r.map(a=>Hr(a));return!("abi"in t)||!t.abi?s:H1({abi:t.abi,logs:s,strict:n})}async function _I(e,{filter:t}){const n=t.strict??!1,s=(await t.request({method:"eth_getFilterLogs",params:[t.id]})).map(a=>Hr(a));return t.abi?H1({abi:t.abi,logs:s,strict:n}):s}function TI(e){const{authorizationList:t}=e;if(t)for(const n of t){const{chainId:r}=n,s=n.address;if(!xt(s))throw new un({address:s});if(r<0)throw new Sf({chainId:r})}Q1(e)}function OI(e){const{blobVersionedHashes:t}=e;if(t){if(t.length===0)throw new Ox;for(const n of t){const r=rt(n),s=br(hs(n,0,1));if(r!==32)throw new hI({hash:n,size:r});if(s!==Tx)throw new pI({hash:n,version:s})}}Q1(e)}function Q1(e){const{chainId:t,maxPriorityFeePerGas:n,maxFeePerGas:r,to:s}=e;if(t<=0)throw new Sf({chainId:t});if(s&&!xt(s))throw new un({address:s});if(r&&r>Tf)throw new hi({maxFeePerGas:r});if(n&&r&&n>r)throw new wl({maxFeePerGas:r,maxPriorityFeePerGas:n})}function RI(e){const{chainId:t,maxPriorityFeePerGas:n,gasPrice:r,maxFeePerGas:s,to:a}=e;if(t<=0)throw new Sf({chainId:t});if(a&&!xt(a))throw new un({address:a});if(n||s)throw new re("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");if(r&&r>Tf)throw new hi({maxFeePerGas:r})}function MI(e){const{chainId:t,maxPriorityFeePerGas:n,gasPrice:r,maxFeePerGas:s,to:a}=e;if(a&&!xt(a))throw new un({address:a});if(typeof t<"u"&&t<=0)throw new Sf({chainId:t});if(n||s)throw new re("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");if(r&&r>Tf)throw new hi({maxFeePerGas:r})}function Df(e){if(!e||e.length===0)return[];const t=[];for(let n=0;n<e.length;n++){const{address:r,storageKeys:s}=e[n];for(let a=0;a<s.length;a++)if(s[a].length-2!==64)throw new b7({storageKey:s[a]});if(!xt(r,{strict:!1}))throw new un({address:r});t.push([r,s])}return t}function DI(e,t){const n=Mx(e);return n==="eip1559"?UI(e,t):n==="eip2930"?zI(e,t):n==="eip4844"?LI(e,t):n==="eip7702"?FI(e,t):WI(e,t)}function FI(e,t){const{authorizationList:n,chainId:r,gas:s,nonce:a,to:c,value:l,maxFeePerGas:d,maxPriorityFeePerGas:f,accessList:h,data:p}=e;TI(e);const m=Df(h),y=$I(n);return Ar(["0x04",ms([le(r),a?le(a):"0x",f?le(f):"0x",d?le(d):"0x",s?le(s):"0x",c??"0x",l?le(l):"0x",p??"0x",m,y,...tu(e,t)])])}function LI(e,t){const{chainId:n,gas:r,nonce:s,to:a,value:c,maxFeePerBlobGas:l,maxFeePerGas:d,maxPriorityFeePerGas:f,accessList:h,data:p}=e;OI(e);let m=e.blobVersionedHashes,y=e.sidecars;if(e.blobs&&(typeof m>"u"||typeof y>"u")){const S=typeof e.blobs[0]=="string"?e.blobs:e.blobs.map(T=>bt(T)),j=e.kzg,N=U1({blobs:S,kzg:j});if(typeof m>"u"&&(m=Px({commitments:N})),typeof y>"u"){const T=z1({blobs:S,commitments:N,kzg:j});y=Rx({blobs:S,commitments:N,proofs:T})}}const v=Df(h),w=[le(n),s?le(s):"0x",f?le(f):"0x",d?le(d):"0x",r?le(r):"0x",a??"0x",c?le(c):"0x",p??"0x",v,l?le(l):"0x",m??[],...tu(e,t)],C=[],A=[],I=[];if(y)for(let S=0;S<y.length;S++){const{blob:j,commitment:N,proof:T}=y[S];C.push(j),A.push(N),I.push(T)}return Ar(["0x03",ms(y?[w,C,A,I]:w)])}function UI(e,t){const{chainId:n,gas:r,nonce:s,to:a,value:c,maxFeePerGas:l,maxPriorityFeePerGas:d,accessList:f,data:h}=e;Q1(e);const p=Df(f),m=[le(n),s?le(s):"0x",d?le(d):"0x",l?le(l):"0x",r?le(r):"0x",a??"0x",c?le(c):"0x",h??"0x",p,...tu(e,t)];return Ar(["0x02",ms(m)])}function zI(e,t){const{chainId:n,gas:r,data:s,nonce:a,to:c,value:l,accessList:d,gasPrice:f}=e;RI(e);const h=Df(d),p=[le(n),a?le(a):"0x",f?le(f):"0x",r?le(r):"0x",c??"0x",l?le(l):"0x",s??"0x",h,...tu(e,t)];return Ar(["0x01",ms(p)])}function WI(e,t){const{chainId:n=0,gas:r,data:s,nonce:a,to:c,value:l,gasPrice:d}=e;MI(e);let f=[a?le(a):"0x",d?le(d):"0x",r?le(r):"0x",c??"0x",l?le(l):"0x",s??"0x"];if(t){const h=(()=>{if(t.v>=35n)return(t.v-35n)/2n>0?t.v:27n+(t.v===35n?0n:1n);if(n>0)return BigInt(n*2)+BigInt(35n+t.v-27n);const y=27n+(t.v===27n?0n:1n);if(t.v!==y)throw new v7({v:t.v});return y})(),p=Un(t.r),m=Un(t.s);f=[...f,le(h),p==="0x00"?"0x":p,m==="0x00"?"0x":m]}else n>0&&(f=[...f,le(n),"0x","0x"]);return ms(f)}function tu(e,t){const n=t??e,{v:r,yParity:s}=n;if(typeof n.r>"u")return[];if(typeof n.s>"u")return[];if(typeof r>"u"&&typeof s>"u")return[];const a=Un(n.r),c=Un(n.s);return[typeof s=="number"?s?le(1):"0x":r===0n?"0x":r===1n?le(1):r===27n?"0x":le(1),a==="0x00"?"0x":a,c==="0x00"?"0x":c]}function $I(e){if(!e||e.length===0)return[];const t=[];for(const n of e){const{chainId:r,nonce:s,...a}=n,c=n.address;t.push([r?An(r):"0x",c,s?An(s):"0x",...tu({},a)])}return t}async function qI({address:e,authorization:t,signature:n}){return bl(jt(e),await M1({authorization:t,signature:n}))}const Ad=new $l(8192);function HI(e,{enabled:t=!0,id:n}){if(!t||!n)return e();if(Ad.get(n))return Ad.get(n);const r=e().finally(()=>Ad.delete(n));return Ad.set(n,r),r}async function nf(e){return new Promise(t=>setTimeout(t,e))}function Ma(e,{delay:t=100,retryCount:n=2,shouldRetry:r=()=>!0}={}){return new Promise((s,a)=>{const c=async({count:l=0}={})=>{const d=async({error:f})=>{const h=typeof t=="function"?t({count:l,error:f}):t;h&&await nf(h),c({count:l+1})};try{const f=await e();s(f)}catch(f){if(l<n&&await r({count:l,error:f}))return d({error:f});a(f)}};c()})}function VI(e,t={}){return async(n,r={})=>{var p;const{dedupe:s=!1,methods:a,retryDelay:c=150,retryCount:l=3,uid:d}={...t,...r},{method:f}=n;if((p=a==null?void 0:a.exclude)!=null&&p.includes(f))throw new qs(new Error("method not supported"),{method:f});if(a!=null&&a.include&&!a.include.includes(f))throw new qs(new Error("method not supported"),{method:f});const h=s?Ba(`${d}.${Ut(n)}`):void 0;return HI(()=>Ma(async()=>{try{return await e(n)}catch(m){const y=m;switch(y.code){case el.code:throw new el(y);case tl.code:throw new tl(y);case nl.code:throw new nl(y,{method:n.method});case rl.code:throw new rl(y);case li.code:throw new li(y);case ps.code:throw new ps(y);case ol.code:throw new ol(y);case Ur.code:throw new Ur(y);case Ta.code:throw new Ta(y);case qs.code:throw new qs(y,{method:n.method});case Oa.code:throw new Oa(y);case sl.code:throw new sl(y);case Ge.code:throw new Ge(y);case il.code:throw new il(y);case al.code:throw new al(y);case cl.code:throw new cl(y);case ll.code:throw new ll(y);case zn.code:throw new zn(y);case ul.code:throw new ul(y);case dl.code:throw new dl(y);case fl.code:throw new fl(y);case hl.code:throw new hl(y);case pl.code:throw new pl(y);case ml.code:throw new ml(y);case gl.code:throw new gl(y);case 5e3:throw new Ge(y);case Ra.code:throw new Ra(y);default:throw m instanceof re?m:new O7(y)}}},{delay:({count:m,error:y})=>{var v;if(y&&y instanceof Vc){const w=(v=y==null?void 0:y.headers)==null?void 0:v.get("Retry-After");if(w!=null&&w.match(/\d/))return Number.parseInt(w,10)*1e3}return~~(1<<m)*c},retryCount:l,shouldRetry:({error:m})=>QI(m)}),{enabled:s,id:h})}}function QI(e){return"code"in e&&typeof e.code=="number"?e.code===-1||e.code===Oa.code||e.code===li.code||e.code===429:e instanceof Vc&&e.status?e.status===403||e.status===408||e.status===413||e.status===429||e.status===500||e.status===502||e.status===503||e.status===504:!0}function GI({chain:e,currentChainId:t}){if(!e)throw new c7;if(t!==e.id)throw new a7({chain:e,currentChainId:t})}function G1(e){const t={formatters:void 0,fees:void 0,serializers:void 0,...e};function n(r){return s=>{const a=typeof s=="function"?s(r):s,c={...r,...a};return Object.assign(c,{extend:n(c)})}}return Object.assign(t,{extend:n(t)})}const KI={"0x0":"reverted","0x1":"success"};function K1(e,t){const n={...e,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,contractAddress:e.contractAddress?e.contractAddress:null,cumulativeGasUsed:e.cumulativeGasUsed?BigInt(e.cumulativeGasUsed):null,effectiveGasPrice:e.effectiveGasPrice?BigInt(e.effectiveGasPrice):null,gasUsed:e.gasUsed?BigInt(e.gasUsed):null,logs:e.logs?e.logs.map(r=>Hr(r)):null,to:e.to?e.to:null,transactionIndex:e.transactionIndex?br(e.transactionIndex):null,status:e.status?KI[e.status]:null,type:e.type?Ex[e.type]||e.type:null};return e.blobGasPrice&&(n.blobGasPrice=BigInt(e.blobGasPrice)),e.blobGasUsed&&(n.blobGasUsed=BigInt(e.blobGasUsed)),n}const YI=_1("transactionReceipt",K1);function Ff(e,{errorInstance:t=new Error("timed out"),timeout:n,signal:r}){return new Promise((s,a)=>{(async()=>{let c;try{const l=new AbortController;n>0&&(c=setTimeout(()=>{r?l.abort():a(t)},n)),s(await e({signal:(l==null?void 0:l.signal)||null}))}catch(l){(l==null?void 0:l.name)==="AbortError"&&a(t),a(l)}finally{clearTimeout(c)}})()})}function JI(){return{current:0,take(){return this.current++},reset(){this.current=0}}}const Nb=JI();function ZI(e,t={}){const{url:n,headers:r}=XI(e);return{async request(s){var v,w,C;const{body:a,fetchFn:c=t.fetchFn??fetch,onRequest:l=t.onRequest,onResponse:d=t.onResponse,timeout:f=t.timeout??1e4}=s,h={...t.fetchOptions??{},...s.fetchOptions??{}},{headers:p,method:m,signal:y}=h;try{const A=await Ff(async({signal:S})=>{const j={...h,body:Array.isArray(a)?Ut(a.map(O=>({jsonrpc:"2.0",id:O.id??Nb.take(),...O}))):Ut({jsonrpc:"2.0",id:a.id??Nb.take(),...a}),headers:{...r,"Content-Type":"application/json",...p},method:m||"POST",signal:y||(f>0?S:null)},N=new Request(n,j),T=await(l==null?void 0:l(N,j))??{...j,url:n};return await c(T.url??n,T)},{errorInstance:new fb({body:a,url:n}),timeout:f,signal:!0});d&&await d(A);let I;if((v=A.headers.get("Content-Type"))!=null&&v.startsWith("application/json"))I=await A.json();else{I=await A.text();try{I=JSON.parse(I||"{}")}catch(S){if(A.ok)throw S;I={error:I}}}if(!A.ok){if(typeof((w=I.error)==null?void 0:w.code)=="number"&&typeof((C=I.error)==null?void 0:C.message)=="string")return I;throw new Vc({body:a,details:Ut(I.error)||A.statusText,headers:A.headers,status:A.status,url:n})}return I}catch(A){throw A instanceof Vc||A instanceof fb?A:new Vc({body:a,cause:A,url:n})}}}}function XI(e){try{const t=new URL(e),n=(()=>{if(t.username){const r=`${decodeURIComponent(t.username)}:${decodeURIComponent(t.password)}`;return t.username="",t.password="",{url:t.toString(),headers:{Authorization:`Basic ${btoa(r)}`}}}})();return{url:t.toString(),...n}}catch{return{url:e}}}const e9=`Ethereum Signed Message:
81
- `;function t9(e){const t=typeof e=="string"?Ba(e):typeof e.raw=="string"?e.raw:bt(e.raw),n=Ba(`${e9}${rt(t)}`);return rr([n,t])}function Wx(e,t){return Lt(t9(e),t)}class n9 extends re{constructor({domain:t}){super(`Invalid domain "${Ut(t)}".`,{metaMessages:["Must be a valid EIP-712 domain."]})}}class r9 extends re{constructor({primaryType:t,types:n}){super(`Invalid primary type \`${t}\` must be one of \`${JSON.stringify(Object.keys(n))}\`.`,{docsPath:"/api/glossary/Errors#typeddatainvalidprimarytypeerror",metaMessages:["Check that the primary type is a key in `types`."]})}}class o9 extends re{constructor({type:t}){super(`Struct type "${t}" is invalid.`,{metaMessages:["Struct type must not be a Solidity type."],name:"InvalidStructTypeError"})}}function s9(e){const{domain:t,message:n,primaryType:r,types:s}=e,a=(c,l)=>{for(const d of c){const{name:f,type:h}=d,p=l[f],m=h.match(C5);if(m&&(typeof p=="number"||typeof p=="bigint")){const[w,C,A]=m;le(p,{signed:C==="int",size:Number.parseInt(A,10)/8})}if(h==="address"&&typeof p=="string"&&!xt(p))throw new un({address:p});const y=h.match(X4);if(y){const[w,C]=y;if(C&&rt(p)!==Number.parseInt(C,10))throw new t4({expectedSize:Number.parseInt(C,10),givenSize:rt(p)})}const v=s[h];v&&(a9(h),a(v,p))}};if(s.EIP712Domain&&t){if(typeof t!="object")throw new n9({domain:t});a(s.EIP712Domain,t)}if(r!=="EIP712Domain")if(s[r])a(s[r],n);else throw new r9({primaryType:r,types:s})}function i9({domain:e}){return[typeof(e==null?void 0:e.name)=="string"&&{name:"name",type:"string"},(e==null?void 0:e.version)&&{name:"version",type:"string"},(typeof(e==null?void 0:e.chainId)=="number"||typeof(e==null?void 0:e.chainId)=="bigint")&&{name:"chainId",type:"uint256"},(e==null?void 0:e.verifyingContract)&&{name:"verifyingContract",type:"address"},(e==null?void 0:e.salt)&&{name:"salt",type:"bytes32"}].filter(Boolean)}function a9(e){if(e==="address"||e==="bool"||e==="string"||e.startsWith("bytes")||e.startsWith("uint")||e.startsWith("int"))throw new o9({type:e})}function c9(e){const{domain:t={},message:n,primaryType:r}=e,s={EIP712Domain:i9({domain:t}),...e.types};s9({domain:t,message:n,primaryType:r,types:s});const a=["0x1901"];return t&&a.push(l9({domain:t,types:s})),r!=="EIP712Domain"&&a.push($x({data:n,primaryType:r,types:s})),Lt(rr(a))}function l9({domain:e,types:t}){return $x({data:e,primaryType:"EIP712Domain",types:t})}function $x({data:e,primaryType:t,types:n}){const r=qx({data:e,primaryType:t,types:n});return Lt(r)}function qx({data:e,primaryType:t,types:n}){const r=[{type:"bytes32"}],s=[u9({primaryType:t,types:n})];for(const a of n[t]){const[c,l]=Vx({types:n,name:a.name,type:a.type,value:e[a.name]});r.push(c),s.push(l)}return wi(r,s)}function u9({primaryType:e,types:t}){const n=An(d9({primaryType:e,types:t}));return Lt(n)}function d9({primaryType:e,types:t}){let n="";const r=Hx({primaryType:e,types:t});r.delete(e);const s=[e,...Array.from(r).sort()];for(const a of s)n+=`${a}(${t[a].map(({name:c,type:l})=>`${l} ${c}`).join(",")})`;return n}function Hx({primaryType:e,types:t},n=new Set){const r=e.match(/^\w*/u),s=r==null?void 0:r[0];if(n.has(s)||t[s]===void 0)return n;n.add(s);for(const a of t[s])Hx({primaryType:a.type,types:t},n);return n}function Vx({types:e,name:t,type:n,value:r}){if(e[n]!==void 0)return[{type:"bytes32"},Lt(qx({data:r,primaryType:n,types:e}))];if(n==="bytes")return[{type:"bytes32"},Lt(r)];if(n==="string")return[{type:"bytes32"},Lt(An(r))];if(n.lastIndexOf("]")===n.length-1){const s=n.slice(0,n.lastIndexOf("[")),a=r.map(c=>Vx({name:t,type:s,types:e,value:c}));return[{type:"bytes32"},Lt(wi(a.map(([c])=>c),a.map(([,c])=>c)))]}return[{type:n},r]}class f9 extends Map{constructor(t){super(),Object.defineProperty(this,"maxSize",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.maxSize=t}get(t){const n=super.get(t);return super.has(t)&&n!==void 0&&(this.delete(t),super.set(t,n)),n}set(t,n){if(super.set(t,n),this.maxSize&&this.size>this.maxSize){const r=this.keys().next().value;r&&this.delete(r)}return this}}const h9={checksum:new f9(8192)},Y0=h9.checksum;class Qx extends h1{constructor(t,n){super(),this.finished=!1,this.destroyed=!1,j4(t);const r=xf(n);if(this.iHash=t.create(),typeof this.iHash.update!="function")throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const s=this.blockLen,a=new Uint8Array(s);a.set(r.length>s?t.create().update(r).digest():r);for(let c=0;c<a.length;c++)a[c]^=54;this.iHash.update(a),this.oHash=t.create();for(let c=0;c<a.length;c++)a[c]^=106;this.oHash.update(a),fs(a)}update(t){return _a(this),this.iHash.update(t),this}digestInto(t){_a(this),ds(t,this.outputLen),this.finished=!0,this.iHash.digestInto(t),this.oHash.update(t),this.oHash.digestInto(t),this.destroy()}digest(){const t=new Uint8Array(this.oHash.outputLen);return this.digestInto(t),t}_cloneInto(t){t||(t=Object.create(Object.getPrototypeOf(this),{}));const{oHash:n,iHash:r,finished:s,destroyed:a,blockLen:c,outputLen:l}=this;return t=t,t.finished=s,t.destroyed=a,t.blockLen=c,t.outputLen=l,t.oHash=n._cloneInto(t.oHash),t.iHash=r._cloneInto(t.iHash),t}clone(){return this._cloneInto()}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}}const Gx=(e,t,n)=>new Qx(e,t).update(n).digest();Gx.create=(e,t)=>new Qx(e,t);function Kx(e,t={}){const{as:n=typeof e=="string"?"Hex":"Bytes"}=t,r=y5(Y7(e));return n==="Bytes"?r:Er(r)}const p9=/^0x[a-fA-F0-9]{40}$/;function Lf(e,t={}){const{strict:n=!0}=t;if(!p9.test(e))throw new Pb({address:e,cause:new m9});if(n){if(e.toLowerCase()===e)return;if(Yx(e)!==e)throw new Pb({address:e,cause:new g9})}}function Yx(e){if(Y0.has(e))return Y0.get(e);Lf(e,{strict:!1});const t=e.substring(2).toLowerCase(),n=Kx(Z7(t),{as:"Bytes"}),r=t.split("");for(let a=0;a<40;a+=2)n[a>>1]>>4>=8&&r[a]&&(r[a]=r[a].toUpperCase()),(n[a>>1]&15)>=8&&r[a+1]&&(r[a+1]=r[a+1].toUpperCase());const s=`0x${r.join("")}`;return Y0.set(e,s),s}function pm(e,t={}){const{strict:n=!0}=t??{};try{return Lf(e,{strict:n}),!0}catch{return!1}}class Pb extends De{constructor({address:t,cause:n}){super(`Address "${t}" is invalid.`,{cause:n}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Address.InvalidAddressError"})}}class m9 extends De{constructor(){super("Address is not a 20 byte (40 hexadecimal character) value."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Address.InvalidInputError"})}}class g9 extends De{constructor(){super("Address does not match its checksum counterpart."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Address.InvalidChecksumError"})}}const y9=/^(.*)\[([0-9]*)\]$/,v9=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,Jx=/^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/,Bb=2n**256n-1n;function fa(e,t,n){const{checksumAddress:r,staticPosition:s}=n,a=Z1(t.type);if(a){const[c,l]=a;return b9(e,{...t,type:l},{checksumAddress:r,length:c,staticPosition:s})}if(t.type==="tuple")return A9(e,t,{checksumAddress:r,staticPosition:s});if(t.type==="address")return w9(e,{checksum:r});if(t.type==="bool")return x9(e);if(t.type.startsWith("bytes"))return C9(e,t,{staticPosition:s});if(t.type.startsWith("uint")||t.type.startsWith("int"))return E9(e,t);if(t.type==="string")return k9(e,{staticPosition:s});throw new eg(t.type)}const _b=32,mm=32;function w9(e,t={}){const{checksum:n=!1}=t,r=e.readBytes(32);return[(a=>n?Yx(a):a)(Er(ej(r,-20))),32]}function b9(e,t,n){const{checksumAddress:r,length:s,staticPosition:a}=n;if(!s){const d=wo(e.readBytes(mm)),f=a+d,h=f+_b;e.setPosition(f);const p=wo(e.readBytes(_b)),m=xl(t);let y=0;const v=[];for(let w=0;w<p;++w){e.setPosition(h+(m?w*32:y));const[C,A]=fa(e,t,{checksumAddress:r,staticPosition:h});y+=A,v.push(C)}return e.setPosition(a+32),[v,32]}if(xl(t)){const d=wo(e.readBytes(mm)),f=a+d,h=[];for(let p=0;p<s;++p){e.setPosition(f+p*32);const[m]=fa(e,t,{checksumAddress:r,staticPosition:f});h.push(m)}return e.setPosition(a+32),[h,32]}let c=0;const l=[];for(let d=0;d<s;++d){const[f,h]=fa(e,t,{checksumAddress:r,staticPosition:a+c});c+=h,l.push(f)}return[l,c]}function x9(e){return[nj(e.readBytes(32),{size:32}),32]}function C9(e,t,{staticPosition:n}){const[r,s]=t.type.split("bytes");if(!s){const c=wo(e.readBytes(32));e.setPosition(n+c);const l=wo(e.readBytes(32));if(l===0)return e.setPosition(n+32),["0x",32];const d=e.readBytes(l);return e.setPosition(n+32),[Er(d),32]}return[Er(e.readBytes(Number.parseInt(s,10),32)),32]}function E9(e,t){const n=t.type.startsWith("int"),r=Number.parseInt(t.type.split("int")[1]||"256",10),s=e.readBytes(32);return[r>48?tj(s,{signed:n}):wo(s,{signed:n}),32]}function A9(e,t,n){const{checksumAddress:r,staticPosition:s}=n,a=t.components.length===0||t.components.some(({name:d})=>!d),c=a?[]:{};let l=0;if(xl(t)){const d=wo(e.readBytes(mm)),f=s+d;for(let h=0;h<t.components.length;++h){const p=t.components[h];e.setPosition(f+l);const[m,y]=fa(e,p,{checksumAddress:r,staticPosition:f});l+=y,c[a?h:p==null?void 0:p.name]=m}return e.setPosition(s+32),[c,32]}for(let d=0;d<t.components.length;++d){const f=t.components[d],[h,p]=fa(e,f,{checksumAddress:r,staticPosition:s});c[a?d:f==null?void 0:f.name]=h,l+=p}return[c,l]}function k9(e,{staticPosition:t}){const n=wo(e.readBytes(32)),r=t+n;e.setPosition(r);const s=wo(e.readBytes(32));if(s===0)return e.setPosition(t+32),["",32];const a=e.readBytes(s,32),c=rj(Z5(a));return e.setPosition(t+32),[c,32]}function S9({checksumAddress:e,parameters:t,values:n}){const r=[];for(let s=0;s<t.length;s++)r.push(Y1({checksumAddress:e,parameter:t[s],value:n[s]}));return r}function Y1({checksumAddress:e=!1,parameter:t,value:n}){const r=t,s=Z1(r.type);if(s){const[a,c]=s;return I9(n,{checksumAddress:e,length:a,parameter:{...r,type:c}})}if(r.type==="tuple")return T9(n,{checksumAddress:e,parameter:r});if(r.type==="address")return j9(n,{checksum:e});if(r.type==="bool")return P9(n);if(r.type.startsWith("uint")||r.type.startsWith("int")){const a=r.type.startsWith("int"),[,,c="256"]=Jx.exec(r.type)??[];return B9(n,{signed:a,size:Number(c)})}if(r.type.startsWith("bytes"))return N9(n,{type:r.type});if(r.type==="string")return _9(n);throw new eg(r.type)}function J1(e){let t=0;for(let a=0;a<e.length;a++){const{dynamic:c,encoded:l}=e[a];c?t+=32:t+=Wn(l)}const n=[],r=[];let s=0;for(let a=0;a<e.length;a++){const{dynamic:c,encoded:l}=e[a];c?(n.push(sn(t+s,{size:32})),r.push(l),s+=Wn(l)):n.push(l)}return Cr(...n,...r)}function j9(e,t){const{checksum:n=!1}=t;return Lf(e,{strict:n}),{dynamic:!1,encoded:di(e.toLowerCase())}}function I9(e,t){const{checksumAddress:n,length:r,parameter:s}=t,a=r===null;if(!Array.isArray(e))throw new W9(e);if(!a&&e.length!==r)throw new z9({expectedLength:r,givenLength:e.length,type:`${s.type}[${r}]`});let c=!1;const l=[];for(let d=0;d<e.length;d++){const f=Y1({checksumAddress:n,parameter:s,value:e[d]});f.dynamic&&(c=!0),l.push(f)}if(a||c){const d=J1(l);if(a){const f=sn(l.length,{size:32});return{dynamic:!0,encoded:l.length>0?Cr(f,d):f}}if(c)return{dynamic:!0,encoded:d}}return{dynamic:!1,encoded:Cr(...l.map(({encoded:d})=>d))}}function N9(e,{type:t}){const[,n]=t.split("bytes"),r=Wn(e);if(!n){let s=e;return r%32!==0&&(s=fi(s,Math.ceil((e.length-2)/2/32)*32)),{dynamic:!0,encoded:Cr(di(sn(r,{size:32})),s)}}if(r!==Number.parseInt(n,10))throw new Xx({expectedSize:Number.parseInt(n,10),value:e});return{dynamic:!1,encoded:fi(e)}}function P9(e){if(typeof e!="boolean")throw new De(`Invalid boolean value: "${e}" (type: ${typeof e}). Expected: \`true\` or \`false\`.`);return{dynamic:!1,encoded:di(X5(e))}}function B9(e,{signed:t,size:n}){if(typeof n=="number"){const r=2n**(BigInt(n)-(t?1n:0n))-1n,s=t?-r-1n:0n;if(e>r||e<s)throw new nx({max:r.toString(),min:s.toString(),signed:t,size:n/8,value:e.toString()})}return{dynamic:!1,encoded:sn(e,{size:32,signed:t})}}function _9(e){const t=N1(e),n=Math.ceil(Wn(t)/32),r=[];for(let s=0;s<n;s++)r.push(fi(zr(t,s*32,(s+1)*32)));return{dynamic:!0,encoded:Cr(fi(sn(Wn(t),{size:32})),...r)}}function T9(e,t){const{checksumAddress:n,parameter:r}=t;let s=!1;const a=[];for(let c=0;c<r.components.length;c++){const l=r.components[c],d=Array.isArray(e)?c:l.name,f=Y1({checksumAddress:n,parameter:l,value:e[d]});a.push(f),f.dynamic&&(s=!0)}return{dynamic:s,encoded:s?J1(a):Cr(...a.map(({encoded:c})=>c))}}function Z1(e){const t=e.match(/^(.*)\[(\d+)?\]$/);return t?[t[2]?Number(t[2]):null,t[1]]:void 0}function xl(e){var r;const{type:t}=e;if(t==="string"||t==="bytes"||t.endsWith("[]"))return!0;if(t==="tuple")return(r=e.components)==null?void 0:r.some(xl);const n=Z1(e.type);return!!(n&&xl({...e,type:n[1]}))}const O9={bytes:new Uint8Array,dataView:new DataView(new ArrayBuffer(0)),position:0,positionReadCount:new Map,recursiveReadCount:0,recursiveReadLimit:Number.POSITIVE_INFINITY,assertReadLimit(){if(this.recursiveReadCount>=this.recursiveReadLimit)throw new D9({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(e){if(e<0||e>this.bytes.length-1)throw new M9({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new Tb({offset:e});const t=this.position-e;this.assertPosition(t),this.position=t},getReadCount(e){return this.positionReadCount.get(e||this.position)||0},incrementPosition(e){if(e<0)throw new Tb({offset:e});const t=this.position+e;this.assertPosition(t),this.position=t},inspectByte(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectBytes(e,t){const n=t??this.position;return this.assertPosition(n+e-1),this.bytes.subarray(n,n+e)},inspectUint8(e){const t=e??this.position;return this.assertPosition(t),this.bytes[t]},inspectUint16(e){const t=e??this.position;return this.assertPosition(t+1),this.dataView.getUint16(t)},inspectUint24(e){const t=e??this.position;return this.assertPosition(t+2),(this.dataView.getUint16(t)<<8)+this.dataView.getUint8(t+2)},inspectUint32(e){const t=e??this.position;return this.assertPosition(t+3),this.dataView.getUint32(t)},pushByte(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushBytes(e){this.assertPosition(this.position+e.length-1),this.bytes.set(e,this.position),this.position+=e.length},pushUint8(e){this.assertPosition(this.position),this.bytes[this.position]=e,this.position++},pushUint16(e){this.assertPosition(this.position+1),this.dataView.setUint16(this.position,e),this.position+=2},pushUint24(e){this.assertPosition(this.position+2),this.dataView.setUint16(this.position,e>>8),this.dataView.setUint8(this.position+2,e&255),this.position+=3},pushUint32(e){this.assertPosition(this.position+3),this.dataView.setUint32(this.position,e),this.position+=4},readByte(){this.assertReadLimit(),this._touch();const e=this.inspectByte();return this.position++,e},readBytes(e,t){this.assertReadLimit(),this._touch();const n=this.inspectBytes(e);return this.position+=t??e,n},readUint8(){this.assertReadLimit(),this._touch();const e=this.inspectUint8();return this.position+=1,e},readUint16(){this.assertReadLimit(),this._touch();const e=this.inspectUint16();return this.position+=2,e},readUint24(){this.assertReadLimit(),this._touch();const e=this.inspectUint24();return this.position+=3,e},readUint32(){this.assertReadLimit(),this._touch();const e=this.inspectUint32();return this.position+=4,e},get remaining(){return this.bytes.length-this.position},setPosition(e){const t=this.position;return this.assertPosition(e),this.position=e,()=>this.position=t},_touch(){if(this.recursiveReadLimit===Number.POSITIVE_INFINITY)return;const e=this.getReadCount();this.positionReadCount.set(this.position,e+1),e>0&&this.recursiveReadCount++}};function R9(e,{recursiveReadLimit:t=8192}={}){const n=Object.create(O9);return n.bytes=e,n.dataView=new DataView(e.buffer,e.byteOffset,e.byteLength),n.positionReadCount=new Map,n.recursiveReadLimit=t,n}class Tb extends De{constructor({offset:t}){super(`Offset \`${t}\` cannot be negative.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Cursor.NegativeOffsetError"})}}class M9 extends De{constructor({length:t,position:n}){super(`Position \`${n}\` is out of bounds (\`0 < position < ${t}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Cursor.PositionOutOfBoundsError"})}}class D9 extends De{constructor({count:t,limit:n}){super(`Recursive read limit of \`${n}\` exceeded (recursive read count: \`${t}\`).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Cursor.RecursiveReadLimitExceededError"})}}function F9(e,t,n={}){const{as:r="Array",checksumAddress:s=!1}=n,a=typeof t=="string"?J5(t):t,c=R9(a);if(ca(a)===0&&e.length>0)throw new U9;if(ca(a)&&ca(a)<32)throw new L9({data:typeof t=="string"?t:Er(t),parameters:e,size:ca(a)});let l=0;const d=r==="Array"?[]:{};for(let f=0;f<e.length;++f){const h=e[f];c.setPosition(l);const[p,m]=fa(c,h,{checksumAddress:s,staticPosition:0});l+=m,r==="Array"?d.push(p):d[h.name??f]=p}return d}function X1(e,t,n){const{checksumAddress:r=!1}={};if(e.length!==t.length)throw new e3({expectedLength:e.length,givenLength:t.length});const s=S9({checksumAddress:r,parameters:e,values:t}),a=J1(s);return a.length===0?"0x":a}function gm(e,t){if(e.length!==t.length)throw new e3({expectedLength:e.length,givenLength:t.length});const n=[];for(let r=0;r<e.length;r++){const s=e[r],a=t[r];n.push(gm.encode(s,a))}return Cr(...n)}(function(e){function t(n,r,s=!1){if(n==="address"){const d=r;return Lf(d),di(d.toLowerCase(),s?32:0)}if(n==="string")return N1(r);if(n==="bytes")return r;if(n==="bool")return di(X5(r),s?32:1);const a=n.match(Jx);if(a){const[d,f,h="256"]=a,p=Number.parseInt(h,10)/8;return sn(r,{size:s?32:p,signed:f==="int"})}const c=n.match(v9);if(c){const[d,f]=c;if(Number.parseInt(f,10)!==(r.length-2)/2)throw new Xx({expectedSize:Number.parseInt(f,10),value:r});return fi(r,s?32:0)}const l=n.match(y9);if(l&&Array.isArray(r)){const[d,f]=l,h=[];for(let p=0;p<r.length;p++)h.push(t(f,r[p],!0));return h.length===0?"0x":Cr(...h)}throw new eg(n)}e.encode=t})(gm||(gm={}));function Zx(e){return Array.isArray(e)&&typeof e[0]=="string"||typeof e=="string"?cb(e):e}class L9 extends De{constructor({data:t,parameters:n,size:r}){super(`Data size of ${r} bytes is too small for given parameters.`,{metaMessages:[`Params: (${sa(n)})`,`Data: ${t} (${r} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.DataSizeTooSmallError"})}}class U9 extends De{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.'),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.ZeroDataError"})}}class z9 extends De{constructor({expectedLength:t,givenLength:n,type:r}){super(`Array length mismatch for type \`${r}\`. Expected: \`${t}\`. Given: \`${n}\`.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.ArrayLengthMismatchError"})}}class Xx extends De{constructor({expectedSize:t,value:n}){super(`Size of bytes "${n}" (bytes${Wn(n)}) does not match expected size (bytes${t}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.BytesSizeMismatchError"})}}class e3 extends De{constructor({expectedLength:t,givenLength:n}){super(["ABI encoding parameters/values length mismatch.",`Expected length (parameters): ${t}`,`Given length (values): ${n}`].join(`
82
- `)),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.LengthMismatchError"})}}class W9 extends De{constructor(t){super(`Value \`${t}\` is not a valid array.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.InvalidArrayError"})}}class eg extends De{constructor(t){super(`Type \`${t}\` is not a valid ABI Type.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiParameters.InvalidTypeError"})}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const Cn=BigInt(0),cn=BigInt(1),Vs=BigInt(2),$9=BigInt(3),t3=BigInt(4),n3=BigInt(5),r3=BigInt(8);function xn(e,t){const n=e%t;return n>=Cn?n:t+n}function Jn(e,t,n){let r=e;for(;t-- >Cn;)r*=r,r%=n;return r}function ym(e,t){if(e===Cn)throw new Error("invert: expected non-zero number");if(t<=Cn)throw new Error("invert: expected positive modulus, got "+t);let n=xn(e,t),r=t,s=Cn,a=cn;for(;n!==Cn;){const l=r/n,d=r%n,f=s-a*l;r=n,n=d,s=a,a=f}if(r!==cn)throw new Error("invert: does not exist");return xn(s,t)}function o3(e,t){const n=(e.ORDER+cn)/t3,r=e.pow(t,n);if(!e.eql(e.sqr(r),t))throw new Error("Cannot find square root");return r}function q9(e,t){const n=(e.ORDER-n3)/r3,r=e.mul(t,Vs),s=e.pow(r,n),a=e.mul(t,s),c=e.mul(e.mul(a,Vs),s),l=e.mul(a,e.sub(c,e.ONE));if(!e.eql(e.sqr(l),t))throw new Error("Cannot find square root");return l}function H9(e){if(e<BigInt(3))throw new Error("sqrt is not defined for small field");let t=e-cn,n=0;for(;t%Vs===Cn;)t/=Vs,n++;let r=Vs;const s=tg(e);for(;Ob(s,r)===1;)if(r++>1e3)throw new Error("Cannot find square root: probably non-prime P");if(n===1)return o3;let a=s.pow(r,t);const c=(t+cn)/Vs;return function(d,f){if(d.is0(f))return f;if(Ob(d,f)!==1)throw new Error("Cannot find square root");let h=n,p=d.mul(d.ONE,a),m=d.pow(f,t),y=d.pow(f,c);for(;!d.eql(m,d.ONE);){if(d.is0(m))return d.ZERO;let v=1,w=d.sqr(m);for(;!d.eql(w,d.ONE);)if(v++,w=d.sqr(w),v===h)throw new Error("Cannot find square root");const C=cn<<BigInt(h-v-1),A=d.pow(p,C);h=v,p=d.sqr(A),m=d.mul(m,p),y=d.mul(y,A)}return y}}function V9(e){return e%t3===$9?o3:e%r3===n3?q9:H9(e)}const Q9=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function G9(e){const t={ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"},n=Q9.reduce((r,s)=>(r[s]="function",r),t);return Pf(e,n)}function K9(e,t,n){if(n<Cn)throw new Error("invalid exponent, negatives unsupported");if(n===Cn)return e.ONE;if(n===cn)return t;let r=e.ONE,s=t;for(;n>Cn;)n&cn&&(r=e.mul(r,s)),s=e.sqr(s),n>>=cn;return r}function s3(e,t,n=!1){const r=new Array(t.length).fill(n?e.ZERO:void 0),s=t.reduce((c,l,d)=>e.is0(l)?c:(r[d]=c,e.mul(c,l)),e.ONE),a=e.inv(s);return t.reduceRight((c,l,d)=>e.is0(l)?c:(r[d]=e.mul(c,r[d]),e.mul(c,l)),a),r}function Ob(e,t){const n=(e.ORDER-cn)/Vs,r=e.pow(t,n),s=e.eql(r,e.ONE),a=e.eql(r,e.ZERO),c=e.eql(r,e.neg(e.ONE));if(!s&&!a&&!c)throw new Error("invalid Legendre symbol result");return s?1:a?0:-1}function i3(e,t){t!==void 0&&Zc(t);const n=t!==void 0?t:e.toString(2).length,r=Math.ceil(n/8);return{nBitLength:n,nByteLength:r}}function tg(e,t,n=!1,r={}){if(e<=Cn)throw new Error("invalid field: expected ORDER > 0, got "+e);const{nBitLength:s,nByteLength:a}=i3(e,t);if(a>2048)throw new Error("invalid field: expected ORDER of <= 2048 bytes");let c;const l=Object.freeze({ORDER:e,isLE:n,BITS:s,BYTES:a,MASK:Nf(s),ZERO:Cn,ONE:cn,create:d=>xn(d,e),isValid:d=>{if(typeof d!="bigint")throw new Error("invalid field element: expected bigint, got "+typeof d);return Cn<=d&&d<e},is0:d=>d===Cn,isOdd:d=>(d&cn)===cn,neg:d=>xn(-d,e),eql:(d,f)=>d===f,sqr:d=>xn(d*d,e),add:(d,f)=>xn(d+f,e),sub:(d,f)=>xn(d-f,e),mul:(d,f)=>xn(d*f,e),pow:(d,f)=>K9(l,d,f),div:(d,f)=>xn(d*ym(f,e),e),sqrN:d=>d*d,addN:(d,f)=>d+f,subN:(d,f)=>d-f,mulN:(d,f)=>d*f,inv:d=>ym(d,e),sqrt:r.sqrt||(d=>(c||(c=V9(e)),c(l,d))),toBytes:d=>n?V5(d,a):Gl(d,a),fromBytes:d=>{if(d.length!==a)throw new Error("Field.fromBytes: expected "+a+" bytes, got "+d.length);return n?H5(d):si(d)},invertBatch:d=>s3(l,d),cmov:(d,f,h)=>h?f:d});return Object.freeze(l)}function a3(e){if(typeof e!="bigint")throw new Error("field order must be bigint");const t=e.toString(2).length;return Math.ceil(t/8)}function c3(e){const t=a3(e);return t+Math.ceil(t/2)}function Y9(e,t,n=!1){const r=e.length,s=a3(t),a=c3(t);if(r<16||r<a||r>1024)throw new Error("expected "+a+"-1024 bytes of input, got "+r);const c=n?H5(e):si(e),l=xn(c,t-cn)+cn;return n?V5(l,s):Gl(l,s)}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const Rb=BigInt(0),vm=BigInt(1);function J0(e,t){const n=t.negate();return e?n:t}function l3(e,t){if(!Number.isSafeInteger(e)||e<=0||e>t)throw new Error("invalid window size, expected [1.."+t+"], got W="+e)}function Z0(e,t){l3(e,t);const n=Math.ceil(t/e)+1,r=2**(e-1),s=2**e,a=Nf(e),c=BigInt(e);return{windows:n,windowSize:r,mask:a,maxNumber:s,shiftBy:c}}function Mb(e,t,n){const{windowSize:r,mask:s,maxNumber:a,shiftBy:c}=n;let l=Number(e&s),d=e>>c;l>r&&(l-=a,d+=vm);const f=t*r,h=f+Math.abs(l)-1,p=l===0,m=l<0,y=t%2!==0;return{nextN:d,offset:h,isZero:p,isNeg:m,isNegF:y,offsetF:f}}function J9(e,t){if(!Array.isArray(e))throw new Error("array expected");e.forEach((n,r)=>{if(!(n instanceof t))throw new Error("invalid point at index "+r)})}function Z9(e,t){if(!Array.isArray(e))throw new Error("array of scalars expected");e.forEach((n,r)=>{if(!t.isValid(n))throw new Error("invalid scalar at index "+r)})}const X0=new WeakMap,u3=new WeakMap;function ep(e){return u3.get(e)||1}function X9(e,t){return{constTimeNegate:J0,hasPrecomputes(n){return ep(n)!==1},unsafeLadder(n,r,s=e.ZERO){let a=n;for(;r>Rb;)r&vm&&(s=s.add(a)),a=a.double(),r>>=vm;return s},precomputeWindow(n,r){const{windows:s,windowSize:a}=Z0(r,t),c=[];let l=n,d=l;for(let f=0;f<s;f++){d=l,c.push(d);for(let h=1;h<a;h++)d=d.add(l),c.push(d);l=d.double()}return c},wNAF(n,r,s){let a=e.ZERO,c=e.BASE;const l=Z0(n,t);for(let d=0;d<l.windows;d++){const{nextN:f,offset:h,isZero:p,isNeg:m,isNegF:y,offsetF:v}=Mb(s,d,l);s=f,p?c=c.add(J0(y,r[v])):a=a.add(J0(m,r[h]))}return{p:a,f:c}},wNAFUnsafe(n,r,s,a=e.ZERO){const c=Z0(n,t);for(let l=0;l<c.windows&&s!==Rb;l++){const{nextN:d,offset:f,isZero:h,isNeg:p}=Mb(s,l,c);if(s=d,!h){const m=r[f];a=a.add(p?m.negate():m)}}return a},getPrecomputes(n,r,s){let a=X0.get(r);return a||(a=this.precomputeWindow(r,n),n!==1&&X0.set(r,s(a))),a},wNAFCached(n,r,s){const a=ep(n);return this.wNAF(a,this.getPrecomputes(a,n,s),r)},wNAFCachedUnsafe(n,r,s,a){const c=ep(n);return c===1?this.unsafeLadder(n,r,a):this.wNAFUnsafe(c,this.getPrecomputes(c,n,s),r,a)},setWindowSize(n,r){l3(r,t),u3.set(n,r),X0.delete(n)}}}function eN(e,t,n,r){J9(n,e),Z9(r,t);const s=n.length,a=r.length;if(s!==a)throw new Error("arrays of points and scalars must have equal length");const c=e.ZERO,l=L7(BigInt(s));let d=1;l>12?d=l-3:l>4?d=l-2:l>0&&(d=2);const f=Nf(d),h=new Array(Number(f)+1).fill(c),p=Math.floor((t.BITS-1)/d)*d;let m=c;for(let y=p;y>=0;y-=d){h.fill(c);for(let w=0;w<a;w++){const C=r[w],A=Number(C>>BigInt(y)&f);h[A]=h[A].add(n[w])}let v=c;for(let w=h.length-1,C=c;w>0;w--)C=C.add(h[w]),v=v.add(C);if(m=m.add(v),y!==0)for(let w=0;w<d;w++)m=m.double()}return m}function d3(e){return G9(e.Fp),Pf(e,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...i3(e.n,e.nBitLength),...e,p:e.Fp.ORDER})}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */function Db(e){e.lowS!==void 0&&yl("lowS",e.lowS),e.prehash!==void 0&&yl("prehash",e.prehash)}function tN(e){const t=d3(e);Pf(t,{a:"field",b:"field"},{allowInfinityPoint:"boolean",allowedPrivateKeyLengths:"array",clearCofactor:"function",fromBytes:"function",isTorsionFree:"function",toBytes:"function",wrapPrivateKey:"boolean"});const{endo:n,Fp:r,a:s}=t;if(n){if(!r.eql(s,r.ZERO))throw new Error("invalid endo: CURVE.a must be 0");if(typeof n!="object"||typeof n.beta!="bigint"||typeof n.splitScalar!="function")throw new Error('invalid endo: expected "beta": bigint and "splitScalar": function')}return Object.freeze({...t})}class nN extends Error{constructor(t=""){super(t)}}const fo={Err:nN,_tlv:{encode:(e,t)=>{const{Err:n}=fo;if(e<0||e>256)throw new n("tlv.encode: wrong tag");if(t.length&1)throw new n("tlv.encode: unpadded data");const r=t.length/2,s=Ed(r);if(s.length/2&128)throw new n("tlv.encode: long form length too big");const a=r>127?Ed(s.length/2|128):"";return Ed(e)+a+s+t},decode(e,t){const{Err:n}=fo;let r=0;if(e<0||e>256)throw new n("tlv.encode: wrong tag");if(t.length<2||t[r++]!==e)throw new n("tlv.decode: wrong tlv");const s=t[r++],a=!!(s&128);let c=0;if(!a)c=s;else{const d=s&127;if(!d)throw new n("tlv.decode(long): indefinite length not supported");if(d>4)throw new n("tlv.decode(long): byte length is too big");const f=t.subarray(r,r+d);if(f.length!==d)throw new n("tlv.decode: length bytes not complete");if(f[0]===0)throw new n("tlv.decode(long): zero leftmost byte");for(const h of f)c=c<<8|h;if(r+=d,c<128)throw new n("tlv.decode(long): not minimal encoding")}const l=t.subarray(r,r+c);if(l.length!==c)throw new n("tlv.decode: wrong value length");return{v:l,l:t.subarray(r+c)}}},_int:{encode(e){const{Err:t}=fo;if(e<yo)throw new t("integer: negative integers are not allowed");let n=Ed(e);if(Number.parseInt(n[0],16)&8&&(n="00"+n),n.length&1)throw new t("unexpected DER parsing assertion: unpadded hex");return n},decode(e){const{Err:t}=fo;if(e[0]&128)throw new t("invalid signature integer: negative");if(e[0]===0&&!(e[1]&128))throw new t("invalid signature integer: unnecessary leading zero");return si(e)}},toSig(e){const{Err:t,_int:n,_tlv:r}=fo,s=Zn("signature",e),{v:a,l:c}=r.decode(48,s);if(c.length)throw new t("invalid signature: left bytes after parsing");const{v:l,l:d}=r.decode(2,a),{v:f,l:h}=r.decode(2,d);if(h.length)throw new t("invalid signature: left bytes after parsing");return{r:n.decode(l),s:n.decode(f)}},hexFromSig(e){const{_tlv:t,_int:n}=fo,r=t.encode(2,n.encode(e.r)),s=t.encode(2,n.encode(e.s)),a=r+s;return t.encode(48,a)}};function tp(e,t){return vl(Gl(e,t))}const yo=BigInt(0),Tt=BigInt(1);BigInt(2);const np=BigInt(3),rN=BigInt(4);function oN(e){const t=tN(e),{Fp:n}=t,r=tg(t.n,t.nBitLength),s=t.toBytes||((S,j,N)=>{const T=j.toAffine();return Xd(Uint8Array.from([4]),n.toBytes(T.x),n.toBytes(T.y))}),a=t.fromBytes||(S=>{const j=S.subarray(1),N=n.fromBytes(j.subarray(0,n.BYTES)),T=n.fromBytes(j.subarray(n.BYTES,2*n.BYTES));return{x:N,y:T}});function c(S){const{a:j,b:N}=t,T=n.sqr(S),B=n.mul(T,S);return n.add(n.add(B,n.mul(S,j)),N)}function l(S,j){const N=n.sqr(j),T=c(S);return n.eql(N,T)}if(!l(t.Gx,t.Gy))throw new Error("bad curve params: generator point");const d=n.mul(n.pow(t.a,np),rN),f=n.mul(n.sqr(t.b),BigInt(27));if(n.is0(n.add(d,f)))throw new Error("bad curve params: a or b");function h(S){return I1(S,Tt,t.n)}function p(S){const{allowedPrivateKeyLengths:j,nByteLength:N,wrapPrivateKey:T,n:B}=t;if(j&&typeof S!="bigint"){if(Ql(S)&&(S=vl(S)),typeof S!="string"||!j.includes(S.length))throw new Error("invalid private key");S=S.padStart(N*2,"0")}let O;try{O=typeof S=="bigint"?S:si(Zn("private key",S,N))}catch{throw new Error("invalid private key, expected hex or "+N+" bytes, got "+typeof S)}return T&&(O=xn(O,B)),da("private key",O,Tt,B),O}function m(S){if(!(S instanceof w))throw new Error("ProjectivePoint expected")}const y=gb((S,j)=>{const{px:N,py:T,pz:B}=S;if(n.eql(B,n.ONE))return{x:N,y:T};const O=S.is0();j==null&&(j=O?n.ONE:n.inv(B));const R=n.mul(N,j),W=n.mul(T,j),H=n.mul(B,j);if(O)return{x:n.ZERO,y:n.ZERO};if(!n.eql(H,n.ONE))throw new Error("invZ was invalid");return{x:R,y:W}}),v=gb(S=>{if(S.is0()){if(t.allowInfinityPoint&&!n.is0(S.py))return;throw new Error("bad point: ZERO")}const{x:j,y:N}=S.toAffine();if(!n.isValid(j)||!n.isValid(N))throw new Error("bad point: x or y not FE");if(!l(j,N))throw new Error("bad point: equation left != right");if(!S.isTorsionFree())throw new Error("bad point: not in prime-order subgroup");return!0});class w{constructor(j,N,T){if(j==null||!n.isValid(j))throw new Error("x required");if(N==null||!n.isValid(N)||n.is0(N))throw new Error("y required");if(T==null||!n.isValid(T))throw new Error("z required");this.px=j,this.py=N,this.pz=T,Object.freeze(this)}static fromAffine(j){const{x:N,y:T}=j||{};if(!j||!n.isValid(N)||!n.isValid(T))throw new Error("invalid affine point");if(j instanceof w)throw new Error("projective point not allowed");const B=O=>n.eql(O,n.ZERO);return B(N)&&B(T)?w.ZERO:new w(N,T,n.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(j){const N=s3(n,j.map(T=>T.pz));return j.map((T,B)=>T.toAffine(N[B])).map(w.fromAffine)}static fromHex(j){const N=w.fromAffine(a(Zn("pointHex",j)));return N.assertValidity(),N}static fromPrivateKey(j){return w.BASE.multiply(p(j))}static msm(j,N){return eN(w,r,j,N)}_setWindowSize(j){I.setWindowSize(this,j)}assertValidity(){v(this)}hasEvenY(){const{y:j}=this.toAffine();if(n.isOdd)return!n.isOdd(j);throw new Error("Field doesn't support isOdd")}equals(j){m(j);const{px:N,py:T,pz:B}=this,{px:O,py:R,pz:W}=j,H=n.eql(n.mul(N,W),n.mul(O,B)),K=n.eql(n.mul(T,W),n.mul(R,B));return H&&K}negate(){return new w(this.px,n.neg(this.py),this.pz)}double(){const{a:j,b:N}=t,T=n.mul(N,np),{px:B,py:O,pz:R}=this;let W=n.ZERO,H=n.ZERO,K=n.ZERO,Q=n.mul(B,B),ae=n.mul(O,O),q=n.mul(R,R),ee=n.mul(B,O);return ee=n.add(ee,ee),K=n.mul(B,R),K=n.add(K,K),W=n.mul(j,K),H=n.mul(T,q),H=n.add(W,H),W=n.sub(ae,H),H=n.add(ae,H),H=n.mul(W,H),W=n.mul(ee,W),K=n.mul(T,K),q=n.mul(j,q),ee=n.sub(Q,q),ee=n.mul(j,ee),ee=n.add(ee,K),K=n.add(Q,Q),Q=n.add(K,Q),Q=n.add(Q,q),Q=n.mul(Q,ee),H=n.add(H,Q),q=n.mul(O,R),q=n.add(q,q),Q=n.mul(q,ee),W=n.sub(W,Q),K=n.mul(q,ae),K=n.add(K,K),K=n.add(K,K),new w(W,H,K)}add(j){m(j);const{px:N,py:T,pz:B}=this,{px:O,py:R,pz:W}=j;let H=n.ZERO,K=n.ZERO,Q=n.ZERO;const ae=t.a,q=n.mul(t.b,np);let ee=n.mul(N,O),te=n.mul(T,R),U=n.mul(B,W),Y=n.add(N,T),Z=n.add(O,R);Y=n.mul(Y,Z),Z=n.add(ee,te),Y=n.sub(Y,Z),Z=n.add(N,B);let F=n.add(O,W);return Z=n.mul(Z,F),F=n.add(ee,U),Z=n.sub(Z,F),F=n.add(T,B),H=n.add(R,W),F=n.mul(F,H),H=n.add(te,U),F=n.sub(F,H),Q=n.mul(ae,Z),H=n.mul(q,U),Q=n.add(H,Q),H=n.sub(te,Q),Q=n.add(te,Q),K=n.mul(H,Q),te=n.add(ee,ee),te=n.add(te,ee),U=n.mul(ae,U),Z=n.mul(q,Z),te=n.add(te,U),U=n.sub(ee,U),U=n.mul(ae,U),Z=n.add(Z,U),ee=n.mul(te,Z),K=n.add(K,ee),ee=n.mul(F,Z),H=n.mul(Y,H),H=n.sub(H,ee),ee=n.mul(Y,te),Q=n.mul(F,Q),Q=n.add(Q,ee),new w(H,K,Q)}subtract(j){return this.add(j.negate())}is0(){return this.equals(w.ZERO)}wNAF(j){return I.wNAFCached(this,j,w.normalizeZ)}multiplyUnsafe(j){const{endo:N,n:T}=t;da("scalar",j,yo,T);const B=w.ZERO;if(j===yo)return B;if(this.is0()||j===Tt)return this;if(!N||I.hasPrecomputes(this))return I.wNAFCachedUnsafe(this,j,w.normalizeZ);let{k1neg:O,k1:R,k2neg:W,k2:H}=N.splitScalar(j),K=B,Q=B,ae=this;for(;R>yo||H>yo;)R&Tt&&(K=K.add(ae)),H&Tt&&(Q=Q.add(ae)),ae=ae.double(),R>>=Tt,H>>=Tt;return O&&(K=K.negate()),W&&(Q=Q.negate()),Q=new w(n.mul(Q.px,N.beta),Q.py,Q.pz),K.add(Q)}multiply(j){const{endo:N,n:T}=t;da("scalar",j,Tt,T);let B,O;if(N){const{k1neg:R,k1:W,k2neg:H,k2:K}=N.splitScalar(j);let{p:Q,f:ae}=this.wNAF(W),{p:q,f:ee}=this.wNAF(K);Q=I.constTimeNegate(R,Q),q=I.constTimeNegate(H,q),q=new w(n.mul(q.px,N.beta),q.py,q.pz),B=Q.add(q),O=ae.add(ee)}else{const{p:R,f:W}=this.wNAF(j);B=R,O=W}return w.normalizeZ([B,O])[0]}multiplyAndAddUnsafe(j,N,T){const B=w.BASE,O=(W,H)=>H===yo||H===Tt||!W.equals(B)?W.multiplyUnsafe(H):W.multiply(H),R=O(this,N).add(O(j,T));return R.is0()?void 0:R}toAffine(j){return y(this,j)}isTorsionFree(){const{h:j,isTorsionFree:N}=t;if(j===Tt)return!0;if(N)return N(w,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:j,clearCofactor:N}=t;return j===Tt?this:N?N(w,this):this.multiplyUnsafe(t.h)}toRawBytes(j=!0){return yl("isCompressed",j),this.assertValidity(),s(w,this,j)}toHex(j=!0){return yl("isCompressed",j),vl(this.toRawBytes(j))}}w.BASE=new w(t.Gx,t.Gy,n.ONE),w.ZERO=new w(n.ZERO,n.ONE,n.ZERO);const{endo:C,nBitLength:A}=t,I=X9(w,C?Math.ceil(A/2):A);return{CURVE:t,ProjectivePoint:w,normPrivateKeyToScalar:p,weierstrassEquation:c,isWithinCurveOrder:h}}function sN(e){const t=d3(e);return Pf(t,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...t})}function iN(e){const t=sN(e),{Fp:n,n:r,nByteLength:s,nBitLength:a}=t,c=n.BYTES+1,l=2*n.BYTES+1;function d(q){return xn(q,r)}function f(q){return ym(q,r)}const{ProjectivePoint:h,normPrivateKeyToScalar:p,weierstrassEquation:m,isWithinCurveOrder:y}=oN({...t,toBytes(q,ee,te){const U=ee.toAffine(),Y=n.toBytes(U.x),Z=Xd;return yl("isCompressed",te),te?Z(Uint8Array.from([ee.hasEvenY()?2:3]),Y):Z(Uint8Array.from([4]),Y,n.toBytes(U.y))},fromBytes(q){const ee=q.length,te=q[0],U=q.subarray(1);if(ee===c&&(te===2||te===3)){const Y=si(U);if(!I1(Y,Tt,n.ORDER))throw new Error("Point is not on curve");const Z=m(Y);let F;try{F=n.sqrt(Z)}catch(ne){const oe=ne instanceof Error?": "+ne.message:"";throw new Error("Point is not on curve"+oe)}const X=(F&Tt)===Tt;return(te&1)===1!==X&&(F=n.neg(F)),{x:Y,y:F}}else if(ee===l&&te===4){const Y=n.fromBytes(U.subarray(0,n.BYTES)),Z=n.fromBytes(U.subarray(n.BYTES,2*n.BYTES));return{x:Y,y:Z}}else{const Y=c,Z=l;throw new Error("invalid Point, expected length of "+Y+", or uncompressed "+Z+", got "+ee)}}});function v(q){const ee=r>>Tt;return q>ee}function w(q){return v(q)?d(-q):q}const C=(q,ee,te)=>si(q.slice(ee,te));class A{constructor(ee,te,U){da("r",ee,Tt,r),da("s",te,Tt,r),this.r=ee,this.s=te,U!=null&&(this.recovery=U),Object.freeze(this)}static fromCompact(ee){const te=s;return ee=Zn("compactSignature",ee,te*2),new A(C(ee,0,te),C(ee,te,2*te))}static fromDER(ee){const{r:te,s:U}=fo.toSig(Zn("DER",ee));return new A(te,U)}assertValidity(){}addRecoveryBit(ee){return new A(this.r,this.s,ee)}recoverPublicKey(ee){const{r:te,s:U,recovery:Y}=this,Z=B(Zn("msgHash",ee));if(Y==null||![0,1,2,3].includes(Y))throw new Error("recovery id invalid");const F=Y===2||Y===3?te+t.n:te;if(F>=n.ORDER)throw new Error("recovery id 2 or 3 invalid");const X=(Y&1)===0?"02":"03",pe=h.fromHex(X+tp(F,n.BYTES)),ne=f(F),oe=d(-Z*ne),fe=d(U*ne),ge=h.BASE.multiplyAndAddUnsafe(pe,oe,fe);if(!ge)throw new Error("point at infinify");return ge.assertValidity(),ge}hasHighS(){return v(this.s)}normalizeS(){return this.hasHighS()?new A(this.r,d(-this.s),this.recovery):this}toDERRawBytes(){return Zd(this.toDERHex())}toDERHex(){return fo.hexFromSig(this)}toCompactRawBytes(){return Zd(this.toCompactHex())}toCompactHex(){const ee=s;return tp(this.r,ee)+tp(this.s,ee)}}const I={isValidPrivateKey(q){try{return p(q),!0}catch{return!1}},normPrivateKeyToScalar:p,randomPrivateKey:()=>{const q=c3(t.n);return Y9(t.randomBytes(q),t.n)},precompute(q=8,ee=h.BASE){return ee._setWindowSize(q),ee.multiply(BigInt(3)),ee}};function S(q,ee=!0){return h.fromPrivateKey(q).toRawBytes(ee)}function j(q){if(typeof q=="bigint")return!1;if(q instanceof h)return!0;const te=Zn("key",q).length,U=n.BYTES,Y=U+1,Z=2*U+1;if(!(t.allowedPrivateKeyLengths||s===Y))return te===Y||te===Z}function N(q,ee,te=!0){if(j(q)===!0)throw new Error("first arg must be private key");if(j(ee)===!1)throw new Error("second arg must be public key");return h.fromHex(ee).multiply(p(q)).toRawBytes(te)}const T=t.bits2int||function(q){if(q.length>8192)throw new Error("input is too large");const ee=si(q),te=q.length*8-a;return te>0?ee>>BigInt(te):ee},B=t.bits2int_modN||function(q){return d(T(q))},O=Nf(a);function R(q){return da("num < 2^"+a,q,yo,O),Gl(q,s)}function W(q,ee,te=H){if(["recovered","canonical"].some(Be=>Be in te))throw new Error("sign() legacy options not supported");const{hash:U,randomBytes:Y}=t;let{lowS:Z,prehash:F,extraEntropy:X}=te;Z==null&&(Z=!0),q=Zn("msgHash",q),Db(te),F&&(q=Zn("prehashed msgHash",U(q)));const pe=B(q),ne=p(ee),oe=[R(ne),R(pe)];if(X!=null&&X!==!1){const Be=X===!0?Y(n.BYTES):X;oe.push(Zn("extraEntropy",Be))}const fe=Xd(...oe),ge=pe;function Ie(Be){const Le=T(Be);if(!y(Le))return;const _e=f(Le),Te=h.BASE.multiply(Le).toAffine(),dt=d(Te.x);if(dt===yo)return;const tt=d(_e*d(ge+dt*ne));if(tt===yo)return;let ft=(Te.x===dt?0:2)|Number(Te.y&Tt),ze=tt;return Z&&v(tt)&&(ze=w(tt),ft^=1),new A(dt,ze,ft)}return{seed:fe,k2sig:Ie}}const H={lowS:t.lowS,prehash:!1},K={lowS:t.lowS,prehash:!1};function Q(q,ee,te=H){const{seed:U,k2sig:Y}=W(q,ee,te),Z=t;return U7(Z.hash.outputLen,Z.nByteLength,Z.hmac)(U,Y)}h.BASE._setWindowSize(8);function ae(q,ee,te,U=K){var ft;const Y=q;ee=Zn("msgHash",ee),te=Zn("publicKey",te);const{lowS:Z,prehash:F,format:X}=U;if(Db(U),"strict"in U)throw new Error("options.strict was renamed to lowS");if(X!==void 0&&X!=="compact"&&X!=="der")throw new Error("format must be compact or der");const pe=typeof Y=="string"||Ql(Y),ne=!pe&&!X&&typeof Y=="object"&&Y!==null&&typeof Y.r=="bigint"&&typeof Y.s=="bigint";if(!pe&&!ne)throw new Error("invalid signature, expected Uint8Array, hex string or Signature instance");let oe,fe;try{if(ne&&(oe=new A(Y.r,Y.s)),pe){try{X!=="compact"&&(oe=A.fromDER(Y))}catch(ze){if(!(ze instanceof fo.Err))throw ze}!oe&&X!=="der"&&(oe=A.fromCompact(Y))}fe=h.fromHex(te)}catch{return!1}if(!oe||Z&&oe.hasHighS())return!1;F&&(ee=t.hash(ee));const{r:ge,s:Ie}=oe,Be=B(ee),Le=f(Ie),_e=d(Be*Le),Te=d(ge*Le),dt=(ft=h.BASE.multiplyAndAddUnsafe(fe,_e,Te))==null?void 0:ft.toAffine();return dt?d(dt.x)===ge:!1}return{CURVE:t,getPublicKey:S,getSharedSecret:N,sign:Q,verify:ae,ProjectivePoint:h,Signature:A,utils:I}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */function aN(e){return{hash:e,hmac:(t,...n)=>Gx(e,t,O4(...n)),randomBytes:R4}}function cN(e,t){const n=r=>iN({...e,...aN(r)});return{...n(t),create:n}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const f3=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),Fb=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),lN=BigInt(0),uN=BigInt(1),wm=BigInt(2),Lb=(e,t)=>(e+t/wm)/t;function dN(e){const t=f3,n=BigInt(3),r=BigInt(6),s=BigInt(11),a=BigInt(22),c=BigInt(23),l=BigInt(44),d=BigInt(88),f=e*e*e%t,h=f*f*e%t,p=Jn(h,n,t)*h%t,m=Jn(p,n,t)*h%t,y=Jn(m,wm,t)*f%t,v=Jn(y,s,t)*y%t,w=Jn(v,a,t)*v%t,C=Jn(w,l,t)*w%t,A=Jn(C,d,t)*C%t,I=Jn(A,l,t)*w%t,S=Jn(I,n,t)*h%t,j=Jn(S,c,t)*v%t,N=Jn(j,r,t)*f%t,T=Jn(N,wm,t);if(!bm.eql(bm.sqr(T),e))throw new Error("Cannot find square root");return T}const bm=tg(f3,void 0,void 0,{sqrt:dN}),h3=cN({a:lN,b:BigInt(7),Fp:bm,n:Fb,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:e=>{const t=Fb,n=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),r=-uN*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),s=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),a=n,c=BigInt("0x100000000000000000000000000000000"),l=Lb(a*e,t),d=Lb(-r*e,t);let f=xn(e-l*n-d*s,t),h=xn(-l*r-d*a,t);const p=f>c,m=h>c;if(p&&(f=t-f),m&&(h=t-h),f>c||h>c)throw new Error("splitScalar: Endomorphism failed, k="+e);return{k1neg:p,k1:f,k2neg:m,k2:h}}}},Nx),fN=Object.freeze(Object.defineProperty({__proto__:null,secp256k1:h3},Symbol.toStringTag,{value:"Module"}));function p3(e,t={}){const{recovered:n}=t;if(typeof e.r>"u")throw new rp({signature:e});if(typeof e.s>"u")throw new rp({signature:e});if(n&&typeof e.yParity>"u")throw new rp({signature:e});if(e.r<0n||e.r>Bb)throw new wN({value:e.r});if(e.s<0n||e.s>Bb)throw new bN({value:e.s});if(typeof e.yParity=="number"&&e.yParity!==0&&e.yParity!==1)throw new rg({value:e.yParity})}function hN(e){return m3(Er(e))}function m3(e){if(e.length!==130&&e.length!==132)throw new vN({signature:e});const t=BigInt(zr(e,0,32)),n=BigInt(zr(e,32,64)),r=(()=>{const s=+`0x${e.slice(130)}`;if(!Number.isNaN(s))try{return ng(s)}catch{throw new rg({value:s})}})();return typeof r>"u"?{r:t,s:n}:{r:t,s:n,yParity:r}}function pN(e){if(!(typeof e.r>"u")&&!(typeof e.s>"u"))return mN(e)}function mN(e){const t=typeof e=="string"?m3(e):e instanceof Uint8Array?hN(e):typeof e.r=="string"?yN(e):e.v?gN(e):{r:e.r,s:e.s,...typeof e.yParity<"u"?{yParity:e.yParity}:{}};return p3(t),t}function gN(e){return{r:e.r,s:e.s,yParity:ng(e.v)}}function yN(e){const t=(()=>{const n=e.v?Number(e.v):void 0;let r=e.yParity?Number(e.yParity):void 0;if(typeof n=="number"&&typeof r!="number"&&(r=ng(n)),typeof r!="number")throw new rg({value:e.yParity});return r})();return{r:BigInt(e.r),s:BigInt(e.s),yParity:t}}function ng(e){if(e===0||e===27)return 0;if(e===1||e===28)return 1;if(e>=35)return e%2===0?1:0;throw new xN({value:e})}class vN extends De{constructor({signature:t}){super(`Value \`${t}\` is an invalid signature size.`,{metaMessages:["Expected: 64 bytes or 65 bytes.",`Received ${Wn(dj(t))} bytes.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidSerializedSizeError"})}}class rp extends De{constructor({signature:t}){super(`Signature \`${Y5(t)}\` is missing either an \`r\`, \`s\`, or \`yParity\` property.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.MissingPropertiesError"})}}class wN extends De{constructor({value:t}){super(`Value \`${t}\` is an invalid r value. r must be a positive integer less than 2^256.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidRError"})}}class bN extends De{constructor({value:t}){super(`Value \`${t}\` is an invalid s value. s must be a positive integer less than 2^256.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidSError"})}}class rg extends De{constructor({value:t}){super(`Value \`${t}\` is an invalid y-parity value. Y-parity must be 0 or 1.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidYParityError"})}}class xN extends De{constructor({value:t}){super(`Value \`${t}\` is an invalid v value. v must be 27, 28 or >=35.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Signature.InvalidVError"})}}function CN(e,t={}){return typeof e.chainId=="string"?EN(e):{...e,...t.signature}}function EN(e){const{address:t,chainId:n,nonce:r}=e,s=pN(e);return{address:t,chainId:Number(n),nonce:BigInt(r),...s}}const AN="0x8010801080108010801080108010801080108010801080108010801080108010",kN=Zx("(uint256 chainId, address delegation, uint256 nonce, uint8 yParity, uint256 r, uint256 s), address to, bytes data");function g3(e){if(typeof e=="string"){if(zr(e,-32)!==AN)throw new IN(e)}else p3(e.authorization)}function SN(e){g3(e);const t=tx(zr(e,-64,-32)),n=zr(e,-t-64,-64),r=zr(e,0,-t-64),[s,a,c]=F9(kN,n);return{authorization:CN({address:s.delegation,chainId:Number(s.chainId),nonce:s.nonce,yParity:s.yParity,r:s.r,s:s.s}),signature:r,...c&&c!=="0x"?{data:c,to:a}:{}}}function jN(e){try{return g3(e),!0}catch{return!1}}let IN=class extends De{constructor(t){super(`Value \`${t}\` is an invalid ERC-8010 wrapped signature.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SignatureErc8010.InvalidWrappedSignatureError"})}};class NN extends re{constructor({value:t}){super(`Number \`${t}\` is not a valid decimal number.`,{name:"InvalidDecimalNumberError"})}}function y3(e,t){if(!/^(-?)([0-9]*)\.?([0-9]*)$/.test(e))throw new NN({value:e});let[n,r="0"]=e.split(".");const s=n.startsWith("-");if(s&&(n=n.slice(1)),r=r.replace(/(0+)$/,""),r.length>t){const[a,c,l]=[r.slice(0,t-1),r.slice(t-1,t),r.slice(t)],d=Math.round(+`${c}.${l}`);d>9?r=`${BigInt(a)+BigInt(1)}0`.padStart(a.length+1,"0"):r=`${a}${d}`,r.length>t&&(r=r.slice(1),n=`${BigInt(n)+1n}`),r=r.slice(0,t)}else r=r.padEnd(t,"0");return BigInt(`${s?"-":""}${n}${r}`)}function PN(e){return e.map(t=>({...t,value:BigInt(t.value)}))}function BN(e){return{...e,balance:e.balance?BigInt(e.balance):void 0,nonce:e.nonce?br(e.nonce):void 0,storageProof:e.storageProof?PN(e.storageProof):void 0}}async function _N(e,{address:t,blockNumber:n,blockTag:r,storageKeys:s}){const a=r??"latest",c=n!==void 0?le(n):void 0,l=await e.request({method:"eth_getProof",params:[t,s,c||a]});return BN(l)}async function TN(e,{address:t,blockNumber:n,blockTag:r="latest",slot:s}){const a=n!==void 0?le(n):void 0;return await e.request({method:"eth_getStorageAt",params:[t,s,a||r]})}async function Uf(e,{blockHash:t,blockNumber:n,blockTag:r,hash:s,index:a,sender:c,nonce:l}){var m,y,v;const d=r||"latest",f=n!==void 0?le(n):void 0;let h=null;if(s?h=await e.request({method:"eth_getTransactionByHash",params:[s]},{dedupe:!0}):t?h=await e.request({method:"eth_getTransactionByBlockHashAndIndex",params:[t,le(a)]},{dedupe:!0}):typeof a=="number"?h=await e.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[f||d,le(a)]},{dedupe:!!f}):c&&typeof l=="number"&&(h=await e.request({method:"eth_getTransactionBySenderAndNonce",params:[c,le(l)]},{dedupe:!0})),!h)throw new L5({blockHash:t,blockNumber:n,blockTag:d,hash:s,index:a});return(((v=(y=(m=e.chain)==null?void 0:m.formatters)==null?void 0:y.transaction)==null?void 0:v.format)||Xl)(h,"getTransaction")}async function ON(e,{hash:t,transactionReceipt:n}){const[r,s]=await Promise.all([Ee(e,eu,"getBlockNumber")({}),t?Ee(e,Uf,"getTransaction")({hash:t}):void 0]),a=(n==null?void 0:n.blockNumber)||(s==null?void 0:s.blockNumber);return a?r-a+1n:0n}async function $d(e,{hash:t}){var s,a,c;const n=await e.request({method:"eth_getTransactionReceipt",params:[t]},{dedupe:!0});if(!n)throw new U5({hash:t});return(((c=(a=(s=e.chain)==null?void 0:s.formatters)==null?void 0:a.transactionReceipt)==null?void 0:c.format)||K1)(n,"getTransactionReceipt")}async function v3(e,t){var I;const{account:n,authorizationList:r,allowFailure:s=!0,blockNumber:a,blockOverrides:c,blockTag:l,stateOverride:d}=t,f=t.contracts,{batchSize:h=t.batchSize??1024,deployless:p=t.deployless??!1}=typeof((I=e.batch)==null?void 0:I.multicall)=="object"?e.batch.multicall:{},m=(()=>{if(t.multicallAddress)return t.multicallAddress;if(p)return null;if(e.chain)return $a({blockNumber:a,chain:e.chain,contract:"multicall3"});throw new Error("client chain not configured. multicallAddress is required.")})(),y=[[]];let v=0,w=0;for(let S=0;S<f.length;S++){const{abi:j,address:N,args:T,functionName:B}=f[S];try{const O=$n({abi:j,args:T,functionName:B});w+=(O.length-2)/2,h>0&&w>h&&y[v].length>0&&(v++,w=(O.length-2)/2,y[v]=[]),y[v]=[...y[v],{allowFailure:!0,callData:O,target:N}]}catch(O){const R=ui(O,{abi:j,address:N,args:T,docsPath:"/docs/contract/multicall",functionName:B,sender:n});if(!s)throw R;y[v]=[...y[v],{allowFailure:!0,callData:"0x",target:N}]}}const C=await Promise.allSettled(y.map(S=>Ee(e,or,"readContract")({...m===null?{code:P1}:{address:m},abi:Na,account:n,args:[S],authorizationList:r,blockNumber:a,blockOverrides:c,blockTag:l,functionName:"aggregate3",stateOverride:d}))),A=[];for(let S=0;S<C.length;S++){const j=C[S];if(j.status==="rejected"){if(!s)throw j.reason;for(let T=0;T<y[S].length;T++)A.push({status:"failure",error:j.reason,result:void 0});continue}const N=j.value;for(let T=0;T<N.length;T++){const{returnData:B,success:O}=N[T],{callData:R}=y[S][T],{abi:W,address:H,functionName:K,args:Q}=f[A.length];try{if(R==="0x")throw new Wl;if(!O)throw new jf({data:B});const ae=vs({abi:W,args:Q,data:B,functionName:K});A.push(s?{result:ae,status:"success"}:ae)}catch(ae){const q=ui(ae,{abi:W,address:H,args:Q,docsPath:"/docs/contract/multicall",functionName:K});if(!s)throw q;A.push({error:q,result:void 0,status:"failure"})}}}if(A.length!==f.length)throw new re("multicall results mismatch");return A}async function xm(e,t){const{blockNumber:n,blockTag:r=e.experimental_blockTag??"latest",blocks:s,returnFullTransactions:a,traceTransfers:c,validation:l}=t;try{const d=[];for(const m of s){const y=m.blockOverrides?ox(m.blockOverrides):void 0,v=m.calls.map(C=>{const A=C,I=A.account?zt(A.account):void 0,S=A.abi?$n(A):A.data,j={...A,account:I,data:A.dataSuffix?rr([S||"0x",A.dataSuffix]):S,from:A.from??(I==null?void 0:I.address)};return xi(j),qa(j)}),w=m.stateOverrides?T1(m.stateOverrides):void 0;d.push({blockOverrides:y,calls:v,stateOverrides:w})}const h=(typeof n=="bigint"?le(n):void 0)||r;return(await e.request({method:"eth_simulateV1",params:[{blockStateCalls:d,returnFullTransactions:a,traceTransfers:c,validation:l},h]})).map((m,y)=>({...F1(m),calls:m.calls.map((v,w)=>{var W,H;const{abi:C,args:A,functionName:I,to:S}=s[y].calls[w],j=((W=v.error)==null?void 0:W.data)??v.returnData,N=BigInt(v.gasUsed),T=(H=v.logs)==null?void 0:H.map(K=>Hr(K)),B=v.status==="0x1"?"success":"failure",O=C&&B==="success"&&j!=="0x"?vs({abi:C,data:j,functionName:I}):null,R=(()=>{if(B==="success")return;let K;if(j==="0x"?K=new Wl:j&&(K=new jf({data:j})),!!K)return ui(K,{abi:C??[],address:S??"0x",args:A,functionName:I??"<unknown>"})})();return{data:j,gasUsed:N,logs:T,status:B,...B==="success"?{result:O}:{error:R}}})}))}catch(d){const f=d,h=_f(f,{});throw h instanceof Yl?f:h}}function Cm(e){let t=!0,n="",r=0,s="",a=!1;for(let c=0;c<e.length;c++){const l=e[c];if(["(",")",","].includes(l)&&(t=!0),l==="("&&r++,l===")"&&r--,!!t){if(r===0){if(l===" "&&["event","function","error",""].includes(s))s="";else if(s+=l,l===")"){a=!0;break}continue}if(l===" "){e[c-1]!==","&&n!==","&&n!==",("&&(n="",t=!1);continue}s+=l,n+=l}}if(!a)throw new De("Unable to normalize signature.");return s}function Em(e,t){const n=typeof e,r=t.type;switch(r){case"address":return pm(e,{strict:!1});case"bool":return n==="boolean";case"function":return n==="string";case"string":return n==="string";default:return r==="tuple"&&"components"in t?Object.values(t.components).every((s,a)=>Em(Object.values(e)[a],s)):/^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/.test(r)?n==="number"||n==="bigint":/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(r)?n==="string"||e instanceof Uint8Array:/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(r)?Array.isArray(e)&&e.every(s=>Em(s,{...t,type:r.replace(/(\[[0-9]{0,}\])$/,"")})):!1}}function w3(e,t,n){for(const r in e){const s=e[r],a=t[r];if(s.type==="tuple"&&a.type==="tuple"&&"components"in s&&"components"in a)return w3(s.components,a.components,n[r]);const c=[s.type,a.type];if(c.includes("address")&&c.includes("bytes20")?!0:c.includes("address")&&c.includes("string")?pm(n[r],{strict:!1}):c.includes("address")&&c.includes("bytes")?pm(n[r],{strict:!1}):!1)return c}}function b3(e,t={}){const{prepare:n=!0}=t,r=Array.isArray(e)||typeof e=="string"?ab(e):e;return{...r,...n?{hash:la(r)}:{}}}function zf(e,t,n){const{args:r=[],prepare:s=!0}=n??{},a=fj(t,{strict:!1}),c=e.filter(f=>a?f.type==="function"||f.type==="error"?x3(f)===zr(t,0,4):f.type==="event"?la(f)===t:!1:"name"in f&&f.name===t);if(c.length===0)throw new rf({name:t});if(c.length===1)return{...c[0],...s?{hash:la(c[0])}:{}};let l;for(const f of c){if(!("inputs"in f))continue;if(!r||r.length===0){if(!f.inputs||f.inputs.length===0)return{...f,...s?{hash:la(f)}:{}};continue}if(!f.inputs||f.inputs.length===0||f.inputs.length!==r.length)continue;if(r.every((p,m)=>{const y="inputs"in f&&f.inputs[m];return y?Em(p,y):!1})){if(l&&"inputs"in l&&l.inputs){const p=w3(f.inputs,l.inputs,r);if(p)throw new MN({abiItem:f,type:p[0]},{abiItem:l,type:p[1]})}l=f}}const d=(()=>{if(l)return l;const[f,...h]=c;return{...f,overloads:h}})();if(!d)throw new rf({name:t});return{...d,...s?{hash:la(d)}:{}}}function x3(...e){const t=(()=>{if(Array.isArray(e[0])){const[n,r]=e;return zf(n,r)}return e[0]})();return zr(la(t),0,4)}function RN(...e){const t=(()=>{if(Array.isArray(e[0])){const[r,s]=e;return zf(r,s)}return e[0]})(),n=typeof t=="string"?t:Jd(t);return Cm(n)}function la(...e){const t=(()=>{if(Array.isArray(e[0])){const[n,r]=e;return zf(n,r)}return e[0]})();return typeof t!="string"&&"hash"in t&&t.hash?t.hash:Kx(N1(RN(t)))}class MN extends De{constructor(t,n){super("Found ambiguous types in overloaded ABI Items.",{metaMessages:[`\`${t.type}\` in \`${Cm(Jd(t.abiItem))}\`, and`,`\`${n.type}\` in \`${Cm(Jd(n.abiItem))}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItem.AmbiguityError"})}}class rf extends De{constructor({name:t,data:n,type:r="item"}){const s=t?` with name "${t}"`:n?` with data "${n}"`:"";super(`ABI ${r}${s} not found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiItem.NotFoundError"})}}function DN(...e){var a;const[t,n]=(()=>{if(Array.isArray(e[0])){const[c,l]=e;return[LN(c),l]}return e})(),{bytecode:r,args:s}=n;return Cr(r,(a=t.inputs)!=null&&a.length&&(s!=null&&s.length)?X1(t.inputs,s):"0x")}function FN(e){return b3(e)}function LN(e){const t=e.find(n=>n.type==="constructor");if(!t)throw new rf({name:"constructor"});return t}function UN(...e){const[t,n=[]]=(()=>{if(Array.isArray(e[0])){const[f,h,p]=e;return[Ub(f,h,{args:p}),p]}const[l,d]=e;return[l,d]})(),{overloads:r}=t,s=r?Ub([t,...r],t.name,{args:n}):t,a=zN(s),c=n.length>0?X1(s.inputs,n):void 0;return c?Cr(a,c):a}function Ji(e,t={}){return b3(e,t)}function Ub(e,t,n){const r=zf(e,t,n);if(r.type!=="function")throw new rf({name:t,type:"function"});return r}function zN(e){return x3(e)}const WN="0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee",mr="0x0000000000000000000000000000000000000000",$N="0x6080604052348015600e575f80fd5b5061016d8061001c5f395ff3fe608060405234801561000f575f80fd5b5060043610610029575f3560e01c8063f8b2cb4f1461002d575b5f80fd5b610047600480360381019061004291906100db565b61005d565b604051610054919061011e565b60405180910390f35b5f8173ffffffffffffffffffffffffffffffffffffffff16319050919050565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f6100aa82610081565b9050919050565b6100ba816100a0565b81146100c4575f80fd5b50565b5f813590506100d5816100b1565b92915050565b5f602082840312156100f0576100ef61007d565b5b5f6100fd848285016100c7565b91505092915050565b5f819050919050565b61011881610106565b82525050565b5f6020820190506101315f83018461010f565b9291505056fea26469706673582212203b9fe929fe995c7cf9887f0bdba8a36dd78e8b73f149b17d2d9ad7cd09d2dc6264736f6c634300081a0033";async function qN(e,t){const{blockNumber:n,blockTag:r,calls:s,stateOverrides:a,traceAssetChanges:c,traceTransfers:l,validation:d}=t,f=t.account?zt(t.account):void 0;if(c&&!f)throw new re("`account` is required when `traceAssetChanges` is true");const h=f?DN(FN("constructor(bytes, bytes)"),{bytecode:sx,args:[$N,UN(Ji("function getBalance(address)"),[f.address])]}):void 0,p=c?await Promise.all(t.calls.map(async U=>{if(!U.data&&!U.abi)return;const{accessList:Y}=await mx(e,{account:f.address,...U,data:U.abi?$n(U):U.data});return Y.map(({address:Z,storageKeys:F})=>F.length>0?Z:null)})).then(U=>U.flat().filter(Boolean)):[],m=await xm(e,{blockNumber:n,blockTag:r,blocks:[...c?[{calls:[{data:h}],stateOverrides:a},{calls:p.map((U,Y)=>({abi:[Ji("function balanceOf(address) returns (uint256)")],functionName:"balanceOf",args:[f.address],to:U,from:mr,nonce:Y})),stateOverrides:[{address:mr,nonce:0}]}]:[],{calls:[...s,{to:mr}].map(U=>({...U,from:f==null?void 0:f.address})),stateOverrides:a},...c?[{calls:[{data:h}]},{calls:p.map((U,Y)=>({abi:[Ji("function balanceOf(address) returns (uint256)")],functionName:"balanceOf",args:[f.address],to:U,from:mr,nonce:Y})),stateOverrides:[{address:mr,nonce:0}]},{calls:p.map((U,Y)=>({to:U,abi:[Ji("function decimals() returns (uint256)")],functionName:"decimals",from:mr,nonce:Y})),stateOverrides:[{address:mr,nonce:0}]},{calls:p.map((U,Y)=>({to:U,abi:[Ji("function tokenURI(uint256) returns (string)")],functionName:"tokenURI",args:[0n],from:mr,nonce:Y})),stateOverrides:[{address:mr,nonce:0}]},{calls:p.map((U,Y)=>({to:U,abi:[Ji("function symbol() returns (string)")],functionName:"symbol",from:mr,nonce:Y})),stateOverrides:[{address:mr,nonce:0}]}]:[]],traceTransfers:l,validation:d}),y=c?m[2]:m[0],[v,w,,C,A,I,S,j]=c?m:[],{calls:N,...T}=y,B=N.slice(0,-1)??[],O=(v==null?void 0:v.calls)??[],R=(w==null?void 0:w.calls)??[],W=[...O,...R].map(U=>U.status==="success"?an(U.data):null),H=(C==null?void 0:C.calls)??[],K=(A==null?void 0:A.calls)??[],Q=[...H,...K].map(U=>U.status==="success"?an(U.data):null),ae=((I==null?void 0:I.calls)??[]).map(U=>U.status==="success"?U.result:null),q=((j==null?void 0:j.calls)??[]).map(U=>U.status==="success"?U.result:null),ee=((S==null?void 0:S.calls)??[]).map(U=>U.status==="success"?U.result:null),te=[];for(const[U,Y]of Q.entries()){const Z=W[U];if(typeof Y!="bigint"||typeof Z!="bigint")continue;const F=ae[U-1],X=q[U-1],pe=ee[U-1],ne=U===0?{address:WN,decimals:18,symbol:"ETH"}:{address:p[U-1],decimals:pe||F?Number(F??1):void 0,symbol:X??void 0};te.some(oe=>oe.token.address===ne.address)||te.push({token:ne,value:{pre:Z,post:Y,diff:Y-Z}})}return{assetChanges:te,block:T,results:B}}async function HN(e,t){var h;const{abi:n,address:r,args:s,functionName:a,dataSuffix:c=typeof e.dataSuffix=="string"?e.dataSuffix:(h=e.dataSuffix)==null?void 0:h.value,...l}=t,d=l.account?zt(l.account):e.account,f=$n({abi:n,args:s,functionName:a});try{const{data:p}=await Ee(e,Ha,"call")({batch:!1,data:`${f}${c?c.replace("0x",""):""}`,to:r,...l,account:d}),m=vs({abi:n,args:s,functionName:a,data:p||"0x"}),y=n.filter(v=>"name"in v&&v.name===t.functionName);return{result:m,request:{abi:y,address:r,args:s,dataSuffix:c,functionName:a,...l,account:d}}}catch(p){throw ui(p,{abi:n,address:r,args:s,docsPath:"/docs/contract/simulateContract",functionName:a,sender:d==null?void 0:d.address})}}async function Wf(e,{filter:t}){return t.request({method:"eth_uninstallFilter",params:[t.id]})}const C3="0x6492649264926492649264926492649264926492649264926492649264926492";function VN(e){if(zr(e,-32)!==C3)throw new KN(e)}function QN(e){const{data:t,signature:n,to:r}=e;return Cr(X1(Zx("address, bytes, bytes"),[r,t,n]),C3)}function GN(e){try{return VN(e),!0}catch{return!1}}class KN extends De{constructor(t){super(`Value \`${t}\` is an invalid ERC-6492 wrapped signature.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SignatureErc6492.InvalidWrappedSignatureError"})}}function YN({r:e,s:t,to:n="hex",v:r,yParity:s}){const a=(()=>{if(s===0||s===1)return s;if(r&&(r===27n||r===28n||r>=35n))return r%2n===0n?1:0;throw new Error("Invalid `v` or `yParity` value")})(),c=`0x${new h3.Signature(an(e),an(t)).toCompactHex()}${a===0?"1b":"1c"}`;return n==="hex"?c:xr(c)}async function $f(e,t){var f,h,p,m;const{address:n,chain:r=e.chain,hash:s,erc6492VerifierAddress:a=t.universalSignatureVerifierAddress??((h=(f=r==null?void 0:r.contracts)==null?void 0:f.erc6492Verifier)==null?void 0:h.address),multicallAddress:c=t.multicallAddress??((m=(p=r==null?void 0:r.contracts)==null?void 0:p.multicall3)==null?void 0:m.address),mode:l="auto"}=t;if(r!=null&&r.verifyHash)return await r.verifyHash(e,t);const d=(()=>{const y=t.signature;return $r(y)?y:typeof y=="object"&&"r"in y&&"s"in y?YN(y):bt(y)})();try{if(l==="eoa")try{if(bl(jt(n),await fm({hash:s,signature:d})))return!0}catch{}return jN(d)?await JN(e,{...t,multicallAddress:c,signature:d}):await ZN(e,{...t,verifierAddress:a,signature:d})}catch(y){if(l!=="eoa")try{if(bl(jt(n),await fm({hash:s,signature:d})))return!0}catch{}if(y instanceof pi)return!1;throw y}}async function JN(e,t){var C;const{address:n,blockNumber:r,blockTag:s,hash:a,multicallAddress:c}=t,{authorization:l,data:d,signature:f,to:h}=SN(t.signature);if(await ef(e,{address:n,blockNumber:r,blockTag:s})===Ar(["0xef0100",l.address]))return await XN(e,{address:n,blockNumber:r,blockTag:s,hash:a,signature:f});const m={address:l.address,chainId:Number(l.chainId),nonce:Number(l.nonce),r:le(l.r,{size:32}),s:le(l.s,{size:32}),yParity:l.yParity};if(!await qI({address:n,authorization:m}))throw new pi;const v=await Ee(e,or,"readContract")({...c?{address:c}:{code:P1},authorizationList:[m],abi:Na,blockNumber:r,blockTag:"pending",functionName:"aggregate3",args:[[...d?[{allowFailure:!0,target:h??n,callData:d}]:[],{allowFailure:!0,target:n,callData:$n({abi:X2,functionName:"isValidSignature",args:[a,f]})}]]}),w=(C=v[v.length-1])==null?void 0:C.returnData;if(w!=null&&w.startsWith("0x1626ba7e"))return!0;throw new pi}async function ZN(e,t){const{address:n,factory:r,factoryData:s,hash:a,signature:c,verifierAddress:l,...d}=t,f=await(async()=>!r&&!s||GN(c)?c:QN({data:s,signature:c,to:r}))(),h=l?{to:l,data:$n({abi:qw,functionName:"isValidSig",args:[n,a,f]}),...d}:{data:B1({abi:qw,args:[n,a,f],bytecode:vj}),...d},{data:p}=await Ee(e,Ha,"call")(h).catch(m=>{throw m instanceof z5?new pi:m});if(l4(p??"0x0"))return!0;throw new pi}async function XN(e,t){const{address:n,blockNumber:r,blockTag:s,hash:a,signature:c}=t;if((await Ee(e,or,"readContract")({address:n,abi:X2,args:[a,c],blockNumber:r,blockTag:s,functionName:"isValidSignature"}).catch(d=>{throw d instanceof C1?new pi:d})).startsWith("0x1626ba7e"))return!0;throw new pi}class pi extends Error{}async function eP(e,{address:t,message:n,factory:r,factoryData:s,signature:a,...c}){const l=Wx(n);return Ee(e,$f,"verifyHash")({address:t,factory:r,factoryData:s,hash:l,signature:a,...c})}async function tP(e,t){const{address:n,factory:r,factoryData:s,signature:a,message:c,primaryType:l,types:d,domain:f,...h}=t,p=c9({message:c,primaryType:l,types:d,domain:f});return Ee(e,$f,"verifyHash")({address:n,factory:r,factoryData:s,hash:p,signature:a,...h})}const op=new Map,zb=new Map;let nP=0;function gs(e,t,n){const r=++nP,s=()=>op.get(e)||[],a=()=>{const h=s();op.set(e,h.filter(p=>p.id!==r))},c=()=>{const h=s();if(!h.some(m=>m.id===r))return;const p=zb.get(e);if(h.length===1&&p){const m=p();m instanceof Promise&&m.catch(()=>{})}a()},l=s();if(op.set(e,[...l,{id:r,fns:t}]),l&&l.length>0)return c;const d={};for(const h in t)d[h]=((...p)=>{var y,v;const m=s();if(m.length!==0)for(const w of m)(v=(y=w.fns)[h])==null||v.call(y,...p)});const f=n(d);return typeof f=="function"&&zb.set(e,f),c}function nu(e,{emitOnBegin:t,initialWaitTime:n,interval:r}){let s=!0;const a=()=>s=!1;return(async()=>{let l;t&&(l=await e({unpoll:a}));const d=await(n==null?void 0:n(l))??r;await nf(d);const f=async()=>{s&&(await e({unpoll:a}),await nf(r),f())};f()})(),a}function E3(e,{emitOnBegin:t=!1,emitMissed:n=!1,onBlockNumber:r,onError:s,poll:a,pollingInterval:c=e.pollingInterval}){const l=typeof a<"u"?a:!(e.transport.type==="webSocket"||e.transport.type==="ipc"||e.transport.type==="fallback"&&(e.transport.transports[0].config.type==="webSocket"||e.transport.transports[0].config.type==="ipc"));let d;return l?(()=>{const p=Ut(["watchBlockNumber",e.uid,t,n,c]);return gs(p,{onBlockNumber:r,onError:s},m=>nu(async()=>{var y;try{const v=await Ee(e,eu,"getBlockNumber")({cacheTime:0});if(d!==void 0){if(v===d)return;if(v-d>1&&n)for(let w=d+1n;w<v;w++)m.onBlockNumber(w,d),d=w}(d===void 0||v>d)&&(m.onBlockNumber(v,d),d=v)}catch(v){(y=m.onError)==null||y.call(m,v)}},{emitOnBegin:t,interval:c}))})():(()=>{const p=Ut(["watchBlockNumber",e.uid,t,n]);return gs(p,{onBlockNumber:r,onError:s},m=>{let y=!0,v=()=>y=!1;return(async()=>{try{const w=(()=>{if(e.transport.type==="fallback"){const A=e.transport.transports.find(I=>I.config.type==="webSocket"||I.config.type==="ipc");return A?A.value:e.transport}return e.transport})(),{unsubscribe:C}=await w.subscribe({params:["newHeads"],onData(A){var S;if(!y)return;const I=an((S=A.result)==null?void 0:S.number);m.onBlockNumber(I,d),d=I},onError(A){var I;(I=m.onError)==null||I.call(m,A)}});v=C,y||v()}catch(w){s==null||s(w)}})(),()=>v()})})()}async function A3(e,t){const{checkReplacement:n=!0,confirmations:r=1,hash:s,onReplaced:a,retryCount:c=6,retryDelay:l=({count:N})=>~~(1<<N)*200,timeout:d=18e4}=t,f=Ut(["waitForTransactionReceipt",e.uid,s]),h=(()=>{var N;return t.pollingInterval?t.pollingInterval:(N=e.chain)!=null&&N.experimental_preconfirmationTime?e.chain.experimental_preconfirmationTime:e.pollingInterval})();let p,m,y,v=!1,w,C;const{promise:A,resolve:I,reject:S}=ax(),j=d?setTimeout(()=>{C==null||C(),w==null||w(),S(new E7({hash:s}))},d):void 0;return w=gs(f,{onReplaced:a,resolve:I,reject:S},async N=>{if(y=await Ee(e,$d,"getTransactionReceipt")({hash:s}).catch(()=>{}),y&&r<=1){clearTimeout(j),N.resolve(y),w==null||w();return}C=Ee(e,E3,"watchBlockNumber")({emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:h,async onBlockNumber(T){const B=R=>{clearTimeout(j),C==null||C(),R(),w==null||w()};let O=T;if(!v)try{if(y){if(r>1&&(!y.blockNumber||O-y.blockNumber+1n<r))return;B(()=>N.resolve(y));return}if(n&&!p&&(v=!0,await Ma(async()=>{p=await Ee(e,Uf,"getTransaction")({hash:s}),p.blockNumber&&(O=p.blockNumber)},{delay:l,retryCount:c}),v=!1),y=await Ee(e,$d,"getTransactionReceipt")({hash:s}),r>1&&(!y.blockNumber||O-y.blockNumber+1n<r))return;B(()=>N.resolve(y))}catch(R){if(R instanceof L5||R instanceof U5){if(!p){v=!1;return}try{m=p,v=!0;const W=await Ma(()=>Ee(e,yr,"getBlock")({blockNumber:O,includeTransactions:!0}),{delay:l,retryCount:c,shouldRetry:({error:Q})=>Q instanceof Cx});v=!1;const H=W.transactions.find(({from:Q,nonce:ae})=>Q===m.from&&ae===m.nonce);if(!H||(y=await Ee(e,$d,"getTransactionReceipt")({hash:H.hash}),r>1&&(!y.blockNumber||O-y.blockNumber+1n<r)))return;let K="replaced";H.to===m.to&&H.value===m.value&&H.input===m.input?K="repriced":H.from===H.to&&H.value===0n&&(K="cancelled"),B(()=>{var Q;(Q=N.onReplaced)==null||Q.call(N,{reason:K,replacedTransaction:m,transaction:H,transactionReceipt:y}),N.resolve(y)})}catch(W){B(()=>N.reject(W))}}else B(()=>N.reject(R))}}})}),A}function rP(e,{blockTag:t=e.experimental_blockTag??"latest",emitMissed:n=!1,emitOnBegin:r=!1,onBlock:s,onError:a,includeTransactions:c,poll:l,pollingInterval:d=e.pollingInterval}){const f=typeof l<"u"?l:!(e.transport.type==="webSocket"||e.transport.type==="ipc"||e.transport.type==="fallback"&&(e.transport.transports[0].config.type==="webSocket"||e.transport.transports[0].config.type==="ipc")),h=c??!1;let p;return f?(()=>{const v=Ut(["watchBlocks",e.uid,t,n,r,h,d]);return gs(v,{onBlock:s,onError:a},w=>nu(async()=>{var C;try{const A=await Ee(e,yr,"getBlock")({blockTag:t,includeTransactions:h});if(A.number!==null&&(p==null?void 0:p.number)!=null){if(A.number===p.number)return;if(A.number-p.number>1&&n)for(let I=(p==null?void 0:p.number)+1n;I<A.number;I++){const S=await Ee(e,yr,"getBlock")({blockNumber:I,includeTransactions:h});w.onBlock(S,p),p=S}}((p==null?void 0:p.number)==null||t==="pending"&&(A==null?void 0:A.number)==null||A.number!==null&&A.number>p.number)&&(w.onBlock(A,p),p=A)}catch(A){(C=w.onError)==null||C.call(w,A)}},{emitOnBegin:r,interval:d}))})():(()=>{let v=!0,w=!0,C=()=>v=!1;return(async()=>{try{r&&Ee(e,yr,"getBlock")({blockTag:t,includeTransactions:h}).then(S=>{v&&w&&(s(S,void 0),w=!1)}).catch(a);const A=(()=>{if(e.transport.type==="fallback"){const S=e.transport.transports.find(j=>j.config.type==="webSocket"||j.config.type==="ipc");return S?S.value:e.transport}return e.transport})(),{unsubscribe:I}=await A.subscribe({params:["newHeads"],async onData(S){var N;if(!v)return;const j=await Ee(e,yr,"getBlock")({blockNumber:(N=S.result)==null?void 0:N.number,includeTransactions:h}).catch(()=>{});v&&(s(j,p),w=!1,p=j)},onError(S){a==null||a(S)}});C=I,v||C()}catch(A){a==null||a(A)}})(),()=>C()})()}function oP(e,t){const{abi:n,address:r,args:s,batch:a=!0,eventName:c,fromBlock:l,onError:d,onLogs:f,poll:h,pollingInterval:p=e.pollingInterval,strict:m}=t;return(typeof h<"u"?h:typeof l=="bigint"?!0:!(e.transport.type==="webSocket"||e.transport.type==="ipc"||e.transport.type==="fallback"&&(e.transport.transports[0].config.type==="webSocket"||e.transport.transports[0].config.type==="ipc")))?(()=>{const C=m??!1,A=Ut(["watchContractEvent",r,s,a,e.uid,c,p,C,l]);return gs(A,{onLogs:f,onError:d},I=>{let S;l!==void 0&&(S=l-1n);let j,N=!1;const T=nu(async()=>{var B;if(!N){try{j=await Ee(e,gx,"createContractEventFilter")({abi:n,address:r,args:s,eventName:c,strict:C,fromBlock:l})}catch{}N=!0;return}try{let O;if(j)O=await Ee(e,Mf,"getFilterChanges")({filter:j});else{const R=await Ee(e,eu,"getBlockNumber")({});S&&S<R?O=await Ee(e,zx,"getContractEvents")({abi:n,address:r,args:s,eventName:c,fromBlock:S+1n,toBlock:R,strict:C}):O=[],S=R}if(O.length===0)return;if(a)I.onLogs(O);else for(const R of O)I.onLogs([R])}catch(O){j&&O instanceof ps&&(N=!1),(B=I.onError)==null||B.call(I,O)}},{emitOnBegin:!0,interval:p});return async()=>{j&&await Ee(e,Wf,"uninstallFilter")({filter:j}),T()}})})():(()=>{const C=m??!1,A=Ut(["watchContractEvent",r,s,a,e.uid,c,p,C]);let I=!0,S=()=>I=!1;return gs(A,{onLogs:f,onError:d},j=>((async()=>{try{const N=(()=>{if(e.transport.type==="fallback"){const O=e.transport.transports.find(R=>R.config.type==="webSocket"||R.config.type==="ipc");return O?O.value:e.transport}return e.transport})(),T=c?Zl({abi:n,eventName:c,args:s}):[],{unsubscribe:B}=await N.subscribe({params:["logs",{address:r,topics:T}],onData(O){var W;if(!I)return;const R=O.result;try{const{eventName:H,args:K}=tf({abi:n,data:R.data,topics:R.topics,strict:m}),Q=Hr(R,{args:K,eventName:H});j.onLogs([Q])}catch(H){let K,Q;if(H instanceof Yd||H instanceof d1){if(m)return;K=H.abiItem.name,Q=(W=H.abiItem.inputs)==null?void 0:W.some(q=>!("name"in q&&q.name))}const ae=Hr(R,{args:Q?[]:{},eventName:K});j.onLogs([ae])}},onError(O){var R;(R=j.onError)==null||R.call(j,O)}});S=B,I||S()}catch(N){d==null||d(N)}})(),()=>S()))})()}function sP(e,{address:t,args:n,batch:r=!0,event:s,events:a,fromBlock:c,onError:l,onLogs:d,poll:f,pollingInterval:h=e.pollingInterval,strict:p}){const m=typeof f<"u"?f:typeof c=="bigint"?!0:!(e.transport.type==="webSocket"||e.transport.type==="ipc"||e.transport.type==="fallback"&&(e.transport.transports[0].config.type==="webSocket"||e.transport.transports[0].config.type==="ipc")),y=p??!1;return m?(()=>{const C=Ut(["watchEvent",t,n,r,e.uid,s,h,c]);return gs(C,{onLogs:d,onError:l},A=>{let I;c!==void 0&&(I=c-1n);let S,j=!1;const N=nu(async()=>{var T;if(!j){try{S=await Ee(e,yx,"createEventFilter")({address:t,args:n,event:s,events:a,strict:y,fromBlock:c})}catch{}j=!0;return}try{let B;if(S)B=await Ee(e,Mf,"getFilterChanges")({filter:S});else{const O=await Ee(e,eu,"getBlockNumber")({});I&&I!==O?B=await Ee(e,V1,"getLogs")({address:t,args:n,event:s,events:a,fromBlock:I+1n,toBlock:O}):B=[],I=O}if(B.length===0)return;if(r)A.onLogs(B);else for(const O of B)A.onLogs([O])}catch(B){S&&B instanceof ps&&(j=!1),(T=A.onError)==null||T.call(A,B)}},{emitOnBegin:!0,interval:h});return async()=>{S&&await Ee(e,Wf,"uninstallFilter")({filter:S}),N()}})})():(()=>{let C=!0,A=()=>C=!1;return(async()=>{try{const I=(()=>{if(e.transport.type==="fallback"){const T=e.transport.transports.find(B=>B.config.type==="webSocket"||B.config.type==="ipc");return T?T.value:e.transport}return e.transport})(),S=a??(s?[s]:void 0);let j=[];S&&(j=[S.flatMap(B=>Zl({abi:[B],eventName:B.name,args:n}))],s&&(j=j[0]));const{unsubscribe:N}=await I.subscribe({params:["logs",{address:t,topics:j}],onData(T){var O;if(!C)return;const B=T.result;try{const{eventName:R,args:W}=tf({abi:S??[],data:B.data,topics:B.topics,strict:y}),H=Hr(B,{args:W,eventName:R});d([H])}catch(R){let W,H;if(R instanceof Yd||R instanceof d1){if(p)return;W=R.abiItem.name,H=(O=R.abiItem.inputs)==null?void 0:O.some(Q=>!("name"in Q&&Q.name))}const K=Hr(B,{args:H?[]:{},eventName:W});d([K])}},onError(T){l==null||l(T)}});A=N,C||A()}catch(I){l==null||l(I)}})(),()=>A()})()}function iP(e,{batch:t=!0,onError:n,onTransactions:r,poll:s,pollingInterval:a=e.pollingInterval}){return(typeof s<"u"?s:e.transport.type!=="webSocket"&&e.transport.type!=="ipc")?(()=>{const f=Ut(["watchPendingTransactions",e.uid,t,a]);return gs(f,{onTransactions:r,onError:n},h=>{let p;const m=nu(async()=>{var y;try{if(!p)try{p=await Ee(e,vx,"createPendingTransactionFilter")({});return}catch(w){throw m(),w}const v=await Ee(e,Mf,"getFilterChanges")({filter:p});if(v.length===0)return;if(t)h.onTransactions(v);else for(const w of v)h.onTransactions([w])}catch(v){(y=h.onError)==null||y.call(h,v)}},{emitOnBegin:!0,interval:a});return async()=>{p&&await Ee(e,Wf,"uninstallFilter")({filter:p}),m()}})})():(()=>{let f=!0,h=()=>f=!1;return(async()=>{try{const{unsubscribe:p}=await e.transport.subscribe({params:["newPendingTransactions"],onData(m){if(!f)return;const y=m.result;r([y])},onError(m){n==null||n(m)}});h=p,f||h()}catch(p){n==null||n(p)}})(),()=>h()})()}class og extends re{constructor({docsPath:t}={}){super(["Could not find an Account to execute with this Action.","Please provide an Account with the `account` argument on the Action, or by supplying an `account` to the Client."].join(`
83
- `),{docsPath:t,docsSlug:"account",name:"AccountNotFoundError"})}}class sp extends re{constructor({docsPath:t,metaMessages:n,type:r}){super(`Account type "${r}" is not supported.`,{docsPath:t,metaMessages:n,name:"AccountTypeNotSupportedError"})}}async function k3(e,{serializedTransaction:t}){return e.request({method:"eth_sendRawTransaction",params:[t]},{retryCount:0})}const ip=new $l(128);async function aP(e,t){var j,N,T,B,O;const{account:n=e.account,assertChainId:r=!0,chain:s=e.chain,accessList:a,authorizationList:c,blobs:l,data:d,dataSuffix:f=typeof e.dataSuffix=="string"?e.dataSuffix:(j=e.dataSuffix)==null?void 0:j.value,gas:h,gasPrice:p,maxFeePerBlobGas:m,maxFeePerGas:y,maxPriorityFeePerGas:v,nonce:w,type:C,value:A,...I}=t;if(typeof n>"u")throw new og({docsPath:"/docs/actions/wallet/sendTransaction"});const S=n?zt(n):null;try{xi(t);const R=await(async()=>{if(t.to)return t.to;if(t.to!==null&&c&&c.length>0)return await M1({authorization:c[0]}).catch(()=>{throw new re("`to` is required. Could not infer from `authorizationList`.")})})();if((S==null?void 0:S.type)==="json-rpc"||S===null){let W;s!==null&&(W=await Ee(e,Rf,"getChainId")({}),r&&GI({currentChainId:W,chain:s}));const H=(B=(T=(N=e.chain)==null?void 0:N.formatters)==null?void 0:T.transactionRequest)==null?void 0:B.format,Q=(H||qa)({...Jl(I,{format:H}),accessList:a,account:S,authorizationList:c,blobs:l,chainId:W,data:f?rr([d??"0x",f]):d,gas:h,gasPrice:p,maxFeePerBlobGas:m,maxFeePerGas:y,maxPriorityFeePerGas:v,nonce:w,to:R,type:C,value:A},"sendTransaction"),ae=ip.get(e.uid),q=ae?"wallet_sendTransaction":"eth_sendTransaction";try{return await e.request({method:q,params:[Q]},{retryCount:0})}catch(ee){if(ae===!1)throw ee;const te=ee;if(te.name==="InvalidInputRpcError"||te.name==="InvalidParamsRpcError"||te.name==="MethodNotFoundRpcError"||te.name==="MethodNotSupportedRpcError")return await e.request({method:"wallet_sendTransaction",params:[Q]},{retryCount:0}).then(U=>(ip.set(e.uid,!0),U)).catch(U=>{const Y=U;throw Y.name==="MethodNotFoundRpcError"||Y.name==="MethodNotSupportedRpcError"?(ip.set(e.uid,!1),te):Y});throw te}}if((S==null?void 0:S.type)==="local"){const W=await Ee(e,$1,"prepareTransactionRequest")({account:S,accessList:a,authorizationList:c,blobs:l,chain:s,data:f?rr([d??"0x",f]):d,gas:h,gasPrice:p,maxFeePerBlobGas:m,maxFeePerGas:y,maxPriorityFeePerGas:v,nonce:w,nonceManager:S.nonceManager,parameters:[...Lx,"sidecars"],type:C,value:A,...I,to:R}),H=(O=s==null?void 0:s.serializers)==null?void 0:O.transaction,K=await S.signTransaction(W,{serializer:H});return await Ee(e,k3,"sendRawTransaction")({serializedTransaction:K})}throw(S==null?void 0:S.type)==="smart"?new sp({metaMessages:["Consider using the `sendUserOperation` Action instead."],docsPath:"/docs/actions/bundler/sendUserOperation",type:"smart"}):new sp({docsPath:"/docs/actions/wallet/sendTransaction",type:S==null?void 0:S.type})}catch(R){throw R instanceof sp?R:Dx(R,{...t,account:S,chain:t.chain||void 0})}}async function cP(e,{serializedTransaction:t,throwOnReceiptRevert:n,timeout:r}){var l,d,f;const s=await e.request({method:"eth_sendRawTransactionSync",params:r?[t,r]:[t]},{retryCount:0}),c=(((f=(d=(l=e.chain)==null?void 0:l.formatters)==null?void 0:d.transactionReceipt)==null?void 0:f.format)||K1)(s);if(c.status==="reverted"&&n)throw new C7({receipt:c});return c}async function lP(e,{account:t=e.account,message:n}){if(!t)throw new og({docsPath:"/docs/actions/wallet/signMessage"});const r=zt(t);if(r.signMessage)return r.signMessage({message:n});const s=typeof n=="string"?Ba(n):n.raw instanceof Uint8Array?An(n.raw):n.raw;return e.request({method:"personal_sign",params:[s,r.address]},{retryCount:0})}async function of(e,t){return of.internal(e,aP,"sendTransaction",t)}(function(e){async function t(n,r,s,a){const{abi:c,account:l=n.account,address:d,args:f,functionName:h,...p}=a;if(typeof l>"u")throw new og({docsPath:"/docs/contract/writeContract"});const m=l?zt(l):null,y=$n({abi:c,args:f,functionName:h});try{return await Ee(n,r,s)({data:y,to:d,account:m,...p})}catch(v){throw ui(v,{abi:c,address:d,args:f,docsPath:"/docs/contract/writeContract",functionName:h,sender:m==null?void 0:m.address})}}e.internal=t})(of||(of={}));function Wr(e,t,n){const r=e[t.name];if(typeof r=="function")return r;const s=e[n];return typeof s=="function"?s:a=>t(e,a)}const qd="2.22.1",uP=()=>`@wagmi/core@${qd}`;var S3=function(e,t,n,r){if(n==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?r:n==="a"?r.call(e):r?r.value:t.get(e)},sf,j3;let ko=class Am extends Error{get docsBaseUrl(){return"https://wagmi.sh/core"}get version(){return uP()}constructor(t,n={}){var a;super(),sf.add(this),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WagmiCoreError"});const r=n.cause instanceof Am?n.cause.details:(a=n.cause)!=null&&a.message?n.cause.message:n.details,s=n.cause instanceof Am&&n.cause.docsPath||n.docsPath;this.message=[t||"An error occurred.","",...n.metaMessages?[...n.metaMessages,""]:[],...s?[`Docs: ${this.docsBaseUrl}${s}.html${n.docsSlug?`#${n.docsSlug}`:""}`]:[],...r?[`Details: ${r}`]:[],`Version: ${this.version}`].join(`
84
- `),n.cause&&(this.cause=n.cause),this.details=r,this.docsPath=s,this.metaMessages=n.metaMessages,this.shortMessage=t}walk(t){return S3(this,sf,"m",j3).call(this,this,t)}};sf=new WeakSet,j3=function e(t,n){return n!=null&&n(t)?t:t.cause?S3(this,sf,"m",e).call(this,t.cause,n):t};class ys extends ko{constructor(){super("Chain not configured."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainNotConfiguredError"})}}class dP extends ko{constructor(){super("Connector already connected."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ConnectorAlreadyConnectedError"})}}class fP extends ko{constructor(){super("Connector not connected."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ConnectorNotConnectedError"})}}class hP extends ko{constructor({address:t,connector:n}){super(`Account "${t}" not found for connector "${n.name}".`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ConnectorAccountNotFoundError"})}}class pP extends ko{constructor({connectionChainId:t,connectorChainId:n}){super(`The current chain of the connector (id: ${n}) does not match the connection's chain (id: ${t}).`,{metaMessages:[`Current Chain ID: ${n}`,`Expected Chain ID: ${t}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ConnectorChainMismatchError"})}}class mP extends ko{constructor({connector:t}){super(`Connector "${t.name}" unavailable while reconnecting.`,{details:["During the reconnection step, the only connector methods guaranteed to be available are: `id`, `name`, `type`, `uid`.","All other methods are not guaranteed to be available until reconnection completes and connectors are fully restored.","This error commonly occurs for connectors that asynchronously inject after reconnection has already started."].join(" ")}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ConnectorUnavailableReconnectingError"})}}async function gP(e,t){var r;let n;if(typeof t.connector=="function"?n=e._internal.connectors.setup(t.connector):n=t.connector,n.uid===e.state.current)throw new dP;try{e.setState(l=>({...l,status:"connecting"})),n.emitter.emit("message",{type:"connecting"});const{connector:s,...a}=t,c=await n.connect(a);return n.emitter.off("connect",e._internal.events.connect),n.emitter.on("change",e._internal.events.change),n.emitter.on("disconnect",e._internal.events.disconnect),await((r=e.storage)==null?void 0:r.setItem("recentConnectorId",n.id)),e.setState(l=>({...l,connections:new Map(l.connections).set(n.uid,{accounts:a.withCapabilities?c.accounts.map(d=>typeof d=="object"?d.address:d):c.accounts,chainId:c.chainId,connector:n}),current:n.uid,status:"connected"})),{accounts:a.withCapabilities?c.accounts.map(l=>typeof l=="object"?l:{address:l,capabilities:{}}):c.accounts,chainId:c.chainId}}catch(s){throw e.setState(a=>({...a,status:a.current?"connected":"disconnected"})),s}}const km=256;let kd=km,Sd;function I3(e=11){if(!Sd||kd+e>km*2){Sd="",kd=0;for(let t=0;t<km;t++)Sd+=(256+Math.random()*256|0).toString(16).substring(1)}return Sd.substring(kd,kd+++e)}function N3(e){const{batch:t,chain:n,ccipRead:r,dataSuffix:s,key:a="base",name:c="Base Client",type:l="base"}=e,d=e.experimental_blockTag??(typeof(n==null?void 0:n.experimental_preconfirmationTime)=="number"?"pending":void 0),f=(n==null?void 0:n.blockTime)??12e3,h=Math.min(Math.max(Math.floor(f/2),500),4e3),p=e.pollingInterval??h,m=e.cacheTime??p,y=e.account?zt(e.account):void 0,{config:v,request:w,value:C}=e.transport({account:y,chain:n,pollingInterval:p}),A={...v,...C},I={account:y,batch:t,cacheTime:m,ccipRead:r,chain:n,dataSuffix:s,key:a,name:c,pollingInterval:p,request:w,transport:A,type:l,uid:I3(),...d?{experimental_blockTag:d}:{}};function S(j){return N=>{const T=N(j);for(const O in I)delete T[O];const B={...j,...T};return Object.assign(B,{extend:S(B)})}}return Object.assign(I,{extend:S(I)})}function yP(e){var p,m,y;const{scheme:t,statement:n,...r}=((p=e.match(vP))==null?void 0:p.groups)??{},{chainId:s,expirationTime:a,issuedAt:c,notBefore:l,requestId:d,...f}=((m=e.match(wP))==null?void 0:m.groups)??{},h=(y=e.split("Resources:")[1])==null?void 0:y.split(`
85
- - `).slice(1);return{...r,...f,...s?{chainId:Number(s)}:{},...a?{expirationTime:new Date(a)}:{},...c?{issuedAt:new Date(c)}:{},...l?{notBefore:new Date(l)}:{},...d?{requestId:d}:{},...h?{resources:h}:{},...t?{scheme:t}:{},...n?{statement:n}:{}}}const vP=/^(?:(?<scheme>[a-zA-Z][a-zA-Z0-9+-.]*):\/\/)?(?<domain>[a-zA-Z0-9+-.]*(?::[0-9]{1,5})?) (?:wants you to sign in with your Ethereum account:\n)(?<address>0x[a-fA-F0-9]{40})\n\n(?:(?<statement>.*)\n\n)?/,wP=/(?:URI: (?<uri>.+))\n(?:Version: (?<version>.+))\n(?:Chain ID: (?<chainId>\d+))\n(?:Nonce: (?<nonce>[a-zA-Z0-9]+))\n(?:Issued At: (?<issuedAt>.+))(?:\nExpiration Time: (?<expirationTime>.+))?(?:\nNot Before: (?<notBefore>.+))?(?:\nRequest ID: (?<requestId>.+))?/;function bP(e){const{address:t,domain:n,message:r,nonce:s,scheme:a,time:c=new Date}=e;if(n&&r.domain!==n||s&&r.nonce!==s||a&&r.scheme!==a||r.expirationTime&&c>=r.expirationTime||r.notBefore&&c<r.notBefore)return!1;try{if(!r.address||!xt(r.address,{strict:!1})||t&&!bl(r.address,t))return!1}catch{return!1}return!0}async function xP(e,t){const{address:n,domain:r,message:s,nonce:a,scheme:c,signature:l,time:d=new Date,...f}=t,h=yP(s);if(!h.address||!bP({address:n,domain:r,message:h,nonce:a,scheme:c,time:d}))return!1;const m=Wx(s);return $f(e,{address:h.address,hash:m,signature:l,...f})}function CP(e){return{call:t=>Ha(e,t),createAccessList:t=>mx(e,t),createBlockFilter:()=>Uj(e),createContractEventFilter:t=>gx(e,t),createEventFilter:t=>yx(e,t),createPendingTransactionFilter:()=>vx(e),estimateContractGas:t=>gI(e,t),estimateGas:t=>q1(e,t),getBalance:t=>Ux(e,t),getBlobBaseFee:()=>yI(e),getBlock:t=>yr(e,t),getBlockNumber:t=>eu(e,t),getBlockTransactionCount:t=>EI(e,t),getBytecode:t=>ef(e,t),getChainId:()=>Rf(e),getCode:t=>ef(e,t),getContractEvents:t=>zx(e,t),getDelegation:t=>SI(e,t),getEip712Domain:t=>II(e,t),getEnsAddress:t=>Sj(e,t),getEnsAvatar:t=>hx(e,t),getEnsName:t=>px(e,t),getEnsResolver:t=>Lj(e,t),getEnsText:t=>fx(e,t),getFeeHistory:t=>BI(e,t),estimateFeesPerGas:t=>eI(e,t),getFilterChanges:t=>Mf(e,t),getFilterLogs:t=>_I(e,t),getGasPrice:()=>L1(e),getLogs:t=>V1(e,t),getProof:t=>_N(e,t),estimateMaxPriorityFeePerGas:t=>Xj(e,t),fillTransaction:t=>Fx(e,t),getStorageAt:t=>TN(e,t),getTransaction:t=>Uf(e,t),getTransactionConfirmations:t=>ON(e,t),getTransactionCount:t=>kx(e,t),getTransactionReceipt:t=>$d(e,t),multicall:t=>v3(e,t),prepareTransactionRequest:t=>$1(e,t),readContract:t=>or(e,t),sendRawTransaction:t=>k3(e,t),sendRawTransactionSync:t=>cP(e,t),simulate:t=>xm(e,t),simulateBlocks:t=>xm(e,t),simulateCalls:t=>qN(e,t),simulateContract:t=>HN(e,t),verifyHash:t=>$f(e,t),verifyMessage:t=>eP(e,t),verifySiweMessage:t=>xP(e,t),verifyTypedData:t=>tP(e,t),uninstallFilter:t=>Wf(e,t),waitForTransactionReceipt:t=>A3(e,t),watchBlocks:t=>rP(e,t),watchBlockNumber:t=>E3(e,t),watchContractEvent:t=>oP(e,t),watchEvent:t=>sP(e,t),watchPendingTransactions:t=>iP(e,t)}}function sg({key:e,methods:t,name:n,request:r,retryCount:s=3,retryDelay:a=150,timeout:c,type:l},d){const f=I3();return{config:{key:e,methods:t,name:n,request:r,retryCount:s,retryDelay:a,timeout:c,type:l},request:VI(r,{methods:t,retryCount:s,retryDelay:a,uid:f}),value:d}}function EP(e,t={}){const{key:n="custom",methods:r,name:s="Custom Provider",retryDelay:a}=t;return({retryCount:c})=>sg({key:n,methods:r,name:s,request:e.request.bind(e),retryCount:t.retryCount??c,retryDelay:a,type:"custom"})}function AP(e,t={}){const{key:n="fallback",name:r="Fallback",rank:s=!1,shouldThrow:a=kP,retryCount:c,retryDelay:l}=t;return(({chain:d,pollingInterval:f=4e3,timeout:h,...p})=>{let m=e,y=()=>{};const v=sg({key:n,name:r,async request({method:w,params:C}){let A;const I=async(S=0)=>{const j=m[S]({...p,chain:d,retryCount:0,timeout:h});try{const N=await j.request({method:w,params:C});return y({method:w,params:C,response:N,transport:j,status:"success"}),N}catch(N){if(y({error:N,method:w,params:C,transport:j,status:"error"}),a(N)||S===m.length-1||(A??(A=m.slice(S+1).some(T=>{const{include:B,exclude:O}=T({chain:d}).config.methods||{};return B?B.includes(w):O?!O.includes(w):!0})),!A))throw N;return I(S+1)}};return I()},retryCount:c,retryDelay:l,type:"fallback"},{onResponse:w=>y=w,transports:m.map(w=>w({chain:d,retryCount:0}))});if(s){const w=typeof s=="object"?s:{};SP({chain:d,interval:w.interval??f,onTransports:C=>m=C,ping:w.ping,sampleCount:w.sampleCount,timeout:w.timeout,transports:m,weights:w.weights})}return v})}function kP(e){return!!("code"in e&&typeof e.code=="number"&&(e.code===Ta.code||e.code===Ge.code||e.code===Ra.code||Hs.nodeMessage.test(e.message)||e.code===5e3))}function SP({chain:e,interval:t=4e3,onTransports:n,ping:r,sampleCount:s=10,timeout:a=1e3,transports:c,weights:l={}}){const{stability:d=.7,latency:f=.3}=l,h=[],p=async()=>{const m=await Promise.all(c.map(async w=>{const C=w({chain:e,retryCount:0,timeout:a}),A=Date.now();let I,S;try{await(r?r({transport:C}):C.request({method:"net_listening"})),S=1}catch{S=0}finally{I=Date.now()}return{latency:I-A,success:S}}));h.push(m),h.length>s&&h.shift();const y=Math.max(...h.map(w=>Math.max(...w.map(({latency:C})=>C)))),v=c.map((w,C)=>{const A=h.map(T=>T[C].latency),S=1-A.reduce((T,B)=>T+B,0)/A.length/y,j=h.map(T=>T[C].success),N=j.reduce((T,B)=>T+B,0)/j.length;return N===0?[0,C]:[f*S+d*N,C]}).sort((w,C)=>C[0]-w[0]);n(v.map(([,w])=>c[w])),await nf(t),p()};p()}class jP extends re{constructor(){super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.",{docsPath:"/docs/clients/intro",name:"UrlRequiredError"})}}function Hd(e,t={}){const{batch:n,fetchFn:r,fetchOptions:s,key:a="http",methods:c,name:l="HTTP JSON-RPC",onFetchRequest:d,onFetchResponse:f,retryDelay:h,raw:p}=t;return({chain:m,retryCount:y,timeout:v})=>{const{batchSize:w=1e3,wait:C=0}=typeof n=="object"?n:{},A=t.retryCount??y,I=v??t.timeout??1e4,S=e||(m==null?void 0:m.rpcUrls.default.http[0]);if(!S)throw new jP;const j=ZI(S,{fetchFn:r,fetchOptions:s,onRequest:d,onResponse:f,timeout:I});return sg({key:a,methods:c,name:l,async request({method:N,params:T}){const B={method:N,params:T},{schedule:O}=cx({id:S,wait:C,shouldSplitBatch(K){return K.length>w},fn:K=>j.request({body:K}),sort:(K,Q)=>K.id-Q.id}),R=async K=>n?O(K):[await j.request({body:K})],[{error:W,result:H}]=await R(B);if(p)return{error:W,result:H};if(W)throw new k1({body:B,error:W,url:S});return H},retryCount:A,retryDelay:h,timeout:I,type:"http"},{fetchOptions:s,url:S})}}async function P3(e,t={}){const{assertChainId:n=!0}=t;let r;if(t.connector){const{connector:h}=t;if(e.state.status==="reconnecting"&&!h.getAccounts&&!h.getChainId)throw new mP({connector:h});const[p,m]=await Promise.all([h.getAccounts().catch(y=>{if(t.account===null)return[];throw y}),h.getChainId()]);r={accounts:p,chainId:m,connector:h}}else r=e.state.connections.get(e.state.current);if(!r)throw new fP;const s=t.chainId??r.chainId,a=await r.connector.getChainId();if(n&&a!==s)throw new pP({connectionChainId:s,connectorChainId:a});const c=r.connector;if(c.getClient)return c.getClient({chainId:s});const l=zt(t.account??r.accounts[0]);if(l&&(l.address=jt(l.address)),t.account&&!r.accounts.some(h=>h.toLowerCase()===l.address.toLowerCase()))throw new hP({address:l.address,connector:c});const d=e.chains.find(h=>h.id===s),f=await r.connector.getProvider({chainId:s});return N3({account:l,chain:d,name:"Connector Client",transport:h=>EP(f)({...h,retryCount:0})})}async function IP(e,t={}){var s,a;let n;if(t.connector)n=t.connector;else{const{connections:c,current:l}=e.state,d=c.get(l);n=d==null?void 0:d.connector}const r=e.state.connections;n&&(await n.disconnect(),n.emitter.off("change",e._internal.events.change),n.emitter.off("disconnect",e._internal.events.disconnect),n.emitter.on("connect",e._internal.events.connect),r.delete(n.uid)),e.setState(c=>{if(r.size===0)return{...c,connections:new Map,current:null,status:"disconnected"};const l=r.values().next().value;return{...c,connections:new Map(r),current:l.connector.uid}});{const c=e.state.current;if(!c)return;const l=(s=e.state.connections.get(c))==null?void 0:s.connector;if(!l)return;await((a=e.storage)==null?void 0:a.setItem("recentConnectorId",l.id))}}function B3(e){return typeof e=="number"?e:e==="wei"?0:Math.abs(p7[e])}function _3(e){const t=e.state.current,n=e.state.connections.get(t),r=n==null?void 0:n.accounts,s=r==null?void 0:r[0],a=e.chains.find(l=>l.id===(n==null?void 0:n.chainId)),c=e.state.status;switch(c){case"connected":return{address:s,addresses:r,chain:a,chainId:n==null?void 0:n.chainId,connector:n==null?void 0:n.connector,isConnected:!0,isConnecting:!1,isDisconnected:!1,isReconnecting:!1,status:c};case"reconnecting":return{address:s,addresses:r,chain:a,chainId:n==null?void 0:n.chainId,connector:n==null?void 0:n.connector,isConnected:!!s,isConnecting:!1,isDisconnected:!1,isReconnecting:!0,status:c};case"connecting":return{address:s,addresses:r,chain:a,chainId:n==null?void 0:n.chainId,connector:n==null?void 0:n.connector,isConnected:!1,isConnecting:!0,isDisconnected:!1,isReconnecting:!1,status:c};case"disconnected":return{address:void 0,addresses:void 0,chain:void 0,chainId:void 0,connector:void 0,isConnected:!1,isConnecting:!1,isDisconnected:!0,isReconnecting:!1,status:c}}}async function NP(e,t){const{allowFailure:n=!0,chainId:r,contracts:s,...a}=t,c=e.getClient({chainId:r});return Wr(c,v3,"multicall")({allowFailure:n,contracts:s,...a})}function T3(e,t){const{chainId:n,...r}=t,s=e.getClient({chainId:n});return Wr(s,or,"readContract")(r)}async function O3(e,t){var l;const{allowFailure:n=!0,blockNumber:r,blockTag:s,...a}=t,c=t.contracts;try{const d={};for(const[m,y]of c.entries()){const v=y.chainId??e.state.chainId;d[v]||(d[v]=[]),(l=d[v])==null||l.push({contract:y,index:m})}const f=()=>Object.entries(d).map(([m,y])=>NP(e,{...a,allowFailure:n,blockNumber:r,blockTag:s,chainId:Number.parseInt(m,10),contracts:y.map(({contract:v})=>v)})),h=(await Promise.all(f())).flat(),p=Object.values(d).flatMap(m=>m.map(({index:y})=>y));return h.reduce((m,y,v)=>(m&&(m[p[v]]=y),m),[])}catch(d){if(d instanceof C1)throw d;const f=()=>c.map(h=>T3(e,{...h,blockNumber:r,blockTag:s}));return n?(await Promise.allSettled(f())).map(h=>h.status==="fulfilled"?{result:h.value,status:"success"}:{error:h.reason,result:void 0,status:"failure"}):await Promise.all(f())}}async function PP(e,t){const{address:n,blockNumber:r,blockTag:s,chainId:a,token:c,unit:l="ether"}=t;if(c)try{return await Wb(e,{balanceAddress:n,chainId:a,symbolType:"string",tokenAddress:c})}catch(m){if(m.name==="ContractFunctionExecutionError"){const y=await Wb(e,{balanceAddress:n,chainId:a,symbolType:"bytes32",tokenAddress:c}),v=c5(Un(y.symbol,{dir:"right"}));return{...y,symbol:v}}throw m}const d=e.getClient({chainId:a}),h=await Wr(d,Ux,"getBalance")(r?{address:n,blockNumber:r}:{address:n,blockTag:s}),p=e.chains.find(m=>m.id===a)??d.chain;return{decimals:p.nativeCurrency.decimals,formatted:qr(h,B3(l)),symbol:p.nativeCurrency.symbol,value:h}}async function Wb(e,t){const{balanceAddress:n,chainId:r,symbolType:s,tokenAddress:a,unit:c}=t,l={abi:[{type:"function",name:"balanceOf",stateMutability:"view",inputs:[{type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"decimals",stateMutability:"view",inputs:[],outputs:[{type:"uint8"}]},{type:"function",name:"symbol",stateMutability:"view",inputs:[],outputs:[{type:s}]}],address:a},[d,f,h]=await O3(e,{allowFailure:!1,contracts:[{...l,functionName:"balanceOf",args:[n],chainId:r},{...l,functionName:"decimals",chainId:r},{...l,functionName:"symbol",chainId:r}]}),p=qr(d??"0",B3(c??f));return{decimals:f,formatted:p,symbol:h,value:d}}function $b(e){return e.state.chainId}function mi(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;let n,r;if(Array.isArray(e)&&Array.isArray(t)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!mi(e[r],t[r]))return!1;return!0}if(typeof e.valueOf=="function"&&e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(typeof e.toString=="function"&&e.toString!==Object.prototype.toString)return e.toString()===t.toString();const s=Object.keys(e);if(n=s.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!Object.hasOwn(t,s[r]))return!1;for(r=n;r--!==0;){const a=s[r];if(a&&!mi(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}let ap=[];function qb(e){const t=e.chains;return mi(ap,t)?ap:(ap=t,t)}function BP(e,t={}){try{return e.getClient(t)}catch{return}}let jd=[];function Sm(e){const t=[...e.state.connections.values()];return e.state.status==="reconnecting"||mi(jd,t)?jd:(jd=t,t)}let Id=[];function Hb(e){const t=e.connectors;return Id.length===t.length&&Id.every((n,r)=>n===t[r])?Id:(Id=t,t)}function _P(e,t){const{chainId:n,...r}=t,s=e.getClient({chainId:n});return Wr(s,hx,"getEnsAvatar")(r)}function TP(e,t){const{chainId:n,...r}=t,s=e.getClient({chainId:n});return Wr(s,px,"getEnsName")(r)}function jm(e,t={}){const n=BP(e,t);return n==null?void 0:n.extend(CP)}let cp=!1;async function OP(e,t={}){var f,h;if(cp)return[];cp=!0,e.setState(p=>({...p,status:p.current?"reconnecting":"connecting"}));const n=[];if((f=t.connectors)!=null&&f.length)for(const p of t.connectors){let m;typeof p=="function"?m=e._internal.connectors.setup(p):m=p,n.push(m)}else n.push(...e.connectors);let r;try{r=await((h=e.storage)==null?void 0:h.getItem("recentConnectorId"))}catch{}const s={};for(const[,p]of e.state.connections)s[p.connector.id]=1;r&&(s[r]=0);const a=Object.keys(s).length>0?[...n].sort((p,m)=>(s[p.id]??10)-(s[m.id]??10)):n;let c=!1;const l=[],d=[];for(const p of a){const m=await p.getProvider().catch(()=>{});if(!m||d.some(w=>w===m)||!await p.isAuthorized())continue;const v=await p.connect({isReconnecting:!0}).catch(()=>null);v&&(p.emitter.off("connect",e._internal.events.connect),p.emitter.on("change",e._internal.events.change),p.emitter.on("disconnect",e._internal.events.disconnect),e.setState(w=>{const C=new Map(c?w.connections:new Map).set(p.uid,{accounts:v.accounts,chainId:v.chainId,connector:p});return{...w,current:c?w.current:p.uid,connections:C}}),l.push({accounts:v.accounts,chainId:v.chainId,connector:p}),d.push(m),c=!0)}return(e.state.status==="reconnecting"||e.state.status==="connecting")&&(c?e.setState(p=>({...p,status:"connected"})):e.setState(p=>({...p,connections:new Map,current:null,status:"disconnected"}))),cp=!1,l}async function RP(e,t){const{account:n,connector:r,...s}=t;let a;return typeof n=="object"&&n.type==="local"?a=e.getClient():a=await P3(e,{account:n,connector:r}),Wr(a,lP,"signMessage")({...s,...n?{account:n}:{}})}class Fn extends ko{constructor(){super("Provider not found."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderNotFoundError"})}}class MP extends ko{constructor({connector:t}){super(`"${t.name}" does not support programmatic chain switching.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SwitchChainNotSupportedError"})}}async function DP(e,t){var c;const{addEthereumChainParameter:n,chainId:r}=t,s=e.state.connections.get(((c=t.connector)==null?void 0:c.uid)??e.state.current);if(s){const l=s.connector;if(!l.switchChain)throw new MP({connector:l});return await l.switchChain({addEthereumChainParameter:n,chainId:r})}const a=e.chains.find(l=>l.id===r);if(!a)throw new ys;return e.setState(l=>({...l,chainId:r})),a}async function FP(e,t){const{chainId:n,timeout:r=0,...s}=t,a=e.getClient({chainId:n}),l=await Wr(a,A3,"waitForTransactionReceipt")({...s,timeout:r});if(l.status==="reverted"){const d=Wr(a,Uf,"getTransaction"),{from:f,...h}=await d({hash:l.transactionHash}),m=await Wr(a,Ha,"call")({...h,account:f,data:h.input,gasPrice:h.type!=="eip1559"?h.gasPrice:void 0,maxFeePerGas:h.type==="eip1559"?h.maxFeePerGas:void 0,maxPriorityFeePerGas:h.type==="eip1559"?h.maxPriorityFeePerGas:void 0}),y=m!=null&&m.data?c5(`0x${m.data.substring(138)}`):"unknown reason";throw new Error(y)}return{...l,chainId:a.chain.id}}function R3(e,t){const{onChange:n}=t;return e.subscribe(()=>_3(e),n,{equalityFn(r,s){const{connector:a,...c}=r,{connector:l,...d}=s;return mi(c,d)&&(a==null?void 0:a.id)===(l==null?void 0:l.id)&&(a==null?void 0:a.uid)===(l==null?void 0:l.uid)}})}function LP(e,t){const{onChange:n}=t;return e.subscribe(r=>r.chainId,n)}function UP(e,t){const{onChange:n}=t;return e.subscribe(()=>Sm(e),n,{equalityFn:mi})}function zP(e,t){const{onChange:n}=t;return e._internal.connectors.subscribe((r,s)=>{n(Object.values(r),s)})}function WP(e,t){const{onChange:n}=t;return e.subscribe(()=>jm(e),n,{equalityFn(r,s){return(r==null?void 0:r.uid)===(s==null?void 0:s.uid)}})}async function $P(e,t){const{account:n,chainId:r,connector:s,...a}=t;let c;return typeof n=="object"&&(n==null?void 0:n.type)==="local"?c=e.getClient({chainId:r}):c=await P3(e,{account:n??void 0,assertChainId:!1,chainId:r,connector:s}),await Wr(c,of,"writeContract")({...a,...n?{account:n}:{},chain:r?{id:r}:null})}qf.type="injected";function qf(e={}){const{shimDisconnect:t=!0,unstable_shimAsyncInject:n}=e;function r(){const d=e.target;if(typeof d=="function"){const f=d();if(f)return f}return typeof d=="object"?d:typeof d=="string"?{...qP[d]??{id:d,name:`${d[0].toUpperCase()}${d.slice(1)}`,provider:`is${d[0].toUpperCase()}${d.slice(1)}`}}:{id:"injected",name:"Injected",provider(f){return f==null?void 0:f.ethereum}}}let s,a,c,l;return d=>({get icon(){return r().icon},get id(){return r().id},get name(){return r().name},get supportsSimulation(){return!0},type:qf.type,async setup(){const f=await this.getProvider();f!=null&&f.on&&e.target&&(c||(c=this.onConnect.bind(this),f.on("connect",c)),s||(s=this.onAccountsChanged.bind(this),f.on("accountsChanged",s)))},async connect({chainId:f,isReconnecting:h,withCapabilities:p}={}){var v,w,C,A,I,S;const m=await this.getProvider();if(!m)throw new Fn;let y=[];if(h)y=await this.getAccounts().catch(()=>[]);else if(t)try{y=(A=(C=(w=(v=(await m.request({method:"wallet_requestPermissions",params:[{eth_accounts:{}}]}))[0])==null?void 0:v.caveats)==null?void 0:w[0])==null?void 0:C.value)==null?void 0:A.map(N=>jt(N)),y.length>0&&(y=await this.getAccounts())}catch(j){const N=j;if(N.code===Ge.code)throw new Ge(N);if(N.code===Ur.code)throw N}try{!(y!=null&&y.length)&&!h&&(y=(await m.request({method:"eth_requestAccounts"})).map(T=>jt(T))),c&&(m.removeListener("connect",c),c=void 0),s||(s=this.onAccountsChanged.bind(this),m.on("accountsChanged",s)),a||(a=this.onChainChanged.bind(this),m.on("chainChanged",a)),l||(l=this.onDisconnect.bind(this),m.on("disconnect",l));let j=await this.getChainId();if(f&&j!==f){const N=await this.switchChain({chainId:f}).catch(T=>{if(T.code===Ge.code)throw T;return{id:j}});j=(N==null?void 0:N.id)??j}return t&&await((I=d.storage)==null?void 0:I.removeItem(`${this.id}.disconnected`)),e.target||await((S=d.storage)==null?void 0:S.setItem("injected.connected",!0)),{accounts:p?y.map(N=>({address:N,capabilities:{}})):y,chainId:j}}catch(j){const N=j;throw N.code===Ge.code?new Ge(N):N.code===Ur.code?new Ur(N):N}},async disconnect(){var h,p;const f=await this.getProvider();if(!f)throw new Fn;a&&(f.removeListener("chainChanged",a),a=void 0),l&&(f.removeListener("disconnect",l),l=void 0),c||(c=this.onConnect.bind(this),f.on("connect",c));try{await Ff(()=>f.request({method:"wallet_revokePermissions",params:[{eth_accounts:{}}]}),{timeout:100})}catch{}t&&await((h=d.storage)==null?void 0:h.setItem(`${this.id}.disconnected`,!0)),e.target||await((p=d.storage)==null?void 0:p.removeItem("injected.connected"))},async getAccounts(){const f=await this.getProvider();if(!f)throw new Fn;return(await f.request({method:"eth_accounts"})).map(p=>jt(p))},async getChainId(){const f=await this.getProvider();if(!f)throw new Fn;const h=await f.request({method:"eth_chainId"});return Number(h)},async getProvider(){if(typeof window>"u")return;let f;const h=r();return typeof h.provider=="function"?f=h.provider(window):typeof h.provider=="string"?f=Vd(window,h.provider):f=h.provider,f&&!f.removeListener&&("off"in f&&typeof f.off=="function"?f.removeListener=f.off:f.removeListener=()=>{}),f},async isAuthorized(){var f,h;try{if(t&&await((f=d.storage)==null?void 0:f.getItem(`${this.id}.disconnected`))||!e.target&&!await((h=d.storage)==null?void 0:h.getItem("injected.connected")))return!1;if(!await this.getProvider()){if(n!==void 0&&n!==!1){const v=async()=>(typeof window<"u"&&window.removeEventListener("ethereum#initialized",v),!!await this.getProvider()),w=typeof n=="number"?n:1e3;if(await Promise.race([...typeof window<"u"?[new Promise(A=>window.addEventListener("ethereum#initialized",()=>A(v()),{once:!0}))]:[],new Promise(A=>setTimeout(()=>A(v()),w))]))return!0}throw new Fn}return!!(await Ma(()=>this.getAccounts())).length}catch{return!1}},async switchChain({addEthereumChainParameter:f,chainId:h}){var v,w,C,A;const p=await this.getProvider();if(!p)throw new Fn;const m=d.chains.find(I=>I.id===h);if(!m)throw new zn(new ys);const y=new Promise(I=>{const S=(j=>{"chainId"in j&&j.chainId===h&&(d.emitter.off("change",S),I())});d.emitter.on("change",S)});try{return await Promise.all([p.request({method:"wallet_switchEthereumChain",params:[{chainId:le(h)}]}).then(async()=>{await this.getChainId()===h&&d.emitter.emit("change",{chainId:h})}),y]),m}catch(I){const S=I;if(S.code===4902||((w=(v=S==null?void 0:S.data)==null?void 0:v.originalError)==null?void 0:w.code)===4902)try{const{default:j,...N}=m.blockExplorers??{};let T;f!=null&&f.blockExplorerUrls?T=f.blockExplorerUrls:j&&(T=[j.url,...Object.values(N).map(R=>R.url)]);let B;(C=f==null?void 0:f.rpcUrls)!=null&&C.length?B=f.rpcUrls:B=[((A=m.rpcUrls.default)==null?void 0:A.http[0])??""];const O={blockExplorerUrls:T,chainId:le(h),chainName:(f==null?void 0:f.chainName)??m.name,iconUrls:f==null?void 0:f.iconUrls,nativeCurrency:(f==null?void 0:f.nativeCurrency)??m.nativeCurrency,rpcUrls:B};return await Promise.all([p.request({method:"wallet_addEthereumChain",params:[O]}).then(async()=>{if(await this.getChainId()===h)d.emitter.emit("change",{chainId:h});else throw new Ge(new Error("User rejected switch after adding network."))}),y]),m}catch(j){throw new Ge(j)}throw S.code===Ge.code?new Ge(S):new zn(S)}},async onAccountsChanged(f){var h;if(f.length===0)this.onDisconnect();else if(d.emitter.listenerCount("connect")){const p=(await this.getChainId()).toString();this.onConnect({chainId:p}),t&&await((h=d.storage)==null?void 0:h.removeItem(`${this.id}.disconnected`))}else d.emitter.emit("change",{accounts:f.map(p=>jt(p))})},onChainChanged(f){const h=Number(f);d.emitter.emit("change",{chainId:h})},async onConnect(f){const h=await this.getAccounts();if(h.length===0)return;const p=Number(f.chainId);d.emitter.emit("connect",{accounts:h,chainId:p});const m=await this.getProvider();m&&(c&&(m.removeListener("connect",c),c=void 0),s||(s=this.onAccountsChanged.bind(this),m.on("accountsChanged",s)),a||(a=this.onChainChanged.bind(this),m.on("chainChanged",a)),l||(l=this.onDisconnect.bind(this),m.on("disconnect",l)))},async onDisconnect(f){const h=await this.getProvider();f&&f.code===1013&&h&&(await this.getAccounts()).length||(d.emitter.emit("disconnect"),h&&(a&&(h.removeListener("chainChanged",a),a=void 0),l&&(h.removeListener("disconnect",l),l=void 0),c||(c=this.onConnect.bind(this),h.on("connect",c))))}})}const qP={coinbaseWallet:{id:"coinbaseWallet",name:"Coinbase Wallet",provider(e){return e!=null&&e.coinbaseWalletExtension?e.coinbaseWalletExtension:Vd(e,"isCoinbaseWallet")}},metaMask:{id:"metaMask",name:"MetaMask",provider(e){return Vd(e,t=>{if(!t.isMetaMask||t.isBraveWallet&&!t._events&&!t._state)return!1;const n=["isApexWallet","isAvalanche","isBitKeep","isBlockWallet","isKuCoinWallet","isMathWallet","isOkxWallet","isOKExWallet","isOneInchIOSWallet","isOneInchAndroidWallet","isOpera","isPhantom","isPortal","isRabby","isTokenPocket","isTokenary","isUniswapWallet","isZerion"];for(const r of n)if(t[r])return!1;return!0})}},phantom:{id:"phantom",name:"Phantom",provider(e){var t,n;return(t=e==null?void 0:e.phantom)!=null&&t.ethereum?(n=e.phantom)==null?void 0:n.ethereum:Vd(e,"isPhantom")}}};function Vd(e,t){function n(s){return typeof t=="function"?t(s):typeof t=="string"?s[t]:!0}const r=e.ethereum;if(r!=null&&r.providers)return r.providers.find(s=>n(s));if(r&&n(r))return r}function HP(e){if(typeof window>"u")return;const t=n=>e(n.detail);return window.addEventListener("eip6963:announceProvider",t),window.dispatchEvent(new CustomEvent("eip6963:requestProvider")),()=>window.removeEventListener("eip6963:announceProvider",t)}function VP(){const e=new Set;let t=[];const n=()=>HP(s=>{t.some(({info:a})=>a.uuid===s.info.uuid)||(t=[...t,s],e.forEach(a=>a(t,{added:[s]})))});let r=n();return{_listeners(){return e},clear(){e.forEach(s=>s([],{removed:[...t]})),t=[]},destroy(){this.clear(),e.clear(),r==null||r()},findProvider({rdns:s}){return t.find(a=>a.info.rdns===s)},getProviders(){return t},reset(){this.clear(),r==null||r(),r=n()},subscribe(s,{emitImmediately:a}={}){return e.add(s),a&&s(t,{added:t}),()=>e.delete(s)}}}const QP=e=>(t,n,r)=>{const s=r.subscribe;return r.subscribe=(c,l,d)=>{let f=c;if(l){const h=(d==null?void 0:d.equalityFn)||Object.is;let p=c(r.getState());f=m=>{const y=c(m);if(!h(p,y)){const v=p;l(p=y,v)}},d!=null&&d.fireImmediately&&l(p,p)}return s(f)},e(t,n,r)},GP=QP;function KP(e,t){let n;try{n=e()}catch{return}return{getItem:s=>{var a;const c=d=>d===null?null:JSON.parse(d,void 0),l=(a=n.getItem(s))!=null?a:null;return l instanceof Promise?l.then(c):c(l)},setItem:(s,a)=>n.setItem(s,JSON.stringify(a,void 0)),removeItem:s=>n.removeItem(s)}}const Im=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(r){return Im(r)(n)},catch(r){return this}}}catch(n){return{then(r){return this},catch(r){return Im(r)(n)}}}},YP=(e,t)=>(n,r,s)=>{let a={storage:KP(()=>localStorage),partialize:w=>w,version:0,merge:(w,C)=>({...C,...w}),...t},c=!1;const l=new Set,d=new Set;let f=a.storage;if(!f)return e((...w)=>{console.warn(`[zustand persist middleware] Unable to update item '${a.name}', the given storage is currently unavailable.`),n(...w)},r,s);const h=()=>{const w=a.partialize({...r()});return f.setItem(a.name,{state:w,version:a.version})},p=s.setState;s.setState=(w,C)=>{p(w,C),h()};const m=e((...w)=>{n(...w),h()},r,s);s.getInitialState=()=>m;let y;const v=()=>{var w,C;if(!f)return;c=!1,l.forEach(I=>{var S;return I((S=r())!=null?S:m)});const A=((C=a.onRehydrateStorage)==null?void 0:C.call(a,(w=r())!=null?w:m))||void 0;return Im(f.getItem.bind(f))(a.name).then(I=>{if(I)if(typeof I.version=="number"&&I.version!==a.version){if(a.migrate)return[!0,a.migrate(I.state,I.version)];console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,I.state];return[!1,void 0]}).then(I=>{var S;const[j,N]=I;if(y=a.merge(N,(S=r())!=null?S:m),n(y,!0),j)return h()}).then(()=>{A==null||A(y,void 0),y=r(),c=!0,d.forEach(I=>I(y))}).catch(I=>{A==null||A(void 0,I)})};return s.persist={setOptions:w=>{a={...a,...w},w.storage&&(f=w.storage)},clearStorage:()=>{f==null||f.removeItem(a.name)},getOptions:()=>a,rehydrate:()=>v(),hasHydrated:()=>c,onHydrate:w=>(l.add(w),()=>{l.delete(w)}),onFinishHydration:w=>(d.add(w),()=>{d.delete(w)})},a.skipHydration||v(),y||m},JP=YP,Vb=e=>{let t;const n=new Set,r=(f,h)=>{const p=typeof f=="function"?f(t):f;if(!Object.is(p,t)){const m=t;t=h??(typeof p!="object"||p===null)?p:Object.assign({},t,p),n.forEach(y=>y(t,m))}},s=()=>t,l={setState:r,getState:s,getInitialState:()=>d,subscribe:f=>(n.add(f),()=>n.delete(f))},d=t=e(r,s,l);return l},lp=e=>e?Vb(e):Vb;var up={exports:{}},Qb;function ZP(){return Qb||(Qb=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function s(d,f,h){this.fn=d,this.context=f,this.once=h||!1}function a(d,f,h,p,m){if(typeof h!="function")throw new TypeError("The listener must be a function");var y=new s(h,p||d,m),v=n?n+f:f;return d._events[v]?d._events[v].fn?d._events[v]=[d._events[v],y]:d._events[v].push(y):(d._events[v]=y,d._eventsCount++),d}function c(d,f){--d._eventsCount===0?d._events=new r:delete d._events[f]}function l(){this._events=new r,this._eventsCount=0}l.prototype.eventNames=function(){var f=[],h,p;if(this._eventsCount===0)return f;for(p in h=this._events)t.call(h,p)&&f.push(n?p.slice(1):p);return Object.getOwnPropertySymbols?f.concat(Object.getOwnPropertySymbols(h)):f},l.prototype.listeners=function(f){var h=n?n+f:f,p=this._events[h];if(!p)return[];if(p.fn)return[p.fn];for(var m=0,y=p.length,v=new Array(y);m<y;m++)v[m]=p[m].fn;return v},l.prototype.listenerCount=function(f){var h=n?n+f:f,p=this._events[h];return p?p.fn?1:p.length:0},l.prototype.emit=function(f,h,p,m,y,v){var w=n?n+f:f;if(!this._events[w])return!1;var C=this._events[w],A=arguments.length,I,S;if(C.fn){switch(C.once&&this.removeListener(f,C.fn,void 0,!0),A){case 1:return C.fn.call(C.context),!0;case 2:return C.fn.call(C.context,h),!0;case 3:return C.fn.call(C.context,h,p),!0;case 4:return C.fn.call(C.context,h,p,m),!0;case 5:return C.fn.call(C.context,h,p,m,y),!0;case 6:return C.fn.call(C.context,h,p,m,y,v),!0}for(S=1,I=new Array(A-1);S<A;S++)I[S-1]=arguments[S];C.fn.apply(C.context,I)}else{var j=C.length,N;for(S=0;S<j;S++)switch(C[S].once&&this.removeListener(f,C[S].fn,void 0,!0),A){case 1:C[S].fn.call(C[S].context);break;case 2:C[S].fn.call(C[S].context,h);break;case 3:C[S].fn.call(C[S].context,h,p);break;case 4:C[S].fn.call(C[S].context,h,p,m);break;default:if(!I)for(N=1,I=new Array(A-1);N<A;N++)I[N-1]=arguments[N];C[S].fn.apply(C[S].context,I)}}return!0},l.prototype.on=function(f,h,p){return a(this,f,h,p,!1)},l.prototype.once=function(f,h,p){return a(this,f,h,p,!0)},l.prototype.removeListener=function(f,h,p,m){var y=n?n+f:f;if(!this._events[y])return this;if(!h)return c(this,y),this;var v=this._events[y];if(v.fn)v.fn===h&&(!m||v.once)&&(!p||v.context===p)&&c(this,y);else{for(var w=0,C=[],A=v.length;w<A;w++)(v[w].fn!==h||m&&!v[w].once||p&&v[w].context!==p)&&C.push(v[w]);C.length?this._events[y]=C.length===1?C[0]:C:c(this,y)}return this},l.prototype.removeAllListeners=function(f){var h;return f?(h=n?n+f:f,this._events[h]&&c(this,h)):(this._events=new r,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=n,l.EventEmitter=l,e.exports=l})(up)),up.exports}var XP=ZP();const eB=K2(XP);class tB{constructor(t){Object.defineProperty(this,"uid",{enumerable:!0,configurable:!0,writable:!0,value:t}),Object.defineProperty(this,"_emitter",{enumerable:!0,configurable:!0,writable:!0,value:new eB})}on(t,n){this._emitter.on(t,n)}once(t,n){this._emitter.once(t,n)}off(t,n){this._emitter.off(t,n)}emit(t,...n){const r=n[0];this._emitter.emit(t,{uid:this.uid,...r})}listenerCount(t){return this._emitter.listenerCount(t)}}function nB(e){return new tB(e)}function rB(e,t){return JSON.parse(e,(n,r)=>{let s=r;return(s==null?void 0:s.__type)==="bigint"&&(s=BigInt(s.value)),(s==null?void 0:s.__type)==="Map"&&(s=new Map(s.value)),(t==null?void 0:t(n,s))??s})}function Gb(e,t){return e.slice(0,t).join(".")||"."}function Kb(e,t){const{length:n}=e;for(let r=0;r<n;++r)if(e[r]===t)return r+1;return 0}function oB(e,t){const n=typeof e=="function",r=typeof t=="function",s=[],a=[];return function(l,d){if(typeof d=="object")if(s.length){const f=Kb(s,this);f===0?s[s.length]=this:(s.splice(f),a.splice(f)),a[a.length]=l;const h=Kb(s,d);if(h!==0)return r?t.call(this,l,d,Gb(a,h)):`[ref=${Gb(a,h)}]`}else s[0]=d,a[0]=l;return n?e.call(this,l,d):d}}function sB(e,t,n,r){return JSON.stringify(e,oB((s,a)=>{let c=a;return typeof c=="bigint"&&(c={__type:"bigint",value:a.toString()}),c instanceof Map&&(c={__type:"Map",value:Array.from(a.entries())}),(t==null?void 0:t(s,c))??c},r),n??void 0)}function iB(e){const{deserialize:t=rB,key:n="wagmi",serialize:r=sB,storage:s=M3}=e;function a(c){return c instanceof Promise?c.then(l=>l).catch(()=>null):c}return{...s,key:n,async getItem(c,l){const d=s.getItem(`${n}.${c}`),f=await a(d);return f?t(f)??null:l??null},async setItem(c,l){const d=`${n}.${c}`;l===null?await a(s.removeItem(d)):await a(s.setItem(d,r(l)))},async removeItem(c){await a(s.removeItem(`${n}.${c}`))}}}const M3={getItem:()=>null,setItem:()=>{},removeItem:()=>{}};function aB(){const e=typeof window<"u"&&window.localStorage?window.localStorage:M3;return{getItem(t){return e.getItem(t)},removeItem(t){e.removeItem(t)},setItem(t,n){try{e.setItem(t,n)}catch{}}}}const Nm=256;let Nd=Nm,Pd;function cB(e=11){if(!Pd||Nd+e>Nm*2){Pd="",Nd=0;for(let t=0;t<Nm;t++)Pd+=(256+Math.random()*256|0).toString(16).substring(1)}return Pd.substring(Nd,Nd+++e)}function lB(e){const{multiInjectedProviderDiscovery:t=!0,storage:n=iB({storage:aB()}),syncConnectedChain:r=!0,ssr:s=!1,...a}=e,c=typeof window<"u"&&t?VP():void 0,l=lp(()=>a.chains),d=lp(()=>{const N=[],T=new Set;for(const B of a.connectors??[]){const O=f(B);if(N.push(O),!s&&O.rdns){const R=typeof O.rdns=="string"?[O.rdns]:O.rdns;for(const W of R)T.add(W)}}if(!s&&c){const B=c.getProviders();for(const O of B)T.has(O.info.rdns)||N.push(f(h(O)))}return N});function f(N){var O;const T=nB(cB()),B={...N({emitter:T,chains:l.getState(),storage:n,transports:a.transports}),emitter:T,uid:T.uid};return T.on("connect",S),(O=B.setup)==null||O.call(B),B}function h(N){const{info:T}=N,B=N.provider;return qf({target:{...T,id:T.rdns,provider:B}})}const p=new Map;function m(N={}){const T=N.chainId??C.getState().chainId,B=l.getState().find(R=>R.id===T);if(N.chainId&&!B)throw new ys;{const R=p.get(C.getState().chainId);if(R&&!B)return R;if(!B)throw new ys}{const R=p.get(T);if(R)return R}let O;if(a.client)O=a.client({chain:B});else{const R=B.id,W=l.getState().map(Q=>Q.id),H={},K=Object.entries(a);for(const[Q,ae]of K)if(!(Q==="chains"||Q==="client"||Q==="connectors"||Q==="transports"))if(typeof ae=="object")if(R in ae)H[Q]=ae[R];else{if(W.some(ee=>ee in ae))continue;H[Q]=ae}else H[Q]=ae;O=N3({...H,chain:B,batch:H.batch??{multicall:!0},transport:Q=>a.transports[R]({...Q,connectors:d})})}return p.set(T,O),O}function y(){return{chainId:l.getState()[0].id,connections:new Map,current:null,status:"disconnected"}}let v;const w="0.0.0-canary-";qd.startsWith(w)?v=Number.parseInt(qd.replace(w,""),10):v=Number.parseInt(qd.split(".")[0]??"0",10);const C=lp(GP(n?JP(y,{migrate(N,T){if(T===v)return N;const B=y(),O=A(N,B.chainId);return{...B,chainId:O}},name:"store",partialize(N){return{connections:{__type:"Map",value:Array.from(N.connections.entries()).map(([T,B])=>{const{id:O,name:R,type:W,uid:H}=B.connector;return[T,{...B,connector:{id:O,name:R,type:W,uid:H}}]})},chainId:N.chainId,current:N.current}},merge(N,T){typeof N=="object"&&N&&"status"in N&&delete N.status;const B=A(N,T.chainId);return{...T,...N,chainId:B}},skipHydration:s,storage:n,version:v}):y));C.setState(y());function A(N,T){return N&&typeof N=="object"&&"chainId"in N&&typeof N.chainId=="number"&&l.getState().some(B=>B.id===N.chainId)?N.chainId:T}r&&C.subscribe(({connections:N,current:T})=>{var B;return T?(B=N.get(T))==null?void 0:B.chainId:void 0},N=>{if(l.getState().some(B=>B.id===N))return C.setState(B=>({...B,chainId:N??B.chainId}))}),c==null||c.subscribe(N=>{const T=new Set,B=new Set;for(const R of d.getState())if(T.add(R.id),R.rdns){const W=typeof R.rdns=="string"?[R.rdns]:R.rdns;for(const H of W)B.add(H)}const O=[];for(const R of N){if(B.has(R.info.rdns))continue;const W=f(h(R));T.has(W.id)||O.push(W)}n&&!C.persist.hasHydrated()||d.setState(R=>[...R,...O],!0)});function I(N){C.setState(T=>{const B=T.connections.get(N.uid);return B?{...T,connections:new Map(T.connections).set(N.uid,{accounts:N.accounts??B.accounts,chainId:N.chainId??B.chainId,connector:B.connector})}:T})}function S(N){C.getState().status==="connecting"||C.getState().status==="reconnecting"||C.setState(T=>{const B=d.getState().find(O=>O.uid===N.uid);return B?(B.emitter.listenerCount("connect")&&B.emitter.off("connect",I),B.emitter.listenerCount("change")||B.emitter.on("change",I),B.emitter.listenerCount("disconnect")||B.emitter.on("disconnect",j),{...T,connections:new Map(T.connections).set(N.uid,{accounts:N.accounts,chainId:N.chainId,connector:B}),current:N.uid,status:"connected"}):T})}function j(N){C.setState(T=>{const B=T.connections.get(N.uid);if(B){const R=B.connector;R.emitter.listenerCount("change")&&B.connector.emitter.off("change",I),R.emitter.listenerCount("disconnect")&&B.connector.emitter.off("disconnect",j),R.emitter.listenerCount("connect")||B.connector.emitter.on("connect",S)}if(T.connections.delete(N.uid),T.connections.size===0)return{...T,connections:new Map,current:null,status:"disconnected"};const O=T.connections.values().next().value;return{...T,connections:new Map(T.connections),current:O.connector.uid}})}return{get chains(){return l.getState()},get connectors(){return d.getState()},storage:n,getClient:m,get state(){return C.getState()},setState(N){let T;typeof N=="function"?T=N(C.getState()):T=N;const B=y();typeof T!="object"&&(T=B),Object.keys(B).some(R=>!(R in T))&&(T=B),C.setState(T,!0)},subscribe(N,T,B){return C.subscribe(N,T,B?{...B,fireImmediately:B.emitImmediately}:void 0)},_internal:{mipd:c,async revalidate(){const N=C.getState(),T=N.connections;let B=N.current;for(const[,O]of T){const R=O.connector;R.isAuthorized&&await R.isAuthorized()||(T.delete(R.uid),B===R.uid&&(B=null))}C.setState(O=>({...O,connections:T,current:B}))},store:C,ssr:!!s,syncConnectedChain:r,transports:a.transports,chains:{setState(N){const T=typeof N=="function"?N(l.getState()):N;if(T.length!==0)return l.setState(T,!0)},subscribe(N){return l.subscribe(N)}},connectors:{providerDetailToConnector:h,setup:f,setState(N){return d.setState(typeof N=="function"?N(d.getState()):N,!0)},subscribe(N){return d.subscribe(N)}},events:{change:I,connect:S,disconnect:j}}}}function uB(e,t){const{initialState:n,reconnectOnMount:r}=t;return n&&!e._internal.store.persist.hasHydrated()&&e.setState({...n,chainId:e.chains.some(s=>s.id===n.chainId)?n.chainId:e.chains[0].id,connections:r?n.connections:new Map,status:r?"reconnecting":"disconnected"}),{async onMount(){e._internal.ssr&&(await e._internal.store.persist.rehydrate(),e._internal.mipd&&e._internal.connectors.setState(s=>{var d;const a=new Set;for(const f of s??[])if(f.rdns){const h=Array.isArray(f.rdns)?f.rdns:[f.rdns];for(const p of h)a.add(p)}const c=[],l=((d=e._internal.mipd)==null?void 0:d.getProviders())??[];for(const f of l){if(a.has(f.info.rdns))continue;const h=e._internal.connectors.providerDetailToConnector(f),p=e._internal.connectors.setup(h);c.push(p)}return[...s,...c]})),r?OP(e):e.storage&&e.setState(s=>({...s,connections:new Map}))}}}function D3(e){var a,c,l;const{chain:t}=e,n=t.rpcUrls.default.http[0];if(!e.transports)return[n];const r=(c=(a=e.transports)==null?void 0:a[t.id])==null?void 0:c.call(a,{chain:t});return(((l=r==null?void 0:r.value)==null?void 0:l.transports)||[r]).map(({value:d})=>(d==null?void 0:d.url)||n)}function dB(e){const{children:t,config:n,initialState:r,reconnectOnMount:s=!0}=e,{onMount:a}=uB(n,{initialState:r,reconnectOnMount:s});n._internal.ssr||a();const c=P.useRef(!0);return P.useEffect(()=>{if(c.current&&n._internal.ssr)return a(),()=>{c.current=!1}},[]),t}const F3=P.createContext(void 0);function fB(e){const{children:t,config:n}=e,r={value:n};return P.createElement(dB,e,P.createElement(F3.Provider,r,t))}const hB="2.19.5",pB=()=>`wagmi@${hB}`;class mB extends ko{constructor(){super(...arguments),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WagmiError"})}get docsBaseUrl(){return"https://wagmi.sh/react"}get version(){return pB()}}class gB extends mB{constructor(){super("`useConfig` must be used within `WagmiProvider`.",{docsPath:"/api/WagmiProvider"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WagmiProviderNotFoundError"})}}function ut(e={}){const t=e.config??P.useContext(F3);if(!t)throw new gB;return t}function yB(e,t){const{onChange:n}=t;return e._internal.chains.subscribe((r,s)=>{n(r,s)})}var dp={exports:{}},fp={},hp={exports:{}},pp={};/**
86
- * @license React
87
- * use-sync-external-store-shim.production.js
88
- *
89
- * Copyright (c) Meta Platforms, Inc. and affiliates.
90
- *
91
- * This source code is licensed under the MIT license found in the
92
- * LICENSE file in the root directory of this source tree.
93
- */var Yb;function vB(){if(Yb)return pp;Yb=1;var e=zl();function t(p,m){return p===m&&(p!==0||1/p===1/m)||p!==p&&m!==m}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,s=e.useEffect,a=e.useLayoutEffect,c=e.useDebugValue;function l(p,m){var y=m(),v=r({inst:{value:y,getSnapshot:m}}),w=v[0].inst,C=v[1];return a(function(){w.value=y,w.getSnapshot=m,d(w)&&C({inst:w})},[p,y,m]),s(function(){return d(w)&&C({inst:w}),p(function(){d(w)&&C({inst:w})})},[p]),c(y),y}function d(p){var m=p.getSnapshot;p=p.value;try{var y=m();return!n(p,y)}catch{return!0}}function f(p,m){return m()}var h=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?f:l;return pp.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:h,pp}var Jb;function wB(){return Jb||(Jb=1,hp.exports=vB()),hp.exports}/**
94
- * @license React
95
- * use-sync-external-store-shim/with-selector.production.js
96
- *
97
- * Copyright (c) Meta Platforms, Inc. and affiliates.
98
- *
99
- * This source code is licensed under the MIT license found in the
100
- * LICENSE file in the root directory of this source tree.
101
- */var Zb;function bB(){if(Zb)return fp;Zb=1;var e=zl(),t=wB();function n(f,h){return f===h&&(f!==0||1/f===1/h)||f!==f&&h!==h}var r=typeof Object.is=="function"?Object.is:n,s=t.useSyncExternalStore,a=e.useRef,c=e.useEffect,l=e.useMemo,d=e.useDebugValue;return fp.useSyncExternalStoreWithSelector=function(f,h,p,m,y){var v=a(null);if(v.current===null){var w={hasValue:!1,value:null};v.current=w}else w=v.current;v=l(function(){function A(T){if(!I){if(I=!0,S=T,T=m(T),y!==void 0&&w.hasValue){var B=w.value;if(y(B,T))return j=B}return j=T}if(B=j,r(S,T))return B;var O=m(T);return y!==void 0&&y(B,O)?(S=T,B):(S=T,j=O)}var I=!1,S,j,N=p===void 0?null:p;return[function(){return A(h())},N===null?void 0:function(){return A(N())}]},[h,p,m,y]);var C=s(f,v[0],v[1]);return c(function(){w.hasValue=!0,w.value=C},[C]),d(C),C},fp}var Xb;function xB(){return Xb||(Xb=1,dp.exports=bB()),dp.exports}var L3=xB();const mp=e=>typeof e=="object"&&!Array.isArray(e);function CB(e,t,n=t,r=mi){const s=P.useRef([]),a=L3.useSyncExternalStoreWithSelector(e,t,n,c=>c,(c,l)=>{if(mp(c)&&mp(l)&&s.current.length){for(const d of s.current)if(!r(c[d],l[d]))return!1;return!0}return r(c,l)});return P.useMemo(()=>{if(mp(a)){const c={...a};let l={};for(const[d,f]of Object.entries(c))l={...l,[d]:{configurable:!1,enumerable:!0,get:()=>(s.current.includes(d)||s.current.push(d),f)}};return Object.defineProperties(c,l),c}return a},[a])}function it(e={}){const t=ut(e);return CB(n=>R3(t,{onChange:n}),()=>_3(t))}function U3(e={}){const{onConnect:t,onDisconnect:n}=e,r=ut(e);P.useEffect(()=>R3(r,{onChange(s,a){if((a.status==="reconnecting"||a.status==="connecting"&&a.address===void 0)&&s.status==="connected"){const{address:c,addresses:l,chain:d,chainId:f,connector:h}=s,p=a.status==="reconnecting"||a.status===void 0;t==null||t({address:c,addresses:l,chain:d,chainId:f,connector:h,isReconnected:p})}else a.status==="connected"&&s.status==="disconnected"&&(n==null||n())}}),[r,t,n])}var Va=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Ks,es,ya,F2,EB=(F2=class extends Va{constructor(){super();Ae(this,Ks);Ae(this,es);Ae(this,ya);he(this,ya,t=>{if(typeof window<"u"&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){L(this,es)||this.setEventListener(L(this,ya))}onUnsubscribe(){var t;this.hasListeners()||((t=L(this,es))==null||t.call(this),he(this,es,void 0))}setEventListener(t){var n;he(this,ya,t),(n=L(this,es))==null||n.call(this),he(this,es,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){L(this,Ks)!==t&&(he(this,Ks,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof L(this,Ks)=="boolean"?L(this,Ks):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Ks=new WeakMap,es=new WeakMap,ya=new WeakMap,F2),ig=new EB,AB={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},ts,u1,L2,kB=(L2=class{constructor(){Ae(this,ts,AB);Ae(this,u1,!1)}setTimeoutProvider(e){he(this,ts,e)}setTimeout(e,t){return L(this,ts).setTimeout(e,t)}clearTimeout(e){L(this,ts).clearTimeout(e)}setInterval(e,t){return L(this,ts).setInterval(e,t)}clearInterval(e){L(this,ts).clearInterval(e)}},ts=new WeakMap,u1=new WeakMap,L2),Qs=new kB;function SB(e){setTimeout(e,0)}var jB=typeof window>"u"||"Deno"in globalThis;function on(){}function IB(e,t){return typeof e=="function"?e(t):e}function Pm(e){return typeof e=="number"&&e>=0&&e!==1/0}function z3(e,t){return Math.max(e+(t||0)-Date.now(),0)}function us(e,t){return typeof e=="function"?e(t):e}function er(e,t){return typeof e=="function"?e(t):e}function e6(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:a,queryKey:c,stale:l}=e;if(c){if(r){if(t.queryHash!==ag(c,t.options))return!1}else if(!Cl(t.queryKey,c))return!1}if(n!=="all"){const d=t.isActive();if(n==="active"&&!d||n==="inactive"&&d)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||s&&s!==t.state.fetchStatus||a&&!a(t))}function t6(e,t){const{exact:n,status:r,predicate:s,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(n){if(gi(t.options.mutationKey)!==gi(a))return!1}else if(!Cl(t.options.mutationKey,a))return!1}return!(r&&t.state.status!==r||s&&!s(t))}function ag(e,t){return((t==null?void 0:t.queryKeyHashFn)||gi)(e)}function gi(e){return JSON.stringify(e,(t,n)=>Bm(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function Cl(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Cl(e[n],t[n])):!1}var NB=Object.prototype.hasOwnProperty;function cg(e,t,n=0){if(e===t)return e;if(n>500)return t;const r=n6(e)&&n6(t);if(!r&&!(Bm(e)&&Bm(t)))return t;const a=(r?e:Object.keys(e)).length,c=r?t:Object.keys(t),l=c.length,d=r?new Array(l):{};let f=0;for(let h=0;h<l;h++){const p=r?h:c[h],m=e[p],y=t[p];if(m===y){d[p]=m,(r?h<a:NB.call(e,p))&&f++;continue}if(m===null||y===null||typeof m!="object"||typeof y!="object"){d[p]=y;continue}const v=cg(m,y,n+1);d[p]=v,v===m&&f++}return a===l&&f===a?e:d}function af(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function n6(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Bm(e){if(!r6(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!r6(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function r6(e){return Object.prototype.toString.call(e)==="[object Object]"}function PB(e){return new Promise(t=>{Qs.setTimeout(t,e)})}function _m(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?cg(e,t):t}function BB(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function _B(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var lg=Symbol();function W3(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===lg?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function ug(e,t){return typeof e=="function"?e(...t):!!e}function TB(e,t,n){let r=!1,s;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(s??(s=t()),r||(r=!0,s.aborted?n():s.addEventListener("abort",n,{once:!0})),s)}),e}var El=(()=>{let e=()=>jB;return{isServer(){return e()},setIsServer(t){e=t}}})();function Tm(){let e,t;const n=new Promise((s,a)=>{e=s,t=a});n.status="pending",n.catch(()=>{});function r(s){Object.assign(n,s),delete n.resolve,delete n.reject}return n.resolve=s=>{r({status:"fulfilled",value:s}),e(s)},n.reject=s=>{r({status:"rejected",reason:s}),t(s)},n}var OB=SB;function RB(){let e=[],t=0,n=l=>{l()},r=l=>{l()},s=OB;const a=l=>{t?e.push(l):s(()=>{n(l)})},c=()=>{const l=e;e=[],l.length&&s(()=>{r(()=>{l.forEach(d=>{n(d)})})})};return{batch:l=>{let d;t++;try{d=l()}finally{t--,t||c()}return d},batchCalls:l=>(...d)=>{a(()=>{l(...d)})},schedule:a,setNotifyFunction:l=>{n=l},setBatchNotifyFunction:l=>{r=l},setScheduler:l=>{s=l}}}var St=RB(),va,ns,wa,U2,MB=(U2=class extends Va{constructor(){super();Ae(this,va,!0);Ae(this,ns);Ae(this,wa);he(this,wa,t=>{if(typeof window<"u"&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){L(this,ns)||this.setEventListener(L(this,wa))}onUnsubscribe(){var t;this.hasListeners()||((t=L(this,ns))==null||t.call(this),he(this,ns,void 0))}setEventListener(t){var n;he(this,wa,t),(n=L(this,ns))==null||n.call(this),he(this,ns,t(this.setOnline.bind(this)))}setOnline(t){L(this,va)!==t&&(he(this,va,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return L(this,va)}},va=new WeakMap,ns=new WeakMap,wa=new WeakMap,U2),cf=new MB;function DB(e){return Math.min(1e3*2**e,3e4)}function $3(e){return(e??"online")==="online"?cf.isOnline():!0}var Om=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function q3(e){let t=!1,n=0,r;const s=Tm(),a=()=>s.status!=="pending",c=w=>{var C;if(!a()){const A=new Om(w);m(A),(C=e.onCancel)==null||C.call(e,A)}},l=()=>{t=!0},d=()=>{t=!1},f=()=>ig.isFocused()&&(e.networkMode==="always"||cf.isOnline())&&e.canRun(),h=()=>$3(e.networkMode)&&e.canRun(),p=w=>{a()||(r==null||r(),s.resolve(w))},m=w=>{a()||(r==null||r(),s.reject(w))},y=()=>new Promise(w=>{var C;r=A=>{(a()||f())&&w(A)},(C=e.onPause)==null||C.call(e)}).then(()=>{var w;r=void 0,a()||(w=e.onContinue)==null||w.call(e)}),v=()=>{if(a())return;let w;const C=n===0?e.initialPromise:void 0;try{w=C??e.fn()}catch(A){w=Promise.reject(A)}Promise.resolve(w).then(p).catch(A=>{var T;if(a())return;const I=e.retry??(El.isServer()?0:3),S=e.retryDelay??DB,j=typeof S=="function"?S(n,A):S,N=I===!0||typeof I=="number"&&n<I||typeof I=="function"&&I(n,A);if(t||!N){m(A);return}n++,(T=e.onFail)==null||T.call(e,n,A),PB(j).then(()=>f()?void 0:y()).then(()=>{t?m(A):v()})})};return{promise:s,status:()=>s.status,cancel:c,continue:()=>(r==null||r(),s),cancelRetry:l,continueRetry:d,canStart:h,start:()=>(h()?v():y().then(v),s)}}var Ys,z2,H3=(z2=class{constructor(){Ae(this,Ys)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Pm(this.gcTime)&&he(this,Ys,Qs.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(El.isServer()?1/0:300*1e3))}clearGcTimeout(){L(this,Ys)!==void 0&&(Qs.clearTimeout(L(this,Ys)),he(this,Ys,void 0))}},Ys=new WeakMap,z2),Js,ba,Xn,Zs,_t,Ml,Xs,Dn,V3,uo,W2,FB=(W2=class extends H3{constructor(t){super();Ae(this,Dn);Ae(this,Js);Ae(this,ba);Ae(this,Xn);Ae(this,Zs);Ae(this,_t);Ae(this,Ml);Ae(this,Xs);he(this,Xs,!1),he(this,Ml,t.defaultOptions),this.setOptions(t.options),this.observers=[],he(this,Zs,t.client),he(this,Xn,L(this,Zs).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,he(this,Js,s6(this.options)),this.state=t.state??L(this,Js),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=L(this,_t))==null?void 0:t.promise}setOptions(t){if(this.options={...L(this,Ml),...t},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const n=s6(this.options);n.data!==void 0&&(this.setState(o6(n.data,n.dataUpdatedAt)),he(this,Js,n))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&L(this,Xn).remove(this)}setData(t,n){const r=_m(this.state.data,t,this.options);return Re(this,Dn,uo).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){Re(this,Dn,uo).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,s;const n=(r=L(this,_t))==null?void 0:r.promise;return(s=L(this,_t))==null||s.cancel(t),n?n.then(on).catch(on):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return L(this,Js)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(t=>er(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===lg||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>us(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!z3(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=L(this,_t))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=L(this,_t))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),L(this,Xn).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(L(this,_t)&&(L(this,Xs)||Re(this,Dn,V3).call(this)?L(this,_t).cancel({revert:!0}):L(this,_t).cancelRetry()),this.scheduleGc()),L(this,Xn).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Re(this,Dn,uo).call(this,{type:"invalidate"})}async fetch(t,n){var d,f,h,p,m,y,v,w,C,A,I,S;if(this.state.fetchStatus!=="idle"&&((d=L(this,_t))==null?void 0:d.status())!=="rejected"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(L(this,_t))return L(this,_t).continueRetry(),L(this,_t).promise}if(t&&this.setOptions(t),!this.options.queryFn){const j=this.observers.find(N=>N.options.queryFn);j&&this.setOptions(j.options)}const r=new AbortController,s=j=>{Object.defineProperty(j,"signal",{enumerable:!0,get:()=>(he(this,Xs,!0),r.signal)})},a=()=>{const j=W3(this.options,n),T=(()=>{const B={client:L(this,Zs),queryKey:this.queryKey,meta:this.meta};return s(B),B})();return he(this,Xs,!1),this.options.persister?this.options.persister(j,T,this):j(T)},l=(()=>{const j={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:L(this,Zs),state:this.state,fetchFn:a};return s(j),j})();(f=this.options.behavior)==null||f.onFetch(l,this),he(this,ba,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((h=l.fetchOptions)==null?void 0:h.meta))&&Re(this,Dn,uo).call(this,{type:"fetch",meta:(p=l.fetchOptions)==null?void 0:p.meta}),he(this,_t,q3({initialPromise:n==null?void 0:n.initialPromise,fn:l.fetchFn,onCancel:j=>{j instanceof Om&&j.revert&&this.setState({...L(this,ba),fetchStatus:"idle"}),r.abort()},onFail:(j,N)=>{Re(this,Dn,uo).call(this,{type:"failed",failureCount:j,error:N})},onPause:()=>{Re(this,Dn,uo).call(this,{type:"pause"})},onContinue:()=>{Re(this,Dn,uo).call(this,{type:"continue"})},retry:l.options.retry,retryDelay:l.options.retryDelay,networkMode:l.options.networkMode,canRun:()=>!0}));try{const j=await L(this,_t).start();if(j===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(j),(y=(m=L(this,Xn).config).onSuccess)==null||y.call(m,j,this),(w=(v=L(this,Xn).config).onSettled)==null||w.call(v,j,this.state.error,this),j}catch(j){if(j instanceof Om){if(j.silent)return L(this,_t).promise;if(j.revert){if(this.state.data===void 0)throw j;return this.state.data}}throw Re(this,Dn,uo).call(this,{type:"error",error:j}),(A=(C=L(this,Xn).config).onError)==null||A.call(C,j,this),(S=(I=L(this,Xn).config).onSettled)==null||S.call(I,this.state.data,j,this),j}finally{this.scheduleGc()}}},Js=new WeakMap,ba=new WeakMap,Xn=new WeakMap,Zs=new WeakMap,_t=new WeakMap,Ml=new WeakMap,Xs=new WeakMap,Dn=new WeakSet,V3=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},uo=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...Q3(r.data,this.options),fetchMeta:t.meta??null};case"success":const s={...r,...o6(t.data,t.dataUpdatedAt),dataUpdateCount:r.dataUpdateCount+1,...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return he(this,ba,t.manual?s:void 0),s;case"error":const a=t.error;return{...r,error:a,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:a,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),St.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),L(this,Xn).notify({query:this,type:"updated",action:t})})},W2);function Q3(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:$3(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function o6(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:"success"}}function s6(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var wn,$e,Dl,nn,ei,xa,ho,rs,Fl,Ca,Ea,ti,ni,os,Aa,Ke,Wc,Rm,Mm,Dm,Fm,Lm,Um,zm,G3,$2,LB=($2=class extends Va{constructor(t,n){super();Ae(this,Ke);Ae(this,wn);Ae(this,$e);Ae(this,Dl);Ae(this,nn);Ae(this,ei);Ae(this,xa);Ae(this,ho);Ae(this,rs);Ae(this,Fl);Ae(this,Ca);Ae(this,Ea);Ae(this,ti);Ae(this,ni);Ae(this,os);Ae(this,Aa,new Set);this.options=n,he(this,wn,t),he(this,rs,null),he(this,ho,Tm()),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(L(this,$e).addObserver(this),i6(L(this,$e),this.options)?Re(this,Ke,Wc).call(this):this.updateResult(),Re(this,Ke,Fm).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Wm(L(this,$e),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Wm(L(this,$e),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Re(this,Ke,Lm).call(this),Re(this,Ke,Um).call(this),L(this,$e).removeObserver(this)}setOptions(t){const n=this.options,r=L(this,$e);if(this.options=L(this,wn).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof er(this.options.enabled,L(this,$e))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Re(this,Ke,zm).call(this),L(this,$e).setOptions(this.options),n._defaulted&&!af(this.options,n)&&L(this,wn).getQueryCache().notify({type:"observerOptionsUpdated",query:L(this,$e),observer:this});const s=this.hasListeners();s&&a6(L(this,$e),r,this.options,n)&&Re(this,Ke,Wc).call(this),this.updateResult(),s&&(L(this,$e)!==r||er(this.options.enabled,L(this,$e))!==er(n.enabled,L(this,$e))||us(this.options.staleTime,L(this,$e))!==us(n.staleTime,L(this,$e)))&&Re(this,Ke,Rm).call(this);const a=Re(this,Ke,Mm).call(this);s&&(L(this,$e)!==r||er(this.options.enabled,L(this,$e))!==er(n.enabled,L(this,$e))||a!==L(this,os))&&Re(this,Ke,Dm).call(this,a)}getOptimisticResult(t){const n=L(this,wn).getQueryCache().build(L(this,wn),t),r=this.createResult(n,t);return zB(this,r)&&(he(this,nn,r),he(this,xa,this.options),he(this,ei,L(this,$e).state)),r}getCurrentResult(){return L(this,nn)}trackResult(t,n){return new Proxy(t,{get:(r,s)=>(this.trackProp(s),n==null||n(s),s==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&L(this,ho).status==="pending"&&L(this,ho).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(r,s))})}trackProp(t){L(this,Aa).add(t)}getCurrentQuery(){return L(this,$e)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=L(this,wn).defaultQueryOptions(t),r=L(this,wn).getQueryCache().build(L(this,wn),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return Re(this,Ke,Wc).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),L(this,nn)))}createResult(t,n){var R;const r=L(this,$e),s=this.options,a=L(this,nn),c=L(this,ei),l=L(this,xa),f=t!==r?t.state:L(this,Dl),{state:h}=t;let p={...h},m=!1,y;if(n._optimisticResults){const W=this.hasListeners(),H=!W&&i6(t,n),K=W&&a6(t,r,n,s);(H||K)&&(p={...p,...Q3(h.data,t.options)}),n._optimisticResults==="isRestoring"&&(p.fetchStatus="idle")}let{error:v,errorUpdatedAt:w,status:C}=p;y=p.data;let A=!1;if(n.placeholderData!==void 0&&y===void 0&&C==="pending"){let W;a!=null&&a.isPlaceholderData&&n.placeholderData===(l==null?void 0:l.placeholderData)?(W=a.data,A=!0):W=typeof n.placeholderData=="function"?n.placeholderData((R=L(this,Ea))==null?void 0:R.state.data,L(this,Ea)):n.placeholderData,W!==void 0&&(C="success",y=_m(a==null?void 0:a.data,W,n),m=!0)}if(n.select&&y!==void 0&&!A)if(a&&y===(c==null?void 0:c.data)&&n.select===L(this,Fl))y=L(this,Ca);else try{he(this,Fl,n.select),y=n.select(y),y=_m(a==null?void 0:a.data,y,n),he(this,Ca,y),he(this,rs,null)}catch(W){he(this,rs,W)}L(this,rs)&&(v=L(this,rs),y=L(this,Ca),w=Date.now(),C="error");const I=p.fetchStatus==="fetching",S=C==="pending",j=C==="error",N=S&&I,T=y!==void 0,O={status:C,fetchStatus:p.fetchStatus,isPending:S,isSuccess:C==="success",isError:j,isInitialLoading:N,isLoading:N,data:y,dataUpdatedAt:p.dataUpdatedAt,error:v,errorUpdatedAt:w,failureCount:p.fetchFailureCount,failureReason:p.fetchFailureReason,errorUpdateCount:p.errorUpdateCount,isFetched:t.isFetched(),isFetchedAfterMount:p.dataUpdateCount>f.dataUpdateCount||p.errorUpdateCount>f.errorUpdateCount,isFetching:I,isRefetching:I&&!S,isLoadingError:j&&!T,isPaused:p.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:j&&T,isStale:dg(t,n),refetch:this.refetch,promise:L(this,ho),isEnabled:er(n.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const W=O.data!==void 0,H=O.status==="error"&&!W,K=q=>{H?q.reject(O.error):W&&q.resolve(O.data)},Q=()=>{const q=he(this,ho,O.promise=Tm());K(q)},ae=L(this,ho);switch(ae.status){case"pending":t.queryHash===r.queryHash&&K(ae);break;case"fulfilled":(H||O.data!==ae.value)&&Q();break;case"rejected":(!H||O.error!==ae.reason)&&Q();break}}return O}updateResult(){const t=L(this,nn),n=this.createResult(L(this,$e),this.options);if(he(this,ei,L(this,$e).state),he(this,xa,this.options),L(this,ei).data!==void 0&&he(this,Ea,L(this,$e)),af(n,t))return;he(this,nn,n);const r=()=>{if(!t)return!0;const{notifyOnChangeProps:s}=this.options,a=typeof s=="function"?s():s;if(a==="all"||!a&&!L(this,Aa).size)return!0;const c=new Set(a??L(this,Aa));return this.options.throwOnError&&c.add("error"),Object.keys(L(this,nn)).some(l=>{const d=l;return L(this,nn)[d]!==t[d]&&c.has(d)})};Re(this,Ke,G3).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Re(this,Ke,Fm).call(this)}},wn=new WeakMap,$e=new WeakMap,Dl=new WeakMap,nn=new WeakMap,ei=new WeakMap,xa=new WeakMap,ho=new WeakMap,rs=new WeakMap,Fl=new WeakMap,Ca=new WeakMap,Ea=new WeakMap,ti=new WeakMap,ni=new WeakMap,os=new WeakMap,Aa=new WeakMap,Ke=new WeakSet,Wc=function(t){Re(this,Ke,zm).call(this);let n=L(this,$e).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(on)),n},Rm=function(){Re(this,Ke,Lm).call(this);const t=us(this.options.staleTime,L(this,$e));if(El.isServer()||L(this,nn).isStale||!Pm(t))return;const r=z3(L(this,nn).dataUpdatedAt,t)+1;he(this,ti,Qs.setTimeout(()=>{L(this,nn).isStale||this.updateResult()},r))},Mm=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(L(this,$e)):this.options.refetchInterval)??!1},Dm=function(t){Re(this,Ke,Um).call(this),he(this,os,t),!(El.isServer()||er(this.options.enabled,L(this,$e))===!1||!Pm(L(this,os))||L(this,os)===0)&&he(this,ni,Qs.setInterval(()=>{(this.options.refetchIntervalInBackground||ig.isFocused())&&Re(this,Ke,Wc).call(this)},L(this,os)))},Fm=function(){Re(this,Ke,Rm).call(this),Re(this,Ke,Dm).call(this,Re(this,Ke,Mm).call(this))},Lm=function(){L(this,ti)!==void 0&&(Qs.clearTimeout(L(this,ti)),he(this,ti,void 0))},Um=function(){L(this,ni)!==void 0&&(Qs.clearInterval(L(this,ni)),he(this,ni,void 0))},zm=function(){const t=L(this,wn).getQueryCache().build(L(this,wn),this.options);if(t===L(this,$e))return;const n=L(this,$e);he(this,$e,t),he(this,Dl,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},G3=function(t){St.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(L(this,nn))}),L(this,wn).getQueryCache().notify({query:L(this,$e),type:"observerResultsUpdated"})})},$2);function UB(e,t){return er(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function i6(e,t){return UB(e,t)||e.state.data!==void 0&&Wm(e,t,t.refetchOnMount)}function Wm(e,t,n){if(er(t.enabled,e)!==!1&&us(t.staleTime,e)!=="static"){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&dg(e,t)}return!1}function a6(e,t,n,r){return(e!==t||er(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&dg(e,n)}function dg(e,t){return er(t.enabled,e)!==!1&&e.isStaleByTime(us(t.staleTime,e))}function zB(e,t){return!af(e.getCurrentResult(),t)}function c6(e){return{onFetch:(t,n)=>{var h,p,m,y,v;const r=t.options,s=(m=(p=(h=t.fetchOptions)==null?void 0:h.meta)==null?void 0:p.fetchMore)==null?void 0:m.direction,a=((y=t.state.data)==null?void 0:y.pages)||[],c=((v=t.state.data)==null?void 0:v.pageParams)||[];let l={pages:[],pageParams:[]},d=0;const f=async()=>{let w=!1;const C=S=>{TB(S,()=>t.signal,()=>w=!0)},A=W3(t.options,t.fetchOptions),I=async(S,j,N)=>{if(w)return Promise.reject();if(j==null&&S.pages.length)return Promise.resolve(S);const B=(()=>{const H={client:t.client,queryKey:t.queryKey,pageParam:j,direction:N?"backward":"forward",meta:t.options.meta};return C(H),H})(),O=await A(B),{maxPages:R}=t.options,W=N?_B:BB;return{pages:W(S.pages,O,R),pageParams:W(S.pageParams,j,R)}};if(s&&a.length){const S=s==="backward",j=S?WB:l6,N={pages:a,pageParams:c},T=j(r,N);l=await I(N,T,S)}else{const S=e??a.length;do{const j=d===0?c[0]??r.initialPageParam:l6(r,l);if(d>0&&j==null)break;l=await I(l,j),d++}while(d<S)}return l};t.options.persister?t.fetchFn=()=>{var w,C;return(C=(w=t.options).persister)==null?void 0:C.call(w,f,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=f}}}function l6(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function WB(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var Ll,Mr,Yt,ri,Dr,Xo,q2,$B=(q2=class extends H3{constructor(t){super();Ae(this,Dr);Ae(this,Ll);Ae(this,Mr);Ae(this,Yt);Ae(this,ri);he(this,Ll,t.client),this.mutationId=t.mutationId,he(this,Yt,t.mutationCache),he(this,Mr,[]),this.state=t.state||K3(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){L(this,Mr).includes(t)||(L(this,Mr).push(t),this.clearGcTimeout(),L(this,Yt).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){he(this,Mr,L(this,Mr).filter(n=>n!==t)),this.scheduleGc(),L(this,Yt).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){L(this,Mr).length||(this.state.status==="pending"?this.scheduleGc():L(this,Yt).remove(this))}continue(){var t;return((t=L(this,ri))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var c,l,d,f,h,p,m,y,v,w,C,A,I,S,j,N,T,B;const n=()=>{Re(this,Dr,Xo).call(this,{type:"continue"})},r={client:L(this,Ll),meta:this.options.meta,mutationKey:this.options.mutationKey};he(this,ri,q3({fn:()=>this.options.mutationFn?this.options.mutationFn(t,r):Promise.reject(new Error("No mutationFn found")),onFail:(O,R)=>{Re(this,Dr,Xo).call(this,{type:"failed",failureCount:O,error:R})},onPause:()=>{Re(this,Dr,Xo).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>L(this,Yt).canRun(this)}));const s=this.state.status==="pending",a=!L(this,ri).canStart();try{if(s)n();else{Re(this,Dr,Xo).call(this,{type:"pending",variables:t,isPaused:a}),L(this,Yt).config.onMutate&&await L(this,Yt).config.onMutate(t,this,r);const R=await((l=(c=this.options).onMutate)==null?void 0:l.call(c,t,r));R!==this.state.context&&Re(this,Dr,Xo).call(this,{type:"pending",context:R,variables:t,isPaused:a})}const O=await L(this,ri).start();return await((f=(d=L(this,Yt).config).onSuccess)==null?void 0:f.call(d,O,t,this.state.context,this,r)),await((p=(h=this.options).onSuccess)==null?void 0:p.call(h,O,t,this.state.context,r)),await((y=(m=L(this,Yt).config).onSettled)==null?void 0:y.call(m,O,null,this.state.variables,this.state.context,this,r)),await((w=(v=this.options).onSettled)==null?void 0:w.call(v,O,null,t,this.state.context,r)),Re(this,Dr,Xo).call(this,{type:"success",data:O}),O}catch(O){try{await((A=(C=L(this,Yt).config).onError)==null?void 0:A.call(C,O,t,this.state.context,this,r))}catch(R){Promise.reject(R)}try{await((S=(I=this.options).onError)==null?void 0:S.call(I,O,t,this.state.context,r))}catch(R){Promise.reject(R)}try{await((N=(j=L(this,Yt).config).onSettled)==null?void 0:N.call(j,void 0,O,this.state.variables,this.state.context,this,r))}catch(R){Promise.reject(R)}try{await((B=(T=this.options).onSettled)==null?void 0:B.call(T,void 0,O,t,this.state.context,r))}catch(R){Promise.reject(R)}throw Re(this,Dr,Xo).call(this,{type:"error",error:O}),O}finally{L(this,Yt).runNext(this)}}},Ll=new WeakMap,Mr=new WeakMap,Yt=new WeakMap,ri=new WeakMap,Dr=new WeakSet,Xo=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),St.batch(()=>{L(this,Mr).forEach(r=>{r.onMutationUpdate(t)}),L(this,Yt).notify({mutation:this,type:"updated",action:t})})},q2);function K3(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var po,gr,Ul,H2,qB=(H2=class extends Va{constructor(t={}){super();Ae(this,po);Ae(this,gr);Ae(this,Ul);this.config=t,he(this,po,new Set),he(this,gr,new Map),he(this,Ul,0)}build(t,n,r){const s=new $B({client:t,mutationCache:this,mutationId:++vd(this,Ul)._,options:t.defaultMutationOptions(n),state:r});return this.add(s),s}add(t){L(this,po).add(t);const n=Bd(t);if(typeof n=="string"){const r=L(this,gr).get(n);r?r.push(t):L(this,gr).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(L(this,po).delete(t)){const n=Bd(t);if(typeof n=="string"){const r=L(this,gr).get(n);if(r)if(r.length>1){const s=r.indexOf(t);s!==-1&&r.splice(s,1)}else r[0]===t&&L(this,gr).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=Bd(t);if(typeof n=="string"){const r=L(this,gr).get(n),s=r==null?void 0:r.find(a=>a.state.status==="pending");return!s||s===t}else return!0}runNext(t){var r;const n=Bd(t);if(typeof n=="string"){const s=(r=L(this,gr).get(n))==null?void 0:r.find(a=>a!==t&&a.state.isPaused);return(s==null?void 0:s.continue())??Promise.resolve()}else return Promise.resolve()}clear(){St.batch(()=>{L(this,po).forEach(t=>{this.notify({type:"removed",mutation:t})}),L(this,po).clear(),L(this,gr).clear()})}getAll(){return Array.from(L(this,po))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>t6(n,r))}findAll(t={}){return this.getAll().filter(n=>t6(t,n))}notify(t){St.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return St.batch(()=>Promise.all(t.map(n=>n.continue().catch(on))))}},po=new WeakMap,gr=new WeakMap,Ul=new WeakMap,H2);function Bd(e){var t;return(t=e.options.scope)==null?void 0:t.id}var mo,ss,bn,go,xo,Qd,$m,V2,HB=(V2=class extends Va{constructor(n,r){super();Ae(this,xo);Ae(this,mo);Ae(this,ss);Ae(this,bn);Ae(this,go);he(this,mo,n),this.setOptions(r),this.bindMethods(),Re(this,xo,Qd).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(n){var s;const r=this.options;this.options=L(this,mo).defaultMutationOptions(n),af(this.options,r)||L(this,mo).getMutationCache().notify({type:"observerOptionsUpdated",mutation:L(this,bn),observer:this}),r!=null&&r.mutationKey&&this.options.mutationKey&&gi(r.mutationKey)!==gi(this.options.mutationKey)?this.reset():((s=L(this,bn))==null?void 0:s.state.status)==="pending"&&L(this,bn).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=L(this,bn))==null||n.removeObserver(this)}onMutationUpdate(n){Re(this,xo,Qd).call(this),Re(this,xo,$m).call(this,n)}getCurrentResult(){return L(this,ss)}reset(){var n;(n=L(this,bn))==null||n.removeObserver(this),he(this,bn,void 0),Re(this,xo,Qd).call(this),Re(this,xo,$m).call(this)}mutate(n,r){var s;return he(this,go,r),(s=L(this,bn))==null||s.removeObserver(this),he(this,bn,L(this,mo).getMutationCache().build(L(this,mo),this.options)),L(this,bn).addObserver(this),L(this,bn).execute(n)}},mo=new WeakMap,ss=new WeakMap,bn=new WeakMap,go=new WeakMap,xo=new WeakSet,Qd=function(){var r;const n=((r=L(this,bn))==null?void 0:r.state)??K3();he(this,ss,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},$m=function(n){St.batch(()=>{var r,s,a,c,l,d,f,h;if(L(this,go)&&this.hasListeners()){const p=L(this,ss).variables,m=L(this,ss).context,y={client:L(this,mo),meta:this.options.meta,mutationKey:this.options.mutationKey};if((n==null?void 0:n.type)==="success"){try{(s=(r=L(this,go)).onSuccess)==null||s.call(r,n.data,p,m,y)}catch(v){Promise.reject(v)}try{(c=(a=L(this,go)).onSettled)==null||c.call(a,n.data,null,p,m,y)}catch(v){Promise.reject(v)}}else if((n==null?void 0:n.type)==="error"){try{(d=(l=L(this,go)).onError)==null||d.call(l,n.error,p,m,y)}catch(v){Promise.reject(v)}try{(h=(f=L(this,go)).onSettled)==null||h.call(f,void 0,n.error,p,m,y)}catch(v){Promise.reject(v)}}}this.listeners.forEach(p=>{p(L(this,ss))})})},V2),Fr,Q2,VB=(Q2=class extends Va{constructor(t={}){super();Ae(this,Fr);this.config=t,he(this,Fr,new Map)}build(t,n,r){const s=n.queryKey,a=n.queryHash??ag(s,n);let c=this.get(a);return c||(c=new FB({client:t,queryKey:s,queryHash:a,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(s)}),this.add(c)),c}add(t){L(this,Fr).has(t.queryHash)||(L(this,Fr).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=L(this,Fr).get(t.queryHash);n&&(t.destroy(),n===t&&L(this,Fr).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){St.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return L(this,Fr).get(t)}getAll(){return[...L(this,Fr).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>e6(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>e6(t,r)):n}notify(t){St.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){St.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){St.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},Fr=new WeakMap,Q2),lt,is,as,ka,Sa,cs,ja,Ia,G2,QB=(G2=class{constructor(e={}){Ae(this,lt);Ae(this,is);Ae(this,as);Ae(this,ka);Ae(this,Sa);Ae(this,cs);Ae(this,ja);Ae(this,Ia);he(this,lt,e.queryCache||new VB),he(this,is,e.mutationCache||new qB),he(this,as,e.defaultOptions||{}),he(this,ka,new Map),he(this,Sa,new Map),he(this,cs,0)}mount(){vd(this,cs)._++,L(this,cs)===1&&(he(this,ja,ig.subscribe(async e=>{e&&(await this.resumePausedMutations(),L(this,lt).onFocus())})),he(this,Ia,cf.subscribe(async e=>{e&&(await this.resumePausedMutations(),L(this,lt).onOnline())})))}unmount(){var e,t;vd(this,cs)._--,L(this,cs)===0&&((e=L(this,ja))==null||e.call(this),he(this,ja,void 0),(t=L(this,Ia))==null||t.call(this),he(this,Ia,void 0))}isFetching(e){return L(this,lt).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return L(this,is).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=L(this,lt).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=L(this,lt).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(us(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return L(this,lt).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),s=L(this,lt).get(r.queryHash),a=s==null?void 0:s.state.data,c=IB(t,a);if(c!==void 0)return L(this,lt).build(this,r).setData(c,{...n,manual:!0})}setQueriesData(e,t,n){return St.batch(()=>L(this,lt).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=L(this,lt).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=L(this,lt);St.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=L(this,lt);return St.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=St.batch(()=>L(this,lt).findAll(e).map(s=>s.cancel(n)));return Promise.all(r).then(on).catch(on)}invalidateQueries(e,t={}){return St.batch(()=>(L(this,lt).findAll(e).forEach(n=>{n.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=St.batch(()=>L(this,lt).findAll(e).filter(s=>!s.isDisabled()&&!s.isStatic()).map(s=>{let a=s.fetch(void 0,n);return n.throwOnError||(a=a.catch(on)),s.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(r).then(on)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=L(this,lt).build(this,t);return n.isStaleByTime(us(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(on).catch(on)}fetchInfiniteQuery(e){return e.behavior=c6(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(on).catch(on)}ensureInfiniteQueryData(e){return e.behavior=c6(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return cf.isOnline()?L(this,is).resumePausedMutations():Promise.resolve()}getQueryCache(){return L(this,lt)}getMutationCache(){return L(this,is)}getDefaultOptions(){return L(this,as)}setDefaultOptions(e){he(this,as,e)}setQueryDefaults(e,t){L(this,ka).set(gi(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...L(this,ka).values()],n={};return t.forEach(r=>{Cl(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){L(this,Sa).set(gi(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...L(this,Sa).values()],n={};return t.forEach(r=>{Cl(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...L(this,as).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=ag(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===lg&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...L(this,as).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){L(this,lt).clear(),L(this,is).clear()}},lt=new WeakMap,is=new WeakMap,as=new WeakMap,ka=new WeakMap,Sa=new WeakMap,cs=new WeakMap,ja=new WeakMap,Ia=new WeakMap,G2);function Y3(e,t){return cg(e,t)}function GB(e){return JSON.stringify(e,(t,n)=>KB(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):typeof n=="bigint"?n.toString():n)}function KB(e){if(!u6(e))return!1;const t=e.constructor;if(typeof t>"u")return!0;const n=t.prototype;return!(!u6(n)||!n.hasOwnProperty("isPrototypeOf"))}function u6(e){return Object.prototype.toString.call(e)==="[object Object]"}function Qa(e){const{_defaulted:t,behavior:n,gcTime:r,initialData:s,initialDataUpdatedAt:a,maxPages:c,meta:l,networkMode:d,queryFn:f,queryHash:h,queryKey:p,queryKeyHashFn:m,retry:y,retryDelay:v,structuralSharing:w,getPreviousPageParam:C,getNextPageParam:A,initialPageParam:I,_optimisticResults:S,enabled:j,notifyOnChangeProps:N,placeholderData:T,refetchInterval:B,refetchIntervalInBackground:O,refetchOnMount:R,refetchOnReconnect:W,refetchOnWindowFocus:H,retryOnMount:K,select:Q,staleTime:ae,suspense:q,throwOnError:ee,config:te,connector:U,query:Y,...Z}=e;return Z}function YB(e){return{mutationFn(t){return gP(e,t)},mutationKey:["connect"]}}function JB(e){return{mutationFn(t){return IP(e,t)},mutationKey:["disconnect"]}}function ZB(e,t={}){return{async queryFn({queryKey:n}){const{address:r,scopeKey:s,...a}=n[1];if(!r)throw new Error("address is required");return await PP(e,{...a,address:r})??null},queryKey:XB(t)}}function XB(e={}){return["balance",Qa(e)]}function e_(e,t={}){return{async queryFn({queryKey:n}){const{name:r,scopeKey:s,...a}=n[1];if(!r)throw new Error("name is required");return _P(e,{...a,name:r})},queryKey:t_(t)}}function t_(e={}){return["ensAvatar",Qa(e)]}function n_(e,t={}){return{async queryFn({queryKey:n}){const{address:r,scopeKey:s,...a}=n[1];if(!r)throw new Error("address is required");return TP(e,{...a,address:r})},queryKey:r_(t)}}function r_(e={}){return["ensName",Qa(e)]}function o_(e,t={}){return{async queryFn({queryKey:n}){const r=t.abi;if(!r)throw new Error("abi is required");const{functionName:s,scopeKey:a,...c}=n[1],l=(()=>{const d=n[1];if(d.address)return{address:d.address};if(d.code)return{code:d.code};throw new Error("address or code is required")})();if(!s)throw new Error("functionName is required");return T3(e,{abi:r,functionName:s,args:c.args,...l,...c})},queryKey:s_(t)}}function s_(e={}){const{abi:t,...n}=e;return["readContract",Qa(n)]}function i_(e,t={}){return{async queryFn({queryKey:n}){var l;const r=[],s=n[1].contracts.length;for(let d=0;d<s;d++){const f=n[1].contracts[d],h=((l=t.contracts)==null?void 0:l[d]).abi;r.push({...f,abi:h})}const{scopeKey:a,...c}=n[1];return O3(e,{...c,contracts:r})},queryKey:a_(t)}}function a_(e={}){const t=[];for(const n of e.contracts??[]){const{abi:r,...s}=n;t.push({...s,chainId:s.chainId??e.chainId})}return["readContracts",Qa({...e,contracts:t})]}function c_(e){return{mutationFn(t){return RP(e,t)},mutationKey:["signMessage"]}}function l_(e){return{mutationFn(t){return DP(e,t)},mutationKey:["switchChain"]}}function u_(e,t={}){return{async queryFn({queryKey:n}){const{hash:r,...s}=n[1];if(!r)throw new Error("hash is required");return FP(e,{...s,onReplaced:t.onReplaced,hash:r})},queryKey:d_(t)}}function d_(e={}){const{onReplaced:t,...n}=e;return["waitForTransactionReceipt",Qa(n)]}function f_(e){return{mutationFn(t){return $P(e,t)},mutationKey:["writeContract"]}}var J3=P.createContext(void 0),Z3=e=>{const t=P.useContext(J3);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},h_=({client:e,children:t})=>(P.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),b.jsx(J3.Provider,{value:e,children:t})),X3=P.createContext(!1),p_=()=>P.useContext(X3);X3.Provider;function m_(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var g_=P.createContext(m_()),y_=()=>P.useContext(g_),v_=(e,t,n)=>{const r=n!=null&&n.state.error&&typeof e.throwOnError=="function"?ug(e.throwOnError,[n.state.error,n]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||r)&&(t.isReset()||(e.retryOnMount=!1))},w_=e=>{P.useEffect(()=>{e.clearReset()},[e])},b_=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:s})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(s&&e.data===void 0||ug(n,[e.error,r])),x_=e=>{if(e.suspense){const n=s=>s==="static"?s:Math.max(s??1e3,1e3),r=e.staleTime;e.staleTime=typeof r=="function"?(...s)=>n(r(...s)):n(r),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},C_=(e,t)=>e.isLoading&&e.isFetching&&!t,E_=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,d6=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function A_(e,t,n){var m,y,v,w;const r=p_(),s=y_(),a=Z3(),c=a.defaultQueryOptions(e);(y=(m=a.getDefaultOptions().queries)==null?void 0:m._experimental_beforeQuery)==null||y.call(m,c);const l=a.getQueryCache().get(c.queryHash);c._optimisticResults=r?"isRestoring":"optimistic",x_(c),v_(c,s,l),w_(s);const d=!a.getQueryCache().get(c.queryHash),[f]=P.useState(()=>new t(a,c)),h=f.getOptimisticResult(c),p=!r&&e.subscribed!==!1;if(P.useSyncExternalStore(P.useCallback(C=>{const A=p?f.subscribe(St.batchCalls(C)):on;return f.updateResult(),A},[f,p]),()=>f.getCurrentResult(),()=>f.getCurrentResult()),P.useEffect(()=>{f.setOptions(c)},[c,f]),E_(c,h))throw d6(c,f,s);if(b_({result:h,errorResetBoundary:s,throwOnError:c.throwOnError,query:l,suspense:c.suspense}))throw h.error;if((w=(v=a.getDefaultOptions().queries)==null?void 0:v._experimental_afterQuery)==null||w.call(v,c,h),c.experimental_prefetchInRender&&!El.isServer()&&C_(h,r)){const C=d?d6(c,f,s):l==null?void 0:l.promise;C==null||C.catch(on).finally(()=>{f.updateResult()})}return c.notifyOnChangeProps?h:f.trackResult(h)}function eC(e,t){return A_(e,LB)}function ru(e,t){const n=Z3(),[r]=P.useState(()=>new HB(n,e));P.useEffect(()=>{r.setOptions(e)},[r,e]);const s=P.useSyncExternalStore(P.useCallback(c=>r.subscribe(St.batchCalls(c)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),a=P.useCallback((c,l)=>{r.mutate(c,l).catch(on)},[r]);if(s.error&&ug(r.options.throwOnError,[s.error]))throw s.error;return{...s,mutate:a,mutateAsync:s.mutate}}function Ga(e){const t=eC({...e,queryKeyHashFn:GB});return t.queryKey=e.queryKey,t}function Ci(e={}){const t=ut(e);return P.useSyncExternalStore(n=>LP(t,{onChange:n}),()=>$b(t),()=>$b(t))}function tC(e={}){const{address:t,query:n={}}=e,r=ut(e),s=Ci({config:r}),a=ZB(r,{...e,chainId:e.chainId??s}),c=!!(t&&(n.enabled??!0));return Ga({...n,...a,enabled:c})}function k_(e={}){const t=ut(e);return P.useSyncExternalStore(n=>yB(t,{onChange:n}),()=>qb(t),()=>qb(t))}function S_(e={}){const t=ut(e);return P.useSyncExternalStore(n=>zP(t,{onChange:n}),()=>Hb(t),()=>Hb(t))}function j_(e={}){const{mutation:t}=e,n=ut(e),r=YB(n),{mutate:s,mutateAsync:a,...c}=ru({...t,...r});return P.useEffect(()=>n.subscribe(({status:l})=>l,(l,d)=>{d==="connected"&&l==="disconnected"&&c.reset()}),[n,c.reset]),{...c,connect:s,connectAsync:a,connectors:S_({config:n})}}function I_(e={}){const t=ut(e);return P.useSyncExternalStore(n=>UP(t,{onChange:n}),()=>Sm(t),()=>Sm(t))}function ou(e={}){const{mutation:t}=e,n=ut(e),r=JB(n),{mutate:s,mutateAsync:a,...c}=ru({...t,...r});return{...c,connectors:I_({config:n}).map(l=>l.connector),disconnect:s,disconnectAsync:a}}function N_(e={}){const{name:t,query:n={}}=e,r=ut(e),s=Ci({config:r}),a=e_(r,{...e,chainId:e.chainId??s}),c=!!(t&&(n.enabled??!0));return Ga({...n,...a,enabled:c})}function P_(e={}){const{address:t,query:n={}}=e,r=ut(e),s=Ci({config:r}),a=n_(r,{...e,chainId:e.chainId??s}),c=!!(t&&(n.enabled??!0));return Ga({...n,...a,enabled:c})}function nC(e={}){const t=ut(e);return L3.useSyncExternalStoreWithSelector(n=>WP(t,{onChange:n}),()=>jm(t,e),()=>jm(t,e),n=>n,(n,r)=>(n==null?void 0:n.uid)===(r==null?void 0:r.uid))}function f6(e={}){const{abi:t,address:n,functionName:r,query:s={}}=e,a=e.code,c=ut(e),l=Ci({config:c}),d=o_(c,{...e,chainId:e.chainId??l}),f=!!((n||a)&&t&&r&&(s.enabled??!0));return Ga({...s,...d,enabled:f,structuralSharing:s.structuralSharing??Y3})}function B_(e={}){const{contracts:t=[],query:n={}}=e,r=ut(e),s=Ci({config:r}),a=P.useMemo(()=>{if(t.length===0)return;const d=t[0].chainId;if(t.every(f=>f.chainId===d))return d},[t]),c=i_(r,{...e,chainId:a??s}),l=P.useMemo(()=>{let d=!1;for(const f of t){const{abi:h,address:p,functionName:m}=f;if(!h||!p||!m){d=!1;break}d=!0}return!!(d&&(n.enabled??!0))},[t,n.enabled]);return Ga({...c,...n,enabled:l,structuralSharing:n.structuralSharing??Y3})}function __(e={}){const{mutation:t}=e,n=ut(e),r=c_(n),{mutate:s,mutateAsync:a,...c}=ru({...t,...r});return{...c,signMessage:s,signMessageAsync:a}}function rC(e={}){const{mutation:t}=e,n=ut(e),r=l_(n),{mutate:s,mutateAsync:a,...c}=ru({...t,...r});return{...c,chains:k_({config:n}),switchChain:s,switchChainAsync:a}}function Vr(e={}){const{hash:t,query:n={}}=e,r=ut(e),s=Ci({config:r}),a=u_(r,{...e,chainId:e.chainId??s}),c=!!(t&&(n.enabled??!0));return Ga({...n,...a,enabled:c})}function Qr(e={}){const{mutation:t}=e,n=ut(e),r=f_(n),{mutate:s,mutateAsync:a,...c}=ru({...t,...r});return{...c,writeContract:s,writeContractAsync:a}}var h6='-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',T_={rounded:`SFRounded, ui-rounded, "SF Pro Rounded", ${h6}`,system:h6},Dc={large:{actionButton:"9999px",connectButton:"12px",modal:"24px",modalMobile:"28px"},medium:{actionButton:"10px",connectButton:"8px",modal:"16px",modalMobile:"18px"},none:{actionButton:"0px",connectButton:"0px",modal:"0px",modalMobile:"0px"},small:{actionButton:"4px",connectButton:"4px",modal:"8px",modalMobile:"8px"}},O_={large:{modalOverlay:"blur(20px)"},none:{modalOverlay:"blur(0px)"},small:{modalOverlay:"blur(4px)"}},R_=({borderRadius:e="large",fontStack:t="rounded",overlayBlur:n="none"})=>({blurs:{modalOverlay:O_[n].modalOverlay},fonts:{body:T_[t]},radii:{actionButton:Dc[e].actionButton,connectButton:Dc[e].connectButton,menuButton:Dc[e].connectButton,modal:Dc[e].modal,modalMobile:Dc[e].modalMobile}}),oC={blue:{accentColor:"#0E76FD",accentColorForeground:"#FFF"},green:{accentColor:"#1DB847",accentColorForeground:"#FFF"},orange:{accentColor:"#FF801F",accentColorForeground:"#FFF"},pink:{accentColor:"#FF5CA0",accentColorForeground:"#FFF"},purple:{accentColor:"#5F5AFA",accentColorForeground:"#FFF"},red:{accentColor:"#FA423C",accentColorForeground:"#FFF"}},p6=oC.blue,sC=({accentColor:e=p6.accentColor,accentColorForeground:t=p6.accentColorForeground,...n}={})=>({...R_(n),colors:{accentColor:e,accentColorForeground:t,actionButtonBorder:"rgba(0, 0, 0, 0.04)",actionButtonBorderMobile:"rgba(0, 0, 0, 0.06)",actionButtonSecondaryBackground:"rgba(0, 0, 0, 0.06)",closeButton:"rgba(60, 66, 66, 0.8)",closeButtonBackground:"rgba(0, 0, 0, 0.06)",connectButtonBackground:"#FFF",connectButtonBackgroundError:"#FF494A",connectButtonInnerBackground:"linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.06))",connectButtonText:"#25292E",connectButtonTextError:"#FFF",connectionIndicator:"#30E000",downloadBottomCardBackground:"linear-gradient(126deg, rgba(255, 255, 255, 0) 9.49%, rgba(171, 171, 171, 0.04) 71.04%), #FFFFFF",downloadTopCardBackground:"linear-gradient(126deg, rgba(171, 171, 171, 0.2) 9.49%, rgba(255, 255, 255, 0) 71.04%), #FFFFFF",error:"#FF494A",generalBorder:"rgba(0, 0, 0, 0.06)",generalBorderDim:"rgba(0, 0, 0, 0.03)",menuItemBackground:"rgba(60, 66, 66, 0.1)",modalBackdrop:"rgba(0, 0, 0, 0.3)",modalBackground:"#FFF",modalBorder:"transparent",modalText:"#25292E",modalTextDim:"rgba(60, 66, 66, 0.3)",modalTextSecondary:"rgba(60, 66, 66, 0.6)",profileAction:"#FFF",profileActionHover:"rgba(255, 255, 255, 0.5)",profileForeground:"rgba(60, 66, 66, 0.06)",selectedOptionBorder:"rgba(60, 66, 66, 0.1)",standby:"#FFD641"},shadows:{connectButton:"0px 4px 12px rgba(0, 0, 0, 0.1)",dialog:"0px 8px 32px rgba(0, 0, 0, 0.32)",profileDetailsAction:"0px 2px 6px rgba(37, 41, 46, 0.04)",selectedOption:"0px 2px 6px rgba(0, 0, 0, 0.24)",selectedWallet:"0px 2px 6px rgba(0, 0, 0, 0.12)",walletLogo:"0px 2px 16px rgba(0, 0, 0, 0.16)"}});sC.accentColors=oC;var qm=`{
102
- "connect_wallet": {
103
- "label": "Connect Wallet",
104
- "wrong_network": {
105
- "label": "Wrong network"
106
- }
107
- },
108
-
109
- "intro": {
110
- "title": "What is a Wallet?",
111
- "description": "A wallet is used to send, receive, store, and display digital assets. It's also a new way to log in, without needing to create new accounts and passwords on every website.",
112
- "digital_asset": {
113
- "title": "A Home for your Digital Assets",
114
- "description": "Wallets are used to send, receive, store, and display digital assets like Ethereum and NFTs."
115
- },
116
- "login": {
117
- "title": "A New Way to Log In",
118
- "description": "Instead of creating new accounts and passwords on every website, just connect your wallet."
119
- },
120
- "get": {
121
- "label": "Get a Wallet"
122
- },
123
- "learn_more": {
124
- "label": "Learn More"
125
- }
126
- },
127
-
128
- "sign_in": {
129
- "label": "Verify your account",
130
- "description": "To finish connecting, you must sign a message in your wallet to verify that you are the owner of this account.",
131
- "message": {
132
- "send": "Sign message",
133
- "preparing": "Preparing message...",
134
- "cancel": "Cancel",
135
- "preparing_error": "Error preparing message, please retry!"
136
- },
137
- "signature": {
138
- "waiting": "Waiting for signature...",
139
- "verifying": "Verifying signature...",
140
- "signing_error": "Error signing message, please retry!",
141
- "verifying_error": "Error verifying signature, please retry!",
142
- "oops_error": "Oops, something went wrong!"
143
- }
144
- },
145
-
146
- "connect": {
147
- "label": "Connect",
148
- "title": "Connect a Wallet",
149
- "new_to_ethereum": {
150
- "description": "New to Ethereum wallets?",
151
- "learn_more": {
152
- "label": "Learn More"
153
- }
154
- },
155
- "learn_more": {
156
- "label": "Learn more"
157
- },
158
- "recent": "Recent",
159
- "status": {
160
- "opening": "Opening %{wallet}...",
161
- "connecting": "Connecting",
162
- "connect_mobile": "Continue in %{wallet}",
163
- "not_installed": "%{wallet} is not installed",
164
- "not_available": "%{wallet} is not available",
165
- "confirm": "Confirm connection in the extension",
166
- "confirm_mobile": "Accept connection request in the wallet"
167
- },
168
- "secondary_action": {
169
- "get": {
170
- "description": "Don't have %{wallet}?",
171
- "label": "GET"
172
- },
173
- "install": {
174
- "label": "INSTALL"
175
- },
176
- "retry": {
177
- "label": "RETRY"
178
- }
179
- },
180
- "walletconnect": {
181
- "description": {
182
- "full": "Need the official WalletConnect modal?",
183
- "compact": "Need the WalletConnect modal?"
184
- },
185
- "open": {
186
- "label": "OPEN"
187
- }
188
- }
189
- },
190
-
191
- "connect_scan": {
192
- "title": "Scan with %{wallet}",
193
- "fallback_title": "Scan with your phone"
194
- },
195
-
196
- "connector_group": {
197
- "installed": "Installed",
198
- "recommended": "Recommended",
199
- "other": "Other",
200
- "popular": "Popular",
201
- "more": "More",
202
- "others": "Others"
203
- },
204
-
205
- "get": {
206
- "title": "Get a Wallet",
207
- "action": {
208
- "label": "GET"
209
- },
210
- "mobile": {
211
- "description": "Mobile Wallet"
212
- },
213
- "extension": {
214
- "description": "Browser Extension"
215
- },
216
- "mobile_and_extension": {
217
- "description": "Mobile Wallet and Extension"
218
- },
219
- "mobile_and_desktop": {
220
- "description": "Mobile and Desktop Wallet"
221
- },
222
- "looking_for": {
223
- "title": "Not what you're looking for?",
224
- "mobile": {
225
- "description": "Select a wallet on the main screen to get started with a different wallet provider."
226
- },
227
- "desktop": {
228
- "compact_description": "Select a wallet on the main screen to get started with a different wallet provider.",
229
- "wide_description": "Select a wallet on the left to get started with a different wallet provider."
230
- }
231
- }
232
- },
233
-
234
- "get_options": {
235
- "title": "Get started with %{wallet}",
236
- "short_title": "Get %{wallet}",
237
- "mobile": {
238
- "title": "%{wallet} for Mobile",
239
- "description": "Use the mobile wallet to explore the world of Ethereum.",
240
- "download": {
241
- "label": "Get the app"
242
- }
243
- },
244
- "extension": {
245
- "title": "%{wallet} for %{browser}",
246
- "description": "Access your wallet right from your favorite web browser.",
247
- "download": {
248
- "label": "Add to %{browser}"
249
- }
250
- },
251
- "desktop": {
252
- "title": "%{wallet} for %{platform}",
253
- "description": "Access your wallet natively from your powerful desktop.",
254
- "download": {
255
- "label": "Add to %{platform}"
256
- }
257
- }
258
- },
259
-
260
- "get_mobile": {
261
- "title": "Install %{wallet}",
262
- "description": "Scan with your phone to download on iOS or Android",
263
- "continue": {
264
- "label": "Continue"
265
- }
266
- },
267
-
268
- "get_instructions": {
269
- "mobile": {
270
- "connect": {
271
- "label": "Connect"
272
- },
273
- "learn_more": {
274
- "label": "Learn More"
275
- }
276
- },
277
- "extension": {
278
- "refresh": {
279
- "label": "Refresh"
280
- },
281
- "learn_more": {
282
- "label": "Learn More"
283
- }
284
- },
285
- "desktop": {
286
- "connect": {
287
- "label": "Connect"
288
- },
289
- "learn_more": {
290
- "label": "Learn More"
291
- }
292
- }
293
- },
294
-
295
- "chains": {
296
- "title": "Switch Networks",
297
- "wrong_network": "Wrong network detected, switch or disconnect to continue.",
298
- "confirm": "Confirm in Wallet",
299
- "switching_not_supported": "Your wallet does not support switching networks from %{appName}. Try switching networks from within your wallet instead.",
300
- "switching_not_supported_fallback": "Your wallet does not support switching networks from this app. Try switching networks from within your wallet instead.",
301
- "disconnect": "Disconnect",
302
- "connected": "Connected"
303
- },
304
-
305
- "profile": {
306
- "disconnect": {
307
- "label": "Disconnect"
308
- },
309
- "copy_address": {
310
- "label": "Copy Address",
311
- "copied": "Copied!"
312
- },
313
- "explorer": {
314
- "label": "View more on explorer"
315
- },
316
- "transactions": {
317
- "description": "%{appName} transactions will appear here...",
318
- "description_fallback": "Your transactions will appear here...",
319
- "recent": {
320
- "title": "Recent Transactions"
321
- },
322
- "clear": {
323
- "label": "Clear All"
324
- }
325
- }
326
- },
327
-
328
- "wallet_connectors": {
329
- "ready": {
330
- "qr_code": {
331
- "step1": {
332
- "description": "Add Ready to your home screen for faster access to your wallet.",
333
- "title": "Open the Ready app"
334
- },
335
- "step2": {
336
- "description": "Create a wallet and username, or import an existing wallet.",
337
- "title": "Create or Import a Wallet"
338
- },
339
- "step3": {
340
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
341
- "title": "Tap the Scan QR button"
342
- }
343
- }
344
- },
345
-
346
- "berasig": {
347
- "extension": {
348
- "step1": {
349
- "title": "Install the BeraSig extension",
350
- "description": "We recommend pinning BeraSig to your taskbar for easier access to your wallet."
351
- },
352
- "step2": {
353
- "title": "Create a Wallet",
354
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
355
- },
356
- "step3": {
357
- "title": "Refresh your browser",
358
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
359
- }
360
- }
361
- },
362
-
363
- "best": {
364
- "qr_code": {
365
- "step1": {
366
- "title": "Open the Best Wallet app",
367
- "description": "Add Best Wallet to your home screen for faster access to your wallet."
368
- },
369
- "step2": {
370
- "title": "Create or Import a Wallet",
371
- "description": "Create a new wallet or import an existing one."
372
- },
373
- "step3": {
374
- "title": "Tap the QR icon and scan",
375
- "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
376
- }
377
- }
378
- },
379
-
380
- "bifrost": {
381
- "qr_code": {
382
- "step1": {
383
- "description": "We recommend putting Bifrost Wallet on your home screen for quicker access.",
384
- "title": "Open the Bifrost Wallet app"
385
- },
386
- "step2": {
387
- "description": "Create or import a wallet using your recovery phrase.",
388
- "title": "Create or Import a Wallet"
389
- },
390
- "step3": {
391
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
392
- "title": "Tap the scan button"
393
- }
394
- }
395
- },
396
-
397
- "bitget": {
398
- "qr_code": {
399
- "step1": {
400
- "description": "We recommend putting Bitget Wallet on your home screen for quicker access.",
401
- "title": "Open the Bitget Wallet app"
402
- },
403
- "step2": {
404
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
405
- "title": "Create or Import a Wallet"
406
- },
407
- "step3": {
408
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
409
- "title": "Tap the scan button"
410
- }
411
- },
412
-
413
- "extension": {
414
- "step1": {
415
- "description": "We recommend pinning Bitget Wallet to your taskbar for quicker access to your wallet.",
416
- "title": "Install the Bitget Wallet extension"
417
- },
418
- "step2": {
419
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
420
- "title": "Create or Import a Wallet"
421
- },
422
- "step3": {
423
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
424
- "title": "Refresh your browser"
425
- }
426
- }
427
- },
428
-
429
- "bitski": {
430
- "extension": {
431
- "step1": {
432
- "description": "We recommend pinning Bitski to your taskbar for quicker access to your wallet.",
433
- "title": "Install the Bitski extension"
434
- },
435
- "step2": {
436
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
437
- "title": "Create or Import a Wallet"
438
- },
439
- "step3": {
440
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
441
- "title": "Refresh your browser"
442
- }
443
- }
444
- },
445
-
446
- "bitverse": {
447
- "qr_code": {
448
- "step1": {
449
- "title": "Open the Bitverse Wallet app",
450
- "description": "Add Bitverse Wallet to your home screen for faster access to your wallet."
451
- },
452
- "step2": {
453
- "title": "Create or Import a Wallet",
454
- "description": "Create a new wallet or import an existing one."
455
- },
456
- "step3": {
457
- "title": "Tap the QR icon and scan",
458
- "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
459
- }
460
- }
461
- },
462
-
463
- "bloom": {
464
- "desktop": {
465
- "step1": {
466
- "title": "Open the Bloom Wallet app",
467
- "description": "We recommend putting Bloom Wallet on your home screen for quicker access."
468
- },
469
- "step2": {
470
- "description": "Create or import a wallet using your recovery phrase.",
471
- "title": "Create or Import a Wallet"
472
- },
473
- "step3": {
474
- "description": "After you have a wallet, click on Connect to connect via Bloom. A connection prompt in the app will appear for you to confirm the connection.",
475
- "title": "Click on Connect"
476
- }
477
- }
478
- },
479
-
480
- "bybit": {
481
- "qr_code": {
482
- "step1": {
483
- "description": "We recommend putting Bybit on your home screen for faster access to your wallet.",
484
- "title": "Open the Bybit app"
485
- },
486
- "step2": {
487
- "description": "You can easily backup your wallet using our backup feature on your phone.",
488
- "title": "Create or Import a Wallet"
489
- },
490
- "step3": {
491
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
492
- "title": "Tap the scan button"
493
- }
494
- },
495
-
496
- "extension": {
497
- "step1": {
498
- "description": "Click at the top right of your browser and pin Bybit Wallet for easy access.",
499
- "title": "Install the Bybit Wallet extension"
500
- },
501
- "step2": {
502
- "description": "Create a new wallet or import an existing one.",
503
- "title": "Create or Import a wallet"
504
- },
505
- "step3": {
506
- "description": "Once you set up Bybit Wallet, click below to refresh the browser and load up the extension.",
507
- "title": "Refresh your browser"
508
- }
509
- }
510
- },
511
-
512
- "binance": {
513
- "qr_code": {
514
- "step1": {
515
- "description": "We recommend putting Binance on your home screen for faster access to your wallet.",
516
- "title": "Open the Binance app"
517
- },
518
- "step2": {
519
- "description": "You can easily backup your wallet using our backup feature on your phone.",
520
- "title": "Create or Import a Wallet"
521
- },
522
- "step3": {
523
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
524
- "title": "Tap the WalletConnect button"
525
- }
526
- },
527
- "extension": {
528
- "step1": {
529
- "title": "Install the Binance Wallet extension",
530
- "description": "We recommend pinning Binance Wallet to your taskbar for quicker access to your wallet."
531
- },
532
- "step2": {
533
- "title": "Create or Import a Wallet",
534
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
535
- },
536
- "step3": {
537
- "title": "Refresh your browser",
538
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
539
- }
540
- }
541
- },
542
-
543
- "coin98": {
544
- "qr_code": {
545
- "step1": {
546
- "description": "We recommend putting Coin98 Wallet on your home screen for faster access to your wallet.",
547
- "title": "Open the Coin98 Wallet app"
548
- },
549
- "step2": {
550
- "description": "You can easily backup your wallet using our backup feature on your phone.",
551
- "title": "Create or Import a Wallet"
552
- },
553
- "step3": {
554
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
555
- "title": "Tap the WalletConnect button"
556
- }
557
- },
558
-
559
- "extension": {
560
- "step1": {
561
- "description": "Click at the top right of your browser and pin Coin98 Wallet for easy access.",
562
- "title": "Install the Coin98 Wallet extension"
563
- },
564
- "step2": {
565
- "description": "Create a new wallet or import an existing one.",
566
- "title": "Create or Import a wallet"
567
- },
568
- "step3": {
569
- "description": "Once you set up Coin98 Wallet, click below to refresh the browser and load up the extension.",
570
- "title": "Refresh your browser"
571
- }
572
- }
573
- },
574
-
575
- "coinbase": {
576
- "qr_code": {
577
- "step1": {
578
- "description": "We recommend putting Coinbase Wallet on your home screen for quicker access.",
579
- "title": "Open the Coinbase Wallet app"
580
- },
581
- "step2": {
582
- "description": "You can easily backup your wallet using the cloud backup feature.",
583
- "title": "Create or Import a Wallet"
584
- },
585
- "step3": {
586
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
587
- "title": "Tap the scan button"
588
- }
589
- },
590
-
591
- "extension": {
592
- "step1": {
593
- "description": "We recommend pinning Coinbase Wallet to your taskbar for quicker access to your wallet.",
594
- "title": "Install the Coinbase Wallet extension"
595
- },
596
- "step2": {
597
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
598
- "title": "Create or Import a Wallet"
599
- },
600
- "step3": {
601
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
602
- "title": "Refresh your browser"
603
- }
604
- }
605
- },
606
-
607
- "compass": {
608
- "extension": {
609
- "step1": {
610
- "description": "We recommend pinning Compass Wallet to your taskbar for quicker access to your wallet.",
611
- "title": "Install the Compass Wallet extension"
612
- },
613
- "step2": {
614
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
615
- "title": "Create or Import a Wallet"
616
- },
617
- "step3": {
618
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
619
- "title": "Refresh your browser"
620
- }
621
- }
622
- },
623
-
624
- "core": {
625
- "qr_code": {
626
- "step1": {
627
- "description": "We recommend putting Core on your home screen for faster access to your wallet.",
628
- "title": "Open the Core app"
629
- },
630
- "step2": {
631
- "description": "You can easily backup your wallet using our backup feature on your phone.",
632
- "title": "Create or Import a Wallet"
633
- },
634
- "step3": {
635
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
636
- "title": "Tap the WalletConnect button"
637
- }
638
- },
639
-
640
- "extension": {
641
- "step1": {
642
- "description": "We recommend pinning Core to your taskbar for quicker access to your wallet.",
643
- "title": "Install the Core extension"
644
- },
645
- "step2": {
646
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
647
- "title": "Create or Import a Wallet"
648
- },
649
- "step3": {
650
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
651
- "title": "Refresh your browser"
652
- }
653
- }
654
- },
655
-
656
- "fox": {
657
- "qr_code": {
658
- "step1": {
659
- "description": "We recommend putting FoxWallet on your home screen for quicker access.",
660
- "title": "Open the FoxWallet app"
661
- },
662
- "step2": {
663
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
664
- "title": "Create or Import a Wallet"
665
- },
666
- "step3": {
667
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
668
- "title": "Tap the scan button"
669
- }
670
- }
671
- },
672
-
673
- "frontier": {
674
- "qr_code": {
675
- "step1": {
676
- "description": "We recommend putting Frontier Wallet on your home screen for quicker access.",
677
- "title": "Open the Frontier Wallet app"
678
- },
679
- "step2": {
680
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
681
- "title": "Create or Import a Wallet"
682
- },
683
- "step3": {
684
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
685
- "title": "Tap the scan button"
686
- }
687
- },
688
-
689
- "extension": {
690
- "step1": {
691
- "description": "We recommend pinning Frontier Wallet to your taskbar for quicker access to your wallet.",
692
- "title": "Install the Frontier Wallet extension"
693
- },
694
- "step2": {
695
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
696
- "title": "Create or Import a Wallet"
697
- },
698
- "step3": {
699
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
700
- "title": "Refresh your browser"
701
- }
702
- }
703
- },
704
-
705
- "im_token": {
706
- "qr_code": {
707
- "step1": {
708
- "title": "Open the imToken app",
709
- "description": "Put imToken app on your home screen for faster access to your wallet."
710
- },
711
- "step2": {
712
- "title": "Create or Import a Wallet",
713
- "description": "Create a new wallet or import an existing one."
714
- },
715
- "step3": {
716
- "title": "Tap Scanner Icon in top right corner",
717
- "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
718
- }
719
- }
720
- },
721
-
722
- "iopay": {
723
- "qr_code": {
724
- "step1": {
725
- "description": "We recommend putting ioPay on your home screen for faster access to your wallet.",
726
- "title": "Open the ioPay app"
727
- },
728
- "step2": {
729
- "description": "You can easily backup your wallet using our backup feature on your phone.",
730
- "title": "Create or Import a Wallet"
731
- },
732
- "step3": {
733
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
734
- "title": "Tap the WalletConnect button"
735
- }
736
- }
737
- },
738
-
739
- "kaikas": {
740
- "extension": {
741
- "step1": {
742
- "description": "We recommend pinning Kaikas to your taskbar for quicker access to your wallet.",
743
- "title": "Install the Kaikas extension"
744
- },
745
- "step2": {
746
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
747
- "title": "Create or Import a Wallet"
748
- },
749
- "step3": {
750
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
751
- "title": "Refresh your browser"
752
- }
753
- },
754
- "qr_code": {
755
- "step1": {
756
- "title": "Open the Kaikas app",
757
- "description": "Put Kaikas app on your home screen for faster access to your wallet."
758
- },
759
- "step2": {
760
- "title": "Create or Import a Wallet",
761
- "description": "Create a new wallet or import an existing one."
762
- },
763
- "step3": {
764
- "title": "Tap Scanner Icon in top right corner",
765
- "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
766
- }
767
- }
768
- },
769
-
770
- "kaia": {
771
- "extension": {
772
- "step1": {
773
- "description": "We recommend pinning Kaia to your taskbar for quicker access to your wallet.",
774
- "title": "Install the Kaia extension"
775
- },
776
- "step2": {
777
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
778
- "title": "Create or Import a Wallet"
779
- },
780
- "step3": {
781
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
782
- "title": "Refresh your browser"
783
- }
784
- },
785
- "qr_code": {
786
- "step1": {
787
- "title": "Open the Kaia app",
788
- "description": "Put Kaia app on your home screen for faster access to your wallet."
789
- },
790
- "step2": {
791
- "title": "Create or Import a Wallet",
792
- "description": "Create a new wallet or import an existing one."
793
- },
794
- "step3": {
795
- "title": "Tap Scanner Icon in top right corner",
796
- "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
797
- }
798
- }
799
- },
800
-
801
- "kraken": {
802
- "qr_code": {
803
- "step1": {
804
- "title": "Open the Kraken Wallet app",
805
- "description": "Add Kraken Wallet to your home screen for faster access to your wallet."
806
- },
807
- "step2": {
808
- "title": "Create or Import a Wallet",
809
- "description": "Create a new wallet or import an existing one."
810
- },
811
- "step3": {
812
- "title": "Tap the QR icon and scan",
813
- "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
814
- }
815
- }
816
- },
817
-
818
- "kresus": {
819
- "qr_code": {
820
- "step1": {
821
- "title": "Open the Kresus Wallet app",
822
- "description": "Add Kresus Wallet to your home screen for faster access to your wallet."
823
- },
824
- "step2": {
825
- "title": "Create or Import a Wallet",
826
- "description": "Create a new wallet or import an existing one."
827
- },
828
- "step3": {
829
- "title": "Tap the QR icon and scan",
830
- "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
831
- }
832
- }
833
- },
834
-
835
- "magicEden": {
836
- "extension": {
837
- "step1": {
838
- "title": "Install the Magic Eden extension",
839
- "description": "We recommend pinning Magic Eden to your taskbar for easier access to your wallet."
840
- },
841
- "step2": {
842
- "title": "Create or Import a Wallet",
843
- "description": "Be sure to back up your wallet using a secure method. Never share your secret recovery phrase with anyone."
844
- },
845
- "step3": {
846
- "title": "Refresh your browser",
847
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
848
- }
849
- }
850
- },
851
-
852
- "metamask": {
853
- "qr_code": {
854
- "step1": {
855
- "title": "Open the MetaMask app",
856
- "description": "We recommend putting MetaMask on your home screen for quicker access."
857
- },
858
- "step2": {
859
- "title": "Create or Import a Wallet",
860
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
861
- },
862
- "step3": {
863
- "title": "Tap the scan button",
864
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
865
- }
866
- },
867
-
868
- "extension": {
869
- "step1": {
870
- "title": "Install the MetaMask extension",
871
- "description": "We recommend pinning MetaMask to your taskbar for quicker access to your wallet."
872
- },
873
- "step2": {
874
- "title": "Create or Import a Wallet",
875
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
876
- },
877
- "step3": {
878
- "title": "Refresh your browser",
879
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
880
- }
881
- }
882
- },
883
-
884
- "nestwallet": {
885
- "extension": {
886
- "step1": {
887
- "title": "Install the NestWallet extension",
888
- "description": "We recommend pinning NestWallet to your taskbar for quicker access to your wallet."
889
- },
890
- "step2": {
891
- "title": "Create or Import a Wallet",
892
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
893
- },
894
- "step3": {
895
- "title": "Refresh your browser",
896
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
897
- }
898
- }
899
- },
900
-
901
- "okx": {
902
- "qr_code": {
903
- "step1": {
904
- "title": "Open the OKX Wallet app",
905
- "description": "We recommend putting OKX Wallet on your home screen for quicker access."
906
- },
907
- "step2": {
908
- "title": "Create or Import a Wallet",
909
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
910
- },
911
- "step3": {
912
- "title": "Tap the scan button",
913
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
914
- }
915
- },
916
-
917
- "extension": {
918
- "step1": {
919
- "title": "Install the OKX Wallet extension",
920
- "description": "We recommend pinning OKX Wallet to your taskbar for quicker access to your wallet."
921
- },
922
- "step2": {
923
- "title": "Create or Import a Wallet",
924
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
925
- },
926
- "step3": {
927
- "title": "Refresh your browser",
928
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
929
- }
930
- }
931
- },
932
-
933
- "omni": {
934
- "qr_code": {
935
- "step1": {
936
- "title": "Open the Omni app",
937
- "description": "Add Omni to your home screen for faster access to your wallet."
938
- },
939
- "step2": {
940
- "title": "Create or Import a Wallet",
941
- "description": "Create a new wallet or import an existing one."
942
- },
943
- "step3": {
944
- "title": "Tap the QR icon and scan",
945
- "description": "Tap the QR icon on your home screen, scan the code and confirm the prompt to connect."
946
- }
947
- }
948
- },
949
-
950
- "1inch": {
951
- "qr_code": {
952
- "step1": {
953
- "description": "Put 1inch Wallet on your home screen for faster access to your wallet.",
954
- "title": "Open the 1inch Wallet app"
955
- },
956
- "step2": {
957
- "description": "Create a wallet and username, or import an existing wallet.",
958
- "title": "Create or Import a Wallet"
959
- },
960
- "step3": {
961
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
962
- "title": "Tap the Scan QR button"
963
- }
964
- }
965
- },
966
-
967
- "token_pocket": {
968
- "qr_code": {
969
- "step1": {
970
- "title": "Open the TokenPocket app",
971
- "description": "We recommend putting TokenPocket on your home screen for quicker access."
972
- },
973
- "step2": {
974
- "title": "Create or Import a Wallet",
975
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
976
- },
977
- "step3": {
978
- "title": "Tap the scan button",
979
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
980
- }
981
- },
982
-
983
- "extension": {
984
- "step1": {
985
- "title": "Install the TokenPocket extension",
986
- "description": "We recommend pinning TokenPocket to your taskbar for quicker access to your wallet."
987
- },
988
- "step2": {
989
- "title": "Create or Import a Wallet",
990
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
991
- },
992
- "step3": {
993
- "title": "Refresh your browser",
994
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
995
- }
996
- }
997
- },
998
-
999
- "trust": {
1000
- "qr_code": {
1001
- "step1": {
1002
- "title": "Open the Trust Wallet app",
1003
- "description": "Put Trust Wallet on your home screen for faster access to your wallet."
1004
- },
1005
- "step2": {
1006
- "title": "Create or Import a Wallet",
1007
- "description": "Create a new wallet or import an existing one."
1008
- },
1009
- "step3": {
1010
- "title": "Tap WalletConnect in Settings",
1011
- "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
1012
- }
1013
- },
1014
-
1015
- "extension": {
1016
- "step1": {
1017
- "title": "Install the Trust Wallet extension",
1018
- "description": "Click at the top right of your browser and pin Trust Wallet for easy access."
1019
- },
1020
- "step2": {
1021
- "title": "Create or Import a wallet",
1022
- "description": "Create a new wallet or import an existing one."
1023
- },
1024
- "step3": {
1025
- "title": "Refresh your browser",
1026
- "description": "Once you set up Trust Wallet, click below to refresh the browser and load up the extension."
1027
- }
1028
- }
1029
- },
1030
-
1031
- "uniswap": {
1032
- "qr_code": {
1033
- "step1": {
1034
- "title": "Open the Uniswap app",
1035
- "description": "Add Uniswap Wallet to your home screen for faster access to your wallet."
1036
- },
1037
- "step2": {
1038
- "title": "Create or Import a Wallet",
1039
- "description": "Create a new wallet or import an existing one."
1040
- },
1041
- "step3": {
1042
- "title": "Tap the QR icon and scan",
1043
- "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
1044
- }
1045
- }
1046
- },
1047
-
1048
- "zerion": {
1049
- "qr_code": {
1050
- "step1": {
1051
- "title": "Open the Zerion app",
1052
- "description": "We recommend putting Zerion on your home screen for quicker access."
1053
- },
1054
- "step2": {
1055
- "title": "Create or Import a Wallet",
1056
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1057
- },
1058
- "step3": {
1059
- "title": "Tap the scan button",
1060
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1061
- }
1062
- },
1063
-
1064
- "extension": {
1065
- "step1": {
1066
- "title": "Install the Zerion extension",
1067
- "description": "We recommend pinning Zerion to your taskbar for quicker access to your wallet."
1068
- },
1069
- "step2": {
1070
- "title": "Create or Import a Wallet",
1071
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1072
- },
1073
- "step3": {
1074
- "title": "Refresh your browser",
1075
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1076
- }
1077
- }
1078
- },
1079
-
1080
- "rainbow": {
1081
- "qr_code": {
1082
- "step1": {
1083
- "title": "Open the Rainbow app",
1084
- "description": "We recommend putting Rainbow on your home screen for faster access to your wallet."
1085
- },
1086
- "step2": {
1087
- "title": "Create or Import a Wallet",
1088
- "description": "You can easily backup your wallet using our backup feature on your phone."
1089
- },
1090
- "step3": {
1091
- "title": "Tap the scan button",
1092
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1093
- }
1094
- }
1095
- },
1096
-
1097
- "enkrypt": {
1098
- "extension": {
1099
- "step1": {
1100
- "description": "We recommend pinning Enkrypt Wallet to your taskbar for quicker access to your wallet.",
1101
- "title": "Install the Enkrypt Wallet extension"
1102
- },
1103
- "step2": {
1104
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
1105
- "title": "Create or Import a Wallet"
1106
- },
1107
- "step3": {
1108
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
1109
- "title": "Refresh your browser"
1110
- }
1111
- }
1112
- },
1113
-
1114
- "frame": {
1115
- "extension": {
1116
- "step1": {
1117
- "description": "We recommend pinning Frame to your taskbar for quicker access to your wallet.",
1118
- "title": "Install Frame & the companion extension"
1119
- },
1120
- "step2": {
1121
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
1122
- "title": "Create or Import a Wallet"
1123
- },
1124
- "step3": {
1125
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
1126
- "title": "Refresh your browser"
1127
- }
1128
- }
1129
- },
1130
-
1131
- "one_key": {
1132
- "extension": {
1133
- "step1": {
1134
- "title": "Install the OneKey Wallet extension",
1135
- "description": "We recommend pinning OneKey Wallet to your taskbar for quicker access to your wallet."
1136
- },
1137
- "step2": {
1138
- "title": "Create or Import a Wallet",
1139
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1140
- },
1141
- "step3": {
1142
- "title": "Refresh your browser",
1143
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1144
- }
1145
- }
1146
- },
1147
-
1148
- "paraswap": {
1149
- "qr_code": {
1150
- "step1": {
1151
- "title": "Open the ParaSwap app",
1152
- "description": "Add ParaSwap Wallet to your home screen for faster access to your wallet."
1153
- },
1154
- "step2": {
1155
- "title": "Create or Import a Wallet",
1156
- "description": "Create a new wallet or import an existing one."
1157
- },
1158
- "step3": {
1159
- "title": "Tap the QR icon and scan",
1160
- "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
1161
- }
1162
- }
1163
- },
1164
-
1165
- "phantom": {
1166
- "extension": {
1167
- "step1": {
1168
- "title": "Install the Phantom extension",
1169
- "description": "We recommend pinning Phantom to your taskbar for easier access to your wallet."
1170
- },
1171
- "step2": {
1172
- "title": "Create or Import a Wallet",
1173
- "description": "Be sure to back up your wallet using a secure method. Never share your secret recovery phrase with anyone."
1174
- },
1175
- "step3": {
1176
- "title": "Refresh your browser",
1177
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1178
- }
1179
- }
1180
- },
1181
-
1182
- "rabby": {
1183
- "extension": {
1184
- "step1": {
1185
- "title": "Install the Rabby extension",
1186
- "description": "We recommend pinning Rabby to your taskbar for quicker access to your wallet."
1187
- },
1188
- "step2": {
1189
- "title": "Create or Import a Wallet",
1190
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1191
- },
1192
- "step3": {
1193
- "title": "Refresh your browser",
1194
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1195
- }
1196
- }
1197
- },
1198
-
1199
- "ronin": {
1200
- "qr_code": {
1201
- "step1": {
1202
- "description": "We recommend putting Ronin Wallet on your home screen for quicker access.",
1203
- "title": "Open the Ronin Wallet app"
1204
- },
1205
- "step2": {
1206
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
1207
- "title": "Create or Import a Wallet"
1208
- },
1209
- "step3": {
1210
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
1211
- "title": "Tap the scan button"
1212
- }
1213
- },
1214
-
1215
- "extension": {
1216
- "step1": {
1217
- "description": "We recommend pinning Ronin Wallet to your taskbar for quicker access to your wallet.",
1218
- "title": "Install the Ronin Wallet extension"
1219
- },
1220
- "step2": {
1221
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone.",
1222
- "title": "Create or Import a Wallet"
1223
- },
1224
- "step3": {
1225
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension.",
1226
- "title": "Refresh your browser"
1227
- }
1228
- }
1229
- },
1230
-
1231
- "ramper": {
1232
- "extension": {
1233
- "step1": {
1234
- "title": "Install the Ramper extension",
1235
- "description": "We recommend pinning Ramper to your taskbar for easier access to your wallet."
1236
- },
1237
- "step2": {
1238
- "title": "Create a Wallet",
1239
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1240
- },
1241
- "step3": {
1242
- "title": "Refresh your browser",
1243
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1244
- }
1245
- }
1246
- },
1247
-
1248
- "safeheron": {
1249
- "extension": {
1250
- "step1": {
1251
- "title": "Install the Core extension",
1252
- "description": "We recommend pinning Safeheron to your taskbar for quicker access to your wallet."
1253
- },
1254
- "step2": {
1255
- "title": "Create or Import a Wallet",
1256
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1257
- },
1258
- "step3": {
1259
- "title": "Refresh your browser",
1260
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1261
- }
1262
- }
1263
- },
1264
-
1265
- "taho": {
1266
- "extension": {
1267
- "step1": {
1268
- "title": "Install the Taho extension",
1269
- "description": "We recommend pinning Taho to your taskbar for quicker access to your wallet."
1270
- },
1271
- "step2": {
1272
- "title": "Create or Import a Wallet",
1273
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1274
- },
1275
- "step3": {
1276
- "title": "Refresh your browser",
1277
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1278
- }
1279
- }
1280
- },
1281
-
1282
- "wigwam": {
1283
- "extension": {
1284
- "step1": {
1285
- "title": "Install the Wigwam extension",
1286
- "description": "We recommend pinning Wigwam to your taskbar for quicker access to your wallet."
1287
- },
1288
- "step2": {
1289
- "title": "Create or Import a Wallet",
1290
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1291
- },
1292
- "step3": {
1293
- "title": "Refresh your browser",
1294
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1295
- }
1296
- }
1297
- },
1298
-
1299
- "talisman": {
1300
- "extension": {
1301
- "step1": {
1302
- "title": "Install the Talisman extension",
1303
- "description": "We recommend pinning Talisman to your taskbar for quicker access to your wallet."
1304
- },
1305
- "step2": {
1306
- "title": "Create or Import an Ethereum Wallet",
1307
- "description": "Be sure to back up your wallet using a secure method. Never share your recovery phrase with anyone."
1308
- },
1309
- "step3": {
1310
- "title": "Refresh your browser",
1311
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1312
- }
1313
- }
1314
- },
1315
-
1316
- "ctrl": {
1317
- "extension": {
1318
- "step1": {
1319
- "title": "Install the CTRL Wallet extension",
1320
- "description": "We recommend pinning CTRL Wallet to your taskbar for quicker access to your wallet."
1321
- },
1322
- "step2": {
1323
- "title": "Create or Import a Wallet",
1324
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1325
- },
1326
- "step3": {
1327
- "title": "Refresh your browser",
1328
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1329
- }
1330
- }
1331
- },
1332
-
1333
- "zeal": {
1334
- "qr_code": {
1335
- "step1": {
1336
- "title": "Open the Zeal app",
1337
- "description": "Add Zeal Wallet to your home screen for faster access to your wallet."
1338
- },
1339
- "step2": {
1340
- "title": "Create or Import a Wallet",
1341
- "description": "Create a new wallet or import an existing one."
1342
- },
1343
- "step3": {
1344
- "title": "Tap the QR icon and scan",
1345
- "description": "Tap the QR icon on your homescreen, scan the code and confirm the prompt to connect."
1346
- }
1347
- },
1348
- "extension": {
1349
- "step1": {
1350
- "title": "Install the Zeal extension",
1351
- "description": "We recommend pinning Zeal to your taskbar for quicker access to your wallet."
1352
- },
1353
- "step2": {
1354
- "title": "Create or Import a Wallet",
1355
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1356
- },
1357
- "step3": {
1358
- "title": "Refresh your browser",
1359
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1360
- }
1361
- }
1362
- },
1363
-
1364
- "safepal": {
1365
- "extension": {
1366
- "step1": {
1367
- "title": "Install the SafePal Wallet extension",
1368
- "description": "Click at the top right of your browser and pin SafePal Wallet for easy access."
1369
- },
1370
- "step2": {
1371
- "title": "Create or Import a wallet",
1372
- "description": "Create a new wallet or import an existing one."
1373
- },
1374
- "step3": {
1375
- "title": "Refresh your browser",
1376
- "description": "Once you set up SafePal Wallet, click below to refresh the browser and load up the extension."
1377
- }
1378
- },
1379
- "qr_code": {
1380
- "step1": {
1381
- "title": "Open the SafePal Wallet app",
1382
- "description": "Put SafePal Wallet on your home screen for faster access to your wallet."
1383
- },
1384
- "step2": {
1385
- "title": "Create or Import a Wallet",
1386
- "description": "Create a new wallet or import an existing one."
1387
- },
1388
- "step3": {
1389
- "title": "Tap WalletConnect in Settings",
1390
- "description": "Choose New Connection, then scan the QR code and confirm the prompt to connect."
1391
- }
1392
- }
1393
- },
1394
-
1395
- "desig": {
1396
- "extension": {
1397
- "step1": {
1398
- "title": "Install the Desig extension",
1399
- "description": "We recommend pinning Desig to your taskbar for easier access to your wallet."
1400
- },
1401
- "step2": {
1402
- "title": "Create a Wallet",
1403
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1404
- },
1405
- "step3": {
1406
- "title": "Refresh your browser",
1407
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1408
- }
1409
- }
1410
- },
1411
-
1412
- "subwallet": {
1413
- "extension": {
1414
- "step1": {
1415
- "title": "Install the SubWallet extension",
1416
- "description": "We recommend pinning SubWallet to your taskbar for quicker access to your wallet."
1417
- },
1418
- "step2": {
1419
- "title": "Create or Import a Wallet",
1420
- "description": "Be sure to back up your wallet using a secure method. Never share your recovery phrase with anyone."
1421
- },
1422
- "step3": {
1423
- "title": "Refresh your browser",
1424
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1425
- }
1426
- },
1427
- "qr_code": {
1428
- "step1": {
1429
- "title": "Open the SubWallet app",
1430
- "description": "We recommend putting SubWallet on your home screen for quicker access."
1431
- },
1432
- "step2": {
1433
- "title": "Create or Import a Wallet",
1434
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1435
- },
1436
- "step3": {
1437
- "title": "Tap the scan button",
1438
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1439
- }
1440
- }
1441
- },
1442
-
1443
- "clv": {
1444
- "extension": {
1445
- "step1": {
1446
- "title": "Install the CLV Wallet extension",
1447
- "description": "We recommend pinning CLV Wallet to your taskbar for quicker access to your wallet."
1448
- },
1449
- "step2": {
1450
- "title": "Create or Import a Wallet",
1451
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1452
- },
1453
- "step3": {
1454
- "title": "Refresh your browser",
1455
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1456
- }
1457
- },
1458
- "qr_code": {
1459
- "step1": {
1460
- "title": "Open the CLV Wallet app",
1461
- "description": "We recommend putting CLV Wallet on your home screen for quicker access."
1462
- },
1463
- "step2": {
1464
- "title": "Create or Import a Wallet",
1465
- "description": "Be sure to back up your wallet using a secure method. Never share your secret phrase with anyone."
1466
- },
1467
- "step3": {
1468
- "title": "Tap the scan button",
1469
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1470
- }
1471
- }
1472
- },
1473
-
1474
- "okto": {
1475
- "qr_code": {
1476
- "step1": {
1477
- "title": "Open the Okto app",
1478
- "description": "Add Okto to your home screen for quick access"
1479
- },
1480
- "step2": {
1481
- "title": "Create an MPC Wallet",
1482
- "description": "Create an account and generate a wallet"
1483
- },
1484
- "step3": {
1485
- "title": "Tap WalletConnect in Settings",
1486
- "description": "Tap the Scan QR icon at the top right and confirm the prompt to connect."
1487
- }
1488
- }
1489
- },
1490
-
1491
- "ledger": {
1492
- "desktop": {
1493
- "step1": {
1494
- "title": "Open the Ledger Live app",
1495
- "description": "We recommend putting Ledger Live on your home screen for quicker access."
1496
- },
1497
- "step2": {
1498
- "title": "Set up your Ledger",
1499
- "description": "Set up a new Ledger or connect to an existing one."
1500
- },
1501
- "step3": {
1502
- "title": "Connect",
1503
- "description": "A connection prompt will appear for you to connect your wallet."
1504
- }
1505
- },
1506
- "qr_code": {
1507
- "step1": {
1508
- "title": "Open the Ledger Live app",
1509
- "description": "We recommend putting Ledger Live on your home screen for quicker access."
1510
- },
1511
- "step2": {
1512
- "title": "Set up your Ledger",
1513
- "description": "You can either sync with the desktop app or connect your Ledger."
1514
- },
1515
- "step3": {
1516
- "title": "Scan the code",
1517
- "description": "Tap WalletConnect then Switch to Scanner. After you scan, a connection prompt will appear for you to connect your wallet."
1518
- }
1519
- }
1520
- },
1521
-
1522
- "valora": {
1523
- "qr_code": {
1524
- "step1": {
1525
- "title": "Open the Valora app",
1526
- "description": "We recommend putting Valora on your home screen for quicker access."
1527
- },
1528
- "step2": {
1529
- "title": "Create or import a wallet",
1530
- "description": "Create a new wallet or import an existing one."
1531
- },
1532
- "step3": {
1533
- "title": "Tap the scan button",
1534
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1535
- }
1536
- }
1537
- },
1538
-
1539
- "gate": {
1540
- "qr_code": {
1541
- "step1": {
1542
- "title": "Open the Gate app",
1543
- "description": "We recommend putting Gate on your home screen for quicker access."
1544
- },
1545
- "step2": {
1546
- "title": "Create or Import a Wallet",
1547
- "description": "Create a new wallet or import an existing one."
1548
- },
1549
- "step3": {
1550
- "title": "Tap the scan button",
1551
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1552
- }
1553
- },
1554
- "extension": {
1555
- "step1": {
1556
- "title": "Install the Gate extension",
1557
- "description": "We recommend pinning Gate to your taskbar for easier access to your wallet."
1558
- },
1559
- "step2": {
1560
- "title": "Create or Import a Wallet",
1561
- "description": "Be sure to back up your wallet using a secure method. Never share your secret recovery phrase with anyone."
1562
- },
1563
- "step3": {
1564
- "title": "Refresh your browser",
1565
- "description": "Once you set up your wallet, click below to refresh the browser and load up the extension."
1566
- }
1567
- }
1568
- },
1569
-
1570
- "gemini": {
1571
- "qr_code": {
1572
- "step1": {
1573
- "title": "Open keys.gemini.com",
1574
- "description": "Visit keys.gemini.com on your mobile browser - no app download required."
1575
- },
1576
- "step2": {
1577
- "title": "Create Your Wallet Instantly",
1578
- "description": "Set up your smart wallet in seconds using your device's built-in authentication."
1579
- },
1580
- "step3": {
1581
- "title": "Scan to Connect",
1582
- "description": "Scan the QR code to instantly connect your wallet - it just works."
1583
- }
1584
- },
1585
- "extension": {
1586
- "step1": {
1587
- "title": "Go to keys.gemini.com",
1588
- "description": "No extensions or downloads needed - your wallet lives securely in the browser."
1589
- },
1590
- "step2": {
1591
- "title": "One-Click Setup",
1592
- "description": "Create your smart wallet instantly with passkey authentication - easier than any wallet out there."
1593
- },
1594
- "step3": {
1595
- "title": "Connect and Go",
1596
- "description": "Approve the connection and you're ready - the unopinionated wallet that just works."
1597
- }
1598
- }
1599
- },
1600
-
1601
- "xportal": {
1602
- "qr_code": {
1603
- "step1": {
1604
- "description": "Put xPortal on your home screen for faster access to your wallet.",
1605
- "title": "Open the xPortal app"
1606
- },
1607
- "step2": {
1608
- "description": "Create a wallet or import an existing one.",
1609
- "title": "Create or Import a Wallet"
1610
- },
1611
- "step3": {
1612
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
1613
- "title": "Tap the Scan QR button"
1614
- }
1615
- }
1616
- },
1617
-
1618
- "mew": {
1619
- "qr_code": {
1620
- "step1": {
1621
- "description": "We recommend putting MEW Wallet on your home screen for quicker access.",
1622
- "title": "Open the MEW Wallet app"
1623
- },
1624
- "step2": {
1625
- "description": "You can easily backup your wallet using the cloud backup feature.",
1626
- "title": "Create or Import a Wallet"
1627
- },
1628
- "step3": {
1629
- "description": "After you scan, a connection prompt will appear for you to connect your wallet.",
1630
- "title": "Tap the scan button"
1631
- }
1632
- }
1633
- },
1634
-
1635
- "zilpay": {
1636
- "qr_code": {
1637
- "step1": {
1638
- "title": "Open the ZilPay app",
1639
- "description": "Add ZilPay to your home screen for faster access to your wallet."
1640
- },
1641
- "step2": {
1642
- "title": "Create or Import a Wallet",
1643
- "description": "Create a new wallet or import an existing one."
1644
- },
1645
- "step3": {
1646
- "title": "Tap the scan button",
1647
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1648
- }
1649
- }
1650
- },
1651
-
1652
- "nova": {
1653
- "qr_code": {
1654
- "step1": {
1655
- "title": "Open the Nova Wallet app",
1656
- "description": "Add Nova Wallet to your home screen for faster access to your wallet."
1657
- },
1658
- "step2": {
1659
- "title": "Create or Import a Wallet",
1660
- "description": "Create a new wallet or import an existing one."
1661
- },
1662
- "step3": {
1663
- "title": "Tap the scan button",
1664
- "description": "After you scan, a connection prompt will appear for you to connect your wallet."
1665
- }
1666
- }
1667
- }
1668
- }
1669
- }
1670
- `;function M_(e,t){return Object.defineProperty(e,"__recipe__",{value:t,writable:!1}),e}var iC=M_;function aC(e){var{conditions:t}=e;if(!t)throw new Error("Styles have no conditions");function n(r){if(typeof r=="string"||typeof r=="number"||typeof r=="boolean"){if(!t.defaultCondition)throw new Error("No default condition");return{[t.defaultCondition]:r}}if(Array.isArray(r)){if(!("responsiveArray"in t))throw new Error("Responsive arrays are not supported");var s={};for(var a in t.responsiveArray)r[a]!=null&&(s[t.responsiveArray[a]]=r[a]);return s}return r}return iC(n,{importPath:"@vanilla-extract/sprinkles/createUtils",importName:"createNormalizeValueFn",args:[{conditions:e.conditions}]})}function D_(e){var{conditions:t}=e;if(!t)throw new Error("Styles have no conditions");var n=aC(e);function r(s,a){if(typeof s=="string"||typeof s=="number"||typeof s=="boolean"){if(!t.defaultCondition)throw new Error("No default condition");return a(s,t.defaultCondition)}var c=Array.isArray(s)?n(s):s,l={};for(var d in c)c[d]!=null&&(l[d]=a(c[d],d));return l}return iC(r,{importPath:"@vanilla-extract/sprinkles/createUtils",importName:"createMapValueFn",args:[{conditions:e.conditions}]})}function F_(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function L_(e){var t=F_(e,"string");return typeof t=="symbol"?t:String(t)}function U_(e,t,n){return t=L_(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function m6(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function gp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?m6(Object(n),!0).forEach(function(r){U_(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m6(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var z_=e=>function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var s=Object.assign({},...n.map(d=>d.styles)),a=Object.keys(s),c=a.filter(d=>"mappings"in s[d]),l=d=>{var f=[],h={},p=gp({},d),m=!1;for(var y of c){var v=d[y];if(v!=null){var w=s[y];m=!0;for(var C of w.mappings)h[C]=v,p[C]==null&&delete p[C]}}var A=m?gp(gp({},h),p):d,I=function(){var N=A[S],T=s[S];try{if(T.mappings)return 1;if(typeof N=="string"||typeof N=="number")f.push(T.values[N].defaultClass);else if(Array.isArray(N))for(var B=0;B<N.length;B++){var O=N[B];if(O!=null){var R=T.responsiveArray[B];f.push(T.values[O].conditions[R])}}else for(var W in N){var H=N[W];H!=null&&f.push(T.values[H].conditions[W])}}catch(K){throw K}};for(var S in A)I();return e(f.join(" "))};return Object.assign(l,{properties:new Set(a)})},W_=e=>e,$_=function(){return z_(W_)(...arguments)};function cC(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var s=e.length;for(t=0;t<s;t++)e[t]&&(n=cC(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function lC(){for(var e,t,n=0,r="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=cC(e))&&(r&&(r+=" "),r+=t);return r}var q_="AEkVMQnvDV0B0wKWAQYBQgDpATQAoQDcAIUApwBsAOMAcACTAEUAigBRAHkAPgA/ACwANwAoAGIAHgAvACsAJQAXAC8AHAAhACIALwAVACsAEQAiAAsAGwARABgAFwA7ACoAKwAsADQAFgAtABIAHAAhAA4AHQAdABUAFgAZAA0ADgAXABAAGQAUABIEtAYQASIUOjfDBdMAsQCuPwFnAKUBA10jAK5/Ly8vLwE/pwUJ6/0HPwbkMQVXBVgAPSs5APa2EQbIwQuUCkEDyJ4zAsUKLwKOoQKG2D+Ob4kCxcsCg/IBH98JAPKtAUECLY0KP48A4wDiChUAF9S5yAwLPZ0EG3cA/QI5GL0P6wkGKekFBIFnDRsHLQCrAGmR76WcfwBbBpMjBukAGwA7DJMAWxVbqft7uycM2yDPCLspA7EUOwD3LWujAKF9GAAXBCXXFgEdALkZzQT6CSBMNwmXCYgeG1ZZTOODQgATAAwAFQAOa1QAIQAOAEfuFdg98zlYypXmLgoQHV9NWD3sABMADAAVAA5rIFxAlwDD6wAbADkMxQAbFVup+3EB224cHQVbBeIC0J8CxLAKTBykZRRzGm1M9QC7DWcC4QALLTSJF8mRAoF7ARMbAL0NZwLhAAstAUhQJZFMCgMt+wUyCddpF60B10MASSsSdwIxFiEC6ye5N2sAOeEB9SUAxw7LtQEbY4EAsQUABQCK00kFG8MfBxcAqCfRAaErLQObAGcBChk+7Td0BBgXAKoBxwIhANMrEnM681CwBZA6dyc1SAX6JwVZBVivuAVpO11CEjpYQZd7k2ZfofgLEwPFByXxdyMEo0sCU1MCdRurJwGPo6U1WwNFFwSDYQkA0QarPy8jBykCOV0AawFhH3EAgx0ZAJUBSbcAJ2kXAa/FAzctIUNTAW9ZBmUCZQDxSRcDKQEFAElBAKsAXQBzACu1Bgfz7xmNfwAJIQApALMbRwHRAdsHCzGXeIHoAAoAEQA0AD0AODN3edPAEF8QXAFNCUxsOhULAqwPpgvlERUM0SrL09gANKkH6wNTB+sDUwNTB+sH6wNTB+sDUwNTA1MDUxwK8BrTwBBfD0gEbQWOBYsE1giDJkkRgQcoCNJUDXQeHEcDRQD8IyVJHDuTMwslQkwMTQMH/DZCbKd9OANHMatU9ZCiA8syTzlsAR5xEqAAKg9zHDW1Tn56R3GgCktPrrV/SWJOZwK+Oqg/+AohCZNvu3dOBj0QFyehEPMMLwGxATcN6UvUBO0GNwTFH3kZFQ/JlZgIoS3ZDOkm3y6dgFYj8Sp/BelL8DzZC0lRZA9VC2EJ3zpfgUoDHQEJIocK2Q01CGkQ7wrFZw3hEUEHNQPRSZYAoQb9Cw0dMRWxJgxiqAsFOXMG9xryC4smqxMlevgFzxodBkkBJRr7AMsu44WsWi1cGE9bBf8LISPDFKRQHA0hQLN4RBoXBxElpQKNQ2xKg1EyHo8h8jw5DWIuD1F4B/E8ARlLC308mkanRQoRzj6JPUQiRUwoBDF7LCsnhwnLD4EMtXxuAVUJHQmtDG0TLRETN8EINQcVKZcgJxEIHUaRYJYE85sD7xPNAwcFOwk9Bw8DsRwpEyoVJQUJgSDTAu820S6vAotWfAETBccPIR/bEExH3A7lCJcCYQN/JecAKRUdABMilwg/XwBbj9RTAS7HCMNqaCNwA2MU410RbweNDlMHoxwvFbsc3XDEXgeGBCifqwlXAXEJlQFbBN8IBTVXjJwgPWdPi1QYlyBdQTtd+AItDGEVm0S5h3QChw9nEhcBMQFvBzUM/QJzEekRZxCRCOeGADWxM/Q6IQRLIX8gDQojA0tsygsjJvUM9GUBnxJeAwg0OXfqZ6dgsiAX+QcVMsFBXCHtC45PyQyYGr0YPlQqGeAHuwPvGu8n5kFTBfsDnw86STPqBLkLZQiHCTsARQ6fEwfTGGYKbYzMAS2HAbOVA1ONfwJriwYzBwcAYweDBXXhABkCowifAAEAywNTADUCqQeZABUAgT0BOQMjKwEd4QKLA48ILccBkSsB7yUEF78MEQDzM25GAsOtAoBmZp4F2VQCigJFMQFJIQQBSkNNA6tt3QDXAEcGD9tDARGnRscW3z8B22snAMMA9wABMQcBPQHJAe9pALMBWwstCZ6vsQFJ5SUAfwARZwHTAoUA2QAxAHvtAU8ASQVV9QXPAktFAQ0tFCdTXQG3AxsBLwEJAHUGx4mhxQMbBGkHzwIQFxXdAu8qB7EDItsTyULBAr3aUQAyEgo0CrUKtB9f81wvAi1uPUwACh+kPsM/SgVNO087VDtPO1Q7TztUO087VDtPO1QDk7veu94KaF9BYecMog3QRMQ6RRPXYE1gLhPELbMUvRXKJVIZORq4JwEl4FUFDwAtz2YsCCg0cRe4ADspZIM9Y4IeLApHHONTjVT0LRcArUueM6sNqBsRRDwFQ3XpYiYWCgoeAmR9AmI+V0mrVzccAqHzAmiUAmYFAp+AOBcHAmY3AmYiBGoEewN/DwN+jjkCOXMTOX46Hx8CbBkCMjI4BgJtwwJtquuGL2NBJwFjANoA3QBGAQeUDIkA+ge+AAmxAncrAnaeOwJ5Rz8CeLYZWNdFqkbTAnw7AnrEAn0FAnzsBVUFHEf8SHlfIAAnEUlUSlcRE0rIAtD9AtDISyMDiEsDh+JEwZEuAvKdXP8DA6pLykwpIctNSE2rAos7AorUvRcDGT9jAbMCjjMCjlg8k30CjtUCjlh0UbBTMQZS0FSBApP3ApMIAOUAGFUaVatVzAIsFymRgjLdeGJFNzUCl5sC765YHaQAVSEClosClniYAKVZqFoFfUkANwKWsQKWSlxAXM0CmccCmWBcxl0DFQKclzm+OpkCnBICn5cCnrSGABkLLSYLAp3tAp6OALE5YTBh6wKezwKgagGlAp6bGwKeSqFjxGQjIScCJ6sCJnoCoPcCoEgCotkCocACpisCpcoCp/sAeQKn7mh4aK3/RWoYas0CrN8CrKoCrWMCrP4CVxkCVdgCsd3TAx9KbJMCsrkJArLkE2zcbV9tRFsDJckCtlg3O26MAylBArhaArlDEQK5JnNwMnDdAr0VArvWcJIDMg0CvoRx/gMzbQK+FnMec0sCw8cCwwBzfnRHMUF03AM8owM8lgM9uwLFeALGQwLGDIUCyGVNAshAAslLAskqAmSZAt3OeHVdeKp5IUvMAxifZv4CYfAZ75Ugewdejl63DQLPZwLPaCtHT87vD5sAwqkCz28BJeYDTg5+RwEC3CMC24YC0ksDUlgDU1sA/QNViICFO8cS6VxBghiCz4LKg4kC2sMC2dqEDIRFpzgDhqEAKwNkCoZtVfUAUQLfYQLetG9zAuIr7RAB8ywjAfSXAfLOgwLr7wLpbHUC6vUC6uAA9UMBtQLuhQLrmJamlv8C7jsDhdyYdXDccZ0C8v8AZQOOEpmPAvcPA5FqA5KDAveUAvnVAvhimhiap7czmxoDnX8C/vYBFwA1nxifrwMFiQOmZgOm1QDNwQMGZqGEogEFAwxFAQsBGwdpBl21YwEAtwRnuw2HHq8JABNxNQAfAy8SSQOFewFfIx0AjOsAHQDmnwObjQizBhufwQCnBRG76R09PhZ4BWg3PkArQiFCtF9xEV+8AJbFBTIAkEwZm7k7JmAyEbrPDi8YxhiJyfYFVwVYBVcFWAVjBVgFVwVYBVcFWAVXBVgFVwVYRhUI14VnAgICCmRe6SsEyQOxBi+7uwC7BKe7AOdAKRayBUY+aT5wQj9Ctl91N1/oAFgRM6sAjP7Ma8v8pudGej0mIwQrFic2NX5t32rB8RnCLGkBa9duMBcFXwVqycHJuAjPSVsAAAAKfF59i74AMz+BAAMW0QblrSMFAIzDCwMBDQDlZR09JB9KQrFCvEE4I18nYDYnOCMJwT0KRD9DPng+gT5wPnECiUK8SUI7X8tOT2pNCixrVC9qC24fX+AzOhsJZ5sKYiMrPB0mQqtCvCvMAcv8X8kOHy4JCAkifp3fajotShfJq8msCWXBy8wKYEFfD+UQoxEAk40dRUIlG6ltOc44CjM/Qz5wQj8cBwodTEdsWywtWuG8Egp97R0rQj8cXQhKCQ4zVENCNwQ7Q5wsCoEbLUI/G/UIUyIjGDAxAAWPYfBeCnFkyWALYC0jbkNgGTkCGx5gswYCaxBlTmBNEQFk52AVYJVgfWCzYEtgkWgWFwa1DtxVqbxaC0MWqwG7K83BAh8VABwDHgF5AmwvMJVSgAGKCrhHGgDkI3SOCsoNpk3qAZsCh5xPBUBfAPf3BwA0FlcMC6UMJB+6r0eAgQw0ABUTnyuCCHoC0gtLZREbANhOBnUECh5aADEAtritAJQnCxZvqyQ4nxkBWwGGCfwD2e0PBqoGSga5AB3LValaCbthE4kLLT8OuwG7ASICR1ooKCggHh8hLBImBiEMjQBUAm5XkEmVAW4fD3FHAdN1D85RIBmpsE3qBxEFTF8A9/cHAHoGJGwKKwulODAtx69WDQsAX7wLAGNAlQh6AOpN7yIbvwAxALa4rQCUJy07Ds4CkBh7ULtYyHRyjsOlmw/ZFUkb7AEpEFwSBh/lAccJOhCTBQ8rDDYLABEAs+AiAQIApADhAJiCCrJrOS8AFABbG8YubHYqDcEQAjskHNPhHB4LG30CewTBCqrxbAAnLQ6mLs6hHAe7CQAQOg+7GkcczaF3HgE9Kl8cLs4RGQB9q9ocAuugCAHCAULz5B9lAb4Jtwz6CDwKPgAFwAs9AksNuwi8DTwKvAk8DrsFmAEbawouzqEqD4sa4QHDAREWOwCgCzsLuxC7BBiqe9wAO2sMPAACpgm8BRvQ9QUBvgH6bsoGewG7D00RErwBAQDqAQAAdBVbBhbLFPxvF7sYOxjbL7ZtvgNIqLsAB7sALrsC6w5WAAq7BAAeuwJVICp/FTwVuwG+J+QAsloBvSjgo7vIAAFbAAG7AAJbAALjAAg7AA67AgAbu6VbDr/EAPQAaPuoOwMBu5UnSwDn3Rm7CBp7CKEFCv9wAN+7p7sau6OLeXIG+6mbgwASuwYbCwG8AACGAG27BgALu6c7ARo7ugihnMoBuwvtB8CpOwDhewG/AADlABW7AAb7AAm7AGmLABq7GLuOaRX7AA5rAC5LHgAGuwAXuwghAA1KAcIAt68mAcAAALQADpsAHBsBv/7hCqEABcYLFRXbAAebAEK7AQIAabsAC3sAHbsACLsJoQAFygBunxnVAJEIIQAFygABOwAH2wAdmwghAAaaAAl7ABsrAG0bAOa7gAAIWwAUuwkhAAbKAOOLAAk7C6EOxPtfAAc7AG6cQEgARwADOwAJrQM3AAcbABl7Abv/Aab7AAobAAo7AAn7p+sGuwAJGwADCwAQOwAIPAAUOwARawAPiwAN6wANuwAZCwYWGwAVOwBumxm7ALobLgATOwMAaSsKAOFLAAI7AARSABd7BRsABtAAGLsAC/sAX7sAa/sA5IsBuwAXdgG8AAFyC6EABUoAbXYAB/sA5XsAHGseAXsoUgA5RQD+Bw0McgAoKnABpAUIXgG8XiMMCQdvS2xfKokfPBRiLTYDoQq0AdgAFgLRA24BdnJHUhQhA08CFT4BLAYDc0a8e1J6QAApADEB+wBTCtsAe5AsASsAduUNETJGAUoAVwUAAVABB4rMAHg7BCClAFoA1hUAlWg3H4sAzWuxAM/UFgjCdXMbGFYdCdEBiJCrIlNTTUgSPMKJ+QB/HDdAKSvgEZdPAHIBKSwwKUIZDwMwVQT3xe4AS2XcAGoCcQI/EXo6x3guNdUGBQAQGx0KCAwqBB8dKU5TTgi5ugAKEs0AJgABGgCGAIkAjjUA7gC0AOAAnTwAuwCrAKYAoQDyAJ8A0wCcAOsBDAEHAMAAeQBaAMsAzQEHANcA6wCIAKIBNQDjANgA1QMBByoz1NTU1LbA3M3QzkMyFwFNAVcvRwFVAWQBYwFWAUdLQ0VoDQFOFQcIAzI2DAcAIg0kJiksODo6PT09Pj8OQB5RUVFRU1NSUylUVVdWVhxdYWFgYmEjZmhwb3JycnJycnR0dHR0dHR0dHR0dnZ3dnVbAEDsAEUAlgB0AC4AYvIAigBTAFMAMwJz6QCH//LyAGAAj+wAmwBLAF4AYPn5qgCBAIEAZQBSAK0AHgCyAH8CPAI/APgA4wD6APoA5AD7AOUA5QDkAOIAKQJ3AU0BPAE6AVABOgE6AToBNQE0ATQBNAEYAVQPACsIAABNFwoWAxUWDgCKAJIAogBLAGQYAi0AcABpAJEDEgMkKgMeQT5HKQCLAksAwwJTAqAAugKSApICkgKSApICkgKHApICkgKSApICkgKSApECkQKUApwCkwKSApICkAKQApACkAKOApECcQHQApMCmwKSApICkRZ5CwD6BQOnAl0CNhcBUBA1At4RCisTAUo3E02RAXekPAFlWQD/Az1HAQAAkykeGI9qAClgAGkALgCJA5TMi/CuhFoFuisOwhEBndV0KgsEIzFsATNabAGyAN5+gH9+gH6BgoJ+g4aEfoWIhoCHgoiCiX6Kfot+jIqNfo5+j4KQfpF+kn6TfpSDlYiWgpd+2gLabOEC2GwAgmwkbKAAg2xsBEkERgRIBEsESQRPBEwERwRNBE8ETgRKBEwETwCWZmwAowOIbAC0ZgEFbADJUWxsAM9sAgxsAPZabAD2ARkA9gD0APQA9QD0A31ebNSEI2XAAPYA9AD0APUA9BxsbACJWmwA9gCJARkA9gCJAL4A6AAIAPYAiQN9XmzUhCNlwBxsAPdabAEZAPYA9gD0APQA9QD0APcA9AD0APUA9AN9XmzUhCNlwBxsbACJWmwBGQD2AIkA9gCJAu0A9gCJAL4CNwD3AIkDfV5s1IQjZcAcbAJDATZsAkoBOWwCS8FsbAJXbGwDnwLtA58DnwOgA6ADoAOg1IQjZcAGA31ebBxsbACJWmwBGQOfAIkDnwCJAu0DnwCJAL4CNwOfAInUhCNlwAYDfV5sHGwEPmwAiQQ/AIkGjTFtIDFs1m4DKGwDrAJsbABVWv4VMgJsbACJAmwAVAEAul5sAmxebGwAiV5sAmxebD3YAEls1gJsbEbCxxP/x5BApA0KYFA89AsjTx97EHmJQPyocItC2JnNFRCEnFU6SFTDoI0PxeRNRoNRWkpzVnWW8pTagkNmgf+jGupqZ3eu50LAFnc+OzfJwdub1AdpOy76VnijWNR/CMEevikQkFyQuLuPajxWi9chqOoMJ7qpCN4sx3LJG4Myu8kD68wC6+iAwt+pU1JEeY13rpCVkXSZfinVKn4xZpxsI3Lp8bJLrJ9ujkrIalMRBAcv/GSKEtowzcEn5XmJw2BagB8V2UWJoJHZ14SXhM7p0XeGFOuw6mlvyq99WYp5XxrO6ru9nn4RHcOkJ7hx5UqWtman7yVMLzYXQefQRUdIY70RYQE8+aAzCNSGQkXiHfnHYRMi+xczKDdZLk3AV1gzxkkSHLjBwuq8shIJ+/RAbqjqQbugFhe0rqklu432EERkM5k9y1DXzds46oLqKAx6OhPT2WiqEfhaITn7OF9Y694AmKmUvbpWp0xJqDaf3jeNJXnK6NpnGcFOmbclbARC+5+5U52ufw5b0Hh+2LrrNimvZe4eYmApRsZnJE310SqB+1xB6rSJfnV1f2D0awB18Oc0sXAFqIlgHgWiaZGdvP5CJUSsCTCQUC335+iSkwPlLJJ5lwjTSn9Lw22NbK1Tu8w+bUpHtDRDPho7Gun8aw2Jzu9i+N0Ot/kPMbLAb/rUQ82kfpk85qLDkfxLl39QPDngo72GYh/Xigbpcm1pA23D2ywt3D8GgMOao040wDqkHxOEx0OhC+ZmHiIdjK7yRbfJD2ouZbAedhD3p7s8WDmCJfNforgDYPGAXSI08fTjPZ5B37lc5VXGzc1vJmibDwBNVzXuaUzg7N5H4BxqjhJ+kz9HLUJys7bpBDYAPvbut13AwJCWd059tS8YTYgC8HwrkewBfa1LSSpmMr9uR2EekTiAMH+Mx4AGzgbquccwBDlLmRhgXL/YiLPCEb6d2k5qJ6o800qddABkpqt7NG+sc2uvHZwZs57W1AHTFM1KkMShasADAh2FvzbzJOzVDMS3ZlT2BSFKdnkZFB6JyqJbhm6XANis9TrtzJdlPVp+rl8v3nIke6Jou7m2TKu53Vounupgkz2LzrQPhhatLIG7rfF/gUKWp15X3LKt+ZvuCDSqPUigF9yJntimC1HJR7Yj/dUrLAXWrT+1tnwPJJLGKAlQ5VeNDWRKCTt2vz3rJuo4+gIt75/Mkfl/gSZblZ9r/SEeeosZXneli/xNh1WVCvkRt2RnyyjtMkMqhzXh1PVOCbILqv0r7rGYm0CHIyKdhHL90cl9E1I6eEtQTCt6RXj8M0HHrHCHLVRpNM6WIbT5BCMGVnL0o5895qSRbCJz+5I8PGMhAN/Xrj4BgIdlKqlHtBHqTJwmK169toZ2IWxNzrAbIG7zh85Q/LG2A4yBcaBel52zdunokB0lv3A7kXnTI7M6ZnfZ7nwuj5lkGhqSpW+w5CI/FmRlplBEbnZy1ZxS3DL8rf1YWhO5XivWZBSRh1gFsjjyj3qRG1cm/6ors7WsEif6WRxns1MKDZa6KrbfMQ/swIb+2nb0tqxHeii6FcgVeAjE/Xwac1owx04dJKG8R5YQgHNnEfHf0qb8WOnU0eQSjazq+IK7cSuCqYzPEUB/x+QgGZqM3dBoYvNvZVOHDkbgdilWdagqO5bkybXfLpyMPuGq8mvAAEZGbR6RwXGlW9ErOWTfnjfx6dXFJqBj0OBSGFz4lWQasNOmVJeN4SFWSLfOGB/7ehV5YuoNNROHZEG9ElVuMnqbDMMuDleOt/cN/gsWxGw128mwU8/HxkOKqdTZnI7dHka67WCTf/FmBrxpNCaKJ1GxBTCSS7MNfhNj8S4Gtotg6Z3AM9cAeVROnppUMaiV5jjudLnNqoVrKO1/FijLlAc74kxydxKX1RQuMqHR63eecYr5o6MJ+B78VsLlCrpelWh6GOrCOBIoQmIcdpJL1pwE2zzZqBkecGTdK8KMOB6r1eNRURyrz6M899TZaoS/vNOxHf+5gORU+OyYIcIW6diP25GHF6u8TNjuL/GJzCnLLXd01KrsjRa51v4+O/VIAWXESJxfxWjv628J+cWUQpoD+Yytzs3jSMRJ23/XT+vUdtUMLDQq1vnIoeg/GjWh88MT6k9dRqDaQ+vodilFgvjuNw5pJpId9mfwyYeLCGb3BmHXdfQfhfPRQaupe/f8TG4Bk3eDKlYBaEK3kZYNN2Sdxz47m/vYBxvIOKtnqplB1pebzuXmAr/MuzQCknKe653dzaWQQ7MUhWYWvzIZwLe1v0rXxImLaz+AkAu+sYikhouNF3EW6w4crZ6MuUiDbIAx8XhAfegcvW6x9BPb3/sCxGWu9YyatqExB+TSm69qIkI9IwhjrcnzME+jWBx4mNQm5WwLzUjSyY4FZ0aMF5YFlXUD4hL4XfOeYv5rDe2s2D/Cn+28fZ9UCnOQvXFMnQqfc0G+ZqOWWD9l/liqUPaNQzZjxCHpUAD8Rcc90MniQ02ugHWsUupFUvhC9usY7zNPt5F2jO7qgzhafsQSd50jgLrC6Qx6bpHbXR3WNAu1BzGmwbz+ebGmwTjdy006Y6zipP7n/OJlvSmbq+SY+nefAVKK6EBMPbce5n3IdRI8+vbxCpN53rw3TvgNds1SuMiuLGxt89L71mxPDeanGhyHvOjmO56tnVpoHalQnL6TqNuqKsHjHCIKB4pCgj4WyYPvRvYvqi5EMr7lN3MotPR/KH7JUD1lZbU0QzfbrEBJnuQiVAyAC9vwXWp2TRU1/0aapyAH2cbglEHVAdl+1rb1u147uV0td1eNoQZsqHrIMIYVPXtLk2TIU3cJE08PjoYNDpfF/IcJnYQHl6nsplczX3Rgah4NbJJHl//5scUufqsSd//kbIS406ZWoMP//+jhGUswX/5nVNz/jAj9KmXPtAmMiK+khhbn1w/mELzZMT/WxcW//y/jsHaOM/61oAW/CjYhJtY622/TtMYuP7bilBvbiT3vB9n8IcFPnwM78H0KfhYDRdY5PhWJ4jWRQzB+HT5NVZV56LG82hcQms+jOTT/c9Y9sx5rPi1/wB7f/+c5UfUCKk3iwwCuywUc2MGnAwsXf1E5hoI55x1Q/Qby+sWH8NRjavZ8VaDsdi1NUVhH86BJHX1yaFt1w1OYeL5LVmdN+5Q+KuTvXEPDzUCg6xp0HhsUhTWSe7MZMM/6rsTUb0/nbUE3YQlGGt48kT1/6cnf6yHnvHtQx9EosOXN077yyEq/jE3YTiG/5SEJmXFeocJJ1EAd6vKeK6VEdJLOZ1km/EwOnZWCQpzCLKPHxrfh4yJhGq//2dos2E/3+MOcdW5EsgIdmTQUQetzRy5fQHhDBl37XbWzsqO/cASEDjyst1/8NEROqVAxWnddQV+umJ8IrKVgKvGaTc0GsQ4s8h0Osql5QKwlddPDjJhKInyWqYUKmmlIts+FIcXZ6yM6cljbsjUG2ksSOkuIw4sYHffRNgBOLApvD6XrR6Rt0rV2Uf8IpnIUVnb9Twt91QjAaD/dStSWDxg7aYY+VXIgnuowYdOkjywa2hlgrnI6PjaU3e3UjQ5Yk5mdIJGyHnv3/P+1EkMav1yFyF+FeJE/RXnWBw+Nh0aOo6TGlKX7d+dkP9+brvr79SdtXJtcD/aXBGiMNfG6/NQniQHYQlK78FEHDqOh+bDI0o+2Ub0h53EL/vlzjrBczVEZz2bOtvIL+DIzDkk9nCWt7tlqsq3l9JMtJk3r5HG2iJ9b/X11TG6wwMAjHLQ2oasaMEsydh88QPvI+hmqIHhvalpKoKOueJR0eZ9J8G2alNOIOy98jwvbc87Ewk9d+5G/tUijTmlbjFlDKXV05HalKxaRTrucc73On7yzAPS6f2v4ogiaWyWeV73dv/MsQT5HjRrsYV9dLAcI3T+zC2qEVINyNpEhoKV+xVSuWtT4AhBfpnZ7unIM+HX3msI0HiI+P+z2PFgkjGi5PqEbG/wNIWeRUjPtDEgbbubN+I4JaDLrW9borRBDob7ZFx+JdKeFVUKVeWqb/c88Ol7DhM0suLtuEd8tkDSMTD3DFx8UphPINHMHi51hAPttXL4Ektt/lKEUG/R4qZKohHjVpAcPIMiHyWr6xR8/EWnNJvBFET76yCdk5er7ADB/1bgoImhpSiZ/omZjPKPCEeZsOwvPmXL+1vlJNeGO3TzySmGA1X6e58gLrazDM71jywM1XL8zKHN6G3kB31Y8vLtP982N975SZXk2JwDvmv7AY/aDsFFk1v+nE7/hbvuOWhBH4kuemeYozPk2K22Vx/YGiDTLU7YilpOt29u3RZMBh4UJjlTP5ItxTzWv6ebL9b+GSU1Vsm2S8LMfVfJczaBSqE8J1A4YUjpsALL7++bwCPXFhaufdpDFtBlHb9makeYbqdg9ltvK/HwF/rNE6KrtWUkEcxmTB7Iyu5TiVaIgW/YxzQhpArliIMkOoK5L7ShVtF+DYqV01mk7fwop04hQRwg4KFmr5z9nYf05VVqkSe7gfnx5bxxlQ0qEV0jiwzf064qG11iEqjHcUgDWWsDs/LEGlzX31T5KVL+7D4EoKim7HBagiqRo5JI3WfDBgpKIruWz9j/J6Hp5Q/EJbMWB8NeSMuFarNw3AEYPBJtYQO/4oD/ZgPTSQ06di0EeumX5EbrdThO+fvYEVSxLtZ3AJkee0Xn0sDwNtiiZhJjJRDuG1YRKB1vOulfd9JjHeyu+UHTmrtra/pm+8Rixh4WKiLaLOCxIbZNoWRZSyyUGLPjAaAo+SQBpfO2uruWrzFxLlpvrXJNMCWtlJDKGAnlWK5xpU2tcxXbeD+sbdfwYXt/qTwDk6UqXR/aUt099DhSNl4Nk8mXwpw+b0nvjKOG6Mg1PRXjrMUMANvNgEArv8nMJs3vj1aHi8MHz/UfJWWzkcrSpZTNBhduXlGR7i+ip/THDp5R9KRNcDKECgtwgXg4EFN5HHfikP/XvsoCkHTg+NbsD8Gl6eknk4Arwn/BWGJ0hgW0/gUKrzuGZhub7igRP3abetpIm+24xEOlWl3YKpm2qTBFvX8ddDRvm1LcwnCJuEfZx12qPY9TrntMIQsv316zvpyWnyStX8VU4j6tQk+CWlLBUCJR6MdH9Cp7g2qdn2WM9qFbREmejH09dlWEPm8hPF0L7RxwRRdiCs0DP8ewk6ApoELkKU9hckSdbnXm8UHJmaNXjxv/q0fTTpu8rnl9lN0vQCpDRbCtcz12rGRFEA7Cfg7FhZn5QFkNmv1ZURKEsiZce1nS9K7HrwpC7yJV4Xt3eAVbLJfoXHrtwG60Z8gwaSnmxoL3s2ZlRqggZN/MHo1oUS4L+GwObFI596Ld4Mvi8l+cQmF1gJpkpnDio7TuO35npaMHiWzFqPSX3qNgkIPGuX0qGYnPIVsM901Yu8oZnOZOY1TbtIdFUNKNq2dP8SJ4F/VCEzIjF0/Rh+7UrZj80tC6rognVH3mqa8eCs/lcQU1Pjj98kBmAKDbZUTwosv02UunRR3n0X6c+f73mtwB7/WbQ16gO431EtwZbNG1SM4TZPBnsQSESlsfG2JLQXx5xWf4bmQ/xcVCPISAX5897JxHKLD/Xkgu57+ABR2+MMtEbX64+MNlBHpKC7sjlWVEShf5qA+dGc59LFVlZrX/Enq9z/v+wnZ1HErmxmjJjxOA+hAjVUWgtq6ygAi/8ewJDjUMFw3zhQFtbyTLDPFd21Ji5S5QPZo9nMSxdg1+DGFSN0wlWt7XeYPbHqLfliV0J1kOhQNp0VbUPy0MS2Ms66OxtSWvaULaWHnfAA+sieVVgtjDwN3nKonWapkSKRN8BKKJQpCfqo8RQI5udhfu5s5+7vwsppmAJDgz2GNA7d43VdbV2l/SrvEu4RYslmNJmfSOVbssxAhSYy6WxpIQdDB0FVBpZ6IM8yr81QN+XLZ3n/wed/R+s6LslkxKbzzst/GkRbe6rFmtvJCwr1T44ETM+IMgOnjUO0eG6a1n2w7lwM1oFBvzMUWRkNFOvKcx3oSb5XdenZ5dXsute6nkRypBiSdAtA2fxAd8UdLOZW/MB7fZoEuFheQXijdaF8kuaRZoSeWdKOkKsGYEGaXfaDKTu0WMTcLniQs7KRCz9iK3SP+Y2xIjkfVGqFLSQ6vh+A1u6FdfwXsv1VPMfi2cxmdM+/xTgMXEyo2ZGcQ2YmPsghnYdv2+z48JpGZA4tUK1p1q2VdVxyfypXEXcrxKKtmt8UdW7sHWmKMqDuBBM3J/JUQx8eUYN4pJ5oRqvdiPHU1o/WPjiKvnlCqOdyxlxF54L9PrtLD1NejZ9aZDivVr6ZfMFK1/psVygoPIAnphcJWWb9+5IKMKmgRQULsTPZi6Bw4wP32zVEoKcHpP73CkFAqS98nSaGoWDjDJiaACJn4p5o1jq9R4Q4VcibhXF//LHP0bdf63kRVZdRbbhGe7sDQcyWS5tpkfeYHnff25WK+4FpzLlAcbaKmHdIBqOw3fImx1uqQIADH0TyHzFlqTG6nMoY81svP0T6BIyELMS8tMe+E1p6TFP6sVpZa6VNaTumufD5aj9goRa9SAmdJT4HhI2r0egj8UrgFb8L59wGLnYlzkLAiUd3m/WWIIEU61kPoEjd3gIVy/fiBcgqQqHnoXpL0SqLGdGGgn7DQeVMSYWHfjno1FngIKP9cjYaTlcRP6bZunjHP13/lbVm4awti894pTf/ZNNqr4OR+tDVie/m+rC8QpVnRbsCMPukOH87B2jM4AG6pHuXl1x9SiKdhYJVOhfo/+SCaGjUW2CoogL1FFhFGN9o+acoVLl0SXs/3vrSccmZeAF3NewFuOg/P12QYKQF+SH+KYcNnsAhIAELPBUgre/KRUJEA+KPD0MHRjv+3J/j2Z23MuJmkfy7leWcMsti8wXLSHgXFJTaksx1Woi6oljwxFVIJG12SBSZLNJDbXMYPekmiXT4FclKI35BFgqnYpKfcsr+f8HUXQoHJ9UYZ4J5YMiHHyAxg6eidhodgqJ2Htf/xYEx+G0zXchuzlt8hcAl+AT8NCQ4orFc4DerabF1enA7NTLnvtZh3FUwqIOvY7Q4DYmoDHwXTSw5UNNh6r7j0B/ezMYJMDcw4+6gCTZX4YQ+7Xs8de72vsR3cmfpxIX64/6KR1p3VX4F6vfHEzxzarh8aDH4G1DFoBBM6npXFpK+Rh+WrcFclAeAxi0PoaR9CpOxxGLSdvxKVSw8oOOanG/soKImRopN38AdcUhhM2GT/PgQeSQrG12njuJJD5Z7vWfAZmFybYLdSA91kB4aoBhoj1Z//KNIVVujqaLLRwCkbyn4vh0739C9V9iSjybeOIeSOvNs7LW1a7EUtNoKAnOGML4U8KBXpfrw73WjAszJG4Qscq+Xr3kZWR4Omm0xT6qE9y6FNSpstV4onMZSqCEJ+3VX9qjvdx5QVrM0WXxmPZxejdfnihcFAjzv5PjlTl6ickDbHe6+Lch52pjOPqk+m3RZ+bh2JSMGtFBuODbMchrpRVlt16NTQ05Ps0IDtWlUmWfP2vX8M4YDynIuOZ4Ck91+591B98Gw9fw+yQogTR8CSg0zaJu+rlBo/mr3A+1NziF+kdubz+whc857AZt6DwIBIF5+5yiaaf3ByQp1Fm3sOkZDAzwsYSQTM/Kv6idkugF63FDobDdUY3huruU+sCaBuRR+HmOowvmZoBjZHNh77SXFtmY/oOUE7ifN7nBHAo83S/xvcS6H4Ci2u/9Id62Wv6Ui+zMNLAzhfkTkVcW2BwrnYvpur0ZDlzs+ZLsmGTWvd1892t78gx1YjEJusGcxphjLkV0UfAKlekfSBVWHE2ahk4AbbRmHyL7GYdtKfdlINwrcdJuf3Cee1nfUojDQn/YmItESOFhtLzrkEv4k2XpMU9oaJQ3VUC+1INh6BE68pkHameGJm4Gvdb24Q0fXWxd9Tp3A9mzFSe4qXDGGDIV4AAGV1jIDfveknH1TwWpUT6HiQxKP3AAHJNkJeRlj/mXBmS4S1j8FK6YmpK7jyyAiRbsMCCLoJcx01fvgpMvKQRxu9IOwymconQjD56g7ksOrcOeoTbius4JnGesAS1DtgdaophYsw1wGIsMS3P7K6doE3K5czznqPQLSRRF/Ylzb5NtSKsL33SgskFNCF4khn5LWaDxI23ZRi2hzqN8uW8UzZEBYy68+VtGLSymQrXGUlr2nO2BbBIT5Vh1RmGAyDXaW0FPrpx3wv2UYdFk9tSl+906bMxCuXQaKDQP/U19UEcVGK4gmksL8lAorxQSAOwpeYX9xrZsh6yoGaL/X5O3tgQC8OM+/GvxnW9XvAtu/JxAigydfSmZfqZfg1XOcHNOpLlN8j64OZ36l5qawDBJ62YaTvxeNmm5gowCdBosgcpHOgNgwA+sknN8XmsR2IYChcafl9bGNMZ/nB5guWuvEziv6QI2bP2DtyKWG/qUjZMaxy+wASkkVGtuwGtywkTYG6MYrZBo18vYcww48G/+f+eITA/qMwbLlJC0S3+/ai2pPvkOhRRVmGTuSupaxhIk0xoXLtixCxSAn4Z3OnUS3wBqVscLI4P3GP7i/6gxYsswsVmkvDXFLhO/OKcur8flegCSKiqmVpIRvCzgbjEA0mXPn+RExXY/2OE1f/BYuWpRQY8gCDpMOYBx9Gn4tL3hihSIR1ixh2PIIT7cr2gUJbfs76EKYG52Jk0UZF/PQkBxGuFCEWXnG6ue/hTIqjTRq1sotVrKrwIGHDrITyuanUzbIYdgdEeV88K1VD82TYB2B61Ft+tB1KqHPmT9+hWoaV+iF3SuvtJqvnoLaA8wxrD56AUMULEgzO9SvBcBAfqz/dzMYzwMt/YLszDbmGe1bcHHfFMcvGql9bf/tp+Hrj4q18aNnftGjmXTfws39emn7/5IBxog9MrmftAA5Oq4awenm8HimWO72dwVlHcHmutVMdrMHw+p2vzpzT+B0iIZ+IEpplwWhClcXlxhxAsF3CHRnnaUEqq3ByQ+cqhe5SvR4SFxh/LZoQwtj8QZQGT1BzY2EMpYnUcZWQEPlwFZw+7UryK9qV8KgruYsvyMoK16KI2sN4SOblrVwhyiL8+IBZ8cpUhsJQSU7TFHAi+L2F0sn0y+FtDODlnuif2Mba8QddPZYYxjTsIgkMe3M6+7kXxUfZvbCUlyq71J1eNczGk6Vqw6rSx2K3vM+DjLxDRGzWepTO2qTT/W8S7u0QXcyFUahcB4vq8xCYTpy8iswtnyz7Kx6lgTEQJ9RqkgEIN6DOUqB0uRdeYuDa7AP7Zy9z+ZlTsmVR5vtV71m3dmdtNeWghbr5PnPJtjXAzcvZjxyV96VEx/B1TA0IEQSI50ywGuIbmAYdQg/l/rxhQLX+6uOLyFsaUt6mtjpAJkLfehnB6MlOHnNOrWLvCBqVBS07jcM+4RzLEed3f3/0Xwp92U+nataNHyEgnnuYR6PXEjRLETz0xrt3UglfK7Bn4aNlXG7cZco4lMziLv5+Mh2JCww3mz69Z9ZMRR/xv5EKJ38IFxKd9dw5CgPIXja/gzAshMbF14/qBIgNkdUQeP8YE7SrICGtiTnAKTyA9cXa3OauDHxZOdTP7yuYBzD1UcHstIO16FxF1bRUAlSkszI83YufTchU8OPnnozDl9bS0y6CnnjGwgj9M61cXcZsljjhLeT/Vq+30ScN2PcT/dOoxUDqDS38+OpCCzLDdnwHQc3ECQVIkaxmdPaZTSdfp2jjGzSdNLM5yPQsgJDl+ZnhclDQi8ltUnkqWJ323IvTZPN8rn0+EshL1cx9PiaLTzUsryn9Zp2Nt/detUAh4N/2I3dlMQqjHFxSihv0uykzflq5clMy2ZBaxoEb0/QMp03IQQus3vnZd/NOmSsmgqXqKFP3ozyDgY7RQS+npabe/hNG+5sa5FtvL8v0uYuag2NewYkcol3TOTadpuncCnDgOGpmLnTQ1PEPUN2cNsrW8LYfIv+hzfb7vod+ipXHzmbgj5Fzc6RcT/5PD7VQ8nTJBNj1urkVUx9uJvTWmqY08OC80rGDLaWXv243VB16gjt4Xtwp5H2UDR0LiKW24Ed/sOO8jl1yEU/XAb3h7ScKnCFy/V3sICrkY1D0K9fSokHIL0s5/7DLShLAPXRbV7fbv4qj6OwHC9d5PlEOX3LRpQ3P7hcSAKlIKPDM83ypz56U5+rJeo0cyUtC7wltL8wqEiNSgZsDWzACc7RFoZqhlD0+sihIBQlkQTXmvUyIOZhkQX2zqME5VRC7ms1sa3CY+odMn3mMBiTvCMKnnCxg5ZPLq4GUDB4jF8Br2K4x4sxfWjGXQatJ25I1JyrIv2Z4bP1jKw5C+B2/s0v4dGUOsaS6IPIQV3ETQ+F2fSl2BPBXHzyYN8VmwWIrKeMX9pyGWuAOVXwkxJsRBaBVzLhZDP8ONGncknL5DpTxHN32GgFWMwsc0GmL0oRDmRT8u2lvjAKUIi0MmXhIHSlFeh3Qh5pP6ap4YUd6b569ZIaHgya2AyD12cPxY0In/PBjzDctTaKJCU+xc6m9RkNLDEE8guvxtJP8sl8N9bLqw0F/qejaBlcHYqw31zYpsutQp07hsP1vhGdl4hJ1wA7OCsAHnKj9879uSHILEmuZ6vI1lT4tvnWCVKZhhYrWHW9oPKPKpbOC6FTjf/OtUvwmiXr2ykvyLzHGQeyS7BenZpL3N/CaF5T7Gkml7JXN5cj0PKaDpZVImD61FuMgFHPqSHvt4Ej4KBdAfdcoO3AjQPLwwtKsgGM+ty4lNZMBEItJSRLunG5ckrM/BeoXWoPZVvEoIzLgFQYPupMwZCXis4W2SCJ2zsefZqCj+aTfSq1FYdUj2UeJALvVTf7vuuikOE1Hit3UIAGUi/sqgMum9vw218y1FlY/9XnOji9nqhGAcMYICc7BiqLZj5N+cKEuSAuiyWbMg81ZD1lHovy/we2eaCcCv4MzEW3O0mVA/t2xdA0cxTVbXmFhn+tARDpvDz5ftLr15OAAmvo2QiAky+feVO4bGibv2nlBmBzqx0lEDfEm4UnEs11pbnwZlJ/0Y73/wBPYfTNZiJKR73TzdCW1BffiJq9bLjQmaKnU0+gN8sfe25IKSUCooQwxePDrFn3a/zUgWxvPoTYVXfobY/GV2qqTkeVDV9D8657fhY0/wiaJ5NfLxhXbE/naxs34N0hd6vxNfdm1TCnozm/NKSCThchoYgMF7Z2tzXFovRfsNVkf86JjrM60r7UIuV3bsmfrMOqzjXjN6HPBG25zCJ3QLueySbj9oFvX/HxWBqh31PBPxduCVAxMqC9HK+YL3oBZqBruoh6LKvdMqoz0PYXUBrwbiioyE8Tj5ImjJmiOOWLbAZvIZ/l9rIPljx3T5glJ2ewlfuIT5GlodQsAf/IEtmYkML5SRQGxxwW+rlZkD8belJNu09Itwx9xDULTnemVDeojdbgcd2gKGM9aO00Jivtbs7ZyOSE8IPh98GfvatD8Ud5uHcZfAfMiPSlIxd4UqeSDzuNfbKDuFepkyC/s3j9fawmhY1b9NqDi0ZS5eP35l7rL2eK5QlWLlyCmxx8AFaFiTuD2pMUxZV5mBSJuJduOaq2ZrWpu28DE8jl/hisBz7bGWH6qLF0ayWNq1Sejtcs8KQrQqJk5P9QHDYHOIolgNsMDmEaWcTelghbfFCDqWrq6YLwDWy+m68ec5nShgq2fduUBpQUuKKKgnttaUX9PRfMmxqJyU7e0RLr1bev+ge1KK0bZyhHKKDE8gQX9Vf7rNHWOxBtZcxwwGusyMpH77qWZxXsQmbgIGhtiO+gSSRCyu/ek+OFsz1HMiQH0IHV7PjJi3dszYfFp8ue9h4+AfKte4MTiehPvxNcm/T1t9vsFZx8rHN5ie77r2jzZOq/Em4Q+H9sNcZakf9HnzCc1fJixppxP8FQABmVnqa6GbJhwaka7WH7Wdoz1WxOjSNV8N9sgW5S3Ppgkut+TTCkjA+AodUOk1KIR+8G8S3WrSZG4nyqfJ6FEjXl6a/LEoRMHZUqfPRWvwqrtXYy9IUsmUGzkqi76ib4NANCe5DnyOxnFRZ9d8FdBVBjra3iNuZhJuWW5Omi/hBigqDsg0mu2AhfJDXdwyMIJ33HHHPfS2JtjegRejX11m41TbNL+Qp7mR0g9CPKTj9PIjuSycGN/YPozXI4zarXuAeLv5CHKtKcJKRbd6R2oLNiEt0T8+QIVJH7zt9ncKMgd49vV2P1AyScZ9Qzbu3m3LBnuu6dw7aE0b6r4kzVkI/GUS88mA53L/rLtntkFlZXGtIoqNP2mD3eVv08AVVPT3wJn81zpbJV9SuqZ6Pd1ge0Zz2RFHeCdV5CLPftH9V5o9+VzFu4R0QeumqDwUhXn3IyYotdJnxr1l3BqWnQVAeDBEOtPyJQx1q5+mODiClXtYeBLTWtsJ42AMBcf/IFIhpfhYO08hsg0Ik+DpQFNOKReK3o3cudkxWX0soPtI5eSFOA6yNylS+IQjrQtYQ/5s4UcixJfokumBUjpH9ofSjUTwPCapGFndfqqG5IHeMMvfg+88SXm7bNyjk6pGKzL+WxDAdqKtQ72WWVbOk3I+ueGuammmB2pvFZvqIcU/lvW3n9+r2lycnQLE4OX9R1jIgW4cDjJ3v8dAa66mVcfC7ptCr5io6mCaA9qI9T9FFWqo1ZAaMxgxAu8aXqmaOYryMND2sTUfoHvxcYK7hEiJhCLYFDx3PBhE97c2a0ub1/ePJcyJOqr7UaTAPTJ+xvZtjb/40sloY1ltRnTkWILmIP2b7S3AdXCR+YiArMUHwdncpjpyDGfzqGOUoAuaamWzAMacQtb34/M32FEgR5lUEf8fRzFrZUhzQj0fR7/6gdzdnVVvcSneLmtqJ930VCCDORY8CVdQWdo/S3PNkX3pQsPVKWIYGAMrFZoq8bQ/OJBDSXP7KSBdL3QN0Zqd393p6VFc7DnlnFiN00SY5Nux7yadeIM0Upl2rVsu8/VAI";const g6=new Map([[8217,"apostrophe"],[8260,"fraction slash"],[12539,"middle dot"]]),y6=4;function H_(e){let t=0;function n(){return e[t++]<<8|e[t++]}let r=n(),s=1,a=[0,1];for(let N=1;N<r;N++)a.push(s+=n());let c=n(),l=t;t+=c;let d=0,f=0;function h(){return d==0&&(f=f<<8|e[t++],d=8),f>>--d&1}const p=31,m=2**p,y=m>>>1,v=y>>1,w=m-1;let C=0;for(let N=0;N<p;N++)C=C<<1|h();let A=[],I=0,S=m;for(;;){let N=Math.floor(((C-I+1)*s-1)/S),T=0,B=r;for(;B-T>1;){let W=T+B>>>1;N<a[W]?B=W:T=W}if(T==0)break;A.push(T);let O=I+Math.floor(S*a[T]/s),R=I+Math.floor(S*a[T+1]/s)-1;for(;((O^R)&y)==0;)C=C<<1&w|h(),O=O<<1&w,R=R<<1&w|1;for(;O&~R&v;)C=C&y|C<<1&w>>>1|h(),O=O<<1^y,R=(R^y)<<1|y|1;I=O,S=1+R-O}let j=r-4;return A.map(N=>{switch(N-j){case 3:return j+65792+(e[l++]<<16|e[l++]<<8|e[l++]);case 2:return j+256+(e[l++]<<8|e[l++]);case 1:return j+e[l++];default:return N-1}})}function V_(e){let t=0;return()=>e[t++]}function uC(e){return V_(H_(Q_(e)))}function Q_(e){let t=[];[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"].forEach((s,a)=>t[s.charCodeAt(0)]=a);let n=e.length,r=new Uint8Array(6*n>>3);for(let s=0,a=0,c=0,l=0;s<n;s++)l=l<<6|t[e.charCodeAt(s)],c+=6,c>=8&&(r[a++]=l>>(c-=8));return r}function G_(e){return e&1?~e>>1:e>>1}function K_(e,t){let n=Array(e);for(let r=0,s=0;r<e;r++)n[r]=s+=G_(t());return n}function Al(e,t=0){let n=[];for(;;){let r=e(),s=e();if(!s)break;t+=r;for(let a=0;a<s;a++)n.push(t+a);t+=s+1}return n}function dC(e){return kl(()=>{let t=Al(e);if(t.length)return t})}function fC(e){let t=[];for(;;){let n=e();if(n==0)break;t.push(Y_(n,e))}for(;;){let n=e()-1;if(n<0)break;t.push(J_(n,e))}return t.flat()}function kl(e){let t=[];for(;;){let n=e(t.length);if(!n)break;t.push(n)}return t}function hC(e,t,n){let r=Array(e).fill().map(()=>[]);for(let s=0;s<t;s++)K_(e,n).forEach((a,c)=>r[c].push(a));return r}function Y_(e,t){let n=1+t(),r=t(),s=kl(t);return hC(s.length,1+e,t).flatMap((c,l)=>{let[d,...f]=c;return Array(s[l]).fill().map((h,p)=>{let m=p*r;return[d+p*n,f.map(y=>y+m)]})})}function J_(e,t){let n=1+t();return hC(n,1+e,t).map(s=>[s[0],s.slice(1)])}function Z_(e){let t=[],n=Al(e);return s(r([]),[]),t;function r(a){let c=e(),l=kl(()=>{let d=Al(e).map(f=>n[f]);if(d.length)return r(d)});return{S:c,B:l,Q:a}}function s({S:a,B:c},l,d){if(!(a&4&&d===l[l.length-1])){a&2&&(d=l[l.length-1]),a&1&&t.push(l);for(let f of c)for(let h of f.Q)s(f,[...l,h],d)}}}function X_(e){return e.toString(16).toUpperCase().padStart(2,"0")}function pC(e){return`{${X_(e)}}`}function eT(e){let t=[];for(let n=0,r=e.length;n<r;){let s=e.codePointAt(n);n+=s<65536?1:2,t.push(s)}return t}function Da(e){let n=e.length;if(n<4096)return String.fromCodePoint(...e);let r=[];for(let s=0;s<n;)r.push(String.fromCodePoint(...e.slice(s,s+=4096)));return r.join("")}function tT(e,t){let n=e.length,r=n-t.length;for(let s=0;r==0&&s<n;s++)r=e[s]-t[s];return r}var nT="AEUDWAHSCGYATwDVADIAdgAiADQAFAAtABQAIQAPACcADQASAAsAGQAJABIACQARAAUACwAFAAwABQAQAAMABwAEAAoABQAJAAIACgABAAQAFAALAAIACwABAAIAAQAHAAMAAwAEAAsADAAMAAwACwANAA0AAwAKAAkABAAdAAYAZwDTAecDNACxCmIB8xhZAqfoC190UGcThgBurwf7PT09Pb09AjgJum8OjDllxHYUKXAPxzq6tABAxgK8ysUvWAgMPT09PT09PSs6LT2HcgWXWwFLoSMEEEl5RFVMKvO0XQ8ExDdJMnIgPi89uj00MsvBXxEPAGPCDwBnQKoEbwRwBHEEcgRzBHQEdQR2BHcEeAR6BHsEfAR+BIAEgfndBQoBYgULAWIFDAFiBNcE2ATZBRAFEQUvBdALFAsVDPcNBw13DYcOMA4xDjMB4BllHI0B2grbAMDpHLkQ7QHVAPRNQQFnGRUEg0yEB2uaJEMAJpIBpob5AERSMAKNoAXqaQLRBMCzEiC+AZ4EWRJJFbEu7QDQLARtEbgECxDwAb/RyAk1AV4nD2cEQQKTAzsAGpobPgAahAGPCrysdy0OAKwAfFIcBAQFUmoA/PtZADkBIadVj2UMUgx5Il4ANQC9vLIBDAHUGVsQ8wCzfQIbGVcCHBZHAZ8CBAgXOhG7AqMZ4M7+1M0UAPDNAWsC+mcJDe8AAQA99zkEXLICyQozAo6lAobcP5JvjQLFzwKD9gU/OD8FEQCtEQL6bW+nAKUEvzjDHsuRyUvOFHcacUz5AqIFRSE2kzsBEQCuaQL5DQTlcgO6twSpTiUgCwIFCAUXBHQEqQV6swAVxUlmTmsCwjqsP/wKJQmXb793UgZBEBsnpRD3DDMBtQE7De1L2ATxBjsEyR99GRkPzZWcCKUt3QztJuMuoYBaI/UqgwXtS/Q83QtNUWgPWQtlCeM6Y4FOAyEBDSKLCt0NOQhtEPMKyWsN5RFFBzkD1UmaAKUHAQsRHTUVtSYQYqwLCTl3Bvsa9guPJq8TKXr8BdMaIQZNASka/wDPLueFsFoxXBxPXwYDCyUjxxSoUCANJUC3eEgaGwcVJakCkUNwSodRNh6TIfY8PQ1mLhNRfAf1PAUZTwuBPJ5Gq0UOEdI+jT1IIklMLAQ1fywvJ4sJzw+FDLl8cgFZCSEJsQxxEzERFzfFCDkHGS2XJCcVCCFGlWCaBPefA/MT0QMLBT8JQQcTA7UcLRMuFSkFDYEk1wLzNtUuswKPVoABFwXLDyUf3xBQR+AO6QibAmUDgyXrAC0VIQAXIpsIQ2MAX4/YUwUuywjHamwjdANnFOdhEXMHkQ5XB6ccMxW/HOFwyF4Lhggoo68JWwF1CZkBXwTjCAk1W4ygIEFnU4tYGJsgYUE/XfwCMQxlFZ9EvYd4AosPaxIbATUBcwc5DQECdxHtEWsQlQjrhgQ1tTP4OiUETyGDIBEKJwNPbM4LJyb5DPhpAaMSYgMMND137merYLYkF/0HGTLFQWAh8QuST80MnBrBGEJULhnkB78D8xrzJ+pBVwX/A6MDEzpNM+4EvQtpCIsJPwBJDqMXB9cYagpxjNABMYsBt5kDV5GDAm+PBjcHCwBnC4cFeeUAHQKnCKMABQDPA1cAOQKtB50AGQCFQQE9AycvASHlAo8DkwgxywGVLwHzKQQbwwwVAPc3bkoCw7ECgGpmogXdWAKOAkk1AU0lBAVOR1EDr3HhANsASwYT30cBFatKyxrjQwHfbysAxwD7AAU1BwVBAc0B820AtwFfCzEJorO1AU3pKQCDABVrAdcCiQDdADUAf/EBUwBNBVn5BdMCT0kBETEYK1dhAbsDHwEzAQ0AeQbLjaXJBx8EbQfTAhAbFeEC7y4HtQEDIt8TzULFAr3eVaFgAmSBAmJCW02vWzcgAqH3AmiYAmYJAp+EOBsLAmY7AmYmBG4EfwN/EwN+kjkGOXcXOYI6IyMCbB0CMjY4CgJtxwJtru+KM2dFKwFnAN4A4QBKBQeYDI0A/gvCAA21AncvAnaiPwJ5S0MCeLodXNtFrkbXAnw/AnrIAn0JAnzwBVkFIEgASH1jJAKBbQKAAAKABQJ/rklYSlsVF0rMAtEBAtDMSycDiE8Dh+ZExZEyAvKhXQMDA65LzkwtJQPPTUxNrwKLPwKK2MEbBx1DZwW3Ao43Ao5cQJeBAo7ZAo5ceFG0UzUKUtRUhQKT+wKTDADpABxVHlWvVdAGLBsplYYy4XhmRTs5ApefAu+yWCGoAFklApaPApZ8nACpWaxaCYFNADsClrUClk5cRFzRApnLAplkXMpdBxkCnJs5wjqdApwWAp+bAp64igAdDzEqDwKd8QKekgC1PWE0Ye8CntMCoG4BqQKenx8Cnk6lY8hkJyUrAievAiZ+AqD7AqBMAqLdAqHEAqYvAqXOAqf/AH0Cp/JofGixAANJahxq0QKs4wKsrgKtZwKtAgJXHQJV3AKx4dcDH05slwKyvQ0CsugXbOBtY21IXwMlzQK2XDs/bpADKUUCuF4CuUcVArkqd3A2cOECvRkCu9pwlgMyEQK+iHICAzNxAr4acyJzTwLDywLDBHOCdEs1RXTgAzynAzyaAz2/AsV8AsZHAsYQiQLIaVECyEQCyU8CyS4CZJ0C3dJ4eWF4rnklS9ADGKNnAgJh9BnzlSR7C16SXrsRAs9rAs9sL0tT0vMTnwDGrQLPcwEp6gNOEn5LBQLcJwLbigLSTwNSXANTXwEBA1WMgIk/AMsW7WBFghyC04LOg40C2scC2d6EEIRJpzwDhqUALwNkDoZxWfkAVQLfZQLeuHN3AuIv7RQB8zAnAfSbAfLShwLr8wLpcHkC6vkC6uQA+UcBuQLuiQLrnJaqlwMC7j8DheCYeXDgcaEC8wMAaQOOFpmTAvcTA5FuA5KHAveYAvnZAvhmmhyaq7s3mx4DnYMC/voBGwA5nxyfswMFjQOmagOm2QDRxQMGaqGIogUJAwxJAtQAPwMA4UEXUwER8wNrB5dnBQCTLSu3r73bAYmZFH8RBDkB+ykFIQ6dCZ8Akv0TtRQrxQL3LScApQC3BbmOkRc/xqdtQS4UJo0uAUMBgPwBtSYAdQMOBG0ALAIWDKEAAAoCPQJqA90DfgSRASBFBSF8CgAFAEQAEwA2EgJ3AQAF1QNr7wrFAgD3Cp8nv7G35QGRIUFCAekUfxE0wIkABAAbAFoCRQKEiwAGOlM6lI1tALg6jzrQAI04wTrcAKUA6ADLATqBOjs5/Dn5O3aJOls7nok6bzkYAVYBMwFsBS81XTWeNa01ZjV1NbY1xTWCNZE10jXhNZ41rTXuNf01sjXBNgI2ETXGNdU2FjYnNd417TYuNj02LjUtITY6Nj02PDbJNwgEkDxXNjg23TcgNw82yiA3iTcwCgSwPGc2JDcZN2w6jTchQtRDB0LgQwscDw8JmyhtKFFVBgDpfwDpsAD+mxQ91wLpNSMArQC9BbeOkRdLxptzBL8MDAMMAQgDAAkKCwsLCQoGBAVVBI/DvwDz9b29kaUCb0QtsRTNLt4eGBcSHAMZFhYZEhYEARAEBUEcQRxBHEEcQRxBHEEaQRxBHEFCSTxBPElISUhBNkM2QTYbNklISVmBVIgELgEaJZkC7aMAoQCjBcGOmxdNxrsBvwGJAaQcEZ0ePCklMAAhMvAIMAL54gC7Bm8EescjzQMpARQpKgDUHqSvAj5Gqwr7YrMUACT9AN3rpF27H7fsd/twPt4l+UW1yQYKBt2Cgy7qJpGiLcdE2P1cQSImUbqJ6ICH27H4knQMIRMrFkHu3sx6tC35Y+eLIh4e4CMKJ4DfyV+8mfta499RCAJ0xfeZR8PsoYOApva9pjGn4PhvyZS7/h5JLuhaucfjuU+Z584wwqNO4hWYmaBCcjgQPale1bjoHzMUbut/zTgxHxBnAyrdKpF4IRMASLBtD/jviyLeCgj8twWjAd3HchN/uqaeRYeHJgl7JEY9/cTrvtfybx/r3Y/NtxJ9dp+MTVmiS9bwBH73s8Di56/Ma+mTPMHq4T1yEG1fWcqr0u+hrGnJEvU1JJAm/maQSrKrazIyvSkDFkj8UUlfBq8baniTGPng6YZRL661rDNw4w/1g2figG0IhXnL7wosd/sVNo5dYSmMBTP5c7rYLjRdCwg8quwljOMPf63D8ICAL0r71XRiyFHdgwHbwfgnPOf4Lzjf2v+j+IiDHG2isp5yUnzSDyDRb4i/Vs0qHSHq8PiEQ/JnBP7PxnjN0j6gT4AVAeRx/1o9VnEUlUwvFrzJqHk9jxAw4sYxCnrxaeBdCFFKbnE7z+x54F5W7ZZsU6kx8Qocul6FoAHHy01FGL/nne61mn4+uYXfQ1Uccn+HMLKE+cZzT8BB1E3FRskOgJrRsq25rauLm8+uamXpkS/bTy6y1wDbCrW4eD532kTWrtNUmVVZOIn/C+/JR9KVR5iG9TY8iaT67ubm/whL1xbKZoqtY+a6fNxMJrg211bGYJDUkYMNWA0BMB++9zOm6Eik4roqs9CCEFW0lyAK0PbvlzvoxrZuY/OEhNW/l/63U15Od/RSvmDvXpGLiVmeGi5PDSH2bYz5o2g6wFDQ2FbZgYgTF8rPlvA1ifjZD3NLtFdXdpSIJvgKR7GpjJWG7GZGawPomIH8B5tUmtHH9LpM+/KQKunEPa1GiQkCXv4Cnm9DLORo2joicHdPDZ64obQrPZ5bgqckkj0G6/NEiPYBY4bCkL7W8G5YzsUb6GakFjykSPkT7JGeLeB6uJOGMm+x7N381BCDfbJFx0dtLgV9Q477BfL1fvitX5anV/oYfxeYl+eF5x5bB8+Ep/L2nsmd56aKF4aAD4GbJWsdKyBW22xEmAD3XdbtsMyAFoR5mOla0gEd9U/YVB7zvHGpHbQonay9Sv0bQ8iZ8piaXVrKc5AG1AmqqgaEvzHSP2Wux7aZTWh6quVDVU01JtMIVRdCFwlSbbqqhoFlyzsotQzRexFvZ/MqUSFu3OhRIuNBbufvBpdVgb8XdGJ48/lJPCZ7dsOujTTbKPSEvGXkOnG2Xdi8/nM3EMRqITd5QeU7iOjKqC7URJY6TnLsHij22xAHKnVRD5MDtBYnoGFqZGMDmXCW6Oj+BAWw14hESY/xLF6bLku06AHkiXTHPCFZ0f9YSqqo27eAhhS67OrA2Het4M9JM3jm/yRX6bYxnfmzYl5qQdHxN08FsNuWDrWd4vMUY2QD3hr8vS73SCTkFoXZR3xNzOQt8d/6HfjBmXqvrE6EGkLzK6YK2U2/ksU/iUH+LvVIsJI+ri2AL/klo+ShdDyfs5A83i2prkMs51IKR7ZcqjZJi5X3+bd8GlyWvtddxKEoEqSgEO7A8jIgf2nH0h8FjM7oB6yte3X5mpL0i/E4Rx0CotKnILJj/vJqo4VkPQ93jRtRVfaitQPqldl5xRYPq8387Z0DcnZvOeION0Ht1+P27kFLGQIcLBX4FG3sffccNHh5cPfzp9INoRtqVtdViJfg8RjnXiIz/MNqEN6zvzX3hMzyWC7oSoXIT14ubc0abPX8Rp9GVa5NI/8iv+6ela1oTncbdimRKnrbRffDR/X4nH+bgqAuHWl7hOaeXPWVzIeRl7ga+JzD4Sx3mlj/q6Ra/E2HhDf21eEzTLNGfCZsY+/yxZzQzIAuijG65ii4O/waAJCrEJaWd/DRAKMQ5678Dw5AT7RCKzdadIwd8LsD+DgPBASmWsUlf8R0k1w/2k4lO2Wpb4zMI6EJVJs0xk/wn8/fRUPqrDKhbjHR41SqgFMx5RGMPuduFwlu5lK89tW11sTqiX/5EfGs5nO+y9FKvgXKPOEmgE05EKNL6Sjb3xS40H3BVPhm0ESOZgAjZoymc8be0inDVo4JdJVf+NKd3tN/CaB7GShhH27qf95NoFZVX/6ZkR2lX+CgWrQ2INgkh+bbMz68+uJ3Clsh8HSMPEQtAt+BBE6fXDab7KIlsKxU1lIXW/KWVstpdPanJ0pdXpQinDyUQjtY7ZVcfiecRxRDMAUhHFU2cEaciQ+htiPMPx1kdvtWG9T44w3r037ljHBFJdYR0r55qvMRixtAEFJAqA4T1ES87FAx7UozXasytg8MftZYt0rjYgLe6EJ5aWvy2qscBSBQ7yehoJIA3wIIZ9ukfkyBb6qnue5ko8W50rpV4kXqWjI5nbGRXrNW0tBZHXlY48nSgcUXBHWT4GcgLZJoLlKJnV96kCYpq9eWHh7xJzkCAyrQuQ5AJ0qq/uZ3toJglNterev+Qm0KXxPg/+YbFRJdfhbp1wOnVOEYdVHTya6CtO0afhEaBhx3oHwCb5Kq6RwHDzFMl2vfjL8GwzcCoTj7wZe+UFnYDV2yKpPU9dba29gYBdNqJg/KXozO+CJTlKmlKhnqTf5doeS35DZFV+cYJQVjd+oVY/Gtc/6XPzUxb1gMqf6cEjNNoRC8AObrp+fx0cVtGu4ffC2TgXRC8zPl8moUHCB5HZ25d87mlsiiK0aNwBtcEQjRNBT/QrXbw/8aVXdKMHn9EqYEKEyxSGTpYQOaes1G1Qq8pDgqkZtlO2HRyCXpmeM7TSrRPkAh004BfisVpF6zP44n2Jvxz/gOVocNCyy9V6lkod28QM4pbaMvVJigD/w3BrsjSJrXlqc4ulBYOCceiBN4b/gHajYyupbhEt63a619Ay4wsL6a6w6B+A7TnoyE7BliWHJfzVxxIKM/W3M/J8Bx99Op863Q8eNuIMGRx++VbYfjm+VGYBA3Ap/KEu/wxBNBpJJncwHPG45V8Gh98ZIrGCc20MwijGowZbcS7d1nEgcOW5cddZpHL2XPAIRbColiheZzXTvBxZOY3iMSDSKDrICyJ/iQs1vdplVdH/JrLJsQ2jtTnfCrITIghq3KFX3qAgLWAIp8IffNSdTYptnbGfc8s+qcr3zyzyHp1aJg+jxTF4kD1ry5Wauv5V3xnOGwTFecNzXSLHBW20/pCQjk4uorD0plIhMSTc79+/r4RKPClRYTBYex1Ob5crtfvRQBBv6re/6FhtCqtduag67glqRA77/3ulblh9YRtMdDxkCyJDeNnAuCLPQFmdRRWJtH20Z8DstfJf+5oj5SSB64d0iF5/Ya4KfTWxfivj9Ap2/zbYaTo/1gO3tM6RYsCZharMBFr7Fm61mLSrQnEI4OF1gbVS4k/JE9UotOrnLJZuswoWodCSV8zbybkJSVIP7n8UaE9xCR39rJZmf27HOAPVOGc9pdkQUcRrI0qyVF9Z3j1RHDbxIfwbWzmPVjwIdPJvtmBYwEQIUsIW1S939hcVikK00ozPRI02cqhzVUNzpOxVdrwRPvlh1aIOf0xFEqD3YkGnCnFah/cFN3J2gB7N+bZSGawwkKFu1tpQMrp1W+27YNkyT0TpcFpTqgOqqLabrgcCUPxh97mREOGy4xItzQ9xSl6rq+8BZsHcrQFReS+QeMxJ3P6CnL9EP/eOLDjumLhvrcQrpPiknsofbzBv9gTP0lU+TIVwE6E7CcKfT36q+ZiEOHJ9ayf0dyUJLezAb2M8aNHwd0+OJmsVgTzRWA";const Sl=44032,lf=4352,uf=4449,df=4519,mC=19,gC=21,Fa=28,ff=gC*Fa,rT=mC*ff,oT=Sl+rT,sT=lf+mC,iT=uf+gC,aT=df+Fa;function $c(e){return e>>24&255}function yC(e){return e&16777215}let Hm,v6,Vm,Gd;function cT(){let e=uC(nT);Hm=new Map(dC(e).flatMap((t,n)=>t.map(r=>[r,n+1<<24]))),v6=new Set(Al(e)),Vm=new Map,Gd=new Map;for(let[t,n]of fC(e)){if(!v6.has(t)&&n.length==2){let[r,s]=n,a=Gd.get(r);a||(a=new Map,Gd.set(r,a)),a.set(s,t)}Vm.set(t,n.reverse())}}function vC(e){return e>=Sl&&e<oT}function lT(e,t){if(e>=lf&&e<sT&&t>=uf&&t<iT)return Sl+(e-lf)*ff+(t-uf)*Fa;if(vC(e)&&t>df&&t<aT&&(e-Sl)%Fa==0)return e+(t-df);{let n=Gd.get(e);return n&&(n=n.get(t),n)?n:-1}}function wC(e){Hm||cT();let t=[],n=[],r=!1;function s(a){let c=Hm.get(a);c&&(r=!0,a|=c),t.push(a)}for(let a of e)for(;;){if(a<128)t.push(a);else if(vC(a)){let c=a-Sl,l=c/ff|0,d=c%ff/Fa|0,f=c%Fa;s(lf+l),s(uf+d),f>0&&s(df+f)}else{let c=Vm.get(a);c?n.push(...c):s(a)}if(!n.length)break;a=n.pop()}if(r&&t.length>1){let a=$c(t[0]);for(let c=1;c<t.length;c++){let l=$c(t[c]);if(l==0||a<=l){a=l;continue}let d=c-1;for(;;){let f=t[d+1];if(t[d+1]=t[d],t[d]=f,!d||(a=$c(t[--d]),a<=l))break}a=$c(t[c])}}return t}function uT(e){let t=[],n=[],r=-1,s=0;for(let a of e){let c=$c(a),l=yC(a);if(r==-1)c==0?r=l:t.push(l);else if(s>0&&s>=c)c==0?(t.push(r,...n),n.length=0,r=l):n.push(l),s=c;else{let d=lT(r,l);d>=0?r=d:s==0&&c==0?(t.push(r),r=l):(n.push(l),s=c)}}return r>=0&&t.push(r,...n),t}function bC(e){return wC(e).map(yC)}function dT(e){return uT(wC(e))}const w6=45,xC=".",CC=65039,EC=1,hf=e=>Array.from(e);function jl(e,t){return e.P.has(t)||e.Q.has(t)}class fT extends Array{get is_emoji(){return!0}}let Qm,AC,Gs,Gm,kC,ha,yp,ia,Us,b6,Km;function fg(){if(Qm)return;let e=uC(q_);const t=()=>Al(e),n=()=>new Set(t()),r=(h,p)=>p.forEach(m=>h.add(m));Qm=new Map(fC(e)),AC=n(),Gs=t(),Gm=new Set(t().map(h=>Gs[h])),Gs=new Set(Gs),kC=n(),n();let s=dC(e),a=e();const c=()=>{let h=new Set;return t().forEach(p=>r(h,s[p])),r(h,t()),h};ha=kl(h=>{let p=kl(e).map(m=>m+96);if(p.length){let m=h>=a;p[0]-=32,p=Da(p),m&&(p=`Restricted[${p}]`);let y=c(),v=c(),w=!e();return{N:p,P:y,Q:v,M:w,R:m}}}),yp=n(),ia=new Map;let l=t().concat(hf(yp)).sort((h,p)=>h-p);l.forEach((h,p)=>{let m=e(),y=l[p]=m?l[p-m]:{V:[],M:new Map};y.V.push(h),yp.has(h)||ia.set(h,y)});for(let{V:h,M:p}of new Set(ia.values())){let m=[];for(let v of h){let w=ha.filter(A=>jl(A,v)),C=m.find(({G:A})=>w.some(I=>A.has(I)));C||(C={G:new Set,V:[]},m.push(C)),C.V.push(v),r(C.G,w)}let y=m.flatMap(v=>hf(v.G));for(let{G:v,V:w}of m){let C=new Set(y.filter(A=>!v.has(A)));for(let A of w)p.set(A,C)}}Us=new Set;let d=new Set;const f=h=>Us.has(h)?d.add(h):Us.add(h);for(let h of ha){for(let p of h.P)f(p);for(let p of h.Q)f(p)}for(let h of Us)!ia.has(h)&&!d.has(h)&&ia.set(h,EC);r(Us,bC(Us)),b6=Z_(e).map(h=>fT.from(h)).sort(tT),Km=new Map;for(let h of b6){let p=[Km];for(let m of h){let y=p.map(v=>{let w=v.get(m);return w||(w=new Map,v.set(m,w)),w});m===CC?p.push(...y):p=y}for(let m of p)m.V=h}}function hg(e){return(SC(e)?"":`${pg(Hf([e]))} `)+pC(e)}function pg(e){return`"${e}"‎`}function hT(e){if(e.length>=4&&e[2]==w6&&e[3]==w6)throw new Error(`invalid label extension: "${Da(e.slice(0,4))}"`)}function pT(e){for(let n=e.lastIndexOf(95);n>0;)if(e[--n]!==95)throw new Error("underscore allowed only at start")}function mT(e){let t=e[0],n=g6.get(t);if(n)throw Qc(`leading ${n}`);let r=e.length,s=-1;for(let a=1;a<r;a++){t=e[a];let c=g6.get(t);if(c){if(s==a)throw Qc(`${n} + ${c}`);s=a+1,n=c}}if(s==r)throw Qc(`trailing ${n}`)}function Hf(e,t=1/0,n=pC){let r=[];gT(e[0])&&r.push("◌"),e.length>t&&(t>>=1,e=[...e.slice(0,t),8230,...e.slice(-t)]);let s=0,a=e.length;for(let c=0;c<a;c++){let l=e[c];SC(l)&&(r.push(Da(e.slice(s,c))),r.push(n(l)),s=c+1)}return r.push(Da(e.slice(s,a))),r.join("")}function gT(e,t){return fg(),Gs.has(e)}function SC(e){return fg(),kC.has(e)}function yT(e){return xT(vT(e,dT,AT))}function vT(e,t,n){if(!e)return[];fg();let r=0;return e.split(xC).map(s=>{let a=eT(s),c={input:a,offset:r};r+=a.length+1;try{let l=c.tokens=ET(a,t,n),d=l.length,f;if(!d)throw new Error("empty label");let h=c.output=l.flat();if(pT(h),!(c.emoji=d>1||l[0].is_emoji)&&h.every(m=>m<128))hT(h),f="ASCII";else{let m=l.flatMap(y=>y.is_emoji?[]:y);if(!m.length)f="Emoji";else{if(Gs.has(h[0]))throw Qc("leading combining mark");for(let w=1;w<d;w++){let C=l[w];if(!C.is_emoji&&Gs.has(C[0]))throw Qc(`emoji + combining mark: "${Da(l[w-1])} + ${Hf([C[0]])}"`)}mT(h);let y=hf(new Set(m)),[v]=bT(y);CT(v,m),wT(v,y),f=v.N}}c.type=f}catch(l){c.error=l}return c})}function wT(e,t){let n,r=[];for(let s of t){let a=ia.get(s);if(a===EC)return;if(a){let c=a.M.get(s);if(n=n?n.filter(l=>c.has(l)):hf(c),!n.length)return}else r.push(s)}if(n){for(let s of n)if(r.every(a=>jl(s,a)))throw new Error(`whole-script confusable: ${e.N}/${s.N}`)}}function bT(e){let t=ha;for(let n of e){let r=t.filter(s=>jl(s,n));if(!r.length)throw ha.some(s=>jl(s,n))?IC(t[0],n):jC(n);if(t=r,r.length==1)break}return t}function xT(e){return e.map(({input:t,error:n,output:r})=>{if(n){let s=n.message;throw new Error(e.length==1?s:`Invalid label ${pg(Hf(t,63))}: ${s}`)}return Da(r)}).join(xC)}function jC(e){return new Error(`disallowed character: ${hg(e)}`)}function IC(e,t){let n=hg(t),r=ha.find(s=>s.P.has(t));return r&&(n=`${r.N} ${n}`),new Error(`illegal mixture: ${e.N} + ${n}`)}function Qc(e){return new Error(`illegal placement: ${e}`)}function CT(e,t){for(let n of t)if(!jl(e,n))throw IC(e,n);if(e.M){let n=bC(t);for(let r=1,s=n.length;r<s;r++)if(Gm.has(n[r])){let a=r+1;for(let c;a<s&&Gm.has(c=n[a]);a++)for(let l=r;l<a;l++)if(n[l]==c)throw new Error(`duplicate non-spacing marks: ${hg(c)}`);if(a-r>y6)throw new Error(`excessive non-spacing marks: ${pg(Hf(n.slice(r-1,a)))} (${a-r}/${y6})`);r=a}}}function ET(e,t,n){let r=[],s=[];for(e=e.slice().reverse();e.length;){let a=kT(e);if(a)s.length&&(r.push(t(s)),s=[]),r.push(n(a));else{let c=e.pop();if(Us.has(c))s.push(c);else{let l=Qm.get(c);if(l)s.push(...l);else if(!AC.has(c))throw jC(c)}}}return s.length&&r.push(t(s)),r}function AT(e){return e.filter(t=>t!=CC)}function kT(e,t){let n=Km,r,s=e.length;for(;s&&(n=n.get(e[--s]),!!n);){let{V:a}=n;a&&(r=a,e.length=s)}return r}function ST(e){return yT(e)}function jT(e){return ST(e)}const IT={gasPriceOracle:{address:"0x420000000000000000000000000000000000000F"},l1Block:{address:"0x4200000000000000000000000000000000000015"},l2CrossDomainMessenger:{address:"0x4200000000000000000000000000000000000007"},l2Erc721Bridge:{address:"0x4200000000000000000000000000000000000014"},l2StandardBridge:{address:"0x4200000000000000000000000000000000000010"},l2ToL1MessagePasser:{address:"0x4200000000000000000000000000000000000016"}},NT={block:Zj({format(e){var n;return{transactions:(n=e.transactions)==null?void 0:n.map(r=>{if(typeof r=="string")return r;const s=Xl(r);return s.typeHex==="0x7e"&&(s.isSystemTx=r.isSystemTx,s.mint=r.mint?an(r.mint):void 0,s.sourceHash=r.sourceHash,s.type="deposit"),s}),stateRoot:e.stateRoot}}}),transaction:Yj({format(e){const t={};return e.type==="0x7e"&&(t.isSystemTx=e.isSystemTx,t.mint=e.mint?an(e.mint):void 0,t.sourceHash=e.sourceHash,t.type="deposit"),t}}),transactionReceipt:YI({format(e){return{l1GasPrice:e.l1GasPrice?an(e.l1GasPrice):null,l1GasUsed:e.l1GasUsed?an(e.l1GasUsed):null,l1Fee:e.l1Fee?an(e.l1Fee):null,l1FeeScalar:e.l1FeeScalar?Number(e.l1FeeScalar):null}}})};function PT(e,t){return TT(e)?_T(e):DI(e,t)}const BT={transaction:PT};function _T(e){OT(e);const{sourceHash:t,data:n,from:r,gas:s,isSystemTx:a,mint:c,to:l,value:d}=e,f=[t,r,l??"0x",c?An(c):"0x",d?An(d):"0x",s?An(s):"0x",a?"0x1":"0x",n??"0x"];return Ar(["0x7e",ms(f)])}function TT(e){return e.type==="deposit"||typeof e.sourceHash<"u"}function OT(e){const{from:t,to:n}=e;if(t&&!xt(t))throw new un({address:t});if(n&&!xt(n))throw new un({address:n})}const x6={blockTime:2e3,contracts:IT,formatters:NT,serializers:BT},Fc=1,Il=G1({...x6,id:8453,name:"Base",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://mainnet.base.org"]}},blockExplorers:{default:{name:"Basescan",url:"https://basescan.org",apiUrl:"https://api.basescan.org/api"}},contracts:{...x6.contracts,disputeGameFactory:{[Fc]:{address:"0x43edB88C4B80fDD2AdFF2412A7BebF9dF42cB40e"}},l2OutputOracle:{[Fc]:{address:"0x56315b90c40730925ec5485cf004d835058518A0"}},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:5022},portal:{[Fc]:{address:"0x49048044D57e1C92A77f79988d21Fa8fAF74E97e",blockCreated:17482143}},l1StandardBridge:{[Fc]:{address:"0x3154Cf16ccdb4C6d922629664174b904d80F2C35",blockCreated:17482143}}},sourceId:Fc});({...Il});const mg=G1({id:1,name:"Ethereum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},blockTime:12e3,rpcUrls:{default:{http:["https://eth.merkle.io"]}},blockExplorers:{default:{name:"Etherscan",url:"https://etherscan.io",apiUrl:"https://api.etherscan.io/api"}},contracts:{ensUniversalResolver:{address:"0xeeeeeeee14d718c2b47d9923deab1335e144eeee",blockCreated:23085558},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}});var gg=Y2(),Jt=function(){return Jt=Object.assign||function(t){for(var n,r=1,s=arguments.length;r<s;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},Jt.apply(this,arguments)};function yg(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,r=Object.getOwnPropertySymbols(e);s<r.length;s++)t.indexOf(r[s])<0&&Object.prototype.propertyIsEnumerable.call(e,r[s])&&(n[r[s]]=e[r[s]]);return n}function NC(e,t,n){if(n||arguments.length===2)for(var r=0,s=t.length,a;r<s;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}var Gc="right-scroll-bar-position",Kc="width-before-scroll-bar",RT="with-scroll-bars-hidden",MT="--removed-body-scroll-bar-size";function vp(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function DT(e,t){var n=P.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var s=n.value;s!==r&&(n.value=r,n.callback(r,s))}}}})[0];return n.callback=t,n.facade}var FT=typeof window<"u"?P.useLayoutEffect:P.useEffect,C6=new WeakMap;function vg(e,t){var n=DT(null,function(r){return e.forEach(function(s){return vp(s,r)})});return FT(function(){var r=C6.get(n);if(r){var s=new Set(r),a=new Set(e),c=n.current;s.forEach(function(l){a.has(l)||vp(l,null)}),a.forEach(function(l){s.has(l)||vp(l,c)})}C6.set(n,e)},[e]),n}function PC(e){return e}function BC(e,t){t===void 0&&(t=PC);var n=[],r=!1,s={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var c=t(a,r);return n.push(c),function(){n=n.filter(function(l){return l!==c})}},assignSyncMedium:function(a){for(r=!0;n.length;){var c=n;n=[],c.forEach(a)}n={push:function(l){return a(l)},filter:function(){return n}}},assignMedium:function(a){r=!0;var c=[];if(n.length){var l=n;n=[],l.forEach(a),c=n}var d=function(){var h=c;c=[],h.forEach(a)},f=function(){return Promise.resolve().then(d)};f(),n={push:function(h){c.push(h),f()},filter:function(h){return c=c.filter(h),n}}}};return s}function wg(e,t){return t===void 0&&(t=PC),BC(e,t)}function bg(e){e===void 0&&(e={});var t=BC(null);return t.options=Jt({async:!0,ssr:!1},e),t}var _C=function(e){var t=e.sideCar,n=yg(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return P.createElement(r,Jt({},n))};_C.isSideCarExport=!0;function TC(e,t){return e.useMedium(t),_C}var OC=bg(),wp=function(){},Vf=P.forwardRef(function(e,t){var n=P.useRef(null),r=P.useState({onScrollCapture:wp,onWheelCapture:wp,onTouchMoveCapture:wp}),s=r[0],a=r[1],c=e.forwardProps,l=e.children,d=e.className,f=e.removeScrollBar,h=e.enabled,p=e.shards,m=e.sideCar,y=e.noIsolation,v=e.inert,w=e.allowPinchZoom,C=e.as,A=C===void 0?"div":C,I=e.gapMode,S=yg(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),j=m,N=vg([n,t]),T=Jt(Jt({},S),s);return P.createElement(P.Fragment,null,h&&P.createElement(j,{sideCar:OC,removeScrollBar:f,shards:p,noIsolation:y,inert:v,setCallbacks:a,allowPinchZoom:!!w,lockRef:n,gapMode:I}),c?P.cloneElement(P.Children.only(l),Jt(Jt({},T),{ref:N})):P.createElement(A,Jt({},T,{className:d,ref:N}),l))});Vf.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Vf.classNames={fullWidth:Kc,zeroRight:Gc};var LT=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function UT(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=LT();return t&&e.setAttribute("nonce",t),e}function zT(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function WT(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var $T=function(){var e=0,t=null;return{add:function(n){e==0&&(t=UT())&&(zT(t,n),WT(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},qT=function(){var e=$T();return function(t,n){P.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},xg=function(){var e=qT(),t=function(n){var r=n.styles,s=n.dynamic;return e(r,s),null};return t},HT={left:0,top:0,right:0,gap:0},bp=function(e){return parseInt(e||"",10)||0},VT=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],s=t[e==="padding"?"paddingRight":"marginRight"];return[bp(n),bp(r),bp(s)]},QT=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return HT;var t=VT(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},GT=xg(),pa="data-scroll-locked",KT=function(e,t,n,r){var s=e.left,a=e.top,c=e.right,l=e.gap;return n===void 0&&(n="margin"),`
1671
- .`.concat(RT,` {
1672
- overflow: hidden `).concat(r,`;
1673
- padding-right: `).concat(l,"px ").concat(r,`;
1674
- }
1675
- body[`).concat(pa,`] {
1676
- overflow: hidden `).concat(r,`;
1677
- overscroll-behavior: contain;
1678
- `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
1679
- padding-left: `.concat(s,`px;
1680
- padding-top: `).concat(a,`px;
1681
- padding-right: `).concat(c,`px;
1682
- margin-left:0;
1683
- margin-top:0;
1684
- margin-right: `).concat(l,"px ").concat(r,`;
1685
- `),n==="padding"&&"padding-right: ".concat(l,"px ").concat(r,";")].filter(Boolean).join(""),`
1686
- }
1687
-
1688
- .`).concat(Gc,` {
1689
- right: `).concat(l,"px ").concat(r,`;
1690
- }
1691
-
1692
- .`).concat(Kc,` {
1693
- margin-right: `).concat(l,"px ").concat(r,`;
1694
- }
1695
-
1696
- .`).concat(Gc," .").concat(Gc,` {
1697
- right: 0 `).concat(r,`;
1698
- }
1699
-
1700
- .`).concat(Kc," .").concat(Kc,` {
1701
- margin-right: 0 `).concat(r,`;
1702
- }
1703
-
1704
- body[`).concat(pa,`] {
1705
- `).concat(MT,": ").concat(l,`px;
1706
- }
1707
- `)},E6=function(){var e=parseInt(document.body.getAttribute(pa)||"0",10);return isFinite(e)?e:0},YT=function(){P.useEffect(function(){return document.body.setAttribute(pa,(E6()+1).toString()),function(){var e=E6()-1;e<=0?document.body.removeAttribute(pa):document.body.setAttribute(pa,e.toString())}},[])},RC=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,s=r===void 0?"margin":r;YT();var a=P.useMemo(function(){return QT(s)},[s]);return P.createElement(GT,{styles:KT(a,!t,s,n?"":"!important")})},Ym=!1;if(typeof window<"u")try{var _d=Object.defineProperty({},"passive",{get:function(){return Ym=!0,!0}});window.addEventListener("test",_d,_d),window.removeEventListener("test",_d,_d)}catch{Ym=!1}var Zi=Ym?{passive:!1}:!1,JT=function(e){return e.tagName==="TEXTAREA"},MC=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!JT(e)&&n[t]==="visible")},ZT=function(e){return MC(e,"overflowY")},XT=function(e){return MC(e,"overflowX")},A6=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var s=DC(e,r);if(s){var a=FC(e,r),c=a[1],l=a[2];if(c>l)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},eO=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},tO=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},DC=function(e,t){return e==="v"?ZT(t):XT(t)},FC=function(e,t){return e==="v"?eO(t):tO(t)},nO=function(e,t){return e==="h"&&t==="rtl"?-1:1},rO=function(e,t,n,r,s){var a=nO(e,window.getComputedStyle(t).direction),c=a*r,l=n.target,d=t.contains(l),f=!1,h=c>0,p=0,m=0;do{var y=FC(e,l),v=y[0],w=y[1],C=y[2],A=w-C-a*v;(v||A)&&DC(e,l)&&(p+=A,m+=v),l instanceof ShadowRoot?l=l.host:l=l.parentNode}while(!d&&l!==document.body||d&&(t.contains(l)||t===l));return(h&&Math.abs(p)<1||!h&&Math.abs(m)<1)&&(f=!0),f},Td=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},k6=function(e){return[e.deltaX,e.deltaY]},S6=function(e){return e&&"current"in e?e.current:e},oO=function(e,t){return e[0]===t[0]&&e[1]===t[1]},sO=function(e){return`
1708
- .block-interactivity-`.concat(e,` {pointer-events: none;}
1709
- .allow-interactivity-`).concat(e,` {pointer-events: all;}
1710
- `)},iO=0,Xi=[];function aO(e){var t=P.useRef([]),n=P.useRef([0,0]),r=P.useRef(),s=P.useState(iO++)[0],a=P.useState(xg)[0],c=P.useRef(e);P.useEffect(function(){c.current=e},[e]),P.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(s));var w=NC([e.lockRef.current],(e.shards||[]).map(S6),!0).filter(Boolean);return w.forEach(function(C){return C.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),w.forEach(function(C){return C.classList.remove("allow-interactivity-".concat(s))})}}},[e.inert,e.lockRef.current,e.shards]);var l=P.useCallback(function(w,C){if("touches"in w&&w.touches.length===2||w.type==="wheel"&&w.ctrlKey)return!c.current.allowPinchZoom;var A=Td(w),I=n.current,S="deltaX"in w?w.deltaX:I[0]-A[0],j="deltaY"in w?w.deltaY:I[1]-A[1],N,T=w.target,B=Math.abs(S)>Math.abs(j)?"h":"v";if("touches"in w&&B==="h"&&T.type==="range")return!1;var O=A6(B,T);if(!O)return!0;if(O?N=B:(N=B==="v"?"h":"v",O=A6(B,T)),!O)return!1;if(!r.current&&"changedTouches"in w&&(S||j)&&(r.current=N),!N)return!0;var R=r.current||N;return rO(R,C,w,R==="h"?S:j)},[]),d=P.useCallback(function(w){var C=w;if(!(!Xi.length||Xi[Xi.length-1]!==a)){var A="deltaY"in C?k6(C):Td(C),I=t.current.filter(function(N){return N.name===C.type&&(N.target===C.target||C.target===N.shadowParent)&&oO(N.delta,A)})[0];if(I&&I.should){C.cancelable&&C.preventDefault();return}if(!I){var S=(c.current.shards||[]).map(S6).filter(Boolean).filter(function(N){return N.contains(C.target)}),j=S.length>0?l(C,S[0]):!c.current.noIsolation;j&&C.cancelable&&C.preventDefault()}}},[]),f=P.useCallback(function(w,C,A,I){var S={name:w,delta:C,target:A,should:I,shadowParent:cO(A)};t.current.push(S),setTimeout(function(){t.current=t.current.filter(function(j){return j!==S})},1)},[]),h=P.useCallback(function(w){n.current=Td(w),r.current=void 0},[]),p=P.useCallback(function(w){f(w.type,k6(w),w.target,l(w,e.lockRef.current))},[]),m=P.useCallback(function(w){f(w.type,Td(w),w.target,l(w,e.lockRef.current))},[]);P.useEffect(function(){return Xi.push(a),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:m}),document.addEventListener("wheel",d,Zi),document.addEventListener("touchmove",d,Zi),document.addEventListener("touchstart",h,Zi),function(){Xi=Xi.filter(function(w){return w!==a}),document.removeEventListener("wheel",d,Zi),document.removeEventListener("touchmove",d,Zi),document.removeEventListener("touchstart",h,Zi)}},[]);var y=e.removeScrollBar,v=e.inert;return P.createElement(P.Fragment,null,v?P.createElement(a,{styles:sO(s)}):null,y?P.createElement(RC,{gapMode:e.gapMode}):null)}function cO(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const lO=TC(OC,aO);var LC=P.forwardRef(function(e,t){return P.createElement(Vf,Jt({},e,{ref:t,sideCar:lO}))});LC.classNames=Vf.classNames;function j6(e){var t=e.match(/^var\((.*)\)$/);return t?t[1]:e}function uO(e,t){var n=e;for(var r of t){if(!(r in n))throw new Error("Path ".concat(t.join(" -> ")," does not exist in object"));n=n[r]}return n}function UC(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],r={};for(var s in e){var a=e[s],c=[...n,s];typeof a=="string"||typeof a=="number"||a==null?r[s]=t(a,c):typeof a=="object"&&!Array.isArray(a)?r[s]=UC(a,t,c):console.warn('Skipping invalid key "'.concat(c.join("."),'". Should be a string, number, null or object. Received: "').concat(Array.isArray(a)?"Array":typeof a,'"'))}return r}function I6(e,t){var n={};if(typeof t=="object"){var r=e;UC(t,(l,d)=>{if(l!=null){var f=uO(r,d);n[j6(f)]=String(l)}})}else{var s=e;for(var a in s){var c=s[a];c!=null&&(n[j6(a)]=c)}}return Object.defineProperty(n,"toString",{value:function(){return Object.keys(this).map(d=>"".concat(d,":").concat(this[d])).join(";")},writable:!1}),n}var qc={exports:{}},dO=qc.exports,N6;function fO(){return N6||(N6=1,(function(e,t){(function(n,r){var s="1.0.41",a="",c="?",l="function",d="undefined",f="object",h="string",p="major",m="model",y="name",v="type",w="vendor",C="version",A="architecture",I="console",S="mobile",j="tablet",N="smarttv",T="wearable",B="embedded",O=500,R="Amazon",W="Apple",H="ASUS",K="BlackBerry",Q="Browser",ae="Chrome",q="Edge",ee="Firefox",te="Google",U="Honor",Y="Huawei",Z="Lenovo",F="LG",X="Microsoft",pe="Motorola",ne="Nvidia",oe="OnePlus",fe="Opera",ge="OPPO",Ie="Samsung",Be="Sharp",Le="Sony",_e="Xiaomi",Te="Zebra",dt="Facebook",tt="Chromium OS",ft="Mac OS",ze=" Browser",ht=function(Oe,Ue){var Ne={};for(var He in Oe)Ue[He]&&Ue[He].length%2===0?Ne[He]=Ue[He].concat(Oe[He]):Ne[He]=Oe[He];return Ne},Ze=function(Oe){for(var Ue={},Ne=0;Ne<Oe.length;Ne++)Ue[Oe[Ne].toUpperCase()]=Oe[Ne];return Ue},gt=function(Oe,Ue){return typeof Oe===h?It(Ue).indexOf(It(Oe))!==-1:!1},It=function(Oe){return Oe.toLowerCase()},qn=function(Oe){return typeof Oe===h?Oe.replace(/[^\d\.]/g,a).split(".")[0]:r},Sr=function(Oe,Ue){if(typeof Oe===h)return Oe=Oe.replace(/^\s\s*/,a),typeof Ue===d?Oe:Oe.substring(0,O)},ir=function(Oe,Ue){for(var Ne=0,He,Bn,at,Fe,ke,Wt;Ne<Ue.length&&!ke;){var jr=Ue[Ne],ar=Ue[Ne+1];for(He=Bn=0;He<jr.length&&!ke&&jr[He];)if(ke=jr[He++].exec(Oe),ke)for(at=0;at<ar.length;at++)Wt=ke[++Bn],Fe=ar[at],typeof Fe===f&&Fe.length>0?Fe.length===2?typeof Fe[1]==l?this[Fe[0]]=Fe[1].call(this,Wt):this[Fe[0]]=Fe[1]:Fe.length===3?typeof Fe[1]===l&&!(Fe[1].exec&&Fe[1].test)?this[Fe[0]]=Wt?Fe[1].call(this,Wt,Fe[2]):r:this[Fe[0]]=Wt?Wt.replace(Fe[1],Fe[2]):r:Fe.length===4&&(this[Fe[0]]=Wt?Fe[3].call(this,Wt.replace(Fe[1],Fe[2])):r):this[Fe]=Wt||r;Ne+=2}},Xt=function(Oe,Ue){for(var Ne in Ue)if(typeof Ue[Ne]===f&&Ue[Ne].length>0){for(var He=0;He<Ue[Ne].length;He++)if(gt(Ue[Ne][He],Oe))return Ne===c?r:Ne}else if(gt(Ue[Ne],Oe))return Ne===c?r:Ne;return Ue.hasOwnProperty("*")?Ue["*"]:Oe},bs={"1.0":"/8","1.2":"/1","1.3":"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"},xs={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2","8.1":"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},Nn={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[C,[y,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[C,[y,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[y,C],[/opios[\/ ]+([\w\.]+)/i],[C,[y,fe+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[C,[y,fe+" GX"]],[/\bopr\/([\w\.]+)/i],[C,[y,fe]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[C,[y,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[C,[y,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[y,C],[/quark(?:pc)?\/([-\w\.]+)/i],[C,[y,"Quark"]],[/\bddg\/([\w\.]+)/i],[C,[y,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[C,[y,"UC"+Q]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[C,[y,"WeChat"]],[/konqueror\/([\w\.]+)/i],[C,[y,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[C,[y,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[C,[y,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[C,[y,"Smart Lenovo "+Q]],[/(avast|avg)\/([\w\.]+)/i],[[y,/(.+)/,"$1 Secure "+Q],C],[/\bfocus\/([\w\.]+)/i],[C,[y,ee+" Focus"]],[/\bopt\/([\w\.]+)/i],[C,[y,fe+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[C,[y,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[C,[y,"Dolphin"]],[/coast\/([\w\.]+)/i],[C,[y,fe+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[C,[y,"MIUI"+ze]],[/fxios\/([\w\.-]+)/i],[C,[y,ee]],[/\bqihoobrowser\/?([\w\.]*)/i],[C,[y,"360"]],[/\b(qq)\/([\w\.]+)/i],[[y,/(.+)/,"$1Browser"],C],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[y,/(.+)/,"$1"+ze],C],[/samsungbrowser\/([\w\.]+)/i],[C,[y,Ie+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[C,[y,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[y,"Sogou Mobile"],C],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[y,C],[/(lbbrowser|rekonq)/i,/\[(linkedin)app\]/i],[y],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[C,y],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[y,dt],C],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/(daum)apps[\/ ]([\w\.]+)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[y,C],[/\bgsa\/([\w\.]+) .*safari\//i],[C,[y,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[C,[y,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[C,[y,ae+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[y,ae+" WebView"],C],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[C,[y,"Android "+Q]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[y,C],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[C,[y,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[C,y],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[y,[C,Xt,bs]],[/(webkit|khtml)\/([\w\.]+)/i],[y,C],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[y,"Netscape"],C],[/(wolvic|librewolf)\/([\w\.]+)/i],[y,C],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[C,[y,ee+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(amaya|dillo|doris|icab|ladybird|lynx|mosaic|netsurf|obigo|polaris|w3m|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[y,[C,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[y,[C,/master.|lts./,""]]],cpu:[[/\b((amd|x|x86[-_]?|wow|win)64)\b/i],[[A,"amd64"]],[/(ia32(?=;))/i,/\b((i[346]|x)86)(pc)?\b/i],[[A,"ia32"]],[/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i],[[A,"arm64"]],[/\b(arm(v[67])?ht?n?[fl]p?)\b/i],[[A,"armhf"]],[/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i],[[A,"arm"]],[/((ppc|powerpc)(64)?)( mac|;|\))/i],[[A,/ower/,a,It]],[/ sun4\w[;\)]/i],[[A,"sparc"]],[/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i],[[A,It]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[m,[w,Ie],[v,j]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[m,[w,Ie],[v,S]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[m,[w,W],[v,S]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[m,[w,W],[v,j]],[/(macintosh);/i],[m,[w,W]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[m,[w,Be],[v,S]],[/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i],[m,[w,U],[v,j]],[/honor([-\w ]+)[;\)]/i],[m,[w,U],[v,S]],[/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i],[m,[w,Y],[v,j]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[m,[w,Y],[v,S]],[/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,/\b((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i],[[m,/_/g," "],[w,_e],[v,j]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i,/ ([\w ]+) miui\/v?\d/i],[[m,/_/g," "],[w,_e],[v,S]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[m,[w,ge],[v,S]],[/\b(opd2(\d{3}a?))(?: bui|\))/i],[m,[w,Xt,{OnePlus:["304","403","203"],"*":ge}],[v,j]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[m,[w,"Vivo"],[v,S]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[m,[w,"Realme"],[v,S]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto(?! 360)[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[m,[w,pe],[v,S]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[m,[w,pe],[v,j]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[m,[w,F],[v,j]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv|watch)\w+)/i,/\blg-?([\d\w]+) bui/i],[m,[w,F],[v,S]],[/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i],[m,[w,Z],[v,j]],[/(nokia) (t[12][01])/i],[w,m,[v,j]],[/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,/nokia[-_ ]?(([-\w\. ]*))/i],[[m,/_/g," "],[v,S],[w,"Nokia"]],[/(pixel (c|tablet))\b/i],[m,[w,te],[v,j]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[m,[w,te],[v,S]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[m,[w,Le],[v,S]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[m,"Xperia Tablet"],[w,Le],[v,j]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[m,[w,oe],[v,S]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[m,[w,R],[v,j]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[m,/(.+)/g,"Fire Phone $1"],[w,R],[v,S]],[/(playbook);[-\w\),; ]+(rim)/i],[m,w,[v,j]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[m,[w,K],[v,S]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[m,[w,H],[v,j]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[m,[w,H],[v,S]],[/(nexus 9)/i],[m,[w,"HTC"],[v,j]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[w,[m,/_/g," "],[v,S]],[/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])\w*(\)| bui)/i],[m,[w,"TCL"],[v,j]],[/(itel) ((\w+))/i],[[w,It],m,[v,Xt,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[m,[w,"Acer"],[v,j]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[m,[w,"Meizu"],[v,S]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[m,[w,"Ulefone"],[v,S]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[m,[w,"Energizer"],[v,S]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[m,[w,"Cat"],[v,S]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[m,[w,"Smartfren"],[v,S]],[/droid.+; (a(?:015|06[35]|142p?))/i],[m,[w,"Nothing"],[v,S]],[/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i],[m,[w,"Archos"],[v,j]],[/archos ([\w ]+)( b|\))/i,/; (ac[3-6]\d\w{2,8})( b|\))/i],[m,[w,"Archos"],[v,S]],[/(imo) (tab \w+)/i,/(infinix) (x1101b?)/i],[w,m,[v,j]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (hmd|imo) ([\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w ]+?)(?: bui|\)|\/)/i,/(oppo) ?([\w ]+) bui/i],[w,m,[v,S]],[/(kobo)\s(ereader|touch)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[w,m,[v,j]],[/(surface duo)/i],[m,[w,X],[v,j]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[m,[w,"Fairphone"],[v,S]],[/(u304aa)/i],[m,[w,"AT&T"],[v,S]],[/\bsie-(\w*)/i],[m,[w,"Siemens"],[v,S]],[/\b(rct\w+) b/i],[m,[w,"RCA"],[v,j]],[/\b(venue[\d ]{2,7}) b/i],[m,[w,"Dell"],[v,j]],[/\b(q(?:mv|ta)\w+) b/i],[m,[w,"Verizon"],[v,j]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[m,[w,"Barnes & Noble"],[v,j]],[/\b(tm\d{3}\w+) b/i],[m,[w,"NuVision"],[v,j]],[/\b(k88) b/i],[m,[w,"ZTE"],[v,j]],[/\b(nx\d{3}j) b/i],[m,[w,"ZTE"],[v,S]],[/\b(gen\d{3}) b.+49h/i],[m,[w,"Swiss"],[v,S]],[/\b(zur\d{3}) b/i],[m,[w,"Swiss"],[v,j]],[/\b((zeki)?tb.*\b) b/i],[m,[w,"Zeki"],[v,j]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[w,"Dragon Touch"],m,[v,j]],[/\b(ns-?\w{0,9}) b/i],[m,[w,"Insignia"],[v,j]],[/\b((nxa|next)-?\w{0,9}) b/i],[m,[w,"NextBook"],[v,j]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[w,"Voice"],m,[v,S]],[/\b(lvtel\-)?(v1[12]) b/i],[[w,"LvTel"],m,[v,S]],[/\b(ph-1) /i],[m,[w,"Essential"],[v,S]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[m,[w,"Envizen"],[v,j]],[/\b(trio[-\w\. ]+) b/i],[m,[w,"MachSpeed"],[v,j]],[/\btu_(1491) b/i],[m,[w,"Rotor"],[v,j]],[/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i],[m,[w,ne],[v,j]],[/(sprint) (\w+)/i],[w,m,[v,S]],[/(kin\.[onetw]{3})/i],[[m,/\./g," "],[w,X],[v,S]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[m,[w,Te],[v,j]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[m,[w,Te],[v,S]],[/smart-tv.+(samsung)/i],[w,[v,N]],[/hbbtv.+maple;(\d+)/i],[[m,/^/,"SmartTV"],[w,Ie],[v,N]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[w,F],[v,N]],[/(apple) ?tv/i],[w,[m,W+" TV"],[v,N]],[/crkey/i],[[m,ae+"cast"],[w,te],[v,N]],[/droid.+aft(\w+)( bui|\))/i],[m,[w,R],[v,N]],[/(shield \w+ tv)/i],[m,[w,ne],[v,N]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[m,[w,Be],[v,N]],[/(bravia[\w ]+)( bui|\))/i],[m,[w,Le],[v,N]],[/(mi(tv|box)-?\w+) bui/i],[m,[w,_e],[v,N]],[/Hbbtv.*(technisat) (.*);/i],[w,m,[v,N]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[w,Sr],[m,Sr],[v,N]],[/droid.+; ([\w- ]+) (?:android tv|smart[- ]?tv)/i],[m,[v,N]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[v,N]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[w,m,[v,I]],[/droid.+; (shield)( bui|\))/i],[m,[w,ne],[v,I]],[/(playstation \w+)/i],[m,[w,Le],[v,I]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[m,[w,X],[v,I]],[/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i],[m,[w,Ie],[v,T]],[/((pebble))app/i,/(asus|google|lg|oppo) ((pixel |zen)?watch[\w ]*)( bui|\))/i],[w,m,[v,T]],[/(ow(?:19|20)?we?[1-3]{1,3})/i],[m,[w,ge],[v,T]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[m,[w,W],[v,T]],[/(opwwe\d{3})/i],[m,[w,oe],[v,T]],[/(moto 360)/i],[m,[w,pe],[v,T]],[/(smartwatch 3)/i],[m,[w,Le],[v,T]],[/(g watch r)/i],[m,[w,F],[v,T]],[/droid.+; (wt63?0{2,3})\)/i],[m,[w,Te],[v,T]],[/droid.+; (glass) \d/i],[m,[w,te],[v,T]],[/(pico) (4|neo3(?: link|pro)?)/i],[w,m,[v,T]],[/; (quest( \d| pro)?)/i],[m,[w,dt],[v,T]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[w,[v,B]],[/(aeobc)\b/i],[m,[w,R],[v,B]],[/(homepod).+mac os/i],[m,[w,W],[v,B]],[/windows iot/i],[[v,B]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[m,[v,S]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[m,[v,j]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[v,j]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[v,S]],[/droid .+?; ([\w\. -]+)( bui|\))/i],[m,[w,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[C,[y,q+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[y,C],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[C,[y,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[y,C],[/ladybird\//i],[[y,"LibWeb"]],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[C,y]],os:[[/microsoft (windows) (vista|xp)/i],[y,C],[/(windows (?:phone(?: os)?|mobile|iot))[\/ ]?([\d\.\w ]*)/i],[y,[C,Xt,xs]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[C,Xt,xs],[y,"Windows"]],[/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[C,/_/g,"."],[y,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[y,ft],[C,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[C,y],[/(ubuntu) ([\w\.]+) like android/i],[[y,/(.+)/,"$1 Touch"],C],[/(android|bada|blackberry|kaios|maemo|meego|openharmony|qnx|rim tablet os|sailfish|series40|symbian|tizen|webos)\w*[-\/; ]?([\d\.]*)/i],[y,C],[/\(bb(10);/i],[C,[y,K]],[/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i],[C,[y,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[C,[y,ee+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[C,[y,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[C,[y,"watchOS"]],[/crkey\/([\d\.]+)/i],[C,[y,ae+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[y,tt],C],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux)(?: arm\w*| x86\w*| ?)([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[y,C],[/(sunos) ?([\w\.\d]*)/i],[[y,"Solaris"],C],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[y,C]]},Mt=function(Oe,Ue){if(typeof Oe===f&&(Ue=Oe,Oe=r),!(this instanceof Mt))return new Mt(Oe,Ue).getResult();var Ne=typeof n!==d&&n.navigator?n.navigator:r,He=Oe||(Ne&&Ne.userAgent?Ne.userAgent:a),Bn=Ne&&Ne.userAgentData?Ne.userAgentData:r,at=Ue?ht(Nn,Ue):Nn,Fe=Ne&&Ne.userAgent==He;return this.getBrowser=function(){var ke={};return ke[y]=r,ke[C]=r,ir.call(ke,He,at.browser),ke[p]=qn(ke[C]),Fe&&Ne&&Ne.brave&&typeof Ne.brave.isBrave==l&&(ke[y]="Brave"),ke},this.getCPU=function(){var ke={};return ke[A]=r,ir.call(ke,He,at.cpu),ke},this.getDevice=function(){var ke={};return ke[w]=r,ke[m]=r,ke[v]=r,ir.call(ke,He,at.device),Fe&&!ke[v]&&Bn&&Bn.mobile&&(ke[v]=S),Fe&&ke[m]=="Macintosh"&&Ne&&typeof Ne.standalone!==d&&Ne.maxTouchPoints&&Ne.maxTouchPoints>2&&(ke[m]="iPad",ke[v]=j),ke},this.getEngine=function(){var ke={};return ke[y]=r,ke[C]=r,ir.call(ke,He,at.engine),ke},this.getOS=function(){var ke={};return ke[y]=r,ke[C]=r,ir.call(ke,He,at.os),Fe&&!ke[y]&&Bn&&Bn.platform&&Bn.platform!="Unknown"&&(ke[y]=Bn.platform.replace(/chrome os/i,tt).replace(/macos/i,ft)),ke},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return He},this.setUA=function(ke){return He=typeof ke===h&&ke.length>O?Sr(ke,O):ke,this},this.setUA(He),this};Mt.VERSION=s,Mt.BROWSER=Ze([y,C,p]),Mt.CPU=Ze([A]),Mt.DEVICE=Ze([m,w,v,I,S,N,j,T,B]),Mt.ENGINE=Mt.OS=Ze([y,C]),e.exports&&(t=e.exports=Mt),t.UAParser=Mt;var Pn=typeof n!==d&&(n.jQuery||n.Zepto);if(Pn&&!Pn.ua){var dn=new Mt;Pn.ua=dn.getResult(),Pn.ua.get=function(){return dn.getUA()},Pn.ua.set=function(Oe){dn.setUA(Oe);var Ue=dn.getResult();for(var Ne in Ue)Pn.ua[Ne]=Ue[Ne]}}})(typeof window=="object"?window:dO)})(qc,qc.exports)),qc.exports}var hO=fO();/*!
1711
- Copyright (c) 2023 Paul Miller (paulmillr.com)
1712
- The library paulmillr-qr is dual-licensed under the Apache 2.0 OR MIT license.
1713
- You can select a license of your choice.
1714
- Licensed under the Apache License, Version 2.0 (the "License");
1715
- you may not use this file except in compliance with the License.
1716
- You may obtain a copy of the License at
1717
-
1718
- http://www.apache.org/licenses/LICENSE-2.0
1719
-
1720
- Unless required by applicable law or agreed to in writing, software
1721
- distributed under the License is distributed on an "AS IS" BASIS,
1722
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1723
- See the License for the specific language governing permissions and
1724
- limitations under the License.
1725
- */const Lc={newline:10,reset:27};function pO(e){if(!Number.isSafeInteger(e))throw new Error(`integer expected: ${e}`)}function mO(e){if(!Number.isSafeInteger(e)||e<1||e>40)throw new Error(`Invalid version=${e}. Expected number [1..40]`)}function Ms(e,t){return e.toString(2).padStart(t,"0")}function P6(e,t){const n=e%t;return n>=0?n:t+n}function Rr(e,t){return new Array(e).fill(t)}function xp(e){return e=e-(e>>>1&1431655765),e=(e&858993459)+(e>>>2&858993459),(e+(e>>>4)&252645135)*16843009>>>24}function B6(e){let t=0,n=0;for(const a of e)t=Math.max(t,a.length),n+=a.length;const r=new Uint8Array(n);let s=0;for(let a=0;a<t;a++)for(const c of e)a<c.length&&(r[s++]=c[a]);return r}function gO(){let e,t=1/0;return{add(n,r){n>=t||(e=r,t=n)},get:()=>e,score:()=>t}}function _6(e){return{has:t=>e.includes(t),decode:t=>{if(!Array.isArray(t)||t.length&&typeof t[0]!="string")throw new Error("alphabet.decode input should be array of strings");return t.map(n=>{if(typeof n!="string")throw new Error(`alphabet.decode: not string element=${n}`);const r=e.indexOf(n);if(r===-1)throw new Error(`Unknown letter: "${n}". Allowed: ${e}`);return r})},encode:t=>{if(!Array.isArray(t)||t.length&&typeof t[0]!="number")throw new Error("alphabet.encode input should be an array of numbers");return t.map(n=>{if(pO(n),n<0||n>=e.length)throw new Error(`Digit index outside alphabet: ${n} (alphabet: ${e.length})`);return e[n]})}}}function T6(e){if(e.length!==32)throw new Error("expects 32 element matrix");const t=[1431655765,858993459,252645135,16711935,65535];for(let n=0;n<5;n++){const r=t[n]>>>0,s=1<<n,a=s<<1;for(let c=0;c<32;c+=a)for(let l=0;l<s;l++){const d=c+l,f=d+s,h=e[d]>>>0,p=e[f]>>>0,m=(h>>>s^p)&r;e[d]=(h^m<<s)>>>0,e[f]=(p^m)>>>0}}}const Uc=e=>1<<(e&31)>>>0,Ds=(e,t)=>t===0?0:t===32?4294967295:(1<<t)-1<<e>>>0;class rn{constructor(t,n){Qo(this,"defined");Qo(this,"value");Qo(this,"tailMask");Qo(this,"words");Qo(this,"fullWords");Qo(this,"height");Qo(this,"width");const{height:r,width:s}=rn.size(t);if(this.height=r,this.width=s,this.tailMask=Ds(0,s&31||32),this.words=Math.ceil(s/32)|0,this.fullWords=Math.floor(s/32)|0,this.value=new Uint32Array(this.words*r),this.defined=new Uint32Array(this.value.length),n){if(n.length!==r)throw new Error(`Bitmap: data height mismatch: exp=${r} got=${n.length}`);for(let a=0;a<r;a++){const c=n[a];if(!c||c.length!==s)throw new Error(`Bitmap: data width mismatch at y=${a}: exp=${s} got=${c==null?void 0:c.length}`);for(let l=0;l<s;l++)this.set(l,a,c[l])}}}static size(t,n){if(typeof t=="number"&&(t={height:t,width:t}),!Number.isSafeInteger(t.height)&&t.height!==1/0)throw new Error(`Bitmap: invalid height=${t.height} (${typeof t.height})`);if(!Number.isSafeInteger(t.width)&&t.width!==1/0)throw new Error(`Bitmap: invalid width=${t.width} (${typeof t.width})`);return n!==void 0&&(t={width:Math.min(t.width,n.width),height:Math.min(t.height,n.height)}),t}static fromString(t){t=t.replace(/^\n+/g,"").replace(/\n+$/g,"");const n=t.split(String.fromCharCode(Lc.newline)),r=n.length;let s;const a=[];for(const c of n){const l=c.split("").map(d=>{if(d==="X")return!0;if(d===" ")return!1;if(d!=="?")throw new Error(`Bitmap.fromString: unknown symbol=${d}`)});if(s!==void 0&&l.length!==s)throw new Error(`Bitmap.fromString different row sizes: width=${s} cur=${l.length}`);s=l.length,a.push(l)}return s===void 0&&(s=0),new rn({height:r,width:s},a)}point(t){return this.get(t.x,t.y)}isInside(t){return 0<=t.x&&t.x<this.width&&0<=t.y&&t.y<this.height}size(t){if(!t)return{height:this.height,width:this.width};const{x:n,y:r}=this.xy(t);return{height:this.height-r,width:this.width-n}}xy(t){if(typeof t=="number"&&(t={x:t,y:t}),!Number.isSafeInteger(t.x))throw new Error(`Bitmap: invalid x=${t.x}`);if(!Number.isSafeInteger(t.y))throw new Error(`Bitmap: invalid y=${t.y}`);return t.x=P6(t.x,this.width),t.y=P6(t.y,this.height),t}wordIndex(t,n){return n*this.words+(t>>>5)}bitIndex(t,n){return{word:this.wordIndex(t,n),bit:t&31}}isDefined(t,n){const r=this.wordIndex(t,n),s=Uc(t);return(this.defined[r]&s)!==0}get(t,n){const r=this.wordIndex(t,n),s=Uc(t);return(this.value[r]&s)!==0}maskWord(t,n,r){const{defined:s,value:a}=this;s[t]|=n,a[t]=a[t]&~n|-r&n}set(t,n,r){r!==void 0&&this.maskWord(this.wordIndex(t,n),Uc(t),r)}fillRectConst(t,n,r,s,a){if(r<=0||s<=0||a===void 0)return;const{value:c,defined:l,words:d}=this,f=t>>>5,h=t+r-1>>>5,p=t&31,m=t+r-1&31;for(let y=0;y<s;y++){const v=(n+y)*d;if(f===h){const w=Ds(p,m-p+1);this.maskWord(v+f,w,a);continue}this.maskWord(v+f,Ds(p,32-p),a);for(let w=f+1;w<h;w++)l[v+w]=4294967295,c[v+w]=a?4294967295:0;this.maskWord(v+h,Ds(0,m+1),a)}}rectWords(t,n,r,s,a){for(let c=0;c<s;c++){const l=n+c;for(let d=0;d<r;){const f=t+d,{bit:h,word:p}=this.bitIndex(f,l),m=Math.min(32-h,r-d);a(p,f,d,c,m),d+=m}}}rect(t,n,r){const{x:s,y:a}=this.xy(t),{height:c,width:l}=rn.size(n,this.size({x:s,y:a}));if(typeof r!="function")return this.fillRectConst(s,a,l,c,r),this;const{defined:d,value:f}=this;return this.rectWords(s,a,l,c,(h,p,m,y,v)=>{let w=0,C=f[h];for(let A=0;A<v;A++){const I=Uc(p+A),S=r({x:m+A,y},(C&I)!==0);S!==void 0&&(w|=I,C=C&~I|-S&I)}d[h]|=w,f[h]=C}),this}rectRead(t,n,r){const{x:s,y:a}=this.xy(t),{height:c,width:l}=rn.size(n,this.size({x:s,y:a})),{value:d}=this;return this.rectWords(s,a,l,c,(f,h,p,m,y)=>{const v=d[f];for(let w=0;w<y;w++){const C=Uc(h+w);r({x:p+w,y:m},(v&C)!==0)}}),this}hLine(t,n,r){return this.rect(t,{width:n,height:1},r)}vLine(t,n,r){return this.rect(t,{width:1,height:n},r)}border(t=2,n){const r=this.height+2*t,s=this.width+2*t,a=new rn({height:r,width:s});return a.rect(0,1/0,n),a.embed({x:t,y:t},this),a}embed(t,n){const{x:r,y:s}=this.xy(t),{height:a,width:c}=rn.size(n.size(),this.size({x:r,y:s}));if(c<=0||a<=0)return this;const{value:l,defined:d}=this,{words:f,value:h}=n;for(let p=0;p<a;p++){const m=p*f;for(let y=0;y<c;){const v=r+y,{word:w,bit:C}=this.bitIndex(v,s+p),{word:A,bit:I}=n.bitIndex(y,p),S=Math.min(32-C,c-y),j=h[A],N=I&&A+1<m+f?h[A+1]:0,T=I?(j>>>I|N<<32-I)>>>0:j,B=Ds(C,S),O=(T&Ds(0,S))<<C>>>0;d[w]|=B,l[w]=l[w]&~B|O,y+=S}}return this}rectSlice(t,n=this.size()){const{x:r,y:s}=this.xy(t),{height:a,width:c}=rn.size(n,this.size({x:r,y:s})),l=new rn({height:a,width:c});return this.rectRead({x:r,y:s},{height:a,width:c},(d,f)=>{this.isDefined(r+d.x,s+d.y)&&l.set(d.x,d.y,f)}),l}transpose(){const{height:t,width:n,value:r,defined:s,words:a}=this,c=new rn({height:n,width:t}),{words:l,value:d,defined:f,tailMask:h}=c,p=new Uint32Array(32),m=new Uint32Array(32);for(let y=0;y<t;y+=32)for(let v=0;v<a;v++){const w=Math.min(32,t-y);for(let C=0;C<w;C++){const A=this.wordIndex(32*v,y+C);p[C]=r[A],m[C]=s[A]}p.fill(0,w),m.fill(0,w),T6(p),T6(m);for(let C=0;C<32;C++){const A=v*32+C;if(A>=n)break;const I=c.wordIndex(y,A),S=y>>>5===l-1?h:4294967295;d[I]=p[C]&S,f[I]=m[C]&S}}return c}negate(){const t=this.defined.length;for(let n=0;n<t;n++)this.value[n]=~this.value[n],this.defined[n]=4294967295;return this}scale(t){if(!Number.isSafeInteger(t)||t>1024)throw new Error(`invalid scale factor: ${t}`);const{height:n,width:r}=this;return new rn({height:t*n,width:t*r}).rect({x:0,y:0},1/0,({x:a,y:c})=>this.get(a/t|0,c/t|0))}clone(){const t=new rn(this.size());return t.defined.set(this.defined),t.value.set(this.value),t}assertDrawn(){const{height:t,width:n,defined:r,tailMask:s,fullWords:a,words:c}=this;if(!(!t||!n))for(let l=0;l<t;l++){const d=l*c;for(let f=0;f<a;f++)if(r[d+f]!==4294967295)throw new Error("Invalid color type=undefined");if(c!==a&&(r[d+a]&s)!==s)throw new Error("Invalid color type=undefined")}}countPatternInRow(t,n,...r){if(n<=0||n>=32)throw new Error("wrong patternLen");const s=(1<<n)-1,{width:a,value:c,words:l}=this;let d=0;const f=this.wordIndex(0,t);for(let h=0,p=0;h<l;h++){const m=c[f+h],y=h===l-1&&a&31||32;for(let v=0;v<y;v++)if(p=(p<<1|m>>>v&1)&s,!(h*32+v+1<n)){for(const w of r)if(p===w){d++;break}}}return d}getRuns(t,n){const{width:r,value:s,words:a}=this;if(r===0)return;let c=0,l;const d=this.wordIndex(0,t);for(let f=0;f<a;f++){const h=s[d+f],p=f===a-1&&r&31||32;for(let m=0;m<p;m++){const y=(h&1<<m)!==0;if(y===l){c++;continue}l!==void 0&&n(c,l),l=y,c=1}}l!==void 0&&n(c,l)}popcnt(){const{height:t,width:n,words:r,fullWords:s,tailMask:a}=this;if(!t||!n)return 0;let c=0;for(let l=0;l<t;l++){const d=l*r;for(let f=0;f<s;f++)c+=xp(this.value[d+f]);r!==s&&(c+=xp(this.value[d+s]&a))}return c}countBoxes2x2(t){const{width:n,words:r}=this;if(n<2||(t|0)<0||t+1>=this.height)return 0;const s=this.wordIndex(0,t)|0,a=this.wordIndex(0,t+1)|0,l=(n&31)===0?2147483647:Ds(0,n-1&31);let d=0;for(let f=0;f<r;f++){const h=this.value[s+f],p=this.value[a+f],m=~(h^p)>>>0,y=f+1<r?this.value[s+f+1]>>>0:0,v=~(h^(h>>>1|(y&1)<<31)>>>0)>>>0,w=f+1<r?this.value[a+f+1]>>>0:0,C=~(p^(p>>>1|(w&1)<<31)>>>0)>>>0;let A=(m&v&C)>>>0;f===r-1&&(A&=l),d+=xp(A)}return d}toString(){const t=String.fromCharCode(Lc.newline);let n="";for(let r=0;r<this.height;r++){let s="";for(let a=0;a<this.width;a++){const c=this.get(a,r);s+=this.isDefined(a,r)?c?"X":" ":"?"}n+=s+(r+1===this.height?"":t)}return n}toRaw(){const t=Array.from({length:this.height},()=>new Array(this.width));for(let n=0;n<this.height;n++){const r=t[n];for(let s=0;s<this.width;s++)r[s]=this.get(s,n)}return t}toASCII(){const{height:t,width:n}=this;let r="";for(let s=0;s<t;s+=2){for(let a=0;a<n;a++){const c=this.get(a,s),l=s+1>=t?!0:this.get(a,s+1);!c&&!l?r+="█":!c&&l?r+="▀":c&&!l?r+="▄":c&&l&&(r+=" ")}r+=String.fromCharCode(Lc.newline)}return r}toTerm(){const t=String.fromCharCode(Lc.reset),n=t+"[0m",r=t+"[1;47m "+n,s=t+"[40m "+n,a=String.fromCharCode(Lc.newline);let c="";for(let l=0;l<this.height;l++){for(let d=0;d<this.width;d++){const f=this.get(d,l);c+=f?s:r}c+=a}return c}toSVG(t=!0){let n=`<svg viewBox="0 0 ${this.width} ${this.height}" xmlns="http://www.w3.org/2000/svg">`,r="",s;return this.rectRead(0,1/0,(a,c)=>{if(!c)return;const{x:l,y:d}=a;if(!t){n+=`<rect x="${l}" y="${d}" width="1" height="1" />`;return}let f=`M${l} ${d}`;if(s){const p=`m${l-s.x} ${d-s.y}`;p.length<=f.length&&(f=p)}const h=l<10?`H${l}`:"h-1";r+=`${f}h1v1${h}Z`,s=a}),t&&(n+=`<path d="${r}"/>`),n+="</svg>",n}toGIF(){const t=l=>[l&255,l>>>8&255],n=[...t(this.width),...t(this.height)],r=[];this.rectRead(0,1/0,(l,d)=>r.push(+(d===!0)));const s=126,a=[71,73,70,56,55,97,...n,246,0,0,255,255,255,...Rr(381,0),44,0,0,0,0,...n,0,7],c=Math.floor(r.length/s);for(let l=0;l<c;l++)a.push(s+1,128,...r.slice(s*l,s*(l+1)).map(d=>+d));return a.push(r.length%s+1,128,...r.slice(c*s).map(l=>+l)),a.push(1,129,0,59),new Uint8Array(a)}toImage(t=!1){const{height:n,width:r}=this.size(),s=new Uint8Array(n*r*(t?3:4));let a=0;for(let c=0;c<n;c++)for(let l=0;l<r;l++){const d=this.get(l,c)?0:255;s[a++]=d,s[a++]=d,s[a++]=d,t||(s[a++]=255)}return{height:n,width:r,data:s}}}const O6=["low","medium","quartile","high"],R6=["numeric","alphanumeric","byte","kanji","eci"],yO=[26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706],vO={low:[7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],medium:[10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],quartile:[13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],high:[17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]},wO={low:[1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],medium:[1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],quartile:[1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],high:[1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]},Zt={size:{encode:e=>21+4*(e-1),decode:e=>(e-17)/4},sizeType:e=>Math.floor((e+7)/17),alignmentPatterns(e){if(e===1)return[];const t=6,n=Zt.size.encode(e)-t-1,r=n-t,s=Math.ceil(r/28);let a=Math.floor(r/s);a%2?a+=1:r%s*2>=s&&(a+=2);const c=[t];for(let l=1;l<s;l++)c.push(n-(s-l)*a);return c.push(n),c},ECCode:{low:1,medium:0,quartile:3,high:2},formatMask:21522,formatBits(e,t){const n=Zt.ECCode[e]<<3|t;let r=n;for(let s=0;s<10;s++)r=r<<1^(r>>9)*1335;return(n<<10|r)^Zt.formatMask},versionBits(e){let t=e;for(let n=0;n<12;n++)t=t<<1^(t>>11)*7973;return e<<12|t},alphabet:{numeric:_6("0123456789"),alphanumerc:_6("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:")},lengthBits(e,t){return{numeric:[10,12,14],alphanumeric:[9,11,13],byte:[8,16,16],kanji:[8,10,12],eci:[0,0,0]}[t][Zt.sizeType(e)]},modeBits:{numeric:"0001",alphanumeric:"0010",byte:"0100",kanji:"1000",eci:"0111"},capacity(e,t){const n=yO[e-1],r=vO[t][e-1],s=wO[t][e-1],a=Math.floor(n/s)-r,c=s-n%s;return{words:r,numBlocks:s,shortBlocks:c,blockLen:a,capacity:(n-r*s)*8,total:(r+a)*s+s-c}}},Cg=[(e,t)=>(e+t)%2==0,(e,t)=>t%2==0,(e,t)=>e%3==0,(e,t)=>(e+t)%3==0,(e,t)=>(Math.floor(t/2)+Math.floor(e/3))%2==0,(e,t)=>e*t%2+e*t%3==0,(e,t)=>(e*t%2+e*t%3)%2==0,(e,t)=>((e+t)%2+e*t%3)%2==0],ye={tables:(e=>{const t=Rr(256,0),n=Rr(256,0);for(let r=0,s=1;r<256;r++)t[r]=s,n[s]=r,s<<=1,s&256&&(s^=e);return{exp:t,log:n}})(285),exp:e=>ye.tables.exp[e],log(e){if(e===0)throw new Error(`GF.log: invalid arg=${e}`);return ye.tables.log[e]%255},mul(e,t){return e===0||t===0?0:ye.tables.exp[(ye.tables.log[e]+ye.tables.log[t])%255]},add:(e,t)=>e^t,pow:(e,t)=>ye.tables.exp[ye.tables.log[e]*t%255],inv(e){if(e===0)throw new Error(`GF.inverse: invalid arg=${e}`);return ye.tables.exp[255-ye.tables.log[e]]},polynomial(e){if(e.length==0)throw new Error("GF.polymomial: invalid length");if(e[0]!==0)return e;let t=0;for(;t<e.length-1&&e[t]==0;t++);return e.slice(t)},monomial(e,t){if(e<0)throw new Error(`GF.monomial: invalid degree=${e}`);if(t==0)return[0];let n=Rr(e+1,0);return n[0]=t,ye.polynomial(n)},degree:e=>e.length-1,coefficient:(e,t)=>e[ye.degree(e)-t],mulPoly(e,t){if(e[0]===0||t[0]===0)return[0];const n=Rr(e.length+t.length-1,0);for(let r=0;r<e.length;r++)for(let s=0;s<t.length;s++)n[r+s]=ye.add(n[r+s],ye.mul(e[r],t[s]));return ye.polynomial(n)},mulPolyScalar(e,t){if(t==0)return[0];if(t==1)return e;const n=Rr(e.length,0);for(let r=0;r<e.length;r++)n[r]=ye.mul(e[r],t);return ye.polynomial(n)},mulPolyMonomial(e,t,n){if(t<0)throw new Error("GF.mulPolyMonomial: invalid degree");if(n==0)return[0];const r=Rr(e.length+t,0);for(let s=0;s<e.length;s++)r[s]=ye.mul(e[s],n);return ye.polynomial(r)},addPoly(e,t){if(e[0]===0)return t;if(t[0]===0)return e;let n=e,r=t;n.length>r.length&&([n,r]=[r,n]);let s=Rr(r.length,0),a=r.length-n.length,c=r.slice(0,a);for(let l=0;l<c.length;l++)s[l]=c[l];for(let l=a;l<r.length;l++)s[l]=ye.add(n[l-a],r[l]);return ye.polynomial(s)},remainderPoly(e,t){const n=Array.from(e);for(let r=0;r<e.length-t.length+1;r++){const s=n[r];if(s!==0)for(let a=1;a<t.length;a++)t[a]!==0&&(n[r+a]=ye.add(n[r+a],ye.mul(t[a],s)))}return n.slice(e.length-t.length+1,n.length)},divisorPoly(e){let t=[1];for(let n=0;n<e;n++)t=ye.mulPoly(t,[1,ye.pow(2,n)]);return t},evalPoly(e,t){if(t==0)return ye.coefficient(e,0);let n=e[0];for(let r=1;r<e.length;r++)n=ye.add(ye.mul(t,n),e[r]);return n},euclidian(e,t,n){ye.degree(e)<ye.degree(t)&&([e,t]=[t,e]);let r=e,s=t,a=[0],c=[1];for(;2*ye.degree(s)>=n;){let f=r,h=a;if(r=s,a=c,r[0]===0)throw new Error("rLast[0] === 0");s=f;let p=[0];const m=ye.inv(r[0]);for(;ye.degree(s)>=ye.degree(r)&&s[0]!==0;){const y=ye.degree(s)-ye.degree(r),v=ye.mul(s[0],m);p=ye.addPoly(p,ye.monomial(y,v)),s=ye.addPoly(s,ye.mulPolyMonomial(r,y,v))}if(p=ye.mulPoly(p,a),c=ye.addPoly(p,h),ye.degree(s)>=ye.degree(r))throw new Error(`Division failed r: ${s}, rLast: ${r}`)}const l=ye.coefficient(c,0);if(l==0)throw new Error("sigmaTilde(0) was zero");const d=ye.inv(l);return[ye.mulPolyScalar(c,d),ye.mulPolyScalar(s,d)]}};function bO(e){return{encode(t){const n=ye.divisorPoly(e),r=Array.from(t);return r.push(...n.slice(0,-1).fill(0)),Uint8Array.from(ye.remainderPoly(r,n))},decode(t){const n=t.slice(),r=ye.polynomial(Array.from(t));let s=Rr(e,0),a=!1;for(let p=0;p<e;p++){const m=ye.evalPoly(r,ye.exp(p));s[s.length-1-p]=m,m!==0&&(a=!0)}if(!a)return n;s=ye.polynomial(s);const c=ye.monomial(e,1),[l,d]=ye.euclidian(c,s,e),f=Rr(ye.degree(l),0);let h=0;for(let p=1;p<256&&h<f.length;p++)ye.evalPoly(l,p)===0&&(f[h++]=ye.inv(p));if(h!==f.length)throw new Error("RS.decode: invalid errors number");for(let p=0;p<f.length;p++){const m=n.length-1-ye.log(f[p]);if(m<0)throw new Error("RS.decode: invalid error location");const y=ye.inv(f[p]);let v=1;for(let w=0;w<f.length;w++)p!==w&&(v=ye.mul(v,ye.add(1,ye.mul(f[w],y))));n[m]=ye.add(n[m],ye.mul(ye.evalPoly(d,y),ye.inv(v)))}return n}}}function xO(e,t){const{words:n,shortBlocks:r,numBlocks:s,blockLen:a,total:c}=Zt.capacity(e,t),l=bO(n);return{encode(d){const f=[],h=[];for(let v=0;v<s;v++){const w=v<r,C=a+(w?0:1);f.push(d.subarray(0,C)),h.push(l.encode(d.subarray(0,C))),d=d.subarray(C)}const p=B6(f),m=B6(h),y=new Uint8Array(p.length+m.length);return y.set(p),y.set(m,p.length),y},decode(d){if(d.length!==c)throw new Error(`interleave.decode: len(data)=${d.length}, total=${c}`);const f=[];for(let m=0;m<s;m++){const y=m<r;f.push(new Uint8Array(n+a+(y?0:1)))}let h=0;for(let m=0;m<a;m++)for(let y=0;y<s;y++)f[y][m]=d[h++];for(let m=r;m<s;m++)f[m][a]=d[h++];for(let m=a;m<a+n;m++)for(let y=0;y<s;y++){const v=y<r;f[y][m+(v?0:1)]=d[h++]}const p=[];for(const m of f)p.push(...Array.from(l.decode(m)).slice(0,-n));return Uint8Array.from(p)}}}function CO(e,t,n,r=!1){const s=Zt.size.encode(e);let a=new rn(s+2);const c=new rn(3).rect(0,3,!0).border(1,!1).border(1,!0).border(1,!1);a=a.embed(0,c).embed({x:-c.width,y:0},c).embed({x:0,y:-c.height},c),a=a.rectSlice(1,s);const l=new rn(1).rect(0,1,!0).border(1,!1).border(1,!0),d=Zt.alignmentPatterns(e);for(const f of d)for(const h of d)a.isDefined(h,f)||a.embed({x:h-2,y:f-2},l);a=a.hLine({x:0,y:6},1/0,({x:f})=>a.isDefined(f,6)?void 0:f%2==0).vLine({x:6,y:0},1/0,({y:f})=>a.isDefined(6,f)?void 0:f%2==0);{const f=Zt.formatBits(t,n),h=p=>!r&&(f>>p&1)==1;for(let p=0;p<6;p++)a.set(8,p,h(p));for(let p=6;p<8;p++)a.set(8,p+1,h(p));for(let p=8;p<15;p++)a.set(8,s-15+p,h(p));for(let p=0;p<8;p++)a.set(s-p-1,8,h(p));for(let p=8;p<9;p++)a.set(15-p-1+1,8,h(p));for(let p=9;p<15;p++)a.set(15-p-1,8,h(p));a.set(8,s-8,!r)}if(e>=7){const f=Zt.versionBits(e);for(let h=0;h<18;h+=1){const p=!r&&(f>>h&1)==1,m=Math.floor(h/3),y=h%3+s-8-3;a.set(y,m,p),a.set(m,y,p)}}return a}function EO(e,t,n){const r=e.height,s=Cg[t];let a=-1,c=r-1;for(let l=r-1;l>0;l-=2){for(l==6&&(l=5);;c+=a){for(let d=0;d<2;d+=1){const f=l-d;e.isDefined(f,c)||n(f,c,s(f,c))}if(c+a<0||c+a>=r)break}a=-a}}function AO(e){let t="numeric";for(let n of e)if(!Zt.alphabet.numeric.has(n)&&(t="alphanumeric",!Zt.alphabet.alphanumerc.has(n)))return"byte";return t}function kO(e){if(typeof e!="string")throw new Error(`utf8ToBytes expected string, got ${typeof e}`);return new Uint8Array(new TextEncoder().encode(e))}function M6(e,t,n,r,s=kO){let a="",c=n.length;if(r==="numeric"){const m=Zt.alphabet.numeric.decode(n.split("")),y=m.length;for(let v=0;v<y-2;v+=3)a+=Ms(m[v]*100+m[v+1]*10+m[v+2],10);y%3===1?a+=Ms(m[y-1],4):y%3===2&&(a+=Ms(m[y-2]*10+m[y-1],7))}else if(r==="alphanumeric"){const m=Zt.alphabet.alphanumerc.decode(n.split("")),y=m.length;for(let v=0;v<y-1;v+=2)a+=Ms(m[v]*45+m[v+1],11);y%2==1&&(a+=Ms(m[y-1],6))}else if(r==="byte"){const m=s(n);c=m.length,a=Array.from(m).map(y=>Ms(y,8)).join("")}else throw new Error("encode: unsupported type");const{capacity:l}=Zt.capacity(e,t),d=Ms(c,Zt.lengthBits(e,r));let f=Zt.modeBits[r]+d+a;if(f.length>l)throw new Error("Capacity overflow");f+="0".repeat(Math.min(4,Math.max(0,l-f.length))),f.length%8&&(f+="0".repeat(8-f.length%8));const h="1110110000010001";for(let m=0;f.length!==l;m++)f+=h[m%h.length];const p=Uint8Array.from(f.match(/(.{8})/g).map(m=>+`0b${m}`));return xO(e,t).encode(p)}function D6(e,t,n,r,s=!1){const a=CO(e,t,r,s);let c=0;const l=8*n.length;if(EO(a,r,(d,f,h)=>{let p=!1;c<l&&(p=(n[c>>>3]>>(7-c&7)&1)!==0,c++),a.set(d,f,p!==h)}),c!==l)throw new Error("QR: bytes left after draw");return a}const zC=e=>{const t=e.map(n=>n?"1":"0").join("");return{len:t.length,n:+`0b${t}`}},WC=[!0,!1,!0,!0,!0,!1,!0],$C=[!1,!1,!1,!1],Od=zC([...WC,...$C]),F6=zC([...$C,...WC]);function SO(e){const{width:t,height:n}=e,r=e.transpose();let s=0;for(let h=0;h<n;h++)e.getRuns(h,p=>{p>=5&&(s+=3+(p-5))});for(let h=0;h<t;h++)r.getRuns(h,p=>{p>=5&&(s+=3+(p-5))});let a=0;for(let h=0;h<n-1;h++)a+=3*e.countBoxes2x2(h);let c=0;for(let h=0;h<n;h++)c+=40*e.countPatternInRow(h,Od.len,Od.n,F6.n);for(let h=0;h<t;h++)c+=40*r.countPatternInRow(h,Od.len,Od.n,F6.n);let l=0;l=e.popcnt();const d=l/(n*t)*100,f=10*Math.floor(Math.abs(d-50)/5);return s+a+c+f}function jO(e,t,n,r){if(r===void 0){const s=gO();for(let a=0;a<Cg.length;a++)s.add(SO(D6(e,t,n,a,!0)),a);r=s.get()}if(r===void 0)throw new Error("Cannot find mask");return D6(e,t,n,r)}function IO(e){if(!O6.includes(e))throw new Error(`Invalid error correction mode=${e}. Expected: ${O6}`)}function NO(e){if(!R6.includes(e))throw new Error(`Encoding: invalid mode=${e}. Expected: ${R6}`);if(e==="kanji"||e==="eci")throw new Error(`Encoding: ${e} is not supported (yet?).`)}function PO(e){if(![0,1,2,3,4,5,6,7].includes(e)||!Cg[e])throw new Error(`Invalid mask=${e}. Expected number [0..7]`)}function BO(e,t="raw",n={}){const r=n.ecc!==void 0?n.ecc:"medium";IO(r);const s=n.encoding!==void 0?n.encoding:AO(e);NO(s),n.mask!==void 0&&PO(n.mask);let a=n.version,c,l=new Error("Unknown error");if(a!==void 0)mO(a),c=M6(a,r,e,s,n.textEncoder);else for(let h=1;h<=40;h++)try{c=M6(h,r,e,s,n.textEncoder),a=h;break}catch(p){l=p}if(!a||!c)throw l;let d=jO(a,r,c,n.mask);d.assertDrawn();const f=n.border===void 0?2:n.border;if(!Number.isSafeInteger(f))throw new Error(`invalid border type=${typeof f}`);if(d=d.border(f,!1),n.scale!==void 0&&(d=d.scale(n.scale)),t==="raw")return d.toRaw();if(t==="ascii")return d.toASCII();if(t==="svg")return d.toSVG(n.optimize);if(t==="gif")return d.toGIF();if(t==="term")return d.toTerm();throw new Error(`Unknown output: ${t}`)}function _O(e,t={}){const{errorCorrection:n,version:r}=t,s=BO(e,"raw",{border:0,ecc:n,scale:1,version:r});return{edgeLength:s.length,finderLength:7,grid:s,value:e}}function Lr(e){const{arena:t,...n}=e;return b.jsxs(Lr.Root,{...n,children:[b.jsx(Lr.Finder,{}),b.jsx(Lr.Cells,{}),t&&b.jsx(Lr.Arena,{children:typeof t=="string"?b.jsx("img",{alt:"Arena",src:t,style:{borderRadius:1,height:"100%",objectFit:"cover",width:"100%"}}):t})]})}(function(e){e.Context=P.createContext(null);function t(a){const{children:c,size:l="100%",value:d,version:f,errorCorrection:h,...p}=a,m=P.useMemo(()=>(P.Children.map(c,S=>!P.isValidElement(S)||typeof S.type=="string"?null:"displayName"in S.type&&S.type.displayName==="Arena"?!0:null)??[]).some(Boolean),[c]),y=P.useMemo(()=>{let S=h;return m&&h==="low"&&(S="medium"),_O(d,{errorCorrection:S,version:f})},[d,m,h,f]),v=1,w=y.edgeLength*v,C=y.finderLength*v/2,A=m?Math.floor(w/4):0,I=P.useMemo(()=>({arenaSize:A,cellSize:v,edgeSize:w,qrcode:y,finderSize:C}),[A,w,y,C]);return b.jsx(e.Context.Provider,{value:I,children:b.jsxs("svg",{...p,width:l,height:l,viewBox:`0 0 ${w} ${w}`,xmlns:"http://www.w3.org/2000/svg",children:[b.jsx("title",{children:"QR Code"}),c]})})}e.Root=t,(function(a){a.displayName="Root"})(t=e.Root||(e.Root={}));function n(a){const{className:c,fill:l,innerClassName:d,radius:f=.25}=a,{cellSize:h,edgeSize:p,finderSize:m}=P.useContext(e.Context);function y({position:v}){let w=m-(m-h)-h/2;v==="top-right"&&(w=p-m-(m-h)-h/2);let C=m-(m-h)-h/2;v==="bottom-left"&&(C=p-m-(m-h)-h/2);let A=m-h*1.5;v==="top-right"&&(A=p-m-h*1.5);let I=m-h*1.5;return v==="bottom-left"&&(I=p-m-h*1.5),b.jsxs(b.Fragment,{children:[b.jsx("rect",{className:c,stroke:l??"currentColor",fill:"transparent",x:w,y:C,width:h+(m-h)*2,height:h+(m-h)*2,rx:2*f*(m-h),ry:2*f*(m-h),strokeWidth:h}),b.jsx("rect",{className:d,fill:l??"currentColor",x:A,y:I,width:h*3,height:h*3,rx:2*f*h,ry:2*f*h})]})}return b.jsxs(b.Fragment,{children:[b.jsx(y,{position:"top-left"}),b.jsx(y,{position:"top-right"}),b.jsx(y,{position:"bottom-left"})]})}e.Finder=n,(function(a){a.displayName="Finder"})(n=e.Finder||(e.Finder={}));function r(a){const{className:c,fill:l="currentColor",inset:d=!0,radius:f=1}=a,{arenaSize:h,cellSize:p,qrcode:m}=P.useContext(e.Context),{edgeLength:y,finderLength:v}=m,w=P.useMemo(()=>{let C="";for(let A=0;A<m.grid.length;A++){const I=m.grid[A];if(I)for(let S=0;S<I.length;S++){if(!I[S])continue;const N=y/2-h/2,T=N+h;if(A>=N&&A<=T&&S>=N&&S<=T)continue;const B=A<v&&S<v,O=A<v&&S>=y-v,R=A>=y-v&&S<v;if(B||O||R)continue;const W=d?p*.1:0,H=(p-W*2)/2,K=S*p+p/2,Q=A*p+p/2,ae=K-H,q=K+H,ee=Q-H,te=Q+H,U=f*H;C+=[`M ${ae+U},${ee}`,`L ${q-U},${ee}`,`A ${U},${U} 0 0,1 ${q},${ee+U}`,`L ${q},${te-U}`,`A ${U},${U} 0 0,1 ${q-U},${te}`,`L ${ae+U},${te}`,`A ${U},${U} 0 0,1 ${ae},${te-U}`,`L ${ae},${ee+U}`,`A ${U},${U} 0 0,1 ${ae+U},${ee}`,"z"].join(" ")}}return C},[h,p,y,v,m.grid,d,f]);return b.jsx("path",{className:c,d:w,fill:l})}e.Cells=r,(function(a){a.displayName="Cells"})(r=e.Cells||(e.Cells={}));function s(a){const{children:c}=a,{arenaSize:l,cellSize:d,edgeSize:f}=P.useContext(e.Context),h=Math.ceil(f/2-l/2),p=l+l%2,m=d/2;return b.jsx("foreignObject",{x:h,y:h,width:p,height:p,children:b.jsx("div",{style:{alignItems:"center",display:"flex",fontSize:1,justifyContent:"center",height:"100%",overflow:"hidden",width:"100%",padding:m,boxSizing:"border-box"},children:c})})}e.Arena=s,(function(a){a.displayName="Arena"})(s=e.Arena||(e.Arena={}))})(Lr||(Lr={}));function TO(e={}){let t,n,r,s;return a=>({id:"baseAccount",name:"Base Account",rdns:"app.base.account",type:"baseAccount",async connect({chainId:c,withCapabilities:l,...d}={}){var f;try{const h=await this.getProvider(),p=c??((f=a.chains[0])==null?void 0:f.id);if(!p)throw new ys;const m=await h.request({method:"wallet_connect",params:[{capabilities:"capabilities"in d&&d.capabilities?d.capabilities:{},chainIds:[le(p),...a.chains.filter(w=>w.id!==p).map(w=>le(w.id))]}]}),y=m.accounts.map(w=>({address:jt(w.address),capabilities:w.capabilities??{}}));let v=Number(m.chainIds[0]);if(n||(n=this.onAccountsChanged.bind(this),h.on("accountsChanged",n)),r||(r=this.onChainChanged.bind(this),h.on("chainChanged",r)),s||(s=this.onDisconnect.bind(this),h.on("disconnect",s)),c&&v!==c){const w=await this.switchChain({chainId:c}).catch(C=>{if(C.code===Ge.code)throw C;return{id:v}});v=(w==null?void 0:w.id)??v}return{accounts:l?y:y.map(w=>w.address),chainId:v}}catch(h){throw/(user closed modal|accounts received is empty|user denied account|request rejected)/i.test(h.message)?new Ge(h):h}},async disconnect(){const c=await this.getProvider();n&&(c.removeListener("accountsChanged",n),n=void 0),r&&(c.removeListener("chainChanged",r),r=void 0),s&&(c.removeListener("disconnect",s),s=void 0),c.disconnect()},async getAccounts(){return(await(await this.getProvider()).request({method:"eth_accounts"})).map(l=>jt(l))},async getChainId(){const l=await(await this.getProvider()).request({method:"eth_chainId"});return Number(l)},async getProvider(){if(!t){const c=(()=>{var f;return typeof e.preference=="string"?{options:e.preference}:{...e.preference,options:((f=e.preference)==null?void 0:f.options)??"all"}})(),{createBaseAccountSDK:l}=await de(async()=>{const{createBaseAccountSDK:f}=await import("./index-CN6n0s2n.js");return{createBaseAccountSDK:f}},[]);t=l({...e,appChainIds:a.chains.map(f=>f.id),preference:c}).getProvider()}return t},async isAuthorized(){try{return!!(await this.getAccounts()).length}catch{return!1}},async switchChain({addEthereumChainParameter:c,chainId:l}){var h,p,m,y;const d=a.chains.find(v=>v.id===l);if(!d)throw new zn(new ys);const f=await this.getProvider();try{return await f.request({method:"wallet_switchEthereumChain",params:[{chainId:le(d.id)}]}),d}catch(v){if(v.code===4902)try{let w;c!=null&&c.blockExplorerUrls?w=c.blockExplorerUrls:w=(h=d.blockExplorers)!=null&&h.default.url?[(p=d.blockExplorers)==null?void 0:p.default.url]:[];let C;(m=c==null?void 0:c.rpcUrls)!=null&&m.length?C=c.rpcUrls:C=[((y=d.rpcUrls.default)==null?void 0:y.http[0])??""];const A={blockExplorerUrls:w,chainId:le(l),chainName:(c==null?void 0:c.chainName)??d.name,iconUrls:c==null?void 0:c.iconUrls,nativeCurrency:(c==null?void 0:c.nativeCurrency)??d.nativeCurrency,rpcUrls:C};return await f.request({method:"wallet_addEthereumChain",params:[A]}),d}catch(w){throw new Ge(w)}throw new zn(v)}},onAccountsChanged(c){c.length===0?this.onDisconnect():a.emitter.emit("change",{accounts:c.map(l=>jt(l))})},onChainChanged(c){const l=Number(c);a.emitter.emit("change",{chainId:l})},async onDisconnect(c){a.emitter.emit("disconnect");const l=await this.getProvider();n&&(l.removeListener("accountsChanged",n),n=void 0),r&&(l.removeListener("chainChanged",r),r=void 0),s&&(l.removeListener("disconnect",s),s=void 0)}})}Eg.type="metaMask";function Eg(e={}){let t,n,r,s,a,c,l,d;return f=>({id:"metaMaskSDK",name:"MetaMask",rdns:["io.metamask","io.metamask.mobile"],type:Eg.type,async setup(){const h=await this.getProvider();h!=null&&h.on&&(c||(c=this.onConnect.bind(this),h.on("connect",c)),s||(s=this.onAccountsChanged.bind(this),h.on("accountsChanged",s)))},async connect({chainId:h,isReconnecting:p,withCapabilities:m}={}){const y=await this.getProvider();l||(l=this.onDisplayUri,y.on("display_uri",l));let v=[];p&&(v=await this.getAccounts().catch(()=>[]));try{let w,C;v!=null&&v.length||(e.connectAndSign||e.connectWith?(e.connectAndSign?w=await t.connectAndSign({msg:e.connectAndSign}):e.connectWith&&(C=await t.connectWith({method:e.connectWith.method,params:e.connectWith.params})),v=await this.getAccounts()):v=(await t.connect()).map(S=>jt(S)));let A=await this.getChainId();if(h&&A!==h){const I=await this.switchChain({chainId:h}).catch(S=>{if(S.code===Ge.code)throw S;return{id:A}});A=(I==null?void 0:I.id)??A}return l&&(y.removeListener("display_uri",l),l=void 0),w?y.emit("connectAndSign",{accounts:v,chainId:A,signResponse:w}):C&&y.emit("connectWith",{accounts:v,chainId:A,connectWithResponse:C}),c&&(y.removeListener("connect",c),c=void 0),s||(s=this.onAccountsChanged.bind(this),y.on("accountsChanged",s)),a||(a=this.onChainChanged.bind(this),y.on("chainChanged",a)),d||(d=this.onDisconnect.bind(this),y.on("disconnect",d)),{accounts:m?v.map(I=>({address:I,capabilities:{}})):v,chainId:A}}catch(w){const C=w;throw C.code===Ge.code?new Ge(C):C.code===Ur.code?new Ur(C):C}},async disconnect(){const h=await this.getProvider();a&&(h.removeListener("chainChanged",a),a=void 0),d&&(h.removeListener("disconnect",d),d=void 0),c||(c=this.onConnect.bind(this),h.on("connect",c)),await t.terminate()},async getAccounts(){return(await(await this.getProvider()).request({method:"eth_accounts"})).map(m=>jt(m))},async getChainId(){const h=await this.getProvider(),p=h.getChainId()||await(h==null?void 0:h.request({method:"eth_chainId"}));return Number(p)},async getProvider(){async function h(){var w,C,A,I,S;const p=await(async()=>{const{default:j}=await de(async()=>{const{default:N}=await import("./metamask-sdk-BpagOCqf.js");return{default:N}},[]);return typeof j!="function"&&typeof j.default=="function"?j.default:j})(),m={};for(const j of f.chains)m[le(j.id)]=(w=D3({chain:j,transports:f.transports}))==null?void 0:w[0];t=new p({_source:"wagmi",forceDeleteProvider:!1,forceInjectProvider:!1,injectProvider:!1,...e,readonlyRPCMap:m,dappMetadata:{...e.dappMetadata,name:(C=e.dappMetadata)!=null&&C.name?(A=e.dappMetadata)==null?void 0:A.name:"wagmi",url:(I=e.dappMetadata)!=null&&I.url?(S=e.dappMetadata)==null?void 0:S.url:typeof window<"u"?window.location.origin:"https://wagmi.sh"},useDeeplink:e.useDeeplink??!0});const y=await t.init(),v=y!=null&&y.activeProvider?y.activeProvider:t.getProvider();if(!v)throw new Fn;return v}return n||(r||(r=h()),n=await r),n},async isAuthorized(){try{return!!(await Ma(()=>Ff(()=>this.getAccounts(),{timeout:200}),{delay:201,retryCount:3})).length}catch{return!1}},async switchChain({addEthereumChainParameter:h,chainId:p}){var C,A;const m=await this.getProvider(),y=f.chains.find(I=>I.id===p);if(!y)throw new zn(new ys);try{return await m.request({method:"wallet_switchEthereumChain",params:[{chainId:le(p)}]}),await v(),await w(p),y}catch(I){const S=I;if(S.code===Ge.code)throw new Ge(S);if(S.code===4902||((A=(C=S==null?void 0:S.data)==null?void 0:C.originalError)==null?void 0:A.code)===4902)try{return await m.request({method:"wallet_addEthereumChain",params:[{blockExplorerUrls:(()=>{const{default:j,...N}=y.blockExplorers??{};if(h!=null&&h.blockExplorerUrls)return h.blockExplorerUrls;if(j)return[j.url,...Object.values(N).map(T=>T.url)]})(),chainId:le(p),chainName:(h==null?void 0:h.chainName)??y.name,iconUrls:h==null?void 0:h.iconUrls,nativeCurrency:(h==null?void 0:h.nativeCurrency)??y.nativeCurrency,rpcUrls:(()=>{var j,N;return(j=h==null?void 0:h.rpcUrls)!=null&&j.length?h.rpcUrls:[((N=y.rpcUrls.default)==null?void 0:N.http[0])??""]})()}]}),await v(),await w(p),y}catch(j){const N=j;throw N.code===Ge.code?new Ge(N):new zn(N)}throw new zn(S)}async function v(){await Ma(async()=>{const I=br(await m.request({method:"eth_chainId"}));if(I!==p)throw new Error("User rejected switch after adding network.");return I},{delay:50,retryCount:20})}async function w(I){await new Promise(S=>{const j=(N=>{"chainId"in N&&N.chainId===I&&(f.emitter.off("change",j),S())});f.emitter.on("change",j),f.emitter.emit("change",{chainId:I})})}},async onAccountsChanged(h){if(h.length===0)if(t.isExtensionActive())this.onDisconnect();else return;else if(f.emitter.listenerCount("connect")){const p=(await this.getChainId()).toString();this.onConnect({chainId:p})}else f.emitter.emit("change",{accounts:h.map(p=>jt(p))})},onChainChanged(h){const p=Number(h);f.emitter.emit("change",{chainId:p})},async onConnect(h){const p=await this.getAccounts();if(p.length===0)return;const m=Number(h.chainId);f.emitter.emit("connect",{accounts:p,chainId:m});const y=await this.getProvider();c&&(y.removeListener("connect",c),c=void 0),s||(s=this.onAccountsChanged.bind(this),y.on("accountsChanged",s)),a||(a=this.onChainChanged.bind(this),y.on("chainChanged",a)),d||(d=this.onDisconnect.bind(this),y.on("disconnect",d))},async onDisconnect(h){const p=await this.getProvider();h&&h.code===1013&&p&&(await this.getAccounts()).length||(f.emitter.emit("disconnect"),a&&(p.removeListener("chainChanged",a),a=void 0),d&&(p.removeListener("disconnect",d),d=void 0),c||(c=this.onConnect.bind(this),p.on("connect",c)))},onDisplayUri(h){f.emitter.emit("message",{type:"display_uri",data:h})}})}Ag.type="safe";function Ag(e={}){const{shimDisconnect:t=!1}=e;let n,r;return s=>({id:"safe",name:"Safe",type:Ag.type,async connect({withCapabilities:a}={}){var f;const c=await this.getProvider();if(!c)throw new Fn;const l=await this.getAccounts(),d=await this.getChainId();return r||(r=this.onDisconnect.bind(this),c.on("disconnect",r)),t&&await((f=s.storage)==null?void 0:f.removeItem("safe.disconnected")),{accounts:a?l.map(h=>({address:h,capabilities:{}})):l,chainId:d}},async disconnect(){var c;const a=await this.getProvider();if(!a)throw new Fn;r&&(a.removeListener("disconnect",r),r=void 0),t&&await((c=s.storage)==null?void 0:c.setItem("safe.disconnected",!0))},async getAccounts(){const a=await this.getProvider();if(!a)throw new Fn;return(await a.request({method:"eth_accounts"})).map(jt)},async getProvider(){if(typeof window<"u"&&(window==null?void 0:window.parent)!==window){if(!n){const{default:c}=await de(async()=>{const{default:h}=await import("./index-CGRcANai.js");return{default:h}},__vite__mapDeps([0,1])),l=new c(e),d=await Ff(()=>l.safe.getInfo(),{timeout:e.unstable_getInfoTimeout??10});if(!d)throw new Error("Could not load Safe information");const f=await(async()=>{const h=await de(()=>import("./index-D4ijtQZo.js").then(p=>p.i),__vite__mapDeps([2,1,3]));return typeof h.SafeAppProvider!="function"&&typeof h.default.SafeAppProvider=="function"?h.default.SafeAppProvider:h.SafeAppProvider})();n=new f(d,l)}return n}},async getChainId(){const a=await this.getProvider();if(!a)throw new Fn;return Number(a.chainId)},async isAuthorized(){var a;try{return t&&await((a=s.storage)==null?void 0:a.getItem("safe.disconnected"))?!1:!!(await this.getAccounts()).length}catch{return!1}},onAccountsChanged(){},onChainChanged(){},onDisconnect(){s.emitter.emit("disconnect")}})}kg.type="walletConnect";function kg(e){const t=e.isNewChainsStale??!0;let n,r;const s="eip155";let a,c,l,d,f,h;return p=>({id:"walletConnect",name:"WalletConnect",type:kg.type,async setup(){const m=await this.getProvider().catch(()=>null);m&&(l||(l=this.onConnect.bind(this),m.on("connect",l)),f||(f=this.onSessionDelete.bind(this),m.on("session_delete",f)))},async connect({chainId:m,withCapabilities:y,...v}={}){var w,C;try{const A=await this.getProvider();if(!A)throw new Fn;d||(d=this.onDisplayUri,A.on("display_uri",d));let I=m;if(!I){const T=await((w=p.storage)==null?void 0:w.getItem("state"))??{};p.chains.some(O=>O.id===T.chainId)?I=T.chainId:I=(C=p.chains[0])==null?void 0:C.id}if(!I)throw new Error("No chains found on connector.");const S=await this.isChainsStale();if(A.session&&S&&await A.disconnect(),!A.session||S){const T=p.chains.filter(B=>B.id!==I).map(B=>B.id);await A.connect({optionalChains:[I,...T],..."pairingTopic"in v?{pairingTopic:v.pairingTopic}:{}}),this.setRequestedChainsIds(p.chains.map(B=>B.id))}const j=(await A.enable()).map(T=>jt(T));let N=await this.getChainId();if(m&&N!==m){const T=await this.switchChain({chainId:m}).catch(B=>{var O;if(B.code===Ge.code&&((O=B.cause)==null?void 0:O.message)!=="Missing or invalid. request() method: wallet_addEthereumChain")throw B;return{id:N}});N=(T==null?void 0:T.id)??N}return d&&(A.removeListener("display_uri",d),d=void 0),l&&(A.removeListener("connect",l),l=void 0),a||(a=this.onAccountsChanged.bind(this),A.on("accountsChanged",a)),c||(c=this.onChainChanged.bind(this),A.on("chainChanged",c)),h||(h=this.onDisconnect.bind(this),A.on("disconnect",h)),f||(f=this.onSessionDelete.bind(this),A.on("session_delete",f)),{accounts:y?j.map(T=>({address:T,capabilities:{}})):j,chainId:N}}catch(A){throw/(user rejected|connection request reset)/i.test(A==null?void 0:A.message)?new Ge(A):A}},async disconnect(){const m=await this.getProvider();try{await(m==null?void 0:m.disconnect())}catch(y){if(!/No matching key/i.test(y.message))throw y}finally{c&&(m==null||m.removeListener("chainChanged",c),c=void 0),h&&(m==null||m.removeListener("disconnect",h),h=void 0),l||(l=this.onConnect.bind(this),m==null||m.on("connect",l)),a&&(m==null||m.removeListener("accountsChanged",a),a=void 0),f&&(m==null||m.removeListener("session_delete",f),f=void 0),this.setRequestedChainsIds([])}},async getAccounts(){return(await this.getProvider()).accounts.map(y=>jt(y))},async getProvider({chainId:m}={}){var v;async function y(){const w=p.chains.map(A=>A.id);if(!w.length)return;const{EthereumProvider:C}=await de(async()=>{const{EthereumProvider:A}=await import("./index.es-Bi6GZ2Ae.js").then(I=>I.X);return{EthereumProvider:A}},__vite__mapDeps([4,3]));return await C.init({...e,disableProviderPing:!0,optionalChains:w,projectId:e.projectId,rpcMap:Object.fromEntries(p.chains.map(A=>{const[I]=D3({chain:A,transports:p.transports});return[A.id,I]})),showQrModal:e.showQrModal??!0})}return n||(r||(r=y()),n=await r,n==null||n.events.setMaxListeners(Number.POSITIVE_INFINITY)),m&&await((v=this.switchChain)==null?void 0:v.call(this,{chainId:m})),n},async getChainId(){return(await this.getProvider()).chainId},async isAuthorized(){try{const[m,y]=await Promise.all([this.getAccounts(),this.getProvider()]);return m.length?await this.isChainsStale()&&y.session?(await y.disconnect().catch(()=>{}),!1):!0:!1}catch{return!1}},async switchChain({addEthereumChainParameter:m,chainId:y}){var C,A,I;const v=await this.getProvider();if(!v)throw new Fn;const w=p.chains.find(S=>S.id===y);if(!w)throw new zn(new ys);try{await Promise.all([new Promise(j=>{const N=({chainId:T})=>{T===y&&(p.emitter.off("change",N),j())};p.emitter.on("change",N)}),v.request({method:"wallet_switchEthereumChain",params:[{chainId:le(y)}]})]);const S=await this.getRequestedChainsIds();return this.setRequestedChainsIds([...S,y]),w}catch(S){const j=S;if(/(user rejected)/i.test(j.message))throw new Ge(j);try{let N;m!=null&&m.blockExplorerUrls?N=m.blockExplorerUrls:N=(C=w.blockExplorers)!=null&&C.default.url?[(A=w.blockExplorers)==null?void 0:A.default.url]:[];let T;(I=m==null?void 0:m.rpcUrls)!=null&&I.length?T=m.rpcUrls:T=[...w.rpcUrls.default.http];const B={blockExplorerUrls:N,chainId:le(y),chainName:(m==null?void 0:m.chainName)??w.name,iconUrls:m==null?void 0:m.iconUrls,nativeCurrency:(m==null?void 0:m.nativeCurrency)??w.nativeCurrency,rpcUrls:T};await v.request({method:"wallet_addEthereumChain",params:[B]});const O=await this.getRequestedChainsIds();return this.setRequestedChainsIds([...O,y]),w}catch(N){throw new Ge(N)}}},onAccountsChanged(m){m.length===0?this.onDisconnect():p.emitter.emit("change",{accounts:m.map(y=>jt(y))})},onChainChanged(m){const y=Number(m);p.emitter.emit("change",{chainId:y})},async onConnect(m){const y=Number(m.chainId),v=await this.getAccounts();p.emitter.emit("connect",{accounts:v,chainId:y})},async onDisconnect(m){this.setRequestedChainsIds([]),p.emitter.emit("disconnect");const y=await this.getProvider();a&&(y.removeListener("accountsChanged",a),a=void 0),c&&(y.removeListener("chainChanged",c),c=void 0),h&&(y.removeListener("disconnect",h),h=void 0),f&&(y.removeListener("session_delete",f),f=void 0),l||(l=this.onConnect.bind(this),y.on("connect",l))},onDisplayUri(m){p.emitter.emit("message",{type:"display_uri",data:m})},onSessionDelete(){this.onDisconnect()},getNamespaceChainsIds(){var y,v,w;return n?((w=(v=(y=n.session)==null?void 0:y.namespaces[s])==null?void 0:v.accounts)==null?void 0:w.map(C=>Number.parseInt(C.split(":")[1]||"",10)))??[]:[]},async getRequestedChainsIds(){var m;return await((m=p.storage)==null?void 0:m.getItem(this.requestedChainsStorageKey))??[]},async isChainsStale(){if(!t)return!1;const m=p.chains.map(w=>w.id),y=this.getNamespaceChainsIds();if(y.length&&!y.some(w=>m.includes(w)))return!1;const v=await this.getRequestedChainsIds();return!m.every(w=>v.includes(w))},async setRequestedChainsIds(m){var y;await((y=p.storage)==null?void 0:y.setItem(this.requestedChainsStorageKey,m))},get requestedChainsStorageKey(){return`${this.id}.requestedChains`}})}var pf={},OO=768,ea=D_({conditions:{defaultCondition:"smallScreen",conditionNames:["smallScreen","largeScreen"],responsiveArray:void 0}}),qC=aC({conditions:{defaultCondition:"smallScreen",conditionNames:["smallScreen","largeScreen"],responsiveArray:void 0}}),Jm=$_({conditions:{defaultCondition:"base",conditionNames:["base","hover","active"],responsiveArray:void 0},styles:{background:{values:{accentColor:{conditions:{base:"ju367v9i",hover:"ju367v9j",active:"ju367v9k"},defaultClass:"ju367v9i"},accentColorForeground:{conditions:{base:"ju367v9l",hover:"ju367v9m",active:"ju367v9n"},defaultClass:"ju367v9l"},actionButtonBorder:{conditions:{base:"ju367v9o",hover:"ju367v9p",active:"ju367v9q"},defaultClass:"ju367v9o"},actionButtonBorderMobile:{conditions:{base:"ju367v9r",hover:"ju367v9s",active:"ju367v9t"},defaultClass:"ju367v9r"},actionButtonSecondaryBackground:{conditions:{base:"ju367v9u",hover:"ju367v9v",active:"ju367v9w"},defaultClass:"ju367v9u"},closeButton:{conditions:{base:"ju367v9x",hover:"ju367v9y",active:"ju367v9z"},defaultClass:"ju367v9x"},closeButtonBackground:{conditions:{base:"ju367va0",hover:"ju367va1",active:"ju367va2"},defaultClass:"ju367va0"},connectButtonBackground:{conditions:{base:"ju367va3",hover:"ju367va4",active:"ju367va5"},defaultClass:"ju367va3"},connectButtonBackgroundError:{conditions:{base:"ju367va6",hover:"ju367va7",active:"ju367va8"},defaultClass:"ju367va6"},connectButtonInnerBackground:{conditions:{base:"ju367va9",hover:"ju367vaa",active:"ju367vab"},defaultClass:"ju367va9"},connectButtonText:{conditions:{base:"ju367vac",hover:"ju367vad",active:"ju367vae"},defaultClass:"ju367vac"},connectButtonTextError:{conditions:{base:"ju367vaf",hover:"ju367vag",active:"ju367vah"},defaultClass:"ju367vaf"},connectionIndicator:{conditions:{base:"ju367vai",hover:"ju367vaj",active:"ju367vak"},defaultClass:"ju367vai"},downloadBottomCardBackground:{conditions:{base:"ju367val",hover:"ju367vam",active:"ju367van"},defaultClass:"ju367val"},downloadTopCardBackground:{conditions:{base:"ju367vao",hover:"ju367vap",active:"ju367vaq"},defaultClass:"ju367vao"},error:{conditions:{base:"ju367var",hover:"ju367vas",active:"ju367vat"},defaultClass:"ju367var"},generalBorder:{conditions:{base:"ju367vau",hover:"ju367vav",active:"ju367vaw"},defaultClass:"ju367vau"},generalBorderDim:{conditions:{base:"ju367vax",hover:"ju367vay",active:"ju367vaz"},defaultClass:"ju367vax"},menuItemBackground:{conditions:{base:"ju367vb0",hover:"ju367vb1",active:"ju367vb2"},defaultClass:"ju367vb0"},modalBackdrop:{conditions:{base:"ju367vb3",hover:"ju367vb4",active:"ju367vb5"},defaultClass:"ju367vb3"},modalBackground:{conditions:{base:"ju367vb6",hover:"ju367vb7",active:"ju367vb8"},defaultClass:"ju367vb6"},modalBorder:{conditions:{base:"ju367vb9",hover:"ju367vba",active:"ju367vbb"},defaultClass:"ju367vb9"},modalText:{conditions:{base:"ju367vbc",hover:"ju367vbd",active:"ju367vbe"},defaultClass:"ju367vbc"},modalTextDim:{conditions:{base:"ju367vbf",hover:"ju367vbg",active:"ju367vbh"},defaultClass:"ju367vbf"},modalTextSecondary:{conditions:{base:"ju367vbi",hover:"ju367vbj",active:"ju367vbk"},defaultClass:"ju367vbi"},profileAction:{conditions:{base:"ju367vbl",hover:"ju367vbm",active:"ju367vbn"},defaultClass:"ju367vbl"},profileActionHover:{conditions:{base:"ju367vbo",hover:"ju367vbp",active:"ju367vbq"},defaultClass:"ju367vbo"},profileForeground:{conditions:{base:"ju367vbr",hover:"ju367vbs",active:"ju367vbt"},defaultClass:"ju367vbr"},selectedOptionBorder:{conditions:{base:"ju367vbu",hover:"ju367vbv",active:"ju367vbw"},defaultClass:"ju367vbu"},standby:{conditions:{base:"ju367vbx",hover:"ju367vby",active:"ju367vbz"},defaultClass:"ju367vbx"}}},borderColor:{values:{accentColor:{conditions:{base:"ju367vc0",hover:"ju367vc1",active:"ju367vc2"},defaultClass:"ju367vc0"},accentColorForeground:{conditions:{base:"ju367vc3",hover:"ju367vc4",active:"ju367vc5"},defaultClass:"ju367vc3"},actionButtonBorder:{conditions:{base:"ju367vc6",hover:"ju367vc7",active:"ju367vc8"},defaultClass:"ju367vc6"},actionButtonBorderMobile:{conditions:{base:"ju367vc9",hover:"ju367vca",active:"ju367vcb"},defaultClass:"ju367vc9"},actionButtonSecondaryBackground:{conditions:{base:"ju367vcc",hover:"ju367vcd",active:"ju367vce"},defaultClass:"ju367vcc"},closeButton:{conditions:{base:"ju367vcf",hover:"ju367vcg",active:"ju367vch"},defaultClass:"ju367vcf"},closeButtonBackground:{conditions:{base:"ju367vci",hover:"ju367vcj",active:"ju367vck"},defaultClass:"ju367vci"},connectButtonBackground:{conditions:{base:"ju367vcl",hover:"ju367vcm",active:"ju367vcn"},defaultClass:"ju367vcl"},connectButtonBackgroundError:{conditions:{base:"ju367vco",hover:"ju367vcp",active:"ju367vcq"},defaultClass:"ju367vco"},connectButtonInnerBackground:{conditions:{base:"ju367vcr",hover:"ju367vcs",active:"ju367vct"},defaultClass:"ju367vcr"},connectButtonText:{conditions:{base:"ju367vcu",hover:"ju367vcv",active:"ju367vcw"},defaultClass:"ju367vcu"},connectButtonTextError:{conditions:{base:"ju367vcx",hover:"ju367vcy",active:"ju367vcz"},defaultClass:"ju367vcx"},connectionIndicator:{conditions:{base:"ju367vd0",hover:"ju367vd1",active:"ju367vd2"},defaultClass:"ju367vd0"},downloadBottomCardBackground:{conditions:{base:"ju367vd3",hover:"ju367vd4",active:"ju367vd5"},defaultClass:"ju367vd3"},downloadTopCardBackground:{conditions:{base:"ju367vd6",hover:"ju367vd7",active:"ju367vd8"},defaultClass:"ju367vd6"},error:{conditions:{base:"ju367vd9",hover:"ju367vda",active:"ju367vdb"},defaultClass:"ju367vd9"},generalBorder:{conditions:{base:"ju367vdc",hover:"ju367vdd",active:"ju367vde"},defaultClass:"ju367vdc"},generalBorderDim:{conditions:{base:"ju367vdf",hover:"ju367vdg",active:"ju367vdh"},defaultClass:"ju367vdf"},menuItemBackground:{conditions:{base:"ju367vdi",hover:"ju367vdj",active:"ju367vdk"},defaultClass:"ju367vdi"},modalBackdrop:{conditions:{base:"ju367vdl",hover:"ju367vdm",active:"ju367vdn"},defaultClass:"ju367vdl"},modalBackground:{conditions:{base:"ju367vdo",hover:"ju367vdp",active:"ju367vdq"},defaultClass:"ju367vdo"},modalBorder:{conditions:{base:"ju367vdr",hover:"ju367vds",active:"ju367vdt"},defaultClass:"ju367vdr"},modalText:{conditions:{base:"ju367vdu",hover:"ju367vdv",active:"ju367vdw"},defaultClass:"ju367vdu"},modalTextDim:{conditions:{base:"ju367vdx",hover:"ju367vdy",active:"ju367vdz"},defaultClass:"ju367vdx"},modalTextSecondary:{conditions:{base:"ju367ve0",hover:"ju367ve1",active:"ju367ve2"},defaultClass:"ju367ve0"},profileAction:{conditions:{base:"ju367ve3",hover:"ju367ve4",active:"ju367ve5"},defaultClass:"ju367ve3"},profileActionHover:{conditions:{base:"ju367ve6",hover:"ju367ve7",active:"ju367ve8"},defaultClass:"ju367ve6"},profileForeground:{conditions:{base:"ju367ve9",hover:"ju367vea",active:"ju367veb"},defaultClass:"ju367ve9"},selectedOptionBorder:{conditions:{base:"ju367vec",hover:"ju367ved",active:"ju367vee"},defaultClass:"ju367vec"},standby:{conditions:{base:"ju367vef",hover:"ju367veg",active:"ju367veh"},defaultClass:"ju367vef"}}},boxShadow:{values:{connectButton:{conditions:{base:"ju367vei",hover:"ju367vej",active:"ju367vek"},defaultClass:"ju367vei"},dialog:{conditions:{base:"ju367vel",hover:"ju367vem",active:"ju367ven"},defaultClass:"ju367vel"},profileDetailsAction:{conditions:{base:"ju367veo",hover:"ju367vep",active:"ju367veq"},defaultClass:"ju367veo"},selectedOption:{conditions:{base:"ju367ver",hover:"ju367ves",active:"ju367vet"},defaultClass:"ju367ver"},selectedWallet:{conditions:{base:"ju367veu",hover:"ju367vev",active:"ju367vew"},defaultClass:"ju367veu"},walletLogo:{conditions:{base:"ju367vex",hover:"ju367vey",active:"ju367vez"},defaultClass:"ju367vex"}}},color:{values:{accentColor:{conditions:{base:"ju367vf0",hover:"ju367vf1",active:"ju367vf2"},defaultClass:"ju367vf0"},accentColorForeground:{conditions:{base:"ju367vf3",hover:"ju367vf4",active:"ju367vf5"},defaultClass:"ju367vf3"},actionButtonBorder:{conditions:{base:"ju367vf6",hover:"ju367vf7",active:"ju367vf8"},defaultClass:"ju367vf6"},actionButtonBorderMobile:{conditions:{base:"ju367vf9",hover:"ju367vfa",active:"ju367vfb"},defaultClass:"ju367vf9"},actionButtonSecondaryBackground:{conditions:{base:"ju367vfc",hover:"ju367vfd",active:"ju367vfe"},defaultClass:"ju367vfc"},closeButton:{conditions:{base:"ju367vff",hover:"ju367vfg",active:"ju367vfh"},defaultClass:"ju367vff"},closeButtonBackground:{conditions:{base:"ju367vfi",hover:"ju367vfj",active:"ju367vfk"},defaultClass:"ju367vfi"},connectButtonBackground:{conditions:{base:"ju367vfl",hover:"ju367vfm",active:"ju367vfn"},defaultClass:"ju367vfl"},connectButtonBackgroundError:{conditions:{base:"ju367vfo",hover:"ju367vfp",active:"ju367vfq"},defaultClass:"ju367vfo"},connectButtonInnerBackground:{conditions:{base:"ju367vfr",hover:"ju367vfs",active:"ju367vft"},defaultClass:"ju367vfr"},connectButtonText:{conditions:{base:"ju367vfu",hover:"ju367vfv",active:"ju367vfw"},defaultClass:"ju367vfu"},connectButtonTextError:{conditions:{base:"ju367vfx",hover:"ju367vfy",active:"ju367vfz"},defaultClass:"ju367vfx"},connectionIndicator:{conditions:{base:"ju367vg0",hover:"ju367vg1",active:"ju367vg2"},defaultClass:"ju367vg0"},downloadBottomCardBackground:{conditions:{base:"ju367vg3",hover:"ju367vg4",active:"ju367vg5"},defaultClass:"ju367vg3"},downloadTopCardBackground:{conditions:{base:"ju367vg6",hover:"ju367vg7",active:"ju367vg8"},defaultClass:"ju367vg6"},error:{conditions:{base:"ju367vg9",hover:"ju367vga",active:"ju367vgb"},defaultClass:"ju367vg9"},generalBorder:{conditions:{base:"ju367vgc",hover:"ju367vgd",active:"ju367vge"},defaultClass:"ju367vgc"},generalBorderDim:{conditions:{base:"ju367vgf",hover:"ju367vgg",active:"ju367vgh"},defaultClass:"ju367vgf"},menuItemBackground:{conditions:{base:"ju367vgi",hover:"ju367vgj",active:"ju367vgk"},defaultClass:"ju367vgi"},modalBackdrop:{conditions:{base:"ju367vgl",hover:"ju367vgm",active:"ju367vgn"},defaultClass:"ju367vgl"},modalBackground:{conditions:{base:"ju367vgo",hover:"ju367vgp",active:"ju367vgq"},defaultClass:"ju367vgo"},modalBorder:{conditions:{base:"ju367vgr",hover:"ju367vgs",active:"ju367vgt"},defaultClass:"ju367vgr"},modalText:{conditions:{base:"ju367vgu",hover:"ju367vgv",active:"ju367vgw"},defaultClass:"ju367vgu"},modalTextDim:{conditions:{base:"ju367vgx",hover:"ju367vgy",active:"ju367vgz"},defaultClass:"ju367vgx"},modalTextSecondary:{conditions:{base:"ju367vh0",hover:"ju367vh1",active:"ju367vh2"},defaultClass:"ju367vh0"},profileAction:{conditions:{base:"ju367vh3",hover:"ju367vh4",active:"ju367vh5"},defaultClass:"ju367vh3"},profileActionHover:{conditions:{base:"ju367vh6",hover:"ju367vh7",active:"ju367vh8"},defaultClass:"ju367vh6"},profileForeground:{conditions:{base:"ju367vh9",hover:"ju367vha",active:"ju367vhb"},defaultClass:"ju367vh9"},selectedOptionBorder:{conditions:{base:"ju367vhc",hover:"ju367vhd",active:"ju367vhe"},defaultClass:"ju367vhc"},standby:{conditions:{base:"ju367vhf",hover:"ju367vhg",active:"ju367vhh"},defaultClass:"ju367vhf"}}}}},{conditions:{defaultCondition:"smallScreen",conditionNames:["smallScreen","largeScreen"],responsiveArray:void 0},styles:{alignItems:{values:{"flex-start":{conditions:{smallScreen:"ju367v0",largeScreen:"ju367v1"},defaultClass:"ju367v0"},"flex-end":{conditions:{smallScreen:"ju367v2",largeScreen:"ju367v3"},defaultClass:"ju367v2"},center:{conditions:{smallScreen:"ju367v4",largeScreen:"ju367v5"},defaultClass:"ju367v4"}}},display:{values:{none:{conditions:{smallScreen:"ju367v6",largeScreen:"ju367v7"},defaultClass:"ju367v6"},block:{conditions:{smallScreen:"ju367v8",largeScreen:"ju367v9"},defaultClass:"ju367v8"},flex:{conditions:{smallScreen:"ju367va",largeScreen:"ju367vb"},defaultClass:"ju367va"},inline:{conditions:{smallScreen:"ju367vc",largeScreen:"ju367vd"},defaultClass:"ju367vc"}}}}},{conditions:void 0,styles:{margin:{mappings:["marginTop","marginBottom","marginLeft","marginRight"]},marginX:{mappings:["marginLeft","marginRight"]},marginY:{mappings:["marginTop","marginBottom"]},padding:{mappings:["paddingTop","paddingBottom","paddingLeft","paddingRight"]},paddingX:{mappings:["paddingLeft","paddingRight"]},paddingY:{mappings:["paddingTop","paddingBottom"]},alignSelf:{values:{"flex-start":{defaultClass:"ju367ve"},"flex-end":{defaultClass:"ju367vf"},center:{defaultClass:"ju367vg"}}},backgroundSize:{values:{cover:{defaultClass:"ju367vh"}}},borderRadius:{values:{1:{defaultClass:"ju367vi"},6:{defaultClass:"ju367vj"},10:{defaultClass:"ju367vk"},13:{defaultClass:"ju367vl"},actionButton:{defaultClass:"ju367vm"},connectButton:{defaultClass:"ju367vn"},menuButton:{defaultClass:"ju367vo"},modal:{defaultClass:"ju367vp"},modalMobile:{defaultClass:"ju367vq"},"25%":{defaultClass:"ju367vr"},full:{defaultClass:"ju367vs"}}},borderStyle:{values:{solid:{defaultClass:"ju367vt"}}},borderWidth:{values:{0:{defaultClass:"ju367vu"},1:{defaultClass:"ju367vv"},2:{defaultClass:"ju367vw"},4:{defaultClass:"ju367vx"}}},cursor:{values:{pointer:{defaultClass:"ju367vy"},none:{defaultClass:"ju367vz"}}},pointerEvents:{values:{none:{defaultClass:"ju367v10"},all:{defaultClass:"ju367v11"}}},minHeight:{values:{8:{defaultClass:"ju367v12"},44:{defaultClass:"ju367v13"}}},flexDirection:{values:{row:{defaultClass:"ju367v14"},column:{defaultClass:"ju367v15"}}},fontFamily:{values:{body:{defaultClass:"ju367v16"}}},fontSize:{values:{12:{defaultClass:"ju367v17"},13:{defaultClass:"ju367v18"},14:{defaultClass:"ju367v19"},16:{defaultClass:"ju367v1a"},18:{defaultClass:"ju367v1b"},20:{defaultClass:"ju367v1c"},23:{defaultClass:"ju367v1d"}}},fontWeight:{values:{regular:{defaultClass:"ju367v1e"},medium:{defaultClass:"ju367v1f"},semibold:{defaultClass:"ju367v1g"},bold:{defaultClass:"ju367v1h"},heavy:{defaultClass:"ju367v1i"}}},gap:{values:{0:{defaultClass:"ju367v1j"},1:{defaultClass:"ju367v1k"},2:{defaultClass:"ju367v1l"},3:{defaultClass:"ju367v1m"},4:{defaultClass:"ju367v1n"},5:{defaultClass:"ju367v1o"},6:{defaultClass:"ju367v1p"},8:{defaultClass:"ju367v1q"},10:{defaultClass:"ju367v1r"},12:{defaultClass:"ju367v1s"},14:{defaultClass:"ju367v1t"},16:{defaultClass:"ju367v1u"},18:{defaultClass:"ju367v1v"},20:{defaultClass:"ju367v1w"},24:{defaultClass:"ju367v1x"},28:{defaultClass:"ju367v1y"},32:{defaultClass:"ju367v1z"},36:{defaultClass:"ju367v20"},44:{defaultClass:"ju367v21"},64:{defaultClass:"ju367v22"},"-1":{defaultClass:"ju367v23"}}},height:{values:{1:{defaultClass:"ju367v24"},2:{defaultClass:"ju367v25"},4:{defaultClass:"ju367v26"},8:{defaultClass:"ju367v27"},12:{defaultClass:"ju367v28"},20:{defaultClass:"ju367v29"},24:{defaultClass:"ju367v2a"},28:{defaultClass:"ju367v2b"},30:{defaultClass:"ju367v2c"},32:{defaultClass:"ju367v2d"},34:{defaultClass:"ju367v2e"},36:{defaultClass:"ju367v2f"},40:{defaultClass:"ju367v2g"},44:{defaultClass:"ju367v2h"},48:{defaultClass:"ju367v2i"},54:{defaultClass:"ju367v2j"},60:{defaultClass:"ju367v2k"},200:{defaultClass:"ju367v2l"},full:{defaultClass:"ju367v2m"},max:{defaultClass:"ju367v2n"}}},justifyContent:{values:{"flex-start":{defaultClass:"ju367v2o"},"flex-end":{defaultClass:"ju367v2p"},center:{defaultClass:"ju367v2q"},"space-between":{defaultClass:"ju367v2r"},"space-around":{defaultClass:"ju367v2s"}}},textAlign:{values:{left:{defaultClass:"ju367v2t"},center:{defaultClass:"ju367v2u"},inherit:{defaultClass:"ju367v2v"}}},marginBottom:{values:{0:{defaultClass:"ju367v2w"},1:{defaultClass:"ju367v2x"},2:{defaultClass:"ju367v2y"},3:{defaultClass:"ju367v2z"},4:{defaultClass:"ju367v30"},5:{defaultClass:"ju367v31"},6:{defaultClass:"ju367v32"},8:{defaultClass:"ju367v33"},10:{defaultClass:"ju367v34"},12:{defaultClass:"ju367v35"},14:{defaultClass:"ju367v36"},16:{defaultClass:"ju367v37"},18:{defaultClass:"ju367v38"},20:{defaultClass:"ju367v39"},24:{defaultClass:"ju367v3a"},28:{defaultClass:"ju367v3b"},32:{defaultClass:"ju367v3c"},36:{defaultClass:"ju367v3d"},44:{defaultClass:"ju367v3e"},64:{defaultClass:"ju367v3f"},"-1":{defaultClass:"ju367v3g"}}},marginLeft:{values:{0:{defaultClass:"ju367v3h"},1:{defaultClass:"ju367v3i"},2:{defaultClass:"ju367v3j"},3:{defaultClass:"ju367v3k"},4:{defaultClass:"ju367v3l"},5:{defaultClass:"ju367v3m"},6:{defaultClass:"ju367v3n"},8:{defaultClass:"ju367v3o"},10:{defaultClass:"ju367v3p"},12:{defaultClass:"ju367v3q"},14:{defaultClass:"ju367v3r"},16:{defaultClass:"ju367v3s"},18:{defaultClass:"ju367v3t"},20:{defaultClass:"ju367v3u"},24:{defaultClass:"ju367v3v"},28:{defaultClass:"ju367v3w"},32:{defaultClass:"ju367v3x"},36:{defaultClass:"ju367v3y"},44:{defaultClass:"ju367v3z"},64:{defaultClass:"ju367v40"},"-1":{defaultClass:"ju367v41"}}},marginRight:{values:{0:{defaultClass:"ju367v42"},1:{defaultClass:"ju367v43"},2:{defaultClass:"ju367v44"},3:{defaultClass:"ju367v45"},4:{defaultClass:"ju367v46"},5:{defaultClass:"ju367v47"},6:{defaultClass:"ju367v48"},8:{defaultClass:"ju367v49"},10:{defaultClass:"ju367v4a"},12:{defaultClass:"ju367v4b"},14:{defaultClass:"ju367v4c"},16:{defaultClass:"ju367v4d"},18:{defaultClass:"ju367v4e"},20:{defaultClass:"ju367v4f"},24:{defaultClass:"ju367v4g"},28:{defaultClass:"ju367v4h"},32:{defaultClass:"ju367v4i"},36:{defaultClass:"ju367v4j"},44:{defaultClass:"ju367v4k"},64:{defaultClass:"ju367v4l"},"-1":{defaultClass:"ju367v4m"}}},marginTop:{values:{0:{defaultClass:"ju367v4n"},1:{defaultClass:"ju367v4o"},2:{defaultClass:"ju367v4p"},3:{defaultClass:"ju367v4q"},4:{defaultClass:"ju367v4r"},5:{defaultClass:"ju367v4s"},6:{defaultClass:"ju367v4t"},8:{defaultClass:"ju367v4u"},10:{defaultClass:"ju367v4v"},12:{defaultClass:"ju367v4w"},14:{defaultClass:"ju367v4x"},16:{defaultClass:"ju367v4y"},18:{defaultClass:"ju367v4z"},20:{defaultClass:"ju367v50"},24:{defaultClass:"ju367v51"},28:{defaultClass:"ju367v52"},32:{defaultClass:"ju367v53"},36:{defaultClass:"ju367v54"},44:{defaultClass:"ju367v55"},64:{defaultClass:"ju367v56"},"-1":{defaultClass:"ju367v57"}}},maxWidth:{values:{1:{defaultClass:"ju367v58"},2:{defaultClass:"ju367v59"},4:{defaultClass:"ju367v5a"},8:{defaultClass:"ju367v5b"},12:{defaultClass:"ju367v5c"},20:{defaultClass:"ju367v5d"},24:{defaultClass:"ju367v5e"},28:{defaultClass:"ju367v5f"},30:{defaultClass:"ju367v5g"},32:{defaultClass:"ju367v5h"},34:{defaultClass:"ju367v5i"},36:{defaultClass:"ju367v5j"},40:{defaultClass:"ju367v5k"},44:{defaultClass:"ju367v5l"},48:{defaultClass:"ju367v5m"},54:{defaultClass:"ju367v5n"},60:{defaultClass:"ju367v5o"},200:{defaultClass:"ju367v5p"},full:{defaultClass:"ju367v5q"},max:{defaultClass:"ju367v5r"}}},minWidth:{values:{1:{defaultClass:"ju367v5s"},2:{defaultClass:"ju367v5t"},4:{defaultClass:"ju367v5u"},8:{defaultClass:"ju367v5v"},12:{defaultClass:"ju367v5w"},20:{defaultClass:"ju367v5x"},24:{defaultClass:"ju367v5y"},28:{defaultClass:"ju367v5z"},30:{defaultClass:"ju367v60"},32:{defaultClass:"ju367v61"},34:{defaultClass:"ju367v62"},36:{defaultClass:"ju367v63"},40:{defaultClass:"ju367v64"},44:{defaultClass:"ju367v65"},48:{defaultClass:"ju367v66"},54:{defaultClass:"ju367v67"},60:{defaultClass:"ju367v68"},200:{defaultClass:"ju367v69"},full:{defaultClass:"ju367v6a"},max:{defaultClass:"ju367v6b"}}},overflow:{values:{hidden:{defaultClass:"ju367v6c"}}},paddingBottom:{values:{0:{defaultClass:"ju367v6d"},1:{defaultClass:"ju367v6e"},2:{defaultClass:"ju367v6f"},3:{defaultClass:"ju367v6g"},4:{defaultClass:"ju367v6h"},5:{defaultClass:"ju367v6i"},6:{defaultClass:"ju367v6j"},8:{defaultClass:"ju367v6k"},10:{defaultClass:"ju367v6l"},12:{defaultClass:"ju367v6m"},14:{defaultClass:"ju367v6n"},16:{defaultClass:"ju367v6o"},18:{defaultClass:"ju367v6p"},20:{defaultClass:"ju367v6q"},24:{defaultClass:"ju367v6r"},28:{defaultClass:"ju367v6s"},32:{defaultClass:"ju367v6t"},36:{defaultClass:"ju367v6u"},44:{defaultClass:"ju367v6v"},64:{defaultClass:"ju367v6w"},"-1":{defaultClass:"ju367v6x"}}},paddingLeft:{values:{0:{defaultClass:"ju367v6y"},1:{defaultClass:"ju367v6z"},2:{defaultClass:"ju367v70"},3:{defaultClass:"ju367v71"},4:{defaultClass:"ju367v72"},5:{defaultClass:"ju367v73"},6:{defaultClass:"ju367v74"},8:{defaultClass:"ju367v75"},10:{defaultClass:"ju367v76"},12:{defaultClass:"ju367v77"},14:{defaultClass:"ju367v78"},16:{defaultClass:"ju367v79"},18:{defaultClass:"ju367v7a"},20:{defaultClass:"ju367v7b"},24:{defaultClass:"ju367v7c"},28:{defaultClass:"ju367v7d"},32:{defaultClass:"ju367v7e"},36:{defaultClass:"ju367v7f"},44:{defaultClass:"ju367v7g"},64:{defaultClass:"ju367v7h"},"-1":{defaultClass:"ju367v7i"}}},paddingRight:{values:{0:{defaultClass:"ju367v7j"},1:{defaultClass:"ju367v7k"},2:{defaultClass:"ju367v7l"},3:{defaultClass:"ju367v7m"},4:{defaultClass:"ju367v7n"},5:{defaultClass:"ju367v7o"},6:{defaultClass:"ju367v7p"},8:{defaultClass:"ju367v7q"},10:{defaultClass:"ju367v7r"},12:{defaultClass:"ju367v7s"},14:{defaultClass:"ju367v7t"},16:{defaultClass:"ju367v7u"},18:{defaultClass:"ju367v7v"},20:{defaultClass:"ju367v7w"},24:{defaultClass:"ju367v7x"},28:{defaultClass:"ju367v7y"},32:{defaultClass:"ju367v7z"},36:{defaultClass:"ju367v80"},44:{defaultClass:"ju367v81"},64:{defaultClass:"ju367v82"},"-1":{defaultClass:"ju367v83"}}},paddingTop:{values:{0:{defaultClass:"ju367v84"},1:{defaultClass:"ju367v85"},2:{defaultClass:"ju367v86"},3:{defaultClass:"ju367v87"},4:{defaultClass:"ju367v88"},5:{defaultClass:"ju367v89"},6:{defaultClass:"ju367v8a"},8:{defaultClass:"ju367v8b"},10:{defaultClass:"ju367v8c"},12:{defaultClass:"ju367v8d"},14:{defaultClass:"ju367v8e"},16:{defaultClass:"ju367v8f"},18:{defaultClass:"ju367v8g"},20:{defaultClass:"ju367v8h"},24:{defaultClass:"ju367v8i"},28:{defaultClass:"ju367v8j"},32:{defaultClass:"ju367v8k"},36:{defaultClass:"ju367v8l"},44:{defaultClass:"ju367v8m"},64:{defaultClass:"ju367v8n"},"-1":{defaultClass:"ju367v8o"}}},position:{values:{absolute:{defaultClass:"ju367v8p"},fixed:{defaultClass:"ju367v8q"},relative:{defaultClass:"ju367v8r"}}},WebkitUserSelect:{values:{none:{defaultClass:"ju367v8s"}}},right:{values:{0:{defaultClass:"ju367v8t"}}},transition:{values:{default:{defaultClass:"ju367v8u"},transform:{defaultClass:"ju367v8v"}}},userSelect:{values:{none:{defaultClass:"ju367v8w"}}},width:{values:{1:{defaultClass:"ju367v8x"},2:{defaultClass:"ju367v8y"},4:{defaultClass:"ju367v8z"},8:{defaultClass:"ju367v90"},12:{defaultClass:"ju367v91"},20:{defaultClass:"ju367v92"},24:{defaultClass:"ju367v93"},28:{defaultClass:"ju367v94"},30:{defaultClass:"ju367v95"},32:{defaultClass:"ju367v96"},34:{defaultClass:"ju367v97"},36:{defaultClass:"ju367v98"},40:{defaultClass:"ju367v99"},44:{defaultClass:"ju367v9a"},48:{defaultClass:"ju367v9b"},54:{defaultClass:"ju367v9c"},60:{defaultClass:"ju367v9d"},200:{defaultClass:"ju367v9e"},full:{defaultClass:"ju367v9f"},max:{defaultClass:"ju367v9g"}}},backdropFilter:{values:{modalOverlay:{defaultClass:"ju367v9h"}}}}}),L6={colors:{accentColor:"var(--rk-colors-accentColor)",accentColorForeground:"var(--rk-colors-accentColorForeground)",actionButtonBorder:"var(--rk-colors-actionButtonBorder)",actionButtonBorderMobile:"var(--rk-colors-actionButtonBorderMobile)",actionButtonSecondaryBackground:"var(--rk-colors-actionButtonSecondaryBackground)",closeButton:"var(--rk-colors-closeButton)",closeButtonBackground:"var(--rk-colors-closeButtonBackground)",connectButtonBackground:"var(--rk-colors-connectButtonBackground)",connectButtonBackgroundError:"var(--rk-colors-connectButtonBackgroundError)",connectButtonInnerBackground:"var(--rk-colors-connectButtonInnerBackground)",connectButtonText:"var(--rk-colors-connectButtonText)",connectButtonTextError:"var(--rk-colors-connectButtonTextError)",connectionIndicator:"var(--rk-colors-connectionIndicator)",downloadBottomCardBackground:"var(--rk-colors-downloadBottomCardBackground)",downloadTopCardBackground:"var(--rk-colors-downloadTopCardBackground)",error:"var(--rk-colors-error)",generalBorder:"var(--rk-colors-generalBorder)",generalBorderDim:"var(--rk-colors-generalBorderDim)",menuItemBackground:"var(--rk-colors-menuItemBackground)",modalBackdrop:"var(--rk-colors-modalBackdrop)",modalBackground:"var(--rk-colors-modalBackground)",modalBorder:"var(--rk-colors-modalBorder)",modalText:"var(--rk-colors-modalText)",modalTextDim:"var(--rk-colors-modalTextDim)",modalTextSecondary:"var(--rk-colors-modalTextSecondary)",profileAction:"var(--rk-colors-profileAction)",profileActionHover:"var(--rk-colors-profileActionHover)",profileForeground:"var(--rk-colors-profileForeground)",selectedOptionBorder:"var(--rk-colors-selectedOptionBorder)",standby:"var(--rk-colors-standby)"},fonts:{body:"var(--rk-fonts-body)"},radii:{actionButton:"var(--rk-radii-actionButton)",connectButton:"var(--rk-radii-connectButton)",menuButton:"var(--rk-radii-menuButton)",modal:"var(--rk-radii-modal)",modalMobile:"var(--rk-radii-modalMobile)"},shadows:{connectButton:"var(--rk-shadows-connectButton)",dialog:"var(--rk-shadows-dialog)",profileDetailsAction:"var(--rk-shadows-profileDetailsAction)",selectedOption:"var(--rk-shadows-selectedOption)",selectedWallet:"var(--rk-shadows-selectedWallet)",walletLogo:"var(--rk-shadows-walletLogo)"},blurs:{modalOverlay:"var(--rk-blurs-modalOverlay)"}},RO={shrink:"_12cbo8i6",shrinkSm:"_12cbo8i7"},MO="_12cbo8i3 ju367v8r",DO={grow:"_12cbo8i4",growLg:"_12cbo8i5"};function wt({active:e,hover:t}){return[MO,t&&DO[t],RO[e]]}var HC=P.createContext(null);function FO(){const{adapter:e}=P.useContext(HC)??{};if(!e)throw new Error("No authentication adapter found");return e}function Qf(){const e=P.useContext(HC);return(e==null?void 0:e.status)??null}function Sg(){const e=Qf(),{isConnected:t}=it();return t?e&&(e==="loading"||e==="unauthenticated")?e:"connected":"disconnected"}function VC(){return typeof navigator<"u"&&/android/i.test(navigator.userAgent)}function LO(){return typeof navigator<"u"&&/iPhone|iPod/.test(navigator.userAgent)}function UO(){return typeof navigator<"u"&&(/iPad/.test(navigator.userAgent)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)}function su(){return LO()||UO()}function Ct(){return VC()||su()}var zO="iekbcc0",WO={a:"iekbcca",blockquote:"iekbcc2",button:"iekbcc9",input:"iekbcc8 iekbcc5 iekbcc4",mark:"iekbcc6",ol:"iekbcc1",q:"iekbcc2",select:"iekbcc7 iekbcc5 iekbcc4",table:"iekbcc3",textarea:"iekbcc5 iekbcc4",ul:"iekbcc1"},$O=({reset:e,...t})=>{if(!e)return Jm(t);const n=WO[e],r=Jm(t);return lC(zO,n,r)},D=k.forwardRef(({as:e="div",className:t,testId:n,...r},s)=>{const a={},c={};for(const d in r)Jm.properties.has(d)?a[d]=r[d]:c[d]=r[d];const l=$O({reset:typeof e=="string"?e:"div",...a});return k.createElement(e,{className:lC(l,t),...c,"data-testid":n?`rk-${n.replace(/^rk-/,"")}`:void 0,ref:s})});D.displayName="Box";var QC=new Map,Cp=new Map;async function GC(e){const t=Cp.get(e);if(t)return t;const n=async()=>e().then(async s=>(QC.set(e,s),s)),r=n().catch(s=>n().catch(a=>{Cp.delete(e)}));return Cp.set(e,r),r}async function Gr(...e){return await Promise.all(e.map(t=>typeof t=="function"?GC(t):t))}function qO(){const[,e]=P.useReducer(t=>t+1,0);return e}function Gf(e){const t=typeof e=="function"?QC.get(e):void 0,n=qO();return P.useEffect(()=>{typeof e=="function"&&!t&&GC(e).then(n)},[e,t,n]),typeof e=="function"?t:e}function Rt({alt:e,background:t,borderColor:n,borderRadius:r,useAsImage:s,boxShadow:a,height:c,src:l,width:d,testId:f}){const h=su(),p=Gf(l),m=p&&/^http/.test(p),[y,v]=P.useReducer(()=>!0,!1);return k.createElement(D,{"aria-label":e,borderRadius:r,boxShadow:a,height:typeof c=="string"?c:void 0,overflow:"hidden",position:"relative",role:"img",style:{background:t,height:typeof c=="number"?c:void 0,width:typeof d=="number"?d:void 0},width:typeof d=="string"?d:void 0,testId:f},k.createElement(D,{...m?{"aria-hidden":!0,as:"img",onLoad:v,src:p}:{"aria-hidden":!0,as:"img",src:p},height:"full",position:"absolute",...h?{WebkitUserSelect:"none"}:{},style:{WebkitTouchCallout:"none",transition:"opacity .15s linear",userSelect:"none",...!s&&m?{opacity:y?1:0}:{}},width:"full"}),n?k.createElement(D,{...typeof n=="object"&&"custom"in n?{style:{borderColor:n.custom}}:{borderColor:n},borderRadius:r,borderStyle:"solid",borderWidth:"1",height:"full",position:"relative",width:"full"}):null)}var HO="_1luule42",VO="_1luule43",QO=e=>P.useMemo(()=>`${e}_${Math.round(Math.random()*1e9)}`,[e]),Nl=({height:e=21,width:t=21})=>{const n=QO("spinner");return k.createElement("svg",{className:HO,fill:"none",height:e,viewBox:"0 0 21 21",width:t,xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Loading"),k.createElement("clipPath",{id:n},k.createElement("path",{d:"M10.5 3C6.35786 3 3 6.35786 3 10.5C3 14.6421 6.35786 18 10.5 18C11.3284 18 12 18.6716 12 19.5C12 20.3284 11.3284 21 10.5 21C4.70101 21 0 16.299 0 10.5C0 4.70101 4.70101 0 10.5 0C16.299 0 21 4.70101 21 10.5C21 11.3284 20.3284 12 19.5 12C18.6716 12 18 11.3284 18 10.5C18 6.35786 14.6421 3 10.5 3Z"})),k.createElement("foreignObject",{clipPath:`url(#${n})`,height:"21",width:"21",x:"0",y:"0"},k.createElement("div",{className:VO})))},We=["#FC5C54","#FFD95A","#E95D72","#6A87C8","#5FD0F3","#75C06B","#FFDD86","#5FC6D4","#FF949A","#FF8024","#9BA1A4","#EC66FF","#FF8CBC","#FF9A23","#C5DADB","#A8CE63","#71ABFF","#FFE279","#B6B1B6","#FF6780","#A575FF","#4D82FF","#FFB35A"],U6=[{color:We[0],emoji:"🌶"},{color:We[1],emoji:"🤑"},{color:We[2],emoji:"🐙"},{color:We[3],emoji:"🫐"},{color:We[4],emoji:"🐳"},{color:We[0],emoji:"🤶"},{color:We[5],emoji:"🌲"},{color:We[6],emoji:"🌞"},{color:We[7],emoji:"🐒"},{color:We[8],emoji:"🐵"},{color:We[9],emoji:"🦊"},{color:We[10],emoji:"🐼"},{color:We[11],emoji:"🦄"},{color:We[12],emoji:"🐷"},{color:We[13],emoji:"🐧"},{color:We[8],emoji:"🦩"},{color:We[14],emoji:"👽"},{color:We[0],emoji:"🎈"},{color:We[8],emoji:"🍉"},{color:We[1],emoji:"🎉"},{color:We[15],emoji:"🐲"},{color:We[16],emoji:"🌎"},{color:We[17],emoji:"🍊"},{color:We[18],emoji:"🐭"},{color:We[19],emoji:"🍣"},{color:We[1],emoji:"🐥"},{color:We[20],emoji:"👾"},{color:We[15],emoji:"🥦"},{color:We[0],emoji:"👹"},{color:We[17],emoji:"🙀"},{color:We[4],emoji:"⛱"},{color:We[21],emoji:"⛵️"},{color:We[17],emoji:"🥳"},{color:We[8],emoji:"🤯"},{color:We[22],emoji:"🤠"}];function GO(e){let t=0;if(e.length===0)return t;for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);t=(t<<5)-t+r,t|=0}return t}function KO(e){const n=Math.abs(GO((typeof e=="string"?e:"").toLowerCase())%U6.length);return U6[n??0]}var YO=({address:e,ensImage:t,size:n})=>{const[r,s]=P.useState(!1);P.useEffect(()=>{if(t){const l=new Image;l.src=t,l.onload=()=>s(!0)}},[t]);const{color:a,emoji:c}=P.useMemo(()=>KO(e),[e]);return t?r?k.createElement(D,{backgroundSize:"cover",borderRadius:"full",position:"absolute",style:{backgroundImage:`url(${t})`,backgroundPosition:"center",height:n,width:n}}):k.createElement(D,{alignItems:"center",backgroundSize:"cover",borderRadius:"full",color:"modalText",display:"flex",justifyContent:"center",position:"absolute",style:{height:n,width:n}},k.createElement(Nl,null)):k.createElement(D,{alignItems:"center",display:"flex",justifyContent:"center",overflow:"hidden",style:{...!t&&{backgroundColor:a},height:n,width:n}},c)},KC=YO,YC=P.createContext(KC);function JC({address:e,imageUrl:t,loading:n,size:r}){const s=P.useContext(YC);return k.createElement(D,{"aria-hidden":!0,borderRadius:"full",overflow:"hidden",position:"relative",style:{height:`${r}px`,width:`${r}px`},userSelect:"none"},k.createElement(D,{alignItems:"center",borderRadius:"full",display:"flex",justifyContent:"center",overflow:"hidden",position:"absolute",style:{fontSize:`${Math.round(r*.55)}px`,height:`${r}px`,transform:n?"scale(0.72)":void 0,transition:".25s ease",transitionDelay:n?void 0:".1s",width:`${r}px`,willChange:"transform"},userSelect:"none"},k.createElement(s,{address:e,ensImage:t,size:r})),n&&k.createElement(D,{color:"accentColor",display:"flex",height:"full",position:"absolute",width:"full"},k.createElement(Nl,{height:"100%",width:"100%"})))}var z6=()=>k.createElement("svg",{fill:"none",height:"7",width:"14",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Dropdown"),k.createElement("path",{d:"M12.75 1.54001L8.51647 5.0038C7.77974 5.60658 6.72026 5.60658 5.98352 5.0038L1.75 1.54001",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2.5",xmlns:"http://www.w3.org/2000/svg"})),W6={defaultLocale:"en",locale:"en"},JO=class{constructor(e){this.listeners=new Set,this.defaultLocale=W6.defaultLocale,this.enableFallback=!1,this.locale=W6.locale,this.cachedLocales=[],this.translations={};for(const[t,n]of Object.entries(e))this.cachedLocales=[...this.cachedLocales,t],this.translations={...this.translations,...this.flattenTranslation(n,t)}}missingMessage(e){return`[missing: "${this.locale}.${e}" translation]`}flattenTranslation(e,t){const n={},r=(s,a)=>{for(const c of Object.keys(s)){const l=`${a}.${c}`,d=s[c];typeof d=="object"&&d!==null?r(d,l):n[l]=d}};return r(e,t),n}translateWithReplacements(e,t={}){let n=e;for(const r in t){const s=t[r];n=n.replace(`%{${r}}`,s)}return n}t(e,t,n){const r=`${this.locale}.${e}`,s=this.translations[r];if(!s){if(this.enableFallback){const a=`${this.defaultLocale}.${e}`,c=this.translations[a];if(c)return this.translateWithReplacements(c,t)}return n!=null&&n.rawKeyIfTranslationMissing?e:this.missingMessage(e)}return this.translateWithReplacements(s,t)}isLocaleCached(e){return this.cachedLocales.includes(e)}updateLocale(e){this.locale=e,this.notifyListeners()}setTranslations(e,t){this.isLocaleCached(e)||(this.cachedLocales=[...this.cachedLocales,e],this.translations={...this.translations,...this.flattenTranslation(t,e)}),this.locale=e,this.notifyListeners()}notifyListeners(){for(const e of this.listeners)e()}onChange(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}},tr=new JO({en:JSON.parse(qm),"en-US":JSON.parse(qm)});tr.defaultLocale="en-US";tr.locale="en-US";tr.enableFallback=!0;var ZO=async e=>{switch(e){case"ar":case"ar-AR":return(await de(async()=>{const{default:t}=await import("./ar_AR-44JUQ6EW-BMX-am0v.js");return{default:t}},[])).default;case"de":case"de-DE":return(await de(async()=>{const{default:t}=await import("./de_DE-PYAO5YD6-BWlqPWgO.js");return{default:t}},[])).default;case"en":case"en-US":return(await de(async()=>{const{default:t}=await Promise.resolve().then(()=>D2);return{default:t}},void 0)).default;case"es":case"es-419":return(await de(async()=>{const{default:t}=await import("./es_419-HRGOJ6VT-D-qzxUM-.js");return{default:t}},[])).default;case"fr":case"fr-FR":return(await de(async()=>{const{default:t}=await import("./fr_FR-IGGVC6RM-D8LpUM75.js");return{default:t}},[])).default;case"hi":case"hi-IN":return(await de(async()=>{const{default:t}=await import("./hi_IN-XSKAA3MF-C3QUpWyP.js");return{default:t}},[])).default;case"id":case"id-ID":return(await de(async()=>{const{default:t}=await import("./id_ID-KUOB4UAL-K9y-nRWm.js");return{default:t}},[])).default;case"ja":case"ja-JP":return(await de(async()=>{const{default:t}=await import("./ja_JP-4WRQ63RX-Ct5pF4ug.js");return{default:t}},[])).default;case"ko":case"ko-KR":return(await de(async()=>{const{default:t}=await import("./ko_KR-I2K7AIEP-B5gw8Mwb.js");return{default:t}},[])).default;case"ms":case"ms-MY":return(await de(async()=>{const{default:t}=await import("./ms_MY-6VZW6Q3Z-BtFD07hR.js");return{default:t}},[])).default;case"pt":case"pt-BR":return(await de(async()=>{const{default:t}=await import("./pt_BR-N3XOZ4SV-CvVpfsHb.js");return{default:t}},[])).default;case"ru":case"ru-RU":return(await de(async()=>{const{default:t}=await import("./ru_RU-IITAPRET-DOj6Jzj7.js");return{default:t}},[])).default;case"th":case"th-TH":return(await de(async()=>{const{default:t}=await import("./th_TH-3ZQCKCQE-BcHUN2Q4.js");return{default:t}},[])).default;case"tr":case"tr-TR":return(await de(async()=>{const{default:t}=await import("./tr_TR-QUPUGMUF-CwpF6ZFn.js");return{default:t}},[])).default;case"ua":case"uk-UA":return(await de(async()=>{const{default:t}=await import("./uk_UA-SSN6SV5E-IlYYyRC6.js");return{default:t}},[])).default;case"vi":case"vi-VN":return(await de(async()=>{const{default:t}=await import("./vi_VN-7BUVRNYY-CZ9S75qZ.js");return{default:t}},[])).default;case"zh":case"zh-CN":case"zh-Hans":return(await de(async()=>{const{default:t}=await import("./zh_CN-HJBN674C-Baf0GEeT.js");return{default:t}},[])).default;case"zh-HK":return(await de(async()=>{const{default:t}=await import("./zh_HK-JW3WLRKE-VztJKXL5.js");return{default:t}},[])).default;case"zh-Hant":case"zh-TW":return(await de(async()=>{const{default:t}=await import("./zh_TW-VNNRNXY7-aWfg7Qp4.js");return{default:t}},[])).default;default:return(await de(async()=>{const{default:t}=await Promise.resolve().then(()=>D2);return{default:t}},void 0)).default}};async function $6(e){if(tr.isLocaleCached(e)){tr.updateLocale(e);return}const n=await ZO(e);tr.setTranslations(e,JSON.parse(n))}var XO=()=>{var e;if(typeof window<"u"&&typeof navigator<"u"){if((e=navigator.languages)!=null&&e.length)return navigator.languages[0];if(navigator.language)return navigator.language}},Et=P.createContext({i18n:tr}),eR=({children:e,locale:t})=>{const[n,r]=P.useState(0),s=P.useMemo(()=>XO(),[]);P.useEffect(()=>tr.onChange(()=>{r(l=>l+1)}),[]),P.useEffect(()=>{t&&t!==tr.locale?$6(t):!t&&s&&s!==tr.locale&&$6(s)},[t,s]);const a=P.useMemo(()=>({t:(l,d)=>tr.t(l,d),i18n:tr}),[n]);return k.createElement(Et.Provider,{value:a},e)};function ZC(e){return e!=null}var q6={iconBackground:"#7290CC",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./apechain-SX5YFU6N-q5qBv-mp.js");return{default:e}},[])).default},Ep={iconBackground:"#96bedc",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./arbitrum-WURIBY6W-CqVkHBr5.js");return{default:e}},[])).default},H6={iconBackground:"#e84141",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./avalanche-KOMJD3XY-Dsn_JPR4.js");return{default:e}},[])).default},Ap={iconBackground:"#0052ff",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./base-OAXLRA4F-CoYTVIiL.js");return{default:e}},[])).default},kp={iconBackground:"#814625",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./berachain-NJECWIVC-DumxnFvf.js");return{default:e}},[])).default},V6={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./blast-V555OVXZ-BbhJh1tj.js");return{default:e}},[])).default},Q6={iconBackground:"#ebac0e",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./bsc-N647EYR2-B2nLKXWV.js");return{default:e}},[])).default},G6={iconBackground:"#FCFF52",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./celo-GEP4TUHG-CenIBYLU.js");return{default:e}},[])).default},K6={iconBackground:"#002D74",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./cronos-HJPAQTAE-BEOvlOC4.js");return{default:e}},[])).default},tR={iconBackground:"#A36EFD",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./degen-FQQ4XGHB-CeHTs88l.js");return{default:e}},[])).default},Zo={iconBackground:"#484c50",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./ethereum-RGGVA4PY-SWGOlkuk.js");return{default:e}},[])).default},Y6={iconBackground:"transparent",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./flow-5FQJFCTK-CUie2reO.js");return{default:e}},[])).default},nR={iconBackground:"#04795c",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./gnosis-37ZC4RBL-B137OtHZ.js");return{default:e}},[])).default},J6={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./gravity-J5YQHTYH-Bj6B0uod.js");return{default:e}},[])).default},rR={iconBackground:"#f9f7ec",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./hardhat-TX56IT5N-CV1FY-wE.js");return{default:e}},[])).default},oR={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./hyperevm-VKPAA4SA-CHwraEsx.js");return{default:e}},[])).default},Z6={iconBackground:"#7132F5",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./ink-FZMYZWHG-62p-5IK5.js");return{default:e}},[])).default},X6={iconBackground:"transparent",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./kaia-65D2U3PU-JmuLQ4gC.js");return{default:e}},[])).default},Sp={iconBackground:"#ffffff",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./linea-QRMVQ5DY-DuI3vv0d.js");return{default:e}},[])).default},jp={iconBackground:"#ffffff",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./manta-SI27YFEJ-CpVOKa06.js");return{default:e}},[])).default},e2={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./mantle-CKIUT334-DR2WgqzU.js");return{default:e}},[])).default},sR={iconBackground:"transparent",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./monad-4KWC6TSS-DVXSkpiz.js");return{default:e}},[])).default},Rd={iconBackground:"#ff5a57",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./optimism-HAF2GUT7-ec6Nqxs9.js");return{default:e}},[])).default},Ip={iconBackground:"#9f71ec",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./polygon-WW6ZI7PM-DXlmm4L1.js");return{default:e}},[])).default},iR={iconBackground:"#1273EA",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./ronin-EMCPYXZT-N-QBHZdV.js");return{default:e}},[])).default},aR={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./sanko-RHQYXGM5-OX010CbN.js");return{default:e}},[])).default},cR={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./superposition-HG6MMR2Y-bRkgatRO.js");return{default:e}},[])).default},t2={iconBackground:"#FFEEDA",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./scroll-5OBGQVOV-DJFECiai.js");return{default:e}},[])).default},n2={iconBackground:"#F50DB4",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./unichain-C5BWO2ZY-BfguYsnu.js");return{default:e}},[])).default},r2={iconBackground:"#f9f7ec",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./xdc-KJ3TDBYO-DNV6zchh.js");return{default:e}},[])).default},o2={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./zetachain-TLDS5IPW-Udhyw16T.js");return{default:e}},[])).default},s2={iconBackground:"#f9f7ec",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./zksync-DH7HK5U4-Dt4usFw6.js");return{default:e}},[])).default},Np={iconBackground:"#000000",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./zora-FYL5H3IO-iB4wygST.js");return{default:e}},[])).default},lR={apechain:{chainId:33139,name:"ApeChain",...q6},apechainCurtis:{chainId:33111,name:"ApeChain Curtis",...q6},arbitrum:{chainId:42161,name:"Arbitrum",...Ep},arbitrumGoerli:{chainId:421613,...Ep},arbitrumSepolia:{chainId:421614,...Ep},avalanche:{chainId:43114,...H6},avalancheFuji:{chainId:43113,...H6},base:{chainId:8453,name:"Base",...Ap},baseGoerli:{chainId:84531,...Ap},baseSepolia:{chainId:84532,...Ap},berachain:{chainId:80094,name:"Berachain",...kp},berachainArtio:{chainId:80085,name:"Berachain Artio",...kp},berachainBArtio:{chainId:80084,name:"Berachain bArtio",...kp},blast:{chainId:81457,name:"Blast",...V6},blastSepolia:{chainId:168587773,...V6},bsc:{chainId:56,name:"BSC",...Q6},bscTestnet:{chainId:97,...Q6},celo:{chainId:42220,name:"Celo",...G6},celoAlfajores:{chainId:44787,name:"Celo Alfajores",...G6},cronos:{chainId:25,...K6},cronosTestnet:{chainId:338,...K6},degen:{chainId:666666666,name:"Degen",...tR},flow:{chainId:747,...Y6},flowTestnet:{chainId:545,...Y6},gnosis:{chainId:100,name:"Gnosis",...nR},goerli:{chainId:5,...Zo},gravity:{chainId:1625,name:"Gravity",...J6},gravitySepolia:{chainId:13505,name:"Gravity Sepolia",...J6},hardhat:{chainId:31337,...rR},holesky:{chainId:17e3,...Zo},hyperevm:{chainId:999,...oR},ink:{chainId:57073,...Z6},inkSepolia:{chainId:763373,...Z6},kaia:{chainId:8217,name:"Kaia",...X6},kairos:{chainId:1001,name:"Kairos",...X6},kovan:{chainId:42,...Zo},linea:{chainId:59144,name:"Linea",...Sp},lineaGoerli:{chainId:59140,name:"Linea Goerli",...Sp},lineaSepolia:{chainId:59141,name:"Linea Sepolia",...Sp},localhost:{chainId:1337,...Zo},mainnet:{chainId:1,name:"Ethereum",...Zo},manta:{chainId:169,name:"Manta",...jp},mantaSepolia:{chainId:3441006,...jp},mantaTestnet:{chainId:3441005,...jp},mantle:{chainId:5e3,...e2},mantleTestnet:{chainId:5001,...e2},monadTestnet:{chainId:10143,name:"Monad Testnet",...sR},optimism:{chainId:10,name:"Optimism",...Rd},optimismGoerli:{chainId:420,...Rd},optimismKovan:{chainId:69,...Rd},optimismSepolia:{chainId:11155420,...Rd},polygon:{chainId:137,name:"Polygon",...Ip},polygonAmoy:{chainId:80002,...Ip},polygonMumbai:{chainId:80001,...Ip},rinkeby:{chainId:4,...Zo},ronin:{chainId:2020,...iR},ropsten:{chainId:3,...Zo},sanko:{chainId:1996,name:"Sanko",...aR},scroll:{chainId:534352,...t2},scrollSepolia:{chainId:534351,...t2},sepolia:{chainId:11155111,...Zo},superposition:{chainId:55244,name:"Superposition",...cR},unichain:{chainId:130,...n2},unichainSepolia:{chainId:1301,...n2},xdc:{chainId:50,name:"XDC",...r2},xdcTestnet:{chainId:51,...r2},zetachain:{chainId:7e3,name:"ZetaChain",...o2},zetachainAthensTestnet:{chainId:7001,name:"Zeta Athens",...o2},zkSync:{chainId:324,name:"zkSync",...s2},zkSyncTestnet:{chainId:280,...s2},zora:{chainId:7777777,name:"Zora",...Np},zoraSepolia:{chainId:999999999,...Np},zoraTestnet:{chainId:999,...Np}},uR=Object.fromEntries(Object.values(lR).filter(ZC).map(({chainId:e,...t})=>[e,t])),dR=e=>e.map(t=>{const n=uR[t.id]??{};return{...t,name:n.name??t.name,iconUrl:t.iconUrl??n.iconUrl,iconBackground:t.iconBackground??n.iconBackground}}),jg=P.createContext({chains:[]});function fR({children:e,initialChain:t}){const{chains:n}=ut();return k.createElement(jg.Provider,{value:P.useMemo(()=>({chains:dR(n),initialChainId:typeof t=="number"?t:t==null?void 0:t.id}),[n,t])},e)}var Ei=()=>P.useContext(jg).chains,hR=()=>P.useContext(jg).initialChainId,pR=()=>{const e=Ei();return P.useMemo(()=>{const t={};for(const n of e)t[n.id]=n;return t},[e])},XC=P.createContext({showBalance:void 0,setShowBalance:()=>{}});function mR({children:e}){const[t,n]=P.useState();return k.createElement(XC.Provider,{value:{showBalance:t,setShowBalance:n}},e)}var e8=()=>P.useContext(XC);function gR(){const[e,t]=P.useState(!1);return P.useEffect(()=>(t(!0),()=>{t(!1)}),[]),P.useCallback(()=>e,[e])}function t8(){const e=Ei(),t=mg.id;return e.some(r=>r.id===t)}function yR(e){const t=t8(),n=s=>{try{return jT(s)}catch{}},{data:r}=N_({chainId:mg.id,name:e?n(e):void 0,query:{enabled:t}});return r}async function Fs(e,t){if(t={headers:{},method:"get",...t,timeout:t.timeout??1e4},!e)throw new Error("rainbowFetch: Missing url argument");const n=new AbortController,r=setTimeout(()=>n.abort(),t.timeout),{body:s,params:a,headers:c,...l}=t,d=s&&typeof s=="object"?JSON.stringify(t.body):t.body,f=await fetch(`${e}${wR(a)}`,{...l,body:d,headers:{Accept:"application/json","Content-Type":"application/json",...c},signal:n.signal});clearTimeout(r);const h=await vR(f);if(f.ok){const{headers:y,status:v}=f;return{data:h,headers:y,status:v}}throw bR({requestBody:s,response:f,responseBody:typeof h=="string"?{error:h}:h})}function vR(e){const t=e.headers.get("Content-Type");return t!=null&&t.startsWith("application/json")?e.json():e.text()}function wR(e){return e&&Object.keys(e).length?`?${new URLSearchParams(e)}`:""}function bR({requestBody:e,response:t,responseBody:n}){const r=(n==null?void 0:n.error)||(t==null?void 0:t.statusText)||"There was an error with the request.",s=new Error(r);return s.response=t,s.responseBody=n,s.requestBody=e,s}var xR=class{constructor(e={}){const{baseUrl:t="",...n}=e;this.baseUrl=t,this.opts=n}get(e,t){return Fs(`${this.baseUrl}${e}`,{...this.opts,...t||{},method:"get"})}delete(e,t){return Fs(`${this.baseUrl}${e}`,{...this.opts,...t||{},method:"delete"})}head(e,t){return Fs(`${this.baseUrl}${e}`,{...this.opts,...t||{},method:"head"})}options(e,t){return Fs(`${this.baseUrl}${e}`,{...this.opts,...t||{},method:"options"})}post(e,t,n){return Fs(`${this.baseUrl}${e}`,{...this.opts,...n||{},body:t,method:"post"})}put(e,t,n){return Fs(`${this.baseUrl}${e}`,{...this.opts,...n||{},body:t,method:"put"})}patch(e,t,n){return Fs(`${this.baseUrl}${e}`,{...this.opts,...n||{},body:t,method:"patch"})}};function CR({baseUrl:e,headers:t,params:n,timeout:r}){return new xR({baseUrl:e,headers:t,params:n,timeout:r})}var ER=!!(typeof process<"u"&&typeof pf<"u"&&pf.RAINBOW_PROVIDER_API_KEY),AR=CR({baseUrl:"https://enhanced-provider.rainbow.me",headers:{"x-api-key":typeof process<"u"&&typeof pf<"u"&&pf.RAINBOW_PROVIDER_API_KEY||"LzbasoBiLqltex3VkcQ7LRmL4PtfiiZ1EMJrizrgfonWN6byJReu/l6yrUoo3zLW"}});function kR(e,t,n={}){return[e,t,n]}function Kd(e){return`rk-ens-name-${e}`}function SR(e){try{const t=e?JSON.parse(e):null;return typeof t=="object"?t:null}catch{return null}}function jR(e,t){if(!xt(e))return;const n=new Date,r=new Date(n.getTime()+180*6e4);localStorage.setItem(Kd(e),JSON.stringify({ensName:t,expires:r.getTime()}))}function IR(e){const t=SR(localStorage.getItem(Kd(e)));if(!t)return null;const{ensName:n,expires:r}=t;return typeof n!="string"||Number.isNaN(Number(r))||new Date().getTime()>Number(r)?(localStorage.removeItem(Kd(e)),null):n}async function NR({address:e}){const t=IR(e);if(t)return t;const r=(await AR.get("/v1/resolve-ens",{params:{address:e}})).data.data;return r&&jR(e,r),r}function PR(e){const t=t8(),{data:n}=P_({chainId:mg.id,address:e,query:{enabled:t}}),{data:r}=eC({queryKey:kR("address",e),queryFn:()=>NR({address:e}),enabled:!t&&!!e&&ER,staleTime:10*(60*1e3),retry:1});return n||r}function n8({address:e,includeBalance:t}){const n=PR(e),r=yR(n),{data:s}=tC({address:t?e:void 0});return{ensName:n,ensAvatar:r,balance:s}}function Ig(){const{chain:e}=it();return(e==null?void 0:e.id)??null}var r8="rk-transactions";function BR(e){try{const t=e?JSON.parse(e):{};return typeof t=="object"?t:{}}catch{return{}}}function i2(){return BR(typeof localStorage<"u"?localStorage.getItem(r8):null)}var _R=/^0x([A-Fa-f0-9]{64})$/;function TR(e){const t=[];return _R.test(e.hash)||t.push("Invalid transaction hash"),typeof e.description!="string"&&t.push("Transaction must have a description"),typeof e.confirmations<"u"&&(!Number.isInteger(e.confirmations)||e.confirmations<1)&&t.push("Transaction confirmations must be a positiver integer"),t}function OR({provider:e}){let t=i2(),n=e;const r=new Set,s=new Set,a=new Map;function c(I){n=I}function l(I,S){var j;return((j=t[I])==null?void 0:j[S])??[]}function d(I,S,j){const N=TR(j);if(N.length>0)throw new Error(["Unable to add transaction",...N].join(`
1726
- `));m(I,S,T=>[{...j,status:"pending"},...T.filter(({hash:B})=>B!==j.hash)])}function f(I,S){m(I,S,()=>[])}function h(I,S,j,N){m(I,S,T=>T.map(B=>B.hash===j?{...B,status:N}:B))}async function p(I,S){await Promise.all(l(I,S).filter(j=>j.status==="pending").map(async j=>{const{confirmations:N,hash:T}=j,B=a.get(T);if(B)return await B;const O=n.waitForTransactionReceipt({confirmations:N,hash:T,timeout:3e5}).then(({status:R})=>{a.delete(T),R!==void 0&&(h(I,S,T,R===0||R==="reverted"?"failed":"confirmed"),w(R))}).catch(()=>{h(I,S,T,"failed")});return a.set(T,O),await O}))}function m(I,S,j){t=i2(),t[I]=t[I]??{};let N=0;const T=10,B=j(t[I][S]??[]).filter(({status:O})=>O==="pending"?!0:N++<=T);t[I][S]=B.length>0?B:void 0,y(),v(),p(I,S)}function y(){localStorage.setItem(r8,JSON.stringify(t))}function v(){for(const I of r)I()}function w(I){for(const S of s)S(I)}function C(I){return r.add(I),()=>{r.delete(I)}}function A(I){return s.add(I),()=>{s.delete(I)}}return{addTransaction:d,clearTransactions:f,getTransactions:l,onTransactionStatus:A,onChange:C,setProvider:c,waitForPendingTransactions:p}}var a2,o8=k.createContext(null);function RR({children:e}){const t=nC(),{address:n}=it(),r=Ig(),{refetch:s}=tC({address:n,query:{enabled:!1}}),[a]=k.useState(()=>a2??(a2=OR({provider:t}))),c=k.useCallback(l=>{l==="success"&&s()},[s]);return k.useEffect(()=>{a.setProvider(t)},[a,t]),k.useEffect(()=>{n&&r&&a.waitForPendingTransactions(n,r)},[a,n,r]),k.useEffect(()=>{if(a&&n&&r)return a.onTransactionStatus(c)},[a,n,r,c]),k.createElement(o8.Provider,{value:a},e)}function s8(){const e=k.useContext(o8);if(!e)throw new Error("Transaction hooks must be used within RainbowKitProvider");return e}function i8(){const e=s8(),{address:t}=it(),n=Ig(),[r,s]=P.useState(()=>e&&t&&n?e.getTransactions(t,n):[]);return P.useEffect(()=>{if(e&&t&&n)return s(e.getTransactions(t,n)),e.onChange(()=>{s(e.getTransactions(t,n))})},[e,t,n]),r}var c2=e=>typeof e=="function"?e():e;function MR(e,{extends:t}={}){const n={...I6(L6,c2(e))};if(!t)return n;const r=I6(L6,c2(t));return Object.fromEntries(Object.entries(n).filter(([a,c])=>c!==r[a]))}function l2(e,t={}){return Object.entries(MR(e,t)).map(([n,r])=>`${n}:${r.replace(/[:;{}</>]/g,"")};`).join("")}var a8={appName:void 0,disclaimer:void 0,learnMoreUrl:"https://learn.rainbow.me/understanding-web3?utm_source=rainbowkit&utm_campaign=learnmore"},iu=P.createContext(a8),c8=P.createContext(!1);function DR(e,t){let n;return()=>{n&&clearTimeout(n),n=setTimeout(()=>{n=null,e()},t)}}var l8=()=>{const[e,t]=P.useState({height:void 0,width:void 0});return P.useEffect(()=>{const n=DR(()=>{t({height:window.innerHeight,width:window.innerWidth})},500);return window.addEventListener("resize",n),n(),()=>window.removeEventListener("resize",n)},[]),e},au=P.createContext({connector:null,setConnector:()=>{}});function FR({children:e}){const[t,n]=P.useState(null);return k.createElement(au.Provider,{value:P.useMemo(()=>({connector:t,setConnector:n}),[t])},e)}var cu={COMPACT:"compact",WIDE:"wide"},Kf=P.createContext(cu.WIDE);function LR({children:e,modalSize:t}){const{width:n}=l8(),r=n&&n<OO,{connector:s}=P.useContext(au);return k.createElement(Kf.Provider,{value:r||s?cu.COMPACT:t},e)}var Ng=P.createContext(!1),UR="rk-version";function zR({version:e}){localStorage.setItem(UR,e)}function WR(){const e=P.useCallback(()=>{zR({version:"2.2.10"})},[]);P.useEffect(()=>{e()},[e])}function $R(e,t){const n={};for(const r of e){const s=t(r);s&&(n[s]=r)}return n}function Pg(){return typeof navigator<"u"&&typeof navigator.userAgent<"u"&&/Version\/([0-9._]+).*Safari/.test(navigator.userAgent)}function qR(){return typeof document<"u"&&getComputedStyle(document.body).getPropertyValue("--arc-palette-focus")!==""}function Bg(){var t,n;if(typeof navigator>"u")return"Browser";const e=(t=navigator.userAgent)==null?void 0:t.toLowerCase();return(n=navigator.brave)!=null&&n.isBrave?"Brave":(e==null?void 0:e.indexOf("edg/"))>-1?"Edge":(e==null?void 0:e.indexOf("op"))>-1?"Opera":qR()?"Arc":(e==null?void 0:e.indexOf("chrome"))>-1?"Chrome":(e==null?void 0:e.indexOf("firefox"))>-1?"Firefox":Pg()?"Safari":"Browser"}var HR=hO.UAParser(),{os:_g}=HR;function VR(){return _g.name==="Windows"}function QR(){return _g.name==="Mac OS"}function GR(){return["Ubuntu","Mint","Fedora","Debian","Arch","Linux"].includes(_g.name)}function Tg(){return VR()?"Windows":QR()?"macOS":GR()?"Linux":"Desktop"}var KR=e=>{var n,r,s,a,c,l,d,f,h,p,m;const t=Bg();return{Arc:(n=e==null?void 0:e.downloadUrls)==null?void 0:n.chrome,Brave:(r=e==null?void 0:e.downloadUrls)==null?void 0:r.chrome,Chrome:(s=e==null?void 0:e.downloadUrls)==null?void 0:s.chrome,Edge:((a=e==null?void 0:e.downloadUrls)==null?void 0:a.edge)||((c=e==null?void 0:e.downloadUrls)==null?void 0:c.chrome),Firefox:(l=e==null?void 0:e.downloadUrls)==null?void 0:l.firefox,Opera:((d=e==null?void 0:e.downloadUrls)==null?void 0:d.opera)||((f=e==null?void 0:e.downloadUrls)==null?void 0:f.chrome),Safari:(h=e==null?void 0:e.downloadUrls)==null?void 0:h.safari,Browser:(p=e==null?void 0:e.downloadUrls)==null?void 0:p.browserExtension}[t]??((m=e==null?void 0:e.downloadUrls)==null?void 0:m.browserExtension)},YR=e=>{var n,r,s;return(su()?(n=e==null?void 0:e.downloadUrls)==null?void 0:n.ios:(r=e==null?void 0:e.downloadUrls)==null?void 0:r.android)??((s=e==null?void 0:e.downloadUrls)==null?void 0:s.mobile)},JR=e=>{var n,r,s,a,c;const t=Tg();return{Windows:(n=e==null?void 0:e.downloadUrls)==null?void 0:n.windows,macOS:(r=e==null?void 0:e.downloadUrls)==null?void 0:r.macos,Linux:(s=e==null?void 0:e.downloadUrls)==null?void 0:s.linux,Desktop:(a=e==null?void 0:e.downloadUrls)==null?void 0:a.desktop}[t]??((c=e==null?void 0:e.downloadUrls)==null?void 0:c.desktop)},u8=(e,t)=>e.some(n=>n.id===t),ZR=e=>!!e.isRainbowKitConnector,u2=e=>{var t;return!!(!e.isRainbowKitConnector&&((t=e.icon)!=null&&t.replace(/\n/g,"").startsWith("data:image"))&&e.uid&&e.name)},XR=(e,t)=>e.id==="walletConnect"&&t?{...e,walletConnectModalConnector:t}:e,eM=({wallets:e,recentWallets:t})=>[...t,...e.filter(n=>!u8(t,n.id))],d8="rk-recent";function tM(e){try{const t=e?JSON.parse(e):[];return Array.isArray(t)?t:[]}catch{return[]}}function f8(){return typeof localStorage<"u"?tM(localStorage.getItem(d8)):[]}function nM(e){return[...new Set(e)]}function rM(e){const t=nM([e,...f8()]);localStorage.setItem(d8,JSON.stringify(t))}function Pl(e=!1){var j,N,T;const t=Ei(),n=hR(),{connectAsync:r,connectors:s}=j_(),a=s,{setIsWalletConnectModalOpen:c}=F8(),l=a.map(B=>({...B,...B.rkDetails||{}}));async function d(B,O){var H,K;const R=await B.getChainId(),W=await r({...O,chainId:(O==null?void 0:O.chainId)??n??((H=t.find(({id:Q})=>Q===R))==null?void 0:H.id)??((K=t[0])==null?void 0:K.id),connector:B});return W&&rM(B.id),W}async function f(B){try{c(!0),await d(B),c(!1)}catch(O){const R=O.name==="UserRejectedRequestError"||O.message==="Connection request reset. Please try again.";if(c(!1),!R)throw O}}const h=async(B,O)=>{const R=await B.getProvider();return B.id==="coinbase"?R.qrUrl:new Promise(W=>R.once("display_uri",H=>{W(O(H))}))},p=l.find(B=>B.id==="walletConnect"&&B.isWalletConnectModalConnector),m=l.filter(u2).map(B=>({...B,groupIndex:0})),y=l.filter(ZR).filter(B=>!B.isWalletConnectModalConnector).filter(B=>e?!m.some(R=>R.id===B.rdns):!0).map(B=>XR(B,p)),v=[...m,...y],w=$R(v,B=>B.id),A=f8().map(B=>w[B]).filter(Boolean).slice(0,3),I=[],S=eM({wallets:v,recentWallets:A});for(const B of S){if(!B)continue;const O=u2(B),R=u8(A,B.id);if(O){I.push({...B,iconUrl:B.icon,ready:!0,connect:d.bind(null,B),groupName:"Installed",recent:R});continue}I.push({...B,ready:B.installed??!0,connect:d.bind(null,B),desktopDownloadUrl:JR(B),extensionDownloadUrl:KR(B),groupName:B.groupName,mobileDownloadUrl:YR(B),getQrCodeUri:(j=B.qrCode)!=null&&j.getUri?()=>h(B,B.qrCode.getUri):void 0,getDesktopUri:(N=B.desktop)!=null&&N.getUri?()=>h(B,B.desktop.getUri):void 0,getMobileUri:(T=B.mobile)!=null&&T.getUri?()=>{var W;return h(B,(W=B.mobile)==null?void 0:W.getUri)}:void 0,recent:R,showWalletConnectModal:B.walletConnectModalConnector?()=>f(B.walletConnectModalConnector):void 0})}return I}var h8=async()=>(await de(async()=>{const{default:e}=await import("./assets-Q6ZU7ZJ5-P8HioiAD.js");return{default:e}},[])).default,oM=()=>Gr(h8),sM=()=>k.createElement(Rt,{background:"#d0d5de",borderRadius:"10",height:"48",src:h8,width:"48"}),p8=async()=>(await de(async()=>{const{default:e}=await import("./login-UP3DZBGS-Db_wM5oQ.js");return{default:e}},[])).default,iM=()=>Gr(p8),aM=()=>k.createElement(Rt,{background:"#d0d5de",borderRadius:"10",height:"48",src:p8,width:"48"}),xe=k.forwardRef(({as:e="div",children:t,className:n,color:r,display:s,font:a="body",id:c,size:l="16",style:d,tabIndex:f,textAlign:h="inherit",weight:p="regular",testId:m},y)=>k.createElement(D,{as:e,className:n,color:r,display:s,fontFamily:a,fontSize:l,fontWeight:p,id:c,ref:y,style:d,tabIndex:f,textAlign:h,testId:m},t));xe.displayName="Text";var cM={large:{fontSize:"16",paddingX:"24",paddingY:"10"},medium:{fontSize:"14",height:"28",paddingX:"12",paddingY:"4"},small:{fontSize:"14",paddingX:"10",paddingY:"5"}};function ln({disabled:e=!1,href:t,label:n,onClick:r,rel:s="noreferrer noopener",size:a="medium",target:c="_blank",testId:l,type:d="primary"}){const f=d==="primary",h=a!=="large",p=Ct(),m=e?"actionButtonSecondaryBackground":f?"accentColor":h?"actionButtonSecondaryBackground":null,{fontSize:y,height:v,paddingX:w,paddingY:C}=cM[a],A=!p||!h;return k.createElement(D,{...t?e?{}:{as:"a",href:t,rel:s,target:c}:{as:"button",type:"button"},onClick:e?void 0:r,...A?{borderColor:p&&!h&&!f?"actionButtonBorderMobile":"actionButtonBorder",borderStyle:"solid",borderWidth:"1"}:{},borderRadius:"actionButton",className:!e&&wt({active:"shrinkSm",hover:"grow"}),display:"block",paddingX:w,paddingY:C,style:{willChange:"transform"},testId:l,textAlign:"center",transition:"transform",...m?{background:m}:{},...v?{height:v}:{}},k.createElement(xe,{color:e?"modalTextSecondary":f?"accentColorForeground":"accentColor",size:y,weight:"bold"},n))}var lM=()=>Ct()?k.createElement("svg",{"aria-hidden":!0,fill:"none",height:"11.5",viewBox:"0 0 11.5 11.5",width:"11.5",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Close"),k.createElement("path",{d:"M2.13388 0.366117C1.64573 -0.122039 0.854272 -0.122039 0.366117 0.366117C-0.122039 0.854272 -0.122039 1.64573 0.366117 2.13388L3.98223 5.75L0.366117 9.36612C-0.122039 9.85427 -0.122039 10.6457 0.366117 11.1339C0.854272 11.622 1.64573 11.622 2.13388 11.1339L5.75 7.51777L9.36612 11.1339C9.85427 11.622 10.6457 11.622 11.1339 11.1339C11.622 10.6457 11.622 9.85427 11.1339 9.36612L7.51777 5.75L11.1339 2.13388C11.622 1.64573 11.622 0.854272 11.1339 0.366117C10.6457 -0.122039 9.85427 -0.122039 9.36612 0.366117L5.75 3.98223L2.13388 0.366117Z",fill:"currentColor"})):k.createElement("svg",{"aria-hidden":!0,fill:"none",height:"10",viewBox:"0 0 10 10",width:"10",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Close"),k.createElement("path",{d:"M1.70711 0.292893C1.31658 -0.0976311 0.683417 -0.0976311 0.292893 0.292893C-0.0976311 0.683417 -0.0976311 1.31658 0.292893 1.70711L3.58579 5L0.292893 8.29289C-0.0976311 8.68342 -0.0976311 9.31658 0.292893 9.70711C0.683417 10.0976 1.31658 10.0976 1.70711 9.70711L5 6.41421L8.29289 9.70711C8.68342 10.0976 9.31658 10.0976 9.70711 9.70711C10.0976 9.31658 10.0976 8.68342 9.70711 8.29289L6.41421 5L9.70711 1.70711C10.0976 1.31658 10.0976 0.683417 9.70711 0.292893C9.31658 -0.0976311 8.68342 -0.0976311 8.29289 0.292893L5 3.58579L1.70711 0.292893Z",fill:"currentColor"})),yi=({"aria-label":e="Close",onClose:t})=>{const n=Ct();return k.createElement(D,{alignItems:"center","aria-label":e,as:"button",background:"closeButtonBackground",borderColor:"actionButtonBorder",borderRadius:"full",borderStyle:"solid",borderWidth:n?"0":"1",className:wt({active:"shrinkSm",hover:"growLg"}),color:"closeButton",display:"flex",height:n?"30":"28",justifyContent:"center",onClick:t,style:{willChange:"transform"},transition:"default",type:"button",width:n?"30":"28"},k.createElement(lM,null))},m8=async()=>(await de(async()=>{const{default:e}=await import("./sign-A7IJEUT5-CGsRnPrd.js");return{default:e}},[])).default;function uM({onClose:e,onCloseModal:t}){const{i18n:n}=P.useContext(Et),[{status:r,...s},a]=k.useState({status:"idle"}),c=FO(),l=P.useCallback(async()=>{try{const v=await c.getNonce();a(w=>({...w,nonce:v}))}catch{a(v=>({...v,errorMessage:n.t("sign_in.message.preparing_error"),status:"idle"}))}},[c,n.t]),d=P.useRef(!1);k.useEffect(()=>{d.current||(d.current=!0,l())},[l]);const f=Ct(),{address:h,chain:p}=it(),{signMessageAsync:m}=__(),y=async()=>{try{const v=p==null?void 0:p.id,{nonce:w}=s;if(!h||!v||!w)return;a(I=>({...I,errorMessage:void 0,status:"signing"}));const C=c.createMessage({address:h,chainId:v,nonce:w});let A;try{A=await m({message:C})}catch(I){return I instanceof Ge?a(S=>({...S,status:"idle"})):a(S=>({...S,errorMessage:n.t("sign_in.signature.signing_error"),status:"idle"}))}a(I=>({...I,status:"verifying"}));try{if(await c.verify({message:C,signature:A})){t();return}throw new Error}catch{return a(I=>({...I,errorMessage:n.t("sign_in.signature.verifying_error"),status:"idle"}))}}catch{a({errorMessage:n.t("sign_in.signature.oops_error"),status:"idle"})}};return k.createElement(D,{position:"relative"},k.createElement(D,{display:"flex",paddingRight:"16",paddingTop:"16",position:"absolute",right:"0"},k.createElement(yi,{onClose:e})),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:f?"32":"24",padding:"24",paddingX:"18",style:{paddingTop:f?"60px":"36px"}},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:f?"6":"4",style:{maxWidth:f?320:280}},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:f?"32":"16"},k.createElement(Rt,{height:40,src:m8,width:40}),k.createElement(xe,{color:"modalText",size:f?"20":"18",textAlign:"center",weight:"heavy"},n.t("sign_in.label"))),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:f?"16":"12"},k.createElement(xe,{color:"modalTextSecondary",size:f?"16":"14",textAlign:"center"},n.t("sign_in.description")),r==="idle"&&s.errorMessage?k.createElement(xe,{color:"error",size:f?"16":"14",textAlign:"center",weight:"bold"},s.errorMessage):null)),k.createElement(D,{alignItems:f?void 0:"center",display:"flex",flexDirection:"column",gap:"8",width:"full"},k.createElement(ln,{disabled:!s.nonce||r==="signing"||r==="verifying",label:s.nonce?r==="signing"?n.t("sign_in.signature.waiting"):r==="verifying"?n.t("sign_in.signature.verifying"):n.t("sign_in.message.send"):n.t("sign_in.message.preparing"),onClick:y,size:f?"large":"medium",testId:"auth-message-button"}),f?k.createElement(ln,{label:"Cancel",onClick:e,size:"large",type:"secondary"}):k.createElement(D,{as:"button",borderRadius:"full",className:wt({active:"shrink",hover:"grow"}),display:"block",onClick:e,paddingX:"10",paddingY:"5",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},k.createElement(xe,{color:"closeButton",size:f?"16":"14",weight:"bold"},n.t("sign_in.message.cancel"))))))}function dM(){const e=Ei(),t=Pl(),n=Qf()==="unauthenticated",r=P.useCallback(()=>{Gr(...t.map(s=>s.iconUrl),...e.map(s=>s.iconUrl).filter(ZC)),Ct()||(oM(),iM()),n&&Gr(m8)},[t,e,n]);P.useEffect(()=>{r()},[r])}var g8="WALLETCONNECT_DEEPLINK_CHOICE";function fM({mobileUri:e,name:t}){localStorage.setItem(g8,JSON.stringify({href:e.split("?")[0],name:t}))}function hM(){localStorage.removeItem(g8)}var y8=P.createContext(void 0),Zm="data-rk",v8=e=>({[Zm]:e||""}),pM=e=>{if(e&&!/^[a-zA-Z0-9_]+$/.test(e))throw new Error(`Invalid ID: ${e}`);return e?`[${Zm}="${e}"]`:`[${Zm}]`},mM=()=>{const e=P.useContext(y8);return v8(e)},gM=sC();function yM({appInfo:e,avatar:t,children:n,coolMode:r=!1,id:s,initialChain:a,locale:c,modalSize:l=cu.WIDE,showRecentTransactions:d=!1,theme:f=gM}){if(dM(),WR(),U3({onDisconnect:hM}),typeof f=="function")throw new Error('A theme function was provided to the "theme" prop instead of a theme object. You must execute this function to get the resulting theme object.');const h=pM(s),p={...a8,...e},m=t??KC;return k.createElement(fR,{initialChain:a},k.createElement(FR,null,k.createElement(eR,{locale:c},k.createElement(c8.Provider,{value:r},k.createElement(LR,{modalSize:l},k.createElement(Ng.Provider,{value:d},k.createElement(RR,null,k.createElement(YC.Provider,{value:m},k.createElement(iu.Provider,{value:p},k.createElement(y8.Provider,{value:s},k.createElement(mR,null,k.createElement(BD,null,f?k.createElement("div",{...v8(s)},k.createElement("style",{dangerouslySetInnerHTML:{__html:[`${h}{${l2("lightMode"in f?f.lightMode:f)}}`,"darkMode"in f?`@media(prefers-color-scheme:dark){${h}{${l2(f.darkMode,{extends:f.lightMode})}}}`:null].join("")}}),n):n))))))))))))}var vM="_9pm4ki5 ju367va ju367v15 ju367v8r",wM="_9pm4ki3 ju367v9h ju367vb3 ju367va ju367v2q ju367v8q",d2=(e,t)=>{const n=e.querySelectorAll("button:not(:disabled), a[href]");n.length!==0&&n[t==="end"?n.length-1:0].focus()};function bM(e){const t=P.useRef(null);return P.useEffect(()=>{const n=document.activeElement;return()=>{var r;(r=n.focus)==null||r.call(n)}},[]),P.useEffect(()=>{if(t.current){const n=t.current.querySelector("[data-auto-focus]");n?n.focus():t.current.focus()}},[]),k.createElement(k.Fragment,null,k.createElement("div",{onFocus:P.useCallback(()=>t.current&&d2(t.current,"end"),[]),tabIndex:0}),k.createElement("div",{ref:t,style:{outline:"none"},tabIndex:-1,...e}),k.createElement("div",{onFocus:P.useCallback(()=>t.current&&d2(t.current,"start"),[]),tabIndex:0}))}var xM=e=>e.stopPropagation();function mf({children:e,onClose:t,open:n,titleId:r}){P.useEffect(()=>{const f=h=>n&&h.key==="Escape"&&t();return document.addEventListener("keydown",f),()=>document.removeEventListener("keydown",f)},[n,t]);const[s,a]=P.useState(!0);P.useEffect(()=>{a(getComputedStyle(window.document.body).overflow!=="hidden")},[]);const c=P.useCallback(()=>t(),[t]),l=mM(),d=Ct();return k.createElement(k.Fragment,null,n?gg.createPortal(k.createElement(LC,{enabled:s},k.createElement(D,{...l},k.createElement(D,{...l,alignItems:d?"flex-end":"center","aria-labelledby":r,"aria-modal":!0,className:wM,onClick:c,position:"fixed",role:"dialog"},k.createElement(bM,{className:vM,onClick:xM,role:"document"},e)))),document.body):null)}var CM="_1ckjpok7",EM="_1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r",AM="_1ckjpok4 _1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r",kM="_1ckjpok6 ju367vq",SM="_1ckjpok3 _1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r",jM="_1ckjpok2 _1ckjpok1 ju367vb6 ju367vdr ju367vp ju367vt ju367vv ju367vel ju367va ju367v15 ju367v6c ju367v8r";function gf({bottomSheetOnMobile:e=!1,children:t,marginTop:n,padding:r="16",paddingBottom:s,wide:a=!1}){const c=Ct(),d=P.useContext(Kf)===cu.COMPACT;return k.createElement(D,{marginTop:n},k.createElement(D,{className:[a?c?jM:d?AM:SM:EM,c?kM:null,c&&e?CM:null].join(" ")},k.createElement(D,{padding:r,paddingBottom:s??r},t)))}var f2=["k","m","b","t"];function Md(e,t=1){return e.toString().replace(new RegExp(`(.+\\.\\d{${t}})\\d+`),"$1").replace(/(\.[1-9]*)0+$/,"$1").replace(/\.$/,"")}function w8(e){if(e<1)return Md(e,3);if(e<10**2)return Md(e,2);if(e<10**4)return new Intl.NumberFormat().format(Number.parseFloat(Md(e,1)));const t=10**1;let n=String(e);for(let r=f2.length-1;r>=0;r--){const s=10**((r+1)*3);if(s<=e){e=e*t/s/t,n=Md(e,1)+f2[r];break}}return n}function b8(e){return e.length<8?e:`${e.substring(0,4)}…${e.substring(e.length-4)}`}function x8(e){if(!e)return"";const t=e.split("."),n=t.pop();return t.join(".").length>24?`${t.join(".").substring(0,24)}...`:`${t.join(".")}.${n}`}var IM=()=>k.createElement("svg",{fill:"none",height:"13",viewBox:"0 0 13 13",width:"13",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Copied"),k.createElement("path",{d:"M4.94568 12.2646C5.41052 12.2646 5.77283 12.0869 6.01892 11.7109L12.39 1.96973C12.5677 1.69629 12.6429 1.44336 12.6429 1.2041C12.6429 0.561523 12.1644 0.0966797 11.5082 0.0966797C11.057 0.0966797 10.7767 0.260742 10.5033 0.691406L4.9115 9.50977L2.07458 5.98926C1.82166 5.68848 1.54822 5.55176 1.16541 5.55176C0.502319 5.55176 0.0238037 6.02344 0.0238037 6.66602C0.0238037 6.95312 0.112671 7.20605 0.358765 7.48633L3.88611 11.7588C4.18005 12.1074 4.50818 12.2646 4.94568 12.2646Z",fill:"currentColor"})),NM=()=>k.createElement("svg",{fill:"none",height:"16",viewBox:"0 0 17 16",width:"17",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Copy"),k.createElement("path",{d:"M3.04236 12.3027H4.18396V13.3008C4.18396 14.8525 5.03845 15.7002 6.59705 15.7002H13.6244C15.183 15.7002 16.0375 14.8525 16.0375 13.3008V6.24609C16.0375 4.69434 15.183 3.84668 13.6244 3.84668H12.4828V2.8418C12.4828 1.29688 11.6283 0.442383 10.0697 0.442383H3.04236C1.48376 0.442383 0.629272 1.29004 0.629272 2.8418V9.90332C0.629272 11.4551 1.48376 12.3027 3.04236 12.3027ZM3.23376 10.5391C2.68689 10.5391 2.39294 10.2656 2.39294 9.68457V3.06055C2.39294 2.47949 2.68689 2.21289 3.23376 2.21289H9.8783C10.4252 2.21289 10.7191 2.47949 10.7191 3.06055V3.84668H6.59705C5.03845 3.84668 4.18396 4.69434 4.18396 6.24609V10.5391H3.23376ZM6.78845 13.9365C6.24158 13.9365 5.94763 13.6699 5.94763 13.0889V6.45801C5.94763 5.87695 6.24158 5.61035 6.78845 5.61035H13.433C13.9799 5.61035 14.2738 5.87695 14.2738 6.45801V13.0889C14.2738 13.6699 13.9799 13.9365 13.433 13.9365H6.78845Z",fill:"currentColor"})),PM=()=>k.createElement("svg",{fill:"none",height:"16",viewBox:"0 0 18 16",width:"18",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Disconnect"),k.createElement("path",{d:"M2.67834 15.5908H9.99963C11.5514 15.5908 12.399 14.7432 12.399 13.1777V10.2656H10.6354V12.9863C10.6354 13.5332 10.3688 13.8271 9.78772 13.8271H2.89026C2.3092 13.8271 2.0426 13.5332 2.0426 12.9863V3.15625C2.0426 2.60254 2.3092 2.30859 2.89026 2.30859H9.78772C10.3688 2.30859 10.6354 2.60254 10.6354 3.15625V5.89746H12.399V2.95801C12.399 1.39941 11.5514 0.544922 9.99963 0.544922H2.67834C1.12659 0.544922 0.278931 1.39941 0.278931 2.95801V13.1777C0.278931 14.7432 1.12659 15.5908 2.67834 15.5908ZM7.43616 8.85059H14.0875L15.0924 8.78906L14.566 9.14453L13.6842 9.96484C13.5406 10.1016 13.4586 10.2861 13.4586 10.4844C13.4586 10.8398 13.7321 11.168 14.1217 11.168C14.3199 11.168 14.4635 11.0928 14.6002 10.9561L16.7809 8.68652C16.986 8.48145 17.0543 8.27637 17.0543 8.06445C17.0543 7.85254 16.986 7.64746 16.7809 7.43555L14.6002 5.17285C14.4635 5.03613 14.3199 4.9541 14.1217 4.9541C13.7321 4.9541 13.4586 5.27539 13.4586 5.6377C13.4586 5.83594 13.5406 6.02734 13.6842 6.15723L14.566 6.98438L15.0924 7.33984L14.0875 7.27148H7.43616C7.01917 7.27148 6.65686 7.62012 6.65686 8.06445C6.65686 8.50195 7.01917 8.85059 7.43616 8.85059Z",fill:"currentColor"}));function BM(){const e=s8(),{address:t}=it(),n=Ig();return P.useCallback(()=>{if(!t||!n)throw new Error("No address or chain ID found");e.clearTransactions(t,n)},[e,t,n])}var C8=e=>{var t,n;return(n=(t=e==null?void 0:e.blockExplorers)==null?void 0:t.default)==null?void 0:n.url},E8=()=>k.createElement("svg",{fill:"none",height:"19",viewBox:"0 0 20 19",width:"20",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Link"),k.createElement("path",{d:"M10 18.9443C15.0977 18.9443 19.2812 14.752 19.2812 9.6543C19.2812 4.56543 15.0889 0.373047 10 0.373047C4.90234 0.373047 0.71875 4.56543 0.71875 9.6543C0.71875 14.752 4.91113 18.9443 10 18.9443ZM10 16.6328C6.1416 16.6328 3.03906 13.5215 3.03906 9.6543C3.03906 5.7959 6.13281 2.68457 10 2.68457C13.8584 2.68457 16.9697 5.7959 16.9697 9.6543C16.9785 13.5215 13.8672 16.6328 10 16.6328ZM12.7158 12.1416C13.2432 12.1416 13.5684 11.7549 13.5684 11.1836V7.19336C13.5684 6.44629 13.1377 6.05957 12.417 6.05957H8.40918C7.8291 6.05957 7.45117 6.38477 7.45117 6.91211C7.45117 7.43945 7.8291 7.77344 8.40918 7.77344H9.69238L10.7207 7.63281L9.53418 8.67871L6.73047 11.4912C6.53711 11.6758 6.41406 11.9395 6.41406 12.2031C6.41406 12.7832 6.85352 13.1699 7.39844 13.1699C7.68848 13.1699 7.92578 13.0732 8.1543 12.8623L10.9316 10.0762L11.9775 8.89844L11.8545 9.98828V11.1836C11.8545 11.7725 12.1885 12.1416 12.7158 12.1416Z",fill:"currentColor"})),_M=()=>k.createElement("svg",{fill:"none",height:"19",viewBox:"0 0 20 19",width:"20",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Cancel"),k.createElement("path",{d:"M10 18.9443C15.0977 18.9443 19.2812 14.752 19.2812 9.6543C19.2812 4.56543 15.0889 0.373047 10 0.373047C4.90234 0.373047 0.71875 4.56543 0.71875 9.6543C0.71875 14.752 4.91113 18.9443 10 18.9443ZM10 16.6328C6.1416 16.6328 3.03906 13.5215 3.03906 9.6543C3.03906 5.7959 6.13281 2.68457 10 2.68457C13.8584 2.68457 16.9697 5.7959 16.9697 9.6543C16.9785 13.5215 13.8672 16.6328 10 16.6328ZM7.29297 13.3018C7.58301 13.3018 7.81152 13.2139 7.99609 13.0205L10 11.0166L12.0127 13.0205C12.1973 13.2051 12.4258 13.3018 12.707 13.3018C13.2432 13.3018 13.6562 12.8887 13.6562 12.3525C13.6562 12.0977 13.5508 11.8691 13.3662 11.6934L11.3535 9.67188L13.375 7.6416C13.5596 7.44824 13.6562 7.22852 13.6562 6.98242C13.6562 6.44629 13.2432 6.0332 12.7158 6.0332C12.4346 6.0332 12.2148 6.12109 12.0215 6.31445L10 8.32715L7.9873 6.32324C7.80273 6.12988 7.58301 6.04199 7.29297 6.04199C6.76562 6.04199 6.35254 6.45508 6.35254 6.99121C6.35254 7.2373 6.44922 7.46582 6.63379 7.6416L8.65527 9.67188L6.63379 11.6934C6.44922 11.8691 6.35254 12.1064 6.35254 12.3525C6.35254 12.8887 6.76562 13.3018 7.29297 13.3018Z",fill:"currentColor"})),TM=()=>k.createElement("svg",{fill:"none",height:"20",viewBox:"0 0 20 20",width:"20",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Success"),k.createElement("path",{d:"M10 19.4443C15.0977 19.4443 19.2812 15.252 19.2812 10.1543C19.2812 5.06543 15.0889 0.873047 10 0.873047C4.90234 0.873047 0.71875 5.06543 0.71875 10.1543C0.71875 15.252 4.91113 19.4443 10 19.4443ZM10 17.1328C6.1416 17.1328 3.03906 14.0215 3.03906 10.1543C3.03906 6.2959 6.13281 3.18457 10 3.18457C13.8584 3.18457 16.9697 6.2959 16.9697 10.1543C16.9785 14.0215 13.8672 17.1328 10 17.1328ZM9.07715 14.3379C9.4375 14.3379 9.7627 14.1533 9.97363 13.8369L13.7441 8.00977C13.8848 7.79883 13.9814 7.5791 13.9814 7.36816C13.9814 6.84961 13.5244 6.48926 13.0322 6.48926C12.707 6.48926 12.4258 6.66504 12.2148 7.0166L9.05957 12.0967L7.5918 10.2949C7.37207 10.0225 7.13477 9.9082 6.84473 9.9082C6.33496 9.9082 5.92188 10.3125 5.92188 10.8223C5.92188 11.0684 6.00098 11.2793 6.18555 11.5078L8.1543 13.8545C8.40918 14.1709 8.70801 14.3379 9.07715 14.3379Z",fill:"currentColor"})),OM=e=>{switch(e){case"pending":return Nl;case"confirmed":return TM;case"failed":return _M;default:return Nl}};function RM({tx:e}){const t=Ct(),n=OM(e.status),r=e.status==="failed"?"error":"accentColor",{chain:s}=it(),a=e.status==="confirmed"?"Confirmed":e.status==="failed"?"Failed":"Pending",c=C8(s);return k.createElement(k.Fragment,null,k.createElement(D,{...c?{as:"a",background:{hover:"profileForeground"},borderRadius:"menuButton",className:wt({active:"shrink"}),href:`${c}/tx/${e.hash}`,rel:"noreferrer noopener",target:"_blank",transition:"default"}:{},color:"modalText",display:"flex",flexDirection:"row",justifyContent:"space-between",padding:"8",width:"full"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:t?"16":"14"},k.createElement(D,{color:r},k.createElement(n,null)),k.createElement(D,{display:"flex",flexDirection:"column",gap:t?"3":"1"},k.createElement(D,null,k.createElement(xe,{color:"modalText",font:"body",size:t?"16":"14",weight:"bold"},e==null?void 0:e.description)),k.createElement(D,null,k.createElement(xe,{color:e.status==="pending"?"modalTextSecondary":r,font:"body",size:"14",weight:t?"medium":"regular"},a)))),c&&k.createElement(D,{alignItems:"center",color:"modalTextDim",display:"flex"},k.createElement(E8,null))))}var MM=3;function DM({address:e}){const t=i8(),n=BM(),{chain:r}=it(),s=C8(r),a=t.slice(0,MM),c=a.length>0,l=Ct(),{appName:d}=P.useContext(iu),{i18n:f}=P.useContext(Et);return k.createElement(k.Fragment,null,k.createElement(D,{display:"flex",flexDirection:"column",gap:"10",paddingBottom:"2",paddingTop:"16",paddingX:l?"8":"18"},c&&k.createElement(D,{paddingBottom:l?"4":"0",paddingTop:"8",paddingX:l?"12":"6"},k.createElement(D,{display:"flex",justifyContent:"space-between"},k.createElement(xe,{color:"modalTextSecondary",size:l?"16":"14",weight:"semibold"},f.t("profile.transactions.recent.title")),k.createElement(D,{style:{marginBottom:-6,marginLeft:-10,marginRight:-10,marginTop:-6}},k.createElement(D,{as:"button",background:{hover:"profileForeground"},borderRadius:"actionButton",className:wt({active:"shrink"}),onClick:n,paddingX:l?"8":"12",paddingY:l?"4":"5",transition:"default",type:"button"},k.createElement(xe,{color:"modalTextSecondary",size:l?"16":"14",weight:"semibold"},f.t("profile.transactions.clear.label")))))),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},c?a.map(h=>k.createElement(RM,{key:h.hash,tx:h})):k.createElement(k.Fragment,null,k.createElement(D,{padding:l?"12":"8"},k.createElement(xe,{color:"modalTextDim",size:l?"16":"14",weight:l?"medium":"bold"},d?f.t("profile.transactions.description",{appName:d}):f.t("profile.transactions.description_fallback"))),l&&k.createElement(D,{background:"generalBorderDim",height:"1",marginX:"12",marginY:"8"})))),s&&k.createElement(D,{paddingBottom:"18",paddingX:l?"8":"18"},k.createElement(D,{alignItems:"center",as:"a",background:{hover:"profileForeground"},borderRadius:"menuButton",className:wt({active:"shrink"}),color:"modalTextDim",display:"flex",flexDirection:"row",href:`${s}/address/${e}`,justifyContent:"space-between",paddingX:"8",paddingY:"12",rel:"noreferrer noopener",style:{willChange:"transform"},target:"_blank",transition:"default",width:"full",...l?{paddingLeft:"12"}:{}},k.createElement(xe,{color:"modalText",font:"body",size:l?"16":"14",weight:l?"semibold":"bold"},f.t("profile.explorer.label")),k.createElement(E8,null))))}function h2({action:e,icon:t,label:n,testId:r,url:s}){const a=Ct();return k.createElement(D,{...s?{as:"a",href:s,rel:"noreferrer noopener",target:"_blank"}:{as:"button",type:"button"},background:{base:"profileAction",...a?{}:{hover:"profileActionHover"}},borderRadius:"menuButton",boxShadow:"profileDetailsAction",className:wt({active:"shrinkSm",hover:a?void 0:"grow"}),display:"flex",onClick:e,padding:a?"6":"8",style:{willChange:"transform"},testId:r,transition:"default",width:"full"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"1",justifyContent:"center",paddingTop:"2",width:"full"},k.createElement(D,{color:"modalText",height:"max"},t),k.createElement(D,null,k.createElement(xe,{color:"modalText",size:a?"12":"13",weight:"semibold"},n))))}function FM({address:e,ensAvatar:t,ensName:n,balance:r,onClose:s,onDisconnect:a}){const c=P.useContext(Ng),[l,d]=P.useState(!1),f=P.useCallback(()=>{e&&(navigator.clipboard.writeText(e),d(!0))},[e]);if(P.useEffect(()=>{if(l){const C=setTimeout(()=>{d(!1)},1500);return()=>clearTimeout(C)}},[l]),!e)return null;const h=n?x8(n):b8(e),p=r==null?void 0:r.formatted,m=p?w8(Number.parseFloat(p)):void 0,y="rk_profile_title",v=Ct(),{i18n:w}=P.useContext(Et);return k.createElement(k.Fragment,null,k.createElement(D,{display:"flex",flexDirection:"column"},k.createElement(D,{background:"profileForeground",padding:"16"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:v?"16":"12",justifyContent:"center",margin:"8",style:{textAlign:"center"}},k.createElement(D,{style:{position:"absolute",right:16,top:16,willChange:"transform"}},k.createElement(yi,{onClose:s}))," ",k.createElement(D,{marginTop:v?"24":"0"},k.createElement(JC,{address:e,imageUrl:t,size:v?82:74})),k.createElement(D,{display:"flex",flexDirection:"column",gap:v?"4":"0",textAlign:"center"},k.createElement(D,{textAlign:"center"},k.createElement(xe,{as:"h1",color:"modalText",id:y,size:v?"20":"18",weight:"heavy"},h)),!!r&&k.createElement(D,{textAlign:"center"},k.createElement(xe,{as:"h1",color:"modalTextSecondary",id:y,size:v?"16":"14",weight:"semibold"},m," ",r.symbol)))),k.createElement(D,{display:"flex",flexDirection:"row",gap:"8",margin:"2",marginTop:"16"},k.createElement(h2,{action:f,icon:l?k.createElement(IM,null):k.createElement(NM,null),label:l?w.t("profile.copy_address.copied"):w.t("profile.copy_address.label")}),k.createElement(h2,{action:a,icon:k.createElement(PM,null),label:w.t("profile.disconnect.label"),testId:"disconnect-button"}))),c&&k.createElement(k.Fragment,null,k.createElement(D,{background:"generalBorder",height:"1",marginTop:"-1"}),k.createElement(D,null,k.createElement(DM,{address:e})))))}function LM({onClose:e,open:t}){const{address:n}=it(),{balance:r,ensAvatar:s,ensName:a}=n8({address:n,includeBalance:t}),{disconnect:c}=ou();return n?k.createElement(k.Fragment,null,n&&k.createElement(mf,{onClose:e,open:t,titleId:"rk_account_modal_title"},k.createElement(gf,{bottomSheetOnMobile:!0,padding:"0"},k.createElement(FM,{address:n,ensAvatar:s,ensName:a,balance:r,onClose:e,onDisconnect:c})))):null}var UM=({size:e})=>k.createElement("svg",{fill:"none",height:e,viewBox:"0 0 28 28",width:e,xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Disconnect"),k.createElement("path",{d:"M6.742 22.195h8.367c1.774 0 2.743-.968 2.743-2.758V16.11h-2.016v3.11c0 .625-.305.96-.969.96H6.984c-.664 0-.968-.335-.968-.96V7.984c0-.632.304-.968.968-.968h7.883c.664 0 .969.336.969.968v3.133h2.016v-3.36c0-1.78-.97-2.757-2.743-2.757H6.742C4.97 5 4 5.977 4 7.758v11.68c0 1.789.969 2.757 2.742 2.757Zm5.438-7.703h7.601l1.149-.07-.602.406-1.008.938a.816.816 0 0 0-.258.593c0 .407.313.782.758.782.227 0 .39-.086.547-.243l2.492-2.593c.235-.235.313-.47.313-.711 0-.242-.078-.477-.313-.719l-2.492-2.586c-.156-.156-.32-.25-.547-.25-.445 0-.758.367-.758.781 0 .227.094.446.258.594l1.008.945.602.407-1.149-.079H12.18a.904.904 0 0 0 0 1.805Z",fill:"currentColor"})),zM="v9horb0",Og=k.forwardRef(({children:e,currentlySelected:t=!1,onClick:n,testId:r,...s},a)=>{const c=Ct();return k.createElement(D,{as:"button",borderRadius:"menuButton",disabled:t,display:"flex",onClick:n,ref:a,testId:r,type:"button"},k.createElement(D,{borderRadius:"menuButton",className:[c?zM:void 0,!t&&wt({active:"shrink"})],padding:c?"8":"6",transition:"default",width:"full",...t?{background:"accentColor",borderColor:"selectedOptionBorder",borderStyle:"solid",borderWidth:"1",boxShadow:"selectedOption",color:"accentColorForeground"}:{background:{hover:"menuItemBackground"},color:"modalText",transition:"default"},...s},e))});Og.displayName="MenuButton";var WM=({chainId:e,currentChainId:t,switchChain:n,chainIconSize:r,isLoading:s,src:a,name:c,iconBackground:l,idx:d})=>{const f=Ct(),{i18n:h}=P.useContext(Et),p=Ei(),m=t===e;return k.createElement(P.Fragment,null,k.createElement(Og,{currentlySelected:m,onClick:m?void 0:()=>n({chainId:e}),testId:`chain-option-${e}`},k.createElement(D,{fontFamily:"body",fontSize:"16",fontWeight:"bold"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",justifyContent:"space-between"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"4",height:r},a&&k.createElement(D,{height:"full",marginRight:"8"},k.createElement(Rt,{alt:c,background:l,borderRadius:"full",height:r,src:a,width:r,testId:`chain-option-${e}-icon`})),k.createElement("div",null,c??c)),m&&k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",marginRight:"6"},k.createElement(xe,{color:"accentColorForeground",size:"14",weight:"medium"},h.t("chains.connected")),k.createElement(D,{background:"connectionIndicator",borderColor:"selectedOptionBorder",borderRadius:"full",borderStyle:"solid",borderWidth:"1",height:"8",marginLeft:"8",width:"8"})),s&&k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",marginRight:"6"},k.createElement(xe,{color:"modalText",size:"14",weight:"medium"},h.t("chains.confirm")),k.createElement(D,{background:"standby",borderRadius:"full",height:"8",marginLeft:"8",width:"8"}))))),f&&d<p.length-1&&k.createElement(D,{background:"generalBorderDim",height:"1",marginX:"8"}))},$M=WM,qM="_18dqw9x0",HM="_18dqw9x1";function VM({onClose:e,open:t}){const{chainId:n}=it(),{chains:r}=ut(),[s,a]=P.useState(null),{switchChain:c}=rC({mutation:{onMutate:({chainId:v})=>{a(v)},onSuccess:()=>{s&&a(null)},onError:()=>{s&&a(null)},onSettled:()=>{e()}}}),{i18n:l}=P.useContext(Et),{disconnect:d}=ou(),f="rk_chain_modal_title",h=Ct(),p=r.some(v=>v.id===n),m=h?"36":"28",y=Ei();return n?k.createElement(mf,{onClose:e,open:t,titleId:f},k.createElement(gf,{bottomSheetOnMobile:!0,paddingBottom:"0"},k.createElement(D,{display:"flex",flexDirection:"column",gap:"14"},k.createElement(D,{display:"flex",flexDirection:"row",justifyContent:"space-between"},h&&k.createElement(D,{width:"30"}),k.createElement(D,{paddingBottom:"0",paddingLeft:"8",paddingTop:"4"},k.createElement(xe,{as:"h1",color:"modalText",id:f,size:h?"20":"18",weight:"heavy"},l.t("chains.title"))),k.createElement(yi,{onClose:e})),!p&&k.createElement(D,{marginX:"8",textAlign:h?"center":"left"},k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},l.t("chains.wrong_network"))),k.createElement(D,{className:h?HM:qM,display:"flex",flexDirection:"column",gap:"4",padding:"2",paddingBottom:"16"},y.map(({iconBackground:v,iconUrl:w,id:C,name:A},I)=>k.createElement($M,{key:C,chainId:C,currentChainId:n,switchChain:c,chainIconSize:m,isLoading:s===C,src:w,name:A,iconBackground:v,idx:I})),!p&&k.createElement(k.Fragment,null,k.createElement(D,{background:"generalBorderDim",height:"1",marginX:"8"}),k.createElement(Og,{onClick:()=>d(),testId:"chain-option-disconnect"},k.createElement(D,{color:"error",fontFamily:"body",fontSize:"16",fontWeight:"bold"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",justifyContent:"space-between"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"4",height:m},k.createElement(D,{alignItems:"center",color:"error",height:m,justifyContent:"center",marginRight:"8"},k.createElement(UM,{size:Number(m)})),k.createElement("div",null,l.t("chains.disconnect"))))))))))):null}function QM(e,t){const n={};for(const r of e){const s=t(r);s&&(n[s]||(n[s]=[]),n[s].push(r))}return n}var Rg=({children:e,href:t})=>k.createElement(D,{as:"a",color:"accentColor",href:t,rel:"noreferrer",target:"_blank"},e),Mg=({children:e})=>k.createElement(xe,{color:"modalTextSecondary",size:"12",weight:"medium"},e);function p2({compactModeEnabled:e=!1,getWallet:t}){const{disclaimer:n,learnMoreUrl:r}=P.useContext(iu),{i18n:s}=P.useContext(Et);return k.createElement(k.Fragment,null,k.createElement(D,{alignItems:"center",color:"accentColor",display:"flex",flexDirection:"column",height:"full",justifyContent:"space-around"},k.createElement(D,{marginBottom:"10"},!e&&k.createElement(xe,{color:"modalText",size:"18",weight:"heavy"},s.t("intro.title"))),k.createElement(D,{display:"flex",flexDirection:"column",gap:"32",justifyContent:"center",marginY:"20",style:{maxWidth:312}},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16"},k.createElement(D,{borderRadius:"6",height:"48",minWidth:"48",width:"48"},k.createElement(sM,null)),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},s.t("intro.digital_asset.title")),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},s.t("intro.digital_asset.description")))),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16"},k.createElement(D,{borderRadius:"6",height:"48",minWidth:"48",width:"48"},k.createElement(aM,null)),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},s.t("intro.login.title")),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},s.t("intro.login.description"))))),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",margin:"10"},k.createElement(ln,{label:s.t("intro.get.label"),onClick:t}),k.createElement(D,{as:"a",className:wt({active:"shrink",hover:"grow"}),display:"block",href:r,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},k.createElement(xe,{color:"accentColor",size:"14",weight:"bold"},s.t("intro.learn_more.label")))),n&&!e&&k.createElement(D,{marginBottom:"8",marginTop:"12",textAlign:"center"},k.createElement(n,{Link:Rg,Text:Mg}))))}var A8=()=>k.createElement("svg",{fill:"none",height:"17",viewBox:"0 0 11 17",width:"11",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Back"),k.createElement("path",{d:"M0.99707 8.6543C0.99707 9.08496 1.15527 9.44531 1.51562 9.79688L8.16016 16.3096C8.43262 16.5732 8.74902 16.7051 9.13574 16.7051C9.90918 16.7051 10.5508 16.0811 10.5508 15.3076C10.5508 14.9121 10.3838 14.5605 10.0938 14.2705L4.30176 8.64551L10.0938 3.0293C10.3838 2.74805 10.5508 2.3877 10.5508 2.00098C10.5508 1.23633 9.90918 0.603516 9.13574 0.603516C8.74902 0.603516 8.43262 0.735352 8.16016 0.999023L1.51562 7.51172C1.15527 7.85449 1.00586 8.21484 0.99707 8.6543Z",fill:"currentColor"})),GM=()=>k.createElement("svg",{fill:"none",height:"12",viewBox:"0 0 8 12",width:"8",xmlns:"http://www.w3.org/2000/svg"},k.createElement("title",null,"Info"),k.createElement("path",{d:"M3.64258 7.99609C4.19336 7.99609 4.5625 7.73828 4.68555 7.24609C4.69141 7.21094 4.70312 7.16406 4.70898 7.13477C4.80859 6.60742 5.05469 6.35547 6.04492 5.76367C7.14648 5.10156 7.67969 4.3457 7.67969 3.24414C7.67969 1.39844 6.17383 0.255859 3.95898 0.255859C2.32422 0.255859 1.05859 0.894531 0.548828 1.86719C0.396484 2.14844 0.320312 2.44727 0.320312 2.74023C0.314453 3.37305 0.742188 3.79492 1.42188 3.79492C1.91406 3.79492 2.33594 3.54883 2.53516 3.11523C2.78711 2.47656 3.23242 2.21289 3.83594 2.21289C4.55664 2.21289 5.10742 2.65234 5.10742 3.29102C5.10742 3.9707 4.7793 4.29883 3.81836 4.87891C3.02148 5.36523 2.50586 5.92773 2.50586 6.76562V6.90039C2.50586 7.55664 2.96289 7.99609 3.64258 7.99609ZM3.67188 11.4473C4.42773 11.4473 5.04297 10.8672 5.04297 10.1406C5.04297 9.41406 4.42773 8.83984 3.67188 8.83984C2.91602 8.83984 2.30664 9.41406 2.30664 10.1406C2.30664 10.8672 2.91602 11.4473 3.67188 11.4473Z",fill:"currentColor"})),KM=({"aria-label":e="Info",onClick:t})=>{const n=Ct();return k.createElement(D,{alignItems:"center","aria-label":e,as:"button",background:"closeButtonBackground",borderColor:"actionButtonBorder",borderRadius:"full",borderStyle:"solid",borderWidth:n?"0":"1",className:wt({active:"shrinkSm",hover:"growLg"}),color:"closeButton",display:"flex",height:n?"30":"28",justifyContent:"center",onClick:t,style:{willChange:"transform"},transition:"default",type:"button",width:n?"30":"28"},k.createElement(GM,null))},k8=e=>{const t=P.useRef(null),n=P.useContext(c8),r=Gf(e);return P.useEffect(()=>{if(n&&t.current&&r)return JM(t.current,r)},[n,r]),t},YM=()=>{const e="_rk_coolMode",t=document.getElementById(e);if(t)return t;const n=document.createElement("div");return n.setAttribute("id",e),n.setAttribute("style",["overflow:hidden","position:fixed","height:100%","top:0","left:0","right:0","bottom:0","pointer-events:none","z-index:2147483647"].join(";")),document.body.appendChild(n),n},m2=0;function JM(e,t){m2++;const n=[15,20,25,35,45],r=35;let s=[],a=!1,c=0,l=0;const d=YM();function f(){const j=n[Math.floor(Math.random()*n.length)],N=Math.random()*10,T=Math.random()*25,B=Math.random()*360,O=Math.random()*35*(Math.random()<=.5?-1:1),R=l-j/2,W=c-j/2,H=Math.random()<=.5?-1:1,K=document.createElement("div");K.innerHTML=`<img src="${t}" width="${j}" height="${j}" style="border-radius: 25%">`,K.setAttribute("style",["position:absolute","will-change:transform",`top:${R}px`,`left:${W}px`,`transform:rotate(${B}deg)`].join(";")),d.appendChild(K),s.push({direction:H,element:K,left:W,size:j,speedHorz:N,speedUp:T,spinSpeed:O,spinVal:B,top:R})}function h(){for(const j of s)j.left=j.left-j.speedHorz*j.direction,j.top=j.top-j.speedUp,j.speedUp=Math.min(j.size,j.speedUp-1),j.spinVal=j.spinVal+j.spinSpeed,j.top>=Math.max(window.innerHeight,document.body.clientHeight)+j.size&&(s=s.filter(N=>N!==j),j.element.remove()),j.element.setAttribute("style",["position:absolute","will-change:transform",`top:${j.top}px`,`left:${j.left}px`,`transform:rotate(${j.spinVal}deg)`].join(";"))}let p;function m(){a&&s.length<r&&f(),h(),p=requestAnimationFrame(m)}m();const y="ontouchstart"in window||navigator.msMaxTouchPoints,v=y?"touchstart":"mousedown",w=y?"touchend":"mouseup",C=y?"touchmove":"mousemove",A=j=>{var N,T;"touches"in j?(c=(N=j.touches)==null?void 0:N[0].clientX,l=(T=j.touches)==null?void 0:T[0].clientY):(c=j.clientX,l=j.clientY)},I=j=>{A(j),a=!0},S=()=>{a=!1};return e.addEventListener(C,A,{passive:!1}),e.addEventListener(v,I),e.addEventListener(w,S),e.addEventListener("mouseleave",S),()=>{e.removeEventListener(C,A),e.removeEventListener(v,I),e.removeEventListener(w,S),e.removeEventListener("mouseleave",S);const j=setInterval(()=>{p&&s.length===0&&(cancelAnimationFrame(p),clearInterval(j),--m2===0&&d.remove())},500)}}var ZM="g5kl0l0",S8=({as:e="button",currentlySelected:t=!1,iconBackground:n,iconUrl:r,name:s,onClick:a,ready:c,recent:l,testId:d,isRainbowKitConnector:f,...h})=>{const p=k8(r),[m,y]=k.useState(!1),{i18n:v}=k.useContext(Et);return k.createElement(D,{display:"flex",flexDirection:"column",onMouseEnter:()=>y(!0),onMouseLeave:()=>y(!1),ref:p},k.createElement(D,{as:e,borderRadius:"menuButton",borderStyle:"solid",borderWidth:"1",className:t?void 0:[ZM,wt({active:"shrink"})],disabled:t,onClick:a,padding:"5",style:{willChange:"transform"},testId:d,transition:"default",width:"full",...t?{background:"accentColor",borderColor:"selectedOptionBorder",boxShadow:"selectedWallet"}:{background:{hover:"menuItemBackground"}},...h},k.createElement(D,{color:t?"accentColorForeground":"modalText",disabled:!c,fontFamily:"body",fontSize:"16",fontWeight:"bold",transition:"default"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"12"},k.createElement(Rt,{background:n,...!m&&f?{borderColor:"actionButtonBorder"}:{},useAsImage:!f,borderRadius:"6",height:"28",src:r,width:"28"}),k.createElement(D,null,k.createElement(D,{style:{marginTop:l?-2:void 0},maxWidth:"200"},s),l&&k.createElement(xe,{color:t?"accentColorForeground":"accentColor",size:"12",style:{lineHeight:1,marginTop:-1},weight:"medium"},v.t("connect.recent")))))))};S8.displayName="ModalSelection";var XM="rk-latest-id";function eD(e){localStorage.setItem(XM,e)}var Pp=(e,t=1)=>{let n=e.replace("#","");n.length===3&&(n=`${n[0]}${n[0]}${n[1]}${n[1]}${n[2]}${n[2]}`);const r=Number.parseInt(n.substring(0,2),16),s=Number.parseInt(n.substring(2,4),16),a=Number.parseInt(n.substring(4,6),16);return t>1&&t<=100&&(t=t/100),`rgba(${r},${s},${a},${t})`},tD=e=>e?[Pp(e,.2),Pp(e,.14),Pp(e,.1)]:null,nD=e=>/^#([0-9a-f]{3}){1,2}$/i.test(e),j8=async()=>(await de(async()=>{const{default:e}=await import("./connect-UA7M4XW6-IY3X6Bmr.js");return{default:e}},[])).default,rD=()=>Gr(j8),oD=()=>k.createElement(Rt,{background:"#515a70",borderColor:"generalBorder",borderRadius:"10",height:"48",src:j8,width:"48"}),I8=async()=>(await de(async()=>{const{default:e}=await import("./create-FASO7PVG-D_rvSpre.js");return{default:e}},[])).default,N8=()=>Gr(I8),sD=()=>k.createElement(Rt,{background:"#e3a5e8",borderColor:"generalBorder",borderRadius:"10",height:"48",src:I8,width:"48"}),P8=async()=>(await de(async()=>{const{default:e}=await import("./refresh-S4T5V5GX-CwqIaaxK.js");return{default:e}},[])).default,iD=()=>Gr(P8),aD=()=>k.createElement(Rt,{background:"#515a70",borderColor:"generalBorder",borderRadius:"10",height:"48",src:P8,width:"48"}),B8=async()=>(await de(async()=>{const{default:e}=await import("./scan-4UYSQ56Q-CjMz6-XC.js");return{default:e}},[])).default,_8=()=>Gr(B8),cD=()=>k.createElement(Rt,{background:"#515a70",borderColor:"generalBorder",borderRadius:"10",height:"48",src:B8,width:"48"}),lD="_1vwt0cg0",uD="_1vwt0cg2 ju367v7a ju367v7v",dD="_1vwt0cg3",fD="_1vwt0cg4";function T8({ecc:e="medium",logoBackground:t,logoSize:n=50,logoUrl:r,size:s=200,uri:a}){const l=s-Number.parseInt("20",10)*2,d=Gf(r);return k.createElement(D,{borderColor:"generalBorder",borderRadius:"menuButton",borderStyle:"solid",borderWidth:"1",className:lD,padding:"20",width:"max"},k.createElement(D,{style:{height:l,userSelect:"none",width:l},userSelect:"none"},k.createElement(Lr.Root,{errorCorrection:e,size:l,value:a},k.createElement(Lr.Cells,{radius:1}),k.createElement(Lr.Finder,{radius:.25}),d&&k.createElement(Lr.Arena,null,k.createElement("img",{alt:"Wallet Logo",src:d,style:{objectFit:"cover",height:"88%",width:"88%",borderRadius:"22.5%",backgroundColor:t}})))))}var O8=async()=>{switch(Bg()){case"Arc":return(await de(async()=>{const{default:t}=await import("./Arc-VDBY7LNS-BChRXCXW.js");return{default:t}},[])).default;case"Brave":return(await de(async()=>{const{default:t}=await import("./Brave-BRAKJXDS-mq-Xo37j.js");return{default:t}},[])).default;case"Chrome":return(await de(async()=>{const{default:t}=await import("./Chrome-65Q5P54Y-DR9MQEVr.js");return{default:t}},[])).default;case"Edge":return(await de(async()=>{const{default:t}=await import("./Edge-XSPUTORV-DEoZslQE.js");return{default:t}},[])).default;case"Firefox":return(await de(async()=>{const{default:t}=await import("./Firefox-AAHGJQIP-Bp_Hm04m.js");return{default:t}},[])).default;case"Opera":return(await de(async()=>{const{default:t}=await import("./Opera-KQZLSACL-Cwv5MDFy.js");return{default:t}},[])).default;case"Safari":return(await de(async()=>{const{default:t}=await import("./Safari-ZPL37GXR-C4Ggg6rz.js");return{default:t}},[])).default;default:return(await de(async()=>{const{default:t}=await import("./Browser-76IHF3Y2-BMhRaC5Z.js");return{default:t}},[])).default}},hD=()=>Gr(O8),R8=async()=>{switch(Tg()){case"Windows":return(await de(async()=>{const{default:t}=await import("./Windows-PPTHQER6-BlyV2p7Y.js");return{default:t}},[])).default;case"macOS":return(await de(async()=>{const{default:t}=await import("./Macos-MW4AE7LN-Vvm8Drw3.js");return{default:t}},[])).default;case"Linux":return(await de(async()=>{const{default:t}=await import("./Linux-OO4TNCLJ-B0aw93n9.js");return{default:t}},[])).default;default:return(await de(async()=>{const{default:t}=await import("./Linux-OO4TNCLJ-B0aw93n9.js");return{default:t}},[])).default}},pD=()=>Gr(R8);function mD({getWalletDownload:e,compactModeEnabled:t}){const r=Pl().filter(a=>a.isRainbowKitConnector).splice(0,5),{i18n:s}=P.useContext(Et);return k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",marginTop:"18",width:"full"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"28",height:"full",width:"full"},r==null?void 0:r.filter(a=>{var c;return a.extensionDownloadUrl||a.desktopDownloadUrl||a.qrCode&&((c=a.downloadUrls)==null?void 0:c.qrCode)}).map(a=>{const{downloadUrls:c,iconBackground:l,iconUrl:d,id:f,name:h,qrCode:p}=a,m=(c==null?void 0:c.qrCode)&&p,y=!!a.extensionDownloadUrl,v=(c==null?void 0:c.qrCode)&&y,w=(c==null?void 0:c.qrCode)&&!!a.desktopDownloadUrl;return k.createElement(D,{alignItems:"center",display:"flex",gap:"16",justifyContent:"space-between",key:a.id,width:"full"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16"},k.createElement(Rt,{background:l,borderColor:"actionButtonBorder",borderRadius:"10",height:"48",src:d,width:"48"}),k.createElement(D,{display:"flex",flexDirection:"column",gap:"2"},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},h),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},v?s.t("get.mobile_and_extension.description"):w?s.t("get.mobile_and_desktop.description"):m?s.t("get.mobile.description"):y?s.t("get.extension.description"):null))),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},k.createElement(ln,{label:s.t("get.action.label"),onClick:()=>e(f),type:"secondary"})))})),k.createElement(D,{alignItems:"center",borderRadius:"10",display:"flex",flexDirection:"column",gap:"8",justifyContent:"space-between",marginBottom:"4",paddingY:"8",style:{maxWidth:275,textAlign:"center"}},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},s.t("get.looking_for.title")),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},t?s.t("get.looking_for.desktop.compact_description"):s.t("get.looking_for.desktop.wide_description"))))}var Bp="44";function gD({changeWalletStep:e,compactModeEnabled:t,connectionError:n,onClose:r,qrCodeUri:s,reconnect:a,wallet:c}){const{downloadUrls:l,iconBackground:d,iconUrl:f,name:h,qrCode:p,ready:m,showWalletConnectModal:y,getDesktopUri:v}=c,w=!!v,C=Pg(),{i18n:A}=P.useContext(Et),I=!!c.extensionDownloadUrl,S=(l==null?void 0:l.qrCode)&&I,j=(l==null?void 0:l.qrCode)&&!!c.desktopDownloadUrl,N=p&&s,T=async()=>{const W=await(v==null?void 0:v());window.open(W,C?"_blank":"_self")},B=y?{description:t?A.t("connect.walletconnect.description.compact"):A.t("connect.walletconnect.description.full"),label:A.t("connect.walletconnect.open.label"),onClick:()=>{r(),y()}}:N?{description:A.t("connect.secondary_action.get.description",{wallet:h}),label:A.t("connect.secondary_action.get.label"),onClick:()=>e(S||j?"DOWNLOAD_OPTIONS":"DOWNLOAD")}:null,{width:O}=l8(),R=O&&O<768;return P.useEffect(()=>{hD(),pD()},[]),k.createElement(D,{display:"flex",flexDirection:"column",height:"full",width:"full"},N?k.createElement(D,{alignItems:"center",display:"flex",height:"full",justifyContent:"center"},k.createElement(T8,{logoBackground:d,logoSize:t?60:72,logoUrl:f,size:t?318:R?Math.max(280,Math.min(O-308,382)):382,uri:s})):k.createElement(D,{alignItems:"center",display:"flex",justifyContent:"center",style:{flexGrow:1}},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"8"},k.createElement(D,{borderRadius:"10",height:Bp,overflow:"hidden"},k.createElement(Rt,{useAsImage:!c.isRainbowKitConnector,height:Bp,src:f,width:Bp})),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"4",paddingX:"32",style:{textAlign:"center"}},k.createElement(xe,{color:"modalText",size:"18",weight:"bold"},m?A.t("connect.status.opening",{wallet:h}):I?A.t("connect.status.not_installed",{wallet:h}):A.t("connect.status.not_available",{wallet:h})),!m&&I?k.createElement(D,{paddingTop:"20"},k.createElement(ln,{href:c.extensionDownloadUrl,label:A.t("connect.secondary_action.install.label"),type:"secondary"})):null,m&&!N&&k.createElement(k.Fragment,null,k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",justifyContent:"center"},k.createElement(xe,{color:"modalTextSecondary",size:"14",textAlign:"center",weight:"medium"},A.t("connect.status.confirm"))),k.createElement(D,{alignItems:"center",color:"modalText",display:"flex",flexDirection:"row",height:"32",marginTop:"8"},n?k.createElement(ln,{label:A.t("connect.secondary_action.retry.label"),onClick:async()=>{w&&T(),a(c)}}):k.createElement(D,{color:"modalTextSecondary"},k.createElement(Nl,null))))))),k.createElement(D,{alignItems:"center",borderRadius:"10",display:"flex",flexDirection:"row",gap:"8",height:"28",justifyContent:"space-between",marginTop:"12"},m&&B&&k.createElement(k.Fragment,null,k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},B.description),k.createElement(ln,{label:B.label,onClick:B.onClick,type:"secondary"}))))}var _p=({actionLabel:e,description:t,iconAccent:n,iconBackground:r,iconUrl:s,isCompact:a,onAction:c,title:l,url:d,variant:f})=>{const h=f==="browser",p=!h&&n&&tD(n);return k.createElement(D,{alignItems:"center",borderRadius:"13",display:"flex",justifyContent:"center",overflow:"hidden",paddingX:a?"18":"44",position:"relative",style:{flex:1,isolation:"isolate"},width:"full"},k.createElement(D,{borderColor:"actionButtonBorder",borderRadius:"13",borderStyle:"solid",borderWidth:"1",style:{bottom:"0",left:"0",position:"absolute",right:"0",top:"0",zIndex:1}}),h&&k.createElement(D,{background:"downloadTopCardBackground",height:"full",position:"absolute",style:{zIndex:0},width:"full"},k.createElement(D,{display:"flex",flexDirection:"row",justifyContent:"space-between",style:{bottom:"0",filter:"blur(20px)",left:"0",position:"absolute",right:"0",top:"0",transform:"translate3d(0, 0, 0)"}},k.createElement(D,{style:{filter:"blur(100px)",marginLeft:-27,marginTop:-20,opacity:.6,transform:"translate3d(0, 0, 0)"}},k.createElement(Rt,{borderRadius:"full",height:"200",src:s,width:"200"})),k.createElement(D,{style:{filter:"blur(100px)",marginRight:0,marginTop:105,opacity:.6,overflow:"auto",transform:"translate3d(0, 0, 0)"}},k.createElement(Rt,{borderRadius:"full",height:"200",src:s,width:"200"})))),!h&&p&&k.createElement(D,{background:"downloadBottomCardBackground",style:{bottom:"0",left:"0",position:"absolute",right:"0",top:"0"}},k.createElement(D,{position:"absolute",style:{background:`radial-gradient(50% 50% at 50% 50%, ${p[0]} 0%, ${p[1]} 25%, rgba(0,0,0,0) 100%)`,height:564,left:-215,top:-197,transform:"translate3d(0, 0, 0)",width:564}}),k.createElement(D,{position:"absolute",style:{background:`radial-gradient(50% 50% at 50% 50%, ${p[2]} 0%, rgba(0, 0, 0, 0) 100%)`,height:564,left:-1,top:-76,transform:"translate3d(0, 0, 0)",width:564}})),k.createElement(D,{alignItems:"flex-start",display:"flex",flexDirection:"row",gap:"24",height:"max",justifyContent:"center",style:{zIndex:1}},k.createElement(D,null,k.createElement(Rt,{height:"60",src:s,width:"60",...r?{background:r,borderColor:"generalBorder",borderRadius:"10"}:null})),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4",style:{flex:1},width:"full"},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},l),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},t),k.createElement(D,{marginTop:"14",width:"max"},k.createElement(ln,{href:d,label:e,onClick:c,size:"medium"})))))};function yD({changeWalletStep:e,wallet:t}){const n=Bg(),r=Tg(),a=P.useContext(Kf)==="compact",{desktop:c,desktopDownloadUrl:l,extension:d,extensionDownloadUrl:f,mobileDownloadUrl:h}=t,{i18n:p}=P.useContext(Et);return P.useEffect(()=>{N8(),_8(),iD(),rD()},[]),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"24",height:"full",marginBottom:"8",marginTop:"4",width:"full"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"8",height:"full",justifyContent:"center",width:"full"},f&&k.createElement(_p,{actionLabel:p.t("get_options.extension.download.label",{browser:n}),description:p.t("get_options.extension.description"),iconUrl:O8,isCompact:a,onAction:()=>e(d!=null&&d.instructions?"INSTRUCTIONS_EXTENSION":"CONNECT"),title:p.t("get_options.extension.title",{wallet:t.name,browser:n}),url:f,variant:"browser"}),l&&k.createElement(_p,{actionLabel:p.t("get_options.desktop.download.label",{platform:r}),description:p.t("get_options.desktop.description"),iconUrl:R8,isCompact:a,onAction:()=>e(c!=null&&c.instructions?"INSTRUCTIONS_DESKTOP":"CONNECT"),title:p.t("get_options.desktop.title",{wallet:t.name,platform:r}),url:l,variant:"desktop"}),h&&k.createElement(_p,{actionLabel:p.t("get_options.mobile.download.label",{wallet:t.name}),description:p.t("get_options.mobile.description"),iconAccent:t.iconAccent,iconBackground:t.iconBackground,iconUrl:t.iconUrl,isCompact:a,onAction:()=>{e("DOWNLOAD")},title:p.t("get_options.mobile.title",{wallet:t.name}),variant:"app"})))}function vD({changeWalletStep:e,wallet:t}){const{downloadUrls:n,qrCode:r}=t,{i18n:s}=P.useContext(Et);return P.useEffect(()=>{N8(),_8()},[]),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"24",height:"full",width:"full"},k.createElement(D,{style:{maxWidth:220,textAlign:"center"}},k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"semibold"},s.t("get_mobile.description"))),k.createElement(D,{height:"full"},n!=null&&n.qrCode?k.createElement(T8,{logoSize:0,size:268,uri:n.qrCode}):null),k.createElement(D,{alignItems:"center",borderRadius:"10",display:"flex",flexDirection:"row",gap:"8",height:"34",justifyContent:"space-between",marginBottom:"12",paddingY:"8"},k.createElement(ln,{label:s.t("get_mobile.continue.label"),onClick:()=>e(r!=null&&r.instructions?"INSTRUCTIONS_MOBILE":"CONNECT")})))}var bo={connect:()=>k.createElement(oD,null),create:()=>k.createElement(sD,null),install:e=>k.createElement(Rt,{background:e.iconBackground,borderColor:"generalBorder",borderRadius:"10",height:"48",src:e.iconUrl,width:"48"}),refresh:()=>k.createElement(aD,null),scan:()=>k.createElement(cD,null)};function wD({connectWallet:e,wallet:t}){var r,s,a,c;const{i18n:n}=P.useContext(Et);return k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",width:"full"},k.createElement(D,{display:"flex",flexDirection:"column",gap:"28",height:"full",justifyContent:"center",paddingY:"32",style:{maxWidth:320}},(s=(r=t==null?void 0:t.qrCode)==null?void 0:r.instructions)==null?void 0:s.steps.map((l,d)=>{var f;return k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16",key:d},k.createElement(D,{borderRadius:"10",height:"48",minWidth:"48",overflow:"hidden",position:"relative",width:"48"},(f=bo[l.step])==null?void 0:f.call(bo,t)),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},n.t(l.title,void 0,{rawKeyIfTranslationMissing:!0})),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},n.t(l.description,void 0,{rawKeyIfTranslationMissing:!0}))))})),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",marginBottom:"16"},k.createElement(ln,{label:n.t("get_instructions.mobile.connect.label"),onClick:()=>e(t)}),k.createElement(D,{as:"a",className:wt({active:"shrink",hover:"grow"}),display:"block",href:(c=(a=t==null?void 0:t.qrCode)==null?void 0:a.instructions)==null?void 0:c.learnMoreUrl,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},k.createElement(xe,{color:"accentColor",size:"14",weight:"bold"},n.t("get_instructions.mobile.learn_more.label")))))}function bD({wallet:e}){var n,r,s,a;const{i18n:t}=P.useContext(Et);return k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",width:"full"},k.createElement(D,{display:"flex",flexDirection:"column",gap:"28",height:"full",justifyContent:"center",paddingY:"32",style:{maxWidth:320}},(r=(n=e==null?void 0:e.extension)==null?void 0:n.instructions)==null?void 0:r.steps.map((c,l)=>{var d;return k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16",key:l},k.createElement(D,{borderRadius:"10",height:"48",minWidth:"48",overflow:"hidden",position:"relative",width:"48"},(d=bo[c.step])==null?void 0:d.call(bo,e)),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},t.t(c.title,void 0,{rawKeyIfTranslationMissing:!0})),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},t.t(c.description,void 0,{rawKeyIfTranslationMissing:!0}))))})),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",marginBottom:"16"},k.createElement(ln,{label:t.t("get_instructions.extension.refresh.label"),onClick:window.location.reload.bind(window.location)}),k.createElement(D,{as:"a",className:wt({active:"shrink",hover:"grow"}),display:"block",href:(a=(s=e==null?void 0:e.extension)==null?void 0:s.instructions)==null?void 0:a.learnMoreUrl,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},k.createElement(xe,{color:"accentColor",size:"14",weight:"bold"},t.t("get_instructions.extension.learn_more.label")))))}function xD({connectWallet:e,wallet:t}){var r,s,a,c;const{i18n:n}=P.useContext(Et);return k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",width:"full"},k.createElement(D,{display:"flex",flexDirection:"column",gap:"28",height:"full",justifyContent:"center",paddingY:"32",style:{maxWidth:320}},(s=(r=t==null?void 0:t.desktop)==null?void 0:r.instructions)==null?void 0:s.steps.map((l,d)=>{var f;return k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"16",key:d},k.createElement(D,{borderRadius:"10",height:"48",minWidth:"48",overflow:"hidden",position:"relative",width:"48"},(f=bo[l.step])==null?void 0:f.call(bo,t)),k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},k.createElement(xe,{color:"modalText",size:"14",weight:"bold"},n.t(l.title,void 0,{rawKeyIfTranslationMissing:!0})),k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},n.t(l.description,void 0,{rawKeyIfTranslationMissing:!0}))))})),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"12",justifyContent:"center",marginBottom:"16"},k.createElement(ln,{label:n.t("get_instructions.desktop.connect.label"),onClick:()=>e(t)}),k.createElement(D,{as:"a",className:wt({active:"shrink",hover:"grow"}),display:"block",href:(c=(a=t==null?void 0:t.desktop)==null?void 0:a.instructions)==null?void 0:c.learnMoreUrl,paddingX:"12",paddingY:"4",rel:"noreferrer",style:{willChange:"transform"},target:"_blank",transition:"default"},k.createElement(xe,{color:"accentColor",size:"14",weight:"bold"},n.t("get_instructions.desktop.learn_more.label")))))}function CD({onClose:e}){const t="rk_connect_title",[n,r]=P.useState(),[s,a]=P.useState(),[c,l]=P.useState(),d=!!(s!=null&&s.qrCode)&&c,[f,h]=P.useState(!1),m=P.useContext(Kf)===cu.COMPACT,{disclaimer:y}=P.useContext(iu),{i18n:v}=P.useContext(Et),w=Pg(),C=P.useRef(!1),{connector:A}=P.useContext(au),S=Pl(!A).filter(ne=>ne.ready||!!ne.extensionDownloadUrl).sort((ne,oe)=>ne.groupIndex-oe.groupIndex),j=Pl(),N=QM(S,ne=>ne.groupName),T=["Recommended","Other","Popular","More","Others","Installed"];P.useEffect(()=>{A&&!C.current&&(Q("CONNECT"),W(A),C.current=!0)},[A]);const B=ne=>{var oe,fe;h(!1),ne.ready&&((fe=(oe=ne==null?void 0:ne.connect)==null?void 0:oe.call(ne))==null||fe.catch(()=>{h(!0)}))},O=async ne=>{const oe=S.find(fe=>ne.id===fe.id);oe!=null&&oe.getDesktopUri&&setTimeout(async()=>{var ge;const fe=await((ge=oe==null?void 0:oe.getDesktopUri)==null?void 0:ge.call(oe));fe&&window.open(fe,w?"_blank":"_self")},0)},R=async ne=>{var ge;const oe=S.find(Ie=>ne.id===Ie.id),fe=await((ge=oe==null?void 0:oe.getQrCodeUri)==null?void 0:ge.call(oe));l(fe),setTimeout(()=>{a(oe),Q("CONNECT")},fe?0:50)},W=async ne=>{eD(ne.id),ne.ready&&(R(ne),O(ne)),B(ne),r(ne.id),ne.ready||(a(ne),Q(ne!=null&&ne.extensionDownloadUrl?"DOWNLOAD_OPTIONS":"CONNECT"))},H=ne=>{var Be;const oe=j.find(Le=>ne===Le.id),fe=(Be=oe==null?void 0:oe.downloadUrls)==null?void 0:Be.qrCode,ge=!!(oe!=null&&oe.desktopDownloadUrl),Ie=!!(oe!=null&&oe.extensionDownloadUrl);a(oe),Q(fe&&(Ie||ge)?"DOWNLOAD_OPTIONS":fe?"DOWNLOAD":ge?"INSTRUCTIONS_DESKTOP":"INSTRUCTIONS_EXTENSION")},K=()=>{r(void 0),a(void 0),l(void 0)},Q=(ne,oe=!1)=>{oe&&ne==="GET"&&ae==="GET"?K():!oe&&ne==="GET"?q("GET"):!oe&&ne==="CONNECT"&&q("CONNECT"),te(ne)},[ae,q]=P.useState("NONE"),[ee,te]=P.useState("NONE");let U=null,Y=null,Z=null,F;P.useEffect(()=>{h(!1)},[ee,s]);const pe=!!(!!(s!=null&&s.extensionDownloadUrl)&&(s!=null&&s.mobileDownloadUrl));switch(ee){case"NONE":U=k.createElement(p2,{getWallet:()=>Q("GET")});break;case"LEARN_COMPACT":U=k.createElement(p2,{compactModeEnabled:m,getWallet:()=>Q("GET")}),Y=v.t("intro.title"),Z="NONE";break;case"GET":U=k.createElement(mD,{getWalletDownload:H,compactModeEnabled:m}),Y=v.t("get.title"),Z=m?"LEARN_COMPACT":"NONE";break;case"CONNECT":U=s&&k.createElement(gD,{changeWalletStep:Q,compactModeEnabled:m,connectionError:f,onClose:e,qrCodeUri:c,reconnect:B,wallet:s}),Y=d&&(s.name==="WalletConnect"?v.t("connect_scan.fallback_title"):v.t("connect_scan.title",{wallet:s.name})),Z=m?A?null:"NONE":null,F=m?A?()=>{}:K:()=>{};break;case"DOWNLOAD_OPTIONS":U=s&&k.createElement(yD,{changeWalletStep:Q,wallet:s}),Y=s&&v.t("get_options.short_title",{wallet:s.name}),Z=A?"CONNECT":m?"NONE":ae;break;case"DOWNLOAD":U=s&&k.createElement(vD,{changeWalletStep:Q,wallet:s}),Y=s&&v.t("get_mobile.title",{wallet:s.name}),Z=pe?"DOWNLOAD_OPTIONS":ae;break;case"INSTRUCTIONS_MOBILE":U=s&&k.createElement(wD,{connectWallet:W,wallet:s}),Y=s&&v.t("get_options.title",{wallet:m&&s.shortName||s.name}),Z="DOWNLOAD";break;case"INSTRUCTIONS_EXTENSION":U=s&&k.createElement(bD,{wallet:s}),Y=s&&v.t("get_options.title",{wallet:m&&s.shortName||s.name}),Z="DOWNLOAD_OPTIONS";break;case"INSTRUCTIONS_DESKTOP":U=s&&k.createElement(xD,{connectWallet:W,wallet:s}),Y=s&&v.t("get_options.title",{wallet:m&&s.shortName||s.name}),Z="DOWNLOAD_OPTIONS";break}return k.createElement(D,{display:"flex",flexDirection:"row",style:{maxHeight:m?468:504}},(m?ee==="NONE":!0)&&k.createElement(D,{className:m?fD:dD,display:"flex",flexDirection:"column",marginTop:"16"},k.createElement(D,{display:"flex",justifyContent:"space-between"},m&&y&&k.createElement(D,{marginLeft:"16",width:"28"},k.createElement(KM,{onClick:()=>Q("LEARN_COMPACT")})),m&&!y&&k.createElement(D,{marginLeft:"16",width:"28"}),k.createElement(D,{marginLeft:m?"0":"6",paddingBottom:"8",paddingTop:"2",paddingX:"18"},k.createElement(xe,{as:"h1",color:"modalText",id:t,size:"18",weight:"heavy",testId:"connect-header-label"},v.t("connect.title"))),m&&k.createElement(D,{marginRight:"16"},k.createElement(yi,{onClose:e}))),k.createElement(D,{className:uD,paddingBottom:"18"},Object.entries(N).map(([ne,oe],fe)=>oe.length>0&&k.createElement(P.Fragment,{key:fe},ne?k.createElement(D,{marginBottom:"8",marginTop:"16",marginX:"6"},k.createElement(xe,{color:ne==="Installed"?"accentColor":"modalTextSecondary",size:"14",weight:"bold"},T.includes(ne)?v.t(`connector_group.${ne.toLowerCase()}`):ne)):null,k.createElement(D,{display:"flex",flexDirection:"column",gap:"4"},oe.map(ge=>k.createElement(S8,{currentlySelected:ge.id===n,iconBackground:ge.iconBackground,iconUrl:ge.iconUrl,key:ge.id,name:ge.name,onClick:()=>W(ge),ready:ge.ready,recent:ge.recent,testId:`wallet-option-${ge.id}`,isRainbowKitConnector:ge.isRainbowKitConnector})))))),m&&k.createElement(k.Fragment,null,k.createElement(D,{background:"generalBorder",height:"1",marginTop:"-1"}),y?k.createElement(D,{paddingX:"24",paddingY:"16",textAlign:"center"},k.createElement(y,{Link:Rg,Text:Mg})):k.createElement(D,{alignItems:"center",display:"flex",justifyContent:"space-between",paddingX:"24",paddingY:"16"},k.createElement(D,{paddingY:"4"},k.createElement(xe,{color:"modalTextSecondary",size:"14",weight:"medium"},v.t("connect.new_to_ethereum.description"))),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"row",gap:"4",justifyContent:"center"},k.createElement(D,{className:wt({active:"shrink",hover:"grow"}),cursor:"pointer",onClick:()=>Q("LEARN_COMPACT"),paddingY:"4",style:{willChange:"transform"},transition:"default"},k.createElement(xe,{color:"accentColor",size:"14",weight:"bold"},v.t("connect.new_to_ethereum.learn_more.label"))))))),(m?ee!=="NONE":!0)&&k.createElement(k.Fragment,null,!m&&k.createElement(D,{background:"generalBorder",minWidth:"1",width:"1"}),k.createElement(D,{display:"flex",flexDirection:"column",margin:"16",style:{flexGrow:1}},k.createElement(D,{alignItems:"center",display:"flex",justifyContent:"space-between",marginBottom:"12"},k.createElement(D,{width:"28"},Z&&k.createElement(D,{as:"button",className:wt({active:"shrinkSm",hover:"growLg"}),color:"accentColor",onClick:()=>{Z&&Q(Z,!0),F==null||F()},paddingX:"8",paddingY:"4",style:{boxSizing:"content-box",height:17,willChange:"transform"},transition:"default",type:"button"},k.createElement(A8,null))),k.createElement(D,{display:"flex",justifyContent:"center",style:{flexGrow:1}},Y&&k.createElement(xe,{color:"modalText",size:"18",textAlign:"center",weight:"heavy"},Y)),k.createElement(yi,{onClose:e})),k.createElement(D,{display:"flex",flexDirection:"column",style:{minHeight:m?396:432}},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"6",height:"full",justifyContent:"center",marginX:"8"},U)))))}var ED="_1am14412",AD="_1am14410",kD="_1am14413",SD=({wallet:e})=>k.createElement("svg",{className:kD,viewBox:"0 0 86 86",width:"86",height:"86"},k.createElement("title",null,"Loading"),k.createElement("rect",{x:"3",y:"3",width:80,height:80,rx:20,ry:20,strokeDasharray:`${160/3} ${320/3}`,strokeDashoffset:160,className:ED,style:{stroke:(e==null?void 0:e.iconAccent)||"#0D3887"}}));function M8({onClose:e,wallet:t,connecting:n}){const{connect:r,iconBackground:s,iconUrl:a,id:c,name:l,getMobileUri:d,ready:f,shortName:h,showWalletConnectModal:p}=t,m=k8(a),y=P.useRef(!1),{i18n:v}=P.useContext(Et),w=P.useCallback(async()=>{if(c!=="walletConnect"&&(async()=>{const A=await(d==null?void 0:d());if(A)if(A&&fM({mobileUri:A,name:l}),A.startsWith("http")){const I=document.createElement("a");I.href=A,I.target="_blank",I.rel="noreferrer noopener",I.click()}else window.location.href=A})(),p){p(),e==null||e();return}try{await(r==null?void 0:r())}catch{}},[r,d,p,e,l,c]);return P.useEffect(()=>{n&&!y.current&&(w(),y.current=!0)},[n,w]),k.createElement(D,{as:"button",color:f?"modalText":"modalTextSecondary",disabled:!f,fontFamily:"body",key:c,onClick:w,ref:m,style:{overflow:"visible",textAlign:"center"},testId:`wallet-option-${c}`,type:"button",width:"full"},k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",justifyContent:"center"},k.createElement(D,{display:"flex",alignItems:"center",justifyContent:"center",paddingBottom:"8",paddingTop:"10",position:"relative"},n?k.createElement(SD,{wallet:t}):null,k.createElement(Rt,{background:s,borderRadius:"13",boxShadow:"walletLogo",height:"60",src:a,width:"60"})),n?null:k.createElement(D,{display:"flex",flexDirection:"column",textAlign:"center"},k.createElement(xe,{as:"h2",color:t.ready?"modalText":"modalTextSecondary",size:"13",weight:"medium"},k.createElement(D,{as:"span",position:"relative"},h??l,!t.ready&&" (unsupported)")),t.recent&&k.createElement(xe,{color:"accentColor",size:"12",weight:"medium"},v.t("connect.recent")))))}function jD({onClose:e}){var y;const t="rk_connect_title",n=Pl().filter(v=>v.isRainbowKitConnector),{disclaimer:r,learnMoreUrl:s}=P.useContext(iu);let a=null,c=null,l=!1,d=null;const[f,h]=P.useState("CONNECT"),{i18n:p}=P.useContext(Et),m=su();switch(f){case"CONNECT":{a=p.t("connect.title"),l=!0,c=k.createElement(D,null,k.createElement(D,{background:"profileForeground",className:AD,display:"flex",paddingBottom:"20",paddingTop:"6",paddingX:"20",style:{gap:"calc((100% - 40px - 240px + 47px) / 4)"}},n.filter(v=>v.ready).map(v=>k.createElement(D,{key:v.id,width:"60"},k.createElement(M8,{onClose:e,wallet:v})))),k.createElement(D,{background:"generalBorder",height:"1",marginBottom:"32",marginTop:"-1"}),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"32",paddingX:"32",style:{textAlign:"center"}},k.createElement(D,{display:"flex",flexDirection:"column",gap:"8",textAlign:"center"},k.createElement(xe,{color:"modalText",size:"16",weight:"bold"},p.t("intro.title")),k.createElement(xe,{color:"modalTextSecondary",size:"16"},p.t("intro.description")))),k.createElement(D,{paddingTop:"32",paddingX:"20"},k.createElement(D,{display:"flex",gap:"14",justifyContent:"center"},k.createElement(ln,{label:p.t("intro.get.label"),onClick:()=>h("GET"),size:"large",type:"secondary"}),k.createElement(ln,{href:s,label:p.t("intro.learn_more.label"),size:"large",type:"secondary"}))),r&&k.createElement(D,{marginTop:"28",marginX:"32",textAlign:"center"},k.createElement(r,{Link:Rg,Text:Mg})));break}case"GET":{a=p.t("get.title"),d="CONNECT";const v=(y=n==null?void 0:n.filter(w=>{var C,A,I;return((C=w.downloadUrls)==null?void 0:C.ios)||((A=w.downloadUrls)==null?void 0:A.android)||((I=w.downloadUrls)==null?void 0:I.mobile)}))==null?void 0:y.splice(0,3);c=k.createElement(D,null,k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",height:"full",marginBottom:"36",marginTop:"5",paddingTop:"12",width:"full"},v.map((w,C)=>{const{downloadUrls:A,iconBackground:I,iconUrl:S,name:j}=w;return!(A!=null&&A.ios)&&!(A!=null&&A.android)&&!(A!=null&&A.mobile)?null:k.createElement(D,{display:"flex",gap:"16",key:w.id,paddingX:"20",width:"full"},k.createElement(D,{style:{minHeight:48,minWidth:48}},k.createElement(Rt,{background:I,borderColor:"generalBorder",borderRadius:"10",height:"48",src:S,width:"48"})),k.createElement(D,{display:"flex",flexDirection:"column",width:"full"},k.createElement(D,{alignItems:"center",display:"flex",height:"48"},k.createElement(D,{width:"full"},k.createElement(xe,{color:"modalText",size:"18",weight:"bold"},j)),k.createElement(ln,{href:(m?A==null?void 0:A.ios:A==null?void 0:A.android)||(A==null?void 0:A.mobile),label:p.t("get.action.label"),size:"small",type:"secondary"})),C<v.length-1&&k.createElement(D,{background:"generalBorderDim",height:"1",marginY:"10",width:"full"})))})),k.createElement(D,{style:{marginBottom:"42px"}}),k.createElement(D,{alignItems:"center",display:"flex",flexDirection:"column",gap:"36",paddingX:"36",style:{textAlign:"center"}},k.createElement(D,{display:"flex",flexDirection:"column",gap:"12",textAlign:"center"},k.createElement(xe,{color:"modalText",size:"16",weight:"bold"},p.t("get.looking_for.title")),k.createElement(xe,{color:"modalTextSecondary",size:"16"},p.t("get.looking_for.mobile.description")))));break}}return k.createElement(D,{display:"flex",flexDirection:"column",paddingBottom:"36"},k.createElement(D,{background:l?"profileForeground":"modalBackground",display:"flex",flexDirection:"column",paddingBottom:"4",paddingTop:"14"},k.createElement(D,{display:"flex",justifyContent:"center",paddingBottom:"6",paddingX:"20",position:"relative"},d&&k.createElement(D,{display:"flex",position:"absolute",style:{left:0,marginBottom:-20,marginTop:-20}},k.createElement(D,{alignItems:"center",as:"button",className:wt({active:"shrinkSm",hover:"growLg"}),color:"accentColor",display:"flex",marginLeft:"4",marginTop:"20",onClick:()=>h(d),padding:"16",style:{height:17,willChange:"transform"},transition:"default",type:"button"},k.createElement(A8,null))),k.createElement(D,{marginTop:"4",textAlign:"center",width:"full"},k.createElement(xe,{as:"h1",color:"modalText",id:t,size:"20",weight:"bold"},a)),k.createElement(D,{alignItems:"center",display:"flex",height:"32",paddingRight:"14",position:"absolute",right:"0"},k.createElement(D,{style:{marginBottom:-20,marginTop:-20}},k.createElement(yi,{onClose:e}))))),k.createElement(D,{display:"flex",flexDirection:"column"},c))}var ID=({onClose:e})=>{const{connector:t}=P.useContext(au),{i18n:n}=P.useContext(Et),r=(t==null?void 0:t.name)||"";return k.createElement(D,null,k.createElement(D,{display:"flex",paddingBottom:"32",justifyContent:"center",alignItems:"center",background:"profileForeground",flexDirection:"column"},k.createElement(D,{width:"full",display:"flex",justifyContent:"flex-end",marginTop:"18",marginRight:"24"},k.createElement(yi,{onClose:e})),k.createElement(D,{width:"60"},k.createElement(M8,{onClose:e,wallet:t,connecting:!0})),k.createElement(D,{marginTop:"20"},k.createElement(xe,{textAlign:"center",color:"modalText",size:"18",weight:"semibold"},n.t("connect.status.connect_mobile",{wallet:r}))),k.createElement(D,{maxWidth:"full",marginTop:"8"},k.createElement(xe,{textAlign:"center",color:"modalText",size:"16",weight:"medium"},n.t("connect.status.confirm_mobile",{wallet:r})))))};function ND({onClose:e}){const{connector:t}=P.useContext(au);return Ct()?t?k.createElement(ID,{onClose:e}):k.createElement(jD,{onClose:e}):k.createElement(CD,{onClose:e})}function PD({onClose:e,open:t}){const n="rk_connect_title",r=Sg(),{disconnect:s}=ou(),{isConnecting:a}=it(),c=k.useCallback(()=>{e(),s()},[e,s]),l=k.useCallback(()=>{a&&s(),e()},[e,s,a]);return r==="disconnected"?k.createElement(mf,{onClose:l,open:t,titleId:n},k.createElement(gf,{bottomSheetOnMobile:!0,padding:"0",wide:!0},k.createElement(ND,{onClose:l}))):r==="unauthenticated"?k.createElement(mf,{onClose:c,open:t,titleId:n},k.createElement(gf,{bottomSheetOnMobile:!0,padding:"0"},k.createElement(uM,{onClose:c,onCloseModal:e}))):null}function Tp(){const[e,t]=P.useState(!1);return{closeModal:P.useCallback(()=>t(!1),[]),isModalOpen:e,openModal:P.useCallback(()=>t(!0),[])}}var Ka=P.createContext({accountModalOpen:!1,chainModalOpen:!1,connectModalOpen:!1,isWalletConnectModalOpen:!1,setIsWalletConnectModalOpen:()=>{}});function BD({children:e}){const{closeModal:t,isModalOpen:n,openModal:r}=Tp(),{closeModal:s,isModalOpen:a,openModal:c}=Tp(),{closeModal:l,isModalOpen:d,openModal:f}=Tp(),[h,p]=P.useState(!1),m=Sg(),{chainId:y}=it(),{chains:v}=ut(),w=v.some(I=>I.id===y),C=P.useCallback(({keepConnectModalOpen:I=!1}={})=>{I||t(),s(),l()},[t,s,l]),A=Qf()==="unauthenticated";return U3({onConnect:()=>C({keepConnectModalOpen:A}),onDisconnect:()=>C()}),P.useEffect(()=>{A&&C()},[A,C]),k.createElement(Ka.Provider,{value:P.useMemo(()=>({accountModalOpen:a,chainModalOpen:d,connectModalOpen:n,isWalletConnectModalOpen:h,openAccountModal:w&&m==="connected"?c:void 0,openChainModal:m==="connected"?f:void 0,openConnectModal:m==="disconnected"||m==="unauthenticated"?r:void 0,setIsWalletConnectModalOpen:p}),[m,a,d,n,c,f,r,w,h])},e,k.createElement(PD,{onClose:t,open:n}),k.createElement(LM,{onClose:s,open:a}),k.createElement(VM,{onClose:l,open:d}))}function _D(){const{accountModalOpen:e,chainModalOpen:t,connectModalOpen:n}=P.useContext(Ka);return{accountModalOpen:e,chainModalOpen:t,connectModalOpen:n}}function TD(){const{accountModalOpen:e,openAccountModal:t}=P.useContext(Ka);return{accountModalOpen:e,openAccountModal:t}}function D8(){const{chainModalOpen:e,openChainModal:t}=P.useContext(Ka);return{chainModalOpen:e,openChainModal:t}}function F8(){const{isWalletConnectModalOpen:e,setIsWalletConnectModalOpen:t}=P.useContext(Ka);return{isWalletConnectModalOpen:e,setIsWalletConnectModalOpen:t}}function OD(){const{connectModalOpen:e,openConnectModal:t}=P.useContext(Ka),{isWalletConnectModalOpen:n}=F8();return{connectModalOpen:e||n,openConnectModal:t}}var Op=()=>{};function Dg({children:e}){const t=gR(),{address:n}=it(),{chainId:r}=it(),{chains:s}=ut(),a=s.some(K=>K.id===r),c=pR(),l=Qf()??void 0,d=r?c[r]:void 0,f=(d==null?void 0:d.name)??void 0,h=(d==null?void 0:d.iconUrl)??void 0,p=(d==null?void 0:d.iconBackground)??void 0,m=Gf(h),y=P.useContext(Ng),v=i8().some(({status:K})=>K==="pending")&&y,{showBalance:w}=e8(),A=typeof w=="boolean"?w:w?qC(w)[Ct()?"smallScreen":"largeScreen"]:!0,{balance:I,ensAvatar:S,ensName:j}=n8({address:n,includeBalance:A}),N=I?`${w8(Number.parseFloat(I.formatted))} ${I.symbol}`:void 0,{openConnectModal:T}=OD(),{openChainModal:B}=D8(),{openAccountModal:O}=TD(),{accountModalOpen:R,chainModalOpen:W,connectModalOpen:H}=_D();return k.createElement(k.Fragment,null,e({account:n?{address:n,balanceDecimals:I==null?void 0:I.decimals,balanceFormatted:I==null?void 0:I.formatted,balanceSymbol:I==null?void 0:I.symbol,displayBalance:N,displayName:j?x8(j):b8(n),ensAvatar:S??void 0,ensName:j??void 0,hasPendingTransactions:v}:void 0,accountModalOpen:R,authenticationStatus:l,chain:r?{hasIcon:!!h,iconBackground:p,iconUrl:m,id:r,name:f,unsupported:!a}:void 0,chainModalOpen:W,connectModalOpen:H,mounted:t(),openAccountModal:O??Op,openChainModal:B??Op,openConnectModal:T??Op}))}Dg.displayName="ConnectButton.Custom";var Hc={accountStatus:"full",chainStatus:{largeScreen:"full",smallScreen:"icon"},label:"Connect Wallet",showBalance:{largeScreen:!0,smallScreen:!1}};function Fg({accountStatus:e=Hc.accountStatus,chainStatus:t=Hc.chainStatus,label:n=Hc.label,showBalance:r=Hc.showBalance}){const s=Ei(),a=Sg(),{setShowBalance:c}=e8(),[l,d]=P.useState(!1),{i18n:f}=P.useContext(Et);return P.useEffect(()=>{c(r),l||d(!0)},[r,c]),l?k.createElement(Dg,null,({account:h,chain:p,mounted:m,openAccountModal:y,openChainModal:v,openConnectModal:w})=>{const C=m&&a!=="loading",A=(p==null?void 0:p.unsupported)??!1;return k.createElement(D,{display:"flex",gap:"12",...!C&&{"aria-hidden":!0,style:{opacity:0,pointerEvents:"none",userSelect:"none"}}},C&&h&&a==="connected"?k.createElement(k.Fragment,null,p&&(s.length>1||A)&&k.createElement(D,{alignItems:"center","aria-label":"Chain Selector",as:"button",background:A?"connectButtonBackgroundError":"connectButtonBackground",borderRadius:"connectButton",boxShadow:"connectButton",className:wt({active:"shrink",hover:"grow"}),color:A?"connectButtonTextError":"connectButtonText",display:ea(t,I=>I==="none"?"none":"flex"),fontFamily:"body",fontWeight:"bold",gap:"6",key:A?"unsupported":"supported",onClick:v,paddingX:"10",paddingY:"8",testId:A?"wrong-network-button":"chain-button",transition:"default",type:"button"},A?k.createElement(D,{alignItems:"center",display:"flex",height:"24",paddingX:"4"},f.t("connect_wallet.wrong_network.label")):k.createElement(D,{alignItems:"center",display:"flex",gap:"6"},p.hasIcon?k.createElement(D,{display:ea(t,I=>I==="full"||I==="icon"?"block":"none"),height:"24",width:"24"},k.createElement(Rt,{alt:p.name??"Chain icon",background:p.iconBackground,borderRadius:"full",height:"24",src:p.iconUrl,width:"24"})):null,k.createElement(D,{display:ea(t,I=>I==="icon"&&!p.iconUrl||I==="full"||I==="name"?"block":"none")},p.name??p.id)),k.createElement(z6,null)),!A&&k.createElement(D,{alignItems:"center",as:"button",background:"connectButtonBackground",borderRadius:"connectButton",boxShadow:"connectButton",className:wt({active:"shrink",hover:"grow"}),color:"connectButtonText",display:"flex",fontFamily:"body",fontWeight:"bold",onClick:y,testId:"account-button",transition:"default",type:"button"},h.displayBalance&&k.createElement(D,{display:ea(r,I=>I?"block":"none"),padding:"8",paddingLeft:"12"},h.displayBalance),k.createElement(D,{background:qC(r)[Ct()?"smallScreen":"largeScreen"]?"connectButtonInnerBackground":"connectButtonBackground",borderColor:"connectButtonBackground",borderRadius:"connectButton",borderStyle:"solid",borderWidth:"2",color:"connectButtonText",fontFamily:"body",fontWeight:"bold",paddingX:"8",paddingY:"6",transition:"default"},k.createElement(D,{alignItems:"center",display:"flex",gap:"6",height:"24"},k.createElement(D,{display:ea(e,I=>I==="full"||I==="avatar"?"block":"none")},k.createElement(JC,{address:h.address,imageUrl:h.ensAvatar,loading:h.hasPendingTransactions,size:24})),k.createElement(D,{alignItems:"center",display:"flex",gap:"6"},k.createElement(D,{display:ea(e,I=>I==="full"||I==="address"?"block":"none")},h.displayName),k.createElement(z6,null)))))):k.createElement(D,{as:"button",background:"accentColor",borderRadius:"connectButton",boxShadow:"connectButton",className:wt({active:"shrink",hover:"grow"}),color:"accentColorForeground",fontFamily:"body",fontWeight:"bold",height:"40",key:"connect",onClick:w,paddingX:"14",testId:"connect-button",transition:"default",type:"button"},m&&n==="Connect Wallet"?f.t("connect_wallet.label"):n))}):k.createElement(k.Fragment,null)}Fg.__defaultProps=Hc;Fg.Custom=Dg;var L8=({appName:e,appDescription:t,appUrl:n,appIcon:r})=>({name:e,description:t??e,url:n??(typeof window<"u"?window.location.origin:""),icons:[...r?[r]:[]]});function RD(e){return Object.fromEntries(Object.entries(e).filter(([t,n])=>n!==void 0))}function MD(e,t){const n=[];for(const r of e)n.some(s=>s[t]===r[t])||n.push(r);return n}var DD=(e,{projectId:t,walletConnectParameters:n,appName:r,appDescription:s,appUrl:a,appIcon:c})=>{if(!e.length)throw new Error("No wallet list was provided");for(const{wallets:y,groupName:v}of e)if(!y.length)throw new Error(`No wallets provided for group: ${v}`);let l=-1;const d=[],f=[],h=[],p=L8({appName:r,appDescription:s,appUrl:a,appIcon:c});for(const[y,{groupName:v,wallets:w}]of e.entries())for(const C of w){l++;const A=C({projectId:t,appName:r,appIcon:c,options:{metadata:p,...n},walletConnectParameters:{metadata:p,...n}});if(A!=null&&A.iconAccent&&!nD(A==null?void 0:A.iconAccent))throw new Error(`Property \`iconAccent\` is not a hex value for wallet: ${A.name}`);const I={...A,groupIndex:y+1,groupName:v,index:l};typeof A.hidden=="function"?h.push(I):f.push(I)}const m=MD([...f,...h],"id");for(const{createConnector:y,groupIndex:v,groupName:w,hidden:C,...A}of m){if(typeof C=="function"&&C())continue;const I=N=>({rkDetails:RD({...A,groupIndex:v,groupName:w,isRainbowKitConnector:!0,...N||{}})});A.id==="walletConnect"&&d.push(y(I({isWalletConnectModalConnector:!0,showQrModal:!0})));const j=y(I());d.push(j)}return d},g2=new Map,FD=({projectId:e,walletConnectParameters:t,rkDetailsShowQrModal:n,rkDetailsIsWalletConnectModalConnector:r})=>{let s={telemetryEnabled:!1,...t||{},projectId:e,showQrModal:!1};n&&(s={...s,showQrModal:!0}),"customStoragePrefix"in s||(s={...s,customStoragePrefix:r?"clientOne":"clientTwo"});const a=JSON.stringify(s),c=g2.get(a);if(c)return c;const l=kg(s);return g2.set(a,l),l};function LD({projectId:e,walletDetails:t,walletConnectParameters:n}){return r=>({...FD({projectId:e,walletConnectParameters:n,rkDetailsShowQrModal:t.rkDetails.showQrModal,rkDetailsIsWalletConnectModalConnector:t.rkDetails.isWalletConnectModalConnector})(r),...t})}function Lg({projectId:e,walletConnectParameters:t}){const n="21fef48091f12692cad574a6f7753643";if(!e||e==="")throw new Error("No projectId found. Every dApp must now provide a WalletConnect Cloud projectId to enable WalletConnect v2 https://www.rainbowkit.com/docs/installation#configure");return e==="YOUR_PROJECT_ID"&&(e=n),r=>LD({projectId:e,walletDetails:r,walletConnectParameters:t})}function U8(e){const t=typeof window<"u"?window:void 0;if(typeof t>"u"||typeof t.ethereum>"u")return;const n=t.ethereum.providers;return n?n.find(r=>r[e]):t.ethereum[e]?t.ethereum:void 0}function z8(e){const t=(n,r)=>{const[s,...a]=r.split("."),c=n[s];if(c)return a.length===0?c:t(c,a.join("."))};if(typeof window<"u")return t(window,e)}function UD({flag:e,namespace:t}){return!!(t&&typeof z8(t)<"u"||typeof U8(e)<"u")}function zD({flag:e,namespace:t}){var s;const n=typeof window<"u"?window:void 0;if(typeof n>"u")return;if(t){const a=z8(t);if(a)return a}const r=(s=n.ethereum)==null?void 0:s.providers;{const a=U8(e);if(a)return a}return typeof r<"u"&&r.length>0?r[0]:n.ethereum}function WD(e){return t=>{const n=e?{target:()=>({id:t.rkDetails.id,name:t.rkDetails.name,provider:e})}:{};return r=>({...qf(n)(r),...t})}}function $D({flag:e,namespace:t,target:n}){const r=n||zD({flag:e,namespace:t});return WD(r)}var W8=({appName:e,appIcon:t})=>{const{preference:n,...r}=W8;return{id:"baseAccount",name:"Base Account",shortName:"Base Account",rdns:"app.base.account",iconUrl:async()=>(await de(async()=>{const{default:s}=await import("./baseAccount-44UITRK7-CsjdbWCf.js");return{default:s}},[])).default,iconAccent:"#0000FF",iconBackground:"#0000FF",installed:!0,createConnector:s=>{const a=TO({appName:e,appLogoUrl:t,...r,preference:{telemetry:!1,...n||{}}});return c=>({...a(c),...s})}}};function qD(e){return!(!(e!=null&&e.isMetaMask)||e.isBraveWallet&&!e._events&&!e._state||e.isApexWallet||e.isAvalanche||e.isBackpack||e.isBifrost||e.isBitKeep||e.isBitski||e.isBinance||e.isBlockWallet||e.isCoinbaseWallet||e.isDawn||e.isEnkrypt||e.isExodus||e.isFrame||e.isFrontier||e.isGamestop||e.isHyperPay||e.isImToken||e.isKuCoinWallet||e.isMathWallet||e.isNestWallet||e.isOkxWallet||e.isOKExWallet||e.isOneInchIOSWallet||e.isOneInchAndroidWallet||e.isOpera||e.isPhantom||e.isZilPay||e.isPortal||e.isxPortal||e.isRabby||e.isRainbow||e.isStatus||e.isTalisman||e.isTally||e.isTokenPocket||e.isTokenary||e.isTrust||e.isTrustWallet||e.isCTRL||e.isZeal||e.isCoin98||e.isMEWwallet||e.isSafeheron||e.isSafePal||e.isWigwam||e.isZerion||e.__seif)}var $8=({projectId:e,walletConnectParameters:t})=>{const{...n}=$8,r=typeof window<"u"?qD(window.ethereum):!1,s=!r&&!Ct(),a=r||Ct();return{id:"metaMask",name:"MetaMask",rdns:"io.metamask",iconUrl:async()=>(await de(async()=>{const{default:c}=await import("./metaMaskWallet-SITXT2FV-BlemcphV.js");return{default:c}},[])).default,iconAccent:"#f6851a",iconBackground:"#fff",installed:r||void 0,downloadUrls:{android:"https://play.google.com/store/apps/details?id=io.metamask",ios:"https://apps.apple.com/us/app/metamask/id1438144202",mobile:"https://metamask.io/download",qrCode:"https://metamask.io/download",chrome:"https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn",edge:"https://microsoftedge.microsoft.com/addons/detail/metamask/ejbalbakoplchlghecdalmeeeajnimhm",firefox:"https://addons.mozilla.org/firefox/addon/ether-metamask",opera:"https://addons.opera.com/extensions/details/metamask-10",browserExtension:"https://metamask.io/download"},mobile:{getUri:a?c=>c:void 0},qrCode:s?{getUri:c=>`https://metamask.app.link/wc?uri=${encodeURIComponent(c)}`,instructions:{learnMoreUrl:"https://metamask.io/faqs/",steps:[{description:"wallet_connectors.metamask.qr_code.step1.description",step:"install",title:"wallet_connectors.metamask.qr_code.step1.title"},{description:"wallet_connectors.metamask.qr_code.step2.description",step:"create",title:"wallet_connectors.metamask.qr_code.step2.title"},{description:"wallet_connectors.metamask.qr_code.step3.description",step:"refresh",title:"wallet_connectors.metamask.qr_code.step3.title"}]}}:void 0,extension:{instructions:{learnMoreUrl:"https://metamask.io/faqs/",steps:[{description:"wallet_connectors.metamask.extension.step1.description",step:"install",title:"wallet_connectors.metamask.extension.step1.title"},{description:"wallet_connectors.metamask.extension.step2.description",step:"create",title:"wallet_connectors.metamask.extension.step2.title"},{description:"wallet_connectors.metamask.extension.step3.description",step:"refresh",title:"wallet_connectors.metamask.extension.step3.title"}]}},createConnector:s?Lg({projectId:e,walletConnectParameters:t}):(c=>l=>{var f,h,p;const d=Eg({dappMetadata:{connector:"rainbowkit",name:(f=t==null?void 0:t.metadata)==null?void 0:f.name,iconUrl:(h=t==null?void 0:t.metadata)==null?void 0:h.icons[0],url:(p=t==null?void 0:t.metadata)==null?void 0:p.url},headless:!0,checkInstallationImmediately:!1,enableAnalytics:!1,...n})(l);return{...d,...c,getChainId:async()=>{var m;try{return await d.getChainId()}catch{return((m=l.chains[0])==null?void 0:m.id)??1}}}})}},HD=({projectId:e,walletConnectParameters:t})=>{const n=UD({flag:"isRainbow"}),r=!n,s=a=>VC()?a:su()?`rainbow://wc?uri=${encodeURIComponent(a)}&connector=rainbowkit`:`https://rnbwapp.com/wc?uri=${encodeURIComponent(a)}&connector=rainbowkit`;return{id:"rainbow",name:"Rainbow",rdns:"me.rainbow",iconUrl:async()=>(await de(async()=>{const{default:a}=await import("./rainbowWallet-O26YNBMX-DUhYus-9.js");return{default:a}},[])).default,iconBackground:"#0c2f78",installed:r?void 0:n,downloadUrls:{android:"https://play.google.com/store/apps/details?id=me.rainbow&referrer=utm_source%3Drainbowkit&utm_source=rainbowkit",ios:"https://apps.apple.com/app/apple-store/id1457119021?pt=119997837&ct=rainbowkit&mt=8",mobile:"https://rainbow.download?utm_source=rainbowkit",qrCode:"https://rainbow.download?utm_source=rainbowkit&utm_medium=qrcode",browserExtension:"https://rainbow.me/extension?utm_source=rainbowkit"},mobile:{getUri:r?s:void 0},qrCode:r?{getUri:s,instructions:{learnMoreUrl:"https://learn.rainbow.me/connect-to-a-website-or-app?utm_source=rainbowkit&utm_medium=connector&utm_campaign=learnmore",steps:[{description:"wallet_connectors.rainbow.qr_code.step1.description",step:"install",title:"wallet_connectors.rainbow.qr_code.step1.title"},{description:"wallet_connectors.rainbow.qr_code.step2.description",step:"create",title:"wallet_connectors.rainbow.qr_code.step2.title"},{description:"wallet_connectors.rainbow.qr_code.step3.description",step:"scan",title:"wallet_connectors.rainbow.qr_code.step3.title"}]}}:void 0,createConnector:r?Lg({projectId:e,walletConnectParameters:t}):$D({flag:"isRainbow"})}},VD=()=>({id:"safe",name:"Safe",iconAccent:"#12ff80",iconBackground:"#fff",iconUrl:async()=>(await de(async()=>{const{default:e}=await import("./safeWallet-5MNKTR5Z-D-5imDLD.js");return{default:e}},[])).default,installed:!(typeof window>"u")&&(window==null?void 0:window.parent)!==window,downloadUrls:{},createConnector:e=>t=>({...Ag()(t),...e})}),QD=({projectId:e,options:t})=>({id:"walletConnect",name:"WalletConnect",installed:void 0,iconUrl:async()=>(await de(async()=>{const{default:r}=await import("./walletConnectWallet-YHWKVTDY-D3lyiczV.js");return{default:r}},[])).default,iconBackground:"#3b99fc",qrCode:{getUri:r=>r},createConnector:Lg({projectId:e,walletConnectParameters:t})}),GD=e=>e.reduce((n,r)=>{const s=r.id;return n[s]=Hd(),n},{}),KD=({appName:e,appDescription:t,appUrl:n,appIcon:r,wallets:s,projectId:a,walletConnectParameters:c,...l})=>{const{transports:d,chains:f,...h}=l,p=L8({appName:e,appDescription:t,appUrl:n,appIcon:r}),m=DD(s||[{groupName:"Popular",wallets:[VD,HD,W8,$8,QD]}],{projectId:a,appName:e,appDescription:t,appUrl:n,appIcon:r,walletConnectParameters:{metadata:p,...c}});return lB({connectors:m,chains:f,transports:d||GD(f),...h})};const YD=KD({appName:"AntSeed Payments",projectId:"9a1851410cb5589bc351a6dabf17140e",chains:[Il],transports:{[Il.id]:AP([Hd("https://base-rpc.publicnode.com"),Hd("https://base.gateway.tenderly.co"),Hd("https://base-public.nodies.app")])}}),JD="";let Dd;function ZD(){return Dd!==void 0||(Dd=new URLSearchParams(window.location.search).get("token")),Dd}async function kr(e,t){const n=ZD(),r={"Content-Type":"application/json"};n&&(r.Authorization=`Bearer ${n}`);const s=await fetch(`${JD}${e}`,{headers:r,...t});if(!s.ok){s.status===401&&window.dispatchEvent(new CustomEvent("antseed:session-expired"));const a=await s.json().catch(()=>({}));throw new Error(a.error||`HTTP ${s.status}`)}return s.json()}async function XD(){return kr("/api/balance")}async function eF(){return kr("/api/config")}async function tF(){return kr("/api/rpc-health")}async function nF(){return kr("/api/channels")}async function rF(){return kr("/api/operator")}async function oF(e){return kr("/api/operator/sign",{method:"POST",body:JSON.stringify({operator:e})})}async function sF(){return kr("/api/emissions")}async function iF(e,t=10){const n=new URLSearchParams({address:e,epochs:String(t)});return kr(`/api/emissions/pending?${n.toString()}`)}async function aF(){return kr("/api/emissions/shares")}async function cF(){return kr("/api/emissions/transfers-enabled")}async function lF(){return kr("/api/buyer-usage")}async function uF(e){const t=`${e.replace(/\/$/,"")}/stats`,n=await fetch(t);if(!n.ok)throw new Error(`network-stats returned ${n.status}`);const r=await n.json(),s=Array.isArray(r.peers)?r.peers:[],a=s.filter(h=>h.onChainStats).length;if(r.totals)return{totals:{activePeers:a,totalRequests:r.totals.totalRequests??"0",totalInputTokens:r.totals.totalInputTokens??"0",totalOutputTokens:r.totals.totalOutputTokens??"0",totalSettlements:Number(r.totals.settlementCount??0),...typeof r.totals.sellerCount=="number"?{sellerCount:r.totals.sellerCount}:{}},indexer:r.indexer};let c=0n,l=0n,d=0n,f=0;for(const h of s){const p=h.onChainStats;if(p){try{c+=BigInt(p.totalRequests??"0"),l+=BigInt(p.totalInputTokens??"0"),d+=BigInt(p.totalOutputTokens??"0")}catch{}f+=Number(p.settlementCount??0)}}return{totals:{activePeers:a,totalRequests:c.toString(),totalInputTokens:l.toString(),totalOutputTokens:d.toString(),totalSettlements:f},indexer:r.indexer}}function q8({size:e=18}){return b.jsxs("svg",{width:e,height:e,viewBox:"0 0 28 28",fill:"none","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",children:[b.jsx("path",{d:"M14 9.625C14.9665 9.625 15.75 8.763 15.75 7.7C15.75 6.637 14.9665 5.775 14 5.775C13.0335 5.775 12.25 6.637 12.25 7.7C12.25 8.763 13.0335 9.625 14 9.625Z",fill:"currentColor"}),b.jsx("path",{d:"M14 15.4C15.353 15.4 16.45 14.146 16.45 12.6C16.45 11.054 15.353 9.8 14 9.8C12.647 9.8 11.55 11.054 11.55 12.6C11.55 14.146 12.647 15.4 14 15.4Z",fill:"currentColor"}),b.jsx("path",{d:"M14 23.45C15.74 23.45 17.15 21.57 17.15 19.25C17.15 16.93 15.74 15.05 14 15.05C12.26 15.05 10.85 16.93 10.85 19.25C10.85 21.57 12.26 23.45 14 23.45Z",fill:"currentColor"}),b.jsx("path",{opacity:"0.6",d:"M12.95 5.95L9.8 2.1",stroke:"currentColor",strokeWidth:"0.6",strokeLinecap:"round"}),b.jsx("path",{opacity:"0.6",d:"M15.05 5.95L18.2 2.1",stroke:"currentColor",strokeWidth:"0.6",strokeLinecap:"round"}),b.jsx("circle",{cx:"9.8",cy:"2.1",r:"0.875",fill:"currentColor"}),b.jsx("circle",{cx:"18.2",cy:"2.1",r:"0.875",fill:"currentColor"}),b.jsx("path",{opacity:"0.4",d:"M12.25 11.2L6.125 7.7",stroke:"currentColor",strokeWidth:"0.52",strokeLinecap:"round"}),b.jsx("path",{opacity:"0.4",d:"M15.75 11.2L21.875 7.7",stroke:"currentColor",strokeWidth:"0.52",strokeLinecap:"round"}),b.jsx("circle",{cx:"6.3",cy:"7.7",r:"0.875",fill:"currentColor"}),b.jsx("circle",{cx:"21.7",cy:"7.7",r:"0.875",fill:"currentColor"})]})}function dF(){return b.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",children:[b.jsx("rect",{x:"2.5",y:"2.5",width:"5.5",height:"5.5",rx:"1",strokeLinejoin:"round"}),b.jsx("rect",{x:"10",y:"2.5",width:"5.5",height:"5.5",rx:"1",strokeLinejoin:"round"}),b.jsx("rect",{x:"2.5",y:"10",width:"5.5",height:"5.5",rx:"1",strokeLinejoin:"round"}),b.jsx("rect",{x:"10",y:"10",width:"5.5",height:"5.5",rx:"1",strokeLinejoin:"round"})]})}function fF(){return b.jsx(q8,{size:18})}function hF(){return b.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true",children:[b.jsx("circle",{cx:"9",cy:"9",r:"6.5",stroke:"currentColor",strokeWidth:"1.35"}),b.jsx("path",{d:"M6.25 6.1H9.05C11.15 6.1 12.75 7.45 12.75 9C12.75 10.55 11.15 11.9 9.05 11.9H6.25V6.1Z",stroke:"currentColor",strokeWidth:"1.35",strokeLinejoin:"round"}),b.jsx("path",{d:"M8.15 6.1V11.9",stroke:"currentColor",strokeWidth:"1.35",strokeLinecap:"round"})]})}function pF(){return b.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round",children:[b.jsx("rect",{x:"1.5",y:"4.25",width:"15",height:"9.5",rx:"1.25"}),b.jsx("circle",{cx:"9",cy:"9",r:"2"})]})}function mF(){return b.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true",children:[b.jsx("path",{d:"M3 6H9.5M12.5 6H15M3 12H5.5M8.5 12H15",stroke:"currentColor",strokeWidth:"1.45",strokeLinecap:"round"}),b.jsx("circle",{cx:"11",cy:"6",r:"1.7",stroke:"currentColor",strokeWidth:"1.35"}),b.jsx("circle",{cx:"7",cy:"12",r:"1.7",stroke:"currentColor",strokeWidth:"1.35"})]})}const gF=[{id:"overview",label:"Overview",icon:b.jsx(dF,{})},{id:"rewards",label:"$ANTS",icon:b.jsx(fF,{})},{id:"diem-rewards",label:"DIEM $ANTS",icon:b.jsx(hF,{})},{id:"activity",label:"Activity",icon:b.jsx(pF,{})},{id:"settings",label:"Settings",icon:b.jsx(mF,{})}];function yF({activeTab:e,onSelect:t}){return b.jsxs("aside",{className:"dash-sidebar",children:[b.jsxs("div",{className:"dash-sidebar-brand",children:[b.jsx("span",{className:"dash-sidebar-brand-icon","aria-hidden":"true",children:b.jsx(q8,{size:20})}),b.jsx("span",{className:"dash-sidebar-title",children:"AntSeed Portal"})]}),b.jsx("nav",{className:"dash-sidebar-nav",children:gF.map(n=>b.jsxs("button",{type:"button",className:`dash-sidebar-item${e===n.id?" dash-sidebar-item--active":""}`,onClick:()=>t(n.id),children:[b.jsx("span",{className:"dash-sidebar-item-icon",children:n.icon}),b.jsx("span",{className:"dash-sidebar-item-label",children:n.label})]},n.id))})]})}const vF={month:"short",day:"numeric"},wF=18;function $s(e){const t=typeof e=="string"?Number(e):e;return Number.isFinite(t)?t.toLocaleString("en-US"):"0"}function ii(e){const t=typeof e=="bigint"||typeof e=="string"?Number(e):e;return Number.isFinite(t)?t>=1e9?`${(t/1e9).toFixed(2)}B`:t>=1e6?`${(t/1e6).toFixed(2)}M`:t>=1e4?`${(t/1e3).toFixed(1)}K`:t.toLocaleString("en-US"):"0"}function aa(e){if(!e)return 0n;try{return BigInt(e)}catch{return 0n}}function Yc(e){const t=Number.parseFloat(e??"0");return Number.isFinite(t)?t:0}function vt(e){const t=typeof e=="string"?Number(e):e??0;return Number.isFinite(t)?t.toLocaleString("en-US",{minimumFractionDigits:2,maximumFractionDigits:2}):"0.00"}function y2(e){return!Number.isFinite(e)||e<=0?"":e.toFixed(6).replace(/\.?(0+)$/,"")}function nr(e,t=6,n=4,r="…"){return`${e.slice(0,t)}${r}${e.slice(-n)}`}function Xm(e){return e>1e12?e:e*1e3}function yf(e,t=vF){return e?new Date(Xm(e)).toLocaleDateString("en-US",t):"—"}function e1(e){const t=typeof e=="bigint"?e:aa(e);if(t===0n)return"0";const n=Number(qr(t,wF));return n>0&&n<1e-4?"< 0.0001":n.toLocaleString("en-US",{maximumFractionDigits:4})}const bF={overview:"Overview",rewards:"$ANTS","diem-rewards":"DIEM $ANTS",activity:"Activity",settings:"Settings"},xF={overview:"Your AntSeed account at a glance.",rewards:"$ANTS earned from AntSeed network usage.","diem-rewards":"$ANTS earned from DIEM staking.",activity:"Settlements and channel closes.",settings:"Wallet, network, and appearance."};function CF(){return b.jsxs("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[b.jsx("circle",{cx:"8",cy:"8",r:"6.3",stroke:"currentColor",strokeWidth:"1.3"}),b.jsx("path",{d:"M5 8.4l2 2 4-4.4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]})}function EF(){return b.jsx("svg",{width:"12",height:"12",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:b.jsx("path",{d:"M4 6l4 4 4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}function AF(){return b.jsxs("svg",{width:"17",height:"17",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[b.jsx("circle",{cx:"8",cy:"8",r:"3",stroke:"currentColor",strokeWidth:"1.3"}),b.jsx("path",{d:"M8 2V3.5M8 12.5V14M2 8H3.5M12.5 8H14M3.8 3.8L4.8 4.8M11.2 11.2L12.2 12.2M3.8 12.2L4.8 11.2M11.2 4.8L12.2 3.8",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]})}function kF(){return b.jsx("svg",{width:"17",height:"17",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:b.jsx("path",{d:"M13.5 10A5.5 5.5 0 016 2.5 5.5 5.5 0 108 13.5a5.5 5.5 0 005.5-3.5z",stroke:"currentColor",strokeWidth:"1.3",strokeLinejoin:"round"})})}function SF({activeTab:e,balance:t,buyerEvmAddress:n,atRisk:r,isDark:s,onToggleTheme:a,onOpenWallet:c}){const l=t?parseFloat(t.total):null;return b.jsxs("header",{className:"dash-topbar",children:[b.jsxs("div",{className:"dash-topbar-titles",children:[b.jsx("div",{className:"dash-topbar-title",children:bF[e]}),b.jsx("div",{className:"dash-topbar-subtitle",children:xF[e]})]}),b.jsxs("div",{className:"dash-topbar-right",children:[b.jsx("button",{type:"button",className:"dash-topbar-theme-toggle",onClick:a,title:s?"Switch to light theme":"Switch to dark theme","aria-label":s?"Switch to light theme":"Switch to dark theme",children:s?b.jsx(AF,{}):b.jsx(kF,{})}),b.jsxs("button",{type:"button",className:`dash-topbar-account${r?" dash-topbar-account--risk":""}`,onClick:c,title:r?"Action needed: authorize a recovery wallet to protect your funds":"AntSeed account and wallet settings","aria-label":r?"Account settings: action needed, authorize a recovery wallet":"Open AntSeed account settings",children:[b.jsxs("span",{className:"dash-topbar-account-avatar",children:[b.jsx(CF,{}),r&&b.jsx("span",{className:"dash-topbar-account-badge","aria-hidden":"true"})]}),b.jsxs("span",{className:"dash-topbar-account-text",children:[b.jsx("span",{className:"dash-topbar-account-balance",children:l!==null?`$${vt(l)}`:"—"}),b.jsx("span",{className:"dash-topbar-account-addr",children:r?"Authorize wallet":n?nr(n):"AntSeed account"})]}),b.jsx("span",{className:"dash-topbar-account-chevron",children:b.jsx(EF,{})})]})]})]})}const jF={[Il.id]:Il};function IF(e){var t;return e!=null&&e.evmChainId?((t=jF[e.evmChainId])==null?void 0:t.name)??e.chainId:"configured payments network"}function Ot(e,t="Something went wrong."){return e instanceof Error?e.message.split(`
1727
- `)[0]??e.message:t}function ws(e){const{isConnected:t,connector:n}=it(),{switchChainAsync:r,isPending:s}=rC(),{openChainModal:a}=D8(),[c,l]=P.useState(void 0),d=e==null?void 0:e.evmChainId,f=IF(e),h=!!(t&&d&&c&&c!==d);P.useEffect(()=>{var A;let v=!1;async function w(){if(!t||!(n!=null&&n.getChainId)){v||l(void 0);return}try{const I=await n.getChainId();v||l(I)}catch{v||l(void 0)}}if(w(),!((A=n==null?void 0:n.emitter)!=null&&A.on))return()=>{v=!0};const C=I=>{if(typeof(I==null?void 0:I.chainId)=="number"){l(I.chainId);return}if(typeof(I==null?void 0:I.chainId)=="string"){l(Number(I.chainId));return}w()};return n.emitter.on("change",C),()=>{var I,S;v=!0,(S=(I=n.emitter).off)==null||S.call(I,"change",C)}},[n,t]);async function p(){if(!t||!(n!=null&&n.getChainId))return;const v=await n.getChainId();return l(v),v}async function m(v,w=1e4){const C=Date.now();for(;Date.now()-C<w;){if(await p()===v)return;await new Promise(I=>setTimeout(I,150))}throw new Error(`Wallet is still on chain ${c??"unknown"}. Please switch to ${f} and try again.`)}async function y(){if(!t)throw new Error("Connect your wallet before continuing.");if(!d)throw new Error("Payments network is not configured.");if(await p()!==d){if(typeof r=="function"){await r({chainId:d}),await m(d);return}throw typeof a=="function"&&a(),new Error(`Please switch your wallet to ${f} and try again.`)}}return{expectedChainId:d,targetChainName:f,walletChainId:c,wrongChain:h,isSwitchingChain:s,ensureCorrectNetwork:y}}const H8=Eo(["function setOperator(address buyer, address operator, uint256 nonce, bytes buyerSig) external","function transferOperator(address buyer, address newOperator) external"]);function V8(e,t){const{address:n}=it(),[r,s]=P.useState(!1),[a,c]=P.useState(null),{expectedChainId:l,ensureCorrectNetwork:d}=ws(e),{writeContract:f,data:h,reset:p}=Qr(),{isSuccess:m}=Vr({hash:h,chainId:l});P.useEffect(()=>{m&&r&&(s(!1),t==null||t())},[m,r,t]);const y=P.useCallback(async()=>{if(!(!n||!(e!=null&&e.depositsContractAddress))){c(null),s(!0),p();try{await d();const w=await oF(n);if(!w.ok){s(!1),c("Failed to sign wallet authorization");return}f({address:e.depositsContractAddress,abi:H8,functionName:"setOperator",chainId:l,args:[w.buyer,n,BigInt(w.nonce),w.signature]},{onError:C=>{s(!1),c(Ot(C))}})}catch(w){s(!1),c(Ot(w,"Failed to set wallet"))}}},[n,e,d,l,f,p]),v=P.useCallback(()=>{c(null),s(!1),p()},[p]);return{run:y,running:r,success:m,error:a,reset:v,txHash:h}}function NF(e,t){const[n,r]=P.useState(!1),[s,a]=P.useState(null),{expectedChainId:c,ensureCorrectNetwork:l}=ws(e),{writeContract:d,data:f,reset:h}=Qr(),{isSuccess:p}=Vr({hash:f,chainId:c});P.useEffect(()=>{p&&n&&(r(!1),t==null||t())},[p,n,t]);const m=P.useCallback(async(v,w)=>{if(e!=null&&e.depositsContractAddress){if(!/^0x[0-9a-fA-F]{40}$/.test(w)){a("Invalid wallet address");return}a(null),r(!0),h();try{await l(),d({address:e.depositsContractAddress,abi:H8,functionName:"transferOperator",chainId:c,args:[v,w]},{onError:C=>{r(!1),a(Ot(C))}})}catch(C){r(!1),a(Ot(C,"Failed to transfer operator"))}}},[e,l,c,d,h]),y=P.useCallback(()=>{a(null),r(!1),h()},[h]);return{run:m,running:n,success:p,error:s,reset:y}}function PF({action:e,children:t,className:n,title:r,tone:s="info",...a}){const c=["as-alert",`as-alert--${s}`,n].filter(Boolean).join(" ");return b.jsxs("div",{className:c,role:s==="danger"||s==="warning"?"alert":"status",...a,children:[b.jsx("div",{className:"as-alert__mark","aria-hidden":"true"}),b.jsxs("div",{className:"as-alert__content",children:[r&&b.jsx("div",{className:"as-alert__title",children:r}),b.jsx("div",{className:"as-alert__body",children:t})]}),e&&b.jsx("div",{className:"as-alert__action",children:e})]})}function En({children:e,className:t,fullWidth:n=!1,leadingIcon:r,size:s="md",trailingIcon:a,type:c="button",variant:l="primary",...d}){const f=["as-button",`as-button--${l}`,`as-button--${s}`,n?"as-button--full":null,t].filter(Boolean).join(" ");return b.jsxs("button",{type:c,className:f,...d,children:[r&&b.jsx("span",{className:"as-button__icon","aria-hidden":"true",children:r}),b.jsx("span",{className:"as-button__label",children:e}),a&&b.jsx("span",{className:"as-button__icon","aria-hidden":"true",children:a})]})}function BF(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function Bl(){return Bl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bl.apply(null,arguments)}var t1="data-focus-lock",Q8="data-focus-lock-disabled",_F="data-no-focus-lock",TF="data-autofocus-inside",OF="data-no-autofocus",Rp={width:"1px",height:"0px",padding:0,overflow:"hidden",position:"fixed",top:"1px",left:"1px"},G8=wg({},function(e){var t=e.target,n=e.currentTarget;return{target:t,currentTarget:n}}),K8=wg(),RF=wg(),MF=bg({async:!0,ssr:typeof document<"u"}),DF=P.createContext(void 0),FF=[],Ug=P.forwardRef(function(t,n){var r,s=P.useState(),a=s[0],c=s[1],l=P.useRef(),d=P.useRef(!1),f=P.useRef(null),h=P.useState({}),p=h[1],m=t.children,y=t.disabled,v=y===void 0?!1:y,w=t.noFocusGuards,C=w===void 0?!1:w,A=t.persistentFocus,I=A===void 0?!1:A,S=t.crossFrame,j=S===void 0?!0:S,N=t.autoFocus,T=N===void 0?!0:N;t.allowTextSelection;var B=t.group,O=t.className,R=t.whiteList,W=t.hasPositiveIndices,H=t.shards,K=H===void 0?FF:H,Q=t.as,ae=Q===void 0?"div":Q,q=t.lockProps,ee=q===void 0?{}:q,te=t.sideCar,U=t.returnFocus,Y=U===void 0?!1:U,Z=t.focusOptions,F=t.onActivation,X=t.onDeactivation,pe=P.useState({}),ne=pe[0],oe=P.useCallback(function(ze){var ht=ze.captureFocusRestore;if(!f.current){var Ze,gt=(Ze=document)==null?void 0:Ze.activeElement;f.current=gt,gt!==document.body&&(f.current=ht(gt))}l.current&&F&&F(l.current),d.current=!0,p()},[F]),fe=P.useCallback(function(){d.current=!1,X&&X(l.current),p()},[X]),ge=P.useCallback(function(ze){var ht=f.current;if(ht){var Ze=(typeof ht=="function"?ht():ht)||document.body,gt=typeof Y=="function"?Y(Ze):Y;if(gt){var It=typeof gt=="object"?gt:void 0;f.current=null,ze?Promise.resolve().then(function(){return Ze.focus(It)}):Ze.focus(It)}}},[Y]),Ie=P.useCallback(function(ze){d.current&&G8.useMedium(ze)},[]),Be=K8.useMedium,Le=P.useCallback(function(ze){l.current!==ze&&(l.current=ze,c(ze))},[]),_e=Bl((r={},r[Q8]=v&&"disabled",r[t1]=B,r),ee),Te=C!==!0,dt=Te&&C!=="tail",tt=vg([n,Le]),ft=P.useMemo(function(){return{observed:l,shards:K,enabled:!v,get active(){return d.current}}},[v,d,K,l]);return k.createElement(P.Fragment,null,Te&&[k.createElement("div",{key:"guard-first","data-focus-guard":!0,tabIndex:v?-1:0,style:Rp}),W?k.createElement("div",{key:"guard-nearest","data-focus-guard":!0,tabIndex:v?-1:1,style:Rp}):null],!v&&k.createElement(te,{id:ne,sideCar:MF,observed:a,disabled:v,persistentFocus:I,crossFrame:j,autoFocus:T,whiteList:R,shards:K,onActivation:oe,onDeactivation:fe,returnFocus:ge,focusOptions:Z,noFocusGuards:C}),k.createElement(ae,Bl({ref:tt},_e,{className:O,onBlur:Be,onFocus:Ie}),k.createElement(DF.Provider,{value:ft},m)),dt&&k.createElement("div",{"data-focus-guard":!0,tabIndex:v?-1:0,style:Rp}))});Ug.propTypes={};function n1(e,t){return n1=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},n1(e,t)}function LF(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,n1(e,t)}function _l(e){"@babel/helpers - typeof";return _l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_l(e)}function UF(e,t){if(_l(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(_l(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function zF(e){var t=UF(e,"string");return _l(t)=="symbol"?t:t+""}function WF(e,t,n){return(t=zF(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $F(e,t){function n(r){return r.displayName||r.name||"Component"}return function(s){var a=[],c;function l(){c=e(a.map(function(f){return f.props})),t(c)}var d=(function(f){LF(h,f);function h(){return f.apply(this,arguments)||this}h.peek=function(){return c};var p=h.prototype;return p.componentDidMount=function(){a.push(this),l()},p.componentDidUpdate=function(){l()},p.componentWillUnmount=function(){var y=a.indexOf(this);a.splice(y,1),l()},p.render=function(){return k.createElement(s,this.props)},h})(P.PureComponent);return WF(d,"displayName","SideEffect("+n(s)+")"),d}}var Kr=function(e){for(var t=Array(e.length),n=0;n<e.length;++n)t[n]=e[n];return t},vi=function(e){return Array.isArray(e)?e:[e]},Y8=function(e){return Array.isArray(e)?e[0]:e},qF=function(e){if(e.nodeType!==Node.ELEMENT_NODE)return!1;var t=window.getComputedStyle(e,null);return!t||!t.getPropertyValue?!1:t.getPropertyValue("display")==="none"||t.getPropertyValue("visibility")==="hidden"},J8=function(e){return e.parentNode&&e.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.parentNode.host:e.parentNode},Z8=function(e){return e===document||e&&e.nodeType===Node.DOCUMENT_NODE},HF=function(e){return e.hasAttribute("inert")},VF=function(e,t){return!e||Z8(e)||!qF(e)&&!HF(e)&&t(J8(e))},X8=function(e,t){var n=e.get(t);if(n!==void 0)return n;var r=VF(t,X8.bind(void 0,e));return e.set(t,r),r},QF=function(e,t){return e&&!Z8(e)?YF(e)?t(J8(e)):!1:!0},eE=function(e,t){var n=e.get(t);if(n!==void 0)return n;var r=QF(t,eE.bind(void 0,e));return e.set(t,r),r},tE=function(e){return e.dataset},GF=function(e){return e.tagName==="BUTTON"},nE=function(e){return e.tagName==="INPUT"},rE=function(e){return nE(e)&&e.type==="radio"},KF=function(e){return!((nE(e)||GF(e))&&(e.type==="hidden"||e.disabled))},YF=function(e){var t=e.getAttribute(OF);return![!0,"true",""].includes(t)},zg=function(e){var t;return!!(e&&(!((t=tE(e))===null||t===void 0)&&t.focusGuard))},r1=function(e){return!zg(e)},JF=function(e){return!!e},ZF=function(e,t){var n=Math.max(0,e.tabIndex),r=Math.max(0,t.tabIndex),s=n-r,a=e.index-t.index;if(s){if(!n)return 1;if(!r)return-1}return s||a},XF=function(e){return e.tabIndex<0&&!e.hasAttribute("tabindex")?0:e.tabIndex},Wg=function(e,t,n){return Kr(e).map(function(r,s){var a=XF(r);return{node:r,index:s,tabIndex:n&&a===-1?(r.dataset||{}).focusGuard?0:-1:a}}).filter(function(r){return!t||r.tabIndex>=0}).sort(ZF)},eL=["button:enabled","select:enabled","textarea:enabled","input:enabled","a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]","[tabindex]","[contenteditable]","[autofocus]"],$g=eL.join(","),tL="".concat($g,", [data-focus-guard]"),oE=function(e,t){return Kr((e.shadowRoot||e).children).reduce(function(n,r){return n.concat(r.matches(t?tL:$g)?[r]:[],oE(r))},[])},nL=function(e,t){var n;return e instanceof HTMLIFrameElement&&(!((n=e.contentDocument)===null||n===void 0)&&n.body)?La([e.contentDocument.body],t):[e]},La=function(e,t){return e.reduce(function(n,r){var s,a=oE(r,t),c=(s=[]).concat.apply(s,a.map(function(l){return nL(l,t)}));return n.concat(c,r.parentNode?Kr(r.parentNode.querySelectorAll($g)).filter(function(l){return l===r}):[])},[])},rL=function(e){var t=e.querySelectorAll("[".concat(TF,"]"));return Kr(t).map(function(n){return La([n])}).reduce(function(n,r){return n.concat(r)},[])},qg=function(e,t){return Kr(e).filter(function(n){return X8(t,n)}).filter(function(n){return KF(n)})},v2=function(e,t){return t===void 0&&(t=new Map),Kr(e).filter(function(n){return eE(t,n)})},Hg=function(e,t,n){return Wg(qg(La(e,n),t),!0,n)},Tl=function(e,t){return Wg(qg(La(e),t),!1)},oL=function(e,t){return qg(rL(e),t)},ai=function(e,t){return e.shadowRoot?ai(e.shadowRoot,t):Object.getPrototypeOf(e).contains!==void 0&&Object.getPrototypeOf(e).contains.call(e,t)?!0:Kr(e.children).some(function(n){var r;if(n instanceof HTMLIFrameElement){var s=(r=n.contentDocument)===null||r===void 0?void 0:r.body;return s?ai(s,t):!1}return ai(n,t)})},sL=function(e){for(var t=new Set,n=e.length,r=0;r<n;r+=1)for(var s=r+1;s<n;s+=1){var a=e[r].compareDocumentPosition(e[s]);(a&Node.DOCUMENT_POSITION_CONTAINED_BY)>0&&t.add(s),(a&Node.DOCUMENT_POSITION_CONTAINS)>0&&t.add(r)}return e.filter(function(c,l){return!t.has(l)})},sE=function(e){return e.parentNode?sE(e.parentNode):e},Vg=function(e){var t=vi(e);return t.filter(Boolean).reduce(function(n,r){var s=r.getAttribute(t1);return n.push.apply(n,s?sL(Kr(sE(r).querySelectorAll("[".concat(t1,'="').concat(s,'"]:not([').concat(Q8,'="disabled"])')))):[r]),n},[])},iL=function(e){try{return e()}catch{return}},Ol=function(e){if(e===void 0&&(e=document),!(!e||!e.activeElement)){var t=e.activeElement;return t.shadowRoot?Ol(t.shadowRoot):t instanceof HTMLIFrameElement&&iL(function(){return t.contentWindow.document})?Ol(t.contentWindow.document):t}},aL=function(e,t){return e===t},cL=function(e,t){return!!Kr(e.querySelectorAll("iframe")).some(function(n){return aL(n,t)})},iE=function(e,t){return t===void 0&&(t=Ol(Y8(e).ownerDocument)),!t||t.dataset&&t.dataset.focusGuard?!1:Vg(e).some(function(n){return ai(n,t)||cL(n,t)})},lL=function(e){e===void 0&&(e=document);var t=Ol(e);return t?Kr(e.querySelectorAll("[".concat(_F,"]"))).some(function(n){return ai(n,t)}):!1},uL=function(e,t){return t.filter(rE).filter(function(n){return n.name===e.name}).filter(function(n){return n.checked})[0]||e},Qg=function(e,t){return rE(e)&&e.name?uL(e,t):e},dL=function(e){var t=new Set;return e.forEach(function(n){return t.add(Qg(n,e))}),e.filter(function(n){return t.has(n)})},w2=function(e){return e[0]&&e.length>1?Qg(e[0],e):e[0]},b2=function(e,t){return e.indexOf(Qg(t,e))},o1="NEW_FOCUS",fL=function(e,t,n,r,s){var a=e.length,c=e[0],l=e[a-1],d=zg(r);if(!(r&&e.indexOf(r)>=0)){var f=r!==void 0?n.indexOf(r):-1,h=s?n.indexOf(s):f,p=s?e.indexOf(s):-1;if(f===-1)return p!==-1?p:o1;if(p===-1)return o1;var m=f-h,y=n.indexOf(c),v=n.indexOf(l),w=dL(n),C=r!==void 0?w.indexOf(r):-1,A=s?w.indexOf(s):C,I=w.filter(function(O){return O.tabIndex>=0}),S=r!==void 0?I.indexOf(r):-1,j=s?I.indexOf(s):S,N=S>=0&&j>=0?j-S:A-C;if(!m&&p>=0||t.length===0)return p;var T=b2(e,t[0]),B=b2(e,t[t.length-1]);if(f<=y&&d&&Math.abs(m)>1)return B;if(f>=v&&d&&Math.abs(m)>1)return T;if(m&&Math.abs(N)>1)return p;if(f<=y)return B;if(f>v)return T;if(m)return Math.abs(m)>1?p:(a+p+m)%a}},hL=function(e){return function(t){var n,r=(n=tE(t))===null||n===void 0?void 0:n.autofocus;return t.autofocus||r!==void 0&&r!=="false"||e.indexOf(t)>=0}},x2=function(e,t,n){var r=e.map(function(a){var c=a.node;return c}),s=v2(r.filter(hL(n)));return s&&s.length?w2(s):w2(v2(t))},s1=function(e,t){return t===void 0&&(t=[]),t.push(e),e.parentNode&&s1(e.parentNode.host||e.parentNode,t),t},Mp=function(e,t){for(var n=s1(e),r=s1(t),s=0;s<n.length;s+=1){var a=n[s];if(r.indexOf(a)>=0)return a}return!1},aE=function(e,t,n){var r=vi(e),s=vi(t),a=r[0],c=!1;return s.filter(Boolean).forEach(function(l){c=Mp(c||l,l)||c,n.filter(Boolean).forEach(function(d){var f=Mp(a,d);f&&(!c||ai(f,c)?c=f:c=Mp(f,c))})}),c},C2=function(e,t){return e.reduce(function(n,r){return n.concat(oL(r,t))},[])},pL=function(e,t){var n=new Map;return t.forEach(function(r){return n.set(r.node,r)}),e.map(function(r){return n.get(r)}).filter(JF)},mL=function(e,t){var n=Ol(vi(e).length>0?document:Y8(e).ownerDocument),r=Vg(e).filter(r1),s=aE(n||e,e,r),a=new Map,c=Tl(r,a),l=c.filter(function(v){var w=v.node;return r1(w)});if(l[0]){var d=Tl([s],a).map(function(v){var w=v.node;return w}),f=pL(d,l),h=f.map(function(v){var w=v.node;return w}),p=f.filter(function(v){var w=v.tabIndex;return w>=0}).map(function(v){var w=v.node;return w}),m=fL(h,p,d,n,t);if(m===o1){var y=x2(c,p,C2(r,a))||x2(c,h,C2(r,a));if(y)return{node:y};console.warn("focus-lock: cannot find any node to move focus into");return}return m===void 0?m:f[m]}},gL=function(e){var t=Vg(e).filter(r1),n=aE(e,e,t),r=Wg(La([n],!0),!0,!0),s=La(t,!1);return r.map(function(a){var c=a.node,l=a.index;return{node:c,index:l,lockItem:s.indexOf(c)>=0,guard:zg(c)}})},Gg=function(e,t){e&&("focus"in e&&e.focus(t),"contentWindow"in e&&e.contentWindow&&e.contentWindow.focus())},Dp=0,Fp=!1,cE=function(e,t,n){n===void 0&&(n={});var r=mL(e,t);if(!Fp&&r){if(Dp>2){console.error("FocusLock: focus-fighting detected. Only one focus management system could be active. See https://github.com/theKashey/focus-lock/#focus-fighting"),Fp=!0,setTimeout(function(){Fp=!1},1);return}Dp++,Gg(r.node,n.focusOptions),Dp--}};function zc(e){if(!e)return null;if(typeof WeakRef>"u")return function(){return e||null};var t=e?new WeakRef(e):null;return function(){return(t==null?void 0:t.deref())||null}}var yL=function(e){if(!e)return null;for(var t=[],n=e;n&&n!==document.body;)t.push({current:zc(n),parent:zc(n.parentElement),left:zc(n.previousElementSibling),right:zc(n.nextElementSibling)}),n=n.parentElement;return{element:zc(e),stack:t,ownerDocument:e.ownerDocument}},vL=function(e){var t,n,r,s,a;if(e)for(var c=e.stack,l=e.ownerDocument,d=new Map,f=0,h=c;f<h.length;f++){var p=h[f],m=(t=p.parent)===null||t===void 0?void 0:t.call(p);if(m&&l.contains(m)){for(var y=(n=p.left)===null||n===void 0?void 0:n.call(p),v=p.current(),w=m.contains(v)?v:void 0,C=(r=p.right)===null||r===void 0?void 0:r.call(p),A=Hg([m],d),I=(a=(s=w??(y==null?void 0:y.nextElementSibling))!==null&&s!==void 0?s:C)!==null&&a!==void 0?a:y;I;){for(var S=0,j=A;S<j.length;S++){var N=j[S];if(I!=null&&I.contains(N.node))return N.node}I=I.nextElementSibling}if(A.length)return A[0].node}}},lE=function(e){var t=yL(e);return function(){return vL(t)}},wL=function(e,t,n){if(!e||!t)return console.error("no element or scope given"),{};var r=vi(t);if(r.every(function(c){return!ai(c,e)}))return console.error("Active element is not contained in the scope"),{};var s=n?Hg(r,new Map):Tl(r,new Map),a=s.findIndex(function(c){var l=c.node;return l===e});if(a!==-1)return{prev:s[a-1],next:s[a+1],first:s[0],last:s[s.length-1]}},bL=function(e,t){var n=t?Hg(vi(e),new Map):Tl(vi(e),new Map);return{first:n[0],last:n[n.length-1]}},xL=function(e){return Object.assign({scope:document.body,cycle:!0,onlyTabbable:!0},e)},uE=function(e,t,n){t===void 0&&(t={});var r=xL(t),s=wL(e,r.scope,r.onlyTabbable);if(s){var a=n(s,r.cycle);a&&Gg(a.node,r.focusOptions)}},CL=function(e,t){t===void 0&&(t={}),uE(e,t,function(n,r){var s=n.next,a=n.first;return s||r&&a})},EL=function(e,t){t===void 0&&(t={}),uE(e,t,function(n,r){var s=n.prev,a=n.last;return s||r&&a})},dE=function(e,t,n){var r,s=bL(e,(r=t.onlyTabbable)!==null&&r!==void 0?r:!0),a=s[n];a&&Gg(a.node,t.focusOptions)},AL=function(e,t){t===void 0&&(t={}),dE(e,t,"first")},kL=function(e,t){t===void 0&&(t={}),dE(e,t,"last")};function Kg(e){setTimeout(e,1)}var SL=function(t){return t&&"current"in t?t.current:t},fE=function(){return document&&document.activeElement===document.body},jL=function(){return fE()||lL()},ma=null,vn=null,E2=function(){return null},ga=null,Rl=!1,Yg=!1,IL=function(){return!0},NL=function(t){return(ma.whiteList||IL)(t)},PL=function(t,n){ga={observerNode:t,portaledElement:n}},BL=function(t){return ga&&ga.portaledElement===t};function A2(e,t,n,r){var s=null,a=e;do{var c=r[a];if(c.guard)c.node.dataset.focusAutoGuard&&(s=c);else if(c.lockItem){if(a!==e)return;s=null}else break}while((a+=n)!==t);s&&(s.node.tabIndex=0)}var _L=function(t){return t?!!Rl:Rl==="meanwhile"},TL=function e(t,n,r){return n&&(n.host===t&&(!n.activeElement||r.contains(n.activeElement))||n.parentNode&&e(t,n.parentNode,r))},OL=function(t,n){return n.some(function(r){return TL(t,r,r)})},hE=function(t){return Tl(t,new Map)},RL=function(t){return!hE([t.parentNode]).some(function(n){return n.node===t})},vf=function(){var t=!1;if(ma){var n=ma,r=n.observed,s=n.persistentFocus,a=n.autoFocus,c=n.shards,l=n.crossFrame,d=n.focusOptions,f=n.noFocusGuards,h=r||ga&&ga.portaledElement;if(fE()&&vn&&vn!==document.body&&(!document.body.contains(vn)||RL(vn))){var p=E2();p&&p.focus()}var m=document&&document.activeElement;if(h){var y=[h].concat(c.map(SL).filter(Boolean)),v=function(){if(!_L(l)||!f||!vn||Yg)return!1;var S=hE(y),j=S.findIndex(function(N){var T=N.node;return T===vn});return j===0||j===S.length-1};if((!m||NL(m))&&(s||v()||!jL()||!vn&&a)&&(h&&!(iE(y)||m&&OL(m,y)||BL(m))&&(document&&!vn&&m&&!a?(m.blur&&m.blur(),document.body.focus()):(t=cE(y,vn,{focusOptions:d}),ga={})),vn=document&&document.activeElement,vn!==document.body&&(E2=lE(vn)),Rl=!1),document&&m!==document.activeElement&&document.querySelector("[data-focus-auto-guard]")){var w=document&&document.activeElement,C=gL(y),A=C.map(function(I){var S=I.node;return S}).indexOf(w);A>-1&&(C.filter(function(I){var S=I.guard,j=I.node;return S&&j.dataset.focusAutoGuard}).forEach(function(I){var S=I.node;return S.removeAttribute("tabIndex")}),A2(A,C.length,1,C),A2(A,-1,-1,C))}}}return t},pE=function(t){vf()&&t&&(t.stopPropagation(),t.preventDefault())},Jg=function(){return Kg(vf)},ML=function(t){var n=t.target,r=t.currentTarget;r.contains(n)||PL(r,n)},DL=function(){return null},mE=function(){Yg=!0},gE=function(){Yg=!1,Rl="just",Kg(function(){Rl="meanwhile"})},FL=function(){document.addEventListener("focusin",pE),document.addEventListener("focusout",Jg),window.addEventListener("focus",mE),window.addEventListener("blur",gE)},LL=function(){document.removeEventListener("focusin",pE),document.removeEventListener("focusout",Jg),window.removeEventListener("focus",mE),window.removeEventListener("blur",gE)};function UL(e){return e.filter(function(t){var n=t.disabled;return!n})}var yE={moveFocusInside:cE,focusInside:iE,focusNextElement:CL,focusPrevElement:EL,focusFirstElement:AL,focusLastElement:kL,captureFocusRestore:lE};function zL(e){var t=e.slice(-1)[0];t&&!ma&&FL();var n=ma,r=n&&t&&t.id===n.id;ma=t,n&&!r&&(n.onDeactivation(),e.filter(function(s){var a=s.id;return a===n.id}).length||n.returnFocus(!t)),t?(vn=null,(!r||n.observed!==t.observed)&&t.onActivation(yE),vf(),Kg(vf)):(LL(),vn=null)}G8.assignSyncMedium(ML);K8.assignMedium(Jg);RF.assignMedium(function(e){return e(yE)});const WL=$F(UL,zL)(DL);var Zg=P.forwardRef(function(t,n){return k.createElement(Ug,Bl({sideCar:WL,ref:n},t))}),vE=Ug.propTypes||{};vE.sideCar;BF(vE,["sideCar"]);Zg.propTypes={};var wE=bg(),Lp=function(){},Yf=P.forwardRef(function(e,t){var n=P.useRef(null),r=P.useState({onScrollCapture:Lp,onWheelCapture:Lp,onTouchMoveCapture:Lp}),s=r[0],a=r[1],c=e.forwardProps,l=e.children,d=e.className,f=e.removeScrollBar,h=e.enabled,p=e.shards,m=e.sideCar,y=e.noRelative,v=e.noIsolation,w=e.inert,C=e.allowPinchZoom,A=e.as,I=A===void 0?"div":A,S=e.gapMode,j=yg(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),N=m,T=vg([n,t]),B=Jt(Jt({},j),s);return P.createElement(P.Fragment,null,h&&P.createElement(N,{sideCar:wE,removeScrollBar:f,shards:p,noRelative:y,noIsolation:v,inert:w,setCallbacks:a,allowPinchZoom:!!C,lockRef:n,gapMode:S}),c?P.cloneElement(P.Children.only(l),Jt(Jt({},B),{ref:T})):P.createElement(I,Jt({},B,{className:d,ref:T}),l))});Yf.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Yf.classNames={fullWidth:Kc,zeroRight:Gc};var i1=!1;if(typeof window<"u")try{var Fd=Object.defineProperty({},"passive",{get:function(){return i1=!0,!0}});window.addEventListener("test",Fd,Fd),window.removeEventListener("test",Fd,Fd)}catch{i1=!1}var ta=i1?{passive:!1}:!1,$L=function(e){return e.tagName==="TEXTAREA"},bE=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!$L(e)&&n[t]==="visible")},qL=function(e){return bE(e,"overflowY")},HL=function(e){return bE(e,"overflowX")},k2=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var s=xE(e,r);if(s){var a=CE(e,r),c=a[1],l=a[2];if(c>l)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},VL=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},QL=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},xE=function(e,t){return e==="v"?qL(t):HL(t)},CE=function(e,t){return e==="v"?VL(t):QL(t)},GL=function(e,t){return e==="h"&&t==="rtl"?-1:1},KL=function(e,t,n,r,s){var a=GL(e,window.getComputedStyle(t).direction),c=a*r,l=n.target,d=t.contains(l),f=!1,h=c>0,p=0,m=0;do{if(!l)break;var y=CE(e,l),v=y[0],w=y[1],C=y[2],A=w-C-a*v;(v||A)&&xE(e,l)&&(p+=A,m+=v);var I=l.parentNode;l=I&&I.nodeType===Node.DOCUMENT_FRAGMENT_NODE?I.host:I}while(!d&&l!==document.body||d&&(t.contains(l)||t===l));return(h&&Math.abs(p)<1||!h&&Math.abs(m)<1)&&(f=!0),f},Ld=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},S2=function(e){return[e.deltaX,e.deltaY]},j2=function(e){return e&&"current"in e?e.current:e},YL=function(e,t){return e[0]===t[0]&&e[1]===t[1]},JL=function(e){return`
1728
- .block-interactivity-`.concat(e,` {pointer-events: none;}
1729
- .allow-interactivity-`).concat(e,` {pointer-events: all;}
1730
- `)},ZL=0,na=[];function XL(e){var t=P.useRef([]),n=P.useRef([0,0]),r=P.useRef(),s=P.useState(ZL++)[0],a=P.useState(xg)[0],c=P.useRef(e);P.useEffect(function(){c.current=e},[e]),P.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(s));var w=NC([e.lockRef.current],(e.shards||[]).map(j2),!0).filter(Boolean);return w.forEach(function(C){return C.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),w.forEach(function(C){return C.classList.remove("allow-interactivity-".concat(s))})}}},[e.inert,e.lockRef.current,e.shards]);var l=P.useCallback(function(w,C){if("touches"in w&&w.touches.length===2||w.type==="wheel"&&w.ctrlKey)return!c.current.allowPinchZoom;var A=Ld(w),I=n.current,S="deltaX"in w?w.deltaX:I[0]-A[0],j="deltaY"in w?w.deltaY:I[1]-A[1],N,T=w.target,B=Math.abs(S)>Math.abs(j)?"h":"v";if("touches"in w&&B==="h"&&T.type==="range")return!1;var O=window.getSelection(),R=O&&O.anchorNode,W=R?R===T||R.contains(T):!1;if(W)return!1;var H=k2(B,T);if(!H)return!0;if(H?N=B:(N=B==="v"?"h":"v",H=k2(B,T)),!H)return!1;if(!r.current&&"changedTouches"in w&&(S||j)&&(r.current=N),!N)return!0;var K=r.current||N;return KL(K,C,w,K==="h"?S:j)},[]),d=P.useCallback(function(w){var C=w;if(!(!na.length||na[na.length-1]!==a)){var A="deltaY"in C?S2(C):Ld(C),I=t.current.filter(function(N){return N.name===C.type&&(N.target===C.target||C.target===N.shadowParent)&&YL(N.delta,A)})[0];if(I&&I.should){C.cancelable&&C.preventDefault();return}if(!I){var S=(c.current.shards||[]).map(j2).filter(Boolean).filter(function(N){return N.contains(C.target)}),j=S.length>0?l(C,S[0]):!c.current.noIsolation;j&&C.cancelable&&C.preventDefault()}}},[]),f=P.useCallback(function(w,C,A,I){var S={name:w,delta:C,target:A,should:I,shadowParent:eU(A)};t.current.push(S),setTimeout(function(){t.current=t.current.filter(function(j){return j!==S})},1)},[]),h=P.useCallback(function(w){n.current=Ld(w),r.current=void 0},[]),p=P.useCallback(function(w){f(w.type,S2(w),w.target,l(w,e.lockRef.current))},[]),m=P.useCallback(function(w){f(w.type,Ld(w),w.target,l(w,e.lockRef.current))},[]);P.useEffect(function(){return na.push(a),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:m}),document.addEventListener("wheel",d,ta),document.addEventListener("touchmove",d,ta),document.addEventListener("touchstart",h,ta),function(){na=na.filter(function(w){return w!==a}),document.removeEventListener("wheel",d,ta),document.removeEventListener("touchmove",d,ta),document.removeEventListener("touchstart",h,ta)}},[]);var y=e.removeScrollBar,v=e.inert;return P.createElement(P.Fragment,null,v?P.createElement(a,{styles:JL(s)}):null,y?P.createElement(RC,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function eU(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const tU=TC(wE,XL);var Xg=P.forwardRef(function(e,t){return P.createElement(Yf,Jt({},e,{ref:t,sideCar:tU}))});Xg.classNames=Yf.classNames;var EE=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},ra=new WeakMap,Ud=new WeakMap,zd={},Up=0,AE=function(e){return e&&(e.host||AE(e.parentNode))},nU=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=AE(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},kE=function(e,t,n,r){var s=nU(t,Array.isArray(e)?e:[e]);zd[n]||(zd[n]=new WeakMap);var a=zd[n],c=[],l=new Set,d=new Set(s),f=function(p){!p||l.has(p)||(l.add(p),f(p.parentNode))};s.forEach(f);var h=function(p){!p||d.has(p)||Array.prototype.forEach.call(p.children,function(m){if(l.has(m))h(m);else try{var y=m.getAttribute(r),v=y!==null&&y!=="false",w=(ra.get(m)||0)+1,C=(a.get(m)||0)+1;ra.set(m,w),a.set(m,C),c.push(m),w===1&&v&&Ud.set(m,!0),C===1&&m.setAttribute(n,"true"),v||m.setAttribute(r,"true")}catch(A){console.error("aria-hidden: cannot operate on ",m,A)}})};return h(t),l.clear(),Up++,function(){c.forEach(function(p){var m=ra.get(p)-1,y=a.get(p)-1;ra.set(p,m),a.set(p,y),m||(Ud.has(p)||p.removeAttribute(r),Ud.delete(p)),y||p.removeAttribute(n)}),Up--,Up||(ra=new WeakMap,ra=new WeakMap,Ud=new WeakMap,zd={})}},rU=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),s=t||EE(e);return s?(r.push.apply(r,Array.from(s.querySelectorAll("[aria-live], script"))),kE(r,s,n,"aria-hidden")):function(){return null}},oU=function(e,t,n){n===void 0&&(n="data-inert-ed");var r=t||EE(e);return r?kE(e,r,n,"inert"):function(){return null}},sU=function(){return typeof HTMLElement<"u"&&HTMLElement.prototype.hasOwnProperty("inert")},iU=function(e,t,n){return n===void 0&&(n="data-suppressed"),(sU()?oU:rU)(e,t,n)};let ci=[];const a1=new Set;function SE(){a1.forEach(e=>e())}function aU(e){ci=ci.filter(t=>t!==e),ci.push(e),SE()}function cU(e){ci=ci.filter(t=>t!==e),SE()}function zp(e){return ci[ci.length-1]===e}function jE(e,t,n){const r=P.useRef(n),s=P.useRef(null),[a,c]=P.useState(!1);P.useEffect(()=>{r.current=n},[n]);const l=P.useCallback(()=>{const f=s.current;s.current=null,f&&document.contains(f)&&f.focus({preventScroll:!0})},[]),d=P.useCallback(()=>{r.current()},[]);return P.useEffect(()=>{if(!e)return;const f=t.current;if(!f)return;const h=f;s.current=document.activeElement instanceof HTMLElement?document.activeElement:null,aU(h),c(zp(h));function p(){c(zp(h))}function m(y){zp(h)&&y.key==="Escape"&&(y.preventDefault(),y.stopPropagation(),y.stopImmediatePropagation(),d())}return a1.add(p),window.addEventListener("keydown",m,!0),()=>{window.removeEventListener("keydown",m,!0),a1.delete(p),cU(h),l()}},[d,e,t,l]),P.useEffect(()=>{if(!e||!a)return;const f=t.current;if(f)return iU(f)},[e,a,t]),{closeDialog:d,isTopDialog:a}}function lU(){return b.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:b.jsx("path",{d:"M4 4L12 12M12 4L4 12",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round"})})}function uU({backdropClassName:e,bodyClassName:t,children:n,className:r,closeLabel:s="Close",eyebrow:a,isOpen:c,onClose:l,side:d="right",subtitle:f,title:h}){const p=P.useRef(null),m=P.useId(),y=P.useId(),{closeDialog:v,isTopDialog:w}=jE(c,p,l),C=c&&w,A=["as-drawer-backdrop",c?"as-drawer-backdrop--open":null,e].filter(Boolean).join(" "),I=["as-drawer",`as-drawer--${d}`,c?"as-drawer--open":null,r].filter(Boolean).join(" "),S=["as-drawer__body",t].filter(Boolean).join(" ");return P.useEffect(()=>{if(!c||!w)return;function j(N){const T=p.current;T&&(N.target instanceof Node&&T.contains(N.target)||N.target instanceof Element&&N.target.closest('[role="dialog"]')!==null||v())}return document.addEventListener("pointerdown",j,!0),()=>document.removeEventListener("pointerdown",j,!0)},[v,c,w]),b.jsxs(b.Fragment,{children:[b.jsx("div",{"aria-hidden":!c,className:A,onClick:v}),b.jsx(Xg,{allowPinchZoom:!0,className:"as-drawer__scroll-lock",enabled:c&&w,children:b.jsx(Zg,{autoFocus:!0,className:"as-drawer__focus-lock",disabled:!c||!w,focusOptions:{preventScroll:!0},returnFocus:!1,children:b.jsxs("aside",{"aria-describedby":f?y:void 0,"aria-hidden":C?void 0:!0,"aria-labelledby":m,"aria-modal":C?"true":void 0,className:I,ref:p,role:"dialog",tabIndex:-1,children:[b.jsxs("header",{className:"as-drawer__header",children:[b.jsxs("div",{className:"as-drawer__titles",children:[a&&b.jsx("div",{className:"as-drawer__eyebrow",children:a}),b.jsx("h2",{className:"as-drawer__title",id:m,children:h}),f&&b.jsx("p",{className:"as-drawer__subtitle",id:y,children:f})]}),b.jsx("button",{type:"button",className:"as-drawer__close",onClick:v,"aria-label":s,children:b.jsx(lU,{})})]}),b.jsx("div",{className:S,children:n})]})})})]})}const dU={sm:"24rem",md:"28.75rem",lg:"35rem"};function fU(){return b.jsx("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:b.jsx("path",{d:"M4 4L12 12M12 4L4 12",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round"})})}function hU({bodyClassName:e,children:t,className:n,closeLabel:r="Close",eyebrow:s,isOpen:a,onClose:c,overlayClassName:l,size:d="md",subtitle:f,title:h}){const p=P.useRef(null),m=P.useId(),y=P.useId(),{closeDialog:v,isTopDialog:w}=jE(a,p,c);if(!a)return null;const C=["as-modal-overlay",l].filter(Boolean).join(" "),A=["as-modal",`as-modal--${d}`,n].filter(Boolean).join(" "),I=["as-modal__body",e].filter(Boolean).join(" "),S={"--as-modal-width":dU[d]};return b.jsx("div",{className:C,role:"presentation",onMouseDown:v,children:b.jsx(Xg,{allowPinchZoom:!0,className:"as-modal__scroll-lock",enabled:w,style:S,children:b.jsx(Zg,{autoFocus:!0,className:"as-modal__focus-lock",disabled:!w,focusOptions:{preventScroll:!0},returnFocus:!1,children:b.jsxs("div",{"aria-describedby":f?y:void 0,"aria-hidden":w?void 0:!0,"aria-labelledby":m,"aria-modal":w?"true":void 0,className:A,ref:p,role:"dialog",tabIndex:-1,onMouseDown:j=>j.stopPropagation(),children:[b.jsxs("header",{className:"as-modal__header",children:[b.jsxs("div",{className:"as-modal__titles",children:[s&&b.jsx("div",{className:"as-modal__eyebrow",children:s}),b.jsx("h2",{className:"as-modal__title",id:m,children:h}),f&&b.jsx("p",{className:"as-modal__subtitle",id:y,children:f})]}),b.jsx(pU,{label:r,className:"as-modal__close",onClick:v,children:b.jsx(fU,{})})]}),b.jsx("div",{className:I,children:t})]})})})})}function pU({children:e,className:t,label:n,onClick:r}){return b.jsx("button",{type:"button",className:t,onClick:r,"aria-label":n,children:e})}function mU({className:e,error:t,hint:n,id:r,label:s,...a}){const c=r??a.name,l=["as-field",e].filter(Boolean).join(" ");return b.jsxs("label",{className:l,htmlFor:c,children:[s&&b.jsx("span",{className:"as-field__label",children:s}),b.jsx("input",{id:c,className:"as-field__input",...a}),t?b.jsx("span",{className:"as-field__error",children:t}):n?b.jsx("span",{className:"as-field__hint",children:n}):null]})}let Jc=0,c1="";function gU(){Jc===0&&(c1=document.body.style.overflow,document.body.style.overflow="hidden"),Jc+=1}function yU(){Jc=Math.max(0,Jc-1),Jc===0&&(document.body.style.overflow=c1,c1="")}function IE(e){P.useEffect(()=>{if(e)return gU(),yU},[e])}function l1({isOpen:e,onClose:t,title:n,subtitle:r,variant:s="default",children:a}){return b.jsx(hU,{bodyClassName:"action-modal-body",className:`action-modal-card action-modal-card--${s}`,closeLabel:"Close",eyebrow:s==="deposit"?"Deposit wizard":void 0,isOpen:e,onClose:t,overlayClassName:"action-modal-overlay",size:s==="deposit"?"lg":"md",subtitle:r,title:n,children:a})}function Ya({children:e,className:t,disabled:n,label:r="Connect wallet"}){return b.jsx(Fg.Custom,{children:({account:s,chain:a,openConnectModal:c,authenticationStatus:l,mounted:d})=>{const f=d&&l!=="loading",h=!!(f&&s&&a&&(!l||l==="authenticated"));return e?e({ready:f,connected:h,openConnectModal:c}):h?null:b.jsx("button",{type:"button",className:t,onClick:c,disabled:!f||n,children:r})}})}function vU({isOpen:e,config:t,hasPendingAction:n,onClose:r,onAuthorized:s}){const{address:a,isConnected:c}=it(),l=c&&!!a,{run:d,running:f,success:h,error:p,reset:m}=V8(t),y=P.useRef(null),[v,w]=P.useState(null),C=()=>{var S;const I=(S=y.current)==null?void 0:S.getBoundingClientRect();I&&w({top:I.bottom+8,left:I.left})},A=()=>w(null);return P.useEffect(()=>{h&&(s(),m())},[h,s,m]),P.useEffect(()=>{e||(m(),w(null))},[e,m]),b.jsx(l1,{isOpen:e,onClose:r,title:"Authorize your wallet",subtitle:"Required to withdraw USDC, claim ANTS, and close channels.",children:b.jsxs("div",{className:"authorize-wallet-modal",children:[b.jsxs("div",{ref:y,className:"authorize-wallet-why",tabIndex:0,onMouseEnter:C,onMouseLeave:A,onFocus:C,onBlur:A,children:[b.jsx("span",{children:"Why you need an authorized wallet"}),b.jsx("span",{className:"authorize-wallet-why-icon","aria-hidden":"true",children:"?"})]}),v&&gg.createPortal(b.jsxs("div",{className:"authorize-wallet-why-tooltip",role:"tooltip",style:{top:v.top,left:v.left},children:[b.jsxs("p",{children:["Your AntSeed signer lives on this node and authorizes spending, but it never holds USDC or ANTS. To ",b.jsx("strong",{children:"withdraw funds"}),","," ",b.jsx("strong",{children:"claim ANTS rewards"}),", or"," ",b.jsx("strong",{children:"close a channel"}),", you need to designate an external wallet that the contracts will trust."]}),b.jsxs("p",{children:["Without an authorized wallet, if you lose access to this node (deleted"," ",b.jsx("code",{children:".antseed"})," directory, lost machine, etc.) your funds are"," ",b.jsx("strong",{children:"unrecoverable"}),". Set this now to keep your funds safe."]})]}),document.body),l?b.jsxs("div",{className:"authorize-wallet-connect",children:[b.jsx("div",{className:"authorize-wallet-step-label",children:"Connected wallet"}),b.jsx("div",{className:"authorize-wallet-addr",children:a})]}):b.jsxs("div",{className:"authorize-wallet-connect",children:[b.jsx("div",{className:"authorize-wallet-step-label",children:"Step 1 — Connect a wallet"}),b.jsx(Ya,{children:({openConnectModal:I,ready:S,connected:j})=>j?null:b.jsx(En,{fullWidth:!0,onClick:I,disabled:!S,children:"Connect wallet"})})]}),b.jsxs("div",{className:"authorize-wallet-actions",children:[b.jsx(En,{fullWidth:!0,onClick:()=>void d(),disabled:!l||f||!t,children:f?"Authorizing…":"Authorize this wallet"}),b.jsx("button",{type:"button",className:"btn-link",onClick:r,disabled:f,children:n?"Cancel":"Later"})]}),p&&b.jsx("div",{className:"status-msg status-error",children:p})]})})}const wU="0x0000000000000000000000000000000000000000",NE=P.createContext(null);function Ai(){const e=P.useContext(NE);if(!e)throw new Error("useAuthorizedWallet must be used inside <AuthorizedWalletProvider>");return e}function bU({config:e,children:t}){const[n,r]=P.useState(null),[s,a]=P.useState(null),[c,l]=P.useState(!1),d=P.useRef(null),[f,h]=P.useState(!1),p=P.useCallback(async()=>{try{const A=await rF();r(A.operator),a(A.operator!==wU)}catch{}},[]);P.useEffect(()=>{p()},[p]);const m=P.useCallback(A=>{if(s!==!1){A&&A();return}d.current=A??null,l(!0)},[s]),y=P.useCallback(()=>{l(!1),d.current=null},[]),v=P.useCallback(async()=>{await p();const A=d.current;d.current=null,l(!1),A&&A()},[p]),w=P.useCallback(()=>h(!0),[]),C=P.useMemo(()=>({operator:n,operatorSet:s,refetch:p,requireAuthorization:m,bannerDismissed:f,dismissBanner:w}),[n,s,p,m,f,w]);return b.jsxs(NE.Provider,{value:C,children:[t,b.jsx(vU,{isOpen:c,config:e,hasPendingAction:d.current!==null,onClose:y,onAuthorized:v})]})}function I2({label:e,children:t,variant:n="default"}){const r=P.useRef(null),[s,a]=P.useState(null),c=()=>{var y;const d=(y=r.current)==null?void 0:y.getBoundingClientRect();if(!d)return;const f=d.left+d.width/2,h=340,p=16,m=Math.min(Math.max(p,f-h/2),window.innerWidth-h-p);a({top:d.bottom+8,left:m})},l=()=>a(null);return b.jsxs(b.Fragment,{children:[b.jsxs("div",{ref:r,className:`info-hint${n==="warn"?" info-hint--warn":""}${e?"":" info-hint--icon-only"}`,tabIndex:0,onMouseEnter:c,onMouseLeave:l,onFocus:c,onBlur:l,children:[e&&b.jsx("span",{children:e}),b.jsx("span",{className:"info-hint-icon","aria-hidden":"true",children:"?"})]}),s&&gg.createPortal(b.jsx("div",{className:"info-hint-tooltip",role:"tooltip",style:{top:s.top,left:s.left},children:t}),document.body)]})}const xU="0x0000000000000000000000000000000000000000";function N2(){return b.jsxs("svg",{width:"13",height:"13",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:[b.jsx("rect",{x:"5.5",y:"5.5",width:"8",height:"8",rx:"1.5",stroke:"currentColor",strokeWidth:"1.3"}),b.jsx("path",{d:"M3 10.5V3.5C3 2.67 3.67 2 4.5 2H10.5",stroke:"currentColor",strokeWidth:"1.3",strokeLinecap:"round"})]})}function Wp(){return b.jsx("svg",{width:"13",height:"13",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:b.jsx("path",{d:"M3.5 8.5L6.5 11.5L12.5 5",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"})})}function CU(){const[e,t]=P.useState(null),n=P.useCallback(async(r,s)=>{try{await navigator.clipboard.writeText(r),t(s),window.setTimeout(()=>t(a=>a===s?null:a),1400)}catch{}},[]);return{copied:e,copy:n}}function EU({isOpen:e,onClose:t,balance:n,config:r,buyerEvmAddress:s,onOpenDeposit:a,onOpenWithdraw:c}){const{address:l,isConnected:d,connector:f}=it(),{disconnect:h}=ou(),{copied:p,copy:m}=CU(),y=d&&!!l,{operator:v,operatorSet:w,refetch:C}=Ai(),A=w===null,I=V8(r,C),S=NF(r,C),[j,N]=P.useState(""),[T,B]=P.useState(!1);P.useEffect(()=>{e&&C()},[e,C]),P.useEffect(()=>{e||(B(!1),N(""),S.reset())},[e]);const O=!!(v&&v.toLowerCase()!==xU),R=!!(O&&y&&l&&v&&v.toLowerCase()===l.toLowerCase()),W=n?parseFloat(n.available):0,H=n?parseFloat(n.reserved):0,K=n?parseFloat(n.total):0;return b.jsxs(uU,{closeLabel:"Close wallet",eyebrow:"Wallet",isOpen:e,onClose:t,side:"right",title:"Accounts & balances",children:[b.jsxs("section",{className:"wallet-panel-section",children:[b.jsx("div",{className:"wallet-panel-section-label",children:"Your AntSeed account"}),b.jsx("div",{className:"wallet-panel-card",children:b.jsxs("div",{className:"wallet-panel-card-row",children:[b.jsxs("div",{className:"wallet-panel-role",children:[b.jsx("span",{className:"wallet-panel-role-dot wallet-panel-role-dot--signer"}),"Signer",b.jsx(I2,{children:b.jsx("p",{children:"Your signer authorizes spending from your AntSeed account — it never holds USDC itself. The balance lives in the AntseedDeposits contract, tracked under this address. Your signer never needs gas."})})]}),b.jsxs("button",{type:"button",className:`wallet-panel-addr${p==="buyer"?" wallet-panel-addr--copied":""}`,onClick:()=>s&&m(s,"buyer"),disabled:!s,title:s??"",children:[b.jsx("span",{className:"wallet-panel-addr-value",children:s?nr(s):"—"}),b.jsx("span",{className:"wallet-panel-addr-icon",children:p==="buyer"?b.jsx(Wp,{}):b.jsx(N2,{})})]})]})}),b.jsxs("div",{className:"wallet-panel-balances",children:[b.jsxs("div",{className:"wallet-panel-balance",children:[b.jsx("span",{className:"wallet-panel-balance-label",children:"Available"}),b.jsxs("span",{className:"wallet-panel-balance-value",children:["$",vt(W)]})]}),b.jsxs("div",{className:"wallet-panel-balance",children:[b.jsx("span",{className:"wallet-panel-balance-label",children:"Reserved"}),b.jsxs("span",{className:"wallet-panel-balance-value",children:["$",vt(H)]})]}),b.jsxs("div",{className:"wallet-panel-balance",children:[b.jsx("span",{className:"wallet-panel-balance-label",children:"Total"}),b.jsxs("span",{className:"wallet-panel-balance-value",children:["$",vt(K)]})]})]}),b.jsxs("div",{className:"wallet-panel-actions",children:[b.jsx(En,{variant:"primary",fullWidth:!0,onClick:a,children:"Deposit"}),b.jsx(En,{variant:"outline",fullWidth:!0,onClick:c,children:"Withdraw"})]})]}),b.jsxs("section",{className:"wallet-panel-section",children:[b.jsx("div",{className:"wallet-panel-section-label",children:"Your wallet"}),y?b.jsxs("div",{className:"wallet-panel-card",children:[b.jsxs("div",{className:"wallet-panel-card-row",children:[b.jsxs("div",{className:"wallet-panel-role",children:[b.jsx("span",{className:"wallet-panel-role-dot wallet-panel-role-dot--connected"}),"Connected"]}),b.jsxs("button",{type:"button",className:`wallet-panel-addr${p==="operator"?" wallet-panel-addr--copied":""}`,onClick:()=>l&&m(l,"operator"),title:l??"",children:[b.jsx("span",{className:"wallet-panel-addr-value",children:l?nr(l):"—"}),b.jsx("span",{className:"wallet-panel-addr-icon",children:p==="operator"?b.jsx(Wp,{}):b.jsx(N2,{})})]})]}),b.jsxs("div",{className:"wallet-panel-meta",children:[b.jsx("span",{className:"wallet-panel-meta-label",children:"Provider"}),b.jsx("span",{className:"wallet-panel-meta-value",children:(f==null?void 0:f.name)??"Unknown"})]}),b.jsx("div",{className:"wallet-panel-operator-status",children:A?b.jsx("span",{className:"wallet-panel-pill wallet-panel-pill--muted",children:"Checking authorization…"}):R?b.jsx(b.Fragment,{children:b.jsxs("span",{className:"wallet-panel-pill wallet-panel-pill--ok",children:[b.jsx(Wp,{})," Authorized for withdrawals"]})}):O?b.jsxs("div",{className:"wallet-panel-warn",children:[b.jsx("div",{className:"wallet-panel-warn-title",children:"Wrong wallet connected"}),b.jsxs("div",{className:"wallet-panel-warn-desc",children:["Switch to ",b.jsx("strong",{children:v?nr(v):""})," in your wallet app to withdraw, claim ANTS, and close channels."]})]}):null}),!R&&!A&&!O&&b.jsxs("div",{className:"wallet-panel-authorize-row",children:[b.jsx("button",{type:"button",className:"wallet-panel-link wallet-panel-link--accent",onClick:()=>void I.run(),disabled:I.running||!r,children:I.running?"Authorizing…":"Authorize this wallet"}),b.jsx(I2,{variant:"warn",children:b.jsx("p",{children:"Without an authorized wallet you cannot withdraw USDC, claim ANTS, or close channels. If you lose access to this node, your funds become unrecoverable. Authorize this wallet to keep your funds safe."})})]}),R&&!T&&b.jsx("button",{type:"button",className:"wallet-panel-link",onClick:()=>B(!0),children:"Transfer authorization to another wallet"}),R&&T&&b.jsxs("div",{className:"wallet-panel-section",children:[b.jsx("div",{className:"wallet-panel-section-label",children:"Transfer to"}),b.jsx(mU,{type:"text",placeholder:"0x...",value:j,onChange:Q=>N(Q.target.value),disabled:S.running}),b.jsx(En,{variant:"danger",onClick:()=>s&&void S.run(s,j),disabled:S.running||!j||!s,children:S.running?"Transferring…":"Transfer authorization"}),S.error&&b.jsx("div",{className:"wallet-panel-error",children:S.error})]}),I.error&&b.jsx("div",{className:"wallet-panel-error",children:I.error}),b.jsx("button",{type:"button",className:"wallet-panel-link",onClick:()=>h(),children:"Disconnect"})]}):b.jsxs("div",{className:"wallet-panel-card",children:[b.jsxs("div",{className:"wallet-panel-role",children:[b.jsx("span",{className:"wallet-panel-role-dot wallet-panel-role-dot--disconnected"}),"Not connected"]}),b.jsx("p",{className:"wallet-panel-explainer",children:"Connect a wallet to receive withdrawals, claim ANTS rewards, and submit on-chain actions for your account. Deposits from any wallet fund your AntSeed account above."}),b.jsx("div",{className:"wallet-panel-connect-wrap",children:b.jsx(Ya,{children:({openConnectModal:Q,ready:ae,connected:q})=>q?null:b.jsx(En,{onClick:Q,disabled:!ae,children:"Connect wallet"})})})]}),b.jsx("p",{className:"wallet-panel-footnote",children:"Deposits can come from any wallet and fund your AntSeed account. Withdrawals are sent to the wallet you authorize here."})]})]})}function $p(e,t){return e?t===8453?`https://basescan.org/tx/${e}`:t===84532?`https://sepolia.basescan.org/tx/${e}`:null:null}const AU=1,P2=[10,25,50,100];function kU(e){try{return y3(e||"0",6)}catch{return 0n}}const SU=[{name:"deposit",type:"function",stateMutability:"nonpayable",inputs:[{name:"buyer",type:"address"},{name:"amount",type:"uint256"}],outputs:[]}],qp=[{name:"balanceOf",type:"function",stateMutability:"view",inputs:[{name:"account",type:"address"}],outputs:[{name:"",type:"uint256"}]},{name:"approve",type:"function",stateMutability:"nonpayable",inputs:[{name:"spender",type:"address"},{name:"amount",type:"uint256"}],outputs:[{name:"",type:"bool"}]},{name:"allowance",type:"function",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"spender",type:"address"}],outputs:[{name:"",type:"uint256"}]}];function PE({config:e,balance:t,buyerAddress:n,onDeposited:r}){return b.jsx("div",{className:"dv",children:b.jsx(jU,{config:e,balance:t,buyerAddress:n,onDeposited:r})})}function jU({config:e,balance:t,buyerAddress:n,onDeposited:r}){const{address:s,isConnected:a}=it(),c=a&&!!s,l=Ci(),[d,f]=P.useState(""),[h,p]=P.useState(null),[m,y]=P.useState("idle"),[v,w]=P.useState(null),[C,A]=P.useState(null),[I,S]=P.useState(!1),[j,N]=P.useState(null),[T,B]=P.useState(!1),[O,R]=P.useState(""),[W,H]=P.useState(!1),K=Yc(t==null?void 0:t.total),Q=Yc(t==null?void 0:t.creditLimit),ae=t!==null,q=ae?Math.max(0,Q-K):0,ee=K===0,te=ee?AU:0,{expectedChainId:U,targetChainName:Y,walletChainId:Z,wrongChain:F,isSwitchingChain:X,ensureCorrectNetwork:pe}=ws(e),ne=n??s;P.useEffect(()=>{W||!ne||R(ne)},[W,ne]);const oe=O.trim(),fe=/^0x[a-fA-F0-9]{40}$/.test(oe),ge=T&&oe!==""&&!fe,Ie=T&&fe?oe:ne,Be=T&&fe&&!!ne&&oe.toLowerCase()!==(ne==null?void 0:ne.toLowerCase()),{data:Le,refetch:_e,isLoading:Te,isFetching:dt}=f6({address:e==null?void 0:e.usdcContractAddress,abi:qp,functionName:"balanceOf",chainId:U,args:[s],query:{enabled:c&&!!e&&!!s}}),tt=Le===void 0?null:Number.parseFloat(qr(Le,6)),ft=tt!==null&&Number.isFinite(tt),ze=Math.max(0,Math.min(q,ft?tt:q));P.useEffect(()=>{if(d!==""||!t)return;const Ve=ze>=10?"10":ze>0?y2(ze):"";if(Ve){f(Ve);const $t=[10,25,50,100].find(jo=>jo===Number(Ve));$t&&p($t)}},[t,Le]);const ht=d?Number.parseFloat(d):0;let Ze=null;d!==""&&t&&(!Number.isFinite(ht)||ht<=0?Ze="Enter a valid amount":/^\d+(\.\d{0,6})?$/.test(d.trim())?ht<te?Ze=`Minimum first deposit is ${te} USDC`:ft?ht>q?Ze=q<=0?"You have reached your credit limit":`You already have $${vt(K)} in AntSeed. You can add $${vt(q)} more.`:ft&&ht>tt&&(Ze=`Your connected wallet only has ${vt(tt)} USDC available.`):Ze="Loading your connected wallet USDC balance…":Ze="USDC supports up to 6 decimal places");const gt=d!==""&&!Ze&&ht>0,{data:It,refetch:qn,isLoading:Sr,isFetching:ir}=f6({address:e==null?void 0:e.usdcContractAddress,abi:qp,functionName:"allowance",chainId:U,args:[s,e==null?void 0:e.depositsContractAddress],query:{enabled:c&&!!e&&!!s}}),Xt=kU(d),bs=It!==void 0,xs=Sr||ir||m==="checking-allowance",Nn=bs&&It>=Xt&&Xt>0n,Pn=gt&&bs&&It<Xt,dn=gt&&Nn?2:1,{writeContract:Oe,data:Ue,reset:Ne}=Qr(),{isSuccess:He}=Vr({hash:Ue,chainId:U,query:{enabled:m==="approving"&&!!Ue}}),{writeContract:Bn,data:at,reset:Fe}=Qr(),{isSuccess:ke}=Vr({hash:at,chainId:U,query:{enabled:m==="depositing"&&!!at}});P.useEffect(()=>{m!=="approving"||!He||(y("checking-allowance"),qn())},[m,He,qn]),P.useEffect(()=>{m==="checking-allowance"&&Nn&&y("idle")},[m,Nn]),P.useEffect(()=>{m!=="depositing"||!ke||(N(at??null),y("done"),r())},[ke,m]);const Wt=P.useCallback(Ve=>{f(Ve);const $t=Number.parseFloat(Ve);if(Number.isFinite($t)){const jo=P2.find(Ir=>Ir===$t);p(jo??null)}else p(null)},[]),jr=P.useCallback(Ve=>{p(Ve),f(Ve==="max"?y2(ze):String(Ve))},[ze]);async function ar(){if(!s||!gt||!e||!Ie)return;w(null),A(null);try{await pe()}catch(Cs){w(Ot(Cs,`Please switch your wallet to ${Y}.`));return}Ne(),Fe();const Ve=await _e(),$t=Ve.data===void 0?null:Number.parseFloat(qr(Ve.data,6));if($t===null||!Number.isFinite($t)){w("Could not check your wallet USDC balance. Please try again.");return}if(ht>$t){w(`Your connected wallet only has ${vt($t)} USDC available.`);return}const Ir=(await qn()).data;if(Ir===void 0){w("Could not check your USDC approval. Please try again.");return}if(Ir>=Xt){y("depositing"),Bn({address:e.depositsContractAddress,abi:SU,functionName:"deposit",chainId:U,args:[Ie,Xt]},{onError:Cs=>{y("idle"),w(Ot(Cs))}});return}y("approving"),Oe({address:e.usdcContractAddress,abi:qp,functionName:"approve",chainId:U,args:[e.depositsContractAddress,Xt]},{onError:Cs=>{y("idle"),w(Ot(Cs))}})}function So(){y("idle"),w(null),A(null),S(!1),N(null),Ne(),Fe(),f(""),p(null)}const Ja=j?$p(j,U??l):null,_n=m==="approving"||m==="depositing"||m==="checking-allowance",ki=Te||dt,lu=Sr||ir;if(m==="done")return b.jsxs("div",{className:"dv-success",children:[b.jsx("div",{className:"dv-success-icon","aria-hidden":"true",children:"✓"}),b.jsx("div",{className:"dv-success-title",children:"Deposit confirmed!"}),b.jsxs("div",{className:"dv-success-amount",children:["$",vt(ht)," USDC"]}),b.jsx("div",{className:"dv-success-note",children:"The transaction confirmed. Your balance will refresh from the payments server."}),j&&b.jsx("div",{className:"dv-success-hash",children:Ja?b.jsxs("a",{href:Ja,target:"_blank",rel:"noopener noreferrer",className:"dv-success-hash-link",children:[j.slice(0,10),"…",j.slice(-8),b.jsx("span",{className:"dv-success-hash-arrow","aria-hidden":"true",children:"↗"})]}):b.jsxs("span",{children:[j.slice(0,10),"…",j.slice(-8)]})}),b.jsx("button",{className:"dv-btn-outline",onClick:So,children:"Add more funds"})]});if(!c)return b.jsxs("div",{className:"dv-form",children:[b.jsx("div",{className:"dv-connect-hint",children:"Connect a wallet so AntSeed can check whether you already approved USDC. If you have, this wizard will jump directly to step 2."}),b.jsx(Ya,{className:"dv-btn-primary"})]});const uu=X?`Switching to ${Y}...`:F?`Switch to ${Y}`:ki||!ft?"Loading wallet USDC...":xs?"Checking approval...":m==="approving"?"Approve USDC in wallet...":m==="depositing"?"Depositing...":Pn?`Step 1: Approve ${d||"0"} USDC`:"Step 2: Deposit USDC",Za=_n||!gt||!e||X||ge||!Ie||lu||ki||!ft;return b.jsxs("div",{className:"dv-form",children:[F&&b.jsxs("div",{className:"dv-chain-warn",role:"alert",children:["Wallet is on chain ",Z??l,". Switch to ",Y," to continue."]}),b.jsxs("div",{className:"dv-amount-block",children:[b.jsx("label",{className:"dv-amount-label",htmlFor:"dv-amount-input",children:"Amount to add"}),b.jsxs("div",{className:`dv-amount-field${d&&Ze?" dv-amount-field--error":""}`,children:[b.jsx("span",{className:"dv-amount-cur","aria-hidden":"true",children:"$"}),b.jsx("input",{id:"dv-amount-input",className:"dv-amount-input",type:"number",inputMode:"decimal",min:te||0,max:ze||void 0,step:"0.01",placeholder:ee?"10.00":"0.00",value:d,onChange:Ve=>Wt(Ve.target.value),disabled:_n,"aria-describedby":"dv-amount-hint",autoFocus:!0}),b.jsx("span",{className:"dv-amount-unit","aria-hidden":"true",children:"USDC"})]}),b.jsxs("div",{className:"dv-chips",role:"group","aria-label":"Quick amount",children:[P2.map(Ve=>b.jsxs("button",{type:"button",className:`dv-chip${h===Ve?" dv-chip--active":""}${Ve>ze&&ze>0?" dv-chip--disabled":""}`,onClick:()=>jr(Ve),disabled:_n||Ve>ze&&ze>0,"aria-pressed":h===Ve,children:["$",Ve]},Ve)),b.jsx("button",{type:"button",className:`dv-chip${h==="max"?" dv-chip--active":""}${ze<=0?" dv-chip--disabled":""}`,onClick:()=>jr("max"),disabled:_n||ze<=0,"aria-pressed":h==="max",children:"Max"})]}),b.jsxs("div",{id:"dv-amount-hint",className:"dv-wallet-hint",children:[ki&&!ft?b.jsx("span",{className:"dv-wallet-hint-loading",children:"Loading wallet balance…"}):ft&&s?b.jsxs("span",{children:[b.jsx("span",{className:"dv-wallet-hint-addr",children:nr(s)})," · ",b.jsxs("strong",{className:"dv-wallet-hint-bal",children:["$",vt(tt??0)," USDC"]})," available in wallet"]}):null,ae&&q<(tt??1/0)&&q>0&&b.jsxs("span",{className:"dv-wallet-hint-limit",children:[" · ","$",vt(q)," deposit headroom"]})]}),Ze&&b.jsx("div",{className:"dv-validation-error",role:"alert",children:Ze})]}),b.jsxs("div",{className:"dv-target",children:[b.jsx("button",{type:"button",className:"dv-target-toggle",onClick:()=>B(Ve=>!Ve),"aria-expanded":T,"aria-controls":"dv-target-panel",disabled:_n,children:"Different AntSeed address"}),T&&b.jsxs("div",{id:"dv-target-panel",className:"dv-target-panel",children:[b.jsx("input",{className:`dv-target-input${ge?" dv-target-input--error":""}`,type:"text",spellCheck:!1,autoComplete:"off",placeholder:ne??"0x...",value:O,onChange:Ve=>{H(!0),R(Ve.target.value)},disabled:_n}),b.jsx("div",{className:`dv-target-note${ge?" dv-target-note--error":""}`,children:ge?"Enter a valid 0x… address (42 chars).":Be?`Crediting ${nr(oe,6,4,"...")}.`:"Credits go to this AntSeed account via the Deposits contract."})]})]}),b.jsx("div",{className:"dv-direct-warning",role:"note",children:"Do not send USDC directly to your AntSeed address. It will not be credited. Use this deposit flow so funds go through the AntSeed Deposits contract."}),b.jsxs("div",{className:"dv-steps","aria-label":"Deposit steps",children:[b.jsxs("div",{className:`dv-step${Nn?" dv-step--done":dn===1?" dv-step--active":""}`,children:[b.jsx("span",{className:"dv-step-dot","aria-hidden":"true",children:Nn?"✓":"1"}),b.jsx("span",{className:"dv-step-label",children:Nn?"Already approved. You can skip straight to step 2.":m==="approving"?"Confirm approval in your wallet. This does not move funds.":m==="checking-allowance"?"Checking your existing approval on-chain…":`Permit AntSeed's Deposits contract to use ${d||"your chosen amount"} USDC. Approval only grants permission.`})]}),b.jsxs("div",{className:`dv-step${dn===2&&!_n||m==="depositing"?" dv-step--active":""}`,children:[b.jsx("span",{className:"dv-step-dot","aria-hidden":"true",children:"2"}),b.jsx("span",{className:"dv-step-label",children:m==="depositing"?"Confirm the deposit transaction. This moves USDC into your AntSeed balance.":dn===2?"Approval detected. The next click deposits USDC into your AntSeed balance.":"Locked until approval is confirmed."})]})]}),b.jsx("button",{className:"dv-btn-primary",onClick:ar,disabled:Za,"aria-busy":_n,children:uu}),Pn&&!_n&&b.jsx("div",{className:"dv-approve-note",children:"Approves only this deposit amount. After approval confirms, confirm the deposit."}),!Pn&&gt&&!_n&&b.jsx("div",{className:"dv-confirm-note",children:"Wallet confirmation required."}),b.jsx("div",{className:"dv-help",children:"Funds credit your available balance right after the transaction confirms. Withdraw unused funds anytime."}),v&&b.jsxs("div",{className:"dv-error",role:"alert",children:[b.jsxs("div",{className:"dv-error-summary",children:[b.jsx("span",{children:v}),C&&b.jsx("button",{type:"button",className:"dv-error-toggle",onClick:()=>S(Ve=>!Ve),"aria-expanded":I,children:I?"Hide detail":"Show detail"})]}),I&&C&&b.jsx("div",{className:"dv-error-detail",children:C}),at&&b.jsx("div",{className:"dv-error-hash",children:$p(at,U??l)?b.jsx("a",{href:$p(at,U??l),target:"_blank",rel:"noopener noreferrer",className:"dv-error-hash-link",children:"View tx ↗"}):b.jsxs("span",{className:"dv-error-hash-raw",children:[at.slice(0,18),"…"]})})]})]})}function IU(){return b.jsx("svg",{width:"14",height:"14",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",children:b.jsx("path",{d:"M4 4L12 12M12 4L4 12",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round"})})}function NU(){return b.jsxs("svg",{width:"64",height:"64",viewBox:"0 0 64 64",fill:"none","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",children:[b.jsx("circle",{cx:"32",cy:"32",r:"30",fill:"var(--accent-dim)",stroke:"var(--accent)",strokeWidth:"2"}),b.jsx("path",{d:"M20 33L28.5 41.5L44.5 23",stroke:"var(--accent)",strokeWidth:"3.5",strokeLinecap:"round",strokeLinejoin:"round"})]})}function PU({phase:e,config:t,balance:n,buyerAddress:r,onDeposited:s,onContinue:a,onDismissDeposit:c}){const[l,d]=P.useState(!1),f=e!==null;return IE(f),f?b.jsx("div",{className:"empty-state-overlay",role:"dialog","aria-label":"Get started",children:b.jsx("div",{className:"empty-state-card",children:e==="deposit"?b.jsxs(b.Fragment,{children:[c&&b.jsx("button",{type:"button",className:"empty-state-close",onClick:c,"aria-label":"Close deposit prompt",children:b.jsx(IU,{})}),b.jsxs("div",{className:"empty-state-header",children:[b.jsx("div",{className:"empty-state-eyebrow",children:"Welcome to AntSeed"}),b.jsx("h2",{className:"empty-state-title",children:"Fund your AntSeed account"}),b.jsx("p",{className:"empty-state-subtitle",children:"Deposit USDC to start routing requests across the network. Your AntSeed signer authorizes spending from the account — it never holds funds itself."})]}),b.jsxs("div",{className:"empty-state-step",children:[b.jsx("div",{className:"empty-state-step-label",children:"Step 1 · Deposit USDC"}),b.jsx(PE,{config:t,balance:n,buyerAddress:r,onDeposited:s})]})]}):b.jsxs("div",{className:"empty-state-success",children:[b.jsx("div",{className:"empty-state-success-icon",children:b.jsx(NU,{})}),b.jsx("h2",{className:"empty-state-title",children:"You're all set"}),b.jsx("p",{className:"empty-state-subtitle",children:"Your deposit is in. AntSeed will now route requests across the network — you only pay for what you use."}),b.jsx("div",{className:"empty-state-success-actions",children:b.jsx(En,{fullWidth:!0,onClick:a,children:"Continue"})})]})})}):null}function BU({isVisible:e,error:t=!1,onRetry:n}){return IE(e),e?t?b.jsx("div",{className:"loader-overlay",role:"alert","aria-live":"assertive",children:b.jsxs("div",{className:"loader-overlay-card loader-overlay-card--error",children:[b.jsx("p",{className:"loader-overlay-error-text",children:"Can’t reach the payments server. Retrying…"}),n&&b.jsx("button",{type:"button",className:"loader-overlay-retry",onClick:n,children:"Retry now"})]})}):b.jsx("div",{className:"loader-overlay",role:"status","aria-live":"polite","aria-label":"Loading",children:b.jsx("div",{className:"loader-overlay-card",children:b.jsx("div",{className:"loader-overlay-spinner"})})}):null}const _U=Eo(["function withdraw(address buyer, uint256 amount) external"]);function TU(e,t){const[n,r]=P.useState(!1),[s,a]=P.useState(null),{expectedChainId:c,ensureCorrectNetwork:l}=ws(e),{writeContract:d,data:f,reset:h}=Qr(),{isSuccess:p}=Vr({hash:f,chainId:c});P.useEffect(()=>{p&&n&&(r(!1),t==null||t())},[p,n,t]);const m=P.useCallback(async(v,w)=>{if(!(e!=null&&e.depositsContractAddress)){a("Payments contract is not configured.");return}if(!/^0x[0-9a-fA-F]{40}$/.test(v)){a("Invalid buyer address.");return}const C=Number(w);if(!Number.isFinite(C)||C<=0){a("Enter a valid amount.");return}let A;try{A=y3(w,6)}catch{a("Invalid amount.");return}if(A<=0n){a("Enter a valid amount.");return}a(null),r(!0),h();try{await l(),d({address:e.depositsContractAddress,abi:_U,functionName:"withdraw",chainId:c,args:[v,A]},{onError:I=>{r(!1),a(Ot(I))}})}catch(I){r(!1),a(Ot(I,"Failed to withdraw"))}},[e,l,c,d,h]),y=P.useCallback(()=>{a(null),r(!1),h()},[h]);return{run:m,running:n,success:p,error:s,reset:y,txHash:f}}const OU="0x0000000000000000000000000000000000000000";function RU({config:e,balance:t,onAction:n}){const[r,s]=P.useState(""),{address:a,isConnected:c}=it(),l=c&&!!a,{requireAuthorization:d,operator:f}=Ai(),{targetChainName:h,walletChainId:p,wrongChain:m,isSwitchingChain:y}=ws(e),{run:v,running:w,success:C,error:A,reset:I,txHash:S}=TU(e,()=>{n()});if(!t)return b.jsxs("div",{className:"card",children:[b.jsx("div",{className:"card-section-title",children:"Withdraw"}),b.jsx("div",{className:"withdraw-loading",children:"Loading..."})]});const j=parseFloat(t.available),N=(e==null?void 0:e.evmAddress)??t.evmAddress,B=!!(l&&(!!f&&f!==OU)&&a&&a.toLowerCase()!==f.toLowerCase()),O=r?parseFloat(r):0,R=Number.isFinite(O)&&O>0&&O<=j;function W(){N&&d(async()=>{I(),await v(N,r)})}function H(){s(""),I()}return b.jsx("div",{className:"withdraw",children:b.jsxs("div",{className:"card",children:[b.jsx("div",{className:"card-section-title",children:"Withdraw USDC"}),b.jsx("div",{className:"wallet-role-hint",children:"Withdrawals are sent to your authorized wallet. You'll be prompted to authorize one if you haven't already."}),C?b.jsxs("div",{className:"deposit-success",children:[b.jsx("div",{className:"deposit-success-icon",children:"✓"}),b.jsx("div",{className:"deposit-success-title",children:"Withdrawal confirmed!"}),S&&b.jsxs("div",{className:"deposit-success-hash",children:[S.slice(0,18),"..."]}),b.jsxs("div",{className:"deposit-success-note",children:["Funds were sent to ",a?nr(a,6,4,"..."):"your authorized wallet","."]}),b.jsx(En,{fullWidth:!0,variant:"outline",onClick:H,style:{marginTop:12},children:"Withdraw more"})]}):l?b.jsxs(b.Fragment,{children:[b.jsxs("div",{className:"deposit-connected",children:[b.jsx("div",{className:"deposit-connected-dot"}),b.jsx("span",{className:"deposit-connected-addr",children:a?nr(a,6,4,"..."):""}),b.jsx("span",{className:"deposit-connected-label",children:"Connected"})]}),m&&b.jsxs("div",{className:"status-msg",style:{marginTop:0,marginBottom:16},children:["Wallet is on chain ",p??"unknown",". Switch to ",h," before withdrawing."]}),B&&f&&b.jsxs("div",{className:"status-msg status-error",role:"alert",style:{marginBottom:16},children:["This account is authorized to ",b.jsx("strong",{children:nr(f,6,4,"...")}),". Connect that wallet to withdraw, or transfer authorization to the connected wallet first."]}),b.jsxs("div",{className:"withdraw-request",children:[b.jsxs("div",{className:"input-group",children:[b.jsx("label",{className:"input-label",children:"Amount (USDC)"}),b.jsx("input",{className:"input-field",type:"number",min:"0",step:"0.01",placeholder:"0.00",value:r,onChange:K=>s(K.target.value),disabled:w}),b.jsxs("span",{className:"hint",children:["Available: $",vt(j)," USDC"]})]}),b.jsx(En,{fullWidth:!0,onClick:W,disabled:w||y||!R||!N||B||!e,children:y?`Switching to ${h}...`:m?`Switch to ${h}`:w?"Processing...":"Withdraw"})]})]}):b.jsx("div",{className:"deposit-connect-wrapper",children:b.jsx(Ya,{children:({openConnectModal:K,ready:Q,connected:ae})=>ae?null:b.jsx(En,{fullWidth:!0,onClick:K,disabled:!Q,children:"Connect Wallet"})})}),A&&b.jsx("div",{className:"status-msg status-error",children:A})]})})}const BE=["function requestClose(bytes32 channelId) external","function withdraw(bytes32 channelId) external","function channels(bytes32 channelId) external view returns (address buyer, address seller, uint128 deposit, uint128 settled, bytes32 metadataHash, uint256 deadline, uint256 settledAt, uint256 closeRequestedAt, uint8 status)","event Reserved(bytes32 indexed channelId, address indexed buyer, address indexed seller, uint128 maxAmount)","event ChannelClosed(bytes32 indexed channelId, address indexed seller, uint128 finalAmount, uint256 platformFee)","event ChannelWithdrawn(bytes32 indexed channelId, address indexed buyer)","event CloseRequested(bytes32 indexed channelId, address indexed buyer)"],MU=Eo(BE);function B2(e){try{return BigInt(e)}catch{return 0n}}function _E(e){const[t,n]=P.useState([]),[r,s]=P.useState(!0),a=P.useCallback(async()=>{try{const{channels:y}=await nF();n(y)}catch{n([])}},[]);P.useEffect(()=>{s(!0),a().finally(()=>s(!1))},[a]);const c=P.useMemo(()=>{if(!(e!=null&&e.channelsContractAddress)||!e.evmChainId)return[];const y=e.channelsContractAddress,v=e.evmChainId;return t.map(w=>({address:y,abi:MU,functionName:"channels",args:[w.channelId],chainId:v}))},[t,e==null?void 0:e.channelsContractAddress,e==null?void 0:e.evmChainId]),{data:l,refetch:d,isFetching:f}=B_({contracts:c,query:{enabled:c.length>0,refetchOnWindowFocus:!1}}),{channels:h,history:p}=P.useMemo(()=>{const y=t.map((v,w)=>{const C=l==null?void 0:l[w],A=(C==null?void 0:C.status)==="success"?C.result:null,I=A?A[2]:B2(v.reserveMax),S=A?A[3]:B2(v.cumulativeSigned),j=A?Number(A[7]):0,N=A?Number(A[8]):v.status==="active"?1:2;return{channelId:v.channelId,seller:v.seller,deposit:qr(I,6),settled:qr(S,6),reservedAt:v.reservedAt,deadline:v.deadline,closeRequestedAt:j,status:N}});return{channels:y.filter(v=>v.status===1),history:y.filter(v=>v.status!==1)}},[t,l]),m=P.useCallback(async()=>{s(!0),await a(),s(!1),await d()},[a,d]);return{channels:h,history:p,loading:r||f,refetch:m}}const Ls=864e5,_2={weekday:"short",month:"short",day:"numeric"};function DU(e,t=30){const n=Date.now(),r=n-t*Ls,s=e.filter(f=>f.requestCount>0),a=new Map;for(const f of s){const h=f.updatedAt||f.reservedAt;if(!Number.isFinite(h)||h<=0)continue;const p=Math.floor(h/Ls)*Ls;if(p<r)continue;let m=0;try{m=Number(BigInt(f.inputTokens||"0")+BigInt(f.outputTokens||"0"))}catch{}const y=a.get(p);y?(y.requests+=f.requestCount,y.tokens+=m):a.set(p,{t:p,fullDate:yf(p,_2),requests:f.requestCount,tokens:m})}const c=Math.floor(n/Ls)*Ls,l=c-(t-1)*Ls,d=[];for(let f=l;f<=c;f+=Ls)d.push(a.get(f)??{t:f,fullDate:yf(f,_2),requests:0,tokens:0});return d}function FU(e){return e>45?2:e>24?3:6}function LU({channels:e,days:t=30}){const n=P.useMemo(()=>DU(e,t),[e,t]),r=P.useMemo(()=>Math.max(1,...n.map(a=>a.requests)),[n]),s=P.useMemo(()=>{const a=n.reduce((l,d)=>l+d.requests,0),c=n.reduce((l,d)=>l+d.tokens,0);return{requests:a,tokens:c}},[n]);return s.requests===0?b.jsx("div",{className:"usage-chart usage-chart--empty",children:b.jsx("div",{className:"usage-chart-empty-text",children:"No usage yet — start sending requests to see your activity here."})}):b.jsxs("div",{className:"usage-chart",children:[b.jsxs("div",{className:"usage-chart-totbar",children:[b.jsxs("div",{className:"usage-chart-tot",children:["Requests",b.jsx("b",{children:$s(s.requests)})]}),b.jsxs("div",{className:"usage-chart-tot",children:["Tokens",b.jsx("b",{children:ii(s.tokens)})]})]}),b.jsx("div",{className:"portal-spark",role:"img","aria-label":`${t}-day usage chart`,style:{gap:`${FU(n.length)}px`},children:n.map((a,c)=>{const l=a.requests===0?4:Math.max(4,a.requests/r*100),d=Math.max(2,Math.round(n.length*.1)),f=c<d?" portal-spark-col--start":c>=n.length-d?" portal-spark-col--end":"";return b.jsxs("div",{className:`portal-spark-col${f}`,children:[b.jsx("div",{className:"portal-spark-bar",style:{height:`${l}%`}}),b.jsxs("div",{className:"portal-spark-tip",role:"tooltip",children:[b.jsx("b",{children:a.fullDate}),b.jsx("br",{}),"Requests ",b.jsx("span",{className:"acc",children:$s(a.requests)}),b.jsx("br",{}),"Tokens ",b.jsx("span",{className:"acc",children:ii(a.tokens)})]})]},a.t)})})]})}const UU=[],zU=[7,30,90],WU=30;function $U(e){return e.status===2?"Settled":e.status===3?"Timed out":e.status===0?"Closed":e.closeRequestedAt>0?"Closing":"Active"}function qU({config:e,balance:t,onOpenDeposit:n,onOpenWithdraw:r,onOpenActivity:s}){const{channels:a,history:c}=_E(e),[l,d]=P.useState(null),[f,h]=P.useState(!1),[p,m]=P.useState(null),[y,v]=P.useState(!1),[w,C]=P.useState(WU),A=(e==null?void 0:e.networkStatsUrl)??null;P.useEffect(()=>{let R=!1;return lF().then(W=>{R||(d(W),h(!1))}).catch(()=>{R||h(!0)}),()=>{R=!0}},[]),P.useEffect(()=>{if(!A){m(null),v(!1);return}let R=!1;return uF(A).then(W=>{R||(m(W),v(!1))}).catch(()=>{R||(m(null),v(!0))}),()=>{R=!0}},[A]);const I=vt(t==null?void 0:t.available),S=vt(t==null?void 0:t.reserved),j=vt(t==null?void 0:t.total),N=aa(p==null?void 0:p.totals.totalInputTokens)+aa(p==null?void 0:p.totals.totalOutputTokens),T=aa(l==null?void 0:l.totalInputTokens)+aa(l==null?void 0:l.totalOutputTokens),B=(l==null?void 0:l.channels)??UU,O=P.useMemo(()=>[...a,...c].slice().sort((R,W)=>Xm(W.reservedAt)-Xm(R.reservedAt)).slice(0,3),[a,c]);return b.jsxs("div",{className:"portal-overview",children:[f&&b.jsxs("div",{className:"portal-inline-warning",children:[b.jsx("span",{"aria-hidden":"true"}),"Usage data is unavailable."]}),b.jsx("section",{className:"overview-balance",children:b.jsxs("div",{className:"overview-balance-main",children:[b.jsx("div",{className:"portal-kicker",children:"Available balance"}),b.jsxs("div",{className:"overview-balance-value",children:["$",I,b.jsx("span",{children:"USDC"})]}),b.jsxs("p",{children:["$",j," total · $",S," in ",(l==null?void 0:l.activeChannels)??0," active channels"]}),b.jsxs("div",{className:"overview-actions",children:[b.jsx("button",{type:"button",className:"portal-primary-btn",onClick:n,children:"Deposit"}),b.jsx("button",{type:"button",className:"portal-secondary-btn",onClick:r,children:"Withdraw"})]})]})}),b.jsxs("section",{className:"overview-section","aria-labelledby":"overview-usage-title",children:[b.jsxs("div",{className:"overview-section-head",children:[b.jsx("h2",{className:"overview-section-title",id:"overview-usage-title",children:"Your usage"}),b.jsx("p",{children:"Account-level requests, tokens, sellers, and channel activity."})]}),b.jsxs("section",{className:"overview-stat-row","aria-label":"Usage totals",children:[b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Requests (all-time)"}),b.jsx("strong",{children:$s((l==null?void 0:l.totalRequests)??0)})]}),b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Tokens (all-time)"}),b.jsx("strong",{children:ii(T)})]}),b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Sellers used"}),b.jsx("strong",{children:$s((l==null?void 0:l.uniqueSellers)??0)})]}),b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Active channels"}),b.jsx("strong",{children:$s((l==null?void 0:l.activeChannels)??0)})]})]}),b.jsxs("section",{className:"overview-lower-grid",children:[b.jsxs("div",{children:[b.jsxs("div",{className:"usage-head",children:[b.jsx("div",{className:"portal-kicker",children:"Usage · daily"}),b.jsx("div",{className:"usage-window",role:"group","aria-label":"Usage window",children:zU.map(R=>b.jsxs("button",{type:"button",className:`usage-window-opt${w===R?" usage-window-opt--active":""}`,"aria-pressed":w===R,onClick:()=>C(R),children:[R,"D"]},R))})]}),b.jsx(LU,{channels:B,days:w})]}),b.jsxs("div",{className:"overview-recent",children:[b.jsxs("div",{className:"overview-recent-head",children:[b.jsx("div",{className:"portal-kicker",children:"Recent activity"}),b.jsx("button",{type:"button",onClick:s,children:"View all →"})]}),O.length===0?b.jsx("p",{children:"No channel activity yet."}):b.jsx("div",{className:"overview-recent-list",children:O.map(R=>b.jsxs("div",{className:"overview-recent-row",children:[b.jsxs("div",{children:[b.jsx("strong",{children:$U(R)}),b.jsx("span",{children:yf(R.reservedAt)})]}),b.jsxs("div",{children:[b.jsxs("strong",{children:["$",vt(R.settled)]}),b.jsxs("span",{children:["of $",vt(R.deposit)]})]})]},R.channelId))})]})]})]}),(p||A&&y)&&b.jsxs("section",{className:"overview-section overview-section--network","aria-labelledby":"overview-network-title",children:[b.jsxs("div",{className:"overview-section-head",children:[b.jsx("h2",{className:"overview-section-title",id:"overview-network-title",children:"Network activity"}),b.jsx("p",{children:"Aggregate activity across sellers on the AntSeed network."})]}),p&&b.jsxs("section",{className:"overview-stat-row overview-stat-row--network","aria-label":"Network totals",children:[b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Active peers"}),b.jsx("strong",{children:$s(p.totals.activePeers)})]}),b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Requests"}),b.jsx("strong",{children:ii(aa(p.totals.totalRequests))})]}),b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Tokens"}),b.jsx("strong",{children:ii(N)})]}),b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Settlements"}),b.jsx("strong",{children:$s(p.totals.totalSettlements)})]})]}),A&&y&&b.jsxs("div",{className:"portal-inline-warning",children:[b.jsx("span",{"aria-hidden":"true"}),"Network stats unavailable."]})]})]})}const T2=["function claimSellerEmissions(uint256[] epochs) external","function claimBuyerEmissions(address buyer, uint256[] epochs) external"],HU=18;function vr(e){try{return BigInt(e)}catch{return 0n}}function oa(e){try{const t=parseFloat(qr(BigInt(e),HU));return t===0?"0":t<1e-4?"< 0.0001":t.toLocaleString("en-US",{maximumFractionDigits:4})}catch{return"0"}}function ey(e,t){var n;return(n=e==null?void 0:e.params)!=null&&n.initialized?e.params:t??(e==null?void 0:e.params)??null}function wf(e,t,n,r,s){const a=vr(e),c=vr(r),l=vr(s);if(a===0n||l===0n||c===0n)return 0n;const d=a*BigInt(Math.round(t*100))/10000n,f=d*c/l,h=d*BigInt(Math.round(n*100))/10000n;return f>h?h:f}function TE(e,t){const n=ey(e,t);if(!n)return"0";const r=wf(e.epochEmission,n.sellerSharePct,n.maxSellerSharePct,e.seller.userPoints,e.seller.totalPoints),s=wf(e.epochEmission,n.buyerSharePct,n.maxBuyerSharePct,e.buyer.userPoints,e.buyer.totalPoints);return(r+s).toString()}function VU(e,t){if(!e)return 0;const n=vr(e.epochEmission);if(n===0n)return 0;const r=vr(TE(e,t));return Number(r*10000n/n)/100}function OE(e,t){const n=ey(e,t);if(!n)return 0n;let r=0n;return e.seller.claimed&&(r+=wf(e.epochEmission,n.sellerSharePct,n.maxSellerSharePct,e.seller.userPoints,e.seller.totalPoints)),e.buyer.claimed&&(r+=wf(e.epochEmission,n.buyerSharePct,n.maxBuyerSharePct,e.buyer.userPoints,e.buyer.totalPoints)),r}function QU(e){if(e<=0)return"ending now";const t=Math.floor(e/86400),n=Math.floor(e%86400/3600),r=Math.floor(e%3600/60);return t>0?`${t}d ${n}h`:n>0?`${n}h ${r}m`:`${r}m`}function RE(e){const t=e.seller.claimed?0n:vr(e.seller.amount),n=e.buyer.claimed?0n:vr(e.buyer.amount);return(t+n).toString()}function GU(e,t){return(vr(RE(e))+OE(e,t)).toString()}function ME(e){return!e.isCurrent&&!e.seller.claimed&&vr(e.seller.amount)>0n}function DE(e){return!e.isCurrent&&!e.buyer.claimed&&vr(e.buyer.amount)>0n}function FE(e){return ME(e)||DE(e)}function KU(e){return e.isCurrent?"Current":FE(e)?"Claimable":e.seller.claimed||e.buyer.claimed?"Claimed":"No pending rewards"}function YU({config:e}){const[t,n]=P.useState(null),[r,s]=P.useState(null),[a,c]=P.useState(null),[l,d]=P.useState(null),[f,h]=P.useState(!0),[p,m]=P.useState(null),y=(e==null?void 0:e.evmAddress)??null,{expectedChainId:v,ensureCorrectNetwork:w}=ws(e),{requireAuthorization:C}=Ai(),{connector:A}=it(),I=P.useCallback(async()=>{if(!y){h(!1);return}h(!0),m(null);try{const[_e,Te,dt,tt]=await Promise.all([sF().catch(()=>null),iF(y).catch(()=>null),aF().catch(()=>null),cF().catch(()=>({enabled:!1,configured:!1}))]);n(_e),s(Te),c(dt),d(tt.enabled),_e||m("Emissions not available on this chain")}finally{h(!1)}},[y]);P.useEffect(()=>{I()},[I]);const{writeContract:S,data:j,reset:N}=Qr(),{isSuccess:T}=Vr({hash:j,chainId:v}),[B,O]=P.useState(null),R=P.useCallback(()=>{if(!(e!=null&&e.emissionsContractAddress)||!r)return;const _e=r.rows.filter(Te=>!Te.isCurrent&&!Te.seller.claimed&&Te.seller.amount!=="0").map(Te=>BigInt(Te.epoch));_e.length!==0&&C(async()=>{O(null);try{await w(),S({address:e.emissionsContractAddress,abi:Eo(T2),functionName:"claimSellerEmissions",chainId:v,args:[_e]},{onError:Te=>O(Ot(Te))})}catch(Te){O(Ot(Te))}})},[e,r,w,v,S,C]);P.useEffect(()=>{T&&(N(),I())},[T,N,I]);const{writeContract:W,data:H,reset:K}=Qr(),{isSuccess:Q}=Vr({hash:H,chainId:v}),[ae,q]=P.useState(null),ee=P.useCallback(()=>{if(!(e!=null&&e.emissionsContractAddress)||!r||!y)return;const _e=r.rows.filter(Te=>!Te.isCurrent&&!Te.buyer.claimed&&Te.buyer.amount!=="0").map(Te=>BigInt(Te.epoch));_e.length!==0&&C(async()=>{q(null);try{await w(),W({address:e.emissionsContractAddress,abi:Eo(T2),functionName:"claimBuyerEmissions",chainId:v,args:[y,_e]},{onError:Te=>q(Ot(Te))})}catch(Te){q(Ot(Te))}})},[e,r,y,w,v,W,C]);if(P.useEffect(()=>{Q&&(K(),I())},[Q,K,I]),f&&!t)return b.jsx("div",{className:"rewards-view",children:b.jsx("div",{className:"overview-empty-desc",children:"Loading…"})});if(p||!t)return b.jsx("div",{className:"rewards-view",children:b.jsxs("div",{className:"overview-empty",children:[b.jsx("div",{className:"overview-empty-title",children:"Emissions not available"}),b.jsx("div",{className:"overview-empty-desc",children:p??"The Emissions contract is not configured for this chain."})]})});const te=Math.floor(Date.now()/1e3),Z=t.genesis+t.currentEpoch*t.epochDuration+t.epochDuration-te,F=t.halvingInterval-t.currentEpoch%t.halvingInterval,X=(r==null?void 0:r.rows)??[],pe=X.filter(_e=>!_e.isCurrent),ne=X.find(_e=>_e.isCurrent),oe=ey(ne,a),fe=pe.reduce((_e,Te)=>_e+vr(RE(Te)),0n),ge=pe.filter(FE).length,Ie=ne?TE(ne,a):"0",Be=VU(ne,a),Le=pe.reduce((_e,Te)=>_e+OE(Te,a),0n);return b.jsxs("div",{className:"rewards-view",children:[b.jsxs("section",{className:"rewards-claim-row",children:[b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Claimable now"}),b.jsxs("div",{className:"rewards-claim-value",children:[oa(fe.toString()),b.jsx("span",{children:"$ANTS"})]}),b.jsx("p",{children:"From closed epochs"})]}),b.jsxs("div",{className:"rewards-claim-actions",children:[b.jsx("button",{type:"button",className:"portal-primary-btn",disabled:!r||r.rows.every(_e=>!ME(_e)),onClick:R,children:"Claim seller"}),b.jsx("button",{type:"button",className:"portal-primary-btn",disabled:!r||r.rows.every(_e=>!DE(_e)),onClick:ee,children:"Claim buyer"}),(e==null?void 0:e.antsTokenAddress)&&A&&b.jsx("button",{type:"button",className:"portal-secondary-btn",onClick:async()=>{try{await(await A.getProvider()).request({method:"wallet_watchAsset",params:{type:"ERC20",options:{address:e.antsTokenAddress,symbol:"ANTS",decimals:18}}})}catch{}},children:"Add ANTS to wallet"})]})]}),b.jsxs("section",{className:"portal-content-section","aria-labelledby":"emissions-current-title",children:[b.jsxs("div",{className:"portal-content-head",children:[b.jsxs("h2",{className:"portal-content-title",id:"emissions-current-title",children:["Epoch #",t.currentEpoch]}),oe&&b.jsxs("p",{children:["Split: ",oe.sellerSharePct,"% sellers · ",oe.buyerSharePct,"% buyers ·"," ",oe.reserveSharePct,"% reserve · ",oe.teamSharePct,"% team"]})]}),b.jsxs("div",{className:"portal-metrics-grid","aria-label":"Current epoch and position details",children:[b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Ends in"}),b.jsx("strong",{children:QU(Z)})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Epoch pool"}),b.jsx("strong",{children:oa(t.epochEmission)})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Epoch duration"}),b.jsxs("strong",{children:[Math.round(t.epochDuration/86400),"d"]})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Next halving"}),b.jsx("strong",{children:F})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Seller points"}),b.jsx("strong",{children:ii((ne==null?void 0:ne.seller.userPoints)??"0")})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Buyer points"}),b.jsx("strong",{children:ii((ne==null?void 0:ne.buyer.userPoints)??"0")})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Estimated reward"}),b.jsx("strong",{children:oa(Ie)})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Your epoch share"}),b.jsx("strong",{children:Be>0?`${Be.toFixed(2)}%`:"—"})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Claimable now"}),b.jsx("strong",{children:oa(fe.toString())})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Claimable epochs"}),b.jsx("strong",{children:ge})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Already claimed"}),b.jsx("strong",{children:oa(Le.toString())})]})]})]}),b.jsxs("section",{className:"portal-content-section","aria-labelledby":"emissions-about-title",children:[b.jsx("div",{className:"portal-content-head",children:b.jsx("h2",{className:"portal-content-title",id:"emissions-about-title",children:"About $ANTS"})}),b.jsxs("div",{className:"rewards-info",children:[b.jsx("p",{children:"$ANTS is the native token of the AntSeed network. It is minted each epoch to active sellers and buyers in proportion to their on-chain activity. There is no pre-mining — you earn simply by using the network."}),b.jsx("p",{children:"Claims are non-custodial: seller claims mint to the claiming wallet, and buyer claims mint to the wallet you've authorized for your buyer identity."})]})]}),b.jsxs("section",{className:"portal-content-section","aria-labelledby":"emissions-history-title",children:[b.jsxs("div",{className:"portal-content-head",children:[b.jsx("h2",{className:"portal-content-title",id:"emissions-history-title",children:"Emission history"}),b.jsx("p",{children:"Closed-epoch reward amounts."})]}),b.jsxs("div",{className:"rewards-history",children:[b.jsx("div",{className:"portal-kicker",children:"Epoch history"}),pe.length===0?b.jsx("p",{children:"No closed epochs yet."}):pe.slice().reverse().map(_e=>b.jsxs("div",{className:"rewards-history-row",children:[b.jsxs("span",{children:["Epoch ",_e.epoch]}),b.jsxs("strong",{children:[oa(GU(_e,a))," $ANTS"]}),b.jsx("em",{children:KU(_e)})]},_e.epoch))]})]}),(B||ae)&&b.jsx("div",{className:"status-msg status-error",children:B||ae}),l===!1&&b.jsxs("div",{className:"portal-inline-warning",children:[b.jsx("span",{"aria-hidden":"true"}),"ANTS transfers are not enabled yet. Claimed tokens remain in your wallet until governance enables transfers."]})]})}const zs="0x1f228613116E2d08014DfdCC198377C8dedf18C9",JU=["function firstRewardEpoch() view returns (uint32)","function finalizedRewardEpoch() view returns (uint32)","function syncedRewardEpoch() view returns (uint32)","function userLastClaimedEpoch(address user) view returns (uint32)","function userEpochClaimed(address user, uint32 rewardEpoch) view returns (bool)","function pendingAntsForEpoch(address user, uint32 rewardEpoch) view returns (uint256)","function claimAnts(uint32[] rewardEpochs)"],O2=16,Ws=Eo(JU);function Wd(e){return typeof e=="number"?e:Number(e??0)}function ZU(e){return typeof e=="bigint"?e:0n}function XU(e){var r,s;if(e.rows.length===0)return"No finalized epochs";const t=(r=e.rows[0])==null?void 0:r.epoch,n=(s=e.rows[e.rows.length-1])==null?void 0:s.epoch;return t===n?`Epoch ${t}`:`Epochs ${t}-${n}`}function ez(e){return(e==null?void 0:e.rows.filter(t=>!t.claimed).map(t=>t.epoch))??[]}function tz(e){return(e==null?void 0:e.rows.reduce((t,n)=>t+(n.claimed?0n:n.amount),0n))??0n}async function nz(e,t){const[n,r,s,a]=await e.multicall({allowFailure:!0,contracts:[{address:zs,abi:Ws,functionName:"firstRewardEpoch"},{address:zs,abi:Ws,functionName:"finalizedRewardEpoch"},{address:zs,abi:Ws,functionName:"syncedRewardEpoch"},{address:zs,abi:Ws,functionName:"userLastClaimedEpoch",args:[t]}]}),c=Wd(n==null?void 0:n.result),l=Wd(r==null?void 0:r.result),d=Wd(s==null?void 0:s.result),f=Wd(a==null?void 0:a.result),h=Math.max(f,c),p=Math.min(l,h+O2),m=[];for(let v=h;v<p;v+=1)m.push(v);const y=m.length===0?[]:await e.multicall({allowFailure:!0,contracts:m.flatMap(v=>[{address:zs,abi:Ws,functionName:"pendingAntsForEpoch",args:[t,v]},{address:zs,abi:Ws,functionName:"userEpochClaimed",args:[t,v]}])});return{firstRewardEpoch:c,finalizedRewardEpoch:l,syncedRewardEpoch:d,userLastClaimedEpoch:f,rows:m.map((v,w)=>{var C,A;return{epoch:v,amount:ZU((C=y[w*2])==null?void 0:C.result),claimed:((A=y[w*2+1])==null?void 0:A.result)===!0}}),hasMore:h+O2<l}}function rz({config:e}){return b.jsx("div",{className:"rewards-view",children:b.jsx(oz,{config:e})})}function oz({config:e}){const{address:t,isConnected:n}=it(),r=nC(),s=t??null,{expectedChainId:a,ensureCorrectNetwork:c}=ws(e),[l,d]=P.useState(null),[f,h]=P.useState(!1),[p,m]=P.useState(null),[y,v]=P.useState(null),[w,C]=P.useState(!1),{writeContract:A,data:I,reset:S,isPending:j}=Qr(),{isSuccess:N}=Vr({hash:I,chainId:a}),T=P.useCallback(async()=>{if(!n||!s||!r){d(null),h(!1);return}h(!0),m(null);try{const W=await nz(r,s);d(W)}catch(W){m(Ot(W,"Unable to load DIEM rewards."))}finally{h(!1)}},[s,n,r]);P.useEffect(()=>{T()},[T]),P.useEffect(()=>{N&&(C(!0),S(),T())},[N,T,S]);const B=P.useMemo(()=>ez(l),[l]),O=P.useMemo(()=>tz(l),[l]),R=P.useCallback(()=>{!l||B.length===0||(v(null),C(!1),(async()=>{try{await c(),A({address:zs,abi:Ws,functionName:"claimAnts",chainId:a,args:[B]},{onError:W=>v(Ot(W))})}catch(W){v(Ot(W))}})())},[B,c,a,l,A]);return b.jsxs(b.Fragment,{children:[b.jsx("section",{className:"portal-content-section portal-content-section--diem",children:b.jsxs("div",{className:"portal-content-head portal-content-head--row",children:[b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"DIEM staking"}),b.jsx("h2",{className:"portal-content-title",children:"Your DIEM $ANTS"}),b.jsx("p",{children:"Rewards earned from staking DIEM through the AntSeed proxy. The 10% DIEM pool fee flows to the Protocol Reserve to strengthen the AntSeed ecosystem and ANTS. Connect the same wallet you used for staking."})]}),!n||!s?b.jsx(Ya,{className:"portal-primary-btn"}):null]})}),!n||!s?null:f&&!l?b.jsx("div",{className:"activity-empty",children:"Loading DIEM rewards…"}):p?b.jsxs("div",{className:"portal-inline-warning",children:[b.jsx("span",{"aria-hidden":"true"}),p]}):b.jsxs(b.Fragment,{children:[b.jsxs("section",{className:"portal-content-section","aria-labelledby":"diem-summary-title",children:[b.jsx("div",{className:"portal-content-head",children:b.jsx("h2",{className:"portal-content-title",id:"diem-summary-title",children:"Reward summary"})}),b.jsxs("div",{className:"portal-metrics-grid",children:[b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Pending $ANTS"}),b.jsxs("strong",{children:[e1(O)," $ANTS"]}),b.jsx("p",{children:"Across scanned finalized epochs"})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Claimable epochs"}),b.jsx("strong",{children:B.length}),b.jsx("p",{children:"Includes 0-$ANTS epochs to clear cursor"})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Finalized epoch"}),b.jsxs("strong",{children:["#",(l==null?void 0:l.finalizedRewardEpoch)??"—"]}),b.jsx("p",{children:"Last claimable reward epoch boundary"})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Scanned range"}),b.jsx("strong",{children:l?XU(l):"—"}),b.jsx("p",{children:l!=null&&l.hasMore?"More epochs available after claim":"Up to date"})]})]}),b.jsxs("div",{className:"rewards-diem-actions",children:[b.jsx("button",{type:"button",className:"portal-primary-btn",onClick:R,disabled:j||B.length===0,children:j?"Claiming…":O>0n?`Claim ${e1(O)} $ANTS`:B.length>0?"Clear 0-$ANTS epochs":"Nothing to claim"}),(l==null?void 0:l.hasMore)&&b.jsx("span",{children:"More finalized epochs load after claiming this range."})]})]}),b.jsxs("section",{className:"portal-content-section","aria-labelledby":"diem-history-title",children:[b.jsxs("div",{className:"portal-content-head",children:[b.jsx("h2",{className:"portal-content-title",id:"diem-history-title",children:"Diem proxy epochs"}),b.jsx("p",{children:"Claimable epochs are finalized by the DiemStakingProxy. Current epochs appear after the proxy closes them."})]}),b.jsx(sz,{rows:(l==null?void 0:l.rows)??[]}),(y||w)&&b.jsx("div",{className:`status-msg ${y?"status-error":"status-success"}`,children:y??"DIEM $ANTS claim confirmed."})]})]})]})}function sz({rows:e}){return e.length===0?b.jsx("p",{children:"No finalized DIEM proxy epochs to show."}):b.jsxs("div",{className:"rewards-history rewards-history--nested",children:[b.jsx("div",{className:"portal-kicker",children:"DIEM epochs"}),e.slice().reverse().map(t=>{const n=t.claimed?"Claimed":t.amount>0n?"Claimable":"Clearable";return b.jsxs("div",{className:"rewards-history-row",children:[b.jsxs("span",{children:["Epoch ",t.epoch]}),b.jsxs("strong",{children:[e1(t.amount)," $ANTS"]}),b.jsx("em",{children:n})]},t.epoch)})]})}const LE=900,Hp=10;function UE(e){return e.status===2?"settled":e.status===3?"timedout":e.status===0?"closed":e.closeRequestedAt===0?"active":Math.floor(Date.now()/1e3)<e.closeRequestedAt+LE?"closing":"withdrawable"}const iz={active:{label:"Active",modifier:"status-pill--active"},closing:{label:"Closing",modifier:"status-pill--closing"},withdrawable:{label:"Withdrawable",modifier:"status-pill--withdrawable"},settled:{label:"Settled",modifier:"status-pill--muted"},timedout:{label:"Timed out",modifier:"status-pill--muted"},closed:{label:"Closed",modifier:"status-pill--muted"}};function az(e,t){if(t==="all")return!0;const n=UE(e);return t==="settlements"?n==="settled":n==="closing"||n==="withdrawable"||n==="closed"||n==="timedout"}function cz(e){return e==="settlements"?"No settlements match this filter.":e==="closes"?"No channel closes match this filter.":"No activity yet. Complete a request to see settlements here."}function lz(e){const t=Math.floor(Date.now()/1e3),n=e+LE-t;if(n<=0)return"0:00";const r=Math.floor(n/60),s=n%60;return`${r}:${s.toString().padStart(2,"0")}`}function R2(e){return yf(e,{month:"short",day:"numeric",year:"numeric"})}const M2=Eo(BE);function uz({session:e,config:t,onRefresh:n}){const r=UE(e),{expectedChainId:s,ensureCorrectNetwork:a}=ws(t),{requireAuthorization:c}=Ai(),[l,d]=P.useState(null),{writeContract:f,data:h}=Qr(),{isSuccess:p}=Vr({hash:h,chainId:s}),{writeContract:m,data:y}=Qr(),{isSuccess:v}=Vr({hash:y,chainId:s}),w=P.useCallback(()=>{c(async()=>{d(null);try{await a(),f({address:t.channelsContractAddress,abi:M2,functionName:"requestClose",chainId:s,args:[e.channelId]})}catch(S){d(Ot(S))}})},[t.channelsContractAddress,a,s,e.channelId,f,c]),C=P.useCallback(()=>{c(async()=>{d(null);try{await a(),m({address:t.channelsContractAddress,abi:M2,functionName:"withdraw",chainId:s,args:[e.channelId]})}catch(S){d(Ot(S))}})},[t.channelsContractAddress,a,s,e.channelId,m,c]),A=iz[r],I=r==="closing"?`Closing ${lz(e.closeRequestedAt)}`:A.label;return b.jsxs("tr",{children:[b.jsx("td",{className:"channels-table-cell-seller",title:e.seller,children:nr(e.seller)}),b.jsxs("td",{className:"channels-table-cell-id",title:e.channelId,children:[e.channelId.slice(0,10),"…"]}),b.jsx("td",{children:b.jsx("span",{className:`status-pill ${A.modifier}`,children:I})}),b.jsxs("td",{className:"channels-table-num",children:["$",e.deposit]}),b.jsxs("td",{className:"channels-table-num",children:["$",e.settled]}),b.jsx("td",{className:"channels-table-date",title:R2(e.reservedAt),children:R2(e.reservedAt)}),b.jsxs("td",{className:"channels-table-action",children:[p||v?b.jsx("button",{className:"btn-link",onClick:n,children:"Refresh"}):r==="active"?b.jsx(En,{size:"sm",variant:"outline",onClick:w,children:"Close"}):r==="closing"?b.jsx(En,{size:"sm",variant:"outline",disabled:!0,children:"Waiting…"}):r==="withdrawable"?b.jsx(En,{size:"sm",onClick:C,children:"Withdraw"}):b.jsx("span",{className:"channels-table-dash",children:"—"}),l&&b.jsx("div",{className:"channels-table-error",children:l})]})]})}function dz({config:e}){const{channels:t,history:n,loading:r,refetch:s}=_E(e),[a,c]=P.useState(0),[l,d]=P.useState("all"),f=P.useCallback(async()=>{await s()},[s]),h=P.useMemo(()=>[...t,...n],[t,n]),p=P.useMemo(()=>{const A=t.reduce((j,N)=>j+Yc(N.deposit),0),I=t.reduce((j,N)=>j+Yc(N.settled),0),S=h.reduce((j,N)=>j+Yc(N.settled),0);return{active:t.length,reserved:A,used:I,total:h.length,totalSpent:S}},[t,h]),m=P.useMemo(()=>h.filter(A=>az(A,l)),[h,l]),y=P.useCallback(A=>{d(A),c(0)},[]),v=Math.max(1,Math.ceil(m.length/Hp));P.useEffect(()=>{a>v-1&&c(v-1)},[a,v]);const w=P.useMemo(()=>m.slice(a*Hp,(a+1)*Hp),[m,a]),C=h.length===m.length?`${h.length} entries`:`${m.length} of ${h.length} entries`;return b.jsxs("div",{className:"activity-view",children:[b.jsxs("section",{className:"portal-content-section","aria-labelledby":"activity-summary-title",children:[b.jsxs("div",{className:"portal-content-head portal-content-head--row",children:[b.jsxs("div",{children:[b.jsx("div",{className:"portal-kicker",children:"Your channels"}),b.jsx("h2",{className:"portal-content-title",id:"activity-summary-title",children:"Payment channels"}),b.jsx("p",{children:"Payment channels between you and sellers. Reserve funds once, then settle per-request against the escrow."})]}),b.jsx("button",{type:"button",className:"portal-secondary-btn",onClick:f,children:"Refresh"})]}),b.jsxs("div",{className:"portal-metrics-grid",children:[b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Active"}),b.jsxs("strong",{children:[p.active," / ",p.total]}),b.jsx("p",{children:"Open now / all-time"})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Reserved"}),b.jsxs("strong",{children:["$",vt(p.reserved)]}),b.jsx("p",{children:"Currently locked"})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Used"}),b.jsxs("strong",{children:["$",vt(p.used)]}),b.jsx("p",{children:"On active channels"})]}),b.jsxs("div",{className:"portal-metric",children:[b.jsx("div",{className:"portal-kicker",children:"Total spent"}),b.jsxs("strong",{children:["$",vt(p.totalSpent)]}),b.jsx("p",{children:"Settled all-time"})]})]})]}),b.jsxs("section",{className:"portal-content-section","aria-labelledby":"activity-log-title",children:[b.jsxs("div",{className:"portal-content-head portal-content-head--row",children:[b.jsxs("div",{children:[b.jsx("h2",{className:"portal-content-title",id:"activity-log-title",children:"Activity log"}),b.jsx("p",{children:"Settlements and channel closes across your payment channels."})]}),b.jsxs("div",{className:"activity-filter-group",role:"group","aria-label":"Activity filter",children:[b.jsx("button",{type:"button",className:l==="all"?"is-active":"",onClick:()=>y("all"),children:"All"}),b.jsx("button",{type:"button",className:l==="settlements"?"is-active":"",onClick:()=>y("settlements"),children:"Settlements"}),b.jsx("button",{type:"button",className:l==="closes"?"is-active":"",onClick:()=>y("closes"),children:"Channel closes"})]})]}),b.jsx("div",{className:"activity-window",children:C}),r&&h.length===0?b.jsx("div",{className:"activity-empty",children:"Loading activity…"}):m.length===0?b.jsx("div",{className:"activity-empty",children:cz(l)}):b.jsxs("div",{className:"activity-table-card",children:[b.jsx("div",{className:"channels-table-wrap",children:b.jsxs("table",{className:"channels-table",children:[b.jsx("thead",{children:b.jsxs("tr",{children:[b.jsx("th",{children:"Seller"}),b.jsx("th",{children:"Channel"}),b.jsx("th",{children:"Status"}),b.jsx("th",{className:"channels-table-num",children:"Reserved"}),b.jsx("th",{className:"channels-table-num",children:"Used"}),b.jsx("th",{children:"Opened"}),b.jsx("th",{})]})}),b.jsx("tbody",{children:w.map(A=>e?b.jsx(uz,{session:A,config:e,onRefresh:f},A.channelId):null)})]})}),v>1&&b.jsxs("div",{className:"channels-pagination",children:[b.jsxs("button",{type:"button",className:"channels-pagination-btn",disabled:a===0,onClick:()=>c(A=>Math.max(0,A-1)),"aria-label":"Previous page",children:[b.jsx("span",{"aria-hidden":"true",children:"←"}),b.jsx("span",{children:"Prev"})]}),b.jsxs("span",{className:"channels-pagination-info",children:["Page ",b.jsx("strong",{children:a+1})," of ",v]}),b.jsxs("button",{type:"button",className:"channels-pagination-btn",disabled:a>=v-1,onClick:()=>c(A=>Math.min(v-1,A+1)),"aria-label":"Next page",children:[b.jsx("span",{children:"Next"}),b.jsx("span",{"aria-hidden":"true",children:"→"})]})]})]})]})]})}function fz(e){return e.state==="reachable"?"set-pill--ok":e.state==="checking"?"set-pill--muted":"set-pill--warn"}function hz(e){return e.state==="reachable"?"reachable":e.state==="checking"?"checking":e.state==="unconfigured"?"not configured":"unreachable"}function pz({config:e}){const{operatorSet:t,operator:n,requireAuthorization:r}=Ai(),{address:s,isConnected:a,connector:c}=it(),{disconnect:l}=ou(),[d,f]=P.useState({state:"checking"});return P.useEffect(()=>{if(!(e!=null&&e.rpcUrl)){f({state:"unconfigured"});return}let h=!1;return f({state:"checking"}),tF().then(p=>{h||f({state:"reachable",blockNumber:p.blockNumber,latencyMs:p.latencyMs})}).catch(p=>{h||f({state:"unreachable",error:p instanceof Error?p.message:String(p)})}),()=>{h=!0}},[e==null?void 0:e.rpcUrl]),b.jsx("div",{className:"settings-view",children:b.jsxs("div",{className:"settings-grid settings-grid--focused",children:[b.jsxs("div",{className:"settings-cell",children:[b.jsx("div",{className:"settings-section-label",children:"Wallet"}),b.jsxs("div",{className:"settings-card",children:[b.jsxs("div",{className:"set-item",children:[b.jsxs("div",{className:"set-copy",children:[b.jsx("h4",{children:"Connected wallet"}),b.jsx("p",{children:"The external wallet used to sign and submit on-chain actions (withdrawals, claims, channel closes)."})]}),b.jsx("div",{className:"set-ctrl set-wallet-ctrl",children:a&&s?b.jsxs(b.Fragment,{children:[b.jsx("span",{className:"set-wallet-addr",children:nr(s)}),(c==null?void 0:c.name)&&b.jsx("span",{className:"set-wallet-provider",children:c.name}),b.jsx("button",{type:"button",className:"set-btn-ghost",onClick:()=>l(),children:"Disconnect"})]}):b.jsx(Ya,{className:"set-btn-ghost"})})]}),b.jsxs("div",{className:"set-item",children:[b.jsxs("div",{className:"set-copy",children:[b.jsx("h4",{children:"Authorized wallet"}),b.jsx("p",{children:"Your AntSeed node signs spending requests but never holds USDC or ANTS. This external wallet can recover funds and claim rewards."})]}),b.jsx("div",{className:"set-ctrl",children:t?b.jsxs(b.Fragment,{children:[b.jsx("span",{className:"set-wallet-addr",children:n?nr(n):"Not configured"}),b.jsxs("span",{className:"set-pill set-pill--ok",children:[b.jsx("span",{className:"set-pill-dot","aria-hidden":"true"}),"authorized"]})]}):b.jsx("button",{type:"button",className:"set-btn-ghost",disabled:t===null,onClick:()=>r(),children:t===null?"Checking…":"Authorize wallet"})})]})]})]}),b.jsxs("div",{className:"settings-cell",children:[b.jsx("div",{className:"settings-section-label",children:"Network"}),b.jsxs("div",{className:"settings-card",children:[b.jsxs("div",{className:"set-item",children:[b.jsxs("div",{className:"set-copy",children:[b.jsx("h4",{children:"Chain"}),b.jsx("p",{children:"Network the AntSeed protocol contracts live on."})]}),b.jsxs("div",{className:"set-ctrl",children:[b.jsx("span",{className:"set-value",children:(e==null?void 0:e.chainId)??"Unknown"}),b.jsxs("span",{className:`set-pill ${fz(d)}`,children:[b.jsx("span",{className:"set-pill-dot","aria-hidden":"true"}),hz(d)]}),d.state==="reachable"&&b.jsxs("span",{className:"set-wallet-provider",children:["block ",d.blockNumber.toLocaleString("en-US")]}),d.state==="unreachable"&&b.jsx("span",{className:"set-wallet-provider",children:d.error})]})]}),b.jsxs("div",{className:"set-item set-item-stack",children:[b.jsxs("div",{className:"set-copy",children:[b.jsx("h4",{children:"RPC endpoint"}),b.jsx("p",{children:"Configured by the active AntSeed node. Change it in node config, then reopen the portal."})]}),b.jsx("div",{className:"set-input-row",children:b.jsx("input",{className:"set-input",value:(e==null?void 0:e.rpcUrl)??"",readOnly:!0,placeholder:"http://127.0.0.1:8545"})})]})]})]})]})})}function mz(){const{operatorSet:e,requireAuthorization:t}=Ai();return e!==!1?null:b.jsx(PF,{className:"payment-authorize-alert",tone:"warning",title:"Your funds are not recoverable yet",action:b.jsx(En,{size:"sm",onClick:()=>t(),children:"Authorize now"}),children:"Authorize an external wallet so you can withdraw USDC, claim ANTS, and close channels. Without one, losing this node means losing your funds."})}const gz=new Set(["overview","rewards","diem-rewards","activity","settings"]);function yz(){const e=new URLSearchParams(window.location.search).get("tab");return!e||e==="deposit"||e==="deposits"||e==="dashboard"?"overview":e==="channels"?"activity":e==="emissions"?"rewards":gz.has(e)?e:"overview"}function vz(){const e=new URLSearchParams(window.location.search),t=e.get("action")??e.get("modal"),n=e.get("tab");return t==="deposit"||n==="deposit"||n==="deposits"}function wz(e){const t=new URL(window.location.href);t.searchParams.set("tab",e),window.history.replaceState({},"",t.toString())}function bz(){const e=new URL(window.location.href);e.searchParams.get("action")==="deposit"&&e.searchParams.delete("action"),e.searchParams.get("modal")==="deposit"&&e.searchParams.delete("modal"),window.history.replaceState({},"",e.toString())}function xz(){const[e,t]=P.useState(null),[n,r]=P.useState(!1),[s,a]=P.useState(!1),c=P.useRef(null),[l,d]=P.useState(null),[f,h]=P.useState(()=>yz()),[p,m]=P.useState(!1),[y,v]=P.useState(()=>vz()?"deposit":null),[w,C]=P.useState(!1),[A,I]=P.useState(()=>{const W=localStorage.getItem("antseed-payments-theme");return W?W==="dark":window.matchMedia("(prefers-color-scheme: dark)").matches});P.useEffect(()=>{const W=()=>C(!0);return window.addEventListener("antseed:session-expired",W),()=>window.removeEventListener("antseed:session-expired",W)},[]),P.useEffect(()=>{document.documentElement.setAttribute("data-theme",A?"dark":"light"),localStorage.setItem("antseed-payments-theme",A?"dark":"light")},[A]);const S=P.useCallback(async()=>{try{const W=await XD();t(W),a(!1),r(!0)}catch{a(!0),c.current&&clearTimeout(c.current),c.current=setTimeout(()=>{S()},5e3)}},[]),j=P.useCallback(async()=>{await S(),setTimeout(S,3e3)},[S]);P.useEffect(()=>(S(),eF().then(d).catch(()=>{}),()=>{c.current&&clearTimeout(c.current)}),[S]);const N=P.useCallback(W=>{h(W),wz(W)},[]),T=P.useCallback(()=>v("deposit"),[]),B=P.useCallback(()=>v("withdraw"),[]),O=P.useCallback(()=>{v(null),bz()},[]),R=(l==null?void 0:l.evmAddress)??(e==null?void 0:e.evmAddress)??null;return b.jsxs(bU,{config:l,children:[b.jsx(Cz,{balance:e,balanceLoaded:n,balanceError:s,onRetryBalance:S,config:l,activeTab:f,onSelectTab:N,isDark:A,onToggleTheme:()=>I(W=>!W),walletDrawerOpen:p,onOpenWalletDrawer:()=>m(!0),onCloseWalletDrawer:()=>m(!1),actionModal:y,onOpenDeposit:T,onOpenWithdraw:B,onCloseActionModal:O,buyerEvmAddress:R,refreshBalance:j}),w&&b.jsx("div",{className:"session-expired-overlay",role:"alert",children:b.jsxs("div",{className:"session-expired-card",children:[b.jsx("div",{className:"session-expired-icon",children:b.jsxs("svg",{width:"48",height:"48",viewBox:"0 0 48 48",fill:"none","aria-hidden":"true",children:[b.jsx("circle",{cx:"24",cy:"24",r:"22",stroke:"var(--text-muted)",strokeWidth:"2",strokeDasharray:"4 3"}),b.jsx("path",{d:"M24 14V26",stroke:"var(--text-muted)",strokeWidth:"2.5",strokeLinecap:"round"}),b.jsx("circle",{cx:"24",cy:"33",r:"1.5",fill:"var(--text-muted)"})]})}),b.jsx("h2",{className:"session-expired-title",children:"Session expired"}),b.jsx("p",{className:"session-expired-subtitle",children:"The payments server was restarted. Please reopen this portal from the desktop app or CLI to get a new session."})]})})]})}function Cz({balance:e,balanceLoaded:t,balanceError:n,onRetryBalance:r,config:s,activeTab:a,onSelectTab:c,isDark:l,onToggleTheme:d,walletDrawerOpen:f,onOpenWalletDrawer:h,onCloseWalletDrawer:p,actionModal:m,onOpenDeposit:y,onOpenWithdraw:v,onCloseActionModal:w,buyerEvmAddress:C,refreshBalance:A}){const[I,S]=P.useState(!1),[j,N]=P.useState(!1),T=Ai(),B=!t,O=t&&e!==null&&parseFloat(e.total)===0&&parseFloat(e.reserved)===0;let R=null;I?R="success":O&&!j&&(R="deposit");const W=B||R!==null,H=P.useCallback(async()=>{S(!0),w(),await A()},[A,w]),K=P.useCallback(()=>S(!1),[]),Q=P.useCallback(()=>N(!0),[]);return b.jsxs(b.Fragment,{children:[b.jsxs("div",{className:`dash-shell${W?" dash-shell--blurred":""}`,children:[b.jsx(yF,{activeTab:a,onSelect:c}),b.jsxs("div",{className:"dash-main",children:[b.jsx(SF,{activeTab:a,balance:e,buyerEvmAddress:C,atRisk:T.operatorSet===!1&&Number((e==null?void 0:e.total)??0)>0,isDark:l,onToggleTheme:d,onOpenWallet:h}),b.jsx(mz,{}),b.jsxs("main",{className:"dash-content",children:[a==="overview"&&b.jsx(qU,{config:s,balance:e,onOpenDeposit:y,onOpenWithdraw:v,onOpenActivity:()=>c("activity")}),a==="rewards"&&b.jsx(YU,{config:s}),a==="diem-rewards"&&b.jsx(rz,{config:s}),a==="activity"&&b.jsx(dz,{config:s}),a==="settings"&&b.jsx(pz,{config:s})]})]})]}),b.jsx(EU,{isOpen:f,onClose:p,balance:e,config:s,buyerEvmAddress:C,onOpenDeposit:y,onOpenWithdraw:v}),b.jsx(BU,{isVisible:B,error:n,onRetry:r}),b.jsx(PU,{phase:R,config:s,balance:e,buyerAddress:C,onDeposited:H,onContinue:K,onDismissDeposit:Q}),b.jsx(l1,{isOpen:m==="deposit",onClose:w,title:"Deposit USDC",subtitle:"Add credits to your AntSeed account with a guided two-step flow.",variant:"deposit",children:b.jsx(PE,{config:s,balance:e,buyerAddress:C,onDeposited:H})}),b.jsx(l1,{isOpen:m==="withdraw",onClose:w,title:"Withdraw USDC",subtitle:"Send funds to your authorized wallet.",children:b.jsx(RU,{config:s,balance:e,onAction:A})})]})}const Ez=new QB,Az=document.getElementById("root");$k.createRoot(Az).render(b.jsx(fB,{config:YD,children:b.jsx(h_,{client:Ez,children:b.jsx(yM,{children:b.jsx(xz,{})})})}));const D2=Object.freeze(Object.defineProperty({__proto__:null,default:qm},Symbol.toStringTag,{value:"Module"}));export{CP as $,Kk as A,re as B,le as C,X4 as D,t4 as E,$z as F,xr as G,Vc as H,un as I,KI as J,an as K,$l as L,br as M,Un as N,G4 as O,og as P,zt as Q,Ee as R,Rf as S,kx as T,Pz as U,ax as V,gs as W,nu as X,Ma as Y,N3 as Z,de as _,N7 as a,h3 as a0,Dz as a1,S4 as a2,Fz as a3,ds as a4,O4 as a5,Zc as a6,j4 as a7,R4 as a8,Gx as a9,c5 as aA,ql as aB,G1 as aa,x6 as ab,eB as ac,rt as ad,Lt as ae,ef as af,or as ag,Eo as ah,Vl as ai,kn as aj,k7 as ak,tm as al,C1 as am,eI as an,T1 as ao,Hr as ap,K1 as aq,Il as ar,mg as as,lI as at,Nx as au,Qz as av,Vz as aw,hs as ax,oi as ay,j7 as az,rr as b,Ha as c,d7 as d,wi as e,$r as f,x1 as g,$n as h,bl as i,Wx as j,c9 as k,If as l,Sz as m,K2 as n,qr as o,AP as p,Hd as q,jz as r,Ut as s,An as t,Ar as u,xt as v,Ua as w,Ba as x,l5 as y,C5 as z};