const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-yF-LxBzd.js","assets/_commonjsHelpers-C4iS2aBk.js","assets/index-y6gnYXmM.js","assets/events-BfiNmFEz.js","assets/index.es-DCT-OfME.js","assets/vue3-apexcharts-Df6ovwwD.js"])))=>i.map(i=>d[i]);
var a5=Object.defineProperty;var Qh=e=>{throw TypeError(e)};var c5=(e,t,n)=>t in e?a5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var qo=(e,t,n)=>c5(e,typeof t!="symbol"?t+"":t,n),Cd=(e,t,n)=>t.has(e)||Qh("Cannot "+n);var N=(e,t,n)=>(Cd(e,t,"read from private field"),n?n.call(e):t.get(e)),ge=(e,t,n)=>t.has(e)?Qh("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),me=(e,t,n,s)=>(Cd(e,t,"write to private field"),s?s.call(e,n):t.set(e,n),n),Se=(e,t,n)=>(Cd(e,t,"access private method"),n);var Uc=(e,t,n,s)=>({set _(r){me(e,t,r,n)},get _(){return N(e,t,s)}});(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))s(r);new MutationObserver(r=>{for(const o of r)if(o.type==="childList")for(const i of o.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&s(i)}).observe(document,{childList:!0,subtree:!0});function n(r){const o={};return r.integrity&&(o.integrity=r.integrity),r.referrerPolicy&&(o.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?o.credentials="include":r.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function s(r){if(r.ep)return;r.ep=!0;const o=n(r);fetch(r.href,o)}})();/*!
  * shared v10.0.4
  * (c) 2024 kazuya kawaguchi
  * Released under the MIT License.
  */const Su=typeof window<"u",Wr=(e,t=!1)=>t?Symbol.for(e):Symbol(e),Na=e=>typeof e=="number"&&isFinite(e),Zh=e=>Rv(e)==="[object RegExp]",u5=e=>Mn(e)&&Object.keys(e).length===0,as=Object.assign;let Yh;const Iv=()=>Yh||(Yh=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),l5=Object.prototype.hasOwnProperty;function Pu(e,t){return l5.call(e,t)}const Os=Array.isArray,Vc=e=>typeof e=="function",dt=e=>typeof e=="string",Es=e=>typeof e=="boolean",Jt=e=>e!==null&&typeof e=="object",d5=Object.prototype.toString,Rv=e=>d5.call(e),Mn=e=>Rv(e)==="[object Object]",jc=e=>!Jt(e)||Os(e);function mu(e,t){if(jc(e)||jc(t))throw new Error("Invalid value");const n=[{src:e,des:t}];for(;n.length;){const{src:s,des:r}=n.pop();Object.keys(s).forEach(o=>{Jt(s[o])&&!Jt(r[o])&&(r[o]=Array.isArray(s[o])?[]:{}),jc(r[o])||jc(s[o])?r[o]=s[o]:n.push({src:s[o],des:r[o]})})}}/*!
  * shared v10.0.4
  * (c) 2024 kazuya kawaguchi
  * Released under the MIT License.
  */const f5=(e,t,n)=>p5({l:e,k:t,s:n}),p5=e=>JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),un=e=>typeof e=="number"&&isFinite(e),m5=e=>tm(e)==="[object Date]",Jh=e=>tm(e)==="[object RegExp]",em=e=>nt(e)&&Object.keys(e).length===0,Gr=Object.assign;let ey;const h5=()=>ey||(ey=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function ty(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")}const cs=Array.isArray,yt=e=>typeof e=="function",Re=e=>typeof e=="string",Yt=e=>typeof e=="boolean",kt=e=>e!==null&&typeof e=="object",y5=e=>kt(e)&&yt(e.then)&&yt(e.catch),$v=Object.prototype.toString,tm=e=>$v.call(e),nt=e=>tm(e)==="[object Object]",b5=e=>e==null?"":cs(e)||nt(e)&&e.toString===$v?JSON.stringify(e,null,2):String(e);function nm(e,t=""){return e.reduce((n,s,r)=>r===0?n+s:n+t+s,"")}function g5(e,t){typeof console<"u"&&(console.warn("[intlify] "+e),t&&console.warn(t.stack))}/*!
  * message-compiler v10.0.4
  * (c) 2024 kazuya kawaguchi
  * Released under the MIT License.
  */function v5(e,t,n){return{line:e,column:t,offset:n}}function pf(e,t,n){return{start:e,end:t}}const Qe={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14,UNHANDLED_CODEGEN_NODE_TYPE:15,UNHANDLED_MINIFIER_NODE_TYPE:16},w5=17;function Ju(e,t,n={}){const{domain:s,messages:r,args:o}=n,i=e,a=new SyntaxError(String(i));return a.code=e,t&&(a.location=t),a.domain=s,a}function _5(e){throw e}const vs=" ",x5="\r",Ut=`
`,C5="\u2028",A5="\u2029";function T5(e){const t=e;let n=0,s=1,r=1,o=0;const i=C=>t[C]===x5&&t[C+1]===Ut,a=C=>t[C]===Ut,c=C=>t[C]===A5,u=C=>t[C]===C5,l=C=>i(C)||a(C)||c(C)||u(C),d=()=>n,f=()=>s,p=()=>r,m=()=>o,h=C=>i(C)||c(C)||u(C)?Ut:t[C],y=()=>h(n),b=()=>h(n+o);function g(){return o=0,l(n)&&(s++,r=0),i(n)&&n++,n++,r++,t[n]}function w(){return i(n+o)&&o++,o++,t[n+o]}function _(){n=0,s=1,r=1,o=0}function A(C=0){o=C}function x(){const C=n+o;for(;C!==n;)g();o=0}return{index:d,line:f,column:p,peekOffset:m,charAt:h,currentChar:y,currentPeek:b,next:g,peek:w,reset:_,resetPeek:A,skipToPeek:x}}const or=void 0,E5=".",ny="'",S5="tokenizer";function P5(e,t={}){const n=t.location!==!1,s=T5(e),r=()=>s.index(),o=()=>v5(s.line(),s.column(),s.index()),i=o(),a=r(),c={currentType:13,offset:a,startLoc:i,endLoc:i,lastType:13,lastOffset:a,lastStartLoc:i,lastEndLoc:i,braceNest:0,inLinked:!1,text:""},u=()=>c,{onError:l}=t;function d(E,I,H,...W){const ee=u();if(I.column+=H,I.offset+=H,l){const re=n?pf(ee.startLoc,I):null,D=Ju(E,re,{domain:S5,args:W});l(D)}}function f(E,I,H){E.endLoc=o(),E.currentType=I;const W={type:I};return n&&(W.loc=pf(E.startLoc,E.endLoc)),H!=null&&(W.value=H),W}const p=E=>f(E,13);function m(E,I){return E.currentChar()===I?(E.next(),I):(d(Qe.EXPECTED_TOKEN,o(),0,I),"")}function h(E){let I="";for(;E.currentPeek()===vs||E.currentPeek()===Ut;)I+=E.currentPeek(),E.peek();return I}function y(E){const I=h(E);return E.skipToPeek(),I}function b(E){if(E===or)return!1;const I=E.charCodeAt(0);return I>=97&&I<=122||I>=65&&I<=90||I===95}function g(E){if(E===or)return!1;const I=E.charCodeAt(0);return I>=48&&I<=57}function w(E,I){const{currentType:H}=I;if(H!==2)return!1;h(E);const W=b(E.currentPeek());return E.resetPeek(),W}function _(E,I){const{currentType:H}=I;if(H!==2)return!1;h(E);const W=E.currentPeek()==="-"?E.peek():E.currentPeek(),ee=g(W);return E.resetPeek(),ee}function A(E,I){const{currentType:H}=I;if(H!==2)return!1;h(E);const W=E.currentPeek()===ny;return E.resetPeek(),W}function x(E,I){const{currentType:H}=I;if(H!==7)return!1;h(E);const W=E.currentPeek()===".";return E.resetPeek(),W}function C(E,I){const{currentType:H}=I;if(H!==8)return!1;h(E);const W=b(E.currentPeek());return E.resetPeek(),W}function k(E,I){const{currentType:H}=I;if(!(H===7||H===11))return!1;h(E);const W=E.currentPeek()===":";return E.resetPeek(),W}function S(E,I){const{currentType:H}=I;if(H!==9)return!1;const W=()=>{const re=E.currentPeek();return re==="{"?b(E.peek()):re==="@"||re==="|"||re===":"||re==="."||re===vs||!re?!1:re===Ut?(E.peek(),W()):B(E,!1)},ee=W();return E.resetPeek(),ee}function R(E){h(E);const I=E.currentPeek()==="|";return E.resetPeek(),I}function B(E,I=!0){const H=(ee=!1,re="")=>{const D=E.currentPeek();return D==="{"||D==="@"||!D?ee:D==="|"?!(re===vs||re===Ut):D===vs?(E.peek(),H(!0,vs)):D===Ut?(E.peek(),H(!0,Ut)):!0},W=H();return I&&E.resetPeek(),W}function L(E,I){const H=E.currentChar();return H===or?or:I(H)?(E.next(),H):null}function X(E){const I=E.charCodeAt(0);return I>=97&&I<=122||I>=65&&I<=90||I>=48&&I<=57||I===95||I===36}function z(E){return L(E,X)}function ie(E){const I=E.charCodeAt(0);return I>=97&&I<=122||I>=65&&I<=90||I>=48&&I<=57||I===95||I===36||I===45}function ne(E){return L(E,ie)}function te(E){const I=E.charCodeAt(0);return I>=48&&I<=57}function ce(E){return L(E,te)}function he(E){const I=E.charCodeAt(0);return I>=48&&I<=57||I>=65&&I<=70||I>=97&&I<=102}function _e(E){return L(E,he)}function Fe(E){let I="",H="";for(;I=ce(E);)H+=I;return H}function Ae(E){let I="";for(;;){const H=E.currentChar();if(H==="{"||H==="}"||H==="@"||H==="|"||!H)break;if(H===vs||H===Ut)if(B(E))I+=H,E.next();else{if(R(E))break;I+=H,E.next()}else I+=H,E.next()}return I}function qe(E){y(E);let I="",H="";for(;I=ne(E);)H+=I;return E.currentChar()===or&&d(Qe.UNTERMINATED_CLOSING_BRACE,o(),0),H}function Ye(E){y(E);let I="";return E.currentChar()==="-"?(E.next(),I+=`-${Fe(E)}`):I+=Fe(E),E.currentChar()===or&&d(Qe.UNTERMINATED_CLOSING_BRACE,o(),0),I}function mt(E){return E!==ny&&E!==Ut}function Xe(E){y(E),m(E,"'");let I="",H="";for(;I=L(E,mt);)I==="\\"?H+=se(E):H+=I;const W=E.currentChar();return W===Ut||W===or?(d(Qe.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,o(),0),W===Ut&&(E.next(),m(E,"'")),H):(m(E,"'"),H)}function se(E){const I=E.currentChar();switch(I){case"\\":case"'":return E.next(),`\\${I}`;case"u":return V(E,I,4);case"U":return V(E,I,6);default:return d(Qe.UNKNOWN_ESCAPE_SEQUENCE,o(),0,I),""}}function V(E,I,H){m(E,I);let W="";for(let ee=0;ee<H;ee++){const re=_e(E);if(!re){d(Qe.INVALID_UNICODE_ESCAPE_SEQUENCE,o(),0,`\\${I}${W}${E.currentChar()}`);break}W+=re}return`\\${I}${W}`}function j(E){return E!=="{"&&E!=="}"&&E!==vs&&E!==Ut}function U(E){y(E);let I="",H="";for(;I=L(E,j);)H+=I;return H}function oe(E){let I="",H="";for(;I=z(E);)H+=I;return H}function be(E){const I=H=>{const W=E.currentChar();return W==="{"||W==="@"||W==="|"||W==="("||W===")"||!W||W===vs?H:(H+=W,E.next(),I(H))};return I("")}function P(E){y(E);const I=m(E,"|");return y(E),I}function O(E,I){let H=null;switch(E.currentChar()){case"{":return I.braceNest>=1&&d(Qe.NOT_ALLOW_NEST_PLACEHOLDER,o(),0),E.next(),H=f(I,2,"{"),y(E),I.braceNest++,H;case"}":return I.braceNest>0&&I.currentType===2&&d(Qe.EMPTY_PLACEHOLDER,o(),0),E.next(),H=f(I,3,"}"),I.braceNest--,I.braceNest>0&&y(E),I.inLinked&&I.braceNest===0&&(I.inLinked=!1),H;case"@":return I.braceNest>0&&d(Qe.UNTERMINATED_CLOSING_BRACE,o(),0),H=q(E,I)||p(I),I.braceNest=0,H;default:{let ee=!0,re=!0,D=!0;if(R(E))return I.braceNest>0&&d(Qe.UNTERMINATED_CLOSING_BRACE,o(),0),H=f(I,1,P(E)),I.braceNest=0,I.inLinked=!1,H;if(I.braceNest>0&&(I.currentType===4||I.currentType===5||I.currentType===6))return d(Qe.UNTERMINATED_CLOSING_BRACE,o(),0),I.braceNest=0,K(E,I);if(ee=w(E,I))return H=f(I,4,qe(E)),y(E),H;if(re=_(E,I))return H=f(I,5,Ye(E)),y(E),H;if(D=A(E,I))return H=f(I,6,Xe(E)),y(E),H;if(!ee&&!re&&!D)return H=f(I,12,U(E)),d(Qe.INVALID_TOKEN_IN_PLACEHOLDER,o(),0,H.value),y(E),H;break}}return H}function q(E,I){const{currentType:H}=I;let W=null;const ee=E.currentChar();switch((H===7||H===8||H===11||H===9)&&(ee===Ut||ee===vs)&&d(Qe.INVALID_LINKED_FORMAT,o(),0),ee){case"@":return E.next(),W=f(I,7,"@"),I.inLinked=!0,W;case".":return y(E),E.next(),f(I,8,".");case":":return y(E),E.next(),f(I,9,":");default:return R(E)?(W=f(I,1,P(E)),I.braceNest=0,I.inLinked=!1,W):x(E,I)||k(E,I)?(y(E),q(E,I)):C(E,I)?(y(E),f(I,11,oe(E))):S(E,I)?(y(E),ee==="{"?O(E,I)||W:f(I,10,be(E))):(H===7&&d(Qe.INVALID_LINKED_FORMAT,o(),0),I.braceNest=0,I.inLinked=!1,K(E,I))}}function K(E,I){let H={type:13};if(I.braceNest>0)return O(E,I)||p(I);if(I.inLinked)return q(E,I)||p(I);switch(E.currentChar()){case"{":return O(E,I)||p(I);case"}":return d(Qe.UNBALANCED_CLOSING_BRACE,o(),0),E.next(),f(I,3,"}");case"@":return q(E,I)||p(I);default:{if(R(E))return H=f(I,1,P(E)),I.braceNest=0,I.inLinked=!1,H;if(B(E))return f(I,0,Ae(E));break}}return H}function G(){const{currentType:E,offset:I,startLoc:H,endLoc:W}=c;return c.lastType=E,c.lastOffset=I,c.lastStartLoc=H,c.lastEndLoc=W,c.offset=r(),c.startLoc=o(),s.currentChar()===or?f(c,13):K(s,c)}return{nextToken:G,currentOffset:r,currentPosition:o,context:u}}const k5="parser",I5=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;function R5(e,t,n){switch(e){case"\\\\":return"\\";case"\\'":return"'";default:{const s=parseInt(t||n,16);return s<=55295||s>=57344?String.fromCodePoint(s):"�"}}}function $5(e={}){const t=e.location!==!1,{onError:n}=e;function s(b,g,w,_,...A){const x=b.currentPosition();if(x.offset+=_,x.column+=_,n){const C=t?pf(w,x):null,k=Ju(g,C,{domain:k5,args:A});n(k)}}function r(b,g,w){const _={type:b};return t&&(_.start=g,_.end=g,_.loc={start:w,end:w}),_}function o(b,g,w,_){t&&(b.end=g,b.loc&&(b.loc.end=w))}function i(b,g){const w=b.context(),_=r(3,w.offset,w.startLoc);return _.value=g,o(_,b.currentOffset(),b.currentPosition()),_}function a(b,g){const w=b.context(),{lastOffset:_,lastStartLoc:A}=w,x=r(5,_,A);return x.index=parseInt(g,10),b.nextToken(),o(x,b.currentOffset(),b.currentPosition()),x}function c(b,g){const w=b.context(),{lastOffset:_,lastStartLoc:A}=w,x=r(4,_,A);return x.key=g,b.nextToken(),o(x,b.currentOffset(),b.currentPosition()),x}function u(b,g){const w=b.context(),{lastOffset:_,lastStartLoc:A}=w,x=r(9,_,A);return x.value=g.replace(I5,R5),b.nextToken(),o(x,b.currentOffset(),b.currentPosition()),x}function l(b){const g=b.nextToken(),w=b.context(),{lastOffset:_,lastStartLoc:A}=w,x=r(8,_,A);return g.type!==11?(s(b,Qe.UNEXPECTED_EMPTY_LINKED_MODIFIER,w.lastStartLoc,0),x.value="",o(x,_,A),{nextConsumeToken:g,node:x}):(g.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,Qn(g)),x.value=g.value||"",o(x,b.currentOffset(),b.currentPosition()),{node:x})}function d(b,g){const w=b.context(),_=r(7,w.offset,w.startLoc);return _.value=g,o(_,b.currentOffset(),b.currentPosition()),_}function f(b){const g=b.context(),w=r(6,g.offset,g.startLoc);let _=b.nextToken();if(_.type===8){const A=l(b);w.modifier=A.node,_=A.nextConsumeToken||b.nextToken()}switch(_.type!==9&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(_)),_=b.nextToken(),_.type===2&&(_=b.nextToken()),_.type){case 10:_.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(_)),w.key=d(b,_.value||"");break;case 4:_.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(_)),w.key=c(b,_.value||"");break;case 5:_.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(_)),w.key=a(b,_.value||"");break;case 6:_.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(_)),w.key=u(b,_.value||"");break;default:{s(b,Qe.UNEXPECTED_EMPTY_LINKED_KEY,g.lastStartLoc,0);const A=b.context(),x=r(7,A.offset,A.startLoc);return x.value="",o(x,A.offset,A.startLoc),w.key=x,o(w,A.offset,A.startLoc),{nextConsumeToken:_,node:w}}}return o(w,b.currentOffset(),b.currentPosition()),{node:w}}function p(b){const g=b.context(),w=g.currentType===1?b.currentOffset():g.offset,_=g.currentType===1?g.endLoc:g.startLoc,A=r(2,w,_);A.items=[];let x=null;do{const S=x||b.nextToken();switch(x=null,S.type){case 0:S.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(S)),A.items.push(i(b,S.value||""));break;case 5:S.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(S)),A.items.push(a(b,S.value||""));break;case 4:S.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(S)),A.items.push(c(b,S.value||""));break;case 6:S.value==null&&s(b,Qe.UNEXPECTED_LEXICAL_ANALYSIS,g.lastStartLoc,0,Qn(S)),A.items.push(u(b,S.value||""));break;case 7:{const R=f(b);A.items.push(R.node),x=R.nextConsumeToken||null;break}}}while(g.currentType!==13&&g.currentType!==1);const C=g.currentType===1?g.lastOffset:b.currentOffset(),k=g.currentType===1?g.lastEndLoc:b.currentPosition();return o(A,C,k),A}function m(b,g,w,_){const A=b.context();let x=_.items.length===0;const C=r(1,g,w);C.cases=[],C.cases.push(_);do{const k=p(b);x||(x=k.items.length===0),C.cases.push(k)}while(A.currentType!==13);return x&&s(b,Qe.MUST_HAVE_MESSAGES_IN_PLURAL,w,0),o(C,b.currentOffset(),b.currentPosition()),C}function h(b){const g=b.context(),{offset:w,startLoc:_}=g,A=p(b);return g.currentType===13?A:m(b,w,_,A)}function y(b){const g=P5(b,Gr({},e)),w=g.context(),_=r(0,w.offset,w.startLoc);return t&&_.loc&&(_.loc.source=b),_.body=h(g),e.onCacheKey&&(_.cacheKey=e.onCacheKey(b)),w.currentType!==13&&s(g,Qe.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,b[w.offset]||""),o(_,g.currentOffset(),g.currentPosition()),_}return{parse:y}}function Qn(e){if(e.type===13)return"EOF";const t=(e.value||"").replace(/\r?\n/gu,"\\n");return t.length>10?t.slice(0,9)+"…":t}function M5(e,t={}){const n={ast:e,helpers:new Set};return{context:()=>n,helper:o=>(n.helpers.add(o),o)}}function sy(e,t){for(let n=0;n<e.length;n++)sm(e[n],t)}function sm(e,t){switch(e.type){case 1:sy(e.cases,t),t.helper("plural");break;case 2:sy(e.items,t);break;case 6:{sm(e.key,t),t.helper("linked"),t.helper("type");break}case 5:t.helper("interpolate"),t.helper("list");break;case 4:t.helper("interpolate"),t.helper("named");break}}function O5(e,t={}){const n=M5(e);n.helper("normalize"),e.body&&sm(e.body,n);const s=n.context();e.helpers=Array.from(s.helpers)}function L5(e){const t=e.body;return t.type===2?ry(t):t.cases.forEach(n=>ry(n)),e}function ry(e){if(e.items.length===1){const t=e.items[0];(t.type===3||t.type===9)&&(e.static=t.value,delete t.value)}else{const t=[];for(let n=0;n<e.items.length;n++){const s=e.items[n];if(!(s.type===3||s.type===9)||s.value==null)break;t.push(s.value)}if(t.length===e.items.length){e.static=nm(t);for(let n=0;n<e.items.length;n++){const s=e.items[n];(s.type===3||s.type===9)&&delete s.value}}}}function Ko(e){switch(e.t=e.type,e.type){case 0:{const t=e;Ko(t.body),t.b=t.body,delete t.body;break}case 1:{const t=e,n=t.cases;for(let s=0;s<n.length;s++)Ko(n[s]);t.c=n,delete t.cases;break}case 2:{const t=e,n=t.items;for(let s=0;s<n.length;s++)Ko(n[s]);t.i=n,delete t.items,t.static&&(t.s=t.static,delete t.static);break}case 3:case 9:case 8:case 7:{const t=e;t.value&&(t.v=t.value,delete t.value);break}case 6:{const t=e;Ko(t.key),t.k=t.key,delete t.key,t.modifier&&(Ko(t.modifier),t.m=t.modifier,delete t.modifier);break}case 5:{const t=e;t.i=t.index,delete t.index;break}case 4:{const t=e;t.k=t.key,delete t.key;break}}delete e.type}function F5(e,t){const{sourceMap:n,filename:s,breakLineCode:r,needIndent:o}=t,i=t.location!==!1,a={filename:s,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:r,needIndent:o,indentLevel:0};i&&e.loc&&(a.source=e.loc.source);const c=()=>a;function u(y,b){a.code+=y}function l(y,b=!0){const g=b?r:"";u(o?g+"  ".repeat(y):g)}function d(y=!0){const b=++a.indentLevel;y&&l(b)}function f(y=!0){const b=--a.indentLevel;y&&l(b)}function p(){l(a.indentLevel)}return{context:c,push:u,indent:d,deindent:f,newline:p,helper:y=>`_${y}`,needIndent:()=>a.needIndent}}function N5(e,t){const{helper:n}=e;e.push(`${n("linked")}(`),Ti(e,t.key),t.modifier?(e.push(", "),Ti(e,t.modifier),e.push(", _type")):e.push(", undefined, _type"),e.push(")")}function B5(e,t){const{helper:n,needIndent:s}=e;e.push(`${n("normalize")}([`),e.indent(s());const r=t.items.length;for(let o=0;o<r&&(Ti(e,t.items[o]),o!==r-1);o++)e.push(", ");e.deindent(s()),e.push("])")}function D5(e,t){const{helper:n,needIndent:s}=e;if(t.cases.length>1){e.push(`${n("plural")}([`),e.indent(s());const r=t.cases.length;for(let o=0;o<r&&(Ti(e,t.cases[o]),o!==r-1);o++)e.push(", ");e.deindent(s()),e.push("])")}}function U5(e,t){t.body?Ti(e,t.body):e.push("null")}function Ti(e,t){const{helper:n}=e;switch(t.type){case 0:U5(e,t);break;case 1:D5(e,t);break;case 2:B5(e,t);break;case 6:N5(e,t);break;case 8:e.push(JSON.stringify(t.value),t);break;case 7:e.push(JSON.stringify(t.value),t);break;case 5:e.push(`${n("interpolate")}(${n("list")}(${t.index}))`,t);break;case 4:e.push(`${n("interpolate")}(${n("named")}(${JSON.stringify(t.key)}))`,t);break;case 9:e.push(JSON.stringify(t.value),t);break;case 3:e.push(JSON.stringify(t.value),t);break}}const V5=(e,t={})=>{const n=Re(t.mode)?t.mode:"normal",s=Re(t.filename)?t.filename:"message.intl",r=!!t.sourceMap,o=t.breakLineCode!=null?t.breakLineCode:n==="arrow"?";":`
`,i=t.needIndent?t.needIndent:n!=="arrow",a=e.helpers||[],c=F5(e,{mode:n,filename:s,sourceMap:r,breakLineCode:o,needIndent:i});c.push(n==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),c.indent(i),a.length>0&&(c.push(`const { ${nm(a.map(d=>`${d}: _${d}`),", ")} } = ctx`),c.newline()),c.push("return "),Ti(c,e),c.deindent(i),c.push("}"),delete e.helpers;const{code:u,map:l}=c.context();return{ast:e,code:u,map:l?l.toJSON():void 0}};function j5(e,t={}){const n=Gr({},t),s=!!n.jit,r=!!n.minify,o=n.optimize==null?!0:n.optimize,a=$5(n).parse(e);return s?(o&&L5(a),r&&Ko(a),{ast:a,code:""}):(O5(a,n),V5(a,n))}/*!
  * core-base v10.0.4
  * (c) 2024 kazuya kawaguchi
  * Released under the MIT License.
  */function H5(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(h5().__INTLIFY_PROD_DEVTOOLS__=!1)}function Ad(e){return n=>z5(n,e)}function z5(e,t){const n=t.b||t.body;if((n.t||n.type)===1){const s=n,r=s.c||s.cases;return e.plural(r.reduce((o,i)=>[...o,oy(e,i)],[]))}else return oy(e,n)}function oy(e,t){const n=t.s||t.static;if(n!=null)return e.type==="text"?n:e.normalize([n]);{const s=(t.i||t.items).reduce((r,o)=>[...r,mf(e,o)],[]);return e.normalize(s)}}function mf(e,t){const n=t.t||t.type;switch(n){case 3:{const s=t;return s.v||s.value}case 9:{const s=t;return s.v||s.value}case 4:{const s=t;return e.interpolate(e.named(s.k||s.key))}case 5:{const s=t;return e.interpolate(e.list(s.i!=null?s.i:s.index))}case 6:{const s=t,r=s.m||s.modifier;return e.linked(mf(e,s.k||s.key),r?mf(e,r):void 0,e.type)}case 7:{const s=t;return s.v||s.value}case 8:{const s=t;return s.v||s.value}default:throw new Error(`unhandled node type on format message part: ${n}`)}}const q5=e=>e;let Hc=Object.create(null);const Ei=e=>kt(e)&&(e.t===0||e.type===0)&&("b"in e||"body"in e);function W5(e,t={}){let n=!1;const s=t.onError||_5;return t.onError=r=>{n=!0,s(r)},{...j5(e,t),detectError:n}}function G5(e,t){if(Re(e)){Yt(t.warnHtmlMessage)&&t.warnHtmlMessage;const s=(t.onCacheKey||q5)(e),r=Hc[s];if(r)return r;const{ast:o,detectError:i}=W5(e,{...t,location:!1,jit:!0}),a=Ad(o);return i?a:Hc[s]=a}else{const n=e.cacheKey;if(n){const s=Hc[n];return s||(Hc[n]=Ad(e))}else return Ad(e)}}let Ba=null;function X5(e){Ba=e}function K5(e,t,n){Ba&&Ba.emit("i18n:init",{timestamp:Date.now(),i18n:e,version:t,meta:n})}const Q5=Z5("function:translate");function Z5(e){return t=>Ba&&Ba.emit(e,t)}const Ls={INVALID_ARGUMENT:w5,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},Y5=24;function Fs(e){return Ju(e,null,void 0)}function rm(e,t){return t.locale!=null?iy(t.locale):iy(e.locale)}let Td;function iy(e){if(Re(e))return e;if(yt(e)){if(e.resolvedOnce&&Td!=null)return Td;if(e.constructor.name==="Function"){const t=e();if(y5(t))throw Fs(Ls.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return Td=t}else throw Fs(Ls.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw Fs(Ls.NOT_SUPPORT_LOCALE_TYPE)}function J5(e,t,n){return[...new Set([n,...cs(t)?t:kt(t)?Object.keys(t):Re(t)?[t]:[n]])]}function Mv(e,t,n){const s=Re(n)?n:ku,r=e;r.__localeChainCache||(r.__localeChainCache=new Map);let o=r.__localeChainCache.get(s);if(!o){o=[];let i=[n];for(;cs(i);)i=ay(o,i,t);const a=cs(t)||!nt(t)?t:t.default?t.default:null;i=Re(a)?[a]:a,cs(i)&&ay(o,i,!1),r.__localeChainCache.set(s,o)}return o}function ay(e,t,n){let s=!0;for(let r=0;r<t.length&&Yt(s);r++){const o=t[r];Re(o)&&(s=ex(e,t[r],n))}return s}function ex(e,t,n){let s;const r=t.split("-");do{const o=r.join("-");s=tx(e,o,n),r.splice(-1,1)}while(r.length&&s===!0);return s}function tx(e,t,n){let s=!1;if(!e.includes(t)&&(s=!0,t)){s=t[t.length-1]!=="!";const r=t.replace(/!/g,"");e.push(r),(cs(n)||nt(n))&&n[r]&&(s=n[r])}return s}const Xr=[];Xr[0]={w:[0],i:[3,0],"[":[4],o:[7]};Xr[1]={w:[1],".":[2],"[":[4],o:[7]};Xr[2]={w:[2],i:[3,0],0:[3,0]};Xr[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]};Xr[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]};Xr[5]={"'":[4,0],o:8,l:[5,0]};Xr[6]={'"':[4,0],o:8,l:[6,0]};const nx=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function sx(e){return nx.test(e)}function rx(e){const t=e.charCodeAt(0),n=e.charCodeAt(e.length-1);return t===n&&(t===34||t===39)?e.slice(1,-1):e}function ox(e){if(e==null)return"o";switch(e.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return e;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function ix(e){const t=e.trim();return e.charAt(0)==="0"&&isNaN(parseInt(e))?!1:sx(t)?rx(t):"*"+t}function ax(e){const t=[];let n=-1,s=0,r=0,o,i,a,c,u,l,d;const f=[];f[0]=()=>{i===void 0?i=a:i+=a},f[1]=()=>{i!==void 0&&(t.push(i),i=void 0)},f[2]=()=>{f[0](),r++},f[3]=()=>{if(r>0)r--,s=4,f[0]();else{if(r=0,i===void 0||(i=ix(i),i===!1))return!1;f[1]()}};function p(){const m=e[n+1];if(s===5&&m==="'"||s===6&&m==='"')return n++,a="\\"+m,f[0](),!0}for(;s!==null;)if(n++,o=e[n],!(o==="\\"&&p())){if(c=ox(o),d=Xr[s],u=d[c]||d.l||8,u===8||(s=u[0],u[1]!==void 0&&(l=f[u[1]],l&&(a=o,l()===!1))))return;if(s===7)return t}}const cy=new Map;function cx(e,t){return kt(e)?e[t]:null}function ux(e,t){if(!kt(e))return null;let n=cy.get(t);if(n||(n=ax(t),n&&cy.set(t,n)),!n)return null;const s=n.length;let r=e,o=0;for(;o<s;){const i=r[n[o]];if(i===void 0||yt(r))return null;r=i,o++}return r}const lx="10.0.4",el=-1,ku="en-US",uy="",ly=e=>`${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;function dx(){return{upper:(e,t)=>t==="text"&&Re(e)?e.toUpperCase():t==="vnode"&&kt(e)&&"__v_isVNode"in e?e.children.toUpperCase():e,lower:(e,t)=>t==="text"&&Re(e)?e.toLowerCase():t==="vnode"&&kt(e)&&"__v_isVNode"in e?e.children.toLowerCase():e,capitalize:(e,t)=>t==="text"&&Re(e)?ly(e):t==="vnode"&&kt(e)&&"__v_isVNode"in e?ly(e.children):e}}let Ov;function fx(e){Ov=e}let Lv;function px(e){Lv=e}let Fv;function mx(e){Fv=e}let Nv=null;const hx=e=>{Nv=e},yx=()=>Nv;let Bv=null;const dy=e=>{Bv=e},bx=()=>Bv;let fy=0;function gx(e={}){const t=yt(e.onWarn)?e.onWarn:g5,n=Re(e.version)?e.version:lx,s=Re(e.locale)||yt(e.locale)?e.locale:ku,r=yt(s)?ku:s,o=cs(e.fallbackLocale)||nt(e.fallbackLocale)||Re(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:r,i=nt(e.messages)?e.messages:{[r]:{}},a=nt(e.datetimeFormats)?e.datetimeFormats:{[r]:{}},c=nt(e.numberFormats)?e.numberFormats:{[r]:{}},u=Gr({},e.modifiers||{},dx()),l=e.pluralRules||{},d=yt(e.missing)?e.missing:null,f=Yt(e.missingWarn)||Jh(e.missingWarn)?e.missingWarn:!0,p=Yt(e.fallbackWarn)||Jh(e.fallbackWarn)?e.fallbackWarn:!0,m=!!e.fallbackFormat,h=!!e.unresolving,y=yt(e.postTranslation)?e.postTranslation:null,b=nt(e.processor)?e.processor:null,g=Yt(e.warnHtmlMessage)?e.warnHtmlMessage:!0,w=!!e.escapeParameter,_=yt(e.messageCompiler)?e.messageCompiler:Ov,A=yt(e.messageResolver)?e.messageResolver:Lv||cx,x=yt(e.localeFallbacker)?e.localeFallbacker:Fv||J5,C=kt(e.fallbackContext)?e.fallbackContext:void 0,k=e,S=kt(k.__datetimeFormatters)?k.__datetimeFormatters:new Map,R=kt(k.__numberFormatters)?k.__numberFormatters:new Map,B=kt(k.__meta)?k.__meta:{};fy++;const L={version:n,cid:fy,locale:s,fallbackLocale:o,messages:i,modifiers:u,pluralRules:l,missing:d,missingWarn:f,fallbackWarn:p,fallbackFormat:m,unresolving:h,postTranslation:y,processor:b,warnHtmlMessage:g,escapeParameter:w,messageCompiler:_,messageResolver:A,localeFallbacker:x,fallbackContext:C,onWarn:t,__meta:B};return L.datetimeFormats=a,L.numberFormats=c,L.__datetimeFormatters=S,L.__numberFormatters=R,__INTLIFY_PROD_DEVTOOLS__&&K5(L,n,B),L}function om(e,t,n,s,r){const{missing:o,onWarn:i}=e;if(o!==null){const a=o(e,n,t,r);return Re(a)?a:t}else return t}function la(e,t,n){const s=e;s.__localeChainCache=new Map,e.localeFallbacker(e,n,t)}function vx(e,t){return e===t?!1:e.split("-")[0]===t.split("-")[0]}function wx(e,t){const n=t.indexOf(e);if(n===-1)return!1;for(let s=n+1;s<t.length;s++)if(vx(e,t[s]))return!0;return!1}function py(e,...t){const{datetimeFormats:n,unresolving:s,fallbackLocale:r,onWarn:o,localeFallbacker:i}=e,{__datetimeFormatters:a}=e,[c,u,l,d]=hf(...t),f=Yt(l.missingWarn)?l.missingWarn:e.missingWarn;Yt(l.fallbackWarn)?l.fallbackWarn:e.fallbackWarn;const p=!!l.part,m=rm(e,l),h=i(e,r,m);if(!Re(c)||c==="")return new Intl.DateTimeFormat(m,d).format(u);let y={},b,g=null;const w="datetime format";for(let x=0;x<h.length&&(b=h[x],y=n[b]||{},g=y[c],!nt(g));x++)om(e,c,b,f,w);if(!nt(g)||!Re(b))return s?el:c;let _=`${b}__${c}`;em(d)||(_=`${_}__${JSON.stringify(d)}`);let A=a.get(_);return A||(A=new Intl.DateTimeFormat(b,Gr({},g,d)),a.set(_,A)),p?A.formatToParts(u):A.format(u)}const Dv=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function hf(...e){const[t,n,s,r]=e,o={};let i={},a;if(Re(t)){const c=t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!c)throw Fs(Ls.INVALID_ISO_DATE_ARGUMENT);const u=c[3]?c[3].trim().startsWith("T")?`${c[1].trim()}${c[3].trim()}`:`${c[1].trim()}T${c[3].trim()}`:c[1].trim();a=new Date(u);try{a.toISOString()}catch{throw Fs(Ls.INVALID_ISO_DATE_ARGUMENT)}}else if(m5(t)){if(isNaN(t.getTime()))throw Fs(Ls.INVALID_DATE_ARGUMENT);a=t}else if(un(t))a=t;else throw Fs(Ls.INVALID_ARGUMENT);return Re(n)?o.key=n:nt(n)&&Object.keys(n).forEach(c=>{Dv.includes(c)?i[c]=n[c]:o[c]=n[c]}),Re(s)?o.locale=s:nt(s)&&(i=s),nt(r)&&(i=r),[o.key||"",a,o,i]}function my(e,t,n){const s=e;for(const r in n){const o=`${t}__${r}`;s.__datetimeFormatters.has(o)&&s.__datetimeFormatters.delete(o)}}function hy(e,...t){const{numberFormats:n,unresolving:s,fallbackLocale:r,onWarn:o,localeFallbacker:i}=e,{__numberFormatters:a}=e,[c,u,l,d]=yf(...t),f=Yt(l.missingWarn)?l.missingWarn:e.missingWarn;Yt(l.fallbackWarn)?l.fallbackWarn:e.fallbackWarn;const p=!!l.part,m=rm(e,l),h=i(e,r,m);if(!Re(c)||c==="")return new Intl.NumberFormat(m,d).format(u);let y={},b,g=null;const w="number format";for(let x=0;x<h.length&&(b=h[x],y=n[b]||{},g=y[c],!nt(g));x++)om(e,c,b,f,w);if(!nt(g)||!Re(b))return s?el:c;let _=`${b}__${c}`;em(d)||(_=`${_}__${JSON.stringify(d)}`);let A=a.get(_);return A||(A=new Intl.NumberFormat(b,Gr({},g,d)),a.set(_,A)),p?A.formatToParts(u):A.format(u)}const Uv=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function yf(...e){const[t,n,s,r]=e,o={};let i={};if(!un(t))throw Fs(Ls.INVALID_ARGUMENT);const a=t;return Re(n)?o.key=n:nt(n)&&Object.keys(n).forEach(c=>{Uv.includes(c)?i[c]=n[c]:o[c]=n[c]}),Re(s)?o.locale=s:nt(s)&&(i=s),nt(r)&&(i=r),[o.key||"",a,o,i]}function yy(e,t,n){const s=e;for(const r in n){const o=`${t}__${r}`;s.__numberFormatters.has(o)&&s.__numberFormatters.delete(o)}}const _x=e=>e,xx=e=>"",Cx="text",Ax=e=>e.length===0?"":nm(e),Tx=b5;function by(e,t){return e=Math.abs(e),t===2?e?e>1?1:0:1:e?Math.min(e,2):0}function Ex(e){const t=un(e.pluralIndex)?e.pluralIndex:-1;return e.named&&(un(e.named.count)||un(e.named.n))?un(e.named.count)?e.named.count:un(e.named.n)?e.named.n:t:t}function Sx(e,t){t.count||(t.count=e),t.n||(t.n=e)}function Px(e={}){const t=e.locale,n=Ex(e),s=kt(e.pluralRules)&&Re(t)&&yt(e.pluralRules[t])?e.pluralRules[t]:by,r=kt(e.pluralRules)&&Re(t)&&yt(e.pluralRules[t])?by:void 0,o=b=>b[s(n,b.length,r)],i=e.list||[],a=b=>i[b],c=e.named||{};un(e.pluralIndex)&&Sx(n,c);const u=b=>c[b];function l(b,g){const w=yt(e.messages)?e.messages(b,!!g):kt(e.messages)?e.messages[b]:!1;return w||(e.parent?e.parent.message(b):xx)}const d=b=>e.modifiers?e.modifiers[b]:_x,f=nt(e.processor)&&yt(e.processor.normalize)?e.processor.normalize:Ax,p=nt(e.processor)&&yt(e.processor.interpolate)?e.processor.interpolate:Tx,m=nt(e.processor)&&Re(e.processor.type)?e.processor.type:Cx,y={list:a,named:u,plural:o,linked:(b,...g)=>{const[w,_]=g;let A="text",x="";g.length===1?kt(w)?(x=w.modifier||x,A=w.type||A):Re(w)&&(x=w||x):g.length===2&&(Re(w)&&(x=w||x),Re(_)&&(A=_||A));const C=l(b,!0)(y),k=A==="vnode"&&cs(C)&&x?C[0]:C;return x?d(x)(k,A):k},message:l,type:m,interpolate:p,normalize:f,values:Gr({},i,c)};return y}const gy=()=>"",_n=e=>yt(e);function vy(e,...t){const{fallbackFormat:n,postTranslation:s,unresolving:r,messageCompiler:o,fallbackLocale:i,messages:a}=e,[c,u]=bf(...t),l=Yt(u.missingWarn)?u.missingWarn:e.missingWarn,d=Yt(u.fallbackWarn)?u.fallbackWarn:e.fallbackWarn,f=Yt(u.escapeParameter)?u.escapeParameter:e.escapeParameter,p=!!u.resolvedMessage,m=Re(u.default)||Yt(u.default)?Yt(u.default)?o?c:()=>c:u.default:n?o?c:()=>c:null,h=n||m!=null&&(Re(m)||yt(m)),y=rm(e,u);f&&kx(u);let[b,g,w]=p?[c,y,a[y]||{}]:Vv(e,c,y,i,d,l),_=b,A=c;if(!p&&!(Re(_)||Ei(_)||_n(_))&&h&&(_=m,A=_),!p&&(!(Re(_)||Ei(_)||_n(_))||!Re(g)))return r?el:c;let x=!1;const C=()=>{x=!0},k=_n(_)?_:jv(e,c,g,_,A,C);if(x)return _;const S=$x(e,g,w,u),R=Px(S),B=Ix(e,k,R),L=s?s(B,c):B;if(__INTLIFY_PROD_DEVTOOLS__){const X={timestamp:Date.now(),key:Re(c)?c:_n(_)?_.key:"",locale:g||(_n(_)?_.locale:""),format:Re(_)?_:_n(_)?_.source:"",message:L};X.meta=Gr({},e.__meta,yx()||{}),Q5(X)}return L}function kx(e){cs(e.list)?e.list=e.list.map(t=>Re(t)?ty(t):t):kt(e.named)&&Object.keys(e.named).forEach(t=>{Re(e.named[t])&&(e.named[t]=ty(e.named[t]))})}function Vv(e,t,n,s,r,o){const{messages:i,onWarn:a,messageResolver:c,localeFallbacker:u}=e,l=u(e,s,n);let d={},f,p=null;const m="translate";for(let h=0;h<l.length&&(f=l[h],d=i[f]||{},(p=c(d,t))===null&&(p=d[t]),!(Re(p)||Ei(p)||_n(p)));h++)if(!wx(f,l)){const y=om(e,t,f,o,m);y!==t&&(p=y)}return[p,f,d]}function jv(e,t,n,s,r,o){const{messageCompiler:i,warnHtmlMessage:a}=e;if(_n(s)){const u=s;return u.locale=u.locale||n,u.key=u.key||t,u}if(i==null){const u=()=>s;return u.locale=n,u.key=t,u}const c=i(s,Rx(e,n,r,s,a,o));return c.locale=n,c.key=t,c.source=s,c}function Ix(e,t,n){return t(n)}function bf(...e){const[t,n,s]=e,r={};if(!Re(t)&&!un(t)&&!_n(t)&&!Ei(t))throw Fs(Ls.INVALID_ARGUMENT);const o=un(t)?String(t):(_n(t),t);return un(n)?r.plural=n:Re(n)?r.default=n:nt(n)&&!em(n)?r.named=n:cs(n)&&(r.list=n),un(s)?r.plural=s:Re(s)?r.default=s:nt(s)&&Gr(r,s),[o,r]}function Rx(e,t,n,s,r,o){return{locale:t,key:n,warnHtmlMessage:r,onError:i=>{throw o&&o(i),i},onCacheKey:i=>f5(t,n,i)}}function $x(e,t,n,s){const{modifiers:r,pluralRules:o,messageResolver:i,fallbackLocale:a,fallbackWarn:c,missingWarn:u,fallbackContext:l}=e,f={locale:t,modifiers:r,pluralRules:o,messages:(p,m)=>{let h=i(n,p);if(h==null&&(l||m)){const[,,y]=Vv(l||e,p,t,a,c,u);h=i(y,p)}if(Re(h)||Ei(h)){let y=!1;const g=jv(e,p,t,h,p,()=>{y=!0});return y?gy:g}else return _n(h)?h:gy}};return e.processor&&(f.processor=e.processor),s.list&&(f.list=s.list),s.named&&(f.named=s.named),un(s.plural)&&(f.pluralIndex=s.plural),f}H5();/**
* @vue/shared v3.5.12
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**//*! #__NO_SIDE_EFFECTS__ */function im(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const ze={},ni=[],us=()=>{},Mx=()=>!1,tl=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),am=e=>e.startsWith("onUpdate:"),at=Object.assign,cm=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},Ox=Object.prototype.hasOwnProperty,We=(e,t)=>Ox.call(e,t),Te=Array.isArray,si=e=>nl(e)==="[object Map]",Hv=e=>nl(e)==="[object Set]",ke=e=>typeof e=="function",ot=e=>typeof e=="string",Ys=e=>typeof e=="symbol",et=e=>e!==null&&typeof e=="object",zv=e=>(et(e)||ke(e))&&ke(e.then)&&ke(e.catch),qv=Object.prototype.toString,nl=e=>qv.call(e),Lx=e=>nl(e).slice(8,-1),Wv=e=>nl(e)==="[object Object]",um=e=>ot(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,xa=im(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),sl=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Fx=/-(\w)/g,fn=sl(e=>e.replace(Fx,(t,n)=>n?n.toUpperCase():"")),Nx=/\B([A-Z])/g,Kr=sl(e=>e.replace(Nx,"-$1").toLowerCase()),rl=sl(e=>e.charAt(0).toUpperCase()+e.slice(1)),Ed=sl(e=>e?`on${rl(e)}`:""),Zt=(e,t)=>!Object.is(e,t),hu=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},Gv=(e,t,n,s=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:s,value:n})},gf=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Bx=e=>{const t=ot(e)?Number(e):NaN;return isNaN(t)?e:t};let wy;const ol=()=>wy||(wy=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function il(e){if(Te(e)){const t={};for(let n=0;n<e.length;n++){const s=e[n],r=ot(s)?jx(s):il(s);if(r)for(const o in r)t[o]=r[o]}return t}else if(ot(e)||et(e))return e}const Dx=/;(?![^(]*\))/g,Ux=/:([^]+)/,Vx=/\/\*[^]*?\*\//g;function jx(e){const t={};return e.replace(Vx,"").split(Dx).forEach(n=>{if(n){const s=n.split(Ux);s.length>1&&(t[s[0].trim()]=s[1].trim())}}),t}function Pe(e){let t="";if(ot(e))t=e;else if(Te(e))for(let n=0;n<e.length;n++){const s=Pe(e[n]);s&&(t+=s+" ")}else if(et(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const Hx="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",zx=im(Hx);function Xv(e){return!!e||e===""}const Kv=e=>!!(e&&e.__v_isRef===!0),Z=e=>ot(e)?e:e==null?"":Te(e)||et(e)&&(e.toString===qv||!ke(e.toString))?Kv(e)?Z(e.value):JSON.stringify(e,Qv,2):String(e),Qv=(e,t)=>Kv(t)?Qv(e,t.value):si(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[s,r],o)=>(n[Sd(s,o)+" =>"]=r,n),{})}:Hv(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>Sd(n))}:Ys(t)?Sd(t):et(t)&&!Te(t)&&!Wv(t)?String(t):t,Sd=(e,t="")=>{var n;return Ys(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
* @vue/reactivity v3.5.12
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/let Ht;class Zv{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=Ht,!t&&Ht&&(this.index=(Ht.scopes||(Ht.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].pause();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,n;if(this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].resume();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].resume()}}run(t){if(this._active){const n=Ht;try{return Ht=this,t()}finally{Ht=n}}}on(){Ht=this}off(){Ht=this.parent}stop(t){if(this._active){let n,s;for(n=0,s=this.effects.length;n<s;n++)this.effects[n].stop();for(n=0,s=this.cleanups.length;n<s;n++)this.cleanups[n]();if(this.scopes)for(n=0,s=this.scopes.length;n<s;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0,this._active=!1}}}function lm(e){return new Zv(e)}function dm(){return Ht}function Wn(e,t=!1){Ht&&Ht.cleanups.push(e)}let Je;const Pd=new WeakSet;class Yv{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,Ht&&Ht.active&&Ht.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Pd.has(this)&&(Pd.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||e1(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,_y(this),t1(this);const t=Je,n=Nn;Je=this,Nn=!0;try{return this.fn()}finally{n1(this),Je=t,Nn=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)mm(t);this.deps=this.depsTail=void 0,_y(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Pd.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){vf(this)&&this.run()}get dirty(){return vf(this)}}let Jv=0,Ca,Aa;function e1(e,t=!1){if(e.flags|=8,t){e.next=Aa,Aa=e;return}e.next=Ca,Ca=e}function fm(){Jv++}function pm(){if(--Jv>0)return;if(Aa){let t=Aa;for(Aa=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;Ca;){let t=Ca;for(Ca=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(s){e||(e=s)}t=n}}if(e)throw e}function t1(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function n1(e){let t,n=e.depsTail,s=n;for(;s;){const r=s.prevDep;s.version===-1?(s===n&&(n=r),mm(s),qx(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=r}e.deps=t,e.depsTail=n}function vf(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(s1(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function s1(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Da))return;e.globalVersion=Da;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!vf(e)){e.flags&=-3;return}const n=Je,s=Nn;Je=e,Nn=!0;try{t1(e);const r=e.fn(e._value);(t.version===0||Zt(r,e._value))&&(e._value=r,t.version++)}catch(r){throw t.version++,r}finally{Je=n,Nn=s,n1(e),e.flags&=-3}}function mm(e,t=!1){const{dep:n,prevSub:s,nextSub:r}=e;if(s&&(s.nextSub=r,e.prevSub=void 0),r&&(r.prevSub=s,e.nextSub=void 0),n.subs===e&&(n.subs=s,!s&&n.computed)){n.computed.flags&=-5;for(let o=n.computed.deps;o;o=o.nextDep)mm(o,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function qx(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Nn=!0;const r1=[];function Qr(){r1.push(Nn),Nn=!1}function Zr(){const e=r1.pop();Nn=e===void 0?!0:e}function _y(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=Je;Je=void 0;try{t()}finally{Je=n}}}let Da=0;class Wx{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class al{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0}track(t){if(!Je||!Nn||Je===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==Je)n=this.activeLink=new Wx(Je,this),Je.deps?(n.prevDep=Je.depsTail,Je.depsTail.nextDep=n,Je.depsTail=n):Je.deps=Je.depsTail=n,o1(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const s=n.nextDep;s.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=s),n.prevDep=Je.depsTail,n.nextDep=void 0,Je.depsTail.nextDep=n,Je.depsTail=n,Je.deps===n&&(Je.deps=s)}return n}trigger(t){this.version++,Da++,this.notify(t)}notify(t){fm();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{pm()}}}function o1(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let s=t.deps;s;s=s.nextDep)o1(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const Iu=new WeakMap,yo=Symbol(""),wf=Symbol(""),Ua=Symbol("");function Lt(e,t,n){if(Nn&&Je){let s=Iu.get(e);s||Iu.set(e,s=new Map);let r=s.get(n);r||(s.set(n,r=new al),r.map=s,r.key=n),r.track()}}function Rs(e,t,n,s,r,o){const i=Iu.get(e);if(!i){Da++;return}const a=c=>{c&&c.trigger()};if(fm(),t==="clear")i.forEach(a);else{const c=Te(e),u=c&&um(n);if(c&&n==="length"){const l=Number(s);i.forEach((d,f)=>{(f==="length"||f===Ua||!Ys(f)&&f>=l)&&a(d)})}else switch((n!==void 0||i.has(void 0))&&a(i.get(n)),u&&a(i.get(Ua)),t){case"add":c?u&&a(i.get("length")):(a(i.get(yo)),si(e)&&a(i.get(wf)));break;case"delete":c||(a(i.get(yo)),si(e)&&a(i.get(wf)));break;case"set":si(e)&&a(i.get(yo));break}}pm()}function Gx(e,t){const n=Iu.get(e);return n&&n.get(t)}function Wo(e){const t=Ve(e);return t===e?t:(Lt(t,"iterate",Ua),Tn(e)?t:t.map(Ft))}function cl(e){return Lt(e=Ve(e),"iterate",Ua),e}const Xx={__proto__:null,[Symbol.iterator](){return kd(this,Symbol.iterator,Ft)},concat(...e){return Wo(this).concat(...e.map(t=>Te(t)?Wo(t):t))},entries(){return kd(this,"entries",e=>(e[1]=Ft(e[1]),e))},every(e,t){return ws(this,"every",e,t,void 0,arguments)},filter(e,t){return ws(this,"filter",e,t,n=>n.map(Ft),arguments)},find(e,t){return ws(this,"find",e,t,Ft,arguments)},findIndex(e,t){return ws(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return ws(this,"findLast",e,t,Ft,arguments)},findLastIndex(e,t){return ws(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return ws(this,"forEach",e,t,void 0,arguments)},includes(...e){return Id(this,"includes",e)},indexOf(...e){return Id(this,"indexOf",e)},join(e){return Wo(this).join(e)},lastIndexOf(...e){return Id(this,"lastIndexOf",e)},map(e,t){return ws(this,"map",e,t,void 0,arguments)},pop(){return da(this,"pop")},push(...e){return da(this,"push",e)},reduce(e,...t){return xy(this,"reduce",e,t)},reduceRight(e,...t){return xy(this,"reduceRight",e,t)},shift(){return da(this,"shift")},some(e,t){return ws(this,"some",e,t,void 0,arguments)},splice(...e){return da(this,"splice",e)},toReversed(){return Wo(this).toReversed()},toSorted(e){return Wo(this).toSorted(e)},toSpliced(...e){return Wo(this).toSpliced(...e)},unshift(...e){return da(this,"unshift",e)},values(){return kd(this,"values",Ft)}};function kd(e,t,n){const s=cl(e),r=s[t]();return s!==e&&!Tn(e)&&(r._next=r.next,r.next=()=>{const o=r._next();return o.value&&(o.value=n(o.value)),o}),r}const Kx=Array.prototype;function ws(e,t,n,s,r,o){const i=cl(e),a=i!==e&&!Tn(e),c=i[t];if(c!==Kx[t]){const d=c.apply(e,o);return a?Ft(d):d}let u=n;i!==e&&(a?u=function(d,f){return n.call(this,Ft(d),f,e)}:n.length>2&&(u=function(d,f){return n.call(this,d,f,e)}));const l=c.call(i,u,s);return a&&r?r(l):l}function xy(e,t,n,s){const r=cl(e);let o=n;return r!==e&&(Tn(e)?n.length>3&&(o=function(i,a,c){return n.call(this,i,a,c,e)}):o=function(i,a,c){return n.call(this,i,Ft(a),c,e)}),r[t](o,...s)}function Id(e,t,n){const s=Ve(e);Lt(s,"iterate",Ua);const r=s[t](...n);return(r===-1||r===!1)&&bm(n[0])?(n[0]=Ve(n[0]),s[t](...n)):r}function da(e,t,n=[]){Qr(),fm();const s=Ve(e)[t].apply(e,n);return pm(),Zr(),s}const Qx=im("__proto__,__v_isRef,__isVue"),i1=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Ys));function Zx(e){Ys(e)||(e=String(e));const t=Ve(this);return Lt(t,"has",e),t.hasOwnProperty(e)}class a1{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,s){const r=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return o;if(n==="__v_raw")return s===(r?o?a3:d1:o?l1:u1).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const i=Te(t);if(!r){let c;if(i&&(c=Xx[n]))return c;if(n==="hasOwnProperty")return Zx}const a=Reflect.get(t,n,$e(t)?t:s);return(Ys(n)?i1.has(n):Qx(n))||(r||Lt(t,"get",n),o)?a:$e(a)?i&&um(n)?a:a.value:et(a)?r?No(a):zs(a):a}}class c1 extends a1{constructor(t=!1){super(!1,t)}set(t,n,s,r){let o=t[n];if(!this._isShallow){const c=Co(o);if(!Tn(s)&&!Co(s)&&(o=Ve(o),s=Ve(s)),!Te(t)&&$e(o)&&!$e(s))return c?!1:(o.value=s,!0)}const i=Te(t)&&um(n)?Number(n)<t.length:We(t,n),a=Reflect.set(t,n,s,$e(t)?t:r);return t===Ve(r)&&(i?Zt(s,o)&&Rs(t,"set",n,s):Rs(t,"add",n,s)),a}deleteProperty(t,n){const s=We(t,n);t[n];const r=Reflect.deleteProperty(t,n);return r&&s&&Rs(t,"delete",n,void 0),r}has(t,n){const s=Reflect.has(t,n);return(!Ys(n)||!i1.has(n))&&Lt(t,"has",n),s}ownKeys(t){return Lt(t,"iterate",Te(t)?"length":yo),Reflect.ownKeys(t)}}class Yx extends a1{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const Jx=new c1,e3=new Yx,t3=new c1(!0);const _f=e=>e,zc=e=>Reflect.getPrototypeOf(e);function n3(e,t,n){return function(...s){const r=this.__v_raw,o=Ve(r),i=si(o),a=e==="entries"||e===Symbol.iterator&&i,c=e==="keys"&&i,u=r[e](...s),l=n?_f:t?xf:Ft;return!t&&Lt(o,"iterate",c?wf:yo),{next(){const{value:d,done:f}=u.next();return f?{value:d,done:f}:{value:a?[l(d[0]),l(d[1])]:l(d),done:f}},[Symbol.iterator](){return this}}}}function qc(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function s3(e,t){const n={get(r){const o=this.__v_raw,i=Ve(o),a=Ve(r);e||(Zt(r,a)&&Lt(i,"get",r),Lt(i,"get",a));const{has:c}=zc(i),u=t?_f:e?xf:Ft;if(c.call(i,r))return u(o.get(r));if(c.call(i,a))return u(o.get(a));o!==i&&o.get(r)},get size(){const r=this.__v_raw;return!e&&Lt(Ve(r),"iterate",yo),Reflect.get(r,"size",r)},has(r){const o=this.__v_raw,i=Ve(o),a=Ve(r);return e||(Zt(r,a)&&Lt(i,"has",r),Lt(i,"has",a)),r===a?o.has(r):o.has(r)||o.has(a)},forEach(r,o){const i=this,a=i.__v_raw,c=Ve(a),u=t?_f:e?xf:Ft;return!e&&Lt(c,"iterate",yo),a.forEach((l,d)=>r.call(o,u(l),u(d),i))}};return at(n,e?{add:qc("add"),set:qc("set"),delete:qc("delete"),clear:qc("clear")}:{add(r){!t&&!Tn(r)&&!Co(r)&&(r=Ve(r));const o=Ve(this);return zc(o).has.call(o,r)||(o.add(r),Rs(o,"add",r,r)),this},set(r,o){!t&&!Tn(o)&&!Co(o)&&(o=Ve(o));const i=Ve(this),{has:a,get:c}=zc(i);let u=a.call(i,r);u||(r=Ve(r),u=a.call(i,r));const l=c.call(i,r);return i.set(r,o),u?Zt(o,l)&&Rs(i,"set",r,o):Rs(i,"add",r,o),this},delete(r){const o=Ve(this),{has:i,get:a}=zc(o);let c=i.call(o,r);c||(r=Ve(r),c=i.call(o,r)),a&&a.call(o,r);const u=o.delete(r);return c&&Rs(o,"delete",r,void 0),u},clear(){const r=Ve(this),o=r.size!==0,i=r.clear();return o&&Rs(r,"clear",void 0,void 0),i}}),["keys","values","entries",Symbol.iterator].forEach(r=>{n[r]=n3(r,e,t)}),n}function hm(e,t){const n=s3(e,t);return(s,r,o)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?s:Reflect.get(We(n,r)&&r in s?n:s,r,o)}const r3={get:hm(!1,!1)},o3={get:hm(!1,!0)},i3={get:hm(!0,!1)};const u1=new WeakMap,l1=new WeakMap,d1=new WeakMap,a3=new WeakMap;function c3(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function u3(e){return e.__v_skip||!Object.isExtensible(e)?0:c3(Lx(e))}function zs(e){return Co(e)?e:ym(e,!1,Jx,r3,u1)}function ul(e){return ym(e,!1,t3,o3,l1)}function No(e){return ym(e,!0,e3,i3,d1)}function ym(e,t,n,s,r){if(!et(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=r.get(e);if(o)return o;const i=u3(e);if(i===0)return e;const a=new Proxy(e,i===2?s:n);return r.set(e,a),a}function Bs(e){return Co(e)?Bs(e.__v_raw):!!(e&&e.__v_isReactive)}function Co(e){return!!(e&&e.__v_isReadonly)}function Tn(e){return!!(e&&e.__v_isShallow)}function bm(e){return e?!!e.__v_raw:!1}function Ve(e){const t=e&&e.__v_raw;return t?Ve(t):e}function gm(e){return!We(e,"__v_skip")&&Object.isExtensible(e)&&Gv(e,"__v_skip",!0),e}const Ft=e=>et(e)?zs(e):e,xf=e=>et(e)?No(e):e;function $e(e){return e?e.__v_isRef===!0:!1}function le(e){return f1(e,!1)}function Bo(e){return f1(e,!0)}function f1(e,t){return $e(e)?e:new l3(e,t)}class l3{constructor(t,n){this.dep=new al,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:Ve(t),this._value=n?t:Ft(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,s=this.__v_isShallow||Tn(t)||Co(t);t=s?t:Ve(t),Zt(t,n)&&(this._rawValue=t,this._value=s?t:Ft(t),this.dep.trigger())}}function v(e){return $e(e)?e.value:e}const d3={get:(e,t,n)=>t==="__v_raw"?e:v(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const r=e[t];return $e(r)&&!$e(n)?(r.value=n,!0):Reflect.set(e,t,n,s)}};function p1(e){return Bs(e)?e:new Proxy(e,d3)}class f3{constructor(t){this.__v_isRef=!0,this._value=void 0;const n=this.dep=new al,{get:s,set:r}=t(n.track.bind(n),n.trigger.bind(n));this._get=s,this._set=r}get value(){return this._value=this._get()}set value(t){this._set(t)}}function m1(e){return new f3(e)}function ll(e){const t=Te(e)?new Array(e.length):{};for(const n in e)t[n]=y1(e,n);return t}class p3{constructor(t,n,s){this._object=t,this._key=n,this._defaultValue=s,this.__v_isRef=!0,this._value=void 0}get value(){const t=this._object[this._key];return this._value=t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return Gx(Ve(this._object),this._key)}}class m3{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function h1(e,t,n){return $e(e)?e:ke(e)?new m3(e):et(e)&&arguments.length>1?y1(e,t,n):le(e)}function y1(e,t,n){const s=e[t];return $e(s)?s:new p3(e,t,n)}class h3{constructor(t,n,s){this.fn=t,this.setter=n,this._value=void 0,this.dep=new al(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Da-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=s}notify(){if(this.flags|=16,!(this.flags&8)&&Je!==this)return e1(this,!0),!0}get value(){const t=this.dep.track();return s1(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function y3(e,t,n=!1){let s,r;return ke(e)?s=e:(s=e.get,r=e.set),new h3(s,r,n)}const Wc={},Ru=new WeakMap;let ro;function b3(e,t=!1,n=ro){if(n){let s=Ru.get(n);s||Ru.set(n,s=[]),s.push(e)}}function g3(e,t,n=ze){const{immediate:s,deep:r,once:o,scheduler:i,augmentJob:a,call:c}=n,u=_=>r?_:Tn(_)||r===!1||r===0?$s(_,1):$s(_);let l,d,f,p,m=!1,h=!1;if($e(e)?(d=()=>e.value,m=Tn(e)):Bs(e)?(d=()=>u(e),m=!0):Te(e)?(h=!0,m=e.some(_=>Bs(_)||Tn(_)),d=()=>e.map(_=>{if($e(_))return _.value;if(Bs(_))return u(_);if(ke(_))return c?c(_,2):_()})):ke(e)?t?d=c?()=>c(e,2):e:d=()=>{if(f){Qr();try{f()}finally{Zr()}}const _=ro;ro=l;try{return c?c(e,3,[p]):e(p)}finally{ro=_}}:d=us,t&&r){const _=d,A=r===!0?1/0:r;d=()=>$s(_(),A)}const y=dm(),b=()=>{l.stop(),y&&cm(y.effects,l)};if(o&&t){const _=t;t=(...A)=>{_(...A),b()}}let g=h?new Array(e.length).fill(Wc):Wc;const w=_=>{if(!(!(l.flags&1)||!l.dirty&&!_))if(t){const A=l.run();if(r||m||(h?A.some((x,C)=>Zt(x,g[C])):Zt(A,g))){f&&f();const x=ro;ro=l;try{const C=[A,g===Wc?void 0:h&&g[0]===Wc?[]:g,p];c?c(t,3,C):t(...C),g=A}finally{ro=x}}}else l.run()};return a&&a(w),l=new Yv(d),l.scheduler=i?()=>i(w,!1):w,p=_=>b3(_,!1,l),f=l.onStop=()=>{const _=Ru.get(l);if(_){if(c)c(_,4);else for(const A of _)A();Ru.delete(l)}},t?s?w(!0):g=l.run():i?i(w.bind(null,!0),!0):l.run(),b.pause=l.pause.bind(l),b.resume=l.resume.bind(l),b.stop=b,b}function $s(e,t=1/0,n){if(t<=0||!et(e)||e.__v_skip||(n=n||new Set,n.has(e)))return e;if(n.add(e),t--,$e(e))$s(e.value,t,n);else if(Te(e))for(let s=0;s<e.length;s++)$s(e[s],t,n);else if(Hv(e)||si(e))e.forEach(s=>{$s(s,t,n)});else if(Wv(e)){for(const s in e)$s(e[s],t,n);for(const s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&$s(e[s],t,n)}return e}/**
* @vue/runtime-core v3.5.12
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/function vc(e,t,n,s){try{return s?e(...s):e()}catch(r){wc(r,t,n)}}function Vn(e,t,n,s){if(ke(e)){const r=vc(e,t,n,s);return r&&zv(r)&&r.catch(o=>{wc(o,t,n)}),r}if(Te(e)){const r=[];for(let o=0;o<e.length;o++)r.push(Vn(e[o],t,n,s));return r}}function wc(e,t,n,s=!0){const r=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:i}=t&&t.appContext.config||ze;if(t){let a=t.parent;const c=t.proxy,u=`https://vuejs.org/error-reference/#runtime-${n}`;for(;a;){const l=a.ec;if(l){for(let d=0;d<l.length;d++)if(l[d](e,c,u)===!1)return}a=a.parent}if(o){Qr(),vc(o,null,10,[e,c,u]),Zr();return}}v3(e,n,r,s,i)}function v3(e,t,n,s=!0,r=!1){if(r)throw e;console.error(e)}const zt=[];let Jn=-1;const ri=[];let mr=null,Qo=0;const b1=Promise.resolve();let $u=null;function Js(e){const t=$u||b1;return e?t.then(this?e.bind(this):e):t}function w3(e){let t=Jn+1,n=zt.length;for(;t<n;){const s=t+n>>>1,r=zt[s],o=Va(r);o<e||o===e&&r.flags&2?t=s+1:n=s}return t}function vm(e){if(!(e.flags&1)){const t=Va(e),n=zt[zt.length-1];!n||!(e.flags&2)&&t>=Va(n)?zt.push(e):zt.splice(w3(t),0,e),e.flags|=1,g1()}}function g1(){$u||($u=b1.then(w1))}function _3(e){Te(e)?ri.push(...e):mr&&e.id===-1?mr.splice(Qo+1,0,e):e.flags&1||(ri.push(e),e.flags|=1),g1()}function Cy(e,t,n=Jn+1){for(;n<zt.length;n++){const s=zt[n];if(s&&s.flags&2){if(e&&s.id!==e.uid)continue;zt.splice(n,1),n--,s.flags&4&&(s.flags&=-2),s(),s.flags&4||(s.flags&=-2)}}}function v1(e){if(ri.length){const t=[...new Set(ri)].sort((n,s)=>Va(n)-Va(s));if(ri.length=0,mr){mr.push(...t);return}for(mr=t,Qo=0;Qo<mr.length;Qo++){const n=mr[Qo];n.flags&4&&(n.flags&=-2),n.flags&8||n(),n.flags&=-2}mr=null,Qo=0}}const Va=e=>e.id==null?e.flags&2?-1:1/0:e.id;function w1(e){try{for(Jn=0;Jn<zt.length;Jn++){const t=zt[Jn];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),vc(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Jn<zt.length;Jn++){const t=zt[Jn];t&&(t.flags&=-2)}Jn=-1,zt.length=0,v1(),$u=null,(zt.length||ri.length)&&w1()}}let vt=null,_1=null;function Mu(e){const t=vt;return vt=e,_1=e&&e.type.__scopeId||null,t}function Y(e,t=vt,n){if(!t||e._n)return e;const s=(...r)=>{s._d&&Ly(-1);const o=Mu(t);let i;try{i=e(...r)}finally{Mu(o),s._d&&Ly(1)}return i};return s._n=!0,s._c=!0,s._d=!0,s}function wm(e,t){if(vt===null)return e;const n=yl(vt),s=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[o,i,a,c=ze]=t[r];o&&(ke(o)&&(o={mounted:o,updated:o}),o.deep&&$s(i),s.push({dir:o,instance:n,value:i,oldValue:void 0,arg:a,modifiers:c}))}return e}function to(e,t,n,s){const r=e.dirs,o=t&&t.dirs;for(let i=0;i<r.length;i++){const a=r[i];o&&(a.oldValue=o[i].value);let c=a.dir[s];c&&(Qr(),Vn(c,n,8,[e.el,a,e,t]),Zr())}}const x1=Symbol("_vte"),C1=e=>e.__isTeleport,Ta=e=>e&&(e.disabled||e.disabled===""),x3=e=>e&&(e.defer||e.defer===""),Ay=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Ty=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,Cf=(e,t)=>{const n=e&&e.to;return ot(n)?t?t(n):null:n},C3={name:"Teleport",__isTeleport:!0,process(e,t,n,s,r,o,i,a,c,u){const{mc:l,pc:d,pbc:f,o:{insert:p,querySelector:m,createText:h,createComment:y}}=u,b=Ta(t.props);let{shapeFlag:g,children:w,dynamicChildren:_}=t;if(e==null){const A=t.el=h(""),x=t.anchor=h("");p(A,n,s),p(x,n,s);const C=(S,R)=>{g&16&&(r&&r.isCE&&(r.ce._teleportTarget=S),l(w,S,R,r,o,i,a,c))},k=()=>{const S=t.target=Cf(t.props,m),R=A1(S,t,h,p);S&&(i!=="svg"&&Ay(S)?i="svg":i!=="mathml"&&Ty(S)&&(i="mathml"),b||(C(S,R),yu(t,!1)))};b&&(C(n,x),yu(t,!0)),x3(t.props)?Gt(k,o):k()}else{t.el=e.el,t.targetStart=e.targetStart;const A=t.anchor=e.anchor,x=t.target=e.target,C=t.targetAnchor=e.targetAnchor,k=Ta(e.props),S=k?n:x,R=k?A:C;if(i==="svg"||Ay(x)?i="svg":(i==="mathml"||Ty(x))&&(i="mathml"),_?(f(e.dynamicChildren,_,S,r,o,i,a),Pm(e,t,!0)):c||d(e,t,S,R,r,o,i,a,!1),b)k?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Gc(t,n,A,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const B=t.target=Cf(t.props,m);B&&Gc(t,B,null,u,0)}else k&&Gc(t,x,C,u,1);yu(t,b)}},remove(e,t,n,{um:s,o:{remove:r}},o){const{shapeFlag:i,children:a,anchor:c,targetStart:u,targetAnchor:l,target:d,props:f}=e;if(d&&(r(u),r(l)),o&&r(c),i&16){const p=o||!Ta(f);for(let m=0;m<a.length;m++){const h=a[m];s(h,t,n,p,!!h.dynamicChildren)}}},move:Gc,hydrate:A3};function Gc(e,t,n,{o:{insert:s},m:r},o=2){o===0&&s(e.targetAnchor,t,n);const{el:i,anchor:a,shapeFlag:c,children:u,props:l}=e,d=o===2;if(d&&s(i,t,n),(!d||Ta(l))&&c&16)for(let f=0;f<u.length;f++)r(u[f],t,n,2);d&&s(a,t,n)}function A3(e,t,n,s,r,o,{o:{nextSibling:i,parentNode:a,querySelector:c,insert:u,createText:l}},d){const f=t.target=Cf(t.props,c);if(f){const p=Ta(t.props),m=f._lpa||f.firstChild;if(t.shapeFlag&16)if(p)t.anchor=d(i(e),t,a(e),n,s,r,o),t.targetStart=m,t.targetAnchor=m&&i(m);else{t.anchor=i(e);let h=m;for(;h;){if(h&&h.nodeType===8){if(h.data==="teleport start anchor")t.targetStart=h;else if(h.data==="teleport anchor"){t.targetAnchor=h,f._lpa=t.targetAnchor&&i(t.targetAnchor);break}}h=i(h)}t.targetAnchor||A1(f,t,l,u),d(m&&i(m),t,f,n,s,r,o)}yu(t,p)}return t.anchor&&i(t.anchor)}const T3=C3;function yu(e,t){const n=e.ctx;if(n&&n.ut){let s,r;for(t?(s=e.el,r=e.anchor):(s=e.targetStart,r=e.targetAnchor);s&&s!==r;)s.nodeType===1&&s.setAttribute("data-v-owner",n.uid),s=s.nextSibling;n.ut()}}function A1(e,t,n,s){const r=t.targetStart=n(""),o=t.targetAnchor=n("");return r[x1]=o,e&&(s(r,e),s(o,e)),o}const hr=Symbol("_leaveCb"),Xc=Symbol("_enterCb");function T1(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Gn(()=>{e.isMounted=!0}),fl(()=>{e.isUnmounting=!0}),e}const yn=[Function,Array],E1={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:yn,onEnter:yn,onAfterEnter:yn,onEnterCancelled:yn,onBeforeLeave:yn,onLeave:yn,onAfterLeave:yn,onLeaveCancelled:yn,onBeforeAppear:yn,onAppear:yn,onAfterAppear:yn,onAppearCancelled:yn},S1=e=>{const t=e.subTree;return t.component?S1(t.component):t},E3={name:"BaseTransition",props:E1,setup(e,{slots:t}){const n=bs(),s=T1();return()=>{const r=t.default&&_m(t.default(),!0);if(!r||!r.length)return;const o=P1(r),i=Ve(e),{mode:a}=i;if(s.isLeaving)return Rd(o);const c=Ey(o);if(!c)return Rd(o);let u=ja(c,i,s,n,f=>u=f);c.type!==qt&&Ao(c,u);const l=n.subTree,d=l&&Ey(l);if(d&&d.type!==qt&&!oo(c,d)&&S1(n).type!==qt){const f=ja(d,i,s,n);if(Ao(d,f),a==="out-in"&&c.type!==qt)return s.isLeaving=!0,f.afterLeave=()=>{s.isLeaving=!1,n.job.flags&8||n.update(),delete f.afterLeave},Rd(o);a==="in-out"&&c.type!==qt&&(f.delayLeave=(p,m,h)=>{const y=k1(s,d);y[String(d.key)]=d,p[hr]=()=>{m(),p[hr]=void 0,delete u.delayedLeave},u.delayedLeave=h})}return o}}};function P1(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==qt){t=n;break}}return t}const S3=E3;function k1(e,t){const{leavingVNodes:n}=e;let s=n.get(t.type);return s||(s=Object.create(null),n.set(t.type,s)),s}function ja(e,t,n,s,r){const{appear:o,mode:i,persisted:a=!1,onBeforeEnter:c,onEnter:u,onAfterEnter:l,onEnterCancelled:d,onBeforeLeave:f,onLeave:p,onAfterLeave:m,onLeaveCancelled:h,onBeforeAppear:y,onAppear:b,onAfterAppear:g,onAppearCancelled:w}=t,_=String(e.key),A=k1(n,e),x=(S,R)=>{S&&Vn(S,s,9,R)},C=(S,R)=>{const B=R[1];x(S,R),Te(S)?S.every(L=>L.length<=1)&&B():S.length<=1&&B()},k={mode:i,persisted:a,beforeEnter(S){let R=c;if(!n.isMounted)if(o)R=y||c;else return;S[hr]&&S[hr](!0);const B=A[_];B&&oo(e,B)&&B.el[hr]&&B.el[hr](),x(R,[S])},enter(S){let R=u,B=l,L=d;if(!n.isMounted)if(o)R=b||u,B=g||l,L=w||d;else return;let X=!1;const z=S[Xc]=ie=>{X||(X=!0,ie?x(L,[S]):x(B,[S]),k.delayedLeave&&k.delayedLeave(),S[Xc]=void 0)};R?C(R,[S,z]):z()},leave(S,R){const B=String(e.key);if(S[Xc]&&S[Xc](!0),n.isUnmounting)return R();x(f,[S]);let L=!1;const X=S[hr]=z=>{L||(L=!0,R(),z?x(h,[S]):x(m,[S]),S[hr]=void 0,A[B]===e&&delete A[B])};A[B]=e,p?C(p,[S,X]):X()},clone(S){const R=ja(S,t,n,s,r);return r&&r(R),R}};return k}function Rd(e){if(_c(e))return e=Lr(e),e.children=null,e}function Ey(e){if(!_c(e))return C1(e.type)&&e.children?P1(e.children):e;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&ke(n.default))return n.default()}}function Ao(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Ao(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function _m(e,t=!1,n){let s=[],r=0;for(let o=0;o<e.length;o++){let i=e[o];const a=n==null?i.key:String(n)+String(i.key!=null?i.key:o);i.type===De?(i.patchFlag&128&&r++,s=s.concat(_m(i.children,t,a))):(t||i.type!==qt)&&s.push(a!=null?Lr(i,{key:a}):i)}if(r>1)for(let o=0;o<s.length;o++)s[o].patchFlag=-2;return s}/*! #__NO_SIDE_EFFECTS__ */function ae(e,t){return ke(e)?at({name:e.name},t,{setup:e}):e}function xm(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Af(e){const t=bs(),n=Bo(null);if(t){const r=t.refs===ze?t.refs={}:t.refs;Object.defineProperty(r,e,{enumerable:!0,get:()=>n.value,set:o=>n.value=o})}return n}function Tf(e,t,n,s,r=!1){if(Te(e)){e.forEach((m,h)=>Tf(m,t&&(Te(t)?t[h]:t),n,s,r));return}if(oi(s)&&!r)return;const o=s.shapeFlag&4?yl(s.component):s.el,i=r?null:o,{i:a,r:c}=e,u=t&&t.r,l=a.refs===ze?a.refs={}:a.refs,d=a.setupState,f=Ve(d),p=d===ze?()=>!1:m=>We(f,m);if(u!=null&&u!==c&&(ot(u)?(l[u]=null,p(u)&&(d[u]=null)):$e(u)&&(u.value=null)),ke(c))vc(c,a,12,[i,l]);else{const m=ot(c),h=$e(c);if(m||h){const y=()=>{if(e.f){const b=m?p(c)?d[c]:l[c]:c.value;r?Te(b)&&cm(b,o):Te(b)?b.includes(o)||b.push(o):m?(l[c]=[o],p(c)&&(d[c]=l[c])):(c.value=[o],e.k&&(l[e.k]=c.value))}else m?(l[c]=i,p(c)&&(d[c]=i)):h&&(c.value=i,e.k&&(l[e.k]=i))};i?(y.id=-1,Gt(y,n)):y()}}}const Sy=e=>e.nodeType===8;ol().requestIdleCallback;ol().cancelIdleCallback;function P3(e,t){if(Sy(e)&&e.data==="["){let n=1,s=e.nextSibling;for(;s;){if(s.nodeType===1){if(t(s)===!1)break}else if(Sy(s))if(s.data==="]"){if(--n===0)break}else s.data==="["&&n++;s=s.nextSibling}}else t(e)}const oi=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function k3(e){ke(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:s,delay:r=200,hydrate:o,timeout:i,suspensible:a=!0,onError:c}=e;let u=null,l,d=0;const f=()=>(d++,u=null,p()),p=()=>{let m;return u||(m=u=t().catch(h=>{if(h=h instanceof Error?h:new Error(String(h)),c)return new Promise((y,b)=>{c(h,()=>y(f()),()=>b(h),d+1)});throw h}).then(h=>m!==u&&u?u:(h&&(h.__esModule||h[Symbol.toStringTag]==="Module")&&(h=h.default),l=h,h)))};return ae({name:"AsyncComponentWrapper",__asyncLoader:p,__asyncHydrate(m,h,y){const b=o?()=>{const g=o(y,w=>P3(m,w));g&&(h.bum||(h.bum=[])).push(g)}:y;l?b():p().then(()=>!h.isUnmounted&&b())},get __asyncResolved(){return l},setup(){const m=gt;if(xm(m),l)return()=>$d(l,m);const h=w=>{u=null,wc(w,m,13,!s)};if(a&&m.suspense||Pi)return p().then(w=>()=>$d(w,m)).catch(w=>(h(w),()=>s?$(s,{error:w}):null));const y=le(!1),b=le(),g=le(!!r);return r&&setTimeout(()=>{g.value=!1},r),i!=null&&setTimeout(()=>{if(!y.value&&!b.value){const w=new Error(`Async component timed out after ${i}ms.`);h(w),b.value=w}},i),p().then(()=>{y.value=!0,m.parent&&_c(m.parent.vnode)&&m.parent.update()}).catch(w=>{h(w),b.value=w}),()=>{if(y.value&&l)return $d(l,m);if(b.value&&s)return $(s,{error:b.value});if(n&&!g.value)return $(n)}}})}function $d(e,t){const{ref:n,props:s,children:r,ce:o}=t.vnode,i=$(e,s,r);return i.ref=n,i.ce=o,delete t.vnode.ce,i}const _c=e=>e.type.__isKeepAlive;function I3(e,t){I1(e,"a",t)}function R3(e,t){I1(e,"da",t)}function I1(e,t,n=gt){const s=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(dl(t,s,n),n){let r=n.parent;for(;r&&r.parent;)_c(r.parent.vnode)&&$3(s,t,n,r),r=r.parent}}function $3(e,t,n,s){const r=dl(t,e,s,!0);Qi(()=>{cm(s[t],r)},n)}function dl(e,t,n=gt,s=!1){if(n){const r=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...i)=>{Qr();const a=Cc(n),c=Vn(t,n,e,i);return a(),Zr(),c});return s?r.unshift(o):r.push(o),o}}const er=e=>(t,n=gt)=>{(!Pi||e==="sp")&&dl(e,(...s)=>t(...s),n)},Cm=er("bm"),Gn=er("m"),M3=er("bu"),R1=er("u"),fl=er("bum"),Qi=er("um"),O3=er("sp"),L3=er("rtg"),F3=er("rtc");function N3(e,t=gt){dl("ec",e,t)}const $1="components";function Ha(e,t){return O1($1,e,!0,t)||e}const M1=Symbol.for("v-ndc");function Ou(e){return ot(e)?O1($1,e,!1)||e:e||M1}function O1(e,t,n=!0,s=!1){const r=vt||gt;if(r){const o=r.type;{const a=CC(o,!1);if(a&&(a===t||a===fn(t)||a===rl(fn(t))))return o}const i=Py(r[e]||o[e],t)||Py(r.appContext[e],t);return!i&&s?o:i}}function Py(e,t){return e&&(e[t]||e[fn(t)]||e[rl(fn(t))])}function Rt(e,t,n,s){let r;const o=n,i=Te(e);if(i||ot(e)){const a=i&&Bs(e);let c=!1;a&&(c=!Tn(e),e=cl(e)),r=new Array(e.length);for(let u=0,l=e.length;u<l;u++)r[u]=t(c?Ft(e[u]):e[u],u,void 0,o)}else if(typeof e=="number"){r=new Array(e);for(let a=0;a<e;a++)r[a]=t(a+1,a,void 0,o)}else if(et(e))if(e[Symbol.iterator])r=Array.from(e,(a,c)=>t(a,c,void 0,o));else{const a=Object.keys(e);r=new Array(a.length);for(let c=0,u=a.length;c<u;c++){const l=a[c];r[c]=t(e[l],l,c,o)}}else r=[];return r}function Ze(e,t,n={},s,r){if(vt.ce||vt.parent&&oi(vt.parent)&&vt.parent.ce)return t!=="default"&&(n.name=t),F(),fe(De,null,[$("slot",n,s&&s())],64);let o=e[t];o&&o._c&&(o._d=!1),F();const i=o&&L1(o(n)),a=n.key||i&&i.key,c=fe(De,{key:(a&&!Ys(a)?a:`_${t}`)+(!i&&s?"_fb":"")},i||(s?s():[]),i&&e._===1?64:-2);return!r&&c.scopeId&&(c.slotScopeIds=[c.scopeId+"-s"]),o&&o._c&&(o._d=!0),c}function L1(e){return e.some(t=>Si(t)?!(t.type===qt||t.type===De&&!L1(t.children)):!0)?e:null}const Ef=e=>e?tw(e)?yl(e):Ef(e.parent):null,Ea=at(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Ef(e.parent),$root:e=>Ef(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Tm(e),$forceUpdate:e=>e.f||(e.f=()=>{vm(e.update)}),$nextTick:e=>e.n||(e.n=Js.bind(e.proxy)),$watch:e=>iC.bind(e)}),Md=(e,t)=>e!==ze&&!e.__isScriptSetup&&We(e,t),B3={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:s,data:r,props:o,accessCache:i,type:a,appContext:c}=e;let u;if(t[0]!=="$"){const p=i[t];if(p!==void 0)switch(p){case 1:return s[t];case 2:return r[t];case 4:return n[t];case 3:return o[t]}else{if(Md(s,t))return i[t]=1,s[t];if(r!==ze&&We(r,t))return i[t]=2,r[t];if((u=e.propsOptions[0])&&We(u,t))return i[t]=3,o[t];if(n!==ze&&We(n,t))return i[t]=4,n[t];Sf&&(i[t]=0)}}const l=Ea[t];let d,f;if(l)return t==="$attrs"&&Lt(e.attrs,"get",""),l(e);if((d=a.__cssModules)&&(d=d[t]))return d;if(n!==ze&&We(n,t))return i[t]=4,n[t];if(f=c.config.globalProperties,We(f,t))return f[t]},set({_:e},t,n){const{data:s,setupState:r,ctx:o}=e;return Md(r,t)?(r[t]=n,!0):s!==ze&&We(s,t)?(s[t]=n,!0):We(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:s,appContext:r,propsOptions:o}},i){let a;return!!n[i]||e!==ze&&We(e,i)||Md(t,i)||(a=o[0])&&We(a,i)||We(s,i)||We(Ea,i)||We(r.config.globalProperties,i)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:We(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Am(){return D3().slots}function D3(){const e=bs();return e.setupContext||(e.setupContext=sw(e))}function Lu(e){return Te(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function ps(e,t){return!e||!t?e||t:Te(e)&&Te(t)?e.concat(t):at({},Lu(e),Lu(t))}let Sf=!0;function U3(e){const t=Tm(e),n=e.proxy,s=e.ctx;Sf=!1,t.beforeCreate&&ky(t.beforeCreate,e,"bc");const{data:r,computed:o,methods:i,watch:a,provide:c,inject:u,created:l,beforeMount:d,mounted:f,beforeUpdate:p,updated:m,activated:h,deactivated:y,beforeDestroy:b,beforeUnmount:g,destroyed:w,unmounted:_,render:A,renderTracked:x,renderTriggered:C,errorCaptured:k,serverPrefetch:S,expose:R,inheritAttrs:B,components:L,directives:X,filters:z}=t;if(u&&V3(u,s,null),i)for(const te in i){const ce=i[te];ke(ce)&&(s[te]=ce.bind(n))}if(r){const te=r.call(n,n);et(te)&&(e.data=zs(te))}if(Sf=!0,o)for(const te in o){const ce=o[te],he=ke(ce)?ce.bind(n,n):ke(ce.get)?ce.get.bind(n,n):us,_e=!ke(ce)&&ke(ce.set)?ce.set.bind(n):us,Fe=M({get:he,set:_e});Object.defineProperty(s,te,{enumerable:!0,configurable:!0,get:()=>Fe.value,set:Ae=>Fe.value=Ae})}if(a)for(const te in a)F1(a[te],s,n,te);if(c){const te=ke(c)?c.call(n):c;Reflect.ownKeys(te).forEach(ce=>{Sa(ce,te[ce])})}l&&ky(l,e,"c");function ne(te,ce){Te(ce)?ce.forEach(he=>te(he.bind(n))):ce&&te(ce.bind(n))}if(ne(Cm,d),ne(Gn,f),ne(M3,p),ne(R1,m),ne(I3,h),ne(R3,y),ne(N3,k),ne(F3,x),ne(L3,C),ne(fl,g),ne(Qi,_),ne(O3,S),Te(R))if(R.length){const te=e.exposed||(e.exposed={});R.forEach(ce=>{Object.defineProperty(te,ce,{get:()=>n[ce],set:he=>n[ce]=he})})}else e.exposed||(e.exposed={});A&&e.render===us&&(e.render=A),B!=null&&(e.inheritAttrs=B),L&&(e.components=L),X&&(e.directives=X),S&&xm(e)}function V3(e,t,n=us){Te(e)&&(e=Pf(e));for(const s in e){const r=e[s];let o;et(r)?"default"in r?o=Nt(r.from||s,r.default,!0):o=Nt(r.from||s):o=Nt(r),$e(o)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>o.value,set:i=>o.value=i}):t[s]=o}}function ky(e,t,n){Vn(Te(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function F1(e,t,n,s){let r=s.includes(".")?X1(n,s):()=>n[s];if(ot(e)){const o=t[e];ke(o)&&Ce(r,o)}else if(ke(e))Ce(r,e.bind(n));else if(et(e))if(Te(e))e.forEach(o=>F1(o,t,n,s));else{const o=ke(e.handler)?e.handler.bind(n):t[e.handler];ke(o)&&Ce(r,o,e)}}function Tm(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:r,optionsCache:o,config:{optionMergeStrategies:i}}=e.appContext,a=o.get(t);let c;return a?c=a:!r.length&&!n&&!s?c=t:(c={},r.length&&r.forEach(u=>Fu(c,u,i,!0)),Fu(c,t,i)),et(t)&&o.set(t,c),c}function Fu(e,t,n,s=!1){const{mixins:r,extends:o}=t;o&&Fu(e,o,n,!0),r&&r.forEach(i=>Fu(e,i,n,!0));for(const i in t)if(!(s&&i==="expose")){const a=j3[i]||n&&n[i];e[i]=a?a(e[i],t[i]):t[i]}return e}const j3={data:Iy,props:Ry,emits:Ry,methods:va,computed:va,beforeCreate:Dt,created:Dt,beforeMount:Dt,mounted:Dt,beforeUpdate:Dt,updated:Dt,beforeDestroy:Dt,beforeUnmount:Dt,destroyed:Dt,unmounted:Dt,activated:Dt,deactivated:Dt,errorCaptured:Dt,serverPrefetch:Dt,components:va,directives:va,watch:z3,provide:Iy,inject:H3};function Iy(e,t){return t?e?function(){return at(ke(e)?e.call(this,this):e,ke(t)?t.call(this,this):t)}:t:e}function H3(e,t){return va(Pf(e),Pf(t))}function Pf(e){if(Te(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Dt(e,t){return e?[...new Set([].concat(e,t))]:t}function va(e,t){return e?at(Object.create(null),e,t):t}function Ry(e,t){return e?Te(e)&&Te(t)?[...new Set([...e,...t])]:at(Object.create(null),Lu(e),Lu(t??{})):t}function z3(e,t){if(!e)return t;if(!t)return e;const n=at(Object.create(null),e);for(const s in t)n[s]=Dt(e[s],t[s]);return n}function N1(){return{app:null,config:{isNativeTag:Mx,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let q3=0;function W3(e,t){return function(s,r=null){ke(s)||(s=at({},s)),r!=null&&!et(r)&&(r=null);const o=N1(),i=new WeakSet,a=[];let c=!1;const u=o.app={_uid:q3++,_component:s,_props:r,_container:null,_context:o,_instance:null,version:TC,get config(){return o.config},set config(l){},use(l,...d){return i.has(l)||(l&&ke(l.install)?(i.add(l),l.install(u,...d)):ke(l)&&(i.add(l),l(u,...d))),u},mixin(l){return o.mixins.includes(l)||o.mixins.push(l),u},component(l,d){return d?(o.components[l]=d,u):o.components[l]},directive(l,d){return d?(o.directives[l]=d,u):o.directives[l]},mount(l,d,f){if(!c){const p=u._ceVNode||$(s,r);return p.appContext=o,f===!0?f="svg":f===!1&&(f=void 0),d&&t?t(p,l):e(p,l,f),c=!0,u._container=l,l.__vue_app__=u,yl(p.component)}},onUnmount(l){a.push(l)},unmount(){c&&(Vn(a,u._instance,16),e(null,u._container),delete u._container.__vue_app__)},provide(l,d){return o.provides[l]=d,u},runWithContext(l){const d=bo;bo=u;try{return l()}finally{bo=d}}};return u}}let bo=null;function Sa(e,t){if(gt){let n=gt.provides;const s=gt.parent&&gt.parent.provides;s===n&&(n=gt.provides=Object.create(s)),n[e]=t}}function Nt(e,t,n=!1){const s=gt||vt;if(s||bo){const r=bo?bo._context.provides:s?s.parent==null?s.vnode.appContext&&s.vnode.appContext.provides:s.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return n&&ke(t)?t.call(s&&s.proxy):t}}function Em(){return!!(gt||vt||bo)}const B1={},D1=()=>Object.create(B1),U1=e=>Object.getPrototypeOf(e)===B1;function G3(e,t,n,s=!1){const r={},o=D1();e.propsDefaults=Object.create(null),V1(e,t,r,o);for(const i in e.propsOptions[0])i in r||(r[i]=void 0);n?e.props=s?r:ul(r):e.type.props?e.props=r:e.props=o,e.attrs=o}function X3(e,t,n,s){const{props:r,attrs:o,vnode:{patchFlag:i}}=e,a=Ve(r),[c]=e.propsOptions;let u=!1;if((s||i>0)&&!(i&16)){if(i&8){const l=e.vnode.dynamicProps;for(let d=0;d<l.length;d++){let f=l[d];if(hl(e.emitsOptions,f))continue;const p=t[f];if(c)if(We(o,f))p!==o[f]&&(o[f]=p,u=!0);else{const m=fn(f);r[m]=kf(c,a,m,p,e,!1)}else p!==o[f]&&(o[f]=p,u=!0)}}}else{V1(e,t,r,o)&&(u=!0);let l;for(const d in a)(!t||!We(t,d)&&((l=Kr(d))===d||!We(t,l)))&&(c?n&&(n[d]!==void 0||n[l]!==void 0)&&(r[d]=kf(c,a,d,void 0,e,!0)):delete r[d]);if(o!==a)for(const d in o)(!t||!We(t,d))&&(delete o[d],u=!0)}u&&Rs(e.attrs,"set","")}function V1(e,t,n,s){const[r,o]=e.propsOptions;let i=!1,a;if(t)for(let c in t){if(xa(c))continue;const u=t[c];let l;r&&We(r,l=fn(c))?!o||!o.includes(l)?n[l]=u:(a||(a={}))[l]=u:hl(e.emitsOptions,c)||(!(c in s)||u!==s[c])&&(s[c]=u,i=!0)}if(o){const c=Ve(n),u=a||ze;for(let l=0;l<o.length;l++){const d=o[l];n[d]=kf(r,c,d,u[d],e,!We(u,d))}}return i}function kf(e,t,n,s,r,o){const i=e[n];if(i!=null){const a=We(i,"default");if(a&&s===void 0){const c=i.default;if(i.type!==Function&&!i.skipFactory&&ke(c)){const{propsDefaults:u}=r;if(n in u)s=u[n];else{const l=Cc(r);s=u[n]=c.call(null,t),l()}}else s=c;r.ce&&r.ce._setProp(n,s)}i[0]&&(o&&!a?s=!1:i[1]&&(s===""||s===Kr(n))&&(s=!0))}return s}const K3=new WeakMap;function j1(e,t,n=!1){const s=n?K3:t.propsCache,r=s.get(e);if(r)return r;const o=e.props,i={},a=[];let c=!1;if(!ke(e)){const l=d=>{c=!0;const[f,p]=j1(d,t,!0);at(i,f),p&&a.push(...p)};!n&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}if(!o&&!c)return et(e)&&s.set(e,ni),ni;if(Te(o))for(let l=0;l<o.length;l++){const d=fn(o[l]);$y(d)&&(i[d]=ze)}else if(o)for(const l in o){const d=fn(l);if($y(d)){const f=o[l],p=i[d]=Te(f)||ke(f)?{type:f}:at({},f),m=p.type;let h=!1,y=!0;if(Te(m))for(let b=0;b<m.length;++b){const g=m[b],w=ke(g)&&g.name;if(w==="Boolean"){h=!0;break}else w==="String"&&(y=!1)}else h=ke(m)&&m.name==="Boolean";p[0]=h,p[1]=y,(h||We(p,"default"))&&a.push(d)}}const u=[i,a];return et(e)&&s.set(e,u),u}function $y(e){return e[0]!=="$"&&!xa(e)}const H1=e=>e[0]==="_"||e==="$stable",Sm=e=>Te(e)?e.map(rs):[rs(e)],Q3=(e,t,n)=>{if(t._n)return t;const s=Y((...r)=>Sm(t(...r)),n);return s._c=!1,s},z1=(e,t,n)=>{const s=e._ctx;for(const r in e){if(H1(r))continue;const o=e[r];if(ke(o))t[r]=Q3(r,o,s);else if(o!=null){const i=Sm(o);t[r]=()=>i}}},q1=(e,t)=>{const n=Sm(t);e.slots.default=()=>n},W1=(e,t,n)=>{for(const s in t)(n||s!=="_")&&(e[s]=t[s])},Z3=(e,t,n)=>{const s=e.slots=D1();if(e.vnode.shapeFlag&32){const r=t._;r?(W1(s,t,n),n&&Gv(s,"_",r,!0)):z1(t,s)}else t&&q1(e,t)},Y3=(e,t,n)=>{const{vnode:s,slots:r}=e;let o=!0,i=ze;if(s.shapeFlag&32){const a=t._;a?n&&a===1?o=!1:W1(r,t,n):(o=!t.$stable,z1(t,r)),i=t}else t&&(q1(e,t),i={default:1});if(o)for(const a in r)!H1(a)&&i[a]==null&&delete r[a]},Gt=fC;function J3(e){return eC(e)}function eC(e,t){const n=ol();n.__VUE__=!0;const{insert:s,remove:r,patchProp:o,createElement:i,createText:a,createComment:c,setText:u,setElementText:l,parentNode:d,nextSibling:f,setScopeId:p=us,insertStaticContent:m}=e,h=(P,O,q,K=null,G=null,E=null,I=void 0,H=null,W=!!O.dynamicChildren)=>{if(P===O)return;P&&!oo(P,O)&&(K=se(P),Ae(P,G,E,!0),P=null),O.patchFlag===-2&&(W=!1,O.dynamicChildren=null);const{type:ee,ref:re,shapeFlag:D}=O;switch(ee){case xc:y(P,O,q,K);break;case qt:b(P,O,q,K);break;case bu:P==null&&g(O,q,K,I);break;case De:L(P,O,q,K,G,E,I,H,W);break;default:D&1?A(P,O,q,K,G,E,I,H,W):D&6?X(P,O,q,K,G,E,I,H,W):(D&64||D&128)&&ee.process(P,O,q,K,G,E,I,H,W,U)}re!=null&&G&&Tf(re,P&&P.ref,E,O||P,!O)},y=(P,O,q,K)=>{if(P==null)s(O.el=a(O.children),q,K);else{const G=O.el=P.el;O.children!==P.children&&u(G,O.children)}},b=(P,O,q,K)=>{P==null?s(O.el=c(O.children||""),q,K):O.el=P.el},g=(P,O,q,K)=>{[P.el,P.anchor]=m(P.children,O,q,K,P.el,P.anchor)},w=({el:P,anchor:O},q,K)=>{let G;for(;P&&P!==O;)G=f(P),s(P,q,K),P=G;s(O,q,K)},_=({el:P,anchor:O})=>{let q;for(;P&&P!==O;)q=f(P),r(P),P=q;r(O)},A=(P,O,q,K,G,E,I,H,W)=>{O.type==="svg"?I="svg":O.type==="math"&&(I="mathml"),P==null?x(O,q,K,G,E,I,H,W):S(P,O,G,E,I,H,W)},x=(P,O,q,K,G,E,I,H)=>{let W,ee;const{props:re,shapeFlag:D,transition:Q,dirs:de}=P;if(W=P.el=i(P.type,E,re&&re.is,re),D&8?l(W,P.children):D&16&&k(P.children,W,null,K,G,Od(P,E),I,H),de&&to(P,null,K,"created"),C(W,P,P.scopeId,I,K),re){for(const Ne in re)Ne!=="value"&&!xa(Ne)&&o(W,Ne,null,re[Ne],E,K);"value"in re&&o(W,"value",null,re.value,E),(ee=re.onVnodeBeforeMount)&&Zn(ee,K,P)}de&&to(P,null,K,"beforeMount");const ve=tC(G,Q);ve&&Q.beforeEnter(W),s(W,O,q),((ee=re&&re.onVnodeMounted)||ve||de)&&Gt(()=>{ee&&Zn(ee,K,P),ve&&Q.enter(W),de&&to(P,null,K,"mounted")},G)},C=(P,O,q,K,G)=>{if(q&&p(P,q),K)for(let E=0;E<K.length;E++)p(P,K[E]);if(G){let E=G.subTree;if(O===E||Z1(E.type)&&(E.ssContent===O||E.ssFallback===O)){const I=G.vnode;C(P,I,I.scopeId,I.slotScopeIds,G.parent)}}},k=(P,O,q,K,G,E,I,H,W=0)=>{for(let ee=W;ee<P.length;ee++){const re=P[ee]=H?yr(P[ee]):rs(P[ee]);h(null,re,O,q,K,G,E,I,H)}},S=(P,O,q,K,G,E,I)=>{const H=O.el=P.el;let{patchFlag:W,dynamicChildren:ee,dirs:re}=O;W|=P.patchFlag&16;const D=P.props||ze,Q=O.props||ze;let de;if(q&&no(q,!1),(de=Q.onVnodeBeforeUpdate)&&Zn(de,q,O,P),re&&to(O,P,q,"beforeUpdate"),q&&no(q,!0),(D.innerHTML&&Q.innerHTML==null||D.textContent&&Q.textContent==null)&&l(H,""),ee?R(P.dynamicChildren,ee,H,q,K,Od(O,G),E):I||ce(P,O,H,null,q,K,Od(O,G),E,!1),W>0){if(W&16)B(H,D,Q,q,G);else if(W&2&&D.class!==Q.class&&o(H,"class",null,Q.class,G),W&4&&o(H,"style",D.style,Q.style,G),W&8){const ve=O.dynamicProps;for(let Ne=0;Ne<ve.length;Ne++){const je=ve[Ne],lt=D[je],_t=Q[je];(_t!==lt||je==="value")&&o(H,je,lt,_t,G,q)}}W&1&&P.children!==O.children&&l(H,O.children)}else!I&&ee==null&&B(H,D,Q,q,G);((de=Q.onVnodeUpdated)||re)&&Gt(()=>{de&&Zn(de,q,O,P),re&&to(O,P,q,"updated")},K)},R=(P,O,q,K,G,E,I)=>{for(let H=0;H<O.length;H++){const W=P[H],ee=O[H],re=W.el&&(W.type===De||!oo(W,ee)||W.shapeFlag&70)?d(W.el):q;h(W,ee,re,null,K,G,E,I,!0)}},B=(P,O,q,K,G)=>{if(O!==q){if(O!==ze)for(const E in O)!xa(E)&&!(E in q)&&o(P,E,O[E],null,G,K);for(const E in q){if(xa(E))continue;const I=q[E],H=O[E];I!==H&&E!=="value"&&o(P,E,H,I,G,K)}"value"in q&&o(P,"value",O.value,q.value,G)}},L=(P,O,q,K,G,E,I,H,W)=>{const ee=O.el=P?P.el:a(""),re=O.anchor=P?P.anchor:a("");let{patchFlag:D,dynamicChildren:Q,slotScopeIds:de}=O;de&&(H=H?H.concat(de):de),P==null?(s(ee,q,K),s(re,q,K),k(O.children||[],q,re,G,E,I,H,W)):D>0&&D&64&&Q&&P.dynamicChildren?(R(P.dynamicChildren,Q,q,G,E,I,H),(O.key!=null||G&&O===G.subTree)&&Pm(P,O,!0)):ce(P,O,q,re,G,E,I,H,W)},X=(P,O,q,K,G,E,I,H,W)=>{O.slotScopeIds=H,P==null?O.shapeFlag&512?G.ctx.activate(O,q,K,I,W):z(O,q,K,G,E,I,W):ie(P,O,W)},z=(P,O,q,K,G,E,I)=>{const H=P.component=vC(P,K,G);if(_c(P)&&(H.ctx.renderer=U),wC(H,!1,I),H.asyncDep){if(G&&G.registerDep(H,ne,I),!P.el){const W=H.subTree=$(qt);b(null,W,O,q)}}else ne(H,P,O,q,G,E,I)},ie=(P,O,q)=>{const K=O.component=P.component;if(lC(P,O,q))if(K.asyncDep&&!K.asyncResolved){te(K,O,q);return}else K.next=O,K.update();else O.el=P.el,K.vnode=O},ne=(P,O,q,K,G,E,I)=>{const H=()=>{if(P.isMounted){let{next:D,bu:Q,u:de,parent:ve,vnode:Ne}=P;{const sn=G1(P);if(sn){D&&(D.el=Ne.el,te(P,D,I)),sn.asyncDep.then(()=>{P.isUnmounted||H()});return}}let je=D,lt;no(P,!1),D?(D.el=Ne.el,te(P,D,I)):D=Ne,Q&&hu(Q),(lt=D.props&&D.props.onVnodeBeforeUpdate)&&Zn(lt,ve,D,Ne),no(P,!0);const _t=Ld(P),hn=P.subTree;P.subTree=_t,h(hn,_t,d(hn.el),se(hn),P,G,E),D.el=_t.el,je===null&&dC(P,_t.el),de&&Gt(de,G),(lt=D.props&&D.props.onVnodeUpdated)&&Gt(()=>Zn(lt,ve,D,Ne),G)}else{let D;const{el:Q,props:de}=O,{bm:ve,m:Ne,parent:je,root:lt,type:_t}=P,hn=oi(O);if(no(P,!1),ve&&hu(ve),!hn&&(D=de&&de.onVnodeBeforeMount)&&Zn(D,je,O),no(P,!0),Q&&be){const sn=()=>{P.subTree=Ld(P),be(Q,P.subTree,P,G,null)};hn&&_t.__asyncHydrate?_t.__asyncHydrate(Q,P,sn):sn()}else{lt.ce&&lt.ce._injectChildStyle(_t);const sn=P.subTree=Ld(P);h(null,sn,q,K,P,G,E),O.el=sn.el}if(Ne&&Gt(Ne,G),!hn&&(D=de&&de.onVnodeMounted)){const sn=O;Gt(()=>Zn(D,je,sn),G)}(O.shapeFlag&256||je&&oi(je.vnode)&&je.vnode.shapeFlag&256)&&P.a&&Gt(P.a,G),P.isMounted=!0,O=q=K=null}};P.scope.on();const W=P.effect=new Yv(H);P.scope.off();const ee=P.update=W.run.bind(W),re=P.job=W.runIfDirty.bind(W);re.i=P,re.id=P.uid,W.scheduler=()=>vm(re),no(P,!0),ee()},te=(P,O,q)=>{O.component=P;const K=P.vnode.props;P.vnode=O,P.next=null,X3(P,O.props,K,q),Y3(P,O.children,q),Qr(),Cy(P),Zr()},ce=(P,O,q,K,G,E,I,H,W=!1)=>{const ee=P&&P.children,re=P?P.shapeFlag:0,D=O.children,{patchFlag:Q,shapeFlag:de}=O;if(Q>0){if(Q&128){_e(ee,D,q,K,G,E,I,H,W);return}else if(Q&256){he(ee,D,q,K,G,E,I,H,W);return}}de&8?(re&16&&Xe(ee,G,E),D!==ee&&l(q,D)):re&16?de&16?_e(ee,D,q,K,G,E,I,H,W):Xe(ee,G,E,!0):(re&8&&l(q,""),de&16&&k(D,q,K,G,E,I,H,W))},he=(P,O,q,K,G,E,I,H,W)=>{P=P||ni,O=O||ni;const ee=P.length,re=O.length,D=Math.min(ee,re);let Q;for(Q=0;Q<D;Q++){const de=O[Q]=W?yr(O[Q]):rs(O[Q]);h(P[Q],de,q,null,G,E,I,H,W)}ee>re?Xe(P,G,E,!0,!1,D):k(O,q,K,G,E,I,H,W,D)},_e=(P,O,q,K,G,E,I,H,W)=>{let ee=0;const re=O.length;let D=P.length-1,Q=re-1;for(;ee<=D&&ee<=Q;){const de=P[ee],ve=O[ee]=W?yr(O[ee]):rs(O[ee]);if(oo(de,ve))h(de,ve,q,null,G,E,I,H,W);else break;ee++}for(;ee<=D&&ee<=Q;){const de=P[D],ve=O[Q]=W?yr(O[Q]):rs(O[Q]);if(oo(de,ve))h(de,ve,q,null,G,E,I,H,W);else break;D--,Q--}if(ee>D){if(ee<=Q){const de=Q+1,ve=de<re?O[de].el:K;for(;ee<=Q;)h(null,O[ee]=W?yr(O[ee]):rs(O[ee]),q,ve,G,E,I,H,W),ee++}}else if(ee>Q)for(;ee<=D;)Ae(P[ee],G,E,!0),ee++;else{const de=ee,ve=ee,Ne=new Map;for(ee=ve;ee<=Q;ee++){const rn=O[ee]=W?yr(O[ee]):rs(O[ee]);rn.key!=null&&Ne.set(rn.key,ee)}let je,lt=0;const _t=Q-ve+1;let hn=!1,sn=0;const ua=new Array(_t);for(ee=0;ee<_t;ee++)ua[ee]=0;for(ee=de;ee<=D;ee++){const rn=P[ee];if(lt>=_t){Ae(rn,G,E,!0);continue}let Kn;if(rn.key!=null)Kn=Ne.get(rn.key);else for(je=ve;je<=Q;je++)if(ua[je-ve]===0&&oo(rn,O[je])){Kn=je;break}Kn===void 0?Ae(rn,G,E,!0):(ua[Kn-ve]=ee+1,Kn>=sn?sn=Kn:hn=!0,h(rn,O[Kn],q,null,G,E,I,H,W),lt++)}const Xh=hn?nC(ua):ni;for(je=Xh.length-1,ee=_t-1;ee>=0;ee--){const rn=ve+ee,Kn=O[rn],Kh=rn+1<re?O[rn+1].el:K;ua[ee]===0?h(null,Kn,q,Kh,G,E,I,H,W):hn&&(je<0||ee!==Xh[je]?Fe(Kn,q,Kh,2):je--)}}},Fe=(P,O,q,K,G=null)=>{const{el:E,type:I,transition:H,children:W,shapeFlag:ee}=P;if(ee&6){Fe(P.component.subTree,O,q,K);return}if(ee&128){P.suspense.move(O,q,K);return}if(ee&64){I.move(P,O,q,U);return}if(I===De){s(E,O,q);for(let D=0;D<W.length;D++)Fe(W[D],O,q,K);s(P.anchor,O,q);return}if(I===bu){w(P,O,q);return}if(K!==2&&ee&1&&H)if(K===0)H.beforeEnter(E),s(E,O,q),Gt(()=>H.enter(E),G);else{const{leave:D,delayLeave:Q,afterLeave:de}=H,ve=()=>s(E,O,q),Ne=()=>{D(E,()=>{ve(),de&&de()})};Q?Q(E,ve,Ne):Ne()}else s(E,O,q)},Ae=(P,O,q,K=!1,G=!1)=>{const{type:E,props:I,ref:H,children:W,dynamicChildren:ee,shapeFlag:re,patchFlag:D,dirs:Q,cacheIndex:de}=P;if(D===-2&&(G=!1),H!=null&&Tf(H,null,q,P,!0),de!=null&&(O.renderCache[de]=void 0),re&256){O.ctx.deactivate(P);return}const ve=re&1&&Q,Ne=!oi(P);let je;if(Ne&&(je=I&&I.onVnodeBeforeUnmount)&&Zn(je,O,P),re&6)mt(P.component,q,K);else{if(re&128){P.suspense.unmount(q,K);return}ve&&to(P,null,O,"beforeUnmount"),re&64?P.type.remove(P,O,q,U,K):ee&&!ee.hasOnce&&(E!==De||D>0&&D&64)?Xe(ee,O,q,!1,!0):(E===De&&D&384||!G&&re&16)&&Xe(W,O,q),K&&qe(P)}(Ne&&(je=I&&I.onVnodeUnmounted)||ve)&&Gt(()=>{je&&Zn(je,O,P),ve&&to(P,null,O,"unmounted")},q)},qe=P=>{const{type:O,el:q,anchor:K,transition:G}=P;if(O===De){Ye(q,K);return}if(O===bu){_(P);return}const E=()=>{r(q),G&&!G.persisted&&G.afterLeave&&G.afterLeave()};if(P.shapeFlag&1&&G&&!G.persisted){const{leave:I,delayLeave:H}=G,W=()=>I(q,E);H?H(P.el,E,W):W()}else E()},Ye=(P,O)=>{let q;for(;P!==O;)q=f(P),r(P),P=q;r(O)},mt=(P,O,q)=>{const{bum:K,scope:G,job:E,subTree:I,um:H,m:W,a:ee}=P;My(W),My(ee),K&&hu(K),G.stop(),E&&(E.flags|=8,Ae(I,P,O,q)),H&&Gt(H,O),Gt(()=>{P.isUnmounted=!0},O),O&&O.pendingBranch&&!O.isUnmounted&&P.asyncDep&&!P.asyncResolved&&P.suspenseId===O.pendingId&&(O.deps--,O.deps===0&&O.resolve())},Xe=(P,O,q,K=!1,G=!1,E=0)=>{for(let I=E;I<P.length;I++)Ae(P[I],O,q,K,G)},se=P=>{if(P.shapeFlag&6)return se(P.component.subTree);if(P.shapeFlag&128)return P.suspense.next();const O=f(P.anchor||P.el),q=O&&O[x1];return q?f(q):O};let V=!1;const j=(P,O,q)=>{P==null?O._vnode&&Ae(O._vnode,null,null,!0):h(O._vnode||null,P,O,null,null,null,q),O._vnode=P,V||(V=!0,Cy(),v1(),V=!1)},U={p:h,um:Ae,m:Fe,r:qe,mt:z,mc:k,pc:ce,pbc:R,n:se,o:e};let oe,be;return{render:j,hydrate:oe,createApp:W3(j,oe)}}function Od({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function no({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function tC(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Pm(e,t,n=!1){const s=e.children,r=t.children;if(Te(s)&&Te(r))for(let o=0;o<s.length;o++){const i=s[o];let a=r[o];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=r[o]=yr(r[o]),a.el=i.el),!n&&a.patchFlag!==-2&&Pm(i,a)),a.type===xc&&(a.el=i.el)}}function nC(e){const t=e.slice(),n=[0];let s,r,o,i,a;const c=e.length;for(s=0;s<c;s++){const u=e[s];if(u!==0){if(r=n[n.length-1],e[r]<u){t[s]=r,n.push(s);continue}for(o=0,i=n.length-1;o<i;)a=o+i>>1,e[n[a]]<u?o=a+1:i=a;u<e[n[o]]&&(o>0&&(t[s]=n[o-1]),n[o]=s)}}for(o=n.length,i=n[o-1];o-- >0;)n[o]=i,i=t[i];return n}function G1(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:G1(t)}function My(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const sC=Symbol.for("v-scx"),rC=()=>Nt(sC);function pl(e,t){return ml(e,null,t)}function oC(e,t){return ml(e,null,{flush:"sync"})}function Ce(e,t,n){return ml(e,t,n)}function ml(e,t,n=ze){const{immediate:s,deep:r,flush:o,once:i}=n,a=at({},n),c=t&&s||!t&&o!=="post";let u;if(Pi){if(o==="sync"){const p=rC();u=p.__watcherHandles||(p.__watcherHandles=[])}else if(!c){const p=()=>{};return p.stop=us,p.resume=us,p.pause=us,p}}const l=gt;a.call=(p,m,h)=>Vn(p,l,m,h);let d=!1;o==="post"?a.scheduler=p=>{Gt(p,l&&l.suspense)}:o!=="sync"&&(d=!0,a.scheduler=(p,m)=>{m?p():vm(p)}),a.augmentJob=p=>{t&&(p.flags|=4),d&&(p.flags|=2,l&&(p.id=l.uid,p.i=l))};const f=g3(e,t,a);return Pi&&(u?u.push(f):c&&f()),f}function iC(e,t,n){const s=this.proxy,r=ot(e)?e.includes(".")?X1(s,e):()=>s[e]:e.bind(s,s);let o;ke(t)?o=t:(o=t.handler,n=t);const i=Cc(this),a=ml(r,o.bind(s),n);return i(),a}function X1(e,t){const n=t.split(".");return()=>{let s=e;for(let r=0;r<n.length&&s;r++)s=s[n[r]];return s}}function Do(e,t,n=ze){const s=bs(),r=fn(t),o=Kr(t),i=K1(e,r),a=m1((c,u)=>{let l,d=ze,f;return oC(()=>{const p=e[r];Zt(l,p)&&(l=p,u())}),{get(){return c(),n.get?n.get(l):l},set(p){const m=n.set?n.set(p):p;if(!Zt(m,l)&&!(d!==ze&&Zt(p,d)))return;const h=s.vnode.props;h&&(t in h||r in h||o in h)&&(`onUpdate:${t}`in h||`onUpdate:${r}`in h||`onUpdate:${o}`in h)||(l=p,u()),s.emit(`update:${t}`,m),Zt(p,m)&&Zt(p,d)&&!Zt(m,f)&&u(),d=p,f=m}}});return a[Symbol.iterator]=()=>{let c=0;return{next(){return c<2?{value:c++?i||ze:a,done:!1}:{done:!0}}}},a}const K1=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${fn(t)}Modifiers`]||e[`${Kr(t)}Modifiers`];function aC(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||ze;let r=n;const o=t.startsWith("update:"),i=o&&K1(s,t.slice(7));i&&(i.trim&&(r=n.map(l=>ot(l)?l.trim():l)),i.number&&(r=n.map(gf)));let a,c=s[a=Ed(t)]||s[a=Ed(fn(t))];!c&&o&&(c=s[a=Ed(Kr(t))]),c&&Vn(c,e,6,r);const u=s[a+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[a])return;e.emitted[a]=!0,Vn(u,e,6,r)}}function Q1(e,t,n=!1){const s=t.emitsCache,r=s.get(e);if(r!==void 0)return r;const o=e.emits;let i={},a=!1;if(!ke(e)){const c=u=>{const l=Q1(u,t,!0);l&&(a=!0,at(i,l))};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}return!o&&!a?(et(e)&&s.set(e,null),null):(Te(o)?o.forEach(c=>i[c]=null):at(i,o),et(e)&&s.set(e,i),i)}function hl(e,t){return!e||!tl(t)?!1:(t=t.slice(2).replace(/Once$/,""),We(e,t[0].toLowerCase()+t.slice(1))||We(e,Kr(t))||We(e,t))}function Ld(e){const{type:t,vnode:n,proxy:s,withProxy:r,propsOptions:[o],slots:i,attrs:a,emit:c,render:u,renderCache:l,props:d,data:f,setupState:p,ctx:m,inheritAttrs:h}=e,y=Mu(e);let b,g;try{if(n.shapeFlag&4){const _=r||s,A=_;b=rs(u.call(A,_,l,d,p,f,m)),g=a}else{const _=t;b=rs(_.length>1?_(d,{attrs:a,slots:i,emit:c}):_(d,null)),g=t.props?a:cC(a)}}catch(_){Pa.length=0,wc(_,e,1),b=$(qt)}let w=b;if(g&&h!==!1){const _=Object.keys(g),{shapeFlag:A}=w;_.length&&A&7&&(o&&_.some(am)&&(g=uC(g,o)),w=Lr(w,g,!1,!0))}return n.dirs&&(w=Lr(w,null,!1,!0),w.dirs=w.dirs?w.dirs.concat(n.dirs):n.dirs),n.transition&&Ao(w,n.transition),b=w,Mu(y),b}const cC=e=>{let t;for(const n in e)(n==="class"||n==="style"||tl(n))&&((t||(t={}))[n]=e[n]);return t},uC=(e,t)=>{const n={};for(const s in e)(!am(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function lC(e,t,n){const{props:s,children:r,component:o}=e,{props:i,children:a,patchFlag:c}=t,u=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return s?Oy(s,i,u):!!i;if(c&8){const l=t.dynamicProps;for(let d=0;d<l.length;d++){const f=l[d];if(i[f]!==s[f]&&!hl(u,f))return!0}}}else return(r||a)&&(!a||!a.$stable)?!0:s===i?!1:s?i?Oy(s,i,u):!0:!!i;return!1}function Oy(e,t,n){const s=Object.keys(t);if(s.length!==Object.keys(e).length)return!0;for(let r=0;r<s.length;r++){const o=s[r];if(t[o]!==e[o]&&!hl(n,o))return!0}return!1}function dC({vnode:e,parent:t},n){for(;t;){const s=t.subTree;if(s.suspense&&s.suspense.activeBranch===e&&(s.el=e.el),s===e)(e=t.vnode).el=n,t=t.parent;else break}}const Z1=e=>e.__isSuspense;function fC(e,t){t&&t.pendingBranch?Te(e)?t.effects.push(...e):t.effects.push(e):_3(e)}const De=Symbol.for("v-fgt"),xc=Symbol.for("v-txt"),qt=Symbol.for("v-cmt"),bu=Symbol.for("v-stc"),Pa=[];let ln=null;function F(e=!1){Pa.push(ln=e?null:[])}function pC(){Pa.pop(),ln=Pa[Pa.length-1]||null}let za=1;function Ly(e){za+=e,e<0&&ln&&(ln.hasOnce=!0)}function Y1(e){return e.dynamicChildren=za>0?ln||ni:null,pC(),za>0&&ln&&ln.push(e),e}function J(e,t,n,s,r,o){return Y1(T(e,t,n,s,r,o,!0))}function fe(e,t,n,s,r){return Y1($(e,t,n,s,r,!0))}function Si(e){return e?e.__v_isVNode===!0:!1}function oo(e,t){return e.type===t.type&&e.key===t.key}const J1=({key:e})=>e??null,gu=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?ot(e)||$e(e)||ke(e)?{i:vt,r:e,k:t,f:!!n}:e:null);function T(e,t=null,n=null,s=0,r=null,o=e===De?0:1,i=!1,a=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&J1(t),ref:t&&gu(t),scopeId:_1,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:s,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:vt};return a?(km(c,n),o&128&&e.normalize(c)):n&&(c.shapeFlag|=ot(n)?8:16),za>0&&!i&&ln&&(c.patchFlag>0||o&6)&&c.patchFlag!==32&&ln.push(c),c}const $=mC;function mC(e,t=null,n=null,s=0,r=null,o=!1){if((!e||e===M1)&&(e=qt),Si(e)){const a=Lr(e,t,!0);return n&&km(a,n),za>0&&!o&&ln&&(a.shapeFlag&6?ln[ln.indexOf(e)]=a:ln.push(a)),a.patchFlag=-2,a}if(AC(e)&&(e=e.__vccOpts),t){t=hC(t);let{class:a,style:c}=t;a&&!ot(a)&&(t.class=Pe(a)),et(c)&&(bm(c)&&!Te(c)&&(c=at({},c)),t.style=il(c))}const i=ot(e)?1:Z1(e)?128:C1(e)?64:et(e)?4:ke(e)?2:0;return T(e,t,n,s,r,i,o,!0)}function hC(e){return e?bm(e)||U1(e)?at({},e):e:null}function Lr(e,t,n=!1,s=!1){const{props:r,ref:o,patchFlag:i,children:a,transition:c}=e,u=t?ew(r||{},t):r,l={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&J1(u),ref:t&&t.ref?n&&o?Te(o)?o.concat(gu(t)):[o,gu(t)]:gu(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:a,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==De?i===-1?16:i|16:i,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Lr(e.ssContent),ssFallback:e.ssFallback&&Lr(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return c&&s&&Ao(l,c.clone(l)),l}function we(e=" ",t=0){return $(xc,null,e,t)}function yC(e,t){const n=$(bu,null,e);return n.staticCount=t,n}function ye(e="",t=!1){return t?(F(),fe(qt,null,e)):$(qt,null,e)}function rs(e){return e==null||typeof e=="boolean"?$(qt):Te(e)?$(De,null,e.slice()):Si(e)?yr(e):$(xc,null,String(e))}function yr(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Lr(e)}function km(e,t){let n=0;const{shapeFlag:s}=e;if(t==null)t=null;else if(Te(t))n=16;else if(typeof t=="object")if(s&65){const r=t.default;r&&(r._c&&(r._d=!1),km(e,r()),r._c&&(r._d=!0));return}else{n=32;const r=t._;!r&&!U1(t)?t._ctx=vt:r===3&&vt&&(vt.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else ke(t)?(t={default:t,_ctx:vt},n=32):(t=String(t),s&64?(n=16,t=[we(t)]):n=8);e.children=t,e.shapeFlag|=n}function ew(...e){const t={};for(let n=0;n<e.length;n++){const s=e[n];for(const r in s)if(r==="class")t.class!==s.class&&(t.class=Pe([t.class,s.class]));else if(r==="style")t.style=il([t.style,s.style]);else if(tl(r)){const o=t[r],i=s[r];i&&o!==i&&!(Te(o)&&o.includes(i))&&(t[r]=o?[].concat(o,i):i)}else r!==""&&(t[r]=s[r])}return t}function Zn(e,t,n,s=null){Vn(e,t,7,[n,s])}const bC=N1();let gC=0;function vC(e,t,n){const s=e.type,r=(t?t.appContext:e.appContext)||bC,o={uid:gC++,vnode:e,type:s,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Zv(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:j1(s,r),emitsOptions:Q1(s,r),emit:null,emitted:null,propsDefaults:ze,inheritAttrs:s.inheritAttrs,ctx:ze,data:ze,props:ze,attrs:ze,slots:ze,refs:ze,setupState:ze,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=aC.bind(null,o),e.ce&&e.ce(o),o}let gt=null;const bs=()=>gt||vt;let Nu,If;{const e=ol(),t=(n,s)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(s),o=>{r.length>1?r.forEach(i=>i(o)):r[0](o)}};Nu=t("__VUE_INSTANCE_SETTERS__",n=>gt=n),If=t("__VUE_SSR_SETTERS__",n=>Pi=n)}const Cc=e=>{const t=gt;return Nu(e),e.scope.on(),()=>{e.scope.off(),Nu(t)}},Fy=()=>{gt&&gt.scope.off(),Nu(null)};function tw(e){return e.vnode.shapeFlag&4}let Pi=!1;function wC(e,t=!1,n=!1){t&&If(t);const{props:s,children:r}=e.vnode,o=tw(e);G3(e,s,o,t),Z3(e,r,n);const i=o?_C(e,t):void 0;return t&&If(!1),i}function _C(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,B3);const{setup:s}=n;if(s){Qr();const r=e.setupContext=s.length>1?sw(e):null,o=Cc(e),i=vc(s,e,0,[e.props,r]),a=zv(i);if(Zr(),o(),(a||e.sp)&&!oi(e)&&xm(e),a){if(i.then(Fy,Fy),t)return i.then(c=>{Ny(e,c,t)}).catch(c=>{wc(c,e,0)});e.asyncDep=i}else Ny(e,i,t)}else nw(e,t)}function Ny(e,t,n){ke(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:et(t)&&(e.setupState=p1(t)),nw(e,n)}let By;function nw(e,t,n){const s=e.type;if(!e.render){if(!t&&By&&!s.render){const r=s.template||Tm(e).template;if(r){const{isCustomElement:o,compilerOptions:i}=e.appContext.config,{delimiters:a,compilerOptions:c}=s,u=at(at({isCustomElement:o,delimiters:a},i),c);s.render=By(r,u)}}e.render=s.render||us}{const r=Cc(e);Qr();try{U3(e)}finally{Zr(),r()}}}const xC={get(e,t){return Lt(e,"get",""),e[t]}};function sw(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,xC),slots:e.slots,emit:e.emit,expose:t}}function yl(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(p1(gm(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Ea)return Ea[n](e)},has(t,n){return n in t||n in Ea}})):e.proxy}function CC(e,t=!0){return ke(e)?e.displayName||e.name:e.name||t&&e.__name}function AC(e){return ke(e)&&"__vccOpts"in e}const M=(e,t)=>y3(e,t,Pi);function Fr(e,t,n){const s=arguments.length;return s===2?et(t)&&!Te(t)?Si(t)?$(e,null,[t]):$(e,t):$(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&Si(n)&&(n=[n]),$(e,t,n))}const TC="3.5.12";/**
* @vue/runtime-dom v3.5.12
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/let Rf;const Dy=typeof window<"u"&&window.trustedTypes;if(Dy)try{Rf=Dy.createPolicy("vue",{createHTML:e=>e})}catch{}const rw=Rf?e=>Rf.createHTML(e):e=>e,EC="http://www.w3.org/2000/svg",SC="http://www.w3.org/1998/Math/MathML",Ss=typeof document<"u"?document:null,Uy=Ss&&Ss.createElement("template"),PC={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,s)=>{const r=t==="svg"?Ss.createElementNS(EC,e):t==="mathml"?Ss.createElementNS(SC,e):n?Ss.createElement(e,{is:n}):Ss.createElement(e);return e==="select"&&s&&s.multiple!=null&&r.setAttribute("multiple",s.multiple),r},createText:e=>Ss.createTextNode(e),createComment:e=>Ss.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ss.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,s,r,o){const i=n?n.previousSibling:t.lastChild;if(r&&(r===o||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),n),!(r===o||!(r=r.nextSibling)););else{Uy.innerHTML=rw(s==="svg"?`<svg>${e}</svg>`:s==="mathml"?`<math>${e}</math>`:e);const a=Uy.content;if(s==="svg"||s==="mathml"){const c=a.firstChild;for(;c.firstChild;)a.appendChild(c.firstChild);a.removeChild(c)}t.insertBefore(a,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},ir="transition",fa="animation",ki=Symbol("_vtc"),ow={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},iw=at({},E1,ow),kC=e=>(e.displayName="Transition",e.props=iw,e),IC=kC((e,{slots:t})=>Fr(S3,aw(e),t)),so=(e,t=[])=>{Te(e)?e.forEach(n=>n(...t)):e&&e(...t)},Vy=e=>e?Te(e)?e.some(t=>t.length>1):e.length>1:!1;function aw(e){const t={};for(const L in e)L in ow||(t[L]=e[L]);if(e.css===!1)return t;const{name:n="v",type:s,duration:r,enterFromClass:o=`${n}-enter-from`,enterActiveClass:i=`${n}-enter-active`,enterToClass:a=`${n}-enter-to`,appearFromClass:c=o,appearActiveClass:u=i,appearToClass:l=a,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:f=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=e,m=RC(r),h=m&&m[0],y=m&&m[1],{onBeforeEnter:b,onEnter:g,onEnterCancelled:w,onLeave:_,onLeaveCancelled:A,onBeforeAppear:x=b,onAppear:C=g,onAppearCancelled:k=w}=t,S=(L,X,z)=>{lr(L,X?l:a),lr(L,X?u:i),z&&z()},R=(L,X)=>{L._isLeaving=!1,lr(L,d),lr(L,p),lr(L,f),X&&X()},B=L=>(X,z)=>{const ie=L?C:g,ne=()=>S(X,L,z);so(ie,[X,ne]),jy(()=>{lr(X,L?c:o),As(X,L?l:a),Vy(ie)||Hy(X,s,h,ne)})};return at(t,{onBeforeEnter(L){so(b,[L]),As(L,o),As(L,i)},onBeforeAppear(L){so(x,[L]),As(L,c),As(L,u)},onEnter:B(!1),onAppear:B(!0),onLeave(L,X){L._isLeaving=!0;const z=()=>R(L,X);As(L,d),As(L,f),uw(),jy(()=>{L._isLeaving&&(lr(L,d),As(L,p),Vy(_)||Hy(L,s,y,z))}),so(_,[L,z])},onEnterCancelled(L){S(L,!1),so(w,[L])},onAppearCancelled(L){S(L,!0),so(k,[L])},onLeaveCancelled(L){R(L),so(A,[L])}})}function RC(e){if(e==null)return null;if(et(e))return[Fd(e.enter),Fd(e.leave)];{const t=Fd(e);return[t,t]}}function Fd(e){return Bx(e)}function As(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[ki]||(e[ki]=new Set)).add(t)}function lr(e,t){t.split(/\s+/).forEach(s=>s&&e.classList.remove(s));const n=e[ki];n&&(n.delete(t),n.size||(e[ki]=void 0))}function jy(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let $C=0;function Hy(e,t,n,s){const r=e._endId=++$C,o=()=>{r===e._endId&&s()};if(n!=null)return setTimeout(o,n);const{type:i,timeout:a,propCount:c}=cw(e,t);if(!i)return s();const u=i+"end";let l=0;const d=()=>{e.removeEventListener(u,f),o()},f=p=>{p.target===e&&++l>=c&&d()};setTimeout(()=>{l<c&&d()},a+1),e.addEventListener(u,f)}function cw(e,t){const n=window.getComputedStyle(e),s=m=>(n[m]||"").split(", "),r=s(`${ir}Delay`),o=s(`${ir}Duration`),i=zy(r,o),a=s(`${fa}Delay`),c=s(`${fa}Duration`),u=zy(a,c);let l=null,d=0,f=0;t===ir?i>0&&(l=ir,d=i,f=o.length):t===fa?u>0&&(l=fa,d=u,f=c.length):(d=Math.max(i,u),l=d>0?i>u?ir:fa:null,f=l?l===ir?o.length:c.length:0);const p=l===ir&&/\b(transform|all)(,|$)/.test(s(`${ir}Property`).toString());return{type:l,timeout:d,propCount:f,hasTransform:p}}function zy(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,s)=>qy(n)+qy(e[s])))}function qy(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function uw(){return document.body.offsetHeight}function MC(e,t,n){const s=e[ki];s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Bu=Symbol("_vod"),lw=Symbol("_vsh"),OC={beforeMount(e,{value:t},{transition:n}){e[Bu]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):pa(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:s}){!t!=!n&&(s?t?(s.beforeEnter(e),pa(e,!0),s.enter(e)):s.leave(e,()=>{pa(e,!1)}):pa(e,t))},beforeUnmount(e,{value:t}){pa(e,t)}};function pa(e,t){e.style.display=t?e[Bu]:"none",e[lw]=!t}const LC=Symbol(""),FC=/(^|;)\s*display\s*:/;function NC(e,t,n){const s=e.style,r=ot(n);let o=!1;if(n&&!r){if(t)if(ot(t))for(const i of t.split(";")){const a=i.slice(0,i.indexOf(":")).trim();n[a]==null&&vu(s,a,"")}else for(const i in t)n[i]==null&&vu(s,i,"");for(const i in n)i==="display"&&(o=!0),vu(s,i,n[i])}else if(r){if(t!==n){const i=s[LC];i&&(n+=";"+i),s.cssText=n,o=FC.test(n)}}else t&&e.removeAttribute("style");Bu in e&&(e[Bu]=o?s.display:"",e[lw]&&(s.display="none"))}const Wy=/\s*!important$/;function vu(e,t,n){if(Te(n))n.forEach(s=>vu(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=BC(e,t);Wy.test(n)?e.setProperty(Kr(s),n.replace(Wy,""),"important"):e[s]=n}}const Gy=["Webkit","Moz","ms"],Nd={};function BC(e,t){const n=Nd[t];if(n)return n;let s=fn(t);if(s!=="filter"&&s in e)return Nd[t]=s;s=rl(s);for(let r=0;r<Gy.length;r++){const o=Gy[r]+s;if(o in e)return Nd[t]=o}return t}const Xy="http://www.w3.org/1999/xlink";function Ky(e,t,n,s,r,o=zx(t)){s&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(Xy,t.slice(6,t.length)):e.setAttributeNS(Xy,t,n):n==null||o&&!Xv(n)?e.removeAttribute(t):e.setAttribute(t,o?"":Ys(n)?String(n):n)}function Qy(e,t,n,s,r){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?rw(n):n);return}const o=e.tagName;if(t==="value"&&o!=="PROGRESS"&&!o.includes("-")){const a=o==="OPTION"?e.getAttribute("value")||"":e.value,c=n==null?e.type==="checkbox"?"on":"":String(n);(a!==c||!("_value"in e))&&(e.value=c),n==null&&e.removeAttribute(t),e._value=n;return}let i=!1;if(n===""||n==null){const a=typeof e[t];a==="boolean"?n=Xv(n):n==null&&a==="string"?(n="",i=!0):a==="number"&&(n=0,i=!0)}try{e[t]=n}catch{}i&&e.removeAttribute(r||t)}function Zo(e,t,n,s){e.addEventListener(t,n,s)}function DC(e,t,n,s){e.removeEventListener(t,n,s)}const Zy=Symbol("_vei");function UC(e,t,n,s,r=null){const o=e[Zy]||(e[Zy]={}),i=o[t];if(s&&i)i.value=s;else{const[a,c]=VC(t);if(s){const u=o[t]=zC(s,r);Zo(e,a,u,c)}else i&&(DC(e,a,i,c),o[t]=void 0)}}const Yy=/(?:Once|Passive|Capture)$/;function VC(e){let t;if(Yy.test(e)){t={};let s;for(;s=e.match(Yy);)e=e.slice(0,e.length-s[0].length),t[s[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):Kr(e.slice(2)),t]}let Bd=0;const jC=Promise.resolve(),HC=()=>Bd||(jC.then(()=>Bd=0),Bd=Date.now());function zC(e,t){const n=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=n.attached)return;Vn(qC(s,n.value),t,5,[s])};return n.value=e,n.attached=HC(),n}function qC(e,t){if(Te(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(s=>r=>!r._stopped&&s&&s(r))}else return t}const Jy=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,WC=(e,t,n,s,r,o)=>{const i=r==="svg";t==="class"?MC(e,s,i):t==="style"?NC(e,n,s):tl(t)?am(t)||UC(e,t,n,s,o):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):GC(e,t,s,i))?(Qy(e,t,s),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Ky(e,t,s,i,o,t!=="value")):e._isVueCE&&(/[A-Z]/.test(t)||!ot(s))?Qy(e,fn(t),s,o,t):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),Ky(e,t,s,i))};function GC(e,t,n,s){if(s)return!!(t==="innerHTML"||t==="textContent"||t in e&&Jy(t)&&ke(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return Jy(t)&&ot(n)?!1:t in e}const dw=new WeakMap,fw=new WeakMap,Du=Symbol("_moveCb"),e0=Symbol("_enterCb"),XC=e=>(delete e.props.mode,e),KC=XC({name:"TransitionGroup",props:at({},iw,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=bs(),s=T1();let r,o;return R1(()=>{if(!r.length)return;const i=e.moveClass||`${e.name||"v"}-move`;if(!eA(r[0].el,n.vnode.el,i))return;r.forEach(ZC),r.forEach(YC);const a=r.filter(JC);uw(),a.forEach(c=>{const u=c.el,l=u.style;As(u,i),l.transform=l.webkitTransform=l.transitionDuration="";const d=u[Du]=f=>{f&&f.target!==u||(!f||/transform$/.test(f.propertyName))&&(u.removeEventListener("transitionend",d),u[Du]=null,lr(u,i))};u.addEventListener("transitionend",d)})}),()=>{const i=Ve(e),a=aw(i);let c=i.tag||De;if(r=[],o)for(let u=0;u<o.length;u++){const l=o[u];l.el&&l.el instanceof Element&&(r.push(l),Ao(l,ja(l,a,s,n)),dw.set(l,l.el.getBoundingClientRect()))}o=t.default?_m(t.default()):[];for(let u=0;u<o.length;u++){const l=o[u];l.key!=null&&Ao(l,ja(l,a,s,n))}return $(c,null,o)}}}),QC=KC;function ZC(e){const t=e.el;t[Du]&&t[Du](),t[e0]&&t[e0]()}function YC(e){fw.set(e,e.el.getBoundingClientRect())}function JC(e){const t=dw.get(e),n=fw.get(e),s=t.left-n.left,r=t.top-n.top;if(s||r){const o=e.el.style;return o.transform=o.webkitTransform=`translate(${s}px,${r}px)`,o.transitionDuration="0s",e}}function eA(e,t,n){const s=e.cloneNode(),r=e[ki];r&&r.forEach(a=>{a.split(/\s+/).forEach(c=>c&&s.classList.remove(c))}),n.split(/\s+/).forEach(a=>a&&s.classList.add(a)),s.style.display="none";const o=t.nodeType===1?t:t.parentNode;o.appendChild(s);const{hasTransform:i}=cw(s);return o.removeChild(s),i}const t0=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Te(t)?n=>hu(t,n):t};function tA(e){e.target.composing=!0}function n0(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Dd=Symbol("_assign"),pw={created(e,{modifiers:{lazy:t,trim:n,number:s}},r){e[Dd]=t0(r);const o=s||r.props&&r.props.type==="number";Zo(e,t?"change":"input",i=>{if(i.target.composing)return;let a=e.value;n&&(a=a.trim()),o&&(a=gf(a)),e[Dd](a)}),n&&Zo(e,"change",()=>{e.value=e.value.trim()}),t||(Zo(e,"compositionstart",tA),Zo(e,"compositionend",n0),Zo(e,"change",n0))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:s,trim:r,number:o}},i){if(e[Dd]=t0(i),e.composing)return;const a=(o||e.type==="number")&&!/^0\d/.test(e.value)?gf(e.value):e.value,c=t??"";a!==c&&(document.activeElement===e&&e.type!=="range"&&(s&&t===n||r&&e.value.trim()===c)||(e.value=c))}},nA=["ctrl","shift","alt","meta"],sA={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>nA.some(n=>e[`${n}Key`]&&!t.includes(n))},Ac=(e,t)=>{const n=e._withMods||(e._withMods={}),s=t.join(".");return n[s]||(n[s]=(r,...o)=>{for(let i=0;i<t.length;i++){const a=sA[t[i]];if(a&&a(r,t))return}return e(r,...o)})},rA=at({patchProp:WC},PC);let s0;function oA(){return s0||(s0=J3(rA))}const iA=(...e)=>{const t=oA().createApp(...e),{mount:n}=t;return t.mount=s=>{const r=cA(s);if(!r)return;const o=t._component;!ke(o)&&!o.render&&!o.template&&(o.template=r.innerHTML),r.nodeType===1&&(r.textContent="");const i=n(r,!1,aA(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),i},t};function aA(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function cA(e){return ot(e)?document.querySelector(e):e}/*!
  * vue-i18n v10.0.4
  * (c) 2024 kazuya kawaguchi
  * Released under the MIT License.
  */const uA="10.0.4";function lA(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(Iv().__INTLIFY_PROD_DEVTOOLS__=!1)}const Sn={UNEXPECTED_RETURN_TYPE:Y5,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function jn(e,...t){return Ju(e,null,void 0)}const $f=Wr("__translateVNode"),Mf=Wr("__datetimeParts"),Of=Wr("__numberParts"),dA=Wr("__setPluralRules"),fA=Wr("__injectWithOption"),Lf=Wr("__dispose");function qa(e){if(!Jt(e))return e;for(const t in e)if(Pu(e,t))if(!t.includes("."))Jt(e[t])&&qa(e[t]);else{const n=t.split("."),s=n.length-1;let r=e,o=!1;for(let i=0;i<s;i++){if(n[i]in r||(r[n[i]]={}),!Jt(r[n[i]])){o=!0;break}r=r[n[i]]}o||(r[n[s]]=e[t],delete e[t]),Jt(r[n[s]])&&qa(r[n[s]])}return e}function mw(e,t){const{messages:n,__i18n:s,messageResolver:r,flatJson:o}=t,i=Mn(n)?n:Os(s)?{}:{[e]:{}};if(Os(s)&&s.forEach(a=>{if("locale"in a&&"resource"in a){const{locale:c,resource:u}=a;c?(i[c]=i[c]||{},mu(u,i[c])):mu(u,i)}else dt(a)&&mu(JSON.parse(a),i)}),r==null&&o)for(const a in i)Pu(i,a)&&qa(i[a]);return i}function hw(e){return e.type}function pA(e,t,n){let s=Jt(t.messages)?t.messages:{};"__i18nGlobal"in n&&(s=mw(e.locale.value,{messages:s,__i18n:n.__i18nGlobal}));const r=Object.keys(s);r.length&&r.forEach(o=>{e.mergeLocaleMessage(o,s[o])});{if(Jt(t.datetimeFormats)){const o=Object.keys(t.datetimeFormats);o.length&&o.forEach(i=>{e.mergeDateTimeFormat(i,t.datetimeFormats[i])})}if(Jt(t.numberFormats)){const o=Object.keys(t.numberFormats);o.length&&o.forEach(i=>{e.mergeNumberFormat(i,t.numberFormats[i])})}}}function r0(e){return $(xc,null,e,0)}const o0="__INTLIFY_META__",i0=()=>[],mA=()=>!1;let a0=0;function c0(e){return(t,n,s,r)=>e(n,s,bs()||void 0,r)}const hA=()=>{const e=bs();let t=null;return e&&(t=hw(e)[o0])?{[o0]:t}:null};function yw(e={}){const{__root:t,__injectWithOption:n}=e,s=t===void 0,r=e.flatJson,o=Su?le:Bo;let i=Es(e.inheritLocale)?e.inheritLocale:!0;const a=o(t&&i?t.locale.value:dt(e.locale)?e.locale:ku),c=o(t&&i?t.fallbackLocale.value:dt(e.fallbackLocale)||Os(e.fallbackLocale)||Mn(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:a.value),u=o(mw(a.value,e)),l=o(Mn(e.datetimeFormats)?e.datetimeFormats:{[a.value]:{}}),d=o(Mn(e.numberFormats)?e.numberFormats:{[a.value]:{}});let f=t?t.missingWarn:Es(e.missingWarn)||Zh(e.missingWarn)?e.missingWarn:!0,p=t?t.fallbackWarn:Es(e.fallbackWarn)||Zh(e.fallbackWarn)?e.fallbackWarn:!0,m=t?t.fallbackRoot:Es(e.fallbackRoot)?e.fallbackRoot:!0,h=!!e.fallbackFormat,y=Vc(e.missing)?e.missing:null,b=Vc(e.missing)?c0(e.missing):null,g=Vc(e.postTranslation)?e.postTranslation:null,w=t?t.warnHtmlMessage:Es(e.warnHtmlMessage)?e.warnHtmlMessage:!0,_=!!e.escapeParameter;const A=t?t.modifiers:Mn(e.modifiers)?e.modifiers:{};let x=e.pluralRules||t&&t.pluralRules,C;C=(()=>{s&&dy(null);const D={version:uA,locale:a.value,fallbackLocale:c.value,messages:u.value,modifiers:A,pluralRules:x,missing:b===null?void 0:b,missingWarn:f,fallbackWarn:p,fallbackFormat:h,unresolving:!0,postTranslation:g===null?void 0:g,warnHtmlMessage:w,escapeParameter:_,messageResolver:e.messageResolver,messageCompiler:e.messageCompiler,__meta:{framework:"vue"}};D.datetimeFormats=l.value,D.numberFormats=d.value,D.__datetimeFormatters=Mn(C)?C.__datetimeFormatters:void 0,D.__numberFormatters=Mn(C)?C.__numberFormatters:void 0;const Q=gx(D);return s&&dy(Q),Q})(),la(C,a.value,c.value);function S(){return[a.value,c.value,u.value,l.value,d.value]}const R=M({get:()=>a.value,set:D=>{a.value=D,C.locale=a.value}}),B=M({get:()=>c.value,set:D=>{c.value=D,C.fallbackLocale=c.value,la(C,a.value,D)}}),L=M(()=>u.value),X=M(()=>l.value),z=M(()=>d.value);function ie(){return Vc(g)?g:null}function ne(D){g=D,C.postTranslation=D}function te(){return y}function ce(D){D!==null&&(b=c0(D)),y=D,C.missing=b}const he=(D,Q,de,ve,Ne,je)=>{S();let lt;try{__INTLIFY_PROD_DEVTOOLS__,s||(C.fallbackContext=t?bx():void 0),lt=D(C)}finally{__INTLIFY_PROD_DEVTOOLS__,s||(C.fallbackContext=void 0)}if(de!=="translate exists"&&Na(lt)&&lt===el||de==="translate exists"&&!lt){const[_t,hn]=Q();return t&&m?ve(t):Ne(_t)}else{if(je(lt))return lt;throw jn(Sn.UNEXPECTED_RETURN_TYPE)}};function _e(...D){return he(Q=>Reflect.apply(vy,null,[Q,...D]),()=>bf(...D),"translate",Q=>Reflect.apply(Q.t,Q,[...D]),Q=>Q,Q=>dt(Q))}function Fe(...D){const[Q,de,ve]=D;if(ve&&!Jt(ve))throw jn(Sn.INVALID_ARGUMENT);return _e(Q,de,as({resolvedMessage:!0},ve||{}))}function Ae(...D){return he(Q=>Reflect.apply(py,null,[Q,...D]),()=>hf(...D),"datetime format",Q=>Reflect.apply(Q.d,Q,[...D]),()=>uy,Q=>dt(Q))}function qe(...D){return he(Q=>Reflect.apply(hy,null,[Q,...D]),()=>yf(...D),"number format",Q=>Reflect.apply(Q.n,Q,[...D]),()=>uy,Q=>dt(Q))}function Ye(D){return D.map(Q=>dt(Q)||Na(Q)||Es(Q)?r0(String(Q)):Q)}const Xe={normalize:Ye,interpolate:D=>D,type:"vnode"};function se(...D){return he(Q=>{let de;const ve=Q;try{ve.processor=Xe,de=Reflect.apply(vy,null,[ve,...D])}finally{ve.processor=null}return de},()=>bf(...D),"translate",Q=>Q[$f](...D),Q=>[r0(Q)],Q=>Os(Q))}function V(...D){return he(Q=>Reflect.apply(hy,null,[Q,...D]),()=>yf(...D),"number format",Q=>Q[Of](...D),i0,Q=>dt(Q)||Os(Q))}function j(...D){return he(Q=>Reflect.apply(py,null,[Q,...D]),()=>hf(...D),"datetime format",Q=>Q[Mf](...D),i0,Q=>dt(Q)||Os(Q))}function U(D){x=D,C.pluralRules=x}function oe(D,Q){return he(()=>{if(!D)return!1;const de=dt(Q)?Q:a.value,ve=O(de),Ne=C.messageResolver(ve,D);return Ei(Ne)||_n(Ne)||dt(Ne)},()=>[D],"translate exists",de=>Reflect.apply(de.te,de,[D,Q]),mA,de=>Es(de))}function be(D){let Q=null;const de=Mv(C,c.value,a.value);for(let ve=0;ve<de.length;ve++){const Ne=u.value[de[ve]]||{},je=C.messageResolver(Ne,D);if(je!=null){Q=je;break}}return Q}function P(D){const Q=be(D);return Q??(t?t.tm(D)||{}:{})}function O(D){return u.value[D]||{}}function q(D,Q){if(r){const de={[D]:Q};for(const ve in de)Pu(de,ve)&&qa(de[ve]);Q=de[D]}u.value[D]=Q,C.messages=u.value}function K(D,Q){u.value[D]=u.value[D]||{};const de={[D]:Q};if(r)for(const ve in de)Pu(de,ve)&&qa(de[ve]);Q=de[D],mu(Q,u.value[D]),C.messages=u.value}function G(D){return l.value[D]||{}}function E(D,Q){l.value[D]=Q,C.datetimeFormats=l.value,my(C,D,Q)}function I(D,Q){l.value[D]=as(l.value[D]||{},Q),C.datetimeFormats=l.value,my(C,D,Q)}function H(D){return d.value[D]||{}}function W(D,Q){d.value[D]=Q,C.numberFormats=d.value,yy(C,D,Q)}function ee(D,Q){d.value[D]=as(d.value[D]||{},Q),C.numberFormats=d.value,yy(C,D,Q)}a0++,t&&Su&&(Ce(t.locale,D=>{i&&(a.value=D,C.locale=D,la(C,a.value,c.value))}),Ce(t.fallbackLocale,D=>{i&&(c.value=D,C.fallbackLocale=D,la(C,a.value,c.value))}));const re={id:a0,locale:R,fallbackLocale:B,get inheritLocale(){return i},set inheritLocale(D){i=D,D&&t&&(a.value=t.locale.value,c.value=t.fallbackLocale.value,la(C,a.value,c.value))},get availableLocales(){return Object.keys(u.value).sort()},messages:L,get modifiers(){return A},get pluralRules(){return x||{}},get isGlobal(){return s},get missingWarn(){return f},set missingWarn(D){f=D,C.missingWarn=f},get fallbackWarn(){return p},set fallbackWarn(D){p=D,C.fallbackWarn=p},get fallbackRoot(){return m},set fallbackRoot(D){m=D},get fallbackFormat(){return h},set fallbackFormat(D){h=D,C.fallbackFormat=h},get warnHtmlMessage(){return w},set warnHtmlMessage(D){w=D,C.warnHtmlMessage=D},get escapeParameter(){return _},set escapeParameter(D){_=D,C.escapeParameter=D},t:_e,getLocaleMessage:O,setLocaleMessage:q,mergeLocaleMessage:K,getPostTranslationHandler:ie,setPostTranslationHandler:ne,getMissingHandler:te,setMissingHandler:ce,[dA]:U};return re.datetimeFormats=X,re.numberFormats=z,re.rt=Fe,re.te=oe,re.tm=P,re.d=Ae,re.n=qe,re.getDateTimeFormat=G,re.setDateTimeFormat=E,re.mergeDateTimeFormat=I,re.getNumberFormat=H,re.setNumberFormat=W,re.mergeNumberFormat=ee,re[fA]=n,re[$f]=se,re[Mf]=j,re[Of]=V,re}const Im={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:e=>e==="parent"||e==="global",default:"parent"},i18n:{type:Object}};function yA({slots:e},t){return t.length===1&&t[0]==="default"?(e.default?e.default():[]).reduce((s,r)=>[...s,...r.type===De?r.children:[r]],[]):t.reduce((n,s)=>{const r=e[s];return r&&(n[s]=r()),n},{})}function bw(){return De}const bA=ae({name:"i18n-t",props:as({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:e=>Na(e)||!isNaN(e)}},Im),setup(e,t){const{slots:n,attrs:s}=t,r=e.i18n||Me({useScope:e.scope,__useComponent:!0});return()=>{const o=Object.keys(n).filter(d=>d!=="_"),i={};e.locale&&(i.locale=e.locale),e.plural!==void 0&&(i.plural=dt(e.plural)?+e.plural:e.plural);const a=yA(t,o),c=r[$f](e.keypath,a,i),u=as({},s),l=dt(e.tag)||Jt(e.tag)?e.tag:bw();return Fr(l,u,c)}}}),u0=bA;function gA(e){return Os(e)&&!dt(e[0])}function gw(e,t,n,s){const{slots:r,attrs:o}=t;return()=>{const i={part:!0};let a={};e.locale&&(i.locale=e.locale),dt(e.format)?i.key=e.format:Jt(e.format)&&(dt(e.format.key)&&(i.key=e.format.key),a=Object.keys(e.format).reduce((f,p)=>n.includes(p)?as({},f,{[p]:e.format[p]}):f,{}));const c=s(e.value,i,a);let u=[i.key];Os(c)?u=c.map((f,p)=>{const m=r[f.type],h=m?m({[f.type]:f.value,index:p,parts:c}):[f.value];return gA(h)&&(h[0].key=`${f.type}-${p}`),h}):dt(c)&&(u=[c]);const l=as({},o),d=dt(e.tag)||Jt(e.tag)?e.tag:bw();return Fr(d,l,u)}}const vA=ae({name:"i18n-n",props:as({value:{type:Number,required:!0},format:{type:[String,Object]}},Im),setup(e,t){const n=e.i18n||Me({useScope:e.scope,__useComponent:!0});return gw(e,t,Uv,(...s)=>n[Of](...s))}}),l0=vA,wA=ae({name:"i18n-d",props:as({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},Im),setup(e,t){const n=e.i18n||Me({useScope:e.scope,__useComponent:!0});return gw(e,t,Dv,(...s)=>n[Mf](...s))}}),d0=wA;function _A(e,t){const n=e;if(e.mode==="composition")return n.__getInstance(t)||e.global;{const s=n.__getInstance(t);return s!=null?s.__composer:e.global.__composer}}function xA(e){const t=i=>{const{instance:a,value:c}=i;if(!a||!a.$)throw jn(Sn.UNEXPECTED_ERROR);const u=_A(e,a.$),l=f0(c);return[Reflect.apply(u.t,u,[...p0(l)]),u]};return{created:(i,a)=>{const[c,u]=t(a);Su&&e.global===u&&(i.__i18nWatcher=Ce(u.locale,()=>{a.instance&&a.instance.$forceUpdate()})),i.__composer=u,i.textContent=c},unmounted:i=>{Su&&i.__i18nWatcher&&(i.__i18nWatcher(),i.__i18nWatcher=void 0,delete i.__i18nWatcher),i.__composer&&(i.__composer=void 0,delete i.__composer)},beforeUpdate:(i,{value:a})=>{if(i.__composer){const c=i.__composer,u=f0(a);i.textContent=Reflect.apply(c.t,c,[...p0(u)])}},getSSRProps:i=>{const[a]=t(i);return{textContent:a}}}}function f0(e){if(dt(e))return{path:e};if(Mn(e)){if(!("path"in e))throw jn(Sn.REQUIRED_VALUE,"path");return e}else throw jn(Sn.INVALID_VALUE)}function p0(e){const{path:t,locale:n,args:s,choice:r,plural:o}=e,i={},a=s||{};return dt(n)&&(i.locale=n),Na(r)&&(i.plural=r),Na(o)&&(i.plural=o),[t,a,i]}function CA(e,t,...n){const s=Mn(n[0])?n[0]:{};(Es(s.globalInstall)?s.globalInstall:!0)&&([u0.name,"I18nT"].forEach(o=>e.component(o,u0)),[l0.name,"I18nN"].forEach(o=>e.component(o,l0)),[d0.name,"I18nD"].forEach(o=>e.component(o,d0))),e.directive("t",xA(t))}const AA=Wr("global-vue-i18n");function TA(e={},t){const n=Es(e.globalInjection)?e.globalInjection:!0,s=new Map,[r,o]=EA(e),i=Wr("");function a(d){return s.get(d)||null}function c(d,f){s.set(d,f)}function u(d){s.delete(d)}const l={get mode(){return"composition"},async install(d,...f){if(d.__VUE_I18N_SYMBOL__=i,d.provide(d.__VUE_I18N_SYMBOL__,l),Mn(f[0])){const h=f[0];l.__composerExtend=h.__composerExtend,l.__vueI18nExtend=h.__vueI18nExtend}let p=null;n&&(p=OA(d,l.global)),CA(d,l,...f);const m=d.unmount;d.unmount=()=>{p&&p(),l.dispose(),m()}},get global(){return o},dispose(){r.stop()},__instances:s,__getInstance:a,__setInstance:c,__deleteInstance:u};return l}function Me(e={}){const t=bs();if(t==null)throw jn(Sn.MUST_BE_CALL_SETUP_TOP);if(!t.isCE&&t.appContext.app!=null&&!t.appContext.app.__VUE_I18N_SYMBOL__)throw jn(Sn.NOT_INSTALLED);const n=SA(t),s=kA(n),r=hw(t),o=PA(e,r);if(o==="global")return pA(s,e,r),s;if(o==="parent"){let c=IA(n,t,e.__useComponent);return c==null&&(c=s),c}const i=n;let a=i.__getInstance(t);if(a==null){const c=as({},e);"__i18n"in r&&(c.__i18n=r.__i18n),s&&(c.__root=s),a=yw(c),i.__composerExtend&&(a[Lf]=i.__composerExtend(a)),$A(i,t,a),i.__setInstance(t,a)}return a}function EA(e,t,n){const s=lm(),r=s.run(()=>yw(e));if(r==null)throw jn(Sn.UNEXPECTED_ERROR);return[s,r]}function SA(e){const t=Nt(e.isCE?AA:e.appContext.app.__VUE_I18N_SYMBOL__);if(!t)throw jn(e.isCE?Sn.NOT_INSTALLED_WITH_PROVIDE:Sn.UNEXPECTED_ERROR);return t}function PA(e,t){return u5(e)?"__i18n"in t?"local":"global":e.useScope?e.useScope:"local"}function kA(e){return e.mode==="composition"?e.global:e.global.__composer}function IA(e,t,n=!1){let s=null;const r=t.root;let o=RA(t,n);for(;o!=null;){const i=e;if(e.mode==="composition"&&(s=i.__getInstance(o)),s!=null||r===o)break;o=o.parent}return s}function RA(e,t=!1){return e==null?null:t&&e.vnode.ctx||e.parent}function $A(e,t,n){Gn(()=>{},t),Qi(()=>{const s=n;e.__deleteInstance(t);const r=s[Lf];r&&(r(),delete s[Lf])},t)}const MA=["locale","fallbackLocale","availableLocales"],m0=["t","rt","d","n","tm","te"];function OA(e,t){const n=Object.create(null);return MA.forEach(r=>{const o=Object.getOwnPropertyDescriptor(t,r);if(!o)throw jn(Sn.UNEXPECTED_ERROR);const i=$e(o.value)?{get(){return o.value.value},set(a){o.value.value=a}}:{get(){return o.get&&o.get()}};Object.defineProperty(n,r,i)}),e.config.globalProperties.$i18n=n,m0.forEach(r=>{const o=Object.getOwnPropertyDescriptor(t,r);if(!o||!o.value)throw jn(Sn.UNEXPECTED_ERROR);Object.defineProperty(e.config.globalProperties,`$${r}`,o)}),()=>{delete e.config.globalProperties.$i18n,m0.forEach(r=>{delete e.config.globalProperties[`$${r}`]})}}lA();fx(G5);px(ux);mx(Mv);if(__INTLIFY_PROD_DEVTOOLS__){const e=Iv();e.__INTLIFY__=!0,X5(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const vw="2.21.34";let ma={getDocsUrl:({docsBaseUrl:e,docsPath:t="",docsSlug:n})=>t?`${e??"https://viem.sh"}${t}${n?`#${n}`:""}`:void 0,version:`viem@${vw}`},ue=class Ff extends Error{constructor(t,n={}){var a;const s=(()=>{var c;return n.cause instanceof Ff?n.cause.details:(c=n.cause)!=null&&c.message?n.cause.message:n.details})(),r=n.cause instanceof Ff&&n.cause.docsPath||n.docsPath,o=(a=ma.getDocsUrl)==null?void 0:a.call(ma,{...n,docsPath:r}),i=[t||"An error occurred.","",...n.metaMessages?[...n.metaMessages,""]:[],...o?[`Docs: ${o}`]:[],...s?[`Details: ${s}`]:[],...ma.version?[`Version: ${ma.version}`]:[]].join(`
`);super(i,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=s,this.docsPath=r,this.metaMessages=n.metaMessages,this.name=n.name??this.name,this.shortMessage=t,this.version=vw}walk(t){return ww(this,t)}};function ww(e,t){return t!=null&&t(e)?e:e&&typeof e=="object"&&"cause"in e?ww(e.cause,t):t?null:e}class LA extends ue{constructor({max:t,min:n,signed:s,size:r,value:o}){super(`Number "${o}" is not in safe ${r?`${r*8}-bit ${s?"signed":"unsigned"} `:""}integer range ${t?`(${n} to ${t})`:`(above ${n})`}`,{name:"IntegerOutOfRangeError"})}}class FA extends ue{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 NA extends ue{constructor(t){super(`Hex value "${t}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`,{name:"InvalidHexBooleanError"})}}class BA extends ue{constructor({givenSize:t,maxSize:n}){super(`Size cannot exceed ${n} bytes. Given size: ${t} bytes.`,{name:"SizeOverflowError"})}}class _w extends ue{constructor({offset:t,position:n,size:s}){super(`Slice ${n==="start"?"starting":"ending"} at offset "${t}" is out-of-bounds (size: ${s}).`,{name:"SliceOffsetOutOfBoundsError"})}}class xw extends ue{constructor({size:t,targetSize:n,type:s}){super(`${s.charAt(0).toUpperCase()}${s.slice(1).toLowerCase()} size (${t}) exceeds padding size (${n}).`,{name:"SizeExceedsPaddingSizeError"})}}class h0 extends ue{constructor({size:t,targetSize:n,type:s}){super(`${s.charAt(0).toUpperCase()}${s.slice(1).toLowerCase()} is expected to be ${n} ${s} long, but is ${t} ${s} long.`,{name:"InvalidBytesLengthError"})}}function Zi(e,{dir:t,size:n=32}={}){return typeof e=="string"?kr(e,{dir:t,size:n}):DA(e,{dir:t,size:n})}function kr(e,{dir:t,size:n=32}={}){if(n===null)return e;const s=e.replace("0x","");if(s.length>n*2)throw new xw({size:Math.ceil(s.length/2),targetSize:n,type:"hex"});return`0x${s[t==="right"?"padEnd":"padStart"](n*2,"0")}`}function DA(e,{dir:t,size:n=32}={}){if(n===null)return e;if(e.length>n)throw new xw({size:e.length,targetSize:n,type:"bytes"});const s=new Uint8Array(n);for(let r=0;r<n;r++){const o=t==="right";s[o?r:n-r-1]=e[o?r:e.length-r-1]}return s}function ms(e,{strict:t=!0}={}){return!e||typeof e!="string"?!1:t?/^0x[0-9a-fA-F]*$/.test(e):e.startsWith("0x")}function ut(e){return ms(e,{strict:!1})?Math.ceil((e.length-2)/2):e.length}function Ds(e,{dir:t="left"}={}){let n=typeof e=="string"?e.replace("0x",""):e,s=0;for(let r=0;r<n.length-1&&n[t==="left"?r:n.length-r-1].toString()==="0";r++)s++;return n=t==="left"?n.slice(s):n.slice(0,n.length-s),typeof e=="string"?(n.length===1&&t==="right"&&(n=`${n}0`),`0x${n.length%2===1?`0${n}`:n}`):n}const UA=new TextEncoder;function Yi(e,t={}){return typeof e=="number"||typeof e=="bigint"?jA(e,t):typeof e=="boolean"?VA(e,t):ms(e)?Pn(e,t):go(e,t)}function VA(e,t={}){const n=new Uint8Array(1);return n[0]=Number(e),typeof t.size=="number"?(kn(n,{size:t.size}),Zi(n,{size:t.size})):n}const _s={zero:48,nine:57,A:65,F:70,a:97,f:102};function y0(e){if(e>=_s.zero&&e<=_s.nine)return e-_s.zero;if(e>=_s.A&&e<=_s.F)return e-(_s.A-10);if(e>=_s.a&&e<=_s.f)return e-(_s.a-10)}function Pn(e,t={}){let n=e;t.size&&(kn(n,{size:t.size}),n=Zi(n,{dir:"right",size:t.size}));let s=n.slice(2);s.length%2&&(s=`0${s}`);const r=s.length/2,o=new Uint8Array(r);for(let i=0,a=0;i<r;i++){const c=y0(s.charCodeAt(a++)),u=y0(s.charCodeAt(a++));if(c===void 0||u===void 0)throw new ue(`Invalid byte sequence ("${s[a-2]}${s[a-1]}" in "${s}").`);o[i]=c*16+u}return o}function jA(e,t){const n=Ee(e,t);return Pn(n)}function go(e,t={}){const n=UA.encode(e);return typeof t.size=="number"?(kn(n,{size:t.size}),Zi(n,{dir:"right",size:t.size})):n}function kn(e,{size:t}){if(ut(e)>t)throw new BA({givenSize:ut(e),maxSize:t})}function Nr(e,t={}){const{signed:n}=t;t.size&&kn(e,{size:t.size});const s=BigInt(e);if(!n)return s;const r=(e.length-2)/2,o=(1n<<BigInt(r)*8n-1n)-1n;return s<=o?s:s-BigInt(`0x${"f".padStart(r*2,"f")}`)-1n}function HA(e,t={}){let n=e;if(t.size&&(kn(n,{size:t.size}),n=Ds(n)),Ds(n)==="0x00")return!1;if(Ds(n)==="0x01")return!0;throw new NA(n)}function hs(e,t={}){return Number(Nr(e,t))}function Cw(e,t={}){let n=Pn(e);return t.size&&(kn(n,{size:t.size}),n=Ds(n,{dir:"right"})),new TextDecoder().decode(n)}const zA=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function qs(e,t={}){return typeof e=="number"||typeof e=="bigint"?Ee(e,t):typeof e=="string"?Ii(e,t):typeof e=="boolean"?Aw(e,t):wt(e,t)}function Aw(e,t={}){const n=`0x${Number(e)}`;return typeof t.size=="number"?(kn(n,{size:t.size}),Zi(n,{size:t.size})):n}function wt(e,t={}){let n="";for(let r=0;r<e.length;r++)n+=zA[e[r]];const s=`0x${n}`;return typeof t.size=="number"?(kn(s,{size:t.size}),Zi(s,{dir:"right",size:t.size})):s}function Ee(e,t={}){const{signed:n,size:s}=t,r=BigInt(e);let o;s?n?o=(1n<<BigInt(s)*8n-1n)-1n:o=2n**(BigInt(s)*8n)-1n:typeof e=="number"&&(o=BigInt(Number.MAX_SAFE_INTEGER));const i=typeof o=="bigint"&&n?-o-1n:0;if(o&&r>o||r<i){const c=typeof e=="bigint"?"n":"";throw new LA({max:o?`${o}${c}`:void 0,min:`${i}${c}`,signed:n,size:s,value:`${e}${c}`})}const a=`0x${(n&&r<0?(1n<<BigInt(s*8))+BigInt(r):r).toString(16)}`;return s?Zi(a,{size:s}):a}const qA=new TextEncoder;function Ii(e,t={}){const n=qA.encode(e);return wt(n,t)}function Ws(e,{includeName:t=!1}={}){if(e.type!=="function"&&e.type!=="event"&&e.type!=="error")throw new r8(e.type);return`${e.name}(${bl(e.inputs,{includeName:t})})`}function bl(e,{includeName:t=!1}={}){return e?e.map(n=>WA(n,{includeName:t})).join(t?", ":","):""}function WA(e,{includeName:t}){return e.type.startsWith("tuple")?`(${bl(e.components,{includeName:t})})${e.type.slice(5)}`:e.type+(t&&e.name?` ${e.name}`:"")}class GA extends ue{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(`
`),{docsPath:t,name:"AbiConstructorNotFoundError"})}}class b0 extends ue{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(`
`),{docsPath:t,name:"AbiConstructorParamsNotFoundError"})}}class Tw extends ue{constructor({data:t,params:n,size:s}){super([`Data size of ${s} bytes is too small for given parameters.`].join(`
`),{metaMessages:[`Params: (${bl(n,{includeName:!0})})`,`Data:   ${t} (${s} 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=s}}class gl extends ue{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.',{name:"AbiDecodingZeroDataError"})}}class XA extends ue{constructor({expectedLength:t,givenLength:n,type:s}){super([`ABI encoding array length mismatch for type ${s}.`,`Expected length: ${t}`,`Given length: ${n}`].join(`
`),{name:"AbiEncodingArrayLengthMismatchError"})}}class KA extends ue{constructor({expectedSize:t,value:n}){super(`Size of bytes "${n}" (bytes${ut(n)}) does not match expected size (bytes${t}).`,{name:"AbiEncodingBytesSizeMismatchError"})}}class QA extends ue{constructor({expectedLength:t,givenLength:n}){super(["ABI encoding params/values length mismatch.",`Expected length (params): ${t}`,`Given length (values): ${n}`].join(`
`),{name:"AbiEncodingLengthMismatchError"})}}class Ew extends ue{constructor(t,{docsPath:n}){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://openchain.xyz/signatures?query=${t}.`].join(`
`),{docsPath:n,name:"AbiErrorSignatureNotFoundError"}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.signature=t}}class ZA extends ue{constructor({docsPath:t}){super("Cannot extract event signature from empty topics.",{docsPath:t,name:"AbiEventSignatureEmptyTopicsError"})}}class Sw extends ue{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://openchain.xyz/signatures?query=${t}.`].join(`
`),{docsPath:n,name:"AbiEventSignatureNotFoundError"})}}class g0 extends ue{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(`
`),{docsPath:n,name:"AbiEventNotFoundError"})}}class Uu extends ue{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(`
`),{docsPath:n,name:"AbiFunctionNotFoundError"})}}class YA extends ue{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(`
`),{docsPath:n,name:"AbiFunctionOutputsNotFoundError"})}}class JA extends ue{constructor(t,n){super("Found ambiguous types in overloaded ABI items.",{metaMessages:[`\`${t.type}\` in \`${Ws(t.abiItem)}\`, and`,`\`${n.type}\` in \`${Ws(n.abiItem)}\``,"","These types encode differently and cannot be distinguished at runtime.","Remove one of the ambiguous items in the ABI."],name:"AbiItemAmbiguityError"})}}class e8 extends ue{constructor({expectedSize:t,givenSize:n}){super(`Expected bytes${t}, got bytes${n}.`,{name:"BytesSizeMismatchError"})}}class Wa extends ue{constructor({abiItem:t,data:n,params:s,size:r}){super([`Data size of ${r} bytes is too small for non-indexed event parameters.`].join(`
`),{metaMessages:[`Params: (${bl(s,{includeName:!0})})`,`Data:   ${n} (${r} 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=s,this.size=r}}class vl extends ue{constructor({abiItem:t,param:n}){super([`Expected a topic for indexed event parameter${n.name?` "${n.name}"`:""} on event "${Ws(t,{includeName:!0})}".`].join(`
`),{name:"DecodeLogTopicsMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=t}}class t8 extends ue{constructor(t,{docsPath:n}){super([`Type "${t}" is not a valid encoding type.`,"Please provide a valid ABI type."].join(`
`),{docsPath:n,name:"InvalidAbiEncodingType"})}}class n8 extends ue{constructor(t,{docsPath:n}){super([`Type "${t}" is not a valid decoding type.`,"Please provide a valid ABI type."].join(`
`),{docsPath:n,name:"InvalidAbiDecodingType"})}}class s8 extends ue{constructor(t){super([`Value "${t}" is not a valid array.`].join(`
`),{name:"InvalidArrayError"})}}class r8 extends ue{constructor(t){super([`"${t}" is not a valid definition type.`,'Valid types: "function", "event", "error"'].join(`
`),{name:"InvalidDefinitionTypeError"})}}function Gs(e){return typeof e[0]=="string"?Tc(e):o8(e)}function o8(e){let t=0;for(const r of e)t+=r.length;const n=new Uint8Array(t);let s=0;for(const r of e)n.set(r,s),s+=r.length;return n}function Tc(e){return`0x${e.reduce((t,n)=>t+n.replace("0x",""),"")}`}class Br extends ue{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"})}}class wl 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 s=this.keys().next().value;s&&this.delete(s)}return this}}function Vu(e){if(!Number.isSafeInteger(e)||e<0)throw new Error(`positive integer expected, not ${e}`)}function i8(e){return e instanceof Uint8Array||e!=null&&typeof e=="object"&&e.constructor.name==="Uint8Array"}function Ec(e,...t){if(!i8(e))throw new Error("Uint8Array expected");if(t.length>0&&!t.includes(e.length))throw new Error(`Uint8Array expected of length ${t}, not of length=${e.length}`)}function a8(e){if(typeof e!="function"||typeof e.create!="function")throw new Error("Hash should be wrapped by utils.wrapConstructor");Vu(e.outputLen),Vu(e.blockLen)}function Ri(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 Pw(e,t){Ec(e);const n=t.outputLen;if(e.length<n)throw new Error(`digestInto() expects output buffer of length at least ${n}`)}const Kc=BigInt(2**32-1),v0=BigInt(32);function c8(e,t=!1){return t?{h:Number(e&Kc),l:Number(e>>v0&Kc)}:{h:Number(e>>v0&Kc)|0,l:Number(e&Kc)|0}}function u8(e,t=!1){let n=new Uint32Array(e.length),s=new Uint32Array(e.length);for(let r=0;r<e.length;r++){const{h:o,l:i}=c8(e[r],t);[n[r],s[r]]=[o,i]}return[n,s]}const l8=(e,t,n)=>e<<n|t>>>32-n,d8=(e,t,n)=>t<<n|e>>>32-n,f8=(e,t,n)=>t<<n-32|e>>>64-n,p8=(e,t,n)=>e<<n-32|t>>>64-n,Go=typeof globalThis=="object"&&"crypto"in globalThis?globalThis.crypto:void 0;/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */const m8=e=>new Uint32Array(e.buffer,e.byteOffset,Math.floor(e.byteLength/4)),Ud=e=>new DataView(e.buffer,e.byteOffset,e.byteLength),Yn=(e,t)=>e<<32-t|e>>>t,w0=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68,h8=e=>e<<24&4278190080|e<<8&16711680|e>>>8&65280|e>>>24&255;function _0(e){for(let t=0;t<e.length;t++)e[t]=h8(e[t])}function y8(e){if(typeof e!="string")throw new Error(`utf8ToBytes expected string, got ${typeof e}`);return new Uint8Array(new TextEncoder().encode(e))}function _l(e){return typeof e=="string"&&(e=y8(e)),Ec(e),e}function b8(...e){let t=0;for(let s=0;s<e.length;s++){const r=e[s];Ec(r),t+=r.length}const n=new Uint8Array(t);for(let s=0,r=0;s<e.length;s++){const o=e[s];n.set(o,r),r+=o.length}return n}class Rm{clone(){return this._cloneInto()}}function kw(e){const t=s=>e().update(_l(s)).digest(),n=e();return t.outputLen=n.outputLen,t.blockLen=n.blockLen,t.create=()=>e(),t}function g8(e=32){if(Go&&typeof Go.getRandomValues=="function")return Go.getRandomValues(new Uint8Array(e));if(Go&&typeof Go.randomBytes=="function")return Go.randomBytes(e);throw new Error("crypto.getRandomValues must be defined")}const Iw=[],Rw=[],$w=[],v8=BigInt(0),ha=BigInt(1),w8=BigInt(2),_8=BigInt(7),x8=BigInt(256),C8=BigInt(113);for(let e=0,t=ha,n=1,s=0;e<24;e++){[n,s]=[s,(2*n+3*s)%5],Iw.push(2*(5*s+n)),Rw.push((e+1)*(e+2)/2%64);let r=v8;for(let o=0;o<7;o++)t=(t<<ha^(t>>_8)*C8)%x8,t&w8&&(r^=ha<<(ha<<BigInt(o))-ha);$w.push(r)}const[A8,T8]=u8($w,!0),x0=(e,t,n)=>n>32?f8(e,t,n):l8(e,t,n),C0=(e,t,n)=>n>32?p8(e,t,n):d8(e,t,n);function E8(e,t=24){const n=new Uint32Array(10);for(let s=24-t;s<24;s++){for(let i=0;i<10;i++)n[i]=e[i]^e[i+10]^e[i+20]^e[i+30]^e[i+40];for(let i=0;i<10;i+=2){const a=(i+8)%10,c=(i+2)%10,u=n[c],l=n[c+1],d=x0(u,l,1)^n[a],f=C0(u,l,1)^n[a+1];for(let p=0;p<50;p+=10)e[i+p]^=d,e[i+p+1]^=f}let r=e[2],o=e[3];for(let i=0;i<24;i++){const a=Rw[i],c=x0(r,o,a),u=C0(r,o,a),l=Iw[i];r=e[l],o=e[l+1],e[l]=c,e[l+1]=u}for(let i=0;i<50;i+=10){for(let a=0;a<10;a++)n[a]=e[i+a];for(let a=0;a<10;a++)e[i+a]^=~n[(a+2)%10]&n[(a+4)%10]}e[0]^=A8[s],e[1]^=T8[s]}n.fill(0)}class $m extends Rm{constructor(t,n,s,r=!1,o=24){if(super(),this.blockLen=t,this.suffix=n,this.outputLen=s,this.enableXOF=r,this.rounds=o,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,Vu(s),0>=this.blockLen||this.blockLen>=200)throw new Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=m8(this.state)}keccak(){w0||_0(this.state32),E8(this.state32,this.rounds),w0||_0(this.state32),this.posOut=0,this.pos=0}update(t){Ri(this);const{blockLen:n,state:s}=this;t=_l(t);const r=t.length;for(let o=0;o<r;){const i=Math.min(n-this.pos,r-o);for(let a=0;a<i;a++)s[this.pos++]^=t[o++];this.pos===n&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;const{state:t,suffix:n,pos:s,blockLen:r}=this;t[s]^=n,n&128&&s===r-1&&this.keccak(),t[r-1]^=128,this.keccak()}writeInto(t){Ri(this,!1),Ec(t),this.finish();const n=this.state,{blockLen:s}=this;for(let r=0,o=t.length;r<o;){this.posOut>=s&&this.keccak();const i=Math.min(s-this.posOut,o-r);t.set(n.subarray(this.posOut,this.posOut+i),r),this.posOut+=i,r+=i}return t}xofInto(t){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(t)}xof(t){return Vu(t),this.xofInto(new Uint8Array(t))}digestInto(t){if(Pw(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,this.state.fill(0)}_cloneInto(t){const{blockLen:n,suffix:s,outputLen:r,rounds:o,enableXOF:i}=this;return t||(t=new $m(n,s,r,i,o)),t.state32.set(this.state32),t.pos=this.pos,t.posOut=this.posOut,t.finished=this.finished,t.rounds=o,t.suffix=s,t.outputLen=r,t.enableXOF=i,t.destroyed=this.destroyed,t}}const S8=(e,t,n)=>kw(()=>new $m(t,e,n)),P8=S8(1,136,256/8);function Ct(e,t){const n=t||"hex",s=P8(ms(e,{strict:!1})?Yi(e):e);return n==="bytes"?s:qs(s)}const Vd=new wl(8192);function xl(e,t){if(Vd.has(`${e}.${t}`))return Vd.get(`${e}.${t}`);const n=t?`${t}${e.toLowerCase()}`:e.substring(2).toLowerCase(),s=Ct(go(n),"bytes"),r=(t?n.substring(`${t}0x`.length):n).split("");for(let i=0;i<40;i+=2)s[i>>1]>>4>=8&&r[i]&&(r[i]=r[i].toUpperCase()),(s[i>>1]&15)>=8&&r[i+1]&&(r[i+1]=r[i+1].toUpperCase());const o=`0x${r.join("")}`;return Vd.set(`${e}.${t}`,o),o}function Cn(e,t){if(!Hn(e,{strict:!1}))throw new Br({address:e});return xl(e,t)}const k8=/^0x[a-fA-F0-9]{40}$/,jd=new wl(8192);function Hn(e,t){const{strict:n=!0}=t??{},s=`${e}.${n}`;if(jd.has(s))return jd.get(s);const r=k8.test(e)?e.toLowerCase()===e?!0:n?xl(e)===e:!0:!1;return jd.set(s,r),r}function ju(e,t,n,{strict:s}={}){return ms(e,{strict:!1})?Fw(e,t,n,{strict:s}):Lw(e,t,n,{strict:s})}function Mw(e,t){if(typeof t=="number"&&t>0&&t>ut(e)-1)throw new _w({offset:t,position:"start",size:ut(e)})}function Ow(e,t,n){if(typeof t=="number"&&typeof n=="number"&&ut(e)!==n-t)throw new _w({offset:n,position:"end",size:ut(e)})}function Lw(e,t,n,{strict:s}={}){Mw(e,t);const r=e.slice(t,n);return s&&Ow(r,t,n),r}function Fw(e,t,n,{strict:s}={}){Mw(e,t);const r=`0x${e.replace("0x","").slice((t??0)*2,(n??e.length)*2)}`;return s&&Ow(r,t,n),r}function Ji(e,t){if(e.length!==t.length)throw new QA({expectedLength:e.length,givenLength:t.length});const n=I8({params:e,values:t}),s=Om(n);return s.length===0?"0x":s}function I8({params:e,values:t}){const n=[];for(let s=0;s<e.length;s++)n.push(Mm({param:e[s],value:t[s]}));return n}function Mm({param:e,value:t}){const n=Lm(e.type);if(n){const[s,r]=n;return $8(t,{length:s,param:{...e,type:r}})}if(e.type==="tuple")return N8(t,{param:e});if(e.type==="address")return R8(t);if(e.type==="bool")return O8(t);if(e.type.startsWith("uint")||e.type.startsWith("int")){const s=e.type.startsWith("int");return L8(t,{signed:s})}if(e.type.startsWith("bytes"))return M8(t,{param:e});if(e.type==="string")return F8(t);throw new t8(e.type,{docsPath:"/docs/contract/encodeAbiParameters"})}function Om(e){let t=0;for(let o=0;o<e.length;o++){const{dynamic:i,encoded:a}=e[o];i?t+=32:t+=ut(a)}const n=[],s=[];let r=0;for(let o=0;o<e.length;o++){const{dynamic:i,encoded:a}=e[o];i?(n.push(Ee(t+r,{size:32})),s.push(a),r+=ut(a)):n.push(a)}return Gs([...n,...s])}function R8(e){if(!Hn(e))throw new Br({address:e});return{dynamic:!1,encoded:kr(e.toLowerCase())}}function $8(e,{length:t,param:n}){const s=t===null;if(!Array.isArray(e))throw new s8(e);if(!s&&e.length!==t)throw new XA({expectedLength:t,givenLength:e.length,type:`${n.type}[${t}]`});let r=!1;const o=[];for(let i=0;i<e.length;i++){const a=Mm({param:n,value:e[i]});a.dynamic&&(r=!0),o.push(a)}if(s||r){const i=Om(o);if(s){const a=Ee(o.length,{size:32});return{dynamic:!0,encoded:o.length>0?Gs([a,i]):a}}if(r)return{dynamic:!0,encoded:i}}return{dynamic:!1,encoded:Gs(o.map(({encoded:i})=>i))}}function M8(e,{param:t}){const[,n]=t.type.split("bytes"),s=ut(e);if(!n){let r=e;return s%32!==0&&(r=kr(r,{dir:"right",size:Math.ceil((e.length-2)/2/32)*32})),{dynamic:!0,encoded:Gs([kr(Ee(s,{size:32})),r])}}if(s!==Number.parseInt(n))throw new KA({expectedSize:Number.parseInt(n),value:e});return{dynamic:!1,encoded:kr(e,{dir:"right"})}}function O8(e){if(typeof e!="boolean")throw new ue(`Invalid boolean value: "${e}" (type: ${typeof e}). Expected: \`true\` or \`false\`.`);return{dynamic:!1,encoded:kr(Aw(e))}}function L8(e,{signed:t}){return{dynamic:!1,encoded:Ee(e,{size:32,signed:t})}}function F8(e){const t=Ii(e),n=Math.ceil(ut(t)/32),s=[];for(let r=0;r<n;r++)s.push(kr(ju(t,r*32,(r+1)*32),{dir:"right"}));return{dynamic:!0,encoded:Gs([kr(Ee(ut(t),{size:32})),...s])}}function N8(e,{param:t}){let n=!1;const s=[];for(let r=0;r<t.components.length;r++){const o=t.components[r],i=Array.isArray(e)?r:o.name,a=Mm({param:o,value:e[i]});s.push(a),a.dynamic&&(n=!0)}return{dynamic:n,encoded:n?Om(s):Gs(s.map(({encoded:r})=>r))}}function Lm(e){const t=e.match(/^(.*)\[(\d+)?\]$/);return t?[t[2]?Number(t[2]):null,t[1]]:void 0}const Hd="/docs/contract/encodeDeployData";function Fm(e){const{abi:t,args:n,bytecode:s}=e;if(!n||n.length===0)return s;const r=t.find(i=>"type"in i&&i.type==="constructor");if(!r)throw new GA({docsPath:Hd});if(!("inputs"in r))throw new b0({docsPath:Hd});if(!r.inputs||r.inputs.length===0)throw new b0({docsPath:Hd});const o=Ji(r.inputs,n);return Tc([s,o])}function Xn(e){return typeof e=="string"?{address:e,type:"json-rpc"}:e}class Nw extends ue{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(`
`),{docsPath:t,docsSlug:"account",name:"AccountNotFoundError"})}}class zd extends ue{constructor({docsPath:t,metaMessages:n,type:s}){super(`Account type "${s}" is not supported.`,{docsPath:t,metaMessages:n,name:"AccountTypeNotSupportedError"})}}function B8(e){const t=Ct(`0x${e.substring(4)}`).substring(26);return xl(`0x${t}`)}const D8="modulepreload",U8=function(e){return"/"+e},A0={},$i=function(t,n,s){let r=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const i=document.querySelector("meta[property=csp-nonce]"),a=(i==null?void 0:i.nonce)||(i==null?void 0:i.getAttribute("nonce"));r=Promise.allSettled(n.map(c=>{if(c=U8(c),c in A0)return;A0[c]=!0;const u=c.endsWith(".css"),l=u?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${c}"]${l}`))return;const d=document.createElement("link");if(d.rel=u?"stylesheet":D8,u||(d.as="script"),d.crossOrigin="",d.href=c,a&&d.setAttribute("nonce",a),document.head.appendChild(d),u)return new Promise((f,p)=>{d.addEventListener("load",f),d.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${c}`)))})}))}function o(i){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=i,window.dispatchEvent(a),!a.defaultPrevented)throw i}return r.then(i=>{for(const a of i||[])a.status==="rejected"&&o(a.reason);return t().catch(o)})};async function V8({hash:e,signature:t}){const n=ms(e)?e:qs(e),{secp256k1:s}=await $i(async()=>{const{secp256k1:i}=await Promise.resolve().then(()=>HP);return{secp256k1:i}},void 0);return`0x${(()=>{if(typeof t=="object"&&"r"in t&&"s"in t){const{r:u,s:l,v:d,yParity:f}=t,p=Number(f??d),m=T0(p);return new s.Signature(Nr(u),Nr(l)).addRecoveryBit(m)}const i=ms(t)?t:qs(t),a=hs(`0x${i.slice(130)}`),c=T0(a);return s.Signature.fromCompact(i.substring(2,130)).addRecoveryBit(c)})().recoverPublicKey(n.substring(2)).toHex(!1)}`}function T0(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 Bw({hash:e,signature:t}){return B8(await V8({hash:e,signature:t}))}class E0 extends ue{constructor({offset:t}){super(`Offset \`${t}\` cannot be negative.`,{name:"NegativeOffsetError"})}}class Dw extends ue{constructor({length:t,position:n}){super(`Position \`${n}\` is out of bounds (\`0 < position < ${t}\`).`,{name:"PositionOutOfBoundsError"})}}class j8 extends ue{constructor({count:t,limit:n}){super(`Recursive read limit of \`${n}\` exceeded (recursive read count: \`${t}\`).`,{name:"RecursiveReadLimitExceededError"})}}const H8={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 j8({count:this.recursiveReadCount+1,limit:this.recursiveReadLimit})},assertPosition(e){if(e<0||e>this.bytes.length-1)throw new Dw({length:this.bytes.length,position:e})},decrementPosition(e){if(e<0)throw new E0({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 E0({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 Nm(e,{recursiveReadLimit:t=8192}={}){const n=Object.create(H8);return n.bytes=e,n.dataView=new DataView(e.buffer,e.byteOffset,e.byteLength),n.positionReadCount=new Map,n.recursiveReadLimit=t,n}function z8(e,t="hex"){const n=Uw(e),s=Nm(new Uint8Array(n.length));return n.encode(s),t==="hex"?wt(s.bytes):s.bytes}function Uw(e){return Array.isArray(e)?q8(e.map(t=>Uw(t))):W8(e)}function q8(e){const t=e.reduce((r,o)=>r+o.length,0),n=Vw(t);return{length:t<=55?1+t:1+n+t,encode(r){t<=55?r.pushByte(192+t):(r.pushByte(247+n),n===1?r.pushUint8(t):n===2?r.pushUint16(t):n===3?r.pushUint24(t):r.pushUint32(t));for(const{encode:o}of e)o(r)}}}function W8(e){const t=typeof e=="string"?Pn(e):e,n=Vw(t.length);return{length:t.length===1&&t[0]<128?1:t.length<=55?1+t.length:1+n+t.length,encode(r){t.length===1&&t[0]<128?r.pushBytes(t):t.length<=55?(r.pushByte(128+t.length),r.pushBytes(t)):(r.pushByte(183+n),n===1?r.pushUint8(t.length):n===2?r.pushUint16(t.length):n===3?r.pushUint24(t.length):r.pushUint32(t.length),r.pushBytes(t))}}}function Vw(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 ue("Length is too large.")}function G8(e){const{chainId:t,contractAddress:n,nonce:s,to:r}=e,o=Ct(Tc(["0x05",z8([t?Ee(t):"0x",n,s?Ee(s):"0x"])]));return r==="bytes"?Pn(o):o}async function jw(e){const{authorization:t,signature:n}=e;return Bw({hash:G8(t),signature:n??t})}class Nf extends ue{constructor({blockNumber:t,chain:n,contract:s}){super(`Chain "${n.name}" does not support contract "${s.name}".`,{metaMessages:["This could be due to any of the following:",...t&&s.blockCreated&&s.blockCreated>t?[`- The contract "${s.name}" was not deployed until block ${s.blockCreated} (current block ${t}).`]:[`- The chain does not have the contract "${s.name}" configured.`]],name:"ChainDoesNotSupportContract"})}}class X8 extends ue{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 K8 extends ue{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(`
`),{name:"ChainNotFoundError"})}}class Hw extends ue{constructor(){super("No chain was provided to the Client.",{name:"ClientChainNotConfiguredError"})}}function Q8({chain:e,currentChainId:t}){if(!e)throw new K8;if(t!==e.id)throw new X8({chain:e,currentChainId:t})}const Z8={gwei:9,wei:18},Y8={ether:-9,wei:9},J8={ether:-18,gwei:-9};function ea(e,t){let n=e.toString();const s=n.startsWith("-");s&&(n=n.slice(1)),n=n.padStart(t,"0");let[r,o]=[n.slice(0,n.length-t),n.slice(n.length-t)];return o=o.replace(/(0+)$/,""),`${s?"-":""}${r||"0"}${o?`.${o}`:""}`}function en(e,t="wei"){return ea(e,Y8[t])}class Jo extends ue{constructor({cause:t,message:n}={}){var r;const s=(r=n==null?void 0:n.replace("execution reverted: ",""))==null?void 0:r.replace("execution reverted","");super(`Execution reverted ${s?`with reason: ${s}`:"for an unknown reason"}.`,{cause:t,name:"ExecutionRevertedError"})}}Object.defineProperty(Jo,"code",{enumerable:!0,configurable:!0,writable:!0,value:3});Object.defineProperty(Jo,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted/});class Hu extends ue{constructor({cause:t,maxFeePerGas:n}={}){super(`The fee cap (\`maxFeePerGas\`${n?` = ${en(n)} gwei`:""}) cannot be higher than the maximum allowed value (2^256-1).`,{cause:t,name:"FeeCapTooHighError"})}}Object.defineProperty(Hu,"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 Bf extends ue{constructor({cause:t,maxFeePerGas:n}={}){super(`The fee cap (\`maxFeePerGas\`${n?` = ${en(n)}`:""} gwei) cannot be lower than the block base fee.`,{cause:t,name:"FeeCapTooLowError"})}}Object.defineProperty(Bf,"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 Df extends ue{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(Df,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/});class Uf extends ue{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(`
`),{cause:t,name:"NonceTooLowError"})}}Object.defineProperty(Uf,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too low|transaction already imported|already known/});class Vf extends ue{constructor({cause:t,nonce:n}={}){super(`Nonce provided for the transaction ${n?`(${n}) `:""}exceeds the maximum allowed nonce.`,{cause:t,name:"NonceMaxValueError"})}}Object.defineProperty(Vf,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce has max value/});class jf extends ue{constructor({cause:t}={}){super(["The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account."].join(`
`),{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(jf,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds|exceeds transaction sender account balance/});class Hf extends ue{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(Hf,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/});class zf extends ue{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(zf,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too low/});class qf extends ue{constructor({cause:t}){super("The transaction type is not supported for this chain.",{cause:t,name:"TransactionTypeNotSupportedError"})}}Object.defineProperty(qf,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/});class zu extends ue{constructor({cause:t,maxPriorityFeePerGas:n,maxFeePerGas:s}={}){super([`The provided tip (\`maxPriorityFeePerGas\`${n?` = ${en(n)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${s?` = ${en(s)} gwei`:""}).`].join(`
`),{cause:t,name:"TipAboveFeeCapError"})}}Object.defineProperty(zu,"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 Cl extends ue{constructor({cause:t}){super(`An error occurred while executing: ${t==null?void 0:t.shortMessage}`,{cause:t,name:"UnknownNodeError"})}}function Bm(e,t="wei"){return ea(e,Z8[t])}function Sc(e){const t=Object.entries(e).map(([s,r])=>r===void 0||r===!1?null:[s,r]).filter(Boolean),n=t.reduce((s,[r])=>Math.max(s,r.length),0);return t.map(([s,r])=>`  ${`${s}:`.padEnd(n+1)}  ${r}`).join(`
`)}class eT extends ue{constructor(){super(["Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.","Use `maxFeePerGas`/`maxPriorityFeePerGas` for EIP-1559 compatible networks, and `gasPrice` for others."].join(`
`),{name:"FeeConflictError"})}}class tT extends ue{constructor({transaction:t}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",Sc(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 nT extends ue{constructor(t,{account:n,docsPath:s,chain:r,data:o,gas:i,gasPrice:a,maxFeePerGas:c,maxPriorityFeePerGas:u,nonce:l,to:d,value:f}){var m;const p=Sc({chain:r&&`${r==null?void 0:r.name} (id: ${r==null?void 0:r.id})`,from:n==null?void 0:n.address,to:d,value:typeof f<"u"&&`${Bm(f)} ${((m=r==null?void 0:r.nativeCurrency)==null?void 0:m.symbol)||"ETH"}`,data:o,gas:i,gasPrice:typeof a<"u"&&`${en(a)} gwei`,maxFeePerGas:typeof c<"u"&&`${en(c)} gwei`,maxPriorityFeePerGas:typeof u<"u"&&`${en(u)} gwei`,nonce:l});super(t.shortMessage,{cause:t,docsPath:s,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Request Arguments:",p].filter(Boolean),name:"TransactionExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}class zw extends ue{constructor({blockHash:t,blockNumber:n,blockTag:s,hash:r,index:o}){let i="Transaction";s&&o!==void 0&&(i=`Transaction at block time "${s}" at index "${o}"`),t&&o!==void 0&&(i=`Transaction at block hash "${t}" at index "${o}"`),n&&o!==void 0&&(i=`Transaction at block number "${n}" at index "${o}"`),r&&(i=`Transaction with hash "${r}"`),super(`${i} could not be found.`,{name:"TransactionNotFoundError"})}}class qw extends ue{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 sT extends ue{constructor({hash:t}){super(`Timed out while waiting for transaction with hash "${t}" to be confirmed.`,{name:"WaitForTransactionReceiptTimeoutError"})}}const Bt=(e,t,n)=>JSON.stringify(e,(s,r)=>typeof r=="bigint"?r.toString():r,n),rT=e=>e,Dm=e=>e;class ka extends ue{constructor({body:t,cause:n,details:s,headers:r,status:o,url:i}){super("HTTP request failed.",{cause:n,details:s,metaMessages:[o&&`Status: ${o}`,`URL: ${Dm(i)}`,t&&`Request body: ${Bt(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=r,this.status=o,this.url=i}}class Ww extends ue{constructor({body:t,error:n,url:s}){super("RPC Request failed.",{cause:n,details:n.message,metaMessages:[`URL: ${Dm(s)}`,`Request body: ${Bt(t)}`],name:"RpcRequestError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.code=n.code}}class S0 extends ue{constructor({body:t,url:n}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${Dm(n)}`,`Request body: ${Bt(t)}`],name:"TimeoutError"})}}const oT=-1;class nn extends ue{constructor(t,{code:n,docsPath:s,metaMessages:r,name:o,shortMessage:i}){super(i,{cause:t,docsPath:s,metaMessages:r||(t==null?void 0:t.metaMessages),name:o||"RpcError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.name=o||t.name,this.code=t instanceof Ww?t.code:n??oT}}class ta extends nn{constructor(t,n){super(t,n),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=n.data}}class Ga extends nn{constructor(t){super(t,{code:Ga.code,name:"ParseRpcError",shortMessage:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."})}}Object.defineProperty(Ga,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32700});class Xa extends nn{constructor(t){super(t,{code:Xa.code,name:"InvalidRequestRpcError",shortMessage:"JSON is not a valid request object."})}}Object.defineProperty(Xa,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32600});class Ka extends nn{constructor(t,{method:n}={}){super(t,{code:Ka.code,name:"MethodNotFoundRpcError",shortMessage:`The method${n?` "${n}"`:""} does not exist / is not available.`})}}Object.defineProperty(Ka,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32601});class Qa extends nn{constructor(t){super(t,{code:Qa.code,name:"InvalidParamsRpcError",shortMessage:["Invalid parameters were provided to the RPC method.","Double check you have provided the correct parameters."].join(`
`)})}}Object.defineProperty(Qa,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32602});class To extends nn{constructor(t){super(t,{code:To.code,name:"InternalRpcError",shortMessage:"An internal error was received."})}}Object.defineProperty(To,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32603});class Eo extends nn{constructor(t){super(t,{code:Eo.code,name:"InvalidInputRpcError",shortMessage:["Missing or invalid parameters.","Double check you have provided the correct parameters."].join(`
`)})}}Object.defineProperty(Eo,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32e3});class Za extends nn{constructor(t){super(t,{code:Za.code,name:"ResourceNotFoundRpcError",shortMessage:"Requested resource not found."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceNotFoundRpcError"})}}Object.defineProperty(Za,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32001});class Ir extends nn{constructor(t){super(t,{code:Ir.code,name:"ResourceUnavailableRpcError",shortMessage:"Requested resource not available."})}}Object.defineProperty(Ir,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32002});class Mi extends nn{constructor(t){super(t,{code:Mi.code,name:"TransactionRejectedRpcError",shortMessage:"Transaction creation failed."})}}Object.defineProperty(Mi,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32003});class Ya extends nn{constructor(t,{method:n}={}){super(t,{code:Ya.code,name:"MethodNotSupportedRpcError",shortMessage:`Method${n?` "${n}"`:""} is not implemented.`})}}Object.defineProperty(Ya,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32004});class Oi extends nn{constructor(t){super(t,{code:Oi.code,name:"LimitExceededRpcError",shortMessage:"Request exceeds defined limit."})}}Object.defineProperty(Oi,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32005});class Ja extends nn{constructor(t){super(t,{code:Ja.code,name:"JsonRpcVersionUnsupportedError",shortMessage:"Version of JSON-RPC protocol is not supported."})}}Object.defineProperty(Ja,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32006});class ht extends ta{constructor(t){super(t,{code:ht.code,name:"UserRejectedRequestError",shortMessage:"User rejected the request."})}}Object.defineProperty(ht,"code",{enumerable:!0,configurable:!0,writable:!0,value:4001});class ec extends ta{constructor(t){super(t,{code:ec.code,name:"UnauthorizedProviderError",shortMessage:"The requested method and/or account has not been authorized by the user."})}}Object.defineProperty(ec,"code",{enumerable:!0,configurable:!0,writable:!0,value:4100});class tc extends ta{constructor(t,{method:n}={}){super(t,{code:tc.code,name:"UnsupportedProviderMethodError",shortMessage:`The Provider does not support the requested method${n?` " ${n}"`:""}.`})}}Object.defineProperty(tc,"code",{enumerable:!0,configurable:!0,writable:!0,value:4200});class So extends ta{constructor(t){super(t,{code:So.code,name:"ProviderDisconnectedError",shortMessage:"The Provider is disconnected from all chains."})}}Object.defineProperty(So,"code",{enumerable:!0,configurable:!0,writable:!0,value:4900});class Li extends ta{constructor(t){super(t,{code:Li.code,name:"ChainDisconnectedError",shortMessage:"The Provider is not connected to the requested chain."})}}Object.defineProperty(Li,"code",{enumerable:!0,configurable:!0,writable:!0,value:4901});class Dr extends ta{constructor(t){super(t,{code:Dr.code,name:"SwitchChainError",shortMessage:"An error occurred when attempting to switch chain."})}}Object.defineProperty(Dr,"code",{enumerable:!0,configurable:!0,writable:!0,value:4902});class iT extends nn{constructor(t){super(t,{name:"UnknownRpcError",shortMessage:"An unknown RPC error occurred."})}}function Um(e,t){const n=(e.details||"").toLowerCase(),s=e instanceof ue?e.walk(r=>(r==null?void 0:r.code)===Jo.code):e;return s instanceof ue?new Jo({cause:e,message:s.details}):Jo.nodeMessage.test(n)?new Jo({cause:e,message:e.details}):Hu.nodeMessage.test(n)?new Hu({cause:e,maxFeePerGas:t==null?void 0:t.maxFeePerGas}):Bf.nodeMessage.test(n)?new Bf({cause:e,maxFeePerGas:t==null?void 0:t.maxFeePerGas}):Df.nodeMessage.test(n)?new Df({cause:e,nonce:t==null?void 0:t.nonce}):Uf.nodeMessage.test(n)?new Uf({cause:e,nonce:t==null?void 0:t.nonce}):Vf.nodeMessage.test(n)?new Vf({cause:e,nonce:t==null?void 0:t.nonce}):jf.nodeMessage.test(n)?new jf({cause:e}):Hf.nodeMessage.test(n)?new Hf({cause:e,gas:t==null?void 0:t.gas}):zf.nodeMessage.test(n)?new zf({cause:e,gas:t==null?void 0:t.gas}):qf.nodeMessage.test(n)?new qf({cause:e}):zu.nodeMessage.test(n)?new zu({cause:e,maxFeePerGas:t==null?void 0:t.maxFeePerGas,maxPriorityFeePerGas:t==null?void 0:t.maxPriorityFeePerGas}):new Cl({cause:e})}function aT(e,{docsPath:t,...n}){const s=(()=>{const r=Um(e,n);return r instanceof Cl?e:r})();return new nT(s,{docsPath:t,...n})}function Vm(e,{format:t}){if(!t)return{};const n={};function s(o){const i=Object.keys(o);for(const a of i)a in e&&(n[a]=e[a]),o[a]&&typeof o[a]=="object"&&!Array.isArray(o[a])&&s(o[a])}const r=t(e||{});return s(r),n}const cT={legacy:"0x0",eip2930:"0x1",eip1559:"0x2",eip4844:"0x3",eip7702:"0x4"};function jm(e){const t={};return typeof e.authorizationList<"u"&&(t.authorizationList=uT(e.authorizationList)),typeof e.accessList<"u"&&(t.accessList=e.accessList),typeof e.blobVersionedHashes<"u"&&(t.blobVersionedHashes=e.blobVersionedHashes),typeof e.blobs<"u"&&(typeof e.blobs[0]!="string"?t.blobs=e.blobs.map(n=>wt(n)):t.blobs=e.blobs),typeof e.data<"u"&&(t.data=e.data),typeof e.from<"u"&&(t.from=e.from),typeof e.gas<"u"&&(t.gas=Ee(e.gas)),typeof e.gasPrice<"u"&&(t.gasPrice=Ee(e.gasPrice)),typeof e.maxFeePerBlobGas<"u"&&(t.maxFeePerBlobGas=Ee(e.maxFeePerBlobGas)),typeof e.maxFeePerGas<"u"&&(t.maxFeePerGas=Ee(e.maxFeePerGas)),typeof e.maxPriorityFeePerGas<"u"&&(t.maxPriorityFeePerGas=Ee(e.maxPriorityFeePerGas)),typeof e.nonce<"u"&&(t.nonce=Ee(e.nonce)),typeof e.to<"u"&&(t.to=e.to),typeof e.type<"u"&&(t.type=cT[e.type]),typeof e.value<"u"&&(t.value=Ee(e.value)),t}function uT(e){return e.map(t=>({address:t.contractAddress,r:t.r,s:t.s,chainId:Ee(t.chainId),nonce:Ee(t.nonce),...typeof t.yParity<"u"?{yParity:Ee(t.yParity)}:{},...typeof t.v<"u"&&typeof t.yParity>"u"?{v:Ee(t.v)}:{}}))}function xe(e,t,n){const s=e[t.name];if(typeof s=="function")return s;const r=e[n];return typeof r=="function"?r:o=>t(e,o)}const Hm=2n**256n-1n;function Al(e){const{account:t,gasPrice:n,maxFeePerGas:s,maxPriorityFeePerGas:r,to:o}=e,i=t?Xn(t):void 0;if(i&&!Hn(i.address))throw new Br({address:i.address});if(o&&!Hn(o))throw new Br({address:o});if(typeof n<"u"&&(typeof s<"u"||typeof r<"u"))throw new eT;if(s&&s>Hm)throw new Hu({maxFeePerGas:s});if(r&&s&&r>s)throw new zu({maxFeePerGas:s,maxPriorityFeePerGas:r})}async function zm(e){const t=await e.request({method:"eth_chainId"},{dedupe:!0});return hs(t)}class lT extends ue{constructor(){super("`baseFeeMultiplier` must be greater than 1.",{name:"BaseFeeScalarError"})}}class qm extends ue{constructor(){super("Chain does not support EIP-1559 fees.",{name:"Eip1559FeesNotSupportedError"})}}class dT extends ue{constructor({maxPriorityFeePerGas:t}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${en(t)} gwei).`,{name:"MaxFeePerGasTooLowError"})}}class Gw extends ue{constructor({blockHash:t,blockNumber:n}){let s="Block";t&&(s=`Block at hash "${t}"`),n&&(s=`Block at number "${n}"`),super(`${s} could not be found.`,{name:"BlockNotFoundError"})}}const Xw={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559","0x3":"eip4844","0x4":"eip7702"};function Kw(e){const t={...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,chainId:e.chainId?hs(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?hs(e.nonce):void 0,to:e.to?e.to:null,transactionIndex:e.transactionIndex?Number(e.transactionIndex):null,type:e.type?Xw[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&&(t.authorizationList=fT(e.authorizationList)),t.yParity=(()=>{if(e.yParity)return Number(e.yParity);if(typeof t.v=="bigint"){if(t.v===0n||t.v===27n)return 0;if(t.v===1n||t.v===28n)return 1;if(t.v>=35n)return t.v%2n===0n?1:0}})(),t.type==="legacy"&&(delete t.accessList,delete t.maxFeePerBlobGas,delete t.maxFeePerGas,delete t.maxPriorityFeePerGas,delete t.yParity),t.type==="eip2930"&&(delete t.maxFeePerBlobGas,delete t.maxFeePerGas,delete t.maxPriorityFeePerGas),t.type==="eip1559"&&delete t.maxFeePerBlobGas,t}function fT(e){return e.map(t=>({contractAddress:t.address,chainId:Number(t.chainId),nonce:Number(t.nonce),r:t.r,s:t.s,yParity:Number(t.yParity)}))}function Qw(e){var n;const t=(n=e.transactions)==null?void 0:n.map(s=>typeof s=="string"?s:Kw(s));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:t,totalDifficulty:e.totalDifficulty?BigInt(e.totalDifficulty):null}}async function Us(e,{blockHash:t,blockNumber:n,blockTag:s,includeTransactions:r}={}){var l,d,f;const o=s??"latest",i=r??!1,a=n!==void 0?Ee(n):void 0;let c=null;if(t?c=await e.request({method:"eth_getBlockByHash",params:[t,i]},{dedupe:!0}):c=await e.request({method:"eth_getBlockByNumber",params:[a||o,i]},{dedupe:!!a}),!c)throw new Gw({blockHash:t,blockNumber:n});return(((f=(d=(l=e.chain)==null?void 0:l.formatters)==null?void 0:d.block)==null?void 0:f.format)||Qw)(c)}async function Wm(e){const t=await e.request({method:"eth_gasPrice"});return BigInt(t)}async function pT(e,t){return Zw(e,t)}async function Zw(e,t){var o,i;const{block:n,chain:s=e.chain,request:r}=t||{};try{const a=((o=s==null?void 0:s.fees)==null?void 0:o.maxPriorityFeePerGas)??((i=s==null?void 0:s.fees)==null?void 0:i.defaultPriorityFee);if(typeof a=="function"){const u=n||await xe(e,Us,"getBlock")({}),l=await a({block:u,client:e,request:r});if(l===null)throw new Error;return l}if(typeof a<"u")return a;const c=await e.request({method:"eth_maxPriorityFeePerGas"});return Nr(c)}catch{const[a,c]=await Promise.all([n?Promise.resolve(n):xe(e,Us,"getBlock")({}),xe(e,Wm,"getGasPrice")({})]);if(typeof a.baseFeePerGas!="bigint")throw new qm;const u=c-a.baseFeePerGas;return u<0n?0n:u}}async function mT(e,t){return Wf(e,t)}async function Wf(e,t){var f,p;const{block:n,chain:s=e.chain,request:r,type:o="eip1559"}=t||{},i=await(async()=>{var m,h;return typeof((m=s==null?void 0:s.fees)==null?void 0:m.baseFeeMultiplier)=="function"?s.fees.baseFeeMultiplier({block:n,client:e,request:r}):((h=s==null?void 0:s.fees)==null?void 0:h.baseFeeMultiplier)??1.2})();if(i<1)throw new lT;const c=10**(((f=i.toString().split(".")[1])==null?void 0:f.length)??0),u=m=>m*BigInt(Math.ceil(i*c))/BigInt(c),l=n||await xe(e,Us,"getBlock")({});if(typeof((p=s==null?void 0:s.fees)==null?void 0:p.estimateFeesPerGas)=="function"){const m=await s.fees.estimateFeesPerGas({block:n,client:e,multiply:u,request:r,type:o});if(m!==null)return m}if(o==="eip1559"){if(typeof l.baseFeePerGas!="bigint")throw new qm;const m=typeof(r==null?void 0:r.maxPriorityFeePerGas)=="bigint"?r.maxPriorityFeePerGas:await Zw(e,{block:l,chain:s,request:r}),h=u(l.baseFeePerGas);return{maxFeePerGas:(r==null?void 0:r.maxFeePerGas)??h+m,maxPriorityFeePerGas:m}}return{gasPrice:(r==null?void 0:r.gasPrice)??u(await xe(e,Wm,"getGasPrice")({}))}}class hT extends ue{constructor(t,{account:n,docsPath:s,chain:r,data:o,gas:i,gasPrice:a,maxFeePerGas:c,maxPriorityFeePerGas:u,nonce:l,to:d,value:f}){var m;const p=Sc({from:n==null?void 0:n.address,to:d,value:typeof f<"u"&&`${Bm(f)} ${((m=r==null?void 0:r.nativeCurrency)==null?void 0:m.symbol)||"ETH"}`,data:o,gas:i,gasPrice:typeof a<"u"&&`${en(a)} gwei`,maxFeePerGas:typeof c<"u"&&`${en(c)} gwei`,maxPriorityFeePerGas:typeof u<"u"&&`${en(u)} gwei`,nonce:l});super(t.shortMessage,{cause:t,docsPath:s,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Estimate Gas Arguments:",p].filter(Boolean),name:"EstimateGasExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}function yT(e,{docsPath:t,...n}){const s=(()=>{const r=Um(e,n);return r instanceof Cl?e:r})();return new hT(s,{docsPath:t,...n})}class bT extends ue{constructor({address:t}){super(`State for account "${t}" is set multiple times.`,{name:"AccountStateConflictError"})}}class gT extends ue{constructor(){super("state and stateDiff are set on the same account.",{name:"StateAssignmentConflictError"})}}function P0(e){return e.reduce((t,{slot:n,value:s})=>`${t}        ${n}: ${s}
`,"")}function vT(e){return e.reduce((t,{address:n,...s})=>{let r=`${t}    ${n}:
`;return s.nonce&&(r+=`      nonce: ${s.nonce}
`),s.balance&&(r+=`      balance: ${s.balance}
`),s.code&&(r+=`      code: ${s.code}
`),s.state&&(r+=`      state:
`,r+=P0(s.state)),s.stateDiff&&(r+=`      stateDiff:
`,r+=P0(s.stateDiff)),r},`  State Override:
`).slice(0,-1)}function k0(e){if(!(!e||e.length===0))return e.reduce((t,{slot:n,value:s})=>{if(n.length!==66)throw new h0({size:n.length,targetSize:66,type:"hex"});if(s.length!==66)throw new h0({size:s.length,targetSize:66,type:"hex"});return t[n]=s,t},{})}function wT(e){const{balance:t,nonce:n,state:s,stateDiff:r,code:o}=e,i={};if(o!==void 0&&(i.code=o),t!==void 0&&(i.balance=Ee(t)),n!==void 0&&(i.nonce=Ee(n)),s!==void 0&&(i.state=k0(s)),r!==void 0){if(i.state)throw new gT;i.stateDiff=k0(r)}return i}function Yw(e){if(!e)return;const t={};for(const{address:n,...s}of e){if(!Hn(n,{strict:!1}))throw new Br({address:n});if(t[n])throw new bT({address:n});t[n]=wT(s)}return t}async function Gm(e,{address:t,blockNumber:n,blockTag:s="latest"}){const r=n?Ee(n):void 0,o=await e.request({method:"eth_getBalance",params:[t,r||s]});return BigInt(o)}async function Xm(e,t){var r,o,i;const{account:n=e.account}=t,s=n?Xn(n):void 0;try{let z=function(ne){const{block:te,request:ce,rpcStateOverride:he}=ne;return e.request({method:"eth_estimateGas",params:he?[ce,te??"latest",he]:te?[ce,te]:[ce]})};const{accessList:a,authorizationList:c,blobs:u,blobVersionedHashes:l,blockNumber:d,blockTag:f,data:p,gas:m,gasPrice:h,maxFeePerBlobGas:y,maxFeePerGas:b,maxPriorityFeePerGas:g,nonce:w,value:_,stateOverride:A,...x}=await Qm(e,{...t,parameters:(s==null?void 0:s.type)==="local"?void 0:["blobVersionedHashes"]}),k=(d?Ee(d):void 0)||f,S=Yw(A),R=await(async()=>{if(x.to)return x.to;if(c&&c.length>0)return await jw({authorization:c[0]}).catch(()=>{throw new ue("`to` is required. Could not infer from `authorizationList`")})})();Al(t);const B=(i=(o=(r=e.chain)==null?void 0:r.formatters)==null?void 0:o.transactionRequest)==null?void 0:i.format,X=(B||jm)({...Vm(x,{format:B}),from:s==null?void 0:s.address,accessList:a,authorizationList:c,blobs:u,blobVersionedHashes:l,data:p,gas:m,gasPrice:h,maxFeePerBlobGas:y,maxFeePerGas:b,maxPriorityFeePerGas:g,nonce:w,to:R,value:_});let ie=BigInt(await z({block:k,request:X,rpcStateOverride:S}));if(c){const ne=await Gm(e,{address:X.from}),te=await Promise.all(c.map(async ce=>{const{contractAddress:he}=ce,_e=await z({block:k,request:{authorizationList:void 0,data:p,from:s==null?void 0:s.address,to:he,value:Ee(ne)},rpcStateOverride:S}).catch(()=>100000n);return 2n*BigInt(_e)}));ie+=te.reduce((ce,he)=>ce+he,0n)}return ie}catch(a){throw yT(a,{...t,account:s,chain:e.chain})}}async function Jw(e,{address:t,blockTag:n="latest",blockNumber:s}){const r=await e.request({method:"eth_getTransactionCount",params:[t,s?Ee(s):n]},{dedupe:!!s});return hs(r)}function e2(e){const{kzg:t}=e,n=e.to??(typeof e.blobs[0]=="string"?"hex":"bytes"),s=typeof e.blobs[0]=="string"?e.blobs.map(o=>Pn(o)):e.blobs,r=[];for(const o of s)r.push(Uint8Array.from(t.blobToKzgCommitment(o)));return n==="bytes"?r:r.map(o=>wt(o))}function t2(e){const{kzg:t}=e,n=e.to??(typeof e.blobs[0]=="string"?"hex":"bytes"),s=typeof e.blobs[0]=="string"?e.blobs.map(i=>Pn(i)):e.blobs,r=typeof e.commitments[0]=="string"?e.commitments.map(i=>Pn(i)):e.commitments,o=[];for(let i=0;i<s.length;i++){const a=s[i],c=r[i];o.push(Uint8Array.from(t.computeBlobKzgProof(a,c)))}return n==="bytes"?o:o.map(i=>wt(i))}function _T(e,t,n,s){if(typeof e.setBigUint64=="function")return e.setBigUint64(t,n,s);const r=BigInt(32),o=BigInt(4294967295),i=Number(n>>r&o),a=Number(n&o),c=s?4:0,u=s?0:4;e.setUint32(t+c,i,s),e.setUint32(t+u,a,s)}const xT=(e,t,n)=>e&t^~e&n,CT=(e,t,n)=>e&t^e&n^t&n;class AT extends Rm{constructor(t,n,s,r){super(),this.blockLen=t,this.outputLen=n,this.padOffset=s,this.isLE=r,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(t),this.view=Ud(this.buffer)}update(t){Ri(this);const{view:n,buffer:s,blockLen:r}=this;t=_l(t);const o=t.length;for(let i=0;i<o;){const a=Math.min(r-this.pos,o-i);if(a===r){const c=Ud(t);for(;r<=o-i;i+=r)this.process(c,i);continue}s.set(t.subarray(i,i+a),this.pos),this.pos+=a,i+=a,this.pos===r&&(this.process(n,0),this.pos=0)}return this.length+=t.length,this.roundClean(),this}digestInto(t){Ri(this),Pw(t,this),this.finished=!0;const{buffer:n,view:s,blockLen:r,isLE:o}=this;let{pos:i}=this;n[i++]=128,this.buffer.subarray(i).fill(0),this.padOffset>r-i&&(this.process(s,0),i=0);for(let d=i;d<r;d++)n[d]=0;_T(s,r-8,BigInt(this.length*8),o),this.process(s,0);const a=Ud(t),c=this.outputLen;if(c%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const u=c/4,l=this.get();if(u>l.length)throw new Error("_sha2: outputLen bigger than state");for(let d=0;d<u;d++)a.setUint32(4*d,l[d],o)}digest(){const{buffer:t,outputLen:n}=this;this.digestInto(t);const s=t.slice(0,n);return this.destroy(),s}_cloneInto(t){t||(t=new this.constructor),t.set(...this.get());const{blockLen:n,buffer:s,length:r,finished:o,destroyed:i,pos:a}=this;return t.length=r,t.pos=a,t.finished=o,t.destroyed=i,r%n&&t.buffer.set(s),t}}const TT=new Uint32Array([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]),ar=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),cr=new Uint32Array(64);class ET extends AT{constructor(){super(64,32,8,!1),this.A=ar[0]|0,this.B=ar[1]|0,this.C=ar[2]|0,this.D=ar[3]|0,this.E=ar[4]|0,this.F=ar[5]|0,this.G=ar[6]|0,this.H=ar[7]|0}get(){const{A:t,B:n,C:s,D:r,E:o,F:i,G:a,H:c}=this;return[t,n,s,r,o,i,a,c]}set(t,n,s,r,o,i,a,c){this.A=t|0,this.B=n|0,this.C=s|0,this.D=r|0,this.E=o|0,this.F=i|0,this.G=a|0,this.H=c|0}process(t,n){for(let d=0;d<16;d++,n+=4)cr[d]=t.getUint32(n,!1);for(let d=16;d<64;d++){const f=cr[d-15],p=cr[d-2],m=Yn(f,7)^Yn(f,18)^f>>>3,h=Yn(p,17)^Yn(p,19)^p>>>10;cr[d]=h+cr[d-7]+m+cr[d-16]|0}let{A:s,B:r,C:o,D:i,E:a,F:c,G:u,H:l}=this;for(let d=0;d<64;d++){const f=Yn(a,6)^Yn(a,11)^Yn(a,25),p=l+f+xT(a,c,u)+TT[d]+cr[d]|0,h=(Yn(s,2)^Yn(s,13)^Yn(s,22))+CT(s,r,o)|0;l=u,u=c,c=a,a=i+p|0,i=o,o=r,r=s,s=p+h|0}s=s+this.A|0,r=r+this.B|0,o=o+this.C|0,i=i+this.D|0,a=a+this.E|0,c=c+this.F|0,u=u+this.G|0,l=l+this.H|0,this.set(s,r,o,i,a,c,u,l)}roundClean(){cr.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}const n2=kw(()=>new ET);function ST(e,t){return n2(ms(e,{strict:!1})?Yi(e):e)}function PT(e){const{commitment:t,version:n=1}=e,s=e.to??(typeof t=="string"?"hex":"bytes"),r=ST(t);return r.set([n],0),s==="bytes"?r:wt(r)}function kT(e){const{commitments:t,version:n}=e,s=e.to??(typeof t[0]=="string"?"hex":"bytes"),r=[];for(const o of t)r.push(PT({commitment:o,to:s,version:n}));return r}const I0=6,s2=32,Km=4096,r2=s2*Km,R0=r2*I0-1-1*Km*I0;class IT extends ue{constructor({maxSize:t,size:n}){super("Blob size is too large.",{metaMessages:[`Max: ${t} bytes`,`Given: ${n} bytes`],name:"BlobSizeTooLargeError"})}}class RT extends ue{constructor(){super("Blob data must not be empty.",{name:"EmptyBlobError"})}}function $T(e){const t=e.to??(typeof e.data=="string"?"hex":"bytes"),n=typeof e.data=="string"?Pn(e.data):e.data,s=ut(n);if(!s)throw new RT;if(s>R0)throw new IT({maxSize:R0,size:s});const r=[];let o=!0,i=0;for(;o;){const a=Nm(new Uint8Array(r2));let c=0;for(;c<Km;){const u=n.slice(i,i+(s2-1));if(a.pushByte(0),a.pushBytes(u),u.length<31){a.pushByte(128),o=!1;break}c++,i+=31}r.push(a)}return t==="bytes"?r.map(a=>a.bytes):r.map(a=>wt(a.bytes))}function MT(e){const{data:t,kzg:n,to:s}=e,r=e.blobs??$T({data:t,to:s}),o=e.commitments??e2({blobs:r,kzg:n,to:s}),i=e.proofs??t2({blobs:r,commitments:o,kzg:n,to:s}),a=[];for(let c=0;c<r.length;c++)a.push({blob:r[c],commitment:o[c],proof:i[c]});return a}function OT(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 tT({transaction:e})}const o2=["blobVersionedHashes","chainId","fees","gas","nonce","type"];async function Qm(e,t){const{account:n=e.account,blobs:s,chain:r,gas:o,kzg:i,nonce:a,nonceManager:c,parameters:u=o2,type:l}=t,d=n&&Xn(n),f={...t,...d?{from:d==null?void 0:d.address}:{}};let p;async function m(){return p||(p=await xe(e,Us,"getBlock")({blockTag:"latest"}),p)}let h;async function y(){return h||(r?r.id:typeof t.chainId<"u"?t.chainId:(h=await xe(e,zm,"getChainId")({}),h))}if((u.includes("blobVersionedHashes")||u.includes("sidecars"))&&s&&i){const b=e2({blobs:s,kzg:i});if(u.includes("blobVersionedHashes")){const g=kT({commitments:b,to:"hex"});f.blobVersionedHashes=g}if(u.includes("sidecars")){const g=t2({blobs:s,commitments:b,kzg:i}),w=MT({blobs:s,commitments:b,proofs:g,to:"hex"});f.sidecars=w}}if(u.includes("chainId")&&(f.chainId=await y()),u.includes("nonce")&&typeof a>"u"&&d)if(c){const b=await y();f.nonce=await c.consume({address:d.address,chainId:b,client:e})}else f.nonce=await xe(e,Jw,"getTransactionCount")({address:d.address,blockTag:"pending"});if((u.includes("fees")||u.includes("type"))&&typeof l>"u")try{f.type=OT(f)}catch{const b=await m();f.type=typeof(b==null?void 0:b.baseFeePerGas)=="bigint"?"eip1559":"legacy"}if(u.includes("fees"))if(f.type!=="legacy"&&f.type!=="eip2930"){if(typeof f.maxFeePerGas>"u"||typeof f.maxPriorityFeePerGas>"u"){const b=await m(),{maxFeePerGas:g,maxPriorityFeePerGas:w}=await Wf(e,{block:b,chain:r,request:f});if(typeof t.maxPriorityFeePerGas>"u"&&t.maxFeePerGas&&t.maxFeePerGas<w)throw new dT({maxPriorityFeePerGas:w});f.maxPriorityFeePerGas=w,f.maxFeePerGas=g}}else{if(typeof t.maxFeePerGas<"u"||typeof t.maxPriorityFeePerGas<"u")throw new qm;const b=await m(),{gasPrice:g}=await Wf(e,{block:b,chain:r,request:f,type:"legacy"});f.gasPrice=g}return u.includes("gas")&&typeof o>"u"&&(f.gas=await xe(e,Xm,"estimateGas")({...f,account:d&&{address:d.address,type:"json-rpc"}})),Al(f),delete f.parameters,f}async function i2(e,{serializedTransaction:t}){return e.request({method:"eth_sendRawTransaction",params:[t]},{retryCount:0})}const $0=new wl(128);async function LT(e,t){var b,g,w,_;const{account:n=e.account,chain:s=e.chain,accessList:r,authorizationList:o,blobs:i,data:a,gas:c,gasPrice:u,maxFeePerBlobGas:l,maxFeePerGas:d,maxPriorityFeePerGas:f,nonce:p,value:m,...h}=t;if(typeof n>"u")throw new Nw({docsPath:"/docs/actions/wallet/sendTransaction"});const y=n?Xn(n):null;try{Al(t);const A=await(async()=>{if(t.to)return t.to;if(o&&o.length>0)return await jw({authorization:o[0]}).catch(()=>{throw new ue("`to` is required. Could not infer from `authorizationList`.")})})();if((y==null?void 0:y.type)==="json-rpc"||y===null){let x;s!==null&&(x=await xe(e,zm,"getChainId")({}),Q8({currentChainId:x,chain:s}));const C=(w=(g=(b=e.chain)==null?void 0:b.formatters)==null?void 0:g.transactionRequest)==null?void 0:w.format,S=(C||jm)({...Vm(h,{format:C}),accessList:r,authorizationList:o,blobs:i,chainId:x,data:a,from:y==null?void 0:y.address,gas:c,gasPrice:u,maxFeePerBlobGas:l,maxFeePerGas:d,maxPriorityFeePerGas:f,nonce:p,to:A,value:m}),R=$0.get(e.uid)?"wallet_sendTransaction":"eth_sendTransaction";try{return await e.request({method:R,params:[S]},{retryCount:0})}catch(B){const L=B;if(L.name==="InvalidInputRpcError"||L.name==="InvalidParamsRpcError"||L.name==="MethodNotFoundRpcError"||L.name==="MethodNotSupportedRpcError")return await e.request({method:"wallet_sendTransaction",params:[S]},{retryCount:0}).then(X=>($0.set(e.uid,!0),X));throw L}}if((y==null?void 0:y.type)==="local"){const x=await xe(e,Qm,"prepareTransactionRequest")({account:y,accessList:r,authorizationList:o,blobs:i,chain:s,data:a,gas:c,gasPrice:u,maxFeePerBlobGas:l,maxFeePerGas:d,maxPriorityFeePerGas:f,nonce:p,nonceManager:y.nonceManager,parameters:[...o2,"sidecars"],value:m,...h,to:A}),C=(_=s==null?void 0:s.serializers)==null?void 0:_.transaction,k=await y.signTransaction(x,{serializer:C});return await xe(e,i2,"sendRawTransaction")({serializedTransaction:k})}throw(y==null?void 0:y.type)==="smart"?new zd({metaMessages:["Consider using the `sendUserOperation` Action instead."],docsPath:"/docs/actions/bundler/sendUserOperation",type:"smart"}):new zd({docsPath:"/docs/actions/wallet/sendTransaction",type:y==null?void 0:y.type})}catch(A){throw A instanceof zd?A:aT(A,{...t,account:y,chain:t.chain||void 0})}}const Gf=[{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"}],a2=[{inputs:[],name:"ResolverNotFound",type:"error"},{inputs:[],name:"ResolverWildcardNotSupported",type:"error"},{inputs:[],name:"ResolverNotContract",type:"error"},{inputs:[{name:"returnData",type:"bytes"}],name:"ResolverError",type:"error"},{inputs:[{components:[{name:"status",type:"uint16"},{name:"message",type:"string"}],name:"errors",type:"tuple[]"}],name:"HttpError",type:"error"}],c2=[...a2,{name:"resolve",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]},{name:"resolve",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"}]}],FT=[...a2,{name:"reverse",type:"function",stateMutability:"view",inputs:[{type:"bytes",name:"reverseName"}],outputs:[{type:"string",name:"resolvedName"},{type:"address",name:"resolvedAddress"},{type:"address",name:"reverseResolver"},{type:"address",name:"resolver"}]},{name:"reverse",type:"function",stateMutability:"view",inputs:[{type:"bytes",name:"reverseName"},{type:"string[]",name:"gateways"}],outputs:[{type:"string",name:"resolvedName"},{type:"address",name:"resolvedAddress"},{type:"address",name:"reverseResolver"},{type:"address",name:"resolver"}]}],M0=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],O0=[{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"}]}],L0=[{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"}],dn=[{type:"event",name:"Approval",inputs:[{indexed:!0,name:"owner",type:"address"},{indexed:!0,name:"spender",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"event",name:"Transfer",inputs:[{indexed:!0,name:"from",type:"address"},{indexed:!0,name:"to",type:"address"},{indexed:!1,name:"value",type:"uint256"}]},{type:"function",name:"allowance",stateMutability:"view",inputs:[{name:"owner",type:"address"},{name:"spender",type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"approve",stateMutability:"nonpayable",inputs:[{name:"spender",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]},{type:"function",name:"balanceOf",stateMutability:"view",inputs:[{name:"account",type:"address"}],outputs:[{type:"uint256"}]},{type:"function",name:"decimals",stateMutability:"view",inputs:[],outputs:[{type:"uint8"}]},{type:"function",name:"name",stateMutability:"view",inputs:[],outputs:[{type:"string"}]},{type:"function",name:"symbol",stateMutability:"view",inputs:[],outputs:[{type:"string"}]},{type:"function",name:"totalSupply",stateMutability:"view",inputs:[],outputs:[{type:"uint256"}]},{type:"function",name:"transfer",stateMutability:"nonpayable",inputs:[{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]},{type:"function",name:"transferFrom",stateMutability:"nonpayable",inputs:[{name:"sender",type:"address"},{name:"recipient",type:"address"},{name:"amount",type:"uint256"}],outputs:[{type:"bool"}]}];function NT(e,t={}){typeof t.size<"u"&&kn(e,{size:t.size});const n=wt(e,t);return Nr(n,t)}function BT(e,t={}){let n=e;if(typeof t.size<"u"&&(kn(n,{size:t.size}),n=Ds(n)),n.length>1||n[0]>1)throw new FA(n);return!!n[0]}function Vs(e,t={}){typeof t.size<"u"&&kn(e,{size:t.size});const n=wt(e,t);return hs(n,t)}function DT(e,t={}){let n=e;return typeof t.size<"u"&&(kn(n,{size:t.size}),n=Ds(n,{dir:"right"})),new TextDecoder().decode(n)}function Tl(e,t){const n=typeof t=="string"?Pn(t):t,s=Nm(n);if(ut(n)===0&&e.length>0)throw new gl;if(ut(t)&&ut(t)<32)throw new Tw({data:typeof t=="string"?t:wt(t),params:e,size:ut(t)});let r=0;const o=[];for(let i=0;i<e.length;++i){const a=e[i];s.setPosition(r);const[c,u]=ii(s,a,{staticPosition:0});r+=u,o.push(c)}return o}function ii(e,t,{staticPosition:n}){const s=Lm(t.type);if(s){const[r,o]=s;return VT(e,{...t,type:o},{length:r,staticPosition:n})}if(t.type==="tuple")return qT(e,t,{staticPosition:n});if(t.type==="address")return UT(e);if(t.type==="bool")return jT(e);if(t.type.startsWith("bytes"))return HT(e,t,{staticPosition:n});if(t.type.startsWith("uint")||t.type.startsWith("int"))return zT(e,t);if(t.type==="string")return WT(e,{staticPosition:n});throw new n8(t.type,{docsPath:"/docs/contract/decodeAbiParameters"})}const F0=32,Xf=32;function UT(e){const t=e.readBytes(32);return[xl(wt(Lw(t,-20))),32]}function VT(e,t,{length:n,staticPosition:s}){if(!n){const i=Vs(e.readBytes(Xf)),a=s+i,c=a+F0;e.setPosition(a);const u=Vs(e.readBytes(F0)),l=nc(t);let d=0;const f=[];for(let p=0;p<u;++p){e.setPosition(c+(l?p*32:d));const[m,h]=ii(e,t,{staticPosition:c});d+=h,f.push(m)}return e.setPosition(s+32),[f,32]}if(nc(t)){const i=Vs(e.readBytes(Xf)),a=s+i,c=[];for(let u=0;u<n;++u){e.setPosition(a+u*32);const[l]=ii(e,t,{staticPosition:a});c.push(l)}return e.setPosition(s+32),[c,32]}let r=0;const o=[];for(let i=0;i<n;++i){const[a,c]=ii(e,t,{staticPosition:s+r});r+=c,o.push(a)}return[o,r]}function jT(e){return[BT(e.readBytes(32),{size:32}),32]}function HT(e,t,{staticPosition:n}){const[s,r]=t.type.split("bytes");if(!r){const i=Vs(e.readBytes(32));e.setPosition(n+i);const a=Vs(e.readBytes(32));if(a===0)return e.setPosition(n+32),["0x",32];const c=e.readBytes(a);return e.setPosition(n+32),[wt(c),32]}return[wt(e.readBytes(Number.parseInt(r),32)),32]}function zT(e,t){const n=t.type.startsWith("int"),s=Number.parseInt(t.type.split("int")[1]||"256"),r=e.readBytes(32);return[s>48?NT(r,{signed:n}):Vs(r,{signed:n}),32]}function qT(e,t,{staticPosition:n}){const s=t.components.length===0||t.components.some(({name:i})=>!i),r=s?[]:{};let o=0;if(nc(t)){const i=Vs(e.readBytes(Xf)),a=n+i;for(let c=0;c<t.components.length;++c){const u=t.components[c];e.setPosition(a+o);const[l,d]=ii(e,u,{staticPosition:a});o+=d,r[s?c:u==null?void 0:u.name]=l}return e.setPosition(n+32),[r,32]}for(let i=0;i<t.components.length;++i){const a=t.components[i],[c,u]=ii(e,a,{staticPosition:n});r[s?i:a==null?void 0:a.name]=c,o+=u}return[r,o]}function WT(e,{staticPosition:t}){const n=Vs(e.readBytes(32)),s=t+n;e.setPosition(s);const r=Vs(e.readBytes(32));if(r===0)return e.setPosition(t+32),["",32];const o=e.readBytes(r,32),i=DT(Ds(o));return e.setPosition(t+32),[i,32]}function nc(e){var s;const{type:t}=e;if(t==="string"||t==="bytes"||t.endsWith("[]"))return!0;if(t==="tuple")return(s=e.components)==null?void 0:s.some(nc);const n=Lm(e.type);return!!(n&&nc({...e,type:n[1]}))}const GT=e=>Ct(Yi(e));function XT(e){return GT(e)}const KT="1.0.6";let In=class Kf extends Error{constructor(t,n={}){var i;const s=n.cause instanceof Kf?n.cause.details:(i=n.cause)!=null&&i.message?n.cause.message:n.details,r=n.cause instanceof Kf&&n.cause.docsPath||n.docsPath,o=[t||"An error occurred.","",...n.metaMessages?[...n.metaMessages,""]:[],...r?[`Docs: https://abitype.dev${r}`]:[],...s?[`Details: ${s}`]:[],`Version: abitype@${KT}`].join(`
`);super(o),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=s,this.docsPath=r,this.metaMessages=n.metaMessages,this.shortMessage=t}};function Yr(e,t){const n=e.exec(t);return n==null?void 0:n.groups}const u2=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,l2=/^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)?$/,d2=/^\(.+?\).*?$/,N0=/^tuple(?<array>(\[(\d*)\])*)$/;function Qf(e){let t=e.type;if(N0.test(e.type)&&"components"in e){t="(";const n=e.components.length;for(let r=0;r<n;r++){const o=e.components[r];t+=Qf(o),r<n-1&&(t+=", ")}const s=Yr(N0,e.type);return t+=`)${(s==null?void 0:s.array)??""}`,Qf({...e,type:t})}return"indexed"in e&&e.indexed&&(t=`${t} indexed`),e.name?`${t} ${e.name}`:t}function ya(e){let t="";const n=e.length;for(let s=0;s<n;s++){const r=e[s];t+=Qf(r),s!==n-1&&(t+=", ")}return t}function QT(e){return e.type==="function"?`function ${e.name}(${ya(e.inputs)})${e.stateMutability&&e.stateMutability!=="nonpayable"?` ${e.stateMutability}`:""}${e.outputs.length?` returns (${ya(e.outputs)})`:""}`:e.type==="event"?`event ${e.name}(${ya(e.inputs)})`:e.type==="error"?`error ${e.name}(${ya(e.inputs)})`:e.type==="constructor"?`constructor(${ya(e.inputs)})${e.stateMutability==="payable"?" payable":""}`:e.type==="fallback"?"fallback()":"receive() external payable"}const f2=/^error (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;function ZT(e){return f2.test(e)}function YT(e){return Yr(f2,e)}const p2=/^event (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;function JT(e){return p2.test(e)}function eE(e){return Yr(p2,e)}const m2=/^function (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)(?: (?<scope>external|public{1}))?(?: (?<stateMutability>pure|view|nonpayable|payable{1}))?(?: returns\s?\((?<returns>.*?)\))?$/;function tE(e){return m2.test(e)}function nE(e){return Yr(m2,e)}const h2=/^struct (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*) \{(?<properties>.*?)\}$/;function y2(e){return h2.test(e)}function sE(e){return Yr(h2,e)}const b2=/^constructor\((?<parameters>.*?)\)(?:\s(?<stateMutability>payable{1}))?$/;function rE(e){return b2.test(e)}function oE(e){return Yr(b2,e)}const iE=/^fallback\(\) external(?:\s(?<stateMutability>payable{1}))?$/;function aE(e){return iE.test(e)}const cE=/^receive\(\) external payable$/;function uE(e){return cE.test(e)}const lE=new Set(["indexed"]),Zf=new Set(["calldata","memory","storage"]);class dE extends In{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 fE extends In{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 pE extends In{constructor({param:t}){super("Invalid ABI parameter.",{details:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParameterError"})}}class mE extends In{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 hE extends In{constructor({param:t,type:n,modifier:s}){super("Invalid ABI parameter.",{details:t,metaMessages:[`Modifier "${s}" not allowed${n?` in "${n}" type`:""}.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidModifierError"})}}class yE extends In{constructor({param:t,type:n,modifier:s}){super("Invalid ABI parameter.",{details:t,metaMessages:[`Modifier "${s}" not allowed${n?` in "${n}" type`:""}.`,`Data location can only be specified for array, struct, or mapping types, but "${s}" was given.`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidFunctionModifierError"})}}class bE extends In{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 In{constructor({signature:t,type:n}){super(`Invalid ${n} signature.`,{details:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSignatureError"})}}class gE extends In{constructor({signature:t}){super("Unknown signature.",{details:t}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownSignatureError"})}}class vE extends In{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 wE extends In{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 _E extends In{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 xE(e,t){return t?`${t}:${e}`:e}const qd=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 CE(e,t={}){if(tE(e)){const n=nE(e);if(!n)throw new wa({signature:e,type:"function"});const s=Ln(n.parameters),r=[],o=s.length;for(let a=0;a<o;a++)r.push(io(s[a],{modifiers:Zf,structs:t,type:"function"}));const i=[];if(n.returns){const a=Ln(n.returns),c=a.length;for(let u=0;u<c;u++)i.push(io(a[u],{modifiers:Zf,structs:t,type:"function"}))}return{name:n.name,type:"function",stateMutability:n.stateMutability??"nonpayable",inputs:r,outputs:i}}if(JT(e)){const n=eE(e);if(!n)throw new wa({signature:e,type:"event"});const s=Ln(n.parameters),r=[],o=s.length;for(let i=0;i<o;i++)r.push(io(s[i],{modifiers:lE,structs:t,type:"event"}));return{name:n.name,type:"event",inputs:r}}if(ZT(e)){const n=YT(e);if(!n)throw new wa({signature:e,type:"error"});const s=Ln(n.parameters),r=[],o=s.length;for(let i=0;i<o;i++)r.push(io(s[i],{structs:t,type:"error"}));return{name:n.name,type:"error",inputs:r}}if(rE(e)){const n=oE(e);if(!n)throw new wa({signature:e,type:"constructor"});const s=Ln(n.parameters),r=[],o=s.length;for(let i=0;i<o;i++)r.push(io(s[i],{structs:t,type:"constructor"}));return{type:"constructor",stateMutability:n.stateMutability??"nonpayable",inputs:r}}if(aE(e))return{type:"fallback"};if(uE(e))return{type:"receive",stateMutability:"payable"};throw new gE({signature:e})}const AE=/^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,TE=/^\((?<type>.+?)\)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/,EE=/^u?int$/;function io(e,t){var d,f;const n=xE(e,t==null?void 0:t.type);if(qd.has(n))return qd.get(n);const s=d2.test(e),r=Yr(s?TE:AE,e);if(!r)throw new pE({param:e});if(r.name&&PE(r.name))throw new mE({param:e,name:r.name});const o=r.name?{name:r.name}:{},i=r.modifier==="indexed"?{indexed:!0}:{},a=(t==null?void 0:t.structs)??{};let c,u={};if(s){c="tuple";const p=Ln(r.type),m=[],h=p.length;for(let y=0;y<h;y++)m.push(io(p[y],{structs:a}));u={components:m}}else if(r.type in a)c="tuple",u={components:a[r.type]};else if(EE.test(r.type))c=`${r.type}256`;else if(c=r.type,(t==null?void 0:t.type)!=="struct"&&!g2(c))throw new fE({type:c});if(r.modifier){if(!((f=(d=t==null?void 0:t.modifiers)==null?void 0:d.has)!=null&&f.call(d,r.modifier)))throw new hE({param:e,type:t==null?void 0:t.type,modifier:r.modifier});if(Zf.has(r.modifier)&&!kE(c,!!r.array))throw new yE({param:e,type:t==null?void 0:t.type,modifier:r.modifier})}const l={type:`${c}${r.array??""}`,...o,...i,...u};return qd.set(n,l),l}function Ln(e,t=[],n="",s=0){const r=e.trim().length;for(let o=0;o<r;o++){const i=e[o],a=e.slice(o+1);switch(i){case",":return s===0?Ln(a,[...t,n.trim()]):Ln(a,t,`${n}${i}`,s);case"(":return Ln(a,t,`${n}${i}`,s+1);case")":return Ln(a,t,`${n}${i}`,s-1);default:return Ln(a,t,`${n}${i}`,s)}}if(n==="")return t;if(s!==0)throw new _E({current:n,depth:s});return t.push(n.trim()),t}function g2(e){return e==="address"||e==="bool"||e==="function"||e==="string"||u2.test(e)||l2.test(e)}const SE=/^(?: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 PE(e){return e==="address"||e==="bool"||e==="function"||e==="string"||e==="tuple"||u2.test(e)||l2.test(e)||SE.test(e)}function kE(e,t){return t||e==="bytes"||e==="string"||e==="tuple"}function IE(e){const t={},n=e.length;for(let i=0;i<n;i++){const a=e[i];if(!y2(a))continue;const c=sE(a);if(!c)throw new wa({signature:a,type:"struct"});const u=c.properties.split(";"),l=[],d=u.length;for(let f=0;f<d;f++){const m=u[f].trim();if(!m)continue;const h=io(m,{type:"struct"});l.push(h)}if(!l.length)throw new vE({signature:a});t[c.name]=l}const s={},r=Object.entries(t),o=r.length;for(let i=0;i<o;i++){const[a,c]=r[i];s[a]=v2(c,t)}return s}const RE=/^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*)(?<array>(?:\[\d*?\])+?)?$/;function v2(e,t,n=new Set){const s=[],r=e.length;for(let o=0;o<r;o++){const i=e[o];if(d2.test(i.type))s.push(i);else{const c=Yr(RE,i.type);if(!(c!=null&&c.type))throw new bE({abiParameter:i});const{array:u,type:l}=c;if(l in t){if(n.has(l))throw new wE({type:l});s.push({...i,type:`tuple${u??""}`,components:v2(t[l]??[],t,new Set([...n,l]))})}else if(g2(l))s.push(i);else throw new dE({type:l})}}return s}function w2(e){const t=IE(e),n=[],s=e.length;for(let r=0;r<s;r++){const o=e[r];y2(o)||n.push(CE(o,t))}return n}function $E(e){let t=!0,n="",s=0,r="",o=!1;for(let i=0;i<e.length;i++){const a=e[i];if(["(",")",","].includes(a)&&(t=!0),a==="("&&s++,a===")"&&s--,!!t){if(s===0){if(a===" "&&["event","function",""].includes(r))r="";else if(r+=a,a===")"){o=!0;break}continue}if(a===" "){e[i-1]!==","&&n!==","&&n!==",("&&(n="",t=!1);continue}r+=a,n+=a}}if(!o)throw new ue("Unable to normalize signature.");return r}const ME=e=>{const t=typeof e=="string"?e:QT(e);return $E(t)};function _2(e){return XT(ME(e))}const El=_2,Zm=e=>ju(_2(e),0,4);function Pc(e){const{abi:t,args:n=[],name:s}=e,r=ms(s,{strict:!1}),o=t.filter(a=>r?a.type==="function"?Zm(a)===s:a.type==="event"?El(a)===s:!1:"name"in a&&a.name===s);if(o.length===0)return;if(o.length===1)return o[0];let i;for(const a of o){if(!("inputs"in a))continue;if(!n||n.length===0){if(!a.inputs||a.inputs.length===0)return a;continue}if(!a.inputs||a.inputs.length===0||a.inputs.length!==n.length)continue;if(n.every((u,l)=>{const d="inputs"in a&&a.inputs[l];return d?Yf(u,d):!1})){if(i&&"inputs"in i&&i.inputs){const u=x2(a.inputs,i.inputs,n);if(u)throw new JA({abiItem:a,type:u[0]},{abiItem:i,type:u[1]})}i=a}}return i||o[0]}function Yf(e,t){const n=typeof e,s=t.type;switch(s){case"address":return Hn(e,{strict:!1});case"bool":return n==="boolean";case"function":return n==="string";case"string":return n==="string";default:return s==="tuple"&&"components"in t?Object.values(t.components).every((r,o)=>Yf(Object.values(e)[o],r)):/^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(s)?n==="number"||n==="bigint":/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(s)?n==="string"||e instanceof Uint8Array:/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(s)?Array.isArray(e)&&e.every(r=>Yf(r,{...t,type:s.replace(/(\[[0-9]{0,}\])$/,"")})):!1}}function x2(e,t,n){for(const s in e){const r=e[s],o=t[s];if(r.type==="tuple"&&o.type==="tuple"&&"components"in r&&"components"in o)return x2(r.components,o.components,n[s]);const i=[r.type,o.type];if(i.includes("address")&&i.includes("bytes20")?!0:i.includes("address")&&i.includes("string")?Hn(n[s],{strict:!1}):i.includes("address")&&i.includes("bytes")?Hn(n[s],{strict:!1}):!1)return i}}const Wd="/docs/contract/decodeFunctionResult";function na(e){const{abi:t,args:n,functionName:s,data:r}=e;let o=t[0];if(s){const a=Pc({abi:t,args:n,name:s});if(!a)throw new Uu(s,{docsPath:Wd});o=a}if(o.type!=="function")throw new Uu(void 0,{docsPath:Wd});if(!o.outputs)throw new YA(o.name,{docsPath:Wd});const i=Tl(o.outputs,r);if(i&&i.length>1)return i;if(i&&i.length===1)return i[0]}const B0="/docs/contract/encodeFunctionData";function OE(e){const{abi:t,args:n,functionName:s}=e;let r=t[0];if(s){const o=Pc({abi:t,args:n,name:s});if(!o)throw new Uu(s,{docsPath:B0});r=o}if(r.type!=="function")throw new Uu(void 0,{docsPath:B0});return{abi:[r],functionName:Zm(Ws(r))}}function tr(e){const{args:t}=e,{abi:n,functionName:s}=(()=>{var a;return e.abi.length===1&&((a=e.functionName)!=null&&a.startsWith("0x"))?e:OE(e)})(),r=n[0],o=s,i="inputs"in r&&r.inputs?Ji(r.inputs,t??[]):void 0;return Tc([o,i??"0x"])}function sa({blockNumber:e,chain:t,contract:n}){var r;const s=(r=t==null?void 0:t.contracts)==null?void 0:r[n];if(!s)throw new Nf({chain:t,contract:{name:n}});if(e&&s.blockCreated&&s.blockCreated>e)throw new Nf({blockNumber:e,chain:t,contract:{name:n,blockCreated:s.blockCreated}});return s.address}const C2={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."},LE={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},FE={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"};function NE(e){const{abi:t,data:n}=e,s=ju(n,0,4);if(s==="0x")throw new gl;const o=[...t||[],LE,FE].find(i=>i.type==="error"&&s===Zm(Ws(i)));if(!o)throw new Ew(s,{docsPath:"/docs/contract/decodeErrorResult"});return{abiItem:o,args:"inputs"in o&&o.inputs&&o.inputs.length>0?Tl(o.inputs,ju(n,4)):void 0,errorName:o.name}}function A2({abiItem:e,args:t,includeFunctionName:n=!0,includeName:s=!1}){if("name"in e&&"inputs"in e&&e.inputs)return`${n?e.name:""}(${e.inputs.map((r,o)=>`${s&&r.name?`${r.name}: `:""}${typeof t[o]=="object"?Bt(t[o]):t[o]}`).join(", ")})`}class T2 extends ue{constructor(t,{account:n,docsPath:s,chain:r,data:o,gas:i,gasPrice:a,maxFeePerGas:c,maxPriorityFeePerGas:u,nonce:l,to:d,value:f,stateOverride:p}){var y;const m=n?Xn(n):void 0;let h=Sc({from:m==null?void 0:m.address,to:d,value:typeof f<"u"&&`${Bm(f)} ${((y=r==null?void 0:r.nativeCurrency)==null?void 0:y.symbol)||"ETH"}`,data:o,gas:i,gasPrice:typeof a<"u"&&`${en(a)} gwei`,maxFeePerGas:typeof c<"u"&&`${en(c)} gwei`,maxPriorityFeePerGas:typeof u<"u"&&`${en(u)} gwei`,nonce:l});p&&(h+=`
${vT(p)}`),super(t.shortMessage,{cause:t,docsPath:s,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],"Raw Call Arguments:",h].filter(Boolean),name:"CallExecutionError"}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.cause=t}}class Ym extends ue{constructor(t,{abi:n,args:s,contractAddress:r,docsPath:o,functionName:i,sender:a}){const c=Pc({abi:n,args:s,name:i}),u=c?A2({abiItem:c,args:s,includeFunctionName:!1,includeName:!1}):void 0,l=c?Ws(c,{includeName:!0}):void 0,d=Sc({address:r&&rT(r),function:l,args:u&&u!=="()"&&`${[...Array((i==null?void 0:i.length)??0).keys()].map(()=>" ").join("")}${u}`,sender:a});super(t.shortMessage||`An unknown error occurred while executing the contract function "${i}".`,{cause:t,docsPath:o,metaMessages:[...t.metaMessages?[...t.metaMessages," "]:[],d&&"Contract Call:",d].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=s,this.cause=t,this.contractAddress=r,this.functionName=i,this.sender=a}}class Jf extends ue{constructor({abi:t,data:n,functionName:s,message:r}){let o,i,a,c;if(n&&n!=="0x")try{i=NE({abi:t,data:n});const{abiItem:l,errorName:d,args:f}=i;if(d==="Error")c=f[0];else if(d==="Panic"){const[p]=f;c=C2[p]}else{const p=l?Ws(l,{includeName:!0}):void 0,m=l&&f?A2({abiItem:l,args:f,includeFunctionName:!1,includeName:!1}):void 0;a=[p?`Error: ${p}`:"",m&&m!=="()"?`       ${[...Array((d==null?void 0:d.length)??0).keys()].map(()=>" ").join("")}${m}`:""]}}catch(l){o=l}else r&&(c=r);let u;o instanceof Ew&&(u=o.signature,a=[`Unable to decode signature "${u}" 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://openchain.xyz/signatures?query=${u}.`]),super(c&&c!=="execution reverted"||u?[`The contract function "${s}" reverted with the following ${u?"signature":"reason"}:`,c||u].join(`
`):`The contract function "${s}" reverted.`,{cause:o,metaMessages:a,name:"ContractFunctionRevertedError"}),Object.defineProperty(this,"data",{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=i,this.reason=c,this.signature=u}}class BE extends ue{constructor({functionName:t}){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"})}}class DE extends ue{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 Jm extends ue{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 eh(e,t){var s,r,o,i,a,c;if(!(e instanceof ue))return!1;const n=e.walk(u=>u instanceof Jf);return n instanceof Jf?!!(((s=n.data)==null?void 0:s.errorName)==="ResolverNotFound"||((r=n.data)==null?void 0:r.errorName)==="ResolverWildcardNotSupported"||((o=n.data)==null?void 0:o.errorName)==="ResolverNotContract"||((i=n.data)==null?void 0:i.errorName)==="ResolverError"||((a=n.data)==null?void 0:a.errorName)==="HttpError"||(c=n.reason)!=null&&c.includes("Wildcard on non-extended resolvers is not supported")||t==="reverse"&&n.reason===C2[50]):!1}function E2(e){if(e.length!==66||e.indexOf("[")!==0||e.indexOf("]")!==65)return null;const t=`0x${e.slice(1,65)}`;return ms(t)?t:null}function wu(e){let t=new Uint8Array(32).fill(0);if(!e)return wt(t);const n=e.split(".");for(let s=n.length-1;s>=0;s-=1){const r=E2(n[s]),o=r?Yi(r):Ct(go(n[s]),"bytes");t=Ct(Gs([t,o]),"bytes")}return wt(t)}function UE(e){return`[${e.slice(2)}]`}function VE(e){const t=new Uint8Array(32).fill(0);return e?E2(e)||Ct(go(e)):wt(t)}function Sl(e){const t=e.replace(/^\.|\.$/gm,"");if(t.length===0)return new Uint8Array(1);const n=new Uint8Array(go(t).byteLength+2);let s=0;const r=t.split(".");for(let o=0;o<r.length;o++){let i=go(r[o]);i.byteLength>255&&(i=go(UE(VE(r[o])))),n[s]=i.length,n.set(i,s+1),s+=i.length+1}return n.byteLength!==s+1?n.slice(0,s+1):n}const jE=3;function Fi(e,{abi:t,address:n,args:s,docsPath:r,functionName:o,sender:i}){const{code:a,data:c,message:u,shortMessage:l}=e instanceof Jm?e:e instanceof ue?e.walk(f=>"data"in f)||e.walk():{},d=e instanceof gl?new BE({functionName:o}):[jE,To.code].includes(a)&&(c||u||l)?new Jf({abi:t,data:typeof c=="object"?c.data:c,functionName:o,message:l??u}):e;return new Ym(d,{abi:t,args:s,contractAddress:n,docsPath:r,functionName:o,sender:i})}const HE="0x82ad56cb",zE="0x608060405234801561001057600080fd5b5060405161018e38038061018e83398101604081905261002f91610124565b6000808351602085016000f59050803b61004857600080fd5b6000808351602085016000855af16040513d6000823e81610067573d81fd5b3d81f35b634e487b7160e01b600052604160045260246000fd5b600082601f83011261009257600080fd5b81516001600160401b038111156100ab576100ab61006b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156100d9576100d961006b565b6040528181528382016020018510156100f157600080fd5b60005b82811015610110576020818601810151838301820152016100f4565b506000918101602001919091529392505050565b6000806040838503121561013757600080fd5b82516001600160401b0381111561014d57600080fd5b61015985828601610081565b602085015190935090506001600160401b0381111561017757600080fd5b61018385828601610081565b915050925092905056fe",qE="0x608060405234801561001057600080fd5b506040516102c03803806102c083398101604081905261002f916101e6565b836001600160a01b03163b6000036100e457600080836001600160a01b03168360405161005c9190610270565b6000604051808303816000865af19150503d8060008114610099576040519150601f19603f3d011682016040523d82523d6000602084013e61009e565b606091505b50915091508115806100b857506001600160a01b0386163b155b156100e1578060405163101bb98d60e01b81526004016100d8919061028c565b60405180910390fd5b50505b6000808451602086016000885af16040513d6000823e81610103573d81fd5b3d81f35b80516001600160a01b038116811461011e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561015457818101518382015260200161013c565b50506000910152565b600082601f83011261016e57600080fd5b81516001600160401b0381111561018757610187610123565b604051601f8201601f19908116603f011681016001600160401b03811182821017156101b5576101b5610123565b6040528181528382016020018510156101cd57600080fd5b6101de826020830160208701610139565b949350505050565b600080600080608085870312156101fc57600080fd5b61020585610107565b60208601519094506001600160401b0381111561022157600080fd5b61022d8782880161015d565b93505061023c60408601610107565b60608601519092506001600160401b0381111561025857600080fd5b6102648782880161015d565b91505092959194509250565b60008251610282818460208701610139565b9190910192915050565b60208152600082518060208401526102ab816040850160208701610139565b601f01601f1916919091016040019291505056fe",WE="0x608060405234801561001057600080fd5b5060405161069438038061069483398101604081905261002f9161051e565b600061003c848484610048565b9050806000526001601ff35b60007f64926492649264926492649264926492649264926492649264926492649264926100748361040c565b036101e7576000606080848060200190518101906100929190610577565b60405192955090935091506000906001600160a01b038516906100b69085906105dd565b6000604051808303816000865af19150503d80600081146100f3576040519150601f19603f3d011682016040523d82523d6000602084013e6100f8565b606091505b50509050876001600160a01b03163b60000361016057806101605760405162461bcd60e51b815260206004820152601e60248201527f5369676e617475726556616c696461746f723a206465706c6f796d656e74000060448201526064015b60405180910390fd5b604051630b135d3f60e11b808252906001600160a01b038a1690631626ba7e90610190908b9087906004016105f9565b602060405180830381865afa1580156101ad573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101d19190610633565b6001600160e01b03191614945050505050610405565b6001600160a01b0384163b1561027a57604051630b135d3f60e11b808252906001600160a01b03861690631626ba7e9061022790879087906004016105f9565b602060405180830381865afa158015610244573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102689190610633565b6001600160e01b031916149050610405565b81516041146102df5760405162461bcd60e51b815260206004820152603a602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e6174757265206c656e6774680000000000006064820152608401610157565b6102e7610425565b5060208201516040808401518451859392600091859190811061030c5761030c61065d565b016020015160f81c9050601b811480159061032b57508060ff16601c14155b1561038c5760405162461bcd60e51b815260206004820152603b602482015260008051602061067483398151915260448201527f3a20696e76616c6964207369676e617475726520762076616c756500000000006064820152608401610157565b60408051600081526020810180835289905260ff83169181019190915260608101849052608081018390526001600160a01b0389169060019060a0016020604051602081039080840390855afa1580156103ea573d6000803e3d6000fd5b505050602060405103516001600160a01b0316149450505050505b9392505050565b600060208251101561041d57600080fd5b508051015190565b60405180606001604052806003906020820280368337509192915050565b6001600160a01b038116811461045857600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b60005b8381101561048c578181015183820152602001610474565b50506000910152565b600082601f8301126104a657600080fd5b81516001600160401b038111156104bf576104bf61045b565b604051601f8201601f19908116603f011681016001600160401b03811182821017156104ed576104ed61045b565b60405281815283820160200185101561050557600080fd5b610516826020830160208701610471565b949350505050565b60008060006060848603121561053357600080fd5b835161053e81610443565b6020850151604086015191945092506001600160401b0381111561056157600080fd5b61056d86828701610495565b9150509250925092565b60008060006060848603121561058c57600080fd5b835161059781610443565b60208501519093506001600160401b038111156105b357600080fd5b6105bf86828701610495565b604086015190935090506001600160401b0381111561056157600080fd5b600082516105ef818460208701610471565b9190910192915050565b828152604060208201526000825180604084015261061e816060850160208701610471565b601f01601f1916919091016060019392505050565b60006020828403121561064557600080fd5b81516001600160e01b03198116811461040557600080fd5b634e487b7160e01b600052603260045260246000fdfe5369676e617475726556616c696461746f72237265636f7665725369676e6572";function GE(e,{docsPath:t,...n}){const s=(()=>{const r=Um(e,n);return r instanceof Cl?e:r})();return new T2(s,{docsPath:t,...n})}function S2(){let e=()=>{},t=()=>{};return{promise:new Promise((s,r)=>{e=s,t=r}),resolve:e,reject:t}}const Gd=new Map;function P2({fn:e,id:t,shouldSplitBatch:n,wait:s=0,sort:r}){const o=async()=>{const l=c();i();const d=l.map(({args:f})=>f);d.length!==0&&e(d).then(f=>{r&&Array.isArray(f)&&f.sort(r);for(let p=0;p<l.length;p++){const{resolve:m}=l[p];m==null||m([f[p],f])}}).catch(f=>{for(let p=0;p<l.length;p++){const{reject:m}=l[p];m==null||m(f)}})},i=()=>Gd.delete(t),a=()=>c().map(({args:l})=>l),c=()=>Gd.get(t)||[],u=l=>Gd.set(t,[...c(),l]);return{flush:i,async schedule(l){const{promise:d,resolve:f,reject:p}=S2();return(n==null?void 0:n([...a(),l]))&&o(),c().length>0?(u({args:l,resolve:f,reject:p}),d):(u({args:l,resolve:f,reject:p}),setTimeout(o,s),d)}}}async function kc(e,t){var B,L,X,z;const{account:n=e.account,batch:s=!!((B=e.batch)!=null&&B.multicall),blockNumber:r,blockTag:o="latest",accessList:i,blobs:a,code:c,data:u,factory:l,factoryData:d,gas:f,gasPrice:p,maxFeePerBlobGas:m,maxFeePerGas:h,maxPriorityFeePerGas:y,nonce:b,to:g,value:w,stateOverride:_,...A}=t,x=n?Xn(n):void 0;if(c&&(l||d))throw new ue("Cannot provide both `code` & `factory`/`factoryData` as parameters.");if(c&&g)throw new ue("Cannot provide both `code` & `to` as parameters.");const C=c&&u,k=l&&d&&g&&u,S=C||k,R=C?QE({code:c,data:u}):k?ZE({data:u,factory:l,factoryData:d,to:g}):u;try{Al(t);const ne=(r?Ee(r):void 0)||o,te=Yw(_),ce=(z=(X=(L=e.chain)==null?void 0:L.formatters)==null?void 0:X.transactionRequest)==null?void 0:z.format,_e=(ce||jm)({...Vm(A,{format:ce}),from:x==null?void 0:x.address,accessList:i,blobs:a,data:R,gas:f,gasPrice:p,maxFeePerBlobGas:m,maxFeePerGas:h,maxPriorityFeePerGas:y,nonce:b,to:S?void 0:g,value:w});if(s&&XE({request:_e})&&!te)try{return await KE(e,{..._e,blockNumber:r,blockTag:o})}catch(Ae){if(!(Ae instanceof Hw)&&!(Ae instanceof Nf))throw Ae}const Fe=await e.request({method:"eth_call",params:te?[_e,ne,te]:[_e,ne]});return Fe==="0x"?{data:void 0}:{data:Fe}}catch(ie){const ne=YE(ie),{offchainLookup:te,offchainLookupSignature:ce}=await $i(async()=>{const{offchainLookup:he,offchainLookupSignature:_e}=await import("./ccip-BPht_beI.js");return{offchainLookup:he,offchainLookupSignature:_e}},[]);if(e.ccipRead!==!1&&(ne==null?void 0:ne.slice(0,10))===ce&&g)return{data:await te(e,{data:ne,to:g})};throw S&&(ne==null?void 0:ne.slice(0,10))==="0x101bb98d"?new DE({factory:l}):GE(ie,{...t,account:x,chain:e.chain})}}function XE({request:e}){const{data:t,to:n,...s}=e;return!(!t||t.startsWith(HE)||!n||Object.values(s).filter(r=>typeof r<"u").length>0)}async function KE(e,t){var h;const{batchSize:n=1024,wait:s=0}=typeof((h=e.batch)==null?void 0:h.multicall)=="object"?e.batch.multicall:{},{blockNumber:r,blockTag:o="latest",data:i,multicallAddress:a,to:c}=t;let u=a;if(!u){if(!e.chain)throw new Hw;u=sa({blockNumber:r,chain:e.chain,contract:"multicall3"})}const d=(r?Ee(r):void 0)||o,{schedule:f}=P2({id:`${e.uid}.${d}`,wait:s,shouldSplitBatch(y){return y.reduce((g,{data:w})=>g+(w.length-2),0)>n*2},fn:async y=>{const b=y.map(_=>({allowFailure:!0,callData:_.data,target:_.to})),g=tr({abi:Gf,args:[b],functionName:"aggregate3"}),w=await e.request({method:"eth_call",params:[{data:g,to:u},d]});return na({abi:Gf,args:[b],functionName:"aggregate3",data:w||"0x"})}}),[{returnData:p,success:m}]=await f({data:i,to:c});if(!m)throw new Jm({data:p});return p==="0x"?{data:void 0}:{data:p}}function QE(e){const{code:t,data:n}=e;return Fm({abi:w2(["constructor(bytes, bytes)"]),bytecode:zE,args:[t,n]})}function ZE(e){const{data:t,factory:n,factoryData:s,to:r}=e;return Fm({abi:w2(["constructor(address, bytes, address, bytes)"]),bytecode:qE,args:[r,t,n,s]})}function YE(e){var n;if(!(e instanceof ue))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 zn(e,t){const{abi:n,address:s,args:r,functionName:o,...i}=t,a=tr({abi:n,args:r,functionName:o});try{const{data:c}=await xe(e,kc,"call")({...i,data:a,to:s});return na({abi:n,args:r,functionName:o,data:c||"0x"})}catch(c){throw Fi(c,{abi:n,address:s,args:r,docsPath:"/docs/contract/readContract",functionName:o})}}async function JE(e,{blockNumber:t,blockTag:n,coinType:s,name:r,gatewayUrls:o,strict:i,universalResolverAddress:a}){let c=a;if(!c){if(!e.chain)throw new Error("client chain not configured. universalResolverAddress is required.");c=sa({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}try{const u=tr({abi:O0,functionName:"addr",...s!=null?{args:[wu(r),BigInt(s)]}:{args:[wu(r)]}}),l={address:c,abi:c2,functionName:"resolve",args:[qs(Sl(r)),u],blockNumber:t,blockTag:n},d=xe(e,zn,"readContract"),f=o?await d({...l,args:[...l.args,o]}):await d(l);if(f[0]==="0x")return null;const p=na({abi:O0,args:s!=null?[wu(r),BigInt(s)]:void 0,functionName:"addr",data:f[0]});return p==="0x"||Ds(p)==="0x00"?null:p}catch(u){if(i)throw u;if(eh(u,"resolve"))return null;throw u}}class eS extends ue{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 ba extends ue{constructor({reason:t}){super(`ENS NFT avatar URI is invalid. ${t}`,{name:"EnsAvatarInvalidNftUriError"})}}class th extends ue{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 tS extends ue{constructor({namespace:t}){super(`ENS NFT avatar namespace "${t}" is not supported. Must be "erc721" or "erc1155".`,{name:"EnsAvatarUnsupportedNamespaceError"})}}const nS=/(?<protocol>https?:\/\/[^\/]*|ipfs:\/|ipns:\/|ar:\/)?(?<root>\/)?(?<subpath>ipfs\/|ipns\/)?(?<target>[\w\-.]+)(?<subtarget>\/.*)?/,sS=/^(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>\/.*)?$/,rS=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,oS=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function iS(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"||!globalThis.hasOwnProperty("Image")?!1:new Promise(n=>{const s=new Image;s.onload=()=>{n(!0)},s.onerror=()=>{n(!1)},s.src=e})}}function D0(e,t){return e?e.endsWith("/")?e.slice(0,-1):e:t}function k2({uri:e,gatewayUrls:t}){const n=rS.test(e);if(n)return{uri:e,isOnChain:!0,isEncoded:n};const s=D0(t==null?void 0:t.ipfs,"https://ipfs.io"),r=D0(t==null?void 0:t.arweave,"https://arweave.net"),o=e.match(nS),{protocol:i,subpath:a,target:c,subtarget:u=""}=(o==null?void 0:o.groups)||{},l=i==="ipns:/"||a==="ipns/",d=i==="ipfs:/"||a==="ipfs/"||sS.test(e);if(e.startsWith("http")&&!l&&!d){let p=e;return t!=null&&t.arweave&&(p=e.replace(/https:\/\/arweave.net/g,t==null?void 0:t.arweave)),{uri:p,isOnChain:!1,isEncoded:!1}}if((l||d)&&c)return{uri:`${s}/${l?"ipns":"ipfs"}/${c}${u}`,isOnChain:!1,isEncoded:!1};if(i==="ar:/"&&c)return{uri:`${r}/${c}${u||""}`,isOnChain:!1,isEncoded:!1};let f=e.replace(oS,"");if(f.startsWith("<svg")&&(f=`data:image/svg+xml;base64,${btoa(f)}`),f.startsWith("data:")||f.startsWith("{"))return{uri:f,isOnChain:!0,isEncoded:!1};throw new th({uri:e})}function I2(e){if(typeof e!="object"||!("image"in e)&&!("image_url"in e)&&!("image_data"in e))throw new eS({data:e});return e.image||e.image_url||e.image_data}async function aS({gatewayUrls:e,uri:t}){try{const n=await fetch(t).then(r=>r.json());return await nh({gatewayUrls:e,uri:I2(n)})}catch{throw new th({uri:t})}}async function nh({gatewayUrls:e,uri:t}){const{uri:n,isOnChain:s}=k2({uri:t,gatewayUrls:e});if(s||await iS(n))return n;throw new th({uri:t})}function cS(e){let t=e;t.startsWith("did:nft:")&&(t=t.replace("did:nft:","").replace(/_/g,"/"));const[n,s,r]=t.split("/"),[o,i]=n.split(":"),[a,c]=s.split(":");if(!o||o.toLowerCase()!=="eip155")throw new ba({reason:"Only EIP-155 supported"});if(!i)throw new ba({reason:"Chain ID not found"});if(!c)throw new ba({reason:"Contract address not found"});if(!r)throw new ba({reason:"Token ID not found"});if(!a)throw new ba({reason:"ERC namespace not found"});return{chainID:Number.parseInt(i),namespace:a.toLowerCase(),contractAddress:c,tokenID:r}}async function uS(e,{nft:t}){if(t.namespace==="erc721")return zn(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 zn(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 tS({namespace:t.namespace})}async function lS(e,{gatewayUrls:t,record:n}){return/eip155:/i.test(n)?dS(e,{gatewayUrls:t,record:n}):nh({uri:n,gatewayUrls:t})}async function dS(e,{gatewayUrls:t,record:n}){const s=cS(n),r=await uS(e,{nft:s}),{uri:o,isOnChain:i,isEncoded:a}=k2({uri:r,gatewayUrls:t});if(i&&(o.includes("data:application/json;base64,")||o.startsWith("{"))){const u=a?atob(o.replace("data:application/json;base64,","")):o,l=JSON.parse(u);return nh({uri:I2(l),gatewayUrls:t})}let c=s.tokenID;return s.namespace==="erc1155"&&(c=c.replace("0x","").padStart(64,"0")),aS({gatewayUrls:t,uri:o.replace(/(?:0x)?{id}/,c)})}async function R2(e,{blockNumber:t,blockTag:n,name:s,key:r,gatewayUrls:o,strict:i,universalResolverAddress:a}){let c=a;if(!c){if(!e.chain)throw new Error("client chain not configured. universalResolverAddress is required.");c=sa({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}try{const u={address:c,abi:c2,functionName:"resolve",args:[qs(Sl(s)),tr({abi:M0,functionName:"text",args:[wu(s),r]})],blockNumber:t,blockTag:n},l=xe(e,zn,"readContract"),d=o?await l({...u,args:[...u.args,o]}):await l(u);if(d[0]==="0x")return null;const f=na({abi:M0,functionName:"text",data:d[0]});return f===""?null:f}catch(u){if(i)throw u;if(eh(u,"resolve"))return null;throw u}}async function fS(e,{blockNumber:t,blockTag:n,assetGatewayUrls:s,name:r,gatewayUrls:o,strict:i,universalResolverAddress:a}){const c=await xe(e,R2,"getEnsText")({blockNumber:t,blockTag:n,key:"avatar",name:r,universalResolverAddress:a,gatewayUrls:o,strict:i});if(!c)return null;try{return await lS(e,{record:c,gatewayUrls:s})}catch{return null}}async function pS(e,{address:t,blockNumber:n,blockTag:s,gatewayUrls:r,strict:o,universalResolverAddress:i}){let a=i;if(!a){if(!e.chain)throw new Error("client chain not configured. universalResolverAddress is required.");a=sa({blockNumber:n,chain:e.chain,contract:"ensUniversalResolver"})}const c=`${t.toLowerCase().substring(2)}.addr.reverse`;try{const u={address:a,abi:FT,functionName:"reverse",args:[qs(Sl(c))],blockNumber:n,blockTag:s},l=xe(e,zn,"readContract"),[d,f]=r?await l({...u,args:[...u.args,r]}):await l(u);return t.toLowerCase()!==f.toLowerCase()?null:d}catch(u){if(o)throw u;if(eh(u,"reverse"))return null;throw u}}async function mS(e,{blockNumber:t,blockTag:n,name:s,universalResolverAddress:r}){let o=r;if(!o){if(!e.chain)throw new Error("client chain not configured. universalResolverAddress is required.");o=sa({blockNumber:t,chain:e.chain,contract:"ensUniversalResolver"})}const[i]=await xe(e,zn,"readContract")({address:o,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[qs(Sl(s))],blockNumber:t,blockTag:n});return i}function Pl(e,{method:t}){var s,r;const n={};return e.transport.type==="fallback"&&((r=(s=e.transport).onResponse)==null||r.call(s,({method:o,response:i,status:a,transport:c})=>{a==="success"&&t===o&&(n[i]=c.request)})),o=>n[o]||e.request}async function hS(e){const t=Pl(e,{method:"eth_newBlockFilter"}),n=await e.request({method:"eth_newBlockFilter"});return{id:n,request:t(n),type:"block"}}class yS extends ue{constructor(t){super(`Filter type "${t}" is not supported.`,{name:"FilterTypeNotSupportedError"})}}const U0="/docs/contract/encodeEventTopics";function Ic(e){var c;const{abi:t,eventName:n,args:s}=e;let r=t[0];if(n){const u=Pc({abi:t,name:n});if(!u)throw new g0(n,{docsPath:U0});r=u}if(r.type!=="event")throw new g0(void 0,{docsPath:U0});const o=Ws(r),i=El(o);let a=[];if(s&&"inputs"in r){const u=(c=r.inputs)==null?void 0:c.filter(d=>"indexed"in d&&d.indexed),l=Array.isArray(s)?s:Object.values(s).length>0?(u==null?void 0:u.map(d=>s[d.name]))??[]:[];l.length>0&&(a=(u==null?void 0:u.map((d,f)=>Array.isArray(l[f])?l[f].map((p,m)=>V0({param:d,value:l[f][m]})):l[f]?V0({param:d,value:l[f]}):null))??[])}return[i,...a]}function V0({param:e,value:t}){if(e.type==="string"||e.type==="bytes")return Ct(Yi(t));if(e.type==="tuple"||e.type.match(/^(.*)\[(\d+)?\]$/))throw new yS(e.type);return Ji([e],[t])}async function sh(e,t){const{address:n,abi:s,args:r,eventName:o,fromBlock:i,strict:a,toBlock:c}=t,u=Pl(e,{method:"eth_newFilter"}),l=o?Ic({abi:s,args:r,eventName:o}):void 0,d=await e.request({method:"eth_newFilter",params:[{address:n,fromBlock:typeof i=="bigint"?Ee(i):i,toBlock:typeof c=="bigint"?Ee(c):c,topics:l}]});return{abi:s,args:r,eventName:o,id:d,request:u(d),strict:!!a,type:"event"}}async function $2(e,{address:t,args:n,event:s,events:r,fromBlock:o,strict:i,toBlock:a}={}){const c=r??(s?[s]:void 0),u=Pl(e,{method:"eth_newFilter"});let l=[];c&&(l=[c.flatMap(p=>Ic({abi:[p],eventName:p.name,args:n}))],s&&(l=l[0]));const d=await e.request({method:"eth_newFilter",params:[{address:t,fromBlock:typeof o=="bigint"?Ee(o):o,toBlock:typeof a=="bigint"?Ee(a):a,...l.length?{topics:l}:{}}]});return{abi:c,args:n,eventName:s?s.name:void 0,fromBlock:o,id:d,request:u(d),strict:!!i,toBlock:a,type:"event"}}async function M2(e){const t=Pl(e,{method:"eth_newPendingTransactionFilter"}),n=await e.request({method:"eth_newPendingTransactionFilter"});return{id:n,request:t(n),type:"transaction"}}async function O2(e,t){const{abi:n,address:s,args:r,functionName:o,...i}=t,a=tr({abi:n,args:r,functionName:o});try{return await xe(e,Xm,"estimateGas")({data:a,to:s,...i})}catch(c){const u=i.account?Xn(i.account):void 0;throw Fi(c,{abi:n,address:s,args:r,docsPath:"/docs/contract/estimateContractGas",functionName:o,sender:u==null?void 0:u.address})}}async function bS(e){const t=await e.request({method:"eth_blobBaseFee"});return BigInt(t)}const gS=new Map,vS=new Map;function wS(e){const t=(r,o)=>({clear:()=>o.delete(r),get:()=>o.get(r),set:i=>o.set(r,i)}),n=t(e,gS),s=t(e,vS);return{clear:()=>{n.clear(),s.clear()},promise:n,response:s}}async function _S(e,{cacheKey:t,cacheTime:n=Number.POSITIVE_INFINITY}){const s=wS(t),r=s.response.get();if(r&&n>0&&new Date().getTime()-r.created.getTime()<n)return r.data;let o=s.promise.get();o||(o=e(),s.promise.set(o));try{const i=await o;return s.response.set({created:new Date,data:i}),i}finally{s.promise.clear()}}const xS=e=>`blockNumber.${e}`;async function Rc(e,{cacheTime:t=e.cacheTime}={}){const n=await _S(()=>e.request({method:"eth_blockNumber"}),{cacheKey:xS(e.uid),cacheTime:t});return BigInt(n)}async function CS(e,{blockHash:t,blockNumber:n,blockTag:s="latest"}={}){const r=n!==void 0?Ee(n):void 0;let o;return t?o=await e.request({method:"eth_getBlockTransactionCountByHash",params:[t]},{dedupe:!0}):o=await e.request({method:"eth_getBlockTransactionCountByNumber",params:[r||s]},{dedupe:!!r}),hs(o)}async function j0(e,{address:t,blockNumber:n,blockTag:s="latest"}){const r=n!==void 0?Ee(n):void 0,o=await e.request({method:"eth_getCode",params:[t,r||s]},{dedupe:!!r});if(o!=="0x")return o}function rh(e,t){if(!Hn(e,{strict:!1}))throw new Br({address:e});if(!Hn(t,{strict:!1}))throw new Br({address:t});return e.toLowerCase()===t.toLowerCase()}const H0="/docs/contract/decodeEventLog";function oh(e){const{abi:t,data:n,strict:s,topics:r}=e,o=s??!0,[i,...a]=r;if(!i)throw new ZA({docsPath:H0});const c=t.length===1?t[0]:t.find(h=>h.type==="event"&&i===El(Ws(h)));if(!(c&&"name"in c)||c.type!=="event")throw new Sw(i,{docsPath:H0});const{name:u,inputs:l}=c,d=l==null?void 0:l.some(h=>!("name"in h&&h.name));let f=d?[]:{};const p=l.filter(h=>"indexed"in h&&h.indexed);for(let h=0;h<p.length;h++){const y=p[h],b=a[h];if(!b)throw new vl({abiItem:c,param:y});f[d?h:y.name||h]=AS({param:y,value:b})}const m=l.filter(h=>!("indexed"in h&&h.indexed));if(m.length>0){if(n&&n!=="0x")try{const h=Tl(m,n);if(h)if(d)f=[...f,...h];else for(let y=0;y<m.length;y++)f[m[y].name]=h[y]}catch(h){if(o)throw h instanceof Tw||h instanceof Dw?new Wa({abiItem:c,data:n,params:m,size:ut(n)}):h}else if(o)throw new Wa({abiItem:c,data:"0x",params:m,size:0})}return{eventName:u,args:Object.values(f).length>0?f:void 0}}function AS({param:e,value:t}){return e.type==="string"||e.type==="bytes"||e.type==="tuple"||e.type.match(/^(.*)\[(\d+)?\]$/)?t:(Tl([e],t)||[])[0]}function ih(e){const{abi:t,args:n,logs:s,strict:r=!0}=e,o=(()=>{if(e.eventName)return Array.isArray(e.eventName)?e.eventName:[e.eventName]})();return s.map(i=>{var a;try{const c=t.find(l=>l.type==="event"&&i.topics[0]===El(l));if(!c)return null;const u=oh({...i,abi:[c],strict:r});return o&&!o.includes(u.eventName)||!TS({args:u.args,inputs:c.inputs,matchArgs:n})?null:{...u,...i}}catch(c){let u,l;if(c instanceof Sw)return null;if(c instanceof Wa||c instanceof vl){if(r)return null;u=c.abiItem.name,l=(a=c.abiItem.inputs)==null?void 0:a.some(d=>!("name"in d&&d.name))}return{...i,args:l?[]:{},eventName:u}}}).filter(Boolean)}function TS(e){const{args:t,inputs:n,matchArgs:s}=e;if(!s)return!0;if(!t)return!1;function r(o,i,a){try{return o.type==="address"?rh(i,a):o.type==="string"||o.type==="bytes"?Ct(Yi(i))===a:i===a}catch{return!1}}return Array.isArray(t)&&Array.isArray(s)?s.every((o,i)=>{if(o==null)return!0;const a=n[i];return a?(Array.isArray(o)?o:[o]).some(u=>r(a,u,t[i])):!1}):typeof t=="object"&&!Array.isArray(t)&&typeof s=="object"&&!Array.isArray(s)?Object.entries(s).every(([o,i])=>{if(i==null)return!0;const a=n.find(u=>u.name===o);return a?(Array.isArray(i)?i:[i]).some(u=>r(a,u,t[o])):!1}):!1}function Ur(e,{args:t,eventName:n}={}){return{...e,blockHash:e.blockHash?e.blockHash:null,blockNumber:e.blockNumber?BigInt(e.blockNumber):null,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}:{}}}async function ah(e,{address:t,blockHash:n,fromBlock:s,toBlock:r,event:o,events:i,args:a,strict:c}={}){const u=c??!1,l=i??(o?[o]:void 0);let d=[];l&&(d=[l.flatMap(h=>Ic({abi:[h],eventName:h.name,args:i?void 0:a}))],o&&(d=d[0]));let f;n?f=await e.request({method:"eth_getLogs",params:[{address:t,topics:d,blockHash:n}]}):f=await e.request({method:"eth_getLogs",params:[{address:t,topics:d,fromBlock:typeof s=="bigint"?Ee(s):s,toBlock:typeof r=="bigint"?Ee(r):r}]});const p=f.map(m=>Ur(m));return l?ih({abi:l,args:a,logs:p,strict:u}):p}async function ch(e,t){const{abi:n,address:s,args:r,blockHash:o,eventName:i,fromBlock:a,toBlock:c,strict:u}=t,l=i?Pc({abi:n,name:i}):void 0,d=l?void 0:n.filter(f=>f.type==="event");return xe(e,ah,"getLogs")({address:s,args:r,blockHash:o,event:l,events:d,fromBlock:a,toBlock:c,strict:u})}class ES extends ue{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 SS(e,t){const{address:n,factory:s,factoryData:r}=t;try{const[o,i,a,c,u,l,d]=await xe(e,zn,"readContract")({abi:PS,address:n,functionName:"eip712Domain",factory:s,factoryData:r});return{domain:{name:i,version:a,chainId:Number(c),verifyingContract:u,salt:l},extensions:d,fields:o}}catch(o){const i=o;throw i.name==="ContractFunctionExecutionError"&&i.cause.name==="ContractFunctionZeroDataError"?new ES({address:n}):i}}const PS=[{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 kS(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(s=>BigInt(s)))}}async function IS(e,{blockCount:t,blockNumber:n,blockTag:s="latest",rewardPercentiles:r}){const o=n?Ee(n):void 0,i=await e.request({method:"eth_feeHistory",params:[Ee(t),o||s,r]},{dedupe:!!o});return kS(i)}async function kl(e,{filter:t}){const n="strict"in t&&t.strict,s=await t.request({method:"eth_getFilterChanges",params:[t.id]});if(typeof s[0]=="string")return s;const r=s.map(o=>Ur(o));return!("abi"in t)||!t.abi?r:ih({abi:t.abi,logs:r,strict:n})}async function RS(e,{filter:t}){const n=t.strict??!1,r=(await t.request({method:"eth_getFilterLogs",params:[t.id]})).map(o=>Ur(o));return t.abi?ih({abi:t.abi,logs:r,strict:n}):r}async function $S(e,{address:t,blockNumber:n,blockTag:s="latest",slot:r}){const o=n!==void 0?Ee(n):void 0;return await e.request({method:"eth_getStorageAt",params:[t,r,o||s]})}async function Il(e,{blockHash:t,blockNumber:n,blockTag:s,hash:r,index:o}){var l,d,f;const i=s||"latest",a=n!==void 0?Ee(n):void 0;let c=null;if(r?c=await e.request({method:"eth_getTransactionByHash",params:[r]},{dedupe:!0}):t?c=await e.request({method:"eth_getTransactionByBlockHashAndIndex",params:[t,Ee(o)]},{dedupe:!0}):(a||i)&&(c=await e.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[a||i,Ee(o)]},{dedupe:!!a})),!c)throw new zw({blockHash:t,blockNumber:n,blockTag:i,hash:r,index:o});return(((f=(d=(l=e.chain)==null?void 0:l.formatters)==null?void 0:d.transaction)==null?void 0:f.format)||Kw)(c)}async function MS(e,{hash:t,transactionReceipt:n}){const[s,r]=await Promise.all([xe(e,Rc,"getBlockNumber")({}),t?xe(e,Il,"getTransaction")({hash:t}):void 0]),o=(n==null?void 0:n.blockNumber)||(r==null?void 0:r.blockNumber);return o?s-o+1n:0n}const OS={"0x0":"reverted","0x1":"success"};function LS(e){const t={...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(n=>Ur(n)):null,to:e.to?e.to:null,transactionIndex:e.transactionIndex?hs(e.transactionIndex):null,status:e.status?OS[e.status]:null,type:e.type?Xw[e.type]||e.type:null};return e.blobGasPrice&&(t.blobGasPrice=BigInt(e.blobGasPrice)),e.blobGasUsed&&(t.blobGasUsed=BigInt(e.blobGasUsed)),t}async function ep(e,{hash:t}){var r,o,i;const n=await e.request({method:"eth_getTransactionReceipt",params:[t]},{dedupe:!0});if(!n)throw new qw({hash:t});return(((i=(o=(r=e.chain)==null?void 0:r.formatters)==null?void 0:o.transactionReceipt)==null?void 0:i.format)||LS)(n)}async function L2(e,t){var y;const{allowFailure:n=!0,batchSize:s,blockNumber:r,blockTag:o,multicallAddress:i,stateOverride:a}=t,c=t.contracts,u=s??(typeof((y=e.batch)==null?void 0:y.multicall)=="object"&&e.batch.multicall.batchSize||1024);let l=i;if(!l){if(!e.chain)throw new Error("client chain not configured. multicallAddress is required.");l=sa({blockNumber:r,chain:e.chain,contract:"multicall3"})}const d=[[]];let f=0,p=0;for(let b=0;b<c.length;b++){const{abi:g,address:w,args:_,functionName:A}=c[b];try{const x=tr({abi:g,args:_,functionName:A});p+=(x.length-2)/2,u>0&&p>u&&d[f].length>0&&(f++,p=(x.length-2)/2,d[f]=[]),d[f]=[...d[f],{allowFailure:!0,callData:x,target:w}]}catch(x){const C=Fi(x,{abi:g,address:w,args:_,docsPath:"/docs/contract/multicall",functionName:A});if(!n)throw C;d[f]=[...d[f],{allowFailure:!0,callData:"0x",target:w}]}}const m=await Promise.allSettled(d.map(b=>xe(e,zn,"readContract")({abi:Gf,address:l,args:[b],blockNumber:r,blockTag:o,functionName:"aggregate3",stateOverride:a}))),h=[];for(let b=0;b<m.length;b++){const g=m[b];if(g.status==="rejected"){if(!n)throw g.reason;for(let _=0;_<d[b].length;_++)h.push({status:"failure",error:g.reason,result:void 0});continue}const w=g.value;for(let _=0;_<w.length;_++){const{returnData:A,success:x}=w[_],{callData:C}=d[b][_],{abi:k,address:S,functionName:R,args:B}=c[h.length];try{if(C==="0x")throw new gl;if(!x)throw new Jm({data:A});const L=na({abi:k,args:B,data:A,functionName:R});h.push(n?{result:L,status:"success"}:L)}catch(L){const X=Fi(L,{abi:k,address:S,args:B,docsPath:"/docs/contract/multicall",functionName:R});if(!n)throw X;h.push({error:X,result:void 0,status:"failure"})}}}if(h.length!==c.length)throw new ue("multicall results mismatch");return h}const Xd=new Map,z0=new Map;let FS=0;function Vr(e,t,n){const s=++FS,r=()=>Xd.get(e)||[],o=()=>{const l=r();Xd.set(e,l.filter(d=>d.id!==s))},i=()=>{const l=z0.get(e);r().length===1&&l&&l(),o()},a=r();if(Xd.set(e,[...a,{id:s,fns:t}]),a&&a.length>0)return i;const c={};for(const l in t)c[l]=(...d)=>{var p,m;const f=r();if(f.length!==0)for(const h of f)(m=(p=h.fns)[l])==null||m.call(p,...d)};const u=n(c);return typeof u=="function"&&z0.set(e,u),i}async function qu(e){return new Promise(t=>setTimeout(t,e))}function $c(e,{emitOnBegin:t,initialWaitTime:n,interval:s}){let r=!0;const o=()=>r=!1;return(async()=>{let a;t&&(a=await e({unpoll:o}));const c=await(n==null?void 0:n(a))??s;await qu(c);const u=async()=>{r&&(await e({unpoll:o}),await qu(s),u())};u()})(),o}function NS(e,{blockTag:t="latest",emitMissed:n=!1,emitOnBegin:s=!1,onBlock:r,onError:o,includeTransactions:i,poll:a,pollingInterval:c=e.pollingInterval}){const u=typeof a<"u"?a:!(e.transport.type==="webSocket"||e.transport.type==="fallback"&&e.transport.transports[0].config.type==="webSocket"),l=i??!1;let d;return u?(()=>{const m=Bt(["watchBlocks",e.uid,t,n,s,l,c]);return Vr(m,{onBlock:r,onError:o},h=>$c(async()=>{var y;try{const b=await xe(e,Us,"getBlock")({blockTag:t,includeTransactions:l});if(b.number&&(d!=null&&d.number)){if(b.number===d.number)return;if(b.number-d.number>1&&n)for(let g=(d==null?void 0:d.number)+1n;g<b.number;g++){const w=await xe(e,Us,"getBlock")({blockNumber:g,includeTransactions:l});h.onBlock(w,d),d=w}}(!(d!=null&&d.number)||t==="pending"&&!(b!=null&&b.number)||b.number&&b.number>d.number)&&(h.onBlock(b,d),d=b)}catch(b){(y=h.onError)==null||y.call(h,b)}},{emitOnBegin:s,interval:c}))})():(()=>{let m=!0,h=!0,y=()=>m=!1;return(async()=>{try{s&&xe(e,Us,"getBlock")({blockTag:t,includeTransactions:l}).then(w=>{m&&h&&(r(w,void 0),h=!1)});const b=(()=>{if(e.transport.type==="fallback"){const w=e.transport.transports.find(_=>_.config.type==="webSocket");return w?w.value:e.transport}return e.transport})(),{unsubscribe:g}=await b.subscribe({params:["newHeads"],onData(w){var x,C,k;if(!m)return;const A=(((k=(C=(x=e.chain)==null?void 0:x.formatters)==null?void 0:C.block)==null?void 0:k.format)||Qw)(w.result);r(A,d),h=!1,d=A},onError(w){o==null||o(w)}});y=g,m||y()}catch(b){o==null||o(b)}})(),()=>y()})()}function F2(e,{emitOnBegin:t=!1,emitMissed:n=!1,onBlockNumber:s,onError:r,poll:o,pollingInterval:i=e.pollingInterval}){const a=typeof o<"u"?o:!(e.transport.type==="webSocket"||e.transport.type==="fallback"&&e.transport.transports[0].config.type==="webSocket");let c;return a?(()=>{const d=Bt(["watchBlockNumber",e.uid,t,n,i]);return Vr(d,{onBlockNumber:s,onError:r},f=>$c(async()=>{var p;try{const m=await xe(e,Rc,"getBlockNumber")({cacheTime:0});if(c){if(m===c)return;if(m-c>1&&n)for(let h=c+1n;h<m;h++)f.onBlockNumber(h,c),c=h}(!c||m>c)&&(f.onBlockNumber(m,c),c=m)}catch(m){(p=f.onError)==null||p.call(f,m)}},{emitOnBegin:t,interval:i}))})():(()=>{const d=Bt(["watchBlockNumber",e.uid,t,n]);return Vr(d,{onBlockNumber:s,onError:r},f=>{let p=!0,m=()=>p=!1;return(async()=>{try{const h=(()=>{if(e.transport.type==="fallback"){const b=e.transport.transports.find(g=>g.config.type==="webSocket");return b?b.value:e.transport}return e.transport})(),{unsubscribe:y}=await h.subscribe({params:["newHeads"],onData(b){var w;if(!p)return;const g=Nr((w=b.result)==null?void 0:w.number);f.onBlockNumber(g,c),c=g},onError(b){var g;(g=f.onError)==null||g.call(f,b)}});m=y,p||m()}catch(h){r==null||r(h)}})(),()=>m()})})()}async function Rl(e,{filter:t}){return t.request({method:"eth_uninstallFilter",params:[t.id]})}function BS(e,{address:t,args:n,batch:s=!0,event:r,events:o,fromBlock:i,onError:a,onLogs:c,poll:u,pollingInterval:l=e.pollingInterval,strict:d}){const f=typeof u<"u"?u:typeof i=="bigint"?!0:!(e.transport.type==="webSocket"||e.transport.type==="fallback"&&e.transport.transports[0].config.type==="webSocket"),p=d??!1;return f?(()=>{const y=Bt(["watchEvent",t,n,s,e.uid,r,l,i]);return Vr(y,{onLogs:c,onError:a},b=>{let g;i!==void 0&&(g=i-1n);let w,_=!1;const A=$c(async()=>{var x;if(!_){try{w=await xe(e,$2,"createEventFilter")({address:t,args:n,event:r,events:o,strict:p,fromBlock:i})}catch{}_=!0;return}try{let C;if(w)C=await xe(e,kl,"getFilterChanges")({filter:w});else{const k=await xe(e,Rc,"getBlockNumber")({});g&&g!==k?C=await xe(e,ah,"getLogs")({address:t,args:n,event:r,events:o,fromBlock:g+1n,toBlock:k}):C=[],g=k}if(C.length===0)return;if(s)b.onLogs(C);else for(const k of C)b.onLogs([k])}catch(C){w&&C instanceof Eo&&(_=!1),(x=b.onError)==null||x.call(b,C)}},{emitOnBegin:!0,interval:l});return async()=>{w&&await xe(e,Rl,"uninstallFilter")({filter:w}),A()}})})():(()=>{let y=!0,b=()=>y=!1;return(async()=>{try{const g=(()=>{if(e.transport.type==="fallback"){const x=e.transport.transports.find(C=>C.config.type==="webSocket");return x?x.value:e.transport}return e.transport})(),w=o??(r?[r]:void 0);let _=[];w&&(_=[w.flatMap(C=>Ic({abi:[C],eventName:C.name,args:n}))],r&&(_=_[0]));const{unsubscribe:A}=await g.subscribe({params:["logs",{address:t,topics:_}],onData(x){var k;if(!y)return;const C=x.result;try{const{eventName:S,args:R}=oh({abi:w??[],data:C.data,topics:C.topics,strict:p}),B=Ur(C,{args:R,eventName:S});c([B])}catch(S){let R,B;if(S instanceof Wa||S instanceof vl){if(d)return;R=S.abiItem.name,B=(k=S.abiItem.inputs)==null?void 0:k.some(X=>!("name"in X&&X.name))}const L=Ur(C,{args:B?[]:{},eventName:R});c([L])}},onError(x){a==null||a(x)}});b=A,y||b()}catch(g){a==null||a(g)}})(),()=>b()})()}function DS(e,{batch:t=!0,onError:n,onTransactions:s,poll:r,pollingInterval:o=e.pollingInterval}){return(typeof r<"u"?r:e.transport.type!=="webSocket")?(()=>{const u=Bt(["watchPendingTransactions",e.uid,t,o]);return Vr(u,{onTransactions:s,onError:n},l=>{let d;const f=$c(async()=>{var p;try{if(!d)try{d=await xe(e,M2,"createPendingTransactionFilter")({});return}catch(h){throw f(),h}const m=await xe(e,kl,"getFilterChanges")({filter:d});if(m.length===0)return;if(t)l.onTransactions(m);else for(const h of m)l.onTransactions([h])}catch(m){(p=l.onError)==null||p.call(l,m)}},{emitOnBegin:!0,interval:o});return async()=>{d&&await xe(e,Rl,"uninstallFilter")({filter:d}),f()}})})():(()=>{let u=!0,l=()=>u=!1;return(async()=>{try{const{unsubscribe:d}=await e.transport.subscribe({params:["newPendingTransactions"],onData(f){if(!u)return;const p=f.result;s([p])},onError(f){n==null||n(f)}});l=d,u||l()}catch(d){n==null||n(d)}})(),()=>l()})()}const Qc=new wl(8192);function US(e,{enabled:t=!0,id:n}){if(!t||!n)return e();if(Qc.get(n))return Qc.get(n);const s=e().finally(()=>Qc.delete(n));return Qc.set(n,s),s}function sc(e,{delay:t=100,retryCount:n=2,shouldRetry:s=()=>!0}={}){return new Promise((r,o)=>{const i=async({count:a=0}={})=>{const c=async({error:u})=>{const l=typeof t=="function"?t({count:a,error:u}):t;l&&await qu(l),i({count:a+1})};try{const u=await e();r(u)}catch(u){if(a<n&&await s({count:a,error:u}))return c({error:u});o(u)}};i()})}function VS(e,t={}){return async(n,s={})=>{const{dedupe:r=!1,retryDelay:o=150,retryCount:i=3,uid:a}={...t,...s},c=r?Ct(Ii(`${a}.${Bt(n)}`)):void 0;return US(()=>sc(async()=>{try{return await e(n)}catch(u){const l=u;switch(l.code){case Ga.code:throw new Ga(l);case Xa.code:throw new Xa(l);case Ka.code:throw new Ka(l,{method:n.method});case Qa.code:throw new Qa(l);case To.code:throw new To(l);case Eo.code:throw new Eo(l);case Za.code:throw new Za(l);case Ir.code:throw new Ir(l);case Mi.code:throw new Mi(l);case Ya.code:throw new Ya(l,{method:n.method});case Oi.code:throw new Oi(l);case Ja.code:throw new Ja(l);case ht.code:throw new ht(l);case ec.code:throw new ec(l);case tc.code:throw new tc(l);case So.code:throw new So(l);case Li.code:throw new Li(l);case Dr.code:throw new Dr(l);case 5e3:throw new ht(l);default:throw u instanceof ue?u:new iT(l)}}},{delay:({count:u,error:l})=>{var d;if(l&&l instanceof ka){const f=(d=l==null?void 0:l.headers)==null?void 0:d.get("Retry-After");if(f!=null&&f.match(/\d/))return Number.parseInt(f)*1e3}return~~(1<<u)*o},retryCount:i,shouldRetry:({error:u})=>jS(u)}),{enabled:r,id:c})}}function jS(e){return"code"in e&&typeof e.code=="number"?e.code===-1||e.code===Oi.code||e.code===To.code:e instanceof ka&&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 HS(e){return{formatters:void 0,fees:void 0,serializers:void 0,...e}}const zS=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,qS=/^(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 $l(e,{errorInstance:t=new Error("timed out"),timeout:n,signal:s}){return new Promise((r,o)=>{(async()=>{let i;try{const a=new AbortController;n>0&&(i=setTimeout(()=>{s?a.abort():o(t)},n)),r(await e({signal:(a==null?void 0:a.signal)||null}))}catch(a){(a==null?void 0:a.name)==="AbortError"&&o(t),o(a)}finally{clearTimeout(i)}})()})}function WS(){return{current:0,take(){return this.current++},reset(){this.current=0}}}const q0=WS();function GS(e,t={}){return{async request(n){var d;const{body:s,onRequest:r=t.onRequest,onResponse:o=t.onResponse,timeout:i=t.timeout??1e4}=n,a={...t.fetchOptions??{},...n.fetchOptions??{}},{headers:c,method:u,signal:l}=a;try{const f=await $l(async({signal:m})=>{const h={...a,body:Array.isArray(s)?Bt(s.map(w=>({jsonrpc:"2.0",id:w.id??q0.take(),...w}))):Bt({jsonrpc:"2.0",id:s.id??q0.take(),...s}),headers:{"Content-Type":"application/json",...c},method:u||"POST",signal:l||(i>0?m:null)},y=new Request(e,h),b=await(r==null?void 0:r(y,h))??{...h,url:e};return await fetch(b.url??e,b)},{errorInstance:new S0({body:s,url:e}),timeout:i,signal:!0});o&&await o(f);let p;if((d=f.headers.get("Content-Type"))!=null&&d.startsWith("application/json"))p=await f.json();else{p=await f.text();try{p=JSON.parse(p||"{}")}catch(m){if(f.ok)throw m;p={error:p}}}if(!f.ok)throw new ka({body:s,details:Bt(p.error)||f.statusText,headers:f.headers,status:f.status,url:e});return p}catch(f){throw f instanceof ka||f instanceof S0?f:new ka({body:s,cause:f,url:e})}}}}class XS extends ue{constructor({type:t}){super(`Struct type "${t}" is invalid.`,{metaMessages:["Struct type must not be a Solidity type."],name:"InvalidStructTypeError"})}}function KS(e){const{domain:t={},message:n,primaryType:s}=e,r={EIP712Domain:eP({domain:t}),...e.types};JS({domain:t,message:n,primaryType:s,types:r});const o=["0x1901"];return t&&o.push(QS({domain:t,types:r})),s!=="EIP712Domain"&&o.push(N2({data:n,primaryType:s,types:r})),Ct(Gs(o))}function QS({domain:e,types:t}){return N2({data:e,primaryType:"EIP712Domain",types:t})}function N2({data:e,primaryType:t,types:n}){const s=B2({data:e,primaryType:t,types:n});return Ct(s)}function B2({data:e,primaryType:t,types:n}){const s=[{type:"bytes32"}],r=[ZS({primaryType:t,types:n})];for(const o of n[t]){const[i,a]=U2({types:n,name:o.name,type:o.type,value:e[o.name]});s.push(i),r.push(a)}return Ji(s,r)}function ZS({primaryType:e,types:t}){const n=qs(YS({primaryType:e,types:t}));return Ct(n)}function YS({primaryType:e,types:t}){let n="";const s=D2({primaryType:e,types:t});s.delete(e);const r=[e,...Array.from(s).sort()];for(const o of r)n+=`${o}(${t[o].map(({name:i,type:a})=>`${a} ${i}`).join(",")})`;return n}function D2({primaryType:e,types:t},n=new Set){const s=e.match(/^\w*/u),r=s==null?void 0:s[0];if(n.has(r)||t[r]===void 0)return n;n.add(r);for(const o of t[r])D2({primaryType:o.type,types:t},n);return n}function U2({types:e,name:t,type:n,value:s}){if(e[n]!==void 0)return[{type:"bytes32"},Ct(B2({data:s,primaryType:n,types:e}))];if(n==="bytes")return s=`0x${(s.length%2?"0":"")+s.slice(2)}`,[{type:"bytes32"},Ct(s)];if(n==="string")return[{type:"bytes32"},Ct(qs(s))];if(n.lastIndexOf("]")===n.length-1){const r=n.slice(0,n.lastIndexOf("[")),o=s.map(i=>U2({name:t,type:r,types:e,value:i}));return[{type:"bytes32"},Ct(Ji(o.map(([i])=>i),o.map(([,i])=>i)))]}return[{type:n},s]}function JS(e){const{domain:t,message:n,primaryType:s,types:r}=e,o=(i,a)=>{for(const c of i){const{name:u,type:l}=c,d=a[u],f=l.match(qS);if(f&&(typeof d=="number"||typeof d=="bigint")){const[h,y,b]=f;Ee(d,{signed:y==="int",size:Number.parseInt(b)/8})}if(l==="address"&&typeof d=="string"&&!Hn(d))throw new Br({address:d});const p=l.match(zS);if(p){const[h,y]=p;if(y&&ut(d)!==Number.parseInt(y))throw new e8({expectedSize:Number.parseInt(y),givenSize:ut(d)})}const m=r[l];m&&(tP(l),o(m,d))}};r.EIP712Domain&&t&&o(r.EIP712Domain,t),s!=="EIP712Domain"&&o(r[s],n)}function eP({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"&&{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 tP(e){if(e==="address"||e==="bool"||e==="string"||e.startsWith("bytes")||e.startsWith("uint")||e.startsWith("int"))throw new XS({type:e})}const nP=`Ethereum Signed Message:
`;function sP(e){const t=typeof e=="string"?Ii(e):typeof e.raw=="string"?e.raw:wt(e.raw),n=Ii(`${nP}${ut(t)}`);return Gs([n,t])}function V2(e,t){return Ct(sP(e),t)}const j2="0x6492649264926492649264926492649264926492649264926492649264926492";function rP(e){return Fw(e,-32)===j2}function oP(e){const{address:t,data:n,signature:s,to:r="hex"}=e,o=Tc([Ji([{type:"address"},{type:"bytes"},{type:"bytes"}],[t,n,s]),j2]);return r==="hex"?o:Pn(o)}class iP extends ue{constructor({value:t}){super(`Number \`${t}\` is not a valid decimal number.`,{name:"InvalidDecimalNumberError"})}}function aP(e,t){if(!/^(-?)([0-9]*)\.?([0-9]*)$/.test(e))throw new iP({value:e});let[n,s="0"]=e.split(".");const r=n.startsWith("-");if(r&&(n=n.slice(1)),s=s.replace(/(0+)$/,""),t===0)Math.round(+`.${s}`)===1&&(n=`${BigInt(n)+1n}`),s="";else if(s.length>t){const[o,i,a]=[s.slice(0,t-1),s.slice(t-1,t),s.slice(t)],c=Math.round(+`${i}.${a}`);c>9?s=`${BigInt(o)+BigInt(1)}0`.padStart(o.length+1,"0"):s=`${o}${c}`,s.length>t&&(s=s.slice(1),n=`${BigInt(n)+1n}`),s=s.slice(0,t)}else s=s.padEnd(t,"0");return BigInt(`${r?"-":""}${n}${s}`)}function cP(e){return e.map(t=>({...t,value:BigInt(t.value)}))}function uP(e){return{...e,balance:e.balance?BigInt(e.balance):void 0,nonce:e.nonce?hs(e.nonce):void 0,storageProof:e.storageProof?cP(e.storageProof):void 0}}async function lP(e,{address:t,blockNumber:n,blockTag:s,storageKeys:r}){const o=s??"latest",i=n!==void 0?Ee(n):void 0,a=await e.request({method:"eth_getProof",params:[t,r,i||o]});return uP(a)}async function H2(e,{confirmations:t=1,hash:n,onReplaced:s,pollingInterval:r=e.pollingInterval,retryCount:o=6,retryDelay:i=({count:c})=>~~(1<<c)*200,timeout:a=18e4}){const c=Bt(["waitForTransactionReceipt",e.uid,n]);let u,l,d,f=!1;const{promise:p,resolve:m,reject:h}=S2(),y=a?setTimeout(()=>h(new sT({hash:n})),a):void 0,b=Vr(c,{onReplaced:s,resolve:m,reject:h},g=>{const w=xe(e,F2,"watchBlockNumber")({emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:r,async onBlockNumber(_){const A=C=>{clearTimeout(y),w(),C(),b()};let x=_;if(!f)try{if(d){if(t>1&&(!d.blockNumber||x-d.blockNumber+1n<t))return;A(()=>g.resolve(d));return}if(u||(f=!0,await sc(async()=>{u=await xe(e,Il,"getTransaction")({hash:n}),u.blockNumber&&(x=u.blockNumber)},{delay:i,retryCount:o}),f=!1),d=await xe(e,ep,"getTransactionReceipt")({hash:n}),t>1&&(!d.blockNumber||x-d.blockNumber+1n<t))return;A(()=>g.resolve(d))}catch(C){if(C instanceof zw||C instanceof qw){if(!u){f=!1;return}try{l=u,f=!0;const k=await sc(()=>xe(e,Us,"getBlock")({blockNumber:x,includeTransactions:!0}),{delay:i,retryCount:o,shouldRetry:({error:B})=>B instanceof Gw});f=!1;const S=k.transactions.find(({from:B,nonce:L})=>B===l.from&&L===l.nonce);if(!S||(d=await xe(e,ep,"getTransactionReceipt")({hash:S.hash}),t>1&&(!d.blockNumber||x-d.blockNumber+1n<t)))return;let R="replaced";S.to===l.to&&S.value===l.value?R="repriced":S.from===S.to&&S.value===0n&&(R="cancelled"),A(()=>{var B;(B=g.onReplaced)==null||B.call(g,{reason:R,replacedTransaction:l,transaction:S,transactionReceipt:d}),g.resolve(d)})}catch(k){A(()=>g.reject(k))}}else A(()=>g.reject(C))}}})});return p}async function uh(e,t){const{abi:n,address:s,args:r,dataSuffix:o,functionName:i,...a}=t,c=a.account?Xn(a.account):e.account,u=tr({abi:n,args:r,functionName:i});try{const{data:l}=await xe(e,kc,"call")({batch:!1,data:`${u}${o?o.replace("0x",""):""}`,to:s,...a,account:c}),d=na({abi:n,args:r,functionName:i,data:l||"0x"}),f=n.filter(p=>"name"in p&&p.name===t.functionName);return{result:d,request:{abi:f,address:s,args:r,dataSuffix:o,functionName:i,...a,account:c}}}catch(l){throw Fi(l,{abi:n,address:s,args:r,docsPath:"/docs/contract/simulateContract",functionName:i,sender:c==null?void 0:c.address})}}class z2 extends Rm{constructor(t,n){super(),this.finished=!1,this.destroyed=!1,a8(t);const s=_l(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 r=this.blockLen,o=new Uint8Array(r);o.set(s.length>r?t.create().update(s).digest():s);for(let i=0;i<o.length;i++)o[i]^=54;this.iHash.update(o),this.oHash=t.create();for(let i=0;i<o.length;i++)o[i]^=106;this.oHash.update(o),o.fill(0)}update(t){return Ri(this),this.iHash.update(t),this}digestInto(t){Ri(this),Ec(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:s,finished:r,destroyed:o,blockLen:i,outputLen:a}=this;return t=t,t.finished=r,t.destroyed=o,t.blockLen=i,t.outputLen=a,t.oHash=n._cloneInto(t.oHash),t.iHash=s._cloneInto(t.iHash),t}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}}const q2=(e,t,n)=>new z2(e,t).update(n).digest();q2.create=(e,t)=>new z2(e,t);/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const lh=BigInt(0),Ml=BigInt(1),dP=BigInt(2);function Po(e){return e instanceof Uint8Array||e!=null&&typeof e=="object"&&e.constructor.name==="Uint8Array"}function Mc(e){if(!Po(e))throw new Error("Uint8Array expected")}function Ni(e,t){if(typeof t!="boolean")throw new Error(`${e} must be valid boolean, got "${t}".`)}const fP=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function Bi(e){Mc(e);let t="";for(let n=0;n<e.length;n++)t+=fP[e[n]];return t}function ei(e){const t=e.toString(16);return t.length&1?`0${t}`:t}function dh(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);return BigInt(e===""?"0":`0x${e}`)}const xs={_0:48,_9:57,_A:65,_F:70,_a:97,_f:102};function W0(e){if(e>=xs._0&&e<=xs._9)return e-xs._0;if(e>=xs._A&&e<=xs._F)return e-(xs._A-10);if(e>=xs._a&&e<=xs._f)return e-(xs._a-10)}function Di(e){if(typeof e!="string")throw new Error("hex string expected, got "+typeof e);const t=e.length,n=t/2;if(t%2)throw new Error("padded hex string expected, got unpadded hex of length "+t);const s=new Uint8Array(n);for(let r=0,o=0;r<n;r++,o+=2){const i=W0(e.charCodeAt(o)),a=W0(e.charCodeAt(o+1));if(i===void 0||a===void 0){const c=e[o]+e[o+1];throw new Error('hex string expected, got non-hex character "'+c+'" at index '+o)}s[r]=i*16+a}return s}function vo(e){return dh(Bi(e))}function fh(e){return Mc(e),dh(Bi(Uint8Array.from(e).reverse()))}function Ui(e,t){return Di(e.toString(16).padStart(t*2,"0"))}function ph(e,t){return Ui(e,t).reverse()}function pP(e){return Di(ei(e))}function Rn(e,t,n){let s;if(typeof t=="string")try{s=Di(t)}catch(o){throw new Error(`${e} must be valid hex string, got "${t}". Cause: ${o}`)}else if(Po(t))s=Uint8Array.from(t);else throw new Error(`${e} must be hex string or Uint8Array`);const r=s.length;if(typeof n=="number"&&r!==n)throw new Error(`${e} expected ${n} bytes, got ${r}`);return s}function rc(...e){let t=0;for(let s=0;s<e.length;s++){const r=e[s];Mc(r),t+=r.length}const n=new Uint8Array(t);for(let s=0,r=0;s<e.length;s++){const o=e[s];n.set(o,r),r+=o.length}return n}function mP(e,t){if(e.length!==t.length)return!1;let n=0;for(let s=0;s<e.length;s++)n|=e[s]^t[s];return n===0}function hP(e){if(typeof e!="string")throw new Error(`utf8ToBytes expected string, got ${typeof e}`);return new Uint8Array(new TextEncoder().encode(e))}const Kd=e=>typeof e=="bigint"&&lh<=e;function Ol(e,t,n){return Kd(e)&&Kd(t)&&Kd(n)&&t<=e&&e<n}function wo(e,t,n,s){if(!Ol(t,n,s))throw new Error(`expected valid ${e}: ${n} <= n < ${s}, got ${typeof t} ${t}`)}function W2(e){let t;for(t=0;e>lh;e>>=Ml,t+=1);return t}function yP(e,t){return e>>BigInt(t)&Ml}function bP(e,t,n){return e|(n?Ml:lh)<<BigInt(t)}const mh=e=>(dP<<BigInt(e-1))-Ml,Qd=e=>new Uint8Array(e),G0=e=>Uint8Array.from(e);function G2(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 s=Qd(e),r=Qd(e),o=0;const i=()=>{s.fill(1),r.fill(0),o=0},a=(...d)=>n(r,s,...d),c=(d=Qd())=>{r=a(G0([0]),d),s=a(),d.length!==0&&(r=a(G0([1]),d),s=a())},u=()=>{if(o++>=1e3)throw new Error("drbg: tried 1000 values");let d=0;const f=[];for(;d<t;){s=a();const p=s.slice();f.push(p),d+=s.length}return rc(...f)};return(d,f)=>{i(),c(d);let p;for(;!(p=f(u()));)c();return i(),p}}const gP={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"||Po(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 Oc(e,t,n={}){const s=(r,o,i)=>{const a=gP[o];if(typeof a!="function")throw new Error(`Invalid validator "${o}", expected function`);const c=e[r];if(!(i&&c===void 0)&&!a(c,e))throw new Error(`Invalid param ${String(r)}=${c} (${typeof c}), expected ${o}`)};for(const[r,o]of Object.entries(t))s(r,o,!1);for(const[r,o]of Object.entries(n))s(r,o,!0);return e}const vP=()=>{throw new Error("not implemented")};function tp(e){const t=new WeakMap;return(n,...s)=>{const r=t.get(n);if(r!==void 0)return r;const o=e(n,...s);return t.set(n,o),o}}const wP=Object.freeze(Object.defineProperty({__proto__:null,aInRange:wo,abool:Ni,abytes:Mc,bitGet:yP,bitLen:W2,bitMask:mh,bitSet:bP,bytesToHex:Bi,bytesToNumberBE:vo,bytesToNumberLE:fh,concatBytes:rc,createHmacDrbg:G2,ensureBytes:Rn,equalBytes:mP,hexToBytes:Di,hexToNumber:dh,inRange:Ol,isBytes:Po,memoized:tp,notImplemented:vP,numberToBytesBE:Ui,numberToBytesLE:ph,numberToHexUnpadded:ei,numberToVarBytesBE:pP,utf8ToBytes:hP,validateObject:Oc},Symbol.toStringTag,{value:"Module"}));/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const At=BigInt(0),ct=BigInt(1),ao=BigInt(2),_P=BigInt(3),np=BigInt(4),X0=BigInt(5),K0=BigInt(8);BigInt(9);BigInt(16);function Qt(e,t){const n=e%t;return n>=At?n:t+n}function xP(e,t,n){if(n<=At||t<At)throw new Error("Expected power/modulo > 0");if(n===ct)return At;let s=ct;for(;t>At;)t&ct&&(s=s*e%n),e=e*e%n,t>>=ct;return s}function bn(e,t,n){let s=e;for(;t-- >At;)s*=s,s%=n;return s}function sp(e,t){if(e===At||t<=At)throw new Error(`invert: expected positive integers, got n=${e} mod=${t}`);let n=Qt(e,t),s=t,r=At,o=ct;for(;n!==At;){const a=s/n,c=s%n,u=r-o*a;s=n,n=c,r=o,o=u}if(s!==ct)throw new Error("invert: does not exist");return Qt(r,t)}function CP(e){const t=(e-ct)/ao;let n,s,r;for(n=e-ct,s=0;n%ao===At;n/=ao,s++);for(r=ao;r<e&&xP(r,t,e)!==e-ct;r++);if(s===1){const i=(e+ct)/np;return function(c,u){const l=c.pow(u,i);if(!c.eql(c.sqr(l),u))throw new Error("Cannot find square root");return l}}const o=(n+ct)/ao;return function(a,c){if(a.pow(c,t)===a.neg(a.ONE))throw new Error("Cannot find square root");let u=s,l=a.pow(a.mul(a.ONE,r),n),d=a.pow(c,o),f=a.pow(c,n);for(;!a.eql(f,a.ONE);){if(a.eql(f,a.ZERO))return a.ZERO;let p=1;for(let h=a.sqr(f);p<u&&!a.eql(h,a.ONE);p++)h=a.sqr(h);const m=a.pow(l,ct<<BigInt(u-p-1));l=a.sqr(m),d=a.mul(d,m),f=a.mul(f,l),u=p}return d}}function AP(e){if(e%np===_P){const t=(e+ct)/np;return function(s,r){const o=s.pow(r,t);if(!s.eql(s.sqr(o),r))throw new Error("Cannot find square root");return o}}if(e%K0===X0){const t=(e-X0)/K0;return function(s,r){const o=s.mul(r,ao),i=s.pow(o,t),a=s.mul(r,i),c=s.mul(s.mul(a,ao),i),u=s.mul(a,s.sub(c,s.ONE));if(!s.eql(s.sqr(u),r))throw new Error("Cannot find square root");return u}}return CP(e)}const TP=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function EP(e){const t={ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"},n=TP.reduce((s,r)=>(s[r]="function",s),t);return Oc(e,n)}function SP(e,t,n){if(n<At)throw new Error("Expected power > 0");if(n===At)return e.ONE;if(n===ct)return t;let s=e.ONE,r=t;for(;n>At;)n&ct&&(s=e.mul(s,r)),r=e.sqr(r),n>>=ct;return s}function PP(e,t){const n=new Array(t.length),s=t.reduce((o,i,a)=>e.is0(i)?o:(n[a]=o,e.mul(o,i)),e.ONE),r=e.inv(s);return t.reduceRight((o,i,a)=>e.is0(i)?o:(n[a]=e.mul(o,n[a]),e.mul(o,i)),r),n}function X2(e,t){const n=t!==void 0?t:e.toString(2).length,s=Math.ceil(n/8);return{nBitLength:n,nByteLength:s}}function K2(e,t,n=!1,s={}){if(e<=At)throw new Error(`Expected Field ORDER > 0, got ${e}`);const{nBitLength:r,nByteLength:o}=X2(e,t);if(o>2048)throw new Error("Field lengths over 2048 bytes are not supported");const i=AP(e),a=Object.freeze({ORDER:e,BITS:r,BYTES:o,MASK:mh(r),ZERO:At,ONE:ct,create:c=>Qt(c,e),isValid:c=>{if(typeof c!="bigint")throw new Error(`Invalid field element: expected bigint, got ${typeof c}`);return At<=c&&c<e},is0:c=>c===At,isOdd:c=>(c&ct)===ct,neg:c=>Qt(-c,e),eql:(c,u)=>c===u,sqr:c=>Qt(c*c,e),add:(c,u)=>Qt(c+u,e),sub:(c,u)=>Qt(c-u,e),mul:(c,u)=>Qt(c*u,e),pow:(c,u)=>SP(a,c,u),div:(c,u)=>Qt(c*sp(u,e),e),sqrN:c=>c*c,addN:(c,u)=>c+u,subN:(c,u)=>c-u,mulN:(c,u)=>c*u,inv:c=>sp(c,e),sqrt:s.sqrt||(c=>i(a,c)),invertBatch:c=>PP(a,c),cmov:(c,u,l)=>l?u:c,toBytes:c=>n?ph(c,o):Ui(c,o),fromBytes:c=>{if(c.length!==o)throw new Error(`Fp.fromBytes: expected ${o}, got ${c.length}`);return n?fh(c):vo(c)}});return Object.freeze(a)}function Q2(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 Z2(e){const t=Q2(e);return t+Math.ceil(t/2)}function kP(e,t,n=!1){const s=e.length,r=Q2(t),o=Z2(t);if(s<16||s<o||s>1024)throw new Error(`expected ${o}-1024 bytes of input, got ${s}`);const i=n?vo(e):fh(e),a=Qt(i,t-ct)+ct;return n?ph(a,r):Ui(a,r)}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const IP=BigInt(0),Zd=BigInt(1),Yd=new WeakMap,Q0=new WeakMap;function RP(e,t){const n=(o,i)=>{const a=i.negate();return o?a:i},s=o=>{if(!Number.isSafeInteger(o)||o<=0||o>t)throw new Error(`Wrong window size=${o}, should be [1..${t}]`)},r=o=>{s(o);const i=Math.ceil(t/o)+1,a=2**(o-1);return{windows:i,windowSize:a}};return{constTimeNegate:n,unsafeLadder(o,i){let a=e.ZERO,c=o;for(;i>IP;)i&Zd&&(a=a.add(c)),c=c.double(),i>>=Zd;return a},precomputeWindow(o,i){const{windows:a,windowSize:c}=r(i),u=[];let l=o,d=l;for(let f=0;f<a;f++){d=l,u.push(d);for(let p=1;p<c;p++)d=d.add(l),u.push(d);l=d.double()}return u},wNAF(o,i,a){const{windows:c,windowSize:u}=r(o);let l=e.ZERO,d=e.BASE;const f=BigInt(2**o-1),p=2**o,m=BigInt(o);for(let h=0;h<c;h++){const y=h*u;let b=Number(a&f);a>>=m,b>u&&(b-=p,a+=Zd);const g=y,w=y+Math.abs(b)-1,_=h%2!==0,A=b<0;b===0?d=d.add(n(_,i[g])):l=l.add(n(A,i[w]))}return{p:l,f:d}},wNAFCached(o,i,a){const c=Q0.get(o)||1;let u=Yd.get(o);return u||(u=this.precomputeWindow(o,c),c!==1&&Yd.set(o,a(u))),this.wNAF(c,u,i)},setWindowSize(o,i){s(i),Q0.set(o,i),Yd.delete(o)}}}function $P(e,t,n,s){if(!Array.isArray(n)||!Array.isArray(s)||s.length!==n.length)throw new Error("arrays of points and scalars must have equal length");s.forEach((l,d)=>{if(!t.isValid(l))throw new Error(`wrong scalar at index ${d}`)}),n.forEach((l,d)=>{if(!(l instanceof e))throw new Error(`wrong point at index ${d}`)});const r=W2(BigInt(n.length)),o=r>12?r-3:r>4?r-2:r?2:1,i=(1<<o)-1,a=new Array(i+1).fill(e.ZERO),c=Math.floor((t.BITS-1)/o)*o;let u=e.ZERO;for(let l=c;l>=0;l-=o){a.fill(e.ZERO);for(let f=0;f<s.length;f++){const p=s[f],m=Number(p>>BigInt(l)&BigInt(i));a[m]=a[m].add(n[f])}let d=e.ZERO;for(let f=a.length-1,p=e.ZERO;f>0;f--)p=p.add(a[f]),d=d.add(p);if(u=u.add(d),l!==0)for(let f=0;f<o;f++)u=u.double()}return u}function Y2(e){return EP(e.Fp),Oc(e,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...X2(e.n,e.nBitLength),...e,p:e.Fp.ORDER})}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */function Z0(e){e.lowS!==void 0&&Ni("lowS",e.lowS),e.prehash!==void 0&&Ni("prehash",e.prehash)}function MP(e){const t=Y2(e);Oc(t,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:n,Fp:s,a:r}=t;if(n){if(!s.eql(r,s.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if(typeof n!="object"||typeof n.beta!="bigint"||typeof n.splitScalar!="function")throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...t})}const{bytesToNumberBE:OP,hexToBytes:LP}=wP,Ps={Err:class extends Error{constructor(t=""){super(t)}},_tlv:{encode:(e,t)=>{const{Err:n}=Ps;if(e<0||e>256)throw new n("tlv.encode: wrong tag");if(t.length&1)throw new n("tlv.encode: unpadded data");const s=t.length/2,r=ei(s);if(r.length/2&128)throw new n("tlv.encode: long form length too big");const o=s>127?ei(r.length/2|128):"";return`${ei(e)}${o}${r}${t}`},decode(e,t){const{Err:n}=Ps;let s=0;if(e<0||e>256)throw new n("tlv.encode: wrong tag");if(t.length<2||t[s++]!==e)throw new n("tlv.decode: wrong tlv");const r=t[s++],o=!!(r&128);let i=0;if(!o)i=r;else{const c=r&127;if(!c)throw new n("tlv.decode(long): indefinite length not supported");if(c>4)throw new n("tlv.decode(long): byte length is too big");const u=t.subarray(s,s+c);if(u.length!==c)throw new n("tlv.decode: length bytes not complete");if(u[0]===0)throw new n("tlv.decode(long): zero leftmost byte");for(const l of u)i=i<<8|l;if(s+=c,i<128)throw new n("tlv.decode(long): not minimal encoding")}const a=t.subarray(s,s+i);if(a.length!==i)throw new n("tlv.decode: wrong value length");return{v:a,l:t.subarray(s+i)}}},_int:{encode(e){const{Err:t}=Ps;if(e<Ms)throw new t("integer: negative integers are not allowed");let n=ei(e);if(Number.parseInt(n[0],16)&8&&(n="00"+n),n.length&1)throw new t("unexpected assertion");return n},decode(e){const{Err:t}=Ps;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 OP(e)}},toSig(e){const{Err:t,_int:n,_tlv:s}=Ps,r=typeof e=="string"?LP(e):e;Mc(r);const{v:o,l:i}=s.decode(48,r);if(i.length)throw new t("Invalid signature: left bytes after parsing");const{v:a,l:c}=s.decode(2,o),{v:u,l}=s.decode(2,c);if(l.length)throw new t("Invalid signature: left bytes after parsing");return{r:n.decode(a),s:n.decode(u)}},hexFromSig(e){const{_tlv:t,_int:n}=Ps,s=`${t.encode(2,n.encode(e.r))}${t.encode(2,n.encode(e.s))}`;return t.encode(48,s)}},Ms=BigInt(0),xt=BigInt(1);BigInt(2);const Y0=BigInt(3);BigInt(4);function FP(e){const t=MP(e),{Fp:n}=t,s=K2(t.n,t.nBitLength),r=t.toBytes||((h,y,b)=>{const g=y.toAffine();return rc(Uint8Array.from([4]),n.toBytes(g.x),n.toBytes(g.y))}),o=t.fromBytes||(h=>{const y=h.subarray(1),b=n.fromBytes(y.subarray(0,n.BYTES)),g=n.fromBytes(y.subarray(n.BYTES,2*n.BYTES));return{x:b,y:g}});function i(h){const{a:y,b}=t,g=n.sqr(h),w=n.mul(g,h);return n.add(n.add(w,n.mul(h,y)),b)}if(!n.eql(n.sqr(t.Gy),i(t.Gx)))throw new Error("bad generator point: equation left != right");function a(h){return Ol(h,xt,t.n)}function c(h){const{allowedPrivateKeyLengths:y,nByteLength:b,wrapPrivateKey:g,n:w}=t;if(y&&typeof h!="bigint"){if(Po(h)&&(h=Bi(h)),typeof h!="string"||!y.includes(h.length))throw new Error("Invalid key");h=h.padStart(b*2,"0")}let _;try{_=typeof h=="bigint"?h:vo(Rn("private key",h,b))}catch{throw new Error(`private key must be ${b} bytes, hex or bigint, not ${typeof h}`)}return g&&(_=Qt(_,w)),wo("private key",_,xt,w),_}function u(h){if(!(h instanceof f))throw new Error("ProjectivePoint expected")}const l=tp((h,y)=>{const{px:b,py:g,pz:w}=h;if(n.eql(w,n.ONE))return{x:b,y:g};const _=h.is0();y==null&&(y=_?n.ONE:n.inv(w));const A=n.mul(b,y),x=n.mul(g,y),C=n.mul(w,y);if(_)return{x:n.ZERO,y:n.ZERO};if(!n.eql(C,n.ONE))throw new Error("invZ was invalid");return{x:A,y:x}}),d=tp(h=>{if(h.is0()){if(t.allowInfinityPoint&&!n.is0(h.py))return;throw new Error("bad point: ZERO")}const{x:y,y:b}=h.toAffine();if(!n.isValid(y)||!n.isValid(b))throw new Error("bad point: x or y not FE");const g=n.sqr(b),w=i(y);if(!n.eql(g,w))throw new Error("bad point: equation left != right");if(!h.isTorsionFree())throw new Error("bad point: not in prime-order subgroup");return!0});class f{constructor(y,b,g){if(this.px=y,this.py=b,this.pz=g,y==null||!n.isValid(y))throw new Error("x required");if(b==null||!n.isValid(b))throw new Error("y required");if(g==null||!n.isValid(g))throw new Error("z required");Object.freeze(this)}static fromAffine(y){const{x:b,y:g}=y||{};if(!y||!n.isValid(b)||!n.isValid(g))throw new Error("invalid affine point");if(y instanceof f)throw new Error("projective point not allowed");const w=_=>n.eql(_,n.ZERO);return w(b)&&w(g)?f.ZERO:new f(b,g,n.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(y){const b=n.invertBatch(y.map(g=>g.pz));return y.map((g,w)=>g.toAffine(b[w])).map(f.fromAffine)}static fromHex(y){const b=f.fromAffine(o(Rn("pointHex",y)));return b.assertValidity(),b}static fromPrivateKey(y){return f.BASE.multiply(c(y))}static msm(y,b){return $P(f,s,y,b)}_setWindowSize(y){m.setWindowSize(this,y)}assertValidity(){d(this)}hasEvenY(){const{y}=this.toAffine();if(n.isOdd)return!n.isOdd(y);throw new Error("Field doesn't support isOdd")}equals(y){u(y);const{px:b,py:g,pz:w}=this,{px:_,py:A,pz:x}=y,C=n.eql(n.mul(b,x),n.mul(_,w)),k=n.eql(n.mul(g,x),n.mul(A,w));return C&&k}negate(){return new f(this.px,n.neg(this.py),this.pz)}double(){const{a:y,b}=t,g=n.mul(b,Y0),{px:w,py:_,pz:A}=this;let x=n.ZERO,C=n.ZERO,k=n.ZERO,S=n.mul(w,w),R=n.mul(_,_),B=n.mul(A,A),L=n.mul(w,_);return L=n.add(L,L),k=n.mul(w,A),k=n.add(k,k),x=n.mul(y,k),C=n.mul(g,B),C=n.add(x,C),x=n.sub(R,C),C=n.add(R,C),C=n.mul(x,C),x=n.mul(L,x),k=n.mul(g,k),B=n.mul(y,B),L=n.sub(S,B),L=n.mul(y,L),L=n.add(L,k),k=n.add(S,S),S=n.add(k,S),S=n.add(S,B),S=n.mul(S,L),C=n.add(C,S),B=n.mul(_,A),B=n.add(B,B),S=n.mul(B,L),x=n.sub(x,S),k=n.mul(B,R),k=n.add(k,k),k=n.add(k,k),new f(x,C,k)}add(y){u(y);const{px:b,py:g,pz:w}=this,{px:_,py:A,pz:x}=y;let C=n.ZERO,k=n.ZERO,S=n.ZERO;const R=t.a,B=n.mul(t.b,Y0);let L=n.mul(b,_),X=n.mul(g,A),z=n.mul(w,x),ie=n.add(b,g),ne=n.add(_,A);ie=n.mul(ie,ne),ne=n.add(L,X),ie=n.sub(ie,ne),ne=n.add(b,w);let te=n.add(_,x);return ne=n.mul(ne,te),te=n.add(L,z),ne=n.sub(ne,te),te=n.add(g,w),C=n.add(A,x),te=n.mul(te,C),C=n.add(X,z),te=n.sub(te,C),S=n.mul(R,ne),C=n.mul(B,z),S=n.add(C,S),C=n.sub(X,S),S=n.add(X,S),k=n.mul(C,S),X=n.add(L,L),X=n.add(X,L),z=n.mul(R,z),ne=n.mul(B,ne),X=n.add(X,z),z=n.sub(L,z),z=n.mul(R,z),ne=n.add(ne,z),L=n.mul(X,ne),k=n.add(k,L),L=n.mul(te,ne),C=n.mul(ie,C),C=n.sub(C,L),L=n.mul(ie,X),S=n.mul(te,S),S=n.add(S,L),new f(C,k,S)}subtract(y){return this.add(y.negate())}is0(){return this.equals(f.ZERO)}wNAF(y){return m.wNAFCached(this,y,f.normalizeZ)}multiplyUnsafe(y){wo("scalar",y,Ms,t.n);const b=f.ZERO;if(y===Ms)return b;if(y===xt)return this;const{endo:g}=t;if(!g)return m.unsafeLadder(this,y);let{k1neg:w,k1:_,k2neg:A,k2:x}=g.splitScalar(y),C=b,k=b,S=this;for(;_>Ms||x>Ms;)_&xt&&(C=C.add(S)),x&xt&&(k=k.add(S)),S=S.double(),_>>=xt,x>>=xt;return w&&(C=C.negate()),A&&(k=k.negate()),k=new f(n.mul(k.px,g.beta),k.py,k.pz),C.add(k)}multiply(y){const{endo:b,n:g}=t;wo("scalar",y,xt,g);let w,_;if(b){const{k1neg:A,k1:x,k2neg:C,k2:k}=b.splitScalar(y);let{p:S,f:R}=this.wNAF(x),{p:B,f:L}=this.wNAF(k);S=m.constTimeNegate(A,S),B=m.constTimeNegate(C,B),B=new f(n.mul(B.px,b.beta),B.py,B.pz),w=S.add(B),_=R.add(L)}else{const{p:A,f:x}=this.wNAF(y);w=A,_=x}return f.normalizeZ([w,_])[0]}multiplyAndAddUnsafe(y,b,g){const w=f.BASE,_=(x,C)=>C===Ms||C===xt||!x.equals(w)?x.multiplyUnsafe(C):x.multiply(C),A=_(this,b).add(_(y,g));return A.is0()?void 0:A}toAffine(y){return l(this,y)}isTorsionFree(){const{h:y,isTorsionFree:b}=t;if(y===xt)return!0;if(b)return b(f,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:y,clearCofactor:b}=t;return y===xt?this:b?b(f,this):this.multiplyUnsafe(t.h)}toRawBytes(y=!0){return Ni("isCompressed",y),this.assertValidity(),r(f,this,y)}toHex(y=!0){return Ni("isCompressed",y),Bi(this.toRawBytes(y))}}f.BASE=new f(t.Gx,t.Gy,n.ONE),f.ZERO=new f(n.ZERO,n.ONE,n.ZERO);const p=t.nBitLength,m=RP(f,t.endo?Math.ceil(p/2):p);return{CURVE:t,ProjectivePoint:f,normPrivateKeyToScalar:c,weierstrassEquation:i,isWithinCurveOrder:a}}function NP(e){const t=Y2(e);return Oc(t,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...t})}function BP(e){const t=NP(e),{Fp:n,n:s}=t,r=n.BYTES+1,o=2*n.BYTES+1;function i(z){return Qt(z,s)}function a(z){return sp(z,s)}const{ProjectivePoint:c,normPrivateKeyToScalar:u,weierstrassEquation:l,isWithinCurveOrder:d}=FP({...t,toBytes(z,ie,ne){const te=ie.toAffine(),ce=n.toBytes(te.x),he=rc;return Ni("isCompressed",ne),ne?he(Uint8Array.from([ie.hasEvenY()?2:3]),ce):he(Uint8Array.from([4]),ce,n.toBytes(te.y))},fromBytes(z){const ie=z.length,ne=z[0],te=z.subarray(1);if(ie===r&&(ne===2||ne===3)){const ce=vo(te);if(!Ol(ce,xt,n.ORDER))throw new Error("Point is not on curve");const he=l(ce);let _e;try{_e=n.sqrt(he)}catch(qe){const Ye=qe instanceof Error?": "+qe.message:"";throw new Error("Point is not on curve"+Ye)}const Fe=(_e&xt)===xt;return(ne&1)===1!==Fe&&(_e=n.neg(_e)),{x:ce,y:_e}}else if(ie===o&&ne===4){const ce=n.fromBytes(te.subarray(0,n.BYTES)),he=n.fromBytes(te.subarray(n.BYTES,2*n.BYTES));return{x:ce,y:he}}else throw new Error(`Point of length ${ie} was invalid. Expected ${r} compressed bytes or ${o} uncompressed bytes`)}}),f=z=>Bi(Ui(z,t.nByteLength));function p(z){const ie=s>>xt;return z>ie}function m(z){return p(z)?i(-z):z}const h=(z,ie,ne)=>vo(z.slice(ie,ne));class y{constructor(ie,ne,te){this.r=ie,this.s=ne,this.recovery=te,this.assertValidity()}static fromCompact(ie){const ne=t.nByteLength;return ie=Rn("compactSignature",ie,ne*2),new y(h(ie,0,ne),h(ie,ne,2*ne))}static fromDER(ie){const{r:ne,s:te}=Ps.toSig(Rn("DER",ie));return new y(ne,te)}assertValidity(){wo("r",this.r,xt,s),wo("s",this.s,xt,s)}addRecoveryBit(ie){return new y(this.r,this.s,ie)}recoverPublicKey(ie){const{r:ne,s:te,recovery:ce}=this,he=x(Rn("msgHash",ie));if(ce==null||![0,1,2,3].includes(ce))throw new Error("recovery id invalid");const _e=ce===2||ce===3?ne+t.n:ne;if(_e>=n.ORDER)throw new Error("recovery id 2 or 3 invalid");const Fe=ce&1?"03":"02",Ae=c.fromHex(Fe+f(_e)),qe=a(_e),Ye=i(-he*qe),mt=i(te*qe),Xe=c.BASE.multiplyAndAddUnsafe(Ae,Ye,mt);if(!Xe)throw new Error("point at infinify");return Xe.assertValidity(),Xe}hasHighS(){return p(this.s)}normalizeS(){return this.hasHighS()?new y(this.r,i(-this.s),this.recovery):this}toDERRawBytes(){return Di(this.toDERHex())}toDERHex(){return Ps.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return Di(this.toCompactHex())}toCompactHex(){return f(this.r)+f(this.s)}}const b={isValidPrivateKey(z){try{return u(z),!0}catch{return!1}},normPrivateKeyToScalar:u,randomPrivateKey:()=>{const z=Z2(t.n);return kP(t.randomBytes(z),t.n)},precompute(z=8,ie=c.BASE){return ie._setWindowSize(z),ie.multiply(BigInt(3)),ie}};function g(z,ie=!0){return c.fromPrivateKey(z).toRawBytes(ie)}function w(z){const ie=Po(z),ne=typeof z=="string",te=(ie||ne)&&z.length;return ie?te===r||te===o:ne?te===2*r||te===2*o:z instanceof c}function _(z,ie,ne=!0){if(w(z))throw new Error("first arg must be private key");if(!w(ie))throw new Error("second arg must be public key");return c.fromHex(ie).multiply(u(z)).toRawBytes(ne)}const A=t.bits2int||function(z){const ie=vo(z),ne=z.length*8-t.nBitLength;return ne>0?ie>>BigInt(ne):ie},x=t.bits2int_modN||function(z){return i(A(z))},C=mh(t.nBitLength);function k(z){return wo(`num < 2^${t.nBitLength}`,z,Ms,C),Ui(z,t.nByteLength)}function S(z,ie,ne=R){if(["recovered","canonical"].some(V=>V in ne))throw new Error("sign() legacy options not supported");const{hash:te,randomBytes:ce}=t;let{lowS:he,prehash:_e,extraEntropy:Fe}=ne;he==null&&(he=!0),z=Rn("msgHash",z),Z0(ne),_e&&(z=Rn("prehashed msgHash",te(z)));const Ae=x(z),qe=u(ie),Ye=[k(qe),k(Ae)];if(Fe!=null&&Fe!==!1){const V=Fe===!0?ce(n.BYTES):Fe;Ye.push(Rn("extraEntropy",V))}const mt=rc(...Ye),Xe=Ae;function se(V){const j=A(V);if(!d(j))return;const U=a(j),oe=c.BASE.multiply(j).toAffine(),be=i(oe.x);if(be===Ms)return;const P=i(U*i(Xe+be*qe));if(P===Ms)return;let O=(oe.x===be?0:2)|Number(oe.y&xt),q=P;return he&&p(P)&&(q=m(P),O^=1),new y(be,q,O)}return{seed:mt,k2sig:se}}const R={lowS:t.lowS,prehash:!1},B={lowS:t.lowS,prehash:!1};function L(z,ie,ne=R){const{seed:te,k2sig:ce}=S(z,ie,ne),he=t;return G2(he.hash.outputLen,he.nByteLength,he.hmac)(te,ce)}c.BASE._setWindowSize(8);function X(z,ie,ne,te=B){var oe;const ce=z;if(ie=Rn("msgHash",ie),ne=Rn("publicKey",ne),"strict"in te)throw new Error("options.strict was renamed to lowS");Z0(te);const{lowS:he,prehash:_e}=te;let Fe,Ae;try{if(typeof ce=="string"||Po(ce))try{Fe=y.fromDER(ce)}catch(be){if(!(be instanceof Ps.Err))throw be;Fe=y.fromCompact(ce)}else if(typeof ce=="object"&&typeof ce.r=="bigint"&&typeof ce.s=="bigint"){const{r:be,s:P}=ce;Fe=new y(be,P)}else throw new Error("PARSE");Ae=c.fromHex(ne)}catch(be){if(be.message==="PARSE")throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(he&&Fe.hasHighS())return!1;_e&&(ie=t.hash(ie));const{r:qe,s:Ye}=Fe,mt=x(ie),Xe=a(Ye),se=i(mt*Xe),V=i(qe*Xe),j=(oe=c.BASE.multiplyAndAddUnsafe(Ae,se,V))==null?void 0:oe.toAffine();return j?i(j.x)===qe:!1}return{CURVE:t,getPublicKey:g,getSharedSecret:_,sign:L,verify:X,ProjectivePoint:c,Signature:y,utils:b}}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */function DP(e){return{hash:e,hmac:(t,...n)=>q2(e,t,b8(...n)),randomBytes:g8}}function UP(e,t){const n=s=>BP({...e,...DP(s)});return Object.freeze({...n(t),create:n})}/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const J2=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),J0=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),VP=BigInt(1),rp=BigInt(2),eb=(e,t)=>(e+t/rp)/t;function jP(e){const t=J2,n=BigInt(3),s=BigInt(6),r=BigInt(11),o=BigInt(22),i=BigInt(23),a=BigInt(44),c=BigInt(88),u=e*e*e%t,l=u*u*e%t,d=bn(l,n,t)*l%t,f=bn(d,n,t)*l%t,p=bn(f,rp,t)*u%t,m=bn(p,r,t)*p%t,h=bn(m,o,t)*m%t,y=bn(h,a,t)*h%t,b=bn(y,c,t)*y%t,g=bn(b,a,t)*h%t,w=bn(g,n,t)*l%t,_=bn(w,i,t)*m%t,A=bn(_,s,t)*u%t,x=bn(A,rp,t);if(!op.eql(op.sqr(x),e))throw new Error("Cannot find square root");return x}const op=K2(J2,void 0,void 0,{sqrt:jP}),hh=UP({a:BigInt(0),b:BigInt(7),Fp:op,n:J0,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:e=>{const t=J0,n=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),s=-VP*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),r=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),o=n,i=BigInt("0x100000000000000000000000000000000"),a=eb(o*e,t),c=eb(-s*e,t);let u=Qt(e-a*n-c*r,t),l=Qt(-a*s-c*o,t);const d=u>i,f=l>i;if(d&&(u=t-u),f&&(l=t-l),u>i||l>i)throw new Error("splitScalar: Endomorphism failed, k="+e);return{k1neg:d,k1:u,k2neg:f,k2:l}}}},n2);BigInt(0);hh.ProjectivePoint;const HP=Object.freeze(Object.defineProperty({__proto__:null,secp256k1:hh},Symbol.toStringTag,{value:"Module"}));function zP({r:e,s:t,to:n="hex",v:s,yParity:r}){const o=(()=>{if(r===0||r===1)return r;if(s&&(s===27n||s===28n||s>=35n))return s%2n===0n?1:0;throw new Error("Invalid `v` or `yParity` value")})(),i=`0x${new hh.Signature(Nr(e),Nr(t)).toCompactHex()}${o===0?"1b":"1c"}`;return n==="hex"?i:Pn(i)}async function yh(e,t){var d,f,p;const{address:n,factory:s,factoryData:r,hash:o,signature:i,universalSignatureVerifierAddress:a=(p=(f=(d=e.chain)==null?void 0:d.contracts)==null?void 0:f.universalSignatureVerifier)==null?void 0:p.address,...c}=t,u=ms(i)?i:typeof i=="object"&&"r"in i&&"s"in i?zP(i):wt(i),l=await(async()=>!s&&!r||rP(u)?u:oP({address:s,data:r,signature:u}))();try{const m=a?{to:a,data:tr({abi:L0,functionName:"isValidSig",args:[n,o,l]}),...c}:{data:Fm({abi:L0,args:[n,o,l],bytecode:WE}),...c},{data:h}=await xe(e,kc,"call")(m);return HA(h??"0x0")}catch(m){try{if(rh(Cn(n),await Bw({hash:o,signature:i})))return!0}catch{}if(m instanceof T2)return!1;throw m}}async function qP(e,{address:t,message:n,factory:s,factoryData:r,signature:o,...i}){const a=V2(n);return yh(e,{address:t,factory:s,factoryData:r,hash:a,signature:o,...i})}async function WP(e,t){const{address:n,factory:s,factoryData:r,signature:o,message:i,primaryType:a,types:c,domain:u,...l}=t,d=KS({message:i,primaryType:a,types:c,domain:u});return yh(e,{address:n,factory:s,factoryData:r,hash:d,signature:o,...l})}function e_(e,t){const{abi:n,address:s,args:r,batch:o=!0,eventName:i,fromBlock:a,onError:c,onLogs:u,poll:l,pollingInterval:d=e.pollingInterval,strict:f}=t;return(typeof l<"u"?l:typeof a=="bigint"?!0:!(e.transport.type==="webSocket"||e.transport.type==="fallback"&&e.transport.transports[0].config.type==="webSocket"))?(()=>{const y=f??!1,b=Bt(["watchContractEvent",s,r,o,e.uid,i,d,y,a]);return Vr(b,{onLogs:u,onError:c},g=>{let w;a!==void 0&&(w=a-1n);let _,A=!1;const x=$c(async()=>{var C;if(!A){try{_=await xe(e,sh,"createContractEventFilter")({abi:n,address:s,args:r,eventName:i,strict:y,fromBlock:a})}catch{}A=!0;return}try{let k;if(_)k=await xe(e,kl,"getFilterChanges")({filter:_});else{const S=await xe(e,Rc,"getBlockNumber")({});w&&w<S?k=await xe(e,ch,"getContractEvents")({abi:n,address:s,args:r,eventName:i,fromBlock:w+1n,toBlock:S,strict:y}):k=[],w=S}if(k.length===0)return;if(o)g.onLogs(k);else for(const S of k)g.onLogs([S])}catch(k){_&&k instanceof Eo&&(A=!1),(C=g.onError)==null||C.call(g,k)}},{emitOnBegin:!0,interval:d});return async()=>{_&&await xe(e,Rl,"uninstallFilter")({filter:_}),x()}})})():(()=>{const y=f??!1,b=Bt(["watchContractEvent",s,r,o,e.uid,i,d,y]);let g=!0,w=()=>g=!1;return Vr(b,{onLogs:u,onError:c},_=>((async()=>{try{const A=(()=>{if(e.transport.type==="fallback"){const k=e.transport.transports.find(S=>S.config.type==="webSocket");return k?k.value:e.transport}return e.transport})(),x=i?Ic({abi:n,eventName:i,args:r}):[],{unsubscribe:C}=await A.subscribe({params:["logs",{address:s,topics:x}],onData(k){var R;if(!g)return;const S=k.result;try{const{eventName:B,args:L}=oh({abi:n,data:S.data,topics:S.topics,strict:f}),X=Ur(S,{args:L,eventName:B});_.onLogs([X])}catch(B){let L,X;if(B instanceof Wa||B instanceof vl){if(f)return;L=B.abiItem.name,X=(R=B.abiItem.inputs)==null?void 0:R.some(ie=>!("name"in ie&&ie.name))}const z=Ur(S,{args:X?[]:{},eventName:L});_.onLogs([z])}},onError(k){var S;(S=_.onError)==null||S.call(_,k)}});w=C,g||w()}catch(A){c==null||c(A)}})(),()=>w()))})()}async function t_(e,t){const{abi:n,account:s=e.account,address:r,args:o,dataSuffix:i,functionName:a,...c}=t;if(typeof s>"u")throw new Nw({docsPath:"/docs/contract/writeContract"});const u=s?Xn(s):null,l=tr({abi:n,args:o,functionName:a});try{return await xe(e,LT,"sendTransaction")({data:`${l}${i?i.replace("0x",""):""}`,to:r,account:u,...c})}catch(d){throw Fi(d,{abi:n,address:r,args:o,docsPath:"/docs/contract/writeContract",functionName:a,sender:u==null?void 0:u.address})}}function Rr(e,t,n){const s=e[t.name];if(typeof s=="function")return s;const r=e[n];return typeof r=="function"?r:o=>t(e,o)}const _u="2.14.1",GP=()=>`@wagmi/core@${_u}`;var n_=function(e,t,n,s){if(n==="a"&&!s)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!s:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?s:n==="a"?s.call(e):s?s.value:t.get(e)},Wu,s_;let nr=class ip extends Error{get docsBaseUrl(){return"https://wagmi.sh/core"}get version(){return GP()}constructor(t,n={}){var o;super(),Wu.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 s=n.cause instanceof ip?n.cause.details:(o=n.cause)!=null&&o.message?n.cause.message:n.details,r=n.cause instanceof ip&&n.cause.docsPath||n.docsPath;this.message=[t||"An error occurred.","",...n.metaMessages?[...n.metaMessages,""]:[],...r?[`Docs: ${this.docsBaseUrl}${r}.html${n.docsSlug?`#${n.docsSlug}`:""}`]:[],...s?[`Details: ${s}`]:[],`Version: ${this.version}`].join(`
`),n.cause&&(this.cause=n.cause),this.details=s,this.docsPath=r,this.metaMessages=n.metaMessages,this.shortMessage=t}walk(t){return n_(this,Wu,"m",s_).call(this,this,t)}};Wu=new WeakSet,s_=function e(t,n){return n!=null&&n(t)?t:t.cause?n_(this,Wu,"m",e).call(this,t.cause,n):t};class oc extends nr{constructor(){super("Chain not configured."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainNotConfiguredError"})}}class XP extends nr{constructor(){super("Connector already connected."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ConnectorAlreadyConnectedError"})}}class KP extends nr{constructor(){super("Connector not connected."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ConnectorNotConnectedError"})}}class QP extends nr{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 ZP extends nr{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 YP extends nr{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`, `uuid`.","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 JP(e,t){var s;let n;if(typeof t.connector=="function"?n=e._internal.connectors.setup(t.connector):n=t.connector,n.uid===e.state.current)throw new XP;try{e.setState(i=>({...i,status:"connecting"})),n.emitter.emit("message",{type:"connecting"});const r=await n.connect({chainId:t.chainId}),o=r.accounts;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((s=e.storage)==null?void 0:s.setItem("recentConnectorId",n.id)),e.setState(i=>({...i,connections:new Map(i.connections).set(n.uid,{accounts:o,chainId:r.chainId,connector:n}),current:n.uid,status:"connected"})),{accounts:o,chainId:r.chainId}}catch(r){throw e.setState(o=>({...o,status:o.current?"connected":"disconnected"})),r}}function St({abi:e,address:t,client:n}){const s=n,[r,o]=s?"public"in s&&"wallet"in s?[s.public,s.wallet]:"public"in s?[s.public,void 0]:"wallet"in s?[void 0,s.wallet]:[s,s]:[void 0,void 0],i=r!=null,a=o!=null,c={};let u=!1,l=!1,d=!1;for(const f of e)if(f.type==="function"?f.stateMutability==="view"||f.stateMutability==="pure"?u=!0:l=!0:f.type==="event"&&(d=!0),u&&l&&d)break;return i&&(u&&(c.read=new Proxy({},{get(f,p){return(...m)=>{const{args:h,options:y}=Zc(m);return xe(r,zn,"readContract")({abi:e,address:t,functionName:p,args:h,...y})}}})),l&&(c.simulate=new Proxy({},{get(f,p){return(...m)=>{const{args:h,options:y}=Zc(m);return xe(r,uh,"simulateContract")({abi:e,address:t,functionName:p,args:h,...y})}}})),d&&(c.createEventFilter=new Proxy({},{get(f,p){return(...m)=>{const h=e.find(g=>g.type==="event"&&g.name===p),{args:y,options:b}=Jd(m,h);return xe(r,sh,"createContractEventFilter")({abi:e,address:t,eventName:p,args:y,...b})}}}),c.getEvents=new Proxy({},{get(f,p){return(...m)=>{const h=e.find(g=>g.type==="event"&&g.name===p),{args:y,options:b}=Jd(m,h);return xe(r,ch,"getContractEvents")({abi:e,address:t,eventName:p,args:y,...b})}}}),c.watchEvent=new Proxy({},{get(f,p){return(...m)=>{const h=e.find(g=>g.type==="event"&&g.name===p),{args:y,options:b}=Jd(m,h);return xe(r,e_,"watchContractEvent")({abi:e,address:t,eventName:p,args:y,...b})}}}))),a&&l&&(c.write=new Proxy({},{get(f,p){return(...m)=>{const{args:h,options:y}=Zc(m);return xe(o,t_,"writeContract")({abi:e,address:t,functionName:p,args:h,...y})}}})),(i||a)&&l&&(c.estimateGas=new Proxy({},{get(f,p){return(...m)=>{const{args:h,options:y}=Zc(m);return xe(r??o,O2,"estimateContractGas")({abi:e,address:t,functionName:p,args:h,...y,account:y.account??o.account})}}})),c.address=t,c.abi=e,c}function Zc(e){const t=e.length&&Array.isArray(e[0]),n=t?e[0]:[],s=(t?e[1]:e[0])??{};return{args:n,options:s}}function Jd(e,t){let n=!1;Array.isArray(e[0])?n=!0:e.length===1?n=t.inputs.some(o=>o.indexed):e.length===2&&(n=!0);const s=n?e[0]:void 0,r=(n?e[1]:e[0])??{};return{args:s,options:r}}const ap=256;let Yc=ap,Jc;function r_(e=11){if(!Jc||Yc+e>ap*2){Jc="",Yc=0;for(let t=0;t<ap;t++)Jc+=(256+Math.random()*256|0).toString(16).substring(1)}return Jc.substring(Yc,Yc+++e)}function o_(e){const{batch:t,cacheTime:n=e.pollingInterval??4e3,ccipRead:s,key:r="base",name:o="Base Client",pollingInterval:i=4e3,type:a="base"}=e,c=e.chain,u=e.account?Xn(e.account):void 0,{config:l,request:d,value:f}=e.transport({chain:c,pollingInterval:i}),p={...l,...f},m={account:u,batch:t,cacheTime:n,ccipRead:s,chain:c,key:r,name:o,pollingInterval:i,request:d,transport:p,type:a,uid:r_()};function h(y){return b=>{const g=b(y);for(const _ in m)delete g[_];const w={...y,...g};return Object.assign(w,{extend:h(w)})}}return Object.assign(m,{extend:h(m)})}function Ll({key:e,name:t,request:n,retryCount:s=3,retryDelay:r=150,timeout:o,type:i},a){const c=r_();return{config:{key:e,name:t,request:n,retryCount:s,retryDelay:r,timeout:o,type:i},request:VS(n,{retryCount:s,retryDelay:r,uid:c}),value:a}}function ek(e,t={}){const{key:n="custom",name:s="Custom Provider",retryDelay:r}=t;return({retryCount:o})=>Ll({key:n,name:s,request:e.request.bind(e),retryCount:t.retryCount??o,retryDelay:r,type:"custom"})}function tk(e,t={}){const{key:n="fallback",name:s="Fallback",rank:r=!1,retryCount:o,retryDelay:i}=t;return({chain:a,pollingInterval:c=4e3,timeout:u,...l})=>{let d=e,f=()=>{};const p=Ll({key:n,name:s,async request({method:m,params:h}){const y=async(b=0)=>{const g=d[b]({...l,chain:a,retryCount:0,timeout:u});try{const w=await g.request({method:m,params:h});return f({method:m,params:h,response:w,transport:g,status:"success"}),w}catch(w){if(f({error:w,method:m,params:h,transport:g,status:"error"}),nk(w)||b===d.length-1)throw w;return y(b+1)}};return y()},retryCount:o,retryDelay:i,type:"fallback"},{onResponse:m=>f=m,transports:d.map(m=>m({chain:a,retryCount:0}))});if(r){const m=typeof r=="object"?r:{};sk({chain:a,interval:m.interval??c,onTransports:h=>d=h,sampleCount:m.sampleCount,timeout:m.timeout,transports:d,weights:m.weights})}return p}}function nk(e){return"code"in e&&typeof e.code=="number"&&(e.code===Mi.code||e.code===ht.code||e.code===5e3)}function sk({chain:e,interval:t=4e3,onTransports:n,sampleCount:s=10,timeout:r=1e3,transports:o,weights:i={}}){const{stability:a=.7,latency:c=.3}=i,u=[],l=async()=>{const d=await Promise.all(o.map(async m=>{const h=m({chain:e,retryCount:0,timeout:r}),y=Date.now();let b,g;try{await h.request({method:"net_listening"}),g=1}catch{g=0}finally{b=Date.now()}return{latency:b-y,success:g}}));u.push(d),u.length>s&&u.shift();const f=Math.max(...u.map(m=>Math.max(...m.map(({latency:h})=>h)))),p=o.map((m,h)=>{const y=u.map(A=>A[h].latency),g=1-y.reduce((A,x)=>A+x,0)/y.length/f,w=u.map(A=>A[h].success),_=w.reduce((A,x)=>A+x,0)/w.length;return _===0?[0,h]:[c*g+a*_,h]}).sort((m,h)=>h[0]-m[0]);n(p.map(([,m])=>o[m])),await qu(t),l()};l()}class rk extends ue{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 tb(e,t={}){const{batch:n,fetchOptions:s,key:r="http",name:o="HTTP JSON-RPC",onFetchRequest:i,onFetchResponse:a,retryDelay:c}=t;return({chain:u,retryCount:l,timeout:d})=>{const{batchSize:f=1e3,wait:p=0}=typeof n=="object"?n:{},m=t.retryCount??l,h=d??t.timeout??1e4,y=e||(u==null?void 0:u.rpcUrls.default.http[0]);if(!y)throw new rk;const b=GS(y,{fetchOptions:s,onRequest:i,onResponse:a,timeout:h});return Ll({key:r,name:o,async request({method:g,params:w}){const _={method:g,params:w},{schedule:A}=P2({id:y,wait:p,shouldSplitBatch(S){return S.length>f},fn:S=>b.request({body:S}),sort:(S,R)=>S.id-R.id}),x=async S=>n?A(S):[await b.request({body:S})],[{error:C,result:k}]=await x(_);if(C)throw new Ww({body:_,error:C,url:y});return k},retryCount:m,retryDelay:c,timeout:h,type:"http"},{fetchOptions:s,url:y})}}function ok(e){var d,f,p;const{scheme:t,statement:n,...s}=((d=e.match(ik))==null?void 0:d.groups)??{},{chainId:r,expirationTime:o,issuedAt:i,notBefore:a,requestId:c,...u}=((f=e.match(ak))==null?void 0:f.groups)??{},l=(p=e.split("Resources:")[1])==null?void 0:p.split(`
- `).slice(1);return{...s,...u,...r?{chainId:Number(r)}:{},...o?{expirationTime:new Date(o)}:{},...i?{issuedAt:new Date(i)}:{},...a?{notBefore:new Date(a)}:{},...c?{requestId:c}:{},...l?{resources:l}:{},...t?{scheme:t}:{},...n?{statement:n}:{}}}const ik=/^(?:(?<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)?/,ak=/(?: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 ck(e){const{address:t,domain:n,message:s,nonce:r,scheme:o,time:i=new Date}=e;if(n&&s.domain!==n||r&&s.nonce!==r||o&&s.scheme!==o||s.expirationTime&&i>=s.expirationTime||s.notBefore&&i<s.notBefore)return!1;try{if(!s.address||t&&!rh(s.address,t))return!1}catch{return!1}return!0}async function uk(e,t){const{address:n,domain:s,message:r,nonce:o,scheme:i,signature:a,time:c=new Date,...u}=t,l=ok(r);if(!l.address||!ck({address:n,domain:s,message:l,nonce:o,scheme:i,time:c}))return!1;const f=V2(r);return yh(e,{address:l.address,hash:f,signature:a,...u})}function lk(e){return{call:t=>kc(e,t),createBlockFilter:()=>hS(e),createContractEventFilter:t=>sh(e,t),createEventFilter:t=>$2(e,t),createPendingTransactionFilter:()=>M2(e),estimateContractGas:t=>O2(e,t),estimateGas:t=>Xm(e,t),getBalance:t=>Gm(e,t),getBlobBaseFee:()=>bS(e),getBlock:t=>Us(e,t),getBlockNumber:t=>Rc(e,t),getBlockTransactionCount:t=>CS(e,t),getBytecode:t=>j0(e,t),getChainId:()=>zm(e),getCode:t=>j0(e,t),getContractEvents:t=>ch(e,t),getEip712Domain:t=>SS(e,t),getEnsAddress:t=>JE(e,t),getEnsAvatar:t=>fS(e,t),getEnsName:t=>pS(e,t),getEnsResolver:t=>mS(e,t),getEnsText:t=>R2(e,t),getFeeHistory:t=>IS(e,t),estimateFeesPerGas:t=>mT(e,t),getFilterChanges:t=>kl(e,t),getFilterLogs:t=>RS(e,t),getGasPrice:()=>Wm(e),getLogs:t=>ah(e,t),getProof:t=>lP(e,t),estimateMaxPriorityFeePerGas:t=>pT(e,t),getStorageAt:t=>$S(e,t),getTransaction:t=>Il(e,t),getTransactionConfirmations:t=>MS(e,t),getTransactionCount:t=>Jw(e,t),getTransactionReceipt:t=>ep(e,t),multicall:t=>L2(e,t),prepareTransactionRequest:t=>Qm(e,t),readContract:t=>zn(e,t),sendRawTransaction:t=>i2(e,t),simulateContract:t=>uh(e,t),verifyMessage:t=>qP(e,t),verifySiweMessage:t=>uk(e,t),verifyTypedData:t=>WP(e,t),uninstallFilter:t=>Rl(e,t),waitForTransactionReceipt:t=>H2(e,t),watchBlocks:t=>NS(e,t),watchBlockNumber:t=>F2(e,t),watchContractEvent:t=>e_(e,t),watchEvent:t=>BS(e,t),watchPendingTransactions:t=>DS(e,t)}}const dk="0x0000000000000000000000000000000000000000";async function bh(e,t={}){let n;if(t.connector){const{connector:u}=t;if(e.state.status==="reconnecting"&&!u.getAccounts&&!u.getChainId)throw new YP({connector:u});const[l,d]=await Promise.all([u.getAccounts(),u.getChainId()]);n={accounts:l,chainId:d,connector:u}}else n=e.state.connections.get(e.state.current);if(!n)throw new KP;const s=t.chainId??n.chainId,r=await n.connector.getChainId();if(r!==n.chainId)throw new ZP({connectionChainId:n.chainId,connectorChainId:r});const o=n.connector;if(o.getClient)return o.getClient({chainId:s});const i=Xn(t.account??n.accounts[0]);if(i.address=Cn(i.address),t.account&&!n.accounts.some(u=>u.toLowerCase()===i.address.toLowerCase()))throw new QP({address:i.address,connector:o});const a=e.chains.find(u=>u.id===s),c=await n.connector.getProvider({chainId:s});return o_({account:i,chain:a,name:"Connector Client",transport:u=>ek(c)({...u,retryCount:0})})}async function fk(e,t={}){var r,o;let n;if(t.connector)n=t.connector;else{const{connections:i,current:a}=e.state,c=i.get(a);n=c==null?void 0:c.connector}const s=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),s.delete(n.uid)),e.setState(i=>{if(s.size===0)return{...i,connections:new Map,current:null,status:"disconnected"};const a=s.values().next().value;return{...i,connections:new Map(s),current:a.connector.uid}});{const i=e.state.current;if(!i)return;const a=(r=e.state.connections.get(i))==null?void 0:r.connector;if(!a)return;await((o=e.storage)==null?void 0:o.setItem("recentConnectorId",a.id))}}function i_(e){return typeof e=="number"?e:e==="wei"?0:Math.abs(J8[e])}function gh(e){const t=e.state.current,n=e.state.connections.get(t),s=n==null?void 0:n.accounts,r=s==null?void 0:s[0],o=e.chains.find(a=>a.id===(n==null?void 0:n.chainId)),i=e.state.status;switch(i){case"connected":return{address:r,addresses:s,chain:o,chainId:n==null?void 0:n.chainId,connector:n==null?void 0:n.connector,isConnected:!0,isConnecting:!1,isDisconnected:!1,isReconnecting:!1,status:i};case"reconnecting":return{address:r,addresses:s,chain:o,chainId:n==null?void 0:n.chainId,connector:n==null?void 0:n.connector,isConnected:!!r,isConnecting:!1,isDisconnected:!1,isReconnecting:!0,status:i};case"connecting":return{address:r,addresses:s,chain:o,chainId:n==null?void 0:n.chainId,connector:n==null?void 0:n.connector,isConnected:!1,isConnecting:!0,isDisconnected:!1,isReconnecting:!1,status:i};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:i}}}async function pk(e,t){const{allowFailure:n=!0,chainId:s,contracts:r,...o}=t,i=e.getClient({chainId:s});return Rr(i,L2,"multicall")({allowFailure:n,contracts:r,...o})}function Jr(e,t){const{chainId:n,...s}=t,r=e.getClient({chainId:n});return Rr(r,zn,"readContract")(s)}async function mk(e,t){var a;const{allowFailure:n=!0,blockNumber:s,blockTag:r,...o}=t,i=t.contracts;try{const c={};for(const[f,p]of i.entries()){const m=p.chainId??e.state.chainId;c[m]||(c[m]=[]),(a=c[m])==null||a.push({contract:p,index:f})}const u=()=>Object.entries(c).map(([f,p])=>pk(e,{...o,allowFailure:n,blockNumber:s,blockTag:r,chainId:Number.parseInt(f),contracts:p.map(({contract:m})=>m)})),l=(await Promise.all(u())).flat(),d=Object.values(c).flatMap(f=>f.map(({index:p})=>p));return l.reduce((f,p,m)=>(f&&(f[d[m]]=p),f),[])}catch(c){if(c instanceof Ym)throw c;const u=()=>i.map(l=>Jr(e,{...l,blockNumber:s,blockTag:r}));return n?(await Promise.allSettled(u())).map(l=>l.status==="fulfilled"?{result:l.value,status:"success"}:{error:l.reason,result:void 0,status:"failure"}):await Promise.all(u())}}async function hk(e,t){const{address:n,blockNumber:s,blockTag:r,chainId:o,token:i,unit:a="ether"}=t;if(i)try{return nb(e,{balanceAddress:n,chainId:o,symbolType:"string",tokenAddress:i})}catch(f){if(f instanceof Ym){const p=await nb(e,{balanceAddress:n,chainId:o,symbolType:"bytes32",tokenAddress:i}),m=Cw(Ds(p.symbol,{dir:"right"}));return{...p,symbol:m}}throw f}const c=e.getClient({chainId:o}),l=await Rr(c,Gm,"getBalance")(s?{address:n,blockNumber:s}:{address:n,blockTag:r}),d=e.chains.find(f=>f.id===o)??c.chain;return{decimals:d.nativeCurrency.decimals,formatted:ea(l,i_(a)),symbol:d.nativeCurrency.symbol,value:l}}async function nb(e,t){const{balanceAddress:n,chainId:s,symbolType:r,tokenAddress:o,unit:i}=t,a={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:r}]}],address:o},[c,u,l]=await mk(e,{allowFailure:!1,contracts:[{...a,functionName:"balanceOf",args:[n],chainId:s},{...a,functionName:"decimals",chainId:s},{...a,functionName:"symbol",chainId:s}]}),d=ea(c??"0",i_(i??u));return{decimals:u,formatted:d,symbol:l,value:c}}function yk(e){return e.state.chainId}function jr(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,s;if(Array.isArray(e)&&Array.isArray(t)){if(n=e.length,n!==t.length)return!1;for(s=n;s--!==0;)if(!jr(e[s],t[s]))return!1;return!0}if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();const r=Object.keys(e);if(n=r.length,n!==Object.keys(t).length)return!1;for(s=n;s--!==0;)if(!Object.prototype.hasOwnProperty.call(t,r[s]))return!1;for(s=n;s--!==0;){const o=r[s];if(o&&!jr(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}let ef=[];function bk(e){const t=e.chains;return jr(ef,t)?ef:(ef=t,t)}function gk(e,t={}){let n;try{n=e.getClient(t)}catch{}return n}let eu=[];function a_(e){const t=[...e.state.connections.values()];return e.state.status==="reconnecting"||jr(eu,t)?eu:(eu=t,t)}let tf=[];function vk(e){const t=e.connectors;return jr(tf,t)?tf:(tf=t,t)}function ft(e,t={}){const n=gk(e,t);return n==null?void 0:n.extend(lk)}let nf=!1;async function wk(e,t={}){var u,l;if(nf)return[];nf=!0,e.setState(d=>({...d,status:d.current?"reconnecting":"connecting"}));const n=[];if((u=t.connectors)!=null&&u.length)for(const d of t.connectors){let f;typeof d=="function"?f=e._internal.connectors.setup(d):f=d,n.push(f)}else n.push(...e.connectors);let s;try{s=await((l=e.storage)==null?void 0:l.getItem("recentConnectorId"))}catch{}const r={};for(const[,d]of e.state.connections)r[d.connector.id]=1;s&&(r[s]=0);const o=Object.keys(r).length>0?[...n].sort((d,f)=>(r[d.id]??10)-(r[f.id]??10)):n;let i=!1;const a=[],c=[];for(const d of o){const f=await d.getProvider().catch(()=>{});if(!f||c.some(h=>h===f)||!await d.isAuthorized())continue;const m=await d.connect({isReconnecting:!0}).catch(()=>null);m&&(d.emitter.off("connect",e._internal.events.connect),d.emitter.on("change",e._internal.events.change),d.emitter.on("disconnect",e._internal.events.disconnect),e.setState(h=>{const y=new Map(i?h.connections:new Map).set(d.uid,{accounts:m.accounts,chainId:m.chainId,connector:d});return{...h,current:i?h.current:d.uid,connections:y}}),a.push({accounts:m.accounts,chainId:m.chainId,connector:d}),c.push(f),i=!0)}return(e.state.status==="reconnecting"||e.state.status==="connecting")&&(i?e.setState(d=>({...d,status:"connected"})):e.setState(d=>({...d,connections:new Map,current:null,status:"disconnected"}))),nf=!1,a}async function _k(e,t){const{abi:n,chainId:s,connector:r,...o}=t;let i;t.account?i=t.account:i=(await bh(e,{chainId:s,connector:r})).account;const a=e.getClient({chainId:s}),c=Rr(a,uh,"simulateContract"),{result:u,request:l}=await c({...o,abi:n,account:i});return{chainId:a.chain.id,result:u,request:{__mode:"prepared",...l,chainId:s}}}class xn extends nr{constructor(){super("Provider not found."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderNotFoundError"})}}class xk extends nr{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 Ck(e,t){var i;const{addEthereumChainParameter:n,chainId:s}=t,r=e.state.connections.get(((i=t.connector)==null?void 0:i.uid)??e.state.current);if(r){const a=r.connector;if(!a.switchChain)throw new xk({connector:a});return await a.switchChain({addEthereumChainParameter:n,chainId:s})}const o=e.chains.find(a=>a.id===s);if(!o)throw new oc;return e.setState(a=>({...a,chainId:s})),o}function Ak(e,t){const{onChange:n}=t;return e.subscribe(()=>gh(e),n,{equalityFn(s,r){const{connector:o,...i}=s,{connector:a,...c}=r;return jr(i,c)&&(o==null?void 0:o.id)===(a==null?void 0:a.id)&&(o==null?void 0:o.uid)===(a==null?void 0:a.uid)}})}function Tk(e,t){const{onChange:n}=t;return e.subscribe(s=>s.chainId,n)}function Ek(e,t){const{onChange:n}=t;return e.subscribe(()=>a_(e),n,{equalityFn:jr})}function Sk(e,t){const{onChange:n}=t;return e._internal.connectors.subscribe((s,r)=>{n(Object.values(s),r)})}async function Oe(e,t){const{chainId:n,timeout:s=0,...r}=t,o=e.getClient({chainId:n}),a=await Rr(o,H2,"waitForTransactionReceipt")({...r,timeout:s});if(a.status==="reverted"){const u=await Rr(o,Il,"getTransaction")({hash:a.transactionHash}),d=await Rr(o,kc,"call")({...u,gasPrice:u.type!=="eip1559"?u.gasPrice:void 0,maxFeePerGas:u.type==="eip1559"?u.maxFeePerGas:void 0,maxPriorityFeePerGas:u.type==="eip1559"?u.maxPriorityFeePerGas:void 0}),f=d!=null&&d.data?Cw(`0x${d.data.substring(138)}`):"unknown reason";throw new Error(f)}return{...a,chainId:o.chain.id}}async function Le(e,t){const{account:n,chainId:s,connector:r,__mode:o,...i}=t;let a;typeof n=="object"&&(n==null?void 0:n.type)==="local"?a=e.getClient({chainId:s}):a=await bh(e,{account:n??void 0,chainId:s,connector:r});const{connector:c}=gh(e);let u;if(o==="prepared"||c!=null&&c.supportsSimulation)u=i;else{const{request:f}=await _k(e,{...i,account:n,chainId:s});u=f}return await Rr(a,t_,"writeContract")({...u,...n?{account:n}:{},chain:s?{id:s}:null})}const Pk=/(rabby|trustwallet)/;ic.type="injected";function ic(e={}){const{shimDisconnect:t=!0,unstable_shimAsyncInject:n}=e;function s(){const c=e.target;if(typeof c=="function"){const u=c();if(u)return u}return typeof c=="object"?c:typeof c=="string"?{...kk[c]??{id:c,name:`${c[0].toUpperCase()}${c.slice(1)}`,provider:`is${c[0].toUpperCase()}${c.slice(1)}`}}:{id:"injected",name:"Injected",provider(u){return u==null?void 0:u.ethereum}}}let r,o,i,a;return c=>({get icon(){return s().icon},get id(){return s().id},get name(){return s().name},get supportsSimulation(){return Pk.test(this.id.toLowerCase())},type:ic.type,async setup(){const u=await this.getProvider();u!=null&&u.on&&e.target&&(i||(i=this.onConnect.bind(this),u.on("connect",i)),r||(r=this.onAccountsChanged.bind(this),u.on("accountsChanged",r)))},async connect({chainId:u,isReconnecting:l}={}){var p,m,h,y,b,g;const d=await this.getProvider();if(!d)throw new xn;let f=[];if(l)f=await this.getAccounts().catch(()=>[]);else if(t)try{f=(y=(h=(m=(p=(await d.request({method:"wallet_requestPermissions",params:[{eth_accounts:{}}]}))[0])==null?void 0:p.caveats)==null?void 0:m[0])==null?void 0:h.value)==null?void 0:y.map(_=>Cn(_)),f.length>0&&(f=await this.getAccounts())}catch(w){const _=w;if(_.code===ht.code)throw new ht(_);if(_.code===Ir.code)throw _}try{!(f!=null&&f.length)&&!l&&(f=(await d.request({method:"eth_requestAccounts"})).map(A=>Cn(A))),i&&(d.removeListener("connect",i),i=void 0),r||(r=this.onAccountsChanged.bind(this),d.on("accountsChanged",r)),o||(o=this.onChainChanged.bind(this),d.on("chainChanged",o)),a||(a=this.onDisconnect.bind(this),d.on("disconnect",a));let w=await this.getChainId();if(u&&w!==u){const _=await this.switchChain({chainId:u}).catch(A=>{if(A.code===ht.code)throw A;return{id:w}});w=(_==null?void 0:_.id)??w}return t&&await((b=c.storage)==null?void 0:b.removeItem(`${this.id}.disconnected`)),e.target||await((g=c.storage)==null?void 0:g.setItem("injected.connected",!0)),{accounts:f,chainId:w}}catch(w){const _=w;throw _.code===ht.code?new ht(_):_.code===Ir.code?new Ir(_):_}},async disconnect(){var l,d;const u=await this.getProvider();if(!u)throw new xn;o&&(u.removeListener("chainChanged",o),o=void 0),a&&(u.removeListener("disconnect",a),a=void 0),i||(i=this.onConnect.bind(this),u.on("connect",i));try{await $l(()=>u.request({method:"wallet_revokePermissions",params:[{eth_accounts:{}}]}),{timeout:100})}catch{}t&&await((l=c.storage)==null?void 0:l.setItem(`${this.id}.disconnected`,!0)),e.target||await((d=c.storage)==null?void 0:d.removeItem("injected.connected"))},async getAccounts(){const u=await this.getProvider();if(!u)throw new xn;return(await u.request({method:"eth_accounts"})).map(d=>Cn(d))},async getChainId(){const u=await this.getProvider();if(!u)throw new xn;const l=await u.request({method:"eth_chainId"});return Number(l)},async getProvider(){if(typeof window>"u")return;let u;const l=s();return typeof l.provider=="function"?u=l.provider(window):typeof l.provider=="string"?u=xu(window,l.provider):u=l.provider,u&&!u.removeListener&&("off"in u&&typeof u.off=="function"?u.removeListener=u.off:u.removeListener=()=>{}),u},async isAuthorized(){var u,l;try{if(t&&await((u=c.storage)==null?void 0:u.getItem(`${this.id}.disconnected`))||!e.target&&!await((l=c.storage)==null?void 0:l.getItem("injected.connected")))return!1;if(!await this.getProvider()){if(n!==void 0&&n!==!1){const m=async()=>(typeof window<"u"&&window.removeEventListener("ethereum#initialized",m),!!await this.getProvider()),h=typeof n=="number"?n:1e3;if(await Promise.race([...typeof window<"u"?[new Promise(b=>window.addEventListener("ethereum#initialized",()=>b(m()),{once:!0}))]:[],new Promise(b=>setTimeout(()=>b(m()),h))]))return!0}throw new xn}return!!(await sc(()=>this.getAccounts())).length}catch{return!1}},async switchChain({addEthereumChainParameter:u,chainId:l}){var p,m,h,y;const d=await this.getProvider();if(!d)throw new xn;const f=c.chains.find(b=>b.id===l);if(!f)throw new Dr(new oc);try{return await Promise.all([d.request({method:"wallet_switchEthereumChain",params:[{chainId:Ee(l)}]}).then(async()=>{await this.getChainId()===l&&c.emitter.emit("change",{chainId:l})}),new Promise(b=>{const g=w=>{"chainId"in w&&w.chainId===l&&(c.emitter.off("change",g),b())};c.emitter.on("change",g)})]),f}catch(b){const g=b;if(g.code===4902||((m=(p=g==null?void 0:g.data)==null?void 0:p.originalError)==null?void 0:m.code)===4902)try{const{default:w,..._}=f.blockExplorers??{};let A;u!=null&&u.blockExplorerUrls?A=u.blockExplorerUrls:w&&(A=[w.url,...Object.values(_).map(S=>S.url)]);let x;(h=u==null?void 0:u.rpcUrls)!=null&&h.length?x=u.rpcUrls:x=[((y=f.rpcUrls.default)==null?void 0:y.http[0])??""];const C={blockExplorerUrls:A,chainId:Ee(l),chainName:(u==null?void 0:u.chainName)??f.name,iconUrls:u==null?void 0:u.iconUrls,nativeCurrency:(u==null?void 0:u.nativeCurrency)??f.nativeCurrency,rpcUrls:x};if(await d.request({method:"wallet_addEthereumChain",params:[C]}),await this.getChainId()!==l)throw new ht(new Error("User rejected switch after adding network."));return f}catch(w){throw new ht(w)}throw g.code===ht.code?new ht(g):new Dr(g)}},async onAccountsChanged(u){var l;if(u.length===0)this.onDisconnect();else if(c.emitter.listenerCount("connect")){const d=(await this.getChainId()).toString();this.onConnect({chainId:d}),t&&await((l=c.storage)==null?void 0:l.removeItem(`${this.id}.disconnected`))}else c.emitter.emit("change",{accounts:u.map(d=>Cn(d))})},onChainChanged(u){const l=Number(u);c.emitter.emit("change",{chainId:l})},async onConnect(u){const l=await this.getAccounts();if(l.length===0)return;const d=Number(u.chainId);c.emitter.emit("connect",{accounts:l,chainId:d});const f=await this.getProvider();f&&(i&&(f.removeListener("connect",i),i=void 0),r||(r=this.onAccountsChanged.bind(this),f.on("accountsChanged",r)),o||(o=this.onChainChanged.bind(this),f.on("chainChanged",o)),a||(a=this.onDisconnect.bind(this),f.on("disconnect",a)))},async onDisconnect(u){const l=await this.getProvider();u&&u.code===1013&&l&&(await this.getAccounts()).length||(c.emitter.emit("disconnect"),l&&(o&&(l.removeListener("chainChanged",o),o=void 0),a&&(l.removeListener("disconnect",a),a=void 0),i||(i=this.onConnect.bind(this),l.on("connect",i))))}})}const kk={coinbaseWallet:{id:"coinbaseWallet",name:"Coinbase Wallet",provider(e){return e!=null&&e.coinbaseWalletExtension?e.coinbaseWalletExtension:xu(e,"isCoinbaseWallet")}},metaMask:{id:"metaMask",name:"MetaMask",provider(e){return xu(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","isPortal","isRabby","isTokenPocket","isTokenary","isUniswapWallet","isZerion"];for(const s of n)if(t[s])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:xu(e,"isPhantom")}}};function xu(e,t){function n(r){return typeof t=="function"?t(r):typeof t=="string"?r[t]:!0}const s=e.ethereum;if(s!=null&&s.providers)return s.providers.find(r=>n(r));if(s&&n(s))return s}function Ik(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 Rk(){const e=new Set;let t=[];const n=()=>Ik(r=>{t.some(({info:o})=>o.uuid===r.info.uuid)||(t=[...t,r],e.forEach(o=>o(t,{added:[r]})))});let s=n();return{_listeners(){return e},clear(){e.forEach(r=>r([],{removed:[...t]})),t=[]},destroy(){this.clear(),e.clear(),s==null||s()},findProvider({rdns:r}){return t.find(o=>o.info.rdns===r)},getProviders(){return t},reset(){this.clear(),s==null||s(),s=n()},subscribe(r,{emitImmediately:o}={}){return e.add(r),o&&r(t,{added:t}),()=>e.delete(r)}}}const $k=e=>(t,n,s)=>{const r=s.subscribe;return s.subscribe=(i,a,c)=>{let u=i;if(a){const l=(c==null?void 0:c.equalityFn)||Object.is;let d=i(s.getState());u=f=>{const p=i(f);if(!l(d,p)){const m=d;a(d=p,m)}},c!=null&&c.fireImmediately&&a(d,d)}return r(u)},e(t,n,s)},Mk=$k;function Ok(e,t){let n;try{n=e()}catch{return}return{getItem:r=>{var o;const i=c=>c===null?null:JSON.parse(c,void 0),a=(o=n.getItem(r))!=null?o:null;return a instanceof Promise?a.then(i):i(a)},setItem:(r,o)=>n.setItem(r,JSON.stringify(o,void 0)),removeItem:r=>n.removeItem(r)}}const cp=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(s){return cp(s)(n)},catch(s){return this}}}catch(n){return{then(s){return this},catch(s){return cp(s)(n)}}}},Lk=(e,t)=>(n,s,r)=>{let o={storage:Ok(()=>localStorage),partialize:h=>h,version:0,merge:(h,y)=>({...y,...h}),...t},i=!1;const a=new Set,c=new Set;let u=o.storage;if(!u)return e((...h)=>{console.warn(`[zustand persist middleware] Unable to update item '${o.name}', the given storage is currently unavailable.`),n(...h)},s,r);const l=()=>{const h=o.partialize({...s()});return u.setItem(o.name,{state:h,version:o.version})},d=r.setState;r.setState=(h,y)=>{d(h,y),l()};const f=e((...h)=>{n(...h),l()},s,r);r.getInitialState=()=>f;let p;const m=()=>{var h,y;if(!u)return;i=!1,a.forEach(g=>{var w;return g((w=s())!=null?w:f)});const b=((y=o.onRehydrateStorage)==null?void 0:y.call(o,(h=s())!=null?h:f))||void 0;return cp(u.getItem.bind(u))(o.name).then(g=>{if(g)if(typeof g.version=="number"&&g.version!==o.version){if(o.migrate)return[!0,o.migrate(g.state,g.version)];console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,g.state];return[!1,void 0]}).then(g=>{var w;const[_,A]=g;if(p=o.merge(A,(w=s())!=null?w:f),n(p,!0),_)return l()}).then(()=>{b==null||b(p,void 0),p=s(),i=!0,c.forEach(g=>g(p))}).catch(g=>{b==null||b(void 0,g)})};return r.persist={setOptions:h=>{o={...o,...h},h.storage&&(u=h.storage)},clearStorage:()=>{u==null||u.removeItem(o.name)},getOptions:()=>o,rehydrate:()=>m(),hasHydrated:()=>i,onHydrate:h=>(a.add(h),()=>{a.delete(h)}),onFinishHydration:h=>(c.add(h),()=>{c.delete(h)})},o.skipHydration||m(),p||f},Fk=Lk,sb=e=>{let t;const n=new Set,s=(u,l)=>{const d=typeof u=="function"?u(t):u;if(!Object.is(d,t)){const f=t;t=l??(typeof d!="object"||d===null)?d:Object.assign({},t,d),n.forEach(p=>p(t,f))}},r=()=>t,a={setState:s,getState:r,getInitialState:()=>c,subscribe:u=>(n.add(u),()=>n.delete(u))},c=t=e(s,r,a);return a},sf=e=>e?sb(e):sb;var c_={exports:{}};(function(e){var t=Object.prototype.hasOwnProperty,n="~";function s(){}Object.create&&(s.prototype=Object.create(null),new s().__proto__||(n=!1));function r(c,u,l){this.fn=c,this.context=u,this.once=l||!1}function o(c,u,l,d,f){if(typeof l!="function")throw new TypeError("The listener must be a function");var p=new r(l,d||c,f),m=n?n+u:u;return c._events[m]?c._events[m].fn?c._events[m]=[c._events[m],p]:c._events[m].push(p):(c._events[m]=p,c._eventsCount++),c}function i(c,u){--c._eventsCount===0?c._events=new s:delete c._events[u]}function a(){this._events=new s,this._eventsCount=0}a.prototype.eventNames=function(){var u=[],l,d;if(this._eventsCount===0)return u;for(d in l=this._events)t.call(l,d)&&u.push(n?d.slice(1):d);return Object.getOwnPropertySymbols?u.concat(Object.getOwnPropertySymbols(l)):u},a.prototype.listeners=function(u){var l=n?n+u:u,d=this._events[l];if(!d)return[];if(d.fn)return[d.fn];for(var f=0,p=d.length,m=new Array(p);f<p;f++)m[f]=d[f].fn;return m},a.prototype.listenerCount=function(u){var l=n?n+u:u,d=this._events[l];return d?d.fn?1:d.length:0},a.prototype.emit=function(u,l,d,f,p,m){var h=n?n+u:u;if(!this._events[h])return!1;var y=this._events[h],b=arguments.length,g,w;if(y.fn){switch(y.once&&this.removeListener(u,y.fn,void 0,!0),b){case 1:return y.fn.call(y.context),!0;case 2:return y.fn.call(y.context,l),!0;case 3:return y.fn.call(y.context,l,d),!0;case 4:return y.fn.call(y.context,l,d,f),!0;case 5:return y.fn.call(y.context,l,d,f,p),!0;case 6:return y.fn.call(y.context,l,d,f,p,m),!0}for(w=1,g=new Array(b-1);w<b;w++)g[w-1]=arguments[w];y.fn.apply(y.context,g)}else{var _=y.length,A;for(w=0;w<_;w++)switch(y[w].once&&this.removeListener(u,y[w].fn,void 0,!0),b){case 1:y[w].fn.call(y[w].context);break;case 2:y[w].fn.call(y[w].context,l);break;case 3:y[w].fn.call(y[w].context,l,d);break;case 4:y[w].fn.call(y[w].context,l,d,f);break;default:if(!g)for(A=1,g=new Array(b-1);A<b;A++)g[A-1]=arguments[A];y[w].fn.apply(y[w].context,g)}}return!0},a.prototype.on=function(u,l,d){return o(this,u,l,d,!1)},a.prototype.once=function(u,l,d){return o(this,u,l,d,!0)},a.prototype.removeListener=function(u,l,d,f){var p=n?n+u:u;if(!this._events[p])return this;if(!l)return i(this,p),this;var m=this._events[p];if(m.fn)m.fn===l&&(!f||m.once)&&(!d||m.context===d)&&i(this,p);else{for(var h=0,y=[],b=m.length;h<b;h++)(m[h].fn!==l||f&&!m[h].once||d&&m[h].context!==d)&&y.push(m[h]);y.length?this._events[p]=y.length===1?y[0]:y:i(this,p)}return this},a.prototype.removeAllListeners=function(u){var l;return u?(l=n?n+u:u,this._events[l]&&i(this,l)):(this._events=new s,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=n,a.EventEmitter=a,e.exports=a})(c_);var Nk=c_.exports;class Bk{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 Nk.EventEmitter})}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 s=n[0];this._emitter.emit(t,{uid:this.uid,...s})}listenerCount(t){return this._emitter.listenerCount(t)}}function Dk(e){return new Bk(e)}function Uk(e,t){return JSON.parse(e,(n,s)=>{let r=s;return(r==null?void 0:r.__type)==="bigint"&&(r=BigInt(r.value)),(r==null?void 0:r.__type)==="Map"&&(r=new Map(r.value)),(t==null?void 0:t(n,r))??r})}function rb(e,t){return e.slice(0,t).join(".")||"."}function ob(e,t){const{length:n}=e;for(let s=0;s<n;++s)if(e[s]===t)return s+1;return 0}function Vk(e,t){const n=typeof e=="function",s=typeof t=="function",r=[],o=[];return function(a,c){if(typeof c=="object")if(r.length){const u=ob(r,this);u===0?r[r.length]=this:(r.splice(u),o.splice(u)),o[o.length]=a;const l=ob(r,c);if(l!==0)return s?t.call(this,a,c,rb(o,l)):`[ref=${rb(o,l)}]`}else r[0]=c,o[0]=a;return n?e.call(this,a,c):c}}function jk(e,t,n,s){return JSON.stringify(e,Vk((r,o)=>{let i=o;return typeof i=="bigint"&&(i={__type:"bigint",value:o.toString()}),i instanceof Map&&(i={__type:"Map",value:Array.from(o.entries())}),(t==null?void 0:t(r,i))??i},s),n??void 0)}function Hk(e){const{deserialize:t=Uk,key:n="wagmi",serialize:s=jk,storage:r=u_}=e;function o(i){return i instanceof Promise?i.then(a=>a).catch(()=>null):i}return{...r,key:n,async getItem(i,a){const c=r.getItem(`${n}.${i}`),u=await o(c);return u?t(u)??null:a??null},async setItem(i,a){const c=`${n}.${i}`;a===null?await o(r.removeItem(c)):await o(r.setItem(c,s(a)))},async removeItem(i){await o(r.removeItem(`${n}.${i}`))}}}const u_={getItem:()=>null,setItem:()=>{},removeItem:()=>{}},up=256;let tu=up,nu;function zk(e=11){if(!nu||tu+e>up*2){nu="",tu=0;for(let t=0;t<up;t++)nu+=(256+Math.random()*256|0).toString(16).substring(1)}return nu.substring(tu,tu+++e)}function qk(e){const{multiInjectedProviderDiscovery:t=!0,storage:n=Hk({storage:typeof window<"u"&&window.localStorage?window.localStorage:u_}),syncConnectedChain:s=!0,ssr:r=!1,...o}=e,i=typeof window<"u"&&t?Rk():void 0,a=sf(()=>o.chains),c=sf(()=>{const A=[],x=new Set;for(const C of o.connectors??[]){const k=u(C);A.push(k),!r&&k.rdns&&x.add(k.rdns)}if(!r&&i){const C=i.getProviders();for(const k of C)x.has(k.info.rdns)||A.push(u(l(k)))}return A});function u(A){var k;const x=Dk(zk()),C={...A({emitter:x,chains:a.getState(),storage:n,transports:o.transports}),emitter:x,uid:x.uid};return x.on("connect",w),(k=C.setup)==null||k.call(C),C}function l(A){const{info:x}=A,C=A.provider;return ic({target:{...x,id:x.rdns,provider:C}})}const d=new Map;function f(A={}){const x=A.chainId??y.getState().chainId,C=a.getState().find(S=>S.id===x);if(A.chainId&&!C)throw new oc;{const S=d.get(y.getState().chainId);if(S&&!C)return S;if(!C)throw new oc}{const S=d.get(x);if(S)return S}let k;if(o.client)k=o.client({chain:C});else{const S=C.id,R=a.getState().map(X=>X.id),B={},L=Object.entries(o);for(const[X,z]of L)if(!(X==="chains"||X==="client"||X==="connectors"||X==="transports"))if(typeof z=="object")if(S in z)B[X]=z[S];else{if(R.some(ne=>ne in z))continue;B[X]=z}else B[X]=z;k=o_({...B,chain:C,batch:B.batch??{multicall:!0},transport:X=>o.transports[S]({...X,connectors:c})})}return d.set(x,k),k}function p(){return{chainId:a.getState()[0].id,connections:new Map,current:null,status:"disconnected"}}let m;const h="0.0.0-canary-";_u.startsWith(h)?m=Number.parseInt(_u.replace(h,"")):m=Number.parseInt(_u.split(".")[0]??"0");const y=sf(Mk(n?Fk(p,{migrate(A,x){if(x===m)return A;const C=p(),k=b(A,C.chainId);return{...C,chainId:k}},name:"store",partialize(A){return{connections:{__type:"Map",value:Array.from(A.connections.entries()).map(([x,C])=>{const{id:k,name:S,type:R,uid:B}=C.connector;return[x,{...C,connector:{id:k,name:S,type:R,uid:B}}]})},chainId:A.chainId,current:A.current}},merge(A,x){typeof A=="object"&&A&&"status"in A&&delete A.status;const C=b(A,x.chainId);return{...x,...A,chainId:C}},skipHydration:r,storage:n,version:m}):p));y.setState(p());function b(A,x){return A&&typeof A=="object"&&"chainId"in A&&typeof A.chainId=="number"&&a.getState().some(C=>C.id===A.chainId)?A.chainId:x}s&&y.subscribe(({connections:A,current:x})=>{var C;return x?(C=A.get(x))==null?void 0:C.chainId:void 0},A=>{if(a.getState().some(C=>C.id===A))return y.setState(C=>({...C,chainId:A??C.chainId}))}),i==null||i.subscribe(A=>{const x=new Set,C=new Set;for(const S of c.getState())x.add(S.id),S.rdns&&C.add(S.rdns);const k=[];for(const S of A){if(C.has(S.info.rdns))continue;const R=u(l(S));x.has(R.id)||k.push(R)}n&&!y.persist.hasHydrated()||c.setState(S=>[...S,...k],!0)});function g(A){y.setState(x=>{const C=x.connections.get(A.uid);return C?{...x,connections:new Map(x.connections).set(A.uid,{accounts:A.accounts??C.accounts,chainId:A.chainId??C.chainId,connector:C.connector})}:x})}function w(A){y.getState().status==="connecting"||y.getState().status==="reconnecting"||y.setState(x=>{const C=c.getState().find(k=>k.uid===A.uid);return C?(C.emitter.listenerCount("connect")&&C.emitter.off("connect",g),C.emitter.listenerCount("change")||C.emitter.on("change",g),C.emitter.listenerCount("disconnect")||C.emitter.on("disconnect",_),{...x,connections:new Map(x.connections).set(A.uid,{accounts:A.accounts,chainId:A.chainId,connector:C}),current:A.uid,status:"connected"}):x})}function _(A){y.setState(x=>{const C=x.connections.get(A.uid);if(C){const S=C.connector;S.emitter.listenerCount("change")&&C.connector.emitter.off("change",g),S.emitter.listenerCount("disconnect")&&C.connector.emitter.off("disconnect",_),S.emitter.listenerCount("connect")||C.connector.emitter.on("connect",w)}if(x.connections.delete(A.uid),x.connections.size===0)return{...x,connections:new Map,current:null,status:"disconnected"};const k=x.connections.values().next().value;return{...x,connections:new Map(x.connections),current:k.connector.uid}})}return{get chains(){return a.getState()},get connectors(){return c.getState()},storage:n,getClient:f,get state(){return y.getState()},setState(A){let x;typeof A=="function"?x=A(y.getState()):x=A;const C=p();typeof x!="object"&&(x=C),Object.keys(C).some(S=>!(S in x))&&(x=C),y.setState(x,!0)},subscribe(A,x,C){return y.subscribe(A,x,C?{...C,fireImmediately:C.emitImmediately}:void 0)},_internal:{mipd:i,store:y,ssr:!!r,syncConnectedChain:s,transports:o.transports,chains:{setState(A){const x=typeof A=="function"?A(a.getState()):A;if(x.length!==0)return a.setState(x,!0)},subscribe(A){return a.subscribe(A)}},connectors:{providerDetailToConnector:l,setup:u,setState(A){return c.setState(typeof A=="function"?A(c.getState()):A,!0)},subscribe(A){return c.subscribe(A)}},events:{change:g,connect:w,disconnect:_}}}}function Wk(e,t){const{initialState:n,reconnectOnMount:s}=t;return n&&!e._internal.store.persist.hasHydrated()&&e.setState({...n,chainId:e.chains.some(r=>r.id===n.chainId)?n.chainId:e.chains[0].id,connections:s?n.connections:new Map,status:s?"reconnecting":"disconnected"}),{async onMount(){e._internal.ssr&&(await e._internal.store.persist.rehydrate(),e._internal.mipd&&e._internal.connectors.setState(r=>{var c;const o=new Set;for(const u of r??[])u.rdns&&o.add(u.rdns);const i=[],a=((c=e._internal.mipd)==null?void 0:c.getProviders())??[];for(const u of a){if(o.has(u.info.rdns))continue;const l=e._internal.connectors.providerDetailToConnector(u),d=e._internal.connectors.setup(l);i.push(d)}return[...r,...i]})),s?wk(e):e.storage&&e.setState(r=>({...r,connections:new Map}))}}}function Gk(e,t={}){const{type:n}=e,{key:s="connector",name:r="Connector",retryDelay:o}=t;return i=>{const{chain:a,connectors:c}=i,u=t.retryCount??i.retryCount;return Ll({key:s,name:r,request:async({method:d,params:f})=>{const p=c==null?void 0:c.getState().find(b=>b.type===n);if(!p)throw new So(new Error(`Could not find connector of type "${n}" in \`connectors\` passed to \`createConfig\`.`));const m=await p.getProvider({chainId:a==null?void 0:a.id});if(!m)throw new So(new Error("Provider is disconnected."));const h=hs(await sc(()=>$l(()=>m.request({method:"eth_chainId"}),{timeout:100})));if(a&&h!==a.id)throw new Li(new Error(`The current chain of the connector (id: ${h}) does not match the target chain for the request (id: ${a.id} – ${a.name}).`));const y={method:d,params:f};return m.request(y)},retryCount:u,retryDelay:o,type:"connector"})}}function Xk(e,t){return tk(e,t)}function Kk(e){var o,i,a;const{chain:t}=e,n=t.rpcUrls.default.http[0];if(!e.transports)return[n];const s=(i=(o=e.transports)==null?void 0:o[t.id])==null?void 0:i.call(o,{chain:t});return(((a=s==null?void 0:s.value)==null?void 0:a.transports)||[s]).map(({value:c})=>(c==null?void 0:c.url)||n)}vh.type="safe";function vh(e={}){const{shimDisconnect:t=!1}=e;let n,s;return r=>({id:"safe",name:"Safe",type:vh.type,async connect(){var c;const o=await this.getProvider();if(!o)throw new xn;const i=await this.getAccounts(),a=await this.getChainId();return s||(s=this.onDisconnect.bind(this),o.on("disconnect",s)),t&&await((c=r.storage)==null?void 0:c.removeItem("safe.disconnected")),{accounts:i,chainId:a}},async disconnect(){var i;const o=await this.getProvider();if(!o)throw new xn;s&&(o.removeListener("disconnect",s),s=void 0),t&&await((i=r.storage)==null?void 0:i.setItem("safe.disconnected",!0))},async getAccounts(){const o=await this.getProvider();if(!o)throw new xn;return(await o.request({method:"eth_accounts"})).map(Cn)},async getProvider(){if(typeof window<"u"&&(window==null?void 0:window.parent)!==window){if(!n){const{default:i}=await $i(async()=>{const{default:l}=await import("./index-yF-LxBzd.js");return{default:l}},__vite__mapDeps([0,1])),a=new i(e),c=await $l(()=>a.safe.getInfo(),{timeout:e.unstable_getInfoTimeout??10});if(!c)throw new Error("Could not load Safe information");const{SafeAppProvider:u}=await $i(async()=>{const{SafeAppProvider:l}=await import("./index-y6gnYXmM.js").then(d=>d.i);return{SafeAppProvider:l}},__vite__mapDeps([2,3,1]));n=new u(c,a)}return n}},async getChainId(){const o=await this.getProvider();if(!o)throw new xn;return Number(o.chainId)},async isAuthorized(){var o;try{return t&&await((o=r.storage)==null?void 0:o.getItem("safe.disconnected"))?!1:!!(await this.getAccounts()).length}catch{return!1}},onAccountsChanged(){},onChainChanged(){},onDisconnect(){r.emitter.emit("disconnect")}})}wh.type="walletConnect";function wh(e){const t=e.isNewChainsStale??!0;let n,s;const r="eip155";let o,i,a,c,u,l;return d=>({id:"walletConnect",name:"WalletConnect",type:wh.type,async setup(){const f=await this.getProvider().catch(()=>null);f&&(a||(a=this.onConnect.bind(this),f.on("connect",a)),u||(u=this.onSessionDelete.bind(this),f.on("session_delete",u)))},async connect({chainId:f,...p}={}){var m,h;try{const y=await this.getProvider();if(!y)throw new xn;c||(c=this.onDisplayUri,y.on("display_uri",c));let b=f;if(!b){const A=await((m=d.storage)==null?void 0:m.getItem("state"))??{};d.chains.some(C=>C.id===A.chainId)?b=A.chainId:b=(h=d.chains[0])==null?void 0:h.id}if(!b)throw new Error("No chains found on connector.");const g=await this.isChainsStale();if(y.session&&g&&await y.disconnect(),!y.session||g){const A=d.chains.filter(x=>x.id!==b).map(x=>x.id);await y.connect({optionalChains:[b,...A],..."pairingTopic"in p?{pairingTopic:p.pairingTopic}:{}}),this.setRequestedChainsIds(d.chains.map(x=>x.id))}const w=(await y.enable()).map(A=>Cn(A)),_=await this.getChainId();return c&&(y.removeListener("display_uri",c),c=void 0),a&&(y.removeListener("connect",a),a=void 0),o||(o=this.onAccountsChanged.bind(this),y.on("accountsChanged",o)),i||(i=this.onChainChanged.bind(this),y.on("chainChanged",i)),l||(l=this.onDisconnect.bind(this),y.on("disconnect",l)),u||(u=this.onSessionDelete.bind(this),y.on("session_delete",u)),{accounts:w,chainId:_}}catch(y){throw/(user rejected|connection request reset)/i.test(y==null?void 0:y.message)?new ht(y):y}},async disconnect(){const f=await this.getProvider();try{await(f==null?void 0:f.disconnect())}catch(p){if(!/No matching key/i.test(p.message))throw p}finally{i&&(f==null||f.removeListener("chainChanged",i),i=void 0),l&&(f==null||f.removeListener("disconnect",l),l=void 0),a||(a=this.onConnect.bind(this),f==null||f.on("connect",a)),o&&(f==null||f.removeListener("accountsChanged",o),o=void 0),u&&(f==null||f.removeListener("session_delete",u),u=void 0),this.setRequestedChainsIds([])}},async getAccounts(){return(await this.getProvider()).accounts.map(p=>Cn(p))},async getProvider({chainId:f}={}){var m;async function p(){const h=d.chains.map(b=>b.id);if(!h.length)return;const{EthereumProvider:y}=await $i(async()=>{const{EthereumProvider:b}=await import("./index.es-DCT-OfME.js");return{EthereumProvider:b}},__vite__mapDeps([4,3,1]));return await y.init({...e,disableProviderPing:!0,optionalChains:h,projectId:e.projectId,rpcMap:Object.fromEntries(d.chains.map(b=>{const[g]=Kk({chain:b,transports:d.transports});return[b.id,g]})),showQrModal:e.showQrModal??!0})}return n||(s||(s=p()),n=await s,n==null||n.events.setMaxListeners(Number.POSITIVE_INFINITY)),f&&await((m=this.switchChain)==null?void 0:m.call(this,{chainId:f})),n},async getChainId(){return(await this.getProvider()).chainId},async isAuthorized(){try{const[f,p]=await Promise.all([this.getAccounts(),this.getProvider()]);return f.length?await this.isChainsStale()&&p.session?(await p.disconnect().catch(()=>{}),!1):!0:!1}catch{return!1}},async switchChain({addEthereumChainParameter:f,chainId:p}){var y,b,g;const m=await this.getProvider();if(!m)throw new xn;const h=d.chains.find(w=>w.id===p);if(!h)throw new Dr(new oc);try{await Promise.all([new Promise(_=>{const A=({chainId:x})=>{x===p&&(d.emitter.off("change",A),_())};d.emitter.on("change",A)}),m.request({method:"wallet_switchEthereumChain",params:[{chainId:Ee(p)}]})]);const w=await this.getRequestedChainsIds();return this.setRequestedChainsIds([...w,p]),h}catch(w){const _=w;if(/(user rejected)/i.test(_.message))throw new ht(_);try{let A;f!=null&&f.blockExplorerUrls?A=f.blockExplorerUrls:A=(y=h.blockExplorers)!=null&&y.default.url?[(b=h.blockExplorers)==null?void 0:b.default.url]:[];let x;(g=f==null?void 0:f.rpcUrls)!=null&&g.length?x=f.rpcUrls:x=[...h.rpcUrls.default.http];const C={blockExplorerUrls:A,chainId:Ee(p),chainName:(f==null?void 0:f.chainName)??h.name,iconUrls:f==null?void 0:f.iconUrls,nativeCurrency:(f==null?void 0:f.nativeCurrency)??h.nativeCurrency,rpcUrls:x};await m.request({method:"wallet_addEthereumChain",params:[C]});const k=await this.getRequestedChainsIds();return this.setRequestedChainsIds([...k,p]),h}catch(A){throw new ht(A)}}},onAccountsChanged(f){f.length===0?this.onDisconnect():d.emitter.emit("change",{accounts:f.map(p=>Cn(p))})},onChainChanged(f){const p=Number(f);d.emitter.emit("change",{chainId:p})},async onConnect(f){const p=Number(f.chainId),m=await this.getAccounts();d.emitter.emit("connect",{accounts:m,chainId:p})},async onDisconnect(f){this.setRequestedChainsIds([]),d.emitter.emit("disconnect");const p=await this.getProvider();o&&(p.removeListener("accountsChanged",o),o=void 0),i&&(p.removeListener("chainChanged",i),i=void 0),l&&(p.removeListener("disconnect",l),l=void 0),u&&(p.removeListener("session_delete",u),u=void 0),a||(a=this.onConnect.bind(this),p.on("connect",a))},onDisplayUri(f){d.emitter.emit("message",{type:"display_uri",data:f})},onSessionDelete(){this.onDisconnect()},getNamespaceChainsIds(){var p,m,h;return n?((h=(m=(p=n.session)==null?void 0:p.namespaces[r])==null?void 0:m.accounts)==null?void 0:h.map(y=>Number.parseInt(y.split(":")[1]||"")))??[]:[]},async getRequestedChainsIds(){var f;return await((f=d.storage)==null?void 0:f.getItem(this.requestedChainsStorageKey))??[]},async isChainsStale(){if(!t)return!1;const f=d.chains.map(h=>h.id),p=this.getNamespaceChainsIds();if(p.length&&!p.some(h=>f.includes(h)))return!1;const m=await this.getRequestedChainsIds();return!f.every(h=>m.includes(h))},async setRequestedChainsIds(f){var p;await((p=d.storage)==null?void 0:p.setItem(this.requestedChainsStorageKey,f))},get requestedChainsStorageKey(){return`${this.id}.requestedChains`}})}var Uo=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(){}},ko=typeof window>"u"||"Deno"in globalThis;function wn(){}function Qk(e,t){return typeof e=="function"?e(t):e}function lp(e){return typeof e=="number"&&e>=0&&e!==1/0}function l_(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ai(e,t){return typeof e=="function"?e(t):e}function On(e,t){return typeof e=="function"?e(t):e}function ib(e,t){const{type:n="all",exact:s,fetchStatus:r,predicate:o,queryKey:i,stale:a}=e;if(i){if(s){if(t.queryHash!==_h(i,t.options))return!1}else if(!ac(t.queryKey,i))return!1}if(n!=="all"){const c=t.isActive();if(n==="active"&&!c||n==="inactive"&&c)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||r&&r!==t.state.fetchStatus||o&&!o(t))}function ab(e,t){const{exact:n,status:s,predicate:r,mutationKey:o}=e;if(o){if(!t.options.mutationKey)return!1;if(n){if(Io(t.options.mutationKey)!==Io(o))return!1}else if(!ac(t.options.mutationKey,o))return!1}return!(s&&t.state.status!==s||r&&!r(t))}function _h(e,t){return((t==null?void 0:t.queryKeyHashFn)||Io)(e)}function Io(e){return JSON.stringify(e,(t,n)=>dp(n)?Object.keys(n).sort().reduce((s,r)=>(s[r]=n[r],s),{}):n)}function ac(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(n=>!ac(e[n],t[n])):!1}function Fl(e,t){if(e===t)return e;const n=cb(e)&&cb(t);if(n||dp(e)&&dp(t)){const s=n?e:Object.keys(e),r=s.length,o=n?t:Object.keys(t),i=o.length,a=n?[]:{};let c=0;for(let u=0;u<i;u++){const l=n?u:o[u];(!n&&s.includes(l)||n)&&e[l]===void 0&&t[l]===void 0?(a[l]=void 0,c++):(a[l]=Fl(e[l],t[l]),a[l]===e[l]&&e[l]!==void 0&&c++)}return r===i&&c===r?e:a}return t}function Gu(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 cb(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function dp(e){if(!ub(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!ub(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function ub(e){return Object.prototype.toString.call(e)==="[object Object]"}function Zk(e){return new Promise(t=>{setTimeout(t,e)})}function fp(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?Fl(e,t):t}function Yk(e,t,n=0){const s=[...e,t];return n&&s.length>n?s.slice(1):s}function Jk(e,t,n=0){const s=[t,...e];return n&&s.length>n?s.slice(0,-1):s}var xh=Symbol();function d_(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===xh?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var co,vr,ui,vv,eI=(vv=class extends Uo{constructor(){super();ge(this,co);ge(this,vr);ge(this,ui);me(this,ui,t=>{if(!ko&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){N(this,vr)||this.setEventListener(N(this,ui))}onUnsubscribe(){var t;this.hasListeners()||((t=N(this,vr))==null||t.call(this),me(this,vr,void 0))}setEventListener(t){var n;me(this,ui,t),(n=N(this,vr))==null||n.call(this),me(this,vr,t(s=>{typeof s=="boolean"?this.setFocused(s):this.onFocus()}))}setFocused(t){N(this,co)!==t&&(me(this,co,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof N(this,co)=="boolean"?N(this,co):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},co=new WeakMap,vr=new WeakMap,ui=new WeakMap,vv),Ch=new eI,li,wr,di,wv,tI=(wv=class extends Uo{constructor(){super();ge(this,li,!0);ge(this,wr);ge(this,di);me(this,di,t=>{if(!ko&&window.addEventListener){const n=()=>t(!0),s=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",s,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",s)}}})}onSubscribe(){N(this,wr)||this.setEventListener(N(this,di))}onUnsubscribe(){var t;this.hasListeners()||((t=N(this,wr))==null||t.call(this),me(this,wr,void 0))}setEventListener(t){var n;me(this,di,t),(n=N(this,wr))==null||n.call(this),me(this,wr,t(this.setOnline.bind(this)))}setOnline(t){N(this,li)!==t&&(me(this,li,t),this.listeners.forEach(s=>{s(t)}))}isOnline(){return N(this,li)}},li=new WeakMap,wr=new WeakMap,di=new WeakMap,wv),Xu=new tI;function pp(){let e,t;const n=new Promise((r,o)=>{e=r,t=o});n.status="pending",n.catch(()=>{});function s(r){Object.assign(n,r),delete n.resolve,delete n.reject}return n.resolve=r=>{s({status:"fulfilled",value:r}),e(r)},n.reject=r=>{s({status:"rejected",reason:r}),t(r)},n}function nI(e){return Math.min(1e3*2**e,3e4)}function f_(e){return(e??"online")==="online"?Xu.isOnline():!0}var p_=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function rf(e){return e instanceof p_}function m_(e){let t=!1,n=0,s=!1,r;const o=pp(),i=h=>{var y;s||(f(new p_(h)),(y=e.abort)==null||y.call(e))},a=()=>{t=!0},c=()=>{t=!1},u=()=>Ch.isFocused()&&(e.networkMode==="always"||Xu.isOnline())&&e.canRun(),l=()=>f_(e.networkMode)&&e.canRun(),d=h=>{var y;s||(s=!0,(y=e.onSuccess)==null||y.call(e,h),r==null||r(),o.resolve(h))},f=h=>{var y;s||(s=!0,(y=e.onError)==null||y.call(e,h),r==null||r(),o.reject(h))},p=()=>new Promise(h=>{var y;r=b=>{(s||u())&&h(b)},(y=e.onPause)==null||y.call(e)}).then(()=>{var h;r=void 0,s||(h=e.onContinue)==null||h.call(e)}),m=()=>{if(s)return;let h;const y=n===0?e.initialPromise:void 0;try{h=y??e.fn()}catch(b){h=Promise.reject(b)}Promise.resolve(h).then(d).catch(b=>{var x;if(s)return;const g=e.retry??(ko?0:3),w=e.retryDelay??nI,_=typeof w=="function"?w(n,b):w,A=g===!0||typeof g=="number"&&n<g||typeof g=="function"&&g(n,b);if(t||!A){f(b);return}n++,(x=e.onFail)==null||x.call(e,n,b),Zk(_).then(()=>u()?void 0:p()).then(()=>{t?f(b):m()})})};return{promise:o,cancel:i,continue:()=>(r==null||r(),o),cancelRetry:a,continueRetry:c,canStart:l,start:()=>(l()?m():p().then(m),o)}}function sI(){let e=[],t=0,n=a=>{a()},s=a=>{a()},r=a=>setTimeout(a,0);const o=a=>{t?e.push(a):r(()=>{n(a)})},i=()=>{const a=e;e=[],a.length&&r(()=>{s(()=>{a.forEach(c=>{n(c)})})})};return{batch:a=>{let c;t++;try{c=a()}finally{t--,t||i()}return c},batchCalls:a=>(...c)=>{o(()=>{a(...c)})},schedule:o,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{s=a},setScheduler:a=>{r=a}}}var bt=sI(),uo,_v,h_=(_v=class{constructor(){ge(this,uo)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),lp(this.gcTime)&&me(this,uo,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(ko?1/0:5*60*1e3))}clearGcTimeout(){N(this,uo)&&(clearTimeout(N(this,uo)),me(this,uo,void 0))}},uo=new WeakMap,_v),fi,pi,gn,Ot,pc,lo,$n,Ts,xv,rI=(xv=class extends h_{constructor(t){super();ge(this,$n);ge(this,fi);ge(this,pi);ge(this,gn);ge(this,Ot);ge(this,pc);ge(this,lo);me(this,lo,!1),me(this,pc,t.defaultOptions),this.setOptions(t.options),this.observers=[],me(this,gn,t.cache),this.queryKey=t.queryKey,this.queryHash=t.queryHash,me(this,fi,oI(this.options)),this.state=t.state??N(this,fi),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=N(this,Ot))==null?void 0:t.promise}setOptions(t){this.options={...N(this,pc),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&N(this,gn).remove(this)}setData(t,n){const s=fp(this.state.data,t,this.options);return Se(this,$n,Ts).call(this,{data:s,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),s}setState(t,n){Se(this,$n,Ts).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var s,r;const n=(s=N(this,Ot))==null?void 0:s.promise;return(r=N(this,Ot))==null||r.cancel(t),n?n.then(wn).catch(wn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(N(this,fi))}isActive(){return this.observers.some(t=>On(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===xh||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(t=0){return this.state.isInvalidated||this.state.data===void 0||!l_(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(s=>s.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=N(this,Ot))==null||n.continue()}onOnline(){var n;const t=this.observers.find(s=>s.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=N(this,Ot))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),N(this,gn).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(N(this,Ot)&&(N(this,lo)?N(this,Ot).cancel({revert:!0}):N(this,Ot).cancelRetry()),this.scheduleGc()),N(this,gn).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Se(this,$n,Ts).call(this,{type:"invalidate"})}fetch(t,n){var c,u,l;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(N(this,Ot))return N(this,Ot).continueRetry(),N(this,Ot).promise}if(t&&this.setOptions(t),!this.options.queryFn){const d=this.observers.find(f=>f.options.queryFn);d&&this.setOptions(d.options)}const s=new AbortController,r=d=>{Object.defineProperty(d,"signal",{enumerable:!0,get:()=>(me(this,lo,!0),s.signal)})},o=()=>{const d=d_(this.options,n),f={queryKey:this.queryKey,meta:this.meta};return r(f),me(this,lo,!1),this.options.persister?this.options.persister(d,f,this):d(f)},i={fetchOptions:n,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:o};r(i),(c=this.options.behavior)==null||c.onFetch(i,this),me(this,pi,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=i.fetchOptions)==null?void 0:u.meta))&&Se(this,$n,Ts).call(this,{type:"fetch",meta:(l=i.fetchOptions)==null?void 0:l.meta});const a=d=>{var f,p,m,h;rf(d)&&d.silent||Se(this,$n,Ts).call(this,{type:"error",error:d}),rf(d)||((p=(f=N(this,gn).config).onError)==null||p.call(f,d,this),(h=(m=N(this,gn).config).onSettled)==null||h.call(m,this.state.data,d,this)),this.scheduleGc()};return me(this,Ot,m_({initialPromise:n==null?void 0:n.initialPromise,fn:i.fetchFn,abort:s.abort.bind(s),onSuccess:d=>{var f,p,m,h;if(d===void 0){a(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(d)}catch(y){a(y);return}(p=(f=N(this,gn).config).onSuccess)==null||p.call(f,d,this),(h=(m=N(this,gn).config).onSettled)==null||h.call(m,d,this.state.error,this),this.scheduleGc()},onError:a,onFail:(d,f)=>{Se(this,$n,Ts).call(this,{type:"failed",failureCount:d,error:f})},onPause:()=>{Se(this,$n,Ts).call(this,{type:"pause"})},onContinue:()=>{Se(this,$n,Ts).call(this,{type:"continue"})},retry:i.options.retry,retryDelay:i.options.retryDelay,networkMode:i.options.networkMode,canRun:()=>!0})),N(this,Ot).start()}},fi=new WeakMap,pi=new WeakMap,gn=new WeakMap,Ot=new WeakMap,pc=new WeakMap,lo=new WeakMap,$n=new WeakSet,Ts=function(t){const n=s=>{switch(t.type){case"failed":return{...s,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...s,fetchStatus:"paused"};case"continue":return{...s,fetchStatus:"fetching"};case"fetch":return{...s,...y_(s.data,this.options),fetchMeta:t.meta??null};case"success":return{...s,data:t.data,dataUpdateCount:s.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const r=t.error;return rf(r)&&r.revert&&N(this,pi)?{...N(this,pi),fetchStatus:"idle"}:{...s,error:r,errorUpdateCount:s.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:s.fetchFailureCount+1,fetchFailureReason:r,fetchStatus:"idle",status:"error"};case"invalidate":return{...s,isInvalidated:!0};case"setState":return{...s,...t.state}}};this.state=n(this.state),bt.batch(()=>{this.observers.forEach(s=>{s.onQueryUpdate()}),N(this,gn).notify({query:this,type:"updated",action:t})})},xv);function y_(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:f_(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function oI(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,s=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?s??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var es,Cv,b_=(Cv=class extends Uo{constructor(n={}){super();ge(this,es);this.config=n,me(this,es,new Map)}build(n,s,r){const o=s.queryKey,i=s.queryHash??_h(o,s);let a=this.get(i);return a||(a=new rI({cache:this,queryKey:o,queryHash:i,options:n.defaultQueryOptions(s),state:r,defaultOptions:n.getQueryDefaults(o)}),this.add(a)),a}add(n){N(this,es).has(n.queryHash)||(N(this,es).set(n.queryHash,n),this.notify({type:"added",query:n}))}remove(n){const s=N(this,es).get(n.queryHash);s&&(n.destroy(),s===n&&N(this,es).delete(n.queryHash),this.notify({type:"removed",query:n}))}clear(){bt.batch(()=>{this.getAll().forEach(n=>{this.remove(n)})})}get(n){return N(this,es).get(n)}getAll(){return[...N(this,es).values()]}find(n){const s={exact:!0,...n};return this.getAll().find(r=>ib(s,r))}findAll(n={}){const s=this.getAll();return Object.keys(n).length>0?s.filter(r=>ib(n,r)):s}notify(n){bt.batch(()=>{this.listeners.forEach(s=>{s(n)})})}onFocus(){bt.batch(()=>{this.getAll().forEach(n=>{n.onFocus()})})}onOnline(){bt.batch(()=>{this.getAll().forEach(n=>{n.onOnline()})})}},es=new WeakMap,Cv),ts,Vt,fo,ns,dr,Av,iI=(Av=class extends h_{constructor(t){super();ge(this,ns);ge(this,ts);ge(this,Vt);ge(this,fo);this.mutationId=t.mutationId,me(this,Vt,t.mutationCache),me(this,ts,[]),this.state=t.state||g_(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){N(this,ts).includes(t)||(N(this,ts).push(t),this.clearGcTimeout(),N(this,Vt).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){me(this,ts,N(this,ts).filter(n=>n!==t)),this.scheduleGc(),N(this,Vt).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){N(this,ts).length||(this.state.status==="pending"?this.scheduleGc():N(this,Vt).remove(this))}continue(){var t;return((t=N(this,fo))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var r,o,i,a,c,u,l,d,f,p,m,h,y,b,g,w,_,A,x,C;me(this,fo,m_({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(k,S)=>{Se(this,ns,dr).call(this,{type:"failed",failureCount:k,error:S})},onPause:()=>{Se(this,ns,dr).call(this,{type:"pause"})},onContinue:()=>{Se(this,ns,dr).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>N(this,Vt).canRun(this)}));const n=this.state.status==="pending",s=!N(this,fo).canStart();try{if(!n){Se(this,ns,dr).call(this,{type:"pending",variables:t,isPaused:s}),await((o=(r=N(this,Vt).config).onMutate)==null?void 0:o.call(r,t,this));const S=await((a=(i=this.options).onMutate)==null?void 0:a.call(i,t));S!==this.state.context&&Se(this,ns,dr).call(this,{type:"pending",context:S,variables:t,isPaused:s})}const k=await N(this,fo).start();return await((u=(c=N(this,Vt).config).onSuccess)==null?void 0:u.call(c,k,t,this.state.context,this)),await((d=(l=this.options).onSuccess)==null?void 0:d.call(l,k,t,this.state.context)),await((p=(f=N(this,Vt).config).onSettled)==null?void 0:p.call(f,k,null,this.state.variables,this.state.context,this)),await((h=(m=this.options).onSettled)==null?void 0:h.call(m,k,null,t,this.state.context)),Se(this,ns,dr).call(this,{type:"success",data:k}),k}catch(k){try{throw await((b=(y=N(this,Vt).config).onError)==null?void 0:b.call(y,k,t,this.state.context,this)),await((w=(g=this.options).onError)==null?void 0:w.call(g,k,t,this.state.context)),await((A=(_=N(this,Vt).config).onSettled)==null?void 0:A.call(_,void 0,k,this.state.variables,this.state.context,this)),await((C=(x=this.options).onSettled)==null?void 0:C.call(x,void 0,k,t,this.state.context)),k}finally{Se(this,ns,dr).call(this,{type:"error",error:k})}}finally{N(this,Vt).runNext(this)}}},ts=new WeakMap,Vt=new WeakMap,fo=new WeakMap,ns=new WeakSet,dr=function(t){const n=s=>{switch(t.type){case"failed":return{...s,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...s,isPaused:!0};case"continue":return{...s,isPaused:!1};case"pending":return{...s,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{...s,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...s,data:void 0,error:t.error,failureCount:s.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),bt.batch(()=>{N(this,ts).forEach(s=>{s.onMutationUpdate(t)}),N(this,Vt).notify({mutation:this,type:"updated",action:t})})},Av);function g_(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var on,mc,Tv,v_=(Tv=class extends Uo{constructor(n={}){super();ge(this,on);ge(this,mc);this.config=n,me(this,on,new Map),me(this,mc,Date.now())}build(n,s,r){const o=new iI({mutationCache:this,mutationId:++Uc(this,mc)._,options:n.defaultMutationOptions(s),state:r});return this.add(o),o}add(n){const s=su(n),r=N(this,on).get(s)??[];r.push(n),N(this,on).set(s,r),this.notify({type:"added",mutation:n})}remove(n){var r;const s=su(n);if(N(this,on).has(s)){const o=(r=N(this,on).get(s))==null?void 0:r.filter(i=>i!==n);o&&(o.length===0?N(this,on).delete(s):N(this,on).set(s,o))}this.notify({type:"removed",mutation:n})}canRun(n){var r;const s=(r=N(this,on).get(su(n)))==null?void 0:r.find(o=>o.state.status==="pending");return!s||s===n}runNext(n){var r;const s=(r=N(this,on).get(su(n)))==null?void 0:r.find(o=>o!==n&&o.state.isPaused);return(s==null?void 0:s.continue())??Promise.resolve()}clear(){bt.batch(()=>{this.getAll().forEach(n=>{this.remove(n)})})}getAll(){return[...N(this,on).values()].flat()}find(n){const s={exact:!0,...n};return this.getAll().find(r=>ab(s,r))}findAll(n={}){return this.getAll().filter(s=>ab(n,s))}notify(n){bt.batch(()=>{this.listeners.forEach(s=>{s(n)})})}resumePausedMutations(){const n=this.getAll().filter(s=>s.state.isPaused);return bt.batch(()=>Promise.all(n.map(s=>s.continue().catch(wn))))}},on=new WeakMap,mc=new WeakMap,Tv);function su(e){var t;return((t=e.options.scope)==null?void 0:t.id)??String(e.mutationId)}function lb(e){return{onFetch:(t,n)=>{var l,d,f,p,m;const s=t.options,r=(f=(d=(l=t.fetchOptions)==null?void 0:l.meta)==null?void 0:d.fetchMore)==null?void 0:f.direction,o=((p=t.state.data)==null?void 0:p.pages)||[],i=((m=t.state.data)==null?void 0:m.pageParams)||[];let a={pages:[],pageParams:[]},c=0;const u=async()=>{let h=!1;const y=w=>{Object.defineProperty(w,"signal",{enumerable:!0,get:()=>(t.signal.aborted?h=!0:t.signal.addEventListener("abort",()=>{h=!0}),t.signal)})},b=d_(t.options,t.fetchOptions),g=async(w,_,A)=>{if(h)return Promise.reject();if(_==null&&w.pages.length)return Promise.resolve(w);const x={queryKey:t.queryKey,pageParam:_,direction:A?"backward":"forward",meta:t.options.meta};y(x);const C=await b(x),{maxPages:k}=t.options,S=A?Jk:Yk;return{pages:S(w.pages,C,k),pageParams:S(w.pageParams,_,k)}};if(r&&o.length){const w=r==="backward",_=w?aI:db,A={pages:o,pageParams:i},x=_(s,A);a=await g(A,x,w)}else{const w=e??o.length;do{const _=c===0?i[0]??s.initialPageParam:db(s,a);if(c>0&&_==null)break;a=await g(a,_),c++}while(c<w)}return a};t.options.persister?t.fetchFn=()=>{var h,y;return(y=(h=t.options).persister)==null?void 0:y.call(h,u,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function db(e,{pages:t,pageParams:n}){const s=t.length-1;return t.length>0?e.getNextPageParam(t[s],t,n[s],n):void 0}function aI(e,{pages:t,pageParams:n}){var s;return t.length>0?(s=e.getPreviousPageParam)==null?void 0:s.call(e,t[0],t,n[0],n):void 0}var it,_r,xr,mi,hi,Cr,yi,bi,Ev,cI=(Ev=class{constructor(t={}){ge(this,it);ge(this,_r);ge(this,xr);ge(this,mi);ge(this,hi);ge(this,Cr);ge(this,yi);ge(this,bi);me(this,it,t.queryCache||new b_),me(this,_r,t.mutationCache||new v_),me(this,xr,t.defaultOptions||{}),me(this,mi,new Map),me(this,hi,new Map),me(this,Cr,0)}mount(){Uc(this,Cr)._++,N(this,Cr)===1&&(me(this,yi,Ch.subscribe(async t=>{t&&(await this.resumePausedMutations(),N(this,it).onFocus())})),me(this,bi,Xu.subscribe(async t=>{t&&(await this.resumePausedMutations(),N(this,it).onOnline())})))}unmount(){var t,n;Uc(this,Cr)._--,N(this,Cr)===0&&((t=N(this,yi))==null||t.call(this),me(this,yi,void 0),(n=N(this,bi))==null||n.call(this),me(this,bi,void 0))}isFetching(t){return N(this,it).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return N(this,_r).findAll({...t,status:"pending"}).length}getQueryData(t){var s;const n=this.defaultQueryOptions({queryKey:t});return(s=N(this,it).get(n.queryHash))==null?void 0:s.state.data}ensureQueryData(t){const n=this.getQueryData(t.queryKey);if(n===void 0)return this.fetchQuery(t);{const s=this.defaultQueryOptions(t),r=N(this,it).build(this,s);return t.revalidateIfStale&&r.isStaleByTime(ai(s.staleTime,r))&&this.prefetchQuery(s),Promise.resolve(n)}}getQueriesData(t){return N(this,it).findAll(t).map(({queryKey:n,state:s})=>{const r=s.data;return[n,r]})}setQueryData(t,n,s){const r=this.defaultQueryOptions({queryKey:t}),o=N(this,it).get(r.queryHash),i=o==null?void 0:o.state.data,a=Qk(n,i);if(a!==void 0)return N(this,it).build(this,r).setData(a,{...s,manual:!0})}setQueriesData(t,n,s){return bt.batch(()=>N(this,it).findAll(t).map(({queryKey:r})=>[r,this.setQueryData(r,n,s)]))}getQueryState(t){var s;const n=this.defaultQueryOptions({queryKey:t});return(s=N(this,it).get(n.queryHash))==null?void 0:s.state}removeQueries(t){const n=N(this,it);bt.batch(()=>{n.findAll(t).forEach(s=>{n.remove(s)})})}resetQueries(t,n){const s=N(this,it),r={type:"active",...t};return bt.batch(()=>(s.findAll(t).forEach(o=>{o.reset()}),this.refetchQueries(r,n)))}cancelQueries(t={},n={}){const s={revert:!0,...n},r=bt.batch(()=>N(this,it).findAll(t).map(o=>o.cancel(s)));return Promise.all(r).then(wn).catch(wn)}invalidateQueries(t={},n={}){return bt.batch(()=>{if(N(this,it).findAll(t).forEach(r=>{r.invalidate()}),t.refetchType==="none")return Promise.resolve();const s={...t,type:t.refetchType??t.type??"active"};return this.refetchQueries(s,n)})}refetchQueries(t={},n){const s={...n,cancelRefetch:(n==null?void 0:n.cancelRefetch)??!0},r=bt.batch(()=>N(this,it).findAll(t).filter(o=>!o.isDisabled()).map(o=>{let i=o.fetch(void 0,s);return s.throwOnError||(i=i.catch(wn)),o.state.fetchStatus==="paused"?Promise.resolve():i}));return Promise.all(r).then(wn)}fetchQuery(t){const n=this.defaultQueryOptions(t);n.retry===void 0&&(n.retry=!1);const s=N(this,it).build(this,n);return s.isStaleByTime(ai(n.staleTime,s))?s.fetch(n):Promise.resolve(s.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(wn).catch(wn)}fetchInfiniteQuery(t){return t.behavior=lb(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(wn).catch(wn)}ensureInfiniteQueryData(t){return t.behavior=lb(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return Xu.isOnline()?N(this,_r).resumePausedMutations():Promise.resolve()}getQueryCache(){return N(this,it)}getMutationCache(){return N(this,_r)}getDefaultOptions(){return N(this,xr)}setDefaultOptions(t){me(this,xr,t)}setQueryDefaults(t,n){N(this,mi).set(Io(t),{queryKey:t,defaultOptions:n})}getQueryDefaults(t){const n=[...N(this,mi).values()];let s={};return n.forEach(r=>{ac(t,r.queryKey)&&(s={...s,...r.defaultOptions})}),s}setMutationDefaults(t,n){N(this,hi).set(Io(t),{mutationKey:t,defaultOptions:n})}getMutationDefaults(t){const n=[...N(this,hi).values()];let s={};return n.forEach(r=>{ac(t,r.mutationKey)&&(s={...s,...r.defaultOptions})}),s}defaultQueryOptions(t){if(t._defaulted)return t;const n={...N(this,xr).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return n.queryHash||(n.queryHash=_h(n.queryKey,n)),n.refetchOnReconnect===void 0&&(n.refetchOnReconnect=n.networkMode!=="always"),n.throwOnError===void 0&&(n.throwOnError=!!n.suspense),!n.networkMode&&n.persister&&(n.networkMode="offlineFirst"),n.enabled!==!0&&n.queryFn===xh&&(n.enabled=!1),n}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...N(this,xr).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){N(this,it).clear(),N(this,_r).clear()}},it=new WeakMap,_r=new WeakMap,xr=new WeakMap,mi=new WeakMap,hi=new WeakMap,Cr=new WeakMap,yi=new WeakMap,bi=new WeakMap,Ev),Xt,Ue,hc,jt,po,gi,Ar,ss,yc,vi,wi,mo,ho,Tr,_i,Ge,_a,mp,hp,yp,bp,gp,vp,wp,__,Sv,w_=(Sv=class extends Uo{constructor(t,n){super();ge(this,Ge);ge(this,Xt);ge(this,Ue);ge(this,hc);ge(this,jt);ge(this,po);ge(this,gi);ge(this,Ar);ge(this,ss);ge(this,yc);ge(this,vi);ge(this,wi);ge(this,mo);ge(this,ho);ge(this,Tr);ge(this,_i,new Set);this.options=n,me(this,Xt,t),me(this,ss,null),me(this,Ar,pp()),this.options.experimental_prefetchInRender||N(this,Ar).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(N(this,Ue).addObserver(this),fb(N(this,Ue),this.options)?Se(this,Ge,_a).call(this):this.updateResult(),Se(this,Ge,bp).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return _p(N(this,Ue),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return _p(N(this,Ue),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Se(this,Ge,gp).call(this),Se(this,Ge,vp).call(this),N(this,Ue).removeObserver(this)}setOptions(t,n){const s=this.options,r=N(this,Ue);if(this.options=N(this,Xt).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof On(this.options.enabled,N(this,Ue))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Se(this,Ge,wp).call(this),N(this,Ue).setOptions(this.options),s._defaulted&&!Gu(this.options,s)&&N(this,Xt).getQueryCache().notify({type:"observerOptionsUpdated",query:N(this,Ue),observer:this});const o=this.hasListeners();o&&pb(N(this,Ue),r,this.options,s)&&Se(this,Ge,_a).call(this),this.updateResult(n),o&&(N(this,Ue)!==r||On(this.options.enabled,N(this,Ue))!==On(s.enabled,N(this,Ue))||ai(this.options.staleTime,N(this,Ue))!==ai(s.staleTime,N(this,Ue)))&&Se(this,Ge,mp).call(this);const i=Se(this,Ge,hp).call(this);o&&(N(this,Ue)!==r||On(this.options.enabled,N(this,Ue))!==On(s.enabled,N(this,Ue))||i!==N(this,Tr))&&Se(this,Ge,yp).call(this,i)}getOptimisticResult(t){const n=N(this,Xt).getQueryCache().build(N(this,Xt),t),s=this.createResult(n,t);return lI(this,s)&&(me(this,jt,s),me(this,gi,this.options),me(this,po,N(this,Ue).state)),s}getCurrentResult(){return N(this,jt)}trackResult(t,n){const s={};return Object.keys(t).forEach(r=>{Object.defineProperty(s,r,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(r),n==null||n(r),t[r])})}),s}trackProp(t){N(this,_i).add(t)}getCurrentQuery(){return N(this,Ue)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=N(this,Xt).defaultQueryOptions(t),s=N(this,Xt).getQueryCache().build(N(this,Xt),n);return s.fetch().then(()=>this.createResult(s,n))}fetch(t){return Se(this,Ge,_a).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),N(this,jt)))}createResult(t,n){var k;const s=N(this,Ue),r=this.options,o=N(this,jt),i=N(this,po),a=N(this,gi),u=t!==s?t.state:N(this,hc),{state:l}=t;let d={...l},f=!1,p;if(n._optimisticResults){const S=this.hasListeners(),R=!S&&fb(t,n),B=S&&pb(t,s,n,r);(R||B)&&(d={...d,...y_(l.data,t.options)}),n._optimisticResults==="isRestoring"&&(d.fetchStatus="idle")}let{error:m,errorUpdatedAt:h,status:y}=d;if(n.select&&d.data!==void 0)if(o&&d.data===(i==null?void 0:i.data)&&n.select===N(this,yc))p=N(this,vi);else try{me(this,yc,n.select),p=n.select(d.data),p=fp(o==null?void 0:o.data,p,n),me(this,vi,p),me(this,ss,null)}catch(S){me(this,ss,S)}else p=d.data;if(n.placeholderData!==void 0&&p===void 0&&y==="pending"){let S;if(o!=null&&o.isPlaceholderData&&n.placeholderData===(a==null?void 0:a.placeholderData))S=o.data;else if(S=typeof n.placeholderData=="function"?n.placeholderData((k=N(this,wi))==null?void 0:k.state.data,N(this,wi)):n.placeholderData,n.select&&S!==void 0)try{S=n.select(S),me(this,ss,null)}catch(R){me(this,ss,R)}S!==void 0&&(y="success",p=fp(o==null?void 0:o.data,S,n),f=!0)}N(this,ss)&&(m=N(this,ss),p=N(this,vi),h=Date.now(),y="error");const b=d.fetchStatus==="fetching",g=y==="pending",w=y==="error",_=g&&b,A=p!==void 0,C={status:y,fetchStatus:d.fetchStatus,isPending:g,isSuccess:y==="success",isError:w,isInitialLoading:_,isLoading:_,data:p,dataUpdatedAt:d.dataUpdatedAt,error:m,errorUpdatedAt:h,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>u.dataUpdateCount||d.errorUpdateCount>u.errorUpdateCount,isFetching:b,isRefetching:b&&!g,isLoadingError:w&&!A,isPaused:d.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:w&&A,isStale:Ah(t,n),refetch:this.refetch,promise:N(this,Ar)};if(this.options.experimental_prefetchInRender){const S=L=>{C.status==="error"?L.reject(C.error):C.data!==void 0&&L.resolve(C.data)},R=()=>{const L=me(this,Ar,C.promise=pp());S(L)},B=N(this,Ar);switch(B.status){case"pending":t.queryHash===s.queryHash&&S(B);break;case"fulfilled":(C.status==="error"||C.data!==B.value)&&R();break;case"rejected":(C.status!=="error"||C.error!==B.reason)&&R();break}}return C}updateResult(t){const n=N(this,jt),s=this.createResult(N(this,Ue),this.options);if(me(this,po,N(this,Ue).state),me(this,gi,this.options),N(this,po).data!==void 0&&me(this,wi,N(this,Ue)),Gu(s,n))return;me(this,jt,s);const r={},o=()=>{if(!n)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!N(this,_i).size)return!0;const c=new Set(a??N(this,_i));return this.options.throwOnError&&c.add("error"),Object.keys(N(this,jt)).some(u=>{const l=u;return N(this,jt)[l]!==n[l]&&c.has(l)})};(t==null?void 0:t.listeners)!==!1&&o()&&(r.listeners=!0),Se(this,Ge,__).call(this,{...r,...t})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Se(this,Ge,bp).call(this)}},Xt=new WeakMap,Ue=new WeakMap,hc=new WeakMap,jt=new WeakMap,po=new WeakMap,gi=new WeakMap,Ar=new WeakMap,ss=new WeakMap,yc=new WeakMap,vi=new WeakMap,wi=new WeakMap,mo=new WeakMap,ho=new WeakMap,Tr=new WeakMap,_i=new WeakMap,Ge=new WeakSet,_a=function(t){Se(this,Ge,wp).call(this);let n=N(this,Ue).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(wn)),n},mp=function(){Se(this,Ge,gp).call(this);const t=ai(this.options.staleTime,N(this,Ue));if(ko||N(this,jt).isStale||!lp(t))return;const s=l_(N(this,jt).dataUpdatedAt,t)+1;me(this,mo,setTimeout(()=>{N(this,jt).isStale||this.updateResult()},s))},hp=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(N(this,Ue)):this.options.refetchInterval)??!1},yp=function(t){Se(this,Ge,vp).call(this),me(this,Tr,t),!(ko||On(this.options.enabled,N(this,Ue))===!1||!lp(N(this,Tr))||N(this,Tr)===0)&&me(this,ho,setInterval(()=>{(this.options.refetchIntervalInBackground||Ch.isFocused())&&Se(this,Ge,_a).call(this)},N(this,Tr)))},bp=function(){Se(this,Ge,mp).call(this),Se(this,Ge,yp).call(this,Se(this,Ge,hp).call(this))},gp=function(){N(this,mo)&&(clearTimeout(N(this,mo)),me(this,mo,void 0))},vp=function(){N(this,ho)&&(clearInterval(N(this,ho)),me(this,ho,void 0))},wp=function(){const t=N(this,Xt).getQueryCache().build(N(this,Xt),this.options);if(t===N(this,Ue))return;const n=N(this,Ue);me(this,Ue,t),me(this,hc,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},__=function(t){bt.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(N(this,jt))}),N(this,Xt).getQueryCache().notify({query:N(this,Ue),type:"observerResultsUpdated"})})},Sv);function uI(e,t){return On(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function fb(e,t){return uI(e,t)||e.state.data!==void 0&&_p(e,t,t.refetchOnMount)}function _p(e,t,n){if(On(t.enabled,e)!==!1){const s=typeof n=="function"?n(e):n;return s==="always"||s!==!1&&Ah(e,t)}return!1}function pb(e,t,n,s){return(e!==t||On(s.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&Ah(e,n)}function Ah(e,t){return On(t.enabled,e)!==!1&&e.isStaleByTime(ai(t.staleTime,e))}function lI(e,t){return!Gu(e.getCurrentResult(),t)}function mb(e,t){return e.filter(n=>!t.includes(n))}function dI(e,t,n){const s=e.slice(0);return s[t]=n,s}var xi,vn,Ci,Ai,an,Er,bc,gc,tn,xp,Cp,Ap,Tp,Pv,fI=(Pv=class extends Uo{constructor(t,n,s){super();ge(this,tn);ge(this,xi);ge(this,vn);ge(this,Ci);ge(this,Ai);ge(this,an);ge(this,Er);ge(this,bc);ge(this,gc);me(this,xi,t),me(this,Ai,s),me(this,Ci,[]),me(this,an,[]),me(this,vn,[]),this.setQueries(n)}onSubscribe(){this.listeners.size===1&&N(this,an).forEach(t=>{t.subscribe(n=>{Se(this,tn,Ap).call(this,t,n)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,N(this,an).forEach(t=>{t.destroy()})}setQueries(t,n,s){me(this,Ci,t),me(this,Ai,n),bt.batch(()=>{const r=N(this,an),o=Se(this,tn,Cp).call(this,N(this,Ci));o.forEach(u=>u.observer.setOptions(u.defaultedQueryOptions,s));const i=o.map(u=>u.observer),a=i.map(u=>u.getCurrentResult()),c=i.some((u,l)=>u!==r[l]);r.length===i.length&&!c||(me(this,an,i),me(this,vn,a),this.hasListeners()&&(mb(r,i).forEach(u=>{u.destroy()}),mb(i,r).forEach(u=>{u.subscribe(l=>{Se(this,tn,Ap).call(this,u,l)})}),Se(this,tn,Tp).call(this)))})}getCurrentResult(){return N(this,vn)}getQueries(){return N(this,an).map(t=>t.getCurrentQuery())}getObservers(){return N(this,an)}getOptimisticResult(t,n){const s=Se(this,tn,Cp).call(this,t),r=s.map(o=>o.observer.getOptimisticResult(o.defaultedQueryOptions));return[r,o=>Se(this,tn,xp).call(this,o??r,n),()=>s.map((o,i)=>{const a=r[i];return o.defaultedQueryOptions.notifyOnChangeProps?a:o.observer.trackResult(a,c=>{s.forEach(u=>{u.observer.trackProp(c)})})})]}},xi=new WeakMap,vn=new WeakMap,Ci=new WeakMap,Ai=new WeakMap,an=new WeakMap,Er=new WeakMap,bc=new WeakMap,gc=new WeakMap,tn=new WeakSet,xp=function(t,n){return n?((!N(this,Er)||N(this,vn)!==N(this,gc)||n!==N(this,bc))&&(me(this,bc,n),me(this,gc,N(this,vn)),me(this,Er,Fl(N(this,Er),n(t)))),N(this,Er)):t},Cp=function(t){const n=new Map(N(this,an).map(r=>[r.options.queryHash,r])),s=[];return t.forEach(r=>{const o=N(this,xi).defaultQueryOptions(r),i=n.get(o.queryHash);if(i)s.push({defaultedQueryOptions:o,observer:i});else{const a=N(this,an).find(c=>c.options.queryHash===o.queryHash);s.push({defaultedQueryOptions:o,observer:a??new w_(N(this,xi),o)})}}),s.sort((r,o)=>t.findIndex(i=>i.queryHash===r.defaultedQueryOptions.queryHash)-t.findIndex(i=>i.queryHash===o.defaultedQueryOptions.queryHash))},Ap=function(t,n){const s=N(this,an).indexOf(t);s!==-1&&(me(this,vn,dI(N(this,vn),s,n)),Se(this,tn,Tp).call(this))},Tp=function(){var t;if(this.hasListeners()){const n=N(this,Er),s=Se(this,tn,xp).call(this,N(this,vn),(t=N(this,Ai))==null?void 0:t.combine);n!==s&&bt.batch(()=>{this.listeners.forEach(r=>{r(N(this,vn))})})}},Pv),Sr,Pr,Kt,Is,Hs,Cu,Ep,kv,pI=(kv=class extends Uo{constructor(n,s){super();ge(this,Hs);ge(this,Sr);ge(this,Pr);ge(this,Kt);ge(this,Is);me(this,Sr,n),this.setOptions(s),this.bindMethods(),Se(this,Hs,Cu).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(n){var r;const s=this.options;this.options=N(this,Sr).defaultMutationOptions(n),Gu(this.options,s)||N(this,Sr).getMutationCache().notify({type:"observerOptionsUpdated",mutation:N(this,Kt),observer:this}),s!=null&&s.mutationKey&&this.options.mutationKey&&Io(s.mutationKey)!==Io(this.options.mutationKey)?this.reset():((r=N(this,Kt))==null?void 0:r.state.status)==="pending"&&N(this,Kt).setOptions(this.options)}onUnsubscribe(){var n;this.hasListeners()||(n=N(this,Kt))==null||n.removeObserver(this)}onMutationUpdate(n){Se(this,Hs,Cu).call(this),Se(this,Hs,Ep).call(this,n)}getCurrentResult(){return N(this,Pr)}reset(){var n;(n=N(this,Kt))==null||n.removeObserver(this),me(this,Kt,void 0),Se(this,Hs,Cu).call(this),Se(this,Hs,Ep).call(this)}mutate(n,s){var r;return me(this,Is,s),(r=N(this,Kt))==null||r.removeObserver(this),me(this,Kt,N(this,Sr).getMutationCache().build(N(this,Sr),this.options)),N(this,Kt).addObserver(this),N(this,Kt).execute(n)}},Sr=new WeakMap,Pr=new WeakMap,Kt=new WeakMap,Is=new WeakMap,Hs=new WeakSet,Cu=function(){var s;const n=((s=N(this,Kt))==null?void 0:s.state)??g_();me(this,Pr,{...n,isPending:n.status==="pending",isSuccess:n.status==="success",isError:n.status==="error",isIdle:n.status==="idle",mutate:this.mutate,reset:this.reset})},Ep=function(n){bt.batch(()=>{var s,r,o,i,a,c,u,l;if(N(this,Is)&&this.hasListeners()){const d=N(this,Pr).variables,f=N(this,Pr).context;(n==null?void 0:n.type)==="success"?((r=(s=N(this,Is)).onSuccess)==null||r.call(s,n.data,d,f),(i=(o=N(this,Is)).onSettled)==null||i.call(o,n.data,null,d,f)):(n==null?void 0:n.type)==="error"&&((c=(a=N(this,Is)).onError)==null||c.call(a,n.error,d,f),(l=(u=N(this,Is)).onSettled)==null||l.call(u,void 0,n.error,d,f))}this.listeners.forEach(d=>{d(N(this,Pr))})})},kv),mI=!1,hI="VUE_QUERY_CLIENT";function x_(e){const t=e?`:${e}`:"";return`${hI}${t}`}function Sp(e,t){Object.keys(e).forEach(n=>{e[n]=t[n]})}function Pp(e,t,n="",s=0){if(t){const r=t(e,n,s);if(r===void 0&&$e(e)||r!==void 0)return r}if(Array.isArray(e))return e.map((r,o)=>Pp(r,t,String(o),s+1));if(typeof e=="object"&&bI(e)){const r=Object.entries(e).map(([o,i])=>[o,Pp(i,t,o,s+1)]);return Object.fromEntries(r)}return e}function yI(e,t){return Pp(e,t)}function Be(e,t=!1){return yI(e,(n,s,r)=>{if(r===1&&s==="queryKey")return Be(n,!0);if(t&&gI(n))return Be(n(),t);if($e(n))return Be(v(n),t)})}function bI(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;const t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function gI(e){return typeof e=="function"}function kp(e,t){return typeof e=="function"?e(...t):!!e}function Nl(e=""){if(!Em())throw new Error("vue-query hooks can only be used inside setup() function or functions that support injection context.");const t=x_(e),n=Nt(t);if(!n)throw new Error("No 'queryClient' found in Vue context, use 'VueQueryPlugin' to properly initialize the library.");return n}var C_=class extends b_{find(e){return super.find(Be(e))}findAll(e={}){return super.findAll(Be(e))}},vI=class extends v_{find(e){return super.find(Be(e))}findAll(e={}){return super.findAll(Be(e))}},A_=class extends cI{constructor(e={}){const t={defaultOptions:e.defaultOptions,queryCache:e.queryCache||new C_,mutationCache:e.mutationCache||new vI};super(t),this.isRestoring=le(!1)}isFetching(e={}){return super.isFetching(Be(e))}isMutating(e={}){return super.isMutating(Be(e))}getQueryData(e){return super.getQueryData(Be(e))}ensureQueryData(e){return super.ensureQueryData(Be(e))}getQueriesData(e){return super.getQueriesData(Be(e))}setQueryData(e,t,n={}){return super.setQueryData(Be(e),t,Be(n))}setQueriesData(e,t,n={}){return super.setQueriesData(Be(e),t,Be(n))}getQueryState(e){return super.getQueryState(Be(e))}removeQueries(e={}){return super.removeQueries(Be(e))}resetQueries(e={},t={}){return super.resetQueries(Be(e),Be(t))}cancelQueries(e={},t={}){return super.cancelQueries(Be(e),Be(t))}invalidateQueries(e={},t={}){const n=Be(e),s=Be(t);if(super.invalidateQueries({...n,refetchType:"none"},s),n.refetchType==="none")return Promise.resolve();const r={...n,type:n.refetchType??n.type??"active"};return Js().then(()=>super.refetchQueries(r,s))}refetchQueries(e={},t={}){return super.refetchQueries(Be(e),Be(t))}fetchQuery(e){return super.fetchQuery(Be(e))}prefetchQuery(e){return super.prefetchQuery(Be(e))}fetchInfiniteQuery(e){return super.fetchInfiniteQuery(Be(e))}prefetchInfiniteQuery(e){return super.prefetchInfiniteQuery(Be(e))}setDefaultOptions(e){super.setDefaultOptions(Be(e))}setQueryDefaults(e,t){super.setQueryDefaults(Be(e),Be(t))}getQueryDefaults(e){return super.getQueryDefaults(Be(e))}setMutationDefaults(e,t){super.setMutationDefaults(Be(e),Be(t))}getMutationDefaults(e){return super.getMutationDefaults(Be(e))}},wI={install:(e,t={})=>{const n=x_(t.queryClientKey);let s;if("queryClient"in t&&t.queryClient)s=t.queryClient;else{const i="queryClientConfig"in t?t.queryClientConfig:void 0;s=new A_(i)}ko||s.mount();let r=()=>{};if(t.clientPersister){s.isRestoring.value=!0;const[i,a]=t.clientPersister(s);r=i,a.then(()=>{var c;s.isRestoring.value=!1,(c=t.clientPersisterOnSuccess)==null||c.call(t,s)})}const o=()=>{s.unmount(),r()};if(e.onUnmount)e.onUnmount(o);else{const i=e.unmount;e.unmount=function(){o(),i()}}e.provide(n,s)}};function _I(e,t,n){const s=Nl(),r=M(()=>{const p=Be(t);typeof p.enabled=="function"&&(p.enabled=p.enabled());const m=s.defaultQueryOptions(p);return m._optimisticResults=s.isRestoring.value?"isRestoring":"optimistic",m}),o=new e(s,r.value),i=ul(o.getCurrentResult());let a=()=>{};Ce(s.isRestoring,p=>{p||(a(),a=o.subscribe(m=>{Sp(i,m)}))},{immediate:!0});const c=()=>{o.setOptions(r.value),Sp(i,o.getCurrentResult())};Ce(r,c),Wn(()=>{a()});const u=(...p)=>(c(),i.refetch(...p)),l=()=>new Promise((p,m)=>{let h=()=>{};const y=()=>{if(r.value.enabled!==!1){o.setOptions(r.value);const b=o.getOptimisticResult(r.value);b.isStale?(h(),o.fetchOptimistic(r.value).then(p,g=>{kp(r.value.throwOnError,[g,o.getCurrentQuery()])?m(g):p(o.getCurrentResult())})):(h(),p(b))}};y(),h=Ce(r,y)});Ce(()=>i.error,p=>{if(i.isError&&!i.isFetching&&kp(r.value.throwOnError,[p,o.getCurrentQuery()]))throw p});const f=ll(i);for(const p in i)typeof i[p]=="function"&&(f[p]=i[p]);return f.suspense=l,f.refetch=u,f}function Fn(e,t){return _I(w_,e)}function xI({queries:e,...t},n){const s=Nl(),r=M(()=>v(e).map(l=>{const d=Be(l);typeof d.enabled=="function"&&(d.enabled=l.enabled());const f=s.defaultQueryOptions(d);return f._optimisticResults=s.isRestoring.value?"isRestoring":"optimistic",f})),o=new fI(s,r.value,t),[,i]=o.getOptimisticResult(r.value,t.combine),a=Bo(i());let c=()=>{};return Ce(s.isRestoring,u=>{if(!u){c(),c=o.subscribe(()=>{const[,d]=o.getOptimisticResult(r.value,t.combine);a.value=d()});const[,l]=o.getOptimisticResult(r.value,t.combine);a.value=l()}},{immediate:!0}),Ce(r,()=>{o.setQueries(r.value,t);const[,u]=o.getOptimisticResult(r.value,t.combine);a.value=u()},{flush:"sync"}),Wn(()=>{c()}),a}function Bl(e,t){const n=Nl(),s=M(()=>n.defaultMutationOptions(Be(e))),r=new pI(n,s.value),o=ul(r.getCurrentResult()),i=r.subscribe(l=>{Sp(o,l)}),a=(l,d)=>{r.mutate(l,d).catch(()=>{})};Ce(s,()=>{r.setOptions(s.value)}),Wn(()=>{i()});const u=ll(o);return Ce(()=>o.error,l=>{if(l&&kp(s.value.throwOnError,[l]))throw l}),{...u,mutate:a,mutateAsync:o.mutate,reset:o.reset}}const CI=function(){return null};function Dl(e){return dm()?(Wn(e),!0):!1}function Xs(e){return typeof e=="function"?e():v(e)}const AI=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const TI=e=>e!=null,EI=Object.prototype.toString,SI=e=>EI.call(e)==="[object Object]",Ku=()=>{};function PI(e,t){function n(...s){return new Promise((r,o)=>{Promise.resolve(e(()=>t.apply(this,s),{fn:t,thisArg:this,args:s})).then(r).catch(o)})}return n}const T_=e=>e();function kI(e,t={}){let n,s,r=Ku;const o=a=>{clearTimeout(a),r(),r=Ku};return a=>{const c=Xs(e),u=Xs(t.maxWait);return n&&o(n),c<=0||u!==void 0&&u<=0?(s&&(o(s),s=null),Promise.resolve(a())):new Promise((l,d)=>{r=t.rejectOnCancel?d:l,u&&!s&&(s=setTimeout(()=>{n&&o(n),s=null,l(a())},u)),n=setTimeout(()=>{s&&o(s),s=null,l(a())},c)})}}function II(e=T_){const t=le(!0);function n(){t.value=!1}function s(){t.value=!0}const r=(...o)=>{t.value&&e(...o)};return{isActive:No(t),pause:n,resume:s,eventFilter:r}}function RI(e){return bs()}function E_(e,t,n={}){const{eventFilter:s=T_,...r}=n;return Ce(e,PI(s,t),r)}function $I(e,t,n={}){const{eventFilter:s,...r}=n,{eventFilter:o,pause:i,resume:a,isActive:c}=II(s);return{stop:E_(e,t,{...r,eventFilter:o}),pause:i,resume:a,isActive:c}}function S_(e,t=!0,n){RI()?Gn(e,n):t?e():Js(e)}function MI(e,t,n={}){const{debounce:s=0,maxWait:r=void 0,...o}=n;return E_(e,t,{...o,eventFilter:kI(s,{maxWait:r})})}function Vi(e,t,n){const s=Ce(e,(r,o,i)=>{r&&(n!=null&&n.once&&Js(()=>s()),t(r,o,i))},{...n,once:!1});return s}function ti(e,t,n){let s;$e(n)?s={evaluating:n}:s={};const{lazy:r=!1,evaluating:o=void 0,shallow:i=!0,onError:a=Ku}=s,c=le(!r),u=i?Bo(t):le(t);let l=0;return pl(async d=>{if(!c.value)return;l++;const f=l;let p=!1;o&&Promise.resolve().then(()=>{o.value=!0});try{const m=await e(h=>{d(()=>{o&&(o.value=!1),p||h()})});f===l&&(u.value=m)}catch(m){a(m)}finally{o&&f===l&&(o.value=!1),p=!0}}),r?M(()=>(c.value=!0,u.value)):u}const ji=AI?window:void 0;function P_(e){var t;const n=Xs(e);return(t=n==null?void 0:n.$el)!=null?t:n}function Ip(...e){let t,n,s,r;if(typeof e[0]=="string"||Array.isArray(e[0])?([n,s,r]=e,t=ji):[t,n,s,r]=e,!t)return Ku;Array.isArray(n)||(n=[n]),Array.isArray(s)||(s=[s]);const o=[],i=()=>{o.forEach(l=>l()),o.length=0},a=(l,d,f,p)=>(l.addEventListener(d,f,p),()=>l.removeEventListener(d,f,p)),c=Ce(()=>[P_(t),Xs(r)],([l,d])=>{if(i(),!l)return;const f=SI(d)?{...d}:d;o.push(...n.flatMap(p=>s.map(m=>a(l,p,m,f))))},{immediate:!0,flush:"post"}),u=()=>{c(),i()};return Dl(u),u}function OI(){const e=le(!1),t=bs();return t&&Gn(()=>{e.value=!0},t),e}function k_(e){const t=OI();return M(()=>(t.value,!!e()))}function LI(e,t,n={}){const{window:s=ji,...r}=n;let o;const i=k_(()=>s&&"MutationObserver"in s),a=()=>{o&&(o.disconnect(),o=void 0)},c=M(()=>{const f=Xs(e),p=(Array.isArray(f)?f:[f]).map(P_).filter(TI);return new Set(p)}),u=Ce(()=>c.value,f=>{a(),i.value&&f.size&&(o=new MutationObserver(t),f.forEach(p=>o.observe(p,r)))},{immediate:!0,flush:"post"}),l=()=>o==null?void 0:o.takeRecords(),d=()=>{u(),a()};return Dl(d),{isSupported:i,stop:d,takeRecords:l}}function FI(e,t={}){const{window:n=ji}=t,s=k_(()=>n&&"matchMedia"in n&&typeof n.matchMedia=="function");let r;const o=le(!1),i=u=>{o.value=u.matches},a=()=>{r&&("removeEventListener"in r?r.removeEventListener("change",i):r.removeListener(i))},c=pl(()=>{s.value&&(a(),r=n.matchMedia(Xs(e)),"addEventListener"in r?r.addEventListener("change",i):r.addListener(i),o.value=r.matches)});return Dl(()=>{c(),a(),r=void 0}),o}const ru=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},ou="__vueuse_ssr_handlers__",NI=BI();function BI(){return ou in ru||(ru[ou]=ru[ou]||{}),ru[ou]}function DI(e,t){return NI[e]||t}function UI(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}const VI={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},hb="vueuse-storage";function jI(e,t,n,s={}){var r;const{flush:o="pre",deep:i=!0,listenToStorageChanges:a=!0,writeDefaults:c=!0,mergeDefaults:u=!1,shallow:l,window:d=ji,eventFilter:f,onError:p=R=>{console.error(R)},initOnMounted:m}=s,h=(l?Bo:le)(t);if(!n)try{n=DI("getDefaultStorage",()=>{var R;return(R=ji)==null?void 0:R.localStorage})()}catch(R){p(R)}if(!n)return h;const y=Xs(t),b=UI(y),g=(r=s.serializer)!=null?r:VI[b],{pause:w,resume:_}=$I(h,()=>x(h.value),{flush:o,deep:i,eventFilter:f});d&&a&&S_(()=>{n instanceof Storage?Ip(d,"storage",k):Ip(d,hb,S),m&&k()}),m||k();function A(R,B){if(d){const L={key:e,oldValue:R,newValue:B,storageArea:n};d.dispatchEvent(n instanceof Storage?new StorageEvent("storage",L):new CustomEvent(hb,{detail:L}))}}function x(R){try{const B=n.getItem(e);if(R==null)A(B,null),n.removeItem(e);else{const L=g.write(R);B!==L&&(n.setItem(e,L),A(B,L))}}catch(B){p(B)}}function C(R){const B=R?R.newValue:n.getItem(e);if(B==null)return c&&y!=null&&n.setItem(e,g.write(y)),y;if(!R&&u){const L=g.read(B);return typeof u=="function"?u(L,y):b==="object"&&!Array.isArray(L)?{...y,...L}:L}else return typeof B!="string"?B:g.read(B)}function k(R){if(!(R&&R.storageArea!==n)){if(R&&R.key==null){h.value=y;return}if(!(R&&R.key!==e)){w();try{(R==null?void 0:R.newValue)!==g.write(h.value)&&(h.value=C(R))}catch(B){p(B)}finally{R?Js(_):_()}}}}function S(R){k(R.detail)}return h}function HI(e={}){const{window:t=ji,initialWidth:n=Number.POSITIVE_INFINITY,initialHeight:s=Number.POSITIVE_INFINITY,listenOrientation:r=!0,includeScrollbar:o=!0,type:i="inner"}=e,a=le(n),c=le(s),u=()=>{t&&(i==="outer"?(a.value=t.outerWidth,c.value=t.outerHeight):o?(a.value=t.innerWidth,c.value=t.innerHeight):(a.value=t.document.documentElement.clientWidth,c.value=t.document.documentElement.clientHeight))};if(u(),S_(u),Ip("resize",u,{passive:!0}),r){const l=FI("(orientation: portrait)");Ce(l,()=>u())}return{width:a,height:c}}const ks=Bo({blue:"#aaa",yellow:"#aaa",green:"#aaa",red:"#aaa",purple:"#aaa",backgroundColor:"#aaa",level1:"#aaa",level2:"#aaa",level3:"#aaa",level4:"#aaa",level5:"#aaa",level6:"#aaa",text:"#aaa"});LI(document.documentElement,e=>{if(!e.some(s=>s.attributeName==="data-theme"))return;const t=getComputedStyle(document.documentElement),n=s=>zI(t.getPropertyValue(s));ks.value={blue:n("--c-chart-blue"),yellow:n("--c-chart-yellow"),green:n("--c-chart-green"),red:n("--c-chart-red"),purple:n("--c-chart-purple"),text:n("--c-chart-text"),backgroundColor:n("--c-lvl1"),level1:n("--c-lvl1"),level2:n("--c-lvl2"),level3:n("--c-lvl3"),level4:n("--c-lvl4"),level5:n("--c-lvl5"),level6:n("--c-lvl6")}},{attributes:!0});function zI(e){const t=document.createElement("canvas");t.width=1,t.height=1;const n=t.getContext("2d");if(!n)throw new Error("Failed to create 2D canvas context");n.fillStyle=e,n.fillRect(0,0,1,1);const s=n.getImageData(0,0,1,1).data;return`#${[s[0],s[1],s[2]].map(o=>o.toString(16).padStart(2,"0")).join("")}`}const It=HS({id:1,name:"Ethereum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://cloudflare-eth.com"]}},blockExplorers:{default:{name:"Etherscan",url:"https://etherscan.io",apiUrl:"https://api.etherscan.io/api"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0xce01f8eee7E479C928F8919abD53E553a36CeF67",blockCreated:19258213},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}}),I_=Symbol(),qI={install(e,t){const{config:n,reconnectOnMount:s=!0}=t;e.provide(I_,n);const{onMount:r}=Wk(n,{...t,reconnectOnMount:s});r()}},WI="0.0.56",GI=()=>`@wagmi/vue@${WI}`;class R_ extends nr{constructor(){super(...arguments),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WagmiError"})}get docsBaseUrl(){return"https://wagmi.sh/vue"}get version(){return GI()}}class XI extends R_{constructor(){super("No `config` found in Vue context, use `WagmiPlugin` to properly initialize the library.",{docsPath:"/api/TODO"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WagmiPluginNotFoundError"})}}class KI extends R_{constructor(){super("Wagmi composables can only be used inside `setup()` function or functions that support injection context.",{docsPath:"/api/TODO"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WagmiInjectionContextError"})}}function QI(e,t){for(const n of Object.keys(e))e[n]=t[n]}function rt(e={}){const t=v(e);if(t.config)return t.config;if(!Em())throw new KI;const n=Nt(I_);if(!n)throw new XI;return n}function Th(e={}){const t=rt(e),n=zs(gh(t)),s=Ak(t,{onChange(r){QI(n,r)}});return Wn(()=>s()),ll(No(n))}function Rp(e,t){if(t){const n=t(e);if(n===void 0&&$e(e)||n!==void 0)return n}if(Array.isArray(e))return e.map(n=>Rp(n,t));if(typeof e=="object"&&ZI(e)){const n=Object.entries(e).map(([s,r])=>[s,Rp(r,t)]);return Object.fromEntries(n)}return e}function Hi(e){return Rp(e,t=>{if($e(t))return Hi(v(t))})}function ZI(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;const t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function YI(e,t){return jr(e,t)?e:Fl(e,t)}function $_(e){return JSON.stringify(e,(t,n)=>JI(n)?Object.keys(n).sort().reduce((s,r)=>(s[r]=n[r],s),{}):typeof n=="bigint"?n.toString():n)}function JI(e){if(!yb(e))return!1;const t=e.constructor;if(typeof t>"u")return!0;const n=t.prototype;return!(!yb(n)||!n.hasOwnProperty("isPrototypeOf"))}function yb(e){return Object.prototype.toString.call(e)==="[object Object]"}function Ul(e){const{_defaulted:t,behavior:n,gcTime:s,initialData:r,initialDataUpdatedAt:o,maxPages:i,meta:a,networkMode:c,queryFn:u,queryHash:l,queryKey:d,queryKeyHashFn:f,retry:p,retryDelay:m,structuralSharing:h,getPreviousPageParam:y,getNextPageParam:b,initialPageParam:g,_optimisticResults:w,enabled:_,notifyOnChangeProps:A,placeholderData:x,refetchInterval:C,refetchIntervalInBackground:k,refetchOnMount:S,refetchOnReconnect:R,refetchOnWindowFocus:B,retryOnMount:L,select:X,staleTime:z,suspense:ie,throwOnError:ne,config:te,connector:ce,query:he,..._e}=e;return _e}function e4(e){return{mutationFn(t){return JP(e,t)},mutationKey:["connect"]}}function t4(e){return{mutationFn(t){return fk(e,t)},mutationKey:["disconnect"]}}function n4(e,t={}){return{async queryFn({queryKey:n}){const{address:s,scopeKey:r,...o}=n[1];if(!s)throw new Error("address is required");return await hk(e,{...o,address:s})??null},queryKey:s4(t)}}function s4(e={}){return["balance",Ul(e)]}function r4(e,t={}){return{gcTime:0,async queryFn({queryKey:n}){const{connector:s}=t,{connectorUid:r,scopeKey:o,...i}=n[1];return bh(e,{...i,connector:s})},queryKey:o4(t)}}function o4(e={}){const{connector:t,...n}=e;return["connectorClient",{...Ul(n),connectorUid:t==null?void 0:t.uid}]}function i4(e,t={}){return{async queryFn({queryKey:n}){const s=t.abi;if(!s)throw new Error("abi is required");const{functionName:r,scopeKey:o,...i}=n[1],a=(()=>{const c=n[1];if(c.address)return{address:c.address};if(c.code)return{code:c.code};throw new Error("address or code is required")})();if(!r)throw new Error("functionName is required");return Jr(e,{abi:s,functionName:r,args:i.args,...a,...i})},queryKey:a4(t)}}function a4(e={}){const{abi:t,...n}=e;return["readContract",Ul(n)]}function c4(e){return{mutationFn(t){return Ck(e,t)},mutationKey:["switchChain"]}}function u4(e,t={}){return{async queryFn({queryKey:n}){const{hash:s,...r}=n[1];if(!s)throw new Error("hash is required");return Oe(e,{...r,onReplaced:t.onReplaced,hash:s})},queryKey:l4(t)}}function l4(e={}){const{onReplaced:t,...n}=e;return["waitForTransactionReceipt",Ul(n)]}function d4(e){return{mutationFn(t){return Le(e,t)},mutationKey:["writeContract"]}}function Vl(e){const t=M(()=>({...v(e),queryKeyHashFn:$_})),n=Fn(t);return n.queryKey=v(t).queryKey,n}function jl(e={}){const t=rt(e),n=le(yk(t)),s=Tk(t,{onChange(r){n.value=r}});return Wn(()=>s()),No(n)}function Hr(e={}){const t=M(()=>Hi(e)),n=rt(t),s=jl({config:n}),r=M(()=>{const{address:o,chainId:i=s.value,query:a={}}=t.value,c=n4(n,{...t.value,chainId:i}),u=!!(o&&(a.enabled??!0));return{...a,...c,enabled:u}});return Vl(r)}function f4(e={}){const t=M(()=>Hi(e)),n=rt(t),s=Nl(),{address:r,connector:o,status:i}=Th({config:n}),a=jl({config:n}),c=M(()=>{const{chainId:l=a.value,connector:d=o.value,query:f={}}=t.value,{queryKey:p,...m}=r4(n,{...Hi(t),chainId:l,connector:d}),h=!!((i.value==="connected"||i.value==="reconnecting"&&(d!=null&&d.getProvider))&&(f.enabled??!0));return{...f,...m,queryKey:p,enabled:h,staleTime:Number.POSITIVE_INFINITY}}),u=le(r);return pl(()=>{const l=u.value;!r&&l?(s.removeQueries({queryKey:c.value.queryKey}),u.value=void 0):r.value!==l&&(s.invalidateQueries({queryKey:c.value.queryKey}),u.value=r.value)}),Vl(c)}function p4(e,t){const{onChange:n}=t;return e._internal.chains.subscribe((s,r)=>{n(s,r)})}function m4(e={}){const t=rt(e),n=le(bk(t)),s=p4(t,{onChange(r){n.value=r}});return Wn(()=>s()),No(n)}function M_(e={}){const t=rt(e),n=le(vk(t)),s=Sk(t,{onChange(r){n.value=r}});return Wn(()=>s()),n}function h4(e={}){const{mutation:t}=e,n=rt(e),s=e4(n),{mutate:r,mutateAsync:o,...i}=Bl({...t,...s}),a=n.subscribe(({status:c})=>c,(c,u)=>{u==="connected"&&c==="disconnected"&&i.reset()});return Wn(()=>a()),{...i,connect:r,connectAsync:o,connectors:M_({config:n}).value}}function y4(e={}){const t=rt(e),n=le(a_(t)),s=Ek(t,{onChange(r){n.value=r}});return Wn(()=>s()),No(n)}function b4(e={}){const{mutation:t}=e,n=rt(e),s=y4({config:n}),r=t4(n),{mutate:o,mutateAsync:i,...a}=Bl({...t,...r});return{...a,connectors:M(()=>s.value.map(c=>c.connector)),disconnect:o,disconnectAsync:i}}function Tt(e={}){const t=M(()=>Hi(e)),n=rt(t),s=jl({config:n}),r=M(()=>{const{abi:o,address:i,chainId:a=s.value,code:c,functionName:u,query:l={}}=t.value,d=i4(n,{...t.value,chainId:a}),f=!!((i||c)&&o&&u&&(l.enabled??!0));return{...l,...d,enabled:f,structuralSharing:l.structuralSharing??YI}});return Vl(r)}function O_(e={}){const{mutation:t}=e,n=rt(e),s=c4(n),{mutate:r,mutateAsync:o,...i}=Bl({...t,...s});return{...i,chains:m4({config:n}),switchChain:r,switchChainAsync:o}}function g4(e={}){const t=M(()=>Hi(e)),n=rt(e),s=jl(),r=M(()=>{const{chainId:o=s.value,hash:i,query:a={}}=t.value,c=u4(n,{...t.value,chainId:o}),u=!!(i&&(a.enabled??!0));return{...a,...c,enabled:u}});return Vl(r)}function v4(e={}){const{mutation:t}=e,n=rt(e),s=d4(n),{mutate:r,mutateAsync:o,...i}=Bl({...t,...s});return{...i,writeContract:r,writeContractAsync:o}}function tt(){const{address:e,isConnected:t,chainId:n}=Th(),s=f4(),r=M(()=>s.data.value&&e.value?e.value.toLocaleLowerCase():void 0);return{isConnected:t,chainId:n,address:r}}function Hl(e,t=6){if(!e)return"0x000...000";const n=t/2+2,s=e.length-t/2;return`${e.substring(0,n)}...${e.substring(s)}`}async function Et(e,t,n,s,r){const o=await Jr(e,{abi:dn,address:t,functionName:"allowance",args:[n,s]});if(o<r){if(o>0n){const a=await Le(e,{abi:dn,address:t,functionName:"approve",args:[s,0n]});await Oe(e,{hash:a})}const i=await Le(e,{abi:dn,address:t,functionName:"approve",args:[s,Hm]});await Oe(e,{hash:i})}}const bb=[{stateMutability:"view",type:"function",name:"tokenURI",inputs:[{name:"token_id",type:"uint256"}],outputs:[{name:"",type:"string"}]},{stateMutability:"view",type:"function",name:"tokensForOwner",inputs:[{name:"owner",type:"address"}],outputs:[{name:"",type:"uint256[]"}]}],gb="0xde1e6a7ed0ad3f61d531a8a78e83ccddbd6e0c49",zi="0x92e6e43f99809df84ed2d533e1fd8017eb966ee2",$p="0x469788fe6e9e9681c6ebf3bf78e7fd26fc015446",w4="0x9bc7c6ad7e7cf3a6fcb58fb21e27752ac1e53f99",_4="0xaef6ea60f6443bad046e825c1d2b0c0b5ebc1f16",x4="0x657ce046d98d163ef4f846210f25919fa7b31944",C4="0x375b28a603be144a646a506fb6673cc3182fc8df",Ro=["0xcc2a0f5e95c88aabd7b8e0db5c5252820cd47f91","0xd248e64b2d3d00d7f6a21009c3fcc1bd593600c9","0x835076176ab24f2c4372ba15c8e7e76c1429e66f","0xf4112931c955fda9fb7f184da3518e6050a30eb7","0x7a7f79c5706716bae853c1b96e36538c7eaa4925","0x853dcbf4dd00dbc6a70002ff87be3671ac966067","0xce45e2e9a1ca8ba9a311bf862606b890c1f5d988","0xd52ca71aafa4d2590aac1e35e3005242dd31e5ed"],Mp="0xcfa23b8f9062369b21049b9f4a4ce79d640d1873",A4="0x0ed7d0497194fc029ae02223fec6d4d567696f17",zl="0x2c5e808fca6d8299ce194e12ed728f0fdbbf06c8",T4="0x11fe17c5ab68cc4cc6d3c281feddfff80bc1d4c7",ql="0x5682a28919389b528ae74dd627e0d632ca7e398c",Wl="0x6788234f40931ca615b0d221c1afbf0ec07afcc5",Gl="0xf09320ed7db384cab7fce9ea9947436a806754d3",vb="0x83507cc8c8b67ed48badd1f59f684d5d02884c81",qi="0x4ebad8dbd4edbd74db0278714fbd67ebc76b89b7",zr="0xde2bef0a01845257b4aef2a2eaa48f6eaeafa8b7",_o="0xf964b0e3ffdea659c44a5a52bc0b82a24b89ce0e",Ks="0x3a886455e5b33300a31c5e77bac01e76c0c7b29c",ys="0x8659fc767cad6005de79af65dafe4249c57927af",E4="0x6ed9c171e02de08aaedf0fc1d589923d807061d6",qr="0x9bfd08d7b3cc40129132a17b4d5b9ea3351464bd",wb="0xd6fc1ecd9965ba9cac895654979564a291c74c29",$o="0x8c4eb0fc6805ee7337ac126f89a807271a88dd67",S4="0x8d2aee9a7d581f3ed29e961a05c54f2be90eb7f3",L_="0xec221ae5c62029cb03d91eff85611a378a1f8883",P4="0x110a888f88b65a2c34a6922f518128eda4fb70de",k4="0x45f97d07dab04b21f36fa3b1149c35e316b35d03",I4="0x88011c72623777f6452a7d6d8bab10ec67e89e01",R4="0x4b0987bef3f966354c6ecd22f6d844d621ee5077",$4="0x83d6cdd50110cb3fd9547618cc94540b79733f76",M4="0x5c53174c8d88f0f56c33f923b8c6a84a1760e484",_b="0xc8d1335d18c0ef56a00dbb8b7a639183ee1c4d78",Op="0xd835cdedc20ca3075f86dea4e0d914499d0c5b25",Lp="0x68b56567af308fe8d94876ab0fe88541ed025e1c",os="0x63f0797015489d407fc2ac7e3891467e1ed0166c",Fp="0x1f409ec6f395493ad39f5b27945f1a6658a23908",Np="0xae12bf0ad604ddb1c5f048e14b48d719fbdc7d7c",O4="0x7374c3dcaf8ff2c9bb706eaff7bf4ebbf9ac6067",cc="0xb192908e533fc64109a20ee7d056175a24f17a55",Bp="0xa1fdfcab1c53e6f80439462f7f394c1f2ba65981",L4="0xed41c3402c4b62777939b7334b4d3d2407517ff9",F4="0x5beef400f378df4f353fb42e58498f9779002624",Dp="0x0cb569209d5d9eeb40b24c5bb79d3184e75528c3",Qu="0x06c3b252c01225fdf3017551f39668c9b6599ac5",An="0x4e3fbd56cd56c3e72c1403e103b45db9da5b9d2b",F_="0xd533a949740bb3306d119cc777fa900ba034cd52",is="0x3432b6a60d23ca0dfca7761b7ab56459d9c964d0",Up="0xda47862a83dac0c112ba89c6abc2159b95afd71c",xb="0x4591dbff62656e7859afe5e45f6f47d3669fbb28",js="0xbce0cf87f513102f22232436cca2ca49e815c3ac",Cb="0xc044613b702ed11567a38108703ac5478a3f7db8",Ab="0x389fb29230d02e67eb963c1f5a00f2b16f95beb7",Eh="0x72a19342e8f1838460ebfccef09f6585e32db86e",ls="0x62b9c7356a2dc64a1969e19c23e4f579f9810aa7",$r="0xfeef77d3f69374f66429c91d732a244f074bdf74",Au="0x34635280737b5bfe6c7dc2fc3065d60d66e78185",Ia="0x0c73f1cfd5c9dfc150c8707aa47acbd14f0be108",ci="0x616e8bfa43f920657b3497dbf40d6b1a02d4608d",N4="0x3e2cad773e36e29a53eaab56726043ac04fe83d7",B4="0x35d28d77369e825298de76060e96e5ada7f5e906",D4="0x2251af9804d0a1a04e8e0e7a1fbb83f4d7423f9e",U4="0x1f9409933aa273dab349ceba255f5ad8f854defb",V4="0x9d0464996170c6b9e75eed71c68b99ddedf279e8",j4="0x971add32Ea87f10bD192671630be3BE8A11b8623",Sh="0xd658a338613198204dca1143ac3f01a722b5d94a",Tu="0xf3a43307dcafa93275993862aae628fcb50dc768",Ph="0x72725c0c879489986d213a9a6d2116de45624c1c",H4="0x3b21c2868b6028cfb38ff86127ef22e68d16d53b",cn="0x35a398425d9f1029021a92bc3d2557d42c8588d7",z4="0xadd2f542f9ff06405fabf8cae4a74bd0fe29c673",q4="0x49b4d1df40442f0c31b1bbaea3ede7c38e37e31a",W4="0x0c73f1cfd5c9dfc150c8707aa47acbd14f0be108",Tb="0xe127ce638293fa123be79c25782a5652581db234",G4=["src"],X4=ae({__name:"LlamaNFT",setup(e){const{address:t,chainId:n}=tt(),s=le(""),{data:r}=Tt({abi:bb,address:Tb,functionName:"tokensForOwner",args:M(()=>[t.value]),query:{enabled:M(()=>!!t.value&&n.value===It.id)}}),{data:o}=Tt({abi:bb,address:Tb,functionName:"tokenURI",args:M(()=>{var i;return[((i=r.value)==null?void 0:i[0])??0n]}),query:{enabled:M(()=>{var i;return(((i=r.value)==null?void 0:i.length)??0)>0})}});return Ce(o,async i=>{if(!i){s.value="";return}const c=await(await fetch(i)).json();c!=null&&c.image&&(s.value=c.image)}),(i,a)=>v(s)?(F(),J("img",{key:0,src:v(s)},null,8,G4)):ye("",!0)}}),pe=(e,t)=>{const n=e.__vccOpts||e;for(const[s,r]of t)n[s]=r;return n},kh=pe(X4,[["__scopeId","data-v-7c253cad"]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const K4=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */var iu={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"};/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Q4=({size:e,strokeWidth:t=2,absoluteStrokeWidth:n,color:s,iconNode:r,name:o,class:i,...a},{slots:c})=>Fr("svg",{...iu,width:e||iu.width,height:e||iu.height,stroke:s||iu.stroke,"stroke-width":n?Number(t)*24/Number(e):t,class:["lucide",`lucide-${K4(o??"icon")}`],...a},[...r.map(u=>Fr(...u)),...c.default?[c.default()]:[]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Wt=(e,t)=>(n,{slots:s})=>Fr(Q4,{...n,iconNode:t,name:e},s);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Z4=Wt("BookOpenIcon",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const N_=Wt("BookIcon",[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Y4=Wt("ChartNoAxesColumnIcon",[["line",{x1:"18",x2:"18",y1:"20",y2:"10",key:"1xfpm4"}],["line",{x1:"12",x2:"12",y1:"20",y2:"4",key:"be30l9"}],["line",{x1:"6",x2:"6",y1:"20",y2:"14",key:"1r4le6"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const J4=Wt("CheckIcon",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const eR=Wt("ChevronRightIcon",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Ih=Wt("ChevronUpIcon",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const tR=Wt("ChevronsLeftRightIcon",[["path",{d:"m9 7-5 5 5 5",key:"j5w590"}],["path",{d:"m15 7 5 5-5 5",key:"1bl6da"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const B_=Wt("ClockIcon",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const nR=Wt("CodeIcon",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const sR=Wt("LockOpenIcon",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 9.9-1",key:"1mm8w8"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const rR=Wt("LockIcon",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const oR=Wt("MegaphoneIcon",[["path",{d:"m3 11 18-5v12L3 14v-3z",key:"n962bs"}],["path",{d:"M11.6 16.8a3 3 0 1 1-5.8-1.6",key:"1yl0tm"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const iR=Wt("MenuIcon",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const aR=Wt("PlaneIcon",[["path",{d:"M17.8 19.2 16 11l3.5-3.5C21 6 21.5 4 21 3c-1-.5-3 0-4.5 1.5L13 8 4.8 6.2c-.5-.1-.9.1-1.1.5l-.3.5c-.2.5-.1 1 .3 1.3L9 12l-2 3H4l-1 1 3 2 2 3 1-1v-3l3-2 3.5 5.3c.3.4.8.5 1.3.3l.5-.2c.4-.3.6-.7.5-1.2z",key:"1v9wt8"}]]);/**
 * @license lucide-vue-next v0.453.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const cR=Wt("TwitterIcon",[["path",{d:"M22 4s-.7 2.1-2 3.4c1.6 10-9.4 17.3-18 11.6 2.2.1 4.4-.6 6-2C3 15.5.5 9.6 3 5c2.2 2.6 5.6 4.1 9 4-.9-4.2 4-6.6 7-3.8 1.1 0 3-1.2 3-1.2z",key:"pff0z6"}]]),D_="/assets/logo-BQfem83O.svg",Eb="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAAlCAYAAADbVxCwAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAA3SURBVHgB7dMxEQAgDASwFold8a8DVPzQu8RDeua+WuIU7NKCQY5gECQYBAkGQYJBkGAQJFjKByviEAl7Owi/AAAAAElFTkSuQmCC",uR="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAABCAYAAAC/iqxnAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAaSURBVHgBxcAxAQAAAAFBKv6qfw5iOEOqowH7/QIA5qQU5gAAAABJRU5ErkJggg==";function lR(e,t,n){return e.reduce((s,r)=>({...s,[t(r)]:n(r)}),{})}function Vp(e){return e!=null}function Rh(e){function t(d){return d<10?"0"+d.toString():d.toString()}const n=e.getTime()-new Date().getTime();if(n<=0)return"00:00:00:00";const s=1e3,r=s*60,o=r*60,i=o*24,a=Math.floor(n/i),c=Math.floor(n%i/o),u=Math.floor(n%o/r),l=Math.floor(n%r/s);return t(a)+":"+t(c)+":"+t(u)+":"+t(l)}function Mr(e){const t=["","k","m","b","t"],n=Math.max(0,Math.min(t.length-1,Math.floor(Math.log10(Math.abs(e))/3)));return t[n]}function xo(e,t=0,n=""){if(n==="dollar"){const r=Math.floor(Math.log10(Math.abs(e))/3)*3;e/=r>0?10**r:1}const s=n===""||t===1/0?void 0:{minimumFractionDigits:t,maximumFractionDigits:t};return e.toLocaleString(void 0,s)}function Ie(e,t){return parseFloat(ea(e,Number(t)))}function $t(e,t){const n=Number(t),s=Number.isInteger(e)?e.toString():e.toFixed(n);return aP(s,n)}function U_(e,t){const n={...e};for(const s in t)Array.isArray(t[s])?n[s]=[...t[s]]:typeof t[s]=="object"&&t[s]!==null?n[s]=U_(n[s],t[s]):n[s]=t[s];return n}function Sb(e,t){return Object.entries(e).reduce((n,[s,r])=>({...n,[t(r,s)]:r}),{})}async function jp(e,t=0,n=1e3){const s=await e(t,n),r=await(s.length>=n?jp(e,t+1,n):Promise.resolve([]));return s.concat(r)}function Mo(e,t){return(Array.isArray(e)?e:[e]).some(s=>t.path.startsWith(s))}const dR=[{stateMutability:"view",type:"function",name:"get_dy",inputs:[{name:"i",type:"int128"},{name:"j",type:"int128"},{name:"dx",type:"uint256"}],outputs:[{name:"",type:"uint256"}]}],Or=[{stateMutability:"view",type:"function",name:"get_dy",inputs:[{name:"i",type:"uint256"},{name:"j",type:"uint256"},{name:"dx",type:"uint256"}],outputs:[{name:"",type:"uint256"}]},{stateMutability:"view",type:"function",name:"price_oracle",inputs:[],outputs:[{name:"",type:"uint256"}]},{stateMutability:"view",type:"function",name:"balances",inputs:[{name:"arg0",type:"uint256"}],outputs:[{name:"",type:"uint256"}]}],fR=[{stateMutability:"view",type:"function",name:"get_dy",inputs:[{name:"i",type:"int128"},{name:"j",type:"int128"},{name:"dx",type:"uint256"}],outputs:[{name:"",type:"uint256"}]},{stateMutability:"view",type:"function",name:"price_oracle",inputs:[],outputs:[{name:"",type:"uint256"}]}],pR=[{stateMutability:"view",type:"function",name:"price_oracle",inputs:[],outputs:[{name:"",type:"uint256"}]}];async function mR(e){const t=10n**18n,n=10n**22n,s=await e.read.get_dy([0n,1n,n]),r=(s-n)*t/s;return 1-Ie(r,18n)}function ds(e,t){return e.getPrice(t).then(n=>n.price).catch(()=>0)}async function Xl(e,t){const n=await ds(e,An),s=await t.readContract({abi:Or,address:Ph,functionName:"price_oracle"});return n*Ie(s,18n)}async function V_(e,t){const n=await ds(e,F_),s=await t.readContract({abi:pR,address:j4,functionName:"price_oracle"});return n*Ie(s,18n)}async function $h(e,t){const n=await ds(e,Up),s=await t.readContract({abi:fR,address:H4,functionName:"price_oracle"});return n*Ie(s,18n)}async function hR(e,t){const n=await ds(e,F_),s=St({abi:dR,address:V4,client:t}),r=await mR(s);return n*r}async function Vo(e,t){const n=await ds(e,is),s=await t.readContract({abi:Or,address:Sh,functionName:"price_oracle"});return n*Ie(s,18n)}async function yR(e,t,n,s,r){const o=await t.multicall({contracts:[{address:s,abi:Or,functionName:"balances",args:[0n]},{address:s,abi:Or,functionName:"balances",args:[1n]},{address:s,abi:Or,functionName:"price_oracle",args:[]},{address:r,abi:dn,functionName:"totalSupply",args:[]}]}),i=o[0].result,a=o[1].result,c=o[2].result,u=o[3].result,l=18n,d=await e.getPrice(n).then(y=>$t(y.price,l)).catch(()=>0n),f=10n**l,h=(i+a)*c/f*d/f*f/u;return Ie(h,l)}async function Wi(e,t){return yR(e,t,is,Sh,Tu)}async function bR(e){return e.getAura().then(n=>{var s;return((s=n.dashboard)==null?void 0:s.auraBalPrice)??0}).catch(()=>0)}const gR=[{inputs:[{internalType:"address",name:"_account",type:"address"}],name:"accountExtraRewardRates",outputs:[{internalType:"address[]",name:"tokens",type:"address[]"},{internalType:"uint256[]",name:"rates",type:"uint256[]"},{internalType:"uint256[]",name:"groups",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_account",type:"address"}],name:"accountRewardRates",outputs:[{internalType:"address[]",name:"tokens",type:"address[]"},{internalType:"uint256[]",name:"rates",type:"uint256[]"},{internalType:"uint256[]",name:"groups",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"_rate",type:"uint256"},{internalType:"uint256",name:"_priceOfReward",type:"uint256"},{internalType:"uint256",name:"_priceOfDeposit",type:"uint256"}],name:"apr",outputs:[{internalType:"uint256",name:"_apr",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"extraRewardRates",outputs:[{internalType:"address[]",name:"tokens",type:"address[]"},{internalType:"uint256[]",name:"rates",type:"uint256[]"},{internalType:"uint256[]",name:"groups",type:"uint256[]"}],stateMutability:"view",type:"function"},{inputs:[],name:"mainRewardRates",outputs:[{internalType:"address[]",name:"tokens",type:"address[]"},{internalType:"uint256[]",name:"rates",type:"uint256[]"},{internalType:"uint256[]",name:"groups",type:"uint256[]"}],stateMutability:"view",type:"function"}],vR=[{inputs:[{internalType:"address",name:"",type:"address"}],name:"rewardData",outputs:[{internalType:"uint256",name:"periodFinish",type:"uint256"},{internalType:"uint256",name:"rewardRate",type:"uint256"},{internalType:"uint256",name:"lastUpdateTime",type:"uint256"},{internalType:"uint256",name:"rewardPerTokenStored",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],wR=[{inputs:[{internalType:"address",name:"",type:"address"}],name:"rewardData",outputs:[{internalType:"uint256",name:"periodFinish",type:"uint256"},{internalType:"uint256",name:"rewardRate",type:"uint256"},{internalType:"uint256",name:"lastUpdateTime",type:"uint256"},{internalType:"uint256",name:"rewardPerTokenStored",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],_R={laf:"https://api.llama.airforce",cb:void 0,cm:"https://api2.curvemonitor.com",pm:void 0,"pm-lrt":void 0};class j_ extends Error{constructor(t,n){super(n),this.status=t}}async function xR(e,t,n){try{const s=await fetch(e,{method:t?"POST":"GET",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t),signal:n});if(s.ok)return s;throw new j_(s.status,`Fetch error ${s.status} for URL: ${e}`)}catch(s){throw s instanceof Error?s:new Error("Unknown fetch error")}}async function CR(e,t,n){return await(await xR(e,t,n)).json()}class Kl{async fetch(t,n,s){return CR(t,n,s)}}class ra extends Kl{constructor(n){super();qo(this,"host");this.host=n}async getHost(){return await this.host}}class pn extends Kl{async getPrice(t){const n=`ethereum:${t}`;return this.fetch(`https://coins.llama.fi/prices/current/${n}`).then(s=>s.coins[n])}async getPrices(t){const n=t.map(s=>`ethereum:${s}`).join(",");return this.fetch(`https://coins.llama.fi/prices/current/${n}`).then(s=>s.coins)}}function oa(e,t){return(Math.pow(1+e/100/t,t)-1)*100}function AR(e){return e.getConvex().then(t=>{var n;return oa(((n=t.dashboard)==null?void 0:n.cvxApr)??0,26)}).catch(()=>0)}async function H_(e,t,n){const s=St({abi:gR,address:z4,client:e}),r=await(n?s.read.accountRewardRates([n]):s.read.mainRewardRates()).then(([d,f])=>[...d].zip([...f])),o=await(n?s.read.accountExtraRewardRates([n]):s.read.extraRewardRates()).then(([d,f])=>[...d].zip([...f])),i=r.concat(o).filter(d=>d[1]>0).groupBy(d=>d[0]).entries().map(([d,f])=>({address:d,rate:f.reduce((p,m)=>p+m[1],BigInt(0))})),a=i.map(d=>d.address).concat([ls]).uniq(),c=await t.getPrices(a).then(d=>lR(Object.keys(d).map(f=>({address:f.replace("ethereum:","").toLocaleLowerCase(),price:d[f].price})),f=>f.address,f=>$t(f.price,18n))),u=[],l=c[ls];for(const d of i){const f=await s.read.apr([d.rate,c[d.address.toLocaleLowerCase()],l]),p=Ie(f,18n);u.push(p)}return u}async function TR(e,t){const s=(await H_(e,t,L_)).reduce((r,o)=>r+o,0);return oa(s*100,52)}async function ER(e,t){const s=(await H_(e,t,S4)).reduce((r,o)=>r+o,0);return oa(s*100,52)}function SR(){return Promise.resolve(.01)}function PR(e){return e.getAura().then(t=>{var n;return oa(((n=t.dashboard)==null?void 0:n.auraBalApr)??0,52)}).catch(()=>0)}async function kR(e,t){const n=St({abi:vR,address:q4,client:e}),s=async b=>{const[g,w]=await n.read.rewardData([b]);return Date.now()/1e3>=Ie(g,0n)?0:Ie(w,18n)},r=await s(is),o=await s(An),i=Ie(await n.read.totalSupply(),18n),a=await Vo(t,e),c=await ds(t,is),u=await ds(t,An),l=i*a,d=31556952,f=r/l*d,p=o/l*d,m=f*c,h=p*u,y=m+h;return oa(y*100,52)}async function IR(e,t){const n=St({abi:wR,address:W4,client:e}),s=async A=>{const[x,C]=await n.read.rewardData([A]);return Date.now()/1e3>=Ie(x,0n)?0:Ie(C,18n)},r=await s(Up),o=await s(An),i=await s(xb),a=Ie(await n.read.totalSupply(),18n),c=await $h(t,e),u=await ds(t,Up),l=await ds(t,An),d=await ds(t,xb),f=a*c,p=31556952,m=r/f*p,h=o/f*p,y=i/f*p,b=m*u,g=h*l,w=y*d,_=b+g+w;return oa(_*100,52)}(function(){var e;try{if(typeof document<"u"){var t=document.createElement("style");t.nonce=(e=document.head.querySelector("meta[property=csp-nonce]"))==null?void 0:e.content,t.appendChild(document.createTextNode(".vue-notification-group{display:block;position:fixed;z-index:5000}.vue-notification-wrapper{display:block;overflow:hidden;width:100%;margin:0;padding:0}.notification-title{font-weight:600}.vue-notification-template{display:block;box-sizing:border-box;background:#fff;text-align:left}.vue-notification{display:block;box-sizing:border-box;text-align:left;font-size:12px;padding:10px;margin:0 5px 5px;color:#fff;background:#44a4fc;border-left:5px solid #187FE7}.vue-notification.warn{background:#ffb648;border-left-color:#f48a06}.vue-notification.error{background:#e54d42;border-left-color:#b82e24}.vue-notification.success{background:#68cd86;border-left-color:#42a85f}.vn-fade-enter-active,.vn-fade-leave-active,.vn-fade-move{transition:all .5s}.vn-fade-enter-from,.vn-fade-leave-to{opacity:0}")),document.head.appendChild(t)}}catch(n){console.error("vite-plugin-css-injected-by-js",n)}})();const z_=new Map;class RR{constructor(t,n,s){this.remaining=n,this.callback=t,this.notifyItem=s,this.resume()}pause(){clearTimeout(this.notifyItem.timer),this.remaining-=Date.now()-this.start}resume(){this.start=Date.now(),clearTimeout(this.notifyItem.timer),this.notifyItem.timer=setTimeout(this.callback,this.remaining)}}function $R(e){return{all:e=e||new Map,on:function(t,n){var s=e.get(t);s?s.push(n):e.set(t,[n])},off:function(t,n){var s=e.get(t);s&&(n?s.splice(s.indexOf(n)>>>0,1):e.set(t,[]))},emit:function(t,n){var s=e.get(t);s&&s.slice().map(function(r){r(n)}),(s=e.get("*"))&&s.slice().map(function(r){r(t,n)})}}}const Zu=$R(),of="[-+]?[0-9]*.?[0-9]+",Pb=[{name:"px",regexp:new RegExp(`^${of}px$`)},{name:"%",regexp:new RegExp(`^${of}%$`)},{name:"px",regexp:new RegExp(`^${of}$`)}],MR=e=>{if(e==="auto")return{type:e,value:0};for(let t=0;t<Pb.length;t++){const n=Pb[t];if(n.regexp.test(e))return{type:n.name,value:parseFloat(e)}}return{type:"",value:e}},OR=e=>{switch(typeof e){case"number":return{type:"px",value:e};case"string":return MR(e);default:return{type:"",value:e}}},kb={x:new Set(["left","center","right"]),y:new Set(["top","bottom"])},LR=(e=>()=>e++)(0),FR=e=>typeof e!="string"?[]:e.split(/\s+/gi).filter(Boolean),NR=e=>{typeof e=="string"&&(e=FR(e));let t=null,n=null;return e.forEach(s=>{kb.y.has(s)&&(n=s),kb.x.has(s)&&(t=s)}),{x:t,y:n}},af={position:["top","right"],cssAnimation:"vn-fade",velocityAnimation:{enter:e=>({height:[e.clientHeight,0],opacity:[1,0]}),leave:{height:0,opacity:[0,1]}}};function BR(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!Si(e)}const au={IDLE:0,DESTROYED:2},DR=ae({name:"notifications",props:{group:{type:String,default:""},width:{type:[Number,String],default:300},reverse:{type:Boolean,default:!1},position:{type:[String,Array],default:()=>af.position},classes:{type:[String,Array],default:"vue-notification"},animationType:{type:String,default:"css",validator(e){return e==="css"||e==="velocity"}},animation:{type:Object,default(){return af.velocityAnimation}},animationName:{type:String,default:af.cssAnimation},speed:{type:Number,default:300},duration:{type:Number,default:3e3},delay:{type:Number,default:0},max:{type:Number,default:1/0},ignoreDuplicates:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!0},pauseOnHover:{type:Boolean,default:!1},dangerouslySetInnerHtml:{type:Boolean,default:!1}},emits:{click:e=>!0,destroy:e=>!0,start:e=>!0},slots:Object,setup:(e,{emit:t,slots:n,expose:s})=>{const r=le([]),o=le(null),i=z_.get("velocity"),a=M(()=>e.animationType==="velocity"),c=M(()=>r.value.filter(R=>R.state!==au.DESTROYED)),u=M(()=>OR(e.width)),l=M(()=>{const{x:R,y:B}=NR(e.position),L=u.value.value,X=u.value.type,z={width:L+X};return B&&(z[B]="0px"),R&&(R==="center"?z.left=`calc(50% - ${+L/2}${X})`:z[R]="0px"),z}),d=M(()=>a.value?{onEnter:C,onLeave:k,onAfterLeave:S}:{}),f=R=>{t("click",R),e.closeOnClick&&w(R)},p=()=>{var R;e.pauseOnHover&&((R=o.value)==null||R.pause())},m=()=>{var R;e.pauseOnHover&&((R=o.value)==null||R.resume())},h=(R={})=>{if(R.group||(R.group=""),R.data||(R.data={}),e.group!==R.group)return;if(R.clean||R.clear){A();return}const B=typeof R.duration=="number"?R.duration:e.duration,L=typeof R.speed=="number"?R.speed:e.speed,X=typeof R.ignoreDuplicates=="boolean"?R.ignoreDuplicates:e.ignoreDuplicates,{title:z,text:ie,type:ne,data:te,id:ce}=R,he={id:ce||LR(),title:z,text:ie,type:ne,state:au.IDLE,speed:L,length:B+2*L,data:te,duplicates:0};B>=0&&(o.value=new RR(()=>w(he),he.length,he));const _e="bottom"in l.value,Fe=e.reverse?!_e:_e;let Ae=-1;const qe=c.value.find(Ye=>Ye.title===R.title&&Ye.text===R.text);if(X&&qe){qe.duplicates++;return}Fe?(r.value.push(he),t("start",he),c.value.length>e.max&&(Ae=0)):(r.value.unshift(he),t("start",he),c.value.length>e.max&&(Ae=c.value.length-1)),Ae!==-1&&w(c.value[Ae])},y=R=>{_(R)},b=R=>["vue-notification-template",e.classes,R.type||""],g=R=>a.value?void 0:{transition:`all ${R.speed}ms`},w=R=>{clearTimeout(R.timer),R.state=au.DESTROYED,S(),t("destroy",R)},_=R=>{const B=r.value.find(L=>L.id===R);B&&w(B)},A=()=>{c.value.forEach(w)},x=(R,B)=>{var L;const X=(L=e.animation)==null?void 0:L[R];return typeof X=="function"?X(B):X},C=(R,B)=>{const L=x("enter",R);i(R,L,{duration:e.speed,complete:B})},k=(R,B)=>{const L=x("leave",R);i(R,L,{duration:e.speed,complete:B})};function S(){r.value=r.value.filter(R=>R.state!==au.DESTROYED)}return Gn(()=>{Zu.on("add",h),Zu.on("close",y)}),()=>{let R;return $("div",{class:"vue-notification-group",style:l.value},[$(QC,ew(d.value,{tag:"div",css:!a.value,name:e.animationName}),BR(R=c.value.map(B=>$("div",{key:B.id,class:"vue-notification-wrapper",style:g(B),"data-id":B.id,onMouseenter:p,onMouseleave:m},[n.body?n.body({item:B,class:[e.classes,B.type],close:()=>w(B)}):$("div",{class:b(B),onClick:()=>f(B)},[e.dangerouslySetInnerHtml?$(De,null,[B.title?$("div",{class:"notification-title",innerHTML:B.title},null):null,$("div",{class:"notification-content",innerHTML:B.text},null)]):$(De,null,[B.title?$("div",{class:"notification-title"},[B.title]):null,$("div",{class:"notification-content"},[B.text])])])])))?R:{default:()=>[R]})])}}}),En=e=>{typeof e=="string"&&(e={title:"",text:e}),typeof e=="object"&&Zu.emit("add",e)};En.close=e=>{Zu.emit("close",e)};const UR="Notifications";function VR(e,t={}){Object.entries(t).forEach(s=>z_.set(...s));const n=t.name||"notify";e.config.globalProperties["$"+n]=En,e.component(t.componentName||UR,DR)}const jR={install:VR},HR=ae({__name:"Button",props:{chainId:{}},emits:["click"],setup(e,{emit:t}){const n=t,{chainId:s}=tt(),{switchChain:r}=O_(),o=i=>{if(i.stopImmediatePropagation(),e.chainId){if(s.value===void 0){En({text:"Wallet not connected",type:"error"});return}s.value!==e.chainId&&r({chainId:e.chainId})}n("click")};return(i,a)=>(F(),J("button",{onClick:o},[Ze(i.$slots,"default",{},void 0,!0)]))}}),Mt=pe(HR,[["__scopeId","data-v-f96d2ba9"]]),zR={key:0,class:"modal"},qR={class:"modal-popup"},WR=ae({__name:"Modal",props:{show:{type:Boolean,default:!1}},emits:["close"],setup(e,{emit:t}){const n=t,s=r=>{r.code==="Escape"&&n("close")};return Gn(()=>{document.addEventListener("keydown",s)}),Qi(()=>{document.removeEventListener("keydown",s)}),Ce(()=>e.show,r=>{document.body.style.overflow=r?"hidden":""}),(r,o)=>(F(),fe(T3,{to:"body"},[r.show?(F(),J("div",zR,[T("div",{class:"modal-mask",onClick:o[0]||(o[0]=i=>n("close"))}),T("div",qR,[Ze(r.$slots,"default",{},void 0,!0)])])):ye("",!0)]))}}),ia=pe(WR,[["__scopeId","data-v-801fe9d3"]]),GR=ae({__name:"Spinner",props:{loading:{type:Boolean},size:{default:"medium"}},setup(e){return(t,n)=>(F(),J("div",{class:Pe(["spinner",[{loading:t.loading},t.size]])},n[0]||(n[0]=[T("div",null,null,-1),T("div",null,null,-1)]),2))}}),XR=pe(GR,[["__scopeId","data-v-a1d713a5"]]),KR=["inert"],QR={key:0,class:"card-title"},ZR={key:1,class:"card-actions-secondary"},YR={key:2,class:"card-actions"},JR=ae({__name:"Card",props:{title:{default:""},compact:{type:Boolean,default:!1},collapsible:{type:Boolean,default:!1},collapsed:{type:Boolean,default:!1},loading:{type:[Boolean,null],default:null}},setup(e){const t=Am(),n=M(()=>e.title||t.title),s=M(()=>t.actions),r=M(()=>t["actions-secondary"]),o=M(()=>e.title||t.title||s.value||r.value),{width:i}=HI(),a=M(()=>i.value<=1280);return(c,u)=>{const l=XR;return F(),J("div",{class:Pe(["card",{loading:c.loading,"loading-backdrop":c.loading!==null,"stack-actions":v(a)}]),inert:!!c.loading},[c.loading!==null?(F(),fe(l,{key:0,loading:c.loading},null,8,["loading"])):ye("",!0),v(o)?(F(),J("div",{key:1,class:Pe(["card-header",{collapsible:c.collapsible}])},[v(n)?(F(),J("div",QR,[Ze(c.$slots,"title",{},()=>[we(Z(c.title),1)],!0)])):ye("",!0),v(r)?(F(),J("div",ZR,[Ze(c.$slots,"actions-secondary",{},void 0,!0)])):ye("",!0),v(s)?(F(),J("div",YR,[Ze(c.$slots,"actions",{},void 0,!0)])):ye("",!0)],2)):(F(),J("div",{key:2,class:Pe(["card-no-header",{compact:c.compact}])},null,2)),T("div",{class:Pe(["card-body",{compact:c.compact,collapsed:c.collapsed}])},[Ze(c.$slots,"default",{},void 0,!0)],2)],10,KR)}}}),He=pe(JR,[["__scopeId","data-v-8a405b44"]]),e$="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAHBhaW50Lm5ldCA0LjAuMTM0A1t6AAACSklEQVRIS7WVTUhUURTHT4sWgZS4aNFGSgqTmUqiKNAoFMWhqbQ2gX1BGdKUChW1EEqiULEsDNSFOBJiaZHQ9EE1pGik6DAzYYsUochFoEExCIGPf/e8e4d5b+ZJb4bxwm/x3j3n/O69j3cPidEomF4hOgU0/Wec8DeUZoIEUfuXLuAXnVcJBx2Ery8I+JIac+8JblGjpVo+mwQ8ceUI4e6FWMLPYXvwajm+t4FQVUQozrEQ8MpbPXJ7PFldStiTtwWufQX/xZFJ+D1G0KYID2sJ4QELAb+IwsWv11yE3THs98OpJMY6loLvbwkF2xwqVY6O+62oO3/OxLVLHkQiERUBdLe349YZG4JvbwgVJcUqDQhOTmB/NmGky0yL+FYsio6Xg4NoOJ2CYGx0FB6XOZEJ9ImjPHVCRSUp2JSVibbmJp3aqrOWgk89KQoWJwneejPhp3LuQQ1hcxZhV85q7MjOQCgQUOUB3/Nn9gTLwcXLiwqhaZoqGRsL8/PYup4QFMdmzLEt+PGOkL9xg6n4x6EhPO7xos/r1YuPP0rMsy2Y8REqD7tVaWAqHIJznfwxmeiPFU/KgpEPflyusI41kpRg7SrCyaPlOgd25qdXsBgg+O6ZmX1lHWvEtoB3kCF2cNzt0inc7kj/ERm/AV9uSQu4WfTeJCyJKzc+kAVriHCsrERnb16upUATPLkdOz6T4JBTNos2cZ/HJy59lgswEplIjBu4I45x9zINhzsZT4T6ExPtMvta1rhRKZ9jAtXy0k1U0CFYWBmo/x+ShmnKzYg0NQAAAABJRU5ErkJggg==",t$=ae({__name:"Tooltip",emits:["show"],setup(e,{emit:t}){const n=t,s=le(!1),r=Af("trigger"),o=Af("content");Ce(s,l=>{n("show",l),l&&Js(()=>{u()})});let i;function a(){i&&(clearTimeout(i),i=void 0),s.value=!0}function c(){i&&clearTimeout(i),i=setTimeout(()=>{s.value=!1,i=void 0},50)}Gn(()=>{u(),window.addEventListener("resize",u)}),Qi(()=>{window.removeEventListener("resize",u)});function u(){if(!r.value||!o.value)return;const l=r.value.getBoundingClientRect(),d=o.value.getBoundingClientRect(),f=14,p=f,m=window.innerHeight-d.height-f,h=Math.min(Math.max(p,l.top-d.height-f),m),y=f,b=window.innerWidth-d.width-f,g=Math.min(Math.max(y,l.left+l.width/2-d.width/2),b);o.value.style.top=`${h}px`,o.value.style.left=`${g}px`}return(l,d)=>(F(),J("div",{class:Pe(["tooltip",{show:v(s)}])},[T("div",{ref:"trigger",class:"trigger",onMouseover:a,onMouseleave:c,onTouchstart:a,onTouchend:c},[Ze(l.$slots,"trigger",{},()=>[d[0]||(d[0]=T("img",{src:e$},null,-1))],!0)],544),T("div",{ref:"content",class:"content",onMouseover:a,onMouseleave:c,onTouchstart:a,onTouchend:c},[Ze(l.$slots,"default",{},void 0,!0)],544)],2))}}),jo=pe(t$,[["__scopeId","data-v-f1e38ac2"]]),n$="/assets/injected-DW80ouY-.webp",s$="/assets/rabby-CG__llS3.svg",r$="/assets/walletconnect-BCBhrtde.webp",o$="/assets/coinbase-CsqSq8Nj.webp",i$="data:image/webp;base64,UklGRuIJAABXRUJQVlA4INYJAABQTwCdASqQAZABPkkgi0WioYlv2BQCQllbuFzQQgaf+g1rnpf5Gfur/ouv54K8GftNl2/Iv+A/Lv+3/Az1Ffcz7gf6Qf4LqV+YD+Z/2j/X/5v3gP83/o/ap6AH6q9aL6AH6semp+ynwiftr+y3s0/f/sx/jj/K9rf94xtMRTr//O/0r3AdkOwdvIcINKVNH8k/1iFbtMZi3As2twLNrcCza3As2twLNrcCza3As2twLNrcCza3As2tv86K1Sn/lbircVbircVbircVvo+IuhKkUafH59MV0gaw7C4+BzmPvHSW19fTgrGhKkSavYZD9pi/odhBF0JUijT47/hKMBg+fEb2gVzAs2tv88VcYiCllb49nsYQU1OCoBuAYWxJTK6cAvmfF6ToV7TGYkChDXyhoIkIRefRbJzvwLNrcCgnFP2Q/qkUafZFGn2P2US1ujrAirQMy1GK9Rjtp3BWNCVIkguMYjQL8M0GC7rHYbpNhf7Pw/cNK9pjMW4InVWnB4X/Kux77oDrFRGA+nT9H3cLoHzKdTqvBI0ZmiFTZzgrGhe7JLHUqtRM0GoBm2fCx0NugEP4Rn0lYykUafZFEMb9XAMGmNg8NzQm1BviRj+a6sMp+fEqfnxKtY/jPIfd/PiVPz4lT89GHSxN0ChpiKYqCfZSKNPr0Cy/vRpI4ZobI5q9FrQ7HbiAYSfscvCdtHiI1LF0afZFEPlvIHHNrbK+oZB6WMmD/NwLNpR9oFY0HwmFm1uBZtZ4tcDAyFpj3As2s8cdym6UbW4Fm1uBPk2pFmhsjmr0Xk0kBP/PGNCVIo0+yKNPsijT7Io0+yKNPsijT7Io0+yKNPsijT7Io0+yKNNwAP7+Aa32O9NQP//+aiQ85uGbqX8qAMi2gBYHvABBejSCKVRwlwknSwekmWw/oN2DsM0EyRQhkdL8kDDzLGrtwD6vLGeABMYegTk2Uhde+N7ONK/joLprkk/CDZQKaf54kh4UalPgPeBRnphxNDfOSDkDVCjac4840+IEuJYs5IkjOs6sImPzP0b8iCttGKBb+kij60c3ifxYrl/3Xv0hjWIIbeyJ2o61OrdedMz7G8Y+V4d9G9FLwH4MaY8Y8GCnyJMfxZ/ULhYb9VE+x6juTHAyXvX0FlIEFkNBTxfTwLvKkP+0UCZqgugNIBLQog7iPFBonuG3MFiSKD6lVo+qTy4vaslgcrz/GSqAwXnyPxj6CxBfLlZb0ij+0uKoaIGm9ZUEFPEaXdz+BeVqg1I/os1mC7iKu5/rbDGjzB6c3akCTpY0OHZ4wR5PSRELDEuHkb6phpM+RGlLuVN8v26i5wH2ak8KmhBqp3SL8shBam1arJwsvNX69fdGsJSjMBX5NQZZCENAuE9vUvdMwSfJz9D3nS3aDmtVmxKjE6qy0Qsdtpcp0jWe1gU46CQbpsIDYqafR7LzcRxMTEoEGE5H8xdsFKPU/KG3jtjtylNoYQiqmdXcQokdTTxrjLzdzwWB9RiSKFM5v22/GI09Yr8fYSBKmGyQbaBUor/bu578Nm9OI5RhfMKnO09YxqD3x0/cTv53sZVEU7c/jELa5JY+uFXVME91SWsLQOTI63bx+3BV8gt7fCiHffGMMr4/SLihamFOtV+QYZUWHd5XuLXKEQTNG9GCtDao7iJVnWLlxqfnhP5kn54xJCx/gADSvAEDQwIomE3NQANF6/ZkVDu/MVcXcHOw8c3bGk+vuhT6f3Tr4NnUPPpa8+hG7YsyedNHK7l4qjvRnFSDhXEhuLq0Ah9hv8Sdlo1R6Sn/Ag112n1U82sWkpSk5IU6PdNFfaBXK8GR7C2Nm/KMWhnQ9pELP9TVr2XpJfuLJOB4Ttqh2aro90aus+ZPOyTlimgP8jVgUzy5hdO9HMwCPjxHGeyTJKQlxScBGPnU1PjBEgEyOWts0CE8V9x7E1+ee3gjyOCiDLhnYELTSKgdhhCbsf6NMjutWZ5XL1O/+Dd06WT62e38YKgGhhGBI07PXacDqA/XTdThkPYNCOFF26Dz2HMCt2/9Rel4gnmQKJjVIQLnEZeF2Nka2MsRuKmjNAAvaWTbVZe91xRYaCd2ml43cOr1YfxmlJ9hCpBPUZIkE6u07L8owldqs4TigKOZK0I7sng62s8U95/t3/oo6sA2eUUmedjAefrskjQjH5qsbhLJyesMEv9jxGV+GOtLyrtsxaWkPNcHBXXj3iZYGxZN6nIcLqaLlHPLPMnZjQQ8BojhDnKHz1lXMfMEHFe4hkgIyYE4KANL9hLLuv69qnxteZIG9m41ampmUsQlEpx3GFeIMX682UDHk1MHDLGoacoeaYSvz5rZF/WWYAlwl0nsB6gkKRihBrxfbKRJWbOQkodXo9nFAHN55srKEDIkskmsFAhtB8JlWPNfjOILKEFwQ2+LTmoG1KLs/Z6ltBt5TvPtEPzcGsLhbjXYk9Mnx7fWMkjrXZ+E0zX38b3zr9OjFrbOf+GZeo0PLtD+ZxcjEf5XqHI+ptX1Sj9yt27SwlUh2Pc9+QHOag7bIYxKtmp8wV39OP8RJb8Ag5x7IAXkgCSOxdcjFb0PKVaxWKyHQJf68yCmeyzp5vGQ/z1Mxgo8CmZl3OKn0onEfx2GWQgRCFQd7t5jx6j0JEET/agi2LjNP2FvxLe3d+6VlTrs+AGqrBPrK1v4bLgqvYwdPUgwDkeJ1gY/y+d4AuoSo8tkciHJQ/RQ//G0yHoqE/HoH6QfVTaZaXR68fqHs6uCDKayag/cIlpHpr31w1QBHu17ohviYmrFjwJ16jGU5hvY+wfq2w1s20oI9emMn0GkxN5IYpm57T8e0ntXyu1xKfsokhV+HWRUF3uC+mZHMVKCT194/Gz2DVqRfi3W8wvYwilf/bWjHFksIGs3HEaW+hESm6ciT3tfLhohZB9NnVtHS/aUk39m9cNCfFx/zzHzqZXOfLrSs0+rfugDRzcz7/vP93ksdi0Ks8xLNInhwkKzmmG8Dbyvw9p1osUJ/jxCjQtG1DxDBJIkD8AWIHnzPVugs+uZ47tknMAEfstIKysdwA/y3uep1Nfl2IZtm6NgIEZfQbTiEbWeXLX5DVgN+wG8TRnpGvH5Bkiuh1OCkaVtDapxLkFplC11AFeIPMSI2lwFalrsCGHC0obfjxkqbNcF3fPXO2KKbMLYG1ub7jWhiwhjMLPPPp2bzQPV89uu2MW0ZwcPPg7FzufEJPxJ/0RNeHAtpWafTVSeYerO76P+whWDfkOsC0UpaqMIceALU2CB+bc66l6aRePCvq+JW5q6SQYanHeHkhKZKiShTc7zKkksZXIyuRlcjKaUUkKEFrCTYCBipRk3lgB8IZ24X/CwgQAAAAAAAAAA";function Gi(e){return e instanceof Error?e.message.includes("Exchange resulted in fewer coins than expected")||e.message.includes("Slippage")?"Transaction failed because slippage was set too low. A slight increase of one or two percent could help, but don't make it too high to ensure your protection. We also highly recommend using MEVBlocker for extra safety.":e.message.includes("HTTP request failed")&&e.message.includes("eth_call")?"The RPC returned an error, probably a rate-limit. Try again layer or try a different wallet.":e.message:JSON.stringify(e)}async function a$(e){try{return await e()}catch(t){En({text:Gi(t),type:"error"});return}}async function Qs(e,t){e.value=!0;try{return await t()}catch(n){En({text:Gi(n),type:"error"});return}finally{e.value=!1}}const c$={class:"buttons"},u$={class:"connectors-body"},l$={class:"connectors"},d$=["src"],f$={key:1,class:"empty"},p$={class:"name"},m$=ae({__name:"WalletConnectButton",setup(e){const{connect:t}=h4(),n=M_(),s=["injected","walletConnect","coinbaseWalletSDK","safe"],r=M(()=>n.value.filter(u=>s.includes(u.id))),o=le(!1);function i(u){switch(u.id){case"injected":return n$;case"walletConnect":return r$;case"coinbaseWalletSDK":return o$;case"safe":return i$;case"io.rabby":return s$;default:return""}}function a(u){return u.id==="injected"?"Browser Extension":u.name}function c(u){t({connector:u},{onError:l=>{En({text:Gi(l),type:"error"})}}),o.value=!1}return(u,l)=>{const d=Mt,f=He,p=ia;return F(),J("div",c$,[$(d,{class:"button primary",onClick:l[0]||(l[0]=m=>o.value=!0)},{default:Y(()=>l[2]||(l[2]=[we(" Connect Wallet ")])),_:1}),ye("",!0),$(p,{show:v(o),onClose:l[1]||(l[1]=m=>o.value=!1)},{default:Y(()=>[$(f,null,{default:Y(()=>[T("div",u$,[l[4]||(l[4]=T("div",{class:"title"},"Connect Your Wallet",-1)),T("div",l$,[(F(!0),J(De,null,Rt(v(r),m=>(F(),fe(d,{key:m.id,class:"connector",onClick:h=>c(m)},{default:Y(()=>[i(m)?(F(),J("img",{key:0,src:i(m)},null,8,d$)):(F(),J("div",f$)),T("div",p$,Z(a(m)),1)]),_:2},1032,["onClick"]))),128))])])]),_:1})]),_:1},8,["show"])])}}}),Mh=pe(m$,[["__scopeId","data-v-74aea17a"]]),h$={class:"wallet"},y$={key:0},b$={key:1},g$={key:0,class:"info"},v$=ae({__name:"Wallet",props:{labelPleaseConnect:{}},setup(e){const{disconnect:t}=b4(),{isConnected:n,chainId:s,address:r}=tt(),{switchChain:o}=O_(),i=M(()=>s.value===It.id),a=()=>{o({chainId:It.id})};function c(){t(void 0,{onError:u=>{En({text:Gi(u),type:"error"})}})}return(u,l)=>{const d=Mt,f=J4;return F(),J("div",h$,[v(n)?(F(),J("div",y$,[v(i)?(F(),fe(d,{key:1,class:"disconnect",onClick:c},{default:Y(()=>[$(f),we(" "+Z(v(Hl)(v(r))),1)]),_:1})):(F(),fe(d,{key:0,class:"change primary",onClick:a},{default:Y(()=>l[0]||(l[0]=[we(" Change Network ")])),_:1}))])):(F(),J("div",b$,[$(Mh),u.labelPleaseConnect?(F(),J("span",g$,Z(u.labelPleaseConnect),1)):ye("",!0)]))])}}}),Oh=pe(v$,[["__scopeId","data-v-a294fc76"]]);/*!
 * pinia v2.2.4
 * (c) 2024 Eduardo San Martin Morote
 * @license MIT
 */let q_;const Ql=e=>q_=e,W_=Symbol();function Hp(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Ra;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Ra||(Ra={}));function w$(){const e=lm(!0),t=e.run(()=>le({}));let n=[],s=[];const r=gm({install(o){Ql(r),r._a=o,o.provide(W_,r),o.config.globalProperties.$pinia=r,s.forEach(i=>n.push(i)),s=[]},use(o){return!this._a&&!mI?s.push(o):n.push(o),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return r}const G_=()=>{};function Ib(e,t,n,s=G_){e.push(t);const r=()=>{const o=e.indexOf(t);o>-1&&(e.splice(o,1),s())};return!n&&dm()&&Wn(r),r}function Xo(e,...t){e.slice().forEach(n=>{n(...t)})}const _$=e=>e(),Rb=Symbol(),cf=Symbol();function zp(e,t){e instanceof Map&&t instanceof Map?t.forEach((n,s)=>e.set(s,n)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const s=t[n],r=e[n];Hp(r)&&Hp(s)&&e.hasOwnProperty(n)&&!$e(s)&&!Bs(s)?e[n]=zp(r,s):e[n]=s}return e}const x$=Symbol();function C$(e){return!Hp(e)||!e.hasOwnProperty(x$)}const{assign:fr}=Object;function A$(e){return!!($e(e)&&e.effect)}function T$(e,t,n,s){const{state:r,actions:o,getters:i}=t,a=n.state.value[e];let c;function u(){a||(n.state.value[e]=r?r():{});const l=ll(n.state.value[e]);return fr(l,o,Object.keys(i||{}).reduce((d,f)=>(d[f]=gm(M(()=>{Ql(n);const p=n._s.get(e);return i[f].call(p,p)})),d),{}))}return c=X_(e,u,t,n,s,!0),c}function X_(e,t,n={},s,r,o){let i;const a=fr({actions:{}},n),c={deep:!0};let u,l,d=[],f=[],p;const m=s.state.value[e];!o&&!m&&(s.state.value[e]={}),le({});let h;function y(k){let S;u=l=!1,typeof k=="function"?(k(s.state.value[e]),S={type:Ra.patchFunction,storeId:e,events:p}):(zp(s.state.value[e],k),S={type:Ra.patchObject,payload:k,storeId:e,events:p});const R=h=Symbol();Js().then(()=>{h===R&&(u=!0)}),l=!0,Xo(d,S,s.state.value[e])}const b=o?function(){const{state:S}=n,R=S?S():{};this.$patch(B=>{fr(B,R)})}:G_;function g(){i.stop(),d=[],f=[],s._s.delete(e)}const w=(k,S="")=>{if(Rb in k)return k[cf]=S,k;const R=function(){Ql(s);const B=Array.from(arguments),L=[],X=[];function z(te){L.push(te)}function ie(te){X.push(te)}Xo(f,{args:B,name:R[cf],store:A,after:z,onError:ie});let ne;try{ne=k.apply(this&&this.$id===e?this:A,B)}catch(te){throw Xo(X,te),te}return ne instanceof Promise?ne.then(te=>(Xo(L,te),te)).catch(te=>(Xo(X,te),Promise.reject(te))):(Xo(L,ne),ne)};return R[Rb]=!0,R[cf]=S,R},_={_p:s,$id:e,$onAction:Ib.bind(null,f),$patch:y,$reset:b,$subscribe(k,S={}){const R=Ib(d,k,S.detached,()=>B()),B=i.run(()=>Ce(()=>s.state.value[e],L=>{(S.flush==="sync"?l:u)&&k({storeId:e,type:Ra.direct,events:p},L)},fr({},c,S)));return R},$dispose:g},A=zs(_);s._s.set(e,A);const C=(s._a&&s._a.runWithContext||_$)(()=>s._e.run(()=>(i=lm()).run(()=>t({action:w}))));for(const k in C){const S=C[k];if($e(S)&&!A$(S)||Bs(S))o||(m&&C$(S)&&($e(S)?S.value=m[k]:zp(S,m[k])),s.state.value[e][k]=S);else if(typeof S=="function"){const R=w(S,k);C[k]=R,a.actions[k]=S}}return fr(A,C),fr(Ve(A),C),Object.defineProperty(A,"$state",{get:()=>s.state.value[e],set:k=>{y(S=>{fr(S,k)})}}),s._p.forEach(k=>{fr(A,i.run(()=>k({store:A,app:s._a,pinia:s,options:a})))}),m&&o&&n.hydrate&&n.hydrate(A.$state,m),u=!0,l=!0,A}function Lh(e,t,n){let s,r;const o=typeof t=="function";typeof e=="string"?(s=e,r=o?n:t):(r=e,s=e.id);function i(a,c){const u=Em();return a=a||(u?Nt(W_,null):null),a&&Ql(a),a=q_,a._s.has(s)||(o?X_(s,t,r,a):T$(s,r,a)),a._s.get(s)}return i.$id=s,i}function sr(e){{e=Ve(e);const t={};for(const n in e){const s=e[n];($e(s)||Bs(s))&&(t[n]=h1(e,n))}return t}}const Lc=Lh("pageStore",()=>({pages:le([])}));/*!
  * vue-router v4.4.5
  * (c) 2024 Eduardo San Martin Morote
  * @license MIT
  */const Yo=typeof document<"u";function K_(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function E$(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&K_(e.default)}const Ke=Object.assign;function uf(e,t){const n={};for(const s in t){const r=t[s];n[s]=qn(r)?r.map(e):e(r)}return n}const $a=()=>{},qn=Array.isArray,Q_=/#/g,S$=/&/g,P$=/\//g,k$=/=/g,I$=/\?/g,Z_=/\+/g,R$=/%5B/g,$$=/%5D/g,Y_=/%5E/g,M$=/%60/g,J_=/%7B/g,O$=/%7C/g,e6=/%7D/g,L$=/%20/g;function Fh(e){return encodeURI(""+e).replace(O$,"|").replace(R$,"[").replace($$,"]")}function F$(e){return Fh(e).replace(J_,"{").replace(e6,"}").replace(Y_,"^")}function qp(e){return Fh(e).replace(Z_,"%2B").replace(L$,"+").replace(Q_,"%23").replace(S$,"%26").replace(M$,"`").replace(J_,"{").replace(e6,"}").replace(Y_,"^")}function N$(e){return qp(e).replace(k$,"%3D")}function B$(e){return Fh(e).replace(Q_,"%23").replace(I$,"%3F")}function D$(e){return e==null?"":B$(e).replace(P$,"%2F")}function uc(e){try{return decodeURIComponent(""+e)}catch{}return""+e}const U$=/\/$/,V$=e=>e.replace(U$,"");function lf(e,t,n="/"){let s,r={},o="",i="";const a=t.indexOf("#");let c=t.indexOf("?");return a<c&&a>=0&&(c=-1),c>-1&&(s=t.slice(0,c),o=t.slice(c+1,a>-1?a:t.length),r=e(o)),a>-1&&(s=s||t.slice(0,a),i=t.slice(a,t.length)),s=q$(s??t,n),{fullPath:s+(o&&"?")+o+i,path:s,query:r,hash:uc(i)}}function j$(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function $b(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function H$(e,t,n){const s=t.matched.length-1,r=n.matched.length-1;return s>-1&&s===r&&Xi(t.matched[s],n.matched[r])&&t6(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function Xi(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function t6(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!z$(e[n],t[n]))return!1;return!0}function z$(e,t){return qn(e)?Mb(e,t):qn(t)?Mb(t,e):e===t}function Mb(e,t){return qn(t)?e.length===t.length&&e.every((n,s)=>n===t[s]):e.length===1&&e[0]===t}function q$(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),s=e.split("/"),r=s[s.length-1];(r===".."||r===".")&&s.push("");let o=n.length-1,i,a;for(i=0;i<s.length;i++)if(a=s[i],a!==".")if(a==="..")o>1&&o--;else break;return n.slice(0,o).join("/")+"/"+s.slice(i).join("/")}const ur={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};var lc;(function(e){e.pop="pop",e.push="push"})(lc||(lc={}));var Ma;(function(e){e.back="back",e.forward="forward",e.unknown=""})(Ma||(Ma={}));function W$(e){if(!e)if(Yo){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),V$(e)}const G$=/^[^#]+#/;function X$(e,t){return e.replace(G$,"#")+t}function K$(e,t){const n=document.documentElement.getBoundingClientRect(),s=e.getBoundingClientRect();return{behavior:t.behavior,left:s.left-n.left-(t.left||0),top:s.top-n.top-(t.top||0)}}const Zl=()=>({left:window.scrollX,top:window.scrollY});function Q$(e){let t;if("el"in e){const n=e.el,s=typeof n=="string"&&n.startsWith("#"),r=typeof n=="string"?s?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!r)return;t=K$(r,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function Ob(e,t){return(history.state?history.state.position-t:-1)+e}const Wp=new Map;function Z$(e,t){Wp.set(e,t)}function Y$(e){const t=Wp.get(e);return Wp.delete(e),t}let J$=()=>location.protocol+"//"+location.host;function n6(e,t){const{pathname:n,search:s,hash:r}=t,o=e.indexOf("#");if(o>-1){let a=r.includes(e.slice(o))?e.slice(o).length:1,c=r.slice(a);return c[0]!=="/"&&(c="/"+c),$b(c,"")}return $b(n,e)+s+r}function eM(e,t,n,s){let r=[],o=[],i=null;const a=({state:f})=>{const p=n6(e,location),m=n.value,h=t.value;let y=0;if(f){if(n.value=p,t.value=f,i&&i===m){i=null;return}y=h?f.position-h.position:0}else s(p);r.forEach(b=>{b(n.value,m,{delta:y,type:lc.pop,direction:y?y>0?Ma.forward:Ma.back:Ma.unknown})})};function c(){i=n.value}function u(f){r.push(f);const p=()=>{const m=r.indexOf(f);m>-1&&r.splice(m,1)};return o.push(p),p}function l(){const{history:f}=window;f.state&&f.replaceState(Ke({},f.state,{scroll:Zl()}),"")}function d(){for(const f of o)f();o=[],window.removeEventListener("popstate",a),window.removeEventListener("beforeunload",l)}return window.addEventListener("popstate",a),window.addEventListener("beforeunload",l,{passive:!0}),{pauseListeners:c,listen:u,destroy:d}}function Lb(e,t,n,s=!1,r=!1){return{back:e,current:t,forward:n,replaced:s,position:window.history.length,scroll:r?Zl():null}}function tM(e){const{history:t,location:n}=window,s={value:n6(e,n)},r={value:t.state};r.value||o(s.value,{back:null,current:s.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function o(c,u,l){const d=e.indexOf("#"),f=d>-1?(n.host&&document.querySelector("base")?e:e.slice(d))+c:J$()+e+c;try{t[l?"replaceState":"pushState"](u,"",f),r.value=u}catch(p){console.error(p),n[l?"replace":"assign"](f)}}function i(c,u){const l=Ke({},t.state,Lb(r.value.back,c,r.value.forward,!0),u,{position:r.value.position});o(c,l,!0),s.value=c}function a(c,u){const l=Ke({},r.value,t.state,{forward:c,scroll:Zl()});o(l.current,l,!0);const d=Ke({},Lb(s.value,c,null),{position:l.position+1},u);o(c,d,!1),s.value=c}return{location:s,state:r,push:a,replace:i}}function nM(e){e=W$(e);const t=tM(e),n=eM(e,t.state,t.location,t.replace);function s(o,i=!0){i||n.pauseListeners(),history.go(o)}const r=Ke({location:"",base:e,go:s,createHref:X$.bind(null,e)},t,n);return Object.defineProperty(r,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(r,"state",{enumerable:!0,get:()=>t.state.value}),r}function sM(e){return typeof e=="string"||e&&typeof e=="object"}function s6(e){return typeof e=="string"||typeof e=="symbol"}const r6=Symbol("");var Fb;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(Fb||(Fb={}));function Ki(e,t){return Ke(new Error,{type:e,[r6]:!0},t)}function Cs(e,t){return e instanceof Error&&r6 in e&&(t==null||!!(e.type&t))}const Nb="[^/]+?",rM={sensitive:!1,strict:!1,start:!0,end:!0},oM=/[.+*?^${}()[\]/\\]/g;function iM(e,t){const n=Ke({},rM,t),s=[];let r=n.start?"^":"";const o=[];for(const u of e){const l=u.length?[]:[90];n.strict&&!u.length&&(r+="/");for(let d=0;d<u.length;d++){const f=u[d];let p=40+(n.sensitive?.25:0);if(f.type===0)d||(r+="/"),r+=f.value.replace(oM,"\\$&"),p+=40;else if(f.type===1){const{value:m,repeatable:h,optional:y,regexp:b}=f;o.push({name:m,repeatable:h,optional:y});const g=b||Nb;if(g!==Nb){p+=10;try{new RegExp(`(${g})`)}catch(_){throw new Error(`Invalid custom RegExp for param "${m}" (${g}): `+_.message)}}let w=h?`((?:${g})(?:/(?:${g}))*)`:`(${g})`;d||(w=y&&u.length<2?`(?:/${w})`:"/"+w),y&&(w+="?"),r+=w,p+=20,y&&(p+=-8),h&&(p+=-20),g===".*"&&(p+=-50)}l.push(p)}s.push(l)}if(n.strict&&n.end){const u=s.length-1;s[u][s[u].length-1]+=.7000000000000001}n.strict||(r+="/?"),n.end?r+="$":n.strict&&(r+="(?:/|$)");const i=new RegExp(r,n.sensitive?"":"i");function a(u){const l=u.match(i),d={};if(!l)return null;for(let f=1;f<l.length;f++){const p=l[f]||"",m=o[f-1];d[m.name]=p&&m.repeatable?p.split("/"):p}return d}function c(u){let l="",d=!1;for(const f of e){(!d||!l.endsWith("/"))&&(l+="/"),d=!1;for(const p of f)if(p.type===0)l+=p.value;else if(p.type===1){const{value:m,repeatable:h,optional:y}=p,b=m in u?u[m]:"";if(qn(b)&&!h)throw new Error(`Provided param "${m}" is an array but it is not repeatable (* or + modifiers)`);const g=qn(b)?b.join("/"):b;if(!g)if(y)f.length<2&&(l.endsWith("/")?l=l.slice(0,-1):d=!0);else throw new Error(`Missing required param "${m}"`);l+=g}}return l||"/"}return{re:i,score:s,keys:o,parse:a,stringify:c}}function aM(e,t){let n=0;for(;n<e.length&&n<t.length;){const s=t[n]-e[n];if(s)return s;n++}return e.length<t.length?e.length===1&&e[0]===80?-1:1:e.length>t.length?t.length===1&&t[0]===80?1:-1:0}function o6(e,t){let n=0;const s=e.score,r=t.score;for(;n<s.length&&n<r.length;){const o=aM(s[n],r[n]);if(o)return o;n++}if(Math.abs(r.length-s.length)===1){if(Bb(s))return 1;if(Bb(r))return-1}return r.length-s.length}function Bb(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const cM={type:0,value:""},uM=/[a-zA-Z0-9_]/;function lM(e){if(!e)return[[]];if(e==="/")return[[cM]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(p){throw new Error(`ERR (${n})/"${u}": ${p}`)}let n=0,s=n;const r=[];let o;function i(){o&&r.push(o),o=[]}let a=0,c,u="",l="";function d(){u&&(n===0?o.push({type:0,value:u}):n===1||n===2||n===3?(o.length>1&&(c==="*"||c==="+")&&t(`A repeatable param (${u}) must be alone in its segment. eg: '/:ids+.`),o.push({type:1,value:u,regexp:l,repeatable:c==="*"||c==="+",optional:c==="*"||c==="?"})):t("Invalid state to consume buffer"),u="")}function f(){u+=c}for(;a<e.length;){if(c=e[a++],c==="\\"&&n!==2){s=n,n=4;continue}switch(n){case 0:c==="/"?(u&&d(),i()):c===":"?(d(),n=1):f();break;case 4:f(),n=s;break;case 1:c==="("?n=2:uM.test(c)?f():(d(),n=0,c!=="*"&&c!=="?"&&c!=="+"&&a--);break;case 2:c===")"?l[l.length-1]=="\\"?l=l.slice(0,-1)+c:n=3:l+=c;break;case 3:d(),n=0,c!=="*"&&c!=="?"&&c!=="+"&&a--,l="";break;default:t("Unknown state");break}}return n===2&&t(`Unfinished custom RegExp for param "${u}"`),d(),i(),r}function dM(e,t,n){const s=iM(lM(e.path),n),r=Ke(s,{record:e,parent:t,children:[],alias:[]});return t&&!r.record.aliasOf==!t.record.aliasOf&&t.children.push(r),r}function fM(e,t){const n=[],s=new Map;t=jb({strict:!1,end:!0,sensitive:!1},t);function r(d){return s.get(d)}function o(d,f,p){const m=!p,h=Ub(d);h.aliasOf=p&&p.record;const y=jb(t,d),b=[h];if("alias"in d){const _=typeof d.alias=="string"?[d.alias]:d.alias;for(const A of _)b.push(Ub(Ke({},h,{components:p?p.record.components:h.components,path:A,aliasOf:p?p.record:h})))}let g,w;for(const _ of b){const{path:A}=_;if(f&&A[0]!=="/"){const x=f.record.path,C=x[x.length-1]==="/"?"":"/";_.path=f.record.path+(A&&C+A)}if(g=dM(_,f,y),p?p.alias.push(g):(w=w||g,w!==g&&w.alias.push(g),m&&d.name&&!Vb(g)&&i(d.name)),i6(g)&&c(g),h.children){const x=h.children;for(let C=0;C<x.length;C++)o(x[C],g,p&&p.children[C])}p=p||g}return w?()=>{i(w)}:$a}function i(d){if(s6(d)){const f=s.get(d);f&&(s.delete(d),n.splice(n.indexOf(f),1),f.children.forEach(i),f.alias.forEach(i))}else{const f=n.indexOf(d);f>-1&&(n.splice(f,1),d.record.name&&s.delete(d.record.name),d.children.forEach(i),d.alias.forEach(i))}}function a(){return n}function c(d){const f=hM(d,n);n.splice(f,0,d),d.record.name&&!Vb(d)&&s.set(d.record.name,d)}function u(d,f){let p,m={},h,y;if("name"in d&&d.name){if(p=s.get(d.name),!p)throw Ki(1,{location:d});y=p.record.name,m=Ke(Db(f.params,p.keys.filter(w=>!w.optional).concat(p.parent?p.parent.keys.filter(w=>w.optional):[]).map(w=>w.name)),d.params&&Db(d.params,p.keys.map(w=>w.name))),h=p.stringify(m)}else if(d.path!=null)h=d.path,p=n.find(w=>w.re.test(h)),p&&(m=p.parse(h),y=p.record.name);else{if(p=f.name?s.get(f.name):n.find(w=>w.re.test(f.path)),!p)throw Ki(1,{location:d,currentLocation:f});y=p.record.name,m=Ke({},f.params,d.params),h=p.stringify(m)}const b=[];let g=p;for(;g;)b.unshift(g.record),g=g.parent;return{name:y,path:h,params:m,matched:b,meta:mM(b)}}e.forEach(d=>o(d));function l(){n.length=0,s.clear()}return{addRoute:o,resolve:u,removeRoute:i,clearRoutes:l,getRoutes:a,getRecordMatcher:r}}function Db(e,t){const n={};for(const s of t)s in e&&(n[s]=e[s]);return n}function Ub(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:pM(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function pM(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const s in e.components)t[s]=typeof n=="object"?n[s]:n;return t}function Vb(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function mM(e){return e.reduce((t,n)=>Ke(t,n.meta),{})}function jb(e,t){const n={};for(const s in e)n[s]=s in t?t[s]:e[s];return n}function hM(e,t){let n=0,s=t.length;for(;n!==s;){const o=n+s>>1;o6(e,t[o])<0?s=o:n=o+1}const r=yM(e);return r&&(s=t.lastIndexOf(r,s-1)),s}function yM(e){let t=e;for(;t=t.parent;)if(i6(t)&&o6(e,t)===0)return t}function i6({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function bM(e){const t={};if(e===""||e==="?")return t;const s=(e[0]==="?"?e.slice(1):e).split("&");for(let r=0;r<s.length;++r){const o=s[r].replace(Z_," "),i=o.indexOf("="),a=uc(i<0?o:o.slice(0,i)),c=i<0?null:uc(o.slice(i+1));if(a in t){let u=t[a];qn(u)||(u=t[a]=[u]),u.push(c)}else t[a]=c}return t}function Hb(e){let t="";for(let n in e){const s=e[n];if(n=N$(n),s==null){s!==void 0&&(t+=(t.length?"&":"")+n);continue}(qn(s)?s.map(o=>o&&qp(o)):[s&&qp(s)]).forEach(o=>{o!==void 0&&(t+=(t.length?"&":"")+n,o!=null&&(t+="="+o))})}return t}function gM(e){const t={};for(const n in e){const s=e[n];s!==void 0&&(t[n]=qn(s)?s.map(r=>r==null?null:""+r):s==null?s:""+s)}return t}const vM=Symbol(""),zb=Symbol(""),Yl=Symbol(""),Nh=Symbol(""),Gp=Symbol("");function ga(){let e=[];function t(s){return e.push(s),()=>{const r=e.indexOf(s);r>-1&&e.splice(r,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function br(e,t,n,s,r,o=i=>i()){const i=s&&(s.enterCallbacks[r]=s.enterCallbacks[r]||[]);return()=>new Promise((a,c)=>{const u=f=>{f===!1?c(Ki(4,{from:n,to:t})):f instanceof Error?c(f):sM(f)?c(Ki(2,{from:t,to:f})):(i&&s.enterCallbacks[r]===i&&typeof f=="function"&&i.push(f),a())},l=o(()=>e.call(s&&s.instances[r],t,n,u));let d=Promise.resolve(l);e.length<3&&(d=d.then(u)),d.catch(f=>c(f))})}function df(e,t,n,s,r=o=>o()){const o=[];for(const i of e)for(const a in i.components){let c=i.components[a];if(!(t!=="beforeRouteEnter"&&!i.instances[a]))if(K_(c)){const l=(c.__vccOpts||c)[t];l&&o.push(br(l,n,s,i,a,r))}else{let u=c();o.push(()=>u.then(l=>{if(!l)throw new Error(`Couldn't resolve component "${a}" at "${i.path}"`);const d=E$(l)?l.default:l;i.mods[a]=l,i.components[a]=d;const p=(d.__vccOpts||d)[t];return p&&br(p,n,s,i,a,r)()}))}}return o}function qb(e){const t=Nt(Yl),n=Nt(Nh),s=M(()=>{const c=v(e.to);return t.resolve(c)}),r=M(()=>{const{matched:c}=s.value,{length:u}=c,l=c[u-1],d=n.matched;if(!l||!d.length)return-1;const f=d.findIndex(Xi.bind(null,l));if(f>-1)return f;const p=Wb(c[u-2]);return u>1&&Wb(l)===p&&d[d.length-1].path!==p?d.findIndex(Xi.bind(null,c[u-2])):f}),o=M(()=>r.value>-1&&CM(n.params,s.value.params)),i=M(()=>r.value>-1&&r.value===n.matched.length-1&&t6(n.params,s.value.params));function a(c={}){return xM(c)?t[v(e.replace)?"replace":"push"](v(e.to)).catch($a):Promise.resolve()}return{route:s,href:M(()=>s.value.href),isActive:o,isExactActive:i,navigate:a}}const wM=ae({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:qb,setup(e,{slots:t}){const n=zs(qb(e)),{options:s}=Nt(Yl),r=M(()=>({[Gb(e.activeClass,s.linkActiveClass,"router-link-active")]:n.isActive,[Gb(e.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const o=t.default&&t.default(n);return e.custom?o:Fr("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:r.value},o)}}}),_M=wM;function xM(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function CM(e,t){for(const n in t){const s=t[n],r=e[n];if(typeof s=="string"){if(s!==r)return!1}else if(!qn(r)||r.length!==s.length||s.some((o,i)=>o!==r[i]))return!1}return!0}function Wb(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const Gb=(e,t,n)=>e??t??n,AM=ae({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const s=Nt(Gp),r=M(()=>e.route||s.value),o=Nt(zb,0),i=M(()=>{let u=v(o);const{matched:l}=r.value;let d;for(;(d=l[u])&&!d.components;)u++;return u}),a=M(()=>r.value.matched[i.value]);Sa(zb,M(()=>i.value+1)),Sa(vM,a),Sa(Gp,r);const c=le();return Ce(()=>[c.value,a.value,e.name],([u,l,d],[f,p,m])=>{l&&(l.instances[d]=u,p&&p!==l&&u&&u===f&&(l.leaveGuards.size||(l.leaveGuards=p.leaveGuards),l.updateGuards.size||(l.updateGuards=p.updateGuards))),u&&l&&(!p||!Xi(l,p)||!f)&&(l.enterCallbacks[d]||[]).forEach(h=>h(u))},{flush:"post"}),()=>{const u=r.value,l=e.name,d=a.value,f=d&&d.components[l];if(!f)return Xb(n.default,{Component:f,route:u});const p=d.props[l],m=p?p===!0?u.params:typeof p=="function"?p(u):p:null,y=Fr(f,Ke({},m,t,{onVnodeUnmounted:b=>{b.component.isUnmounted&&(d.instances[l]=null)},ref:c}));return Xb(n.default,{Component:y,route:u})||y}}});function Xb(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const TM=AM;function EM(e){const t=fM(e.routes,e),n=e.parseQuery||bM,s=e.stringifyQuery||Hb,r=e.history,o=ga(),i=ga(),a=ga(),c=Bo(ur);let u=ur;Yo&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const l=uf.bind(null,se=>""+se),d=uf.bind(null,D$),f=uf.bind(null,uc);function p(se,V){let j,U;return s6(se)?(j=t.getRecordMatcher(se),U=V):U=se,t.addRoute(U,j)}function m(se){const V=t.getRecordMatcher(se);V&&t.removeRoute(V)}function h(){return t.getRoutes().map(se=>se.record)}function y(se){return!!t.getRecordMatcher(se)}function b(se,V){if(V=Ke({},V||c.value),typeof se=="string"){const O=lf(n,se,V.path),q=t.resolve({path:O.path},V),K=r.createHref(O.fullPath);return Ke(O,q,{params:f(q.params),hash:uc(O.hash),redirectedFrom:void 0,href:K})}let j;if(se.path!=null)j=Ke({},se,{path:lf(n,se.path,V.path).path});else{const O=Ke({},se.params);for(const q in O)O[q]==null&&delete O[q];j=Ke({},se,{params:d(O)}),V.params=d(V.params)}const U=t.resolve(j,V),oe=se.hash||"";U.params=l(f(U.params));const be=j$(s,Ke({},se,{hash:F$(oe),path:U.path})),P=r.createHref(be);return Ke({fullPath:be,hash:oe,query:s===Hb?gM(se.query):se.query||{}},U,{redirectedFrom:void 0,href:P})}function g(se){return typeof se=="string"?lf(n,se,c.value.path):Ke({},se)}function w(se,V){if(u!==se)return Ki(8,{from:V,to:se})}function _(se){return C(se)}function A(se){return _(Ke(g(se),{replace:!0}))}function x(se){const V=se.matched[se.matched.length-1];if(V&&V.redirect){const{redirect:j}=V;let U=typeof j=="function"?j(se):j;return typeof U=="string"&&(U=U.includes("?")||U.includes("#")?U=g(U):{path:U},U.params={}),Ke({query:se.query,hash:se.hash,params:U.path!=null?{}:se.params},U)}}function C(se,V){const j=u=b(se),U=c.value,oe=se.state,be=se.force,P=se.replace===!0,O=x(j);if(O)return C(Ke(g(O),{state:typeof O=="object"?Ke({},oe,O.state):oe,force:be,replace:P}),V||j);const q=j;q.redirectedFrom=V;let K;return!be&&H$(s,U,j)&&(K=Ki(16,{to:q,from:U}),Fe(U,U,!0,!1)),(K?Promise.resolve(K):R(q,U)).catch(G=>Cs(G)?Cs(G,2)?G:_e(G):ce(G,q,U)).then(G=>{if(G){if(Cs(G,2))return C(Ke({replace:P},g(G.to),{state:typeof G.to=="object"?Ke({},oe,G.to.state):oe,force:be}),V||q)}else G=L(q,U,!0,P,oe);return B(q,U,G),G})}function k(se,V){const j=w(se,V);return j?Promise.reject(j):Promise.resolve()}function S(se){const V=Ye.values().next().value;return V&&typeof V.runWithContext=="function"?V.runWithContext(se):se()}function R(se,V){let j;const[U,oe,be]=SM(se,V);j=df(U.reverse(),"beforeRouteLeave",se,V);for(const O of U)O.leaveGuards.forEach(q=>{j.push(br(q,se,V))});const P=k.bind(null,se,V);return j.push(P),Xe(j).then(()=>{j=[];for(const O of o.list())j.push(br(O,se,V));return j.push(P),Xe(j)}).then(()=>{j=df(oe,"beforeRouteUpdate",se,V);for(const O of oe)O.updateGuards.forEach(q=>{j.push(br(q,se,V))});return j.push(P),Xe(j)}).then(()=>{j=[];for(const O of be)if(O.beforeEnter)if(qn(O.beforeEnter))for(const q of O.beforeEnter)j.push(br(q,se,V));else j.push(br(O.beforeEnter,se,V));return j.push(P),Xe(j)}).then(()=>(se.matched.forEach(O=>O.enterCallbacks={}),j=df(be,"beforeRouteEnter",se,V,S),j.push(P),Xe(j))).then(()=>{j=[];for(const O of i.list())j.push(br(O,se,V));return j.push(P),Xe(j)}).catch(O=>Cs(O,8)?O:Promise.reject(O))}function B(se,V,j){a.list().forEach(U=>S(()=>U(se,V,j)))}function L(se,V,j,U,oe){const be=w(se,V);if(be)return be;const P=V===ur,O=Yo?history.state:{};j&&(U||P?r.replace(se.fullPath,Ke({scroll:P&&O&&O.scroll},oe)):r.push(se.fullPath,oe)),c.value=se,Fe(se,V,j,P),_e()}let X;function z(){X||(X=r.listen((se,V,j)=>{if(!mt.listening)return;const U=b(se),oe=x(U);if(oe){C(Ke(oe,{replace:!0}),U).catch($a);return}u=U;const be=c.value;Yo&&Z$(Ob(be.fullPath,j.delta),Zl()),R(U,be).catch(P=>Cs(P,12)?P:Cs(P,2)?(C(P.to,U).then(O=>{Cs(O,20)&&!j.delta&&j.type===lc.pop&&r.go(-1,!1)}).catch($a),Promise.reject()):(j.delta&&r.go(-j.delta,!1),ce(P,U,be))).then(P=>{P=P||L(U,be,!1),P&&(j.delta&&!Cs(P,8)?r.go(-j.delta,!1):j.type===lc.pop&&Cs(P,20)&&r.go(-1,!1)),B(U,be,P)}).catch($a)}))}let ie=ga(),ne=ga(),te;function ce(se,V,j){_e(se);const U=ne.list();return U.length?U.forEach(oe=>oe(se,V,j)):console.error(se),Promise.reject(se)}function he(){return te&&c.value!==ur?Promise.resolve():new Promise((se,V)=>{ie.add([se,V])})}function _e(se){return te||(te=!se,z(),ie.list().forEach(([V,j])=>se?j(se):V()),ie.reset()),se}function Fe(se,V,j,U){const{scrollBehavior:oe}=e;if(!Yo||!oe)return Promise.resolve();const be=!j&&Y$(Ob(se.fullPath,0))||(U||!j)&&history.state&&history.state.scroll||null;return Js().then(()=>oe(se,V,be)).then(P=>P&&Q$(P)).catch(P=>ce(P,se,V))}const Ae=se=>r.go(se);let qe;const Ye=new Set,mt={currentRoute:c,listening:!0,addRoute:p,removeRoute:m,clearRoutes:t.clearRoutes,hasRoute:y,getRoutes:h,resolve:b,options:e,push:_,replace:A,go:Ae,back:()=>Ae(-1),forward:()=>Ae(1),beforeEach:o.add,beforeResolve:i.add,afterEach:a.add,onError:ne.add,isReady:he,install(se){const V=this;se.component("RouterLink",_M),se.component("RouterView",TM),se.config.globalProperties.$router=V,Object.defineProperty(se.config.globalProperties,"$route",{enumerable:!0,get:()=>v(c)}),Yo&&!qe&&c.value===ur&&(qe=!0,_(r.location).catch(oe=>{}));const j={};for(const oe in ur)Object.defineProperty(j,oe,{get:()=>c.value[oe],enumerable:!0});se.provide(Yl,V),se.provide(Nh,ul(j)),se.provide(Gp,c);const U=se.unmount;Ye.add(se),se.unmount=function(){Ye.delete(se),Ye.size<1&&(u=ur,X&&X(),X=null,c.value=ur,qe=!1,te=!1),U()}}};function Xe(se){return se.reduce((V,j)=>V.then(()=>S(j)),Promise.resolve())}return mt}function SM(e,t){const n=[],s=[],r=[],o=Math.max(t.matched.length,e.matched.length);for(let i=0;i<o;i++){const a=t.matched[i];a&&(e.matched.find(u=>Xi(u,a))?s.push(a):n.push(a));const c=e.matched[i];c&&(t.matched.find(u=>Xi(u,c))||r.push(c))}return[n,s,r]}function aa(){return Nt(Yl)}function Ho(e){return Nt(Nh)}const PM={class:"header-desktop"},kM={class:"navigation"},IM={class:"plane"},RM={class:"nav-link-container"},$M={key:0,src:uR},MM={class:"support"},OM=ae({__name:"HeaderDesktop",setup(e){const t=Lc(),n=Ho(),s=M(()=>t.pages.filter(o=>o.visible)),r=M(()=>{let o=12;for(const i of t.pages)if(Mo(i.titleRoute,n)){o=i.planeX;break}return`transform: translateX(${o}px) rotate(45deg);`});return(o,i)=>{const a=Ha("router-link"),c=aR,u=kh;return F(),J("header",null,[T("div",PM,[$(a,{to:"/",class:"title"},{default:Y(()=>i[0]||(i[0]=[T("img",{src:D_},null,-1)])),_:1}),T("nav",kM,[T("ul",null,[T("span",IM,[$(c,{style:il(v(r))},null,8,["style"])]),i[1]||(i[1]=T("img",{src:Eb},null,-1)),(F(!0),J(De,null,Rt(v(s),(l,d)=>(F(),J(De,{key:l.title},[T("li",null,[$(a,{class:Pe(["nav-link",{"router-link-active":v(Mo)(l.titleRoute,v(n))}]),to:Array.isArray(l.titleRoute)?l.titleRoute[0]:l.titleRoute},{default:Y(()=>[T("div",RM,Z(l.title),1)]),_:2},1032,["class","to"])]),d<v(s).length-1?(F(),J("img",$M)):ye("",!0)],64))),128)),i[2]||(i[2]=T("img",{src:Eb},null,-1))])]),T("nav",MM,[$(Oh),$(u)])])])}}}),LM=pe(OM,[["__scopeId","data-v-caa248ba"]]),FM=["onClick"],NM=ae({__name:"OptionsList",props:{options:{},open:{type:Boolean},direction:{default:"down"}},emits:["select"],setup(e,{emit:t}){const n=t;return(s,r)=>(F(),J("div",{class:Pe(["options-list",[{open:s.open},s.direction]])},[(F(!0),J(De,null,Rt(s.options,(o,i)=>(F(),J("div",{key:i,class:"option-wrapper",onClick:Ac(a=>n("select",o),["stop"])},[Ze(s.$slots,"option",{option:o,idx:i},()=>[we(Z(o),1)],!0)],8,FM))),128))],2))}}),BM=pe(NM,[["__scopeId","data-v-f323f40e"]]),DM={class:"selected"},UM={class:"option-wrapper"},VM={key:0,class:"label"},jM={class:"chevrons"},HM=ae({__name:"Select",props:{options:{},selected:{},label:{},chevrons:{type:Boolean,default:!0},direction:{default:"down"}},emits:["select"],setup(e,{emit:t}){const n=t,s=le(!1);function r(o){s.value=!1,n("select",o)}return(o,i)=>{const a=BM,c=tR;return F(),J("div",{tabindex:"0",class:Pe(["select",[{open:v(s),chevrons:o.chevrons},o.direction]]),onBlur:i[0]||(i[0]=u=>s.value=!1),onClick:i[1]||(i[1]=Ac(u=>s.value=!v(s),["stop"]))},[T("div",DM,[T("div",UM,[Ze(o.$slots,"option",{option:o.selected,isSelected:!0},()=>[we(Z(o.selected),1)],!0)]),o.label?(F(),J("div",VM,Z(o.label),1)):ye("",!0)]),$(a,{direction:o.direction,options:o.options,open:v(s),onSelect:r},{option:Y(({option:u})=>[Ze(o.$slots,"option",{option:u,isSelected:!1},()=>[we(Z(u),1)],!0)]),_:3},8,["direction","options","open"]),T("div",jM,[$(c)])],34)}}}),ca=pe(HM,[["__scopeId","data-v-9b7ef414"]]),zM=["en","zh","fr"],qM={class:"label"},WM="locale",Bh=ae({__name:"SelectLanguage",props:{locales:{default:()=>zM},direction:{default:"up"}},setup(e){const t=jI(WM,"en"),{locale:n}=Me({useScope:"global"});Gn(()=>{s(t.value)});function s(o){t.value=o,n.value=t.value}function r(o){switch(o){case"en":return"English";case"fr":return"Français";case"zh":return"中文"}}return(o,i)=>{const a=ca;return F(),fe(a,{direction:o.direction,options:o.locales.map(c=>c),selected:v(t),onSelect:s},{option:Y(({option:c})=>[T("div",qM,Z(r(c)),1)]),_:1},8,["direction","options","selected"])}}});function Kb(e){return Array.isArray(e.children)}function Qb(e){return typeof e.to=="string"}const GM={class:"nav-link-container"},XM={class:"nav-link-container"},KM=ae({__name:"MenuItem",props:{item:{}},emits:["navigated"],setup(e,{emit:t}){const n=t,s=Ho(),r=le(!1),o=M(()=>Qb(e.item)?[e.item]:Kb(e.item)?[e.item,...r.value?e.item.children:[]]:[]),i=()=>{Kb(e.item)&&e.item.children.filter(u=>Mo(u.to,s)).length>0&&(r.value=!0)};Ce(()=>e.item,()=>{i()},{immediate:!0}),Ce(()=>s.fullPath,()=>{i()},{immediate:!0});const a=()=>{r.value=!r.value};return(c,u)=>{const l=Ha("router-link");return F(!0),J(De,null,Rt(v(o),d=>(F(),J("li",{key:d.label},[v(Qb)(d)?(F(),fe(l,{key:0,class:Pe(["nav-link leaf",{"router-link-active":v(Mo)(d.to,v(s))}]),to:d.to,onClick:u[0]||(u[0]=f=>n("navigated"))},{default:Y(()=>[T("div",GM,[d.icon?(F(),fe(Ou(d.icon),{key:0})):ye("",!0),we(" "+Z(d.label),1)])]),_:2},1032,["to","class"])):d?(F(),J("a",{key:1,class:"nav-link node",onClick:a},[T("div",XM,[d.icon?(F(),fe(Ou(d.icon),{key:0})):ye("",!0),we(" "+Z(d.label),1)])])):ye("",!0)]))),128)}}}),a6=pe(KM,[["__scopeId","data-v-6741c115"]]),QM={class:"menu-mobile"},ZM={class:"navigation"},YM=ae({__name:"MenuMobile",props:{open:{type:Boolean,default:!1}},emits:["closed","navigated"],setup(e,{emit:t}){const n=t,s=Lc(),r=Ho(),o=aa(),i=le("Curve"),a=M(()=>{var f;const d=(f=s.pages.find(p=>p.title===i.value))==null?void 0:f.titleRoute;return typeof d=="string"?d:Array.isArray(d)?d[0]:null}),c=M(()=>{var d;return((d=s.pages.find(f=>f.title===i.value))==null?void 0:d.items)??[]}),u=M(()=>s.pages.filter(d=>d.visible).map(d=>d.title)),l=async d=>{if(i.value=d,c.value.length===0){const f=a.value;f&&(await o.push(f),n("navigated"))}};return Ce(()=>e.open,()=>{var d;i.value=((d=s.pages.find(f=>Mo(f.titleRoute,r)))==null?void 0:d.title)??"Curve"}),(d,f)=>{const p=ca,m=Bh;return F(),J("div",QM,[T("div",{class:Pe(["overlay",{open:d.open,closed:!d.open}]),onClick:f[0]||(f[0]=h=>n("closed"))},null,2),T("div",{class:Pe(["menu",{open:d.open,closed:!d.open}])},[$(p,{options:v(u),selected:v(i),onSelect:l},null,8,["options","selected"]),T("nav",ZM,[(F(!0),J(De,null,Rt(v(c),h=>(F(),J("ul",{key:h.label},[$(a6,{item:h,onNavigated:f[1]||(f[1]=y=>n("navigated"))},null,8,["item"])]))),128))]),$(m,{class:"language",direction:"up"})],2)])}}}),JM=pe(YM,[["__scopeId","data-v-6beffd8a"]]),eO={class:"header-mobile"},tO={class:"wallet"},nO=ae({__name:"HeaderMobile",setup(e){const t=le(!1),n=()=>{t.value=!t.value,document.documentElement.style.overflow=t.value?"hidden":""},s=()=>{t.value=!1,document.documentElement.style.overflow=""};return(r,o)=>{const i=kh,a=iR;return F(),J("header",null,[T("div",eO,[o[0]||(o[0]=T("div",{class:"title"},[T("img",{src:D_})],-1)),T("div",tO,[$(Oh,{class:"wallet"}),$(i)]),$(a,{class:Pe(["hamburger",{"is-active":v(t),open:v(t),closed:!v(t)}]),onClick:n},null,8,["class"])]),$(JM,{open:v(t),onClosed:s,onNavigated:s},null,8,["open"])])}}}),sO=pe(nO,[["__scopeId","data-v-833c3ced"]]),rO=ae({__name:"Header",setup(e){const t=Ho(),n=M(()=>t.name!=="curvemonitor");return(s,r)=>(F(),J("div",{class:Pe(["headers",{hasHeader:v(n)}])},[$(LM,{class:"desktop"}),$(sO,{class:"mobile"})],2))}}),oO=pe(rO,[["__scopeId","data-v-ee42ba76"]]),iO={class:"nav-link",href:"https://docs.llama.airforce/",target:"_blank"},aO={class:"nav-link-container icon"},cO={class:"nav-link",href:"https://medium.com/@llamaairforce",target:"_blank"},uO={class:"nav-link-container icon"},lO={class:"nav-link",href:"https://twitter.com/0xAlunara",target:"_blank"},dO={class:"nav-link-container icon"},fO={class:"nav-link-container icon"},pO=ae({__name:"Footer",setup(e){const t=Lc(),n=Ho(),s=M(()=>t.pages.find(i=>Mo(i.titleRoute,n))),r=M(()=>{var i;return((i=s.value)==null?void 0:i.items)??[]}),o=M(()=>{var i;return!(r.value.length>0||(i=s.value)!=null&&i.forceShowMenu)});return(i,a)=>{const c=Bh,u=N_,l=oR,d=cR,f=nR,p=Ha("router-link");return F(),J("footer",{class:Pe({"no-language":!v(o)})},[v(o)?(F(),fe(c,{key:0})):ye("",!0),T("nav",null,[T("ul",null,[T("li",null,[T("a",iO,[T("div",aO,[$(u)])])]),T("li",null,[T("a",cO,[T("div",uO,[$(l)])])]),a[0]||(a[0]=T("li",null,[T("a",{class:"nav-link",href:"https://discord.gg/E3KHXkvzPJ",target:"_blank"},[T("div",{class:"nav-link-container icon"},[T("div",{class:"discord"})])])],-1)),T("li",null,[T("a",lO,[T("div",dO,[$(d)])])]),T("li",null,[$(p,{to:"/code",class:"nav-link"},{default:Y(()=>[T("div",fO,[$(f)])]),_:1})])])])],2)}}}),mO=pe(pO,[["__scopeId","data-v-42e28fab"]]),hO={class:"sticky-wrapper"},yO={key:0,class:"title"},bO=["src"],gO={class:"navigation"},vO={class:"bottom"},c6=ae({__name:"MenuDesktop",emits:["navigated"],setup(e,{emit:t}){const{t:n}=Me(),s=t,r=Lc(),o=Ho(),i=M(()=>r.pages.find(l=>Mo(l.titleRoute,o))),a=M(()=>{var l;return((l=i.value)==null?void 0:l.menuHeader)??""}),c=M(()=>{var l;return((l=i.value)==null?void 0:l.items)??[]}),u=M(()=>{var l;return c.value.length>0||!!((l=i.value)!=null&&l.forceShowMenu)});return(l,d)=>{const f=kh,p=Bh;return F(),J("div",{class:Pe(["menu-desktop",{hasMenu:v(u)}])},[T("div",hO,[v(u)?(F(),J("div",yO,[T("img",{src:v(a)},null,8,bO)])):ye("",!0),T("nav",gO,[(F(!0),J(De,null,Rt(v(c),m=>(F(),J("ul",{key:m.label},[$(a6,{item:m,onNavigated:d[0]||(d[0]=h=>s("navigated"))},null,8,["item"])]))),128))]),T("div",vO,[$(f),$(p),v(u)?(F(),fe(Oh,{key:0,"label-please-connect":v(n)("please-connect")},null,8,["label-please-connect"])):ye("",!0)])])],2)}}});function Zb(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"please-connect":{t:0,b:{t:2,i:[{t:3}],s:"Connect your wallet to see your personal earnings in each round"}}}})}typeof Zb=="function"&&Zb(c6);const wO=pe(c6,[["__scopeId","data-v-74189856"]]),_O={class:"announcements"},xO=["innerHTML"],CO={href:"https://medium.com/@llamaairforce/discord-7a6c25a2b454",target:"_blank"},Jl=ae({__name:"Announcement",setup(e){const{t}=Me();return(n,s)=>{const r=He;return F(),fe(r,{class:"announcement-card border-flash"},{default:Y(()=>[T("div",_O,[T("h1",{innerHTML:v(t)("announcement-discord")},null,8,xO),T("span",null,[T("a",CO,Z(v(t)("link-discord")),1)])])]),_:1})}}});function Yb(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"announcement-discord":{t:0,b:{t:2,i:[{t:3}],s:"Join our official Discord server for emotional and tech support!"}},"link-discord":{t:0,b:{t:2,i:[{t:3}],s:"You can read our announcement here."}}}})}function Jb(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{"announcement-discord":{t:0,b:{t:2,i:[{t:3}],s:"加入我们的官方 Discord 服务器，获取情感和技术支持！"}},"link-discord":{t:0,b:{t:2,i:[{t:3}],s:"您可在此阅读我们的公告。"}}}})}function eg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{"announcement-discord":{t:0,b:{t:2,i:[{t:3}],s:"Rejoignez notre serveur Discord officiel pour un soutien émotionnel et technique !"}},"link-discord":{t:0,b:{t:2,i:[{t:3}],s:"Vous pouvez lire notre annonce ici."}}}})}typeof Yb=="function"&&Yb(Jl);typeof Jb=="function"&&Jb(Jl);typeof eg=="function"&&eg(Jl);const AO=pe(Jl,[["__scopeId","data-v-5447dbdd"]]),u6=Symbol();function TO(e){Sa(u6,e)}function EO(){const e=Nt(u6);if(!e)throw new Error("Theme not provided");return e}const SO={class:"root"},PO={class:"main"},kO={class:"content"},IO=ae({__name:"App",setup(e){window.document.documentElement.setAttribute("data-theme","dark");const t=M(()=>({colors:ks.value,colorsArray:[ks.value.blue,ks.value.yellow,ks.value.green,ks.value.red,ks.value.purple]}));return TO(t),(n,s)=>{const r=Ha("notifications"),o=Ha("router-view");return F(),J("div",SO,[$(r,{width:600,duration:-1}),$(v(CI)),$(oO,{class:"header"}),$(wO,{class:"menu"}),T("main",PO,[T("div",kO,[$(AO),$(o,null,{default:Y(({Component:i})=>[$(IC,{name:"fade",mode:"out-in"},{default:Y(()=>[(F(),fe(Ou(i)))]),_:2},1024)]),_:1})])]),$(mO,{class:"footer"})])}}}),RO=pe(IO,[["__scopeId","data-v-ab9cfe8c"]]),l6="/assets/pirex-DDub80N9.webp",d6="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGkAAAAgCAYAAAAR1VaeAAAABmJLR0QA/wD/AP+gvaeTAAAE70lEQVRoge2aa4hVVRTHf+tmo05gPnqOzZBpgdlDAlGThEDNoMToIZQTRBED05eCXhQE6gcN+lAhESI9nBCJHgYVZI5mBdmTiF5TpJY6afmcnMnG8d+HfQfv3XfvM2fGe+cww/3BhZn12uuedc7eZ699jWGGpDnAUuBC4BdgtZntzDSpKqeQdLekkyrmmKSrss6tSh5JuxXmjaxzOx1yWSdQLiSNBiZG1JcNZi7lZtgUycy6gF0R9Q+DmUuVBCTdLumEN9UdkTQ169xOB8s6gXIjaTpwJ1AHtAFrzKw926yqVKlSpUoKTNIlAfkuM+uJOUmqB870xHvM7LhnNw4Y59n9bWZHC2yuAGYBDbg1ci/QamY/J4w/Ergopvc4aWY7UtoiaSIwF6gHxgOdwD7gS+AbMzuZMs7FFL89qzAPSTXADcAU4HygA/ge2GxmHX6wEOf2kcCPAZ9ZAbtlAbumvG6KpM2R8SXpfUkNkfFnJ/j5dIRiBGIulrS9j1j7JD0paUyKeIc83+MFuiZJ7ZExDkt6RJIVBgtR0SJJmi5pf/L1kCTtkbuz/bhlK5KkWkkt/YgnSW2SrhxIkSStSjnG872xstjM5oC1QOKNkKcOeKFSicjdrS8Bd/XT9VJgi6TJ/RxvLvBwSvMHJM2HbIr0OHBN/u8e3Bp0IMH+Jkl+W6cbOBj59Idm4I6A/D9gC66AbwF/BWwmAK/2Y6wRwHpO7U07gd+B41EPeBDIZLqTpB5JKySdU2A7VdLWiH1z2iuRj11IcLqTNErS3sBYn8st+r7tykhuN0bi+9NdL79KWijpjLxdjaRGSf8EbLsk1WRVpIcicc+WW5x9XkzKx4uRtkgLAuMckHReQuwNAZ9XIrahIu2XVBexvz9yraZlMd3tAZ4LKczsCPB2QDWhAnlcH5C1mNn+BJ9nUsaJ8ayZ7Y3oWoDQ6/2ELIq0zcxOJOh/C8hGVyCP+oDssz58vsKtV4XUKT91pWBzTGFmncCfAVXtiJTBy0nSnQpu4zgYfAjs9mRfJzmYWY+kFcBZnqoG6EoxZprvXjIdZlGkaCcjjwYjCTN7eYB+y09j2L66FUH9sDn0G84M9Eka8udQkq4DLvDE28wscbqVtAgY6Ynf8fuW5SRWpPGEN3C9+E3ToUgzsMST3Qq82YffeqC24H8Bo8qYVwk5St9WwHWkg8i1QqJ7iSFE6Im5OslBrvNR64kPmlnoGpaNHHA4IF+U4PNEhXIZbD4NyBrljkFi3BeQfVKmfKLkgJ8C8iZJSwsFct3ip4F7Kp3UILEJ1z8rZBKwRpJ/VoakW+jtpRWzsQK5FTEC+Ah3yOXL10lahjuIGg3MAMbg5uAuSh/7IYWZHZK0mtKudCNwraTXgR2477wAmB8IsxN4rZJ5givGWuBR3IbMZ1L+U8g6YCzJU+JQYTmwEPDPhiYDj/Xh2w3cW+n1CCBnZruAp1La/4Er6LAgf0x9M/BdP107gUYzay1/VqXkAMxsJe7O+TfBdjsw28xC/aUhS/4mnQWswv3OIAkB7wIzzWxDpXPrpWhTKndUvQSYiXvNPopreG40s60FdnMo7TG1mlnR4Z2kacDlnl2bmX0bS0juLGeGJ243s1RvUZJuo/h7dZtZqLMe8h0LzMOt0Q247nsHbs/4BfCBmbWljLWY0h/rvGdmxxJ85lG6B/34f3eJYhRDmCCwAAAAAElFTkSuQmCC",Dh="/assets/votium-BRqnfLb6.png",$O={class:"dashboard"},MO={class:"topic"},OO={class:"description"},LO={class:"points"},FO={class:"topic"},NO={class:"description"},BO={class:"points"},DO={class:"topic"},UO={class:"description"},VO={class:"points"},ed=ae({__name:"Home.page",setup(e){const{t}=Me(),n=aa();function s(r){n.push(`/${r}`)}return(r,o)=>{const i=He;return F(),J("div",$O,[$(i,{style:{"grid-area":"pirex"},class:"topic-card",onClick:o[0]||(o[0]=a=>s("pirex"))},{default:Y(()=>[T("div",MO,[o[3]||(o[3]=T("img",{src:l6},null,-1)),T("div",OO,Z(v(t)("description-pirex")),1),T("div",LO,[T("ul",null,[T("li",null,Z(v(t)("point-pirex-1")),1),T("li",null,Z(v(t)("point-pirex-2")),1),T("li",null,Z(v(t)("point-pirex-3")),1),T("li",null,Z(v(t)("point-pirex-4")),1)])])])]),_:1}),$(i,{style:{"grid-area":"union"},class:"topic-card",onClick:o[1]||(o[1]=a=>s("union"))},{default:Y(()=>[T("div",FO,[o[4]||(o[4]=T("img",{src:d6},null,-1)),T("div",NO,Z(v(t)("description-union")),1),T("div",BO,[T("ul",null,[T("li",null,Z(v(t)("point-union-1")),1),T("li",null,Z(v(t)("point-union-2")),1),T("li",null,Z(v(t)("point-union-3")),1),T("li",null,Z(v(t)("point-union-4")),1)])])])]),_:1}),$(i,{style:{"grid-area":"votium"},class:"topic-card",onClick:o[2]||(o[2]=a=>s("incentives"))},{default:Y(()=>[T("div",DO,[o[5]||(o[5]=T("img",{src:Dh},null,-1)),T("div",UO,Z(v(t)("description-votium")),1),T("div",VO,[T("ul",null,[T("li",null,Z(v(t)("point-votium-1")),1),T("li",null,Z(v(t)("point-votium-2")),1),T("li",null,Z(v(t)("point-votium-3")),1),T("li",null,Z(v(t)("point-votium-4")),1)])])])]),_:1})])}}});function tg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"description-pirex":{t:0,b:{t:2,i:[{t:3}],s:"pxCVX is the cheapest liquid wrapper specifically designed for vlCVX. Known as a 'pure' liquid wrapper, each pxCVX token is directly backed by one vlCVX token, and there is no additional leverage risk."}},"point-pirex-1":{t:0,b:{t:2,i:[{t:3}],s:"Llama Airforce operates a pxCVX Pounder vault, which converts the underlying incentives into more pxCVX."}},"point-pirex-2":{t:0,b:{t:2,i:[{t:3}],s:"Pirex automatically re-locks CVX as vlCVX, unless a redemption is initiated."}},"point-pirex-3":{t:0,b:{t:2,i:[{t:3}],s:"Pirex maintains a pxCVX/CVX liquidity pool for instant swapping, usually at a discount."}},"point-pirex-4":{t:0,b:{t:2,i:[{t:3}],s:"pxCVX can be redeemed for CVX, as each pxCVX is backed 1:1 by CVX. There is a redemption fee that scales inversely with the unlock time."}},"description-union":{t:0,b:{t:2,i:[{t:3}],s:"By joining The Union you forward your bribe rewards to Llama Airforce, we collectively claim them, swap all of them for cvxCRV, put it in an auto-compounder and finally airdrop you the pounder shares."}},"point-union-1":{t:0,b:{t:2,i:[{t:3}],s:"The Union does not hold custody of your CVX, you remain in full control of your tokens."}},"point-union-2":{t:0,b:{t:2,i:[{t:3}],s:"Just like with Votium, the rewards roll over and you are not required to claim immediately."}},"point-union-3":{t:0,b:{t:2,i:[{t:3}],s:"The airdropped rewards will auto-compound even when unclaimed."}},"point-union-4":{t:0,b:{t:2,i:[{t:3}],s:"By also delegating to votium.eth you don't even have to worry about voting and maximizing your output."}},"description-votium":{t:0,b:{t:2,i:[{t:3}],s:"Votium is an incentives platform where vlCVX and veCRV holders earn rewards from buyers seeking deep liquidity. Delegating/Voting carries no risk to your funds, as you always retain custody of your vlCVX and veCRV."}},"point-votium-1":{t:0,b:{t:2,i:[{t:3}],s:"Allows protocols to buy CRV emissions through Convex's governance system."}},"point-votium-2":{t:0,b:{t:2,i:[{t:3}],s:"vlCVX holders are free to accept the incentive rewards to their likings."}},"point-votium-3":{t:0,b:{t:2,i:[{t:3}],s:"Rewards roll over to the next round and claiming immediately is not required."}},"point-votium-4":{t:0,b:{t:2,i:[{t:3}],s:"Delegating to votium.eth automates voting for the best $ / vlCVX possible."}}}})}function ng(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{"description-pirex":{t:0,b:{t:2,i:[{t:3}],s:'pxCVX 是专为 vlCVX 设计的最便宜的液体包装。被称为 "纯 "流动包装，每个 pxCVX 代币直接由一个 vlCVX 代币支持、 而且没有额外的杠杆风险。'}},"point-pirex-1":{t:0,b:{t:2,i:[{t:3}],s:"Llama Airforce 运营着一个 pxCVX Pounder 金库，它能将基础奖励转换成更多的 pxCVX。"}},"point-pirex-2":{t:0,b:{t:2,i:[{t:3}],s:"除非启动赎回，否则 Pirex 会自动将 CVX 重新锁定为 vlCVX。"}},"point-pirex-3":{t:0,b:{t:2,i:[{t:3}],s:"Pirex 维护一个 pxCVX/CVX 流动性池，用于即时交换，通常有折扣。"}},"point-pirex-4":{t:0,b:{t:2,i:[{t:3}],s:"pxCVX 可以兑换 CVX，因为每个 pxCVX 都得到 CVX 1:1 的支持。赎回费与解锁时间成反比。"}},"description-union":{t:0,b:{t:2,i:[{t:3}],s:'加入 "联盟 "后，您将把贿赂奖励转交给 "喇嘛空军"、 我们将集体认领这些奖励，把它们全部换成 cvxCRV，并将其放入自动复合机中 并最终向您空投 pounder 股份。'}},"point-union-1":{t:0,b:{t:2,i:[{t:3}],s:"联盟不会保管您的 CVX，您仍可完全控制您的代币。"}},"point-union-2":{t:0,b:{t:2,i:[{t:3}],s:"与 Votium 一样，奖励可以滚动，您无需 立即领取。"}},"point-union-3":{t:0,b:{t:2,i:[{t:3}],s:"即使无人认领，空投的奖励也会自动累积。"}},"point-union-4":{t:0,b:{t:2,i:[{t:3}],s:"通过委托 votium.eth，您甚至不必担心 投票和最大化产出。"}},"description-votium":{t:0,b:{t:2,i:[{t:3}],s:"Votium 是一个奖励平台，vlCVX 和 veCRV 持有者可从寻求深度流动性的买家处获得奖励。委托/投票不会给您的资金带来任何风险，因为您始终保持对 vlCVX 和 veCRV 的保管。"}},"point-votium-1":{t:0,b:{t:2,i:[{t:3}],s:"允许协议通过 Convex 治理系统购买 CRV 排放量。系统。"}},"point-votium-2":{t:0,b:{t:2,i:[{t:3}],s:"vlCVX 持有者可根据自己的喜好自由接受奖励。"}},"point-votium-3":{t:0,b:{t:2,i:[{t:3}],s:"奖励滚入下一轮，无需立即领取。"}},"point-votium-4":{t:0,b:{t:2,i:[{t:3}],s:"委托 votium.eth 可自动投票选出最佳 $/vlCVX。"}}}})}function sg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{"description-pirex":{t:0,b:{t:2,i:[{t:3}],s:`Le pxCVX est l'enveloppe liquide la moins chère spécialement conçue pour le vlCVX. Connu sous le nom de "pure" liquid wrapper, chaque jeton pxCVX est directement soutenu par un jeton vlCVX, et il n'y a pas de risque d'effet de levier supplémentaire.`}},"point-pirex-1":{t:0,b:{t:2,i:[{t:3}],s:"Llama Airforce exploite un coffre-fort de pxCVX Pounder, qui convertit les incitations sous-jacentes en davantage de pxCVX."}},"point-pirex-2":{t:0,b:{t:2,i:[{t:3}],s:"Pirex reverrouille automatiquement CVX en tant que vlCVX, à moins qu'un rachat ne soit initié."}},"point-pirex-3":{t:0,b:{t:2,i:[{t:3}],s:"Pirex maintient un pool de liquidités pxCVX/CVX pour l'échange instantané, généralement avec une décote."}},"point-pirex-4":{t:0,b:{t:2,i:[{t:3}],s:"Les pxCVX peuvent être échangés contre des CVX, car chaque pxCVX est garanti à hauteur de 1:1 par des CVX. Il existe une commission de rachat qui est inversement proportionnelle à la durée de déblocage."}},"description-union":{t:0,b:{t:2,i:[{t:3}],s:"En rejoignant l'Union, vous transmettez vos pots-de-vin à Llama Airforce, nous les réclamons collectivement, les échangeons tous contre des cvxCRV, les plaçons dans un auto-compoundeur et vous les envoyons par avion. et enfin, nous vous larguons les parts de pounder."}},"point-union-1":{t:0,b:{t:2,i:[{t:3}],s:"L'Union n'a pas la garde de vos CVX, vous restez maître de vos jetons."}},"point-union-2":{t:0,b:{t:2,i:[{t:3}],s:"Comme pour Votium, les récompenses sont cumulables et vous n'êtes pas obligé de les réclamer immédiatement. de les réclamer immédiatement."}},"point-union-3":{t:0,b:{t:2,i:[{t:3}],s:"Les récompenses larguées par avion s'accumulent automatiquement, même si elles ne sont pas réclamées."}},"point-union-4":{t:0,b:{t:2,i:[{t:3}],s:"En déléguant également à votium.eth, vous n'avez même pas à vous soucier de voter et de maximiser votre production. de voter et de maximiser votre production."}},"description-votium":{t:0,b:{t:2,i:[{t:3}],s:"Votium est une plateforme d'incitation où les détenteurs de vlCVX et de veCRV sont récompensés par des acheteurs à la recherche de liquidités importantes. Déléguer/voter ne comporte aucun risque pour vos fonds, car vous conservez toujours la garde de vos vlCVX et veCRV."}},"point-votium-1":{t:0,b:{t:2,i:[{t:3}],s:"Votium est une plateforme d'incitation où les détenteurs de vlCVX et de veCRV sont récompensés par des acheteurs à la recherche de liquidités importantes. Déléguer/voter ne comporte aucun risque pour vos fonds, car vous conservez toujours la garde de vos vlCVX et veCRV."}},"point-votium-2":{t:0,b:{t:2,i:[{t:3}],s:"Les titulaires de vlCVX sont libres d'accepter les primes d'encouragement à leur guise."}},"point-votium-3":{t:0,b:{t:2,i:[{t:3}],s:"Les récompenses sont reportées au tour suivant et il n'est pas nécessaire de les réclamer immédiatement. n'est pas nécessaire."}},"point-votium-4":{t:0,b:{t:2,i:[{t:3}],s:"La délégation à votium.eth automatise le vote pour le meilleur $ / vlCVX possible."}}}})}typeof tg=="function"&&tg(ed);typeof ng=="function"&&ng(ed);typeof sg=="function"&&sg(ed);const jO=pe(ed,[["__scopeId","data-v-44020737"]]),HO="/assets/404-DGbqGNxT.png",zO={class:"not-found"},f6=ae({__name:"NotFound.page",setup(e){const{t}=Me();return(n,s)=>(F(),J("div",zO,[we(Z(v(t)("404"))+" ",1),s[0]||(s[0]=T("img",{src:HO},null,-1))]))}});function rg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{404:{t:0,b:{t:2,i:[{t:3}],s:"Where are you going, pilot? Page not found, please return home fren."}}}})}typeof rg=="function"&&rg(f6);const qO=pe(f6,[["__scopeId","data-v-9dd845aa"]]),WO={class:"collapsible-inside"},GO=ae({__name:"Collapsible",props:{expanded:{type:Boolean,default:!0}},setup(e){return(t,n)=>(F(),J("div",{class:Pe(["collapsible-outside",{expanded:t.expanded}])},[T("div",WO,[Ze(t.$slots,"default",{},void 0,!0)])],2))}}),Uh=pe(GO,[["__scopeId","data-v-b6bcb0c4"]]),XO={class:"row-details"},KO=ae({__name:"TableRow",props:{data:{},selected:{type:Boolean,default:!1},expanded:{type:Boolean,default:!1},expandSide:{default:"right"}},emits:["click"],setup(e,{emit:t}){const n=t,s=Am(),r=M(()=>{var a;const i=s["row-details"];if(i){const c=(a=i()[0])==null?void 0:a.children;if(c)return Array.isArray(c)&&c.length>0}return!1}),o=()=>{n("click",e.data)};return(i,a)=>{const c=Ih,u=Uh;return F(),J("div",{class:Pe(["row",{expanded:i.expanded}])},[T("div",{class:Pe(["row-data",{active:i.selected,expandable:v(r),"has-data":!!i.data}]),onClick:o},[i.data&&v(r)&&i.expandSide==="left"?(F(),fe(c,{key:0,class:"expander"})):ye("",!0),Ze(i.$slots,"row",{},void 0,!0),i.data&&v(r)&&i.expandSide!=="left"?(F(),fe(c,{key:1,class:"expander"})):ye("",!0)],2),i.data?(F(),fe(u,{key:0,expanded:i.expanded},{default:Y(()=>[T("div",XO,[Ze(i.$slots,"row-details",{},void 0,!0)])]),_:3},8,["expanded"])):ye("",!0)],2)}}}),QO=pe(KO,[["__scopeId","data-v-bb7df2bf"]]),ZO={class:"table"},YO=["onClick"],JO=ae({__name:"Table",props:{columns:{default:()=>[]},rows:{default:()=>[]},rowsMin:{default:null},selectedRow:{default:null},expanded:{default:()=>[]},expandSide:{default:"right"},sorting:{default:()=>({order:"asc"})}},emits:["selected","sortColumn"],setup(e,{emit:t}){const n=t,s=M(()=>{if(e.rowsMin===null)return[];const l=Math.max(0,e.rowsMin-e.rows.length);return new Array(l)}),r=M(()=>e.columns.map(l=>typeof l=="string"?{id:l,label:l}:l)),o=l=>{l&&n("selected",l)},i=l=>{const d=l+1;return!!(e.rows[l+1]&&e.rows.findIndex(m=>m===e.selectedRow)===d)},a=l=>e.sorting.column===l.id&&e.sorting.order==="asc",c=l=>e.sorting.column===l.id&&e.sorting.order==="desc",u=l=>{if(!l.sort)return;const d=l.id===e.sorting.column&&e.sorting.order==="asc"?"desc":"asc";n("sortColumn",l.id,d)};return(l,d)=>{const f=eR,p=QO;return F(),J("div",ZO,[l.columns.length>0?(F(),fe(p,{key:0,class:Pe({"selected-below":i(-1)})},{row:Y(()=>[(F(!0),J(De,null,Rt(v(r),m=>(F(),J("div",{key:m.id,class:Pe(["column-header",{sortable:m.sort,sorting:m.sort&&l.sorting.column===m.id,[m.align||""]:!!m.align}]),onClick:h=>u(m)},[T("span",null,Z(m.label),1),m.sort?(F(),fe(f,{key:0,class:Pe(["sorting-arrow",{asc:a(m),desc:c(m)}])},null,8,["class"])):ye("",!0)],10,YO))),128))]),_:1},8,["class"])):ye("",!0),(F(!0),J(De,null,Rt(l.rows,(m,h)=>(F(),fe(p,{key:m,data:m,class:Pe({"selected-below":i(h)}),selected:l.selectedRow===m,expanded:l.expanded.includes(m),"expand-side":l.expandSide,onClick:o},{row:Y(()=>[Ze(l.$slots,"row",{item:m},void 0,!0)]),"row-details":Y(()=>[Ze(l.$slots,"row-details",{item:m},void 0,!0)]),_:2},1032,["data","class","selected","expanded","expand-side"]))),128)),(F(!0),J(De,null,Rt(v(s),m=>(F(),fe(p,{key:m}))),128)),l.$slots["row-aggregation"]&&l.rows.length>0?(F(),fe(p,{key:1,class:"aggregation"},{row:Y(()=>[Ze(l.$slots,"row-aggregation",{},void 0,!0)]),_:3})):ye("",!0)])}}}),zo=pe(JO,[["__scopeId","data-v-8ac4ff20"]]),e9={class:"dashboard"},t9=["href"],n9=["href"],s9=["href"],p6=ae({__name:"Code.page",setup(e){const l=[{name:"union",contracts:[{contract:w4,description:"multisig",gnosis:!0},{contract:_4,description:"treasury",gnosis:!0},{contract:x4,description:"treasury-arbitrum",network:"arbitrum",gnosis:!0},{contract:C4,description:"treasury-base",network:"base",gnosis:!0},{contract:Ro.at(-1)??"",description:"union-zap"},{contract:Ro[0],description:"union-forward"}]},{name:"distributors",contracts:[{contract:zl,description:"distributor-ucrv"},{contract:ql,description:"distributor-ufxs"},{contract:Wl,description:"distributor-ucvx"},{contract:Gl,description:"distributor-uprisma"}]},{name:"uCVX",contracts:[{contract:ys,description:"vault"},{contract:k4,description:"strategy"},{contract:cc,description:"zaps"},{contract:Bp,description:"zaps-claim"},{contract:L4,description:"Pirex Claims Distributor Zap"},{contract:E4,description:"Pirex Multisig",gnosis:!0}]},{name:"uCRV",contracts:[{contract:zr,description:"vault"},{contract:L_,description:"strategy"},{contract:N4,description:"zap-harvester"},{contract:Op,description:"zaps"},{contract:Lp,description:"zaps-claim"}]},{name:"uFXS",contracts:[{contract:Ks,description:"vault"},{contract:P4,description:"strategy"},{contract:B4,description:"zap-harvester"},{contract:Fp,description:"zaps"},{contract:Np,description:"zaps-claim"}]},{name:"uPRISMA",contracts:[{contract:qr,description:"vault"},{contract:I4,description:"strategy"},{contract:U4,description:"zap-harvester"},{contract:F4,description:"zaps"},{contract:Dp,description:"zaps-claim"}]},{name:"uBAL",contracts:[{contract:$o,description:"vault"},{contract:R4,description:"strategy"},{contract:$4,description:"handler-aura"},{contract:M4,description:"handler-bbusd"},{contract:O4,description:"zaps"},{contract:D4,description:"zap-harvester"}]},{name:"registries",contracts:[{contract:Mp,description:"registry-union"},{contract:zi,description:"registry-votium"},{contract:$p,description:"registry-snapshot"}]},{name:"Pirex",contracts:[{contract:cn,description:"Pirex"},{contract:js,description:"pxCVX"}]}],d=[{name:"Llama Airforce",url:"https://github.com/Llama-Airforce/Llama-Airforce",description:"repo-laf"},{name:"Union Contracts",url:"https://github.com/convex-community/union_contracts",description:"repo-union"},{name:"Subgraphs",url:"https://github.com/convex-community/convex-subgraph",description:"repo-graphs"}],f=[{name:"haowi.eth",url:"https://twitter.com/HaowiWang",description:"Translation: Chinese / 中文"}],p=h=>{switch(h.network){case"arbitrum":return h.gnosis?`https://app.safe.global/home?safe=arb1:${h.contract}`:`https://arbiscan.io/address/${h.contract}`;case"base":return h.gnosis?`https://app.safe.global/home?safe=base:${h.contract}`:`https://basescan.org/address/${h.contract}`;case"ethereum":default:return h.gnosis?`https://app.safe.global/home?safe=eth:${h.contract}`:`https://etherscan.io/address/${h.contract}`}},{t:m}=Me();return(h,y)=>{const b=zo,g=He;return F(),J("div",e9,[$(g,{class:"repositories-card",title:v(m)("repositories")},{default:Y(()=>[$(b,{class:"repositories-table",rows:d,columns:[v(m)("repository"),v(m)("description")]},{row:Y(({item:w})=>[T("div",null,[T("a",{target:"_blank",href:w.url},Z(w.name),9,t9)]),T("div",null,Z(v(m)(w.description)),1)]),_:1},8,["columns"])]),_:1},8,["title"]),$(g,{class:"other-card",title:v(m)("other")},{default:Y(()=>[$(b,{class:"other-table",rows:f,columns:[v(m)("other"),v(m)("description")]},{row:Y(({item:w})=>[T("div",null,[T("a",{target:"_blank",href:w.url},Z(w.name),9,n9)]),T("div",null,Z(v(m)(w.description)),1)]),_:1},8,["columns"])]),_:1},8,["title"]),(F(),J(De,null,Rt(l,w=>$(g,{key:w.name,class:"contracts-card",title:v(m)(w.name)},{default:Y(()=>[$(b,{class:"contracts-table",rows:w.contracts,columns:[v(m)("contract"),v(m)("description")]},{row:Y(({item:_})=>[T("div",null,[T("a",{class:"font-mono",target:"_blank",href:p(_)},Z(_.contract),9,s9)]),T("div",null,Z(v(m)(_.description)),1)]),_:2},1032,["rows","columns"])]),_:2},1032,["title"])),64))])}}});function og(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{repositories:{t:0,b:{t:2,i:[{t:3}],s:"Repositories"}},repository:{t:0,b:{t:2,i:[{t:3}],s:"Repository"}},description:{t:0,b:{t:2,i:[{t:3}],s:"Description"}},contract:{t:0,b:{t:2,i:[{t:3}],s:"Contract"}},other:{t:0,b:{t:2,i:[{t:3}],s:"Other"}},"repo-laf":{t:0,b:{t:2,i:[{t:3}],s:"This website's front-end, excluding the Union"}},"repo-union":{t:0,b:{t:2,i:[{t:3}],s:"All deployed Union contracts and tests"}},"repo-graphs":{t:0,b:{t:2,i:[{t:3}],s:"The Graph subgraphs related to Curve, Convex, Votium and more"}},union:{t:0,b:{t:2,i:[{t:3}],s:"Union"}},distributors:{t:0,b:{t:2,i:[{t:3}],s:"Distributors"}},registries:{t:0,b:{t:2,i:[{t:3}],s:"Registries"}},multisig:{t:0,b:{t:2,i:[{t:3}],s:"Multisig"}},treasury:{t:0,b:{t:2,i:[{t:3}],s:"Treasury"}},"treasury-arbitrum":{t:0,b:{t:2,i:[{t:3}],s:"Treasury Arbitrum"}},"treasury-base":{t:0,b:{t:2,i:[{t:3}],s:"Treasury Base"}},"union-zap":{t:0,b:{t:2,i:[{t:3}],s:"Zap V9"}},"union-forward":{t:0,b:{t:2,i:[{t:3}],s:"Forwarding Address"}},"distributor-ucrv":{t:0,b:{t:2,i:[{t:3}],s:"Merkle Distributor - uCRV"}},"distributor-ufxs":{t:0,b:{t:2,i:[{t:3}],s:"Merkle Distributor - uFXS"}},"distributor-ucvx":{t:0,b:{t:2,i:[{t:3}],s:"Merkle Distributor - uCVX"}},"distributor-uprisma":{t:0,b:{t:2,i:[{t:3}],s:"Merkle Distributor - uPRISMA"}},vault:{t:0,b:{t:2,i:[{t:3}],s:"Vault"}},strategy:{t:0,b:{t:2,i:[{t:3}],s:"Strategy"}},zaps:{t:0,b:{t:2,i:[{t:3}],s:"Zaps"}},"zaps-claim":{t:0,b:{t:2,i:[{t:3}],s:"Distributor Claim Zaps"}},"zap-harvester":{t:0,b:{t:2,i:[{t:3}],s:"Harvester"}},"handler-aura":{t:0,b:{t:2,i:[{t:3}],s:"Aura Handler"}},"handler-bbusd":{t:0,b:{t:2,i:[{t:3}],s:"BBUSD Handler"}},"registry-union":{t:0,b:{t:2,i:[{t:3}],s:"Union - Allocation Registry"}},"registry-votium":{t:0,b:{t:2,i:[{t:3}],s:"Votium - Registry"}},"registry-snapshot":{t:0,b:{t:2,i:[{t:3}],s:"Snapshot - Registry"}}}})}typeof og=="function"&&og(p6);const r9=pe(p6,[["__scopeId","data-v-be55acf9"]]),o9=ae({__name:"ClearCacheButton",setup(e){const t=()=>{window.localStorage.clear()};return(n,s)=>{const r=Mt;return F(),fe(r,{class:"button primary",onClick:t},{default:Y(()=>s[0]||(s[0]=[we(" Clear Cache ")])),_:1})}}}),i9=pe(o9,[["__scopeId","data-v-fd76e529"]]),a9={class:"dashboard"},c9=ae({__name:"Debug.page",setup(e){return(t,n)=>(F(),J("div",a9,[$(i9)]))}}),u9=pe(c9,[["__scopeId","data-v-ba75e447"]]),l9=[{path:"/",component:jO},{path:"/code",component:r9},{path:"/debug",component:u9},{path:"/:pathMatch(.*)*",name:"NotFound",component:qO}],d9=["votium","hh"];function m6(e){return d9.includes(e)}const f9=["cvx-crv","cvx-prisma","cvx-fxn","aura-bal"];function h6(e){return f9.includes(e)}function p9(e){switch(e){case"votium":return["cvx-crv","cvx-prisma","cvx-fxn"];case"hh":return["aura-bal"];default:return[]}}const gs=Lh("bribesStore",()=>{const e=le("votium"),t=le("cvx-crv"),n=M(()=>!e.value||!t.value?null:{platform:e.value,protocol:t.value});function s(r){const o=t.value;if(e.value){const i=p9(e.value);i.includes(r)?t.value=r:t.value===r?t.value=i[0]:(t.value=r,e.value=e.value==="hh"?"votium":"hh")}else t.value=r;return o===r}return{platform:e,protocol:t,product:n,setProtocol:s}}),m9="/assets/votium-DTG-AdiX.png",h9="/assets/redacted-r8ShDf4e.png",rr="/assets/crv-DgSNXO2J.svg",Oo="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20164%20164'%3e%3cdefs%3e%3cstyle%3e.cls-1{fill:none;}.cls-2{fill:%23fc306b;}.cls-3{fill:%234f28dd;}.cls-4{fill:%230bb875;}.cls-5{fill:%231a78d7;}.cls-6{fill:%23e91224;}.cls-7{fill:%23f86e30;}.cls-8{fill:%23827ff4;}.cls-9{fill:%2374ca38;}.cls-10{fill:%2353aef9;}.cls-11{fill:%23f78f31;}.cls-12{fill:%23feb92f;}.cls-13{fill:%23ffc866;}%3c/style%3e%3c/defs%3e%3ctitle%3eprisma-icon-colour%3c/title%3e%3cg%20id='Layer_2'%20data-name='Layer%202'%3e%3cg%20id='Layer_1-2'%20data-name='Layer%201'%3e%3cg%20id='prisma-icon-colour'%3e%3crect%20class='cls-1'%20width='164'%20height='164'/%3e%3cpolygon%20class='cls-2'%20points='81.993%2037.084%2082.007%2037.099%2081.993%2037.113%2081.993%2037.084'/%3e%3cpath%20class='cls-2'%20d='M92.4895,30.74306,82.00723,37.79921l-.01449-22.881c0-.50671-.39077-.7962-.70942-.56468a.97063.97063,0,0,1,1.63623.26069Z'/%3e%3cpath%20class='cls-3'%20d='M82.71665,149.46509a1.07926,1.07926,0,0,1-1.63587-.26069L59.34884,118.11954l22.65839,12.56074v18.22013C82.00723,149.39262,82.39817,149.68212,82.71665,149.46509Z'/%3e%3cpath%20class='cls-4'%20d='M81.99274,86.27042v27.41885L39.47017,88.38107a2.06156,2.06156,0,0,1-.91232-1.44783c0-.0578-.01449-.11577-.01449-.17374a1.87742,1.87742,0,0,1,.31866-1.11485L49.489,67.95221Z'/%3e%3cpath%20class='cls-5'%20d='M81.99274,112.56027v19.35695l-22.6439-13.79768L39.47017,89.14846a5.85849,5.85849,0,0,1-.91232-2.21522,2.06156,2.06156,0,0,0,.91232,1.44783Z'/%3e%3cpath%20class='cls-6'%20d='M82.00723,37.79921,71.51047,30.72857s9.72955-16.34605,9.77285-16.375c.31865-.23152.70942.058.70942.56468Z'/%3e%3cpolygon%20class='cls-7'%20points='82.007%2037.099%2081.993%2049.029%2081.993%2061.948%2061.043%2048.45%2061.028%2048.45%2071.51%2030.729%2081.993%2037.084%2082.007%2037.099'/%3e%3cpath%20class='cls-8'%20d='M104.65148,118.134,82.91955,149.2044a.25816.25816,0,0,1-.07246.10127.45313.45313,0,0,1-.13044.15942c-.31848.217-.70942-.07247-.70942-.56468V130.68028Z'/%3e%3cpath%20class='cls-9'%20d='M125.45661,86.7595c0,.058-.01449.11594-.01449.17374a2.0892,2.0892,0,0,1-.912,1.46232L82.00723,113.68927l-.01449-27.41885L114.51111,67.9667l10.627,17.67795A1.8761,1.8761,0,0,1,125.45661,86.7595Z'/%3e%3cpath%20class='cls-10'%20d='M125.44212,86.93324a5.85731,5.85731,0,0,1-.912,2.21522L104.65148,118.134,82.00723,131.93171v-19.621l42.52292-23.91512A2.0892,2.0892,0,0,0,125.44212,86.93324Z'/%3e%3cpath%20class='cls-11'%20d='M92.483,30.73659l10.48178,17.71483-20.972,13.49609.0057-24.83892Z'/%3e%3cpath%20class='cls-12'%20d='M82.00177,60.94718v26.219L49.48394,67.95482,61.03835,48.44734Z'/%3e%3cpath%20class='cls-13'%20d='M102.96185,48.45127l11.55442,19.50748L81.99844,87.17015v-26.219Z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",y9="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3c!--%20Generated%20by%20Pixelmator%20Pro%203.4.1%20--%3e%3csvg%20width='400'%20height='400'%20viewBox='0%200%20400%20400'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='f-logo-1'%3e%3cg%20id='Layer1'%3e%3cpath%20id='Path'%20fill='%23ffffff'%20stroke='none'%20d='M%20400%20200%20C%20400%20310.45697%20310.45694%20400%20200%20400%20C%2089.543045%20400%20-0%20310.45697%20-0%20200%20C%20-0%2089.54306%2089.543045%200%20200%200%20C%20310.45694%200%20400%2089.54306%20400%20200%20Z'/%3e%3clinearGradient%20id='linearGradient1'%20x1='35.363636'%20y1='145.090909'%20x2='339.090909'%20y2='145.090909'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20offset='1e-05'%20stop-color='%231b75ba'%20stop-opacity='1'/%3e%3cstop%20offset='0.17'%20stop-color='%232967b2'%20stop-opacity='1'/%3e%3cstop%20offset='0.72'%20stop-color='%23543d99'%20stop-opacity='1'/%3e%3cstop%20offset='1'%20stop-color='%23652d8f'%20stop-opacity='1'/%3e%3c/linearGradient%3e%3cpath%20id='path1'%20fill='url(%23linearGradient1)'%20stroke='none'%20d='M%20338.636353%2095.909088%20C%20304.818176%2051.909088%20260.727264%2025.909088%20191.72728%2025.909088%20C%20109.909096%2025.909088%2035.363636%20101.181824%2035.363636%20181.545456%20C%2035.363636%20237.454559%2067.090912%20264.272705%20102.090904%20264.272705%20C%20129.893814%20265.148621%20155.60939%20249.583939%20167.72728%20224.545456%20C%20168.16951%20223.707687%20168.145325%20222.700424%20167.663376%20221.884842%20C%20167.181442%20221.06929%20166.310806%20220.56221%20165.363647%20220.545456%20L%20118.181816%20220.545456%20C%20116.309525%20220.496155%20114.817535%20218.963852%20114.818184%20217.090897%20L%20114.818184%20182.909103%20C%20114.817535%20181.036148%20116.309525%20179.503845%20118.181816%20179.454544%20L%20181.818176%20179.454544%20C%20184.390915%20179.445633%20186.712677%20177.909714%20187.727264%20175.545456%20C%20215.545441%20111.909088%20264.818176%2098.090912%20293.090912%2095.818176%20C%20307.607056%2094.651642%20322.21637%2095.817932%20336.363647%2099.272705%20C%20337.266144%2099.603973%20338.278259%2099.277039%20338.816498%2098.480438%20C%20339.354736%2097.683868%20339.280426%2096.622894%20338.636353%2095.909088%20Z'/%3e%3c/g%3e%3c/g%3e%3cg%20id='x-logo-2'%3e%3cg%20id='g1'%3e%3clinearGradient%20id='linearGradient2'%20x1='73.038164'%20y1='275.106532'%20x2='392.394819'%20y2='275.106532'%20gradientUnits='userSpaceOnUse'%20gradientTransform='matrix(0.836072%20-0.548619%200.548619%200.836072%20-112.750057%20172.734729)'%3e%3cstop%20offset='1e-05'%20stop-color='%23d81c5c'%20stop-opacity='1'/%3e%3cstop%20offset='1'%20stop-color='%23ed4036'%20stop-opacity='1'/%3e%3c/linearGradient%3e%3cpath%20id='path2'%20fill='url(%23linearGradient2)'%20stroke='none'%20d='M%2061.741951%20305.684631%20C%2096.066559%20349.861969%20140.634644%20375.089233%20209.336365%20374.919891%20C%20291.034424%20374.226563%20365.494629%20298.464233%20365.024689%20217.953613%20C%20364.633789%20161.959198%20332.889709%20135.098236%20297.569916%20135.485229%20C%20269.739258%20134.841766%20244.126038%20150.604095%20232.159195%20175.738815%20C%20231.736221%20176.59549%20231.798355%20177.612076%20232.322495%20178.410858%20C%20232.846649%20179.209641%20233.754501%20179.671265%20234.708755%20179.624222%20L%20281.679535%20179.373764%20C%20283.570953%20179.364639%20285.114685%20180.884659%20285.134888%20182.775986%20L%20285.400482%20217.063736%20C%20285.409546%20217.975494%20285.046143%20218.851501%20284.394287%20219.489075%20C%20283.742432%20220.126663%20282.858612%20220.470612%20281.947266%20220.441345%20L%20218.425095%20220.880478%20C%20215.865585%20220.898087%20213.554199%20222.41478%20212.519287%20224.755783%20C%20185.088669%20288.667664%20135.773926%20302.795807%20107.450043%20305.373413%20C%2092.939285%20306.603302%2078.325226%20305.49585%2064.165573%20302.093262%20C%2063.201771%20301.738312%2062.120163%20302.087341%2061.545639%20302.93869%20C%2060.971092%20303.790039%2061.052128%20304.923676%2061.741951%20305.684631%20Z'/%3e%3c/g%3e%3c/g%3e%3c/svg%3e",b9="/assets/aura-BkeVNIUE.png",g9={class:"system-selector"},v9={class:"option"},w9=["src"],_9={class:"label"},x9={class:"option"},C9=["src"],A9={class:"label"},Vh=ae({__name:"SelectSystem",emits:["select-platform","select-protocol"],setup(e,{emit:t}){const{t:n}=Me(),s=t,r=gs(),o=M(()=>[{platform:"votium",label:"Votium",logo:m9},{platform:"hh",label:"Hidden Hand",logo:h9}]),i=M(()=>o.value.find(d=>d.platform===r.platform)??o.value[0]),a=M(()=>c.value.find(d=>d.protocol===r.protocol)??c.value[0]),c=M(()=>[{protocol:"cvx-crv",label:"Curve",logo:rr},{protocol:"cvx-prisma",label:"Prisma",logo:Oo},{protocol:"cvx-fxn",label:"f(x) Protocol",logo:y9},{protocol:"aura-bal",label:"Aura",logo:b9}]),u=d=>{const{platform:f}=d;s("select-platform",f),l(c.value[0])},l=d=>{const{protocol:f}=d;s("select-protocol",f)};return(d,f)=>{const p=ca;return F(),J("div",g9,[$(p,{class:"platform",label:v(n)("platform"),options:v(o),selected:v(i),onSelect:u},{option:Y(({option:m})=>[T("div",v9,[T("img",{src:m.logo},null,8,w9),T("div",_9,Z(m.label),1)])]),_:1},8,["label","options","selected"]),$(p,{class:"protocol",label:v(n)("protocol"),options:v(c),selected:v(a),onSelect:l},{option:Y(({option:m})=>[T("div",x9,[T("img",{src:m.logo},null,8,C9),T("div",A9,Z(m.label),1)])]),_:1},8,["label","options","selected"])])}}});function ig(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{platform:{t:0,b:{t:2,i:[{t:3}],s:"Platform"}},protocol:{t:0,b:{t:2,i:[{t:3}],s:"Protocol"}}}})}function ag(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{platform:{t:0,b:{t:2,i:[{t:3}],s:"平台"}},protocol:{t:0,b:{t:2,i:[{t:3}],s:"协议"}}}})}typeof ig=="function"&&ig(Vh);typeof ag=="function"&&ag(Vh);const y6=pe(Vh,[["__scopeId","data-v-a6524725"]]),T9={class:"async-value"},E9={key:0,class:"symbol"},S9={class:"value"},P9={key:1,class:"unit"},k9={key:2,class:"symbol"},I9="|/-\\",R9=ae({__name:"AsyncValue",props:{value:{default:null},type:{default:null},precision:{type:[Number,Function],default:2},showUnit:{type:Boolean,default:!0},showSymbol:{type:Boolean,default:!0},showZero:{type:Boolean,default:!1}},setup(e){let t=0,n=0;const s=le("|"),r=M(()=>e.value?xo(e.value,typeof e.precision=="function"?e.precision(e.value):e.precision,e.type??""):e.value===0&&e.showZero?"0":e.value===null||e.value===void 0?s.value:"?"),o=M(()=>e.precision===1/0||!e.type?"":!e.value||!isFinite(e.value)?e.showUnit?Mr(0):"":Mr(e.value));return Ce(()=>e.value,i=>{if(clearInterval(n),t=0,i)return;const a=()=>{t=(t+1)%4,s.value=I9[t]};n=window.setInterval(a,250)},{immediate:!0}),(i,a)=>(F(),J("div",T9,[i.showSymbol&&i.type==="dollar"?(F(),J("span",E9," $ ")):ye("",!0),T("span",S9,Z(v(r)),1),i.showUnit?(F(),J("span",P9,Z(v(o)),1)):ye("",!0),i.showSymbol&&i.type==="percentage"?(F(),J("span",k9," % ")):ye("",!0)]))}}),Pt=pe(R9,[["__scopeId","data-v-fc324bcc"]]),$9={key:0,class:"value"},M9={key:1,class:"value"},O9=["innerHTML"],L9={key:0,class:"value"},F9={key:1,class:"value"},N9=["innerHTML"],B9={class:"labels"},D9={class:"label"},U9={class:"label-second"},V9=ae({__name:"KPI",props:{label:{default:""},labelSecond:{default:""},tooltip:{default:""},tooltipType:{default:"icon"},value:{},hasValue:{type:Boolean,default:!1}},setup(e){return(t,n)=>{const s=jo;return F(),J("div",{class:Pe(["kpi",{disabled:!t.hasValue}])},[T("div",{class:Pe(["value-container",{underline:t.tooltip&&t.tooltipType==="underline"}])},[Ze(t.$slots,"default",{},()=>[t.tooltip&&t.tooltipType==="underline"?(F(),fe(s,{key:0},{trigger:Y(()=>[t.hasValue?(F(),J("span",$9,Z(t.value),1)):(F(),J("span",M9," ? "))]),default:Y(()=>[Ze(t.$slots,"tooltip",{},()=>[T("span",{innerHTML:t.tooltip},null,8,O9)],!0)]),_:3})):(F(),J(De,{key:1},[t.hasValue?(F(),J("span",L9,Z(t.value),1)):(F(),J("span",F9," ? "))],64))],!0),t.tooltip&&t.tooltipType==="icon"?(F(),fe(s,{key:0},{default:Y(()=>[T("span",{innerHTML:t.tooltip},null,8,N9)]),_:1})):ye("",!0)],2),T("div",B9,[Ze(t.$slots,"label",{},()=>[T("div",D9,Z(t.label),1)],!0),Ze(t.$slots,"label-second",{},()=>[T("div",U9,Z(t.labelSecond),1)],!0)])],2)}}}),td=pe(V9,[["__scopeId","data-v-c4934141"]]);function b6(e){return e.bribes.reduce((t,n)=>t+n.amountDollars,0)}function j9(e){return Object.entries(e.bribed).reduce((t,[,n])=>t+n,0)}function H9(e){return b6(e)/j9(e)}function Yu(e){return new Date(e.end*1e3)}function Oa(e){return Yu(e).toLocaleDateString()}function g6(e,t){switch(e.protocol){case"cvx-crv":case"cvx-prisma":case"cvx-fxn":return`https://vote.convexfinance.com/#/proposal/${t}`;case"aura-bal":return`https://snapshot.org/#/aurafinance.eth/${t?`proposal/${t}`:""}`}}function v6(e){return Object.entries(e.bribed).map(([t,n])=>{const s=e.bribes.filter(u=>u.pool===t),r=s.map(u=>u.amount),o=s.map(u=>u.amountDollars),i=s.reduce((u,l)=>u+l.amountDollars,0),a=s.map(u=>u.maxPerVote??0),c=i/n;return{pool:t,vlAsset:n,amount:r,amountDollars:o,amountDollarsTotal:i,maxPerVote:a,dollarPerVlAsset:c}}).filter(t=>isFinite(t.dollarPerVlAsset)&&t.amountDollarsTotal>100&&t.dollarPerVlAsset>0&&t.dollarPerVlAsset<100)}function z9(e,t){const n=v6(e);return Object.entries(t).map(([s,r])=>{const o=n.find(l=>l.pool===s);if(!o)return;const a=o.amount.zip(o.amountDollars,o.maxPerVote).map(([l,d,f])=>{const p=d/l;let m=l/o.vlAsset;return f&&(m=Math.min(f,m)),m*r.vlAsset*p}).reduce((l,d)=>l+d,0),c=t[o.pool].vlAsset,u=a/c;return{pool:o.pool,dollarPerVlAsset:u,amountDollars:a,percentage:r.percentage}}).filter(s=>s!==void 0)}function q9(e,t){return e.filter(Vp).filter(n=>t.includes(n.delegate)).orderBy(n=>n.space,"desc").uniqWith((n,s)=>n.delegator===s.delegator)}function W9(e,t,n,s,r){const o={};let i=s.find(a=>a.voter===t);if(!i&&n&&(i=s.find(a=>a.voter===n)),i){const a=r[0][t]??0,c=Object.entries(i.choice).reduce((u,[,l])=>u+l,0);e.id==="QmaS9vd1vJKQNBYX4KWQ3nppsTT3QSL3nkz5ZYSwEJk6hZ"&&(i.choice[52]=i.choice[52]||0+i.choice[41]||0,i.choice[41]=0,i.choice[52]===0&&delete i.choice[52]);for(const[u,l]of Object.entries(i.choice)){const d=e.choices[parseInt(u,10)-1],f=l/c,p=a*f;o[d]={vlAsset:p,percentage:f*100}}}return o}function Lo(e){switch(e){case"cvx-crv":case"cvx-prisma":case"cvx-fxn":return"vlCVX";case"aura-bal":return"vlAURA";default:return"vl???"}}const G9={class:"summary"},X9={class:"option"},K9=["href"],Q9={key:0},Z9={key:1},w6=ae({__name:"Summary",props:{rounds:{default:()=>[]},epoch:{}},emits:["select-round"],setup(e,{emit:t}){const{t:n}=Me(),s=t;let r;const{product:o}=sr(gs()),i=le(""),a=M(()=>e.rounds.orderBy(m=>m,"desc")),c=M(()=>e.epoch?g6(e.epoch,e.epoch.proposal):""),u=M(()=>e.epoch?H9(e.epoch):void 0),l=M(()=>e.epoch?b6(e.epoch):void 0),d=M(()=>e.epoch?Oa(e.epoch):""),f=M(()=>e.epoch?new Date().getTime()>Yu(e.epoch).getTime():!1);Ce(()=>e.epoch,m=>{clearInterval(r),m&&(r=setInterval(()=>{i.value=Rh(Yu(m))}))});const p=m=>{s("select-round",m)};return(m,h)=>{var _;const y=ca,b=td,g=Pt,w=B_;return F(),J("div",G9,[m.epoch?(F(),fe(y,{key:0,label:v(n)("round-number"),options:v(a),selected:m.epoch.round,onSelect:p},{option:Y(({option:A})=>[T("div",X9,Z(A),1)]),_:1},8,["label","options","selected"])):(F(),fe(b,{key:1})),$(b,{label:"$/"+v(Lo)((_=v(o))==null?void 0:_.protocol),"has-value":!!v(u)},{default:Y(()=>[$(g,{type:"dollar",value:v(u),precision:5},null,8,["value"])]),_:1},8,["label","has-value"]),$(b,{label:v(n)("deadline"),value:v(d),"has-value":!!v(d)},{"label-second":Y(()=>[T("a",{class:"vote-link",target:"_blank",href:v(c)},[v(f)?(F(),J("span",Q9,Z(v(n)("voting-ended")),1)):(F(),J("span",Z9,[$(w,{style:{"vertical-align":"top"}}),we(" "+Z(v(i)),1)]))],8,K9)]),_:1},8,["label","value","has-value"]),$(b,{label:"Total","has-value":!!v(l)},{default:Y(()=>[$(g,{type:"dollar",value:v(l),precision:2},null,8,["value"])]),_:1},8,["has-value"])])}}});function cg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"round-number":{t:0,b:{t:2,i:[{t:3}],s:"Round Number"}},deadline:{t:0,b:{t:2,i:[{t:3}],s:"Deadline"}},"voting-ended":{t:0,b:{t:2,i:[{t:3}],s:"Voting Ended"}}}})}typeof cg=="function"&&cg(w6);const Y9=pe(w6,[["__scopeId","data-v-a4ddc8f6"]]);function jh(e,t){const n=le(e),s=le("desc"),r=(i,a)=>{n.value=i,s.value=a},o=M(()=>({column:n.value,order:s.value}));return{sortColumn:n,sortOrder:s,sorting:o,onSort:r}}const J9={class:"bribe"},eL={class:"end"},tL={class:"end"},nL={class:"bribes"},sL={class:"end"},rL={class:"end"},_6=ae({__name:"TableBribed",props:{epoch:{}},setup(e){const{t}=Me(),{protocol:n}=sr(gs()),s=M(()=>[{id:"pool",label:t("pool"),sort:!0},{id:"vlasset",label:`$/${Lo(n.value)}`,sort:!0,align:"end"},{id:"total",label:t("total"),sort:!0,align:"end"}]),{sorting:r,onSort:o}=jh("total"),i=M(()=>e.epoch?v6(e.epoch).orderBy(f=>{switch(r.value.column){case"pool":return f.pool;case"vlasset":return f.dollarPerVlAsset;case"total":return f.amountDollars.reduce((p,m)=>p+m,0)}},r.value.order):[]),a=d=>d.pool,c=d=>d.amountDollars.reduce((f,p)=>f+p,0),u=d=>d.dollarPerVlAsset,l=d=>{var f;return(((f=e.epoch)==null?void 0:f.bribes)??[]).filter(p=>p.pool===d.pool).orderBy(p=>p.amountDollars,"desc")};return(d,f)=>{const p=Pt,m=jo,h=zo,y=He;return F(),fe(y,{title:v(t)("title")},{default:Y(()=>[$(h,{class:"bribed-table",rows:v(i),columns:v(s),sorting:v(r),onSortColumn:v(o)},{row:Y(({item:b})=>[$(m,null,{trigger:Y(()=>[T("div",J9,[T("div",null,Z(a(b)),1),T("div",eL,[$(p,{type:"dollar",value:u(b),precision:5},null,8,["value"])]),T("div",tL,[$(p,{type:"dollar",value:c(b),precision:2},null,8,["value"])])])]),default:Y(()=>[T("div",nL,[T("span",null,Z(a(b)),1),T("ul",null,[(F(!0),J(De,null,Rt(l(b),g=>(F(),J("li",{key:g.pool},[T("div",null,Z(g.token),1),T("div",sL,[$(p,{type:"dollar",value:g.amountDollars,precision:2},null,8,["value"])]),T("div",rL,[$(p,{type:"dollar",value:g.amount,precision:2,"show-symbol":!1},null,8,["value"])])]))),128))])])]),_:2},1024)]),_:1},8,["rows","columns","sorting","onSortColumn"])]),_:1},8,["title"])}}});function ug(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{title:{t:0,b:{t:2,i:[{t:3}],s:"All Pools"}},pool:{t:0,b:{t:2,i:[{t:3}],s:"Pool"}},total:{t:0,b:{t:2,i:[{t:3}],s:"Total"}}}})}typeof ug=="function"&&ug(_6);const oL=pe(_6,[["__scopeId","data-v-f6ed62ea"]]),lg="https://hub.snapshot.org/graphql",dg="https://score.snapshot.org/api/scores";class iL extends ra{async getProposal(t){const n=`{
            proposal(id: "${t}") {
                id
                snapshot
                choices
                end
            } }`;return this.fetch(lg,{query:n}).then(s=>s.data.proposal)}getDelegations(t,n){const s=n.delegators&&n.delegators.length>0?`delegator_in: ${JSON.stringify(n.delegators)}`:"",r=n.delegates&&n.delegates.length>0?`delegate_in: ${JSON.stringify(n.delegates)}`:"",o=["",n.space],i=`space_in: ${JSON.stringify(o)}`;let a=0;const c=async(l,d)=>{const f={block:t,timestampLast:a,spaceIn:i,delegateIn:r,delegatorIn:s,offset:d},p=await this.getHost(),h=(await this.fetch(`${p}/delegations`,f)).data.delegations;return a=Math.max(...h.map(y=>y.timestamp)),h.map(y=>(y.delegate=y.delegate.toLocaleLowerCase(),y.delegator=y.delegator.toLocaleLowerCase(),y))};function u(l,d,f){return f.map(p=>p.id).indexOf(l.id)===d}return jp(c).then(l=>l.filter(u))}async getVotes(t,n=[]){const s=n.map(i=>Cn(i)),r=n.length>0?`voter_in: ${JSON.stringify(s)}`:"";return jp((i,a)=>{const c=`{
                votes(
                    where: {
                        proposal: "${t}",
                        ${r}
                    },
                    first: ${a}
                    skip: ${i*a}
                    orderBy: "created"
                    orderDirection: desc
                ) {
                    id
                    voter
                    choice
                } }`;return this.fetch(lg,{query:c}).then(u=>u.data.votes.map(l=>(l.voter=l.voter.toLocaleLowerCase(),l)))}).then(i=>(t==="0xdf8a01486bd5e3a8c11b161f2a43f7295b0cd4ff257d5de95e485512287157b3"&&n.includes("0x3cde8fa1c73afe0828f672d197e082463c2ac8e2")&&i.push(aL),i))}async getScores(t,n,s){switch(t){case"cvx-crv":return await this.getScoresCvx(n,s);case"cvx-prisma":return await this.getScoresCvx(n,s);case"cvx-fxn":return await this.getScoresCvx(n,s);case"aura-bal":return await this.getScoresAura(n,s)}}async getScoresCvx(t,n){const r=[{name:"erc20-balance-of",params:{symbol:"CVX",address:t>=13948583?t>=14400650?t>=15091880?"0x81768695e9fdda232491bec5b21fd1bc1116f917":"0x1cc2CFed7e40bAb890Ca532AD0DBB413e072b988":"0x59CcBAABBFCAC52E007A706242C5B81a48179BF2":"0xD18140b4B819b895A3dba5442F959fA44994AF50",decimals:18}}],o={space:"cvx.eth",network:"1",snapshot:t,strategies:r,addresses:n};return this.fetch(dg,{params:o}).then(i=>i.result.scores.map(a=>Sb(a,(c,u)=>u.toLocaleLowerCase())))}async getScoresAura(t,n){const i={space:t>=16438041?"gauges.aurafinance.eth":"aurafinance.eth",network:"1",snapshot:t,strategies:[{name:"erc20-votes-with-override",params:{symbol:"vlAURA",address:"0x3Fa73f1E5d8A792C80F426fc8F84FBF7Ce9bBCAC",decimals:18}}],addresses:n};return this.fetch(dg,{params:i}).then(a=>a.result.scores.map(c=>Sb(c,(u,l)=>l.toLocaleLowerCase())))}}const aL={id:"",voter:"0x3cde8fa1c73afe0828f672d197e082463c2ac8e2",choice:{34:1003664,10:797362,3:735059,50:595202,41:505444,30:178861,46:153029,39:132059,63:130284,57:115001,12:114928,42:97179,2:87768,52:78816,62:72466,51:66378,53:50156,72:41716,58:37209,49:33585,75:29596,74:29376,25:26741,69:24724,29:24521,73:23503,77:20734,78:13528,66:10177,54:9735,86:8117,56:6892}},cL="https://api.thegraph.com/subgraphs/name/aurafinance/aura";let uL=class extends Kl{async getDelegation(t,n){var i,a;const s=`{
      auraLockerAccounts(
        where: {
          id: "${t}"
        },
        first: 100,
        block: {
          number: ${n}
        }
      ) {
        id,
        balanceLocked,
        delegate {
          id
        }
      }
    }`;return{id:"",delegate:((a=(i=(await this.fetch(cL,{query:s})).data.auraLockerAccounts[0])==null?void 0:i.delegate)==null?void 0:a.id)??t,delegator:t,timestamp:0,space:""}}};const lL=["cb","laf","cm","pm","pm-lrt"];function dL(){const e="laf";if(!lL.includes(e)){const t=`Unknown app for useApp(): ${e}`;throw En({text:t,type:"error"}),new Error(t)}return e}const cu={};function fL(e){return _R[e]}async function mn(e){const t=dL(),n=t;if(cu[n])return Promise.resolve(cu[n]);const s=fL(t);return cu[n]=s,cu[n]}const pL={class:"card-title"},mL={key:0},hL={key:0,class:"personalDollarPerVlAsset"},yL={class:"bribe"},bL={class:"end"},gL={class:"end"},vL={class:"tooltip-hover"},wL={key:1,class:"no-data"},_L={key:1},xL={key:2},x6=ae({__name:"TablePersonal",props:{epoch:{}},setup(e){const t=new iL(mn()),n=new uL,{t:s}=Me(),{protocol:r}=sr(gs()),{isConnected:o,address:i}=tt(),a=M(()=>[{id:"percentage",label:"%",sort:!0},{id:"pool",label:s("pool"),sort:!0},{id:"vlasset",label:`$/${Lo(r.value)}`,sort:!0,align:"end"},{id:"total",label:s("total"),sort:!0,align:"end"}]),{sorting:c,onSort:u}=jh("total"),l=M(()=>{var L;return((L=e.epoch)==null?void 0:L.platform)!=="hh"}),d=M(()=>m.value.orderBy(L=>{switch(c.value.column){case"pool":return L.pool;case"vlasset":return L.dollarPerVlAsset;default:case"total":return L.amountDollars}},c.value.order)),f=M(()=>d.value.reduce((L,X)=>L+X.amountDollars,0)),p=M(()=>{const L=d.value.reduce((X,z)=>X+z.amountDollars/z.dollarPerVlAsset,0);return f.value/L}),m=M(()=>{var z;if(!e.epoch||!b.value||!i.value||Object.keys(C.value).length===0||A.value.length===0)return[];let L;r.value==="aura-bal"?L=w.value[0].delegate:L=(z=q9([w.value[0],w.value[1]],A.value.map(ie=>ie.voter))[0])==null?void 0:z.delegate;const X=W9(b.value,i.value,L,A.value,C.value);return z9(e.epoch,X)}),h=M(()=>y.value||g.value||_.value||x.value),{isFetching:y,data:b}=Fn({queryKey:["bribes-personal-proposal",M(()=>{var L;return(L=e.epoch)==null?void 0:L.proposal})],queryFn:({queryKey:[,L]})=>L?t.getProposal(L):null}),{isFetching:g,data:w}=Fn({queryKey:["bribes-personal-delegations",M(()=>{var L;return(L=b.value)==null?void 0:L.snapshot}),i],queryFn:({queryKey:[,L,X]})=>{if(!L||!X)return[];const z=parseInt(L,10);return r.value==="aura-bal"?n.getDelegation(X,z).then(ie=>[ie]):t.getDelegations(z,{delegators:[X],space:"cvx.eth"})},initialData:[],initialDataUpdatedAt:0}),{isFetching:_,data:A}=Fn({queryKey:["bribes-personal-votes",M(()=>{var L;return(L=e.epoch)==null?void 0:L.proposal}),i,M(()=>w.value.map(L=>L.delegate))],queryFn:({queryKey:[,L,X,z]})=>!L||!X?[]:t.getVotes(L,[X,...z]),initialData:[],initialDataUpdatedAt:0}),{isFetching:x,data:C}=Fn({queryKey:["bribes-personal-scores",M(()=>{var L;return(L=b.value)==null?void 0:L.snapshot}),i],queryFn:({queryKey:[,L,X]})=>{if(!L||!X||!r.value)return[];const z=parseInt(L,10);return t.getScores(r.value,z,[X])},initialData:{},initialDataUpdatedAt:0}),k=L=>L.pool,S=L=>L.amountDollars,R=L=>L.dollarPerVlAsset,B=L=>L.percentage;return(L,X)=>{const z=Pt,ie=jo,ne=zo,te=He;return F(),fe(te,null,{title:Y(()=>[T("div",pL,[we(Z(v(s)("title"))+" ",1),v(f)?(F(),J("span",mL," - ")):ye("",!0),v(f)?(F(),fe(z,{key:1,type:"dollar",value:v(f),precision:2},null,8,["value"])):ye("",!0)])]),actions:Y(()=>[v(p)?(F(),J("div",hL,[$(z,{type:"dollar",value:v(p),precision:4},null,8,["value"]),we("/"+Z(v(Lo)(v(r))),1)])):ye("",!0)]),default:Y(()=>[v(d).length>0?(F(),fe(ne,{key:0,class:"personal-table",rows:v(d),columns:v(a),sorting:v(c),onSortColumn:v(u)},{row:Y(({item:ce})=>[$(ie,null,{trigger:Y(()=>[T("div",yL,[T("div",null,[$(z,{type:"percentage",value:B(ce),precision:0},null,8,["value"])]),T("div",null,Z(k(ce)),1),T("div",bL,[$(z,{type:"dollar",value:R(ce),precision:5},null,8,["value"])]),T("div",gL,[$(z,{type:"dollar",value:S(ce),precision:2},null,8,["value"])])])]),default:Y(()=>[T("div",vL,Z(k(ce)),1)]),_:2},1024)]),_:1},8,["rows","columns","sorting","onSortColumn"])):(F(),J("div",wL,[!v(o)&&v(l)?(F(),fe(Mh,{key:0})):v(h)?(F(),J("span",_L,Z(v(s)("loading"))+" "+Z(v(Hl)(v(i))),1)):(F(),J("span",xL,"There's no personal rewards yet"))]))]),_:1})}}});function fg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{title:{t:0,b:{t:2,i:[{t:3}],s:"Personal Rewards"}},pool:{t:0,b:{t:2,i:[{t:3}],s:"Pool"}},total:{t:0,b:{t:2,i:[{t:3}],s:"Total"}},loading:{t:0,b:{t:2,i:[{t:3}],s:"Loading"}}}})}typeof fg=="function"&&fg(x6);const CL=pe(x6,[["__scopeId","data-v-a51bda7b"]]),AL=ae({__name:"ChartApex",props:{options:{},series:{}},setup(e){const t=k3(()=>$i(()=>import("./vue3-apexcharts-Df6ovwwD.js"),__vite__mapDeps([5,1])));return(n,s)=>(F(),fe(v(t),{class:"chart",height:"100%",options:n.options,series:n.series},null,8,["options","series"]))}}),C6=pe(AL,[["__scopeId","data-v-9001ed29"]]),TL=e=>({chart:{id:"chart",background:"transparant",foreColor:e.colors.level5,fontFamily:"ui-monospace, SFMono-Regular, SF Mono, Menlo, Monaco, Consolas, monospace",toolbar:{autoSelected:"zoom",tools:{download:!1,pan:!1}},zoom:{autoScaleYaxis:!0}},colors:e.colorsArray,grid:{borderColor:e.colors.level5,strokeDashArray:4,xaxis:{lines:{show:!1}}},fill:{type:"solid",opacity:1},stroke:{curve:"smooth",width:2},theme:{mode:"dark"},xaxis:{type:"category",axisBorder:{color:e.colors.level5,height:1},axisTicks:{color:e.colors.level5},title:{color:e.colors.level5}},yaxis:{tickAmount:4,axisBorder:{color:e.colors.level5},axisTicks:{color:e.colors.level5},title:{color:e.colors.level5}}});function A6(e,t){t??(t=EO());const n=TL(t.value);return e?U_(n,e):n}const T6=ae({__name:"ChartBribesRound",props:{epoch:{}},setup(e){const{t}=Me(),{protocol:n}=sr(gs()),s=M(()=>{var u;const c=n.value==="aura-bal"?0:2500;return(((u=e.epoch)==null?void 0:u.bribes)??[]).filter(l=>l.amountDollars>c)}),r=M(()=>s.value.groupBy(c=>c.pool).entries().map(([,c])=>c.reduce((u,l)=>({pool:u.pool,amountDollars:u.amountDollars+l.amountDollars}),{pool:c[0].pool,amountDollars:0})).orderBy(c=>c.amountDollars,"desc").map(c=>c.pool).take(20)),o=M(()=>A6({chart:{id:"votium-bribe-round",type:"bar",stacked:!0},xaxis:{categories:r.value},yaxis:{labels:{formatter:c=>`$${xo(c,2,"dollar")}${Mr(c)}`}},plotOptions:{bar:{columnWidth:a(r.value.length).toString()+"%",distributed:!0,dataLabels:{position:"top",hideOverflowingLabels:!1}}},legend:{show:!1},tooltip:{followCursor:!1,enabled:!0,intersect:!1,custom:c=>c.w.globals.initialSeries.map(l=>({token:l.name,sum:l.data[c.dataPointIndex]})).filter(l=>l.sum>0).map(l=>({token:l.token,sum:`$${xo(l.sum,2,"dollar")}${Mr(l.sum)}`})).orderBy(l=>l.sum,"desc").map(l=>`<div><b>${l.token}</b>:</div><div>${l.sum}</div>`).join("")},dataLabels:{enabled:!1,formatter:(c,u)=>{if(u.seriesIndex===u.w.config.series.length-1){const l=u.w.globals.stackedSeriesTotals[u.dataPointIndex];return`$${xo(l,2,"dollar")}${Mr(l)}`}return""},offsetY:-25,style:{fontSize:"12px",fontFamily:"ui-monospace, SFMono-Regular, SF Mono, Menlo, Monaco, Consolas, monospace"}}})),i=M(()=>s.value.groupBy(c=>c.token).entries().map(([c,u])=>({name:c,data:r.value.map(l=>u.reduce((d,f)=>f.pool===l?d+f.amountDollars:d,0))}))),a=c=>20+60/(1+30*Math.exp(-c/3));return(c,u)=>{const l=C6,d=He;return F(),fe(d,{title:v(t)("title")},{default:Y(()=>[$(l,{options:v(o),series:v(i)},null,8,["options","series"])]),_:1},8,["title"])}}});function pg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{title:{t:0,b:{t:2,i:[{t:3}],s:"Rewards"}}}})}typeof pg=="function"&&pg(T6);const EL=pe(T6,[["__scopeId","data-v-a45a98be"]]);class E6 extends ra{async rounds(t){const n=await this.getHost();return this.fetch(`${n}/bribes/${t.platform}/${t.protocol}/rounds`)}async getEpoch(t){const n=await this.getHost(),s=t.round.toString();let r=`${n}/bribes/${t.platform}/${t.protocol}`;return s&&(r+=`/${s}`),this.fetch(r)}async getOverview(){const t=await this.getHost();return this.fetch(`${t}/bribes/overview`)}}const nd={HH_API_URL:"https://api.hiddenhand.finance/proposal/aura",LA_API_URL:"https://llama-airforce-api.aura.finance/dollar-per-vlasset",START_ROUND:28,START_DATE:1689019200,BIWEEKLY:86400*14};function SL(e,t){if(!e.dashboard||!t.dashboard)return{statusCode:500,dashboard:void 0};const n=[...e.dashboard.epochs,...t.dashboard.epochs];return{...e,dashboard:{...e.dashboard,rewardPerDollarBribe:t.dashboard.rewardPerDollarBribe,epochs:n}}}function Hh(e,t){return 86400*(e??0)+3600*(t??0)}function PL(e){const{START_DATE:t,BIWEEKLY:n,START_ROUND:s}=nd,r=Hh(5,-4),o=e-s;return t-r+o*n}function mg(e){const t=Hh(5);return PL(e)+t}function hg(e){const{START_DATE:t,BIWEEKLY:n,START_ROUND:s}=nd,r=Hh(9,4),o=Math.ceil((e-t-r)/n);return s+o}const{HH_API_URL:kL,LA_API_URL:IL,START_ROUND:uu,START_DATE:yg,BIWEEKLY:bg}=nd;class S6 extends Kl{constructor(){super();qo(this,"latestRound");qo(this,"today");const n=Date.now()/1e3;this.latestRound=hg(n),this.today=n}async fetchIncentivePerVote(){return this.fetch(`${IL}/${Math.floor(this.today)}`).catch(()=>({result:{emissionValuePerVote:0,emissionsPerDollarSpent:0,totalEmission:0}}))}async fetchRound(n){return this.fetch(`${kL}/${n}`).then(s=>s.data)}async fetchRounds(){const n=hg(this.today)-uu+1;return Promise.all([...new Array(n)].map((s,r)=>this.fetchRound(yg+r*bg)))}async getRound(n){var c;if(n!==void 0&&n<uu-1)return Promise.resolve({statusCode:400});const s=n??this.latestRound,r=await this.fetchRound(yg+(s-uu)*bg),o=((c=r[r.length-1])==null?void 0:c.proposalDeadline)??mg(s),i=Object.fromEntries(r.map(({title:u,voteCount:l,totalValue:d})=>[u,d>0?l:0]).filter(([,u])=>!!u)),a=r.map(u=>u.bribes.map(l=>({pool:u.title,token:l.symbol.toUpperCase(),amount:l.amount,amountDollars:l.value}))).flat();return Promise.resolve({statusCode:200,epoch:{round:s,platform:"hh",protocol:"aura-bal",proposal:"",end:o,bribed:i,bribes:a}})}async getOverview(){const n=this.fetchRounds().then(r=>r.map((o,i)=>{var p;const a=o.map(({totalValue:m,voteCount:h})=>[m,m>0?h:0]),c=a.reduce((m,[h])=>m+h,0),u=a.reduce((m,[,h])=>m+h,0),l=u>0?c/u:0,d=uu+i,f=((p=o[o.length-1])==null?void 0:p.proposalDeadline)??mg(d);return{protocol:"aura-bal",totalAmountDollars:c,end:f,dollarPerVlAsset:l,round:d,proposal:""}})),s=await this.fetchIncentivePerVote().then(({result:r})=>r.emissionsPerDollarSpent);return n.then(r=>({statusCode:r.length>0?200:500,dashboard:{id:"bribes-overview-aura",rewardPerDollarBribe:s,epochs:r}}))}}class RL extends E6{constructor(n){super(n);qo(this,"auraService");this.auraService=new S6}async rounds(){return Promise.resolve({statusCode:200,rounds:[...new Array(this.auraService.latestRound)].map((n,s)=>s+1)})}async getEpoch(n){if(n.round>=nd.START_ROUND)return this.auraService.getRound(n.round);const s=await this.getHost(),r=n.round.toString();return this.fetch(`${s}/bribes/${n.platform}/${n.protocol}/${r}`)}}const ff=new WeakMap;function La(e,t,n={}){const{mode:s="replace",route:r=Ho(),router:o=aa(),transform:i=d=>d}=n;ff.has(o)||ff.set(o,new Map);const a=ff.get(o);let c=r.params[e];Dl(()=>{c=void 0});let u;const l=m1((d,f)=>(u=f,{get(){return d(),i(c!==void 0&&c!==""?c:Xs(t))},set(p){c!==p&&(c=p===t||p===null?void 0:p,a.set(e,p===t||p===null?void 0:p),f(),Js(()=>{if(a.size===0)return;const m=Object.fromEntries(a.entries());a.clear();const{params:h,query:y,hash:b}=r;o[Xs(s)]({params:{...h,...m},query:y,hash:b})}))}}));return Ce(()=>r.params[e],d=>{c!==d&&(c=d,u())},{flush:"sync"}),l}const $L={class:"dashboard"},ML=ae({__name:"Rounds.page",setup(e){let t=!1;const n=gs(),{platform:s,product:r}=sr(n),{setProtocol:o}=n,i=le(void 0),a=aa(),c=La("round",0,{transform:Number}),u=La("platform"),l=La("protocol"),d=M(()=>{var w;return((w=r.value)==null?void 0:w.protocol)==="aura-bal"?new RL(mn()):new E6(mn())}),{data:f}=Fn({queryKey:["bribes-rounds",r],queryFn:({queryKey:[,w]})=>w?d.value.rounds(w).then(_=>_.rounds):[],initialData:[],initialDataUpdatedAt:0}),{data:p}=Fn({queryKey:["bribes-epoch",r,i],queryFn:({queryKey:[,w,_]})=>{if(w&&_)return d.value.getEpoch({platform:w.platform,protocol:w.protocol,round:_}).then(A=>A.epoch)},initialData:void 0,initialDataUpdatedAt:0,enabled:()=>!!i.value});Cm(g),fl(()=>{t=!1}),Ce(f,w=>{i.value||(i.value=w.at(-1))},{immediate:!0}),Ce(i,w=>{r.value&&w&&b(r.value,w)});const m=(w,_=!1)=>{t&&!_||(s.value=w)},h=(w,_=!1)=>{if(t&&!_)return;const A=o(w);s.value&&!_&&y(A?i.value:void 0)},y=w=>{i.value=w},b=async(w,_)=>{const{platform:A,protocol:x}=w;await a.push({name:"rounds-incentives",params:{platform:A,protocol:x,round:_}})};function g(){t||(t=!0,m6(u.value)&&h6(l.value)?(m(u.value,!0),h(l.value,!0),c.value&&y(c.value)):r.value&&(m(r.value.platform,!0),h(r.value.protocol,!0)),t=!1)}return(w,_)=>(F(),J("div",$L,[$(y6,{style:{"grid-area":"select-system"},onSelectPlatform:m,onSelectProtocol:h}),$(Y9,{style:{"grid-area":"summary"},rounds:v(f),epoch:v(p),onSelectRound:y},null,8,["rounds","epoch"]),$(EL,{style:{"grid-area":"chart",height:"370px"},epoch:v(p)},null,8,["epoch"]),$(CL,{style:{"grid-area":"table-personal","max-height":"750px"},epoch:v(p)},null,8,["epoch"]),$(oL,{style:{"grid-area":"table-bribed","max-height":"750px"},epoch:v(p)},null,8,["epoch"])]))}}),gg=pe(ML,[["__scopeId","data-v-a84d0627"]]),P6=ae({__name:"ChartBribesRevenue",props:{overview:{}},setup(e){const{t}=Me(),{protocol:n}=sr(gs()),s=M(()=>{var i;return((i=e.overview)==null?void 0:i.epochs)??[]}),r=M(()=>A6({chart:{id:"votium-bribe-revenue"},stroke:{width:2},xaxis:{categories:[...s.value].sort((i,a)=>i.round-a.round).map(i=>Oa(i))},yaxis:[{tickAmount:4,labels:{formatter:i=>`$${xo(i,2,"dollar")}${Mr(i)}`,style:{colors:[ks.value.blue]}}},{opposite:!0,tickAmount:4,labels:{formatter:i=>`$${xo(i,n.value==="cvx-prisma"?5:2,"dollar")}${Mr(i)}`,style:{colors:[ks.value.yellow]}}}],plotOptions:{bar:{columnWidth:"15%",distributed:!1,dataLabels:{position:"top"}}},markers:{size:3},dataLabels:{enabled:!1,formatter:i=>`$${xo(i,2,"dollar")}${Mr(i)}`,offsetY:-25,style:{fontSize:"12px",fontFamily:"ui-monospace, SFMono-Regular, SF Mono, Menlo, Monaco, Consolas, monospace"}}})),o=M(()=>[{name:t("revenue"),type:"column",data:[...s.value].sort((i,a)=>i.round-a.round).map(i=>({x:Oa(i),y:i.totalAmountDollars}))},{name:`$/${Lo(n.value)}`,type:"line",data:[...s.value].sort((i,a)=>i.round-a.round).map(i=>({x:Oa(i),y:i.dollarPerVlAsset}))}]);return(i,a)=>{const c=C6,u=He;return F(),fe(u,{title:v(t)("title")},{default:Y(()=>[$(c,{options:v(r),series:v(o)},null,8,["options","series"])]),_:1},8,["title"])}}});function vg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{title:{t:0,b:{t:2,i:[{t:3}],s:"Round by Round"}},revenue:{t:0,b:{t:2,i:[{t:3}],s:"Revenue"}}}})}typeof vg=="function"&&vg(P6);const OL=["href"],LL={key:0},FL={key:1},NL={class:"content"},BL={class:"end"},DL={class:"end"},k6=ae({__name:"TableRounds",props:{overview:{}},setup(e){const{t}=Me(),{protocol:n}=sr(gs()),s=aa(),r=M(()=>["",{id:"deadline",label:t("deadline"),sort:!0},{id:"vlasset",label:`$/${Lo(n.value)}`,sort:!0,align:"end"},{id:"total",label:t("total"),sort:!0,align:"end"}]),{sorting:o,onSort:i}=jh("deadline"),a=M(()=>{var h;return(((h=e.overview)==null?void 0:h.epochs)??[]).orderBy(y=>{switch(o.value.column){case"deadline":return y.round;case"vlasset":return l(y);case"total":return d(y)}},o.value.order)}),c=h=>h.round,u=h=>g6(h,h.proposal),l=h=>h.dollarPerVlAsset,d=h=>h.totalAmountDollars,f=h=>Oa(h),p=h=>new Date>Yu(h),m=async h=>{await s.push({name:"rounds-incentives",params:{round:h.round}})};return(h,y)=>{const b=jo,g=B_,w=Pt,_=zo,A=He;return F(),fe(A,{title:v(t)("all-rounds")},{actions:Y(()=>[$(b,null,{default:Y(()=>[we(Z(v(t)("tooltip")),1)]),_:1})]),default:Y(()=>[$(_,{class:"bribe-rounds-table",rows:v(a),columns:v(r),sorting:v(o),onSortColumn:v(i),onSelected:m},{row:Y(({item:x})=>[T("div",{class:"round-number",onClick:y[0]||(y[0]=Ac(()=>{},["stop"]))},[T("a",{class:"vote-link",target:"_blank",href:u(x)},[p(x)?(F(),J("span",LL,Z(c(x)),1)):(F(),J("span",FL,[$(b,null,{trigger:Y(()=>[$(g,{style:{"vertical-align":"middle"}})]),default:Y(()=>[T("span",NL,Z(v(t)("ongoing")),1)]),_:1})]))],8,OL)]),T("div",null,Z(f(x)),1),T("div",BL,[$(w,{type:"dollar",value:l(x),precision:5},null,8,["value"])]),T("div",DL,[$(w,{type:"dollar",value:d(x),precision:2},null,8,["value"])])]),_:1},8,["rows","columns","sorting","onSortColumn"])]),_:1},8,["title"])}}});function wg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{deadline:{t:0,b:{t:2,i:[{t:3}],s:"Deadline"}},total:{t:0,b:{t:2,i:[{t:3}],s:"Total"}},"all-rounds":{t:0,b:{t:2,i:[{t:3}],s:"All Rounds"}},tooltip:{t:0,b:{t:2,i:[{t:3}],s:"Dollar values for finished rounds are dollar values at the time of snapshot ending."}},ongoing:{t:0,b:{t:2,i:[{t:3}],s:"Ongoing"}}}})}typeof wg=="function"&&wg(k6);const UL=pe(k6,[["__scopeId","data-v-44f0d616"]]),VL={class:"summary"},I6=ae({__name:"Summary",props:{overview:{}},setup(e){const{t}=Me(),{protocol:n}=sr(gs()),s=M(()=>{var u;return((u=e.overview)==null?void 0:u.epochs)??[]}),r=M(()=>t("record-earnings",[Lo(n.value)])),o=M(()=>s.value.reduce((u,l)=>u+l.totalAmountDollars,0)),i=M(()=>{var u;return((u=e.overview)==null?void 0:u.rewardPerDollarBribe)??0}),a=M(()=>Math.max(...s.value.map(u=>u.dollarPerVlAsset))),c=M(()=>{let u="???";switch(n.value){case"cvx-crv":u="CRV";break;case"cvx-prisma":u="PRISMA";break;case"cvx-fxn":u="FXN";break;case"aura-bal":u="BAL + AURA";break;default:u="???"}return t("tooltip",[u])});return(u,l)=>{const d=Pt,f=td;return F(),J("div",VL,[$(f,{class:"all-time-revenue",label:v(t)("all-time-revenue"),"has-value":!!v(o)},{default:Y(()=>[$(d,{type:"dollar",value:v(o),precision:2},null,8,["value"])]),_:1},8,["label","has-value"]),$(f,{class:"emissions-per-bribe",label:v(t)("emissions"),"has-value":!!v(i),tooltip:v(c)},{default:Y(()=>[$(d,{type:"dollar",value:v(i),precision:2},null,8,["value"])]),_:1},8,["label","has-value","tooltip"]),$(f,{class:"record-earnings",label:v(r),"has-value":!!v(a)},{default:Y(()=>[$(d,{type:"dollar",value:v(a),precision:5},null,8,["value"])]),_:1},8,["label","has-value"])])}}});function _g(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"all-time-revenue":{t:0,b:{t:2,i:[{t:3}],s:"All time revenue"}},emissions:{t:0,b:{t:2,i:[{t:3}],s:"Emissions / $1 spent on bribes"}},"record-earnings":{t:0,b:{t:2,i:[{t:3,v:"Record earnings per "},{t:5,i:0}]}},tooltip:{t:0,b:{t:2,i:[{t:3,v:"This statistic is for <u><strong>bribers</strong></u>:<br /> It tells you how much gauge emission rewards ("},{t:5,i:0},{t:3,v:") liquidity providers will get for each dollar spent on pool bribes.<br /> A value above $1 means that it's cheaper to bribe compared to directly handing out liquidity mining rewards."}]}}}})}typeof _g=="function"&&_g(I6);const jL=pe(I6,[["__scopeId","data-v-8166f3b6"]]);class HL extends ra{constructor(n){super(n);qo(this,"auraService");this.auraService=new S6}async getOverview(n){const s=await this.getHost(),r=this.fetch(`${s}/dashboard/${n}`);if(n==="bribes-overview-aura"){const[o,i]=await Promise.all([r,this.auraService.getOverview()]);return SL(o,i)}return r}}const zL={class:"dashboard"},qL=ae({__name:"Overview.page",setup(e){const t=new HL(mn());let n=!1;const s=gs(),{platform:r,product:o}=sr(s),{setProtocol:i}=s,a=aa(),c=La("platform"),u=La("protocol"),l=M(()=>{var y;switch((y=o.value)==null?void 0:y.platform){case"votium":switch(o.value.protocol){case"cvx-crv":return"bribes-overview-votium";case"cvx-prisma":return"bribes-overview-prisma";case"cvx-fxn":return"bribes-overview-fxn";default:throw new Error("Unknown protocol for dashboard")}case"hh":return"bribes-overview-aura";default:throw new Error("Unknown platform for dashboard")}}),{data:d}=Fn({queryKey:["bribes-overview",l],queryFn:({queryKey:[,y]})=>{if(y)return t.getOverview(y).then(b=>b.dashboard)}});Cm(h),fl(()=>{n=!1});const f=(y,b=!1)=>{n&&!b||(r.value=y)},p=(y,b=!1)=>{var g;n&&!b||(i(y),(g=o.value)!=null&&g.platform&&l.value&&m(o.value))},m=async y=>{const{platform:b,protocol:g}=y;await a.push({name:"overview-incentives",params:{platform:b,protocol:g}})};function h(){n||(n=!0,m6(c.value)&&h6(u.value)?(f(c.value,!0),p(u.value,!0)):o.value&&(f(o.value.platform,!0),p(o.value.protocol,!0)),n=!1)}return(y,b)=>(F(),J("div",zL,[$(y6,{style:{"grid-area":"select-system"},onSelectPlatform:f,onSelectProtocol:p}),$(jL,{style:{"grid-area":"summary"},overview:v(d)},null,8,["overview"]),$(P6,{style:{"grid-area":"chart",height:"370px"},overview:v(d)},null,8,["overview"]),$(UL,{style:{"grid-area":"table",height:"420px"},overview:v(d)},null,8,["overview"])]))}}),xg=pe(qL,[["__scopeId","data-v-d4eae1c7"]]),WL=[{path:"/votium",redirect:{name:"rounds-incentives"}},{path:"/votium/bribes/:round?",redirect:{name:"rounds-incentives"}},{path:"/bribes",redirect:{name:"rounds-incentives"}},{path:"/bribes/rounds/:platform?/:protocol?/:round?",name:"rounds",component:gg},{path:"/bribes/overview/:platform?/:protocol?",name:"overview",component:xg},{path:"/incentives",redirect:{name:"rounds-incentives"}},{path:"/incentives/rounds/:platform?/:protocol?/:round?",name:"rounds-incentives",component:gg},{path:"/incentives/overview/:platform?/:protocol?",name:"overview-incentives",component:xg}],GL={title:"Bribes",titleRoute:["/incentives","/bribes"],visible:!0,planeX:410,menuHeader:Dh,items:[{to:"/incentives/rounds",label:"Rounds",icon:Y4},{to:"/incentives/overview",label:"Overview",icon:Z4}],forceShowMenu:!1},st=[{inputs:[],name:"FEE_DENOMINATOR",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"},{internalType:"address",name:"spender",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"account",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"user",type:"address"}],name:"balanceOfUnderlying",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"platformFee",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"callIncentive",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"subtractedValue",type:"uint256"}],name:"decreaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"uint256",name:"_amount",type:"uint256"}],name:"deposit",outputs:[{internalType:"uint256",name:"_shares",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"}],name:"depositAll",outputs:[{internalType:"uint256",name:"_shares",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"addedValue",type:"uint256"}],name:"increaseAllowance",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalUnderlying",outputs:[{internalType:"uint256",name:"total",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"underlying",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"},{internalType:"uint256",name:"_shares",type:"uint256"}],name:"withdraw",outputs:[{internalType:"uint256",name:"withdrawn",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"}],name:"withdrawAll",outputs:[{internalType:"uint256",name:"withdrawn",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"withdrawalPenalty",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}],Fc=[{inputs:[],name:"FEE_DENOMINATOR",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"},{internalType:"address",name:"",type:"address"}],name:"allowance",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"spender",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"approve",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"asset",outputs:[{internalType:"contract ERC20",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"}],name:"balanceOf",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"shares",type:"uint256"}],name:"convertToAssets",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"assets",type:"uint256"}],name:"convertToShares",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"decimals",outputs:[{internalType:"uint8",name:"",type:"uint8"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"assets",type:"uint256"},{internalType:"address",name:"receiver",type:"address"}],name:"deposit",outputs:[{internalType:"uint256",name:"shares",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"harvest",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"}],name:"maxDeposit",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"}],name:"maxMint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"maxRedeem",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"owner",type:"address"}],name:"maxWithdraw",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"shares",type:"uint256"},{internalType:"address",name:"receiver",type:"address"}],name:"mint",outputs:[{internalType:"uint256",name:"assets",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"name",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"}],name:"nonces",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"platformFee",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"assets",type:"uint256"}],name:"previewDeposit",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"shares",type:"uint256"}],name:"previewMint",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"shares",type:"uint256"}],name:"previewRedeem",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"assets",type:"uint256"}],name:"previewWithdraw",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"shares",type:"uint256"},{internalType:"address",name:"receiver",type:"address"},{internalType:"address",name:"owner",type:"address"}],name:"redeem",outputs:[{internalType:"uint256",name:"assets",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"symbol",outputs:[{internalType:"string",name:"",type:"string"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalAssets",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[],name:"totalSupply",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transfer",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"address",name:"from",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"}],name:"transferFrom",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"assets",type:"uint256"},{internalType:"address",name:"receiver",type:"address"},{internalType:"address",name:"owner",type:"address"}],name:"withdraw",outputs:[{internalType:"uint256",name:"shares",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"withdrawalPenalty",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"}];function XL(e){return e.tkn==="cvxCRV"&&e.utkn==="uCRV"}function KL(e){return e.tkn==="cvxFXS"&&e.utkn==="uFXS"}function QL(e){return e.tkn==="cvxPRISMA"&&e.utkn==="uPRISMA"}function ZL(e){return e.tkn==="pxCVX"&&e.utkn==="uCVX"}async function YL(e,t,n){const s=await V_(t,e),r=St({abi:st,address:zr,client:e}),o=await eo(r);n=n??{index:0,amount:"0x0",proof:[]};const i=BigInt(n.amount),a=o*Ie(i,18n),c=a*s;return{id:"union",tkn:"cvxCRV",utkn:"uCRV",claim:n,amount:i,amountAsset:a,amountDollar:c,distributorAddress:zl,swap:{buy:"ETH",sell:"cvxCRV"}}}async function JL(e,t,n){const s=await Vo(t,e),r=St({abi:st,address:Ks,client:e}),o=await eo(r);n=n??{index:0,amount:"0x0",proof:[]};const i=BigInt(n.amount),a=o*Ie(i,18n),c=a*s;return{id:"ufxs",tkn:"cvxFXS",utkn:"uFXS",claim:n,amount:i,amountAsset:a,amountDollar:c,distributorAddress:ql,swap:{buy:"ETH",sell:"cvxFXS"}}}async function e7(e,t,n){const s=await $h(t,e),r=St({abi:st,address:qr,client:e}),o=await eo(r);n=n??{index:0,amount:"0x0",proof:[]};const i=BigInt(n.amount),a=o*Ie(i,18n),c=a*s;return{id:"uprisma",tkn:"cvxPRISMA",utkn:"uPRISMA",claim:n,amount:i,amountAsset:a,amountDollar:c,distributorAddress:Gl,swap:{buy:"ETH",sell:"cvxPRISMA"}}}async function t7(e,t,n){const s=await Xl(t,e),r=St({abi:Fc,address:ys,client:e}),o=await eo(r);n=n??{index:0,amount:"0x0",proof:[]};const i=BigInt(n.amount),a=o*Ie(i,18n),c=a*s;return{id:"ucvx",tkn:"pxCVX",utkn:"uCVX",claim:n,amount:i,amountAsset:a,amountDollar:c,distributorAddress:Wl,swap:{buy:"CVX",sell:"ETH"}}}const n7={address:zl,tokenAddress:zr,network:"ethereum"},s7={address:ql,tokenAddress:Ks,network:"ethereum"},r7={address:Gl,tokenAddress:qr,network:"ethereum"},o7={address:Wl,tokenAddress:ys,network:"ethereum"};function R6(e){switch(e){case"union":return n7;case"ufxs":return s7;case"uprisma":return r7;case"ucvx":return o7;default:throw new Error("Unknown airdrop id")}}async function i7(e){const t=Ie(await e.read.FEE_DENOMINATOR(),1n),n=Ie(await e.read.platformFee(),1n)/t*100,s=Ie(await e.read.withdrawalPenalty(),1n)/t*100;let r=0;return $6(e)||(r=Ie(await e.read.callIncentive(),1n)/t*100),{platform:n,caller:r,withdrawal:s}}function $6(e){return e.abi.some(t=>t.name==="totalAssets")}function a7(e){return $6(e)?e.read.totalAssets():e.read.totalUnderlying()}async function eo(e){const t=10n**18n,n=await a7(e),s=await e.read.totalSupply();return s>0n?Ie(n*t/s,18n):1}function pr(){return{priceUnderlying:void 0,priceShare:void 0,balanceDeposit:void 0,balanceWithdraw:void 0,balanceUnclaimed:void 0,decimalsDeposit:18n,decimalsWithdraw:18n,symbolDeposit:"???",symbolWithdraw:"???",symbolLpPrimary:"???",oraclePrice:1,tvl:void 0,apy:void 0}}const Nc=Lh("unionStore",()=>{const e=zs({ucrv:null,ucrv2:null,ufxs:null,uprisma:null,ucvx:null,ubal:null,ufxslp:null}),t=zs({ucrv:void 0,ucrv2:void 0,ufxs:void 0,uprisma:void 0,ucvx:void 0,ubal:void 0,ufxslp:void 0});function n(a){const c=e[a];return{pounder:c==null?void 0:c.pounder,state:c==null?void 0:c.state,zapsFactories:c==null?void 0:c.zapsFactories}}async function s(a){var b,g;const{pounder:c,state:u}=n(a);if(!c||!u)return;const[l,d,f,p,m,h,y]=await Promise.all([c.getPriceUnderlying(),c.getApy(),c.contract.read.decimals(),c.contract.read.symbol(),c.contract.read.totalSupply(),eo(c.contract),((b=c.lp)==null?void 0:b.getOraclePrice())??1]);u.priceUnderlying=l,u.apy=d,u.symbolLpPrimary=((g=c.lp)==null?void 0:g.symbolPrimary)??"",u.decimalsWithdraw=BigInt(f),u.symbolWithdraw=p,u.tvl=m,u.priceShare=h,u.oraclePrice=y}async function r(a,c){const{pounder:u,state:l}=n(a);l&&(c&&u?l.balanceWithdraw=await u.contract.read.balanceOf([c]):l.balanceWithdraw=void 0)}async function o(a,c){const{state:u}=n(a);u&&c&&(u.symbolDeposit=c.depositSymbol,u.balanceDeposit=await c.depositBalance(),u.decimalsDeposit=await c.depositDecimals()??18n)}function i(a,c){const{state:u}=n(a);u&&(u.balanceUnclaimed=BigInt(c?c.amount:0))}return{pounders:e,claims:t,getPounder:n,updatePounder:s,updateBalances:r,updateZapDeposit:o,updateClaim:i}});class zh extends ra{async getClaim(t,n){const s=await this.getHost(),r=Cn(n);try{return await this.fetch(`${s}/airdrop/${t}/${r}`)}catch(o){if(o instanceof j_)return null;throw o}}}class M6 extends ra{async getConvex(){const t="flyer-convex",n=await this.getHost();return this.fetch(`${n}/dashboard/${t}`)}async getAura(){const t="flyer-aura",n=await this.getHost();return this.fetch(`${n}/dashboard/${t}`)}}const dc=[{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"}],name:"claim",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"enum ClaimZaps.Option",name:"option",type:"uint8"}],name:"claimAs",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"enum ClaimZaps.Option",name:"option",type:"uint8"},{internalType:"uint256",name:"minAmountOut",type:"uint256"}],name:"claimAs",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"freeze",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"frozen",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"}],name:"isClaimed",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[],name:"merkleRoot",outputs:[{internalType:"bytes32",name:"",type:"bytes32"}],stateMutability:"view",type:"function"},{inputs:[],name:"unfreeze",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"vault",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[],name:"week",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"_merkleRoot",type:"bytes32"},{internalType:"bool",name:"_unfreeze",type:"bool"}],name:"updateMerkleRoot",outputs:[],stateMutability:"nonpayable",type:"function"}];function Ns(e,t,n,s){const{data:r}=Fn({queryKey:["union-claim",t,n],queryFn:({queryKey:[,l,d]})=>e.getClaim(l,d),enabled:M(()=>!!n.value)}),o=R6(t),{data:i}=Tt({abi:dc,address:o.address,functionName:"frozen",query:{enabled:s,initialData:!1,initialDataUpdatedAt:0}}),{data:a,refetch:c}=Tt({abi:dc,address:o.address,functionName:"isClaimed",args:M(()=>{var l;return[BigInt(((l=r.value)==null?void 0:l.index)??0)]}),query:{enabled:M(()=>!!r.value),initialData:!1,initialDataUpdatedAt:0}});return{claim:M(()=>i.value||a.value?void 0:r.value),refetch:c}}function c7(e,t){const n=ft(e);if(!n)throw Error("Cannot create public viem client");const s=()=>hR(t,n),r=()=>ER(n,t),o=St({abi:st,address:qi,client:n});return{id:"ucrv2",name:"Curve V2",logo:rr,symbol:"cvxCRV",description:"description-ucrv",asset:ls,contract:o,swapDeposit:{buy:"cvxCRV",sell:"ETH"},swapWithdraw:{buy:"ETH",sell:"cvxCRV"},distributor:A4,getPriceUnderlying:s,getApy:r,lp:null}}function u7(e,t){const n=ft(e);if(!n)throw Error("Cannot create public viem client");const s=()=>V_(t,n),r=()=>TR(n,t),o=St({abi:st,address:zr,client:n});return{id:"ucrv",name:"Curve",logo:rr,symbol:"cvxCRV",description:"description-ucrv",asset:ls,contract:o,swapDeposit:{buy:"cvxCRV",sell:"ETH"},swapWithdraw:{buy:"ETH",sell:"cvxCRV"},distributor:zl,getPriceUnderlying:s,getApy:r,lp:null}}const O6="/assets/cvxfxs-mzEpa4jt.png";function l7(e,t){const n=ft(e);if(!n)throw Error("Cannot create public viem client");const s=()=>Vo(t,n),r=()=>kR(n,t),o=St({abi:st,address:Ks,client:n});return{id:"ufxs",name:"Frax",logo:O6,symbol:"cvxFXS",description:"description-ufxs",asset:$r,contract:o,swapDeposit:{buy:"cvxFXS",sell:"ETH"},swapWithdraw:{buy:"ETH",sell:"cvxFXS"},distributor:ql,getPriceUnderlying:s,getApy:r,lp:null}}function d7(e,t){const n=ft(e);if(!n)throw Error("Cannot create public viem client");const s=()=>Wi(t,n),r=()=>SR(),o=()=>Jr(e,{abi:Or,address:Sh,functionName:"price_oracle"}).then(a=>Ie(a,18n)),i=St({abi:st,address:_o,client:n});return{id:"ufxslp",name:"Frax LP",logo:O6,symbol:"cvxFXSFXS-f",description:"description-ufxslp",asset:$r,contract:i,distributor:T4,getPriceUnderlying:s,getApy:r,lp:{symbolPrimary:"FXS",getOraclePrice:o}}}const Fo="data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M16%2032C24.8366%2032%2032%2024.8366%2032%2016C32%207.16344%2024.8366%200%2016%200C7.16344%200%200%207.16344%200%2016C0%2024.8366%207.16344%2032%2016%2032Z'%20fill='white'/%3e%3cpath%20d='M25.188%2013.502V8.50195H22.688V6.00195H17.689V3.50195H12.689V6.00195H7.68896V8.50195H5.18896V23.501H7.68896V26.001H12.689V28.5H17.688V26.001H22.688V23.501H25.188V18.501H20.189V21.001H17.689V23.501H12.689V21.001H10.191V11.002H12.691V8.50195H17.69V11.002H20.19V13.502H25.188Z'%20fill='url(%23paint0_linear_103_2)'/%3e%3cpath%20d='M19.43%208.37598H17.689V11.001H19.43V8.37598Z'%20fill='%231682FE'/%3e%3cpath%20d='M14.4261%203.5H12.6851V6.125H14.4261V3.5Z'%20fill='%231682FE'/%3e%3cpath%20d='M9.42801%206H7.68701V8.625H9.42801V6Z'%20fill='%2360D8A4'/%3e%3cpath%20d='M6.94504%2016H5.18604V23.499H6.94504V16Z'%20fill='%23F4BB3B'/%3e%3cpath%20d='M6.94504%208.50195H5.18604V16.001H6.94504V8.50195Z'%20fill='%2360D8A4'/%3e%3cpath%20d='M21.928%2010.875H20.187V13.5H21.928V10.875Z'%20fill='%231682FE'/%3e%3cpath%20d='M21.927%2018.5H20.186V21.125H21.927V18.5Z'%20fill='%23FF5A5A'/%3e%3cpath%20d='M19.43%2021H17.689V23.625H19.43V21Z'%20fill='%23FF5A5A'/%3e%3cpath%20d='M14.427%2025.874H12.686V28.499H14.427V25.874Z'%20fill='%23FF5A5A'/%3e%3cpath%20d='M9.42704%2023.375H7.68604V26H9.42704V23.375Z'%20fill='%23F4BB3B'/%3e%3cpath%20d='M26.814%2013.5V8.5H24.313V6H19.314V3.5H14.314V6H9.31399V8.5H6.81299V23.5H9.31299V26H14.312V28.499H19.312V26H24.313V23.5H26.814V18.5H21.814V21H19.314V23.5H14.314V21H11.814V11H14.314V8.5H19.314V11H21.814V13.5H26.814Z'%20fill='%233A3A3A'/%3e%3cdefs%3e%3clinearGradient%20id='paint0_linear_103_2'%20x1='19.088'%20y1='6.47714'%20x2='7.19692'%20y2='25.055'%20gradientUnits='userSpaceOnUse'%3e%3cstop%20stop-color='%231682FE'/%3e%3cstop%20offset='0.3'%20stop-color='%2360D8A4'/%3e%3cstop%20offset='0.7'%20stop-color='%23FCA75B'/%3e%3cstop%20offset='1'%20stop-color='%23FF5A5A'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e";function L6(e,t,n){const s=ft(e);if(!s)throw Error("Cannot create public viem client");const r=()=>Xl(t,s),o=()=>AR(n),i=St({abi:Fc,address:ys,client:s});return{id:"ucvx",name:"Convex (Pirex)",logo:Fo,symbol:"pxCVX",description:"description-ucvx",asset:js,contract:i,distributor:Wl,swapDeposit:{buy:"CVX",sell:"ETH"},swapWithdraw:{buy:"ETH",sell:"CVX"},getPriceUnderlying:r,getApy:o,lp:null}}const qh="/assets/aurabal-Bc0LsDHv.png";function f7(e,t){const n=ft(e);if(!n)throw Error("Cannot create public viem client");const s=()=>bR(t),r=()=>PR(t),o=St({abi:st,address:$o,client:n});return{id:"ubal",name:"Balancer",logo:qh,symbol:"auraBAL",description:"description-ubal",asset:ci,contract:o,swapDeposit:{buy:"auraBAL",sell:"ETH"},swapWithdraw:{buy:"ETH",sell:"auraBAL"},getPriceUnderlying:s,getApy:r,lp:null}}function p7(e,t){const n=ft(e);if(!n)throw Error("Cannot create public viem client");const s=()=>$h(t,n),r=()=>IR(n,t),o=St({abi:st,address:qr,client:n});return{id:"uprisma",name:"Prisma",logo:Oo,symbol:"cvxPRISMA",description:"description-uprisma",asset:Au,contract:o,swapDeposit:{buy:"cvxPRISMA",sell:"ETH"},swapWithdraw:{buy:"ETH",sell:"cvxPRISMA"},distributor:Gl,getPriceUnderlying:s,getApy:r,lp:null}}async function sd(e,t,n){const s=e(),r=t(),o=n();if(!o||!r)return;const i=[BigInt(o.claim.index),r,o.amount,o.claim.proof],a=await Le(s,{abi:dc,address:o.distributorAddress,functionName:"claim",args:i});return Oe(s,{hash:a})}function Bn(e,t,n){const s=e(),r=t();return!r||!n?Promise.resolve(void 0):Jr(s,{abi:dn,address:n,functionName:"balanceOf",args:[r]})}function Dn(e,t){const n=e();return t?Jr(n,{abi:dn,address:t,functionName:"decimals"}).then(s=>BigInt(s)):Promise.resolve(void 0)}function Zs(e,t,n,s){const r=$t(t/n*(1-s),24n),o=10n**24n;return e*r/o}function m7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct deposit zaps");await Et(i,ls,a,qi,c);const l=await Le(i,{abi:st,address:qi,functionName:"deposit",args:[a,c]});return Oe(i,{hash:l})};return[{logo:rr,label:"cvxCRV",zap:()=>s(),depositSymbol:"cvxCRV",depositBalance:()=>Bn(e,t,ls),depositDecimals:()=>Dn(e,ls)}]}function h7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct withdraw zaps");const l=await Le(i,{abi:st,address:qi,functionName:"withdraw",args:[a,c]});return Oe(i,{hash:l})};return[{logo:rr,label:"cvxCRV",withdrawSymbol:"cvxCRV",withdrawDecimals:()=>Promise.resolve(18n),zap:()=>s()}]}function y7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct deposit zaps");await Et(i,ls,a,zr,c);const l=await Le(i,{abi:st,address:zr,functionName:"deposit",args:[a,c]});return Oe(i,{hash:l})};return[{logo:rr,label:"cvxCRV",zap:()=>s(),depositSymbol:"cvxCRV",depositBalance:()=>Bn(e,t,ls),depositDecimals:()=>Dn(e,ls)}]}function b7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct withdraw zaps");const l=await Le(i,{abi:st,address:zr,functionName:"withdraw",args:[a,c]});return Oe(i,{hash:l})};return[{logo:rr,label:"cvxCRV",withdrawSymbol:"cvxCRV",withdrawDecimals:()=>Promise.resolve(18n),zap:()=>s()}]}const g7=[{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAndStakeIn3PoolConvex",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"claimFromDistributorAsCvx",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsEth",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsUnderlying",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}],rd="/assets/airforce-DvH2fKPr.png";function v7(e,t,n){const s=async()=>{const a=e(),c=t(),u=n();if(!c||!u)throw new Error("Unable to construct extra claim zaps");await Et(a,zr,c,Lp,u.amount);const l=[BigInt(u.claim.index),c,u.amount,u.claim.proof,c],d=await Le(a,{abi:g7,address:Lp,functionName:"claimFromDistributorAsUnderlying",args:l});return Oe(a,{hash:d})};return[{logo:rd,label:"uCRV",withdrawSymbol:"uCRV",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:()=>sd(e,t,n)},{logo:rr,label:"cvxCRV",withdrawSymbol:"cvxCRV",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:()=>s()}]}const fs="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAYAAACqaXHeAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAHBhaW50Lm5ldCA0LjAuMTM0A1t6AAAHKklEQVR4XuWbSWgVSxSGTaImDmgCijghoiaIKxWnh6AbccSFOBviTlBcPhB0ISLRhUbyNgq6cUIF0YAgxoUoCHmaOGwEfU8cNkZFgxr0Kqg57//rniK+m+qbHqpvcvGDw73dXXXqnNPd1dWnqgekTVdX1wTIWkg95DLkAaT958+fGUiXSob79BjL1P/48WMdfieomuJBREpg+B9w6gjkH2wngjqg7wh1YrNEm+l/wLhKGPknDH5qLE8B6mYb+FupzfY9MKYKhh2AYZ+MlQUAbXVCDuBvlZpReNB4GYzYAekwVvUBCHwHbcDfMjWrMKDRasjfWTP6HtjS8u3btxo1L13QO29Fg5+17X4DbYLUqZn+QRu85P/KNtd/URv93hJQWAHFTaaFIkBtrVDzk0FFUNhsNBcRanOyIEABL/uiOfO5qO3xbwcoiHTPf/jwQT5+/Khb/qFuthEF+qDuRIO9veoIBY2bO3euzJs3L5UgUOf8+fNNGzGCEO3pgAo1kNCPOhpEw1DViO8gWOet/jlz5kQKAn2BVKNu76A87/vQgxx75ln1V4lzplzkOm8lRhBa8FOKuvlBQQ4tQxHkvJUgI79//y5v3ryR58+fy4sXL+Tdu3eCW06PdhPkvBW2zTJhoW+oFwzKVKFQ6LE9hp+ycuVKp3FWGITXr1/LhQsXZMuWLTJt2jQpKyvrUW7gwIFSXV1typw7d07a29vzOk9h27QhLPDtPX6CX6BQgG9YkQgThNLSUuf+fFJSUuLcbyWq8xb4WI/6PcExvs93ZotFI0wQfEpc5wl85Gt7z3wCDjDREJtCBWHFihWxnbfQV+jqBvtKfGRy0g6CD+cJAvAvfrrTa9jBfJsXvnz5IhUVFU4H2Bds2LBBLl68KI8fPza9/9u3b6WtrU0OHTokkyZNctajsE9gx+gL+LwAerNg44juT8zt27edDgwZMkRu3ryppdx0dnbKwoULnfUpJ06c0JLJgc8N0JkFl3/i7K2lsbHRafzWreFG1hwXDBo0yKlj06ZNWio5CMAT6DRnf4Lu88LevXudxu/YEXp8Ze51l47Zs2drCT/A9/F86Vmn2144fPiw0/jRo0eHvoevX78ue/bskf379xt9R48elVOnTsm1a9e0hB8QgLW8Aup12ws00hUAyrhx4+T48ePy+XP/SCnSdwbgsm57IZPJyMiRI50BsDJ8+HBZv369nDx5Ul69eqU1Cw98v8QAPNBtb+zevdvpeJDU1NTI9u3bpampyTwJCgV8v88A+Hu4KhwLzJgxw+lsb1JeXm4GU3wh8jHoyQeefu0MQEa3vfLy5UuZOnWq08mwYvsM2Kha/YIAZDgGSEc76OjokI0bNzqdiyKrV682V5Vv6HuqAbDcvXvXDGKChshhZOnSpc6kSRJMANK6BVwwe3P27FnzPjBq1Cino/nk4MGDqskP5hZIoxMMAxqXhw8fSkNDgyxfvlyGDRvmdPpXGTFihHz65G8WHjaYTtD7YzAOX79+lStXrphL3eW8lTNnzmiN5MB38xj0OhDKhWcsanaYPb/LeUqUd4regO9mIORtKMxnN0d4fKWdMmWKDB061BhdW1urJcKzePHiHs5TVq1apSWSg1ug3uvL0L59+5xGjxkzxqTCo7Bt2zanriVLlmiJ5ODkm5chb6/Dzc3NTqMpvDqisGzZMqeeNWvWaInkwPfx0GlyAk90XyL4IhTUm0+cOFHev2davndaW1udcweUXbt2aalk0Gfoy4J7wVtKrK6uzmk4ZdasWfL0af7c6507d2Ts2LHO+pQbN25oyWQgAN0pMWx4S4ry7EFloAwePFg2b94sp0+flpaWFjMWuHXrlhw7dswMefNNokyfPt2MH3wAn7uTotj2lhbnoIYq05BFixalkxYn2JloYoQDmTSdt5JkVsiCJ9//J0YI9lfiKog9NVYI560kmSDBiXZPjREcjDU52pvzQT16EokbBPjonhwlOM51v5Gmx4NS2FY4xc21AOfPnzed3+TJkwNnfpkNmjlzpuzcuVOuXr3a6/R41CDA+fzT4wSFvC2QoAOuBQwcLzx79sw8Ae7duyePHj0yKfPcHt73Agnc+/kXSBCU4xIZLicJRVAQaLiPV9egIMRYHRJuiQxBYS6GDp28zw2CL+ctuUGI4Xz4RVIWVKjT+qGwQfDtvIU6qTuq84S+qFvRwD0ZaaEkDYtqXBQYhBjON6o70UH9ol4qixOYbKksgYLfd7G0hYo0mkWB2urHeQsUFssHE434Se8bIjRQB/n9Ppn5FTTEcULowVLa0BbapOYVBrRbikb52Vy4PFcKsG3agL/hRnhpgMa5vpjfBfsf/QTAttgm/vbdh5O5wJhKJhpgGLMtqUDdkP716WwuMI4fTy+ANEASZ5upQ3UtwGb//Xg6CBg+HmI/n78EuY/ndI/P57mPx7QMy7JONm+fGgMG/Af6GQYJf6VvigAAAABJRU5ErkJggg==";function w7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct deposit zaps");await Et(i,$r,a,Ks,c);const l=await Le(i,{abi:st,address:Ks,functionName:"deposit",args:[a,c]});return Oe(i,{hash:l})};return[{logo:fs,label:"cvxFXS",zap:()=>s(),depositSymbol:"cvxFXS",depositBalance:()=>Bn(e,t,$r),depositDecimals:()=>Dn(e,$r)}]}function _7(e,t,n){const s=e(),r=async()=>{const a=t(),c=n();if(!a||!c)throw new Error("Unable to construct withdraw zaps");const l=await Le(s,{abi:st,address:Ks,functionName:"withdraw",args:[a,c]});return Oe(s,{hash:l})};return[{logo:fs,label:"cvxFXS",withdrawSymbol:"cvxFXS",withdrawDecimals:()=>Promise.resolve(18n),zap:()=>r()}]}const x7=[{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"claimFromDistributorAsCvx",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsEth",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsFxs",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsUnderlying",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}];async function C7(e,t){const n=ft(t);if(!n)throw Error("Cannot create public viem client");const s=await Vo(e,n).then(a=>a).catch(()=>1/0),r=St({abi:st,address:Ks,client:n}),o=await eo(r);return s*o}function A7(e,t,n){const s=async a=>{const c=e(),u=t(),l=n();if(!u||!l)throw new Error("Unable to construct extra claim zaps");await Et(c,Ks,u,Np,l.amount);const d=[BigInt(l.claim.index),u,l.amount,l.claim.proof,a,u],f=await Le(c,{abi:x7,address:Np,functionName:"claimFromDistributorAsUnderlying",args:d});return Oe(c,{hash:f})};return[{logo:rd,label:"uFXS",withdrawSymbol:"uFXS",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:()=>sd(e,t,n)},{logo:fs,label:"cvxFXS",withdrawSymbol:"cvxFXS",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:a=>s(a??0n),getMinAmountOut:async(a,c,u)=>{const l=new pn,d=e(),f=ft(d);if(!f)throw Error("Cannot create public viem client");const p=await Vo(l,f).then(h=>h).catch(()=>1/0),m=await C7(l,d);return Zs(c,m,p,u)}}]}const Fa=[{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"claimFromVaultAsCvx",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsEth",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"assetIndex",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsUnderlying",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromEth",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"uint256[2]",name:"amounts",type:"uint256[2]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromUnderlyingAssets",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"inputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"depositViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"lpTokenAmount",type:"uint256"},{internalType:"uint256",name:"crvAmount",type:"uint256"},{internalType:"uint256",name:"cvxAmount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositWithRewards",outputs:[],stateMutability:"nonpayable",type:"function"}];function T7(e,t,n){const s=async l=>{const d=e(),f=t(),p=n();if(!f||!p)throw new Error("Unable to construct deposit zaps");await Et(d,is,f,os,p);const h=await Le(d,{abi:Fa,address:os,functionName:"claimFromVaultAsUnderlying",args:[p,0n,l,f]});return Oe(d,{hash:h})},r=async l=>{const d=e(),f=t(),p=n();if(!f||!p)throw new Error("Unable to construct deposit zaps");await Et(d,$r,f,os,p);const h=await Le(d,{abi:Fa,address:os,functionName:"claimFromVaultAsUnderlying",args:[0n,p,l,f]});return Oe(d,{hash:h})},o=async()=>{const l=e(),d=t(),f=n();if(!d||!f)throw new Error("Unable to construct deposit zaps");await Et(l,Tu,d,os,f);const m=await Le(l,{abi:Fa,address:os,functionName:"depositWithRewards",args:[f,0n,0n,0n,d]});return Oe(l,{hash:m})};return[{logo:fs,label:"FXS",zap:l=>s(l??0n),depositSymbol:"FXS",depositBalance:()=>Bn(e,t,is),depositDecimals:()=>Dn(e,is),getMinAmountOut:async(l,d,f)=>{const p=new pn,m=e(),h=ft(m);if(!h)throw Error("Cannot create public viem client");const y=await p.getPrice(is).then(g=>g.price).catch(()=>1/0),b=await Wi(p,h).then(g=>g).catch(()=>1/0);return Zs(d,y,b,f)}},{logo:fs,label:"cvxFXS",zap:l=>r(l??0n),depositSymbol:"cvxFXS",depositBalance:()=>Bn(e,t,$r),depositDecimals:()=>Dn(e,$r),getMinAmountOut:async(l,d,f)=>{const p=new pn,m=e(),h=ft(m);if(!h)throw Error("Cannot create public viem client");const y=await Vo(p,h).then(g=>g).catch(()=>1/0),b=await Wi(p,h).then(g=>g).catch(()=>1/0);return Zs(d,y,b,f)}},{logo:fs,label:"cvxFXS LP token",zap:()=>o(),depositSymbol:"cvxFXSFXS-f",depositBalance:()=>Bn(e,t,Tu),depositDecimals:()=>Dn(e,Tu)}]}function E7(e,t,n){const s=async l=>{const d=e(),f=t(),p=n();if(!f||!p)throw new Error("Unable to construct withdraw zaps");await Et(d,_o,f,os,p);const h=await Le(d,{abi:Fa,address:os,functionName:"claimFromVaultAsUnderlying",args:[p,0n,l,f]});return Oe(d,{hash:h})},r=async l=>{const d=e(),f=t(),p=n();if(!f||!p)throw new Error("Unable to construct withdraw zaps");await Et(d,_o,f,os,p);const h=await Le(d,{abi:Fa,address:os,functionName:"claimFromVaultAsUnderlying",args:[p,1n,l,f]});return Oe(d,{hash:h})},o=async()=>{const l=e(),d=t(),f=n();if(!d||!f)throw new Error("Unable to construct withdraw zaps");const m=await Le(l,{abi:st,address:_o,functionName:"withdraw",args:[d,f]});return Oe(l,{hash:m})};return[{logo:fs,label:"FXS",withdrawSymbol:"FXS",withdrawDecimals:()=>Promise.resolve(18n),zap:l=>s(l??0n),getMinAmountOut:async(l,d,f)=>{const p=new pn,m=e(),h=ft(m);if(!h)throw Error("Cannot create public viem client");const y=await p.getPrice(is).then(g=>g.price).catch(()=>1/0),b=await Wi(p,h).then(g=>g).catch(()=>1/0);return Zs(d,b,y,f)}},{logo:fs,label:"cvxFXS",withdrawSymbol:"cvxFXS",withdrawDecimals:()=>Promise.resolve(18n),zap:l=>r(l??0n),getMinAmountOut:async(l,d,f)=>{const p=new pn,m=e(),h=ft(m);if(!h)throw Error("Cannot create public viem client");const y=await Vo(p,h).then(g=>g).catch(()=>1/0),b=await Wi(p,h).then(g=>g).catch(()=>1/0);return Zs(d,b,y,f)}},{logo:fs,label:"cvxFXS LP token",withdrawSymbol:"cvxFXSFXS-f",withdrawDecimals:()=>Promise.resolve(18n),zap:()=>o()}]}const F6=[{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsCrv",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsCvx",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsCvxCrv",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsEth",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositFromCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositFromCvx",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositFromCvxCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositFromEth",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"inputToken",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}];async function S7(e,t){const n=await Jr(e,{abi:Or,address:Ph,functionName:"get_dy",args:[0n,1n,t]});return t>=n}function N6(e,t,n){const s=async()=>{const c=e(),u=t(),l=n();if(!u||!l)throw new Error("Unable to construct deposit zaps");await Et(c,js,u,ys,l);const f=await Le(c,{abi:Fc,address:ys,functionName:"deposit",args:[l,u]});return Oe(c,{hash:f})},r=async c=>{const u=e(),l=t(),d=n();if(!l||!d)throw new Error("Unable to construct deposit zaps");await Et(u,An,l,cc,d);const f=await S7(u,d),m=await Le(u,{abi:F6,address:cc,functionName:"depositFromCvx",args:[d,c,l,f]});return Oe(u,{hash:m})};return[{logo:Fo,label:"CVX",zap:c=>r(c??0n),depositSymbol:"CVX",depositBalance:()=>Bn(e,t,An),depositDecimals:()=>Dn(e,An),getMinAmountOut:async(c,u,l)=>{const d=new pn,f=e(),p=ft(f);if(!p)throw Error("Cannot create public viem client");const m=await d.getPrice(An).then(y=>y.price).catch(()=>1/0),h=await Xl(d,p).then(y=>y).catch(()=>1/0);return Zs(u,m,h,l)}},{logo:Fo,label:"pxCVX",zap:()=>s(),depositSymbol:"pxCVX",depositBalance:()=>Bn(e,t,js),depositDecimals:()=>Dn(e,js)}]}async function B6(e,t){const n=ft(t);if(!n)return 0;const s=await Xl(e,n).then(a=>a).catch(()=>1/0),r=St({abi:Fc,address:ys,client:n}),o=await eo(r);return s*o}function D6(e,t,n){const s=async()=>{const c=e(),u=t(),l=n();if(!u||!l)throw new Error("Unable to construct withdraw zaps");const f=await Le(c,{abi:Fc,address:ys,functionName:"redeem",args:[l,u,u]});return Oe(c,{hash:f})},r=async c=>{const u=e(),l=t(),d=n();if(!l||!d)throw new Error("Unable to construct withdraw zaps");await Et(u,ys,l,cc,d);const p=await Le(u,{abi:F6,address:cc,functionName:"claimFromVaultAsCvx",args:[d,c,l]});return Oe(u,{hash:p})};return[{logo:Fo,label:"CVX",withdrawSymbol:"CVX",withdrawDecimals:()=>Promise.resolve(18n),zap:c=>r(c??0n),getMinAmountOut:async(c,u,l)=>{const d=new pn,f=await d.getPrice(An).then(m=>m.price).catch(()=>1/0),p=await B6(d,e());return Zs(u,p,f,l)}},{logo:Fo,label:"pxCVX",withdrawSymbol:"pxCVX",withdrawDecimals:()=>Promise.resolve(18n),zap:()=>s()}]}const P7=[{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsCvx",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsCvxCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsEth",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}];function k7(e,t,n){const s=async a=>{const c=e(),u=t(),l=n();if(!u||!l)throw new Error("Unable to construct extra claim zaps");await Et(c,ys,u,Bp,l.amount);const d=[BigInt(l.claim.index),u,l.amount,l.claim.proof,a,u],f=await Le(c,{abi:P7,address:Bp,functionName:"claimFromDistributorAsCvx",args:d});return Oe(c,{hash:f})};return[{logo:Fo,label:"CVX",withdrawSymbol:"CVX",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:a=>s(a??0n),getMinAmountOut:async(a,c,u)=>{const l=new pn,d=await l.getPrice(An).then(p=>p.price).catch(()=>1/0),f=await B6(l,e());return Zs(c,f,d,u)}},{logo:rd,label:"uCVX",withdrawSymbol:"uCVX",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:()=>sd(e,t,n)}]}function I7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct deposit zaps");await Et(i,ci,a,$o,c);const l=await Le(i,{abi:st,address:$o,functionName:"deposit",args:[a,c]});return Oe(i,{hash:l})};return[{logo:qh,label:"auraBAL",zap:()=>s(),depositBalance:()=>Bn(e,t,ci),depositDecimals:()=>Dn(e,ci),depositSymbol:"auraBAL"}]}function R7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct withdraw zaps");const l=await Le(i,{abi:st,address:$o,functionName:"withdraw",args:[a,c]});return Oe(i,{hash:l})};return[{logo:qh,label:"auraBAL",withdrawSymbol:"auraBAL",withdrawDecimals:()=>Promise.resolve(18n),zap:()=>s()}]}const U6=[{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"migrate",outputs:[],stateMutability:"nonpayable",type:"function"}];function $7(e,t,n){const s=async()=>{const c=e(),u=t(),l=n();if(!u||!l)throw new Error("Unable to construct deposit zaps");await Et(c,Au,u,qr,l);const f=await Le(c,{abi:st,address:qr,functionName:"deposit",args:[u,l]});return Oe(c,{hash:f})},r=async()=>{const c=e(),u=t(),l=n();if(!u||!l)throw new Error("Unable to construct deposit zaps");await Et(c,Ia,u,Qu,l);const f=await Le(c,{abi:U6,address:Qu,functionName:"migrate",args:[l,u]});return Oe(c,{hash:f})};return[{logo:Oo,label:"cvxPRISMA",zap:()=>s(),depositSymbol:"cvxPRISMA",depositBalance:()=>Bn(e,t,Au),depositDecimals:()=>Dn(e,Au)},{logo:Oo,label:"Migrate from Convex",zap:()=>r(),depositSymbol:"stkCvxPRISMA",depositBalance:()=>Bn(e,t,Ia),depositDecimals:()=>Dn(e,Ia)}]}function M7(e,t,n){const s=async()=>{const i=e(),a=t(),c=n();if(!a||!c)throw new Error("Unable to construct withdraw zaps");const l=await Le(i,{abi:st,address:qr,functionName:"withdraw",args:[a,c]});return Oe(i,{hash:l})};return[{logo:Oo,label:"cvxPRISMA",withdrawSymbol:"cvxPRISMA",withdrawDecimals:()=>Promise.resolve(18n),zap:()=>s()}]}const O7=[{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsEth",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsPrisma",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsUnderlying",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"index",type:"uint256"},{internalType:"address",name:"account",type:"address"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"bytes32[]",name:"merkleProof",type:"bytes32[]"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromDistributorViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}];function L7(e,t,n){const s=async()=>{const a=e(),c=t(),u=n();if(!c||!u)throw new Error("Unable to construct extra claim zaps");await Et(a,qr,c,Dp,u.amount);const l=[BigInt(u.claim.index),c,u.amount,u.claim.proof,c],d=await Le(a,{abi:O7,address:Dp,functionName:"claimFromDistributorAsUnderlying",args:l});return Oe(a,{hash:d})};return[{logo:rd,label:"uPRISMA",withdrawSymbol:"uPRISMA",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:()=>sd(e,t,n)},{logo:Oo,label:"cvxPRISMA",withdrawSymbol:"cvxPRISMA",withdrawDecimals:()=>Promise.resolve(18n),claimBalance:()=>{var a;return Promise.resolve(((a=n())==null?void 0:a.amount)??0n)},zap:()=>s()}]}const F7={class:"pool"},N7={class:"pool-data"},B7=["src"],D7={class:"name"},U7={key:0},V7=ae({__name:"Pool",props:{name:{},logo:{},symbol:{},priceUnderlying:{}},setup(e){return(t,n)=>{const s=Pt,r=jo;return F(),J("div",F7,[$(r,null,{trigger:Y(()=>[T("div",N7,[T("img",{class:"logo",src:t.logo},null,8,B7),T("span",D7,Z(t.name),1)])]),default:Y(()=>[t.priceUnderlying?(F(),J("span",U7,[we(Z(t.symbol)+": ",1),$(s,{"show-zero":"",type:"dollar",value:t.priceUnderlying,precision:3},null,8,["value"])])):ye("",!0)]),_:1})])}}}),j7=pe(V7,[["__scopeId","data-v-2d2b6c37"]]),H7={class:"balance"},z7={class:"value"},q7={class:"value-tooltip"},W7={class:"underlying"},G7={style:{display:"flex",gap:"0.5rem","justify-content":"end"}},X7={key:0},K7={key:0},Q7={style:{display:"flex",gap:"0.5rem","justify-content":"end"}},Z7={key:0},Y7={class:"label"},od=ae({__name:"Balance",props:{symbol:{},state:{}},setup(e){const{t}=Me(),n=M(()=>{const{balanceWithdraw:i,balanceUnclaimed:a,priceUnderlying:c,priceShare:u,decimalsDeposit:l}=e.state;if(c===void 0||u===void 0||i===void 0&&a===void 0)return;const d=(i??0n)+(a??0n);return Ie(d,l)*c*u}),s=M(()=>{const{balanceWithdraw:i,priceShare:a,decimalsDeposit:c}=e.state;if(!(i===void 0||a===void 0))return Ie(i,c)*a}),r=M(()=>{const{balanceUnclaimed:i,priceShare:a,decimalsDeposit:c}=e.state;if(!(i===void 0||a===void 0))return Ie(i,c)*a}),o=M(()=>e.state.balanceUnclaimed&&e.state.balanceUnclaimed>0n);return(i,a)=>{const c=Pt,u=jo;return F(),J("div",H7,[T("div",z7,[$(u,null,{trigger:Y(()=>[T("div",q7,[$(c,{"show-zero":"",type:"dollar",value:v(n),precision:1},null,8,["value"])])]),default:Y(()=>[T("ul",W7,[T("li",null,[T("div",null,Z(i.symbol)+":",1),T("div",G7,[T("div",null,Z((Math.round((v(s)||0)*1e3)/1e3).toFixed(3)),1),i.state.symbolLpPrimary?(F(),J("div",X7," (~"+Z((Math.round((v(s)||0)*2*1e3*(1-(1-i.state.oraclePrice)/2))/1e3).toFixed(3))+" "+Z(i.state.symbolLpPrimary)+") ",1)):ye("",!0)])]),v(o)?(F(),J("li",K7,[T("div",null,Z(i.symbol)+" (Union):",1),T("div",Q7,[T("div",null,Z((Math.round((v(r)||0)*1e3)/1e3).toFixed(3)),1),i.state.symbolLpPrimary?(F(),J("div",Z7," (~"+Z((Math.round((v(r)||0)*2*1e3*(1-(1-i.state.oraclePrice)/2))/1e3).toFixed(3))+" "+Z(i.state.symbolLpPrimary)+") ",1)):ye("",!0)])])):ye("",!0)])]),_:1})]),T("div",Y7,Z(v(t)("your-balance")),1)])}}});function Cg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"your-balance":{t:0,b:{t:2,i:[{t:3}],s:"Your Balance"}}}})}function Ag(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{"your-balance":{t:0,b:{t:2,i:[{t:3}],s:"你的余额"}}}})}function Tg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{"your-balance":{t:0,b:{t:2,i:[{t:3}],s:"Votre solde"}}}})}typeof Cg=="function"&&Cg(od);typeof Ag=="function"&&Ag(od);typeof Tg=="function"&&Tg(od);const J7=pe(od,[["__scopeId","data-v-6710b533"]]),eF={class:"apy"},tF={class:"value"},nF={class:"value-tooltip"},sF=["innerHTML"],rF={class:"fees"},oF={key:0},iF={key:1},aF={key:2},cF={class:"label"},id=ae({__name:"Apy",props:{apy:{},fees:{}},emits:["show"],setup(e,{emit:t}){const{t:n}=Me(),s=t;return(r,o)=>{const i=Pt,a=jo;return F(),J("div",eF,[T("div",tF,[$(a,{onShow:o[0]||(o[0]=c=>s("show",c))},{trigger:Y(()=>[T("div",nF,[$(i,{type:"percentage",value:r.apy,precision:2},null,8,["value"])])]),default:Y(()=>{var c,u,l,d,f,p;return[T("span",{class:"info",innerHTML:v(n)("apy-info")},null,8,sF),T("ul",rF,[((c=r.fees)==null?void 0:c.platform)!==0?(F(),J("li",oF,[T("div",null,Z(v(n)("fee-on-yield")),1),T("div",null,[$(i,{type:"percentage",value:(u=r.fees)==null?void 0:u.platform,precision:2},null,8,["value"])])])):ye("",!0),((l=r.fees)==null?void 0:l.caller)!==0?(F(),J("li",iF,[T("div",null,Z(v(n)("caller-incentive")),1),T("div",null,[$(i,{type:"percentage",value:(d=r.fees)==null?void 0:d.caller,precision:2},null,8,["value"])])])):ye("",!0),((f=r.fees)==null?void 0:f.withdrawal)!==0?(F(),J("li",aF,[T("div",null,Z(v(n)("withdrawal-fee")),1),T("div",null,[$(i,{type:"percentage",value:(p=r.fees)==null?void 0:p.withdrawal,precision:2},null,8,["value"])])])):ye("",!0)])]}),_:1})]),T("div",cF,Z(v(n)("apy")),1)])}}});function Eg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{apy:{t:0,b:{t:2,i:[{t:3}],s:"APY"}},"apy-info":{t:0,b:{t:2,i:[{t:3}],s:"APY calculation assumes weekly compounding<br />and excludes the following fees:"}},"fee-on-yield":{t:0,b:{t:2,i:[{t:3}],s:"Fee on yield:"}},"caller-incentive":{t:0,b:{t:2,i:[{t:3}],s:"Caller incentive (fee on yield):"}},"withdrawal-fee":{t:0,b:{t:2,i:[{t:3}],s:"Withdrawal fee (on total deposit):"}}}})}function Sg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{apy:{t:0,b:{t:2,i:[{t:3}],s:"APY"}},"apy-info":{t:0,b:{t:2,i:[{t:3}],s:"APY计算基于按周复投的计算<br />并排除了以下费用:"}},"fee-on-yield":{t:0,b:{t:2,i:[{t:3}],s:"收益费:"}},"caller-incentive":{t:0,b:{t:2,i:[{t:3}],s:"触发激励 (基于收益的费用):"}},"withdrawal-fee":{t:0,b:{t:2,i:[{t:3}],s:"提款费 (基于总存款的费用):"}}}})}function Pg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{apy:{t:0,b:{t:2,i:[{t:3}],s:"APY"}},"apy-info":{t:0,b:{t:2,i:[{t:3}],s:"Le calcul de l'APY suppose une capitalisation hebdomadaire<br />et exclut les frais suivants :"}},"fee-on-yield":{t:0,b:{t:2,i:[{t:3}],s:"Frais sur le rendement :"}},"caller-incentive":{t:0,b:{t:2,i:[{t:3}],s:"Incitatif pour l'appelant (frais sur le rendement) :"}},"withdrawal-fee":{t:0,b:{t:2,i:[{t:3}],s:"Frais de retrait (sur le dépôt total) :"}}}})}typeof Eg=="function"&&Eg(id);typeof Sg=="function"&&Sg(id);typeof Pg=="function"&&Pg(id);const uF=pe(id,[["__scopeId","data-v-514b79d4"]]),lF={class:"tvl"},dF={class:"value"},fF={class:"label"},ad=ae({__name:"Tvl",props:{state:{}},setup(e){const{t}=Me(),n=M(()=>{const{tvl:s,priceUnderlying:r,priceShare:o,decimalsWithdraw:i}=e.state;if(!(s===void 0||r===void 0||o===void 0))return Ie(s,i)*r*o});return(s,r)=>{const o=Pt;return F(),J("div",lF,[T("div",dF,[$(o,{"show-zero":"",type:"dollar",value:v(n),precision:1},null,8,["value"])]),T("div",fF,Z(v(t)("tvl")),1)])}}});function kg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{tvl:{t:0,b:{t:2,i:[{t:3}],s:"TVL"}}}})}function Ig(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{tvl:{t:0,b:{t:2,i:[{t:3}],s:"TVL"}}}})}function Rg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{tvl:{t:0,b:{t:2,i:[{t:3}],s:"TVL"}}}})}typeof kg=="function"&&kg(ad);typeof Ig=="function"&&Ig(ad);typeof Rg=="function"&&Rg(ad);const pF=pe(ad,[["__scopeId","data-v-4d36753c"]]),mF=ae({__name:"PounderSummary",props:{pounderId:{},expanded:{type:Boolean}},emits:["toggleExpand"],setup(e,{emit:t}){const n=t,s=Nc(),r=M(()=>s.pounders[e.pounderId]),o=M(()=>r.value.pounder),i=M(()=>r.value.state),a=le(void 0),c=le(!1);return Vi(c,async()=>{a.value=await i7(o.value.contract)}),(u,l)=>{const d=Ih;return F(),J("div",{class:"row",onClick:l[1]||(l[1]=f=>n("toggleExpand"))},[$(j7,{class:"pounder-item",name:v(o).name,logo:v(o).logo,symbol:v(o).symbol,"price-underlying":v(i).priceUnderlying},null,8,["name","logo","symbol","price-underlying"]),$(J7,{class:"pounder-item",symbol:v(o).symbol,state:v(i)},null,8,["symbol","state"]),$(uF,{class:"pounder-item",apy:v(i).apy,fees:v(a),onShow:l[0]||(l[0]=f=>c.value=!0)},null,8,["apy","fees"]),$(pF,{class:"pounder-item",state:v(i)},null,8,["state"]),T("div",{class:Pe(["pounder-item expander",{expanded:u.expanded}])},[$(d)],2)])}}}),hF=pe(mF,[["__scopeId","data-v-09a3b0f6"]]),yF={class:"modal-card"},bF={class:"buttons"},gF={key:1,class:"not-ready"},vF=ae({__name:"ModalYesNo",props:{show:{type:Boolean,default:!1},title:{default:""},ready:{type:Boolean,default:!0},readyMsg:{default:""}},emits:["yes","no"],setup(e,{emit:t}){const n=t;return(s,r)=>{const o=Mt,i=He,a=ia;return F(),fe(a,{show:s.show},{default:Y(()=>[$(i,{class:"modal-card",title:s.title},{default:Y(()=>[T("div",yF,[Ze(s.$slots,"default",{},void 0,!0),T("div",bF,[$(o,{class:"no",onClick:r[0]||(r[0]=c=>n("no"))},{default:Y(()=>r[2]||(r[2]=[we(" No ")])),_:1}),s.ready?(F(),fe(o,{key:0,class:"yes",onClick:r[1]||(r[1]=c=>n("yes"))},{default:Y(()=>r[3]||(r[3]=[we(" Yes ")])),_:1})):(F(),J("div",gF,Z(s.readyMsg),1))])])]),_:3},8,["title"])]),_:3},8,["show"])}}}),cd=pe(vF,[["__scopeId","data-v-16fa9929"]]),wF=["min","max"],_F=ae({__name:"Slider",props:ps({min:{},max:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=Do(e,"modelValue",{set(n){return Number(n)}});return(n,s)=>wm((F(),J("input",{"onUpdate:modelValue":s[0]||(s[0]=r=>t.value=r),type:"range",min:n.min,max:n.max},null,8,wF)),[[pw,t.value]])}}),ud=pe(_F,[["__scopeId","data-v-7d7044f5"]]),xF=["min","max"],CF=ae({__name:"InputNumber",props:ps({min:{default:()=>-1/0},max:{default:()=>1/0}},{modelValue:{required:!0,default:null},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const t=Do(e,"modelValue");return Ce(t,n=>{n===""?t.value=null:typeof n=="number"&&(t.value=Math.min(Math.max(n,e.min),e.max))}),(n,s)=>wm((F(),J("input",{"onUpdate:modelValue":s[0]||(s[0]=r=>t.value=r),type:"number",min:n.min,max:n.max},null,8,xF)),[[pw,t.value]])}}),ld=pe(CF,[["__scopeId","data-v-861d5729"]]),AF={class:"pounder-input"},TF={class:"input"},EF={class:"labels"},SF={class:"balance"},PF={class:"value"},dd=ae({__name:"PounderInput",props:{balance:{default:null},decimals:{},token:{},modelValue:{},price:{default:0}},emits:["update:modelValue"],setup(e,{emit:t}){const{t:n}=Me(),s=t,r=le(0),o=M(()=>{if(!e.balance||!e.decimals)return 0;const u=Ie(e.balance,e.decimals);return u>=.01?u:0}),i=M(()=>!r.value||!e.price?0:r.value*e.price),a=M(()=>1/10**8);Ce(r,u=>{try{typeof u=="string"&&(u=parseFloat(u)),s("update:modelValue",$t(u,e.decimals))}catch{}}),Ce(()=>e.modelValue,u=>{r.value=Ie(u,e.decimals)},{immediate:!0});const c=()=>{e.balance&&(r.value=Ie(e.balance,e.decimals))};return(u,l)=>{const d=Pt,f=ld,p=ud;return F(),J("div",AF,[T("div",TF,[T("div",EF,[T("div",SF,[T("div",PF,Z(v(n)("balance"))+" "+Z(v(o))+" "+Z(u.token),1),T("a",{class:"max",onClick:c},Z(v(n)("max")),1)]),T("div",{class:Pe(["dollars",{hide:u.price===0}])},[we(Z(v(n)("dollars"))+" ",1),$(d,{"show-zero":"",type:"dollar",value:v(i),precision:2},null,8,["value"])],2)]),$(f,{modelValue:v(r),"onUpdate:modelValue":l[0]||(l[0]=m=>$e(r)?r.value=m:null),min:0,max:v(o)},null,8,["modelValue","max"])]),$(p,{modelValue:v(r),"onUpdate:modelValue":l[1]||(l[1]=m=>$e(r)?r.value=m:null),class:"slider",min:0,max:v(o),step:v(a)},null,8,["modelValue","max","step"])])}}});function $g(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{balance:{t:0,b:{t:2,i:[{t:3}],s:"Balance:"}},max:{t:0,b:{t:2,i:[{t:3}],s:"Max"}},dollars:{t:0,b:{t:2,i:[{t:3}],s:"Dollars:"}}}})}function Mg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{balance:{t:0,b:{t:2,i:[{t:3}],s:"余额:"}},max:{t:0,b:{t:2,i:[{t:3}],s:"最大"}},dollars:{t:0,b:{t:2,i:[{t:3}],s:"美元:"}}}})}function Og(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{balance:{t:0,b:{t:2,i:[{t:3}],s:"Solde :"}},max:{t:0,b:{t:2,i:[{t:3}],s:"Max"}},dollars:{t:0,b:{t:2,i:[{t:3}],s:"Dollars :"}}}})}typeof $g=="function"&&$g(dd);typeof Mg=="function"&&Mg(dd);typeof Og=="function"&&Og(dd);const Lg=pe(dd,[["__scopeId","data-v-a9e69856"]]),kF={class:"option"},IF=["src"],RF={class:"label"},$F=ae({__name:"SelectZap",props:ps({zaps:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:ps(["select"],["update:modelValue"]),setup(e,{emit:t}){const n=Do(e,"modelValue"),s=t,r=i=>i,o=i=>{s("select",i)};return Ce(()=>e.zaps,()=>{e.zaps.length>0&&o(e.zaps[0])},{immediate:!0}),(i,a)=>{const c=ca;return F(),fe(c,{options:i.zaps,selected:n.value,onSelect:o},{option:Y(({option:u})=>[T("div",kF,[T("img",{src:r(u.logo??"")},null,8,IF),T("div",RF,Z(u.label??"?"),1)])]),_:1},8,["options","selected"])}}}),Xp=pe($F,[["__scopeId","data-v-0be4ff7f"]]),MF={class:"content"},OF={class:"slippage"},LF={style:{"grid-area":"info"},class:"info"},FF={style:{"grid-area":"label1"}},NF={style:{"grid-area":"percentage"}},BF={style:{"grid-area":"label2"}},DF={style:{"grid-area":"symbol"}},fd=ae({__name:"ModalSlippage",props:{show:{type:Boolean},symbolOutput:{},minAmountOutRef:{}},emits:["close","yes","no"],setup(e,{emit:t}){const{t:n}=Me(),s=t,r=le(.03),o=le(0);return Ce([r,()=>e.minAmountOutRef],([i])=>{o.value=e.minAmountOutRef*(1-i)}),Ce(()=>e.show,()=>{r.value=.03}),(i,a)=>{const c=ud,u=ld,l=cd;return F(),fe(l,{title:v(n)("price-modal-title"),show:i.show,ready:v(o)>0,"ready-msg":v(n)("no-zero"),onClose:a[2]||(a[2]=d=>s("close")),onYes:a[3]||(a[3]=d=>s("yes",v(o))),onNo:a[4]||(a[4]=d=>s("no"))},{default:Y(()=>[T("div",MF,[T("div",OF,[T("div",LF,Z(v(n)("slippage-info")),1),T("span",FF,Z(v(n)("percentage")),1),$(c,{modelValue:v(r),"onUpdate:modelValue":a[0]||(a[0]=d=>$e(r)?r.value=d:null),style:{"grid-area":"slider"},min:.001,max:.2,step:.001},null,8,["modelValue"]),T("span",NF,Z((Math.round(v(r)*100*1e3)/1e3).toFixed(2))+"% ",1),T("span",BF,Z(v(n)("min-amount")),1),$(u,{modelValue:v(o),"onUpdate:modelValue":a[1]||(a[1]=d=>$e(o)?o.value=d:null),style:{"grid-area":"input"},min:0,max:1/0},null,8,["modelValue"]),T("span",DF,Z(i.symbolOutput),1)])])]),_:1},8,["title","show","ready","ready-msg"])}}});function Fg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"price-modal-title":{t:0,b:{t:2,i:[{t:3}],s:"Price control"}},percentage:{t:0,b:{t:2,i:[{t:3}],s:"Percentage"}},"min-amount":{t:0,b:{t:2,i:[{t:3}],s:"Min Amount"}},"no-zero":{t:0,b:{t:2,i:[{t:3}],s:"Zero min amount not allowed"}},"slippage-info":{t:0,b:{t:2,i:[{t:3}],s:"Price control is a safeguard against excessive slippage or sandwich attacks. By setting a minimum percentage for your input, you establish a lower limit for your returns. If you encounter a slippage error, the value you set might be too low. A slight increase of one or two percent could help, but don't make it too high to ensure your protection."}}}})}function Ng(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{"price-modal-title":{t:0,b:{t:2,i:[{t:3}],s:"价格控制"}},percentage:{t:0,b:{t:2,i:[{t:3}],s:"百分比"}},"min-amount":{t:0,b:{t:2,i:[{t:3}],s:"最小数量"}},"no-zero":{t:0,b:{t:2,i:[{t:3}],s:"最小数量不能为0"}},"slippage-info":{t:0,b:{t:2,i:[{t:3}],s:"价格控制是防止过度滑点或夹心层攻击的一种保障措施。通过设定输入的最低百分比，可以为收益设定一个下限。如果您遇到滑点错误，您设定的值可能太低。稍微增加一到两个百分点可能会有帮助，但不要太高，以确保您的保护。"}}}})}function Bg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{"price-modal-title":{t:0,b:{t:2,i:[{t:3}],s:"Contrôle des prix"}},percentage:{t:0,b:{t:2,i:[{t:3}],s:"Pourcentage"}},"min-amount":{t:0,b:{t:2,i:[{t:3}],s:"Montant minimum"}},"no-zero":{t:0,b:{t:2,i:[{t:3}],s:"Montant minimum zéro non autorisé"}},"slippage-info":{t:0,b:{t:2,i:[{t:3}],s:"Le contrôle des prix est une protection contre les dérapages excessifs ou les attaques en sandwich. En fixant un pourcentage minimum pour vos intrants, vous établissez une limite inférieure pour vos retours. Si vous rencontrez une erreur de dérapage, la valeur que vous avez fixée est peut-être trop basse. Une légère augmentation d'un ou deux pour cent pourrait être utile, mais ne la fixez pas trop haut pour assurer votre protection."}}}})}typeof Fg=="function"&&Fg(fd);typeof Ng=="function"&&Ng(fd);typeof Bg=="function"&&Bg(fd);const Wh=pe(fd,[["__scopeId","data-v-39e43a28"]]);var Eu={};(function(e){var t=Object.defineProperty,n=(V,j,U)=>j in V?t(V,j,{enumerable:!0,configurable:!0,writable:!0,value:U}):V[j]=U,s=(V,j,U)=>(n(V,typeof j!="symbol"?j+"":j,U),U);Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});class r{constructor(j){this.key=j}postMessageToWindow(j,U,oe){const be=typeof oe=="object"?oe:{},P={key:this.key,method:U,...be};j.postMessage(P,"*")}listenToMessageFromWindow(j,U,oe){const be=P=>{!o(P.data)||P.data.key!==this.key||P.data.method!==U||oe(P.data)};return j.addEventListener("message",be),be}stopListeningToMessageFromWindow(j,U,oe){j.removeEventListener("message",oe)}stopListeningWindowListener(j,U){j.removeEventListener("message",U)}}function o(V){return typeof V=="object"&&V!==null&&"key"in V&&"method"in V&&typeof V.key=="string"&&typeof V.method=="string"}var i=(V=>(V.PROVIDER_RPC_REQUEST="PROVIDER_RPC_REQUEST",V.PROVIDER_RPC_RESPONSE="PROVIDER_RPC_RESPONSE",V.PROVIDER_ON_EVENT="PROVIDER_ON_EVENT",V))(i||{});const a=new r("cowSwapIframeRpcProviderTransport"),c=["connect","disconnect","close","chainChanged","accountsChanged"];class u{constructor(j){s(this,"ethereumProvider",null),s(this,"requestWaitingForConnection",{}),s(this,"processRpcCallFromWindow",({rpcRequest:U})=>{if(!this.ethereumProvider){U.id&&(this.requestWaitingForConnection[U.id]=U);return}this.processRpcRequest(U)}),this.iframeWidow=j}disconnect(){this.ethereumProvider=null,a.stopListeningToMessageFromWindow(window,i.PROVIDER_RPC_REQUEST,this.processRpcCallFromWindow)}onConnect(j){this.ethereumProvider?this.disconnect():a.listenToMessageFromWindow(window,i.PROVIDER_RPC_REQUEST,this.processRpcCallFromWindow),this.ethereumProvider=j,this.processPendingRequests(),c.forEach(U=>{j.on(U,oe=>this.onProviderEvent(U,oe))})}processPendingRequests(){Object.keys(this.requestWaitingForConnection).forEach(j=>{this.processRpcRequest(this.requestWaitingForConnection[j])}),this.requestWaitingForConnection={}}processRpcRequest(j){const{id:U,jsonrpc:oe,method:be}=j;!this.ethereumProvider||!U||(be==="enable"?this.ethereumProvider.enable():this.ethereumProvider.request({...j,id:U})).then(P=>this.forwardRpcResponseToIframe({rpcResponse:{jsonrpc:oe,id:U,result:P}})).catch(P=>this.forwardRpcResponseToIframe({rpcResponse:{jsonrpc:oe,id:U,error:P}}))}onProviderEvent(j,U){a.postMessageToWindow(this.iframeWidow,i.PROVIDER_ON_EVENT,{event:j,params:U})}forwardRpcResponseToIframe(j){a.postMessageToWindow(this.iframeWidow,i.PROVIDER_RPC_RESPONSE,j)}}var l={exports:{}};(function(V){var j=Object.prototype.hasOwnProperty,U="~";function oe(){}Object.create&&(oe.prototype=Object.create(null),new oe().__proto__||(U=!1));function be(K,G,E){this.fn=K,this.context=G,this.once=E||!1}function P(K,G,E,I,H){if(typeof E!="function")throw new TypeError("The listener must be a function");var W=new be(E,I||K,H),ee=U?U+G:G;return K._events[ee]?K._events[ee].fn?K._events[ee]=[K._events[ee],W]:K._events[ee].push(W):(K._events[ee]=W,K._eventsCount++),K}function O(K,G){--K._eventsCount===0?K._events=new oe:delete K._events[G]}function q(){this._events=new oe,this._eventsCount=0}q.prototype.eventNames=function(){var K=[],G,E;if(this._eventsCount===0)return K;for(E in G=this._events)j.call(G,E)&&K.push(U?E.slice(1):E);return Object.getOwnPropertySymbols?K.concat(Object.getOwnPropertySymbols(G)):K},q.prototype.listeners=function(K){var G=U?U+K:K,E=this._events[G];if(!E)return[];if(E.fn)return[E.fn];for(var I=0,H=E.length,W=new Array(H);I<H;I++)W[I]=E[I].fn;return W},q.prototype.listenerCount=function(K){var G=U?U+K:K,E=this._events[G];return E?E.fn?1:E.length:0},q.prototype.emit=function(K,G,E,I,H,W){var ee=U?U+K:K;if(!this._events[ee])return!1;var re=this._events[ee],D=arguments.length,Q,de;if(re.fn){switch(re.once&&this.removeListener(K,re.fn,void 0,!0),D){case 1:return re.fn.call(re.context),!0;case 2:return re.fn.call(re.context,G),!0;case 3:return re.fn.call(re.context,G,E),!0;case 4:return re.fn.call(re.context,G,E,I),!0;case 5:return re.fn.call(re.context,G,E,I,H),!0;case 6:return re.fn.call(re.context,G,E,I,H,W),!0}for(de=1,Q=new Array(D-1);de<D;de++)Q[de-1]=arguments[de];re.fn.apply(re.context,Q)}else{var ve=re.length,Ne;for(de=0;de<ve;de++)switch(re[de].once&&this.removeListener(K,re[de].fn,void 0,!0),D){case 1:re[de].fn.call(re[de].context);break;case 2:re[de].fn.call(re[de].context,G);break;case 3:re[de].fn.call(re[de].context,G,E);break;case 4:re[de].fn.call(re[de].context,G,E,I);break;default:if(!Q)for(Ne=1,Q=new Array(D-1);Ne<D;Ne++)Q[Ne-1]=arguments[Ne];re[de].fn.apply(re[de].context,Q)}}return!0},q.prototype.on=function(K,G,E){return P(this,K,G,E,!1)},q.prototype.once=function(K,G,E){return P(this,K,G,E,!0)},q.prototype.removeListener=function(K,G,E,I){var H=U?U+K:K;if(!this._events[H])return this;if(!G)return O(this,H),this;var W=this._events[H];if(W.fn)W.fn===G&&(!I||W.once)&&(!E||W.context===E)&&O(this,H);else{for(var ee=0,re=[],D=W.length;ee<D;ee++)(W[ee].fn!==G||I&&!W[ee].once||E&&W[ee].context!==E)&&re.push(W[ee]);re.length?this._events[H]=re.length===1?re[0]:re:O(this,H)}return this},q.prototype.removeAllListeners=function(K){var G;return K?(G=U?U+K:K,this._events[G]&&O(this,G)):(this._events=new oe,this._eventsCount=0),this},q.prototype.off=q.prototype.removeListener,q.prototype.addListener=q.prototype.on,q.prefixed=U,q.EventEmitter=q,V.exports=q})(l);class d{constructor(){s(this,"subscriptions",{})}on(j){const{event:U,handler:oe}=j;return this.subscriptions[U]||(this.subscriptions[U]=[]),this.subscriptions[U].push(oe),j}off(j){const{event:U,handler:oe}=j;return this.subscriptions[U]&&(this.subscriptions[U]=this.subscriptions[U].filter(be=>be!==oe)),j}emit(j,U){this.subscriptions[j]&&this.subscriptions[j].forEach(oe=>oe(U))}}var f=(V=>(V.ACTIVATE="ACTIVATE",V.UPDATE_HEIGHT="UPDATE_HEIGHT",V.SET_FULL_HEIGHT="SET_FULL_HEIGHT",V.EMIT_COW_EVENT="EMIT_COW_EVENT",V.PROVIDER_RPC_REQUEST="PROVIDER_RPC_REQUEST",V.INTERCEPT_WINDOW_OPEN="INTERCEPT_WINDOW_OPEN",V))(f||{}),p=(V=>(V.UPDATE_PARAMS="UPDATE_PARAMS",V.UPDATE_APP_DATA="UPDATE_APP_DATA",V.PROVIDER_RPC_RESPONSE="PROVIDER_RPC_RESPONSE",V.PROVIDER_ON_EVENT="PROVIDER_ON_EVENT",V))(p||{}),m=(V=>(V.SWAP="swap",V.LIMIT="limit",V.ADVANCED="advanced",V))(m||{});const h=["primary","background","paper","text","danger","warning","alert","info","success"],y=new r("cowSwapWidget");class b{constructor(j,U=[]){s(this,"eventEmitter",new d),s(this,"listeners",[]),s(this,"widgetListener"),this.contentWindow=j,this.updateListeners(U),this.widgetListener=y.listenToMessageFromWindow(this.contentWindow,f.EMIT_COW_EVENT,oe=>this.eventEmitter.emit(oe.event,oe.payload))}stopListeningIframe(){y.stopListeningWindowListener(this.contentWindow,this.widgetListener)}updateListeners(j){for(const U of this.listeners)this.eventEmitter.off(U);this.listeners=j||[];for(const U of this.listeners)this.eventEmitter.on(U)}}class g{constructor(j,U){s(this,"forwardSdkMessage"),this.appWindow=j,this.iframeWidow=U,this.forwardSdkMessage=oe=>{w(oe.data)&&oe.origin!==window.location.origin&&(_(oe.data)?this.appWindow.parent.postMessage(oe.data,"*"):A(oe.data)&&this.iframeWidow.postMessage(oe.data,"*"))},this.startListening()}startListening(){this.appWindow.addEventListener("message",this.forwardSdkMessage)}stopListening(){this.appWindow.removeEventListener("message",this.forwardSdkMessage)}}function w(V){return typeof V=="object"&&V!==null&&"id"in V&&typeof V.id=="string"}function _(V){return"method"in V&&typeof V.method=="string"&&"params"in V&&"env"in V&&typeof V.env=="object"&&V.env!==null&&"sdkVersion"in V.env}function A(V){return"success"in V&&typeof V.success=="boolean"&&"version"in V&&typeof V.version=="string"}function x(V){return!!(V&&typeof V=="object")}const C="_";function k(V){const j=typeof V.baseUrl=="string"?V.baseUrl:"https://swap.cow.fi",U=S(V);return j+"/#"+U+"?"+R(V)}function S(V){const{chainId:j=1,sell:U,buy:oe,tradeType:be=m.SWAP}=V,P=[(U==null?void 0:U.asset)||C,(oe==null?void 0:oe.asset)||C].map(encodeURIComponent).join("/");return`/${j}/widget/${be}/${P}`}function R(V){const j=new URLSearchParams;return L(B(j,V),V)}function B(V,j){const{sell:U,buy:oe}=j;return U!=null&&U.amount&&V.append("sellAmount",U.amount),oe!=null&&oe.amount&&V.append("buyAmount",oe.amount),V}function L(V,j){const U=j.theme;return U?(x(U)?(V.append("palette",encodeURIComponent(JSON.stringify(U))),V.append("theme",U.baseTheme)):(V.append("palette","null"),V.append("theme",U)),V):(V.append("palette","null"),V)}const X="640px",z="450px",ie=20;function ne(V,j){const{params:U,provider:oe,listeners:be}=j;let P=oe,O=U;const q=ce(U);V.innerHTML="",V.appendChild(q);const{contentWindow:K}=q;if(!K)throw console.error("Iframe does not contain a window",q),new Error("Iframe does not contain a window!");const G=[];G.push(_e(K,U.appCode)),G.push(...Ae(q,U.height)),G.push(Fe());const E=new b(window,be);let I=te(K,null,P);q.addEventListener("load",()=>he(K,O,P));const H=new g(window,K);return{updateParams:W=>{O=W,he(K,O,P)},updateListeners:W=>E.updateListeners(W),updateProvider:W=>{P=W,I=te(K,I,W)},destroy:()=>{I.disconnect(),E.stopListeningIframe(),G.forEach(W=>window.removeEventListener("message",W)),H.stopListening(),V.removeChild(q)}}}function te(V,j,U){j&&j.disconnect();const oe=j||new u(V);return U&&oe.onConnect(U),oe}function ce(V){const{width:j=z,height:U=X}=V,oe=document.createElement("iframe");return oe.src=k(V),oe.width=j,oe.height=U,oe.style.border="0",oe.allow="clipboard-read; clipboard-write",oe}function he(V,j,U){const oe=!!U,be=S(j),P=R(j).toString(),{theme:O,...q}=j;y.postMessageToWindow(V,p.UPDATE_PARAMS,{urlParams:{pathname:be,search:P},appParams:q,hasProvider:oe})}function _e(V,j){return y.listenToMessageFromWindow(window,f.ACTIVATE,()=>{y.postMessageToWindow(V,p.UPDATE_APP_DATA,{metaData:j?{appCode:j}:void 0})})}function Fe(){return y.listenToMessageFromWindow(window,f.INTERCEPT_WINDOW_OPEN,({href:V,rel:j,target:U})=>{const oe=V.toString();if(!oe.startsWith("http")&&oe.match(/^[a-zA-Z0-9]+:\/\//)){window.open(oe,U,j);return}})}function Ae(V,j=X){return[y.listenToMessageFromWindow(window,f.UPDATE_HEIGHT,U=>{V.style.height=U.height?`${U.height+ie}px`:j}),y.listenToMessageFromWindow(window,f.SET_FULL_HEIGHT,({isUpToSmall:U})=>{V.style.height=U?j:`${document.body.offsetHeight}px`})]}const qe=Object.values(m);function Ye(V,j,U){if(mt(V)){const oe=V[U];return se(oe)?oe[j]:oe}if(se(V)){const oe=V[j];return mt(oe)?oe[U]:oe}return V}function mt(V){return typeof V!="object"?!1:Object.keys(V).every(j=>qe.includes(j))}const Xe=/^\d+$/;function se(V){return typeof V!="object"?!1:Object.keys(V).every(j=>typeof j=="number"||Xe.test(j))}e.TradeType=m,e.WIDGET_PALETTE_COLORS=h,e.WidgetMethodsEmit=f,e.WidgetMethodsListen=p,e.createCowSwapWidget=ne,e.isCowSwapWidgetPalette=x,e.isPerNetworkConfig=se,e.isPerTradeTypeConfig=mt,e.resolveFlexibleConfig=Ye,e.widgetIframeTransport=y})(Eu);const UF=ae({__name:"CowSwap",props:{buy:{},sell:{},level:{}},setup(e){const{connector:t}=Th(),n=ti(async()=>{var a;return await((a=t.value)==null?void 0:a.getProvider())}),s=Af("cow");let r;Qi(()=>{r==null||r.destroy()}),pl(()=>{if(!e.buy||!e.sell||!s.value||!n.value)return;const i=o(e.buy,e.sell,e.level);if(!r){r=Eu.createCowSwapWidget(s.value,{params:i,provider:n.value});return}r.updateParams(i)});function o(i,a,c){return{appCode:"Llama Airforce",width:"100%",height:"520px",chainId:1,tokenLists:["https://files.cow.fi/tokens/CoinGecko.json","https://files.cow.fi/tokens/CowSwap.json"],tradeType:Eu.TradeType.SWAP,sell:{asset:a,amount:"0"},buy:{asset:i,amount:"0"},enabledTradeTypes:[Eu.TradeType.SWAP],theme:{baseTheme:"dark",primary:"#18181b",background:"#18181b",paper:c===1?"#18181b":"#27272a",text:"#fafafa",danger:"#ff5757",warning:"#ffcc00",alert:"#ffcc00",info:"#2081f0",success:"#7ed957"},customTokens:[{chainId:1,address:"0x34635280737b5BFe6c7DC2FC3065D60d66e78185",name:"Convex Prisma",decimals:18,symbol:"cvxPRISMA",logoURI:"https://assets.coingecko.com/coins/images/32961/large/cvxprisma.png?1700026172"}],standaloneMode:!1,disableToastMessages:!1}}return(i,a)=>(F(),J("div",{ref_key:"cow",ref:s,class:"cow"},null,512))}}),VF=pe(UF,[["__scopeId","data-v-e491bb50"]]),jF={class:"content"},HF={class:"info"},zF={class:"swap"},pd=ae({__name:"ModalCowSwap",props:{swap:{}},emits:["close"],setup(e,{emit:t}){const{t:n}=Me(),s=t;return(r,o)=>{const i=He,a=ia;return F(),fe(a,{onClose:o[0]||(o[0]=c=>s("close"))},{default:Y(()=>[$(i,{title:v(n)("swap")},{default:Y(()=>{var c,u;return[T("div",jF,[T("div",HF,Z(v(n)("swap-info")),1),T("div",zF,[$(VF,{class:"cow",level:1,buy:((c=r.swap)==null?void 0:c.buy)??"ETH",sell:((u=r.swap)==null?void 0:u.sell)??"USDC"},null,8,["buy","sell"])])])]}),_:1},8,["title"])]),_:1})}}});function Dg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{information:{t:0,b:{t:2,i:[{t:3}],s:"Information"}},swap:{t:0,b:{t:2,i:[{t:3}],s:"Swap"}},"swap-info":{t:0,b:{t:2,i:[{t:3}],s:"The preferred method for depositing is using the available zaps from the dropdown menu. If your preferred token is not listed, we recommend using the CoWSwap widget for MEV-protected trading with optimal routing into the native pounder token, which you can then deposit. Although this two-step process might be a bit cumbersome, it ensures your safety. The same method applies for withdrawing from the pounder."}}}})}function Ug(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{information:{t:0,b:{t:2,i:[{t:3}],s:"信息"}},swap:{t:0,b:{t:2,i:[{t:3}],s:"交换"}},"swap-info":{t:0,b:{t:2,i:[{t:3}],s:"存款的首选方法是使用下拉菜单中的可用 Zaps。如果您首选的代币没有列出，我们建议您使用 CoWSwap 小工具进行 MEV 保护交易，并将其优化路由到本地 pounder 代币，然后再存入。虽然这两个步骤可能有点繁琐，但可以确保您的安全。同样的方法也适用于从 pounder 取款。"}}}})}function Vg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{information:{t:0,b:{t:2,i:[{t:3}],s:"Informations"}},swap:{t:0,b:{t:2,i:[{t:3}],s:"Échange"}},"swap-info":{t:0,b:{t:2,i:[{t:3}],s:"La méthode préférée pour le dépôt est l'utilisation des zaps disponibles à partir du menu déroulant. Si votre jeton préféré ne figure pas dans la liste, nous vous recommandons d'utiliser le widget CoWSwap pour un échange protégé par MEV avec un acheminement optimal vers le jeton pounder natif, que vous pouvez ensuite déposer. Bien que ce processus en deux étapes puisse être un peu lourd, il garantit votre sécurité. La même méthode s'applique pour le retrait du pounder."}}}})}typeof Dg=="function"&&Dg(pd);typeof Ug=="function"&&Ug(pd);typeof Vg=="function"&&Vg(pd);const Kp=pe(pd,[["__scopeId","data-v-39ae60e7"]]),Qp="/assets/cow-D4rpdXOv.webp",qF={class:"details"},WF={class:"deposit-and-withdraw"},GF={class:"deposit"},XF={class:"actions"},KF={class:"buttons"},QF=["src"],ZF={class:"withdraw"},YF={class:"actions"},JF={class:"buttons"},eN=["src"],tN={class:"description"},nN={class:"title"},md=ae({__name:"PounderDetails",props:{pounderId:{},expanded:{type:Boolean}},emits:["deposit","withdraw"],setup(e,{emit:t}){const{t:n}=Me(),s=t,{address:r}=tt(),o=rt(),i=Nc(),a=le(!1),c=le(!1);let u=null;const l=le(0n),d=le(0n),f=le(!1),p=le(!1),m=le([]),h=le([]),y=le(void 0),b=le(void 0),g=le(0),w=le(0),_=le(""),A=M(()=>i.pounders[e.pounderId]),x=M(()=>i.claims[e.pounderId]),C=M(()=>n(A.value.pounder.description)),k=M(()=>A.value.state),S=M(()=>A.value.zapsFactories),R=le(!1),B=M(()=>A.value.pounder.swapDeposit??null),L=le(!1),X=M(()=>A.value.pounder.swapWithdraw??null),z=M(()=>{const{balanceWithdraw:j,balanceUnclaimed:U}=k.value;return(j??0n)+(U??0n)}),ie=M(()=>{if(k.value.balanceDeposit)return l.value>k.value.balanceDeposit?k.value.balanceDeposit:l.value}),ne=M(()=>{if(z.value)return d.value>z.value?z.value:d.value}),te=M(()=>{const j=ie;return j.value!==void 0&&j.value>0n&&!f.value}),ce=M(()=>{const j=ne;return j.value!==void 0&&j.value>0n&&!p.value}),he=M(()=>f.value?n("zap-depositing"):n("zap-deposit")),_e=M(()=>p.value?n("zap-withdrawing"):n("zap-withdraw"));Ce(S,()=>{h.value=S.value.createZapsDeposit(()=>ie.value),b.value=h.value[0],m.value=S.value.createZapsWithdrawal(()=>ne.value),y.value=m.value[0]},{immediate:!0}),Ce([b,r,h1(()=>e.expanded)],async([,,j])=>{j&&b.value!==void 0&&await i.updateZapDeposit(e.pounderId,b.value)},{immediate:!0});const Ae=async j=>{if(!(!b.value||!ie.value)){if(b.value.getMinAmountOut){if(!j){c.value=!0,u=()=>Ae(!0);const U=await mn();g.value=await b.value.getMinAmountOut(U,ie.value,0).then(oe=>Ie(oe,k.value.decimalsWithdraw)),_.value=A.value.pounder.symbol;return}}else w.value=0;await Qs(f,async()=>{if(!b.value)return;const U=$t(w.value,k.value.decimalsWithdraw);await b.value.zap(U),l.value=0n,await i.updatePounder(e.pounderId),await i.updateBalances(e.pounderId,r.value),await i.updateZapDeposit(e.pounderId,b.value),s("deposit")})}},qe=async(j,U)=>{if(!y.value||!ne.value||k.value.balanceWithdraw===void 0)return;if(a.value=ne.value>k.value.balanceWithdraw,a.value&&!j){u=()=>Ye();return}a.value=!1;const oe=await y.value.withdrawDecimals();if(oe){if(y.value.getMinAmountOut){if(!U){c.value=!0,u=()=>qe(!0,!0);const be=await mn();g.value=await y.value.getMinAmountOut(be,ne.value,0).then(P=>Ie(P,k.value.decimalsDeposit)),_.value=y.value.withdrawSymbol;return}}else w.value=0;await Qs(p,async()=>{if(!y.value)return;const be=$t(w.value,oe);await y.value.zap(be),d.value=0n,await i.updatePounder(e.pounderId),await i.updateBalances(e.pounderId,r.value),b.value&&await i.updateZapDeposit(e.pounderId,b.value),s("withdraw")})}},Ye=async()=>{const j=A.value.pounder.distributor;if(!x.value||!j)return;const U=BigInt(x.value.amount);await a$(async()=>{if(!x.value||!r.value)return;const oe=[BigInt(x.value.index),r.value,U,x.value.proof],be=await Le(o,{abi:dc,address:j,functionName:"claim",args:oe});await Oe(o,{hash:be}),i.updateClaim(e.pounderId),await qe(!0,!1)})},mt=async()=>{a.value=!1,await(u==null?void 0:u())},Xe=async j=>{c.value=!1,w.value=j,await(u==null?void 0:u())},se=j=>{b.value=j},V=j=>{y.value=j};return(j,U)=>{const oe=Mt,be=cd;return F(),J("div",qF,[T("div",WF,[T("div",GF,[$(Lg,{modelValue:v(l),"onUpdate:modelValue":U[0]||(U[0]=P=>$e(l)?l.value=P:null),token:v(k).symbolDeposit,balance:v(k).balanceDeposit,decimals:v(k).decimalsDeposit},null,8,["modelValue","token","balance","decimals"]),T("div",XF,[v(b)?(F(),fe(Xp,{key:0,modelValue:v(b),"onUpdate:modelValue":U[1]||(U[1]=P=>$e(b)?b.value=P:null),class:Pe({expanded:j.expanded}),zaps:v(h),onSelect:se},null,8,["modelValue","class","zaps"])):ye("",!0),T("div",KF,[$(oe,{class:"primary",disabled:!v(te),"chain-id":v(It).id,onClick:U[2]||(U[2]=P=>Ae(!1))},{default:Y(()=>[we(Z(v(he)),1)]),_:1},8,["disabled","chain-id"]),v(B)?(F(),fe(oe,{key:0,class:"swap","chain-id":v(It).id,onClick:U[3]||(U[3]=P=>R.value=!0)},{default:Y(()=>{var P;return[T("img",{src:v(Qp)},null,8,QF),we(" "+Z(v(n)("buy",[((P=v(B))==null?void 0:P.buy)??"?"])),1)]}),_:1},8,["chain-id"])):ye("",!0)])])]),T("div",ZF,[$(Lg,{modelValue:v(d),"onUpdate:modelValue":U[4]||(U[4]=P=>$e(d)?d.value=P:null),token:v(k).symbolWithdraw,balance:v(z),decimals:v(k).decimalsWithdraw,price:(v(k).priceShare??0)*(v(k).priceUnderlying??0)},null,8,["modelValue","token","balance","decimals","price"]),T("div",YF,[v(y)?(F(),fe(Xp,{key:0,modelValue:v(y),"onUpdate:modelValue":U[5]||(U[5]=P=>$e(y)?y.value=P:null),class:Pe({expanded:j.expanded}),zaps:v(m),onSelect:V},null,8,["modelValue","class","zaps"])):ye("",!0),T("div",JF,[$(oe,{class:"primary",disabled:!v(ce),"chain-id":v(It).id,onClick:U[6]||(U[6]=P=>qe(!1,!1))},{default:Y(()=>[we(Z(v(_e)),1)]),_:1},8,["disabled","chain-id"]),v(X)?(F(),fe(oe,{key:0,class:"swap","chain-id":v(It).id,onClick:U[7]||(U[7]=P=>L.value=!0)},{default:Y(()=>{var P;return[T("img",{src:v(Qp)},null,8,eN),we(" "+Z(v(n)("sell",[((P=v(X))==null?void 0:P.sell)??"?"])),1)]}),_:1},8,["chain-id"])):ye("",!0)]),$(be,{title:v(n)("claim-rewards-title"),show:v(a),onClose:U[8]||(U[8]=P=>a.value=!1),onNo:U[9]||(U[9]=P=>a.value=!1),onYes:mt},{default:Y(()=>[T("span",null,Z(v(n)("claim-first")),1)]),_:1},8,["title","show"])])])]),T("div",tN,[T("span",nN,Z(v(n)("information")),1),T("span",null,Z(v(C)),1)]),$(Kp,{show:v(R),swap:v(B),onClose:U[10]||(U[10]=P=>R.value=!1)},null,8,["show","swap"]),$(Kp,{show:v(L),swap:v(X),onClose:U[11]||(U[11]=P=>L.value=!1)},null,8,["show","swap"]),$(Wh,{show:v(c),"symbol-output":v(_),"min-amount-out-ref":v(g),onClose:U[12]||(U[12]=P=>c.value=!1),onNo:U[13]||(U[13]=P=>c.value=!1),onYes:Xe},null,8,["show","symbol-output","min-amount-out-ref"])])}}});function jg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"zap-deposit":{t:0,b:{t:2,i:[{t:3}],s:"Deposit"}},"zap-depositing":{t:0,b:{t:2,i:[{t:3}],s:"Depositing..."}},"zap-withdraw":{t:0,b:{t:2,i:[{t:3}],s:"Withdraw"}},"zap-withdrawing":{t:0,b:{t:2,i:[{t:3}],s:"Withdrawing..."}},"claim-rewards-title":{t:0,b:{t:2,i:[{t:3}],s:"Claim Union rewards"}},"claim-first":{t:0,b:{t:2,i:[{t:3}],s:"In order to withdraw the requested amount you first need to claim your Union rewards"}},buy:{t:0,b:{t:2,i:[{t:3,v:"Buy "},{t:5,i:0}]}},sell:{t:0,b:{t:2,i:[{t:3,v:"Sell "},{t:5,i:0}]}},"description-ucrv":{t:0,b:{t:2,i:[{t:3}],s:"This pounder stakes cvxCRV single-sidedly on Convex. Llama Airforce devs actively choose the highest yielding reward weight option for the staked cvxCRV."}},"description-ufxs":{t:0,b:{t:2,i:[{t:3}],s:"This pounder stakes cvxFXS single-sidedly on Convex."}},"description-uprisma":{t:0,b:{t:2,i:[{t:3}],s:"This pounder stakes cvxPRISMA single-sidedly on Convex."}},"description-ucvx":{t:0,b:{t:2,i:[{t:3}],s:"This pounder stakes pxCVX and compounds the earned bribe rewards for more pxCVX."}},"description-ubal":{t:0,b:{t:2,i:[{t:3}],s:"This pounder stakes auraBAL on Aura."}},"description-ufxslp":{t:0,b:{t:2,i:[{t:3}],s:"This pounder stakes cvxFXS/FXS LP tokens on Convex. This staking method no longer actively rewarded by Convex; these rewards have been moved to single-sided cvxFXS staking."}},information:{t:0,b:{t:2,i:[{t:3}],s:"Information"}}}})}function Hg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{"zap-deposit":{t:0,b:{t:2,i:[{t:3}],s:"订金"}},"zap-depositing":{t:0,b:{t:2,i:[{t:3}],s:"订金。。。"}},"zap-withdraw":{t:0,b:{t:2,i:[{t:3}],s:"提取"}},"zap-withdrawing":{t:0,b:{t:2,i:[{t:3}],s:"提取。。。"}},"claim-rewards-title":{t:0,b:{t:2,i:[{t:3}],s:"索取奖励"}},"claim-first":{t:0,b:{t:2,i:[{t:3}],s:"在提取您要求的金额之前，请先领取您的收益"}},buy:{t:0,b:{t:2,i:[{t:3,v:"购买 "},{t:5,i:0}]}},sell:{t:0,b:{t:2,i:[{t:3,v:"卖出 "},{t:5,i:0}]}},information:{t:0,b:{t:2,i:[{t:3}],s:"信息"}}}})}function zg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{"zap-deposit":{t:0,b:{t:2,i:[{t:3}],s:"Déposer"}},"zap-depositing":{t:0,b:{t:2,i:[{t:3}],s:"Déposer..."}},"zap-withdraw":{t:0,b:{t:2,i:[{t:3}],s:"Retirer"}},"zap-withdrawing":{t:0,b:{t:2,i:[{t:3}],s:"Retirer..."}},"claim-rewards-title":{t:0,b:{t:2,i:[{t:3}],s:"Réclamer les récompenses de l'Union"}},"claim-first":{t:0,b:{t:2,i:[{t:3}],s:"Pour retirer le montant demandé, vous devez d'abord réclamer vos récompenses de l'Union"}},buy:{t:0,b:{t:2,i:[{t:3,v:"Acheter "},{t:5,i:0}]}},sell:{t:0,b:{t:2,i:[{t:3,v:"Vendre "},{t:5,i:0}]}},"description-ucrv":{t:0,b:{t:2,i:[{t:3}],s:"Ce pounder stake du cvxCRV en unilatéral sur Convex. Les développeurs de Llama Airforce sélectionnent activement l'option de récompense offrant le rendement le plus élevé pour le cvxCRV staké."}},"description-ufxs":{t:0,b:{t:2,i:[{t:3}],s:"Ce pounder stake du cvxFXS en unilatéral sur Convex."}},"description-uprisma":{t:0,b:{t:2,i:[{t:3}],s:"Ce pounder stake du cvxPRISMA en unilatéral sur Convex."}},"description-ucvx":{t:0,b:{t:2,i:[{t:3}],s:"Ce pounder stake du pxCVX et compounde les récompenses de pots-de-vin gagnées pour plus de pxCVX."}},"description-ubal":{t:0,b:{t:2,i:[{t:3}],s:"Ce pounder stake de l'auraBAL sur Aura."}},"description-ufxslp":{t:0,b:{t:2,i:[{t:3}],s:"Ce pounder stake des tokens cvxFXS/FXS LP sur Convex. Cette méthode de staking n'est plus activement récompensée par Convex; les récompenses ont été déplacées vers le staking cvxFXS unilatéral."}},information:{t:0,b:{t:2,i:[{t:3}],s:"Informations"}}}})}typeof jg=="function"&&jg(md);typeof Hg=="function"&&Hg(md);typeof zg=="function"&&zg(md);const sN=pe(md,[["__scopeId","data-v-8db28e51"]]),Zp=ae({__name:"Pounder",props:{pounderId:{}},setup(e){const{address:t}=tt(),n=Nc(),s=le(!1),r=M(()=>n.pounders[e.pounderId]),o=M(()=>r.value.pounder),i=M(()=>n.claims[e.pounderId]);return Ce([t,o],()=>n.updateBalances(e.pounderId,t.value),{immediate:!0}),Ce(i,a=>{n.updateClaim(e.pounderId,a)},{immediate:!0}),Ce(o,async()=>{await n.updatePounder(e.pounderId)},{immediate:!0}),(a,c)=>{const u=Uh,l=He;return F(),fe(l,{compact:"",class:"pounder"},{default:Y(()=>[$(hF,{"pounder-id":a.pounderId,expanded:v(s),onToggleExpand:c[0]||(c[0]=d=>s.value=!v(s))},null,8,["pounder-id","expanded"]),$(u,{expanded:v(s)},{default:Y(()=>[$(sN,{"pounder-id":a.pounderId,expanded:v(s)},null,8,["pounder-id","expanded"])]),_:1},8,["expanded"])]),_:1})}}}),rN=ae({__name:"ButtonToggle",props:{modelValue:{type:Boolean,default:!1},modelModifiers:{}},emits:ps(["change"],["update:modelValue"]),setup(e,{emit:t}){const n=Do(e,"modelValue"),s=t,r=()=>{const o=!n.value;n.value=o,s("change",o)};return(o,i)=>{const a=Mt;return F(),fe(a,{class:Pe({toggled:n.value}),onClick:r},{default:Y(()=>[Ze(o.$slots,"default",{},void 0,!0)]),_:3},8,["class"])}}}),V6=pe(rN,[["__scopeId","data-v-9cfb50ee"]]),oN={},iN={class:"strategy"};function aN(e,t){return F(),J("div",iN,t[0]||(t[0]=[T("div",{class:"info"}," The vault locks the user's CVX in Convex to receive vlCVX in 16 week intervals. The vlCVX then receives optimal bribe rewards from an integration with Votium which can be claimed by the holders of pxCVX. ",-1),T("div",{class:"links"},[T("a",{href:"https://docs.redacted.finance/products/pirex/convex/pxcvx-standard-mode",target:"_blank"}," Learn More "),T("a",{href:"https://etherscan.io/address/0x35A398425d9f1029021A92bc3d2557D42C8588D7",target:"_blank"}," Etherscan ")],-1)]))}const cN=pe(oN,[["render",aN],["__scopeId","data-v-04121b8d"]]),uN={},lN={class:"fees"};function dN(e,t){const n=Pt,s=td;return F(),J("div",lN,[$(s,{"tooltip-type":"icon",label:"Bribe Fee",tooltip:"Fee accessed on bribes earned from vlCVX"},{default:Y(()=>[$(n,{type:"percentage",value:4})]),_:1}),$(s,{"tooltip-type":"icon",label:"Redemption Fee",tooltip:"Linearly scales with time depending on redemption time. Can be avoided swapping through curve pool depending on slippage"},{default:Y(()=>[$(n,{type:"percentage",value:5})]),_:1})])}const fN=pe(uN,[["render",dN],["__scopeId","data-v-e77e49a9"]]),pN="/assets/omniscia-DVS81mgW.png",mN="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZEAAABlCAYAAACMVd7sAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAt+SURBVHgB7d3/cds2G8Dxx73+33SCcoM6E0SeIN7AygRxJrDeCexMIGWCJBNIncDeQOoEzjvBUyCE7xgSFEkQlEHo+7njqZZFkIIbPMTvC8FZUdXCvFya4405itqvD+b4YV8vLi6eBAA6XAiyZoLGwry8M4d9fQkefe3MYYPJdxNUdgIAyJ8JHG/McWeOZ41nb461q8kAAHJjC3hX0E9tTTABgExoWfO419NbE0wAYMZMIb7QsqnptezNsRQAwLzo69Q+2twLACB9WjZfbTU9j0rzFnBWGOI7M66Q/irlcN0UHcxxdXFxcRAA2SOIzIgJIHaOx6M0Jwmm5iAEEuAs/CaYk62kH0CswhxfXdADkDGCyEyYAvlO0m3C8rH3Smc7ALw2E0CWOl+3AiBb9IkkTsuO9Lk0Y/nYBR3f0j8C5InmrPTZZqxC5sv2i6wFQJaoiSTM1UL2kocrVgIG8kNNJG05PcHfCYDsUBNJVGa1kBfURoDMUBNJV45P7tRGgMxQE0mQlpP0bC0kx8l6f5rayA8BkAVqImm6ljwDiLUUANkgiKTpneTrvQDIBs1ZCTLNWbYpq5A8/TDNWX8KgCxQE0mMG5VVSL7sXihzWgMMwBEEkfScQwFLEAEyQRBJTyH5I4gAmSCIpKeQ/P0hALJAEEnPOWzkVAiALDA6KzGu0zn3QGJHaD0JgNkjiCTGBJGNebmRvO1MELkSALNHcxZew/8FQBYIIuk5SP4OAiALNGclxi2+eA59IizCCGTgd0GKlpK3jZR7rwOYOWoiCTK1kWfJuzbCcvBAJugTSVPOw1+fCCBAPmjOStMXydd3AQAAAAAACEbHeqLcUN9rmY+ix2c2pj/kIACyQRBJlAsidofDXEZpHcxxRRAB8sLorES5EUyfJR9fCCBAfqiJJC6T/dYPQi0EyBJBJHFuz/WFzNsTS78DAAAAAAAAAF4ZfSIz4rbO3cr4Yb8Hmd4H0w+yE5yE+X9jYV7Wlbe+m/y/FWBirJ01I7Zz2hQWn+TXwiJEIdMigLyOovLffwhwAswTmRlTOG/My1tJdz+OD+4eAZwBaiIz5GokNpCMrZHE9omhvMB5IYjMlJu4dyUA8IpozkJ0dt0vc9CpC5wBggiicjPs7Qiy9wIgezRnZcat/rswx0eJPwrr56KQbR3n5to35uVByiHIOwEAzJedO2COjV3EUcM9m2Pt5iF0XatqKzgZT/6nNugCmaImkjE3V8MeLxMVCylrKX9JWVsoaqfYmsbBHP+aw46y2rHyLoBjCCJnwg29tcc3AYBICCJIjuucr/vhNuoamtbLNsN/S1nzuqz8+iBl7esfc3wLrXXV7zd27c19h+pSN0F5EXitUdd0zaA2z9/Jr3lvHdxh859aL3DOYvSJuKHBW0+/zL4lsHTdz9r16fT1aI6lDOS556jDm7XZp7X0fGZ0n4jNY5cHo/Jfy7/jXUtax6x14N8ZQCZ0ZBBxBdjeU7DYgqj3gpOuALvXcfY6rNC8HfPdO9K+rt9by+dGBRFtz/+tDsv/hY4byPHz3pVgApwXHRFEzGcvWwqezcACrC2dF/Z3W1dIfVV/rafqrud1beCq13gWEoHnHpctnwsOIkfy7UEG0LL20cbmz6PL+7XL/2M1lb2Wg0EAnAMNDCJaPmn7mpxWMoC7/nNLYWRrCm86zt20FGZ9A8lD7bxBBXBLmoXnfgpp/w5VvYKI+dxNpPxfq58NFosj59kAvNT24H8jAPKnAUHEfOZjS8ExqE9ByyfpuueAdGyhvfWk1RlIPN/fXn/Uvi/aLJjXA67fGUS0veawlAHU33xoaxmDahLaHkyuBUDedGAQaSnAbMG7kAHU35Zvfy4kkDl35bm3zoCkETvYtXxC39fSK458flAQUX/Bb/N/aMF/50lnI4Fa/p7PSh8JkDftGURc4bj2FDx7DWgD12bBvY9R4GgzkHQWsNrsBA/uYNfyqbx3WtoziHTkfyHD7tHX3LaRkdQfSB4FQL60RxBxBdjoIaSV9OoFbdQnVm32c3QV5NE62LXHsN7a5zuDiLYP4X0MzP9tLZ29ROLutZ6XKwGQJ+0IIhppCGktzXp6sednDA4K2qzBDO5g9+RlZ+GsHUHkSP5vQvLfcz2rkIi0WbMb3c8EIFF6JIhopCGktev1mj8xljaDQldt5HJswafliKaqZY9zWoOIto9cW0kgzz1OsuCjTjyRE0AitCWIaKQhpJ7rrXVgQRt4HV9t5E3HOdvQgk8HDOutnecNIi7/fcZ2+g++x8BrdTaTAsiA7x+7RhpC2nK9/SkKMXetzZD71xEd7DpgWG/tvEYQ0fYRcEsZQSMOIOhxrXoQp0kLyJH628h9BdjoWcjafBKedOSONjvwH6T7/gZ3sOvAYb21cxeevK7bR8r/VS3dlUxImzU7ZrInhFV8cSoHc1xFWqm1Xoj87HOR0ymO/dKudmvu57P5z+okRTthbifHXdfSHrOybf1p/SDx8v/v2s9PMq1/az9fnuCa6IkgglP5MPFS34Wczl89PvNNfg0iN/aJvWM59frM+C8Sz1XE/K8HqB8yrYMgWb8JcBprPaNZx24TsF3lLVvwLts+75q7ispbh7a97ANtzyn/cTrURDAV+3RafWItpCzIriaokdhrnbJ5o++1/ifldsQv3pujrT/lxnPuGKfM/6nRkQ7kTv2js1aezt3RnevaHAab7JIY2qODXQOH9dbS8I3O8uX/PkL+DxqtNpY256QsBMmgOQuTMU+8K/Pyofa2faq0y2yMWeK73gZfSLo+136+9nym3heyiVFbcPn/qfZ2IWWNZMzKuPWa2NSjpS47rg9g7rR7xrpvyGmvvTparredw9OpNocjN+Y5aIQ5L3p8xvp1zPzXgGVZQmlzBQAWYgRypOFrZ4UWZKu2QjMmd9/LyrGQgfTIDHYduFrvkWssjuVHzPzXCXdy9FxrXbtO8FI5ABKm/VbxbSvI7mUgPdHSGxo4g7yWxrFa2r72u6BmJu2/iu/ek28hgWTQCschNEJfEYCZ0P77idiCwbccue08HbpQ4abPNUOpf8fEQgKo58ldIzYLaf/9RNryf63D9rP3FfBj+rkaNEIABzATOnxnw42nENrrgEJa/XtOBPezeNLe19JeSSD1LBGvEReR1AE7G2pZi/vazP5h+4poszYSbT8X9a/7VQiAPGnYHusrT0GxH1iQ3XrSGBVI1L95lr2v4PkK6u9gj1YAa9ge6w86Iv/Vv9ZX7/OPpHvjua+VAMiXBi7ZrXECie+p+l7DN1va19KK8oStzQ72qlFNNRoQRNx5o/Jf/SPv7PlLCWDO++i5n68CIG86Yt8H9dcmbMG06Hn+sW13lwPSuFe/MXMqqtdYaLtCRtDAIOLObQskveZ/aPsQ7rXqoFWIt5407N+VGetA7nTk5kHaPpfhtuf5be38LwXi2l3D3mfhDvvzrbbXEHoHsgHf0/cdRw8I0BFBxJ2/bPn+vTrLtX33yp/fz+Xzwn2umv932p7/gwdbAJgpjbADnUYYgqr+p+oQW51myLDv/kbXdHRkEHFpXI7Jfy3/fhsdzwavXg8PADKhkbYx1TiBZExhttcJ14LSZgd7lNneGiGIuHRi5P9S22slXdbKKKxZuRAgAvcPf1l5K3gpc09aLwatKeXSsU+07+T4+k52La6dOT6b9HcyIRegqgX8hxhLvnvy7Mmk+00CRMz/hUvH5n9x5KM7c/xjjoeO/VaQIIIIzoKWbes2kBSVt38uIX/KpdFdzaOoXP/tDJdmH6yS/2/cYb/7QcqHDQIHAHTRZuc1M7ABAP1ocxRSIQAAdNFIAw8AAGdIm+tkRZnACADInDZXvJ1sEycAQGY04mq9AIAz4qmFRFsuHUjBbwJgSvW+j2/nMC8EABCBNpf/KATIyO8CYBIuYHypvHWgFoLc/AdCn8psLd3gQQAAAABJRU5ErkJggg==",hN={},yN={class:"audits"};function bN(e,t){return F(),J("div",yN,t[0]||(t[0]=[yC('<div class="audit" data-v-1266f34e><a class="logo" href="https://omniscia.io/" target="_blank" data-v-1266f34e><img class="no-hover" src="'+pN+'" alt="Omniscia" data-v-1266f34e></a><a href="https://omniscia.io/pirex-multi-token-convex-wrapper/" target="_blank" data-v-1266f34e> Report </a></div><div class="audit" data-v-1266f34e><a class="logo" href="https://www.keyko.io/" target="_blank" data-v-1266f34e><img class="no-hover" src="'+mN+'" alt="Keyko" data-v-1266f34e></a><a href="https://drive.google.com/file/d/151iyZSiFhHmdEaSu3w-3ba19NKaERexH/view?usp=sharing" target="_blank" data-v-1266f34e> Report </a></div>',2)]))}const gN=pe(hN,[["render",bN],["__scopeId","data-v-1266f34e"]]),vN={class:"tabs"},wN={class:"vault-info-body"},_N=ae({__name:"VaultInfo",setup(e){const n=le(["strategy","fees","audits"][0]),s=r=>{n.value=r};return(r,o)=>{const i=V6,a=He;return F(),fe(a,{title:"Vault Info"},{actions:Y(()=>[T("div",vN,[$(i,{"model-value":v(n)==="strategy",onClick:o[0]||(o[0]=c=>s("strategy"))},{default:Y(()=>o[3]||(o[3]=[we(" Strategy ")])),_:1},8,["model-value"]),$(i,{"model-value":v(n)==="fees",onClick:o[1]||(o[1]=c=>s("fees"))},{default:Y(()=>o[4]||(o[4]=[we(" Fees ")])),_:1},8,["model-value"]),$(i,{"model-value":v(n)==="audits",onClick:o[2]||(o[2]=c=>s("audits"))},{default:Y(()=>o[5]||(o[5]=[we(" Audits ")])),_:1},8,["model-value"])])]),default:Y(()=>[T("div",wN,[v(n)==="strategy"?(F(),fe(cN,{key:0})):ye("",!0),v(n)==="fees"?(F(),fe(fN,{key:1})):ye("",!0),v(n)==="audits"?(F(),fe(gN,{key:2})):ye("",!0)])]),_:1})}}}),xN=pe(_N,[["__scopeId","data-v-795c5609"]]),CN=new pn;function AN(e){const t=xI({queries:M(()=>e.value.map(r=>({queryKey:["token-price",r],queryFn:()=>CN.getPrice(r)})))}),n=M(()=>t.value.some(o=>o.isLoading)?void 0:Object.fromEntries(e.value.map((o,i)=>[o,t.value[i].data]))),s=M(()=>t.value.some(r=>r.isLoading));return{data:n,isLoading:s}}const TN={class:"checkbox"},EN=["checked"],SN=["aria-checked"],PN={class:"checkmark-label"},kN=ae({__name:"Checkbox",props:{modelValue:{type:Boolean,required:!0},modelModifiers:{}},emits:ps(["change"],["update:modelValue"]),setup(e,{emit:t}){const n=Do(e,"modelValue"),s=t,r=o=>{const i=o.target.checked;n.value=i,s("change",i)};return(o,i)=>(F(),J("label",TN,[T("input",{type:"checkbox",checked:n.value,onChange:r},null,40,EN),T("span",{class:Pe(["checkmark",{checked:n.value}]),role:"checkbox","aria-checked":n.value},i[0]||(i[0]=[T("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[T("path",{d:"M20 6L9 17L4 12",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)]),10,SN),T("span",PN,[Ze(o.$slots,"default",{},void 0,!0)])]))}}),IN=pe(kN,[["__scopeId","data-v-57d2ab9e"]]),RN=["src"],$N=["href"],MN=["src"],ON=ae({__name:"TokenIcon",props:{chain:{default:"ethereum"},address:{},clickable:{type:Boolean,default:!1}},setup(e){const t=le("");function n(o){return`https://cdn.jsdelivr.net/gh/curvefi/curve-assets/images/assets${e.chain!=="ethereum"?`-${e.chain}`:""}/${o}.png`}const s=()=>{t.value="https://lend.curve.fi/images/default-crypto.png"};Ce(()=>e.address,o=>{t.value=n(o.toLowerCase())},{immediate:!0});const r=M(()=>{switch(e.chain){case"arbitrum":return`https://arbiscan.io/address/${e.address}`;case"ethereum":default:return`https://etherscan.io/address/${e.address}`}});return(o,i)=>o.clickable?(F(),J("a",{key:1,target:"_blank",href:v(r)},[T("img",{class:"token",src:v(t),onError:s},null,40,MN)],8,$N)):(F(),J("img",{key:0,class:"token",src:v(t),onError:s},null,40,RN))}}),Gh=pe(ON,[["__scopeId","data-v-864e9394"]]),LN={class:"end"},FN={class:"end"},NN=ae({__name:"RewardsTable",props:{rewards:{},canSelect:{type:Boolean,default:!1},selected:{default:()=>[]}},emits:["select"],setup(e,{emit:t}){const n=t,s=M(()=>["",{label:"Reward"},{label:"Amount",align:"end"},{label:"Value",align:"end"},...e.canSelect?[""]:[]]);function r(o){const i=JSON.stringify(o);return e.selected.map(a=>JSON.stringify(a)).includes(i)}return(o,i)=>{const a=Gh,c=Pt,u=IN,l=zo;return F(),fe(l,{class:Pe(["rewards-table",{"can-select":o.canSelect}]),columns:v(s),rows:o.rewards,onSelected:i[1]||(i[1]=d=>n("select",d))},{row:Y(({item:d})=>[$(a,{address:d.address},null,8,["address"]),T("div",null,Z(d.symbol),1),T("div",LN,[$(c,{type:"dollar",value:d.amount,precision:4,"show-symbol":!1},null,8,["value"])]),T("div",FN,[$(c,{type:"dollar",value:d.amountUsd},null,8,["value"])]),o.canSelect?(F(),J("div",{key:0,class:"center",onClick:i[0]||(i[0]=Ac(()=>{},["stop"]))},[$(u,{"model-value":r(d),"onUpdate:modelValue":f=>n("select",d)},null,8,["model-value","onUpdate:modelValue"])])):ye("",!0)]),_:1},8,["class","columns","rows"])}}}),Yp=pe(NN,[["__scopeId","data-v-7fc4141e"]]);function BN(e){return e.type==="snapshot"}function j6(e,t,n){return e.groupBy(s=>s.address).entries().map(([,s])=>({address:s[0].address,amount:s.reduce((r,{rewardAmount:o})=>r+o,0n),metadata:s.map(r=>n==="snapshot"?{epoch:r.epoch,rewardIndex:r.rewardIndex}:r.epoch)})).map(({address:s,amount:r,metadata:o})=>{const i=t[s];if(!i)return{type:n,symbol:"?",address:s,amount:0,amountUsd:0,[n==="snapshot"?"claims":"epochs"]:[]};const{symbol:a,decimals:c,price:u}=i,l=Number(ea(r,c)),d=l*u;return{type:n,symbol:a.toLocaleUpperCase(),address:s,amount:l,amountUsd:d,[n==="snapshot"?"claims":"epochs"]:o}})}const H6=(e,t)=>j6(e.filter(({isClaimed:n})=>!n),t,"snapshot"),z6=(e,t)=>j6(e,t,"futures");function DN(e,t){return e.concat(t).groupBy(n=>n.address).entries().map(([,n])=>{const s=n[0];return{type:"combined",symbol:s.symbol,address:s.address,amount:n.reduce((r,{amount:o})=>r+o,0),amountUsd:n.reduce((r,{amountUsd:o})=>r+o,0)}})}const UN=e=>({address:e.address.toLocaleLowerCase(),rewardAmount:BigInt(e.rewardAmount),rewardIndex:e.rewardIndex,isClaimed:e.isClaimed,epoch:e.epoch}),VN=e=>({address:e.address.toLocaleLowerCase(),rewardAmount:BigInt(e.rewardAmount),epoch:e.epoch}),jN=e=>({tokenId:BigInt(e.tokenId),balance:BigInt(parseFloat(e.balance))});class HN extends ra{async getRewards(t){const n=await this.getHost(),s=await this.fetch(`${n}/pirex/rewards/${t}`);return{snapshotRewards:s.snapshotRewards.flat().flatMap(r=>UN(r)),futuresRewards:s.futuresRewards.flat().flatMap(r=>VN(r))}}async getRedemptions(t){const n=await this.getHost();return(await this.fetch(`${n}/pirex/redemptions/${t}`)).map(r=>jN(r))}}const q6=new HN(mn());function zN(e){return Fn({queryKey:["pirex-rewards",e],queryFn:async({queryKey:[,t]})=>q6.getRewards(t),initialData:{snapshotRewards:[],futuresRewards:[]},initialDataUpdatedAt:0,enabled:M(()=>!!e.value)})}function qN(e){return Fn({queryKey:["pirex-redemptions",e],queryFn:async({queryKey:[,t]})=>q6.getRedemptions(t),initialData:[],initialDataUpdatedAt:0,enabled:M(()=>!!e.value)})}const gr=[{inputs:[],name:"MAX_REDEMPTION_TIME",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"enum PirexCvx.Fees",name:"",type:"uint8"}],name:"fees",outputs:[{internalType:"uint32",name:"",type:"uint32"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"",type:"uint256"}],name:"redemptions",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256[]",name:"lockIndexes",type:"uint256[]"},{internalType:"enum PirexCvx.Futures",name:"f",type:"uint8"},{internalType:"uint256[]",name:"assets",type:"uint256[]"},{internalType:"address",name:"receiver",type:"address"}],name:"initiateRedemptions",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"epoch",type:"uint256"},{internalType:"uint256[]",name:"rewardIndexes",type:"uint256[]"},{internalType:"address",name:"receiver",type:"address"}],name:"redeemSnapshotRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"epoch",type:"uint256"},{internalType:"address",name:"receiver",type:"address"}],name:"redeemFuturesRewards",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256[]",name:"unlockTimes",type:"uint256[]"},{internalType:"uint256[]",name:"assets",type:"uint256[]"},{internalType:"address",name:"receiver",type:"address"}],name:"redeem",outputs:[],stateMutability:"nonpayable",type:"function"}],qg=[{inputs:[{internalType:"address",name:"account",type:"address"},{internalType:"address",name:"operator",type:"address"}],name:"isApprovedForAll",outputs:[{internalType:"bool",name:"",type:"bool"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"operator",type:"address"},{internalType:"bool",name:"approved",type:"bool"}],name:"setApprovalForAll",outputs:[],stateMutability:"nonpayable",type:"function"}];function Un(e,t){const{successMessage:n,onError:s,onSuccess:r,showSuccess:o=!0}=t??{},{data:i,error:a,isPending:c,writeContract:u}=v4(),{isLoading:l,isSuccess:d}=g4({hash:i}),f=M(()=>c.value||l.value),p=(...m)=>{try{e(u,...m)}catch(h){En({text:Gi(h),type:"error"}),h instanceof Error&&(s==null||s(h))}};return Vi(a,m=>{En({text:Gi(m),type:"error"}),s==null||s(m)}),Vi(d,()=>{o&&En({text:typeof n=="function"?n():n??"Transaction has been successfully processed",type:"success"}),r==null||r()}),{execute:p,isExecuting:f}}const WN={class:"epochs"},GN=["onClick"],XN={class:"info"},KN={class:"data"},QN={class:"chevron"},ZN={class:"epoch-details"},YN={key:0,class:"reward-type"},JN={key:1,class:"reward-type"},eB=ae({__name:"ModalClaim",props:{snapshots:{},futures:{},prices:{}},emits:["close","claimed"],setup(e,{emit:t}){var k;const n=t,{address:s}=tt();function r(S){return new Date(S*1e3).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}const o=M(()=>[...e.snapshots,...e.futures].groupBy(S=>S.epoch).entries().map(([,S])=>({epoch:S[0].epoch,snapshots:S.filter(R=>"rewardIndex"in R),futures:S.filter(R=>!("rewardIndex"in R))}))),i=M(()=>Object.fromEntries(o.value.map(S=>[S.epoch,{snapshot:H6(S.snapshots,e.prices),futures:z6(S.futures,e.prices)}])));function a(S){return i.value[S.epoch].snapshot.reduce((B,L)=>B+L.amountUsd,0)}const c=le([]);function u(S){l(S)?c.value=c.value.filter(R=>R!==S.epoch):c.value.push(S.epoch),d[S.epoch]||(d[S.epoch]=i.value[S.epoch].snapshot)}function l(S){return c.value.includes(S.epoch)}const d=zs({});function f(S,R){d[S.epoch].map(B=>B.address).includes(R.address)?d[S.epoch]=d[S.epoch].filter(B=>B.address!==R.address):d[S.epoch].push(R)}function p(S){var R;return!!s.value&&(((R=d[S.epoch])==null?void 0:R.length)??0)>0}function m(){return!!s.value}let h=[];const{execute:y,isExecuting:b}=Un((S,R)=>{const B=d[R.epoch].filter(X=>BN(X)).flatMap(X=>X.claims.filter(z=>z.epoch===R.epoch)),L=B.map(X=>BigInt(X.rewardIndex));h=B,S({address:cn,abi:gr,functionName:"redeemSnapshotRewards",args:[BigInt(R.epoch),L,s.value]})},{successMessage:`Successfully claimed snapshot rewards for epoch: ${((k=h[0])==null?void 0:k.epoch)??"?"}!`,onSuccess:()=>{h=[]},onError:()=>{h=[]}}),{data:g,refetch:w}=Tt({abi:qg,address:Cb,functionName:"isApprovedForAll",args:M(()=>[s.value,cn]),query:{enabled:M(()=>!!s.value),initialData:!1,initialDataUpdatedAt:0}}),{execute:_,isExecuting:A}=Un(S=>{S({abi:qg,address:Cb,functionName:"setApprovalForAll",args:[cn,!0]})},{successMessage:"Successfully approved futures claim zap!",onSuccess:()=>{w()}}),{execute:x,isExecuting:C}=Un((S,R)=>{S({address:cn,abi:gr,functionName:"redeemFuturesRewards",args:[BigInt(R.epoch),s.value]})},{successMessage:"Successfully claimed futures rewards!"});return(S,R)=>{const B=Pt,L=Ih,X=Mt,z=Uh,ie=He,ne=ia;return F(),fe(ne,{onClose:R[1]||(R[1]=te=>n("close"))},{default:Y(()=>[$(ie,{title:"Convex Rewards"},{default:Y(()=>[T("div",WN,[R[7]||(R[7]=T("div",{class:"headers"},[T("div",null,"Epoch"),T("div",null,"Total Claimable")],-1)),(F(!0),J(De,null,Rt(v(o),te=>(F(),J("div",{key:te.epoch,class:Pe(["epoch",{expanded:l(te)}]),onClick:ce=>u(te)},[T("div",XN,[T("div",KN,Z(r(te.epoch)),1),$(B,{type:"dollar",value:a(te)},null,8,["value"]),T("div",QN,[$(L,{class:Pe({expanded:l(te)})},null,8,["class"])])]),$(z,{class:"rewards-collapsible",expanded:l(te),onClick:R[0]||(R[0]=Ac(()=>{},["stop"]))},{default:Y(()=>[T("div",ZN,[v(i)[te.epoch].snapshot.length>0?(F(),J("div",YN,[R[3]||(R[3]=T("div",{class:"title"},"Snapshot Rewards",-1)),$(Yp,{"can-select":"",rewards:v(i)[te.epoch].snapshot,selected:v(d)[te.epoch],onSelect:ce=>f(te,ce)},null,8,["rewards","selected","onSelect"]),$(X,{class:"primary",disabled:v(b)||!p(te),onClick:ce=>v(y)(te)},{default:Y(()=>R[2]||(R[2]=[we(" Claim Snapshot Rewards ")])),_:2},1032,["disabled","onClick"])])):ye("",!0),v(i)[te.epoch].futures.length>0?(F(),J("div",JN,[R[6]||(R[6]=T("div",{class:"title"},"Futures Rewards",-1)),$(Yp,{rewards:v(i)[te.epoch].futures},null,8,["rewards"]),v(g)?(F(),fe(X,{key:0,class:"primary",disabled:v(C)||!m(),onClick:ce=>v(x)(te)},{default:Y(()=>R[4]||(R[4]=[we(" Claim Futures Rewards ")])),_:2},1032,["disabled","onClick"])):(F(),fe(X,{key:1,class:"primary",disabled:v(A),onClick:v(_)},{default:Y(()=>R[5]||(R[5]=[we(" Approve Futures Claim Zap (only once needed) ")])),_:1},8,["disabled","onClick"]))])):ye("",!0)])]),_:2},1032,["expanded"])],10,GN))),128))])]),_:1})]),_:1})}}}),tB=pe(eB,[["__scopeId","data-v-60661651"]]),nB={class:"rewards"},sB={key:0,class:"right"},rB={key:1,class:"right no-data"},oB=ae({__name:"Rewards",setup(e){const t=le(!1),{address:n}=tt(),{data:s,isFetching:r}=zN(n),o=le([]),i=M(()=>s.value.snapshotRewards.filter(m=>!o.value.find(y=>y.epoch===m.epoch&&y.rewardIndex===m.rewardIndex))),a=M(()=>s.value.futuresRewards),c=M(()=>[...new Set([...i.value.map(m=>m.address),...a.value.map(m=>m.address)])]),{data:u,isLoading:l}=AN(c),d=M(()=>{if(!u.value)return[];const m=H6(i.value,u.value),h=z6(a.value,u.value);return DN(m,h)}),f=M(()=>r.value||l.value);function p(m){o.value.push(...m)}return(m,h)=>{const y=Mt;return F(),J("div",nB,[h[3]||(h[3]=T("div",{class:"left"},[T("div",{class:"title"},"Rewards"),T("div",{class:"info"},[we(" Depositors are eligible to claim rewards for their "),T("strong",null,"pxCVX"),we(" holdings at the epoch timestamp. Rewards are distributed based on a snapshot of "),T("strong",null,"pxCVX"),we(" balances, taken at the timestamp of each epoch. Claims for "),T("strong",null,"RFN"),we(" and pending unlocks are also available here. ")]),T("a",{href:"https://docs.redacted.finance/products/pirex/convex/pxcvx-standard-mode",target:"_blank"}," Learn More ")],-1)),v(d).length>0?(F(),J("div",sB,[$(Yp,{rewards:v(d),loading:v(f)},null,8,["rewards","loading"]),$(y,{class:"primary",onClick:h[0]||(h[0]=b=>t.value=!0)},{default:Y(()=>h[2]||(h[2]=[we(" Show Claims ")])),_:1})])):(F(),J("div",rB," No rewards for "+Z(v(Hl)(v(n))),1)),v(d).length>0?(F(),fe(tB,{key:2,show:v(t),snapshots:v(i),futures:v(a),prices:v(u),onClose:h[1]||(h[1]=b=>t.value=!1),onClaimed:p},null,8,["show","snapshots","futures","prices"])):ye("",!0)])}}}),iB=pe(oB,[["__scopeId","data-v-b3434ba8"]]),aB={class:"end"},cB={class:"end"},uB={class:"end"},lB=ae({__name:"RedemptionsUserTable",props:{redemptions:{}},emits:["redeemed"],setup(e,{emit:t}){const n=t,{address:s}=tt();function r(d){return new Date(Number(d.tokenId)*1e3)}function o(d){return!!s.value&&r(d)<=new Date(Date.now())}let i=null;const{execute:a,isExecuting:c}=Un((d,f)=>{i=f,d({address:cn,abi:gr,functionName:"redeem",args:[[f.tokenId],[f.balance],s.value]})},{successMessage:"Successfully redeemed epoch",onSuccess:()=>{n("redeemed",i),i=null},onError:()=>{i=null}});function u(d){return r(d).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function l(d){return Ie(d.balance,18n)}return(d,f)=>{const p=Pt,m=Mt,h=zo;return F(),fe(h,{class:"redemptions-user-table",columns:[{label:"Unlock",align:"end"},{label:"Amount",align:"end"},""],rows:d.redemptions},{row:Y(({item:y})=>[T("div",aB,Z(u(y)),1),T("div",cB,[$(p,{type:"dollar",value:l(y),precision:4,"show-symbol":!1},null,8,["value"])]),T("div",uB,[$(m,{class:"primary",disabled:v(c)||!o(y),"chain-id":v(It).id,onClick:b=>v(a)(y)},{default:Y(()=>f[0]||(f[0]=[we(" Redeem ")])),_:2},1032,["disabled","chain-id","onClick"])])]),_:1},8,["rows"])}}}),dB=pe(lB,[["__scopeId","data-v-32be4f3a"]]),fB={class:"redemptions-user"},pB={key:0,class:"right"},mB={key:1,class:"right no-data"},hB=ae({__name:"RedemptionsUser",setup(e){const{address:t}=tt(),{data:n,isLoading:s}=qN(t),r=le([]),o=M(()=>n.value.filter(a=>!r.value.find(u=>u.tokenId===a.tokenId&&u.balance===a.balance)));function i(a){r.value.push(a)}return(a,c)=>(F(),J("div",fB,[c[0]||(c[0]=T("div",{class:"left"},[T("div",{class:"title"},"Redemptions"),T("div",{class:"info"},[we(" Your "),T("strong",null,"upxCVX"),we(" holdings represent burned "),T("strong",null,"pxCVX"),we(" used to initiate redemption of underlying "),T("strong",null,"CVX"),we(". You can redeem for underlying "),T("strong",null,"CVX"),we(" anytime after the unlock date. ")]),T("a",{href:"https://docs.redacted.finance/products/pirex/pxcvx/upxcvx-unlocking",target:"_blank"}," Learn More ")],-1)),v(o).length>0?(F(),J("div",pB,[$(dB,{redemptions:v(o),loading:v(s),onRedeemed:i},null,8,["redemptions","loading"])])):(F(),J("div",mB," No pending redemptions for "+Z(v(Hl)(v(t))),1))]))}}),yB=pe(hB,[["__scopeId","data-v-d2bea8fa"]]),bB={class:"tabs"},gB=ae({__name:"UserInfo",setup(e){const n=le(["rewards","redemptions"][0]),s=r=>{n.value=r};return(r,o)=>{const i=V6,a=He;return F(),fe(a,{title:"User Info"},{actions:Y(()=>[T("div",bB,[$(i,{"model-value":v(n)==="rewards",onClick:o[0]||(o[0]=c=>s("rewards"))},{default:Y(()=>o[2]||(o[2]=[we(" Rewards ")])),_:1},8,["model-value"]),$(i,{"model-value":v(n)==="redemptions",onClick:o[1]||(o[1]=c=>s("redemptions"))},{default:Y(()=>o[3]||(o[3]=[we(" Redemptions ")])),_:1},8,["model-value"])])]),default:Y(()=>[v(n)==="rewards"?(F(),fe(iB,{key:0})):ye("",!0),v(n)==="redemptions"?(F(),fe(yB,{key:1})):ye("",!0)]),_:1})}}}),vB=pe(gB,[["__scopeId","data-v-3893b341"]]),wB=[{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"lockedBalances",outputs:[{internalType:"uint256",name:"total",type:"uint256"},{internalType:"uint256",name:"unlockable",type:"uint256"},{internalType:"uint256",name:"locked",type:"uint256"},{components:[{internalType:"uint112",name:"amount",type:"uint112"},{internalType:"uint112",name:"boosted",type:"uint112"},{internalType:"uint32",name:"unlockTime",type:"uint32"}],internalType:"struct CvxLockerV2.LockedBalance[]",name:"lockData",type:"tuple[]"}],stateMutability:"view",type:"function"}],_B={class:"radio"},xB=["checked","value","name"],CB=["aria-checked"],AB={class:"radio-label"},TB=ae({__name:"RadioButton",props:ps({values:{},value:{},name:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:ps(["change"],["update:modelValue"]),setup(e,{emit:t}){const n=Do(e,"modelValue"),s=t,r=o=>{o.target.checked&&(n.value=e.value),s("change",e.value)};return(o,i)=>(F(),J("label",_B,[T("input",{type:"radio",checked:n.value===o.value,value:o.value,name:o.name,onChange:r},null,40,xB),T("span",{class:Pe(["radio-mark",{checked:n.value===o.value}]),role:"radio","aria-checked":n.value===o.value},i[0]||(i[0]=[T("span",{class:"inner-circle"},null,-1)]),10,CB),T("span",AB,[Ze(o.$slots,"default",{},void 0,!0)])]))}}),EB=pe(TB,[["__scopeId","data-v-3506293d"]]),SB={class:"end"},PB={class:"end"},kB={class:"center"},IB=ae({__name:"RedemptionsInitTable",props:{redemptions:{}},emits:["redemption"],setup(e,{emit:t}){const n=t;function s(a){return new Date(a*1e3).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}function r(a){return Number(a.toFixed(a>100?0:2)).toLocaleString()}const o=le(void 0),i=M(()=>e.redemptions.map(a=>a.lockIndex));return Ce(o,a=>{const c=e.redemptions.find(u=>u.lockIndex===a);c&&n("redemption",c)}),(a,c)=>{const u=Pt,l=EB,d=zo;return F(),fe(d,{class:"redemptions-init-table",columns:["Unlock Date",{label:"CVX Available",align:"end"},{label:"Early Unlock Fee",align:"end"},""],rows:a.redemptions,onSelected:c[1]||(c[1]=f=>o.value=f.lockIndex)},{row:Y(({item:f})=>[T("div",null,Z(s(f.unlockTime)),1),T("div",SB,Z(r(f.cvxAvailable)),1),T("div",PB,[$(u,{type:"percentage",value:f.fee},null,8,["value"])]),T("div",kB,[$(l,{modelValue:v(o),"onUpdate:modelValue":c[0]||(c[0]=p=>$e(o)?o.value=p:null),name:"redemption",values:v(i),value:f.lockIndex},null,8,["modelValue","values","value"])])]),_:1},8,["rows"])}}}),RB=pe(IB,[["__scopeId","data-v-47853f53"]]);function W6(e,t,n,s,r){const{maxApprove:o=!0}=r??{},i=M(()=>!!t.value),{data:a,refetch:c}=Tt({abi:dn,address:e,functionName:"allowance",args:M(()=>[t.value,n]),query:{enabled:i,initialData:0n,initialDataUpdatedAt:0}}),u=M(()=>{if(a.value===void 0||!i.value)return!1;const f=s.value??0n;return a.value<f});MI(s,()=>{i.value&&c()},{debounce:200});const{execute:l,isExecuting:d}=Un(f=>{const p=o?Hm:s.value;if(!p)throw new Error("No approval spend amount given.");f({abi:dn,address:v(e),functionName:"approve",args:[n,p]})},{onSuccess:()=>{i.value&&c()},showSuccess:!1});return{allowance:a,needsApprove:u,approve:l,isApproving:d}}const $B={class:"redemptions-init-body"},MB={class:"input"},OB=1e6,LB=ae({__name:"ModalRedemptionsInit",emits:["close"],setup(e,{emit:t}){const n=t,s=M(()=>k.value?"Approving...":L.value?"Redeeming...":x.value?"Approve":"Redeem"),{data:r}=Tt({abi:gr,address:cn,functionName:"fees",args:[1]}),{data:o}=Tt({abi:gr,address:cn,functionName:"fees",args:[2]}),{data:i}=Tt({abi:gr,address:cn,functionName:"MAX_REDEMPTION_TIME"}),{data:a,refetch:c}=Tt({abi:wB,address:Eh,functionName:"lockedBalances",args:[cn]});function u(X){if(!o.value||!r.value||!i.value)return 0;const z=Date.now()/1e3;return(r.value-(r.value-o.value)*(X-z)/i.value)/OB*100}const l=rt(),d=ti(async()=>{if(!a.value)return[];const z=a.value[3].map(async({amount:ie,unlockTime:ne},te)=>{const ce=u(ne),he=await Jr(l,{abi:gr,address:cn,functionName:"redemptions",args:[BigInt(ne)]}),_e=Ie(ie-he,18n);return{lockIndex:te,unlockTime:ne,cvxAvailable:_e,fee:ce}});return Promise.all(z)},[]),f=js,{address:p}=tt(),{data:m,refetch:h}=Hr({address:p,token:js}),y=M(()=>{var X;return((X=m.value)==null?void 0:X.value)??0n}),b=M(()=>Ie(y.value,18n)),g=le(null),w=M(()=>typeof g.value=="number"?g.value:0),_=M(()=>$t(w.value,18n)),A=M(()=>{var X;return w.value>0&&w.value<=b.value&&w.value<=(((X=R.value)==null?void 0:X.cvxAvailable)??0)}),{needsApprove:x,approve:C,isApproving:k}=W6(js,p,cn,_,{maxApprove:!1});function S(){x.value?C():B()}const R=le(void 0),{execute:B,isExecuting:L}=Un(X=>{X({abi:gr,address:cn,functionName:"initiateRedemptions",args:[[BigInt(R.value.lockIndex)],1,[_.value],p.value]})},{successMessage:"You've succesfully redeemed pxCVX!",onSuccess:()=>{c(),h(),g.value=null}});return(X,z)=>{const ie=Gh,ne=ld,te=Mt,ce=He,he=ia;return F(),fe(he,{onClose:z[3]||(z[3]=_e=>n("close"))},{default:Y(()=>[$(ce,{title:"Pirex Convex Redemptions"},{default:Y(()=>[T("div",$B,[$(RB,{class:"redemptions-init-table",redemptions:v(d),onRedemption:z[0]||(z[0]=_e=>R.value=_e)},null,8,["redemptions"]),T("div",MB,[$(ie,{address:v(f)},null,8,["address"]),z[4]||(z[4]=T("div",{class:"symbol"},"pxCVX",-1)),$(ne,{modelValue:v(g),"onUpdate:modelValue":z[1]||(z[1]=_e=>$e(g)?g.value=_e:null),min:0,max:1/0,placeholder:v(b)},null,8,["modelValue","placeholder"]),T("a",{onClick:z[2]||(z[2]=_e=>g.value=v(b))},"Max"),$(te,{class:"primary",disabled:!v(A)||v(k)||v(L),"chain-id":v(It).id,onClick:S},{default:Y(()=>[we(Z(v(s)),1)]),_:1},8,["disabled","chain-id"])])])]),_:1})]),_:1})}}}),FB=pe(LB,[["__scopeId","data-v-7458a5d3"]]),NB={class:"redemptions-init-body"},BB=ae({__name:"RedemptionsInit",setup(e){const t=le(!1);return(n,s)=>{const r=Mt,o=He;return F(),fe(o,{title:"Redemptions"},{default:Y(()=>[T("div",NB,[s[3]||(s[3]=T("div",{class:"info"}," Burn pxCVX to initiate a withdrawal of CVX from the protocol. Rewards can still be claimed until redemption date. ",-1)),s[4]||(s[4]=T("a",{href:"https://docs.redacted.finance/products/pirex/pxcvx/upxcvx-unlocking",target:"_blank"}," Learn More ",-1)),$(r,{class:"primary",onClick:s[0]||(s[0]=i=>t.value=!0)},{default:Y(()=>s[2]||(s[2]=[we(" Initiate Redemption ")])),_:1})]),$(FB,{show:v(t),onClose:s[1]||(s[1]=i=>t.value=!1)},null,8,["show"])]),_:1})}}}),DB=pe(BB,[["__scopeId","data-v-3d518a78"]]),UB={class:"option"},VB={class:"label"},jB=ae({__name:"SelectToken",props:ps({tokens:{}},{modelValue:{required:!0},modelModifiers:{}}),emits:ps(["select"],["update:modelValue"]),setup(e,{emit:t}){const n=Do(e,"modelValue"),s=t,r=o=>{s("select",o)};return Ce(()=>e.tokens,()=>{e.tokens.length>0&&r(e.tokens[0])},{immediate:!0}),(o,i)=>{const a=Gh,c=ca;return F(),fe(c,{options:o.tokens,selected:n.value,onSelect:r},{option:Y(({option:{address:u,symbol:l}})=>[T("div",UB,[$(a,{class:"icon",address:u},null,8,["address"]),T("div",VB,Z(l??"?"),1)])]),_:1},8,["options","selected"])}}}),HB=pe(jB,[["__scopeId","data-v-db632c27"]]),zB=[{inputs:[{internalType:"enum LpxCvx.Token",name:"source",type:"uint8"},{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minReceived",type:"uint256"},{internalType:"uint256",name:"fromIndex",type:"uint256"},{internalType:"uint256",name:"toIndex",type:"uint256"}],name:"swap",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"}],name:"unwrap",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"}],name:"wrap",outputs:[],stateMutability:"nonpayable",type:"function"}],qB={class:"swap-body"},WB={class:"input"},GB={class:"slippage"},XB={style:{"grid-area":"info"},class:"info"},KB={class:"explanation"},QB={class:"discount"},ZB={style:{"grid-area":"label1"}},YB={style:{"grid-area":"percentage"}},JB={style:{"grid-area":"label2"}},eD={style:{"grid-area":"symbol"}},hd=ae({__name:"ModalSwap",emits:["close","yes","no"],setup(e,{emit:t}){const{t:n}=Me(),s=t,r=M(()=>S.value?"Approving...":L.value?"Swapping...":C.value?"Approve":"Swap"),{address:o}=tt(),i=[{address:js,symbol:"pxCVX"},{address:An,symbol:"CVX"}],a=le(i[0]),c=M(()=>{const X=i[a.value.symbol==="pxCVX"?0:1],z=i[a.value.symbol==="pxCVX"?1:0];return{from:X,to:z}}),{data:u,refetch:l}=Hr({address:o,token:M(()=>c.value.from.address)}),d=M(()=>{var X;return((X=u.value)==null?void 0:X.value)??0n}),f=M(()=>Ie(d.value,18n)),p=le(null),m=M(()=>typeof p.value=="number"?p.value:0),h=M(()=>$t(m.value,18n)),y=M(()=>m.value>0&&m.value<=f.value&&w.value>0n),b=le(.03),g=M(()=>m.value*(1-b.value)),w=M(()=>$t(g.value,18n)),_=M(()=>m.value<100?$t(100,18n):h.value),{data:A}=Tt({abi:Or,address:Ph,functionName:"get_dy",args:M(()=>{const X=c.value.from.symbol==="pxCVX"?1n:0n;return[X,X===1n?0n:1n,_.value]})}),x=M(()=>{const X=Ie(_.value,18n);return 100*Ie(A.value??0n,18n)/X}),{needsApprove:C,approve:k,isApproving:S}=W6(M(()=>c.value.from.address),o,Ab,h,{maxApprove:!1});function R(){C.value?k():B()}const{execute:B,isExecuting:L}=Un(X=>{const z=c.value.from.symbol==="pxCVX"?1:0,ie=z===1?0:1;X({abi:zB,address:Ab,functionName:"swap",args:[z,h.value,w.value,BigInt(z),BigInt(ie)]})},{successMessage:"You've succesfully swapped!",onSuccess:()=>{l(),p.value=null}});return(X,z)=>{const ie=HB,ne=ld,te=Pt,ce=ud,he=Mt,_e=He,Fe=ia;return F(),fe(Fe,{onClose:z[6]||(z[6]=Ae=>s("close"))},{default:Y(()=>[$(_e,{title:"Swap"},{default:Y(()=>[T("div",qB,[T("div",WB,[$(ie,{modelValue:v(a),"onUpdate:modelValue":z[0]||(z[0]=Ae=>$e(a)?a.value=Ae:null),class:"token-select",tokens:i,onSelect:z[1]||(z[1]=Ae=>a.value=Ae)},null,8,["modelValue"]),$(ne,{modelValue:v(p),"onUpdate:modelValue":z[2]||(z[2]=Ae=>$e(p)?p.value=Ae:null),min:0,max:1/0,placeholder:v(f)},null,8,["modelValue","placeholder"]),T("a",{onClick:z[3]||(z[3]=Ae=>p.value=v(f))},"Max")]),z[8]||(z[8]=T("h3",null,"Slippage",-1)),T("div",GB,[T("div",XB,[T("div",KB,Z(v(n)("slippage-info")),1),T("div",QB,[z[7]||(z[7]=T("div",{class:"title"},"Current discount",-1)),$(te,{type:"percentage",value:v(x)},null,8,["value"])])]),T("span",ZB,Z(v(n)("percentage")),1),$(ce,{modelValue:v(b),"onUpdate:modelValue":z[4]||(z[4]=Ae=>$e(b)?b.value=Ae:null),style:{"grid-area":"slider"},min:.001,max:.2,step:.001},null,8,["modelValue"]),T("span",YB,Z((Math.round(v(b)*100*1e3)/1e3).toFixed(2))+"% ",1),T("span",JB,Z(v(n)("min-amount")),1),$(ne,{modelValue:v(g),"onUpdate:modelValue":z[5]||(z[5]=Ae=>$e(g)?g.value=Ae:null),disabled:"",style:{"grid-area":"input"},min:0,max:1/0},null,8,["modelValue"]),T("span",eD,Z(v(c).to.symbol),1)]),$(he,{class:"primary",disabled:!v(y)||v(S)||v(L),"chain-id":v(It).id,onClick:R},{default:Y(()=>[we(Z(v(r)),1)]),_:1},8,["disabled","chain-id"])])]),_:1})]),_:1})}}});function Wg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"price-modal-title":{t:0,b:{t:2,i:[{t:3}],s:"Price control"}},percentage:{t:0,b:{t:2,i:[{t:3}],s:"Percentage"}},"min-amount":{t:0,b:{t:2,i:[{t:3}],s:"Min Amount"}},"no-zero":{t:0,b:{t:2,i:[{t:3}],s:"Zero min amount not allowed"}},"slippage-info":{t:0,b:{t:2,i:[{t:3}],s:"Price control is a safeguard against excessive slippage or sandwich attacks. By setting a minimum percentage for your input, you establish a lower limit for your returns. If you encounter a slippage error, the value you set might be too low. A slight increase of one or two percent could help, but don't make it too high to ensure your protection."}}}})}function Gg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{"price-modal-title":{t:0,b:{t:2,i:[{t:3}],s:"价格控制"}},percentage:{t:0,b:{t:2,i:[{t:3}],s:"百分比"}},"min-amount":{t:0,b:{t:2,i:[{t:3}],s:"最小数量"}},"no-zero":{t:0,b:{t:2,i:[{t:3}],s:"最小数量不能为0"}},"slippage-info":{t:0,b:{t:2,i:[{t:3}],s:"价格控制是防止过度滑点或夹心层攻击的一种保障措施。通过设定输入的最低百分比，可以为收益设定一个下限。如果您遇到滑点错误，您设定的值可能太低。稍微增加一到两个百分点可能会有帮助，但不要太高，以确保您的保护。"}}}})}function Xg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{"price-modal-title":{t:0,b:{t:2,i:[{t:3}],s:"Contrôle des prix"}},percentage:{t:0,b:{t:2,i:[{t:3}],s:"Pourcentage"}},"min-amount":{t:0,b:{t:2,i:[{t:3}],s:"Montant minimum"}},"no-zero":{t:0,b:{t:2,i:[{t:3}],s:"Montant minimum zéro non autorisé"}},"slippage-info":{t:0,b:{t:2,i:[{t:3}],s:"Le contrôle des prix est une protection contre les dérapages excessifs ou les attaques en sandwich. En fixant un pourcentage minimum pour vos intrants, vous établissez une limite inférieure pour vos retours. Si vous rencontrez une erreur de dérapage, la valeur que vous avez fixée est peut-être trop basse. Une légère augmentation d'un ou deux pour cent pourrait être utile, mais ne la fixez pas trop haut pour assurer votre protection."}}}})}typeof Wg=="function"&&Wg(hd);typeof Gg=="function"&&Gg(hd);typeof Xg=="function"&&Xg(hd);const tD=pe(hd,[["__scopeId","data-v-8fd885de"]]),nD={class:"swap-body"},sD=ae({__name:"Swap",setup(e){const t=le(!1);return(n,s)=>{const r=Mt,o=He;return F(),fe(o,{title:"Swap"},{default:Y(()=>[T("div",nD,[s[3]||(s[3]=T("div",{class:"info"},[we(" Swap "),T("strong",null,"pxCVX"),we(" for "),T("strong",null,"CVX"),we(" or vice versa though the curve pool. ")],-1)),s[4]||(s[4]=T("a",{href:"https://docs.redacted.finance/products/pirex/convex/pxcvx-cvx-lp",target:"_blank"}," Learn More ",-1)),$(r,{class:"primary",onClick:s[0]||(s[0]=i=>t.value=!0)},{default:Y(()=>s[2]||(s[2]=[we(" Swap ")])),_:1})]),$(tD,{show:v(t),onClose:s[1]||(s[1]=i=>t.value=!1)},null,8,["show"])]),_:1})}}}),rD=pe(sD,[["__scopeId","data-v-6250f47e"]]),oD={class:"dashboard"},iD={style:{"grid-area":"left"},class:"col"},aD={style:{"grid-area":"right"},class:"col"},cD=ae({__name:"Pirex.page",setup(e){const t=new zh(mn()),n=new pn,s=new M6(mn()),{isConnected:r,address:o}=tt(),i=Nc(),{claim:a}=Ns(t,"ucvx",o,!0);Ce(a,l=>i.claims.ucvx=l??void 0,{immediate:!0}),Ce(o,u),Gn(u);const c=rt();function u(){const l=L6(c,n,s),d={createZapsDeposit:f=>N6(()=>c,()=>o.value,f),createZapsWithdrawal:f=>D6(()=>c,()=>o.value,f)};i.pounders[l.id]={pounder:l,zapsFactories:d,state:pr()},i.updateClaim(l.id,a.value??void 0)}return(l,d)=>(F(),J("div",oD,[v(i).pounders.ucvx?(F(),fe(Zp,{key:0,style:{"grid-area":"pounder"},"pounder-id":"ucvx"})):ye("",!0),T("div",iD,[$(xN),v(r)?(F(),fe(vB,{key:0})):ye("",!0)]),T("div",aD,[$(DB),$(rD)])]))}}),uD=pe(cD,[["__scopeId","data-v-8778b644"]]),lD=[{path:"/pirex",name:"pirex",component:uD}],dD={title:"Pirex",titleRoute:"/pirex",visible:!0,planeX:165,menuHeader:l6,items:[],forceShowMenu:!1},fD={class:"docs"},pD={class:"icon"},mD={key:0,style:{"margin-right":"0.75rem"}},hD=["innerHTML"],yd=ae({__name:"Documentation",props:{extra:{default:""}},setup(e){const{t}=Me();return(n,s)=>{const r=N_,o=He;return F(),fe(o,null,{default:Y(()=>[T("div",fD,[T("div",pD,[$(r)]),T("h1",null,[n.extra?(F(),J("span",mD,Z(n.extra),1)):ye("",!0),T("span",{innerHTML:v(t)("docs")},null,8,hD)])])]),_:1})}}});function Kg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{docs:{t:0,b:{t:2,i:[{t:3}],s:'Read our docs <a href="https://docs.llama.airforce" target="_blank">here</a>.'}}}})}function Qg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{docs:{t:0,b:{t:2,i:[{t:3}],s:'阅读我们的文件<a href="https://docs.llama.airforce" target="_blank">这里</a>.'}}}})}function Zg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{docs:{t:0,b:{t:2,i:[{t:3}],s:'Lisez notre documentation <a href="https://docs.llama.airforce" target="_blank">ici</a>.'}}}})}typeof Kg=="function"&&Kg(yd);typeof Qg=="function"&&Qg(yd);typeof Zg=="function"&&Zg(yd);const Jp=pe(yd,[["__scopeId","data-v-4c348e6e"]]),yD={class:"migrations"},bD=["innerHTML"],gD={class:"actions"},bd=ae({__name:"MigrateUBal",setup(e){const{t}=Me(),{address:n}=tt(),s=M(()=>t("migrateUBal",[(Math.round(Ie(l.value,18n)*1e3)/1e3).toFixed(3)])),r=M(()=>l.value>0n&&!a.value),o=M(()=>l.value===0n&&p.value>0n&&!a.value),i=M(()=>{const b=$t(.1,18n);return l.value>b}),a=le(!1),{data:c,refetch:u}=Hr({address:n,token:wb}),l=M(()=>{var b;return((b=c.value)==null?void 0:b.value)??0n}),{data:d,refetch:f}=Hr({address:n,token:ci}),p=M(()=>{var b;return((b=d.value)==null?void 0:b.value)??0n}),m=rt();function h(){if(!(!i.value||a.value))return Qs(a,async()=>{const b=await Le(m,{abi:st,address:wb,functionName:"withdrawAll",args:[n.value]});await Oe(m,{hash:b}),await Promise.all([u(),f()])})}function y(){if(!(!i.value||a.value))return Qs(a,async()=>{let b=await Le(m,{abi:dn,address:ci,functionName:"approve",args:[$o,p.value]});await Oe(m,{hash:b}),b=await Le(m,{abi:st,address:$o,functionName:"deposit",args:[n.value,p.value]}),await Oe(m,{hash:b}),window.location.reload()})}return(b,g)=>{const w=He;return v(i)?(F(),fe(w,{key:0,class:"border-flash"},{default:Y(()=>[T("div",yD,[T("h1",{innerHTML:v(s)},null,8,bD),T("span",gD,[T("a",{class:Pe({disabled:!v(r)||v(a)}),onClick:h},Z(v(t)("withdraw")),3),T("a",{class:Pe({disabled:!v(o)||v(a)}),onClick:y},Z(v(t)("deposit")),3)])])]),_:1})):ye("",!0)}}});function Yg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{withdraw:{t:0,b:{t:2,i:[{t:3}],s:"Withdraw from old vault"}},deposit:{t:0,b:{t:2,i:[{t:3}],s:"Deposit into new vault"}},migrateUBal:{t:0,b:{t:2,i:[{t:3,v:"Hello ser, you have "},{t:5,i:0},{t:3,v:" uBAL you need to migrate! <br />It's sitting in the old pounder now, not earning rewards!"}]}}}})}function Jg(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{withdraw:{t:0,b:{t:2,i:[{t:3}],s:"从旧金库中提款"}},deposit:{t:0,b:{t:2,i:[{t:3}],s:"存款到新的金库"}},migrateUBal:{t:0,b:{t:2,i:[{t:3,v:"您好，您有"},{t:5,i:0},{t:3,v:" uBAL 需要迁移到新金库！ <br />您在旧金库中无法获得收益"}]}}}})}function ev(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{withdraw:{t:0,b:{t:2,i:[{t:3}],s:"Retirer de l'ancien coffre"}},deposit:{t:0,b:{t:2,i:[{t:3}],s:"Déposer dans le nouveau coffre"}},migrateUBal:{t:0,b:{t:2,i:[{t:3,v:"Bonjour, vous avez "},{t:5,i:0},{t:3,v:" uBAL que vous devez migrer! <br />Il est actuellement dans l'ancien pounder, il n'accumule pas de récompenses!"}]}}}})}typeof Yg=="function"&&Yg(bd);typeof Jg=="function"&&Jg(bd);typeof ev=="function"&&ev(bd);const vD=pe(bd,[["__scopeId","data-v-53c558cd"]]),wD=[{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAndStakeIn3PoolConvex",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsCrv",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"claimFromVaultAsCvx",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsEth",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromEth",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromUCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"inputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"depositViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}],_D={class:"migration"},xD=["innerHTML"],CD={class:"actions"},gd=ae({__name:"MigrateUCrv",setup(e){const{t}=Me(),{address:n}=tt(),{data:s}=Hr({address:n,token:qi}),r=M(()=>{var l;return((l=s.value)==null?void 0:l.value)??0n}),o=M(()=>t("migrateUCrv",[(Math.round(Ie(r.value,18n)*1e3)/1e3).toFixed(3)])),i=M(()=>{const l=$t(.1,18n);return r.value>l}),a=le(!1),c=rt();function u(){if(!(!i.value||a.value))return Qs(a,async()=>{let l=await Le(c,{abi:dn,address:qi,functionName:"approve",args:[Op,r.value]});await Oe(c,{hash:l}),l=await Le(c,{abi:wD,address:Op,functionName:"depositFromUCrv",args:[r.value,0n,n.value]}),await Oe(c,{hash:l}),window.location.reload()})}return(l,d)=>{const f=He;return v(i)?(F(),fe(f,{key:0,class:"migration border-flash"},{default:Y(()=>[T("div",_D,[T("h1",{innerHTML:v(o)},null,8,xD),T("span",CD,[T("a",{class:Pe({disabled:!v(i)||v(a)}),onClick:u},Z(v(t)(v(a)?"migrating":"migrate")),3)])])]),_:1})):ye("",!0)}}});function tv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrate"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migrating..."}},migrateUCrv:{t:0,b:{t:2,i:[{t:3,v:"Hello ser, you have "},{t:5,i:0},{t:3,v:" uCRV you need to migrate! <br />The old one will still work, but the new one has a few internal improvements!"}]}}}})}function nv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"迁移"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"迁移中..."}},migrateUCrv:{t:0,b:{t:2,i:[{t:3,v:"您好，您好 "},{t:5,i:0},{t:3,v:" uCRV 需要迁移到新金库! <br />旧的仍然可以工作，但新的有一些内部改进!"}]}}}})}function sv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrer"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migration en cours..."}},migrateUCrv:{t:0,b:{t:2,i:[{t:3,v:"Bonjour, vous avez "},{t:5,i:0},{t:3,v:" uCRV que vous devez migrer! <br />L'ancien fonctionnera toujours, mais le nouveau a quelques améliorations internes!"}]}}}})}typeof tv=="function"&&tv(gd);typeof nv=="function"&&nv(gd);typeof sv=="function"&&sv(gd);const AD=pe(gd,[["__scopeId","data-v-05331089"]]),TD=[{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAndStakeIn3PoolConvex",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsCrv",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"claimFromVaultAsCvx",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsEth",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromEth",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromUCrv",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"inputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"depositViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}],ED={class:"migration"},SD=["innerHTML"],PD={class:"actions"},vd=ae({__name:"MigrateUCrvV2",setup(e){const{t}=Me(),{address:n}=tt(),{data:s}=Hr({address:n,token:vb}),r=M(()=>{var l;return((l=s.value)==null?void 0:l.value)??0n}),o=M(()=>t("migrateUCrv",[(Math.round(Ie(r.value,18n)*1e3)/1e3).toFixed(3)])),i=M(()=>{const l=$t(.1,18n);return r.value>l}),a=le(!1),c=rt();function u(){if(!(!i.value||a.value))return Qs(a,async()=>{let l=await Le(c,{abi:dn,address:vb,functionName:"approve",args:[_b,r.value]});await Oe(c,{hash:l}),l=await Le(c,{abi:TD,address:_b,functionName:"depositFromUCrv",args:[r.value,0n,n.value]}),await Oe(c,{hash:l}),window.location.reload()})}return(l,d)=>{const f=He;return v(i)?(F(),fe(f,{key:0,class:"border-flash"},{default:Y(()=>[T("div",ED,[T("h1",{innerHTML:v(o)},null,8,SD),T("span",PD,[T("a",{class:Pe({disabled:!v(i)||v(a)}),onClick:u},Z(v(t)(v(a)?"migrating":"migrate")),3)])])]),_:1})):ye("",!0)}}});function rv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrate"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migrating..."}},migrateUCrv:{t:0,b:{t:2,i:[{t:3,v:"Hello ser, you have "},{t:5,i:0},{t:3,v:" uCRV you need to migrate! <br />It might still earn yield, but it will be subpar!"}]}}}})}function ov(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"迁移"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"迁移中..."}},migrateUCrv:{t:0,b:{t:2,i:[{t:3,v:"您好，您好 "},{t:5,i:0},{t:3,v:" uCRV 需要迁移到新金库! <br />您在旧金库中可以继续获得收益，但会逐步减少!"}]}}}})}function iv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrer"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migration en cours..."}},migrateUCrv:{t:0,b:{t:2,i:[{t:3,v:"Bonjour, vous avez "},{t:5,i:0},{t:3,v:" uCRV que vous devez migrer! <br />Il pourrait toujours générer du rendement, mais il serait inférieur!"}]}}}})}typeof rv=="function"&&rv(vd);typeof ov=="function"&&ov(vd);typeof iv=="function"&&iv(vd);const kD=pe(vd,[["__scopeId","data-v-51854540"]]),ID=[{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"claimFromVaultAsCvx",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsEth",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsFxs",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultAsUsdt",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"outputToken",type:"address"},{internalType:"address",name:"to",type:"address"}],name:"claimFromVaultViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositFromEth",outputs:[],stateMutability:"payable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositFromFxs",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"to",type:"address"}],name:"depositFromUFxs",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[{internalType:"uint256",name:"amount",type:"uint256"},{internalType:"uint256",name:"minAmountOut",type:"uint256"},{internalType:"address",name:"router",type:"address"},{internalType:"address",name:"inputToken",type:"address"},{internalType:"address",name:"to",type:"address"},{internalType:"bool",name:"lock",type:"bool"}],name:"depositViaUniV2EthPair",outputs:[],stateMutability:"nonpayable",type:"function"}];async function RD(e,t){const n=ft(t);if(!n)throw Error("Cannot create public viem client");const s=await Wi(e,n).then(a=>a).catch(()=>1/0),r=St({abi:st,address:_o,client:n}),o=await eo(r);return s*o}const $D={class:"migration"},MD=["innerHTML"],OD={class:"actions"},wd=ae({__name:"MigrateUFxs",setup(e){const{t}=Me(),n=new pn,{address:s}=tt(),{data:r}=Hr({address:s,token:_o}),o=M(()=>{var y;return((y=r.value)==null?void 0:y.value)??0n});let i=null;const a=le(0),c=le(0),u=le(!1),l=M(()=>t("migrateUFxs",[(Math.round(Ie(o.value,18n)*1e3)/1e3).toFixed(3)])),d=M(()=>{const y=$t(.1,18n);return o.value>y}),f=le(!1),p=rt();async function m(y){if(!(!d.value||f.value)){if(!y){u.value=!0,i=()=>m(!0);const b=await n.getPrice(is).then(w=>w.price).catch(()=>1/0),g=await RD(n,p);c.value=Ie(Zs(o.value,g,b,0),18n);return}await Qs(f,async()=>{let b=await Le(p,{abi:dn,address:_o,functionName:"approve",args:[Fp,o.value]});await Oe(p,{hash:b});const g=$t(a.value,18n);b=await Le(p,{abi:ID,address:Fp,functionName:"depositFromUFxs",args:[o.value,g,s.value]}),await Oe(p,{hash:b}),window.location.reload()})}}const h=async y=>{u.value=!1,a.value=y,await(i==null?void 0:i())};return(y,b)=>{const g=He;return v(d)?(F(),fe(g,{key:0,class:"border-flash"},{default:Y(()=>[T("div",$D,[T("h1",{innerHTML:v(l)},null,8,MD),T("span",OD,[T("a",{class:Pe({disabled:!v(d)||v(f)}),onClick:b[0]||(b[0]=w=>m(!1))},Z(v(t)(v(f)?"migrating":"migrate")),3)]),$(Wh,{"symbol-output":"cvxFXS",show:v(u),"min-amount-out-ref":v(c),onClose:b[1]||(b[1]=w=>u.value=!1),onNo:b[2]||(b[2]=w=>u.value=!1),onYes:h},null,8,["show","min-amount-out-ref"])])]),_:1})):ye("",!0)}}});function av(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrate"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migrating..."}},migrateUFxs:{t:0,b:{t:2,i:[{t:3,v:"Hello ser, you have "},{t:5,i:0},{t:3,v:" uFXS you need to migrate! <br />It's sitting in the old pounder now, not earning rewards!"}]}}}})}function cv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"迁移"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"迁移中..."}},migrateUFxs:{t:0,b:{t:2,i:[{t:3,v:"您好，您有"},{t:5,i:0},{t:3,v:" uFXS 需要迁移到新金库！ <br />您在旧金库中无法获得收益"}]}}}})}function uv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrer"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migration en cours..."}},migrateUFxs:{t:0,b:{t:2,i:[{t:3,v:"Bonjour, vous avez "},{t:5,i:0},{t:3,v:" uFXS que vous devez migrer! <br />Il est actuellement dans l'ancien pounder, il n'accumule pas de récompenses!"}]}}}})}typeof av=="function"&&av(wd);typeof cv=="function"&&cv(wd);typeof uv=="function"&&uv(wd);const LD=pe(wd,[["__scopeId","data-v-02a21d96"]]),FD={class:"migration"},ND=["innerHTML"],BD={class:"actions"},_d=ae({__name:"MigrateStkCvxPrisma",setup(e){const{t}=Me(),{address:n}=tt(),{data:s}=Hr({address:n,token:Ia}),r=M(()=>{var l;return((l=s.value)==null?void 0:l.value)??0n}),o=M(()=>t("migrateStkCvxCrv",[(Math.round(Ie(r.value,18n)*1e3)/1e3).toFixed(3)])),i=M(()=>{const l=$t(.1,18n);return r.value>l}),a=le(!1),c=rt();function u(){if(!(!i.value||a.value))return Qs(a,async()=>{let l=await Le(c,{abi:dn,address:Ia,functionName:"approve",args:[Qu,r.value]});await Oe(c,{hash:l}),l=await Le(c,{abi:U6,address:Qu,functionName:"migrate",args:[r.value,n.value]}),await Oe(c,{hash:l}),window.location.reload()})}return(l,d)=>{const f=He;return v(i)?(F(),fe(f,{key:0,class:"border-flash"},{default:Y(()=>[T("div",FD,[T("h1",{innerHTML:v(o)},null,8,ND),T("span",BD,[T("a",{class:Pe({disabled:!v(i)||v(a)}),onClick:u},Z(v(t)(v(a)?"migrating":"migrate")),3)])])]),_:1})):ye("",!0)}}});function lv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrate"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migrating..."}},migrateStkCvxCrv:{t:0,b:{t:2,i:[{t:3,v:"Hello ser, it seems you have "},{t:5,i:0},{t:3,v:" cvxPRISMA staked in Convex. <br />Do you wish to move those cheaply into the pounder?"}]}}}})}function dv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"迁移"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"迁移中..."}},migrateStkCvxCrv:{t:0,b:{t:2,i:[{t:3,v:"您好，先生，您似乎在 Convex 下注了 "},{t:5,i:0},{t:3,v:" cvxPRISMA。 <br />你想廉价地把钱存入金库吗？"}]}}}})}function fv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{migrate:{t:0,b:{t:2,i:[{t:3}],s:"Migrer"}},migrating:{t:0,b:{t:2,i:[{t:3}],s:"Migration en cours..."}},migrateStkCvxCrv:{t:0,b:{t:2,i:[{t:3,v:"Bonjour, il semble que vous ayez "},{t:5,i:0},{t:3,v:" cvxPRISMA mis en jeu dans Convex. <br />Souhaitez-vous les transférer à bas prix dans le pounder?"}]}}}})}typeof lv=="function"&&lv(_d);typeof dv=="function"&&dv(_d);typeof fv=="function"&&fv(_d);const DD=pe(_d,[["__scopeId","data-v-765a8049"]]),UD=ae({__name:"Migrations",setup(e){return(t,n)=>(F(),J(De,null,[$(kD),$(AD),$(vD),$(LD),$(DD)],64))}}),VD={class:"dashboard"},xd=ae({__name:"Pounders.page",setup(e){const{t}=Me(),n=new zh(mn()),s=new pn,r=new M6(mn()),{address:o}=tt(),i=Nc(),a=M(()=>[i.pounders.ucrv,i.pounders.ucvx,i.pounders.uprisma].filter(Vp)),c=M(()=>[i.pounders.ubal,i.pounders.ufxs,i.pounders.ufxslp,i.pounders.ucrv2].filter(Vp));Gn(m);const{claim:u}=Ns(n,"union",o,!0),{claim:l}=Ns(n,"ufxs",o,!0),{claim:d}=Ns(n,"uprisma",o,!0),{claim:f}=Ns(n,"ucvx",o,!0);Ce(u,x=>i.claims.ucrv=x??void 0,{immediate:!0}),Ce(l,x=>i.claims.ufxs=x??void 0,{immediate:!0}),Ce(d,x=>i.claims.uprisma=x??void 0,{immediate:!0}),Ce(f,x=>i.claims.ucvx=x??void 0,{immediate:!0});const p=rt();function m(){h(),A(),y(),b(),w(),g(),_()}function h(){const x=L6(p,s,r),C={createZapsDeposit:k=>N6(()=>p,()=>o.value,k),createZapsWithdrawal:k=>D6(()=>p,()=>o.value,k)};i.pounders[x.id]={pounder:x,zapsFactories:C,state:pr()},i.updateClaim(x.id,f.value??void 0)}function y(){const x=u7(p,s),C={createZapsDeposit:k=>y7(()=>p,()=>o.value,k),createZapsWithdrawal:k=>b7(()=>p,()=>o.value,k)};i.pounders[x.id]={pounder:x,zapsFactories:C,state:pr()},i.updateClaim(x.id,u.value??void 0)}function b(){const x=l7(p,s),C={createZapsDeposit:k=>w7(()=>p,()=>o.value,k),createZapsWithdrawal:k=>_7(()=>p,()=>o.value,k)};i.pounders[x.id]={pounder:x,zapsFactories:C,state:pr()},i.updateClaim(x.id,l.value??void 0)}function g(){const x=p7(p,s),C={createZapsDeposit:k=>$7(()=>p,()=>o.value,k),createZapsWithdrawal:k=>M7(()=>p,()=>o.value,k)};i.pounders[x.id]={pounder:x,zapsFactories:C,state:pr()},i.updateClaim(x.id,d.value??void 0)}function w(){const x=d7(p,s),C={createZapsDeposit:k=>T7(()=>p,()=>o.value,k),createZapsWithdrawal:k=>E7(()=>p,()=>o.value,k)};i.pounders[x.id]={pounder:x,zapsFactories:C,state:pr()}}function _(){const x=f7(p,r),C={createZapsDeposit:k=>I7(()=>p,()=>o.value,k),createZapsWithdrawal:k=>R7(()=>p,()=>o.value,k)};i.pounders[x.id]={pounder:x,zapsFactories:C,state:pr()}}function A(){const x=c7(p,s),C={createZapsDeposit:k=>m7(()=>p,()=>o.value,k),createZapsWithdrawal:k=>h7(()=>p,()=>o.value,k)};i.pounders[x.id]={pounder:x,zapsFactories:C,state:pr()}}return Ce(o,m),(x,C)=>{const k=He;return F(),J("div",VD,[$(UD),$(Jp,{extra:v(t)("pounders-info")},null,8,["extra"]),(F(!0),J(De,null,Rt(v(a),S=>(F(),fe(Zp,{key:S.pounder.id,"pounder-id":S.pounder.id},null,8,["pounder-id"]))),128)),$(k,{class:"information"},{default:Y(()=>[we(Z(v(t)("pounders-info-deprecated")),1)]),_:1}),(F(!0),J(De,null,Rt(v(c),S=>(F(),fe(Zp,{key:S.pounder.id,"pounder-id":S.pounder.id},null,8,["pounder-id"]))),128))])}}});function pv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"en",resource:{"pounders-info":{t:0,b:{t:2,i:[{t:3}],s:"Union's auto-compounders streamline life for busy llamas."}},"pounders-info-deprecated":{t:0,b:{t:2,i:[{t:3}],s:"The following pounders are considered legacy. If you're lucky they still yield."}}}})}function mv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"zh",resource:{"pounders-info":{t:0,b:{t:2,i:[{t:3}],s:"Union的自动复投功能使辛劳的羊驼们更加方便管理他们的贿赂收益。"}},"pounders-info-deprecated":{t:0,b:{t:2,i:[{t:3}],s:"以下金库被视为传统金库。如果你幸运的话，它们还能产出。"}}}})}function hv(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"fr",resource:{"pounders-info":{t:0,b:{t:2,i:[{t:3}],s:"Les auto-compounders de l'Union rendent la vie un peu plus facile à gérer pour les llamas qui travaillent dur."}},"pounders-info-deprecated":{t:0,b:{t:2,i:[{t:3}],s:"Les pounders suivants sont considérés comme des héritages. Si vous avez de la chance, ils sont encore disponibles"}}}})}typeof pv=="function"&&pv(xd);typeof mv=="function"&&mv(xd);typeof hv=="function"&&hv(xd);const jD=pe(xd,[["__scopeId","data-v-37c347f4"]]),HD=[{path:"/pounders/",component:jD}],zD={title:"Pounders",titleRoute:"/pounders",visible:!0,planeX:270,menuHeader:d6,items:[],forceShowMenu:!1},qD={class:"tab-view"},WD={class:"tab-controls"},GD={class:"tab-headers"},XD=["onClick"],KD={key:0,class:"actions"},QD={class:"tabs"},ZD=ae({__name:"TabView",props:{active:{default:0}},emits:["tab"],setup(e,{emit:t}){const n=t,s=le(null),r=Am(),o=M(()=>r.default?r.default().filter(a=>a.props).map(a=>a):[]);Ce(()=>e.active,a=>{s.value=a,n("tab",{tab:o.value[a],index:s.value})},{immediate:!0});const i=(a,c)=>{a.props.disabled||(s.value=c,n("tab",{tab:o.value[c],index:s.value}))};return(a,c)=>(F(),J("div",qD,[T("div",WD,[T("ul",GD,[(F(!0),J(De,null,Rt(v(o),(u,l)=>(F(),J("li",{key:l,class:Pe(["tab-header",{active:v(s)===l,disabled:u.props.disabled}]),onClick:d=>i(u,l)},Z(u.props.header),11,XD))),128))]),a.$slots.actions?(F(),J("div",KD,[Ze(a.$slots,"actions",{},void 0,!0)])):ye("",!0)]),T("div",QD,[(F(!0),J(De,null,Rt(v(o),(u,l)=>wm((F(),J("div",{key:l,class:"tab"},[(F(),fe(Ou(u)))])),[[OC,v(s)===l]])),128))])]))}}),YD=pe(ZD,[["__scopeId","data-v-402cc8e6"]]),JD=ae({__name:"TabItem",props:{header:{},disabled:{type:Boolean}},setup(e){return(t,n)=>Ze(t.$slots,"default")}}),yv=[{inputs:[{internalType:"address",name:"",type:"address"},{internalType:"uint256",name:"",type:"uint256"}],name:"assetAllocations",outputs:[{internalType:"uint16",name:"",type:"uint16"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address[]",name:"members",type:"address[]"}],name:"getAllocations",outputs:[{internalType:"uint16[16][]",name:"",type:"uint16[16][]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint16[16]",name:"choices",type:"uint16[16]"}],name:"recordAllocation",outputs:[],stateMutability:"nonpayable",type:"function"}],G6=()=>[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],eU=()=>[1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];function lu(e){const t=G6();for(let n=0;n<t.length;n++)t[n]=e[n]??0;return t}function bv(e){const t=e.reduce((n,s)=>n+Math.abs(s),0);return e.map(n=>n/t)}function tU(e,t){return e.every((n,s)=>n===t[s])}const nU={class:"allocator"},sU={class:"airdrops"},rU={class:"lock"},oU={class:"label"},iU={class:"icon"},aU=["src"],cU={class:"percentage"},X6=ae({__name:"Allocator",setup(e){const{t}=Me(),{address:n}=tt(),s=le([{icon:rr,label:"uCRV",value:100,locked:!1},{icon:fs,label:"uFXS",value:0,locked:!1},{icon:Fo,label:"uCVX",value:0,locked:!1},{icon:Oo,label:"uPRISMA",value:0,locked:!1}]),r=M(()=>b.value?t("submitting"):t("submit")),o=M(()=>s.value.filter(w=>!w.locked).length>2),i=M(()=>0),a=M(()=>100),c=M(()=>.1),u=w=>w.icon,l=w=>w.label,d=w=>w.value,f=w=>w.locked,p=w=>{!w.locked&&!o.value||(w.locked=!w.locked)},{data:m}=Tt({abi:yv,address:Mp,functionName:"getAllocations",args:M(()=>[[n.value]]),query:{enabled:M(()=>!!n.value)}}),h=M(()=>{if(!m.value||m.value.length===0)return;let w=lu(m.value[0].map(Number));return w=tU(w,G6())?eU():w,w=lu(bv(w).map(_=>_*100)),w});Vi(h,w=>{s.value[0].value=w[0],s.value[1].value=w[1],s.value[2].value=w[2],s.value[3].value=w[3]});const{execute:y,isExecuting:b}=Un(w=>{let _=bv(lu(s.value.map(A=>A.value)));_=lu(_.map(A=>Math.round(A*1e4))),w({address:Mp,abi:yv,functionName:"recordAllocation",args:[_]})},{successMessage:()=>t("allocation-changed")}),g=(w,_)=>{s.value[_].value=w;const x=s.value.reduce((R,B)=>R+B.value,0)-100;let C=0;const k=[...s.value];k.splice(_,1);for(const R of k)if(!R.locked){let B=R.value-x/k.filter(L=>!L.locked).length;B<0&&(C+=B,B=0),R.value=B}const S=[...k].filter(R=>R.value>0&&!R.locked);for(const R of S)R.value+=C/S.length};return(w,_)=>{const A=rR,x=sR,C=ud,k=Pt,S=Mt,R=He;return F(),fe(R,null,{default:Y(()=>[T("div",nU,[T("div",sU,[(F(!0),J(De,null,Rt(v(s),(B,L)=>(F(),J("div",{key:B.label,class:"airdrop"},[T("div",rU,[f(B)?(F(),fe(A,{key:0,onClick:X=>p(B)},null,8,["onClick"])):(F(),fe(x,{key:1,class:Pe({canLock:v(o)}),onClick:X=>p(B)},null,8,["class","onClick"]))]),T("div",oU,[T("div",iU,[T("img",{src:u(B)},null,8,aU)]),we(" "+Z(l(B)),1)]),$(C,{class:"slider",min:v(i),max:v(a),step:v(c),"model-value":B.value,disabled:f(B),"onUpdate:modelValue":X=>g(X,L)},null,8,["min","max","step","model-value","disabled","onUpdate:modelValue"]),T("div",cU,[$(k,{"show-zero":"",type:"percentage",value:d(B),precision:1},null,8,["value"])])]))),128))]),$(S,{class:"action-button primary",disabled:v(b),"chain-id":v(It).id,onClick:v(y)},{default:Y(()=>[we(Z(v(r)),1)]),_:1},8,["disabled","chain-id","onClick"])])]),_:1})}}});function pt(e){const t=e;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{en:{apy:{t:0,b:{t:2,i:[{t:3}],s:"APY"}},tvl:{t:0,b:{t:2,i:[{t:3}],s:"TVL"}},submit:{t:0,b:{t:2,i:[{t:3}],s:"Submit"}},submitting:{t:0,b:{t:2,i:[{t:3}],s:"Submitting..."}},"allocation-changed":{t:0,b:{t:2,i:[{t:3}],s:"Allocation succesfully updated!"}},allocation:{t:0,b:{t:2,i:[{t:3}],s:"Allocation"}},"rewards-balance":{t:0,b:{t:2,i:[{t:3}],s:"Rewards Balance ($)"}},frozen:{t:0,b:{t:2,i:[{t:3}],s:"Bribe rewards are being processed, balances are temporarily frozen and show $0. No panik."}},"membership-activation":{t:0,b:{t:2,i:[{t:3,v:"New memberships will activate in "},{t:5,i:0}]}},delegate:{t:0,b:{t:2,i:[{t:3}],s:"Delegate"}},delegating:{t:0,b:{t:2,i:[{t:3}],s:"Delegating..."}},delegated:{t:0,b:{t:2,i:[{t:3}],s:"You're Delegated to Votium"}},"not-delegated":{t:0,b:{t:2,i:[{t:3}],s:"You're Not Delegated to Votium"}},"delegation-advice":{t:0,b:{t:2,i:[{t:3}],s:"Delegating to votium both automates voting and ensures you get the highest $/vlCVX possible."}},"delegation-changed":{t:0,b:{t:2,i:[{t:3}],s:"Delegation has been succesfully set to Votium."}},"claim-notice":{t:0,b:{t:2,i:[{t:3}],s:"Your unclaimed balance is already auto-compounding, so claiming is optional."}},"withdraw-as":{t:0,b:{t:2,i:[{t:3}],s:"Withdraw as:"}},"withdraw-as-token":{t:0,b:{t:2,i:[{t:3,v:"Withdraw as "},{t:5,i:0}]}},"swap-token":{t:0,b:{t:2,i:[{t:3,v:"Sell "},{t:5,i:0}]}},nothing:{t:0,b:{t:2,i:[{t:3}],s:"Nothing to claim"}},"claim-info":{t:0,b:{t:2,i:[{t:3,v:"If you change the 'withdraw as' asset, we will swap your "},{t:5,i:0},{t:3,v:" for the chosen asset before depositing in your wallet. "},{t:5,i:0},{t:3,v:" is a share token whose number stays constant. The underlying "},{t:5,i:1},{t:3,v:" value will grow as it compounds."}]}},title:{t:0,b:{t:2,i:[{t:3}],s:"Welcome to The Union"}},"join-1":{t:0,b:{t:2,i:[{t:3}],s:"Rising Ethereum gas costs, CVX locker dilution and an increasing amount of different Votium reward tokens makes it harder and harder for the small-time player to join in on the Votium pool parties and make a profit."}},"join-2":{t:0,b:{t:2,i:[{t:3}],s:"It is time for the working class to unionize and collectively pool their rewards together and convert it into a single claimable asset without wastefully burning profits, while also turbo charging the flywheel we all love so dearly."}},"join-3":{t:0,b:{t:2,i:[{t:3}],s:"By joining The Union we will take care of your bribe rewards and consolidate them into auto compounded cvxCRV."}},"modal-title":{t:0,b:{t:2,i:[{t:3}],s:"Membership of the Union"}},"no-lock":{t:0,b:{t:2,i:[{t:3}],s:"You have not locked any CVX yet. Are you sure want to join the Union?"}},join:{t:0,b:{t:2,i:[{t:3}],s:"Join the Union"}},joining:{t:0,b:{t:2,i:[{t:3}],s:"Joining ..."}},"already-forwarded":{t:0,b:{t:2,i:[{t:3}],s:"Already forwarded to another address"}},"forwarding-in-progress":{t:0,b:{t:2,i:[{t:3}],s:"Address forwarding expiration in progress"}},joined:{t:0,b:{t:2,i:[{t:3}],s:"You've succesfully joined the Union, welcome comrade!"}},left:{t:0,b:{t:2,i:[{t:3}],s:"You're succesfully left the Union. Goodbye comrade!"}},"nothing-locked":{t:0,b:{t:2,i:[{t:3}],s:"You do not have any CVX locked for the upcoming round"}},member:{t:0,b:{t:2,i:[{t:3}],s:"You're a member of The Union"}},"no-member":{t:0,b:{t:2,i:[{t:3}],s:"You're not a member of The Union"}},leave:{t:0,b:{t:2,i:[{t:3}],s:"Leave The Union"}},"leave-title":{t:0,b:{t:2,i:[{t:3}],s:"Membership of the Union"}},"leave-confirmation":{t:0,b:{t:2,i:[{t:3}],s:"Are you sure you want to leave The Union?"}},"leave-notice":{t:0,b:{t:2,i:[{t:3}],s:"When you leave you will not be able to rejoin until at least one round has passed."}},rejoin:{t:0,b:{t:2,i:[{t:3}],s:"Rejoin The Union"}},"active-in":{t:0,b:{t:2,i:[{t:3,v:"Membership active in "},{t:5,i:0}]}},"prisma-warning":{t:0,b:{t:2,i:[{t:3}],s:"Beware of phishing scams and imposters! Always double-check the URL before interacting with smart contracts. Always do your due diligence. It's not worth getting rekt over shortcuts or neglect."}},"prisma-info":{t:0,b:{t:2,i:[{t:3}],s:"Prisma, a DeFi tool, leverages Ethereum's LSTs to mint mkUSD, a stablecoin boosted by incentives on Curve and Convex Finance. Users can receive trading fees, CRV, CVX, and PRISMA on top of their Ethereum staking rewards. Built on Liquity, it's a resilient protocol with a decentralized stablecoin, overseen by the Prisma DAO."}},"prisma-deadline":{t:0,b:{t:2,i:[{t:3}],s:"The airdrop is claimable until <strong>January 2, 2024</strong>.<br>Beyond that date, the unclaimed amount will be converted into CVX and distributed to the people in the uCVX pounder."}},"prisma-learn-more":{t:0,b:{t:2,i:[{t:3}],s:"Learn more about Prisma."}},"prisma-loading":{t:0,b:{t:2,i:[{t:3}],s:"Loading..."}},"prisma-eligible-yay":{t:0,b:{t:2,i:[{t:3}],s:"You're eligible!"}},"prisma-eligible-nay":{t:0,b:{t:2,i:[{t:3}],s:"You're <strong>NOT</strong> eligible"}},"prisma-claim":{t:0,b:{t:2,i:[{t:3}],s:"Claim cvxPRISMA"}}},zh:{apy:{t:0,b:{t:2,i:[{t:3}],s:"APY"}},tvl:{t:0,b:{t:2,i:[{t:3}],s:"TVL"}},submit:{t:0,b:{t:2,i:[{t:3}],s:"递交"}},submitting:{t:0,b:{t:2,i:[{t:3}],s:"递交..."}},"allocation-changed":{t:0,b:{t:2,i:[{t:3}],s:"分配成功更新！"}},allocation:{t:0,b:{t:2,i:[{t:3}],s:"分配"}},"rewards-balance":{t:0,b:{t:2,i:[{t:3}],s:"奖励余额 ($)"}},frozen:{t:0,b:{t:2,i:[{t:3}],s:"贿赂奖励正在处理中，余额暂时被冻结并显示为0，请不要担心，您的资金是安全的。"}},"membership-activation":{t:0,b:{t:2,i:[{t:3,v:"新会员资格将会在 "},{t:5,i:0},{t:3,v:"激活"}]}},delegate:{t:0,b:{t:2,i:[{t:3}],s:"托管"}},delegating:{t:0,b:{t:2,i:[{t:3}],s:"正在托管..."}},delegated:{t:0,b:{t:2,i:[{t:3}],s:"您已托管给Votium"}},"not-delegated":{t:0,b:{t:2,i:[{t:3}],s:"您尚未托管给 Votium"}},"delegation-advice":{t:0,b:{t:2,i:[{t:3}],s:"将投票权托管给Votium，既可以自动投票，又能确保您能获得最高的收益。"}},"delegation-changed":{t:0,b:{t:2,i:[{t:3}],s:"已成功向 Votium 授权。"}},"claim-notice":{t:0,b:{t:2,i:[{t:3}],s:"您尚未领取的收益已经自动复利，您可以自由选择是否领取。"}},"withdraw-as":{t:0,b:{t:2,i:[{t:3}],s:"提款币种:"}},"withdraw-as-token":{t:0,b:{t:2,i:[{t:3,v:"提款为 "},{t:5,i:0}]}},"sell-token":{t:0,b:{t:2,i:[{t:3,v:"卖出 "},{t:5,i:0}]}},nothing:{t:0,b:{t:2,i:[{t:3}],s:"没有未提取的收益"}},"claim-info":{t:0,b:{t:2,i:[{t:3,v:"如果您修改收益结算的币种, 我们将在存款之前，帮您将 "},{t:5,i:0},{t:3,v:" 兑换为您的所选资产 . "},{t:5,i:0},{t:3,v:" 是一种共享代币，将会保持不变. 潜在的"},{t:5,i:1},{t:3,v:"将会因自动复投而增长."}]}},title:{t:0,b:{t:2,i:[{t:3}],s:"欢迎来到 Union"}},"join-1":{t:0,b:{t:2,i:[{t:3}],s:"以太坊的Gas正在不断上涨, CVX锁仓量正在不断提高。 小玩家将越来越没有能力处理从votium领取的不同种类的奖励代币。"}},"join-2":{t:0,b:{t:2,i:[{t:3}],s:"union将会帮助用户领取收益，并处理为单一的资产，节省处理奖励代币的费用。"}},"join-3":{t:0,b:{t:2,i:[{t:3}],s:"加入union，我们将会帮助处理您的贿赂奖励，并复投到cvxCRV获取更多收益。"}},"modal-title":{t:0,b:{t:2,i:[{t:3}],s:"Union会员"}},"no-lock":{t:0,b:{t:2,i:[{t:3}],s:"你还没有锁定任何CVX，您确定想要加入Union会员嘛？"}},join:{t:0,b:{t:2,i:[{t:3}],s:"加入Union"}},joining:{t:0,b:{t:2,i:[{t:3}],s:"正在加入 ..."}},"already-forwarded":{t:0,b:{t:2,i:[{t:3}],s:"已经转发给另外一个地址"}},"forwarding-in-progress":{t:0,b:{t:2,i:[{t:3}],s:"地址转发即将过期"}},joined:{t:0,b:{t:2,i:[{t:3}],s:"你成功加入了联盟，欢迎你，同志！"}},left:{t:0,b:{t:2,i:[{t:3}],s:"你已成功脱离联盟。再见了，同志"}},"nothing-locked":{t:0,b:{t:2,i:[{t:3}],s:"你在下一个周期中没有锁定的CVX"}},member:{t:0,b:{t:2,i:[{t:3}],s:"您是Union的会员"}},"no-member":{t:0,b:{t:2,i:[{t:3}],s:"您不是Union的会员"}},leave:{t:0,b:{t:2,i:[{t:3}],s:"注销会员"}},"leave-title":{t:0,b:{t:2,i:[{t:3}],s:"Union会员"}},"leave-confirmation":{t:0,b:{t:2,i:[{t:3}],s:"您确定要注销Union会员嘛?"}},"leave-notice":{t:0,b:{t:2,i:[{t:3}],s:"如果您注销会员，您将无法重新加入直到本周期结束."}},rejoin:{t:0,b:{t:2,i:[{t:3}],s:"重新加入会员"}},"active-in":{t:0,b:{t:2,i:[{t:3,v:"活跃会员数量 "},{t:5,i:0}]}},"prisma-warning":{t:0,b:{t:2,i:[{t:3}],s:"谨防网络钓鱼欺诈和冒名顶替者！在与智能合约互动之前，请务必仔细检查超链接。始终尽职尽责。不值得因为走捷径或疏忽而吃亏。"}},"prisma-info":{t:0,b:{t:2,i:[{t:3}],s:"Prisma 是一款 DeFi 工具，它利用以太坊的 LST 来铸造 mkUSD，这是一种稳定币，通过 Curve 和 Convex Finance 上的激励措施而得到提升。用户除了获得以太坊赌注奖励外，还可以获得交易费、CRV、CVX 和 PRISMA。它基于 Liquity 构建，是一个具有去中心化稳定币的弹性协议，由 Prisma DAO 监督。"}},"prisma-deadline":{t:0,b:{t:2,i:[{t:3}],s:"该空投可在<strong>2024 年 1 月 2 日</strong>前申请。<br>超过该日期，无人认领的金额将转换为 CVX，并分配给 uCVX pounder 中的人"}},"prisma-learn-more":{t:0,b:{t:2,i:[{t:3}],s:"了解有关 Prisma 的更多信息。"}},"prisma-loading":{t:0,b:{t:2,i:[{t:3}],s:"正在加载..."}},"prisma-eligible-yay":{t:0,b:{t:2,i:[{t:3}],s:"您符合条件！"}},"prisma-eligible-nay":{t:0,b:{t:2,i:[{t:3}],s:"你<strong>没有</strong>资格"}},"prisma-claim":{t:0,b:{t:2,i:[{t:3}],s:"申请 cvxPRISMA"}}},fr:{apy:{t:0,b:{t:2,i:[{t:3}],s:"APY"}},tvl:{t:0,b:{t:2,i:[{t:3}],s:"TVL"}},submit:{t:0,b:{t:2,i:[{t:3}],s:"Valider"}},submitting:{t:0,b:{t:2,i:[{t:3}],s:"Validation en cours..."}},"allocation-changed":{t:0,b:{t:2,i:[{t:3}],s:"Allocation mise à jour avec succès !"}},allocation:{t:0,b:{t:2,i:[{t:3}],s:"Allocation"}},"rewards-balance":{t:0,b:{t:2,i:[{t:3}],s:"Solde des récompenses ($)"}},frozen:{t:0,b:{t:2,i:[{t:3}],s:"Les récompenses des pots-de-vin sont en cours de traitement, les soldes sont temporairement gelés et affichent $0. Pas de panique."}},"membership-activation":{t:0,b:{t:2,i:[{t:3,v:"Les nouvelles adhésions seront activées dans "},{t:5,i:0}]}},delegate:{t:0,b:{t:2,i:[{t:3}],s:"Déléguer"}},delegating:{t:0,b:{t:2,i:[{t:3}],s:"Délégation en cours..."}},delegated:{t:0,b:{t:2,i:[{t:3}],s:"Vous avez délégué à Votium"}},"not-delegated":{t:0,b:{t:2,i:[{t:3}],s:"Vous n'avez pas délégué à Votium"}},"delegation-advice":{t:0,b:{t:2,i:[{t:3}],s:"Déléguer à Votium permet à la fois d'automatiser le vote et de garantir que vous obtenez le meilleur ratio $/vlCVX possible."}},"delegation-changed":{t:0,b:{t:2,i:[{t:3}],s:"La délégation a été établie avec succès à Votium."}},"claim-notice":{t:0,b:{t:2,i:[{t:3}],s:"Votre solde non réclamé est déjà réinvesti automatiquement, donc la réclamation est facultative."}},"withdraw-as":{t:0,b:{t:2,i:[{t:3}],s:"Retirer en tant que :"}},"withdraw-as-token":{t:0,b:{t:2,i:[{t:3,v:"Retirer en tant que "},{t:5,i:0}]}},"sell-token":{t:0,b:{t:2,i:[{t:3,v:"Vendre "},{t:5,i:0}]}},nothing:{t:0,b:{t:2,i:[{t:3}],s:"Rien à réclamer"}},"claim-info":{t:0,b:{t:2,i:[{t:3,v:"Si vous modifiez l'actif de retrait 'retirer en tant que', nous échangerons votre "},{t:5,i:0},{t:3,v:" contre l'actif choisi avant de le déposer dans votre portefeuille. "},{t:5,i:0},{t:3,v:" est un token de part dont le nombre reste constant. La valeur sous-jacente de "},{t:5,i:1},{t:3,v:" augmentera à mesure qu'elle se compose."}]}},title:{t:0,b:{t:2,i:[{t:3}],s:"Bienvenue sur L'Union"}},"join-1":{t:0,b:{t:2,i:[{t:3}],s:"L'augmentation des coûts du gaz Ethereum, la dilution des réserves de CVX et la multiplication des différents tokens de récompense Votium rendent de plus en plus difficile pour les petits investisseurs de participer aux pools de Votium et de réaliser des profits."}},"join-2":{t:0,b:{t:2,i:[{t:3}],s:"Il est temps pour la classe ouvrière de se syndiquer, de regrouper collectivement nos récompenses et de les convertir en un seul actif réclamable, sans gaspiller inutilement des profits, tout en alimentant notre dynamisme collectif."}},"join-3":{t:0,b:{t:2,i:[{t:3}],s:"En rejoignant L'Union, nous prendrons soin de vos pots-de-vin et les consoliderons en cvxCRV avec réinvestissement automatique."}},"modal-title":{t:0,b:{t:2,i:[{t:3}],s:"Adhésion à l'Union"}},"no-lock":{t:0,b:{t:2,i:[{t:3}],s:"Vous n'avez verrouillé aucun CVX pour l'instant. Êtes-vous sûr de vouloir rejoindre l'Union?"}},join:{t:0,b:{t:2,i:[{t:3}],s:"Rejoindre l'Union"}},joining:{t:0,b:{t:2,i:[{t:3}],s:"Adhésion en cours..."}},"already-forwarded":{t:0,b:{t:2,i:[{t:3}],s:"Déjà transféré à une autre adresse"}},"forwarding-in-progress":{t:0,b:{t:2,i:[{t:3}],s:"Expiration de la redirection d'adresse en cours"}},joined:{t:0,b:{t:2,i:[{t:3}],s:"Vous avez réussi à rejoindre l'Union, bienvenue camarade !"}},left:{t:0,b:{t:2,i:[{t:3}],s:"Vous avez réussi à quitter l'Union. Au revoir camarade !"}},"nothing-locked":{t:0,b:{t:2,i:[{t:3}],s:"Vous n'avez aucun CVX verrouillé pour le tour à venir"}},member:{t:0,b:{t:2,i:[{t:3}],s:"Vous êtes membre de L'Union"}},"no-member":{t:0,b:{t:2,i:[{t:3}],s:"Vous n'êtes pas membre de L'Union"}},leave:{t:0,b:{t:2,i:[{t:3}],s:"Quitter L'Union"}},"leave-title":{t:0,b:{t:2,i:[{t:3}],s:"Adhésion à l'Union"}},"leave-confirmation":{t:0,b:{t:2,i:[{t:3}],s:"Êtes-vous sûr de vouloir quitter L'Union?"}},"leave-notice":{t:0,b:{t:2,i:[{t:3}],s:"Lorsque vous partez, vous ne pourrez pas rejoindre avant qu'au moins un tour soit passé."}},rejoin:{t:0,b:{t:2,i:[{t:3}],s:"Rejoindre à nouveau L'Union"}},"active-in":{t:0,b:{t:2,i:[{t:3,v:"Adhésion active dans "},{t:5,i:0}]}},"prisma-warning":{t:0,b:{t:2,i:[{t:3}],s:"Attention aux escroqueries par hameçonnage et aux imposteurs ! Vérifiez toujours l'URL avant d'interagir avec les contrats intelligents. Faites toujours preuve de diligence raisonnable. Cela ne vaut pas la peine de se faire reprendre pour des raccourcis ou de la négligence."}},"prisma-info":{t:0,b:{t:2,i:[{t:3}],s:"Prisma, un outil DeFi, exploite les LST d'Ethereum pour frapper mkUSD, un stablecoin stimulé par des incitations sur Curve et Convex Finance. Les utilisateurs peuvent recevoir des commissions de trading, CRV, CVX et PRISMA en plus de leurs récompenses de mise en Ethereum. Construit sur Liquity, c'est un protocole résilient avec un stablecoin décentralisé, supervisé par la DAO Prisma."}},"prisma-deadline":{t:0,b:{t:2,i:[{t:3}],s:"Le parachutage peut être revendiqué jusqu'au <strong>2 janvier 2024</strong>.<br>Au-delà de cette date, le montant non réclamé sera converti en CVX et distribué aux personnes du groupe uCVX."}},"prisma-learn-more":{t:0,b:{t:2,i:[{t:3}],s:"En savoir plus sur Prisma."}},"prisma-loading":{t:0,b:{t:2,i:[{t:3}],s:"Chargement..."}},"prisma-eligible-yay":{t:0,b:{t:2,i:[{t:3}],s:"Vous êtes éligible !"}},"prisma-eligible-nay":{t:0,b:{t:2,i:[{t:3}],s:"Vous n'êtes <strong>PAS</strong> éligible"}},"prisma-claim":{t:0,b:{t:2,i:[{t:3}],s:"Réclamer cvxPRISMA"}}}}})}typeof pt=="function"&&pt(X6);const uU=pe(X6,[["__scopeId","data-v-d37b7961"]]),lU={class:"balance"},K6=ae({__name:"Balance",props:{airdrop:{default:null}},setup(e){const{t}=Me(),n=M(()=>{var o;return`${((o=e.airdrop)==null?void 0:o.tkn)??"???"} Balance`}),s=M(()=>{var o;return((o=e.airdrop)==null?void 0:o.amountAsset)??0}),r=M(()=>{var o;return((o=e.airdrop)==null?void 0:o.amountDollar)??0});return(o,i)=>{const a=Pt,c=td;return F(),J("div",lU,[$(c,{class:"token",label:v(n),"has-value":!!o.airdrop},{default:Y(()=>[$(a,{"show-zero":"",type:"dollar",value:v(s),precision:3,"show-symbol":!1},null,8,["value"])]),_:1},8,["label","has-value"]),$(c,{class:"dollars",label:v(t)("rewards-balance"),"has-value":!!o.airdrop},{default:Y(()=>[$(a,{"show-zero":"",type:"dollar",value:v(r),precision:2},null,8,["value"])]),_:1},8,["label","has-value"])])}}});typeof pt=="function"&&pt(K6);const du=pe(K6,[["__scopeId","data-v-9a4fc391"]]),fc=[{inputs:[{internalType:"address[]",name:"accounts",type:"address[]"}],name:"batchAddressCheck",outputs:[{internalType:"address[]",name:"",type:"address[]"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"uint256",name:"size",type:"uint256"},{internalType:"uint256",name:"page",type:"uint256"}],name:"forwardPage",outputs:[{internalType:"address[]",name:"",type:"address[]"}],stateMutability:"view",type:"function"},{inputs:[],name:"nextEpoch",outputs:[{internalType:"uint256",name:"",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"",type:"address"}],name:"registry",outputs:[{internalType:"uint256",name:"start",type:"uint256"},{internalType:"address",name:"to",type:"address"},{internalType:"uint256",name:"expiration",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_to",type:"address"}],name:"setRegistry",outputs:[],stateMutability:"nonpayable",type:"function"},{inputs:[],name:"setToExpire",outputs:[],stateMutability:"nonpayable",type:"function"}],Q6=ae({__name:"Deadline",setup(e){const{t}=Me();let n;const s=le(t("membership-activation",["?"])),{data:r}=Tt({abi:fc,address:zi,functionName:"nextEpoch"}),o=M(()=>r.value?new Date(Ie(r.value,0n)*1e3):void 0);return Vi(o,i=>{n&&clearInterval(n),n=setInterval(()=>{s.value=t("membership-activation",[Rh(i)])})},{immediate:!0}),(i,a)=>{const c=He;return F(),fe(c,{class:"deadline border-flash"},{default:Y(()=>[T("h1",null,Z(v(s)),1)]),_:1})}}});typeof pt=="function"&&pt(Q6);const dU=pe(Q6,[["__scopeId","data-v-3a1deb7e"]]),fU={class:"claim-body"},pU={class:"withdraw"},mU={class:"pounding"},hU={class:"label"},yU={class:"info"},bU={class:"buttons"},gU=["src"],Z6=ae({__name:"Claim",props:{airdrop:{}},emits:["claimed"],setup(e,{emit:t}){const{t:n}=Me(),s=t,{address:r}=tt(),o=rt(),i=le([]),a=le(void 0),c=le(!1),u=le(!1);let l=null;const d=le(!1),f=le(0),p=le(0),m=le(""),h=M(()=>{var C;if(!((C=e.airdrop)!=null&&C.claim))return n("nothing");const x=a.value?a.value.label:"?";return n("withdraw-as-token",[x])}),y=M(()=>{var x;return((x=e.airdrop)==null?void 0:x.tkn)??"TKN"}),b=M(()=>{var x;return((x=e.airdrop)==null?void 0:x.utkn)??"uTKN"}),g=M(()=>!!e.airdrop&&e.airdrop.amount>0n);Vi(()=>e.airdrop,x=>{i.value=[],XL(x)?i.value=v7(()=>o,()=>r.value,()=>x):KL(x)?i.value=A7(()=>o,()=>r.value,()=>x):QL(x)?i.value=L7(()=>o,()=>r.value,()=>x):ZL(x)&&(i.value=k7(()=>o,()=>r.value,()=>x)),a.value=i.value[0]},{immediate:!0});const w=async x=>{if(!a.value)return;const C=await a.value.withdrawDecimals();if(C){if(a.value.getMinAmountOut){if(!x){d.value=!0,l=()=>w(!0);const k=await a.value.claimBalance();if(!k)return;const S=await mn();f.value=await a.value.getMinAmountOut(S,k,0).then(R=>Ie(R,18n)),m.value=a.value.withdrawSymbol;return}}else p.value=0;await Qs(c,async()=>{if(!a.value)return;const k=$t(p.value,C);await a.value.zap(k),s("claimed")})}},_=x=>{a.value=x},A=async x=>{d.value=!1,p.value=x,await(l==null?void 0:l())};return(x,C)=>{const k=Mt,S=He;return F(),fe(S,{class:"claim"},{default:Y(()=>{var R;return[T("div",fU,[T("div",pU,[T("div",mU,Z(v(n)("claim-notice")),1),T("div",hU,Z(v(n)("withdraw-as")),1),v(a)?(F(),fe(Xp,{key:0,modelValue:v(a),"onUpdate:modelValue":C[0]||(C[0]=B=>$e(a)?a.value=B:null),zaps:v(i),onSelect:_},null,8,["modelValue","zaps"])):ye("",!0),T("div",yU,Z(v(n)("claim-info",[v(b),v(y)])),1)]),T("div",bU,[$(k,{class:"primary",disabled:!x.airdrop||v(c)||!v(g),"chain-id":v(It).id,onClick:C[1]||(C[1]=B=>w(!1))},{default:Y(()=>[we(Z(v(h)),1)]),_:1},8,["disabled","chain-id"]),$(k,{class:"swap","chain-id":v(It).id,onClick:C[2]||(C[2]=B=>u.value=!0)},{default:Y(()=>{var B;return[T("img",{src:v(Qp)},null,8,gU),we(" "+Z(v(n)("swap-token",[((B=x.airdrop)==null?void 0:B.tkn)??"?"])),1)]}),_:1},8,["chain-id"])])]),$(Kp,{show:v(u),swap:((R=x.airdrop)==null?void 0:R.swap)??null,onClose:C[3]||(C[3]=B=>u.value=!1)},null,8,["show","swap"]),$(Wh,{show:v(d),"symbol-output":v(m),"min-amount-out-ref":v(f),onClose:C[4]||(C[4]=B=>d.value=!1),onNo:C[5]||(C[5]=B=>d.value=!1),onYes:A},null,8,["show","symbol-output","min-amount-out-ref"])]}),_:1})}}});typeof pt=="function"&&pt(Z6);const fu=pe(Z6,[["__scopeId","data-v-da4a7806"]]),Y6=[{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"lockedBalanceOf",outputs:[{internalType:"uint256",name:"amount",type:"uint256"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"address",name:"_user",type:"address"}],name:"lockedBalances",outputs:[{internalType:"uint256",name:"total",type:"uint256"},{internalType:"uint256",name:"unlockable",type:"uint256"},{internalType:"uint256",name:"locked",type:"uint256"},{components:[{internalType:"uint112",name:"amount",type:"uint112"},{internalType:"uint112",name:"boosted",type:"uint112"},{internalType:"uint32",name:"unlockTime",type:"uint32"}],internalType:"struct CvxLocker.LockedBalance[]",name:"lockData",type:"tuple[]"}],stateMutability:"view",type:"function"}];function J6(e){const{data:t,refetch:n}=Tt({address:zi,abi:fc,functionName:"registry",args:M(()=>[e.value]),query:{enabled:M(()=>!!e.value)}});return{status:M(()=>{if(!t.value)return;const[r,o,i]=t.value,a=o.toLocaleLowerCase(),c=Number(r)*1e3,u=c>=new Date().getTime(),l=Number(i)*1e3,d=l!==68719476735*1e3,f=d&&new Date().getTime()<l,p=d&&!f&&c<l,m=!!Ro.find(h=>h===a)&&!p;return{to:a,forwarded:m,pending:u,start:c,expiring:f,expired:p}}),refetch:n}}const vU={class:"join"},wU={class:"text"},e5=ae({__name:"Join",emits:["joined"],setup(e,{emit:t}){const{t:n}=Me(),s=t,{isConnected:r,address:o}=tt(),{data:i}=Tt({abi:Y6,address:Eh,functionName:"lockedBalanceOf",args:M(()=>[o.value]),query:{enabled:M(()=>!!o.value)}}),{status:a}=J6(o),c=M(()=>i.value?i.value<=0n:!0),u=M(()=>a.value?a.value.expiring:!1),l=M(()=>{if(!a.value)return!1;const{expired:b,to:g}=a.value;function w(_){return Ro.includes(_)||_==="0x0000000000000000000000000000000000000000"}return!b&&!w(g)}),d=M(()=>l.value||u.value),f=M(()=>y.value?n("joining"):l.value?n("already-forwarded"):u.value?n("forwarding-in-progress"):n("join")),p=le(!1);function m(b){if(c.value&&!b){p.value=!0;return}h()}const{execute:h,isExecuting:y}=Un(b=>{b({address:zi,abi:fc,functionName:"setRegistry",args:[Ro[0]]})},{successMessage:()=>n("joined"),onSuccess:()=>{s("joined")}});return(b,g)=>{const w=Mt,_=cd,A=He;return F(),fe(A,{title:v(n)("title")},{default:Y(()=>[T("div",vU,[T("div",wU,[T("p",null,Z(v(n)("join-1")),1),T("p",null,Z(v(n)("join-2")),1),T("p",null,Z(v(n)("join-3")),1)]),v(r)?(F(),fe(w,{key:0,class:"action-button primary",disabled:v(y)||v(d),"chain-id":v(It).id,onClick:g[0]||(g[0]=x=>m(!1))},{default:Y(()=>[we(Z(v(f)),1)]),_:1},8,["disabled","chain-id"])):(F(),fe(Mh,{key:1,class:"action-button"})),$(_,{title:v(n)("modal-title"),show:v(p),onClose:g[1]||(g[1]=x=>p.value=!1),onNo:g[2]||(g[2]=x=>p.value=!1),onYes:g[3]||(g[3]=x=>{p.value=!1,m(!0)})},{default:Y(()=>[T("span",null,Z(v(n)("no-lock")),1)]),_:1},8,["title","show"])])]),_:1},8,["title"])}}});typeof pt=="function"&&pt(e5);const _U=pe(e5,[["__scopeId","data-v-1473bac8"]]),t5=ae({__name:"Locks",setup(e){const{t}=Me(),{address:n}=tt(),{data:s}=Tt({abi:Y6,address:Eh,functionName:"lockedBalances",args:M(()=>[n.value]),query:{enabled:M(()=>!!n.value)}}),r=M(()=>{if(s.value){const[o,i]=s.value;return o-i>0n}else return!1});return(o,i)=>{const a=He;return v(r)?ye("",!0):(F(),fe(a,{key:0,class:"no-locks border-flash"},{default:Y(()=>[T("h1",null,Z(v(t)("nothing-locked")),1)]),_:1}))}}});typeof pt=="function"&&pt(t5);const xU=pe(t5,[["__scopeId","data-v-0bc98277"]]),n5=ae({__name:"Frozen",props:{airdrop:{default:null}},setup(e){const{t}=Me(),n=M(()=>e.airdrop?R6(e.airdrop.id):void 0),{data:s}=Tt({abi:dc,address:M(()=>{var r;return((r=n.value)==null?void 0:r.address)??dk}),functionName:"frozen",query:{enabled:M(()=>!!n.value),initialData:!1,initialDataUpdatedAt:0}});return(r,o)=>{const i=He;return v(s)?(F(),fe(i,{key:0,class:"frozen border-flash"},{default:Y(()=>[T("h1",null,Z(v(t)("frozen")),1)]),_:1})):ye("",!0)}}});typeof pt=="function"&&pt(n5);const pu=pe(n5,[["__scopeId","data-v-12652ad5"]]),gv=[{inputs:[{internalType:"address",name:"",type:"address"},{internalType:"bytes32",name:"",type:"bytes32"}],name:"delegation",outputs:[{internalType:"address",name:"",type:"address"}],stateMutability:"view",type:"function"},{inputs:[{internalType:"bytes32",name:"id",type:"bytes32"},{internalType:"address",name:"delegate",type:"address"}],name:"setDelegate",outputs:[],stateMutability:"nonpayable",type:"function"}],CU={class:"delegation"},AU={class:"not-delegated-body"},TU={class:"text"},s5=ae({__name:"Delegation",setup(e){const{t}=Me(),{address:n}=tt(),s=Ii("cvx.eth",{size:32}),{data:r,refetch:o}=Tt({abi:gv,address:$p,functionName:"delegation",args:M(()=>[n.value,s]),query:{enabled:M(()=>!!n.value)}}),i=M(()=>{var d;return((d=r.value)==null?void 0:d.toLocaleLowerCase())??""}),a=M(()=>i.value===gb),c=M(()=>l.value?"Delegating":"Delegate"),{execute:u,isExecuting:l}=Un(d=>{d({address:$p,abi:gv,functionName:"setDelegate",args:[s,gb]})},{successMessage:()=>t("delegation-changed"),onSuccess:()=>{o()}});return(d,f)=>{const p=He,m=Mt;return F(),J("div",CU,[v(a)?(F(),fe(p,{key:0,class:"delegated border-flash"},{default:Y(()=>[T("h1",null,Z(v(t)("delegated")),1)]),_:1})):(F(),fe(p,{key:1,class:"not-delegated border-flash"},{default:Y(()=>[T("div",AU,[T("div",TU,[T("h1",null,Z(v(t)("not-delegated")),1),T("p",null,Z(v(t)("delegation-advice")),1)]),$(m,{class:"action-button primary",disabled:v(l),"chain-id":v(It).id,onClick:v(u)},{default:Y(()=>[we(Z(v(c)),1)]),_:1},8,["disabled","chain-id","onClick"])])]),_:1}))])}}});typeof pt=="function"&&pt(s5);const EU=pe(s5,[["__scopeId","data-v-9f389f67"]]),SU={class:"status"},PU={key:0},kU={key:1},IU={key:2},RU=["disabled"],$U=["disabled"],r5=ae({__name:"Membership",props:{status:{default:null}},emits:["left","rejoined"],setup(e,{emit:t}){const{t:n}=Me();let s;const r=t,o=le(!1),i=le(""),a=M(()=>{var y;return((y=e.status)==null?void 0:y.forwarded)??!1}),c=M(()=>{var y;return((y=e.status)==null?void 0:y.pending)??!1}),u=M(()=>{var y;return((y=e.status)==null?void 0:y.expiring)??!1}),l=M(()=>{var y;return((y=e.status)==null?void 0:y.expired)??!1});Ce(c,()=>{var y;clearInterval(s),!(!c.value||!((y=e.status)!=null&&y.start))&&(s=setInterval(()=>{i.value=n("active-in",[Rh(new Date(e.status.start))])}))},{immediate:!0});let d="leave";function f(y){o.value=!c.value,!(o.value&&!y)&&(o.value=!1,d="leave",m())}function p(){d="rejoin",m()}const{execute:m,isExecuting:h}=Un(y=>{y(d==="leave"?{address:zi,abi:fc,functionName:"setToExpire"}:{address:zi,abi:fc,functionName:"setRegistry",args:[Ro[0]]})},{successMessage:()=>n(d==="leave"?"left":"joined"),onSuccess:()=>{r(d==="leave"?"left":"rejoined")}});return(y,b)=>{const g=cd,w=He;return F(),fe(w,{class:Pe(["border-flash",{forwarded:v(a),pending:v(c),expiring:v(u),expired:v(l)}])},{default:Y(()=>[T("div",SU,[v(a)&&!v(c)&&!v(u)&&!v(l)?(F(),J("h1",PU,Z(v(n)("member")),1)):ye("",!0),v(c)?(F(),J("h1",kU,Z(v(i)),1)):ye("",!0),!v(a)||v(u)||v(l)?(F(),J("h1",IU,Z(v(n)("no-member")),1)):ye("",!0),v(a)&&!v(u)&&!v(l)?(F(),J("a",{key:3,disabled:v(h),onClick:b[0]||(b[0]=_=>f(!1))},Z(v(n)("leave")),9,RU)):ye("",!0),v(l)?(F(),J("a",{key:4,disabled:v(h),onClick:p},Z(v(n)("rejoin")),9,$U)):ye("",!0),$(g,{title:v(n)("leave-title"),show:v(o),onClose:b[1]||(b[1]=_=>o.value=!1),onNo:b[2]||(b[2]=_=>o.value=!1),onYes:b[3]||(b[3]=_=>{o.value=!1,f(!0)})},{default:Y(()=>[T("span",null,Z(v(n)("leave-confirmation")),1),T("span",null,Z(v(n)("leave-notice")),1)]),_:1},8,["title","show"])])]),_:1},8,["class"])}}});typeof pt=="function"&&pt(r5);const MU=pe(r5,[["__scopeId","data-v-ca9430fe"]]),OU={class:"union"},LU={key:0,class:"join"},FU={class:"tab"},NU={class:"tab"},BU={class:"tab"},DU={class:"tab"},UU={class:"tab"},o5=ae({__name:"Member.page",setup(e){const{t}=Me(),n=new zh(mn()),s=new pn,{address:r}=tt(),{status:o,refetch:i}=J6(r),a=M(()=>{if(!o.value)return!1;const{to:C}=o.value;function k(S){return Ro.includes(S)||S==="0x0000000000000000000000000000000000000000"}return!k(C)}),c=M(()=>o.value?o.value.forwarded&&!o.value.expiring&&!a.value:!1),{claim:u,refetch:l}=Ns(n,"union",r,!0),{claim:d,refetch:f}=Ns(n,"ufxs",r,!0),{claim:p,refetch:m}=Ns(n,"uprisma",r,!0),{claim:h,refetch:y}=Ns(n,"ucvx",r,!0);function b(){i(),l(),f(),y(),m()}const g=rt(),w=ti(()=>{const C=ft(g);if(!C)throw Error("Cannot create public viem client");return YL(C,s,u.value??void 0)}),_=ti(()=>{const C=ft(g);if(!C)throw Error("Cannot create public viem client");return JL(C,s,d.value??void 0)}),A=ti(()=>{const C=ft(g);if(!C)throw Error("Cannot create public viem client");return t7(C,s,h.value??void 0)}),x=ti(()=>{const C=ft(g);if(!C)throw Error("Cannot create public viem client");return e7(C,s,p.value??void 0)});return(C,k)=>{const S=JD,R=YD;return F(),J("div",OU,[v(c)?ye("",!0):(F(),J("div",LU,[$(Jp),$(_U,{onJoined:b}),$(dU)])),T("div",{class:Pe(["member",{isMember:v(c)}])},[v(c)?(F(),fe(Jp,{key:0})):ye("",!0),$(MU,{status:v(o),onLeft:b,onRejoined:b},null,8,["status"]),$(EU),$(xU),$(R,null,{default:Y(()=>[$(S,{header:v(t)("allocation")},{default:Y(()=>[T("div",FU,[$(uU)])]),_:1},8,["header"]),$(S,{header:"uCRV"},{default:Y(()=>[T("div",NU,[$(pu,{airdrop:v(w)},null,8,["airdrop"]),$(du,{airdrop:v(w)},null,8,["airdrop"]),$(fu,{airdrop:v(w),onClaimed:v(l)},null,8,["airdrop","onClaimed"])])]),_:1}),$(S,{header:"uFXS"},{default:Y(()=>[T("div",BU,[$(pu,{airdrop:v(_)},null,8,["airdrop"]),$(du,{airdrop:v(_)},null,8,["airdrop"]),$(fu,{airdrop:v(_),onClaimed:v(f)},null,8,["airdrop","onClaimed"])])]),_:1}),$(S,{header:"uCVX"},{default:Y(()=>[T("div",DU,[$(pu,{airdrop:v(A)},null,8,["airdrop"]),$(du,{airdrop:v(A)},null,8,["airdrop"]),$(fu,{airdrop:v(A),onClaimed:v(y)},null,8,["airdrop","onClaimed"])])]),_:1}),$(S,{header:"uPRISMA"},{default:Y(()=>[T("div",UU,[$(pu,{airdrop:v(x)},null,8,["airdrop"]),$(du,{airdrop:v(x)},null,8,["airdrop"]),$(fu,{airdrop:v(x),onClaimed:v(m)},null,8,["airdrop","onClaimed"])])]),_:1})]),_:1})],2)])}}});typeof pt=="function"&&pt(o5);const VU=pe(o5,[["__scopeId","data-v-8e1f95ee"]]),jU=[{path:"/union",redirect:{name:"union"}},{path:"/union/member",name:"union",component:VU}],HU={title:"Union",titleRoute:"/union",visible:!0,planeX:55,menuHeader:Dh,items:[],forceShowMenu:!1};let i5="http://localhost:8545";i5=void 0;function zU(e=[]){return qk({chains:[It],connectors:[ic(),...e],transports:{[It.id]:Xk([tb(i5,{batch:{wait:100}}),Gk(ic),tb("https://eth.llamarpc.com",{batch:{wait:200}})])}})}class qU{constructor(t){this.value=t}entries(){return Object.entries(this.value)}}Array.prototype.take=function(e){return this.slice(0,e)};Array.prototype.takeRight=function(e){return this.slice(-e)};Array.prototype.drop=function(e=1){return this.slice(Math.max(0,e))};Array.prototype.dropWhile=function(e){const t=this.findIndex((n,s,r)=>!e(n,s,r));return t===-1?[]:this.slice(t)};Array.prototype.zip=function(...e){return this.map((t,n)=>[t,...e.map(s=>s[n])])};Array.prototype.uniq=function(){return[...new Set(this)]};Array.prototype.uniqWith=function(e){return this.filter((t,n)=>this.findIndex(s=>e(t,s))===n)};Array.prototype.orderBy=function(e,t="asc"){const n=Array.isArray(e)?e:[e],s=Array.isArray(t)?t:[t];return[...this].sort((r,o)=>{for(let i=0;i<n.length;i++){const a=n[i],c=Array.isArray(t)?s[i]||"asc":t,u=a(r),l=a(o);if(u!==l)return(u>l?1:-1)*(c==="asc"?1:-1)}return 0})};Array.prototype.groupBy=function(e){const t=Object.groupBy(this,e);return new qU(t)};Array.prototype.sumBy=function(e){return this.reduce((t,n)=>t+e(n),0)};Array.prototype.meanBy=function(e){const t=this.sumBy(e);return this.length>0?t/this.length:0};Array.prototype.maxBy=function(e){return this.reduce((t,n)=>e(n)>e(t)?n:t)};Array.prototype.difference=function(...e){const t=new Set(e.flat());return this.filter(n=>!t.has(n))};function WU(e,t){const n=iA(e);for(const i of t.plugins??[])n.use(i);const s=w$();n.use(s);const r=new A_({defaultOptions:{queries:{staleTime:1e3*60*5,queryKeyHashFn:$_}},queryCache:new C_({onError:(i,a)=>{i.message.includes("Connector not connected")||i.message.includes("connector2.getAccounts is not a function")||i.message.includes("getAccounts is not a function")||En({text:`Failed querying ${a.queryHash} >>> ${i.message}`,type:"error"})}})}),o=EM({history:nM(),routes:t.routes});return n.use(o).use(wI,{queryClient:r}).use(jR).use(qI,{config:zU(t.extraWagmiConnectors)}),{app:n,pinia:s}}const GU=wh({projectId:"7a61bbd683f613a5308ca86fd4cb14f7",showQrModal:!0,qrModalOptions:{themeMode:"dark"}}),Bc=[],Dc=[...l9];Bc.push(HU),Dc.push(...jU);Bc.push(dD);Bc.push(zD);Bc.push(GL);Dc.push(...HD);Dc.push(...WL);Dc.push(...lD);const{app:XU}=WU(RO,{extraWagmiConnectors:[GU,vh()],plugins:[TA({legacy:!1,locale:"en",fallbackLocale:"en"})],routes:Dc}),KU=Lc();KU.pages=Bc;XU.mount("#app");export{ue as B,ka as H,$i as _,Gn as a,fl as b,Dm as c,ae as d,NE as e,QT as f,bs as g,Fr as h,rh as i,kc as j,P8 as k,Gs as l,Ji as m,Js as n,Cm as o,ms as p,le as r,Bt as s,ll as t,Ce as w};
